New Meta and CMU paper.
Long-horizon agents also require control over what is stored in working memory in addition to larger context windows.
Token thresholds are a bad signal for when an agent should compress its context.
Generally, long-horizon agents tend to compress context when crossing a token threshold, even if the reasoning state at this point is unrelated.
So, Agentic Context Management (ACM)proposed in this paper, turns context management into an agent action.
The agent decides when to compress . Old turns are replaced with a short summary . Raw messages are stored outside of the system ( not deleted ) .
If an archived detail is needed again, query_memory retrieves it on demand.
The post-training pipeline teaches timing in both directions: A teacher inserts context management when rollouts start to loop, and removes premature compression when the better move is another search, a document fetch, or a final answer.
The average peak context decreases from 63K to 54K tokens. Qwen3.5-9B increases from 57.0% Pass@1 under ReAct to 72.7% after ACM post-training, a 27% relative gain on BrowseComp-Plus.
The model also provides more consistent responses across four trials and explores longer.
Overall, the ACM does not create long-horizon agency; it helps a capable agent to maintain long-horizon agency when raw history eclipses the task.
- arxiv. org/abs/2607.23809
Title: "ACM: Agentic Context Management for Long Horizon Tasks"