An agent harness is the software around an AI model that turns it into an agent. The model decides what to do next. The harness does everything else: it runs the loop, gives the model its tools, assembles the context it sees, keeps track of state, handles errors, and decides when the job is done.
A useful way to think about it: agent = model + your data + harness. The model decides what to do. Your data, meaning the documents, records and systems it can reach through tools, gives it something real to work on. The harness runs the loop that connects the two. The same model can power a chatbot, a coding agent or a sales assistant. What makes each one different is the data it can reach and the harness around it.
A language model on its own only turns text into text. It can't run code, call an API or remember what happened three steps ago. When a model "calls a tool", it actually writes out a request, such as query_database(table="customers"). Something else has to read that request, run it with the right credentials, and pass the result back. That something is the harness.
The gap widens as tasks get longer. To "find customers we haven't contacted in 30 days and draft emails to them", the harness has to:
Without a harness, you have a model. Put a harness around it and connect it to your data, and you have an agent.
These terms get mixed up, often because one product ships several of them together. Here's how they differ:
Agent harness vs agent runtime: the harness decides what the agent should do next. The runtime decides where that happens and under what constraints. For a deeper comparison, see Agent Harness vs Agent Runtime.
Agent harness vs framework: a framework is a set of parts. A harness is the assembled thing that runs your agent. You might build a harness with a framework, or use a product that ships one ready-made.
Agent harness vs scaffolding: the terms overlap and aren't yet standardised. A common distinction, used in Hugging Face's agent glossary, is that scaffolding is what the model works from (its instructions, tool definitions and output format), while the harness is the code that runs the loop, calls the tools and decides when to stop. Many people use "scaffolding" loosely for both.
Agent harness vs evaluation harness: an evaluation harness tests models or agents against a set of tasks and scores the results. EleutherAI's open-source LM Evaluation Harness is a well-known example. An agent harness runs the agent on real work. Agent evaluations often run the agent inside its own harness, so they measure the whole system rather than the model alone.
Every agent harness, from a coding agent to a customer support bot, handles the same core jobs:
You've probably used an agent harness already, even if it wasn't called that:
A harness that works for one developer often breaks in a company. It isn't the loop that breaks. It's the connection to your data: which systems the agent can reach, as whom, and under what rules. Enterprise agent harnesses need:
For a deeper look at these requirements, see What Makes a Great Agent Harness?
Build your own harness when the agent is your product, you need full control over the loop, and you have engineers to maintain it as models and protocols change. Frameworks make the first version fast. The ongoing work is integrations, permissions, error handling and evaluation.
Use a platform when you're building internal agents for many teams. In that case most of the effort isn't the loop. It's connecting company systems safely, keeping permissions right, and giving IT one place to see and control every agent.
Many companies do both. Product teams build custom harnesses, and a shared platform governs the tools and data those harnesses can reach. For a comparison of options, see Best Agent Harness Platforms.
This section describes Credal's product.
Credal is the MCP gateway and agent builder for enterprise AI. It supports both approaches:
The result is one place to see and control every agent and tool call, whichever harness the agent runs in.
An agent harness is the software around an AI model that turns it into an agent. It runs the loop, provides tools, assembles context, tracks state, handles errors and decides when the task is complete.
The harness is part of the agent. An agent is a model, connected to your data, run by a harness toward a goal. The model makes decisions, and the harness carries them out and manages everything around them.
The model is the language model that decides what to do. The harness is the code that runs the model in a loop with tools, memory and guardrails, and connects it to your data. The agent is all of them together: model + your data + harness.
No. A framework is a toolkit for building harnesses. A harness is the working system that runs a specific agent.
The harness decides what the agent does next. The runtime is the infrastructure where it runs, with sandboxing, resource limits and network and credential controls.
An agent harness runs an agent on real tasks. An evaluation harness runs a set of test tasks and scores the agent's performance.
Claude Code is an agent built on a harness. Anthropic describes the Claude Agent SDK as the harness that powers Claude Code: the loop, built-in tools and context management. Other coding tools, such as OpenAI's Codex and Cursor's agent mode, are built on harnesses too.
Per-user permissions inherited from source systems, scoped tools, rules enforced outside the model, human approvals for sensitive actions, a complete audit trail, evaluations before rollout, and the freedom to switch models.
Models keep getting smarter, but the harness and the data it connects to decide whether that intelligence turns into reliable work. For one developer, the hard part is the loop. For an enterprise, it's the data: making sure every agent can reach exactly what it should, as the right person, under the right rules.
One platform for all agents. Full visibility for admins, full access for teams.