Definition
What is Context Compression?
Last updated
The practice of reducing token count in an AI agent's context window while preserving the information needed to complete tasks.
As AI agents work through multi-step tasks, they accumulate conversation history, tool outputs, and observations that dilute attention. Context compression techniques like structured summarization, tool response offloading, and embedding-based reduction keep the working context focused. Research shows effective compression can reduce memory usage by 26-54% while preserving task performance.
Further reading
Articles about Context Compression
How agents manage their own context window
Agent context management is shifting from fixed harness rules to learned, runtime decisions an agent makes about its own window. What the 2026 research shows.
Demand paging for the AI context window
A 2026 systems paper found 21.8% of tokens in agent context windows are wasted. Demand paging treats the AI context window as L1 cache, not full memory.
Five criteria of good context for AI agents
A 2026 paper formalizes five criteria for good AI agent context: relevance, sufficiency, isolation, economy, and provenance. Here's how to design for each.
When agent memory needs sleep, and when it doesn't
Memory consolidation fixes one specific failure: agents writing the same claim dozens of times into a flat scratchpad. When it helps and where it breaks.
All terms
View full glossaryPut context into practice
Create your first context container and connect it to your AI tools in minutes.
Create Your First Container