class

OpenAI::ChatCompletionTokenLogprob

Inherits JSON::Serializable < Reference < Object

Constructors

new(token : String = "", logprob : Float64 = 0.0, bytes : ChatCompletionTokenLogprobBytes = nil, top_logprobs : Array(ChatCompletionTokenLogprobTopLogprobsItem) = [] of ChatCompletionTokenLogprobTopLogprobsItem)
Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source

Instance methods

bytes
Source
bytes=(bytes : ChatCompletionTokenLogprobBytes)
Source
logprob

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

Source
logprob=(logprob : Float64)

The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.

Source
token

The token.

Source
token=(token : String)

The token.

Source
top_logprobs

List of the most likely tokens and their log probability, at this token position. In rare cases, there may be fewer than the number of requested top_logprobs returned.

Source
top_logprobs=(top_logprobs : Array(ChatCompletionTokenLogprobTopLogprobsItem))

List of the most likely tokens and their log probability, at this token position. In rare cases, there may be fewer than the number of requested top_logprobs returned.

Source