@howlil/ez-agents 3.4.2 → 3.5.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.
- package/README.md +77 -2
- package/agents/ez-observer-agent.md +260 -0
- package/agents/ez-release-agent.md +333 -0
- package/agents/ez-requirements-agent.md +377 -0
- package/agents/ez-scrum-master-agent.md +242 -0
- package/agents/ez-tech-lead-agent.md +267 -0
- package/bin/install.js +3221 -3272
- package/commands/ez/arch-review.md +102 -0
- package/commands/ez/execute-phase.md +11 -0
- package/commands/ez/export-session.md +79 -0
- package/commands/ez/gather-requirements.md +117 -0
- package/commands/ez/git-workflow.md +72 -0
- package/commands/ez/hotfix.md +120 -0
- package/commands/ez/import-session.md +82 -0
- package/commands/ez/list-sessions.md +96 -0
- package/commands/ez/package-manager.md +316 -0
- package/commands/ez/plan-phase.md +9 -1
- package/commands/ez/preflight.md +79 -0
- package/commands/ez/progress.md +13 -1
- package/commands/ez/release.md +153 -0
- package/commands/ez/resume.md +107 -0
- package/commands/ez/standup.md +85 -0
- package/ez-agents/bin/ez-tools.cjs +1095 -716
- package/ez-agents/bin/lib/bdd-validator.cjs +622 -0
- package/ez-agents/bin/lib/content-scanner.cjs +238 -0
- package/ez-agents/bin/lib/context-cache.cjs +154 -0
- package/ez-agents/bin/lib/context-errors.cjs +71 -0
- package/ez-agents/bin/lib/context-manager.cjs +220 -0
- package/ez-agents/bin/lib/discussion-synthesizer.cjs +458 -0
- package/ez-agents/bin/lib/file-access.cjs +207 -0
- package/ez-agents/bin/lib/git-errors.cjs +83 -0
- package/ez-agents/bin/lib/git-utils.cjs +321 -203
- package/ez-agents/bin/lib/git-workflow-engine.cjs +1157 -0
- package/ez-agents/bin/lib/index.cjs +46 -2
- package/ez-agents/bin/lib/lockfile-validator.cjs +227 -0
- package/ez-agents/bin/lib/logger.cjs +124 -154
- package/ez-agents/bin/lib/memory-compression.cjs +256 -0
- package/ez-agents/bin/lib/metrics-tracker.cjs +406 -0
- package/ez-agents/bin/lib/package-manager-detector.cjs +203 -0
- package/ez-agents/bin/lib/package-manager-executor.cjs +385 -0
- package/ez-agents/bin/lib/package-manager-service.cjs +216 -0
- package/ez-agents/bin/lib/release-validator.cjs +614 -0
- package/ez-agents/bin/lib/safe-exec.cjs +128 -214
- package/ez-agents/bin/lib/session-chain.cjs +304 -0
- package/ez-agents/bin/lib/session-errors.cjs +81 -0
- package/ez-agents/bin/lib/session-export.cjs +251 -0
- package/ez-agents/bin/lib/session-import.cjs +262 -0
- package/ez-agents/bin/lib/session-manager.cjs +280 -0
- package/ez-agents/bin/lib/tier-manager.cjs +428 -0
- package/ez-agents/bin/lib/url-fetch.cjs +170 -0
- package/ez-agents/references/metrics-schema.md +118 -0
- package/ez-agents/references/planning-config.md +140 -0
- package/ez-agents/references/tier-strategy.md +103 -0
- package/ez-agents/templates/bdd-feature.md +173 -0
- package/ez-agents/templates/discussion.md +68 -0
- package/ez-agents/templates/incident-runbook.md +205 -0
- package/ez-agents/templates/release-checklist.md +133 -0
- package/ez-agents/templates/rollback-plan.md +201 -0
- package/ez-agents/workflows/arch-review.md +54 -0
- package/ez-agents/workflows/autonomous.md +844 -743
- package/ez-agents/workflows/execute-phase.md +45 -0
- package/ez-agents/workflows/export-session.md +255 -0
- package/ez-agents/workflows/gather-requirements.md +206 -0
- package/ez-agents/workflows/help.md +92 -0
- package/ez-agents/workflows/hotfix.md +291 -0
- package/ez-agents/workflows/import-session.md +303 -0
- package/ez-agents/workflows/new-milestone.md +713 -384
- package/ez-agents/workflows/new-project.md +1107 -1113
- package/ez-agents/workflows/plan-phase.md +22 -0
- package/ez-agents/workflows/progress.md +15 -25
- package/ez-agents/workflows/release.md +253 -0
- package/ez-agents/workflows/resume-session.md +215 -0
- package/ez-agents/workflows/standup.md +64 -0
- package/package.json +9 -2
|
@@ -1,1113 +1,1107 @@
|
|
|
1
|
-
<purpose>
|
|
2
|
-
Initialize a new project through unified flow: questioning, research (optional), requirements, roadmap. This is the most leveraged moment in any project — deep questioning here means better plans, better execution, better outcomes. One workflow takes you from idea to ready-for-planning.
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
-
|
|
18
|
-
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
**
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
##
|
|
84
|
-
|
|
85
|
-
**
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
])
|
|
122
|
-
```
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
**If
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
"
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
```
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
**
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
"
|
|
481
|
-
"
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
**
|
|
496
|
-
|
|
497
|
-
```
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
<
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
-
|
|
689
|
-
-
|
|
690
|
-
</
|
|
691
|
-
|
|
692
|
-
<
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
</
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
</
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
```
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
-
|
|
787
|
-
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
-
|
|
811
|
-
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
-
|
|
841
|
-
-
|
|
842
|
-
-
|
|
843
|
-
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
-
|
|
851
|
-
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
-
|
|
857
|
-
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
```
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
```
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
```
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
**
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
-
|
|
1086
|
-
-
|
|
1087
|
-
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
- [ ]
|
|
1094
|
-
- [ ]
|
|
1095
|
-
- [ ]
|
|
1096
|
-
- [ ]
|
|
1097
|
-
- [ ]
|
|
1098
|
-
- [ ]
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
-
|
|
1103
|
-
-
|
|
1104
|
-
-
|
|
1105
|
-
-
|
|
1106
|
-
-
|
|
1107
|
-
|
|
1108
|
-
- [ ] REQUIREMENTS.md traceability updated
|
|
1109
|
-
- [ ] User knows next step is `/ez:discuss-phase 1`
|
|
1110
|
-
|
|
1111
|
-
**Atomic commits:** Each phase commits its artifacts immediately. If context is lost, artifacts persist.
|
|
1112
|
-
|
|
1113
|
-
</success_criteria>
|
|
1
|
+
<purpose>
|
|
2
|
+
Initialize a new project through unified flow: questioning, research (optional), requirements, roadmap. This is the most leveraged moment in any project — deep questioning here means better plans, better execution, better outcomes. One workflow takes you from idea to ready-for-planning.
|
|
3
|
+
|
|
4
|
+
**GSD-2 Enhanced:** Includes health check, cost tracking, crash recovery, fresh context, and stuck detection for production-grade reliability.
|
|
5
|
+
</purpose>
|
|
6
|
+
|
|
7
|
+
<required_reading>
|
|
8
|
+
Read all files referenced by the invoking prompt's execution_context before starting.
|
|
9
|
+
</required_reading>
|
|
10
|
+
|
|
11
|
+
<auto_mode>
|
|
12
|
+
## Auto Mode Detection
|
|
13
|
+
|
|
14
|
+
Check if `--auto` flag is present in $ARGUMENTS.
|
|
15
|
+
|
|
16
|
+
**If auto mode:**
|
|
17
|
+
- Skip brownfield mapping offer (assume greenfield)
|
|
18
|
+
- Skip deep questioning (extract context from provided document)
|
|
19
|
+
- Config: YOLO mode is implicit (skip that question), but ask granularity/git/agents FIRST (Step 2a)
|
|
20
|
+
- After config: run Steps 6-9 automatically with smart defaults:
|
|
21
|
+
- Research: Always yes
|
|
22
|
+
- Requirements: Include all table stakes + features from provided document
|
|
23
|
+
- Requirements approval: Auto-approve
|
|
24
|
+
- Roadmap approval: Auto-approve
|
|
25
|
+
|
|
26
|
+
**Document requirement:**
|
|
27
|
+
Auto mode requires an idea document — either:
|
|
28
|
+
- File reference: `/ez:new-project --auto @prd.md`
|
|
29
|
+
- Pasted/written text in the prompt
|
|
30
|
+
|
|
31
|
+
If no document content provided, error:
|
|
32
|
+
|
|
33
|
+
```
|
|
34
|
+
Error: --auto requires an idea document.
|
|
35
|
+
|
|
36
|
+
Usage:
|
|
37
|
+
/ez:new-project --auto @your-idea.md
|
|
38
|
+
/ez:new-project --auto [paste or write your idea here]
|
|
39
|
+
|
|
40
|
+
The document should describe what you want to build.
|
|
41
|
+
```
|
|
42
|
+
</auto_mode>
|
|
43
|
+
|
|
44
|
+
<process>
|
|
45
|
+
|
|
46
|
+
## 0. Pre-Flight Health Check (GSD-2 Pattern)
|
|
47
|
+
|
|
48
|
+
**MANDATORY FIRST STEP — Validate environment before ANY operation:**
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
# Run health check
|
|
52
|
+
HEALTH=$(node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" doctor --json)
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
**Check:**
|
|
56
|
+
- ✅ Node.js version >= 16.7.0
|
|
57
|
+
- ✅ AI tools available (Claude, OpenCode, etc.)
|
|
58
|
+
- ✅ Config valid (`.planning/config.json` or create default)
|
|
59
|
+
- ✅ Git repo initialized (or auto-init)
|
|
60
|
+
- ✅ API keys configured
|
|
61
|
+
|
|
62
|
+
**If any check fails:**
|
|
63
|
+
```
|
|
64
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
65
|
+
EZ ► HEALTH CHECK FAILED
|
|
66
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
67
|
+
|
|
68
|
+
❌ [Failed check description]
|
|
69
|
+
|
|
70
|
+
Fix:
|
|
71
|
+
[suggested command]
|
|
72
|
+
|
|
73
|
+
Example:
|
|
74
|
+
$ [example command]
|
|
75
|
+
|
|
76
|
+
Resolve before continuing with project initialization.
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
**Abort project init until resolved.**
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
## 0a. Gather Initial Context (CONTEXT-01, CONTEXT-02)
|
|
84
|
+
|
|
85
|
+
**Initialize ContextManager for context gathering:**
|
|
86
|
+
|
|
87
|
+
```javascript
|
|
88
|
+
const ContextManager = require('../bin/lib/context-manager.cjs');
|
|
89
|
+
const contextManager = new ContextManager(process.cwd());
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
**Request initial project context:**
|
|
93
|
+
|
|
94
|
+
```javascript
|
|
95
|
+
const context = await contextManager.requestContext({
|
|
96
|
+
files: ['README.md', 'package.json'],
|
|
97
|
+
urls: []
|
|
98
|
+
});
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
**Agent can request additional context using:**
|
|
102
|
+
- `ez-tools context read <pattern>` — Read local files
|
|
103
|
+
- `ez-tools context fetch <url>` — Fetch URL content (requires user confirmation)
|
|
104
|
+
|
|
105
|
+
**Update STATE.md with context sources:**
|
|
106
|
+
|
|
107
|
+
```javascript
|
|
108
|
+
await contextManager.updateStateMd();
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
**Continue to Setup (Step 1) with gathered context.**
|
|
112
|
+
|
|
113
|
+
---
|
|
114
|
+
|
|
115
|
+
## 1. Setup with Lock File (GSD-2 Pattern)
|
|
116
|
+
|
|
117
|
+
**Execute initialization with crash recovery:**
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
INIT=$(node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" init new-project)
|
|
121
|
+
if [[ "$INIT" == @file:* ]]; then INIT=$(cat "${INIT#@file:}"); fi
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
Parse JSON for: `researcher_model`, `synthesizer_model`, `roadmapper_model`, `commit_docs`, `project_exists`, `has_codebase_map`, `planning_exists`, `has_existing_code`, `has_package_file`, `is_brownfield`, `needs_codebase_map`, `has_git`, `project_path`.
|
|
125
|
+
|
|
126
|
+
**If `project_exists` is true:** Error — project already initialized. Use `/ez:progress`.
|
|
127
|
+
|
|
128
|
+
**Create lock file for crash recovery:**
|
|
129
|
+
|
|
130
|
+
```bash
|
|
131
|
+
# Create auto.lock
|
|
132
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-create \
|
|
133
|
+
--operation="new-project" \
|
|
134
|
+
--project-path="$project_path"
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
**Create `.planning/auto.lock`:**
|
|
138
|
+
```json
|
|
139
|
+
{
|
|
140
|
+
"pid": 12345,
|
|
141
|
+
"operation": "new-project",
|
|
142
|
+
"project_path": "/path/to/project",
|
|
143
|
+
"started_at": "2026-03-18T12:00:00.000Z",
|
|
144
|
+
"last_heartbeat": "2026-03-18T12:00:00.000Z",
|
|
145
|
+
"state": "setup"
|
|
146
|
+
}
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
**If `has_git` is false:** Initialize git:
|
|
150
|
+
```bash
|
|
151
|
+
git init
|
|
152
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="git_initialized"
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
---
|
|
156
|
+
|
|
157
|
+
## 2. Brownfield Offer
|
|
158
|
+
|
|
159
|
+
**If auto mode:** Skip to Step 4 (assume greenfield, synthesize PROJECT.md from provided document).
|
|
160
|
+
|
|
161
|
+
**If `needs_codebase_map` is true** (from init — existing code detected but no codebase map):
|
|
162
|
+
|
|
163
|
+
Use AskUserQuestion:
|
|
164
|
+
- header: "Codebase"
|
|
165
|
+
- question: "I detected existing code in this directory. Would you like to map the codebase first?"
|
|
166
|
+
- options:
|
|
167
|
+
- "Map codebase first" — Run /ez:map-codebase to understand existing architecture (Recommended)
|
|
168
|
+
- "Skip mapping" — Proceed with project initialization
|
|
169
|
+
|
|
170
|
+
**If "Map codebase first":**
|
|
171
|
+
```
|
|
172
|
+
Run `/ez:map-codebase` first, then return to `/ez:new-project`
|
|
173
|
+
```
|
|
174
|
+
Exit command.
|
|
175
|
+
|
|
176
|
+
**If "Skip mapping" OR `needs_codebase_map` is false:** Continue to Step 3.
|
|
177
|
+
|
|
178
|
+
**Update lock file state:**
|
|
179
|
+
```bash
|
|
180
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="brownfield_check_complete"
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
---
|
|
184
|
+
|
|
185
|
+
## 2a. Auto Mode Config (auto mode only)
|
|
186
|
+
|
|
187
|
+
**If auto mode:** Collect config settings upfront before processing the idea document.
|
|
188
|
+
|
|
189
|
+
YOLO mode is implicit (auto = YOLO). Ask remaining config questions:
|
|
190
|
+
|
|
191
|
+
**Round 1 — Core settings (3 questions, no Mode question):**
|
|
192
|
+
|
|
193
|
+
```
|
|
194
|
+
AskUserQuestion([
|
|
195
|
+
{
|
|
196
|
+
header: "Granularity",
|
|
197
|
+
question: "How finely should scope be sliced into phases?",
|
|
198
|
+
multiSelect: false,
|
|
199
|
+
options: [
|
|
200
|
+
{ label: "Coarse (Recommended)", description: "Fewer, broader phases (3-5 phases, 1-3 plans each)" },
|
|
201
|
+
{ label: "Standard", description: "Balanced phase size (5-8 phases, 3-5 plans each)" },
|
|
202
|
+
{ label: "Fine", description: "Many focused phases (8-12 phases, 5-10 plans each)" }
|
|
203
|
+
]
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
header: "Execution",
|
|
207
|
+
question: "Run plans in parallel?",
|
|
208
|
+
multiSelect: false,
|
|
209
|
+
options: [
|
|
210
|
+
{ label: "Parallel (Recommended)", description: "Independent plans run simultaneously" },
|
|
211
|
+
{ label: "Sequential", description: "One plan at a time" }
|
|
212
|
+
]
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
header: "Git Tracking",
|
|
216
|
+
question: "Commit planning docs to git?",
|
|
217
|
+
multiSelect: false,
|
|
218
|
+
options: [
|
|
219
|
+
{ label: "Yes (Recommended)", description: "Planning docs tracked in version control" },
|
|
220
|
+
{ label: "No", description: "Keep .planning/ local-only (add to .gitignore)" }
|
|
221
|
+
]
|
|
222
|
+
}
|
|
223
|
+
])
|
|
224
|
+
```
|
|
225
|
+
|
|
226
|
+
**Round 2 — Workflow agents (same as Step 5):**
|
|
227
|
+
|
|
228
|
+
```
|
|
229
|
+
AskUserQuestion([
|
|
230
|
+
{
|
|
231
|
+
header: "Research",
|
|
232
|
+
question: "Research before planning each phase? (adds tokens/time)",
|
|
233
|
+
multiSelect: false,
|
|
234
|
+
options: [
|
|
235
|
+
{ label: "Yes (Recommended)", description: "Investigate domain, find patterns, surface gotchas" },
|
|
236
|
+
{ label: "No", description: "Plan directly from requirements" }
|
|
237
|
+
]
|
|
238
|
+
},
|
|
239
|
+
{
|
|
240
|
+
header: "Plan Check",
|
|
241
|
+
question: "Verify plans will achieve their goals? (adds tokens/time)",
|
|
242
|
+
multiSelect: false,
|
|
243
|
+
options: [
|
|
244
|
+
{ label: "Yes (Recommended)", description: "Catch gaps before execution starts" },
|
|
245
|
+
{ label: "No", description: "Execute plans without verification" }
|
|
246
|
+
]
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
header: "Verifier",
|
|
250
|
+
question: "Verify work satisfies requirements after each phase? (adds tokens/time)",
|
|
251
|
+
multiSelect: false,
|
|
252
|
+
options: [
|
|
253
|
+
{ label: "Yes (Recommended)", description: "Confirm deliverables match phase goals" },
|
|
254
|
+
{ label: "No", description: "Trust execution, skip verification" }
|
|
255
|
+
]
|
|
256
|
+
},
|
|
257
|
+
{
|
|
258
|
+
header: "AI Models",
|
|
259
|
+
question: "Which AI models for planning agents?",
|
|
260
|
+
multiSelect: false,
|
|
261
|
+
options: [
|
|
262
|
+
{ label: "Balanced (Recommended)", description: "Sonnet for most agents — good quality/cost ratio" },
|
|
263
|
+
{ label: "Quality", description: "Opus for research/roadmap — higher cost, deeper analysis" },
|
|
264
|
+
{ label: "Budget", description: "Haiku where possible — fastest, lowest cost" }
|
|
265
|
+
]
|
|
266
|
+
}
|
|
267
|
+
])
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
Create `.planning/config.json` with mode set to "yolo":
|
|
271
|
+
|
|
272
|
+
```json
|
|
273
|
+
{
|
|
274
|
+
"mode": "yolo",
|
|
275
|
+
"granularity": "[selected]",
|
|
276
|
+
"parallelization": true|false,
|
|
277
|
+
"commit_docs": true|false,
|
|
278
|
+
"model_profile": "quality|balanced|budget",
|
|
279
|
+
"workflow": {
|
|
280
|
+
"research": true|false,
|
|
281
|
+
"plan_check": true|false,
|
|
282
|
+
"verifier": true|false,
|
|
283
|
+
"nyquist_validation": depth !== "quick",
|
|
284
|
+
"auto_advance": true
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
```
|
|
288
|
+
|
|
289
|
+
**If commit_docs = No:** Add `.planning/` to `.gitignore`.
|
|
290
|
+
|
|
291
|
+
**Commit config.json:**
|
|
292
|
+
|
|
293
|
+
```bash
|
|
294
|
+
mkdir -p .planning
|
|
295
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" commit "chore: add project config" --files .planning/config.json
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
**Persist auto-advance chain flag to config (survives context compaction):**
|
|
299
|
+
|
|
300
|
+
```bash
|
|
301
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" config-set workflow._auto_chain_active true
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
**Update lock file state:**
|
|
305
|
+
```bash
|
|
306
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="config_complete"
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
Proceed to Step 4 (skip Steps 3 and 5).
|
|
310
|
+
|
|
311
|
+
---
|
|
312
|
+
|
|
313
|
+
## 3. Deep Questioning
|
|
314
|
+
|
|
315
|
+
**If auto mode:** Skip (already handled in Step 2a). Extract project context from provided document instead and proceed to Step 4.
|
|
316
|
+
|
|
317
|
+
**Display stage banner:**
|
|
318
|
+
|
|
319
|
+
```
|
|
320
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
321
|
+
EZ ► QUESTIONING
|
|
322
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
323
|
+
```
|
|
324
|
+
|
|
325
|
+
**Open the conversation:**
|
|
326
|
+
|
|
327
|
+
Ask inline (freeform, NOT AskUserQuestion):
|
|
328
|
+
|
|
329
|
+
"What do you want to build?"
|
|
330
|
+
|
|
331
|
+
Wait for their response. This gives you the context needed to ask intelligent follow-up questions.
|
|
332
|
+
|
|
333
|
+
**Follow the thread:**
|
|
334
|
+
|
|
335
|
+
Based on what they said, ask follow-up questions that dig into their response. Use AskUserQuestion with options that probe what they mentioned — interpretations, clarifications, concrete examples.
|
|
336
|
+
|
|
337
|
+
Keep following threads. Each answer opens new threads to explore. Ask about:
|
|
338
|
+
- What excited them
|
|
339
|
+
- What problem sparked this
|
|
340
|
+
- What they mean by vague terms
|
|
341
|
+
- What it would actually look like
|
|
342
|
+
- What's already decided
|
|
343
|
+
|
|
344
|
+
Consult `questioning.md` for techniques:
|
|
345
|
+
- Challenge vagueness
|
|
346
|
+
- Make abstract concrete
|
|
347
|
+
- Surface assumptions
|
|
348
|
+
- Find edges
|
|
349
|
+
- Reveal motivation
|
|
350
|
+
|
|
351
|
+
**Check context (background, not out loud):**
|
|
352
|
+
|
|
353
|
+
As you go, mentally check the context checklist from `questioning.md`. If gaps remain, weave questions naturally. Don't suddenly switch to checklist mode.
|
|
354
|
+
|
|
355
|
+
**Decision gate:**
|
|
356
|
+
|
|
357
|
+
When you could write a clear PROJECT.md, use AskUserQuestion:
|
|
358
|
+
|
|
359
|
+
- header: "Ready?"
|
|
360
|
+
- question: "I think I understand what you're after. Ready to create PROJECT.md?"
|
|
361
|
+
- options:
|
|
362
|
+
- "Create PROJECT.md" — Let's move forward
|
|
363
|
+
- "Keep exploring" — I want to share more / ask me more
|
|
364
|
+
|
|
365
|
+
If "Keep exploring" — ask what they want to add, or identify gaps and probe naturally.
|
|
366
|
+
|
|
367
|
+
Loop until "Create PROJECT.md" selected.
|
|
368
|
+
|
|
369
|
+
**Update lock file state:**
|
|
370
|
+
```bash
|
|
371
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="questioning_complete"
|
|
372
|
+
```
|
|
373
|
+
|
|
374
|
+
---
|
|
375
|
+
|
|
376
|
+
## 4. Write PROJECT.md
|
|
377
|
+
|
|
378
|
+
**If auto mode:** Synthesize from provided document. No "Ready?" gate was shown — proceed directly to commit.
|
|
379
|
+
|
|
380
|
+
Synthesize all context into `.planning/PROJECT.md` using the template from `templates/project.md`.
|
|
381
|
+
|
|
382
|
+
**For greenfield projects:**
|
|
383
|
+
|
|
384
|
+
Initialize requirements as hypotheses:
|
|
385
|
+
|
|
386
|
+
```markdown
|
|
387
|
+
## Requirements
|
|
388
|
+
|
|
389
|
+
### Validated
|
|
390
|
+
|
|
391
|
+
(None yet — ship to validate)
|
|
392
|
+
|
|
393
|
+
### Active
|
|
394
|
+
|
|
395
|
+
- [ ] [Requirement 1]
|
|
396
|
+
- [ ] [Requirement 2]
|
|
397
|
+
- [ ] [Requirement 3]
|
|
398
|
+
|
|
399
|
+
### Out of Scope
|
|
400
|
+
|
|
401
|
+
- [Exclusion 1] — [why]
|
|
402
|
+
- [Exclusion 2] — [why]
|
|
403
|
+
```
|
|
404
|
+
|
|
405
|
+
All Active requirements are hypotheses until shipped and validated.
|
|
406
|
+
|
|
407
|
+
**For brownfield projects (codebase map exists):**
|
|
408
|
+
|
|
409
|
+
Infer Validated requirements from existing code:
|
|
410
|
+
|
|
411
|
+
1. Read `.planning/codebase/ARCHITECTURE.md` and `STACK.md`
|
|
412
|
+
2. Identify what the codebase already does
|
|
413
|
+
3. These become the initial Validated set
|
|
414
|
+
|
|
415
|
+
```markdown
|
|
416
|
+
## Requirements
|
|
417
|
+
|
|
418
|
+
### Validated
|
|
419
|
+
|
|
420
|
+
- ✓ [Existing capability 1] — existing
|
|
421
|
+
- ✓ [Existing capability 2] — existing
|
|
422
|
+
- ✓ [Existing capability 3] — existing
|
|
423
|
+
|
|
424
|
+
### Active
|
|
425
|
+
|
|
426
|
+
- [ ] [New requirement 1]
|
|
427
|
+
- [ ] [New requirement 2]
|
|
428
|
+
|
|
429
|
+
### Out of Scope
|
|
430
|
+
|
|
431
|
+
- [Exclusion 1] — [why]
|
|
432
|
+
```
|
|
433
|
+
|
|
434
|
+
**Key Decisions:**
|
|
435
|
+
|
|
436
|
+
Initialize with any decisions made during questioning:
|
|
437
|
+
|
|
438
|
+
```markdown
|
|
439
|
+
## Key Decisions
|
|
440
|
+
|
|
441
|
+
| Decision | Rationale | Outcome |
|
|
442
|
+
|----------|-----------|---------|
|
|
443
|
+
| [Choice from questioning] | [Why] | — Pending |
|
|
444
|
+
```
|
|
445
|
+
|
|
446
|
+
**Last updated footer:**
|
|
447
|
+
|
|
448
|
+
```markdown
|
|
449
|
+
---
|
|
450
|
+
*Last updated: [date] after initialization*
|
|
451
|
+
```
|
|
452
|
+
|
|
453
|
+
Do not compress. Capture everything gathered.
|
|
454
|
+
|
|
455
|
+
**Commit PROJECT.md:**
|
|
456
|
+
|
|
457
|
+
```bash
|
|
458
|
+
mkdir -p .planning
|
|
459
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" commit "docs: initialize project" --files .planning/PROJECT.md
|
|
460
|
+
```
|
|
461
|
+
|
|
462
|
+
**Update lock file state:**
|
|
463
|
+
```bash
|
|
464
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="project_defined"
|
|
465
|
+
```
|
|
466
|
+
|
|
467
|
+
---
|
|
468
|
+
|
|
469
|
+
## 5. Workflow Preferences
|
|
470
|
+
|
|
471
|
+
**If auto mode:** Skip — config was collected in Step 2a. Proceed to Step 5.5.
|
|
472
|
+
|
|
473
|
+
**Check for global defaults** at `~/.ez/defaults.json` using direct path existence checks only.
|
|
474
|
+
Do **not** glob or recursively search home directories for this file.
|
|
475
|
+
If it exists, offer to use saved defaults:
|
|
476
|
+
|
|
477
|
+
```
|
|
478
|
+
AskUserQuestion([
|
|
479
|
+
{
|
|
480
|
+
question: "Use your saved default settings? (from ~/.ez/defaults.json)",
|
|
481
|
+
header: "Defaults",
|
|
482
|
+
multiSelect: false,
|
|
483
|
+
options: [
|
|
484
|
+
{ label: "Yes (Recommended)", description: "Use saved defaults, skip settings questions" },
|
|
485
|
+
{ label: "No", description: "Configure settings manually" }
|
|
486
|
+
]
|
|
487
|
+
}
|
|
488
|
+
])
|
|
489
|
+
```
|
|
490
|
+
|
|
491
|
+
If "Yes": read `~/.ez/defaults.json`, use those values for config.json, and skip directly to **Commit config.json** below.
|
|
492
|
+
|
|
493
|
+
If "No" or it doesn't exist: proceed with the questions below.
|
|
494
|
+
|
|
495
|
+
**Round 1 — Core workflow settings (4 questions):**
|
|
496
|
+
|
|
497
|
+
```
|
|
498
|
+
questions: [
|
|
499
|
+
{
|
|
500
|
+
header: "Mode",
|
|
501
|
+
question: "How do you want to work?",
|
|
502
|
+
multiSelect: false,
|
|
503
|
+
options: [
|
|
504
|
+
{ label: "YOLO (Recommended)", description: "Auto-approve, just execute" },
|
|
505
|
+
{ label: "Interactive", description: "Confirm at each step" }
|
|
506
|
+
]
|
|
507
|
+
},
|
|
508
|
+
{
|
|
509
|
+
header: "Granularity",
|
|
510
|
+
question: "How finely should scope be sliced into phases?",
|
|
511
|
+
multiSelect: false,
|
|
512
|
+
options: [
|
|
513
|
+
{ label: "Coarse", description: "Fewer, broader phases (3-5 phases, 1-3 plans each)" },
|
|
514
|
+
{ label: "Standard", description: "Balanced phase size (5-8 phases, 3-5 plans each)" },
|
|
515
|
+
{ label: "Fine", description: "Many focused phases (8-12 phases, 5-10 plans each)" }
|
|
516
|
+
]
|
|
517
|
+
},
|
|
518
|
+
{
|
|
519
|
+
header: "Execution",
|
|
520
|
+
question: "Run plans in parallel?",
|
|
521
|
+
multiSelect: false,
|
|
522
|
+
options: [
|
|
523
|
+
{ label: "Parallel (Recommended)", description: "Independent plans run simultaneously" },
|
|
524
|
+
{ label: "Sequential", description: "One plan at a time" }
|
|
525
|
+
]
|
|
526
|
+
},
|
|
527
|
+
{
|
|
528
|
+
header: "Git Tracking",
|
|
529
|
+
question: "Commit planning docs to git?",
|
|
530
|
+
multiSelect: false,
|
|
531
|
+
options: [
|
|
532
|
+
{ label: "Yes (Recommended)", description: "Planning docs tracked in version control" },
|
|
533
|
+
{ label: "No", description: "Keep .planning/ local-only (add to .gitignore)" }
|
|
534
|
+
]
|
|
535
|
+
}
|
|
536
|
+
]
|
|
537
|
+
```
|
|
538
|
+
|
|
539
|
+
**Round 2 — Workflow agents:**
|
|
540
|
+
|
|
541
|
+
These spawn additional agents during planning/execution. They add tokens and time but improve quality. They add tokens and time but improve quality.
|
|
542
|
+
|
|
543
|
+
All recommended for important projects. Skip for quick experiments.
|
|
544
|
+
|
|
545
|
+
```
|
|
546
|
+
questions: [
|
|
547
|
+
{
|
|
548
|
+
header: "Research",
|
|
549
|
+
question: "Research before planning each phase? (adds tokens/time)",
|
|
550
|
+
multiSelect: false,
|
|
551
|
+
options: [
|
|
552
|
+
{ label: "Yes (Recommended)", description: "Investigate domain, find patterns, surface gotchas" },
|
|
553
|
+
{ label: "No", description: "Plan directly from requirements" }
|
|
554
|
+
]
|
|
555
|
+
},
|
|
556
|
+
{
|
|
557
|
+
header: "Plan Check",
|
|
558
|
+
question: "Verify plans will achieve their goals? (adds tokens/time)",
|
|
559
|
+
multiSelect: false,
|
|
560
|
+
options: [
|
|
561
|
+
{ label: "Yes (Recommended)", description: "Catch gaps before execution starts" },
|
|
562
|
+
{ label: "No", description: "Execute plans without verification" }
|
|
563
|
+
]
|
|
564
|
+
},
|
|
565
|
+
{
|
|
566
|
+
header: "Verifier",
|
|
567
|
+
question: "Verify work satisfies requirements after each phase? (adds tokens/time)",
|
|
568
|
+
multiSelect: false,
|
|
569
|
+
options: [
|
|
570
|
+
{ label: "Yes (Recommended)", description: "Confirm deliverables match phase goals" },
|
|
571
|
+
{ label: "No", description: "Trust execution, skip verification" }
|
|
572
|
+
]
|
|
573
|
+
},
|
|
574
|
+
{
|
|
575
|
+
header: "AI Models",
|
|
576
|
+
question: "Which AI models for planning agents?",
|
|
577
|
+
multiSelect: false,
|
|
578
|
+
options: [
|
|
579
|
+
{ label: "Balanced (Recommended)", description: "Sonnet for most agents — good quality/cost ratio" },
|
|
580
|
+
{ label: "Quality", description: "Opus for research/roadmap — higher cost, deeper analysis" },
|
|
581
|
+
{ label: "Budget", description: "Haiku where possible — fastest, lowest cost" }
|
|
582
|
+
]
|
|
583
|
+
}
|
|
584
|
+
]
|
|
585
|
+
```
|
|
586
|
+
|
|
587
|
+
Create `.planning/config.json` with all settings:
|
|
588
|
+
|
|
589
|
+
```json
|
|
590
|
+
{
|
|
591
|
+
"mode": "yolo|interactive",
|
|
592
|
+
"granularity": "coarse|standard|fine",
|
|
593
|
+
"parallelization": true|false,
|
|
594
|
+
"commit_docs": true|false,
|
|
595
|
+
"model_profile": "quality|balanced|budget",
|
|
596
|
+
"workflow": {
|
|
597
|
+
"research": true|false,
|
|
598
|
+
"plan_check": true|false,
|
|
599
|
+
"verifier": true|false,
|
|
600
|
+
"nyquist_validation": depth !== "quick"
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
```
|
|
604
|
+
|
|
605
|
+
**If commit_docs = No:**
|
|
606
|
+
- Set `commit_docs: false` in config.json
|
|
607
|
+
- Add `.planning/` to `.gitignore` (create if needed)
|
|
608
|
+
|
|
609
|
+
**If commit_docs = Yes:**
|
|
610
|
+
- No additional gitignore entries needed
|
|
611
|
+
|
|
612
|
+
**Commit config.json:**
|
|
613
|
+
|
|
614
|
+
```bash
|
|
615
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" commit "chore: add project config" --files .planning/config.json
|
|
616
|
+
```
|
|
617
|
+
|
|
618
|
+
**Note:** Run `/ez:settings` anytime to update these preferences.
|
|
619
|
+
|
|
620
|
+
**Update lock file state:**
|
|
621
|
+
```bash
|
|
622
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="config_complete"
|
|
623
|
+
```
|
|
624
|
+
|
|
625
|
+
## 5.5. Resolve Model Profile
|
|
626
|
+
|
|
627
|
+
Use models from init: `researcher_model`, `synthesizer_model`, `roadmapper_model`.
|
|
628
|
+
|
|
629
|
+
---
|
|
630
|
+
|
|
631
|
+
## 6. Research Decision (with Fresh Context - GSD-2 Pattern)
|
|
632
|
+
|
|
633
|
+
**If auto mode:** Default to "Research first" without asking.
|
|
634
|
+
|
|
635
|
+
Use AskUserQuestion:
|
|
636
|
+
- header: "Research"
|
|
637
|
+
- question: "Research the domain ecosystem before defining requirements?"
|
|
638
|
+
- options:
|
|
639
|
+
- "Research first (Recommended)" — Discover standard stack, expected features, architecture patterns
|
|
640
|
+
- "Skip research" — I know this domain well, go straight to requirements
|
|
641
|
+
|
|
642
|
+
**If "Research first":**
|
|
643
|
+
|
|
644
|
+
Display stage banner:
|
|
645
|
+
```
|
|
646
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
647
|
+
EZ ► RESEARCHING
|
|
648
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
649
|
+
|
|
650
|
+
Researching [domain] ecosystem...
|
|
651
|
+
```
|
|
652
|
+
|
|
653
|
+
Create research directory:
|
|
654
|
+
```bash
|
|
655
|
+
mkdir -p .planning/research
|
|
656
|
+
```
|
|
657
|
+
|
|
658
|
+
**Determine milestone context:**
|
|
659
|
+
|
|
660
|
+
Check if this is greenfield or subsequent milestone:
|
|
661
|
+
- If no "Validated" requirements in PROJECT.md → Greenfield (building from scratch)
|
|
662
|
+
- If "Validated" requirements exist → Subsequent milestone (adding to existing app)
|
|
663
|
+
|
|
664
|
+
Display spawning indicator:
|
|
665
|
+
```
|
|
666
|
+
◆ Spawning 4 researchers in parallel...
|
|
667
|
+
→ Stack research
|
|
668
|
+
→ Features research
|
|
669
|
+
→ Architecture research
|
|
670
|
+
→ Pitfalls research
|
|
671
|
+
```
|
|
672
|
+
|
|
673
|
+
**Spawn 4 parallel ez-project-researcher agents with FRESH CONTEXT (GSD-2 Pattern):**
|
|
674
|
+
|
|
675
|
+
Each uses this template with dimension-specific fields:
|
|
676
|
+
|
|
677
|
+
```
|
|
678
|
+
Task(prompt="
|
|
679
|
+
<research_type>Project Research — {DIMENSION} for [domain].</research_type>
|
|
680
|
+
|
|
681
|
+
<fresh_context>
|
|
682
|
+
CONTEXT RESET: This is a fresh 200K session.
|
|
683
|
+
No accumulated garbage from prior tasks.
|
|
684
|
+
Only relevant context pre-loaded below.
|
|
685
|
+
</fresh_context>
|
|
686
|
+
|
|
687
|
+
<pre_loaded_context>
|
|
688
|
+
- .planning/PROJECT.md excerpt (core value, goals)
|
|
689
|
+
- .planning/config.json (workflow settings)
|
|
690
|
+
</pre_loaded_context>
|
|
691
|
+
|
|
692
|
+
<milestone_context>
|
|
693
|
+
{greenfield_or_subsequent}
|
|
694
|
+
|
|
695
|
+
Greenfield: Research the standard stack for building [domain] from scratch.
|
|
696
|
+
Subsequent: Research what's needed to add [target features] to an existing [domain] app. Don't re-research the existing system.
|
|
697
|
+
</milestone_context>
|
|
698
|
+
|
|
699
|
+
<question>
|
|
700
|
+
{QUESTION}
|
|
701
|
+
</question>
|
|
702
|
+
|
|
703
|
+
<files_to_read>
|
|
704
|
+
- {project_path} (Project context and goals)
|
|
705
|
+
</files_to_read>
|
|
706
|
+
|
|
707
|
+
<downstream_consumer>
|
|
708
|
+
{CONSUMER}
|
|
709
|
+
</downstream_consumer>
|
|
710
|
+
|
|
711
|
+
<quality_gate>
|
|
712
|
+
{GATES}
|
|
713
|
+
</quality_gate>
|
|
714
|
+
|
|
715
|
+
<output>
|
|
716
|
+
Write to: .planning/research/{FILE}
|
|
717
|
+
Use template: ~/.claude/ez-agents/templates/research-project/{FILE}
|
|
718
|
+
</output>
|
|
719
|
+
", subagent_type="ez-project-researcher", model="{researcher_model}", description="{DIMENSION} research")
|
|
720
|
+
```
|
|
721
|
+
|
|
722
|
+
**Dimension-specific fields:**
|
|
723
|
+
|
|
724
|
+
| Field | Stack | Features | Architecture | Pitfalls |
|
|
725
|
+
|-------|-------|----------|-------------|----------|
|
|
726
|
+
| QUESTION | What's the standard 2025 stack for [domain]? | What features do [domain] products have? | How are [domain] systems typically structured? | What do [domain] projects commonly get wrong? |
|
|
727
|
+
| CONSUMER | Specific libraries with versions, clear rationale, what NOT to use | Table stakes vs differentiators vs anti-features | Component boundaries, data flow, build order | Warning signs, prevention strategy, phase mapping |
|
|
728
|
+
| GATES | Versions current (verify with Context7), rationale explains WHY | Categories clear, complexity noted, dependencies identified | Components clearly defined, data flow explicit | Pitfalls specific to domain, prevention actionable |
|
|
729
|
+
| FILE | STACK.md | FEATURES.md | ARCHITECTURE.md | PITFALLS.md |
|
|
730
|
+
|
|
731
|
+
After all 4 complete, spawn synthesizer to create SUMMARY.md:
|
|
732
|
+
|
|
733
|
+
```
|
|
734
|
+
Task(prompt="
|
|
735
|
+
Synthesize research outputs into SUMMARY.md.
|
|
736
|
+
|
|
737
|
+
<files_to_read>
|
|
738
|
+
- .planning/research/STACK.md
|
|
739
|
+
- .planning/research/FEATURES.md
|
|
740
|
+
- .planning/research/ARCHITECTURE.md
|
|
741
|
+
- .planning/research/PITFALLS.md
|
|
742
|
+
</files_to_read>
|
|
743
|
+
|
|
744
|
+
Write to: .planning/research/SUMMARY.md
|
|
745
|
+
Use template: ~/.claude/ez-agents/templates/research-project/SUMMARY.md
|
|
746
|
+
Commit after writing.
|
|
747
|
+
", subagent_type="ez-research-synthesizer", model="{synthesizer_model}", description="Synthesize research")
|
|
748
|
+
```
|
|
749
|
+
|
|
750
|
+
Display research complete banner and key findings:
|
|
751
|
+
```
|
|
752
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
753
|
+
EZ ► RESEARCH COMPLETE ✓
|
|
754
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
755
|
+
|
|
756
|
+
## Key Findings
|
|
757
|
+
|
|
758
|
+
**Stack:** [from SUMMARY.md]
|
|
759
|
+
**Table Stakes:** [from SUMMARY.md]
|
|
760
|
+
**Watch Out For:** [from SUMMARY.md]
|
|
761
|
+
|
|
762
|
+
Files: `.planning/research/`
|
|
763
|
+
```
|
|
764
|
+
|
|
765
|
+
**Update lock file state:**
|
|
766
|
+
```bash
|
|
767
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="research_complete"
|
|
768
|
+
```
|
|
769
|
+
|
|
770
|
+
**If "Skip research":** Continue to Step 7.
|
|
771
|
+
|
|
772
|
+
---
|
|
773
|
+
|
|
774
|
+
## 7. Define Requirements
|
|
775
|
+
|
|
776
|
+
Display stage banner:
|
|
777
|
+
```
|
|
778
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
779
|
+
EZ ► DEFINING REQUIREMENTS
|
|
780
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
781
|
+
```
|
|
782
|
+
|
|
783
|
+
**Load context:**
|
|
784
|
+
|
|
785
|
+
Read PROJECT.md and extract:
|
|
786
|
+
- Core value (the ONE thing that must work)
|
|
787
|
+
- Stated constraints (budget, timeline, tech limitations)
|
|
788
|
+
- Any explicit scope boundaries
|
|
789
|
+
|
|
790
|
+
**If research exists:** Read research/FEATURES.md and extract feature categories.
|
|
791
|
+
|
|
792
|
+
**If auto mode:**
|
|
793
|
+
- Auto-include all table stakes features (users expect these)
|
|
794
|
+
- Include features explicitly mentioned in provided document
|
|
795
|
+
- Auto-defer differentiators not mentioned in document
|
|
796
|
+
- Skip per-category AskUserQuestion loops
|
|
797
|
+
- Skip "Any additions?" question
|
|
798
|
+
- Skip requirements approval gate
|
|
799
|
+
- Generate REQUIREMENTS.md and commit directly
|
|
800
|
+
|
|
801
|
+
**Present features by category (interactive mode only):**
|
|
802
|
+
|
|
803
|
+
```
|
|
804
|
+
Here are the features for [domain]:
|
|
805
|
+
|
|
806
|
+
## Authentication
|
|
807
|
+
**Table stakes:**
|
|
808
|
+
- Sign up with email/password
|
|
809
|
+
- Email verification
|
|
810
|
+
- Password reset
|
|
811
|
+
- Session management
|
|
812
|
+
|
|
813
|
+
**Differentiators:**
|
|
814
|
+
- Magic link login
|
|
815
|
+
- OAuth (Google, GitHub)
|
|
816
|
+
- 2FA
|
|
817
|
+
|
|
818
|
+
**Research notes:** [any relevant notes]
|
|
819
|
+
|
|
820
|
+
---
|
|
821
|
+
|
|
822
|
+
## [Next Category]
|
|
823
|
+
...
|
|
824
|
+
```
|
|
825
|
+
|
|
826
|
+
**If no research:** Gather requirements through conversation instead.
|
|
827
|
+
|
|
828
|
+
Ask: "What are the main things users need to be able to do?"
|
|
829
|
+
|
|
830
|
+
For each capability mentioned:
|
|
831
|
+
- Ask clarifying questions to make it specific
|
|
832
|
+
- Probe for related capabilities
|
|
833
|
+
- Group into categories
|
|
834
|
+
|
|
835
|
+
**Scope each category:**
|
|
836
|
+
|
|
837
|
+
For each category, use AskUserQuestion:
|
|
838
|
+
|
|
839
|
+
- header: "[Category]" (max 12 chars)
|
|
840
|
+
- question: "Which [category] features are in v1?"
|
|
841
|
+
- multiSelect: true
|
|
842
|
+
- options:
|
|
843
|
+
- "[Feature 1]" — [brief description]
|
|
844
|
+
- "[Feature 2]" — [brief description]
|
|
845
|
+
- "[Feature 3]" — [brief description]
|
|
846
|
+
- "None for v1" — Defer entire category
|
|
847
|
+
|
|
848
|
+
Track responses:
|
|
849
|
+
- Selected features → v1 requirements
|
|
850
|
+
- Unselected table stakes → v2 (users expect these)
|
|
851
|
+
- Unselected differentiators → out of scope
|
|
852
|
+
|
|
853
|
+
**Identify gaps:**
|
|
854
|
+
|
|
855
|
+
Use AskUserQuestion:
|
|
856
|
+
- header: "Additions"
|
|
857
|
+
- question: "Any requirements research missed? (Features specific to your vision)"
|
|
858
|
+
- options:
|
|
859
|
+
- "No, research covered it" — Proceed
|
|
860
|
+
- "Yes, let me add some" — Capture additions
|
|
861
|
+
|
|
862
|
+
**Validate core value:**
|
|
863
|
+
|
|
864
|
+
Cross-check requirements against Core Value from PROJECT.md. If gaps detected, surface them.
|
|
865
|
+
|
|
866
|
+
**Generate REQUIREMENTS.md:**
|
|
867
|
+
|
|
868
|
+
Create `.planning/REQUIREMENTS.md` with:
|
|
869
|
+
- v1 Requirements grouped by category (checkboxes, REQ-IDs)
|
|
870
|
+
- v2 Requirements (deferred)
|
|
871
|
+
- Out of Scope (explicit exclusions with reasoning)
|
|
872
|
+
- Traceability section (empty, filled by roadmap)
|
|
873
|
+
|
|
874
|
+
**REQ-ID format:** `[CATEGORY]-[NUMBER]` (AUTH-01, CONTENT-02)
|
|
875
|
+
|
|
876
|
+
**Requirement quality criteria:**
|
|
877
|
+
|
|
878
|
+
Good requirements are:
|
|
879
|
+
- **Specific and testable:** "User can reset password via email link" (not "Handle password reset")
|
|
880
|
+
- **User-centric:** "User can X" (not "System does Y")
|
|
881
|
+
- **Atomic:** One capability per requirement (not "User can login and manage profile")
|
|
882
|
+
- **Independent:** Minimal dependencies on other requirements
|
|
883
|
+
|
|
884
|
+
Reject vague requirements. Push for specificity.
|
|
885
|
+
|
|
886
|
+
Present FULL requirements list for confirmation:
|
|
887
|
+
|
|
888
|
+
```
|
|
889
|
+
## Project Requirements
|
|
890
|
+
|
|
891
|
+
### [Category 1]
|
|
892
|
+
- [ ] **CAT1-01**: User can do X
|
|
893
|
+
- [ ] **CAT1-02**: User can do Y
|
|
894
|
+
|
|
895
|
+
### [Category 2]
|
|
896
|
+
- [ ] **CAT2-01**: User can do Z
|
|
897
|
+
|
|
898
|
+
Does this capture what you're building? (yes / adjust)
|
|
899
|
+
```
|
|
900
|
+
|
|
901
|
+
If "adjust": Return to scoping.
|
|
902
|
+
|
|
903
|
+
**Commit requirements:**
|
|
904
|
+
```bash
|
|
905
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" commit "docs: define project requirements" --files .planning/REQUIREMENTS.md
|
|
906
|
+
```
|
|
907
|
+
|
|
908
|
+
**Update lock file state:**
|
|
909
|
+
```bash
|
|
910
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="requirements_defined"
|
|
911
|
+
```
|
|
912
|
+
|
|
913
|
+
---
|
|
914
|
+
|
|
915
|
+
## 8. Create Roadmap (with Stuck Detection - GSD-2 Pattern)
|
|
916
|
+
|
|
917
|
+
Display stage banner:
|
|
918
|
+
```
|
|
919
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
920
|
+
EZ ► CREATING ROADMAP
|
|
921
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
922
|
+
|
|
923
|
+
◆ Spawning roadmapper...
|
|
924
|
+
```
|
|
925
|
+
|
|
926
|
+
**Initialize stuck detection:**
|
|
927
|
+
|
|
928
|
+
```bash
|
|
929
|
+
# Start stuck watcher
|
|
930
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" stuck-watch start \
|
|
931
|
+
--operation="roadmap-creation" \
|
|
932
|
+
--max-retries=1 \
|
|
933
|
+
--timeout=300
|
|
934
|
+
```
|
|
935
|
+
|
|
936
|
+
```
|
|
937
|
+
Task(prompt="
|
|
938
|
+
<planning_context>
|
|
939
|
+
<files_to_read>
|
|
940
|
+
- .planning/PROJECT.md
|
|
941
|
+
- .planning/REQUIREMENTS.md
|
|
942
|
+
- .planning/research/SUMMARY.md (if exists)
|
|
943
|
+
- .planning/config.json
|
|
944
|
+
</files_to_read>
|
|
945
|
+
</planning_context>
|
|
946
|
+
|
|
947
|
+
<instructions>
|
|
948
|
+
Create roadmap for new project:
|
|
949
|
+
1. Start phase numbering from 1
|
|
950
|
+
2. Derive phases from requirements
|
|
951
|
+
3. Map every requirement to exactly one phase
|
|
952
|
+
4. Derive 2-5 success criteria per phase (observable user behaviors)
|
|
953
|
+
5. Validate 100% coverage
|
|
954
|
+
6. Write files immediately (ROADMAP.md, STATE.md, update REQUIREMENTS.md traceability)
|
|
955
|
+
7. Return ROADMAP CREATED with summary
|
|
956
|
+
|
|
957
|
+
Write files first, then return.
|
|
958
|
+
</instructions>
|
|
959
|
+
", subagent_type="ez-roadmapper", model="{roadmapper_model}", description="Create roadmap")
|
|
960
|
+
```
|
|
961
|
+
|
|
962
|
+
**Handle return:**
|
|
963
|
+
|
|
964
|
+
**If `## ROADMAP BLOCKED`:**
|
|
965
|
+
1. Log error type and location
|
|
966
|
+
2. Retry ONCE with diagnostic context:
|
|
967
|
+
```
|
|
968
|
+
Task(prompt="
|
|
969
|
+
<retry_context>
|
|
970
|
+
PREVIOUS ATTEMPT FAILED
|
|
971
|
+
Error Type: [error_type]
|
|
972
|
+
Error Location: [location]
|
|
973
|
+
Suggested Fix: [fix]
|
|
974
|
+
|
|
975
|
+
CONTEXT SNAPSHOT FOR DEBUGGING:
|
|
976
|
+
[snapshot of files read]
|
|
977
|
+
|
|
978
|
+
Please try again with this diagnostic information.
|
|
979
|
+
</retry_context>
|
|
980
|
+
", subagent_type="ez-roadmapper", model="{roadmapper_model}", description="Create roadmap (retry)")
|
|
981
|
+
```
|
|
982
|
+
3. If fails again → STOP with exact failure report:
|
|
983
|
+
```
|
|
984
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
985
|
+
EZ ► ROADMAP CREATION FAILED
|
|
986
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
987
|
+
|
|
988
|
+
Error Type: [type]
|
|
989
|
+
Error Location: [file:line]
|
|
990
|
+
Suggested Fix: [action]
|
|
991
|
+
|
|
992
|
+
Context Snapshot: .planning/logs/stuck-snapshot-[timestamp].json
|
|
993
|
+
|
|
994
|
+
Next Steps:
|
|
995
|
+
1. Review context snapshot
|
|
996
|
+
2. Fix [specific issue]
|
|
997
|
+
3. Run: /ez:new-project --retry
|
|
998
|
+
```
|
|
999
|
+
|
|
1000
|
+
**If `## ROADMAP CREATED`:** Read ROADMAP.md, present inline:
|
|
1001
|
+
|
|
1002
|
+
```
|
|
1003
|
+
## Proposed Roadmap
|
|
1004
|
+
|
|
1005
|
+
**[N] phases** | **[X] requirements mapped** | All covered ✓
|
|
1006
|
+
|
|
1007
|
+
| # | Phase | Goal | Requirements | Success Criteria |
|
|
1008
|
+
|---|-------|------|--------------|------------------|
|
|
1009
|
+
| 1 | [Name] | [Goal] | [REQ-IDs] | [count] |
|
|
1010
|
+
|
|
1011
|
+
### Phase Details
|
|
1012
|
+
|
|
1013
|
+
**Phase 1: [Name]**
|
|
1014
|
+
Goal: [goal]
|
|
1015
|
+
Requirements: [REQ-IDs]
|
|
1016
|
+
Success criteria:
|
|
1017
|
+
1. [criterion]
|
|
1018
|
+
2. [criterion]
|
|
1019
|
+
```
|
|
1020
|
+
|
|
1021
|
+
**Ask for approval** via AskUserQuestion:
|
|
1022
|
+
- "Approve" — Commit and continue
|
|
1023
|
+
- "Adjust phases" — Tell me what to change
|
|
1024
|
+
- "Review full file" — Show raw ROADMAP.md
|
|
1025
|
+
|
|
1026
|
+
**If "Adjust":** Get notes, re-spawn roadmapper with revision context, loop until approved.
|
|
1027
|
+
**If "Review":** Display raw ROADMAP.md, re-ask.
|
|
1028
|
+
|
|
1029
|
+
**Commit roadmap** (after approval):
|
|
1030
|
+
```bash
|
|
1031
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" commit "docs: create project roadmap ([N] phases)" --files .planning/ROADMAP.md .planning/STATE.md .planning/REQUIREMENTS.md
|
|
1032
|
+
```
|
|
1033
|
+
|
|
1034
|
+
**Update lock file state:**
|
|
1035
|
+
```bash
|
|
1036
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-update --state="roadmap_created"
|
|
1037
|
+
```
|
|
1038
|
+
|
|
1039
|
+
---
|
|
1040
|
+
|
|
1041
|
+
## 9. Release Lock File
|
|
1042
|
+
|
|
1043
|
+
**Project initialization complete:**
|
|
1044
|
+
|
|
1045
|
+
```bash
|
|
1046
|
+
node "$HOME/.claude/ez-agents/bin/ez-tools.cjs" lock-release
|
|
1047
|
+
```
|
|
1048
|
+
|
|
1049
|
+
---
|
|
1050
|
+
|
|
1051
|
+
## 10. Done
|
|
1052
|
+
|
|
1053
|
+
```
|
|
1054
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1055
|
+
EZ ► PROJECT INITIALIZED ✓
|
|
1056
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
1057
|
+
|
|
1058
|
+
**Project: [Project Name]**
|
|
1059
|
+
|
|
1060
|
+
| Artifact | Location |
|
|
1061
|
+
|----------------|-----------------------------|
|
|
1062
|
+
| Project | `.planning/PROJECT.md` |
|
|
1063
|
+
| Research | `.planning/research/` |
|
|
1064
|
+
| Requirements | `.planning/REQUIREMENTS.md` |
|
|
1065
|
+
| Roadmap | `.planning/ROADMAP.md` |
|
|
1066
|
+
| Config | `.planning/config.json` |
|
|
1067
|
+
|
|
1068
|
+
**[N] phases** | **[X] requirements** | Ready to build ✓
|
|
1069
|
+
|
|
1070
|
+
## ▶ Next Up
|
|
1071
|
+
|
|
1072
|
+
**Phase 1: [Phase Name]** — [Goal]
|
|
1073
|
+
|
|
1074
|
+
`/ez:discuss-phase 1` — gather context and clarify approach
|
|
1075
|
+
|
|
1076
|
+
<sub>`/clear` first → fresh context window</sub>
|
|
1077
|
+
|
|
1078
|
+
Also: `/ez:plan-phase 1` — skip discussion, plan directly
|
|
1079
|
+
```
|
|
1080
|
+
|
|
1081
|
+
</process>
|
|
1082
|
+
|
|
1083
|
+
<success_criteria>
|
|
1084
|
+
- [ ] Pre-flight health check passed (all systems go)
|
|
1085
|
+
- [ ] Lock file created and maintained throughout
|
|
1086
|
+
- [ ] PROJECT.md created with clear core value
|
|
1087
|
+
- [ ] REQUIREMENTS.md created with REQ-IDs
|
|
1088
|
+
- [ ] ROADMAP.md created with phased execution plan
|
|
1089
|
+
- [ ] STATE.md initialized
|
|
1090
|
+
- [ ] Config.json created with workflow preferences
|
|
1091
|
+
- [ ] Research completed (if selected) — 4 parallel agents with fresh context
|
|
1092
|
+
- [ ] Requirements gathered and scoped per category
|
|
1093
|
+
- [ ] ez-roadmapper spawned with stuck detection
|
|
1094
|
+
- [ ] Roadmap files written immediately (not draft)
|
|
1095
|
+
- [ ] User feedback incorporated (if any)
|
|
1096
|
+
- [ ] All commits made (if planning docs committed)
|
|
1097
|
+
- [ ] Lock file released on completion
|
|
1098
|
+
- [ ] User knows next step: `/ez:discuss-phase 1`
|
|
1099
|
+
|
|
1100
|
+
**Atomic commits:** Each artifact committed immediately after creation.
|
|
1101
|
+
|
|
1102
|
+
**GSD-2 Reliability:**
|
|
1103
|
+
- ✅ Health check pre-flight validation
|
|
1104
|
+
- ✅ Crash recovery via lock files
|
|
1105
|
+
- ✅ Fresh context per researcher/agent
|
|
1106
|
+
- ✅ Stuck detection with diagnostics during roadmap creation
|
|
1107
|
+
</success_criteria>
|