/speccy:speccyfrom speccy
Guides users through a full pipeline from rough idea to reviewed implementation: specification writing, adversarial critique, planning, implementation, and post-build review.
Ships in speccy. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Full pipeline: specification → spec critique → planning → plan critique → implementation → implementation review.
The orchestrator runs in the main conversation. Heavy work (adversarial critiques, codebase research for planning, applying critique revisions, implementation, and code review) is delegated to subagents so the main context stays small. Persistent state lives in files; the run can be paused at any phase boundary, its context cleared, and resumed.
<skill-dir> is the absolute path of the directory holding this SKILL.md. The host reports it when it loads the skill (a "base directory" line, or the path the skill was listed at); use that path, never a guess or a path relative to the working directory. Every <skill-dir>/… path in this skill and its phase files means that directory. Write it out in full before passing such a path to a subagent, which starts in the project's directory and does not know it.
When the skill triggers, show the speccy banner first, on every invocation. Run banner.sh by its absolute path: a relative path breaks when the Bash cwd has drifted or the skill is installed as a plugin. Don't prepend cd and don't use command substitution; both break the pre-approved permission match.
bash <skill-dir>/banner.sh
The script prints two Markdown lines. Reproduce them verbatim at the top of your reply; that is what the user sees. Running the script alone isn't enough, because its tool output is hidden by default.
The banner is cosmetic. If the script fails or would prompt, just proceed without it; never block the run on it.
Then check for an in-progress run (see Resuming a run below). If one exists, offer to resume before starting fresh.
For a new run, give a one-sentence introduction: this skill walks through writing a spec, getting it independently critiqued, building the implementation, and reviewing the result. Then ask two things in one turn:
Walkthrough or start? Tell the user they can ask for a walkthrough of the process, or just describe what they want to build to get going. If they ask for the walkthrough, explain each phase in a few sentences, organised around what the user does vs what runs autonomously:
Also mention: state is saved after every phase boundary, so the user can clear the context and re-invoke the skill at any point to resume with a fresh context. Useful for long runs where the main conversation has grown.
Defaults you can change. Note the per-phase model defaults (just below) and that they're overridable. No need to ask; just flag that the options exist.
Each phase has its own model default:
high effort and manages its own models.No default uses the XL rung. It buys raw capability, where these roles need judgment and coding strength, which L already leads on.
Two overrides: pin a single adversary rung (adversaryModel), then used for every critique round and review lens; and raise the builder (builderModel), commonly to the L rung for high-stakes work.
Each loop restarts at round 1 and exits early when a round surfaces no valuable criticism (the spec and plan loops first run one more round to check the readability pass; see 1d and 2a).
If the user's trigger message already includes a description of what to build, skip straight to the adversary rung note and proceed to the precondition check and Phase 1 (<skill-dir>/phases/spec.md; see Phase dispatch).
Run state lives at .speccy/<run-id>/state.json, written after every phase boundary by state.mjs, its only writer. You read it directly as a file (resume, the round number N, prior engagement questions, the models, whether a readability pass has run) and never hand-write it. Its fields: runId, slug, baseBranch, adversaryModel, builderModel, phase, specPath, planPath, decisionLogPath, the three round counters, readabilityPasses, engagementQuestions. The schema is closed; the CLI rejects anything else.
Run the CLI by its absolute path, node <skill-dir>/state.mjs <verb> --run <runId> … (the same literal-path, no-cd, no-substitution rule as the banner; --run is required on every verb). It writes loudly: a bad transition or an unmet guard prints the reasons and exits non-zero, leaving state untouched, and every call prints the phase you land in and a one-line hint at what comes next. Each phase below gives the exact call to make; you never need --help.
The pull to add a field comes when a decision lands and the artifact hasn't caught up. Write it to the artifact then and there:
What remains is genuinely transient: the user is mid-read, a precondition passed an hour ago, an agent is running. That dies with the context by design, and a resumed run re-checks or asks.
adversaryModel defaults to "L": the rung for every critique round and the review panel's judgment lenses (the suppressions and comment lenses run a rung below; see Getting started). If the user pinned a different adversary rung, store that rung here instead and use it for every critique round and review lens.
On trigger, read .speccy/.current-runid, a pointer to the most recent run written when the run is created (see Phase 1c). If it exists, Read that run's state.json; if phase is not "complete", surface the run to the user and ask whether to resume or start fresh. To resume, Read the phase file the recorded phase maps to (see Phase dispatch), read the artifacts state.json references (spec, plan, latest critique round), and continue from the recorded phase.
state.json names the spec, plan, and decision log, and no other file. List .speccy/<run-id>/ to see what else the run produced — earlier rounds, spikes, readability change notes, deferred findings — and read what the phase you are resuming into needs.
When an artifact is replaced, rename what reviewed it. A re-plan leaves its critique rounds and readability change notes describing a draft that no longer exists, and a resumed context reading one cold will act on findings that no longer apply. For a re-plan, state.mjs replan does this: it renames the plan-review files to SUPERSEDED-<original name> (a spike verdict is evidence about the world rather than a review of a draft, so it keeps its name). They remain the run's history, grouped in a listing, and the wrap-up reads them for a reversal nobody logged, so they are renamed rather than deleted.
A resumed run skips the precondition checks (but not the harness binding; see Resolve the harness binding), so if the recorded phase is spec-critique or later, suggest enabling auto-accept first: the rest of the run is autonomous tool calls. A resume at spec-draft just re-presents the draft for reading, so it needs no such nudge.
After completing each phase, state.mjs advance to the next and continue. The user can clear the context and re-invoke the skill at any point to resume from the recorded phase; no need to ask permission at phase boundaries.
Read .speccy/ artifacts and write run artifacts (spec, engagement-question files, review notes) as plain file reads and writes; where the harness honours the skill's pre-approved tools, these and state.mjs never prompt. state.json itself is written only through state.mjs, never by hand. Do not rely on a file-globbing tool: it isn't available in every session, which is why run discovery uses the .current-runid pointer. The pointer tracks the latest run; earlier runs remain in .speccy/ if the user wants to revisit one.
At the start of every orchestrator conversation, before any phase work, resolve which harness speccy is running under and hold the result for the conversation. This is the one place harness identity is established; nothing else probes for it. It runs on every conversation, fresh or resumed, unlike the precondition checks below that a resume skips.
Identify the harness. Read it from your own knowledge of the host you are running in (a short identifier such as claude or codex). If you genuinely cannot tell, ask the user once to declare it; this fallback matters only for a host that exposes no identity signal, which neither current target is.
Resolve and validate the binding. Invoke the resolver by its absolute path (the same literal-path, no-cd, no-substitution rule as the banner and state.mjs):
node <skill-dir>/binding.mjs --harness <harness>
It reads that harness's adapter defaults (adapters/<harness>.mjs) and prints the resolved binding as JSON: the capability→mechanism map, the rung→model map (S/M/L/XL), and the instruction-file name. It fails loud like state.mjs: an unknown harness, a missing capability mechanism, an unresolved rung, or an absent instruction-file name prints a speccy binding: line and exits non-zero, so a half-resolved binding never reaches a phase.
Resolve the model families, if the binding names any. When the binding carries a modelResolution, its rungs name model families rather than models: follow that rule once, now, to turn each into a concrete model, and hold the resulting rung→model map in place of the families.
Hold it; write no file. Keep the resolved binding in the conversation. Every phase reads this held binding rather than re-deriving anything: it resolves a model-ladder rung (S/M/L/XL) to the concrete model to spawn, names the mechanism behind a capability (spawn a subagent, run the workflow, arm the monitor), and gives the instruction-file name that subagents and worktree-init point at.
Re-run on every fresh conversation. A context clear or a switch of host starts a new conversation, so resolve again at its start; state.json carries no harness.
Before running any of the checks below, suggest the user enable auto-accept. From here to the end of the run the work is mostly tool calls (the verification smoke-test runs the project's linters and tests, then planning, critique, implementation, and review run autonomous loops), so approving each one by hand is pure friction. The spec interview is a conversation regardless, so auto-accept doesn't take any decisions away: the user still reviews and edits the spec content directly.
Every subagent inherits the session's effort, and speccy spawns dozens of them: critics, revise agents, a planner, the review lenses, the fixers, and the whole build. At xhigh or max that multiplies across the pipeline and the run takes far longer.
Run the binding's effort check (its effortCheck); it names the command that reads the session's effort and the levels that count as above high.
If the effort is above high, say so and suggest lowering it to high before starting. It is the user's call, since this costs time rather than correctness. If it prints nothing, say nothing: an unreported effort is not a low one.
Check that the instruction file documents the project's verification tools (build, lint, static analysis, test commands). These are needed during implementation: execute agents run them to validate their work. If they're missing, tell the user before proceeding. Establishing verification standards is part of project setup; discovering them mid-build is too late.
Documented is not the same as working. Smoke-test the tooling now, on the clean tree, before investing in spec and plan: a broken or pathological verification setup discovered at implementation has already cost a spec, several critique rounds, and a plan. Run each documented command once and confirm it completes, passes (or note its baseline failures), and returns in a reasonable time. Surface anything that hangs, errors, or floods output before proceeding.
Worktrees come into play only for parallel tasks. Plan-execution runs sequential tasks directly on the main checkout; only parallel tasks get git worktrees, which lack gitignored state. You won't know whether the plan produces parallel tasks until breakdown, so treat this as preparation that may not be exercised this run. Check whether the instruction file has a ## Worktree init section with gather/apply blocks. If it does, nothing to do: plan-execution will use it if parallel tasks arise. If it's missing:
.gitignore and the verification commands for clues about what needs recreating.A purely sequential plan never touches worktrees, so a project that only runs sequential work can skip this, but it's cheap insurance for any run that fans out.
Before starting work:
git status --porcelain; if the working tree is dirty, tell the user and stop.git branch --show-current and note the current branch. This is the base branch for the rest of the pipeline.Every artifact this pipeline produces (spec, plan, critique, review notes, summary, decision log) is written for a person first: the reviewer now, and whoever picks the work up later. <skill-dir>/prompts/writing-style.md holds the rules. It governs what speccy writes itself, and it is passed to every subagent speccy spawns to write one of those artifacts (see Propagate the session's voice to subagents). Plan-execution's build agents are outside it: their task files are working notes for the build rather than something a reviewer reads.
The critique loops pull the other way, since the cheapest answer to a critic is one more clause. Three things push back, all wired in below. Every one of those agents gets writing-style.md, so a draft starts readable. The readability pass (<skill-dir>/prompts/readability-pass.md) is the one step allowed to remove. And once that pass has run, the critique prompts add a reader lens, which is what stops the rewrite sliding back over the rounds that follow.
Every step of a run is tempted to add: a critic finds a gap, a fix fills it, and the next reviewer finds the fix's gap. Each addition looks reasonable on its own, and the sum is how a run overbuilds. Weigh every choice you make (drafting, triage, briefing a reviser, review dispositions) against leaving the addition out, and prefer removing, narrowing, or revisiting an earlier choice. When two options both hold, the one that builds less wins.
specs/<slug>-decision-log.md is created with the spec at 1c and appended to as the run goes. The wrap-up completes it; it does not start it.
It exists this early because the spec and plan hold only the position they now hold. How a position was reached has nowhere else to go, so a run without this file writes it into state.json, into a chat message a context clear eats, or nowhere. Three things go in, at the moment they land:
Nothing else. Use the wrap-up's entry shape from the start (what was proposed, what was decided, why, origin), keep entries to a few lines, and write no entry at all for a decision that still stands as the spec or plan states it. Commit it alongside the change it explains.
Subagents run in the background, and their completion notifications are unreliable: the returned summary can arrive misrouted under a different agent's completion, and the notification's apparent identity (which agent, which round) can be wrong. A round-3 critique may surface labelled as the round-2 revise agent. This is expected harness noise.
So for every spawned agent: you know what it was spawned to do and the exact file it writes, and the round number comes from state.json rather than the notification. When a completion arrives, read that file and act only on its contents. Never branch control flow (early-exit, round counting, commit messages, what you tell the user) on a returned summary or a notification's label. Don't narrate or diagnose misrouting; read the right file and carry on.
The main session may be governed by a behavioural or output style a fresh agent context does not inherit: a house-voice hook (e.g. one injected at session start), a configured output style, or communication conventions that live beyond the project's instruction file. A subagent starts clean and never sees the main session's system prompt, so unless you carry that style across, every critic, revise agent, planner, review lens, and fixer speaks in a default voice that clashes with how this session talks, and the artifacts they write (critiques, plan, review notes) read in a different register from the rest of the run.
So before spawning any subagent, restate the active style concisely at the top of its prompt, enough that both its reasoning and its written output match the session's voice. Pass <skill-dir>/prompts/writing-style.md to every subagent that writes an artifact, which is all of them but the fixer: the session's voice is a layer on top of those rules rather than a substitute for them, and a style restated from memory is the least reliable way to carry a writing standard across a context boundary. Two things are out of reach and don't need carrying: conventions already in the instruction file (the harness loads it for subagents — whether it auto-loads into a subagent is harness-dependent, and where it doesn't the orchestrator passes it itself, a consideration the binding carries), and the harness's code reviewer run inline (it manages its own prompt; the orchestrator just applies the session's voice when it normalises those findings into the lens file). This rule applies to every spawn site in the phases below; it is stated once here rather than repeated at each. speccy's own narration back to the user follows the same style as a matter of course.
Pass <skill-dir>/prompts/tool-use.md to every subagent speccy spawns, plan-execution's build agents included. Like the writing-style rule above, it applies at every spawn site in the phases below and is stated once here rather than repeated at each, with the same two exceptions: the harness's code reviewer and any project review gate manage their own prompts.
speccy's own output is the hazard. Adversarially-hardened specs and plans read as authoritative, and the more authoritative they read, the stronger the pull for the user to approve without understanding (cognitive surrender: borrowed confidence, surface correctness hiding deeper flaws). The pipeline already hardens its artifacts. These habits guard the user's engagement, which nothing else does.
Apply these habits at the run's three human gates and nowhere else: the spec critique (1d), the plan review (2b), and the wrap-up decision log (Phase 5). The other interactive moments are not gates, so pose no pre-question there: the intake and interview gather requirements, the first-draft review (1c) is the user's turn to read and edit, and the build kickoff (Phase 3) is a handoff. The pre-question in particular assumes the user has read the artifact and is about to see it critiqued; asked before a draft is read, or after a decision is already made, it has no referent and reads as the ritual this section exists to prevent. The three habits:
Origin flips as the user engages. When speccy surfaces a speccy, alone decision and the user ratifies it, re-tag it speccy, user-agreed; if they override or reshape it, re-tag it User. Record the flip in the artifact, so a later gate or the wrap-up doesn't re-surface a call the user has already owned. (Challenging a User hunch is different: if the user then gives a clear reason, it stays User, now with its rationale recorded.)
Ask these as ordinary questions inside the flow of the gate; never announce that you're doing them and never give them a label to the user (no "engagement check", no "cognitive surrender"): a prompt flagged as a check gets performed rather than thought about. A user who would rather not be asked can simply decline, or say so at the start; honour that, and you need not advertise the possibility.
Vary the questions across gates. The job repeats at each gate but the wording must not: the same pre-question framing heard three times decays into a ritual the user pattern-matches and shrugs past, which is the ritualization this whole section fights. Before posing a pre-question or a "what convinced you", read engagementQuestions from state.json to see what earlier gates already asked, and come at this one from a fresh angle (a different referent, a different way in) rather than reciting the template. After you ask, write a short paraphrase of what you actually posed to a file and record it with state.mjs engagement-add --run <id> --gate <gate> --from-file <path> (the text goes through a file, never a flag). The list starts empty and survives a context clear, so a resumed context still knows what framings are spent. The point is to avoid repeating yourself, and it never demands perfect wording: the engagement comes from the loop, and variation only keeps the loop from going stale.
Each of these questions is a stop. Ask it as the last thing in the turn and wait: the question fails precisely when the orchestrator asks, then keeps thinking and running tool calls until it scrolls off unanswered. Nothing follows the question until the user replies, and a pre-question never reveals the critique in the same turn (which would pre-empt the answer and lose the anti-anchoring). Put it on its own line at the end of the reply.
The long idle stretches are the other good moment. The autonomous phases (plan critique in 2a, the build in Phase 3, the review panel in Phase 4) leave the user waiting on a subagent for a long while. That idle time engages well with a different device from the gate habits: an offer to deepen understanding rather than a pre-question, since there is no artifact to predict yet. Offer to walk through how a part of the system works relative to what's being built, or raise an implementation detail the plan left open and ask whether the user has a preference. Only when there's something genuine to say; manufactured filler trains the user to tune speccy out. Two rules keep it from backfiring, and both invert the gate question's "stop":
Apply the same standard to the final diff: read it as if a contributor you do not fully trust wrote it.
The phase bodies live in one file each, under <skill-dir>/phases/. The core above (getting started, resuming, the harness binding, preconditions, the state CLI contract, and every bold cross-cutting rule) is always loaded; the phase files layer on top. So a run that clears its context at a boundary reloads this core plus only the phase it is resuming into.
When you enter or resume into a phase, Read its file before acting. Map the phase in state.json to a file:
phase in state.json | Read |
|---|---|
spec-draft, spec-critique | <skill-dir>/phases/spec.md (Phase 1) |
planning, plan-critique, plan-review | <skill-dir>/phases/plan.md (Phase 2) |
implementation, review, wrap-up | <skill-dir>/phases/build.md (Phases 3–4 + wrap-up) |
complete | none; report and run metrics (see <skill-dir>/phases/build.md, wrap-up) |
A fresh run starts at spec-draft, so read <skill-dir>/phases/spec.md once the precondition checks pass. Each file ends by naming the next, so you know which to load when a phase hands on. This extra Read is the point: it keeps a phase's detail out of context until the phase needs it.
DECISION_LOG.md (opens in a new tab)banner.sh (opens in a new tab)binding.mjs (opens in a new tab)metrics.mjs (opens in a new tab)metrics.sh (opens in a new tab)phases/build.md (opens in a new tab)phases/plan.md (opens in a new tab)phases/spec.md (opens in a new tab)prompts/implementation-fix.md (opens in a new tab)prompts/plan-critique.md (opens in a new tab)prompts/plan-research.md (opens in a new tab)prompts/plan-template.md (opens in a new tab)prompts/readability-pass.md (opens in a new tab)prompts/review-codebase-fit.md (opens in a new tab)prompts/review-comments.md (opens in a new tab)prompts/review-local-docs.md (opens in a new tab)prompts/review-output-contract.md (opens in a new tab)prompts/review-spec-fidelity.md (opens in a new tab)prompts/review-suppressions.md (opens in a new tab)prompts/review-tests.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
2 skills in this plugin
npx claudepluginhub aquivalabs/speccy --plugin speccyOther plugins' skills for the same job