pub struct HttpUsage {
pub input_tokens: Option<u64>,
pub cache_read_input_tokens: Option<u64>,
pub cache_creation_input_tokens: Option<u64>,
pub output_tokens: Option<u64>,
}Expand description
Token usage from a single turn.
Fields§
§input_tokens: Option<u64>Uncached input/prompt tokens consumed (excludes cache reads and writes).
cache_read_input_tokens: Option<u64>Input tokens served from the prompt cache.
cache_creation_input_tokens: Option<u64>Input tokens written to the prompt cache.
output_tokens: Option<u64>Output/completion tokens generated.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for HttpUsage
impl RefUnwindSafe for HttpUsage
impl Send for HttpUsage
impl Sync for HttpUsage
impl Unpin for HttpUsage
impl UnsafeUnpin for HttpUsage
impl UnwindSafe for HttpUsage
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more