بنقرة واحدة
2-design
Use when entering design phase — architecture options with trade-offs, design pattern research
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Use when entering design phase — architecture options with trade-offs, design pattern research
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
Use when closing a finished milestone — writes MILESTONE.yml so /quangflow:status hides it from default view
Use when starting a new project or feature — scans codebase, creates CONTEXT.md, detects project type
Use when entering requirements phase — clarifying questions, edge cases, milestone splits, team composition
Use when entering execution handoff — ROADMAP generation, TDD/logging mandates, SHIP/REFINE gate
Use when entering verification — TDD compliance audit, evidence certification, gap detection
Use when project is shipped — systematic debugging, structured log scan, bug triage, hotfix
| name | 2-design |
| description | Use when entering design phase — architecture options with trade-offs, design pattern research |
You are now entering Phase 2: Design / Structure.
See _protocols/_shared.md → State Check Template. Required artifact: REQUIREMENTS.md.
If none found: "No requirements found. Run /quangflow:1-brainstorm <idea> first."
See _protocols/_shared.md → Milestone Detection. Target artifact: DESIGN.md.
Only consider requirements tagged for the current milestone. Reference project-level CONTEXT.md for any locked decisions from previous milestones.
See _protocols/_autopilot.md → Phase 2 — Design. If pm_mode: autopilot: auto-pick best option, skip to review gate.
If hands-on or not set: proceed with normal flow below.
See _protocols/_shared.md → GOTCHAs System → Review Protocol.
Read both plans/GOTCHAS.md (global) and plans/{feature-slug}/GOTCHAS.md (feature) if they exist. Filter by tags relevant to this milestone's domain (e.g., design, database, auth, etc.).
If relevant gotchas found: present them (prefixed [global] or [{feature}]) before tension analysis so they inform design decisions.
List the "tension points" in this milestone's requirements:
For the problem domain of this milestone, research applicable software design patterns:
Identify the core problem types in this milestone's requirements:
Evaluate each candidate pattern against the actual requirements:
Present only patterns that genuinely fit (max 3): "Applicable design patterns for this milestone:
Integrate chosen patterns into the design options below.
Propose EXACTLY 2-3 structural options. For each option include:
Before proceeding, you MUST:
Agent waits. Does nothing until user picks an option.
Write DESIGN.md to ./plans/{feature-slug}/milestone-{N}/DESIGN.md containing:
Include a Mermaid diagram at the top of DESIGN.md showing the high-level architecture:
graph LR (left-to-right) — group by layer: Frontend → Backend → Storage → Externaldesign/ subfolder.Example structure in DESIGN.md:
# Milestone {N} — Design
...
## Architecture Overview
\`\`\`mermaid
graph LR
subgraph FE["Frontend"]
...
end
subgraph BE["Backend"]
...
end
subgraph DB["Storage"]
...
end
subgraph EXT["External"]
...
end
FE -->|requests| BE
BE -->|read/write| DB
...
\`\`\`
This diagram gives readers instant visual context before reading detailed sections.
If REQUIREMENTS.md has team_mode: true, refine the team based on the chosen architecture:
Re-read team_composition from REQUIREMENTS.md
Compare against the chosen design — the architecture may reveal:
Present updated composition:
"Based on the chosen architecture, I'd refine the team:
| Change | Before | After | Reason |
|---|---|---|---|
| Split | dev-backend | dev-api + dev-data | Separate API layer from data layer per chosen design |
| Merge | dev-infra | → into dev-backend | Infra scope too small for dedicated role |
| Add | — | dev-worker | Architecture includes async job queue |
Updated team:
| Role | Focus | File Ownership |
|---|---|---|
| ... | ... | ... |
Adjust or approve?"
If user approves or adjusts, update team_composition in REQUIREMENTS.md
If user says "no changes needed", keep existing composition
Skip this section entirely if team_mode: false or not set.
See _protocols/_shared.md → Output Rule.
See _protocols/_shared.md → Progress Tracking. Append Phase 2 row to plans/{feature-slug}/PROGRESS.md.
Key decisions to log: chosen option name, patterns applied, team refinements.
Tell user: "Phase 2 complete for milestone-{N}. Design saved to ./plans/{feature-slug}/milestone-{N}/DESIGN.md."
Then suggest next command:
**Next:** `/quangflow:3-handoff` — Generate execution artifacts (ROADMAP, CONTEXT, team pipeline)
↳ Skip? Not recommended — Phase 3 produces the ROADMAP that devs/team follow
↳ Also available: `/quangflow:status` (check status), `/quangflow:status save` (save context)