specdacular 0.9.2 → 0.10.1

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 (36) hide show
  1. package/README.md +40 -36
  2. package/agents/specd-codebase-mapper.md +1 -1
  3. package/bin/install.js +46 -12
  4. package/commands/{specd/map-codebase.md → specd.codebase.map.md} +1 -1
  5. package/commands/specd.codebase.review.md +39 -0
  6. package/commands/{specd/config.md → specd.config.md} +1 -1
  7. package/commands/{specd/continue.md → specd.continue.md} +1 -1
  8. package/commands/{specd/help.md → specd.help.md} +1 -1
  9. package/commands/specd.new-project.md +58 -0
  10. package/commands/{specd/new.md → specd.new.md} +4 -4
  11. package/commands/{specd/status.md → specd.status.md} +1 -1
  12. package/commands/specd.toolbox.md +63 -0
  13. package/commands/{specd/update.md → specd.update.md} +1 -1
  14. package/hooks/specd-statusline.js +1 -1
  15. package/package.json +1 -1
  16. package/specdacular/HELP.md +24 -20
  17. package/specdacular/agents/feature-researcher.md +4 -4
  18. package/specdacular/agents/project-researcher.md +409 -0
  19. package/specdacular/references/execute-hooks.md +1 -1
  20. package/specdacular/references/select-feature.md +1 -1
  21. package/specdacular/references/select-phase.md +1 -1
  22. package/specdacular/references/validate-task.md +3 -3
  23. package/specdacular/templates/tasks/PROJECT.md +52 -0
  24. package/specdacular/templates/tasks/REQUIREMENTS.md +75 -0
  25. package/specdacular/templates/tasks/STATE.md +1 -1
  26. package/specdacular/workflows/brain.md +2 -2
  27. package/specdacular/workflows/config.md +1 -1
  28. package/specdacular/workflows/context-add.md +1 -1
  29. package/specdacular/workflows/context-manual-review.md +1 -1
  30. package/specdacular/workflows/new-project.md +799 -0
  31. package/specdacular/workflows/new.md +6 -6
  32. package/specdacular/workflows/orchestrator/new.md +3 -3
  33. package/specdacular/workflows/orchestrator/plan.md +1 -1
  34. package/specdacular/workflows/plan.md +3 -3
  35. package/specdacular/workflows/status.md +3 -3
  36. package/commands/specd/toolbox.md +0 -103
@@ -0,0 +1,799 @@
1
+ <purpose>
2
+ Bootstrap a new project from idea to structured plan. Standalone workflow — no brain/pipeline integration. Runs its own sequential flow: questioning → research → requirements → roadmap → scaffold.
3
+
4
+ After scaffolding, sub-projects use `/specd.new` and `/specd.continue` for their individual task lifecycles.
5
+
6
+ **Output:** `.specd/tasks/project/PROJECT.md` (Phase 1), research files (Phase 2), REQUIREMENTS.md + ROADMAP.md (Phase 3), scaffolded sub-projects (Phase 4)
7
+ </purpose>
8
+
9
+ <philosophy>
10
+
11
+ ## Collaborative, Not Interrogative
12
+
13
+ Follow the thread. When the user mentions something interesting, explore it. Don't march through a checklist of questions. Build understanding through natural dialogue.
14
+
15
+ ## Vision First, Details Later
16
+
17
+ The questioning stage captures the big picture — what, why, who, constraints. Technical details (stack, libraries, architecture) come from research agents later.
18
+
19
+ ## Opinionated Research
20
+
21
+ Research agents don't list options — they recommend. "Use X because Y" is more useful than "you could use X, Y, or Z."
22
+
23
+ ## Greenfield Assumptions
24
+
25
+ There's no codebase to learn from. All context comes from the user's vision and domain research. This is fundamentally different from `/specd.new`.
26
+
27
+ </philosophy>
28
+
29
+ <process>
30
+
31
+ <step name="validate">
32
+ Get project name and validate.
33
+
34
+ **If $ARGUMENTS provided:**
35
+ Use as project name. This is a label for the project, not a task name.
36
+
37
+ **If no arguments:**
38
+ Ask: "What's the name of this project?"
39
+
40
+ **Check if project already exists:**
41
+ ```bash
42
+ [ -d ".specd/tasks/project" ] && echo "exists"
43
+ ```
44
+
45
+ **If project exists:**
46
+ Use AskUserQuestion:
47
+ - header: "Project Exists"
48
+ - question: "A project has already been initialized. What would you like to do?"
49
+ - options:
50
+ - "Start fresh" — Delete existing and reinitialize
51
+ - "View existing" — Show current PROJECT.md
52
+
53
+ **If "Start fresh":**
54
+ ```bash
55
+ rm -rf .specd/tasks/project
56
+ ```
57
+
58
+ **If "View existing":**
59
+ Read and display `.specd/tasks/project/PROJECT.md`. End workflow.
60
+
61
+ **If new project:**
62
+ Continue to questioning.
63
+ </step>
64
+
65
+ <step name="questioning">
66
+ Collaborative conversation to understand the project vision.
67
+
68
+ **Opening:**
69
+ ```
70
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
71
+ NEW PROJECT: {project-name}
72
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
73
+
74
+ Tell me about this project. What are you building and why?
75
+ ```
76
+
77
+ Wait for response.
78
+
79
+ **Follow the thread:**
80
+ Based on their response, explore:
81
+ - What's the core value? ("When you say X, tell me more about...")
82
+ - Who uses it? ("Who's the primary user? What's their workflow?")
83
+ - What does it need to do? ("What are the must-have capabilities for v1?")
84
+ - Any known technical constraints? ("Any preferences for stack, hosting, team size?")
85
+ - What's out of scope? ("What should we explicitly NOT build?")
86
+ - Sub-projects? ("Does this feel like one app or multiple services?")
87
+
88
+ **Record decisions inline:**
89
+ When the user makes a clear choice, note it for DECISIONS.md later.
90
+
91
+ **After 4-6 exchanges, summarize:**
92
+ ```
93
+ Here's what I'm hearing:
94
+
95
+ **Vision:** {one-liner}
96
+ **Problem:** {what it solves}
97
+ **Users:** {who and how}
98
+ **Key goals:**
99
+ - {goal 1}
100
+ - {goal 2}
101
+ - {goal 3}
102
+
103
+ **Constraints:** {known constraints}
104
+ **Sub-projects:** {identified or "TBD from research"}
105
+
106
+ Does that capture it? Anything to add or correct?
107
+ ```
108
+
109
+ **When to move on:**
110
+ - User confirms the summary
111
+ - You have enough for a meaningful PROJECT.md
112
+ - Technical details can wait for research
113
+
114
+ Continue to write_project.
115
+ </step>
116
+
117
+ <step name="write_project">
118
+ Create the project task directory and write initial documents.
119
+
120
+ **Create directory:**
121
+ ```bash
122
+ mkdir -p .specd/tasks/project
123
+ ```
124
+
125
+ **Write PROJECT.md:**
126
+ Use template at `~/.claude/specdacular/templates/tasks/PROJECT.md`
127
+ Fill in from the questioning conversation.
128
+
129
+ **Write CONTEXT.md:**
130
+ Use template at `~/.claude/specdacular/templates/tasks/CONTEXT.md`
131
+ - Discussion summary from questioning
132
+ - Any resolved questions
133
+ - Open questions that research should address
134
+ - Gray areas (if any)
135
+
136
+ **Write DECISIONS.md:**
137
+ Use template at `~/.claude/specdacular/templates/tasks/DECISIONS.md`
138
+ Record any decisions made during questioning using:
139
+ @~/.claude/specdacular/references/record-decision.md
140
+
141
+ **Write config.json:**
142
+ ```json
143
+ {
144
+ "task_name": "project",
145
+ "project_name": "{project-name}",
146
+ "created": "{date}",
147
+ "stage": "questioning",
148
+ "type": "project"
149
+ }
150
+ ```
151
+
152
+ Continue to commit.
153
+ </step>
154
+
155
+ <step name="commit">
156
+ Commit the project initialization.
157
+
158
+ @~/.claude/specdacular/references/commit-docs.md
159
+
160
+ - **$FILES:** `.specd/tasks/project/`
161
+ - **$MESSAGE:** `docs(project): initialize project — {project-name}` with brief vision summary
162
+ - **$LABEL:** `project initialization`
163
+
164
+ Continue to research.
165
+ </step>
166
+
167
+ <step name="research">
168
+ Spawn 4 parallel research agents to investigate the project domain.
169
+
170
+ **Show banner:**
171
+ ```
172
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
173
+ RESEARCHING: {project-name}
174
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
175
+ Spawning 4 research agents...
176
+ ```
177
+
178
+ **Prepare context:**
179
+ Read `.specd/tasks/project/PROJECT.md` and `.specd/tasks/project/CONTEXT.md`.
180
+ Build `$PROJECT_CONTEXT` combining: vision, problem, users, goals, constraints, open questions.
181
+
182
+ **Spawn 4 agents using Task tool with `run_in_background: true`:**
183
+
184
+ All agents use `subagent_type: "general-purpose"` and `model: "sonnet"`.
185
+
186
+ **Agent 1 — Stack:**
187
+ ```
188
+ Task(
189
+ subagent_type: "general-purpose"
190
+ model: "sonnet"
191
+ description: "Stack research"
192
+ run_in_background: true
193
+ prompt: "First, read {install-path}/specdacular/agents/project-researcher.md for your role.
194
+
195
+ <focus_area>Stack</focus_area>
196
+
197
+ <project_context>
198
+ $PROJECT_CONTEXT
199
+ </project_context>
200
+
201
+ <research_questions>
202
+ 1. What's the best technology stack for this type of project?
203
+ 2. What frameworks and libraries are recommended for each layer?
204
+ 3. What infrastructure (hosting, CI/CD, monitoring) fits best?
205
+ 4. What are the key version requirements and compatibility concerns?
206
+ </research_questions>
207
+
208
+ Return findings in the Stack Research output format from your role definition."
209
+ )
210
+ ```
211
+
212
+ **Agent 2 — Features:**
213
+ ```
214
+ Task(
215
+ subagent_type: "general-purpose"
216
+ model: "sonnet"
217
+ description: "Features research"
218
+ run_in_background: true
219
+ prompt: "First, read {install-path}/specdacular/agents/project-researcher.md for your role.
220
+
221
+ <focus_area>Features</focus_area>
222
+
223
+ <project_context>
224
+ $PROJECT_CONTEXT
225
+ </project_context>
226
+
227
+ <research_questions>
228
+ 1. What features are table stakes (users expect them)?
229
+ 2. What features would differentiate this project?
230
+ 3. What features should wait for v2+?
231
+ 4. What anti-features should be explicitly avoided?
232
+ </research_questions>
233
+
234
+ Return findings in the Features Research output format from your role definition."
235
+ )
236
+ ```
237
+
238
+ **Agent 3 — Architecture:**
239
+ ```
240
+ Task(
241
+ subagent_type: "general-purpose"
242
+ model: "sonnet"
243
+ description: "Architecture research"
244
+ run_in_background: true
245
+ prompt: "First, read {install-path}/specdacular/agents/project-researcher.md for your role.
246
+
247
+ <focus_area>Architecture</focus_area>
248
+
249
+ <project_context>
250
+ $PROJECT_CONTEXT
251
+ </project_context>
252
+
253
+ <research_questions>
254
+ 1. What architecture pattern fits this project (monolith, microservices, modular)?
255
+ 2. What are the natural service boundaries?
256
+ 3. What does the data model look like?
257
+ 4. What directory structure is recommended?
258
+ </research_questions>
259
+
260
+ Return findings in the Architecture Research output format from your role definition."
261
+ )
262
+ ```
263
+
264
+ **Agent 4 — Pitfalls:**
265
+ ```
266
+ Task(
267
+ subagent_type: "general-purpose"
268
+ model: "sonnet"
269
+ description: "Pitfalls research"
270
+ run_in_background: true
271
+ prompt: "First, read {install-path}/specdacular/agents/project-researcher.md for your role.
272
+
273
+ <focus_area>Pitfalls</focus_area>
274
+
275
+ <project_context>
276
+ $PROJECT_CONTEXT
277
+ </project_context>
278
+
279
+ <research_questions>
280
+ 1. What do teams commonly get wrong when building this type of project?
281
+ 2. What are the performance and scalability pitfalls?
282
+ 3. What security concerns are specific to this domain?
283
+ 4. What architectural mistakes lead to rewrites?
284
+ </research_questions>
285
+
286
+ Return findings in the Pitfalls Research output format from your role definition."
287
+ )
288
+ ```
289
+
290
+ **Wait for all agents to complete.**
291
+
292
+ ```
293
+ Research agents complete:
294
+ - Stack: {✓ | ✗}
295
+ - Features: {✓ | ✗}
296
+ - Architecture: {✓ | ✗}
297
+ - Pitfalls: {✓ | ✗}
298
+ ```
299
+
300
+ Continue to write_research.
301
+ </step>
302
+
303
+ <step name="write_research">
304
+ Write research findings to files and synthesize a summary.
305
+
306
+ **Create research directory:**
307
+ ```bash
308
+ mkdir -p .specd/tasks/project/research
309
+ ```
310
+
311
+ **Write individual research files from agent outputs:**
312
+ - `.specd/tasks/project/research/STACK.md` — Stack agent findings
313
+ - `.specd/tasks/project/research/FEATURES.md` — Features agent findings
314
+ - `.specd/tasks/project/research/ARCHITECTURE.md` — Architecture agent findings
315
+ - `.specd/tasks/project/research/PITFALLS.md` — Pitfalls agent findings
316
+
317
+ **Synthesize SUMMARY.md:**
318
+ Read all 4 files and write `.specd/tasks/project/research/SUMMARY.md` containing:
319
+
320
+ ```markdown
321
+ # Research Summary: {project-name}
322
+
323
+ ## Key Recommendation
324
+
325
+ {One paragraph: the single most important takeaway from research}
326
+
327
+ ## Stack
328
+
329
+ {2-3 sentence summary of recommended stack}
330
+
331
+ ## Features
332
+
333
+ - **Table stakes:** {count} features identified
334
+ - **Differentiators:** {count} features identified
335
+ - **v2+:** {count} features deferred
336
+
337
+ ## Architecture
338
+
339
+ {2-3 sentence summary of recommended architecture}
340
+
341
+ ## Pitfalls
342
+
343
+ - **Critical:** {count} — {brief list}
344
+ - **Moderate:** {count}
345
+ - **Minor:** {count}
346
+
347
+ ## Confidence
348
+
349
+ | Area | Level | Notes |
350
+ |------|-------|-------|
351
+ | Stack | {level} | {brief note} |
352
+ | Features | {level} | {brief note} |
353
+ | Architecture | {level} | {brief note} |
354
+ | Pitfalls | {level} | {brief note} |
355
+
356
+ ## Roadmap Implications
357
+
358
+ {How research findings should influence requirements and phasing}
359
+ ```
360
+
361
+ **Update config.json:**
362
+ ```json
363
+ {
364
+ "stage": "research",
365
+ ...
366
+ }
367
+ ```
368
+
369
+ Continue to commit_research.
370
+ </step>
371
+
372
+ <step name="commit_research">
373
+ Commit research files.
374
+
375
+ @~/.claude/specdacular/references/commit-docs.md
376
+
377
+ - **$FILES:** `.specd/tasks/project/research/ .specd/tasks/project/config.json`
378
+ - **$MESSAGE:** `docs(project): research complete — {project-name}` with key findings summary
379
+ - **$LABEL:** `research findings`
380
+
381
+ Continue to research_complete.
382
+ </step>
383
+
384
+ <step name="research_complete">
385
+ Show research summary and indicate next steps.
386
+
387
+ ```
388
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
389
+ RESEARCH COMPLETE
390
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
391
+
392
+ **Project:** {project-name}
393
+
394
+ **Key recommendation:** {one-liner from SUMMARY.md}
395
+
396
+ **Findings:**
397
+ - Stack: {brief summary}
398
+ - Features: {brief summary}
399
+ - Architecture: {brief summary}
400
+ - Pitfalls: {brief summary}
401
+
402
+ **Confidence:** {overall level}
403
+
404
+ ## Created
405
+
406
+ - `.specd/tasks/project/research/STACK.md`
407
+ - `.specd/tasks/project/research/FEATURES.md`
408
+ - `.specd/tasks/project/research/ARCHITECTURE.md`
409
+ - `.specd/tasks/project/research/PITFALLS.md`
410
+ - `.specd/tasks/project/research/SUMMARY.md`
411
+
412
+ ```
413
+
414
+ Continue to requirements.
415
+ </step>
416
+
417
+ <step name="requirements">
418
+ Scope v1 features from research findings via multi-select.
419
+
420
+ ```
421
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
422
+ REQUIREMENTS SCOPING: {project-name}
423
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
424
+ ```
425
+
426
+ **Read research FEATURES.md:**
427
+ ```bash
428
+ cat .specd/tasks/project/research/FEATURES.md
429
+ ```
430
+ Parse features by category: table stakes, differentiators, nice-to-have, anti-features.
431
+
432
+ **Present features for scoping using AskUserQuestion with multiSelect: true.**
433
+
434
+ For each category, present features in batches of up to 4 (AskUserQuestion limit):
435
+
436
+ **Table Stakes:**
437
+ ```
438
+ **Table Stakes** — Users expect these. Deselect only if you have a reason.
439
+ ```
440
+ Use AskUserQuestion:
441
+ - header: "Table Stakes"
442
+ - question: "Which table stakes features should be in v1?"
443
+ - multiSelect: true
444
+ - options: up to 4 features per batch (label: feature name, description: brief description)
445
+ - Mark all as recommended for table stakes
446
+
447
+ If >4 table stakes features, use multiple AskUserQuestion calls.
448
+
449
+ **Differentiators:**
450
+ ```
451
+ **Differentiators** — These set your project apart. Pick what matters for v1.
452
+ ```
453
+ Use AskUserQuestion:
454
+ - header: "Differentiators"
455
+ - question: "Which differentiator features should be in v1?"
456
+ - multiSelect: true
457
+ - options: up to 4 per batch
458
+
459
+ **Nice-to-Have:**
460
+ ```
461
+ **Nice-to-Have** — These can wait for v2+. Include any you want in v1.
462
+ ```
463
+ Use AskUserQuestion:
464
+ - header: "Nice-to-Have"
465
+ - question: "Any nice-to-have features to include in v1?"
466
+ - multiSelect: true
467
+ - options: up to 4 per batch
468
+
469
+ **After all selections:**
470
+
471
+ Compile results:
472
+ - Selected features → v1 requirements with REQ-IDs (REQ-001, REQ-002, ...)
473
+ - Unselected table stakes/differentiators → v2+ with rationale "Deferred by user during scoping"
474
+ - Unselected nice-to-haves → v2+
475
+ - Anti-features from research → out of scope
476
+
477
+ **Write REQUIREMENTS.md:**
478
+ Use template at `~/.claude/specdacular/templates/tasks/REQUIREMENTS.md`
479
+ Write to `.specd/tasks/project/REQUIREMENTS.md`.
480
+
481
+ **Show summary:**
482
+ ```
483
+ **v1 Scope:**
484
+ - {count} table stakes
485
+ - {count} differentiators
486
+ - {count} nice-to-haves
487
+ Total: {count} requirements
488
+
489
+ **Deferred to v2+:** {count}
490
+ **Out of scope:** {count}
491
+ ```
492
+
493
+ **Commit:**
494
+ @~/.claude/specdacular/references/commit-docs.md
495
+
496
+ - **$FILES:** `.specd/tasks/project/REQUIREMENTS.md`
497
+ - **$MESSAGE:** `docs(project): requirements scoped — {count} v1 requirements`
498
+ - **$LABEL:** `requirements scoped`
499
+
500
+ Continue to roadmap.
501
+ </step>
502
+
503
+ <step name="roadmap">
504
+ Generate a phased roadmap from requirements, research, and architecture findings.
505
+
506
+ ```
507
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
508
+ GENERATING ROADMAP: {project-name}
509
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
510
+ ```
511
+
512
+ **Read context:**
513
+ - `.specd/tasks/project/REQUIREMENTS.md` — v1 requirements with REQ-IDs
514
+ - `.specd/tasks/project/research/ARCHITECTURE.md` — service boundaries, sub-projects
515
+ - `.specd/tasks/project/research/STACK.md` — technology choices
516
+ - `.specd/tasks/project/research/SUMMARY.md` — roadmap implications
517
+
518
+ **Identify sub-projects:**
519
+ From architecture research service boundaries and questioning context:
520
+ - Each service/boundary = potential sub-project
521
+ - If user specified sub-projects during questioning, use those
522
+ - Single-service projects still get one sub-project entry (DEC-002: always orchestrator mode)
523
+
524
+ **Generate phases:**
525
+ Order by dependency:
526
+ 1. Project setup / infrastructure (environment, CI/CD, shared config)
527
+ 2. Data model / core types (shared across services)
528
+ 3. API / backend services (data layer before consumers)
529
+ 4. Frontend / UI (consumes APIs)
530
+ 5. Integration / cross-service features
531
+ 6. Polish / optimization
532
+
533
+ Map each phase to the REQ-IDs it satisfies. Assign phases to sub-projects.
534
+
535
+ **Write ROADMAP.md:**
536
+ Write to `.specd/tasks/project/ROADMAP.md`:
537
+
538
+ ```markdown
539
+ # Roadmap: {project-name}
540
+
541
+ ## Overview
542
+
543
+ | Metric | Value |
544
+ |--------|-------|
545
+ | Total Phases | {count} |
546
+ | Sub-Projects | {count} |
547
+ | v1 Requirements | {count} |
548
+
549
+ ---
550
+
551
+ ## Sub-Projects
552
+
553
+ | Name | Type | Technology | Description |
554
+ |------|------|-----------|-------------|
555
+ | {name} | {frontend/backend/worker/etc.} | {stack} | {what it does} |
556
+
557
+ ---
558
+
559
+ ## Phases
560
+
561
+ {For each phase:}
562
+ - [ ] **Phase {N}: {Name}** — {goal} ({REQ-IDs})
563
+
564
+ ---
565
+
566
+ ## Phase Details
567
+
568
+ ### Phase {N}: {Name}
569
+
570
+ **Goal:** {what this phase accomplishes}
571
+ **Sub-project:** {which sub-project this targets}
572
+ **Requirements:** {REQ-IDs this phase satisfies}
573
+
574
+ **Creates:**
575
+ - {key deliverables}
576
+
577
+ **Dependencies:** {earlier phases this depends on}
578
+
579
+ **Success Criteria:**
580
+ 1. {testable criterion}
581
+
582
+ ---
583
+
584
+ ## Execution Order
585
+
586
+ {Dependency diagram}
587
+
588
+ ---
589
+
590
+ ## Requirements Coverage
591
+
592
+ | REQ-ID | Feature | Phase |
593
+ |--------|---------|-------|
594
+ | REQ-001 | {name} | Phase {N} |
595
+ ```
596
+
597
+ **Update config.json:**
598
+ ```json
599
+ {
600
+ "stage": "roadmap",
601
+ ...
602
+ }
603
+ ```
604
+
605
+ **Commit:**
606
+ @~/.claude/specdacular/references/commit-docs.md
607
+
608
+ - **$FILES:** `.specd/tasks/project/ROADMAP.md .specd/tasks/project/config.json`
609
+ - **$MESSAGE:** `docs(project): roadmap created — {N} phases, {N} sub-projects`
610
+ - **$LABEL:** `roadmap created`
611
+
612
+ Continue to roadmap_complete.
613
+ </step>
614
+
615
+ <step name="roadmap_complete">
616
+ Show roadmap summary and indicate next steps.
617
+
618
+ ```
619
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
620
+ ROADMAP COMPLETE
621
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
622
+
623
+ **Project:** {project-name}
624
+
625
+ **Sub-projects:** {list}
626
+ **Phases:** {count}
627
+ **Requirements covered:** {count}/{total}
628
+
629
+ {For each phase:}
630
+ Phase {N}: {Name} — {goal}
631
+ Sub-project: {name}
632
+ Requirements: {REQ-IDs}
633
+
634
+ ## Created
635
+
636
+ - `.specd/tasks/project/REQUIREMENTS.md` — {count} v1 requirements
637
+ - `.specd/tasks/project/ROADMAP.md` — {count} phases
638
+
639
+ ```
640
+
641
+ Continue to scaffold.
642
+ </step>
643
+
644
+ <step name="scaffold">
645
+ Create orchestrator config, sub-project directories, and seed setup tasks.
646
+
647
+ ```
648
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
649
+ SCAFFOLDING: {project-name}
650
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
651
+ ```
652
+
653
+ **Read context:**
654
+ - `.specd/tasks/project/ROADMAP.md` — sub-projects list, phases per sub-project
655
+ - `.specd/tasks/project/REQUIREMENTS.md` — v1 requirements for seeding setup tasks
656
+ - `.specd/tasks/project/research/STACK.md` — technology per sub-project
657
+ - `.specd/tasks/project/research/ARCHITECTURE.md` — service responsibilities
658
+
659
+ **Create orchestrator config at root:**
660
+ Write `.specd/config.json`:
661
+ ```json
662
+ {
663
+ "type": "orchestrator",
664
+ "project_name": "{project-name}",
665
+ "created": "{date}",
666
+ "projects": [
667
+ {
668
+ "name": "{sub-project-name}",
669
+ "path": "{sub-project-name}/",
670
+ "type": "{frontend|backend|worker|etc.}"
671
+ }
672
+ ]
673
+ }
674
+ ```
675
+
676
+ Note: If `.specd/config.json` already exists (e.g., with auto-commit settings), merge the orchestrator fields into it rather than overwriting.
677
+
678
+ **For each sub-project from ROADMAP.md:**
679
+
680
+ 1. Create directory structure:
681
+ ```bash
682
+ mkdir -p {sub-project-name}/.specd/tasks/setup
683
+ ```
684
+
685
+ 2. Write sub-project `.specd/config.json`:
686
+ ```json
687
+ {
688
+ "type": "project",
689
+ "project_name": "{sub-project-name}",
690
+ "orchestrator": "../",
691
+ "created": "{date}"
692
+ }
693
+ ```
694
+
695
+ 3. Write `.specd/tasks/setup/FEATURE.md` seeded from system-level research.
696
+ Use the FEATURE.md template (`~/.claude/specdacular/templates/tasks/FEATURE.md`) filled with:
697
+
698
+ - **What This Is:** Initial setup for {sub-project-name} — {description from ROADMAP.md}. Creates project structure, installs dependencies, configures development environment.
699
+
700
+ - **Must Create:** Based on STACK.md recommendations for this sub-project:
701
+ - Project configuration files (package.json, tsconfig, etc.)
702
+ - Directory structure per ARCHITECTURE.md recommendations
703
+ - Development environment config (linting, formatting, testing)
704
+ - Basic entry point / hello world
705
+
706
+ - **Must Integrate With:** Other sub-projects per ARCHITECTURE.md:
707
+ - Shared types/interfaces if identified
708
+ - API contracts between services
709
+ - Orchestrator config at root
710
+
711
+ - **Constraints:** From STACK.md and ARCHITECTURE.md:
712
+ - Specific technology versions
713
+ - Architecture patterns to follow
714
+ - Coding standards
715
+
716
+ - **Success Criteria:**
717
+ - Project initializes without errors
718
+ - Dev server/process starts
719
+ - Tests run (even if just a placeholder)
720
+ - Linting passes
721
+
722
+ 4. Show per sub-project:
723
+ ```
724
+ Created: {sub-project-name}/
725
+ ├── .specd/config.json
726
+ └── .specd/tasks/setup/FEATURE.md
727
+ ```
728
+
729
+ **Update project config.json:**
730
+ ```json
731
+ {
732
+ "stage": "complete",
733
+ ...
734
+ }
735
+ ```
736
+
737
+ **Commit:**
738
+ @~/.claude/specdacular/references/commit-docs.md
739
+
740
+ - **$FILES:** `.specd/config.json` plus all sub-project `.specd/` directories
741
+ - **$MESSAGE:** `docs(project): scaffold {N} sub-projects` with list of sub-project names
742
+ - **$LABEL:** `scaffolding complete`
743
+
744
+ Continue to completion.
745
+ </step>
746
+
747
+ <step name="completion">
748
+ Show final project summary with all artifacts and next steps.
749
+
750
+ ```
751
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
752
+ PROJECT COMPLETE: {project-name}
753
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
754
+
755
+ ## Artifacts
756
+
757
+ - `.specd/tasks/project/PROJECT.md` — Project vision
758
+ - `.specd/tasks/project/research/` — Stack, features, architecture, pitfalls
759
+ - `.specd/tasks/project/REQUIREMENTS.md` — {count} v1 requirements
760
+ - `.specd/tasks/project/ROADMAP.md` — {count} phases
761
+ - `.specd/config.json` — Orchestrator config
762
+
763
+ ## Sub-Projects
764
+
765
+ {For each sub-project:}
766
+ **{name}/** — {description}
767
+ └── Ready: `/specd.continue setup` to begin
768
+
769
+ ## Next Steps
770
+
771
+ For each sub-project, run the setup task:
772
+
773
+ cd {sub-project-name}
774
+ /specd.continue setup
775
+
776
+ This will walk through setting up the project using the
777
+ research findings and requirements from this session.
778
+ ```
779
+
780
+ End workflow.
781
+ </step>
782
+
783
+ </process>
784
+
785
+ <success_criteria>
786
+ - Questioning produces PROJECT.md with clear vision, goals, users, constraints
787
+ - Project directory created at `.specd/tasks/project/`
788
+ - CONTEXT.md and DECISIONS.md initialized from discussion
789
+ - 4 research agents spawn in parallel after PROJECT.md is written
790
+ - Each agent writes its findings (STACK.md, FEATURES.md, ARCHITECTURE.md, PITFALLS.md)
791
+ - SUMMARY.md synthesized from all 4 outputs
792
+ - Requirements scoped via multi-select from research FEATURES.md
793
+ - REQUIREMENTS.md written with REQ-IDs, v1/v2/out-of-scope sections
794
+ - Roadmap generated with phases mapped to REQ-IDs and sub-projects
795
+ - Orchestrator config created at root with projects array
796
+ - Sub-project directories created with config and seeded setup FEATURE.md
797
+ - All files committed to git
798
+ - Completion banner shows all artifacts and next steps per sub-project
799
+ </success_criteria>