validate

A command that checks a completed coding plan against its stated success criteria and reports pass or fail with file references.

In plain words
What is it for?
Use it after implementation, when rechecking an archived plan, or when a deliverable was edited afterward.
Why use it?
It shows whether the implementation meets the agreed requirements instead of relying on an informal review.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/keez97/phase-gate/validate
Clone the repo
git clone --depth 1 https://github.com/keez97/phase-gate
Per session 16 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,651 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00016 $0.01651
Opus 5 $0.00008 $0.00826
Sonnet 5 $0.00003 $0.00330
Haiku 4.5 $0.00002 $0.00165

Measured yesterday against content hash d34969193c86, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

validate scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/validate.md · 166 lines

How it starts

The opening of the file, as written. The whole thing — 166 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/validate — Plan Verification

Checks that the implementation actually meets the plan's success criteria. Run after /implement finishes, or as a re-check on an already-archived plan.

This is verification, not review. You are checking whether specific, stated criteria are met — not forming new opinions about quality.

When to skip. New plans authored with a verification.jsonl already had every row flipped at /implement's Phase-End Verification Gate. /validate here is for:

  • Legacy plans with markdown criteria only (no verification.jsonl).
  • Re-runs of an already-archived plan against its current verification.jsonl state.
  • Sanity passes when a deliverable was edited after /implement completed.

Step 1: Detect the Plan

Resolve the plan path:

  1. If passed as the command argument, use it.
  2. Otherwise, the most recent plan under plans/active/ (highest date).
  3. Read the full Success Criteria checklist from the plan.

If no plan exists: stop and say "No plan found. Run /plan first."

If the plan has no success criteria: stop and say "Plan has no success criteria. Add them to the plan before validating."


Step 2: Mechanical Verification Pass (when verification.jsonl exists)

Plans created with the verification spine carry a per-plan verification.jsonl with one row per atomic Success Criterion. When that file exists, the runner is canonical — prose judgment in Step 3 is replaced by the runner's flip log.

PLAN_DIR="$(dirname "$PLAN_PATH")"
if [[ -f "$PLAN_DIR/verification.jsonl" ]]; then
  bash "${CLAUDE_PLUGIN_ROOT}/scripts/verification-run.sh" "$PLAN_DIR"
  RUN_RC=$?
fi

Behavior:

  • Walks the latest-wins state of every row, runs each passes:false row's check_command, captures combined output to <plan-dir>/evidence/<id>.log, and flips the row via verification-flip.sh.
  • Distinguishes command not found (rc=127) from real check failures in stderr; both flip the row to passes:false-with-evidence so the audit trail records the failure mode.
  • Final summary line: verification: N/M verified, K failed, L skipped (phase=<filter>).
  • Idempotent — already-passing rows are reported but not re-executed.
  • Optional --phase=<phase-slug> flag scopes the run to a single phase.

Read the full file on GitHub · 166 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 166 lines · 16 tokens per session scan A d34969193c86

Subscribe to this mod's changes

validate is a command published in the GitHub repository keez97/phase-gate (1 stars, last pushed 3mo ago), licensed MIT. It adds 16 tokens to every session and 1,651 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.