toolhq.io

skills / agent architecture

verify-before-done

Never report work as finished without evidence, and say plainly what was not checked instead of implying it was.

SKILL.md

Save as .claude/skills/verify-before-done/SKILL.md in a repository, or under ~/.claude/skills/verify-before-done/SKILL.md to have it everywhere. The copy button takes the whole file, frontmatter included.

---
name: verify-before-done
description: Check that finished work actually behaves as asked, and report the evidence along with anything left unchecked. Use when about to say a task, fix or feature is complete, when asked to confirm that something works, or before handing work back for review.
---

# Verify before done

"Done" is a claim about behaviour, and a claim needs evidence. Your job here
is to produce that evidence, or to say plainly that you could not.

## Levels of evidence

From weakest to strongest. Know which one you have reached.

1. **Written** — the code exists. This proves nothing.
2. **Compiles** — type check, lint and build pass. The code is well formed. It
   may still do the wrong thing.
3. **Tests pass** — the behaviour the tests cover is right, and only that.
4. **Observed** — you ran the real thing and saw the behaviour that was asked
   for.

The request was almost always for level 4. Reporting level 2 as "done" is the
most common false claim, because a green build feels like success.

## Order of work

1. Restate the request as something observable. Not "fix the login bug" but
   "submitting valid credentials lands on the dashboard".
2. Run the thing. Do not reason about running it. Reading the code and
   concluding that it would work is a prediction, not a result.
3. Exercise the real path: the actual endpoint, page or command, with real
   arguments, including one input that should fail.
4. Check what you may have broken. Run the full suite and the build, not only
   the test you added.
5. Read your own diff once more for debug lines, stray files and changes you
   did not intend.
6. Record the exact command and its real output as you go, not afterwards.

## A test you did not watch fail

A passing test proves little until you have seen it fail for the right reason.
Remove the fix, run the test, confirm it fails on the assertion that names the
behaviour, then restore the fix.

The traps this catches: a test file the runner never collected, a test marked
as skipped, an assertion that checks a mock rather than the code, and a runner
that reports zero tests as a pass. Always read the count of tests that ran.

## What not to do

- **Do not describe an expected output as if it were observed.** "This returns
  200" means you saw 200. If you did not, write "should return 200" and mark
  it unverified.
- **Do not paste output from memory or tidy it up.** Copy the real text. If
  you trim it, mark where.
- **Do not imply full coverage.** Checking one case and writing "tested" lets
  the reader assume the rest.
- **Do not weaken a check to make it pass.** Deleting a failing test, skipping
  it, loosening an assertion or swallowing an error is hiding a failure.
- **Do not treat silence as success.** Check the exit code, and check that the
  command did something at all.
- **Do not stop at the first green result.** One passing run after several
  failures deserves a second run.

## When verification is impossible

Sometimes it is: no credentials, no device, a dependency that only exists in
production, a job that runs once a month. Then say that verification was
impossible and why, describe the check that would settle it, and name who can
run it. Never quietly report success in its place.

Unverified is an acceptable result. Unverified reported as verified is not.

## Say how sure you are

- **Verified** — ran it and saw the behaviour. Command and output included.
- **Partly verified** — some paths observed. List which ones, and which not.
- **Unverified** — written and believed correct, not run. Say why.

Apply the label per claim, not once for the whole task. A fix can be verified
while its edge cases are not.

## Report back

1. What was asked, stated as an observable outcome.
2. Each check: the exact command and the real result.
3. What you did not check, and why.
4. The verdict: done, done with named gaps, or not done.

what it needs

Nothing. This skill is instructions only, so it works in any agent that reads SKILL.md with nothing installed and no account. Save the file and it is live in the next session.

the instructions, in full

Verify before done

"Done" is a claim about behaviour, and a claim needs evidence. Your job here is to produce that evidence, or to say plainly that you could not.

Levels of evidence

From weakest to strongest. Know which one you have reached.

  1. Written — the code exists. This proves nothing.
  2. Compiles — type check, lint and build pass. The code is well formed. It may still do the wrong thing.
  3. Tests pass — the behaviour the tests cover is right, and only that.
  4. Observed — you ran the real thing and saw the behaviour that was asked for.

The request was almost always for level 4. Reporting level 2 as "done" is the most common false claim, because a green build feels like success.

Order of work

  1. Restate the request as something observable. Not "fix the login bug" but "submitting valid credentials lands on the dashboard".
  2. Run the thing. Do not reason about running it. Reading the code and concluding that it would work is a prediction, not a result.
  3. Exercise the real path: the actual endpoint, page or command, with real arguments, including one input that should fail.
  4. Check what you may have broken. Run the full suite and the build, not only the test you added.
  5. Read your own diff once more for debug lines, stray files and changes you did not intend.
  6. Record the exact command and its real output as you go, not afterwards.

A test you did not watch fail

A passing test proves little until you have seen it fail for the right reason. Remove the fix, run the test, confirm it fails on the assertion that names the behaviour, then restore the fix.

The traps this catches: a test file the runner never collected, a test marked as skipped, an assertion that checks a mock rather than the code, and a runner that reports zero tests as a pass. Always read the count of tests that ran.

What not to do

When verification is impossible

Sometimes it is: no credentials, no device, a dependency that only exists in production, a job that runs once a month. Then say that verification was impossible and why, describe the check that would settle it, and name who can run it. Never quietly report success in its place.

Unverified is an acceptable result. Unverified reported as verified is not.

Say how sure you are

Apply the label per claim, not once for the whole task. A fix can be verified while its edge cases are not.

Report back

  1. What was asked, stated as an observable outcome.
  2. Each check: the exact command and the real result.
  3. What you did not check, and why.
  4. The verdict: done, done with named gaps, or not done.

credit

This skill covers ground first mapped by addyosmani/agent-skills, a widely used open collection of engineering skills. The instructions above are written from scratch for this library, in its own voice and with its own opinions, and nothing is copied. The thanks is for the idea.