harness-engineering

harness-engineering is a skill for Claude Code, Codex from docxology/template. It costs 47 tokens per session (2,297 once invoked), scanned A, a copy of harness-engineering, Apache-2.0.

A design guide for autonomous agent systems—software that can work through tasks with limited human input. It covers feedback, editable areas, logs, evaluation, recovery, rollback, and approval boundaries.

In plain words
What is it for?
Use it when building research loops, experiment systems, background agents, evaluation setups, or pull-request-producing agents.
Why use it?
It helps prevent long-running agents from losing their state, weakening their own checks, or making unsafe irreversible changes.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

Good fit Use it when building research loops, experiment systems, background agents, evaluation setups, or pull-request-producing agents.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/docxology/template/harness-engineering
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add docxology/template --skill harness-engineering
Clone the repo
git clone --depth 1 https://github.com/docxology/template

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for harness-engineering

README.md
[![agentmods](https://agentmods.dev/badge/skills/docxology/template/harness-engineering/github.svg)](https://agentmods.dev/skills/docxology/template/harness-engineering)
Your own site
<a href="https://agentmods.dev/skills/docxology/template/harness-engineering"><img src="https://agentmods.dev/badge/skills/docxology/template/harness-engineering/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for harness-engineering

Your own site · 80×15
<a href="https://agentmods.dev/skills/docxology/template/harness-engineering"><img src="https://agentmods.dev/badge/skills/docxology/template/harness-engineering.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,297 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00047 $0.02297
Opus 5.5 $0.00019 $0.00919
Sonnet 5.5 $0.00009 $0.00459
Haiku 4.5 $0.00005 $0.00230

Measured 1mo ago against content hash dde3d8f46d4d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

harness-engineering scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

This is a copy

100% identical to harness-engineering — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.agents/skills/harness-engineering/SKILL.md · 235 lines

How it starts

The opening of the file, as written. The whole thing — 235 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Harness Engineering

Harness engineering designs the control system around an agent: what it may edit, how it receives feedback, where it writes state, how failures recover, and who can approve irreversible actions. The harness is the difference between a helpful agent session and an autonomous loop that can run for days without corrupting its objective.

When to Activate

Activate this skill when:

  • Building autonomous research or experimentation loops
  • Designing an agent environment with locked metrics and editable code or content
  • Creating PR-producing or background agents
  • Evaluating whether an agent can safely run without frequent human prompts
  • Adding novelty, ablation, pruning, rollback, or durable logging to an agent workflow
  • Preventing agents from gaming benchmarks, weakening rubrics, or losing state across compaction

Do not activate this skill for adjacent work owned by other skills:

  • General quality gates, regression suites, or outcome metrics without autonomous control surfaces: evaluation.
  • Tool schemas, response formats, and recovery errors for harness tools: tool-design.
  • Project-level task-model fit, pipeline shape, and cost planning: project-development.
  • Remote sandbox, warm-pool, and hosted session infrastructure: hosted-agents.

Core Concepts

Harness Boundary

Separate the agent from the environment it operates inside. The agent proposes actions; the harness defines allowed surfaces, feedback, persistence, and promotion rules.

Use four surface classes:

Surface Examples Rule
Locked Eval metric, rubric, validation script, merge policy Agent may read and propose changes, but cannot score itself with modified rules
Editable Skill draft, experiment file, prompt, config under test Agent may mutate during the loop
Append-only Results log, research thread, rejected ideas Agent may append, not rewrite
Human-controlled Merge, production deploy, credentials, destructive operations Requires explicit human approval

Read the full file on GitHub · 235 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 235 lines · 47 tokens per session scan A dde3d8f46d4d

Subscribe to this mod's changes

harness-engineering is a skill published in the GitHub repository docxology/template (20 stars, last pushed yesterday), licensed Apache-2.0. It adds 47 tokens to every session and 2,297 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 100% identical to harness-engineering, differing in 0 lines, and is treated as a copy.

Related

Other skills, from other repositories

planning-with-files

Persistent file-based planning for multi-step AI-agent work. Keeps taskplan.md, findings.md, and progress.md on disk; lifecycle hooks inject selected project planning context. Automatic recovery reads project planning files only. Explicit session-catchup.py --metadata reads same-project local agent session records and…

mxyhi/ok-skills · 117 tokens

bopomofo-rescue

A text-recovery tool for Taiwanese Bopomofo, also called Zhuyin, keyboard mistakes. It converts letter-and-number sequences typed with the wrong input mode back into likely Chinese text.

mxyhi/ok-skills · 332 tokens

aerospace-engineering-technician

Use when a task needs the judgment of an Aerospace Engineering and Operations Technologist/Technician — verifying an installed fastener's preload against a drawing's torque callout via the T=K·D·F relationship, reducing strain-gauge data from a structural proof-load test into stress and checking it against an…

wonsukchoi/domain-experts · 169 tokens

agricultural-sciences-professor

Use when a task needs the judgment of a tenure-track or tenured Agricultural Sciences faculty member at a land-grant university — deciding whether to submit a grant this cycle versus wait, allocating time across the teaching/research/extension appointment split, diagnosing a stalled graduate student or field trial, or…

wonsukchoi/domain-experts · 75 tokens

anthropology-archaeology-professor

Use when a task needs the judgment of a postsecondary Anthropology or Archaeology professor — designing a gen-ed or major-track course, building a tenure or promotion dossier, defending a department against an enrollment-driven program review, mentoring a graduate student's fieldwork grant application, or writing an…

wonsukchoi/domain-experts · 77 tokens

art-drama-music-professor-postsecondary

Use when a task needs the judgment of a Postsecondary Art, Drama, or Music Professor — diagnosing a jury/crit score that contradicts a semester of formative work, building a studio-art or performance tenure dossier around exhibitions and productions instead of publications, staffing applied one-on-one lessons or crit…

wonsukchoi/domain-experts · 94 tokens