Skip to content

CompletionTokensDetails

autogen.oai.oai_models.completion_usage.CompletionTokensDetails #

Bases: BaseModel

model_config class-attribute #

model_config = ConfigDict(extra='allow')

accepted_prediction_tokens class-attribute instance-attribute #

accepted_prediction_tokens = None

When using Predicted Outputs, the number of tokens in the prediction that appeared in the completion.

audio_tokens class-attribute instance-attribute #

audio_tokens = None

Audio input tokens generated by the model.

reasoning_tokens class-attribute instance-attribute #

reasoning_tokens = None

Tokens generated by the model for reasoning.

rejected_prediction_tokens class-attribute instance-attribute #

rejected_prediction_tokens = None

When using Predicted Outputs, the number of tokens in the prediction that did not appear in the completion. However, like reasoning tokens, these tokens are still counted in the total completion tokens for purposes of billing, output, and context window limits.