ChatResponse

data class ChatResponse(val message: ChatMessage.Assistant, val usage: TokenUsage? = null)

What a ChatModel answered.

Constructors

Link copied to clipboard
constructor(message: ChatMessage.Assistant, usage: TokenUsage? = null)

Properties

Link copied to clipboard

the model's message. Add it to the conversation before the next request. Its ChatMessage.Assistant.truncated tells whether the model reached its output limit.

Link copied to clipboard

the tokens the call used, when the provider reports them.