You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
2.**Context Assessment** - Review existing codebase for relevant patterns and constraints (optional)
60
+
3.**Initial Scope Assessment** - Evaluate if the feature is appropriately sized for this workflow
61
+
4.**Clarifying Questions** - Gather detailed requirements through structured inquiry
62
+
5.**Spec Generation** - Create the detailed specification document
63
+
6.**Review and Refine** - Validate completeness and clarity with the user
63
64
64
-
## Step 1: Initial Scope Assessment
65
+
## Step 1: Create Spec Directory
65
66
66
-
Before asking questions, evaluate whether this feature request is appropriately sized for this spec-driven workflow.
67
+
Create the spec directory structure before proceeding with any other steps. This ensures all files (questions, spec, tasks, proofs) have a consistent location.
68
+
69
+
**Directory Structure:**
70
+
71
+
-**Path**: `./docs/specs/[NN]-spec-[feature-name]/` where `[NN]` is a zero-padded 2-digit sequence number (e.g., `01`, `02`, `03`)
72
+
-**Naming Convention**: Use lowercase with hyphens for the feature name
73
+
-**Examples**: `01-spec-user-authentication/`, `02-spec-payment-integration/`, etc.
74
+
75
+
**Verification**: Confirm the directory exists before proceeding to Step 2.
76
+
77
+
## Step 2: Context Assessment
78
+
79
+
If working in a pre-existing project, begin by briefly reviewing the codebase and existing docs to understand:
80
+
81
+
- Current architecture patterns and conventions
82
+
- Relevant existing components or features
83
+
- Integration constraints or dependencies
84
+
- Files that might need modification or extension
85
+
-**Repository Standards and Patterns**: Identify existing coding standards, architectural patterns, and development practices from:
- Testing patterns and quality assurance practices
91
+
- Commit message conventions and development workflows
92
+
93
+
**Use this context to inform scope validation and requirements, not to drive technical decisions.** Focus on understanding what exists to make the spec more realistic and achievable, and ensure any implementation will follow the repository's established patterns.
94
+
95
+
## Step 3: Initial Scope Assessment
96
+
97
+
Evaluate whether this feature request is appropriately sized for this spec-driven workflow.
67
98
68
99
**Chain-of-thought reasoning:**
69
100
70
101
- Consider the complexity and scope of the requested feature
71
102
- Compare against the following examples
103
+
- Use context from Step 2 to inform the assessment
72
104
- If scope is too large, suggest breaking into smaller specs
73
105
- If scope is too small, suggest direct implementation without formal spec
74
106
@@ -104,11 +136,11 @@ Before asking questions, evaluate whether this feature request is appropriately
104
136
105
137
If the scope appears inappropriate, inform the user and suggest alternatives before proceeding.
106
138
107
-
## Step 2: Clarifying Questions
139
+
## Step 4: Clarifying Questions
108
140
109
-
Ask clarifying questions to gather sufficient detail. **Always provide numbered or lettered options** to allow the user to make selections easily by responding with *"1A, 2B, 3C"*, etc. Focus on understanding the "what" and "why" rather than the "how."
141
+
Ask clarifying questions to gather sufficient detail. **Always provide multiple choice answers** with numbered or lettered options to allow the user to make selections easily. Focus on understanding the "what" and "why" rather than the "how."
110
142
111
-
Adapt your questions based on the user's input. Use the following common areas to guide your questions:
143
+
Use the following common areas to guide your questions:
112
144
113
145
**Core Understanding:**
114
146
@@ -133,24 +165,21 @@ Adapt your questions based on the user's input. Use the following common areas t
133
165
134
166
**Progressive Disclosure:** Start with Core Understanding, then expand based on feature complexity and user responses.
135
167
136
-
## Step 3: Context Assessment (Optional)
168
+
**Questions File Workflow:**
137
169
138
-
If the feature involves existing systems, briefly review the codebase and existing docs to understand:
170
+
1.**Create Questions File**: Save questions to `[NN]-questions-[N]-[feature-name].md` where `[N]` is the round number (starting at 1, incrementing for each new round).
171
+
2.**Point User to File**: Direct the user to the questions file and instruct them to answer the questions directly in the file.
172
+
3.**Wait for Confirmation**: After the user indicates they have saved their answers, read the file and continue the conversation.
173
+
4.**Follow-Up Rounds**: If answers reveal new questions, create a new questions file with incremented round number (`[NN]-questions-[N+1]-[feature-name].md`) and repeat the process.
139
174
140
-
- Current architecture patterns and conventions
141
-
- Relevant existing components or features
142
-
- Integration constraints or dependencies
143
-
- Files that might need modification or extension
144
-
-**Repository Standards and Patterns**: Identify existing coding standards, architectural patterns, and development practices from:
- Testing patterns and quality assurance practices
149
-
- Commit message conventions and development workflows
175
+
**Iterative Process:**
150
176
151
-
**Use this context to inform scope validation and requirements, not to drive technical decisions.** Focus on understanding what exists to make the spec more realistic and achievable, and ensure any implementation will follow the repository's established patterns.
177
+
- If a user's answer reveals new questions or areas needing clarification, ask follow-up questions in a new questions file.
178
+
- If the user requests clarification or rephrasing of a question, provide it in the current questions file and continue the conversation.
179
+
- Build on previous answers - use context from earlier responses to inform subsequent questions.
180
+
- Continue until you have enough detail to populate all spec sections (User Stories, Functional Requirements, Demoable Units, etc.), then proceed to Step 5.
152
181
153
-
## Step 4: Spec Generation
182
+
## Step 5: Spec Generation
154
183
155
184
Generate a comprehensive specification using this exact structure:
156
185
@@ -174,11 +203,13 @@ Generate a comprehensive specification using this exact structure:
174
203
[Focus on tangible progress and WHAT will be demonstrated. Define 2-4 small, end-to-end vertical slices using the format below.]
175
204
176
205
### [Unit 1]: [Title]
206
+
177
207
**Purpose:** [What this slice accomplishes and who it serves]
178
208
**Demo Criteria:** [What will be shown to verify working value]
@@ -206,12 +237,13 @@ Generate a comprehensive specification using this exact structure:
206
237
## Repository Standards
207
238
208
239
[Identify existing patterns and practices that implementation should follow. Examples include:
240
+
209
241
- Coding standards and style guides from the repository
210
242
- Architectural patterns and file organization
211
243
- Testing conventions and quality assurance practices
212
244
- Documentation patterns and commit conventions
213
245
- Build and deployment workflows
214
-
If no specific standards are identified, state "Follow established repository patterns and conventions."]
246
+
If no specific standards are identified, state "Follow established repository patterns and conventions."]
215
247
216
248
## Technical Considerations
217
249
@@ -233,7 +265,7 @@ If no specific standards are identified, state "Follow established repository pa
233
265
2. [Question 2]
234
266
```
235
267
236
-
## Step 5: Review and Refinement
268
+
## Step 6: Review and Refinement
237
269
238
270
After generating the spec, present it to the user and ask:
239
271
@@ -247,9 +279,8 @@ Iterate based on feedback until the user is satisfied.
247
279
## Output Requirements
248
280
249
281
**Format:** Markdown (`.md`)
250
-
**Directory:** Create `./docs/specs/[NN]-spec-[feature-name]/` where `[NN]` is a zero-padded 2-digit sequence number starting from 01 (e.g., `01`, `02`, `03`). For example, `01-spec-user-authentication/`, `02-spec-payment-integration/`, etc.
**Example:** For feature "user authentication", create directory `01-spec-user-authentication/`and save file as `01-spec-user-authentication.md` inside it
283
+
**Example:** For feature "user authentication", the spec directory would be `01-spec-user-authentication/`with a spec file as `01-spec-user-authentication.md` inside it
253
284
254
285
## Critical Constraints (Negative Instructions)
255
286
@@ -280,16 +311,17 @@ Once this spec is complete and approved, instruct the user to run `/generate-tas
280
311
281
312
Follow this exact sequence:
282
313
283
-
1.**Initial Scope Assessment**: Use the provided examples to evaluate if the feature is appropriately sized
284
-
2.**Clarifying Questions**: Ask structured questions with numbered/lettered options for easy selection
285
-
3.**Context Assessment**: Review existing codebase for relevant patterns and constraints (optional)
286
-
4.**Spec Generation**: Create the spec using the exact structure provided
0 commit comments