speckit.companion.classify — Claude Code command
speckit.companion.classify evaluates task scope from spec.md to classify changes as simple, normal, or oversized. Companion workflows use this signal to adapt the execution pipeline.
MIT ★ 110 updated 2026-10-19
.claude/commands/speckit.companion.classify.mdWhat speckit.companion.classify does
This command functions as a read-only sizing step. It inspects spec.md, alongside plan.md and tasks.md when present, without writing to .spec-context.json or modifying any spec documents. It prints a single [companion] size=<simple|normal|oversized> log entry and exposes the value as structured output for workflow switch logic.
A task qualifies as simple only when it touches 5 or fewer files, decomposes into at most 10 tasks, and remains trivial to test and revert. If the work involves database migrations, deleted records, or public interfaces, the step refuses the simple classification regardless of file count. Ambiguous changes default to normal, while broad multi-subsystem work triggers an oversized warning without skipping phases.
What it helps with
- evaluate task scope directly from spec.md
- route Companion pipelines based on implementation size
- prevent skipping verification steps during database migrations
- detect oversized refactorings before starting code generation
Example prompts for the agent
- /speckit.companion.classify
- Run /speckit.companion.classify to estimate scope from spec.md
How to install speckit.companion.classify
Manually: put the files in place
.claude/commands/speckit.companion.classify.mdCall it with /speckit.companion.classify. For all projects use ~/.claude/commands/
Manually: put the files in place
~/.codex/prompts/speckit.companion.classify.mdCall it with /prompts:speckit.companion.classify. Codex marks this format deprecated in favour of skills
Manually: put the files in place
.github/prompts/speckit.companion.classify.prompt.mdManually: put the files in place
.gemini/commands/speckit.companion.classify.tomlGemini stores commands as TOML: the prompt text goes into the prompt field
Questions about speckit.companion.classify
How to install speckit.companion.classify in Claude Code?
Place the command file at .claude/commands/speckit.companion.classify.md.
What does speckit.companion.classify do?
It parses spec.md and task files to report change complexity as simple, normal, or oversized. The command is read-only and leaves workspace files unchanged.
Why would a two-file change avoid the simple status?
Irreversible or hard-to-verify edits, such as database migrations or API contract updates, automatically disqualify a task from being marked simple.
Source text
speckit.companion.classify.md · MIT
--- description: "Classify the change size (simple | normal | oversized) so the Companion workflow can right-size the pipeline" --- # Classify Change Size Emit a single complexity signal — `simple`, `normal`, or `oversized` — that the Companion workflow's routing step reads to right-size the pipeline. On the workflow path there is no `complexityFastPath` on/off setting: the thresholds live here, in the workflow, not in a VS Code toggle. This is a **thin, read-only** step. It does not write `.spec-context.json` and does not create or edit any spec files; it only reports a size. ## Heuristic (thresholds live here, not in a setting) Estimate the scope of the change from `spec.md` (and `plan.md`/`tasks.md` if they already exist): <!-- speckit-companion:part sizing --> - **small**: the change plausibly touches **≤ 5 files** and decomposes into **≤ 10 tasks**, and is easy to undo and easy to check. A change that is hard to reverse (a migration, deleted stored data, a published contract) or hard to verify is never small, whatever its file count. - **oversized**: the change clearly exceeds the small bar by a wide margin (broad multi-subsystem work, many new files, or a long task list). - **normal**: anything in between (the default). <!-- /speckit-companion:part sizing --> When unsure, prefer `normal` — the routing step's safe default is the full pipeline, so an ambiguous estimate never skips a phase. ## Output Print exactly one line so the size is visible in the run log: ```text [companion] size=<simple|normal|oversized> ``` Expose the same value as structured output `size` (so a `switch` node can read `steps.classify.output.size`). Routing contract: <!-- speckit-companion:part routing --> - `simple` → the workflow folds toward implement (less ceremony). `simple` is the verdict every reader of the recorded size expects; `small` names the *bar*, never the verdict. - `oversized` → the workflow prints a visible warning and still runs the **full** pipeline. It never silently skips a phase. - `normal` (and any unresolved value) → the full pipeline. <!-- /speckit-companion:part routing -->
© alfredoperez · MIT · alfredoperez/speckit-companion