LogProbability

class oci.generative_ai_inference.models.LogProbability(**kwargs)

Bases: object

The log probabilities of the generated tokens.

Methods

__init__(**kwargs) Initializes a new LogProbability object with values from keyword arguments.

Attributes

log_probabilities Gets the log_probabilities of this LogProbability.
text Gets the text of this LogProbability.
token_ids Gets the token_ids of this LogProbability.
__init__(**kwargs)

Initializes a new LogProbability object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class):

Parameters:
  • token_ids (list[int]) – The value to assign to the token_ids property of this LogProbability.
  • text (str) – The value to assign to the text property of this LogProbability.
  • log_probabilities (list[float]) – The value to assign to the log_probabilities property of this LogProbability.
log_probabilities

Gets the log_probabilities of this LogProbability. The log probability of each token used to construct the text chunk.

Returns:The log_probabilities of this LogProbability.
Return type:list[float]
text

Gets the text of this LogProbability. The text chunk for which the log probabilities was calculated.

Returns:The text of this LogProbability.
Return type:str
token_ids

Gets the token_ids of this LogProbability. The token ids of each token used to construct the text chunk.

Returns:The token_ids of this LogProbability.
Return type:list[int]