approve-direction

A command that records a person's approval of a workflow's direction, including its goal, acceptance criteria, and supporting evidence.

In plain words
What is it for?
Use it when the user has reviewed and approved the workflow direction. It is the sanctioned command for recording that approval.
Why use it?
It creates a formal approval checkpoint before the build proceeds, so the agreed direction is recorded.

Command for Claude Code

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/friedbotstudio/baseline/approve-direction
Clone the repo
git clone --depth 1 https://github.com/friedbotstudio/baseline

Made for: Claude Code.

Per session 79 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,052 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.00079 $0.01052
Opus 5 $0.00039 $0.00526
Sonnet 5 $0.00016 $0.00210
Haiku 4.5 $0.00008 $0.00105

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

Security

Grade A, and why

approve-direction 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.

.claude/commands/approve-direction.md · 30 lines

What it actually says

The user has reviewed and approved the DIRECTION of the workflow referenced by $ARGUMENTS — the problem, goal, and acceptance criteria in the intake, plus the CO-A evidence (demonstrated understanding + risk acceptance). Record approval. This single gate authorizes the whole build direction; the spec and implementation between here and the commit are machine-reviewed (spec-traceability, checker fan-out, shippability, drift-check, design-calls), never human-eyeballed.

How this works structurally: when the user typed /approve-direction <arg>, the consent_gate_grant UserPromptSubmit hook ran before this body was passed to Claude and wrote a short-lived consent marker at .claude/state/.direction_approval_grant whose slug is the bare slug derived from <arg>. The direction_approval_guard PreToolUse hook reads that marker on the approval-token Write and allows it when the marker is fresh and the approval filename's bare slug matches. Claude cannot forge the marker — that's what makes the gate structural.

State-write discipline (binding — see .claude/CONSTITUTION.md §2 "State-write discipline"). The approval token at .claude/state/spec_approvals/<slug>.approval is a Tier 1 consent artifact: it SHALL be written with the Write tool only. (The token path is spec_approvals/ for continuity — epic_approval_guard and track_guard derive their forge-proof root from it; D-2.) You SHALL NOT write it via Bash (no >/>> redirect, heredoc, tee, cp, or sed -i) — destructive_cmd_guard blocks Bash writes to consent paths, and the direction_approval_guard marker is validated only on the Write tool. Use Bash solely to compute the two scalar values below (date +%s, git log, and the content hash). Resolve and verify the intake path with the Read tool, never shell dirname/basename/[ -f ].

Steps:

  1. Derive the bare slug from $ARGUMENTS in-context (no shell needed): strip any directory prefix and a trailing .md. E.g. docs/intake/foo.mdfoo, foofoo. The same canonicalization runs inside consent_gate_grant, so the marker slug and the expected slug always agree.
  2. Resolve the intake path:
    • If $ARGUMENTS contains a /, treat it as a path (absolute or relative to repo root).
    • Otherwise the path is docs/intake/<slug>.md. Confirm the intake file exists by reading it with the Read tool. If the Read fails, stop and ask for the correct slug or path.
  3. Write the approval token with the Write tool to .claude/state/spec_approvals/<slug>.approval (the Write tool creates the parent directory). Contents:
    • Line 1: APPROVED
    • Line 2: epoch timestamp (run date +%s)
    • Line 3: absolute path to the intake file
    • Line 4: git short SHA of the intake file at this moment (if in a git repo; run git log -1 --format=%h -- "<resolved-path>", otherwise N/A)
    • Line 5: the intake content hashcomputeSpecContentHash of the intake bytes from .claude/hooks/lib/spec-content-hash.mjs (the hasher is content-agnostic; D-4). Compute it in Bash (read-only): node -e "import('./.claude/hooks/lib/spec-content-hash.mjs').then(m=>import('node:fs').then(fs=>console.log(m.computeSpecContentHash(fs.readFileSync('<resolved-path>')))))". This line lets the harness resume detect a post-approval intake amendment and re-yield.
  4. Confirm to the user: "Approved direction <slug>. Approval token written to .claude/state/spec_approvals/<slug>.approval. The spec and implementation now proceed under machine review; the next human gate is /grant-commit (approve-landing)."

Do NOT mark any spec or intake as "Approved" inside the markdown — the Direction Approval Guard hook blocks that. The approval token is the authoritative record.

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 · 30 lines · 79 tokens per session scan A 7744282e65b2

Subscribe to this mod's changes

approve-direction is a command published in the GitHub repository friedbotstudio/baseline (11 stars, last pushed 5d ago), licensed Apache-2.0. It adds 79 tokens to every session and 1,052 once invoked, about $0.0004 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-30.