Class ChatCompletionTokenLogprob
java.lang.Object
com.sap.ai.sdk.orchestration.model.ChatCompletionTokenLogprob
ChatCompletionTokenLogprob
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceBuilder helper class.static interfaceBuilder helper class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedDefault constructor for ChatCompletionTokenLogprob. -
Method Summary
Modifier and TypeMethodDescriptionaddBytesItem(Integer bytesItem) Add one bytes instance to thisChatCompletionTokenLogprob.addTopLogprobsItem(ChatCompletionTokenLogprobTopLogprobsInner topLogprobsItem) Add one topLogprobs instance to thisChatCompletionTokenLogprob.Set the bytes of thisChatCompletionTokenLogprobinstance and return the same instance.create()Create a type-safe, fluent-api builder object to construct a newChatCompletionTokenLogprobinstance with all required arguments.booleangetBytes()A list of integers representing the UTF-8 bytes representation of the token.getCustomField(String name) Deprecated.Get the names of the unrecognizable properties of theChatCompletionTokenLogprob.The log probability of this token.getToken()The token.List of the most likely tokens and their log probability, at this token position.inthashCode()Set the logprob of thisChatCompletionTokenLogprobinstance and return the same instance.voidSet the bytes of thisChatCompletionTokenLogprobinstance.voidsetCustomField(String customFieldName, Object customFieldValue) Set an unrecognizable property of thisChatCompletionTokenLogprobinstance.voidsetLogprob(Float logprob) Set the logprob of thisChatCompletionTokenLogprobinstance.voidSet the token of thisChatCompletionTokenLogprobinstance.voidsetTopLogprobs(List<ChatCompletionTokenLogprobTopLogprobsInner> topLogprobs) Set the topLogprobs of thisChatCompletionTokenLogprobinstance.Set the token of thisChatCompletionTokenLogprobinstance and return the same instance.toMap()Get the value of all properties of thisChatCompletionTokenLogprobinstance including unrecognized properties.topLogprobs(List<ChatCompletionTokenLogprobTopLogprobsInner> topLogprobs) Set the topLogprobs of thisChatCompletionTokenLogprobinstance and return the same instance.toString()
-
Constructor Details
-
ChatCompletionTokenLogprob
protected ChatCompletionTokenLogprob()Default constructor for ChatCompletionTokenLogprob.
-
-
Method Details
-
token
Set the token of thisChatCompletionTokenLogprobinstance and return the same instance.- Parameters:
token- The token.- Returns:
- The same instance of this
ChatCompletionTokenLogprobclass
-
getToken
The token.- Returns:
- token The token of this
ChatCompletionTokenLogprobinstance.
-
setToken
Set the token of thisChatCompletionTokenLogprobinstance.- Parameters:
token- The token.
-
logprob
Set the logprob of thisChatCompletionTokenLogprobinstance and return the same instance.- Parameters:
logprob- The log probability of this token.- Returns:
- The same instance of this
ChatCompletionTokenLogprobclass
-
getLogprob
The log probability of this token.- Returns:
- logprob The logprob of this
ChatCompletionTokenLogprobinstance.
-
setLogprob
Set the logprob of thisChatCompletionTokenLogprobinstance.- Parameters:
logprob- The log probability of this token.
-
bytes
Set the bytes of thisChatCompletionTokenLogprobinstance and return the same instance.- Parameters:
bytes- A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are multi-byte.- Returns:
- The same instance of this
ChatCompletionTokenLogprobclass
-
addBytesItem
Add one bytes instance to thisChatCompletionTokenLogprob.- Parameters:
bytesItem- The bytes that should be added- Returns:
- The same instance of type
ChatCompletionTokenLogprob
-
getBytes
A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are multi-byte.- Returns:
- bytes The bytes of this
ChatCompletionTokenLogprobinstance.
-
setBytes
Set the bytes of thisChatCompletionTokenLogprobinstance.- Parameters:
bytes- A list of integers representing the UTF-8 bytes representation of the token. Useful in instances where characters are multi-byte.
-
topLogprobs
@Nonnull public ChatCompletionTokenLogprob topLogprobs(@Nullable List<ChatCompletionTokenLogprobTopLogprobsInner> topLogprobs) Set the topLogprobs of thisChatCompletionTokenLogprobinstance and return the same instance.- Parameters:
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`.- Returns:
- The same instance of this
ChatCompletionTokenLogprobclass
-
addTopLogprobsItem
@Nonnull public ChatCompletionTokenLogprob addTopLogprobsItem(@Nonnull ChatCompletionTokenLogprobTopLogprobsInner topLogprobsItem) Add one topLogprobs instance to thisChatCompletionTokenLogprob.- Parameters:
topLogprobsItem- The topLogprobs that should be added- Returns:
- The same instance of type
ChatCompletionTokenLogprob
-
getTopLogprobs
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`.- Returns:
- topLogprobs The topLogprobs of this
ChatCompletionTokenLogprobinstance.
-
setTopLogprobs
Set the topLogprobs of thisChatCompletionTokenLogprobinstance.- Parameters:
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`.
-
getCustomFieldNames
Get the names of the unrecognizable properties of theChatCompletionTokenLogprob.- Returns:
- The set of properties names
-
getCustomField
@Nullable @Deprecated public Object getCustomField(@Nonnull String name) throws NoSuchElementException Deprecated.UsetoMap()instead.Get the value of an unrecognizable property of thisChatCompletionTokenLogprobinstance.- Parameters:
name- The name of the property- Returns:
- The value of the property
- Throws:
NoSuchElementException- If no property with the given name could be found.
-
toMap
Get the value of all properties of thisChatCompletionTokenLogprobinstance including unrecognized properties.- Returns:
- The map of all properties
-
setCustomField
Set an unrecognizable property of thisChatCompletionTokenLogprobinstance. If the map previously contained a mapping for the key, the old value is replaced by the specified value.- Parameters:
customFieldName- The name of the propertycustomFieldValue- The value of the property
-
equals
-
hashCode
public int hashCode() -
toString
-
create
Create a type-safe, fluent-api builder object to construct a newChatCompletionTokenLogprobinstance with all required arguments.
-
toMap()instead.