liveBook · Manning

Agent harness

As explained in Building Reliable AI Systems

A harness is orchestration infrastructure that manages an AI agent's loop, state, tools, approvals, tracing, and output channels.

An LLM that only returns text is not yet an agent. A harness coordinates tools, results, state, and recovery, turning tool integrations into a working agent loop. section 7.9 section 7.9.1

Separate orchestration from execution:

  • The harness owns the agent loop, state, tool routing, approvals, tracing, and output channels. section 7.9.1
  • The sandbox runs code and commands in isolation; credentials and sensitive data remain in the harness. If execution crashes, the harness can restore a checkpoint. section 7.9.1

Implementations

OpenAI’s agents SDK and Codex CLI illustrate model-native harnesses paired with sandboxed compute. OpenClaw illustrates a model-agnostic, community-extensible harness; NemoClaw uses OpenShell for enterprise sandboxing. section 7.9.1

Figure 7.4 The harness owns the agent loop, memory, and LLM communication. The sandbox executes code in isolation with no direct model access. Tasks flow right; results flow left. If the sandbox crashes, the harness recovers.
figure

Use the diagram to trace task flow from harness to isolated sandbox and results back, including recovery after a sandbox crash. section 7.9.1

How Building Reliable AI Systems covers it

How deep it goes
Explains control-plane and compute-plane responsibilities, including isolation, credentials, and checkpoint recovery.
Examples
Compares OpenAI’s agents SDK and Codex CLI, OpenClaw, and NemoClaw with OpenShell.
What it assumes
Builds on MCP tools and contrasts harnesses with standalone LLM prompt-response behavior.
What you can do after
Evaluate agent architectures by distinguishing orchestration responsibilities from isolated code execution.
How it connects
Connects agent loops and tool routing with MCP tools, memory, approvals, tracing, and sandboxed execution.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Building Reliable AI Systems. The section links point to the parts of the book it draws on.