OpenAIChoice
@Serializable
A choice in an OpenAI chat completion response.
Example:
{
"index": 0,
"message": { "role": "assistant", "content": "Hello!" },
"finish_reason": "stop"
}Content copied to clipboard
Constructors
Link copied to clipboard
constructor(index: Int, message: OpenAIMessage, finishReason: String? = null, logprobs: OpenAIChoiceLogprobs? = null)
Properties
Link copied to clipboard
Why the model stopped: "stop", "length", "tool_calls", "content_filter" or "function_call" (deprecated). null while still generating.
Link copied to clipboard
Log probability information for the choice. Only present when logprobs is set to true in the request. null otherwise.
Link copied to clipboard
The message returned by the model.