Write a Design Doc
Create the smallest design document that lets a reviewer understand the decision and lets a planner proceed without inventing core behavior.
Establish the design basis
- Read the conversation, linked briefs, research, decision records, and relevant project material.
- Synthesize settled context. Do not restart the discovery interview or ask the user to repeat information already available.
- Inspect the existing system where the proposal must fit. Confirm paths, interfaces, constraints, and conventions before relying on them.
- Confirm the project context and design accordingly:
- Greenfield: Distinguish proposed foundations from observed facts and
settle the platform, structure, ownership, and bootstrap decisions needed
for planning.
- Existing system: Make current behavior, integration points,
conventions, compatibility, migration, and preserved behavior explicit.
- Hybrid: Define the new and existing sides separately, then make their
boundary, contract, ownership, and failure behavior concrete.
Do not infer
Greenfield from missing repository access alone.
- Separate the input into:
- Known facts: supported by evidence.
- Decisions: choices already made, with their rationale.
- Assumptions: beliefs that still require validation and the consequence if wrong.
- Open questions: unresolved choices, marked as blocking or non-blocking.
- Investigate discoverable facts directly. Ask the user only for consequential decisions that cannot be inferred safely.
Scale the depth to risk
Classify the change as low, medium, or high risk using reversibility, blast radius, novelty, data sensitivity, migration difficulty, external dependencies, and operational burden. State the classification and why it applies.
Read design-coverage.md to select the concerns that deserve treatment. Cover every core concern, then add conditional concerns in proportion to risk. Do not inflate a local, reversible change into an architecture treatise, and do not compress an irreversible change into a happy-path sketch.
Draft the document
Copy and adapt design-doc-template.md. Preserve an established project template when one exists, while ensuring the same decisions remain visible.
Write for a capable reader who was not part of the conversation:
- Define the problem, desired outcome, scope, and non-goals before describing mechanics.
- Record the chosen direction and the meaningful alternatives rejected.
- Make boundaries, ownership, user and system flows, interfaces, data behavior, and failure recovery concrete where applicable.
- Explain why each material choice fits the constraints and what trade-off it accepts.
- Use diagrams, examples, or pseudocode only when they remove ambiguity.
- Cite evidence for externally verifiable claims. Do not present guesses as facts.
- Prefer stable responsibilities and contracts over speculative file lists or implementation code.
- Record risks, rabbit holes, mitigations, rollout, rollback, and verification at the depth warranted by the risk classification.
Test the design on paper
Walk representative success, failure, recovery, and boundary scenarios through the proposed design. Check that each stated goal has observable evidence of success and that each important constraint is reflected in a decision. Surface contradictions instead of smoothing them over.
Declare readiness
Mark the document ready for review only when:
- The problem, outcome, scope, and non-goals agree with the established brief.
- The chosen direction and its consequential trade-offs are explicit.
- Critical flows, boundaries, contracts, data changes, and failure behavior are concrete enough for the assessed risk.
- Assumptions include validation actions, and open questions identify their impact and next decision-maker.
- Validation, rollout, recovery, and ownership are credible where applicable.
- A planner can decompose the work without inventing product behavior or architectural choices.
Otherwise mark it not ready, name the blocking decisions or evidence, and recommend the smallest next action.
Present the completed document and readiness result. Ask the user to accept it
as ready for independent review or request revisions. Stop there: do not review
the document, create an implementation plan, or begin implementation unless the
user separately asks for that work.
1---2name: write-design-doc3description: Turn an approved idea brief, selected solution direction, or established product and technical context into a risk-scaled design document. Use when a direction has been chosen and implementation needs concrete boundaries, flows, interfaces, data behavior, failure handling, validation, and delivery decisions, or when an existing draft needs to become ready for independent review and planning.4---56# Write a Design Doc78Create the smallest design document that lets a reviewer understand the decision and lets a planner proceed without inventing core behavior.910## Establish the design basis11121. Read the conversation, linked briefs, research, decision records, and relevant project material.132. Synthesize settled context. Do not restart the discovery interview or ask the user to repeat information already available.143. Inspect the existing system where the proposal must fit. Confirm paths, interfaces, constraints, and conventions before relying on them.154. Confirm the project context and design accordingly:16 - **Greenfield:** Distinguish proposed foundations from observed facts and17 settle the platform, structure, ownership, and bootstrap decisions needed18 for planning.19 - **Existing system:** Make current behavior, integration points,20 conventions, compatibility, migration, and preserved behavior explicit.21 - **Hybrid:** Define the new and existing sides separately, then make their22 boundary, contract, ownership, and failure behavior concrete.23 Do not infer `Greenfield` from missing repository access alone.245. Separate the input into:25 - **Known facts:** supported by evidence.26 - **Decisions:** choices already made, with their rationale.27 - **Assumptions:** beliefs that still require validation and the consequence if wrong.28 - **Open questions:** unresolved choices, marked as blocking or non-blocking.296. Investigate discoverable facts directly. Ask the user only for consequential decisions that cannot be inferred safely.3031## Scale the depth to risk3233Classify the change as low, medium, or high risk using reversibility, blast radius, novelty, data sensitivity, migration difficulty, external dependencies, and operational burden. State the classification and why it applies.3435Read [design-coverage.md](references/design-coverage.md) to select the concerns that deserve treatment. Cover every core concern, then add conditional concerns in proportion to risk. Do not inflate a local, reversible change into an architecture treatise, and do not compress an irreversible change into a happy-path sketch.3637## Draft the document3839Copy and adapt [design-doc-template.md](assets/design-doc-template.md). Preserve an established project template when one exists, while ensuring the same decisions remain visible.4041Write for a capable reader who was not part of the conversation:4243- Define the problem, desired outcome, scope, and non-goals before describing mechanics.44- Record the chosen direction and the meaningful alternatives rejected.45- Make boundaries, ownership, user and system flows, interfaces, data behavior, and failure recovery concrete where applicable.46- Explain why each material choice fits the constraints and what trade-off it accepts.47- Use diagrams, examples, or pseudocode only when they remove ambiguity.48- Cite evidence for externally verifiable claims. Do not present guesses as facts.49- Prefer stable responsibilities and contracts over speculative file lists or implementation code.50- Record risks, rabbit holes, mitigations, rollout, rollback, and verification at the depth warranted by the risk classification.5152## Test the design on paper5354Walk representative success, failure, recovery, and boundary scenarios through the proposed design. Check that each stated goal has observable evidence of success and that each important constraint is reflected in a decision. Surface contradictions instead of smoothing them over.5556## Declare readiness5758Mark the document **ready for review** only when:5960- The problem, outcome, scope, and non-goals agree with the established brief.61- The chosen direction and its consequential trade-offs are explicit.62- Critical flows, boundaries, contracts, data changes, and failure behavior are concrete enough for the assessed risk.63- Assumptions include validation actions, and open questions identify their impact and next decision-maker.64- Validation, rollout, recovery, and ownership are credible where applicable.65- A planner can decompose the work without inventing product behavior or architectural choices.6667Otherwise mark it **not ready**, name the blocking decisions or evidence, and recommend the smallest next action.6869Present the completed document and readiness result. Ask the user to accept it70as ready for independent review or request revisions. Stop there: do not review71the document, create an implementation plan, or begin implementation unless the72user separately asks for that work.