Prompt file imported from kzsoftworks/windsurf-workflows (
.windsurf/workflows/2-design.md). Copyright stays with the author.
Design Workflow
When to use
This workflow activates when:
- User types
/design - User asks for implementation options
- User wants to explore different approaches
Prerequisites
- Discovery must be complete (check
docs/development/current-task.md) - If Discovery not done, suggest running
/discoveryfirst
Steps
-
Load context
- Read
docs/development/current-task.md - Review Discovery findings (current state and gaps)
- Verify Design stage is not already complete
- Read
-
Generate design alternatives Based on gaps identified, create 2-3 distinct approaches:
## DESIGN OPTIONS ### Option A: [Descriptive Name] **Approach:** [High-level description] **Implementation Details:** - [Key implementation point] - [Key implementation point] **Pros:** - ✅ [Advantage] - ✅ [Advantage] **Cons:** - ❌ [Disadvantage] - ❌ [Disadvantage] **Effort:** ⭐⭐⭐ (1-5 scale) **Risk:** Low/Medium/High --- ### Option B: [Descriptive Name] [Same structure] --- ### Option C: [Descriptive Name] [Same structure] -
Provide comparison matrix
## COMPARISON | Aspect | Option A | Option B | Option C | |--------|----------|----------|----------| | Development Time | [Estimate] | [Estimate] | [Estimate] | | Complexity | [Level] | [Level] | [Level] | | Maintainability | [Rating] | [Rating] | [Rating] | | Performance | [Rating] | [Rating] | [Rating] | | Scalability | [Rating] | [Rating] | [Rating] | -
Ask for decision Questions to ask:
- "Which option aligns best with your priorities?"
- "Would you like me to elaborate on any option?"
- "Should we combine aspects from multiple options?"
- "Are there other approaches you'd like me to consider?"
-
Document decision Once user selects an approach:
- Confirm the choice
- Ask for any modifications to the selected approach
- Document reasons for selection
-
Update task file Update the Design Decisions section in
docs/development/current-task.md:## Design Decisions <!-- Updated by /design workflow --> ### Selected Approach - **Option:** [Selected option name] - **Key Points:** [Main implementation details] ### Rationale - [Why this option was chosen] - [Key benefits expected] ### Rejected Alternatives - Option [X]: [Why rejected] - Option [Y]: [Why rejected] -
Update progress tracker Mark Design as complete:
| Design | ✅ | [Date] | Selected: [approach name] | -
Add to decision log
- [Date] Design - Selected [approach name] - [Brief rationale] -
Create implementation plan Break down the selected approach:
## IMPLEMENTATION PLAN 1. [First component/task] - Create [file/component] - Implement [functionality] 2. [Second component/task] - Modify [existing file] - Add [new feature] 3. [Continue...] -
Suggest next step Output:
✅ Design Phase Complete Selected approach: [Name] I've documented the decision and created an implementation plan in `docs/development/current-task.md`. Next step: Run `/implement` to start building the solution. Would you prefer incremental implementation (with checkpoints) or continuous?
Important Notes
- Always provide meaningful alternatives, not just variations
- Consider existing code and patterns from discovery
- Be realistic about effort and complexity estimates
- Document why alternatives were rejected
- Break down implementation into clear steps