agileflow 2.94.1 → 2.95.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 (74) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/README.md +3 -3
  3. package/lib/colors.generated.js +117 -0
  4. package/lib/colors.js +59 -109
  5. package/lib/generator-factory.js +333 -0
  6. package/lib/path-utils.js +49 -0
  7. package/lib/session-registry.js +25 -15
  8. package/lib/smart-json-file.js +40 -32
  9. package/lib/state-machine.js +286 -0
  10. package/package.json +1 -1
  11. package/scripts/agileflow-configure.js +7 -6
  12. package/scripts/archive-completed-stories.sh +86 -11
  13. package/scripts/babysit-context-restore.js +89 -0
  14. package/scripts/claude-tmux.sh +111 -5
  15. package/scripts/damage-control/bash-tool-damage-control.js +11 -247
  16. package/scripts/damage-control/edit-tool-damage-control.js +9 -249
  17. package/scripts/damage-control/write-tool-damage-control.js +9 -244
  18. package/scripts/generate-colors.js +314 -0
  19. package/scripts/lib/colors.generated.sh +82 -0
  20. package/scripts/lib/colors.sh +10 -70
  21. package/scripts/lib/configure-features.js +401 -0
  22. package/scripts/lib/context-loader.js +181 -52
  23. package/scripts/precompact-context.sh +54 -17
  24. package/scripts/session-coordinator.sh +2 -2
  25. package/scripts/session-manager.js +653 -10
  26. package/src/core/commands/audit.md +93 -0
  27. package/src/core/commands/auto.md +73 -0
  28. package/src/core/commands/babysit.md +169 -13
  29. package/src/core/commands/baseline.md +73 -0
  30. package/src/core/commands/batch.md +64 -0
  31. package/src/core/commands/blockers.md +60 -0
  32. package/src/core/commands/board.md +66 -0
  33. package/src/core/commands/choose.md +77 -0
  34. package/src/core/commands/ci.md +77 -0
  35. package/src/core/commands/compress.md +27 -1
  36. package/src/core/commands/configure.md +126 -10
  37. package/src/core/commands/council.md +74 -0
  38. package/src/core/commands/debt.md +72 -0
  39. package/src/core/commands/deploy.md +73 -0
  40. package/src/core/commands/deps.md +68 -0
  41. package/src/core/commands/docs.md +60 -0
  42. package/src/core/commands/feedback.md +68 -0
  43. package/src/core/commands/ideate.md +74 -0
  44. package/src/core/commands/impact.md +74 -0
  45. package/src/core/commands/install.md +529 -0
  46. package/src/core/commands/maintain.md +558 -0
  47. package/src/core/commands/metrics.md +75 -0
  48. package/src/core/commands/multi-expert.md +74 -0
  49. package/src/core/commands/packages.md +69 -0
  50. package/src/core/commands/readme-sync.md +64 -0
  51. package/src/core/commands/research/analyze.md +285 -121
  52. package/src/core/commands/research/import.md +281 -109
  53. package/src/core/commands/retro.md +76 -0
  54. package/src/core/commands/review.md +72 -0
  55. package/src/core/commands/rlm.md +83 -0
  56. package/src/core/commands/rpi.md +90 -0
  57. package/src/core/commands/session/cleanup.md +214 -12
  58. package/src/core/commands/session/end.md +155 -17
  59. package/src/core/commands/sprint.md +72 -0
  60. package/src/core/commands/story-validate.md +68 -0
  61. package/src/core/commands/template.md +69 -0
  62. package/src/core/commands/tests.md +83 -0
  63. package/src/core/commands/update.md +59 -0
  64. package/src/core/commands/validate-expertise.md +76 -0
  65. package/src/core/commands/velocity.md +74 -0
  66. package/src/core/commands/verify.md +91 -0
  67. package/src/core/commands/whats-new.md +69 -0
  68. package/src/core/commands/workflow.md +88 -0
  69. package/src/core/templates/command-documentation.md +187 -0
  70. package/tools/cli/commands/session.js +1171 -0
  71. package/tools/cli/commands/setup.js +2 -81
  72. package/tools/cli/installers/core/installer.js +0 -5
  73. package/tools/cli/installers/ide/claude-code.js +6 -0
  74. package/tools/cli/lib/config-manager.js +42 -5
@@ -7,7 +7,8 @@ compact_context:
7
7
  - "ACTIVE COMMAND: /agileflow:session:end - Terminate current session"
8
8
  - "For NON-MAIN sessions: 4 options (merge/end/delete/cancel)"
9
9
  - "For MAIN sessions: 2 options (end/cancel)"
10
- - "Merge flow: check uncommitted preview check conflicts → strategy → confirm → execute"
10
+ - "Uncommitted changes: INLINE options (commit/commit-custom/stash/discard/cancel) - NOT blocking!"
11
+ - "Merge flow: check uncommitted → handle inline → preview → conflicts → strategy → confirm → execute → unstash if stashed"
11
12
  - "Main session can only be marked inactive, not deleted or merged"
12
13
  - "Use AskUserQuestion for all user choices"
13
14
  state_fields:
@@ -15,6 +16,7 @@ compact_context:
15
16
  - is_main_session
16
17
  - user_choice
17
18
  - merge_strategy
19
+ - stash_used
18
20
  ---
19
21
 
20
22
  # /agileflow:session:end
@@ -178,17 +180,123 @@ node .agileflow/scripts/session-manager.js check-merge {session_id}
178
180
 
179
181
  If response contains `reason: "uncommitted_changes"`:
180
182
 
183
+ **Display change summary:**
181
184
  ```
182
185
  ⚠️ You have uncommitted changes in this session.
183
186
 
184
- Please commit your changes before merging:
185
- git add .
186
- git commit -m "your message"
187
+ {details_from_response}
187
188
 
188
- Or discard changes:
189
- git checkout -- .
189
+ ```
190
+
191
+ **Present inline options with AskUserQuestion:**
190
192
 
191
- Then run /agileflow:session:end again.
193
+ ```
194
+ AskUserQuestion:
195
+ question: "How would you like to handle these uncommitted changes?"
196
+ header: "Uncommitted changes"
197
+ multiSelect: false
198
+ options:
199
+ - label: "Commit all changes (Recommended)"
200
+ description: "Create a commit with auto-generated message"
201
+ - label: "Commit with custom message"
202
+ description: "Enter your own commit message"
203
+ - label: "Stash changes temporarily"
204
+ description: "Stash, merge, then restore after merge"
205
+ - label: "Discard all changes"
206
+ description: "Discard local changes and continue with merge"
207
+ - label: "Cancel"
208
+ description: "Keep session active with uncommitted changes"
209
+ ```
210
+
211
+ #### If "Commit all changes" selected:
212
+
213
+ ```bash
214
+ node .agileflow/scripts/session-manager.js commit-changes {session_id}
215
+ ```
216
+
217
+ Display:
218
+ ```
219
+ ✓ Changes committed: {commitHash}
220
+ Message: {message}
221
+ ```
222
+
223
+ Continue to **Merge Step 2**.
224
+
225
+ #### If "Commit with custom message" selected:
226
+
227
+ First, ask for the commit message:
228
+ ```
229
+ AskUserQuestion:
230
+ question: "Enter your commit message:"
231
+ header: "Commit message"
232
+ multiSelect: false
233
+ options:
234
+ - label: "feat: ..."
235
+ description: "New feature"
236
+ - label: "fix: ..."
237
+ description: "Bug fix"
238
+ - label: "chore: ..."
239
+ description: "Maintenance/cleanup"
240
+ ```
241
+
242
+ The user will select "Other" to enter a custom message. Then:
243
+
244
+ ```bash
245
+ node .agileflow/scripts/session-manager.js commit-changes {session_id} --message="{user_message}"
246
+ ```
247
+
248
+ Display:
249
+ ```
250
+ ✓ Changes committed: {commitHash}
251
+ Message: {message}
252
+ ```
253
+
254
+ Continue to **Merge Step 2**.
255
+
256
+ #### If "Stash changes temporarily" selected:
257
+
258
+ ```bash
259
+ node .agileflow/scripts/session-manager.js stash {session_id}
260
+ ```
261
+
262
+ Display:
263
+ ```
264
+ ✓ Changes stashed: {message}
265
+
266
+ Note: After merge completes, stash will be restored on main branch.
267
+ ```
268
+
269
+ Continue to **Merge Step 2**.
270
+
271
+ **IMPORTANT**: After the merge completes successfully (at the end of Merge Step 7), run:
272
+ ```bash
273
+ node .agileflow/scripts/session-manager.js unstash {session_id}
274
+ ```
275
+
276
+ Display:
277
+ ```
278
+ ✓ Stashed changes restored to main branch.
279
+ ```
280
+
281
+ #### If "Discard all changes" selected:
282
+
283
+ ```bash
284
+ node .agileflow/scripts/session-manager.js discard-changes {session_id}
285
+ ```
286
+
287
+ Display:
288
+ ```
289
+ ✓ All uncommitted changes discarded.
290
+
291
+ ⚠️ Note: Untracked files were NOT deleted.
292
+ ```
293
+
294
+ Continue to **Merge Step 2**.
295
+
296
+ #### If "Cancel" selected:
297
+
298
+ ```
299
+ Session remains active with uncommitted changes.
192
300
  ```
193
301
 
194
302
  **Exit the flow here.** Do not continue to merge.
@@ -485,7 +593,30 @@ node .agileflow/scripts/session-manager.js status
485
593
  ```bash
486
594
  node .agileflow/scripts/session-manager.js check-merge {session_id}
487
595
  ```
488
- If `reason: "uncommitted_changes"` → Show commit instructions EXIT
596
+ If `reason: "uncommitted_changes"` → Show inline options (5 choices):
597
+ ```xml
598
+ <invoke name="AskUserQuestion">
599
+ <parameter name="questions">[{
600
+ "question": "How would you like to handle these uncommitted changes?",
601
+ "header": "Uncommitted changes",
602
+ "multiSelect": false,
603
+ "options": [
604
+ {"label": "Commit all changes (Recommended)", "description": "Create a commit with auto-generated message"},
605
+ {"label": "Commit with custom message", "description": "Enter your own commit message"},
606
+ {"label": "Stash changes temporarily", "description": "Stash, merge, then restore after merge"},
607
+ {"label": "Discard all changes", "description": "Discard local changes and continue"},
608
+ {"label": "Cancel", "description": "Keep session active with uncommitted changes"}
609
+ ]
610
+ }]</parameter>
611
+ </invoke>
612
+ ```
613
+
614
+ **Step 1a: Handle uncommitted choice**
615
+ - "Commit all": `node .agileflow/scripts/session-manager.js commit-changes {id}` → continue
616
+ - "Commit custom": Ask for message → `commit-changes {id} --message="..."` → continue
617
+ - "Stash": `node .agileflow/scripts/session-manager.js stash {id}` → continue (unstash after merge)
618
+ - "Discard": `node .agileflow/scripts/session-manager.js discard-changes {id}` → continue
619
+ - "Cancel": EXIT
489
620
 
490
621
  **Step 2: Get preview**
491
622
  ```bash
@@ -621,13 +752,15 @@ tmux kill-window
621
752
  2. Check is_main
622
753
  3. Show options (4 for non-main, 2 for main)
623
754
  4. If merge selected:
624
- a. Check uncommitted → block if dirty
625
- b. Preview commits/files
626
- c. Check conflicts → offer alternatives if conflicts
627
- d. Choose strategy (squash/merge)
628
- e. Confirm cleanup
629
- f. Execute integrate
630
- g. Show success with cd command
755
+ a. Check uncommitted → show inline options (commit/stash/discard/cancel)
756
+ b. Handle uncommitted (commit-changes, stash, or discard-changes)
757
+ c. Preview commits/files
758
+ d. Check conflicts → offer alternatives if conflicts
759
+ e. Choose strategy (squash/merge)
760
+ f. Confirm cleanup
761
+ g. Execute integrate
762
+ h. If stash was used → unstash on main
763
+ i. Show success with cd command
631
764
  5. If end/delete → Execute and show result
632
765
  6. If in tmux → Offer to close tab
633
766
  ```
@@ -638,18 +771,22 @@ tmux kill-window
638
771
 
639
772
  ❌ Show merge option for main session
640
773
  ❌ Skip uncommitted check before merge
774
+ ❌ Block and exit on uncommitted changes (use inline options instead!)
641
775
  ❌ Merge without showing preview
642
776
  ❌ Merge when conflicts exist without warning
643
777
  ❌ Delete worktree before merge completes
778
+ ❌ Forget to unstash after merge if stash was used
644
779
 
645
780
  ### DO THESE
646
781
 
647
782
  ✅ Always check is_main first
648
- ✅ Check uncommitted changes before anything
783
+ ✅ Check uncommitted changes and offer inline options
784
+ ✅ Handle uncommitted with commit-changes, stash, or discard-changes
649
785
  ✅ Show preview before merge
650
786
  ✅ Handle conflicts gracefully
651
787
  ✅ Squash as default strategy
652
788
  ✅ Show cd command after successful merge
789
+ ✅ If stash was used, unstash after merge completes
653
790
 
654
791
  ---
655
792
 
@@ -658,7 +795,8 @@ tmux kill-window
658
795
  - `/agileflow:session:end` IS ACTIVE
659
796
  - Non-main: 4 options (merge first!)
660
797
  - Main: 2 options only
661
- - Merge flow: uncommitted preview conflicts → strategy → confirm → execute
798
+ - Uncommitted changes: inline options (commit/stash/discard/cancel) - NOT blocking!
799
+ - Merge flow: uncommitted → handle → preview → conflicts → strategy → confirm → execute → unstash if needed
662
800
  - Default strategy: squash
663
801
  - Always show cd command to return to main
664
802
  - **After session ends: Offer to close tmux tab (if in tmux)**
@@ -630,6 +630,78 @@ After displaying plan, ask:
630
630
 
631
631
  ---
632
632
 
633
+ ## Expected Output
634
+
635
+ ### Success - Sprint Planning
636
+
637
+ ```
638
+ 📅 Sprint Planning: Sprint 13
639
+ ══════════════════════════════════════════════════════════════
640
+
641
+ 📊 Capacity Analysis
642
+ ┌────────────────────────────────────────────────────────────┐
643
+ │ Team Velocity (avg last 3 sprints): 38 points │
644
+ │ Available capacity: 36 points (1 dev on PTO) │
645
+ │ Recommended commitment: 32-36 points │
646
+ └────────────────────────────────────────────────────────────┘
647
+
648
+ 📋 Suggested Sprint Backlog
649
+ ┌────────────────────────────────────────────────────────────┐
650
+ │ MUST HAVE (P0-P1) - 24 points │
651
+ ├────────────────────────────────────────────────────────────┤
652
+ │ US-0060: OAuth completion (8 pts) - AG-API │
653
+ │ US-0061: Rate limiting (5 pts) - AG-CI │
654
+ │ US-0062: Session security fix (3 pts) - AG-SECURITY │
655
+ │ US-0063: Dashboard updates (8 pts) - AG-UI │
656
+ ├────────────────────────────────────────────────────────────┤
657
+ │ SHOULD HAVE (P2) - 12 points │
658
+ ├────────────────────────────────────────────────────────────┤
659
+ │ US-0064: Email notifications (5 pts) - AG-API │
660
+ │ US-0065: Metrics dashboard (4 pts) - AG-UI │
661
+ │ US-0066: Documentation update (3 pts) - AG-DOCS │
662
+ └────────────────────────────────────────────────────────────┘
663
+
664
+ ⚠️ Dependency Alert:
665
+ US-0060 must complete before US-0064 can start
666
+
667
+ Total: 36 points | Risk: Low
668
+
669
+ Commit this sprint plan? [Y/n]
670
+ ```
671
+
672
+ ### Success - Sprint Started
673
+
674
+ ```
675
+ 📅 Sprint 13 Started
676
+ ══════════════════════════════════════════════════════════════
677
+
678
+ Duration: 2026-01-29 to 2026-02-12 (14 days)
679
+ Commitment: 7 stories (36 points)
680
+ Goal: Complete OAuth and security hardening
681
+
682
+ ✓ Status.json updated
683
+ ✓ Sprint created in milestones.md
684
+ ✓ Stories moved to 'in_progress' column
685
+
686
+ Next: /agileflow:board to see sprint view
687
+ ```
688
+
689
+ ### Error - Active Sprint Exists
690
+
691
+ ```
692
+ ❌ Error: Sprint 12 is still active
693
+
694
+ Stories remaining: 2 (4 points)
695
+ Days remaining: 1
696
+
697
+ Options:
698
+ 1. Complete current sprint: /agileflow:sprint ACTION=end
699
+ 2. Carry over stories: /agileflow:sprint ACTION=carryover
700
+ 3. Force new sprint: /agileflow:sprint ACTION=start FORCE=true
701
+ ```
702
+
703
+ ---
704
+
633
705
  ## Related Commands
634
706
 
635
707
  - `/agileflow:board` - Visual kanban board
@@ -413,6 +413,74 @@ After validation completes, offer context-aware next steps:
413
413
 
414
414
  ---
415
415
 
416
+ ## Expected Output
417
+
418
+ ### Success - Story Valid
419
+
420
+ ```
421
+ ✅ Story Validation: US-0050
422
+ ══════════════════════════════════════════════════════════════
423
+
424
+ Checking story completeness...
425
+
426
+ ✓ Title: Clear and descriptive
427
+ ✓ Description: Contains user value
428
+ ✓ Acceptance Criteria: 5 criteria in Given/When/Then format
429
+ ✓ Estimate: 1.5d (within range)
430
+ ✓ Owner: AG-API (valid agent)
431
+ ✓ Dependencies: None or all exist
432
+ ✓ Epic: EP-0010 (linked)
433
+
434
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
435
+ ✅ Story is ready for development
436
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
437
+
438
+ INVEST Score: 9/10
439
+ - Independent: ✓
440
+ - Negotiable: ✓
441
+ - Valuable: ✓
442
+ - Estimable: ✓
443
+ - Small: ✓
444
+ - Testable: ✓
445
+ ```
446
+
447
+ ### Partial Success - Issues Found
448
+
449
+ ```
450
+ ⚠️ Story Validation: US-0051
451
+ ══════════════════════════════════════════════════════════════
452
+
453
+ Issues found (2):
454
+
455
+ 🔴 CRITICAL:
456
+ 1. Acceptance criteria missing Given/When/Then format
457
+ Found: "Login should work"
458
+ Expected: "Given a registered user, When they submit valid credentials, Then they receive a JWT token"
459
+
460
+ 🟡 WARNING:
461
+ 2. Estimate missing
462
+ Add estimate: 0.5d, 1d, 1.5d, or 2d
463
+
464
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
465
+ ⚠️ Story needs fixes before development
466
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
467
+
468
+ Fix issues now? [Y/n]
469
+ ```
470
+
471
+ ### Error - Story Not Found
472
+
473
+ ```
474
+ ❌ Error: Story not found: US-9999
475
+
476
+ Check story ID and try again.
477
+
478
+ List available stories:
479
+ /agileflow:story:list STATUS=ready
480
+ ```
481
+
482
+ ---
483
+
416
484
  ## Related Commands
417
485
 
418
486
  - `/agileflow:story:view` - View story details with contextual actions
@@ -566,6 +566,75 @@ OUTPUT
566
566
 
567
567
  ---
568
568
 
569
+ ## Expected Output
570
+
571
+ ### Success - List Templates
572
+
573
+ ```
574
+ 📋 Available Templates
575
+ ══════════════════════════════════════════════════════════════
576
+
577
+ Built-in Templates (docs/00-meta/templates/):
578
+ • story-template.md User stories with AC
579
+ • epic-template.md Epics with milestones
580
+ • adr-template.md Architecture Decision Records
581
+ • agent-profile-template.md Agent profiles
582
+ • research-template.md Research notes
583
+
584
+ Custom Templates (docs/00-meta/templates/custom/):
585
+ • meeting-notes.md (created 2025-10-15)
586
+ • incident-report.md (created 2025-10-10)
587
+ • sprint-retro.md (created 2025-10-01)
588
+
589
+ Usage: /agileflow:template ACTION=use TYPE=custom NAME=meeting-notes
590
+ ```
591
+
592
+ ### Success - Create Template
593
+
594
+ ```
595
+ 📝 Creating Template: sprint-retro
596
+ ══════════════════════════════════════════════════════════════
597
+
598
+ Template type: Sprint Retrospective
599
+ Variables detected: {{SPRINT_NUMBER}}, {{START_DATE}}, {{END_DATE}}, {{TEAM}}
600
+
601
+ Preview:
602
+ ─────────────────────────────────────────
603
+ # Sprint {{SPRINT_NUMBER}} Retrospective
604
+
605
+ **Dates**: {{START_DATE}} to {{END_DATE}}
606
+ **Team**: {{TEAM}}
607
+
608
+ ## What Went Well?
609
+ 1.
610
+
611
+ ## What Didn't Go Well?
612
+ 1.
613
+
614
+ ## Action Items
615
+ - [ ] {{ACTION_1}}
616
+ ─────────────────────────────────────────
617
+
618
+ Save to: docs/00-meta/templates/custom/sprint-retro.md
619
+ Proceed? (YES/NO)
620
+ ```
621
+
622
+ ### Error - Template Not Found
623
+
624
+ ```
625
+ ❌ Template not found: my-template
626
+
627
+ Available templates:
628
+ • story-template
629
+ • epic-template
630
+ • adr-template
631
+ • meeting-notes (custom)
632
+
633
+ Create new: /agileflow:template ACTION=create NAME=my-template
634
+ ```
635
+
636
+ ---
637
+
569
638
  ## Related Commands
570
639
 
571
640
  - `/agileflow:configure` - Manage AgileFlow features and hooks
@@ -638,6 +638,89 @@ OUTPUT
638
638
 
639
639
  ---
640
640
 
641
+ ## Expected Output
642
+
643
+ ### Success - Test Setup Complete
644
+
645
+ ```
646
+ 🧪 Test Infrastructure Setup
647
+ ══════════════════════════════════════════════════════════════
648
+
649
+ Detected: Node.js (TypeScript)
650
+ Framework: Jest
651
+
652
+ ✅ Installed dependencies:
653
+ • jest @types/jest ts-jest
654
+ • @testing-library/react @testing-library/jest-dom
655
+
656
+ ✅ Created configuration:
657
+ • jest.config.js (coverage threshold: 70%)
658
+
659
+ ✅ Created example tests:
660
+ • tests/unit/example.test.ts (2 tests)
661
+ • tests/integration/api.test.ts (2 tests)
662
+
663
+ ✅ Updated package.json scripts:
664
+ • test, test:watch, test:coverage, test:unit, test:integration
665
+
666
+ ✅ Updated CI workflow:
667
+ • .github/workflows/ci.yml (test job added)
668
+
669
+ ✅ Created documentation:
670
+ • docs/02-practices/testing.md
671
+
672
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
673
+ Running verification...
674
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
675
+
676
+ $ npm test
677
+ PASS tests/unit/example.test.ts (4 tests)
678
+ PASS tests/integration/api.test.ts (2 tests)
679
+
680
+ Tests: 6 passed, 6 total
681
+ Time: 2.3s
682
+
683
+ ✅ Test infrastructure ready!
684
+
685
+ Try running: npm test
686
+ ```
687
+
688
+ ### Error - Tests Already Exist
689
+
690
+ ```
691
+ ⚠️ Existing Test Setup Detected
692
+ ══════════════════════════════════════════════════════════════
693
+
694
+ Found:
695
+ • jest.config.js (existing configuration)
696
+ • tests/ directory (14 test files)
697
+ • package.json test script
698
+
699
+ Current coverage: 72%
700
+
701
+ Options:
702
+ 1. Skip setup (tests already configured)
703
+ 2. Add missing components only
704
+ 3. Reset and reconfigure
705
+
706
+ What would you like to do?
707
+ ```
708
+
709
+ ### Error - Unknown Project Type
710
+
711
+ ```
712
+ ❌ Could not detect project type
713
+
714
+ No package.json, requirements.txt, Gemfile, or go.mod found.
715
+
716
+ Please specify framework manually:
717
+ /agileflow:tests FRAMEWORK=jest
718
+ /agileflow:tests FRAMEWORK=pytest
719
+ /agileflow:tests FRAMEWORK=rspec
720
+ ```
721
+
722
+ ---
723
+
641
724
  ## Related Commands
642
725
 
643
726
  - `/agileflow:configure` - Manage AgileFlow features and hooks
@@ -523,6 +523,65 @@ OUTPUT
523
523
 
524
524
  ---
525
525
 
526
+ ## Expected Output
527
+
528
+ ### Success - Update Generated
529
+
530
+ ```
531
+ 📊 Stakeholder Update Generated
532
+ ══════════════════════════════════════════════════════════════
533
+
534
+ Period: Oct 9-16, 2025 (Week)
535
+ Audience: Executive
536
+ Format: Markdown
537
+
538
+ Data collected from:
539
+ ✓ status.json (45 stories)
540
+ ✓ 3 epics
541
+ ✓ Git history (28 commits)
542
+ ✓ Bus log (142 events)
543
+ ✓ 2 ADRs
544
+
545
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
546
+ Preview
547
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
548
+
549
+ ## Executive Summary
550
+ **Status**: 🟢 On Track
551
+
552
+ We completed the user authentication epic this week,
553
+ delivering all planned features on schedule.
554
+
555
+ **Key Highlights**:
556
+ - ✅ 12 stories completed (velocity: 18 points)
557
+ - 🎯 Payment integration on track for end-of-month
558
+
559
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
560
+
561
+ Save to: docs/08-project/updates/20251016-update.md
562
+
563
+ Send update? (YES/NO/EDIT)
564
+ ```
565
+
566
+ ### Error - No Data for Period
567
+
568
+ ```
569
+ ⚠️ Insufficient data for update
570
+
571
+ Period: Oct 1-7, 2025
572
+ Stories completed: 0
573
+ Commits: 3
574
+
575
+ Not enough activity to generate meaningful update.
576
+
577
+ Options:
578
+ 1. Expand period to last 2 weeks
579
+ 2. Generate minimal status report
580
+ 3. Cancel
581
+ ```
582
+
583
+ ---
584
+
526
585
  ## Related Commands
527
586
 
528
587
  - `/agileflow:docs` - Synchronize documentation with code
@@ -221,6 +221,82 @@ RULES
221
221
 
222
222
  ---
223
223
 
224
+ ## Expected Output
225
+
226
+ ### Success - All Validations Pass
227
+
228
+ ```
229
+ ======================================
230
+ EXPERTISE VALIDATION REPORT
231
+ ======================================
232
+
233
+ Validating: database
234
+ [PASS] File exists: expertise.yaml
235
+ [PASS] Required sections present
236
+ [PASS] No stale learnings
237
+ [PASS] File size OK (142 lines)
238
+ [PASS] All referenced files exist
239
+
240
+ Validating: api
241
+ [PASS] All checks passed
242
+
243
+ Validating: ui
244
+ [PASS] All checks passed
245
+
246
+ --------------------------------------
247
+ SUMMARY
248
+ --------------------------------------
249
+ Total domains: 25
250
+ Passed: 25
251
+ Warnings: 0
252
+ Failures: 0
253
+
254
+ ✅ All expertise files are valid and up-to-date.
255
+ ```
256
+
257
+ ### Success - Issues Found
258
+
259
+ ```
260
+ ======================================
261
+ EXPERTISE VALIDATION REPORT
262
+ ======================================
263
+
264
+ Validating: database
265
+ [PASS] File exists: expertise.yaml
266
+ [PASS] Required sections present
267
+ [WARN] 2 stale learnings (>30 days)
268
+ [FAIL] DRIFT: src/old/database.ts not found
269
+ [FAIL] DRIFT: lib/deprecated/orm.js not found
270
+
271
+ Validating: api
272
+ [PASS] All checks passed
273
+
274
+ --------------------------------------
275
+ SUMMARY
276
+ --------------------------------------
277
+ Total domains: 25
278
+ Passed: 23
279
+ Warnings: 1
280
+ Failures: 2
281
+
282
+ RECOMMENDED ACTIONS:
283
+ 1. Update database expertise - remove reference to src/old/database.ts
284
+ 2. Update database expertise - remove reference to lib/deprecated/orm.js
285
+ 3. Review stale learnings in database domain
286
+ ```
287
+
288
+ ### Error - Expertise Not Found
289
+
290
+ ```
291
+ ❌ Expertise file not found: .agileflow/experts/mobile/expertise.yaml
292
+
293
+ The 'mobile' domain has no expertise file.
294
+
295
+ Create one with: /agileflow:agent mobile
296
+ ```
297
+
298
+ ---
299
+
224
300
  ## Related Commands
225
301
 
226
302
  - `/agileflow:diagnose` - System health diagnostics