sdd-pipeline 1.2.0 → 1.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/sdd.js CHANGED
@@ -4,7 +4,7 @@
4
4
  const path = require('path')
5
5
  const fs = require('fs')
6
6
  const init = require('../lib/init')
7
- const bmad = require('../lib/bmad')
7
+ const bmad = require('../lib/bmad/index')
8
8
  const config = require('../lib/config')
9
9
 
10
10
  const args = process.argv.slice(2)
@@ -15,7 +15,18 @@ switch (cmd) {
15
15
  init.run()
16
16
  break
17
17
  case 'bmad':
18
- bmad.run(args.slice(1).join(' '))
18
+ // Non-interactive mode: run BMAD with just the feature description
19
+ const input = args.slice(1).join(' ')
20
+ if (!input) {
21
+ console.error('Usage: sdd bmad <feature description>')
22
+ process.exit(1)
23
+ }
24
+ // Initialize BMAD session
25
+ const session = bmad.init(input)
26
+ // Generate brief with minimal answers
27
+ const result = bmad.generateBrief()
28
+ console.log(`[OK] BMAD-brief.md created.`)
29
+ console.log(`Confidence: ${result.confidence.score}/100 — ${result.confidence.level}`)
19
30
  break
20
31
  case 'spec':
21
32
  console.log('Run: claude "/sdd-spec" to generate SPEC.md')
@@ -77,6 +77,12 @@ function inferProblem(input) {
77
77
  if (lower.includes('export') || lower.includes('report')) {
78
78
  return 'Users cannot act on their data — business decisions are slowed or made without full information.'
79
79
  }
80
+ if (lower.includes('todo') || lower.includes('task')) {
81
+ return 'Users forget tasks or lack a system to track progress — important items slip through the cracks.'
82
+ }
83
+ if (lower.includes('contact form') || lower.includes('form')) {
84
+ return 'Users cannot easily reach out or submit information — communication barriers reduce engagement.'
85
+ }
80
86
 
81
87
  // Generic fallback
82
88
  return 'Users face a friction point that prevents them from completing their goal — specific symptoms and impact are being confirmed in the interview.'
@@ -0,0 +1,385 @@
1
+ # SDD TASKS Generator - Phase 3
2
+ # Generates tasks including TEST tasks from SPEC.md testing requirements
3
+ $ErrorActionPreference = 'Stop'
4
+
5
+ $SDD_TASKS_DIR = "sdd/tasks"
6
+
7
+ Write-Host ""
8
+ Write-Host "=== SDD TASKS Generator - Phase 3 ===" -ForegroundColor Cyan
9
+ Write-Host ""
10
+
11
+ # Check for SPEC
12
+ $specPath = "sdd/SPEC.md"
13
+ if (-not (Test-Path $specPath)) {
14
+ Write-Host "[ERROR] Phase 2 not complete." -ForegroundColor Red
15
+ Write-Host "sdd/SPEC.md not found." -ForegroundColor Red
16
+ exit 1
17
+ }
18
+ Write-Host "[OK] SPEC.md verified" -ForegroundColor Green
19
+
20
+ # Read SPEC
21
+ $specContent = Get-Content $specPath -Raw -Encoding UTF8
22
+
23
+ # Extract project name
24
+ $projectName = "Project"
25
+ if ($specContent -match "^# SPEC\.md.*?[-—]\s+(.+)$") {
26
+ $projectName = $Matches[1].Trim()
27
+ }
28
+
29
+ # Extract features for testing
30
+ $features = @()
31
+ if ($specContent -match "### 4\.1 Core Features(.+?)(?=###|\Z)" -CaseSensitive:$false) {
32
+ $featuresSection = $Matches[1]
33
+ $featureBlocks = [regex]::Matches($featuresSection, '(?:#### \[([^\]]+)\]|(?:^|\n)- \*\*As a\*\*[^$]+)')
34
+ foreach ($block in $featureBlocks) {
35
+ if ($block.Value -match '\*\*As a\*\*[^,]+,\s*\*\*I want\*\*\s*([^,]+)') {
36
+ $features += $Matches[1].Trim()
37
+ }
38
+ }
39
+ }
40
+
41
+ # Extract test requirements
42
+ $testCategories = @()
43
+ if ($specContent -match "### 9\.1 Test Categories(.+?)(?=###|\Z)" -CaseSensitive:$false) {
44
+ $testSection = $Matches[1]
45
+ if ($testSection -match 'Unit Tests') { $testCategories += 'Unit' }
46
+ if ($testSection -match 'Integration Tests') { $testCategories += 'Integration' }
47
+ if ($testSection -match 'E2E Tests') { $testCategories += 'E2E' }
48
+ if ($testSection -match 'Accessibility Tests') { $testCategories += 'Accessibility' }
49
+ }
50
+
51
+ # Extract user flows for testing
52
+ $userFlows = @()
53
+ if ($specContent -match "Flow:\s*(.+?)(?=\n\s*$|\n\s*\`\`\`)" -CaseSensitive:$false) {
54
+ $userFlows = [regex]::Matches($specContent, "Flow:\s*(.+?)[\n\r]", [System.Text.RegularExpressions.RegexOptions]::Singleline) | ForEach-Object { $_.Groups[1].Value.Trim() }
55
+ }
56
+
57
+ # Extract test specifications
58
+ $unitTests = @()
59
+ if ($specContent -match "(?:### 9\.2 Unit Test Specifications|Unit:\s*(.+?)(?=Unit:|Flow:|\Z))" -CaseSensitive:$false) {
60
+ $unitSection = $Matches[0]
61
+ $unitTests = [regex]::Matches($unitSection, "it\('([^']+)'") | ForEach-Object { $_.Groups[1].Value }
62
+ }
63
+
64
+ # Create task directory
65
+ $TASK_ID = Get-Date -Format "yyyyMMdd-HHmmss"
66
+ $TASK_DIR = "$SDD_TASKS_DIR/task-$TASK_ID-$($projectName.ToLower().Replace(' ', '-'))"
67
+ New-Item -ItemType Directory -Path $TASK_DIR -Force | Out-Null
68
+
69
+ # Build task list
70
+ $taskList = @()
71
+
72
+ # Phase 1: Project Setup
73
+ $taskList += @{
74
+ id = "T-001"
75
+ name = "Project Setup"
76
+ phase = 1
77
+ estimate = "1h"
78
+ depends_on = @()
79
+ content = @"
80
+ ---
81
+ name: T-001-project-setup
82
+ description: "Initial project setup: create directory structure, configuration files, and base code"
83
+ phase: 1
84
+ estimate: 1h
85
+ spec_sections: ["3.1", "4.1"]
86
+ depends_on: []
87
+ ---
88
+
89
+ # T-001: Project Setup
90
+
91
+ ## Files to Create
92
+ - [List files based on tech stack from SPEC Section 6]
93
+
94
+ ## Implementation Steps
95
+ 1. Create project structure
96
+ 2. Set up configuration files
97
+ 3. Create base HTML/CSS/JS files
98
+ 4. Verify initial setup works
99
+
100
+ ## Verification
101
+ - [ ] Project structure matches spec
102
+ - [ ] Configuration files created
103
+ - [ ] Base files load without errors
104
+ "@
105
+ }
106
+
107
+ # Phase 2-4: Feature implementation tasks (placeholder)
108
+ $featurePhase = 2
109
+ $features | ForEach-Object {
110
+ $featureName = $_
111
+ $taskList += @{
112
+ id = "T-00$featurePhase"
113
+ name = "$featureName"
114
+ phase = $featurePhase
115
+ estimate = "1h"
116
+ depends_on = @("T-001")
117
+ content = @"
118
+ ---
119
+ name: T-00$featurePhase-feature
120
+ description: "Implement: $featureName"
121
+ phase: $featurePhase
122
+ estimate: 1h
123
+ spec_sections: ["4.1"]
124
+ depends_on: ["T-001"]
125
+ ---
126
+
127
+ # T-00$featurePhase`: $featureName
128
+
129
+ ## Files to Modify/Create
130
+ - [List files]
131
+
132
+ ## Implementation Steps
133
+ 1. Implement $featureName feature
134
+ 2. Connect to other components
135
+ 3. Test manually
136
+
137
+ ## Verification
138
+ - [ ] Feature works as specified
139
+ - [ ] No console errors
140
+ "@
141
+ }
142
+ $featurePhase++
143
+ }
144
+
145
+ # Phase for testing
146
+ $testPhase = $featurePhase
147
+
148
+ # Add TEST tasks based on categories
149
+ if ($testCategories -contains 'Unit' -or $unitTests.Count -gt 0) {
150
+ $taskList += @{
151
+ id = "T-00$testPhase"
152
+ name = "Unit Tests"
153
+ phase = $testPhase
154
+ estimate = "1h"
155
+ depends_on = @("T-00$($testPhase-1)")
156
+ content = @"
157
+ ---
158
+ name: T-00$testPhase-unit-tests
159
+ description: "Write and run unit tests for core functionality"
160
+ phase: $testPhase
161
+ estimate: 1h
162
+ spec_sections: ["9.1", "9.2"]
163
+ depends_on: ["T-00$($testPhase-1)"]
164
+ ---
165
+
166
+ # T-00$testPhase`: Unit Tests
167
+
168
+ ## Test Files to Create
169
+ - `tests/unit/*.test.js` (or equivalent)
170
+
171
+ ## Unit Tests to Implement
172
+
173
+ ### Core Functions
174
+ ` + ($unitTests -join "`n- `") + @"
175
+
176
+ ### Test Cases
177
+ - Test happy path (valid input)
178
+ - Test error path (invalid input)
179
+ - Test edge cases (empty, null, boundary values)
180
+
181
+ ## Verification
182
+ - [ ] All unit tests pass
183
+ - [ ] Code coverage > 80%
184
+ - [ ] No failing tests
185
+ "@
186
+ }
187
+ $testPhase++
188
+ }
189
+
190
+ if ($testCategories -contains 'Integration') {
191
+ $taskList += @{
192
+ id = "T-00$testPhase"
193
+ name = "Integration Tests"
194
+ phase = $testPhase
195
+ estimate = "1h"
196
+ depends_on = @("T-00$($testPhase-1)")
197
+ content = @"
198
+ ---
199
+ name: T-00$testPhase-integration-tests
200
+ description: "Write integration tests for component interactions"
201
+ phase: $testPhase
202
+ estimate: 1h
203
+ spec_sections: ["9.1", "9.3"]
204
+ depends_on: ["T-00$($testPhase-1)"]
205
+ ---
206
+
207
+ # T-00$testPhase`: Integration Tests
208
+
209
+ ## Test Files to Create
210
+ - `tests/integration/*.test.js`
211
+
212
+ ## Integration Flows to Test
213
+ ` + ($userFlows | ForEach-Object { "- $_" } -join "`n") + @"
214
+
215
+ ## Test Scenarios
216
+ - Verify components interact correctly
217
+ - Test data flow between modules
218
+ - Verify state changes propagate
219
+
220
+ ## Verification
221
+ - [ ] All integration tests pass
222
+ - [ ] Components communicate correctly
223
+ - [ ] State management works
224
+ "@
225
+ }
226
+ $testPhase++
227
+ }
228
+
229
+ if ($testCategories -contains 'E2E') {
230
+ $taskList += @{
231
+ id = "T-00$testPhase"
232
+ name = "End-to-End Tests"
233
+ phase = $testPhase
234
+ estimate = "1h"
235
+ depends_on = @("T-00$($testPhase-1)")
236
+ content = @"
237
+ ---
238
+ name: T-00$testPhase-e2e-tests
239
+ description: "Write E2E tests for complete user workflows"
240
+ phase: $testPhase
241
+ estimate: 1h
242
+ spec_sections: ["9.1", "9.4"]
243
+ depends_on: ["T-00$($testPhase-1)"]
244
+ ---
245
+
246
+ # T-00$testPhase`: End-to-End Tests
247
+
248
+ ## Test Files to Create
249
+ - `tests/e2e/*.test.js`
250
+
251
+ ## E2E Scenarios
252
+ ` + ($userFlows | ForEach-Object { "- $_" } -join "`n") + @"
253
+
254
+ ## Test Approach
255
+ - Use Playwright/Cypress/Selenium
256
+ - Test complete user journeys
257
+ - Verify full application flow
258
+
259
+ ## Verification
260
+ - [ ] All E2E tests pass
261
+ - [ ] User flows complete successfully
262
+ - [ ] No broken links or redirects
263
+ "@
264
+ }
265
+ $testPhase++
266
+ }
267
+
268
+ if ($testCategories -contains 'Accessibility') {
269
+ $taskList += @{
270
+ id = "T-00$testPhase"
271
+ name = "Accessibility Tests"
272
+ phase = $testPhase
273
+ estimate = "1h"
274
+ depends_on = @("T-00$($testPhase-1)")
275
+ content = @"
276
+ ---
277
+ name: T-00$testPhase-a11y-tests
278
+ description: "Verify accessibility compliance (WCAG 2.1 AA)"
279
+ phase: $testPhase
280
+ estimate: 1h
281
+ spec_sections: ["9.1"]
282
+ depends_on: ["T-00$($testPhase-1)"]
283
+ ---
284
+
285
+ # T-00$testPhase`: Accessibility Tests
286
+
287
+ ## Accessibility Requirements (from SPEC Section 3.1)
288
+ - Keyboard navigable
289
+ - Screen reader labels
290
+ - Color contrast compliance
291
+
292
+ ## Test Tools
293
+ - axe-core
294
+ - Lighthouse
295
+ - NVDA/VoiceOver
296
+
297
+ ## Verification
298
+ - [ ] axe-core reports 0 violations
299
+ - [ ] Keyboard navigation works
300
+ - [ ] Screen reader announces content
301
+ - [ ] Color contrast meets WCAG AA
302
+ "@
303
+ }
304
+ $testPhase++
305
+ }
306
+
307
+ # Final phase: Polish and Converge
308
+ $finalPhase = $testPhase
309
+ $taskList += @{
310
+ id = "T-00$finalPhase"
311
+ name = "Final Polish and Converge"
312
+ phase = $finalPhase
313
+ estimate = "1h"
314
+ depends_on = @("T-00$($finalPhase-1)")
315
+ content = @"
316
+ ---
317
+ name: T-00$finalPhase-final-polish
318
+ description: "Final polish, code review, and converge validation"
319
+ phase: $finalPhase
320
+ estimate: 1h
321
+ spec_sections: ["9", "10"]
322
+ depends_on: ["T-00$($finalPhase-1)"]
323
+ ---
324
+
325
+ # T-00$finalPhase`: Final Polish and Converge
326
+
327
+ ## Final Checks
328
+ - [ ] All tests pass
329
+ - [ ] Code follows style guide
330
+ - [ ] No console errors
331
+ - [ ] Responsive design works
332
+ - [ ] Performance acceptable
333
+
334
+ ## Converge Validation
335
+ - Run: `pwsh run-converge.ps1 -Strict`
336
+ - Verify all checks pass
337
+ - Fix any issues found
338
+
339
+ ## Verification
340
+ - [ ] All converge checks pass
341
+ - [ ] Ready for deployment
342
+ "@
343
+ }
344
+
345
+ # Generate MASTER-TASKS.md
346
+ $masterTasks = "# MASTER-TASKS — $projectName`n`n"
347
+ $masterTasks += "## Task Index`n`n"
348
+ $masterTasks += "| ID | Name | Estimate | Status |`n"
349
+ $masterTasks += "|----|------|----------|--------|`n"
350
+
351
+ $totalTasks = $taskList.Count
352
+ $completed = 0
353
+
354
+ $taskList | ForEach-Object {
355
+ $masterTasks += "| $($_.id) | $($_.name) | $($_.estimate) | [ ] |`n"
356
+ }
357
+
358
+ $masterTasks += "`n## Progress`n`n"
359
+ $masterTasks += "- Completed: $completed / $totalTasks`n"
360
+ $masterTasks += "- In Progress: 0`n"
361
+ $masterTasks += "- Pending: $totalTasks`n`n"
362
+ $masterTasks += "## Notes`n`n"
363
+ $masterTasks += "Generated from SPEC.md testing requirements.`n"
364
+ $masterTasks += "Test categories detected: $($testCategories -join ', ')`n"
365
+
366
+ Set-Content -Path "$TASK_DIR/MASTER-TASKS.md" -Value $masterTasks -Encoding UTF8
367
+ Write-Host " [CREATED] MASTER-TASKS.md" -ForegroundColor Gray
368
+
369
+ # Generate task files
370
+ $taskList | ForEach-Object {
371
+ $task = $_
372
+ # Convert ID like T-001 to T-001-name.md
373
+ $safeName = $task.name -replace '[^a-zA-Z0-9]', '-' -replace '-+', '-'
374
+ $filename = "$($task.id)-$($safeName.ToLower()).md"
375
+ Set-Content -Path "$TASK_DIR/$filename" -Value $task.content -Encoding UTF8
376
+ Write-Host " [CREATED] $filename" -ForegroundColor Gray
377
+ }
378
+
379
+ Write-Host ""
380
+ Write-Host "[OK] Tasks created: $TASK_DIR" -ForegroundColor Green
381
+ Write-Host " MASTER-TASKS.md"
382
+ Write-Host " $($taskList.Count) task files"
383
+ Write-Host " Test tasks: $($testCategories -join ', ')"
384
+ Write-Host ""
385
+ Write-Host "Next: claude `/sdd-cook` or manually implement tasks" -ForegroundColor Cyan
@@ -1,6 +1,7 @@
1
- <!-- Template: SPEC.md v3.0.0 -->
1
+ <!-- Template: SPEC.md v3.1.0 -->
2
2
  <!-- Spec-Driven Development — Agent-Optimized SPEC -->
3
3
  <!-- Generated by: SDD Pipeline (2026-08-28) -->
4
+ <!-- Updated: 2026-08-29 — Clause ID tracking added -->
4
5
  <!-- Key: MUST=required, SHOULD=recommended, MUST NOT=forbidden -->
5
6
 
6
7
  # SPEC.md — [Project Name]
@@ -37,26 +38,36 @@
37
38
  ## 3. Exact Content Contracts
38
39
 
39
40
  > **Critical:** These blocks contain EXACT text that MUST appear verbatim in the implementation.
41
+ > **Clause Tracking:** Each contract item has a `[SC-xxx]` ID for automated validation.
40
42
 
41
43
  ### 3.1 Required Text (copy verbatim)
42
44
 
45
+ > **Clause IDs for tracking:** `[SC-001]`, `[SC-002]`, etc.
46
+
43
47
  ```
44
- [Copy exact text here — headlines, button labels, error messages, etc.]
48
+ [SC-001] [Copy exact text here — headlines]
49
+ [SC-002] [Copy exact text here — button labels]
50
+ [SC-003] [Copy exact text here — error messages]
45
51
  ```
46
52
 
47
53
  ### 3.2 Exact Colors
48
54
 
49
- | Element | Hex | Usage |
50
- |---------|-----|-------|
51
- | Primary | `#XXXXXX` | [Usage] |
52
- | Secondary | `#XXXXXX` | [Usage] |
53
- | Error | `#XXXXXX` | [Usage] |
55
+ > **Clause IDs for tracking:** `[SC-COLOR-xxx]`
56
+
57
+ | Clause ID | Element | Hex | Usage |
58
+ |-----------|---------|-----|-------|
59
+ | [SC-COLOR-001] | Primary | `#XXXXXX` | [Usage] |
60
+ | [SC-COLOR-002] | Secondary | `#XXXXXX` | [Usage] |
61
+ | [SC-COLOR-003] | Error | `#XXXXXX` | [Usage] |
54
62
 
55
63
  ### 3.3 Exact Dimensions
56
64
 
57
- | Element | Size | Context |
58
- |---------|------|---------|
59
- | [Element] | [W]x[H]px | [Where] |
65
+ > **Clause IDs for tracking:** `[SC-DIM-xxx]`
66
+
67
+ | Clause ID | Element | Size | Context |
68
+ |-----------|---------|------|---------|
69
+ | [SC-DIM-001] | [Element] | [W]x[H]px | [Where] |
70
+ | [SC-DIM-002] | [Element] | [W]x[H]px | [Where] |
60
71
 
61
72
  ---
62
73
 
@@ -64,7 +75,7 @@
64
75
 
65
76
  ### 4.1 Core Features
66
77
 
67
- #### [Feature Name]
78
+ #### [[SC-FEATURE-001] Feature Name]
68
79
 
69
80
  - **Description:** [What it does]
70
81
  - **BMAD Source:** Architect MVP (Q4) + UX first impression (Q7)
@@ -81,8 +92,8 @@
81
92
  ```
82
93
 
83
94
  **Acceptance criteria:**
84
- - [ ] [Specific, measurable condition]
85
- - [ ] [Specific, measurable condition]
95
+ - [[AC-001]] [Specific, measurable condition]
96
+ - [[AC-002]] [Specific, measurable condition]
86
97
 
87
98
  ### 4.2 User Flows
88
99
 
@@ -173,7 +184,130 @@ Flow: [Flow Name]
173
184
 
174
185
  ---
175
186
 
176
- ## 9. Success Criteria
187
+ ## 9. Testing Requirements
188
+
189
+ > **Critical:** This section defines WHAT to test. Task generator uses this to create test tasks.
190
+
191
+ ### 9.1 Test Categories
192
+
193
+ | Category | Description | Priority |
194
+ |----------|-------------|----------|
195
+ | Unit Tests | Individual function/method testing | MUST |
196
+ | Integration Tests | Component interaction testing | MUST |
197
+ | E2E Tests | Full user flow testing | SHOULD |
198
+ | Visual Tests | UI rendering verification | SHOULD |
199
+ | Accessibility Tests | WCAG compliance | MUST |
200
+
201
+ ### 9.2 Unit Test Specifications
202
+
203
+ > **Format:** `describe([unit]) → it([behavior]) → expect([assertion])`
204
+
205
+ ```
206
+ Unit: [function/module name]
207
+ describe('[unit name]')
208
+ it('[should do X when Y]')
209
+ expect([actual]).to[matcher]([expected])
210
+ ```
211
+
212
+ **Examples:**
213
+ ```
214
+ Unit: addTask()
215
+ describe('addTask()')
216
+ it('should add task to list when input is valid')
217
+ expect(tasks.length).toBe(1)
218
+ it('should show error when input is empty')
219
+ expect(alert).toHaveBeenCalled()
220
+ it('should clear input after adding task')
221
+ expect(input.value).toBe('')
222
+
223
+ Unit: toggleTask()
224
+ describe('toggleTask(id)')
225
+ it('should toggle completed state')
226
+ expect(task.completed).toBe(true)
227
+ it('should persist state to localStorage')
228
+ expect(localStorage.setItem).toHaveBeenCalled()
229
+ ```
230
+
231
+ ### 9.3 Integration Test Specifications
232
+
233
+ ```
234
+ Flow: [user flow name]
235
+ Given: [initial state]
236
+ When: [action]
237
+ Then: [expected outcome]
238
+ ```
239
+
240
+ **Examples:**
241
+ ```
242
+ Flow: Add Task Flow
243
+ Given: empty task list
244
+ When: user types "Buy milk" and clicks Add
245
+ Then: task appears in list with "Buy milk" text
246
+
247
+ Flow: Complete Task Flow
248
+ Given: task "Buy milk" exists
249
+ When: user clicks on task text
250
+ Then: task shows strikethrough, completed=true
251
+
252
+ Flow: Delete Task Flow
253
+ Given: task "Buy milk" exists
254
+ When: user clicks Delete button
255
+ Then: task removed from list, localStorage updated
256
+ ```
257
+
258
+ ### 9.4 E2E Test Specifications
259
+
260
+ ```
261
+ Scenario: [user scenario]
262
+ Given: [prerequisites]
263
+ When: [user actions]
264
+ Then: [system response]
265
+ ```
266
+
267
+ **Examples:**
268
+ ```
269
+ Scenario: Add and complete a task
270
+ Given: browser at app URL
271
+ When: I type "Test task" and submit form
272
+ And: I click on the task text
273
+ Then: I see task with strikethrough
274
+ And: I refresh the page
275
+ And: task is still marked complete
276
+
277
+ Scenario: Empty input validation
278
+ Given: browser at app URL
279
+ When: I click Add button with empty input
280
+ Then: I see validation error message
281
+ And: no task is added
282
+ ```
283
+
284
+ ### 9.5 Test Data
285
+
286
+ > **Known inputs for testing:**
287
+
288
+ | Test Case | Input | Expected Output |
289
+ |-----------|-------|-----------------|
290
+ | Valid task | "Buy groceries" | Task added to list |
291
+ | Empty task | "" | Validation error |
292
+ | Long task | "[200+ chars]" | Task added (truncated display) |
293
+ | Duplicate task | "Same task" (x2) | Both tasks added |
294
+ | Special chars | "Task <script>" | Sanitized, displayed safely |
295
+
296
+ ### 9.6 Test Verification Checklist
297
+
298
+ > **sdd-tasks generates test tasks from this checklist.**
299
+
300
+ For each feature in Section 4.1:
301
+
302
+ - [ ] Unit test: Happy path
303
+ - [ ] Unit test: Error path
304
+ - [ ] Unit test: Edge case
305
+ - [ ] Integration test: Component interaction
306
+ - [ ] E2E test: Full user flow
307
+
308
+ ---
309
+
310
+ ## 10. Success Criteria
177
311
 
178
312
  > **Agent instruction:** These criteria define "done". All MUST pass before marking complete.
179
313
 
@@ -184,7 +318,7 @@ Flow: [Flow Name]
184
318
 
185
319
  ---
186
320
 
187
- ## 10. Decision Log
321
+ ## 11. Decision Log
188
322
 
189
323
  > **Agent instruction:** This log explains WHY. Read when uncertain about intent.
190
324
 
@@ -194,7 +328,7 @@ Flow: [Flow Name]
194
328
 
195
329
  ---
196
330
 
197
- ## 11. Anti-Patterns (Do NOT do)
331
+ ## 12. Anti-Patterns (Do NOT do)
198
332
 
199
333
  > **Agent warning:** These patterns were explicitly rejected. Do not suggest or implement.
200
334
 
@@ -205,15 +339,33 @@ Flow: [Flow Name]
205
339
 
206
340
  ## Agent Verification Checklist
207
341
 
342
+ > **Updated v3.1:** Use clause IDs `[SC-xxx]` for automated tracking.
343
+
208
344
  Before marking implementation complete, verify:
209
345
 
346
+ - [ ] All clause IDs tracked: `[SC-001]`, `[SC-002]`, etc.
210
347
  - [ ] All "Required Text" (Section 3.1) appears verbatim
211
348
  - [ ] All colors match hex values in Section 3.2 exactly
212
349
  - [ ] All dimensions match Section 3.3 exactly
213
- - [ ] All acceptance criteria in Section 4.1 checked
350
+ - [ ] All acceptance criteria `[AC-xxx]` in Section 4.1 checked
214
351
  - [ ] All user flows implemented as specified
215
352
  - [ ] All edge cases handled as specified
216
353
  - [ ] All data contracts match schemas exactly
217
354
  - [ ] No items from Out of Scope (Section 7) implemented
218
355
  - [ ] All Open Questions resolved or escalated
219
356
  - [ ] All Success Criteria met
357
+ - [ ] Converge report generated in `converge/task-T-XXX.md`
358
+
359
+ ---
360
+
361
+ ## Clause Index
362
+
363
+ > **Auto-generated index of all clause IDs for easy reference.**
364
+
365
+ | Clause ID | Type | Location | Text |
366
+ |-----------|------|----------|------|
367
+ | [SC-001] | Text | §3.1 | [excerpt] |
368
+ | [SC-002] | Text | §3.1 | [excerpt] |
369
+ | [SC-COLOR-001] | Color | §3.2 | [excerpt] |
370
+ | [SC-FEATURE-001] | Feature | §4.1 | [excerpt] |
371
+ | [AC-001] | Criterion | §4.1 | [excerpt] |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sdd-pipeline",
3
- "version": "1.2.0",
3
+ "version": "1.2.2",
4
4
  "description": "Spec-Driven Development pipeline for Claude Code — organized output structure (sdd/brief.md, sdd/SPEC.md, sdd/tasks/, sdd/converge/)",
5
5
  "bin": {
6
6
  "sdd": "bin/sdd.js"