AI harnesses: guides and sensors, the four boxes to fill

· Published · 1 min read

A harness is everything in an agent that is not the model.

Birgitta Böckeler (martinfowler.com, April 2026) structures it along two axes.

Axis 1: timing

  • Guides act before: they raise the probability that the first draft is right.
  • Sensors act after: they let the agent correct itself.

Without sensors, the agent repeats the same mistake. Without guides, it does not know which rules to apply.

Axis 2: mode

  • Computational: tsc, ESLint, dependency-cruiser. Deterministic, a few seconds.
  • Inferential: a review skill, an LLM judge. Semantic, expensive, non-deterministic.

Four boxes

Cross the two axes and you get four boxes.

Your AGENTS.md occupies only one of them: inferential guides. The least deterministic box, yet often the only one filled.

A dependency-cruiser rule wired into a hook fills another box: the agent learns it violated a boundary before you open the PR.

Placement rule: the faster a check is, the further left it belongs. Hook, pre-commit, CI, human review.

The harnessability of a codebase

But not all of these checks are available everywhere. Strict typing gives you a sensor. Clean module boundaries make a structural rule possible. Without those properties, the check does not exist.

Böckeler calls this the harnessability of a codebase, and draws the conclusion that hurts: the harness is most necessary where it is hardest to build.

Sources

  • Birgitta Böckeler, Article on AI agent harnesses (martinfowler.com) (2026)
  • Sander Verweij, dependency-cruiser