An AI harness is the software that connects a model to the tools and environment needed to perform a task. It executes actions, returns their results to the model and organises the work: what information the model receives, where it can act and which controls apply.

Databricks’ explanation of agent harnesses places this layer around the model. The distinction helps clarify what we are using: the model generates responses and proposed actions; the harness coordinates their execution; the agent is the system combining both to work towards a goal.

What an AI harness is used for

Its purpose is to let a model-based application operate on files, data and services. This takes more than a well-written input: it requires connections to tools, somewhere to execute them and a way to continue from their results.

These capabilities can support different tasks:

  • Software development: inspect a project, modify files and run tests.
  • Information analysis: find documents, extract data, perform calculations and prepare a report with its sources.
  • Business processes: look up an order, update a ticket or prepare a response, within the permissions defined for each operation.

The scope depends on the available tools. Read access to a database allows queries; modifying it requires other tools and authorisations. The harness determines how those capabilities become specific operations.

How it works: decide, execute and observe

In an agent that uses tools, work typically proceeds through a cycle:

  1. The model receives the task and available context. It can answer or propose using a tool.
  2. The harness processes the request. It checks whether the action is permitted and executes the tool with the corresponding arguments.
  3. The result returns to the model. It may contain data, confirmation or an error.
  4. The system continues or stops. The new information supports choosing the next step, delivering a result or asking for help.

This tool loop explains how a model’s request becomes an action executed by an application.

For example, when fixing a program, the model can propose a change and request a test. The harness runs that test and returns its result. If it fails, the model receives the error message to revise its proposal. The cycle also needs time, cost or attempt limits to prevent continued work without progress.

The components of a harness

Each implementation combines these functions differently. Some come ready-made in a product; others must be built or configured for the application.

Instructions and context. These define the task, rules and information the model sees. Context engineering addresses selecting and maintaining that information: relevant documents, recent results and instructions needed for the next step.

Tools and integrations. These connect the model to search, databases, files, applications or code execution. They need clear interfaces and responses so the agent can distinguish a valid result from a failed operation.

Execution environment and permissions. These establish where actions take place and which resources they can access. An isolated environment can limit the effects of running code. Access controls and approvals determine which operations are allowed and which require human intervention.

State and memory. These preserve completed work and pending steps. To resume a long-running task, the system needs to save useful information and retrieve it when appropriate. Storing a file and bringing it back into the model’s context are separate steps.

Execution control. This organises calls to the model and tools, handles interruptions and establishes when to continue, retry or stop. It can combine fixed steps with model decisions; orchestration coordinates that process.

Verification and observability. Checks review results; logs make it possible to inspect actions, errors and duration. An automated test, data validation or human review provides different evidence about the work. The Claude Code documentation shows how context, actions and verification connect in a coding assistant.

What options are available?

There are products with an integrated harness and libraries for incorporating one into your own application. Distinguish them before comparing names: using an assistant and developing one address different needs.

The following options were checked against their official documentation on 20 October 2026.

Assistants and platforms for working directly

  • Claude Code, by Anthropic. A development assistant that can read a project, edit files and run commands. It integrates the work loop and context management around Claude models. It is available through several interfaces, including the terminal and editor.
  • Codex CLI, by OpenAI. Supports terminal-based work on a local repository: inspecting files, making changes and running installed tools. It includes permission configuration and can be used interactively or in automated workflows.
  • OpenHands. An ecosystem for software development agents. It includes components for tools, conversations and workspaces, alongside interfaces and execution services. OpenHands Cloud provides a managed service; its Software Agent SDK supports building custom agents.

Libraries for building agents

  • Claude Agent SDK, by Anthropic. Makes the tools, agent loop and context management used by Claude Code available in Python and TypeScript. It lets developers integrate those capabilities into their own applications.
  • Deep Agents, by LangChain. A library explicitly described as an agent harness. It includes file tools, context management, memory and delegation to other agents, with additional configurable capabilities. It uses LangGraph as its orchestration runtime.

LangGraph sits at another layer: it provides execution, persistence and human-intervention mechanisms on which agents can be built. Deep Agents adds harness capabilities on that foundation. This distinction separates orchestration infrastructure from a solution with more choices already made.

How to choose for the task

The first decision is whether to use an existing agent or develop your own application. An integrated assistant offers a starting point for working directly with code. Connecting an organisation’s specific processes, data and permissions requires assessing libraries and the infrastructure needed for that integration.

Then examine practical questions:

  • Which models it supports and which tools it can connect.
  • Where actions execute and what happens to the data.
  • How it enforces permissions, approvals and resource limits.
  • What it saves between sessions and how it resumes work.
  • How it supports checking results, inspecting logs and measuring cost.

The choice should be tested against representative tasks. A system that works when reading one document may behave differently with missing data, a failed tool or a task requiring several attempts. The distinction between predefined workflows and agents matters too: a process with known steps may need less complexity.

Why the same model can produce different results

Two assistants can use the same model while receiving different documents, accessing different tools or applying different checks. These conditions change each system’s opportunities to complete the task.

When comparing assistants, it is therefore worth asking what was evaluated: the model alone or the complete system. Keeping test tasks fixed and recording the configuration helps investigate the harness’s contribution alongside time, cost and errors.

Improving the model remains important. Designing its working environment matters too: this determines what information it has, what it can do and how we check the result. Understanding the harness helps us examine those decisions when assessing an AI tool.

Found this useful? If you would like to support this space, you can buy me a coffee.

Buy me a coffee Optional support through PayPal. You choose the amount.