HarnessLab ๐Ÿ”ฌ

April 4, 2026 ยท View on GitHub

A benchmark for evaluating AI agent harness designs โ€” the first framework that treats the harness as the independent variable.

"When we evaluate 'an agent,' we're evaluating the harness and the model working together." โ€” Anthropic, Demystifying Evals for AI Agents (2026)

The Problem

Every existing agent benchmark evaluates the combined model+harness system. When LangChain changed only the harness (same GPT-5.2-Codex model) and jumped from 52.8%โ†’66.5% on Terminal-Bench 2.0, or when fixing harness bugs alone took Opus 4.5 from 42%โ†’95% on CORE-Bench, it became clear: the harness is a first-order variable that no benchmark isolates.

What HarnessLab Does

HarnessLab holds the model and task fixed and systematically measures the causal contribution of each harness module.

Three Novel Metrics

MetricWhat It Measures
Harness Contribution Matrix (HCM)ฮทยฒ effect size: what % of performance variance is explained by each module?
Harness Generalization Score (HGS)Cross-domain rank correlation: does a harness that works for coding also work for web tasks?
Durability CurvePerformance by trajectory depth (steps 1โ†’100+): where does the "cliff" occur?

Architecture

6 Harness Modules ร— 4-5 Implementations = 30 Variants

ModuleImplementations
Context ManagerNullContext, SlidingWindow, LLMSummarizer, ObservationMask, HybridAdaptive
Retry PolicyNoRetry, SimpleRetry, ExponentialBackoff, InformedBacktrack, MultiPathSearch
Tool SelectorFullToolset, ProgressiveDisclosure, SemanticRouter, MinimalToolset, HarnessVerified
Memory SystemStateless, FilesystemState, EpisodicMemory, SemanticSearch, WorkspaceManifest
Output ValidatorNullValidator, SchemaValidator, SelfCritique, SeparateVerifier, DSAPVerifier
OrchestrationSingleAgent, FixedPipeline, DynamicOrchestration, SelfEvolution, SubAgentDelegation

120 Tasks ร— 4 Domains ร— 3 Difficulty Levels

DomainEasy (10-20 steps)Medium (20-50 steps)Hard (50+ steps)
Coding101010
Web101010
Research101010
Computation101010

Fractional Factorial Experimental Design (Resolution V)

  • 64 core configurations (covers all main effects + 2-factor interactions)
    • 32 targeted follow-up runs
  • Total: 96 harness configurations evaluated

Quick Start

pip install harnesslab

# Run a mini experiment (mock executor, no API key needed)
harnesslab run --design mini --tasks-per-domain 2

# Launch the interactive dashboard
harnesslab dashboard

# Analyze results
harnesslab analyze results/exp_001/results.jsonl

# List available tasks
harnesslab list --tasks --domain coding

Expected Key Findings

Based on the research literature (NLAH, AutoHarness, Meta-Harness, Efficient Benchmarking):

  1. Context Manager + Memory System explain >60% of performance variance
  2. Durability cliff at ~step 50-60 for most configurations; ObservationMask + FilesystemState flatten it dramatically
  3. ObservationMask + FilesystemState is super-additive (combined effect > sum of individual effects)
  4. InformedBacktrack + SeparateVerifier is sub-additive (redundant recovery mechanisms)
  5. 5-10 "universal" harnesses generalize across domains (HGS > 0.6)
  6. Minimal Viable Harness (3 modules) achieves ~85% of full benefit at ~40% of cost

Project Structure

harnesslab/
โ”œโ”€โ”€ harnesslab/
โ”‚   โ”œโ”€โ”€ modules/           # 6 module families ร— 5 implementations
โ”‚   โ”‚   โ”œโ”€โ”€ context/       # NullContext, SlidingWindow, LLMSummarizer, ObservationMask, HybridAdaptive
โ”‚   โ”‚   โ”œโ”€โ”€ retry/         # NoRetry, SimpleRetry, ExponentialBackoff, InformedBacktrack, MultiPathSearch
โ”‚   โ”‚   โ”œโ”€โ”€ tools/         # FullToolset, ProgressiveDisclosure, SemanticRouter, MinimalToolset, HarnessVerified
โ”‚   โ”‚   โ”œโ”€โ”€ memory/        # Stateless, FilesystemState, EpisodicMemory, SemanticSearch, WorkspaceManifest
โ”‚   โ”‚   โ”œโ”€โ”€ validation/    # NullValidator, SchemaValidator, SelfCritique, SeparateVerifier, DSAPVerifier
โ”‚   โ”‚   โ””โ”€โ”€ orchestration/ # SingleAgent, FixedPipeline, DynamicOrchestration, SelfEvolution, SubAgentDelegation
โ”‚   โ”œโ”€โ”€ tasks/             # 120 benchmark tasks + graders
โ”‚   โ”œโ”€โ”€ experiments/       # Fractional factorial design + mock/real executor
โ”‚   โ”œโ”€โ”€ analysis/          # HCM, HGS, Durability Curve
โ”‚   โ”œโ”€โ”€ dashboard/         # Plotly Dash interactive leaderboard
โ”‚   โ”œโ”€โ”€ cli.py             # Click CLI
โ”‚   โ””โ”€โ”€ config.py          # YAML config system
โ”œโ”€โ”€ scripts/               # run_mini_experiment.py, run_dashboard.py
โ”œโ”€โ”€ tests/                 # Full test suite
โ”œโ”€โ”€ results/               # Experiment outputs (gitignored)
โ””โ”€โ”€ pyproject.toml
PaperWhat It DoesHarnessLab's Contribution
NLAH (Pan et al., 2026)Ablates 6 modules on SWE-benchExtends to 4 domains, adds interaction effects, cost model, durability
AutoHarness (Lou et al., 2026)Synthesizes harnesses for gamesProvides evaluation target for synthesized harnesses
Meta-Harness (Lee et al., 2026)Black-box harness optimizationExplains why optimized harnesses work (module attribution)
Efficient Benchmarking (Ndzomga et al., 2026)Shows scaffold = major confoundQuantifies and attributes the confound

Citation

@software{harnesslab2026,
  title={HarnessLab: A Benchmark for Evaluating Agent Harness Designs},
  year={2026},
  note={First benchmark treating harness as independent variable},
  url={https://github.com/harnesslab/harnesslab}
}

License

MIT