[2606.09498] Self-Harness: Harnesses That Improve Themselves
Abstract:The performance of LLM-based agents is jointly shaped by their base models and the harnesses that mediate their interaction with the environment. Because different models exhibit distinct behaviors, effective harness design is inherently model-specific. Yet agent harnesses are still largely engineered by human experts, a paradigm that scales poorly as modern LLMs become increasingly diverse and rapidly evolving. In this paper, we introduce Self-Harness, a new paradigm in which an LLM-based agent improves its own operating harness, without relying on human engineers or stronger external agents. We operationalize Self-Harness as an iterative loop with three stages: Weakness Mining, which identifies model-specific failure patterns from execution traces; Harness Proposal, which generates diverse yet minimal harness modifications tied to these failures; and Proposal Validation, which accepts candidate edits only after regression testing. We instantiate Self-Harness on Terminal-Bench-2.0 using a minimal initial harness and three base models from diverse families: MiniMax M2.5, Qwen3.5-35B-A3B, and GLM-5. Across all three models, Self-Harness consistently improves performance, with held-out pass rates increasing from 40.5% to 61.9%, 23.8% to 38.1%, and 42.9% to 57.1%, respectively. Qualitative analyses further show that Self-Harness does not simply add generic instructions, but effectively turns model-specific weaknesses into concrete, executable harness changes. These results suggest a path toward LLM-based agents that are not merely shaped by their harnesses, but can also participate in reshaping them.
2026-8-21 Self-Harness: Harnesses That Improve Themselves Hangfan Zhang1 , Shao Zhang1 , Kangcong Li1 , Chen Zhang1 Yang Chen1 , Yiqun Zhang1 , Lei Bai1,† , Shuyue Hu1,† 1 Shanghai Artificial Intelligence Laboratory, {zhanghangfan,zhangshao,hushuyue}@pjlab.org.cn…
saved by
related reading
- [2606.09498] Self-Harness: Harnesses That Improve Themselvesarxiv.org
- Harness Engineering for Self-Improvement | Lil'Loglilianweng.github.io
- Building Effective AI Agents \ Anthropicanthropic.com
- LLM Powered Autonomous Agents | Lil'Loglilianweng.github.io
- What is an Agent Harness?rubriclabs.com
- Bring Your Own Harness to AC2appliedcompute.com
- Continually improving our agent harness · Cursorcursor.com
- Guardian Angels: LLM Personalization for Productivity and Security · Gwern.netgwern.net
- The Last Harness You'll Ever Buildarxiv.org
- Building Effective AI Agents \ Anthropicanthropic.com
- [2604.25850] Agentic Harness Engineering: Observability-Driven Automatic Evolution of Coding-Agent Harnessesarxiv.org
- Prime Agent: A self-improving RLM agentprimeintellect.ai