Papers · arXiv 2610.14224
Harness^2: Recursive Agent Harnessing for an Open World
Published cs.AIcs.CLcs.LG arXivPDF
Summary in three lines
- 🎯 In open-world agent deployment, novel tasks lack ground-truth verifiers, and task-specific harness edits fail to transfer to future tasks.
- 🔧 Harness2 introduces two coupled levels of recursion: task-level recursion using contrastive Propose–Probe–Compose steps, and harnessing-level recursion that updates a continual improvement library across tasks.
- 📈 Yields single-step gains of up to 11.5 points on WorkBuddy-Bench, 4.5 points on JobBench, and 11.8 percentage points on LAB, with additional gains via parallel or sequential recursion.
Abstract
LLM agents' capabilities depend not only on their underlying models but also on their execution harnesses. Recursive self-improvement (RSI) offers a promising approach to automatically evolve these harnesses. However, deploying RSI in open-world settings still faces two critical challenges. First, open-world tasks are typically unseen during the harness design phase and novel at test time, leaving no ground-truth verifiers to reliably guide online harness edits. Second, the RSI process remains highly task-specific and fails to generalize to novel scenarios. We introduce Harness^2, a plug-and-play, recursive agent harnessing framework that addresses these challenges through two connected levels of recursion. Task-level recursion refines the current task's harness using a contrastive Propose-Probe-Compose step that reliably guides edits without ground-truth verifiers, and can be scaled further via parallel or sequential recursion. Harnessing-level recursion then extracts experience from these edits to update a continual improvement harness, enabling the agent to better adapt to future tasks. Across three professional benchmarks and four model-harness configurations, a single step consistently improves GLM-5 and Gemini 3.5 Flash over their base harnesses, yielding gains of up to 11.5 points on WorkBuddy-Bench, 4.5 points on JobBench, and 11.8 percentage points on LAB, with further gains as the task-level recursion budget increases.
Reading guide
Problem and motivation
An LLM agent's performance depends heavily on its execution harness—the runtime scaffolding of prompts, tools, memory, subagents, and plugins surrounding a frozen base model. In dynamic open-world settings, agents continually encounter unseen, complex workflows. Existing recursive self-improvement (RSI) techniques for harnesses struggle due to two primary challenges:
- Absence of ground-truth verifiers: Online deployment tasks do not provide ground-truth answers or reliable test-time scoring functions to evaluate whether an online harness edit helped or harmed performance.
- Lack of cross-task transfer: Direct harness modifications are typically task-specific; blindly carrying an execution harness forward across shifting task distributions causes instability and performance regressions.
Key ideas
Harness^2 couples two distinct levels of recursion:
- Task-Level Recursion: Refines the execution harness for the active task without ground-truth verifiers via a contrastive Propose–Probe–Compose cycle. It formulates invariant proposals (agent operational workflows) and domain-specific proposals (practitioner domain rules), probes both under matched conditions, and composes verified behavioral improvements.
- Harnessing-Level Recursion: Extracts reusable procedural lessons and adopted components from the test-time refinement process into a persistent harness improvement library, improving the improver's meta-capability on subsequent tasks.
- Pluggable Scaling: Supports scaling exploration width via parallel recursion ( candidate pools composed concurrently) or depth via sequential recursion ( chained iterations).
Method
An agent is decomposed into a frozen model and an editable harness across file-level components (system prompt, guardrails, memory, skills, tool guidance, scripts, subagents, middleware plugin).
Task-Level Recursion
For a task , execution history , and fixed improvement harness , a contrastive step produces an updated harness , execution record , and step record :
- Propose: Samples a reference execution . Conditioned on and , it generates an invariant candidate (procedural/tool flow) and a domain-specific candidate (practitioner constraints).
- Probe: Executes candidates on to observe behavioral contrasts against the reference execution.
- Compose: Selectively merges verified, non-conflicting edits from the candidate pool.
In Parallel Recursion, invariant and domain candidates are sampled, and independent composition sessions yield successors: In Sequential Recursion, refinement steps are chained sequentially:
Harnessing-Level Recursion
After task completion and artifact selection, the improvement process reviews the full improvement record to update the improvement harness library: Lessons are explicitly conditioned on concrete trajectory contrasts, avoiding spurious attributions.
Results
Evaluated across WorkBuddy-Bench (WB), JobBench, and Legal Agent Benchmark (LAB) using Gemini 3.5 Flash and GLM-5 under OpenCode and Codex:
- Single Step () Gains: Yields improvements up to points on WB Avg. (GLM-5 on OpenCode: ), points on JobBench (Gemini on OpenCode: ), and percentage points in LAB Partial pass rate (GLM-5 on OpenCode: ).
- Budget Scaling: Adding parallel recursion at yields additional gains of to points on WB, to points on JobBench, and to percentage points on LAB.
- Same-Model improver: Demonstrates that gains do not rely on an external superior model; when the same model acts as both executor and harness editor (tested across GLM-5 up to Claude Opus 5), consistent performance improvements occur across all benchmarks.
- Component Ablations: Removing the library, scoping roles, and composition lowers WB performance by , , and points, respectively.
Limitations and open questions
- Inference Compute Overhead: Proposing, probing, and composing multiple harnesses incurs substantial additional token and rollout costs.
- Stochasticity and Attribution Bias: Without ground-truth verifiers, reliance on behavioral contrasts can still occasionally lead to noisy credit attribution or conservative/restrictive edits when execution variance is high.
- Library Growth and Pruning: The library retains components sequentially; mechanisms to prune outdated lessons or actively consolidate conflicting skills over very long task horizons remain an open area for research.
Key terms
- harness
- The runtime scaffolding—including system prompts, guardrails, memory, skills, tool guidance, scripts, subagents, and middleware plugins—that surrounds a frozen base LLM to operate as an agent.
- recursive agent harnessing
- A dual-loop recursive self-improvement framework where task-level recursion refines the current task's execution harness while harnessing-level recursion updates the improvement mechanism across tasks.
- Propose–Probe–Compose
- A contrastive harness improvement step that proposes scoped harness modifications, probes their empirical behavior against reference runs, and selectively composes validated diffs without ground-truth labels.
- parallel recursion
- A task-level exploration approach that generates and probes multiple invariant and domain-specific candidates concurrently, followed by multiple independent composition sessions.
- sequential recursion
- An iterative task-level refinement strategy chaining successive contrastive improvement steps conditioned on accumulated execution history.
- harness improvement library
- A persistent cross-task repository containing adopted executable harnesses and documented operational lessons that inform future harness modifications.
- invariant candidate
- A proposed harness variant targeting general agentic execution deficiencies such as tool usage, planning, deterministic scripting, or context management.
- domain-specific candidate
- A proposed harness variant targeting procedural requirements, domain knowledge, consistency checks, and deliverable contracts relevant to a specific operational domain.
Questions
How does Harness2 evaluate harness edits without ground-truth verifiers or task labels?
It uses behavioral contrasts obtained during matched candidate probing against unedited reference rollouts. Rather than assuming correctness scores, the composer looks for specific behavioral mechanisms, error mitigation, and output conformance in the execution trajectories.
Does Harness2 require a more powerful LLM to act as the harness editor?
No. Experiments using the exact same model as both executor and harness editor (tested across GLM-5, Gemini, and Claude variants) showed consistent improvements on all evaluated benchmarks, including a 13.7 point gain on LAB using GLM-5.
What happens if a proposed harness edit introduces errors or fails validation?
Harness2 performs structural validation (e.g., verifying skill triggers and script syntax). If invalid, it retries once with validator feedback; if it fails again or causes catastrophic runtime issues like empty outputs, it safely falls back to the previous stable harness state.
Can experience accumulated in one benchmark transfer to another?
Yes. In cross-benchmark experiments, transferring an improvement library accumulated on JobBench to WorkBuddy-Bench improved one-step refinement performance across Code (+0.6), Web (+0.5), and Office (+2.9) domains without additional probing.
The overview on this page was written by AI from the paper and may contain mistakes. Read the paper for the details.