Skip to main content
The Python SDK and docs are currently in beta. Report issues on GitHub.
Chat completion choice

Fields

FieldTypeRequiredDescriptionExample
finish_reasonNullable[components.ChatFinishReasonEnum]:heavy_check_mark:N/Astop
indexint:heavy_check_mark:Choice index0
logprobsOptionalNullable[components.ChatTokenLogprobs]:heavy_minus_sign:Log probabilities for the completion{"content": [{"bytes": null,"logprob": -0.612345,"token": " Hello","top_logprobs": []}
],
“refusal”: null<br/>}
messagecomponents.ChatAssistantMessage:heavy_check_mark:Assistant message for requests and responses{"content": "What is the capital of France?","role": "user"}