AI Agent Harness
This post appeared first in my notes: AI Agent Harness.
An AI agent harness is a tool or environment that wraps an AI model and exposes it as an interactive agent; giving it access to tools (file system, shell, browser, APIs, messaging), a conversation loop, and context about its operating environment. The harness handles the orchestration; routing tool calls, managing context windows, streaming output, persisting state, applying permission profiles.
Most early harnesses were coding-focused (Claude Code, Codex CLI, Aider), but the category now spans coding, personal-assistant, and managed-cloud variants. Hermes Agent and OpenClaw are personal-assistant harnesses with messaging gateways and skill learning loops; Codex Cloud and Claude Managed Agents are managed-cloud variants where the agent runs server-side. The pattern is the same, but their orientation is not.
The simplest way I know to explain it comes from Isuru Wijesiri's book Harness Engineering 101: "The LLM is the brain. The harness is the body." A model API is stateless. On every turn, you send the whole conversation as a JSON array and you get text back. The harness is the program that builds, maintains and protects that array. Tools, memory, subagents, compaction, permissions: each one is a patch on that loop, added because something broke. More in Harness Engineering.
You can also build your own. Toolkits like the Pi SDK, Mastra Harness and the OpenAI Agents SDK give you the agent loop as a library, so routing, permissions and checks live in your code instead of in a vendor's defaults. I explain why you'd want that in Harness Engineering.
The term distinguishes the harness (the scaffolding around the model) from the model itself. The same harness can often work with multiple models; the same model can be driven by multiple harnesses. Although it's not a given. I've tried using Claude Code at work against different models (e.g., GPT 5.4) and it was a disaster ;-)
Common capabilities
- Read/write files and execute shell commands
- Search codebases (grep, AST, LSP)
- Run tests and linters
- Browser/web access
- Model Context Protocol (MCP) tool integration
- Git operations (commits, PRs, diffs)
- Multi-agent coordination (subagents, parallel workers)
- Persistent memory and context files (e.g., CLAUDE.md, AGENTS.md)
Harnesses I've taken notes about
The detailed map is at AI Agent Harnesses (MoC).
- 2026-10-01 Claude Code context all - see exactly what eats your context window
- 2026-10-03 OpenClaw 2.0 - easier setup, shared sessions, same security defaults
- 2026-10-04 Claude Code Mods - Claude Code is now programmable, and mods aren't sandboxed
- 2026-10-04 You Should Know - a second pair of eyes on long Claude Code runs
- 2026-10-16 Claude Code idle compaction - cheaper to resume, but from a summary
- AI Agent Harness
- Aider
- Antigravity 2.0
- Antigravity CLI
- Antigravity SDK
- Claude Code
- Claude Code Auto Mode
- Claude Code Channels
- Claude Code Projects
- Claude Code Routines
- Claude Dynamic Workflows
- Claude Managed Agents
- Claude Managed Agents Environments
- Claude Managed Agents Multi-Agent
- Claude Managed Agents Sessions
- Claude Opus 4.8 and Dynamic Workflows
- Cline
- Codex App
- Codex CLI
- Codex Cloud
- Codex IDE Extension
- Cook AI Agent
- Cursor
- Cursor Agent SDK
- Cursor CLI
- Docker Agent
- Fabro
- Gemini CLI
- GitHub Copilot
- GitHub Copilot App
- GitHub Copilot CLI
- GitHub Copilot SDK
- Google Antigravity
- Goose
- Grok Build
- Harness Engineering
- Harness2
- Hermes Agent
- JCode
- JetBrains Air
- JetBrains Thinkrail
- Kimi CLI
- LangChain Deep Agents
- Microsoft Agent Framework
- oh-my-pi
- OpenAI Agents API
- OpenAI Agents SDK
- OpenAI Codex
- OpenClaude
- OpenClaw
- OpenClaw ACP Agents
- OpenClaw Channels
- OpenClaw Gateway
- OpenClaw Hooks
- OpenClaw Memory System
- OpenClaw Multi-Agent Routing
- OpenClaw Nodes
- OpenClaw Skills
- OpenClaw Standing Orders
- OpenClaw Sub-Agents
- OpenCode
- OpenHarness
- OpenWork
- Paseo
- Pi Mono
- Pi pod
- Pydantic AI
- qm (Y Combinator)
- Roo Code
- Superset
- TrueForge
- Vercel fx
- Vercel Open Agents
- Windsurf
- ZCode
References
- Harness Engineering 101 (Isuru Wijesiri): https://github.com/IsuruMaduranga/harness-engineering-101
Related
- Harness2
- OpenAI Agents API
- AI Agents
- AI Agent Skills
- Model Context Protocol (MCP)
- Large Language Models (LLMs)
- How coding agents work
- Agentic Engineering
- AI Subagents
- AI Agent Orchestration
- Harness Engineering
- Context Engineering
- Agent System Engineering
- Loop Engineering
- Agentic loops
- Cursor Agent SDK — agents as versioned Markdown and TypeScript projects; Cursor runs the loop
- Hybrid Reasoning Agents — agents that think in latent space but keep tool calls in text
- Crabbox — remote testbox infrastructure that harnesses can call as a tool
- Living shim between humans and AI models
- TrueForge — open-source vendor-neutral harness by TrueFoundry
- ZCode — Z.ai's GLM-5.2 harness
- Shepherd (AI) — reversible-execution runtime for supervising agents
- OpenHarness — open-source command center running many coding agents across machines
About Sébastien
Ready to get to the next level?
Found this valuable? Share it with someone who needs it.