Agent Harnesses Under the Hood
A source-level tour of seven agent harnesses and a final comparison: execution loops, durable sessions, context management, tools, and security boundaries.
8 articles · Read in order

≈ 7 min read
Claude Code Under the Hood: A Recovery-Oriented Agent Harness
An unverified source snapshot shows a harness designed around recovery: explicit loop transitions, streaming tool execution, layered context defenses, and replayable session history.
≈ 6 min read
Codex Under the Hood: Making the Sandbox a First-Class Agent Concern
A source-level tour of Codex's Rust harness: multi-signal turn completion, PTY-backed execution, layered sandbox policy, replayable JSONL history, and an app-server interface.
≈ 6 min read
opencode Under the Hood: Durable State, Live Streams, and Reversible Sessions
A source-level look at opencode's TypeScript harness: database-backed session projections, streamed tool events, layered compaction, reversible workspace snapshots, and blocking approvals.
≈ 5 min read
Pi's Small Agent Harness: Queues, Session Trees, and an Honest Security Boundary
Pi keeps its agent runtime deliberately small: a two-queue loop, append-only session trees, and extensions in place of built-in product features. Its most important decision is equally explicit: it provides no sandbox.
≈ 5 min read
OpenClaw's Agent Gateway: Sessions, Persistent Work, and Optional Isolation
OpenClaw turns an agent loop into a persistent gateway for chat channels. Session keys, serialized lanes, heartbeats, cron jobs, and optional sandbox backends address the risks of an assistant that keeps running when you leave the terminal.
≈ 6 min read
Hermes Agent's Durability Rule: Persist Before a Tool Can Act
Hermes Agent centers its safety model on a simple ordering rule: write an assistant tool call to SQLite before executing it. Combined with iteration budgets, protocol repair, non-destructive compaction, and layered terminal controls, that rule supports long-running autonomous work.
≈ 9 min read
DeepSeek Harness: An Auditable, Composable Agent Runtime
How DeepSeek Harness turns a small agent loop into a configurable product: turn and step scheduling, waterfall tools, event-sourced sessions, and a carefully bounded fail-closed subprocess sandbox.
≈ 9 min read
Can DeepSeek Harness Reproduce Six Other Agent Harnesses?
A final comparison of seven agent harnesses, with a strict distinction between DSH capabilities that are shipped, supported by partial plugin evidence, and suggested only by an architectural seam.