spiral

spiral is a command for Claude Code from musingfox/cc-plugins. It costs 83 tokens per session (7,220 once invoked), scanned A, original, MIT.

A planning command that turns a vague question into a concrete implementation-sized goal. It explores several directions, lets you choose one, and narrows the choice into a plan or milestone without writing code.

In plain words
What is it for?
Use it to explore approaches, select a direction, define milestones, and prepare a goal for a later coding step.
Why use it?
Unclear requests often lead to premature implementation or a plan at the wrong level of detail. This process adds focused decisions one layer at a time and stops when the goal is concrete enough.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the spiral plugin — 1 command, 3 agents shipped together

Good fit Use it to explore approaches, select a direction, define milestones, and prepare a goal for a later coding step.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add musingfox/cc-plugins
Claude Code
/plugin install spiral

Made for: Claude Code.

Or install spiral, the plugin that ships this one along with the rest of its 1 command, 3 agents.

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 spiral

README.md
[![agentmods](https://agentmods.dev/badge/commands/musingfox/cc-plugins/spiral/github.svg)](https://agentmods.dev/commands/musingfox/cc-plugins/spiral)
Your own site
<a href="https://agentmods.dev/commands/musingfox/cc-plugins/spiral"><img src="https://agentmods.dev/badge/commands/musingfox/cc-plugins/spiral/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 spiral

Your own site · 80×15
<a href="https://agentmods.dev/commands/musingfox/cc-plugins/spiral"><img src="https://agentmods.dev/badge/commands/musingfox/cc-plugins/spiral.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 83 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 7,220 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.00083 $0.07220
Opus 5.5 $0.00033 $0.02888
Sonnet 5.5 $0.00017 $0.01444
Haiku 4.5 $0.00008 $0.00722

Measured 10d ago against content hash fc7a59120bfa, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

spiral 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 10d 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.

spiral/commands/spiral.md · 457 lines

How it starts

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

Spiral

You drive the main thread: dispatch Divergence — the one thing here that must not see your hypotheses — dispatch Probes to walk whatever the human leaves open, and a Prototype where a walk can only be settled by building the thing, then converge what they settled into a plan yourself, write what the human reads, and stop. You do not name directions or pick between them.

Each layer lands one plan or milestone, concrete at that layer's grain and no finer. The next layer diverges from that plan, so the spiral descends — vague question → approach → milestone → an implementation-sized goal. It stops where the human says it is concrete enough, and /cf takes the goal from there.

A layer takes as many rounds as it needs. A round is one demand on the human's attention: every decision that is askable now, asked at once, answered, and folded back in — which is what makes the next ones askable. concept.md §5 defines the term; this file just runs it.

Concept: ${CLAUDE_PLUGIN_ROOT}/docs/concept.md holds the reasons behind these rules. Read a section when a step cites it (concept.md §N), not up front. The question is $ARGUMENTS.

mkdir -p .spiral
grep -qxF '.spiral/' .gitignore 2>/dev/null || echo '.spiral/' >> .gitignore

Two counters, and they move independently. The layer L deepens only when the human says 再挖一層; the round a within a layer increments whenever the layer is not settled yet — they rejected the menu (都不對), or they answered some decisions and left others blank. Start at L1-a1. Nothing is ever overwritten — what was asked and what came back are the carry-over that keeps the next round from repeating it.

1 — Diverge

Agent(subagent_type: "spiral:divergence", model: "opus") with what to widen from plus the carry-over for this layer, verbatim: every direction already rejected and the human's feedback on it, and every decision they have already settled here.

  • L1-a1 → the question itself.
  • L<N>-a1 (N>1) → the previous layer's plan, .spiral/L<N-1>-plan.md.
  • L<N>-a<M> (M>1) → the same source as a1 at this layer; there is no plan for this layer yet. What changed is the rejected set and what they settled, not the artifact.
  • A layer reopened by an ascent (§3, §5) → the same source as a1 at that layer, with the carry-over ${CLAUDE_PLUGIN_ROOT}/docs/ascent.md describes.

Read the full file on GitHub · 457 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. 10d ago Changed · -11 lines · -9 tokens per session fc7a59120bfa
  2. 18d ago Changed · +28 lines 8cbbb82d76a1
  3. 20d ago Changed · +12 lines · +2 tokens per session 5ace6d2423b8
  4. 1mo ago Changed · +12 lines 96a2b736ff2a
  5. 1mo ago Changed · +207 lines · +32 tokens per session ce05164ba11c
  6. 1mo ago First seen · 209 lines · 58 tokens per session scan A 45fbe66bcf07

Subscribe to this mod's changes

spiral is a command published in the GitHub repository musingfox/cc-plugins (2 stars, last pushed yesterday), licensed MIT. It adds 83 tokens to every session and 7,220 once invoked, about $0.0003 per session on Opus 5.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-05.