Class ChatCompletion.Choice
-
- All Implemented Interfaces:
public final class ChatCompletion.Choice
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final class
ChatCompletion.Choice.Builder
A builder for Choice.
public final class
ChatCompletion.Choice.FinishReason
The reason the model stopped generating tokens. This will be
stop
if the model hit a natural stop point or a provided stop sequence,length
if the maximum number of tokens specified in the request was reached,content_filter
if content was omitted due to a flag from our content filters,tool_calls
if the model called a tool, orfunction_call
(deprecated) if the model called a function.public final class
ChatCompletion.Choice.Logprobs
Log probability information for the choice.
-
Method Summary
Modifier and Type Method Description final ChatCompletion.Choice.FinishReason
finishReason()
The reason the model stopped generating tokens. final Long
index()
The index of the choice in the list of choices. final Optional<ChatCompletion.Choice.Logprobs>
logprobs()
Log probability information for the choice. final ChatCompletionMessage
message()
A chat completion message generated by the model. final JsonField<ChatCompletion.Choice.FinishReason>
_finishReason()
The reason the model stopped generating tokens. final JsonField<Long>
_index()
The index of the choice in the list of choices. final JsonField<ChatCompletion.Choice.Logprobs>
_logprobs()
Log probability information for the choice. final JsonField<ChatCompletionMessage>
_message()
A chat completion message generated by the model. final Map<String, JsonValue>
_additionalProperties()
final ChatCompletion.Choice
validate()
final ChatCompletion.Choice.Builder
toBuilder()
Boolean
equals(Object other)
Integer
hashCode()
String
toString()
final static ChatCompletion.Choice.Builder
builder()
-
-
Method Detail
-
finishReason
final ChatCompletion.Choice.FinishReason finishReason()
The reason the model stopped generating tokens. This will be
stop
if the model hit a natural stop point or a provided stop sequence,length
if the maximum number of tokens specified in the request was reached,content_filter
if content was omitted due to a flag from our content filters,tool_calls
if the model called a tool, orfunction_call
(deprecated) if the model called a function.
-
logprobs
final Optional<ChatCompletion.Choice.Logprobs> logprobs()
Log probability information for the choice.
-
message
final ChatCompletionMessage message()
A chat completion message generated by the model.
-
_finishReason
final JsonField<ChatCompletion.Choice.FinishReason> _finishReason()
The reason the model stopped generating tokens. This will be
stop
if the model hit a natural stop point or a provided stop sequence,length
if the maximum number of tokens specified in the request was reached,content_filter
if content was omitted due to a flag from our content filters,tool_calls
if the model called a tool, orfunction_call
(deprecated) if the model called a function.
-
_logprobs
final JsonField<ChatCompletion.Choice.Logprobs> _logprobs()
Log probability information for the choice.
-
_message
final JsonField<ChatCompletionMessage> _message()
A chat completion message generated by the model.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
validate
final ChatCompletion.Choice validate()
-
toBuilder
final ChatCompletion.Choice.Builder toBuilder()
-
builder
final static ChatCompletion.Choice.Builder builder()
-
-
-
-