Author, bring in, revise or reference a design document.
71%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
Passed
No findings from the security scan
Fix and improve this skill with Tessl
tessl review fix ./skills/spek-design/SKILL.mdVersion check first. Before running any other command, run
spektacular version check.
- On
status: "match", continue with the skill and produce no version-related output.- On
"mismatch","missing"or"upgrade_needed", the project's settings or installed Spektacular files are out of date: relay the response'sactionmessage to the user, ask them to runspektacular migrate(they can preview it withspektacular migrate --dry-run), and wait for their decision before continuing.- On
"unsupported_format", relay theactionmessage: the project was written by a newer Spektacular, which the user must install before continuing.- Never run
migrateorinit, and never modify installed files yourself. Upgrading is always an explicit, user-initiated action.
Mark spans. Before you launch a helper agent, run spektacular trace start <helper> --type sub-agent and put the id it prints in the helper's brief: "Your parent span is <id>: start any span of your own with --parent <id>." When the helper returns, run spektacular trace stop <id> (add --status error if it failed), chained with your next command.
Before you ask the user a question, run spektacular trace start <question> --type user-wait, and once they answer run spektacular trace stop <id>, chained with your next command.
This skill handles the four ways a design document enters a project: helping the user work one
out that does not exist yet, bringing in one they already have, revising one that exists, and
recording a reference to one already stored. Unlike spek-new, spek-plan and spek-implement,
it does not drive an interactive CLI state machine — it is a static playbook. That is deliberate
and load-bearing: a state machine could not run inside a spec workflow, and design conversation
happens during one. The agent recognises which situation the user is in, picks one of four
branches, and calls the matching spektacular design command directly.
Two classes of design document exist and the difference matters at every branch. A design the project already had is stored exactly as supplied and never gains anything. A design Spektacular authors with the user carries the same lifecycle record every spec and plan carries, so it reports where it stands, which spec's conversation produced it, and which specs reference it.
Invoke this skill whenever a design document is in play. Typical natural-language triggers:
One skill handles all four intents. Discriminate by what the user actually said. If it is genuinely unclear whether they already have the document written, ask that one question — it is the only thing separating the author branch from the bring-in branch.
Before any branch that names a source, run spektacular design sources to see the declared
sources and their locations. Choose only from the names it returns, never a name you inferred.
spektacular design list shows what those sources already hold, including which documents carry a
lifecycle record and which do not.
Triggered when the design has been worked out in conversation, or needs to be, and nothing is written down yet. This branch runs an interview and then writes the document from it.
Run the interview before drafting anything. It follows the Flipped Interaction pattern (White et al., "A Prompt Pattern Catalog to Enhance Prompt Engineering with ChatGPT," arXiv:2302.11382), the same pattern the spec workflow's own interview uses: rather than asking the user to author the document from a blank prompt, you drive the conversation with a stated goal, adaptive questions toward it, and an explicit stopping condition.
Stated goal: understand the design well enough to write a document someone could build from.
Ask adaptive, open questions — not a fixed script. Start from what the user has already said. Ask about the shape of the thing being designed, what it does in the ordinary case, what it does at the edges, what it deliberately does not do, and which parts are settled versus still open. Each question should follow from the answer before it, pursuing what is still unclear rather than working through a checklist.
Stop once a further answer would not change the document. That is the stopping condition, and it is a rule rather than a suggestion. Test it directly: ask yourself whether another answer would change what you write. When the answer is no, stop and draft. This should take a small number of exchanges. If the user's description already settles the design, a short interview or none at all is correct — do not manufacture questions for their own sake.
Write the design, not the conversation. The document records the decisions, not the back-and-forth that produced them, and it is the size of the design rather than the size of the discussion. A transcript is a failure of this branch even when every fact in it is accurate.
Do not impose a structure. There is no template and no required headings. The document's shape follows the design.
Then:
.spektacular/tmp/<slug>.md with your own Write tool.spektacular design author --data '{"source":"<name>","path":"<path>"}' --from .spektacular/tmp/<slug>.md--spec <spec name> when the conversation belonged to a spec, which records where the
design came from. Add --document-status <draft|final|superseded|archived> to set its
lifecycle status; it defaults to draft.rm .spektacular/tmp/<slug>.md.spektacular design ref add --data '{"spec":"<spec>","source":"<name>","path":"<path>"}'Triggered when the user already has the design written and wants it stored. There is no interview: the document exists, and the work is to store it without disturbing it.
spektacular design write --data '{"source":"<name>","path":"<path>"}' --from <path to their file>spektacular design ref add if a spec should point at it.Do not use design author here. Authoring stamps a lifecycle record, and a document the user
handed over is not one Spektacular wrote.
Triggered when a design that already exists has changed.
spektacular design read --data '{"source":"<name>","path":"<path>"}'.spektacular design author, exactly as in the author branch. For a document
Spektacular authored this is an update in place: it keeps the document's original capture date
and the specs already referencing it, so existing references keep resolving. Pass
--document-status superseded if the design has been replaced rather than amended.If the document is one the project already had, and so carries no lifecycle record, revise it with
spektacular design write instead, which again stores the bytes exactly as supplied.
spektacular design list tells the two apart: a document Spektacular authored reports its status
and capture date, one the project already had reports only a source and a path.
Triggered when the document is already in a declared source and all that is missing is the link from a spec.
spektacular design ref add --data '{"spec":"<spec>","source":"<name>","path":"<path>"}'Recording a reference keeps both documents in agreement: the spec gains the reference, and a design
Spektacular authored gains the spec in its own record. A design the project already had takes part
without being touched. spektacular design ref list --data '{"spec":"<spec>"}' reports what a spec
already references and whether each reference resolves, and spektacular design ref remove drops
one from both sides.
Nothing is written without the user's explicit agreement. Every branch that writes presents its document or its proposal first and waits.
If the user declines, asks for changes, or expresses uncertainty at any propose-then-confirm
checkpoint, do not invoke spektacular design author or spektacular design write. Either
loop back and refine the draft, or stop and leave the source untouched. Remove any staged scratch
file at .spektacular/tmp/<slug>.md either way; a half-finished proposal should not linger on
disk.
A decline is final for that design, not a "not now": do not raise it again for the same detail later in the conversation. It also means the detail does not get smuggled into the spec body instead — it stays out, or it stays as the one-line steer it already was.
The propose-then-confirm contract is enforced by this prose, not by a CLI guard. Treat it as load-bearing: a write without explicit user approval is a bug in the skill's execution, not an acceptable shortcut.
nicholasjackson/tcgreplay
19cd525
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.