Harness Engineering

Harness engineering for coding agents whose work you can check.

Harness engineering turns a coding agent you keep rescuing into a workflow your engineers can actually review. Around the agent you already use, we set up repository context, controls on how it runs and loops that feed results back.

DIRECT ANSWER

Harness engineering is the design of everything an AI coding agent works inside: its repository instructions, how it pulls context, its tools and permissions, the state it keeps while running and the loops that check its output. Devoun builds those controls into your codebase, so your team can look over each change, pick up work that stopped midway and judge when a result is fit for review.

Best for

  • Engineering teams whose coding agents keep ignoring the rules of the repository
  • Teams handing off changes with several steps that still need tests and a human reviewer

Consider another approach

  • Building an AI product for customers from scratch, with nothing implemented yet
  • A one-off training workshop, or work that only evaluates and builds nothing

When does it make sense to bring in harness engineering?

Maybe the agent changes code in the wrong layer, forgets where it was from one session to the next, or reports success while the tests are red. Before touching the setup, we follow a single typical task end to end. What you get is a working agent workflow inside a repository you already have. If you need a new AI product, see AI Agents & Products; if the goal is broader adoption across the company, see AI Enablement.

Hand the agent directions it can actually use.

We set up short AGENTS.md instructions, references to the architecture, the build commands and retrieval of the context each task needs. What the agent knows about the repository is versioned next to the code itself. OpenAI’s harness engineering account explains how the work moves toward designing the environment and its feedback loops. Context engineering only feeds the agent relevant information; a harness goes further, governing how the agent runs and checking what it produced.

Limit every action, and keep track of what comes next.

We set which tools the agent may use, sandbox its execution where that is needed, and fix limits on credentials, per-run budgets and the points where it must hand back to a person. At each checkpoint the record shows what was changed, what broke and what is still open. Anthropic’s long-running agent research stresses keeping progress notes and working in small increments from one session to the next. If you need new tool interfaces, we scope them as MCP Server Development; a separate, independent threat review sits with AI Security.

An agent saying it passed is not the change passing.

An example of how acceptance could work: in a test repository, the agent has to fix a regression. First it reproduces the bug, then it makes the change, gets through the checks we agreed on and leaves a diff someone can review. Along the way we cut the run off, restart it from the last checkpoint and block a tool call it is not allowed to make. To pass, the repository must end up in the expected state with the test results on record; the agent announcing success counts for nothing. We are proposing this test here; it is not the outcome of any client project.

Confirm the results before you give the agent more freedom.

Linting, tests, architecture checks and review gates all become part of the loop. We then log failures, retries, time taken and usage and compare them with a starting baseline. Anthropic’s agent evaluation guidance separates the state the environment is actually left in from the agent’s own account of events. Building evaluation datasets, comparing models and watching an application’s quality over time are handled separately under AI Evaluation & LLMOps.

Hand over a workflow any of your engineers can run.

At handover you get the instructions and configuration under version control, the tool policies, a set of typical tasks, the run logs and a runbook for recovery. Your engineers practice one ordinary run and one that gets interrupted. We agree the scope, the fees and any support afterward for your specific repository; nobody can promise a set level of autonomy or speed for every codebase. To check who owns what, work through our software handover checklist.

See how it is built, and weigh the proof.

Our projects page includes the Optivoy airline booking agent, which is related AI agent work where a person has to approve any step that touches payment. It is not proof of what harness engineering achieves. Your first engagement has to show results on the tasks you and we agree on.

Questions before you start

A working workflow built around your coding agent, covering repository context, rules for tools and permissions, checkpoints during runs, gates that verify output and documentation for running it. Whatever must work at handover is set by the tasks we agree on.
No. Prompt engineering adjusts the instructions a model receives. Harness engineering goes further and reshapes where those instructions are carried out, including tool access, state, recovery, checks and review. Improving prompts may be one piece of it.
Yes. We begin by reviewing the repository, how the agent is connected and the failure you can reproduce. Where your current setup can carry the controls you need, we build on it. We only build a custom orchestration layer if your existing tools cannot do what was agreed.
Harness engineering builds the environment coding work runs in, plus the loop that feeds results back. AI Evaluation & LLMOps covers purpose-built evaluation datasets, comparisons and continuous monitoring of LLM applications already in use. A harness runs checks, but it does not take the place of that wider evaluation work.
It comes down to how complex the repository is, the tool permissions involved, the infrastructure runs need and which tasks have to be verified. Before anything starts, we agree a limited assessment and a proposal for the build. Where they apply, model usage, hosting and later support are listed as separate items.
To begin, an overview of the repository, the build instructions and one failure example with sensitive data removed. For the build itself, we need the code and test-environment access we agree on. You do not have to share production credentials for the first assessment, and we spell out which tools are allowed and where approval is required.

Plan your agent harness

Come with a repository, a failure your agent keeps repeating and the task you would like to hand off. Before any work begins, we settle access, the checks for acceptance and a limited scope for the build.