SWE-Pruner Pro trims coding-agent context by up to 39% using the agent’s own states
pmttyji · reddit · 2026-07-21
SWE-Pruner Pro is a new pruning method for coding agents that uses the agent’s own internal representations to decide what tool output to keep.
- The paper argues that the agent already encodes relevance signals while reading tool output, so a separate code classifier is not always necessary.
- A small head maps the hidden states into per-line keep/prune labels, with a length-aware embedding based on the tool output length.
- Across two open-weight backbones and four multi-turn benchmarks, it reportedly saves up to 39% of prompt and completion tokens while maintaining task quality.
- On MiMo-V2-Flash, it also improves SWE-Bench Verified resolve rate by +3.8% and Oolong long-context accuracy by +2.2 points.
Related event: ByteDance's SWE-Pruner Pro Enables Coding Agents to Self-Prune Context(3 posts)→
More from coding & agent
- Kolab Benchmark Uses Pro Screen Recordings to Show AI Agents Overestimate Collaboration Quality — minnesotanlp · 2026-10-27
- Dev argues Claude burns far more tokens than GPT models for the same coding work — haider1 · 2026-10-27
- Stop building agents that can't change models: stable contracts, external state, real evals — rseroter · 2026-10-27
- Cheap models can cost more in agent harnesses than frontier ones, researcher warns — vasuman · 2026-10-27
- Kanzo: A 5k-Line Rust Kanban Binary With MCP for Claude Code and Codex — allmudi · 2026-10-27
- 'A human approves everything' is a trap: approval fatigue and how to actually design safe agents — Efistoffeles · 2026-10-27