Skip to content
Back to skills

Taskproof Dispatch

ASecurity

Use when a main agent dispatches coding cards to worker agents through taskproof and must follow the dispatch discipline — register projects and their lanes, write cards from the template, fire them in parallel by default, read status and logs, kill by PID, and review the machine's acceptance evidence instead of re-running it or trusting the worker.

  • 3 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added November 7, 2026
developmentpythonrustgoshellbashsqlvuenodedebugginggit

Works with

  • terminal
  • cli
  • api

Security analysis

A100/100

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

Scanned November 7, 2026

npx -y skills add HaoHaoP/taskproof --skill taskproof-dispatch --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Taskproof Dispatch?

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

Security grade badge for Taskproof Dispatch
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/haohaop-taskproof-dispatch/badge)](https://www.skillsdirectory.com/skills/haohaop-taskproof-dispatch)

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
---
name: taskproof-dispatch
description: Use when a main agent dispatches coding cards to worker agents through taskproof and must follow the dispatch discipline — register projects and their lanes, write cards from the template, fire them in parallel by default, read status and logs, kill by PID, and review the machine's acceptance evidence instead of re-running it or trusting the worker.
---

# Dispatch work with taskproof

`taskproof` does not decide *what* to do; it only guarantees that work it dispatched is **independently verified** and **recorded**.
This skill is the operating manual for the **main agent** (the one that dispatches): one card at a time, every card carries a root cause and acceptance criteria, and after firing you review the evidence — the machine's acceptance result plus the dimensions it cannot see — instead of repeating the machine's work or trusting the worker's self-report.

Commands are always a single copy-pasteable line. Example paths are always written `/absolute/path/to/repo`.

## 0. Iron rules

1. One card does one thing; the card body must name the root cause as **file:line**, never "go find it yourself".
2. Put the acceptance command in the card body, and keep it consistent with `verify` in the registry.
3. The worker only implements and **does not commit**; `git add` / commit / push are the main agent's job.
4. Lanes in the same group are serial, different groups are parallel — the criteria are in section 6; everything else is **parallel by default**.
5. **Kill by PID**, never `pkill -f` (section 7).
6. For UI verification use only a one-off profile under `/tmp` plus a one-off workspace; **never write to the real registry** (section 8).
7. The worker's self-report is still not a conclusion — but **the machine's acceptance result is one**. taskproof runs the registered command after the agent exits (step ⑦) and writes the outcome to the ledger, so re-running it by reflex is duplicate work: do it only for the three exceptions in section 9. What you self-assert is what the machine cannot see — real runtime state, the scope of the diff, whether a delete kept what should have survived; **but real runtime state has a ceiling**: one command, one number, and a probe that needs exploring is folded into the card first ([`references/token-discipline.md`](references/token-discipline.md), section 1).
8. **Never paraphrase source material into a card.** A prototype, a spec, a design doc goes in by absolute path + line range with one line telling the worker to read it itself. A card that restates the operator's material loses precision, and you pay for it twice.
9. **One closure rework is free.** Acceptance went red → find the root cause → one more card on that same root cause. Everything else you notice goes into the backlog, not into a new card; any other card needs the operator's nod (section 9).
10. A card that adds behaviour or fixes a bug **names one test per root cause** in its acceptance command, and the worker's delivery pastes the failing run it saw first (section 9).
11. **Downgrade the model only where the card is enumerable and machine-checkable** (`--reasoning none`, a cheap model); a card on a local model also needs its own exclusive `group`.

Rules 7–11 are the dispatch-economy rules — the judgement tables behind them are in [`references/token-discipline.md`](references/token-discipline.md).

12. **A card whose result a human will look at carries a reference, not a description.** It declares exactly one reference header — `口径:` (the reference is a **store** you owe a write-back to) or `参照物:` (an immutable source: prototype, existing implementation, circled screenshot) — and the checks that apply to that kind run before it fires. Any one failing means **do not fire** (section 2.1).
13. **The store is the only source of visual content.** A card names paths and line ranges; colours, sizes, visibility rules and copy live in the store. When the operator changes their mind, the store is written first — a card that contradicts the store is a card defect.
14. **Same region, three consecutive cards rejected as "the previous card's output" → stop firing and build a comparison page** (section 2.1).

The visual-card rules (12–14) are in [`references/visual-cards.md`](references/visual-cards.md) — the four kinds of reference, the status truth table, the red-to-green probe, the comparison page and the convergence budget.

## 0.1 This repository is public

Anything written here is world-readable, and stays that way. Three rules:

- **Examples are neutral placeholders.** `header-buttons`, `prototype.html:1710-1735`, `release-1.2:src/views/index/params/index.vue:1-11`, `/absolute/path/…`. Never a real project name, repository directory, branch, feature name, hostname, person, or home directory.
- **Never paraphrase a job into the manual.** An example that reads naturally here is an example that came from somewhere. Wording and header names adapt to whatever you are working on; the manual must not carry it back.
- **`tools/scan_assets.py` is a backstop, not a proof.** Its organisation-specific words live *outside* the repository (`~/.taskproof/asset-patterns.txt`) and a clean run reports only that *those* words are absent. It cannot tell you nothing leaked; it tells you the listed words are not there. Add the words you actually use as you meet them, and never let a green check stand in for the rule.

This covers commit messages and file names as well as file bodies — a message is world-readable the moment it is pushed, and it is the part nobody re-reads before pushing.

## 1. Register a project and its taskgroups

```bash
taskproof init
taskproof register /absolute/path/to/repo                     # a lane that stands alone
taskproof register /absolute/path/to/repo --project my-repo   # attach a lane to an existing project
taskproof register /absolute/path/to/repo --id my-lane --project my-repo
taskproof --json register /absolute/path/to/repo --dry-run
```

The registry has **two layers**, and `register` writes the lower one:

- **`[[project]]`** — a *place*: `id`, `path` (its default), `aliases`. It is what the board filters by and shows as a row. Optional; a lane that names no project stands up a same-named one.
- **`[[taskgroup]]`** — a **lane**: `id`, `project`, `path`, `aliases`, `verify`, `verify_kind`, `forbidden_paths`, `result_schema`. This is what you dispatch into, and its `group` is the concurrency lock.

`register` appends a `[[taskgroup]]` (`--project` attaches it to a declared project; without the flag the lane stands alone). `--dry-run` probes only and writes nothing; `--json` is a root-level switch and must come **before** the subcommand. The registry defaults to `~/.taskproof/projects.toml`; `--workspace <dir>` points it elsewhere.

A file written in the old one-block-per-lane shape keeps working untouched: a `[[project]]` carrying any lane field (`verify`, `verify_kind`, `forbidden_paths`, `result_schema`) reads as a same-named project **plus** a same-named lane, keeping its own `group` as the lock.

Fields are defined by `docs/REGISTRY.md`; the ones that matter at dispatch time:

| Field (on the lane) | Required | Default | Notes |
|---|---|---|---|
| `id` | yes | — | Unique among lanes; a duplicate is a hard error |
| `project` | no | its own `id` | Must name a declared project, or be omitted entirely |
| `path` | no | the project's `path` | Must be an absolute path |
| `group` | no | its own `id` | The concurrency lock — see section 6 |
| `aliases` | no | `[]` | Aliases, accepted wherever an id is accepted |
| `verify` | no | — | Acceptance command, run by taskproof after the agent exits |
| `verify_kind` | no | `"none"` | `check` / `build` / `none` |
| `forbidden_paths` | no | `[]` | Prefixes the agent must not touch; a trailing `/` covers the whole directory tree |
| `result_schema` | no | `"default"` | `default` / `none` / an absolute path to a JSON Schema |
| `workspace` | no | `"none"` | `none` / `worktree` — see "a lane owns a checkout" below |
| `link` | no | `[]` | Dependency paths (workspace-relative) symlinked from the main checkout |
| `branch` | no | — | The branch this lane belongs on. **Declaring it is a pre-dispatch gate:** a `workspace = "none"` lane is refused unless the tree is checked out ON that branch (a detached `HEAD` counts as `HEAD` and is refused), a `worktree` lane builds its checkout from that branch — otherwise exit `78`, no ledger row, no slot. Not declaring it is no gate at all |
| `timeout` | no | `[defaults] timeout` | Wall-clock seconds for one card; the chain is `--timeout` > lane > `[defaults]` > built-in 1800 |
| `idle_timeout` | no | `0` | No-progress watchdog in seconds, `0` = off; both log bytes and the tree fingerprint must fall silent |

Semantics to remember:

- `taskproof projects` lists projects with their lanes; `taskproof taskgroups` lists lanes with their project. A **project id resolves to a lane only when the project has exactly one**; with several lanes, name the lane (or use `?project=` on the API, which accepts either).
- `group` is a **serialisation key, not a label**. One task per lock runs at a time; different locks run in parallel up to `[defaults] concurrency`. It defaults to the lane's own id, so two lanes only serialise when they **name the same value** — that is how a Python lane and a desktop lane over one working tree are kept out of each other's way.
- A missing `verify` is not "passed", it is **SKIPPED**.
- `forbidden_paths` is checked after the run, and does not rest on `git status` alone — `.git/` and ignored build output count too; touching them fails the task.
- The gate ignores Python byte-code (`__pycache__` segments, `.pyc` / `.pyo`) because it is a byproduct of running the tool, not authored work — but that is not a licence to litter. **When you run Python inside a card's worktree, use `python3 -B` (or `export PYTHONDONTWRITEBYTECODE=1`)**, or build data with the main-tree / installed package instead of importing from the worktree. Belt and suspenders, not a replacement for the gate.
- A type prefix is not an exception: `presence:` adds a *weaker* observation for its own rule and never cancels a `file` or directory rule that also covers the path. In particular `presence:t/__pycache__/` does **not** exempt byte-code from a `t/` rule.
- One repository owning several lanes is the normal shape (one per stack or per working copy); that is what the project layer exists for.
- **A lane owns a checkout.** `workspace = "worktree"` gives the lane one long-lived git worktree beside the repository (`<repo>-ws-<lane>`), created lazily the first time a card actually fires into it and **reused by every card after**; the run directory is the lane's own place inside it, so a lane pointing at a subdirectory runs in that subdirectory. `link = ["web/node_modules", …]` symlinks dependencies from the main checkout into it (without it the usual markers are probed: `package.json` -> `node_modules`, `Cargo.toml` -> `target`; a Python venv is deliberately never inferred — its config and console scripts hard-code absolute paths). The default is `none` on purpose: a verify command that `cd`s to an absolute main-tree path would silently accept the *main tree* from inside a workspace. `taskproof workspaces` lists these; `taskproof workspace-rm <lane>` prints the evidence (uncommitted changes, unmerged commits) and refuses to delete one that still holds work unless `--force`. `--worktree` keeps its one-off meaning; when a lane has a workspace, that one wins.
- The `.git` rule reads `refs/heads/*` **minus the branches another worktree has checked out**: a commit in a sibling checkout is not this card's doing. The card's own HEAD and branch, new branches and tags, `refs/remotes/*` and the stash are still caught.

## 2. Write the card to a file

The card body lives in a file and is passed with `$(cat ...)` at fire time — this avoids shell escaping and keeps the card reusable and archivable.

### 2.1 A card whose result a human will look at

A **visual card** — layout, colour, size, position, visibility, copy — carries three things a logic card does not, because the ordinary acceptance command cannot see a look and will happily rubber-stamp sixteen rejections:

**One reference header.** `口径: <store path>#<anchor>` when the reference is a **store** — a file you owe a write-back to — and then `region:` is required too: the convergence-budget slug for one file plus one visual area. Or `参照物: <prototype or existing implementation>:<lines>` when the reference is an **immutable source**. A store is not an entry requirement — a project that has none still fires visual cards on prototype line ranges.

**The checks that apply, any one failing = do not fire.** For a store reference: the file exists, the anchor resolves to what the card claims, it has been written **since this region's previous card**, and its directory is **clean in git**. For an immutable reference only the first two apply — the other two are reported **n/a, not passed**, because a prototype does not change and nobody owes it a write-back. The staleness check is the point: a store that stopped being maintained is worse than no store, because cards stop citing it and start describing symptoms again. The git check catches the other writer: once a second session is working the same feature the store has more than one writer, and mtime cannot tell "I forgot to write back" from "someone else just wrote it" — only a committed state can.

**A reference, one per card.** Exactly four kinds count: a prototype line range, an existing implementation's line range, a signed-off comparison page, or a screenshot the operator circled plus its measured values. The operator's words are not a reference. Where a card would cite several sources that disagree, reconcile them **before** writing the card, write the resolution into the store, and let the card cite one.

Plus a **status truth table** (rows = every state that can exist, columns = elements, cells = shown/hidden/position + the `file:line` that decides it) and a **red-to-green probe** (one assertion, real browser, red before the fix). Anything that cannot be moved to the machine side is written down as "human eye", explicitly.

When no reference can be named, or the operator answers "like X" / "hard to say" / "your call", or this region already had a card rejected — the next action is **not a card**: build a hand-made comparison page for the whole region, get it circled, and put it in the store.

Full detail: [`references/visual-cards.md`](references/visual-cards.md). The checks run mechanically: `python3 tools/check-card.py <card.md>` — exit `0` fire, `1` do not fire, `2` unreadable card.

````bash
mkdir -p /tmp/cards
cat > /tmp/cards/tp-card19.md <<'CARD'
# TP-card19 · 一句话说明这张卡做什么

## 根因
- `src/taskproof/cli.py:88` 在 X 情况下返回了错误的退出码。

## 要做的事
- 只改 `src/taskproof/cli.py`,修掉上面这一处。

## 验收
```bash
cd /absolute/path/to/repo && python -m pytest -q
```

## 硬约束
- 只改上面点名的文件;不 `git add` / commit / push。

## 交付
- 改动文件清单 + 验收命令的真实输出。
CARD
````

**Start from the template.** `templates/card.md` (English) or `templates/card.zh-CN.md` (the one actually used here) — copy it and fill every section; an empty section is a card defect, not a style choice.

**Source material goes in by path, never by paraphrase.** When the operator handed you a prototype, a screenshot, a design doc or a spec, the card carries its absolute path plus the exact line range and one line saying *read it yourself, do not ask me to restate it* — the shape is in [`references/token-discipline.md`](references/token-discipline.md) section 2. The codex adapter runs with `--sandbox workspace-write`, which restricts **writes**, not reads: the worker can open anything you can name. Restating the spec from memory is exactly where precision dies, and it costs tokens on both ends.

### 2.2 Acceptance must run inside the worker's sandbox

`--sandbox workspace-write` restricts **where it may write**. Three kinds of acceptance therefore do not belong in a card — not because they are hard, but because the worker physically cannot do them: the card ends on a blocker, or records `done` and leaves the work to a human.

- **Writing outside the checkout.** The sandbox refuses with `writing outside of the project` / `Operation not permitted`. Any self-check script that must land on disk goes inside the workspace or the repository (`/tmp` is fine; the main tree and sibling repositories are not). In one 14-day window, 10 of 131 parsable cards died here.
- **A browser or a renderer as acceptance.** The sandbox blocks Chrome's Mach ports; the worker gets `SIGABRT`, then either spins to the timeout or gives up (6/131). Real-browser and DOM measurement is the main agent's **batch review step** (section 9), never a card's acceptance.
- **Acceptance that can only go green by breaking the card.** "Write these tests, do not touch the source" is a card defect, not strictness: the test is red, so the worker either stops or breaks the rule (5/131). Either change the source in the same card, or fire the source card first.

The consequence matters more than the failures: of those cards only **3 ended `failed`; 31 recorded `done`** anyway. `done` does not mean nobody has to look — a green ledger only says that one command was green.

All three have a machine check now: `python3 tools/check-card.py <card>.md --lane <lane id>` — 查5 write scope (n/a, not a failure, when `--lane` is absent), 查6 browser, 查7 contract (a `[WARN]` only, never a changed exit code: a card whose subject *is* the test is legitimate). Exit `0` fire, `1` do not fire, `2` unreadable card.

## 3. Look at in-flight state before firing

```bash
taskproof tasks --all
taskproof --json tasks --all
```

`tasks --all` ignores the cwd scope and lists every lane; `--json` is for machines. Before firing, check how many are running; if you are within the concurrency cap, send the independent work out together.

The `tasks` table is ordered `ID / STATUS / DISPO / ...`. **DISPO** is the human-review answer — whether this card still needs a person — while `STATUS` says how far the run got. Its values are `disputed` (卡边界有争议), `awaiting_review` (待批), `blocked` (受阻等人), `failed` (需人看一眼), `settled` (已了结), and `unknown` (未知). Filter with `--dispo <value>` using either the English value or the Chinese label. Old rows are not backfilled; a missing disposition renders as `—`.

Then spend 30 seconds blocking three kinds of wasted run (in one 14-day window 14 of 319 cards changed nothing, and another batch had to be re-fired as "v2, fix card"):

- **Does the target file exist?** Look for every file the card names, **in the lane's workspace**. A workspace parked on an old commit does not contain it: the worker either rebuilds the file from scratch or stops — both are wasted. Write "if a named file does not exist, stop and report" into the card as well.
- **Is the baseline aligned?** `git -C <workspace> log -1 --format=%H` must equal `git -C <main tree> rev-parse <branch>`. If not, reset with `workspace-rm --force` first (the evidence procedure is in the ops card); the next card rebuilds lazily at the current HEAD.
- **Was the previous card merged?** Merging is the main agent's job. Miss it once and the next card's `git diff` carries the previous one along, so `git apply` inserts it twice.

## 4. Fire

```bash
taskproof run my-lane --adapter codex --timeout 1800 "$(cat /tmp/cards/tp-card19.md)"
```

- `--adapter`: `codex` / `claude` / `gemini` / `opencode` / `custom:<cmd>`.
- `--timeout`: seconds; the chain is `--timeout` > the lane's `timeout` > `[defaults] timeout` > built-in 1800.
- `--idle-timeout`: seconds; the no-progress watchdog, alive only while **both** log bytes and the tree fingerprint fall silent, `0` = off. Raise it whenever you raise the wall clock, or the watchdog fires first.
- `--reasoning none`: turn the worker's reasoning off, and `--model <m>` swap the model — only for cards that are enumerable and machine-checkable (rule 11, section 9).
- `--cap N`: a one-off global cap for this dispatch only.
- `--worktree`: a fresh checkout beside the repository, kept when it has changes. A *one-off*: a lane that declares `workspace = "worktree"` has a long-lived checkout instead, and that one wins.
- Card in a file, passed with `$(cat ...)`: saves escaping, and makes backup and re-runs easy.

**There is no parked state.** `run` starts the card there and then. If the cap is full it exits **75** and records nothing: wait and retry, raise the cap for this dispatch (`--cap N`), or persist a new one (`config --concurrency N`).

An unforced second `run` of the same card exits **76** and adds no task row. "The same card" is the fingerprint of lane + branch + card text, not the filename. To dispatch it again, add `--force`: the new row keeps `dispatch_key` as `NULL` and its `started` event records `duplicate_of`. To rerun a terminal card under a fresh mandate and the lane's current settings, use `rerun <id>`; the ledger links the pair both ways with `rerun_of` / `rerun_as`.

## 4.1 Acceptance is frozen at dispatch

`run` snapshots the lane's acceptance command, branch, adapter, forbidden paths, timeouts, and issue time into `tasks.mandate` (12 keys: `card_sha256`, `lane`, `branch`, `verify`, `verify_kind`, `forbidden_paths`, `adapter`, `model`, `reasoning`, `timeout`, `idle_timeout`, `issued_at`). Acceptance follows that snapshot by default.

Changing the lane's `verify` after dispatch **does not** move the finish line for a card already in flight: the card is accepted against the value captured when it was fired. If the registry's current value differs, taskproof records a `mandate_drift` event and still follows the mandate.

To make an old card use the registry's **current** acceptance value, run `taskproof verify <id> --current`.

This boundary is deliberate: acceptance criteria may change before dispatch, but never after it. Otherwise two runs of the same card could be judged by different finish lines and their results would not be comparable.

## 5. Check status and read logs

```bash
taskproof tasks --all
taskproof tasks --all --lane my-lane      # one lane's cards, with their verdict
taskproof --json tasks --all
taskproof show <task-id>                  # ends with the `changes:` block
taskproof wait <task-id>                  # block until the verdict, then print it
taskproof log <task-id>
taskproof log <task-id> --follow
taskproof verify <task-id>
taskproof workspaces
taskproof workspace-rm my-lane            # prints the evidence, refuses unless clean
taskproof workspace-rm my-lane --force
```

`log` prints the task's full event stream; `--follow` follows it all the way to the terminal state.

`tasks --lane <id>` narrows to one lane, `--id <id,id>` picks rows out by id, and `--dispo <value>` filters the human-review dimension. `DISPO` sits immediately after `STATUS`: the latter is the machine's progress, the former is whether a person still has to act. The table also carries the verdict: `VERIFY` reads `exit=N`, `?` when no exit was recorded, and an en dash when acceptance never ran (`SKIPPED`) — a skipped check must never look like a pass. `FILES` is the changed-file count. Rows from before DISPO existed are not backfilled and display `—`.

`wait <id>` polls the ledger until the card is terminal, and **it is the whole replacement for a hand-rolled `while …; do <read the ledger>; sleep N; done` loop**: exits `0` for `done`, `1` for any other terminal state, `124` when the wait itself gives up (the task is never touched). `show <id>` ends with a `changes:` block listing the paths this run left dirty, marking the ones that were **already dirty before the run** with `[跑前已脏]` — that is the part of `files_changed` which is not this card's doing. Between `tasks`, `show`, `log` and `--json`, reading the ledger with `sqlite3` is never necessary.

`verifying` is a **real, persisted state**: while the acceptance command runs, the card is written as `verifying`, so a long build or test suite is visible on the board instead of hiding inside `running`. A card sitting there is not stuck — it is being accepted.

`verify <id>` re-runs the registered acceptance command for an existing task and appends a `verify` event. That is the main agent's review step (section 9): it records the re-run as a fact instead of asserting one.

`workspaces` lists the lanes that declared one, with its path and what is still in it. `workspace-rm` prints the evidence (uncommitted changes, unmerged commits, the worktree unregistration) and deletes only a workspace that holds no work — `--force` overrides and says so in its output. Deleting a lane's checkout is never a side effect of anything else: `rm <id>` deletes the task (and the one-off checkout that task itself left), never a lane's workspace.

## 5.1 Human sign-off: `accept`

`accept <id>` is how a human closes a card the pipeline stopped on its own. It is a **registration, not a verdict**.

- It never re-runs acceptance and never rewrites `verify_*`: the acceptance result stays authoritative and the registration rides alongside it.
- `blocked` (a forbidden-path breach): `accept <id>` clears it, note optional — green acceptance -> `done`, red or skipped -> `failed`.
- `failed` (acceptance went red, or the adapter failed): `accept <id> --note "…"` clears it to `done`, but the note is **required** — an empty or missing note is refused (CLI `rc != 0`, HTTP `400`). The note records *why* the failure was judged a false red; it is not a substitute for the run's own `verify_*`.
- `done` / `timeout` / `cancelled` and every non-terminal state are refused.

## 6. Parallel scheduling: parallel by default

**Parallel is the default — do not serialise out of habit.** Before firing:

1. Look at `group` first: **lanes with different locks should be fired at the same time**. Giving one project several lanes exists for exactly this — as long as the file ranges do not overlap, dispatching them together is safe and is the main lever for cutting total time.
2. The **global cap** is workspace-level and is always shown together with its **effective value and where it comes from** — `auto` (machine-detected), `toml` (`[defaults] concurrency`), or `cli` (a one-off `run --cap N`). Ask with `taskproof config --show` (or `taskproof doctor`) instead of assuming a number: a fresh workspace carries no key and auto-detects `clamp(2, cores // 4, 6)`, or 2 when RAM < 8 GB. Count how many are running with `taskproof tasks --all` first; if you are within the cap, fire the independent work together, and do not blindly fire until the slots are full. Change the persisted value with `taskproof config --concurrency N` (comment-preserving, non-retroactive); raise it for a single dispatch with `run --cap N`.
3. **Fire now; ordering is yours.** Nothing parks a card and no daemon pushes a queue — the sequence of cards is the main agent's decision, which is also what keeps the per-card commit boundary. A refused dispatch (exit 75, same lock busy or cap full) leaves no trace in the ledger: wait for the lane to drain and fire again.
4. The only legitimate way to run within one lane in parallel: add another **lane** (its own `path`), give it a different `group`, and let it declare `workspace = "worktree"` so it has a checkout of its own (`--worktree` still works for a one-off); do this **only for cards whose file ranges do not overlap** — the main agent merges both diffs back into the main tree afterwards in one batch.
5. Therefore **there is exactly one criterion for serialising: the same lock and overlapping file ranges**. Every other case should run in parallel.
6. Batch the main agent's own rhythm too: collect reviews and commits and do them together; do not let "wait for me to commit" become the metronome for the whole chain.

## 7. Killing processes: by PID

```bash
taskproof --json tasks --all      # find the task's pid
kill <pid>
```

**Never `pkill -f`.** The card body is passed to `taskproof run` as argv, so any string that appears in the card (for example `--remote-debugging-port=9333`) is on the firing process's own command line, and `pkill -f` kills the fire along with it — the symptom is exit -15, no task created, an empty log.

## 8. UI verification: a one-off profile + a one-off workspace

A dispatched UI card must be verified in a one-off environment that writes state to `/tmp`, never to the real registry:

```bash
taskproof --workspace /tmp/tp-verify-$$ init
taskproof --workspace /tmp/tp-verify-$$ register /absolute/path/to/repo --id verify-repo --project verify-repo
```

**Never write `~/.taskproof/projects.toml`.** A real delete/change test destroys the user's registry entries — in this development a worker once ran a delete test against the real registry and removed one of the user's projects. (The registry is the operator's file; when it *is* the task, back it up first and show the diff.)

**The local REST API is read-only and the desktop console is a viewer.** `taskproof api` serves reads only — there is no `--allow-write`, no session token and no write endpoint (a write-shaped request is a plain 404). Dispatching, stopping, accepting and deleting all live in the CLI, so a card that changes the console is verified by reading what it renders, not by driving writes through it.

## 9. Main agent review: check the evidence, do not re-do the work

A worker reporting done is not evidence — and neither is your own second run of a command the machine already ran. Spend your assertions on what the machine cannot see:

- [ ] **Read the acceptance result and its events**: `taskproof show <id>` / `taskproof log <id>` — the lane's command really ran (the recorded `verify_cmd` is not `SKIPPED`), `verify_exit == 0`, `PASSED`, and a step ⑦ event next to it.
- [ ] **Re-run acceptance (`taskproof verify <id>`) in exactly three cases**: it was **SKIPPED** (no lane `verify`, or the card was fired with `--no-verify`); the command **covers less** than the card demands (assert the missing dimension yourself — one command, one number); or **green smells false** (a check that cannot fail, e.g. `eslint` over an `.eslintignore`d path, a test that only matches source text, a build that emitted nothing).
- [ ] **Assert what the machine cannot see**: a real window → read the DOM (a debugging port plus CDP beats a screenshot); a real file → `ls -l` or a byte/size comparison; a delete → what should have survived is still there; a running server → the bytes come from the tree the card changed.
- [ ] **Read the diff for scope** — line by line, instead of re-running the suite.
- [ ] `git add` **only the files this card names**; do not wrap unrelated changes in. Confirm the worker did not commit (commits are the main agent's job).
- [ ] Batch reviews and commits; do not turn them into a synchronisation point per task.
- [ ] If the card changed something the *operator* will read day to day (a registry layout, a CLI surface, this skill), re-read that surface before you commit it.

A **red** result is the one thing that earns a second look by default: re-run it 2–3 times in the same tree before calling it a defect (a machine running several lanes makes polling tests flaky), then decide.

The three habits this checklist leans on without repeating — closure rework is free once and nothing else is free, behaviour cards name a test, a cheap model only for enumerable cards — are iron rules 9–11. The judgement tables behind them (the false-green catalogue, the backlog format, which cards qualify for a cheap model, docs folded into the feature card) are in [`references/token-discipline.md`](references/token-discipline.md); read it once before you write a card.

## 10. References

- Registry fields and hard errors: [`docs/REGISTRY.md`](../../docs/REGISTRY.md)
- Design decisions: [`docs/DESIGN.md`](../../docs/DESIGN.md)
- A full from-zero-to-one-dispatch walkthrough: [`docs/WALKTHROUGH.md`](../../docs/WALKTHROUGH.md)
- Dispatch economy — review, source material, TDD, closure/backlog, model downgrade: [`references/token-discipline.md`](references/token-discipline.md)
- Visual cards — references, status truth table, red-to-green probe, comparison page, convergence budget: [`references/visual-cards.md`](references/visual-cards.md)
- Card templates to copy: [`templates/card.md`](templates/card.md) (English) / [`templates/card.zh-CN.md`](templates/card.zh-CN.md) (简体中文)
- Exit codes: 0 success / 2 registry problem / 64 usage error / 70 adapter failure / 71 verification failure / 75 concurrency limit / 76 duplicate card

Files in this skill

  • SKILL.md32.3 KB
  • SKILL.zh-CN.md29.1 KB
  • references/token-discipline.md11.9 KB
  • references/token-discipline.zh-CN.md10.9 KB
  • references/visual-cards.md10.6 KB
  • references/visual-cards.zh-CN.md9.6 KB
  • templates/card.md4.6 KB
  • templates/card.zh-CN.md4.4 KB

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 development →

Comments

Loading comments…

Newsletter

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