harness-control
Skill0 starsChanged 3 months agoMITView on GitHub
Control an Agent Harness instance — start/pause/resume/cancel mock and real runs, issue or block approvals, and verify runs against the independent manifest verifier. Use when operating a harness, reviewing a run ledger, or debugging why a run ended FAILED/CANCELED/CRASHED.
2 other projects use a version of this.
Adopted by
Most recently taken up by
- Ai-assistant-KIRA/antigravity-harnesstheir own version, first seen Nov 8, 2026
- stump-wtf/claude-plugin-harnesstheir own version, first seen Nov 3, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 2
- Ai-assistant-KIRA/antigravity-harness★ 1same name
- stump-wtf/claude-plugin-harness★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 18
Start a mock run (no network, no key):
- Distinctive: line 57
If a run reads FAILED but the executor exit was 0, read the attempt verdict reason: the model claimed completion but the requirement …
- Very specific: line 65
Don't edit ledgers or run.json by hand — the verifier will (correctly) fail.
- Distinctive: line 66
Don't add a provider that holds a key in a fixture.
- Very specific: line 67
Don't run public-release-check.mjs on a dirty tree as a pass — a root .runs/dist is a blocker.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Harness Control
Operate runs in this repo's harness. Everything is public-safe: mock executor by default, no network, no keys.
Orientation
- Runs live under
<runsDir>; each run is<runsDir>/<runId>/run.jsonplus append-onlyevidence.jsonl. - The completion gate runs the independent verifier —
computeVerdict+verifyFingerprint. A run only reaches DONE on a verifier PASS, never on a model claim. - Ledgers are append-only. Re-running
verify-manifest.mjsmust reproduce the recorded verdict and fingerprint; a mismatch means tampering or a bug (see regressions below).
Do
- Start a mock run (no network, no key):
node -e "
import('@m2atrid/pis-harness-service').then(async ({ HarnessService }) => {
const s = new HarnessService({ runsDir: '.runs' });
const r = await s.start({ slug: 'demo', manifestSha256: 'a'.repeat(64), sessionId: 'x', argv: ['node','-e','true'], cwd: '.', requirements: [{ requirementId: 'r1', evaluator: 'output-includes', needle: 'fake-executor' }] });
const f = await s.runner.waitFor(r.runId);
console.log(r.runId, f.status);
});
"- Independently verify a finished run:
node scripts/verify-manifest.mjs .runs <runId>Expect recordedStatus === recomputedStatus and fingerprintMatch: true.
Approval flow
Closed state machine: RUNNING -> WAITING_APPROVAL -> QUEUED (approve, exactly one grant) | FAILED (reject).
approve parks the run in QUEUED (never silently resumes); the child was already terminated at the gate.
resume is the only grant consumer and takes no caller argv/cwd/env (server-side registry decides):
await service.requestApproval({ runId, scope: "approve:tool", prompt: "allow tool?" });
await service.approve({ runId, decidedBy: "ops" });
await service.resume({ runId }); // consumes the one-time grant, RUNNINGA second approve while a grant is outstanding throws; a grant is consumed at most once. reject closes the run FAILED. Run-record mutations are serialized per run (per-run lock in lock.mjs), so concurrent ops never lose updates.
Debugging terminal states
| status | meaning | next step |
| DONE | verifier PASS | done |
| FAILED | executor non-zero OR verifier not PASS | read attempt.release.notes |
| CRASHED | lease expired / owner died | runner.recoverCrashed() then resume |
| CANCELED | operator cancel | start a new run |
| WAITING_APPROVAL | gate for one-time approval | approve/reject |
If a run reads FAILED but the executor exit was 0, read the attempt verdict reason: the model claimed completion but the requirement evidence did not prove it. That's the gate working.
Regressions this repo has already caught
- Completion-gate evidence bug: the verifier computed a PASS verdict in memory but the evidence was never appended to the ledger;
verify-manifest.mjsreportedfingerprintMatch: false, recomputedStatus: FAIL. Fixed in 10.5 — evidence is persisted viaappendEvidencebefore the record is saved. Keep the regression test inpackages/harness-core/test/core.test.js("completion gate persists evidence so the independent verifier agrees").
Don't
- Don't edit ledgers or
run.jsonby hand — the verifier will (correctly) fail. - Don't add a provider that holds a key in a fixture. maskedProfile only.
- Don't run
public-release-check.mjson a dirty tree as a pass — a root.runs/distis a blocker.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

