specdacular 0.7.1 → 0.8.0

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 (63) hide show
  1. package/README.md +72 -74
  2. package/commands/specd/continue.md +59 -0
  3. package/commands/specd/new.md +65 -0
  4. package/commands/specd/status.md +1 -1
  5. package/commands/specd/toolbox.md +59 -0
  6. package/package.json +1 -1
  7. package/specdacular/HELP.md +19 -16
  8. package/specdacular/agents/feature-researcher.md +4 -4
  9. package/specdacular/references/load-context.md +83 -0
  10. package/specdacular/references/record-decision.md +61 -0
  11. package/specdacular/references/select-feature.md +20 -20
  12. package/specdacular/references/select-phase.md +3 -3
  13. package/specdacular/references/spawn-research-agents.md +180 -0
  14. package/specdacular/references/synthesize-research.md +127 -0
  15. package/specdacular/references/validate-task.md +64 -0
  16. package/specdacular/templates/{features → tasks}/CHANGELOG.md +2 -8
  17. package/specdacular/templates/{features → tasks}/CONTEXT.md +6 -17
  18. package/specdacular/templates/tasks/DECISIONS.md +46 -0
  19. package/specdacular/templates/{features → tasks}/FEATURE.md +3 -3
  20. package/specdacular/templates/tasks/PLAN.md +91 -0
  21. package/specdacular/templates/tasks/RESEARCH.md +121 -0
  22. package/specdacular/templates/{features → tasks}/ROADMAP.md +6 -43
  23. package/specdacular/templates/tasks/STATE.md +93 -0
  24. package/specdacular/templates/tasks/config.json +15 -0
  25. package/specdacular/workflows/continue.md +275 -0
  26. package/specdacular/workflows/discuss.md +184 -0
  27. package/specdacular/workflows/execute.md +174 -0
  28. package/specdacular/workflows/new.md +299 -0
  29. package/specdacular/workflows/orchestrator/new.md +265 -0
  30. package/specdacular/workflows/orchestrator/plan.md +169 -0
  31. package/specdacular/workflows/plan.md +201 -0
  32. package/specdacular/workflows/research.md +166 -0
  33. package/specdacular/workflows/review.md +289 -0
  34. package/specdacular/workflows/status.md +17 -17
  35. package/commands/specd/blueprint.md +0 -64
  36. package/commands/specd/feature/continue.md +0 -84
  37. package/commands/specd/feature/new.md +0 -67
  38. package/commands/specd/feature/toolbox.md +0 -49
  39. package/specdacular/templates/blueprint/index.html +0 -110
  40. package/specdacular/templates/blueprint/scripts.js +0 -71
  41. package/specdacular/templates/blueprint/styles.css +0 -429
  42. package/specdacular/templates/features/DECISIONS.md +0 -109
  43. package/specdacular/templates/features/DEPENDENCIES.md +0 -47
  44. package/specdacular/templates/features/PLAN.md +0 -180
  45. package/specdacular/templates/features/RESEARCH.md +0 -183
  46. package/specdacular/templates/features/STATE.md +0 -110
  47. package/specdacular/templates/features/config.json +0 -20
  48. package/specdacular/workflows/blueprint-diagrams.md +0 -273
  49. package/specdacular/workflows/blueprint-wireframes.md +0 -312
  50. package/specdacular/workflows/blueprint.md +0 -372
  51. package/specdacular/workflows/continue-feature.md +0 -621
  52. package/specdacular/workflows/discuss-feature.md +0 -382
  53. package/specdacular/workflows/execute-plan.md +0 -636
  54. package/specdacular/workflows/insert-phase.md +0 -246
  55. package/specdacular/workflows/new-feature.md +0 -760
  56. package/specdacular/workflows/plan-feature.md +0 -691
  57. package/specdacular/workflows/plan-phase.md +0 -355
  58. package/specdacular/workflows/prepare-phase.md +0 -745
  59. package/specdacular/workflows/renumber-phases.md +0 -273
  60. package/specdacular/workflows/research-feature.md +0 -252
  61. package/specdacular/workflows/research-phase.md +0 -576
  62. package/specdacular/workflows/review-feature.md +0 -316
  63. package/specdacular/workflows/review-phase.md +0 -545
@@ -1,760 +0,0 @@
1
- <purpose>
2
- Initialize a new feature folder and start the first discussion. Creates structure, asks initial questions, and writes technical requirements.
3
-
4
- **Core flow:**
5
- ```
6
- new-feature → (discuss ↔ research)* → plan-feature
7
- ```
8
-
9
- The user controls the rhythm after initialization. This command is just the entry point.
10
-
11
- **Output:** `.specd/features/{feature-name}/` folder with FEATURE.md, CONTEXT.md, DECISIONS.md, CHANGELOG.md, STATE.md, config.json
12
- </purpose>
13
-
14
- <philosophy>
15
-
16
- ## Collaborative, Not Interrogative
17
-
18
- Follow the thread. Build understanding through natural dialogue. When the user says something interesting, explore it. Don't march through a checklist.
19
-
20
- **Bad:** "Question 1: What's the feature? Question 2: What's the scope? Question 3: ..."
21
- **Good:** "Tell me about what you're building... [response] ...Interesting, when you say X, do you mean Y or Z?"
22
-
23
- ## Technical Focus
24
-
25
- This is about technical requirements, not product specs. Focus on:
26
- - What code needs to exist
27
- - What existing code it integrates with
28
- - Technical constraints
29
-
30
- ## Probe Until Initial Understanding
31
-
32
- Keep asking until you understand:
33
- 1. What this creates (files, components, APIs)
34
- 2. What it integrates with (existing code)
35
- 3. Key constraints (technical, timeline, scope)
36
-
37
- You don't need to resolve everything — that's what `discuss-feature` is for.
38
-
39
- ## Decisions Get Recorded
40
-
41
- Any decision made during this initial discussion goes into DECISIONS.md with date and rationale.
42
-
43
- </philosophy>
44
-
45
- <process>
46
-
47
- <step name="validate">
48
- Get feature name and validate.
49
-
50
- **If $ARGUMENTS provided:**
51
- Use as feature name. Normalize to kebab-case (lowercase, hyphens).
52
-
53
- **If no arguments:**
54
- Ask: "What's the name of this feature?"
55
-
56
- **Validate:**
57
- - Feature name should be kebab-case
58
- - Check if `.specd/features/{name}/` already exists
59
-
60
- ```bash
61
- # Check if feature exists
62
- [ -d ".specd/features/$FEATURE_NAME" ] && echo "exists"
63
- ```
64
-
65
- **If feature exists:**
66
- Use AskUserQuestion:
67
- - header: "Feature Exists"
68
- - question: "Feature '{name}' already exists. What would you like to do?"
69
- - options:
70
- - "Resume" — Continue with existing feature (suggest /specd:feature:discuss)
71
- - "Reset" — Delete and start fresh
72
- - "Different name" — Use a different name
73
-
74
- **If new feature:**
75
- Continue to codebase_context.
76
- </step>
77
-
78
- <step name="codebase_context">
79
- Look for codebase documentation and detect orchestrator mode.
80
-
81
- **Check for existing config:**
82
- ```bash
83
- cat .specd/config.json 2>/dev/null
84
- ```
85
-
86
- **Check for orchestrator mode (DEC-006):**
87
-
88
- If config exists, read `"type"` field.
89
-
90
- **If type = "orchestrator":**
91
- Set mode = "orchestrator".
92
-
93
- Read system-level codebase docs:
94
- - `.specd/codebase/PROJECTS.md` — Project registry
95
- - `.specd/codebase/TOPOLOGY.md` — Communication patterns
96
- - `.specd/codebase/CONTRACTS.md` — Shared interfaces
97
- - `.specd/codebase/CONCERNS.md` — System-level concerns
98
-
99
- Read project list from config.json `"projects"` array.
100
-
101
- ```
102
- Orchestrator mode detected. {N} projects registered.
103
- I'll use system-level docs to understand cross-project architecture.
104
- ```
105
-
106
- Continue to orchestrator_discussion.
107
-
108
- **If type = "project" or absent:**
109
- Set mode = "project".
110
-
111
- **If config exists with codebase_docs path:**
112
- Use that path for codebase docs.
113
-
114
- **If no config, check default location:**
115
- ```bash
116
- ls .specd/codebase/*.md 2>/dev/null
117
- ```
118
-
119
- **If codebase docs found:**
120
- ```
121
- Found codebase documentation. I'll reference these when defining requirements.
122
- ```
123
-
124
- Read the available docs to understand:
125
- - Project structure (where new code goes)
126
- - Code patterns (how things are done here)
127
- - Architecture (how systems connect)
128
-
129
- Continue to first_discussion.
130
-
131
- **If no codebase docs found:**
132
- Use AskUserQuestion:
133
- - header: "No Codebase Docs"
134
- - question: "I didn't find codebase documentation. How should we proceed?"
135
- - options:
136
- - "Run map-codebase first" — Creates AI-optimized docs
137
- - "Continue without" — Proceed without codebase context
138
- - "Custom location" — Docs are elsewhere
139
-
140
- **If custom location:**
141
- Ask for path, then save to `.specd/config.json`.
142
-
143
- Continue to first_discussion.
144
- </step>
145
-
146
- <step name="orchestrator_discussion">
147
- System-level feature discussion for orchestrator mode.
148
-
149
- **Opening:**
150
- ```
151
- Let's talk about what you're building across the system.
152
-
153
- What's the {feature-name} feature? What system-level behavior does it add?
154
- ```
155
-
156
- Wait for response.
157
-
158
- **Follow the thread:**
159
- Based on their response, ask follow-up questions that:
160
- - Identify which projects are affected ("Which parts of the system does this touch?")
161
- - Explore cross-project behavior ("How would data flow between projects for this?")
162
- - Identify contract implications ("Does this change how projects communicate?")
163
- - Understand project responsibilities ("What does each project need to do?")
164
-
165
- **System-level probes (follow the conversation, don't march through):**
166
- - "Which projects does this involve?"
167
- - "What crosses project boundaries here?"
168
- - "Does this change any existing communication patterns?"
169
- - "What's each project's responsibility for this feature?"
170
- - "Are there shared data structures or APIs that need to align?"
171
- - "What's the simplest cross-project version that would work?"
172
-
173
- **Use system-level context from codebase docs:**
174
- - Reference PROJECTS.md for project responsibilities
175
- - Reference TOPOLOGY.md for existing communication patterns
176
- - Reference CONTRACTS.md for existing shared interfaces
177
- - Reference CONCERNS.md for system-level gotchas that might apply
178
-
179
- **Check understanding:**
180
- After 4-6 exchanges, summarize with project involvement:
181
- ```
182
- So if I understand correctly:
183
- - This feature [system-level behavior]
184
- - It involves these projects:
185
- - {project-1}: [responsibility]
186
- - {project-2}: [responsibility]
187
- - Cross-project interaction: [how projects coordinate]
188
- - Key constraint: [constraint]
189
-
190
- Does that capture it, or should we dig into anything more?
191
- ```
192
-
193
- **When to move on:**
194
- - User confirms understanding is correct
195
- - You have a clear project list with per-project responsibilities
196
- - Cross-project behavior is understood
197
-
198
- Continue to route_projects.
199
- </step>
200
-
201
- <step name="route_projects">
202
- Confirm which projects are involved in this feature.
203
-
204
- **Build project suggestion:**
205
- From the discussion, identify involved projects. Cross-reference with:
206
- - CONTRACTS.md — which projects have existing relationships relevant to this feature
207
- - PROJECTS.md — project responsibilities that align with feature needs
208
-
209
- **Present suggestion:**
210
- ```
211
- Based on our discussion, these projects are involved:
212
-
213
- {For each project:}
214
- - **{project-name}** ({project-path}) — {responsibility for this feature}
215
-
216
- {If any projects from config NOT included:}
217
- Not involved: {project-name} — {brief reason}
218
- ```
219
-
220
- Use AskUserQuestion:
221
- - header: "Projects"
222
- - question: "Are these the right projects for this feature?"
223
- - options:
224
- - "Yes, looks right" — Continue with these projects
225
- - "I need to adjust" — Add or remove projects
226
-
227
- **If "I need to adjust":**
228
- Ask user which projects to add or remove. Update the list accordingly.
229
-
230
- **Store project routing:**
231
- Build routing data:
232
- ```json
233
- {
234
- "projects": [
235
- {"name": "{project-name}", "path": "{project-path}", "responsibility": "{what this project does for the feature}"}
236
- ]
237
- }
238
- ```
239
-
240
- Continue to create_orchestrator_feature.
241
- </step>
242
-
243
- <step name="create_orchestrator_feature">
244
- Create orchestrator-level feature folder with system-view documents.
245
-
246
- **Create feature directory:**
247
- ```bash
248
- mkdir -p .specd/features/{feature-name}
249
- ```
250
-
251
- **Write FEATURE.md (system view):**
252
- Use template at `~/.claude/specdacular/templates/features/FEATURE.md` but adapt for system level:
253
-
254
- - **What This Is:** System-level description from orchestrator discussion
255
- - **Must Create:** List the involved projects and what each creates (high-level)
256
- - **Must Integrate With:** Cross-project interactions, existing contracts affected
257
- - **Constraints:** System-level constraints (cross-project coordination, contract alignment)
258
- - **Success Criteria:** System-level observable behaviors (not project-level details)
259
- - **Out of Scope:** Explicit exclusions from the discussion
260
- - **Initial Context:**
261
- - User Need: from discussion
262
- - Projects Involved: list with responsibilities
263
- - Cross-Project Contracts: what needs to align between projects
264
-
265
- **Write CONTEXT.md:**
266
- Use template at `~/.claude/specdacular/templates/features/CONTEXT.md`
267
-
268
- Fill in:
269
- - **Discussion Summary:** System-level discussion summary
270
- - **Resolved Questions:** Questions answered during orchestrator discussion
271
- - **Deferred Questions:** Things to resolve during planning
272
- - **Gray Areas Remaining:** Open areas
273
-
274
- **Write DECISIONS.md:**
275
- Use template at `~/.claude/specdacular/templates/features/DECISIONS.md`
276
- Record any decisions made during the system-level discussion.
277
-
278
- **Write CHANGELOG.md:**
279
- Use template at `~/.claude/specdacular/templates/features/CHANGELOG.md`
280
- Initialize empty.
281
-
282
- **Write STATE.md:**
283
- Use template at `~/.claude/specdacular/templates/features/STATE.md`
284
-
285
- Initialize with:
286
- - Stage: discussion
287
- - Initial discussion complete: yes
288
- - Add "Sub-Project Features" section:
289
-
290
- ```markdown
291
- ## Sub-Project Features
292
-
293
- | Project | Path | Feature Path | Status |
294
- |---------|------|--------------|--------|
295
- | {project-name} | {project-path} | {project-path}/.specd/features/{feature-name}/ | initialized |
296
- ```
297
-
298
- **Write config.json:**
299
- ```json
300
- {
301
- "feature_name": "{name}",
302
- "created": "{date}",
303
- "stage": "discussion",
304
- "discussion_sessions": 1,
305
- "decisions_count": {N},
306
- "orchestrator": true,
307
- "projects": [
308
- {"name": "{project-name}", "path": "{project-path}", "responsibility": "{responsibility}"}
309
- ]
310
- }
311
- ```
312
-
313
- Continue to delegate_to_projects.
314
- </step>
315
-
316
- <step name="delegate_to_projects">
317
- Create feature folders in each involved sub-project with translated requirements.
318
-
319
- For each project in the routing data:
320
-
321
- **Create feature directory:**
322
- ```bash
323
- mkdir -p {project-path}/.specd/features/{feature-name}
324
- ```
325
-
326
- **Write FEATURE.md (project-specific):**
327
- Use template at `~/.claude/specdacular/templates/features/FEATURE.md`
328
-
329
- Translate the system-level requirements into project-specific requirements:
330
- - **What This Is:** What this project specifically does for the feature (not the system-level description)
331
- - **Must Create:** Specific files/components this project needs to create
332
- - **Must Integrate With:** Existing code in THIS project + cross-project interfaces it must implement
333
- - **Constraints:** Project-specific constraints + any contract requirements from the orchestrator
334
- - **Success Criteria:** Project-specific observable behaviors
335
- - **Out of Scope:** What this project does NOT handle (other projects' responsibilities)
336
- - **Initial Context:**
337
- - User Need: project-specific slice of the system need
338
- - Integration Points: what this project exposes or consumes from other projects
339
-
340
- **IMPORTANT (DEC-001):** The sub-project FEATURE.md must read like a normal, self-contained feature requirement. No references to "orchestrator," "multi-project," or other projects by name. Cross-project requirements should be phrased as external interface requirements:
341
- - BAD: "API project must expose /auth/login for the UI project"
342
- - GOOD: "Must expose /auth/login endpoint that returns JWT tokens"
343
-
344
- **Write CONTEXT.md:**
345
- Use template at `~/.claude/specdacular/templates/features/CONTEXT.md`
346
- - Discussion Summary: "Requirements defined as part of system-level {feature-name} feature planning."
347
- - Resolved Questions: Any project-specific questions resolved during orchestrator discussion
348
-
349
- **Write DECISIONS.md:**
350
- Use template at `~/.claude/specdacular/templates/features/DECISIONS.md`
351
- Include any project-specific decisions from orchestrator discussion.
352
-
353
- **Write CHANGELOG.md:**
354
- Use template at `~/.claude/specdacular/templates/features/CHANGELOG.md`
355
- Initialize empty.
356
-
357
- **Write STATE.md:**
358
- Use template at `~/.claude/specdacular/templates/features/STATE.md`
359
- Initialize with stage: discussion, initial discussion complete: yes.
360
-
361
- **Write config.json:**
362
- ```json
363
- {
364
- "feature_name": "{name}",
365
- "created": "{date}",
366
- "stage": "discussion",
367
- "discussion_sessions": 0,
368
- "decisions_count": {N}
369
- }
370
- ```
371
-
372
- Note: `discussion_sessions: 0` because no per-project discussion happened — requirements came from orchestrator delegation.
373
-
374
- After all projects processed, verify:
375
- ```bash
376
- for project in {project-paths}; do
377
- echo "Checking $project..."
378
- ls "$project/.specd/features/{feature-name}/"
379
- done
380
- ```
381
-
382
- Continue to orchestrator_feature_commit.
383
- </step>
384
-
385
- <step name="orchestrator_feature_commit">
386
- Commit orchestrator and all sub-project feature files.
387
-
388
- ```bash
389
- # Add orchestrator feature files
390
- git add .specd/features/{feature-name}/
391
-
392
- # Add per-project feature files
393
- {For each project:}
394
- git add {project-path}/.specd/features/{feature-name}/
395
-
396
- git commit -m "docs({feature-name}): initialize multi-project feature
397
-
398
- Orchestrator:
399
- - FEATURE.md: System-level requirements
400
- - CONTEXT.md: Cross-project discussion
401
- - DECISIONS.md: {N} decisions
402
- - STATE.md: Sub-project tracking
403
-
404
- Projects:
405
- {For each project:}
406
- - {project-name}: Project-specific requirements
407
-
408
- Co-Authored-By: Claude <noreply@anthropic.com>"
409
- ```
410
-
411
- Continue to orchestrator_feature_completion.
412
- </step>
413
-
414
- <step name="orchestrator_feature_completion">
415
- Present multi-project feature creation summary.
416
-
417
- ```
418
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
419
- MULTI-PROJECT FEATURE INITIALIZED
420
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
421
-
422
- **Feature:** {feature-name}
423
-
424
- ## Orchestrator (.specd/features/{feature-name}/)
425
-
426
- - FEATURE.md — System-level requirements
427
- - CONTEXT.md — Cross-project discussion
428
- - DECISIONS.md — {N} decisions recorded
429
- - STATE.md — Sub-project tracking
430
-
431
- ## Projects
432
-
433
- {For each project:}
434
- **{project-name}** ({project-path}/.specd/features/{feature-name}/)
435
- - FEATURE.md — {brief responsibility summary}
436
- - Responsibility: {one-liner}
437
-
438
- ## Summary
439
-
440
- {2-3 sentence system-level summary}
441
- ```
442
-
443
- Continue to orchestrator_continuation_offer.
444
- </step>
445
-
446
- <step name="orchestrator_continuation_offer">
447
- Offer to continue or stop (same pattern as existing continuation_offer).
448
-
449
- **If gray areas remain in orchestrator CONTEXT.md:**
450
-
451
- Use AskUserQuestion:
452
- - header: "Continue?"
453
- - question: "Want to keep discussing the open areas, or come back later?"
454
- - options:
455
- - "Keep discussing" — Dive into the gray areas now
456
- - "Stop for now" — Come back with /specd:feature:continue {feature-name}
457
-
458
- **If Keep discussing:**
459
- Execute the discuss-feature workflow logic:
460
- @~/.claude/specdacular/workflows/discuss-feature.md
461
-
462
- After discussion completes, return to this step.
463
-
464
- **If no gray areas remain:**
465
-
466
- Use AskUserQuestion:
467
- - header: "Continue?"
468
- - question: "Discussion looks solid. Want to keep going or come back later?"
469
- - options:
470
- - "Continue" — Move to the next step (research or planning)
471
- - "Stop for now" — Come back with /specd:feature:continue {feature-name}
472
-
473
- **If Continue:**
474
- Hand off to continue-feature workflow:
475
- @~/.claude/specdacular/workflows/continue-feature.md
476
-
477
- Start from the read_state step with the current feature.
478
-
479
- **If Stop for now:**
480
- ```
481
- ───────────────────────────────────────────────────────
482
-
483
- Progress saved. Pick up where you left off anytime:
484
-
485
- /specd:feature:continue {feature-name}
486
- ```
487
-
488
- End workflow.
489
- </step>
490
-
491
- <step name="first_discussion">
492
- Start the conversation.
493
-
494
- **Opening:**
495
- ```
496
- Let's talk about what you're building.
497
-
498
- What's the {feature-name} feature? Give me the quick version — what problem does it solve and roughly how?
499
- ```
500
-
501
- Wait for response.
502
-
503
- **Follow the thread:**
504
- Based on their response, ask follow-up questions that:
505
- - Clarify what they said ("When you say X, do you mean...?")
506
- - Explore interesting aspects ("Tell me more about how that would work...")
507
- - Identify technical implications ("So that would mean creating a...")
508
-
509
- **Questions to answer (not in order — follow the conversation):**
510
- 1. What does this create? (new files, components, APIs, data)
511
- 2. What does it integrate with? (existing code, external services)
512
- 3. What are the key constraints? (technical, timeline, scope)
513
- 4. What's explicitly out of scope? (scope boundaries)
514
-
515
- **Conversational probes:**
516
- - "Walk me through how someone would use this..."
517
- - "What existing code does this touch?"
518
- - "What's the simplest version that would be useful?"
519
- - "Is there anything you've already decided on how to build this?"
520
- - "What definitely should NOT be part of this?"
521
-
522
- **Check understanding:**
523
- After 4-6 exchanges, summarize:
524
- ```
525
- So if I understand correctly:
526
- - This feature [does X]
527
- - It needs to create [files/components]
528
- - It integrates with [existing code]
529
- - Key constraint: [constraint]
530
-
531
- Does that capture it, or should we dig into anything more?
532
- ```
533
-
534
- **When to move on:**
535
- - User confirms understanding is correct
536
- - You have enough for initial FEATURE.md
537
- - Further details can be discussed later with /specd:feature:discuss
538
-
539
- Continue to write_feature.
540
- </step>
541
-
542
- <step name="write_feature">
543
- Create feature directory and FEATURE.md.
544
-
545
- **Create feature directory:**
546
- ```bash
547
- mkdir -p .specd/features/{feature-name}
548
- ```
549
-
550
- **Write FEATURE.md:**
551
- Use template at `~/.claude/specdacular/templates/features/FEATURE.md`
552
-
553
- Fill in based on conversation:
554
- - **What This Is:** 1-2 sentences from discussion
555
- - **Must Create:** Files/components identified
556
- - **Must Integrate With:** Existing code mentioned
557
- - **Constraints:** Any constraints identified
558
- - **Success Criteria:** Observable behaviors
559
- - **Out of Scope:** Explicit exclusions
560
- - **Initial Context:** Notes from discussion
561
-
562
- Continue to write_context.
563
- </step>
564
-
565
- <step name="write_context">
566
- Write CONTEXT.md with initial discussion state.
567
-
568
- **Write CONTEXT.md:**
569
- Use template at `~/.claude/specdacular/templates/features/CONTEXT.md`
570
-
571
- Fill in:
572
- - **Discussion Summary:** Brief summary of what was discussed
573
- - **Resolved Questions:** Questions that were answered in this session
574
- - **Deferred Questions:** Things that came up but weren't resolved
575
- - **Gray Areas Remaining:** Areas that need more discussion
576
-
577
- Continue to initialize_decisions.
578
- </step>
579
-
580
- <step name="initialize_decisions">
581
- Initialize DECISIONS.md with any decisions made.
582
-
583
- **Write DECISIONS.md:**
584
- Use template at `~/.claude/specdacular/templates/features/DECISIONS.md`
585
-
586
- If any decisions were made during discussion (technology choices, scope decisions, approach decisions), record them:
587
-
588
- ```markdown
589
- ### DEC-001: {Decision}
590
- **Date:** {today}
591
- **Status:** Active
592
- **Context:** Identified during initial feature discussion
593
- **Decision:** {What was decided}
594
- **Rationale:**
595
- - {Why}
596
- **Implications:**
597
- - {What this means}
598
- ```
599
-
600
- If no decisions yet, leave with just the template structure.
601
-
602
- Continue to initialize_changelog.
603
- </step>
604
-
605
- <step name="initialize_changelog">
606
- Initialize CHANGELOG.md (empty, ready for implementation).
607
-
608
- **Write CHANGELOG.md:**
609
- Use template at `~/.claude/specdacular/templates/features/CHANGELOG.md`
610
-
611
- Replace `{feature-name}` with actual feature name. Leave the rest as template structure — entries will be added during plan execution.
612
-
613
- Continue to initialize_state.
614
- </step>
615
-
616
- <step name="initialize_state">
617
- Create STATE.md and config.json.
618
-
619
- **Write STATE.md:**
620
- Use template at `~/.claude/specdacular/templates/features/STATE.md`
621
-
622
- Initialize with:
623
- - Stage: discussion
624
- - Initial discussion complete: yes
625
- - Gray areas identified: based on deferred questions
626
-
627
- **Write config.json:**
628
- ```json
629
- {
630
- "feature_name": "{name}",
631
- "created": "{date}",
632
- "stage": "discussion",
633
- "discussion_sessions": 1,
634
- "decisions_count": {N}
635
- }
636
- ```
637
-
638
- Continue to commit.
639
- </step>
640
-
641
- <step name="commit">
642
- Commit the feature initialization.
643
-
644
- @~/.claude/specdacular/references/commit-docs.md
645
-
646
- - **$FILES:** `.specd/features/{feature-name}/`
647
- - **$MESSAGE:** `docs({feature-name}): initialize feature` with list of created files
648
- - **$LABEL:** `feature initialization`
649
-
650
- Continue to completion.
651
- </step>
652
-
653
- <step name="completion">
654
- Present what was created and offer to continue.
655
-
656
- **Output:**
657
- ```
658
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
659
- FEATURE INITIALIZED
660
- ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
661
-
662
- **Feature:** {feature-name}
663
-
664
- ## Created
665
-
666
- - `.specd/features/{feature-name}/FEATURE.md` — Technical requirements
667
- - `.specd/features/{feature-name}/CONTEXT.md` — Discussion context
668
- - `.specd/features/{feature-name}/DECISIONS.md` — {N} decisions recorded
669
- - `.specd/features/{feature-name}/CHANGELOG.md` — Implementation log (empty)
670
- - `.specd/features/{feature-name}/STATE.md` — Progress tracking
671
- - `.specd/features/{feature-name}/config.json` — Configuration
672
-
673
- ## Summary
674
-
675
- {2-3 sentence summary of what this feature does}
676
-
677
- {If gray areas remain:}
678
- **Open areas to discuss:**
679
- - {Gray area 1}
680
- - {Gray area 2}
681
- ```
682
-
683
- Continue to continuation_offer.
684
- </step>
685
-
686
- <step name="continuation_offer">
687
- Offer to continue discussing or stop.
688
-
689
- **If gray areas remain:**
690
-
691
- Use AskUserQuestion:
692
- - header: "Continue?"
693
- - question: "Want to keep discussing the open areas, or come back later?"
694
- - options:
695
- - "Keep discussing" — Dive into the gray areas now
696
- - "Stop for now" — Come back with /specd:feature:continue {feature-name}
697
-
698
- **If Keep discussing:**
699
- Execute the discuss-feature workflow logic:
700
- @~/.claude/specdacular/workflows/discuss-feature.md
701
-
702
- After discussion completes (commit done), return to this step (continuation_offer) — re-read CONTEXT.md to check if gray areas remain, and offer again.
703
-
704
- **If no gray areas remain:**
705
-
706
- Use AskUserQuestion:
707
- - header: "Continue?"
708
- - question: "Discussion looks solid. Want to keep going or come back later?"
709
- - options:
710
- - "Continue" — Move to the next step (research or planning)
711
- - "Stop for now" — Come back with /specd:feature:continue {feature-name}
712
-
713
- **If Continue:**
714
- Hand off to the continue-feature workflow logic to determine next action:
715
- @~/.claude/specdacular/workflows/continue-feature.md
716
-
717
- Start from the read_state step with the current feature.
718
-
719
- **If Stop for now:**
720
- ```
721
- ───────────────────────────────────────────────────────
722
-
723
- Progress saved. Pick up where you left off anytime:
724
-
725
- /specd:feature:continue {feature-name}
726
- ```
727
-
728
- End workflow.
729
- </step>
730
-
731
- </process>
732
-
733
- <success_criteria>
734
-
735
- ## Single-Project Mode
736
- - Feature folder created at `.specd/features/{name}/`
737
- - FEATURE.md has specific technical requirements (files to create, integrations)
738
- - CONTEXT.md captures the discussion state
739
- - DECISIONS.md initialized (with any decisions made)
740
- - CHANGELOG.md initialized (empty, ready for implementation)
741
- - STATE.md tracks current stage
742
- - config.json created
743
- - Committed to git
744
- - User presented with clear next options
745
-
746
- ## Multi-Project Mode (Orchestrator)
747
- - Orchestrator mode detected from `.specd/config.json` type field
748
- - System-level discussion focuses on cross-project behavior
749
- - Project routing suggests involved projects from discussion + CONTRACTS.md
750
- - User confirms or adjusts project selection
751
- - Orchestrator feature folder created with system-level FEATURE.md, CONTEXT.md, DECISIONS.md, STATE.md
752
- - Orchestrator STATE.md includes Sub-Project Features table
753
- - Orchestrator config.json includes `orchestrator: true` and `projects` array
754
- - Each sub-project gets feature folder with project-specific requirements
755
- - Sub-project FEATURE.md reads as normal self-contained feature (DEC-001)
756
- - All files committed (orchestrator + all sub-projects)
757
- - Multi-project summary presented
758
- - User presented with clear next options
759
-
760
- </success_criteria>