Skip to content

completion_usage

Classes:

Name Description
CompletionUsage

CompletionUsage

Attributes:

Name Type Description
completion_tokens int

Number of tokens in the generated completion.

prompt_tokens int

Number of tokens in the prompt.

total_tokens int

Total number of tokens used in the request (prompt + completion).

completion_tokens instance-attribute

completion_tokens: int

Number of tokens in the generated completion.

prompt_tokens instance-attribute

prompt_tokens: int

Number of tokens in the prompt.

total_tokens instance-attribute

total_tokens: int

Total number of tokens used in the request (prompt + completion).