Class ChatCompletionTokenLogprob.Builder
-
- All Implemented Interfaces:
public final class ChatCompletionTokenLogprob.Builder
-
-
Constructor Summary
Constructors Constructor Description ChatCompletionTokenLogprob.Builder()
-
Method Summary
Modifier and Type Method Description final ChatCompletionTokenLogprob.Builder
token(String token)
The token. final ChatCompletionTokenLogprob.Builder
token(JsonField<String> token)
The token. final ChatCompletionTokenLogprob.Builder
bytes(List<Long> bytes)
A list of integers representing the UTF-8 bytes representation of the token. final ChatCompletionTokenLogprob.Builder
bytes(Optional<List<Long>> bytes)
A list of integers representing the UTF-8 bytes representation of the token. final ChatCompletionTokenLogprob.Builder
bytes(JsonField<List<Long>> bytes)
A list of integers representing the UTF-8 bytes representation of the token. final ChatCompletionTokenLogprob.Builder
addByte(Long byte_)
A list of integers representing the UTF-8 bytes representation of the token. final ChatCompletionTokenLogprob.Builder
logprob(Double logprob)
The log probability of this token, if it is within the top 20 most likely tokens. final ChatCompletionTokenLogprob.Builder
logprob(JsonField<Double> logprob)
The log probability of this token, if it is within the top 20 most likely tokens. final ChatCompletionTokenLogprob.Builder
topLogprobs(List<ChatCompletionTokenLogprob.TopLogprob> topLogprobs)
List of the most likely tokens and their log probability, at this token position. final ChatCompletionTokenLogprob.Builder
topLogprobs(JsonField<List<ChatCompletionTokenLogprob.TopLogprob>> topLogprobs)
List of the most likely tokens and their log probability, at this token position. final ChatCompletionTokenLogprob.Builder
addTopLogprob(ChatCompletionTokenLogprob.TopLogprob topLogprob)
List of the most likely tokens and their log probability, at this token position. final ChatCompletionTokenLogprob.Builder
additionalProperties(Map<String, JsonValue> additionalProperties)
final ChatCompletionTokenLogprob.Builder
putAdditionalProperty(String key, JsonValue value)
final ChatCompletionTokenLogprob.Builder
putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
final ChatCompletionTokenLogprob.Builder
removeAdditionalProperty(String key)
final ChatCompletionTokenLogprob.Builder
removeAllAdditionalProperties(Set<String> keys)
final ChatCompletionTokenLogprob
build()
-
-
Method Detail
-
token
final ChatCompletionTokenLogprob.Builder token(String token)
The token.
-
token
final ChatCompletionTokenLogprob.Builder token(JsonField<String> token)
The token.
-
bytes
final ChatCompletionTokenLogprob.Builder bytes(List<Long> bytes)
A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be
null
if there is no bytes representation for the token.
-
bytes
final ChatCompletionTokenLogprob.Builder bytes(Optional<List<Long>> bytes)
A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be
null
if there is no bytes representation for the token.
-
bytes
final ChatCompletionTokenLogprob.Builder bytes(JsonField<List<Long>> bytes)
A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be
null
if there is no bytes representation for the token.
-
addByte
final ChatCompletionTokenLogprob.Builder addByte(Long byte_)
A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are represented by multiple tokens and their byte representations must be combined to generate the correct text representation. Can be
null
if there is no bytes representation for the token.
-
logprob
final ChatCompletionTokenLogprob.Builder logprob(Double 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.
-
logprob
final ChatCompletionTokenLogprob.Builder logprob(JsonField<Double> 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.
-
topLogprobs
final ChatCompletionTokenLogprob.Builder topLogprobs(List<ChatCompletionTokenLogprob.TopLogprob> topLogprobs)
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.
-
topLogprobs
final ChatCompletionTokenLogprob.Builder topLogprobs(JsonField<List<ChatCompletionTokenLogprob.TopLogprob>> topLogprobs)
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.
-
addTopLogprob
final ChatCompletionTokenLogprob.Builder addTopLogprob(ChatCompletionTokenLogprob.TopLogprob topLogprob)
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.
-
additionalProperties
final ChatCompletionTokenLogprob.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final ChatCompletionTokenLogprob.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final ChatCompletionTokenLogprob.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final ChatCompletionTokenLogprob.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final ChatCompletionTokenLogprob.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final ChatCompletionTokenLogprob build()
-
-
-
-