Retrieves metadata from assistant replies within an LLMMessage
object.
It returns the metadata as a tibble.
Details
Metadata columns may include:
model
: The model used for generating the reply.timestamp
: The time when the reply was generated.prompt_tokens
: The number of tokens in the input prompt.completion_tokens
: The number of tokens in the assistant's reply.total_tokens
: The total number of tokens (prompt + completion).
For convenience, last_metadata()
is provided to retrieve the metadata for the last message.