spec

A feature-specification command that records who a feature is for, why it is needed, and what should happen. It expresses acceptance criteria as Given/When/Then scenarios, where each scenario describes a starting state, an action, and an observable result.

In plain words
What is it for?
Use it to define a feature’s success cases, edge cases, failure behavior, scope limits, open questions, and saved project context.
Why use it?
It turns vague feature requests into testable expectations and exposes missing decisions before implementation begins.

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/hautc-it/cil/spec
Clone the repo
git clone --depth 1 https://github.com/hautc-it/cil

Made for: Claude Code.

Per session 24 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 396 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.00024 $0.00396
Opus 5 $0.00012 $0.00198
Sonnet 5 $0.00005 $0.00079
Haiku 4.5 $0.00002 $0.00040

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

Security

Grade A, and why

spec 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/spec.md · 74 lines

What it actually says

/spec

Feature: $ARGUMENTS

Produce a written spec before /develop so success criteria are explicit, not inferred.


Step 1 — Clarify intent

Ask the user (or restate, if clear):

  • Who is this for? (user role, system, internal)
  • Why now? (problem being solved, trigger)
  • What changes for the user when this exists?

If any of these are unclear, list 2–3 interpretations and ask.


Step 2 — Acceptance criteria (Given/When/Then)

Write 3–7 concrete, testable scenarios. Each one should be a single clear behavior — not a list of features.

Scenario 1: <name>
  Given <starting state>
  When  <action>
  Then  <observable outcome>

Scenario 2: ...

Cover at minimum: happy path, one edge case, one failure mode.


Step 3 — Out of scope

Bullet list of related things that look in-scope but are NOT being done now. This prevents scope creep during /develop.


Step 4 — Open questions

Anything you couldn't decide alone. Flag explicitly — don't assume.


Step 5 — Persist

Store the spec for cross-session continuity:

memory_store("decision", "spec for $ARGUMENTS — <one-line summary>", ["spec", "$ARGUMENTS"])

For each acceptance criterion:

memory_store("constraint", "$ARGUMENTS must <criterion>", ["spec", "acceptance"])

Output

Print the spec, ending with:

Spec ready. Next: /develop $ARGUMENTS.

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 · 74 lines · 24 tokens per session scan A b5aa9bfccc9f

Subscribe to this mod's changes

spec is a command published in the GitHub repository hautc-it/cil (1 stars, last pushed 1mo ago), licensed MIT. It adds 24 tokens to every session and 396 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.