Skip to main content

Module context

Module context 

Source

Re-exports§

pub use compaction::*;

Modules§

compaction

Structs§

SessionUsageTracker
Billable usage for one agent session. The root agent’s session tracker captures totals for all agents (e.g. sub-agents).
TokenTracker
One agent’s context window, tracked from real LLM API usage rather than estimation. Owns the ContextUsage snapshot the agent publishes and evaluates the compaction policy against it.

Constants§

DEFAULT_COMPACTION_THRESHOLD
Default threshold for triggering context compaction (85%)