Beyond Weight Updates: Evolving Agent Harnesses for Domain Specialization

BoHao ChenarXiv 2026

TL;DR

Instead of fine-tuning model weights to specialize AI agents, why not evolve the "harness" they live in? This paper introduces harness evolution—optimizing system prompts, tool schemas, and skill libraries—showing it can recover most of the performance gains of expensive weight updates at a fraction of the compute cost, all while avoiding the "catastrophic forgetting" that plagues traditional fine-tuning.

What Problem Does This Paper Address?

Domain specialization for LLM agents is typically treated as a weight-update problem. If you want a coding agent, you collect trajectories and run Supervised Fine-Tuning (SFT) or Reinforcement Learning (RL) to create a new model checkpoint.

However, this approach has three major drawbacks:

  1. Expense: RL requires massive compute clusters and thousands of rollouts.
  2. Destructive Side Effects: SFT often shifts the model away from its pretrained distribution, leading to "reasoning truncation" (shorter, lazier thought chains) and a loss of format robustness.
  3. Monolithic Nature: You end up with a heavy, specialized checkpoint that might perform worse on general tasks.

The authors argue that an agent is actually a policy (the weights) plus a harness (the scaffolding). Most pipelines optimize the weights and leave the harness hand-designed. This paper asks: can we specialize agents by evolving the harness instead?

Methods

The authors propose Harness Evolution, casting the design of the agent's environment as an optimization problem.

Figure 2: RL-style harness evolution. The inner loop is identical to weight-based RL, but the outer loop applies GEPA to the harness. The policy is frozen; the adapter is reloaded on demand per vertical domain.

Key components of their approach include:

  • The Genotype: The "genome" being optimized consists of the system prompt, tool descriptions, a library of reusable skills, and few-shot exemplars.
  • GEPA (Reflective Evolutionary Optimizer): Instead of using gradients, they use an LLM-driven outer loop. The system observes failed trajectories, generates a natural language reflection on why it failed, and proposes mutations to the harness (e.g., "always run the test before submitting" or "use a specific grep flag").
  • Harness Adapters: The output is a portable "adapter"—a small set of text-based configuration changes that can be loaded onto a frozen base model for a specific domain (like software engineering or financial trading) and unloaded when not needed.

For comparison, they also implement a state-of-the-art weight-update baseline using SAO (Single-rollout Asynchronous Optimization), a variant of RL designed for long-horizon agent tasks.

Datasets

The researchers evaluated their approach on three benchmarks that stress different parts of an agent's harness:

  1. SWE-bench Verified: Repository-level software engineering (tests code editing and debugging skills).
  2. OfficeBench: Multi-application office automation (tests complex API usage).
  3. Terminal-Bench: Hard command-line tasks (tests shell syntax and tool composition).

Key Insights and Ideas

  • "Domain Expertise" is often Scaffolding: A surprising amount of what we perceive as an agent's "expertise" is actually just a well-designed harness. Providing the right tools, risk vocabulary, and planning templates can elicit latent capabilities in a frozen model that previously seemed absent.
  • Avoiding the Stability-Plasticity Trade-off: Traditional fine-tuning often "breaks" the model's reasoning. The authors found that after fine-tuning a Qwen3.5-4B model, reasoning truncation rose significantly. Harness evolution avoids this by construction because the underlying policy weights never change.
Figure 3: Forward KL (SFT) versus reverse KL (RL). SFT can take mass from the prior mode; RL tends to preserve it while amplifying the target mode. Adapted from Chen et al. [2026].
  • Sample Efficiency: GEPA is roughly 35x more sample-efficient than GRPO-style RL. This is because a single natural language reflection ("You forgot to check if the file exists") provides a much denser signal for improvement than a scalar reward used in gradient estimation.

Key Results

The experiments revealed a consistent "dual-path" pattern:

  • Weight updates provide the strongest single-path gains for low-level fluency (like mastering shell syntax).
  • Harness evolution recovers 55–110% of those gains at a tiny fraction of the compute cost (zero GPU hours for training).
  • The Combined Path is King: Using both specialized weights and an evolved harness yielded the best results across the board. On SWE-bench Verified, the base agent scored 0.31; the combined approach reached 0.61.
Diagnostics showing that fine-tuning increases reasoning truncation and reduces format robustness, a failure mode harness adapters avoid.

Limitations and Future Work

  • Ground Truth Requirement: GEPA currently requires a reliable benchmark or reward signal to determine which harness mutations are actually improvements.
  • Base-Harness Expressiveness: Evolution can only rearrange what the base harness exposes. If a task requires a brand-new tool that hasn't been coded yet, a simple prompt edit won't suffice.
  • Future Directions: The authors suggest "meta-evolution" (evolving the actual structure of the harness, not just the content) and using "router policies" to automatically select the right harness adapter based on the incoming task description.

Summary updated

BibTeX
@misc{chen2026beyond,
  author = {BoHao Chen},
  title = {{Beyond Weight Updates: Evolving Agent Harnesses for Domain Specialization}},
  year = {2026},
  eprint = {2611.25380},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.25380},
}
Figure