pub struct CacheHitRateByModel {
pub model: Option<String>,
pub total_input_tokens: u64,
pub total_cache_read_tokens: u64,
pub total_cache_creation_tokens: u64,
pub hit_rate: Option<f64>,
}Expand description
Cache token efficiency per model.
hit_rate = cache_read_tokens / (cache_read_tokens + input_tokens).
Only set when at least one of the token counts is non-zero.
Fields§
§model: Option<String>§total_input_tokens: u64§total_cache_read_tokens: u64§total_cache_creation_tokens: u64§hit_rate: Option<f64>Trait Implementations§
Source§impl Clone for CacheHitRateByModel
impl Clone for CacheHitRateByModel
Source§fn clone(&self) -> CacheHitRateByModel
fn clone(&self) -> CacheHitRateByModel
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CacheHitRateByModel
impl Debug for CacheHitRateByModel
Source§impl<'de> Deserialize<'de> for CacheHitRateByModel
impl<'de> Deserialize<'de> for CacheHitRateByModel
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for CacheHitRateByModel
impl RefUnwindSafe for CacheHitRateByModel
impl Send for CacheHitRateByModel
impl Sync for CacheHitRateByModel
impl Unpin for CacheHitRateByModel
impl UnsafeUnpin for CacheHitRateByModel
impl UnwindSafe for CacheHitRateByModel
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