feature-design

feature-design is a command for Claude Code from axiomantic/spellbook. It costs 11 tokens per session (3,792 once invoked), scanned A, original, MIT.

A command for creating and reviewing a software design document before implementation. It checks that the project has been understood and that required discovery work and review are complete.

In plain words
What is it for?
Use it to document a feature’s design, confirm its requirements are understood, and prepare it for implementation planning.
Why use it?
It prevents development from proceeding with missing context, unresolved questions, or an unreviewed design. Failed checks stop the workflow until the groundwork is complete.

Command for Claude Code

Written for Claude Code: a Claude Code command (commands/*.md). Also seen: reads .claude/ paths; mentions CLAUDE.md; mentions subagents.

Good fit Use it to document a feature’s design, confirm its requirements are understood, and prepare it for implementation planning.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/axiomantic/spellbook/feature-design
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.

Clone the repo
git clone --depth 1 https://github.com/axiomantic/spellbook

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for feature-design

README.md
[![agentmods](https://agentmods.dev/badge/commands/axiomantic/spellbook/feature-design/github.svg)](https://agentmods.dev/commands/axiomantic/spellbook/feature-design)
Your own site
<a href="https://agentmods.dev/commands/axiomantic/spellbook/feature-design"><img src="https://agentmods.dev/badge/commands/axiomantic/spellbook/feature-design/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for feature-design

Your own site · 80×15
<a href="https://agentmods.dev/commands/axiomantic/spellbook/feature-design"><img src="https://agentmods.dev/badge/commands/axiomantic/spellbook/feature-design.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 11 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,792 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00011 $0.03792
Opus 5 $0.00005 $0.01896
Sonnet 5 $0.00002 $0.00758
Haiku 4.5 $0.00001 $0.00379

Measured 5d ago against content hash 1a0ccaab4d3a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

feature-design 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 5d ago.

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/feature-design.md · 392 lines

How it starts

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

/feature-design

Phase 2 of the develop workflow. Run after /feature-discover completes.

Before ANY Phase 2 work, run this check:

PROJECT_ROOT=$(git rev-parse --show-toplevel 2>/dev/null || pwd)
PROJECT_ENCODED=$(echo "$PROJECT_ROOT" | sed 's|^/||' | tr '/' '-')

echo "=== Phase 2 Prerequisites ==="

# CHECK 1: needs_design must be set (this phase does not run otherwise)
echo "Required: needs_design == true"
echo "Current need-flags: [SESSION_PREFERENCES.need_flags]"
# needs_infrastructure IMPLIES needs_design (auto-set in Phase 0; see design §2.2).
# If needs_design is not set, this phase does not run — return to the orchestrator.

# CHECK 2: Understanding document must exist (Phase 1.5 artifact)
echo "Required: Understanding document exists"
ls ~/.local/spellbook/docs/$PROJECT_ENCODED/understanding/ 2>/dev/null || echo "FAIL: No understanding document found"

# CHECK 3: Completeness score must be 100%
echo "Required: Phase 1.5 completeness score = 100%"
echo "Verify: SESSION_CONTEXT.design_context populated with no TBD values"

# CHECK 4: Devil's advocate was dispatched
echo "Required: Devil's advocate review completed"

If ANY check fails: STOP. Return to the appropriate phase.

Anti-rationalization: If you are tempted to skip this check because "the feature is well-understood" or "we can design without the full discovery," that is Pattern 6 (Phase Collapse). The understanding document IS the input to design. Without it, design is guesswork.

Invariant Principles

  1. Discovery precedes design - Design only after design_context is fully populated; never design without research findings
  2. Synthesis mode for subagents - Design-exploration subagent receives complete context; no interactive discovery in design phase
  3. Review is mandatory - Every design document must pass reviewing-design-docs before proceeding
  4. Approval gates respect mode - Interactive mode pauses for user; autonomous mode auto-fixes all findings

Read the full file on GitHub · 392 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. 5d ago First seen · 392 lines · 11 tokens per session scan A 1a0ccaab4d3a

Subscribe to this mod's changes

feature-design is a command published in the GitHub repository axiomantic/spellbook (10 stars, last pushed yesterday), licensed MIT. It adds 11 tokens to every session and 3,792 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-09-03.