pub struct ContextUsageParams {
pub usage_ratio: Option<f64>,
pub context_limit: Option<u32>,
pub input_tokens: u32,
pub output_tokens: u32,
pub cache_read_tokens: Option<u32>,
pub cache_creation_tokens: Option<u32>,
pub reasoning_tokens: Option<u32>,
pub total_input_tokens: u64,
pub total_output_tokens: u64,
pub total_cache_read_tokens: u64,
pub total_cache_creation_tokens: u64,
pub total_reasoning_tokens: u64,
}Expand description
Parameters for _aether/context_usage notifications.
Per-turn fields (input_tokens, output_tokens, cache_read_tokens,
cache_creation_tokens, reasoning_tokens) come from the most recent
API response. The total_* fields are cumulative across the agent’s
lifetime. The optional fields are None when the provider doesn’t
expose that dimension; this is semantically distinct from Some(0).
Fields§
§usage_ratio: Option<f64>§context_limit: Option<u32>§input_tokens: u32§output_tokens: u32§cache_read_tokens: Option<u32>§cache_creation_tokens: Option<u32>§reasoning_tokens: Option<u32>§total_input_tokens: u64§total_output_tokens: u64§total_cache_read_tokens: u64§total_cache_creation_tokens: u64§total_reasoning_tokens: u64Trait Implementations§
Source§impl Clone for ContextUsageParams
impl Clone for ContextUsageParams
Source§fn clone(&self) -> ContextUsageParams
fn clone(&self) -> ContextUsageParams
Returns a duplicate of the value. Read more
1.0.0 · 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 ContextUsageParams
impl Debug for ContextUsageParams
Source§impl<'de> Deserialize<'de> for ContextUsageParams
impl<'de> Deserialize<'de> for ContextUsageParams
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
Source§impl From<ContextUsageParams> for ExtNotification
impl From<ContextUsageParams> for ExtNotification
Source§fn from(params: ContextUsageParams) -> Self
fn from(params: ContextUsageParams) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ContextUsageParams
impl PartialEq for ContextUsageParams
Source§impl Serialize for ContextUsageParams
impl Serialize for ContextUsageParams
impl StructuralPartialEq for ContextUsageParams
Auto Trait Implementations§
impl Freeze for ContextUsageParams
impl RefUnwindSafe for ContextUsageParams
impl Send for ContextUsageParams
impl Sync for ContextUsageParams
impl Unpin for ContextUsageParams
impl UnsafeUnpin for ContextUsageParams
impl UnwindSafe for ContextUsageParams
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