AI coding agents are getting more efficient at forgetting things they don't need.
Researchers have released CoACT, a compression method that shrinks the observations LLM-based coding agents accumulate as they work through software tasks. The core idea, which they call next-action preservation (NAP), is that a compressed observation is only valid if it would cause the agent to take the same next step as the full, uncompressed version. During training, a teacher model generates multiple compressed candidates; CoACT then filters them using two rewards — one for action preservation, one for length reduction — and trains a lightweight compressor on the survivors. Tested on SWE-bench Verified across three agentic models, CoACT cut average total token consumption by 33% while keeping task-solving performance close to baseline.
Token costs are one of the less-discussed drags on agentic AI in production. Coding agents work iteratively — each tool call or file read appends more text to the context, and that context gets re-processed on every inference step. A 33% reduction in token use at that layer compounds quickly across long tasks and large deployments. The NAP framing also offers something earlier compression work lacked: a concrete, behavioral signal for whether a compression is actually safe to apply.
Whether the gains hold outside benchmark conditions — on messier, real-world codebases with noisier observations — is the question any team evaluating this should ask first.