@atlashub/smartstack-cli 4.18.0 → 4.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (160) hide show
  1. package/package.json +1 -1
  2. package/templates/agents/ba-reader.md +86 -80
  3. package/templates/agents/ba-writer.md +318 -415
  4. package/templates/agents/docs-context-reader.md +3 -3
  5. package/templates/mcp-scaffolding/frontend/nav-routes.ts.hbs +133 -0
  6. package/templates/mcp-scaffolding/frontend/routes.tsx.hbs +126 -0
  7. package/templates/skills/apex/SKILL.md +29 -16
  8. package/templates/skills/apex/_shared.md +62 -9
  9. package/templates/skills/apex/references/analysis-methods.md +8 -6
  10. package/templates/skills/apex/references/challenge-questions.md +5 -5
  11. package/templates/skills/apex/references/core-seed-data.md +68 -45
  12. package/templates/skills/apex/references/frontend-route-wiring-app-tsx.md +26 -21
  13. package/templates/skills/apex/references/parallel-execution.md +156 -0
  14. package/templates/skills/apex/references/person-extension-pattern.md +12 -12
  15. package/templates/skills/apex/references/post-checks.md +1748 -1726
  16. package/templates/skills/apex/references/smartstack-api.md +63 -57
  17. package/templates/skills/apex/references/smartstack-frontend-compliance.md +594 -0
  18. package/templates/skills/apex/references/smartstack-frontend.md +1246 -1842
  19. package/templates/skills/apex/references/smartstack-layers.md +98 -145
  20. package/templates/skills/apex/steps/step-00-init.md +30 -6
  21. package/templates/skills/apex/steps/step-01-analyze.md +27 -23
  22. package/templates/skills/apex/steps/step-02-plan.md +12 -12
  23. package/templates/skills/apex/steps/step-03-execute.md +198 -143
  24. package/templates/skills/apex/steps/step-04-examine.md +24 -93
  25. package/templates/skills/apex/steps/step-05-deep-review.md +16 -16
  26. package/templates/skills/apex/steps/step-06-resolve.md +9 -9
  27. package/templates/skills/apex/steps/step-07-tests.md +3 -1
  28. package/templates/skills/apex/steps/step-08-run-tests.md +1 -1
  29. package/templates/skills/business-analyse/SKILL.md +182 -301
  30. package/templates/skills/business-analyse/_shared.md +119 -336
  31. package/templates/skills/business-analyse/html/ba-interactive.html +703 -82
  32. package/templates/skills/business-analyse/html/build-html.js +41 -3
  33. package/templates/skills/business-analyse/html/src/partials/cadrage-context.html +34 -0
  34. package/templates/skills/business-analyse/html/src/partials/cadrage-risks.html +48 -0
  35. package/templates/skills/business-analyse/html/src/partials/cadrage-scope.html +49 -0
  36. package/templates/skills/business-analyse/html/src/partials/cadrage-stakeholders.html +55 -0
  37. package/templates/skills/business-analyse/html/src/partials/cadrage-success.html +34 -0
  38. package/templates/skills/business-analyse/html/src/partials/consol-datamodel.html +8 -0
  39. package/templates/skills/business-analyse/html/src/partials/consol-flows.html +29 -0
  40. package/templates/skills/business-analyse/html/src/partials/consol-interactions.html +8 -0
  41. package/templates/skills/business-analyse/html/src/partials/consol-permissions.html +8 -0
  42. package/templates/skills/business-analyse/html/src/partials/decomp-dependencies.html +38 -0
  43. package/templates/skills/business-analyse/html/src/partials/decomp-modules.html +51 -0
  44. package/templates/skills/business-analyse/html/src/partials/handoff-summary.html +24 -0
  45. package/templates/skills/business-analyse/html/src/partials/module-spec-container.html +4 -0
  46. package/templates/skills/business-analyse/html/src/scripts/01-data-init.js +17 -1
  47. package/templates/skills/business-analyse/html/src/scripts/02-navigation.js +31 -5
  48. package/templates/skills/business-analyse/html/src/scripts/05-render-specs.js +100 -63
  49. package/templates/skills/business-analyse/html/src/scripts/06-render-mockups.js +372 -0
  50. package/templates/skills/business-analyse/html/src/scripts/10-comments.js +41 -13
  51. package/templates/skills/business-analyse/html/src/styles/09-mockups-html.css +136 -0
  52. package/templates/skills/business-analyse/patterns/suggestion-catalog.md +7 -5
  53. package/templates/skills/business-analyse/questionnaire/02-stakeholders-scope.md +142 -0
  54. package/templates/skills/business-analyse/questionnaire/03-data-ui.md +94 -0
  55. package/templates/skills/business-analyse/questionnaire/04-risks-metrics.md +150 -0
  56. package/templates/skills/business-analyse/questionnaire/05-cross-module.md +69 -0
  57. package/templates/skills/business-analyse/questionnaire.md +23 -280
  58. package/templates/skills/business-analyse/react/application-viewer.md +2 -2
  59. package/templates/skills/business-analyse/react/components.md +4 -4
  60. package/templates/skills/business-analyse/react/i18n-template.md +1 -1
  61. package/templates/skills/business-analyse/react/schema.md +14 -14
  62. package/templates/skills/business-analyse/references/acceptance-criteria.md +21 -21
  63. package/templates/skills/business-analyse/references/analysis-semantic-checks.md +3 -3
  64. package/templates/skills/business-analyse/references/compilation-structure-cards.md +1 -1
  65. package/templates/skills/business-analyse/references/consolidation-structural-checks.md +5 -5
  66. package/templates/skills/business-analyse/references/deploy-data-build.md +12 -11
  67. package/templates/skills/business-analyse/references/deploy-modes.md +10 -10
  68. package/templates/skills/business-analyse/references/detection-strategies.md +6 -6
  69. package/templates/skills/business-analyse/references/html-data-mapping.md +15 -15
  70. package/templates/skills/business-analyse/references/naming-conventions.md +4 -4
  71. package/templates/skills/business-analyse/references/review-data-mapping.md +29 -29
  72. package/templates/skills/business-analyse/references/robustness-checks.md +36 -36
  73. package/templates/skills/business-analyse/references/spec-auto-inference.md +2 -2
  74. package/templates/skills/business-analyse/references/ui-dashboard-spec.md +1 -1
  75. package/templates/skills/business-analyse/references/ui-resource-cards.md +1 -1
  76. package/templates/skills/business-analyse/references/validation-checklist.md +3 -3
  77. package/templates/skills/business-analyse/references/wireframe-svg-style-guide.md +2 -2
  78. package/templates/skills/business-analyse/schemas/application-schema.json +8 -8
  79. package/templates/skills/business-analyse/schemas/feature-schema.json +3 -3
  80. package/templates/skills/business-analyse/schemas/index-schema.json +47 -0
  81. package/templates/skills/business-analyse/schemas/project-schema.json +6 -6
  82. package/templates/skills/business-analyse/schemas/sections/analysis-schema.json +1 -1
  83. package/templates/skills/business-analyse/schemas/sections/handoff-schema.json +5 -3
  84. package/templates/skills/business-analyse/schemas/sections/metadata-schema.json +4 -4
  85. package/templates/skills/business-analyse/schemas/sections/specification-schema.json +1 -1
  86. package/templates/skills/business-analyse/schemas/shared/common-defs.json +4 -4
  87. package/templates/skills/business-analyse/steps/step-00-init.md +68 -77
  88. package/templates/skills/business-analyse/steps/step-01-cadrage.md +54 -180
  89. package/templates/skills/business-analyse/steps/step-02-structure.md +175 -0
  90. package/templates/skills/business-analyse/steps/step-03-specify.md +198 -0
  91. package/templates/skills/business-analyse/steps/step-04-consolidate.md +478 -0
  92. package/templates/skills/business-analyse/steps/step-05-deploy.md +220 -0
  93. package/templates/skills/business-analyse/steps/step-06-review.md +51 -69
  94. package/templates/skills/business-analyse/templates/tpl-frd.md +1 -1
  95. package/templates/skills/business-analyse/templates/tpl-handoff.md +20 -17
  96. package/templates/skills/business-analyse/templates/tpl-launch-displays.md +2 -2
  97. package/templates/skills/business-analyse/templates-react.md +2 -2
  98. package/templates/skills/derive-prd/SKILL.md +92 -0
  99. package/templates/skills/derive-prd/references/acceptance-criteria.md +169 -0
  100. package/templates/skills/derive-prd/references/entity-domain-mapping.md +115 -0
  101. package/templates/skills/{business-analyse → derive-prd}/references/handoff-file-templates.md +131 -120
  102. package/templates/skills/{business-analyse → derive-prd}/references/handoff-mappings.md +95 -95
  103. package/templates/skills/{business-analyse → derive-prd}/references/handoff-seeddata-generation.md +312 -312
  104. package/templates/skills/{business-analyse → derive-prd}/references/prd-generation.md +262 -263
  105. package/templates/skills/derive-prd/references/readiness-scoring.md +104 -0
  106. package/templates/skills/derive-prd/schemas/handoff-schema.json +95 -0
  107. package/templates/skills/derive-prd/steps/step-00-validate.md +130 -0
  108. package/templates/skills/derive-prd/steps/step-01-transform.md +206 -0
  109. package/templates/skills/derive-prd/steps/step-02-export.md +181 -0
  110. package/templates/skills/{business-analyse → derive-prd}/templates/tpl-progress.md +172 -172
  111. package/templates/skills/ralph-loop/SKILL.md +2 -1
  112. package/templates/skills/ralph-loop/references/init-resume-recovery.md +1 -1
  113. package/templates/skills/ralph-loop/steps/step-01-task.md +2 -2
  114. package/templates/skills/apex/references/agent-teams-protocol.md +0 -203
  115. package/templates/skills/business-analyse/_architecture.md +0 -124
  116. package/templates/skills/business-analyse/_elicitation.md +0 -206
  117. package/templates/skills/business-analyse/_module-loop.md +0 -115
  118. package/templates/skills/business-analyse/_rules.md +0 -142
  119. package/templates/skills/business-analyse/_suggestions.md +0 -34
  120. package/templates/skills/business-analyse/questionnaire/00-application.md +0 -160
  121. package/templates/skills/business-analyse/questionnaire/00b-project.md +0 -85
  122. package/templates/skills/business-analyse/questionnaire/02-stakeholders.md +0 -189
  123. package/templates/skills/business-analyse/questionnaire/03-scope.md +0 -164
  124. package/templates/skills/business-analyse/questionnaire/04-data.md +0 -88
  125. package/templates/skills/business-analyse/questionnaire/05-integrations.md +0 -58
  126. package/templates/skills/business-analyse/questionnaire/06-security.md +0 -68
  127. package/templates/skills/business-analyse/questionnaire/07-ui.md +0 -76
  128. package/templates/skills/business-analyse/questionnaire/08-performance.md +0 -42
  129. package/templates/skills/business-analyse/questionnaire/09-constraints.md +0 -45
  130. package/templates/skills/business-analyse/questionnaire/10-documentation.md +0 -58
  131. package/templates/skills/business-analyse/questionnaire/11-data-lifecycle.md +0 -59
  132. package/templates/skills/business-analyse/questionnaire/12-migration.md +0 -58
  133. package/templates/skills/business-analyse/questionnaire/13-cross-module.md +0 -69
  134. package/templates/skills/business-analyse/questionnaire/14-risk-assumptions.md +0 -135
  135. package/templates/skills/business-analyse/questionnaire/15-success-metrics.md +0 -136
  136. package/templates/skills/business-analyse/references/agent-module-prompt.md +0 -366
  137. package/templates/skills/business-analyse/references/agent-pooling-best-practices.md +0 -557
  138. package/templates/skills/business-analyse/references/cache-warming-strategy.md +0 -566
  139. package/templates/skills/business-analyse/references/cadrage-challenge-patterns.md +0 -41
  140. package/templates/skills/business-analyse/references/cadrage-coverage-matrix.md +0 -74
  141. package/templates/skills/business-analyse/references/cadrage-pre-analysis.md +0 -115
  142. package/templates/skills/business-analyse/references/cadrage-shared-modules.md +0 -68
  143. package/templates/skills/business-analyse/references/cadrage-structure-cards.md +0 -85
  144. package/templates/skills/business-analyse/references/team-orchestration.md +0 -1093
  145. package/templates/skills/business-analyse/references/validate-incremental-html.md +0 -121
  146. package/templates/skills/business-analyse/steps/step-01b-applications.md +0 -419
  147. package/templates/skills/business-analyse/steps/step-02-decomposition.md +0 -387
  148. package/templates/skills/business-analyse/steps/step-03a-data.md +0 -16
  149. package/templates/skills/business-analyse/steps/step-03a1-setup.md +0 -486
  150. package/templates/skills/business-analyse/steps/step-03a2-analysis.md +0 -300
  151. package/templates/skills/business-analyse/steps/step-03b-ui.md +0 -405
  152. package/templates/skills/business-analyse/steps/step-03c-compile.md +0 -516
  153. package/templates/skills/business-analyse/steps/step-03d-validate.md +0 -691
  154. package/templates/skills/business-analyse/steps/step-04-consolidation.md +0 -17
  155. package/templates/skills/business-analyse/steps/step-04a-collect.md +0 -415
  156. package/templates/skills/business-analyse/steps/step-04b-analyze.md +0 -163
  157. package/templates/skills/business-analyse/steps/step-04c-decide.md +0 -186
  158. package/templates/skills/business-analyse/steps/step-05a-handoff.md +0 -937
  159. package/templates/skills/business-analyse/steps/step-05b-deploy.md +0 -522
  160. package/templates/skills/business-analyse/steps/step-05c-ralph-readiness.md +0 -703
@@ -1,6 +1,6 @@
1
1
  # Robustness Checks for Business Analysis
2
2
 
3
- > **Authoritative minimums:** See `_rules.md` § "Minimum Counts" for the single source of truth on all minimum thresholds.
3
+ > **Authoritative minimums:** See `_shared.md` § "Minimum Counts" for the single source of truth on all minimum thresholds.
4
4
  > **Objective:** Prevent incomplete specifications and broken references from reaching development.
5
5
 
6
6
  ## Overview
@@ -9,10 +9,10 @@ This document consolidates all robustness checks implemented across the business
9
9
 
10
10
  ---
11
11
 
12
- ## Phase 1: Module Specification Checklist (Step-03d)
12
+ ## Phase 1: Module Specification Checklist (Step-03)
13
13
 
14
- > **When:** Before marking module status = "specified"
15
- > **Blocking:** YES - Module CANNOT proceed to handoff with failing checks
14
+ > **When:** At end of step-03, before marking module status = "specified"
15
+ > **Blocking:** YES - Module CANNOT proceed to consolidation with failing checks
16
16
 
17
17
  ### Purpose
18
18
 
@@ -43,7 +43,7 @@ Ensures each module has ALL required components before being marked as "specifie
43
43
  | 3.1 | Use cases count | ≥6 | YES | CRUD (5) + 1 business-specific minimum |
44
44
  | 3.2 | UC module prefixes | All UCs use module prefix | YES | Prevents ID collisions |
45
45
  | 3.3 | Functional requirements count | ≥4 | YES | FRs must cover key functionality |
46
- | 3.4 | UC-FR linkage | Every UC has ≥1 linked FR | YES | Orphan UCs indicate incomplete requirements |
46
+ | 3.4 | UC-FR linkage | Every UC has ≥1 linked FR | NO (WARNING) | Orphan UCs indicate incomplete requirements |
47
47
  | 3.5 | FR-BR linkage | Every FR has ≥1 linked BR | NO (WARNING) | FRs without BRs may lack validation logic |
48
48
 
49
49
  #### SECTION 4: Permissions (3 checks)
@@ -75,19 +75,19 @@ Ensures each module has ALL required components before being marked as "specifie
75
75
 
76
76
  | # | Check | Minimum | Blocking | Rationale |
77
77
  |---|-------|---------|----------|-----------|
78
- | 7.1 | CORE seed data arrays | All 9 arrays present (per `_rules.md` § "Minimum Counts") | YES | Missing CORE data breaks deployment |
78
+ | 7.1 | CORE seed data arrays | All 9 arrays present (per `_shared.md` § "Minimum Counts") | YES | Missing CORE data breaks deployment |
79
79
  | 7.2 | Business seed data | Template defined | NO (WARNING) | Helps with testing |
80
80
 
81
- **CORE arrays required (9 total — see `_rules.md` § "seedDataCore arrays"):**
82
- 1. `navigationApplications` — required for 1st module, can be `[]` for subsequent
83
- 2. `applicationRoles` — required for 1st module, can be `[]` for subsequent
84
- 3. `navigationModules`
85
- 4. `navigationSections`
86
- 5. `navigationResources`
87
- 6. `navigationTranslations`
88
- 7. `permissions`
89
- 8. `rolePermissions`
90
- 9. `permissionConstants`
81
+ **CORE arrays required (9 total — see `_shared.md` § "seedDataCore arrays"):**
82
+ 1. `navigationApplications` — required once per application
83
+ 2. `applicationRoles` — required once per application
84
+ 3. `navigationModules` — one per module
85
+ 4. `navigationSections` — one per section (list, detail, create, etc.)
86
+ 5. `navigationResources` — optional per resource
87
+ 6. `navigationTranslations` — 4 languages per nav module
88
+ 7. `permissions` — CRUD + business actions per module
89
+ 8. `rolePermissions` — role to permission mappings
90
+ 9. `permissionConstants` — PascalCase constants for code
91
91
 
92
92
  #### SECTION 8: API Endpoints (2 checks)
93
93
 
@@ -116,7 +116,7 @@ Ensures each module has ALL required components before being marked as "specifie
116
116
  2. **DISPLAY** table of failures with details
117
117
  3. **ACTIONS:**
118
118
  - Fix ALL blocking failures
119
- - Re-run step-03d validation
119
+ - Re-run step-03 module specification
120
120
  - Proceed only when ALL blocking checks pass
121
121
 
122
122
  **Example output:**
@@ -136,7 +136,7 @@ ACTIONS REQUIRED:
136
136
  1. Add business rules in ≥1 other category (CALC, WF, SEC, or DATA)
137
137
  2. Add 2 more use cases (business-specific)
138
138
  3. Create wireframe for "Settings" section
139
- 4. Re-run step-03d validation
139
+ 4. Re-run step-03 validation
140
140
 
141
141
  DO NOT PROCEED TO CONSOLIDATION UNTIL ALL CHECKS PASS
142
142
  ═══════════════════════════════════════════════════════════════
@@ -229,7 +229,7 @@ BLOCKING ERRORS:
229
229
 
230
230
  ACTIONS REQUIRED:
231
231
  1. Fix ALL unresolved references listed above
232
- 2. Return to step-03a for affected modules
232
+ 2. Return to step-03 for affected modules
233
233
  3. Re-run step-04 consolidation
234
234
 
235
235
  DO NOT PROCEED TO HANDOFF UNTIL ALL REFERENCES RESOLVED
@@ -264,9 +264,9 @@ DEVELOPMENT CANNOT PROCEED WITH CIRCULAR DEPENDENCIES
264
264
 
265
265
  ---
266
266
 
267
- ## Phase 3: Ralph Readiness Validation (Step-05c)
267
+ ## Phase 3: Ralph Readiness Validation (Step-05)
268
268
 
269
- > **When:** After artifacts deployed (step-05b), before launching /ralph-loop
269
+ > **When:** After artifacts deployed (step-05), before launching /ralph-loop
270
270
  > **Blocking:** YES - Development blocked if critical checks fail
271
271
 
272
272
  ### Purpose
@@ -278,10 +278,10 @@ Final gate to ensure business analysis is 100% ready for implementation. Catches
278
278
  | # | Category | Checks | Blocking | Purpose |
279
279
  |---|----------|--------|----------|---------|
280
280
  | 1 | Module Status | All modules status = "handed-off" | YES | Incomplete modules break ralph-loop |
281
- | 2 | PRD Files | All PRD files exist, valid structure, file counts match | YES | Ralph-loop reads PRDs for tasks |
281
+ | 2 | PRD Files | All .ralph/prd-{module}.json files exist, valid structure, file counts match index.json | YES | Ralph-loop reads PRDs for tasks |
282
282
  | 3 | Dependency Graph | Valid, no cycles, topological order correct | YES | Determines module implementation order |
283
283
  | 4 | Cross-Module References | All references resolvable | YES | Prevents FK constraint errors |
284
- | 5 | Handoff Completeness | All 7 file categories, brToCodeMapping, apiEndpointSummary | YES | Missing data breaks code generation |
284
+ | 5 | Handoff Completeness | All 8 file categories, brToCodeMapping, apiEndpointSummary | YES | Missing data breaks code generation |
285
285
  | 6 | i18n Keys | All keys have 4 languages | NO (WARNING) | Missing translations won't block dev |
286
286
  | 7 | Master Feature | Status = "handed-off", handoff complete | YES | Ralph-loop needs master handoff |
287
287
  | 8 | Progress Tracker | File exists, structure valid, task count matches | NO (WARNING) | Used for progress tracking |
@@ -340,7 +340,7 @@ Status: NOT READY FOR DEVELOPMENT ✗
340
340
  Critical Issues Found:
341
341
  ✗ Module status validation: FAIL (1/5 modules incomplete)
342
342
  - Reporting module status is "specified", must be "handed-off"
343
- - Fix: Return to step-05a-handoff.md for Reporting module
343
+ - Fix: Return to step-05-deploy.md for Reporting module
344
344
 
345
345
  ✗ PRD files validation: FAIL (1/5 files invalid)
346
346
  - prd-Reporting.json has wrong structure (filesToCreate at root level)
@@ -348,7 +348,7 @@ Critical Issues Found:
348
348
 
349
349
  Required Actions:
350
350
  1. Fix all critical issues listed above
351
- 2. Re-run validation: load step-05c-ralph-readiness.md
351
+ 2. Re-run validation: load step-05-deploy.md
352
352
  3. Only proceed to /ralph-loop when all critical checks pass
353
353
 
354
354
  DO NOT PROCEED TO /RALPH-LOOP UNTIL ALL CRITICAL CHECKS PASS
@@ -414,7 +414,7 @@ WHY: This will cause FK constraint violation in database
414
414
  HOW TO FIX:
415
415
  Option 1: Create "Task" entity in Projects module
416
416
  Option 2: Remove reference from TimeEntry (change taskId to projectId)
417
- WHERE: Return to step-03a1-setup.md for TimeTracking module
417
+ WHERE: Return to step-03-specify.md for TimeTracking module
418
418
  ```
419
419
 
420
420
  ---
@@ -433,7 +433,7 @@ WHERE: Return to step-03a1-setup.md for TimeTracking module
433
433
 
434
434
  **Fix:**
435
435
  1. Add missing components until minimums met
436
- 2. Re-run step-03d validation
436
+ 2. Re-run step-03 validation
437
437
  3. Proceed only when ALL blocking checks pass
438
438
 
439
439
  ---
@@ -480,9 +480,9 @@ WHERE: Return to step-03a1-setup.md for TimeTracking module
480
480
  3. **Option 3: Remove unnecessary dependency**
481
481
  - Review if dependency is truly needed
482
482
  - Remove if redundant
483
- 4. Return to step-02, fix dependency graph
484
- 5. Re-run step-03 for affected modules
485
- 6. Re-run step-04 consolidation
483
+ 4. Return to step-02-structure, fix dependency graph
484
+ 5. Re-run step-03-specify for affected modules
485
+ 6. Re-run step-04-consolidate
486
486
 
487
487
  ---
488
488
 
@@ -497,11 +497,11 @@ WHERE: Return to step-03a1-setup.md for TimeTracking module
497
497
  2. Identify missing/invalid artifacts
498
498
 
499
499
  **Fix:**
500
- - **Module status incomplete:** Return to step-05a for affected module
500
+ - **Module status incomplete:** Return to step-05-deploy for affected module
501
501
  - **PRD files invalid:** Re-run `ss derive-prd` for affected module
502
- - **Handoff incomplete:** Return to step-05a, complete handoff section
503
- - **Cross-module refs broken:** Return to step-04, fix references
504
- - Re-run step-05c after fixes
502
+ - **Handoff incomplete:** Return to step-05-deploy, complete handoff section
503
+ - **Cross-module refs broken:** Return to step-04-consolidate, fix references
504
+ - Re-run step-05-deploy after fixes
505
505
 
506
506
  ---
507
507
 
@@ -527,7 +527,7 @@ WHERE: Return to step-03a1-setup.md for TimeTracking module
527
527
  - Application marked as "consolidated"
528
528
  - Ready for handoff
529
529
 
530
- ### Ralph Readiness
530
+ ### Ralph Readiness (Step-05)
531
531
 
532
532
  **Target:**
533
533
  - 100% critical checks passed
@@ -535,7 +535,7 @@ WHERE: Return to step-03a1-setup.md for TimeTracking module
535
535
 
536
536
  **Success:**
537
537
  - Application ready for /ralph-loop
538
- - 0% chance of ralph-loop failure due to incomplete BA
538
+ - Development can proceed with full confidence
539
539
 
540
540
  ---
541
541
 
@@ -1,6 +1,6 @@
1
1
  # Specification: Auto-Inference Rules
2
2
 
3
- > Reference for step-03a1-setup.md — convention/override depth auto-generation from entity definitions.
3
+ > Reference for step-03-specify.md — convention/override depth auto-generation from entity definitions.
4
4
 
5
5
  ## Entity Attribute → SmartTable Column
6
6
 
@@ -76,7 +76,7 @@ IF coverageMatrix[module].detailTabs EXISTS:
76
76
  FOR EACH tabName IN detailTabs:
77
77
  IF tabName matches a 1:N relationship entity → SmartTable tab
78
78
  ELIF tabName == "Historique"/"History" → Timeline tab
79
- ELSE → custom DetailCard tab (contents TBD in step-03b)
79
+ ELSE → custom DetailCard tab (contents TBD in step-03)
80
80
 
81
81
  # 3. If no cadrage tabs, auto-infer from relationships
82
82
  ELSE:
@@ -1,6 +1,6 @@
1
1
  # UI: Dashboard Specification
2
2
 
3
- > Reference for step-03b-ui.md — section 3d dashboard KPI and chart capture.
3
+ > Reference for step-03-specify.md — section 3d dashboard KPI and chart capture.
4
4
 
5
5
  ## 3d. Dashboard Specification (if section = dashboard)
6
6
 
@@ -1,6 +1,6 @@
1
1
  # UI: Resource Structure Cards
2
2
 
3
- > Reference for step-03b-ui.md — exact JSON formats for section resources (SmartTable, SmartForm) and wireframes.
3
+ > Reference for step-03-specify.md — exact JSON formats for section resources (SmartTable, SmartForm) and wireframes.
4
4
 
5
5
  ## specification.sections[] (with resources)
6
6
 
@@ -1,6 +1,6 @@
1
1
  # Module Specification Checklist
2
2
 
3
- > **Authoritative minimums:** See `_rules.md` § "Minimum Counts" for the single source of truth on all minimum thresholds.
3
+ > **Authoritative minimums:** See `_shared.md` for the single source of truth on all minimum thresholds.
4
4
  > **CRITICAL:** This checklist MUST be FULLY COMPLETED before marking module status = "specified".
5
5
  > **Rationale:** Prevents incomplete modules from reaching handoff, reduces ralph-loop failures.
6
6
 
@@ -269,7 +269,7 @@ const checklist = {
269
269
  status: Array.isArray(specification.gherkinScenarios) ? "PASS" : "FAIL",
270
270
  blocking: true,
271
271
  details: "gherkinScenarios MUST be an array [{feature, scenarios}], not a single object. " +
272
- "Auto-fix: wrap in array [gherkinScenarios]. See step-03c ABSOLUTE FORMAT CHECKS."
272
+ "Auto-fix: wrap in array [gherkinScenarios]. See step-03 ABSOLUTE FORMAT CHECKS."
273
273
  },
274
274
 
275
275
  gherkinContent: {
@@ -311,7 +311,7 @@ IF blockingFailures.length > 0:
311
311
 
312
312
  ACTIONS REQUIRED:
313
313
  1. Fix ALL blocking failures listed above
314
- 2. Re-run step-03d validation
314
+ 2. Re-run step-03 validation
315
315
  3. DO NOT mark module as "specified" until ALL blocking checks pass
316
316
 
317
317
  STOP - DO NOT PROCEED TO UPDATE STATUS
@@ -2,7 +2,7 @@
2
2
 
3
3
  > **Purpose:** Self-contained specification for generating professional SVG wireframes from ASCII art.
4
4
  > This document is sent as the FULL prompt to a Sonnet Task agent alongside the ASCII wireframe.
5
- > Referenced by: `validate-incremental-html.md` (Step 3-bis), `step-05b-deploy.md` (Section 7-bis)
5
+ > Referenced by: `step-05-deploy.md` (Section 8: Generate SVG Wireframes)
6
6
 
7
7
  ## Agent Prompt Template
8
8
 
@@ -280,7 +280,7 @@ This signals the system to use the ASCII wireframe instead.
280
280
 
281
281
  ## Orchestration Instructions
282
282
 
283
- > **FOR the agent executing step-03d 11-bis or step-05b**: Follow this process to generate SVGs.
283
+ > **FOR the agent executing step-03 or step-05**: Follow this process to generate SVGs.
284
284
 
285
285
  ### Step-by-step process:
286
286
 
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "application-schema.json",
4
4
  "title": "SmartStack Business Analysis - Application Level",
5
- "description": "Master feature.json for multi-module application analysis. Published to docs/{app}/business-analyse/v{X.Y}/feature.json",
5
+ "description": "Master index.json for multi-module application analysis. Published to docs/{app}/business-analyse/v{X.Y}/index.json",
6
6
  "type": "object",
7
7
  "required": ["id", "version", "status", "scope", "metadata"],
8
8
  "properties": {
@@ -24,7 +24,7 @@
24
24
  "scope": {
25
25
  "type": "string",
26
26
  "const": "application",
27
- "description": "Marks this as an application-level feature.json"
27
+ "description": "Marks this as an application-level index.json"
28
28
  },
29
29
 
30
30
  "metadata": {
@@ -55,16 +55,16 @@
55
55
  },
56
56
  "applicationCode": {
57
57
  "type": "string",
58
- "description": "PascalCase application code for navigation hierarchy (e.g., HumanResources). Confirmed in step-01b."
58
+ "description": "PascalCase application code for navigation hierarchy (e.g., HumanResources). Confirmed in step-02."
59
59
  },
60
60
  "applicationRoute": {
61
61
  "type": "string",
62
62
  "pattern": "^/[a-z-/]+$",
63
- "description": "Kebab-case route path for navigation (e.g., /human-resources). Confirmed in step-01b."
63
+ "description": "Kebab-case route path for navigation (e.g., /human-resources). Confirmed in step-02."
64
64
  },
65
65
  "applicationIcon": {
66
66
  "type": "string",
67
- "description": "Lucide icon name for application navigation entry (e.g., users, shopping-cart). Confirmed in step-01b."
67
+ "description": "Lucide icon name for application navigation entry (e.g., users, shopping-cart). Confirmed in step-02."
68
68
  },
69
69
  "workflow": {
70
70
  "type": "object",
@@ -215,7 +215,7 @@
215
215
 
216
216
  "modules": {
217
217
  "type": "array",
218
- "description": "Enriched by step-02-decomposition: module registry with dependencies",
218
+ "description": "Enriched by step-02-structure: module registry with dependencies",
219
219
  "items": {
220
220
  "type": "object",
221
221
  "required": ["code", "description"],
@@ -244,7 +244,7 @@
244
244
  },
245
245
  "featureJsonPath": {
246
246
  "type": ["string", "null"],
247
- "description": "Path to the module-level feature.json once created"
247
+ "description": "Path to the module-level index.json once created"
248
248
  },
249
249
  "priority": {
250
250
  "type": "string",
@@ -287,7 +287,7 @@
287
287
 
288
288
  "dependencyGraph": {
289
289
  "type": "object",
290
- "description": "Enriched by step-02-decomposition: module dependency graph",
290
+ "description": "Enriched by step-02-structure: module dependency graph",
291
291
  "properties": {
292
292
  "edges": {
293
293
  "type": "array",
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "feature.json",
3
+ "$id": "feature-schema.json",
4
4
  "title": "SmartStack Business Analysis Feature v5.0",
5
- "description": "Root schema for module-level feature.json. References sub-schemas in sections/ and shared/. Each BA step loads only the sub-schema(s) it needs.",
5
+ "description": "Root schema for module-level index.json. References sub-schemas in sections/ and shared/. Each BA step loads only the sub-schema(s) it needs.",
6
6
  "type": "object",
7
7
  "required": ["id", "version", "status", "metadata"],
8
8
  "properties": {
@@ -43,7 +43,7 @@
43
43
  }
44
44
  },
45
45
 
46
- "$comment": "Sub-schema loading guide per BA step: step-00-init → metadata-schema.json | step-01-cadrage → discovery-schema.json (module) OR application-schema.json (master) | step-02-decomposition → application-schema.json (modules[], dependencyGraph) | step-03a-data → analysis-schema.json | step-03b-ui → specification-schema.json (wireframes, layouts) | step-03c-compile → specification-schema.json | step-03d-validate → validation-schema.json | step-04-consolidation → validation-schema.json + application-schema.json (consolidation) | step-05a-handoff → handoff-schema.json (filesToCreate, brToCodeMapping, apiEndpointSummary) | step-05b-deploy → (prd, progress, manifest, ba-interactive.html)",
46
+ "$comment": "Sub-schema loading guide per BA step: step-00-init → metadata-schema.json | step-01-cadrage → discovery-schema.json (module) OR application-schema.json (master) | step-02-structure → application-schema.json (modules[], dependencyGraph) | step-03-specify → analysis-schema.json + specification-schema.json | step-04-consolidate → validation-schema.json + application-schema.json (consolidation) | step-05-deploy → handoff-schema.json (filesToCreate, brToCodeMapping, apiEndpointSummary) + (prd, progress, manifest, ba-interactive.html) | step-06-review → applies ba-review.json corrections, creates new version",
47
47
 
48
48
  "$defs": {
49
49
  "stepStatus": { "$ref": "shared/common-defs.json#/$defs/stepStatus" },
@@ -0,0 +1,47 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "index-schema.json",
4
+ "title": "Business Analysis Index",
5
+ "description": "Index file for granular business analysis JSON files. References individual thematic files (entities, rules, usecases, etc.) with metadata and hashes.",
6
+ "type": "object",
7
+ "required": ["metadata", "files"],
8
+ "properties": {
9
+ "metadata": {
10
+ "type": "object",
11
+ "required": ["featureId", "moduleCode", "version", "status"],
12
+ "properties": {
13
+ "featureId": { "type": "string", "description": "Unique feature identifier (e.g. FEAT-001)" },
14
+ "moduleCode": { "type": "string", "description": "PascalCase module code (e.g. Employees)" },
15
+ "applicationCode": { "type": "string", "description": "PascalCase application code (e.g. HumanResources)" },
16
+ "version": { "type": "string", "description": "Semantic version (e.g. 1.0)" },
17
+ "status": { "type": "string", "enum": ["draft", "identified", "specified", "validated", "reviewed"] },
18
+ "createdAt": { "type": "string", "format": "date-time" },
19
+ "lastModified": { "type": "string", "format": "date-time" }
20
+ }
21
+ },
22
+ "files": {
23
+ "type": "object",
24
+ "description": "References to individual JSON files",
25
+ "additionalProperties": {
26
+ "type": "object",
27
+ "required": ["path"],
28
+ "properties": {
29
+ "path": { "type": "string", "description": "Relative path to the JSON file" },
30
+ "hash": { "type": "string", "description": "Content hash for change detection" },
31
+ "lastModified": { "type": "string", "description": "Last modification date" }
32
+ }
33
+ }
34
+ },
35
+ "summary": {
36
+ "type": "object",
37
+ "properties": {
38
+ "entityCount": { "type": "integer" },
39
+ "ruleCount": { "type": "integer" },
40
+ "useCaseCount": { "type": "integer" },
41
+ "permissionCount": { "type": "integer" },
42
+ "screenCount": { "type": "integer" },
43
+ "dependencies": { "type": "array", "items": { "type": "string" } }
44
+ }
45
+ }
46
+ }
47
+ }
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "project-schema.json",
4
4
  "title": "SmartStack Business Analysis - Project Level",
5
- "description": "Master feature.json for multi-application project analysis. Published to docs/business-analyse/v{X.Y}/feature.json. Only created when 2+ applications are identified.",
5
+ "description": "Master index.json for multi-application project analysis. Published to docs/business-analyse/v{X.Y}/index.json. Only created when 2+ applications are identified.",
6
6
  "type": "object",
7
7
  "required": ["id", "version", "status", "scope", "metadata"],
8
8
  "properties": {
@@ -24,7 +24,7 @@
24
24
  "scope": {
25
25
  "type": "string",
26
26
  "const": "project",
27
- "description": "Marks this as a project-level feature.json (multi-application)"
27
+ "description": "Marks this as a project-level index.json (multi-application)"
28
28
  },
29
29
 
30
30
  "metadata": {
@@ -79,7 +79,7 @@
79
79
  "properties": {
80
80
  "init": { "$ref": "#/$defs/stepStatus" },
81
81
  "cadrage": { "$ref": "#/$defs/stepStatus" },
82
- "applicationDecomposition": { "$ref": "#/$defs/stepStatus" },
82
+ "structure": { "$ref": "#/$defs/stepStatus" },
83
83
  "specify": { "$ref": "#/$defs/stepStatus" },
84
84
  "consolidation": { "$ref": "#/$defs/stepStatus" },
85
85
  "handoff": { "$ref": "#/$defs/stepStatus" }
@@ -219,7 +219,7 @@
219
219
 
220
220
  "applications": {
221
221
  "type": "array",
222
- "description": "Enriched by step-01b-applications: application registry",
222
+ "description": "Enriched by step-02-structure: application registry",
223
223
  "items": {
224
224
  "type": "object",
225
225
  "required": ["code", "name"],
@@ -273,7 +273,7 @@
273
273
  },
274
274
  "featureJsonPath": {
275
275
  "type": ["string", "null"],
276
- "description": "Path to the application-level feature.json once created"
276
+ "description": "Path to the application-level index.json once created"
277
277
  },
278
278
  "estimatedComplexity": {
279
279
  "type": "string",
@@ -285,7 +285,7 @@
285
285
 
286
286
  "applicationDependencyGraph": {
287
287
  "type": "object",
288
- "description": "Enriched by step-01b-applications: inter-application dependency graph",
288
+ "description": "Enriched by step-02-structure: inter-application dependency graph",
289
289
  "properties": {
290
290
  "edges": {
291
291
  "type": "array",
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "analysis-schema.json",
4
4
  "title": "SmartStack BA - Analysis",
5
- "description": "Module-level analysis: objectives, business rules, entities, process flows, integrations, data lifecycle. Enriched by step-03a-data.",
5
+ "description": "Module-level analysis: objectives, business rules, entities, process flows, integrations, data lifecycle. Enriched by step-03-specify.",
6
6
  "type": "object",
7
7
  "properties": {
8
8
  "objectives": {
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "handoff-schema.json",
4
4
  "title": "SmartStack BA - Handoff",
5
- "description": "Module-level handoff: file mapping (7 categories), BR-to-code mapping, API endpoint summary. Used by step-05a-handoff.",
5
+ "description": "Module-level handoff: file mapping (8 categories), BR-to-code mapping, API endpoint summary. Used by /derive-prd skill.",
6
6
  "type": "object",
7
7
  "properties": {
8
8
  "complexity": { "type": "string", "enum": ["simple", "medium", "complex"] },
@@ -15,8 +15,10 @@
15
15
  "api": { "type": "array", "items": { "$ref": "../shared/common-defs.json#/$defs/fileSpec" } },
16
16
  "frontend": { "type": "array", "items": { "$ref": "../shared/common-defs.json#/$defs/fileSpec" } },
17
17
  "seedData": { "type": "array", "items": { "$ref": "../shared/common-defs.json#/$defs/fileSpec" } },
18
- "tests": { "type": "array", "items": { "$ref": "../shared/common-defs.json#/$defs/fileSpec" } }
19
- }
18
+ "tests": { "type": "array", "items": { "$ref": "../shared/common-defs.json#/$defs/fileSpec" } },
19
+ "documentation": { "type": "array", "items": { "$ref": "../shared/common-defs.json#/$defs/fileSpec" } }
20
+ },
21
+ "required": ["domain", "application", "infrastructure", "api", "frontend", "seedData", "tests", "documentation"]
20
22
  },
21
23
  "brToCodeMapping": {
22
24
  "type": "array",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "metadata-schema.json",
3
+ "$id": "metadata-schema",
4
4
  "title": "SmartStack BA - Metadata & Application Context",
5
5
  "description": "Module metadata and inherited application context. Used by step-00-init.",
6
6
 
@@ -13,7 +13,7 @@
13
13
  "updatedAt": { "type": "string", "format": "date-time" },
14
14
  "application": { "type": "string", "description": "Application name (PascalCase)" },
15
15
  "module": { "type": "string", "description": "Module name (PascalCase)" },
16
- "projectRef": { "type": ["string", "null"], "description": "Parent project ID (PROJ-XXX) when part of a multi-application project" },
16
+ "projectRef": { "type": ["string", "null"], "description": "Parent project ID (PROJ-XXX) when part of a multi-application project, null for standalone" },
17
17
  "language": { "type": "string", "enum": ["fr", "en", "it", "de"] },
18
18
  "featureDescription": { "type": "string" },
19
19
  "featureType": {
@@ -29,7 +29,7 @@
29
29
  "mcpAvailable": { "type": "boolean" },
30
30
  "scope": { "type": "string", "enum": ["application", "module"], "default": "module" },
31
31
  "applicationRef": { "type": ["string", "null"], "description": "Parent application feature ID (FEAT-XXX)" },
32
- "applicationPath": { "type": ["string", "null"], "description": "Path to parent application-level feature.json" },
32
+ "applicationPath": { "type": ["string", "null"], "description": "Path to parent application-level index.json" },
33
33
  "moduleIndex": { "type": ["integer", "null"], "description": "Position in topological order (0-based)" },
34
34
  "totalModules": { "type": ["integer", "null"] },
35
35
  "inheritsRoles": { "type": "boolean", "default": false },
@@ -48,7 +48,7 @@
48
48
 
49
49
  "applicationContext": {
50
50
  "type": "object",
51
- "description": "Inherited from parent application feature.json when part of multi-module analysis",
51
+ "description": "Inherited from parent application index.json when part of multi-module analysis",
52
52
  "properties": {
53
53
  "applicationRoles": {
54
54
  "type": "array",
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "$id": "specification-schema.json",
4
4
  "title": "SmartStack BA - Specification",
5
- "description": "Module-level specification: actors, use cases, FRs, permissions, navigation, wireframes, dashboards, sections, resources. Enriched by step-03c-compile.",
5
+ "description": "Module-level specification: actors, use cases, FRs, permissions, navigation, wireframes, dashboards, sections, resources. Enriched by step-03-specify.",
6
6
  "type": "object",
7
7
  "properties": {
8
8
  "actors": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "common-defs.json",
3
+ "$id": "common-defs",
4
4
  "title": "SmartStack BA - Shared Definitions",
5
5
  "description": "Reusable $defs shared across all BA sub-schemas",
6
6
 
@@ -16,8 +16,8 @@
16
16
 
17
17
  "moduleStatus": {
18
18
  "type": "string",
19
- "description": "Status of a module or application through the BA workflow. Module flow: draft → analysed → specified → approved → handed-off. Application flow: draft → framed → decomposed → specified → consolidated → handed-off.",
20
- "enum": ["draft", "framed", "decomposed", "analysed", "specified", "rejected", "approved", "consolidated", "handed-off"]
19
+ "description": "Status of a module or application through the BA workflow. Module flow: draft → identified → specified → validatedreviewed → handed-off. Application flow: draft → framed → decomposed → specified → consolidated → handed-off.",
20
+ "enum": ["draft", "framed", "decomposed", "identified", "specified", "validated", "consolidated", "reviewed", "handed-off"]
21
21
  },
22
22
 
23
23
  "priority": {
@@ -48,7 +48,7 @@
48
48
  "description": "Acceptance criteria describing how the implementation must match the wireframe layout. MANDATORY for Page and DashboardPage types."
49
49
  },
50
50
  "category": { "type": "string", "enum": ["core", "business"], "description": "SeedData category: core (navigation/permissions) or business (lookup tables)" },
51
- "source": { "type": "string", "description": "Source path in feature.json for derivation" },
51
+ "source": { "type": "string", "description": "Source path in index.json for derivation" },
52
52
  "description": { "type": "string" },
53
53
  "pattern": { "type": "string", "description": "Reference pattern from existing codebase" },
54
54
  "instructions": { "type": "string" },