harness-eval

Deterministic checks for the configuration that AI coding agents run with:
instruction files, skills, commands, hooks, MCP configs, agent definitions and
pipeline harnesses. It auto-detects the tools a repository uses (Claude Code,
Cursor, Copilot, Gemini CLI, Codex, OpenCode, Windsurf, Cline, fullsend),
builds one component graph across them, and runs 93 deterministic rules
against it. No LLM, no network, same answer every run.
Every rule declares what a finding means, and that is the only thing the
commands select on:
| Effect | Meaning | Example |
|---|
block | A defect. The configuration cannot do what it says. | a hook runs a script that does not exist; a frontmatter key is misspelt so the client ignores it; a secret file is committed |
policy | A fact that needs a trust decision. | permission prompts disabled; a wildcard Bash grant; a floating image: ...:latest |
signal | A heuristic match. A claim for a reader, not a verdict. | an injection phrase in a prompt; a taint path from $1 to eval |
advice | Quality. Nothing gates on it. | a vague description; redundant guidance; token budget |
Four commands
| Command | Asks | Runs | Exit code |
|---|
harness-autonomy | Can this change merge without a person? | block + policy rules that have passed the corpus. Never a heuristic. | 0 PASS, 1 FAIL, 2 REVIEW_REQUIRED, 64 usage error, 70 internal error |
harness-gate | Is the configuration broken? | block rules at gating tier (--include-provisional adds the rest) | 1 on any error or warning |
harness-security | What should a security reviewer read? | policy + signal rules, security block rules, YARA, optional OSV lookup and LLM review | 0 unless --fail-on-* |
harness-lint | How healthy is the setup? | advice rules plus system analysis (token budget, triggers, dependencies). --all runs every rule. | 0 unless --fail-on-* |
Plus harness-review (LLM rubric review; Gemini, Anthropic or any
OpenAI-compatible endpoint), rules (list and filter the catalog),
baseline and doctor.
Quick start
pip install harness-eval
harness-eval harness-autonomy . # the merge decision
harness-eval harness-security . # the security read
harness-eval harness-lint . # the quality report
harness-eval rules --effect block # what counts as a defect
harness-autonomy: my-repo
Verdict: REVIEW_REQUIRED
Policy (needs a decision) (1):
hooks/permission-prompt-disabled .claude/settings.json permissions.defaultMode is 'bypassPermissions' ...
Coverage:
components: 1 claude_md, 2 command, 1 hooks, 1 mcp_config, 3 skill
rules: 41 ran of 47 selected
not applicable (no agent component in the setup): agent/description-required, ...
Evidence:
fingerprint: 3f9c... revision: 7b1e2d... rules digest: a41c...
Also available as a GitHub Action, Tekton Task, Claude Code plugin, Cursor
commands and pre-commit hook.
New to harness-eval? The hands-on demo has example skills and
setups, some broken on purpose, to scan in five minutes.
Using it in an auto-merge policy (ADLC)
An agent-driven development lifecycle merges some changes without a human in
the loop. The policy that decides which ones needs evidence it can trust, and
a configuration check is one of three kinds of deterministic evidence it
should have:
| Evidence | Question | Who produces it |
|---|
| Repository preconditions | Does this repo have branch protection, required checks, CODEOWNERS? | the forge, checked once |
| Facts about the change | Is CI green on this exact SHA? Does the diff touch a protected path? Is a reviewer thread still open? | the CI system, every change |
| Configuration health | Does the agent configuration this change ships actually work, and did the change widen any trust boundary? | harness-autonomy, every change |
harness-autonomy is built to be that third input, and nothing more: