pub struct MetadataContextAttributionResultContextAttributionCategories {
pub buffer: i64,
pub custom_instructions: i64,
pub free_space: i64,
pub mcp_tools: i64,
pub messages: i64,
pub system_prompt: i64,
pub system_tools: i64,
}Expand description
The six normalized /context header buckets, computed from the same tokenization as entries so the two never disagree. Convenience rollups: freeSpace and buffer describe window capacity rather than occupied context, so the values do not sum to totalTokens.
Fields§
§buffer: i64Output reserve plus post-blocking-threshold buffer.
custom_instructions: i64Custom-instructions tokens (0 when none are configured).
free_space: i64Remaining unused window capacity (clamped at 0).
mcp_tools: i64MCP tool-definition tokens.
messages: i64Conversation (user/assistant/tool) message tokens.
system_prompt: i64System prompt tokens, excluding custom instructions.
system_tools: i64Non-MCP tool-definition tokens.
Trait Implementations§
Source§impl Clone for MetadataContextAttributionResultContextAttributionCategories
impl Clone for MetadataContextAttributionResultContextAttributionCategories
Source§fn clone(&self) -> MetadataContextAttributionResultContextAttributionCategories
fn clone(&self) -> MetadataContextAttributionResultContextAttributionCategories
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 Default for MetadataContextAttributionResultContextAttributionCategories
impl Default for MetadataContextAttributionResultContextAttributionCategories
Source§fn default() -> MetadataContextAttributionResultContextAttributionCategories
fn default() -> MetadataContextAttributionResultContextAttributionCategories
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for MetadataContextAttributionResultContextAttributionCategories
impl<'de> Deserialize<'de> for MetadataContextAttributionResultContextAttributionCategories
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 MetadataContextAttributionResultContextAttributionCategories
impl RefUnwindSafe for MetadataContextAttributionResultContextAttributionCategories
impl Send for MetadataContextAttributionResultContextAttributionCategories
impl Sync for MetadataContextAttributionResultContextAttributionCategories
impl Unpin for MetadataContextAttributionResultContextAttributionCategories
impl UnsafeUnpin for MetadataContextAttributionResultContextAttributionCategories
impl UnwindSafe for MetadataContextAttributionResultContextAttributionCategories
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