Skip to content
Back to skills

Agent Harness

ASecurity

Use when making a repository agent-ready, verifying its instruction index, documented commands or harness CI, bootstrapping those artifacts, auditing harness maturity, or integrating delegated-review evidence with execution and merge controls. Not for a standalone code review or a small content edit without harness changes.

  • 8 stars
  • 0 votes
  • 0 copies
  • 5 views
  • Added September 19, 2026
ai-agentsbashgit

Security analysis

A100/100

Pro scans all 20 files and shows the line behind each finding

Scanned November 9, 2026

npx -y skills add netresearch/agent-harness-skill --skill agent-harness --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Agent Harness?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Agent Harness
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/netresearch-agent-harness/badge)](https://www.skillsdirectory.com/skills/netresearch-agent-harness)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
# SPDX-License-Identifier: CC-BY-SA-4.0
# SPDX-FileCopyrightText: Netresearch DTT GmbH
name: agent-harness
description: "Use when making a repository agent-ready, verifying its instruction index, documented commands or harness CI, bootstrapping those artifacts, auditing harness maturity, or integrating delegated-review evidence with execution and merge controls. Not for a standalone code review or a small content edit without harness changes."
license: "(MIT AND CC-BY-SA-4.0). See LICENSE-MIT and LICENSE-CC-BY-SA-4.0"
compatibility: "Requires Bash, Read, Write, Edit, Glob, Grep tools"
metadata:
  author: Netresearch DTT GmbH
  version: "1.10.0"
  repository: https://github.com/netresearch/agent-harness-skill
allowed-tools: Bash(${CLAUDE_SKILL_DIR}/scripts/*) Bash(git:*) Bash(make:*) Read Write Edit Glob Grep Agent
---

# Agent Harness

The agent harness makes a repo agent-ready with self-sustaining enforcement. This skill **installs** it; CI, hooks, and conventions then enforce it.

## Modes

### 1. Verify (primary)

Always start here. From the target repo root, run:

```bash
${CLAUDE_SKILL_DIR}/scripts/verify-harness.sh
```

Analyse the output and fix or suggest fixes. Verification checks dead references, line counts, missing artefacts, and command/target alignment.

### 2. Bootstrap

When artefacts are missing, create them from templates:

| Artefact | Template | Platform |
| --- | --- | --- |
| `AGENTS.md` | `templates/AGENTS.md.tmpl` | All |
| `docs/ARCHITECTURE.md` | `templates/ARCHITECTURE.md.tmpl` | All |
| `docs/exec-plans/{active,completed}/` | Create directories | All |
| `.github/workflows/harness-verify.yml` | `templates/harness-verify.yml.tmpl` | GitHub |
| `.gitlab-ci.yml` (harness-verify job) | `templates/gitlab-ci-harness-verify.yml.tmpl` | GitLab |
| `.forgejo/workflows/harness-verify.yml` | `templates/forgejo-harness-verify.yml.tmpl` | Forgejo/Gitea |
| `.github/workflows/harness-checkpoints.yml` | `templates/harness-checkpoints.yml.tmpl` | GitHub |
| `.gitlab-ci.yml` (harness-checkpoints job) | `templates/gitlab-ci-harness-checkpoints.yml.tmpl` | GitLab |
| `.forgejo/workflows/harness-checkpoints.yml` | `templates/forgejo-harness-checkpoints.yml.tmpl` | Forgejo/Gitea |
| `.github/pull_request_template.md` | `templates/pull_request_template.md.tmpl` | GitHub |
| `.gitlab/merge_request_templates/Default.md` | `templates/merge_request_template.md.tmpl` | GitLab |
| `.forgejo/pull_request_template.md` | `templates/pull_request_template.md.tmpl` | Forgejo/Gitea |
| `.envrc` | `templates/envrc.tmpl` | All |
| Makefile harness targets | `templates/Makefile.harness.tmpl` | All |
| `scripts/verify-harness.sh` | `${CLAUDE_SKILL_DIR}/scripts/verify-harness.sh` (copy directly) | All |
| `.harness/checkpoints.yml` | see `references/enforcement-mechanisms.md` § 12 | All |

Populate with repo-specific values and preserve unrelated content. Existing
authorization to update these files remains valid; ask only for a new scope or
permission decision, not for each routine edit.

### 3. Audit

Report the repo's maturity level (1, 2, or 3) and show what is needed to reach the next level. See `references/maturity-levels.md` for detailed criteria.

## Running the checks that skills ship

A skill's own validator is run by an agent only if the agent decides to, and measured over six trials on the case where it was most obviously relevant, it was run once ([#61](https://github.com/netresearch/agent-harness-skill/issues/61)). A repository therefore declares in `.harness/checkpoints.yml` which skills' checkpoints apply to it, pinned by ref, and a CI job runs them:

```bash
${CLAUDE_SKILL_DIR}/scripts/run-shipped-checkpoints.sh
```

It fails the job on a failing checkpoint of severity `error`, reports the rest, and exits 2 on a declaration it cannot resolve rather than passing quietly. `verify-harness.sh` errors when a declaration has no job, and when a job has no declaration.

For explicitly required results, set `require_pass` on the declaration entry.
Only one passing result per named ID fulfills that obligation; skipped, blocked
or missing results leave verification incomplete. See
`references/enforcement-mechanisms.md`, section 12, for the contract and limits.

## Key Principles

- **AGENTS.md is an index, not an encyclopedia.** Keep it under 150 lines. Put detail in `docs/`.
- **Enforcement is project-level.** CI workflows, git hooks, and branch protection enforce the harness -- not this skill at runtime.
- **Verify first, bootstrap second.** Always run verification before creating artefacts. The skill checks artefacts, not tools.
- **Delegate specialist work.** See `references/skill-integration-map.md` for skill routing (`@agent-rules`, `@github-project`, `@enterprise-readiness`, `@retro`).
- **Verify evidence and enforcement separately.** A structural pass, static review,
  actual test execution and a protected merge gate prove different things. Record
  the checked revision/environment and unresolved coverage; a missing tool, denied
  access or timeout is not a pass. Use the review evidence contract in
  `references/skill-integration-map.md` when integrating review or eval results.
- **Bound delegated work.** Use focused specialists for independent risks within
  one task budget. Delegation cannot broaden permissions or count as a human's
  approval. Reuse valid evidence for the same revision/property; rerun affected
  checks when either changes.
- **Does not own learning.** Session retrospection, outcome review, and constitutional audits are delegated to `retro-skill`. The harness verifies integration points exist (AH-22, AH-23) but does not invoke retro at runtime.

## Maturity Levels

**Level 1 -- Basic:** AGENTS.md exists, is an index, documents commands.

**Level 2 -- Verified:** CI enforces harness integrity, AGENTS.md references resolve, commands match Makefile/scripts, ARCHITECTURE.md exists.

**Level 3 -- Enforced:** Branch protection requires harness CI, git hooks auto-activate, PR template includes checklist, drift detection on push.

See `references/maturity-levels.md` for the full breakdown.

## References

- `references/maturity-levels.md` -- Maturity criteria and progression
- `references/harness-engineering-overview.md` -- Theory: four functions, patterns
- `references/agent-first-architecture.md` -- Legibility, layered deps, agent-first tech
- `references/enforcement-mechanisms.md` -- 12-mechanism table (CI, hooks, protection, drift, shipped checkpoints)
- `references/skill-integration-map.md` -- Skill routing map + integration contracts with companion skills

Files in this skill

  • SKILL.md4.1 KB
  • checkpoints.yaml11.6 KB
  • references/adr/001-verify-first-design.md2.3 KB
  • references/adr/002-enforcement-layers.md3.3 KB
  • references/adr/003-skill-delegation-model.md3 KB
  • references/adr/004-agents-md-as-index.md3.2 KB
  • references/adr/005-checkpoint-maturity-model.md3.4 KB
  • references/agent-first-architecture.md4.6 KB
  • references/enforcement-mechanisms.md34.4 KB
  • references/harness-engineering-overview.md10.1 KB
  • references/maturity-levels.md17.3 KB
  • references/skill-integration-map.md14.9 KB
  • scripts/verify-harness.sh24.5 KB
  • templates/AGENTS.md.tmpl1.2 KB
  • templates/ARCHITECTURE.md.tmpl918 B
  • templates/Makefile.harness.tmpl410 B
  • templates/envrc.tmpl426 B
  • templates/exec-plan.md.tmpl708 B
  • templates/forgejo-harness-verify.yml.tmpl992 B
  • templates/gitlab-ci-harness-verify.yml.tmpl444 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.