second brain source
← 首页

external-source

Harness Engineering: Anatomy, Architecture, and Evolution of Coding Agents — A Source-Code Study of Eleven Systems

Note: body below is original English text extracted from https://arxiv.org/html/2609.00006v1. Figures/tables are not fully preserved. Do not treat this file as a translation.

arXiv:2609.00006v1 [cs.SE] (Atom published 2026-07-15; study pins July 2026 releases)

Harness Engineering: Anatomy, Architecture, and Evolution of Coding Agents A Source-Code Study of Eleven Systems

Paul Barbaste (Lead and corresponding author; Inclusive Brains; Wavestone AI Lab), Tristan Darrigol, Germain Vu, Tom Wiltberger (Wavestone AI Lab)

(July 2026)

Abstract

An agent is a model plus a harness: the runtime that couples an LLM to the world through a loop, tools, context management, safety controls, orchestration, and extension surfaces. Harness engineering, named as a discipline in early 2026, is the design and evolution of that runtime. This paper gives the young discipline its most comprehensive empirical foundation to date. It is a source-code anatomy of eleven production coding harnesses: Claude Code (Anthropic), Codex CLI (OpenAI), Gemini CLI (Google), Mistral Vibe (Mistral), OpenHands, Aider, Mini-SWE-Agent, Hermes (Nous Research), Pi, OpenCode, and OpenClaw, plus Omnigent (Databricks), the first meta-harness we are aware of, analyzed as a contrast point. The paper defines what a harness is, maps its seven canonical subsystems with the minimal and maximal implementation of each, and dissects all eleven systems along those subsystems. It does not benchmark or rank; it describes and compares how the systems are built.

The audit yields 13 cross-cutting observations and a catalog of 29 recurring design patterns. Two absences survive a threefold corpus expansion: across roughly four million lines of Python, TypeScript, and Rust, no agent runtime imports a general-purpose agentic framework (LangChain, LangGraph, AutoGen, or a dozen others; Gemini CLI uses neither of Google's own), and none retrieves code with vector embeddings; the field runs on hand-rolled async loops and deterministic retrieval (ripgrep, tree-sitter, glob, auto-discovered Markdown context files). The extensibility standards resolved: SKILL.md skills lead MCP in adoption (9/11 vs. 8/11), with registries, trust tiers, and the corpus's first agent-authored skills; ACP ships in six systems and acquired a third role, harness hosting, with OpenHands running Claude Code, Codex, or Gemini CLI as interchangeable backends.

Because the original eight systems were re-pinned rather than replaced, the study also contains a controlled longitudinal sample: the same harnesses, source-diffed across one quarter. The diff shows convergence becoming imitation (Codex adopts Claude Code's hook vocabulary verbatim and ships an importer for its sessions and settings; OpenHands reads Claude Code's plugin format), while behavioral policy migrates from prompt prose to configuration, and three of the April edition's observations required substantive revision in place.

These threads converge on the paper's thesis: in the first half of 2026 the coding harness completed a turn from tool to platform. Harnesses became importable SDKs while framework vendors shipped harnesses; marketplaces, switching-cost tooling, and enterprise governance layers appeared; the agent became addressable as a model behind an OpenAI-compatible endpoint; and a meta-harness now orchestrates eleven vendor harnesses (half this corpus among them) behind one API, re-implementing the expensive parts and arbitraging the proprietary ones. The paper closes with 18 design recommendations pinned to the observed code, and a 90-line minimum-viable-harness scaffold that implements ten of them.

Keywords: harness engineering, coding agents, LLM agents, agent architecture, platformization, tool use, multi-agent systems, MCP, agent skills

2.1 Definition (verbatim excerpt)

An agent is a model plus a harness. The harness is everything except the model: the runtime that couples an LLM to the world—its loop, its tools, its context, its safety controls, its orchestration, and its extension surfaces. Harness engineering is the discipline of designing and evolving that runtime.

2.3 The Seven Subsystems (summary table from paper)

Subsystem Role Minimal form Maximal form
Agent loop Alternates inference with action; stop + recovery Mini-SWE-Agent: linear while + one bash tool OpenHands: event-sourced conversation + parallel action batches
LLM integration Provider protocols, prompt, caching, routing Mini-SWE-Agent: one LiteLLM call Hermes: five transports, 29 provider profiles; Codex: server-delivered model catalog
Tools & actions What the agent can do Mini-SWE-Agent: bash only Claude Code: 43 typed tools with deferred loading; Codex: tool calls as V8-executed code
Memory & context Context rationing + persistence Mini-SWE-Agent: unbounded linear history Codex: agent-maintained cross-session memory; Gemini CLI: graph-based context distillation
Safety & permissions What runs / asks / forbidden Mini-SWE-Agent: cost and step limits Codex: policy rules + LLM approval reviewer + three-platform OS sandbox
Orchestration Sub-agents / protocols Aider: none Claude Code: recursive composition; Omnigent: cross-vendor (meta-layer)
Extensibility hooks / skills / plugins / MCP Mini-SWE-Agent: structural typing Pi: everything-is-an-extension; Codex: marketplace plugins

Selected cross-cutting observations (verbatim-leaning)

Observation 1. The eleven systems span three orders of magnitude in code size while targeting similar tasks, yet loop sophistication does not predict benchmark performance. Mini-SWE-Agent's minimal linear loop achieves reported results in the same range as OpenHands's event-sourced conversation engine...

Observation 2. Provider-native optimizations—cache boundaries, extended thinking, reasoning effort, model-specific prompts—are not gated on tight coupling; they are gated on who pays the per-provider conditional-code cost.

Observation 3. Prompt rhetoric converges where engineering experience converges, then thins as trust calibrates. Anti-gold-plating language appears in nearly isomorphic phrasings across six independently developed scaffolds...

Remainder

Full original English text (83 pages): see html_url / source_url / pdf_url in frontmatter. Do not invent missing sections from this partial extract.