ChatChoice interface
The representation of a single prompt completion as part of an overall chat completions request.
Generally, n
choices are generated per provided prompt with a default value of 1.
Token limits and other settings may limit the number of choices generated.
Properties
content |
Information about the content filtering category (hate, sexual, violence, self_harm), if it has been detected, as well as the severity level (very_low, low, medium, high-scale that determines the intensity and risk level of harmful content) and if it has been filtered or not. |
delta | The delta message content for a streaming response. |
enhancements | Represents the output results of Azure OpenAI enhancements to chat completions, as configured via the matching input provided in the request. This supplementary information is only available when using Azure OpenAI and only when the request is configured to use enhancements. |
finish |
The reason the model stopped generating tokens, together with any applicable details. This structured representation replaces 'finish_reason' for some models. |
finish |
The reason that this chat completions choice completed its generated. |
index | The ordered index associated with this chat completions choice. |
logprobs | The log probability information for this choice, as enabled via the 'logprobs' request option. |
message | The chat message for a given chat completions prompt. |
Property Details
contentFilterResults
Information about the content filtering category (hate, sexual, violence, self_harm), if it has been detected, as well as the severity level (very_low, low, medium, high-scale that determines the intensity and risk level of harmful content) and if it has been filtered or not.
contentFilterResults?: ContentFilterResultsForChoice
Property Value
delta
The delta message content for a streaming response.
delta?: ChatResponseMessage
Property Value
enhancements
Represents the output results of Azure OpenAI enhancements to chat completions, as configured via the matching input provided in the request. This supplementary information is only available when using Azure OpenAI and only when the request is configured to use enhancements.
enhancements?: AzureChatEnhancements
Property Value
finishDetails
The reason the model stopped generating tokens, together with any applicable details. This structured representation replaces 'finish_reason' for some models.
finishDetails?: ChatFinishDetailsUnion
Property Value
finishReason
The reason that this chat completions choice completed its generated.
finishReason: null | string
Property Value
null | string
index
The ordered index associated with this chat completions choice.
index: number
Property Value
number
logprobs
The log probability information for this choice, as enabled via the 'logprobs' request option.
logprobs: null | ChatChoiceLogProbabilityInfo
Property Value
null | ChatChoiceLogProbabilityInfo
message
The chat message for a given chat completions prompt.
message?: ChatResponseMessage
Property Value
Azure SDK for JavaScript