Drafts the acceptance scenarios and key decisions of a BDK Change into its issue body (issue.md in the run directory) from its proposal and the code map - approaches with diagrams and self-critique, questions to the user through a Lavish page or AskUserQuestion (or decided and recorded by policy), the living-documentation changes (proposed ADRs written with /bdk:adr, module map and glossary changes), a split into sub-issues when the change is too large for one pull request - fixes them after ...
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Design Draft?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/broneq-design-draft)
---
name: design-draft
description: 'Drafts the acceptance scenarios and key decisions of a BDK Change into its issue body (issue.md in the run directory) from its proposal and the code map - approaches with diagrams and self-critique, questions to the user through a Lavish page or AskUserQuestion (or decided and recorded by policy), the living-documentation changes (proposed ADRs written with /bdk:adr, module map and glossary changes), a split into sub-issues when the change is too large for one pull request - fixes them after a failed design verification, and writes the intent page of a scope change for the design gate. Use when a Change has a proposal and needs its scenarios and design, when asked to design a Change, or when /bdk:design drafts or fixes a design.'
argument-hint: "[change-name] [what to focus on]"
allowed-tools: Bash(${CLAUDE_PLUGIN_ROOT}/bin/bdk *) Bash(npx -y lavish-axi *) Bash(rm .bdk/runs/*/design/split.json) Read Grep Glob Write Edit Skill Agent SendMessage ToolSearch AskUserQuestion
---
Current BDK configuration of this project:
!`"${CLAUDE_PLUGIN_ROOT}/bin/bdk" config show`
Arguments: $ARGUMENTS
# Design draft
When the block above says "BDK not configured: run /bdk:setup", stop: reply with that line and write nothing.
You write the `## Acceptance scenarios` and `## Key decisions` of the Change's issue body `.bdk/runs/<change>/issue.md`, the `## Proposal` edits a scope answer needs, the entries you append to `scope-log.md`, a proposed split (`design/split.json` and its body files), the intent page `.bdk/runs/<change>/design/intent.html`, your Lavish pages, and the `proposed` ADRs of step 6 (through `/bdk:adr`, removed with `bdk adr reject`), nothing else: no code, no module map or glossary edit (the plan puts those into the part that makes them true), no plan parts, no other run files, nothing to the tracker (the design gate syncs the issue and accepts the ADRs).
## 0. Run on the designer
This block runs on the `bdk:designer` agent, whose instructions start with "You are `bdk:designer`". When you are that agent, go to step 1. When you are not (a user typed the command, or another skill invoked this one in the main thread), do not read the code or write a file yourself:
1. Start the agent with the Agent tool in the foreground (`run_in_background: false`): `subagent_type: "bdk:designer"`, prompt `Run the skill bdk:design-draft with the arguments: <the arguments above>. Write the questions in <language>, the language the user writes in.` (the language of the user's messages), `model` set to `models.designer.model` and `effort` set to `models.designer.effort`, each only when the configuration above sets it. Keep the agent ID it returns.
2. When it ends with `Page open: <page>`: the page is where the user answers; the decisions listed after that line are only for you to name. Tell the user in one line that the questions are on that page in the browser, then always wait for the feedback with `npx -y lavish-axi poll <page>` in the foreground, whatever else the designer reports about the page; never ask the page's questions in your reply instead (Bash `timeout` 600000; run it again when it times out). Continue the same agent with `SendMessage` (load it first with `ToolSearch` query `select:SendMessage` when it is listed only by name): `Answers: <the poll's output, verbatim>`. Do not summarise, interpret or settle anything in it: a note the user wrote may open a new decision, and only the designer decides that. When the poll is interrupted, or the user asks to stop waiting, do not poll again in this turn: answer what the user asked, name the page and its open decisions, say that answers given on the page stay queued and that `/bdk:design-draft <change>` picks them up, and end your turn.
3. When it ends with open questions and no page: ask them with `AskUserQuestion`: at most four questions per call, the recommended option first, each option one label and one sentence. Then continue the same agent with `SendMessage`: `Answers: <question>: <chosen option or the user's note>; ...`. Without the tool or the agent ID, start a new designer as in 1 with the arguments `<change> Answers: ...`.
4. When `AskUserQuestion` is not available: say that the browser review page (Lavish) could not open, when the designer says so, then list the questions in your reply, numbered, the recommended option first and marked "(recommended)", and end the reply with one line saying how to answer (`Reply with the numbers of your choices, or your own answer.`). When the user answers in the conversation, send the answers as in 3.
5. When it ends with `Needs user: SL-<n>`, reply with that line, the entry's AC and question, and that a session that can ask answers it, and stop.
6. The designer may come back with a further round (2 to 4 again) until it writes the files. Then reply with the agent's reply and stop.
Done when the designer has written the files or the questions are with the user.
## 1. Find the Change and the mode
The argument names the Change. Without one, take the `current` Change of `.bdk/runs/run.json`, else the only directory under `.bdk/runs/` other than `pr-<N>/` that holds an `issue.md`. With none or several, name what you found, ask which one, and stop. All paths below are under `.bdk/runs/<change>/`.
When the text after the Change name is `intent page`, this is the **intent page**: go to "Intent page". Otherwise list `design/verify-*.md`. When the frontmatter of the latest one says `verdict: fail`, this is a **fix**: go to "Fix after a failed verification". Otherwise, when `issue.md` holds `## Key decisions` and the arguments hold text after the Change name, this is a **revision**: go to "Revise on a request". Otherwise this is a **draft**.
Note `policy.questions` from the configuration above (`stop` when absent). Text after the Change name that starts with `Answers:`, or a message with answers, decides the open decisions it names: do not ask them again.
## 2. Ground in the code
Read `issue.md` (the `### Intent` and `### Acceptance` of its `## Proposal` are the reference: every AC is answered, and only the user changes one), `scope-log.md`, `source/issue.md` when present, and `explore/index.md` when present, then the `explore/` files whose question you need (the map `explore/design.md`, the recon `explore/propose-recon.md`; without an index, every file of `explore/`), and the project's rules: `CLAUDE.md` at the root and `.claude/rules/*.md`, each when present. Read, when they exist, the ADR index at `docs.adr.index` of the configuration above and the ADRs that bind the paths the change touches (`"${CLAUDE_PLUGIN_ROOT}/bin/bdk" adr for --files <path> --files <path> ...` prints them), the glossary at `docs.glossary` and the module map of the architecture doc at `docs.architecture` (its `yaml bdk-architecture` block). Every recommendation follows them, and step 4 checks the user's answers against them. Without the map, read the code the proposal touches yourself (its nouns, their callers one level out, their tests) before anything else. Every claim you later make about the code comes from a file and line you read; the verifier checks each one.
Then run `"${CLAUDE_PLUGIN_ROOT}/bin/bdk" rules for --stage design`, without files: it prints the design rules of the BDK pack and of the project, each under its id. Each rule is a constraint on the design. When a rule and the proposal pull apart, the departure is an open decision (step 3).
Done when you know what exists, which patterns the project uses, what is missing, and which rules hold.
## 3. Find the decisions
List what the Change must decide: each branching technical decision (where the logic lives, data shape, interfaces, failure handling) and each product point the proposal leaves open (formats, limits, defaults, what the user sees on failure).
For each branching decision, weigh at least two approaches as [approaches](references/approaches.md) describes, and pick a recommendation. When only one is viable, say why the others fail.
Add as open decisions: every open entry of `scope-log.md` (`By: needs-user` with no later `Answers: SL-<n>`), and every AC the code or a rule keeps you from meeting as written: a change of an AC is the user's ([Scope changes and deviations](#scope-changes-and-deviations)), never yours.
Sort each decision: **settled** when the proposal, the code, a rule of step 2 or the project's conventions answer it; **open** when they do not. A data-model change (new or changed fields, tables, migrations) is always open: approval of a design is not approval of a schema.
Done when every decision has a recommendation and is settled or open.
## 4. Ask in rounds
With no open decision, go to step 5.
With `policy.questions: decide-and-record`: ask nothing. Take the recommended answers; step 6 records them. A decision that would change an AC, and an open log entry, is never taken: append an open entry `By: needs-user` for each such decision ("Scope changes and deviations"), write no scenarios and no decisions, and end your turn with the line `Needs user: SL-<n>` (the first open entry).
Otherwise ask in rounds, at most three. Round 1 asks every open decision, the open log entries first; a later round asks only what the last answers opened (below), never an answered decision again. Each question puts the recommended option first, each option with its trade-off in one line. Write the questions, on a page or listed, in the language your prompt names as the user's (`Write the questions in <language>`); in English when it names none.
1. **Lavish.** Write the round's page: `.lavish/design-<change>.html` for round 1, `.lavish/design-<change>-<round>.html` for a later one (a new file, because the user may have ended the last page's session). Every card follows [the question page](references/question-page.md): a context with today's code (`file:line`), the options with their consequences, and the recommendation with its reason, each section marked; its look follows the Lavish commands that reference names. Check the page as its "Check before opening" says and fix it until every card passes, then open it with `npx -y lavish-axi <page>`. When it opens, end your turn: the first line `Page open: <page>`, then the round's decisions, numbered, the recommended option first. Do not poll: the thread that started you waits for the feedback, so the user can stop the wait, and sends it back as `Answers: ...`. Write nothing else before the answers.
2. **In your reply** when the Lavish open command exits non-zero: list the round's decisions as numbered questions, each with its options, the recommended option first and marked "(recommended)", each option with its trade-off in one line, and end your turn. Write nothing before the answers: the thread that started you asks the user and sends them back.
Resuming: when a round's page exists, `issue.md` holds no `## Key decisions`, and no answers came with the arguments or a message, the user has not answered yet. Check the latest page as [the question page](references/question-page.md) says and fix it in place until every card passes (a page from an earlier run may hold bare cards), open it again with `npx -y lavish-axi <page>`, and end your turn as in 1 with its decisions; write no new page.
When answers arrive, apply them, then look for what they opened:
- a free note asking for something no decision covers: a new decision;
- an answer that adds, drops or narrows an AC, the intent or a "What changes" item of the proposal: a scope change ([Scope changes and deviations](#scope-changes-and-deviations));
- an answer that contradicts the acceptance signal the proposal carries, or a rule of step 2 (`CLAUDE.md`, `.claude/rules/`, an ADR, a rule `bdk rules for` printed): a decision to confirm. Quote the rule and its file or id; options "Follow the rule" (recommended) and "Keep <the answer> as a deviation".
Ask what they opened in the next round. A decision still open after round 3 takes the recommended answer and step 6 marks it `Decided without the user:`; one that would change an AC does not: append it as an open entry `By: needs-user` and end as `decide-and-record` says.
Done when every open decision has an answer.
## 5. Write the acceptance scenarios
Write `## Acceptance scenarios` into `issue.md`, after `## Proposal` (with Edit, replacing an earlier draft's section): behaviour only, one `###` heading per scenario, its name unique in the issue (plan parts and verifiers refer to it as `Scenario: <name>`), then `- WHEN` and `- THEN` lines (`- AND` continues either) that can run against the product:
```markdown
## Acceptance scenarios
### Export skips void entries
- WHEN the ledger holds entries of 5, -2 and a void 10
- AND the user exports it as CSV
- THEN the file holds a header row and two entry rows
```
Put each answer of step 4 where it belongs (a delimiter, a format, a limit is a THEN). Every AC that no `By: user` entry dropped is answered by a scenario. A change with no behaviour to test (a refactoring, tooling, docs) writes `None.` under the heading, and step 6 answers each AC by id.
## 6. Write the key decisions
Write `## Key decisions` into `issue.md`, after the scenarios, the same way:
- `### D1: <the choice>`, D2, ...: the reason; the alternatives and why each lost; an ADR that already decides it is cited (`ADR-0012`), not argued again. A decision that follows from a rule names its id in the reason (`follows IO-1`); one that departs from a rule names the id and the user's agreement. Under every decision taken by policy without asking, or left open after round 3, a line `Decided without the user: <why this answer>`; under a decision that changed the scope or kept a deviation, its `Scope changed by the user:` or `Deviation:` line.
- A small Mermaid diagram under the decision whose flow or structure prose leaves ambiguous, edges labelled.
- `### Risks` from the self-critique of [approaches](references/approaches.md): at least a bottleneck, a failure mode or operational risk, a hidden cost, an assumption the user did not confirm, each `- [risk] -> mitigation`.
- The decisions name the modules, interfaces and data they add or change; the code they build on is in the map. No code. Only decisions a reviewer must know: detail that decides nothing stays out of the issue.
- `### Living documentation`, after the decisions (and before `### Acceptance`), as the next section says.
- With `None.` as the scenarios, a last `### Acceptance` naming each AC id and the decision or module that meets it.
**Living documentation.** The design proposes what the change does to the project's ADRs, module map and glossary; the user accepts it with the design at the gate. One bullet per change, or `- None.` when there is none:
```markdown
### Living documentation
- ADR: ADR-0012 Store the ledger as JSON lines (proposed, docs/adr/ledger/0012-json-lines.md), from D2
- Module map: add `export` (path `src/export`, "Writes the ledger as CSV", uses `ledger`) to docs/architecture.md
- Glossary: add **Void entry**: an entry kept in the ledger but left out of totals and exports. _Avoid_: cancelled entry
```
- **ADR** for each decision that meets the bar of `/bdk:adr`: hard to reverse, surprising without context, the result of a real trade-off. Call the Skill tool with `bdk:adr` and the arguments `Decision of the design stage, status proposed, no issues (the design gate sets them), governs <the path globs it binds>: <the problem, the options with why each lost, the choice>`. Name the ADR it reports. A decision that only follows an ADR in force cites it and needs none; one that reverses an ADR in force supersedes it, and the bullet names both.
- **Module map** for each module the change adds, removes, renames or moves, and each change of a module's responsibility or of the modules it uses: the entry as the map will hold it (id, path, responsibility, uses). A new directory where the map's `sources` (or the directories beside its modules) expect a module is a new module: `bdk arch check` fails on a directory no module holds. Without a module map, a change that adds a module proposes the doc at `docs.architecture`.
- **Glossary** for each domain term the change introduces, renames or gives a new meaning, in the format of `/bdk:glossary` (the term, one sentence, `_Avoid_:` words); a term used against the glossary is an open decision (step 3), not a bullet.
The ADRs are written now, as `proposed`; the map and glossary changes are only proposed here: the plan gives each to the part that makes it true.
**A split.** When the change is too large for one pull request (more than one reviewable pull request's worth, or deliverables that can land apart), propose a split; the user decides at the design gate. Add a decision `### D<n>: Split into sub-issues` naming each piece (its key, title, AC ids and the pieces it waits for) and why; under `## Acceptance scenarios` write only `Split into sub-issues.`; every AC goes to a piece. Write `design/split.json`, each `key` matching `^[a-z0-9-]+$`, `body-file` relative to it:
```json
{ "sub-issues": [
{ "key": "schema", "title": "Void entries in the ledger", "body-file": "sub-schema.md" },
{ "key": "export", "title": "CSV export", "body-file": "sub-export.md", "blocked-by": ["schema"] }
] }
```
and one body file per piece in `design/`: `## Proposal` (`Part of #<parent>.`, the parent's number from `issue.json`, what this piece delivers and its AC ids), `## Acceptance scenarios` (its own, as step 5 says), `## Key decisions` (`The parent's, #<parent>.` and any of its own).
Done when `issue.md` holds both sections, and a proposed split has its files.
## 7. Reply
Reply briefly: the files written, each decision taken without the user, each scope change and deviation, a proposed split with its pieces, and the questions asked with their answers, by round.
## Scope changes and deviations
You own the edits of the `## Proposal` that a user's answer needs, and the entries of the design stage in `scope-log.md`; nothing else changes them after `/bdk:propose`. An AC changes only through an entry `By: user`.
- **Scope change.** An answer of the user that adds, drops, narrows or reinterprets an AC, the intent or a "What changes" item. Before step 5, append an entry to `scope-log.md` with Edit, the next `SL-<n>`:
```markdown
## SL-2
- Stage: design
- Date: <today, YYYY-MM-DD>
- AC: AC-2
- Before: <the AC as it stands>
- After: <the new text, or dropped>
- Why: <what the design found, with file:line>
- Options: <the chosen option>; <each rejected option and why it lost>
- By: user
```
An answer to an open entry adds the line `- Answers: SL-<n>` before `By: user`. Then edit the `## Proposal` with Edit to match: a changed AC keeps its id, its old text struck (`~~...~~`) and the new text after it with `(SL-<n>)`; a dropped AC is struck whole and moves to Out of scope with the reason; Intent and What changes follow. Change nothing else in it. Write no scenario for a dropped AC; in a revision, remove the ones already written. Under the decision, a line `Scope changed by the user: <what changed> (SL-<n>)`.
- **Needs the user.** A change of an AC you cannot ask about (`decide-and-record`, or after round 3): append the same entry with `By: needs-user` and the default under `After:`, change nothing in the Proposal, and never write `Decided without the user:` for it.
- **Deviation.** When the user keeps an answer that contradicts the acceptance signal or a project rule, record it under the decision: `Deviation: <the rule or the acceptance signal> (<its file or rule id, or "proposal">) - <what the user chose and why>`, and move what it drops to Out of scope of the Proposal; when it changes an AC, it is also a scope change with its entry. The design gate shows each deviation and syncs the issue.
## Intent page
Called with `<change> intent page` by the design gate: the scope changed after propose, and the user sees it on one page before approving. Read `scope-log.md`, `issue.md` (`### Intent`, `### Acceptance`, `## Key decisions`) and `source/issue.md` when present, then write `.bdk/runs/<change>/design/intent.html` as [the intent page](references/intent-page.md) says, check it as it says, and write nothing else. Reply with the page path and the entries it shows.
## Fix after a failed verification
Read the latest `verify-N.md`. For each `Must address` item, change the scenarios, the key decisions, `### Living documentation`, a proposed ADR or the split files so the defect is gone: read the code the evidence names before you change a claim about it. For each `Should consider` item, fix it or keep a one-line reason to leave it. Ask the user (step 4) only when a fix changes a decision the user took; under `decide-and-record`, record the new answer instead.
Change only what the items need. Reply with the IDs fixed and the IDs left, each left one with its reason.
## Revise on a request
The text after the Change name is a change the user asked for, often at the design gate of `/bdk:design`. Read `issue.md` and the code the request touches. Change the scenarios and key decisions only as far as the request needs, and the Proposal when it changes the scope ([Scope changes and deviations](#scope-changes-and-deviations)); keep every other decision as it is. A decision the request drops or reverses takes its proposed ADR with it: run `"${CLAUDE_PLUGIN_ROOT}/bin/bdk" adr reject --adr ADR-<NNNN>` (it deletes only a `proposed` record and rewrites the index) and drop its bullet; a decision the request changes gets its proposed ADR edited to match. A request to keep the change whole withdraws a split: move the pieces' scenarios back under `## Acceptance scenarios`, drop the split decision and run `rm .bdk/runs/<change>/design/split.json`. When the request leaves a decision open, ask it as step 4 says (under `decide-and-record`, take the recommended answer and record it).
Reply with what you changed, in a few lines.