← Back to Paper Radar

HarnessCompass: Guiding Automatic Harness Evolution toward Generalizable and Effective Agent Harnesses

Luan Zhang, Ruo-Chen Zhou, Dan-Dan Song, Zheng-Yu Chen, Yu-Hang Tian, Jun Yang, Hui-Peng Ma, Chen-Hao Li, Guang-Yuan Feng, Xu-Dong Li, Yi-Zhou Jin, Yan Xu
arXiv.org | 2026

Reading guide · Based on sections of the original paper

The authors argue that automatic harness evolution for coding agents works better when it is disciplined. Their HarnessCompass method allows only task-agnostic edits, adds verified first-person feedback from the agent, and optimizes structural and guidance components on separate tracks before merging them.

Why read this

Practitioners who tune agent scaffolds for SWE-style tasks should read it to see whether constraining harness search improves transfer to unseen tasks, rather than just raising scores on the tasks used for search.

What the authors found

  • On SWE-bench Verified with GPT-5.4 in non-thinking mode, the harness was evolved on 50 tasks. On the 450 held-out tasks, the authors report 60.4% Pass@1 for HarnessCompass, 54.7% for AHE and 51.6% for the bash-only seed. HarnessCompass took 5 evolution turns versus AHE's 20. The margin is larger on held-out tasks (5.7 points) than on the evolution set (3.0 points). The advantage is more evident on held-out tasks.
  • The cumulative ablation qualifies the headline result. The generalization gate alone reached 58.4% held-out Pass@1 in 2 turns. Adding proactive feedback raised the evolution-set score to 66% but cut held-out Pass@1 to 55.8% and took 12 turns. Only the R³ merge step restored held-out Pass@1 to 60.4%. Each principle contributes, and their effects are complementary.
  • A harness evolved on GPT-5.4 and then frozen raised Claude-Sonnet-4.6's total Pass@1 from 70.0% to 73.8% compared with that model's own seed harness. The gain is uneven across repositories: pytest fell 10.5 points and sphinx fell 4.5 points. The frozen harness improves a model it was never evolved on.

Main limitation

Results come from k=2 rollouts on a single benchmark. The supplied sections report no spread across runs. The authors also caution that small repositories have coarse statistical resolution. Small repositories have limited statistical resolution.

Where to start

Each principle contributes, and their effects are complementary. · Check how each principle trades evolution-set gains against held-out transfer, especially the drop in held-out performance after proactive feedback is added.

Abstract

Harness design plays a critical role in agent performance by shaping how large language models (LLMs) perceive, reason over, and act within executable environments. Recent work has proposed automatic harness evolution, which iteratively improves the harness from agent--environment interactions. However, existing methods often overfit to the evolution tasks, rely exclusively on trajectory-derived signals, and optimize harness components jointly, causing interference across components. We propose HarnessCompass, a novel automatic harness evolution framework built around constrained evolution, proactive feedback, and component-wise optimization. HarnessCompass first enforces global constraints on evolution, restricting modifications to task-agnostic harness changes that generalize beyond the evolution tasks. It then augments trajectory-derived evidence with proactive first-person feedback from the agent about harness usage, yielding richer signals for evolution. Finally, it decouples the optimization of different harness components before consolidating them into a unified harness, reducing cross-component interference while preserving component synergy. On SWE-bench Verified with GPT-5.4, HarnessCompass improves Pass@1 from 54\% to 66\% in only 5 evolution iterations, outperforming AHE in both effectiveness and evolution efficiency. In addition, the evolved harness transfers effectively to held-out tasks and other models, demonstrating substantially stronger generalization than prior automatic harness evolution methods.

Generated automatically from paper sections on 2026-11-28.