specsmd 0.1.1 → 0.1.3

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.
Files changed (24) hide show
  1. package/flows/aidlc/skills/construction/bolt-start.md +106 -78
  2. package/flows/aidlc/skills/inception/bolt-plan.md +18 -5
  3. package/flows/aidlc/skills/inception/review.md +1 -1
  4. package/flows/aidlc/skills/inception/units.md +17 -13
  5. package/flows/aidlc/skills/operations/monitor.md +1 -1
  6. package/flows/aidlc/templates/construction/bolt-template.md +25 -4
  7. package/flows/aidlc/templates/construction/bolt-types/ddd-construction-bolt/ddd-01-domain-model-template.md +2 -2
  8. package/flows/aidlc/templates/construction/bolt-types/ddd-construction-bolt/ddd-02-technical-design-template.md +2 -2
  9. package/flows/aidlc/templates/construction/bolt-types/ddd-construction-bolt/ddd-03-test-report-template.md +2 -2
  10. package/flows/aidlc/templates/construction/bolt-types/simple-construction-bolt.md +5 -0
  11. package/flows/aidlc/templates/construction/construction-log-template.md +2 -2
  12. package/flows/aidlc/templates/inception/inception-log-template.md +1 -1
  13. package/flows/aidlc/templates/inception/requirements-template.md +1 -1
  14. package/flows/aidlc/templates/inception/stories-template.md +1 -1
  15. package/flows/aidlc/templates/inception/story-template.md +11 -11
  16. package/flows/aidlc/templates/inception/system-context-template.md +1 -1
  17. package/flows/aidlc/templates/inception/unit-brief-template.md +3 -3
  18. package/flows/aidlc/templates/inception/units-template.md +1 -1
  19. package/lib/analytics/tracker.js +40 -13
  20. package/lib/installer.js +19 -5
  21. package/package.json +2 -1
  22. package/scripts/artifact-validator.js +594 -0
  23. package/scripts/bolt-complete.js +606 -0
  24. package/scripts/status-integrity.js +598 -0
@@ -182,13 +182,31 @@ Ready to proceed?
182
182
 
183
183
  If the bolt type specifies automatic validation criteria, follow those rules.
184
184
 
185
+ ### 8b. Final Stage Checkpoint (CRITICAL RE-READ)
186
+
187
+ **⚠️ If this is the FINAL stage of the bolt**, before presenting completion:
188
+
189
+ 1. **STOP** and re-read **Step 10** from this skill
190
+ 2. This step is often skipped due to context distance - re-reading prevents this
191
+ 3. Do NOT report bolt as complete until you have executed Step 10
192
+
193
+ ```text
194
+ ┌─────────────────────────────────────────────────────────────┐
195
+ │ FINAL STAGE DETECTED │
196
+ │ → Re-read Step 10 NOW │
197
+ │ → You MUST run: node .specsmd/scripts/bolt-complete.js │
198
+ │ → Do NOT manually edit story files │
199
+ └─────────────────────────────────────────────────────────────┘
200
+ ```
201
+
185
202
  ### 9. Update Bolt File on Stage Completion
186
203
 
204
+ **Trigger**: After EACH stage completion (not just final stage).
205
+
187
206
  After each stage completion:
188
207
 
189
208
  - Add stage to `stages_completed` with timestamp
190
209
  - Update `current_stage` to next stage
191
- - If final stage, set `status: completed` and `completed` timestamp
192
210
 
193
211
  **⚠️ TIMESTAMP FORMAT**: See `memory-bank.yaml` → `conventions.timestamps`
194
212
 
@@ -197,112 +215,97 @@ After each stage completion:
197
215
  status: in-progress
198
216
  current_stage: {next-stage-from-bolt-type}
199
217
  stages_completed:
200
- - {stage-name}: {timestamp}
218
+ - name: {stage-name}
219
+ completed: {timestamp}
220
+ artifact: {artifact-filename}
201
221
  ---
202
222
  ```
203
223
 
204
- **On bolt completion**, also update:
205
-
206
- ```yaml
207
- completed: {timestamp}
208
- ```
209
-
210
- #### Update Story Status (On Bolt Completion)
211
-
212
- When marking a bolt as `status: complete`, update all stories in the bolt's `stories` array:
224
+ **If this is the FINAL stage**, proceed to **Step 10** (bolt completion).
213
225
 
214
- 1. **Read bolt's stories**: Get story IDs from bolt frontmatter `stories: [001-story-name, 002-story-name, ...]`
215
- 2. **Locate story files**: `{intent}/units/{unit}/stories/{story-id}.md`
216
- 3. **Update each story frontmatter**:
226
+ **If this is NOT the final stage**, update bolt file and proceed to next stage. Stop here.
217
227
 
218
- ```yaml
219
- # Change from
220
- status: draft
221
- implemented: false
228
+ ---
222
229
 
223
- # To
224
- status: complete
225
- implemented: true
226
- ```
230
+ ### 10. Mark Bolt Complete (HARD GATE - MANDATORY ON FINAL STAGE)
227
231
 
228
- **Example**:
232
+ **Trigger**: ONLY when this is the FINAL stage.
229
233
 
230
234
  ```text
231
- Bolt stories: [001-create-role, 002-manage-permissions, 003-view-roles]
232
-
233
- Updated:
234
- ✅ stories/001-create-role.md status: complete, implemented: true
235
- ✅ stories/002-manage-permissions.md status: complete, implemented: true
236
- ✅ stories/003-view-roles.md → status: complete, implemented: true
235
+ HARD GATE - SCRIPT EXECUTION REQUIRED
236
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
237
+ You CANNOT report bolt completion without:
238
+ 1. Running the bolt-complete.js script
239
+ 2. Showing the script output to the user
240
+
241
+ If you skip this, the memory-bank becomes inconsistent.
242
+ Do NOT manually edit story files - the script handles everything.
237
243
  ```
238
244
 
239
- This ensures the memory-bank reflects actual implementation status and the VS Code extension shows correct completion indicators.
245
+ **Run this command:**
240
246
 
241
- #### Update Unit & Intent Status (Status Cascade)
247
+ ```bash
248
+ node .specsmd/scripts/bolt-complete.js {bolt-id}
249
+ ```
242
250
 
243
- Status changes cascade upward: Bolt → Story → Unit → Intent.
251
+ **What this command does (deterministically):**
244
252
 
245
- **On Bolt Start** (when changing from `planned` to `in-progress`):
253
+ 1. Updates bolt file to `status: complete`
254
+ 2. Updates ALL stories in bolt's `stories` array to `status: complete, implemented: true`
255
+ 3. Updates unit status if all bolts for unit are complete
256
+ 4. Updates intent status if all units for intent are complete
246
257
 
247
- 1. **Update Unit Status**:
248
- - Read unit-brief: `{intent}/units/{unit}/unit-brief.md`
249
- - If unit status is `stories-defined` or `stories-updated` → change to `in-progress`
258
+ **Example output:**
250
259
 
251
- 2. **Update Intent Status**:
252
- - Read requirements: `{intent}/requirements.md`
253
- - If intent status is `units-defined` → change to `construction`
260
+ ```text
261
+ ════════════════════════════════════════
262
+ Bolt Completion: 016-analytics-tracker
263
+ ════════════════════════════════════════
254
264
 
255
- **On Bolt Completion** (after updating stories):
265
+ Bolt: 016-analytics-tracker
266
+ Intent: 007-installer-analytics
267
+ Unit: analytics-tracker
268
+ Stories: 12
256
269
 
257
- 1. **Check Unit Completion**:
258
- - Find all bolts for this unit: scan `memory-bank/bolts/*/bolt.md` and match `unit: {unit-name}` in frontmatter
259
- - If ALL bolts have `status: complete` → update unit-brief to `status: complete`
270
+ Bolt status: in-progress → complete
260
271
 
261
- 2. **Check Intent Completion**:
262
- - Read unit-briefs for all units in intent: `{intent}/units/*/unit-brief.md`
263
- - If ALL units have `status: complete` update requirements to `status: complete`
272
+ Updating stories:
273
+ ✓ 001-initialize-mixpanel - draft complete
274
+ ✓ 002-generate-machine-hash - draft → complete
275
+ ...
264
276
 
265
- **Status Transitions**:
277
+ Stories: 12 updated, 0 skipped, 0 errors
266
278
 
267
- ```text
268
- Intent: draft → requirements-defined → units-defined → construction → complete
269
- Unit: draft → stories-defined → in-progress → complete
270
- Story: draft → in-progress → complete
279
+ ✓ Unit status: in-progress → complete
280
+ Intent status: construction → complete
281
+
282
+ ════════════════════════════════════════
283
+ ✓ Bolt Complete: 016-analytics-tracker
284
+ ════════════════════════════════════════
271
285
  ```
272
286
 
273
- **Example** (001-artifact-parser completes):
287
+ **Do NOT manually edit story files.** The command handles everything deterministically.
274
288
 
275
- ```text
276
- 1. Stories updated: 001, 002, 003, 004 → complete
277
- 2. Check unit bolts:
278
- - 001-artifact-parser: complete ✓
279
- - 005-artifact-parser: planned ✗
280
- → Unit stays in-progress (not all bolts complete)
281
- 3. Intent stays construction (unit not complete)
282
- ```
289
+ **Verify the script completed successfully:**
283
290
 
284
- **Example** (last bolt for file-watcher completes):
291
+ After running the command, verify the changes were applied correctly:
285
292
 
286
- ```text
287
- 1. Stories updated: 001, 002 → complete
288
- 2. Check unit bolts:
289
- - 003-file-watcher: complete
290
- → Only bolt for unit, all complete!
291
- Update unit-brief: status: complete
292
- 3. Check intent units:
293
- - artifact-parser: in-progress ✗
294
- - file-watcher: complete ✓
295
- - sidebar-provider: in-progress ✗
296
- → Intent stays construction (not all units complete)
297
- ```
293
+ - [ ] **Bolt file updated**:
294
+ - [ ] `status: complete`
295
+ - [ ] `current_stage: null`
296
+ - [ ] `completed: {timestamp}` set
297
+
298
+ - [ ] **Stories updated** (sample 2-3 from the bolt's stories array):
299
+ - [ ] `status: complete`
300
+ - [ ] `implemented: true`
298
301
 
299
- ### 10. Continue or Complete
302
+ - [ ] **Unit status updated** (if all bolts for this unit are complete):
303
+ - [ ] Check `{intent}/units/{unit}/unit-brief.md` → `status: complete`
300
304
 
301
- Based on condition:
305
+ - [ ] **Intent status updated** (if all units for this intent are complete):
306
+ - [ ] Check `{intent}/intent.md` → `status: complete`
302
307
 
303
- - **More stages remain** Proceed to next stage
304
- - **Final stage complete** → Mark bolt complete, suggest next bolt
305
- - **User stops** → Save progress, can resume later
308
+ **If any verification fails**, the script may have encountered an error. Check the console output for error messages.
306
309
 
307
310
  ---
308
311
 
@@ -396,6 +399,31 @@ If construction log doesn't exist, create it using template:
396
399
 
397
400
  ---
398
401
 
402
+ ## Bolt Completion Checklist
403
+
404
+ **Use this checklist to verify all completion tasks are done:**
405
+
406
+ ```text
407
+ □ Bolt file updated:
408
+ □ status: complete
409
+ □ completed: {timestamp}
410
+ □ current_stage: null
411
+
412
+ □ Stories updated (Step 10):
413
+ □ Each story in bolt's stories array:
414
+ □ status: complete
415
+ □ implemented: true
416
+
417
+ □ Status cascade checked (Step 11):
418
+ □ Unit status updated if all bolts complete
419
+ □ Intent status updated if all units complete
420
+
421
+ □ Construction log updated:
422
+ □ "{bolt-id} completed" entry added
423
+ ```
424
+
425
+ ---
426
+
399
427
  ## Transition
400
428
 
401
429
  After bolt completion:
@@ -63,7 +63,7 @@ Review all stories to understand:
63
63
 
64
64
  ```yaml
65
65
  ---
66
- unit: expense-tracker-ui
66
+ unit: 001-expense-tracker-ui
67
67
  unit_type: frontend
68
68
  default_bolt_type: simple-construction-bolt
69
69
  ---
@@ -235,8 +235,8 @@ Establish execution order based on dependencies:
235
235
  ```markdown
236
236
  ---
237
237
  id: {BBB}-{unit-name}
238
- unit: {unit-name}
239
- intent: {intent-name}
238
+ unit: {UUU}-{unit-name}
239
+ intent: {NNN}-{intent-name}
240
240
  type: {bolt-type} # From unit-brief.md or default (ddd-construction-bolt, simple-construction-bolt)
241
241
  status: planned
242
242
  stories: [story-1, story-2]
@@ -289,10 +289,23 @@ Establish execution order based on dependencies:
289
289
 
290
290
  Check the plan against:
291
291
 
292
+ **Frontmatter Validation (CRITICAL - check each bolt.md)**:
293
+
294
+ - [ ] `id` - Bolt identifier present
295
+ - [ ] `unit` - Parent unit ID present
296
+ - [ ] `intent` - Parent intent ID present
297
+ - [ ] `type` - Bolt type specified (`ddd-construction-bolt` or `simple-construction-bolt`)
298
+ - [ ] `status` - Set to `planned`
299
+ - [ ] `stories` - **Array of story IDs included** (NOT just in body, MUST be in frontmatter)
300
+ - [ ] `created` - Timestamp present
301
+ - [ ] `requires_bolts` - Dependency array present (can be empty `[]`)
302
+ - [ ] `enables_bolts` - Enables array present (can be empty `[]`)
303
+ - [ ] `complexity` - Complexity block with all 4 fields
304
+
305
+ **Content Validation**:
306
+
292
307
  - [ ] All stories are assigned to bolts
293
308
  - [ ] Dependencies are respected (bolt-to-bolt AND unit-to-unit)
294
- - [ ] All dependencies documented in frontmatter
295
- - [ ] Complexity assessment included for each bolt
296
309
  - [ ] Each bolt has clear outputs
297
310
  - [ ] No bolt is too large (max 5-6 stories)
298
311
  - [ ] No circular dependencies exist
@@ -126,7 +126,7 @@ Update these sections:
126
126
 
127
127
  ```markdown
128
128
  ---
129
- intent: {intent-name}
129
+ intent: {NNN}-{intent-name}
130
130
  created: {original-date}
131
131
  completed: {today}
132
132
  status: complete
@@ -152,12 +152,14 @@ When `frontend.enabled: true` in the project type configuration, create a fronte
152
152
 
153
153
  ```yaml
154
154
  ---
155
- unit: {intent}-ui
155
+ unit: {UUU}-{intent}-ui
156
156
  unit_type: frontend
157
157
  default_bolt_type: simple-construction-bolt
158
158
  ---
159
159
  ```
160
160
 
161
+ **Note**: The `unit` field uses the full folder name including the numeric prefix (e.g., `001-auth-service`, `002-auth-service-ui`). This matches the folder structure and enables direct path construction in scripts.
162
+
161
163
  ---
162
164
 
163
165
  ### 6. Propose Unit Structure
@@ -193,10 +195,10 @@ Present proposed decomposition with their assigned requirements:
193
195
  Update `units.md` with all units for this intent
194
196
 
195
197
  3. **Create Unit Directories**:
196
- For each unit: `{schema.units}/{unit-name}/`
198
+ For each unit: `{schema.units}/{UUU}-{unit-name}/`
197
199
 
198
200
  4. **Create Unit Brief** (CRITICAL):
199
- For each unit, create `unit-brief.md` using `.specsmd/aidlc/templates/inception/unit-brief-template.md`
201
+ For each unit, create `{UUU}-{unit-name}/unit-brief.md` using `.specsmd/aidlc/templates/inception/unit-brief-template.md`
200
202
 
201
203
  This brief is the **input for Construction Agent**. Include:
202
204
  - Purpose and scope
@@ -209,14 +211,16 @@ Present proposed decomposition with their assigned requirements:
209
211
 
210
212
  ```yaml
211
213
  ---
212
- unit: auth-service
213
- intent: 001-user-authentication
214
+ unit: {UUU}-{unit-name}
215
+ intent: {NNN}-{intent-name}
214
216
  phase: inception
215
217
  status: draft
216
218
  ---
217
219
  ```
218
220
 
219
- Note: Story naming uses the story title (e.g., `001-user-signup.md`). No prefix field needed.
221
+ **Note**: The `unit` field uses the full folder name including the numeric prefix. This matches the folder structure and enables direct path construction in scripts.
222
+
223
+ Story naming uses the story title (e.g., `001-user-signup.md`). No prefix field needed.
220
224
 
221
225
  **For frontend units**, also include:
222
226
 
@@ -239,25 +243,25 @@ For each unit, verify:
239
243
  ## Output
240
244
 
241
245
  ```markdown
242
- ## Unit Decomposition: {intent-name}
246
+ ## Unit Decomposition: {NNN}-{intent-name}
243
247
 
244
248
  ### Units Created
245
249
 
246
- - [ ] **{unit-1}**: {purpose} - Dependencies: None - Stories: ~{n}
247
- - [ ] **{unit-2}**: {purpose} - Dependencies: `{unit-1}` - Stories: ~{n}
250
+ - [ ] **{UUU}-{unit-1}**: {purpose} - Dependencies: None - Stories: ~{n}
251
+ - [ ] **{UUU}-{unit-2}**: {purpose} - Dependencies: `{UUU}-{unit-1}` - Stories: ~{n}
248
252
 
249
253
  ### Dependency Graph
250
254
 
251
- {unit-1} ──► {unit-2} ──► {unit-3}
255
+ {UUU}-{unit-1} ──► {UUU}-{unit-2} ──► {UUU}-{unit-3}
252
256
 
253
257
 
254
- {unit-4}
258
+ {UUU}-{unit-4}
255
259
 
256
260
  ### Artifacts Created
257
261
 
258
262
  ✅ `{intent-path}/units.md`
259
- ✅ `{intent-path}/units/{unit-1}/unit-brief.md`
260
- ✅ `{intent-path}/units/{unit-2}/unit-brief.md`
263
+ ✅ `{intent-path}/units/{UUU}-{unit-1}/unit-brief.md`
264
+ ✅ `{intent-path}/units/{UUU}-{unit-2}/unit-brief.md`
261
265
 
262
266
  ```
263
267
 
@@ -141,7 +141,7 @@ Create/update `deployment/monitoring.md`:
141
141
 
142
142
  ```markdown
143
143
  ---
144
- unit: {unit-name}
144
+ unit: {UUU}-{unit-name}
145
145
  configured: {timestamp}
146
146
  ---
147
147
 
@@ -27,8 +27,8 @@ memory-bank/bolts/{bolt-id}/
27
27
  ```yaml
28
28
  ---
29
29
  id: bolt-{unit}-{sequence}
30
- unit: {unit-name}
31
- intent: {intent-name}
30
+ unit: {UUU}-{unit-name}
31
+ intent: {NNN}-{intent-name}
32
32
  type: ddd-construction-bolt
33
33
  status: planned
34
34
  stories:
@@ -57,6 +57,27 @@ complexity:
57
57
 
58
58
  ---
59
59
 
60
+ ## Required Frontmatter Fields (VALIDATION CHECKLIST)
61
+
62
+ Before creating a bolt, verify ALL required fields are present:
63
+
64
+ | Field | Required | Description |
65
+ |-------|----------|-------------|
66
+ | `id` | **YES** | Bolt identifier (format: `{BBB}-{unit-name}`) |
67
+ | `unit` | **YES** | Parent unit ID |
68
+ | `intent` | **YES** | Parent intent ID |
69
+ | `type` | **YES** | Bolt type (`ddd-construction-bolt` or `simple-construction-bolt`) |
70
+ | `status` | **YES** | Current status (`planned`, `in-progress`, `completed`, `blocked`) |
71
+ | `stories` | **YES** | Array of story IDs included in this bolt |
72
+ | `created` | **YES** | Creation timestamp |
73
+ | `requires_bolts` | **YES** | Array of bolt IDs this depends on (can be empty `[]`) |
74
+ | `enables_bolts` | **YES** | Array of bolt IDs waiting on this (can be empty `[]`) |
75
+ | `complexity` | **YES** | Complexity assessment block |
76
+
77
+ **If any required field is missing, the bolt is INVALID.**
78
+
79
+ ---
80
+
60
81
  ## Content
61
82
 
62
83
  ```markdown
@@ -132,8 +153,8 @@ complexity:
132
153
  ```yaml
133
154
  ---
134
155
  id: bolt-auth-service-1
135
- unit: auth-service
136
- intent: user-authentication
156
+ unit: 001-auth-service
157
+ intent: 001-user-authentication
137
158
  type: ddd-construction-bolt
138
159
  status: in-progress
139
160
  stories:
@@ -1,6 +1,6 @@
1
1
  ---
2
- unit: {unit-name}
3
- bolt: {bolt-id}
2
+ unit: {UUU}-{unit-name}
3
+ bolt: {BBB}-{unit-name}
4
4
  stage: model
5
5
  status: complete
6
6
  updated: {YYYY-MM-DDTHH:MM:SSZ}
@@ -1,6 +1,6 @@
1
1
  ---
2
- unit: {unit-name}
3
- bolt: {bolt-id}
2
+ unit: {UUU}-{unit-name}
3
+ bolt: {BBB}-{unit-name}
4
4
  stage: design
5
5
  status: complete
6
6
  updated: {YYYY-MM-DDTHH:MM:SSZ}
@@ -1,6 +1,6 @@
1
1
  ---
2
- unit: {unit-name}
3
- bolt: {bolt-id}
2
+ unit: {UUU}-{unit-name}
3
+ bolt: {BBB}-{unit-name}
4
4
  stage: test
5
5
  status: complete
6
6
  updated: {YYYY-MM-DDTHH:MM:SSZ}
@@ -270,6 +270,11 @@ created: {YYYY-MM-DDTHH:MM:SSZ}
270
270
  - **Tests**: {passed}/{total} passed
271
271
  - **Coverage**: {percentage}%
272
272
 
273
+ ### Test Files
274
+
275
+ - [x] `{path/to/test-file.test.ts}` - {what this test file covers}
276
+ - [x] `{path/to/another.test.ts}` - {what this test file covers}
277
+
273
278
  ### Acceptance Criteria Validation
274
279
 
275
280
  - ✅/❌ **{Criterion}**: {Status}
@@ -14,8 +14,8 @@ Use this template to track construction progress and replanning decisions for a
14
14
 
15
15
  ```markdown
16
16
  ---
17
- unit: {unit-name}
18
- intent: {intent-name}
17
+ unit: {UUU}-{unit-name}
18
+ intent: {NNN}-{intent-name}
19
19
  created: {YYYY-MM-DDTHH:MM:SSZ}
20
20
  last_updated: {YYYY-MM-DDTHH:MM:SSZ}
21
21
  ---
@@ -14,7 +14,7 @@ Use this template to track inception progress and decisions for an intent.
14
14
 
15
15
  ```markdown
16
16
  ---
17
- intent: {intent-name}
17
+ intent: {NNN}-{intent-name}
18
18
  created: {YYYY-MM-DDTHH:MM:SSZ}
19
19
  completed: {YYYY-MM-DDTHH:MM:SSZ or null}
20
20
  status: {in-progress | complete}
@@ -8,7 +8,7 @@ Use this template when documenting requirements for an intent.
8
8
 
9
9
  ```yaml
10
10
  ---
11
- intent: {intent-name}
11
+ intent: {NNN}-{intent-name}
12
12
  phase: inception
13
13
  status: draft|in-progress|complete
14
14
  created: {YYYY-MM-DDTHH:MM:SSZ}
@@ -1,5 +1,5 @@
1
1
  ---
2
- intent: {intent-name}
2
+ intent: {NNN}-{intent-name}
3
3
  phase: inception
4
4
  status: stories-created
5
5
  updated: {YYYY-MM-DDTHH:MM:SSZ}
@@ -8,9 +8,9 @@ Use this template when creating individual story files during story creation.
8
8
 
9
9
  ```yaml
10
10
  ---
11
- id: {intent-name}-story-{n}
12
- unit: {unit-name}
13
- intent: {intent-name}
11
+ id: {SSS}-{title-slug}
12
+ unit: {UUU}-{unit-name}
13
+ intent: {NNN}-{intent-name}
14
14
  status: draft
15
15
  priority: must|should|could
16
16
  created: {YYYY-MM-DDTHH:MM:SSZ}
@@ -24,7 +24,7 @@ implemented: false
24
24
  ## Content
25
25
 
26
26
  ```markdown
27
- # Story: {intent-name}-story-{n}
27
+ # Story: {SSS}-{title-slug}
28
28
 
29
29
  ## User Story
30
30
 
@@ -91,19 +91,19 @@ implemented: false
91
91
 
92
92
  ```yaml
93
93
  ---
94
- id: user-authentication-story-1
95
- unit: auth-service
96
- intent: user-authentication
94
+ id: 001-user-signup
95
+ unit: 001-auth-service
96
+ intent: 001-user-authentication
97
97
  status: ready
98
98
  priority: must
99
99
  created: 2024-12-05T10:00:00Z
100
- assigned_bolt: bolt-auth-service-1
100
+ assigned_bolt: 001-auth-service
101
101
  implemented: false
102
102
  ---
103
103
  ```
104
104
 
105
105
  ```markdown
106
- # Story: user-authentication-story-1
106
+ # Story: 001-user-signup
107
107
 
108
108
  ## User Story
109
109
 
@@ -129,8 +129,8 @@ implemented: false
129
129
  - None (first story)
130
130
 
131
131
  ### Enables
132
- - story-2 (User login)
133
- - story-3 (Email verification)
132
+ - 002-user-login (User login)
133
+ - 003-email-verification (Email verification)
134
134
 
135
135
  ## Edge Cases
136
136
 
@@ -1,5 +1,5 @@
1
1
  ---
2
- intent: {intent-name}
2
+ intent: {NNN}-{intent-name}
3
3
  phase: inception
4
4
  status: context-defined
5
5
  updated: {YYYY-MM-DDTHH:MM:SSZ}
@@ -8,8 +8,8 @@ Use this template when creating unit briefs during decomposition. This is the **
8
8
 
9
9
  ```yaml
10
10
  ---
11
- unit: {unit-name}
12
- intent: {intent-name}
11
+ unit: {UUU}-{unit-name}
12
+ intent: {NNN}-{intent-name}
13
13
  phase: inception
14
14
  status: draft|ready
15
15
  created: {YYYY-MM-DDTHH:MM:SSZ}
@@ -17,7 +17,7 @@ updated: {YYYY-MM-DDTHH:MM:SSZ}
17
17
  ---
18
18
  ```
19
19
 
20
- Note: Story naming uses the story title (e.g., `001-user-signup.md`). No prefix field needed.
20
+ **Note**: The `unit` field uses the full folder name including the 3-digit prefix (e.g., `001-auth-service`). This matches the folder structure and enables direct path construction in scripts. Story naming uses the story title (e.g., `001-user-signup.md`).
21
21
 
22
22
  ---
23
23
 
@@ -1,5 +1,5 @@
1
1
  ---
2
- intent: {intent-name}
2
+ intent: {NNN}-{intent-name}
3
3
  phase: inception
4
4
  status: units-decomposed
5
5
  updated: {YYYY-MM-DDTHH:MM:SSZ}