Agent memory gets its own compressor: SumOne learns from masked reconstruction and cuts search-task cost to 22% of full context
Synopsis
Long-horizon language-model agents accumulate ever-longer interaction histories, so context compaction is necessary, yet existing learned compaction methods often depend on downstream task outcomes or solver behavior. SumOne is a standalone 2-billion-parameter summarizer trained with a task-agnostic reward built from masked reconstruction and optimized with GRPO, using only raw trajectories and no reference summaries or downstream task execution. On DeepSearchQA it cuts cumulative agent input from 2.83M to 591K tokens with F1 0.48 versus 0.52 for full context; on SWE-bench Verified it reaches a 0.59 resolved rate versus 0.63, with input falling from 4.10M to 1.09M tokens.
Interpretation
Agent context compaction can be handled by a separate small model instead of having the downstream agent summarize itself or tying compaction training to a specific task. Earlier learned compaction either depends on downstream task outcomes or solver behavior, or embeds memory maintenance in the agent workflow, such as HiAgent's subgoal summarization and FoldGRPO's training on compressed tool responses. On DeepSearchQA, SumOne scores 0.48 F1 versus 0.52 for full context, cutting cumulative input from 2.83M to 591K tokens at 22% of the full-context inference cost; on SWE-bench Verified it reaches a 0.59 resolved rate versus 0.63, cutting cumulative input from 4.10M to 1.09M tokens at 58% of the full-context cost.
The training signal comes from the raw trajectories themselves: a summary must let a frozen model recover masked spans of the original history. The summarizer first writes a text summary of the expired interaction history, then the history is split into roughly 512-token blocks and 50% of them are randomly masked, with a frozen Qwen3.5-9B reconstructor predicting the missing content conditioned on the summary and retained context. DeepSeek V4.1 Flash scores reconstruction quality by precision and recall, and a summary-length penalty is added to form the reward; GRPO trains the summarizer for 600 steps on about 5K trajectories drawn from OpenSeeker-v1-Data and SWE-smith, starting from Qwen3.5-2B.
At inference only the summarizer is kept, the reconstruction and judging pipeline is removed, and one checkpoint can be paired with an otherwise unchanged agent. At the same compaction threshold it beats letting the downstream agent summarize itself: F1 rises from 0.44 to 0.48 on DeepSearchQA and the resolved rate from 0.56 to 0.59 on SWE-bench Verified, at lower total cost. The same checkpoint is used without additional fine-tuning across four downstream models, DeepSeek V4.1 Flash, GPT-6 Luna, GLM-5.3 and Gemini 3.7 Flash, and four harnesses, OpenCode, OpenHands, Codex and DeepSeek Harness.
Perspective
The demonstrated scope is long-horizon web search and software-engineering tasks, with main experiments using Qwen3.5-35B-A3B as the downstream model and OpenCode as the harness, all compression methods sharing a 32K compaction threshold; transfer experiments cover four downstream models and four harnesses. Training data are concentrated in web-search and software-engineering trajectories, and the authors propose extending the module with adaptive memory management, retrieval, tools and meta-memory as future work.
The authors note that training data are concentrated in web-search and software-engineering trajectories and that other domains may have different memory requirements; the training signal depends on a frozen reconstructor and an LLM-based reconstruction judge, which are not needed at inference but whose capabilities may affect the quality of the learned summarizer. Ablations show a 50% mask ratio and a moderate length penalty perform best, with performance dropping away from that setting.
