fraim-framework 2.0.66 → 2.0.67

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 (254) hide show
  1. package/dist/registry/ai-manager-rules/customer-development-phases/phase1-customer-profiling.md +101 -0
  2. package/dist/registry/ai-manager-rules/customer-development-phases/phase2-platform-discovery.md +235 -0
  3. package/dist/registry/ai-manager-rules/customer-development-phases/phase3-prospect-qualification.md +243 -0
  4. package/dist/registry/ai-manager-rules/customer-development-phases/phase4-inventory-compilation.md +206 -0
  5. package/dist/registry/ai-manager-rules/design-phases/design-completeness-review.md +73 -0
  6. package/dist/registry/ai-manager-rules/design-phases/design-design.md +145 -0
  7. package/dist/registry/ai-manager-rules/design-phases/design.md +108 -0
  8. package/dist/registry/ai-manager-rules/design-phases/finalize.md +60 -0
  9. package/dist/registry/ai-manager-rules/design-phases/validate.md +125 -0
  10. package/dist/registry/ai-manager-rules/design.json +97 -0
  11. package/dist/registry/ai-manager-rules/implement-phases/code.md +323 -0
  12. package/dist/registry/ai-manager-rules/implement-phases/completeness-review.md +94 -0
  13. package/dist/registry/ai-manager-rules/implement-phases/finalize.md +177 -0
  14. package/dist/registry/ai-manager-rules/implement-phases/implement-code.md +283 -0
  15. package/dist/registry/ai-manager-rules/implement-phases/implement-completeness-review.md +120 -0
  16. package/dist/registry/ai-manager-rules/implement-phases/implement-regression.md +173 -0
  17. package/dist/registry/ai-manager-rules/implement-phases/implement-repro.md +104 -0
  18. package/dist/registry/ai-manager-rules/implement-phases/implement-scoping.md +100 -0
  19. package/dist/registry/ai-manager-rules/implement-phases/implement-smoke.md +237 -0
  20. package/dist/registry/ai-manager-rules/implement-phases/implement-spike.md +121 -0
  21. package/dist/registry/ai-manager-rules/implement-phases/implement-validate.md +375 -0
  22. package/dist/registry/ai-manager-rules/implement-phases/quality-review.md +304 -0
  23. package/dist/registry/ai-manager-rules/implement-phases/regression.md +159 -0
  24. package/dist/registry/ai-manager-rules/implement-phases/repro.md +101 -0
  25. package/dist/registry/ai-manager-rules/implement-phases/scoping.md +93 -0
  26. package/dist/registry/ai-manager-rules/implement-phases/smoke.md +225 -0
  27. package/dist/registry/ai-manager-rules/implement-phases/spike.md +118 -0
  28. package/dist/registry/ai-manager-rules/implement-phases/validate.md +347 -0
  29. package/dist/registry/ai-manager-rules/implement.json +153 -0
  30. package/dist/registry/ai-manager-rules/retrospective.md +116 -0
  31. package/dist/registry/ai-manager-rules/shared-phases/address-pr-feedback.md +188 -0
  32. package/dist/registry/ai-manager-rules/shared-phases/finalize.md +169 -0
  33. package/dist/registry/ai-manager-rules/shared-phases/submit-pr.md +202 -0
  34. package/dist/registry/ai-manager-rules/shared-phases/wait-for-pr-review.md +170 -0
  35. package/dist/registry/ai-manager-rules/spec-phases/finalize.md +60 -0
  36. package/dist/registry/ai-manager-rules/spec-phases/spec-competitor-analysis.md +105 -0
  37. package/dist/registry/ai-manager-rules/spec-phases/spec-completeness-review.md +66 -0
  38. package/dist/registry/ai-manager-rules/spec-phases/spec-spec.md +139 -0
  39. package/dist/registry/ai-manager-rules/spec-phases/spec.md +102 -0
  40. package/dist/registry/ai-manager-rules/spec-phases/validate.md +118 -0
  41. package/dist/registry/ai-manager-rules/spec.json +112 -0
  42. package/dist/registry/ai-manager-rules/test.json +98 -0
  43. package/dist/registry/ai-manager-rules/user-survey-phases/phase1-survey-scoping.md +60 -0
  44. package/dist/registry/ai-manager-rules/user-survey-phases/phase2-survey-build-linkedin.md +23 -0
  45. package/dist/registry/ai-manager-rules/user-survey-phases/phase3-survey-build-reddit.md +22 -0
  46. package/dist/registry/ai-manager-rules/user-survey-phases/phase4-survey-build-x.md +21 -0
  47. package/dist/registry/ai-manager-rules/user-survey-phases/phase5-survey-build-facebook.md +19 -0
  48. package/dist/registry/ai-manager-rules/user-survey-phases/phase6-survey-build-custom.md +15 -0
  49. package/dist/registry/ai-manager-rules/user-survey-phases/phase7-survey-dispatch.md +45 -0
  50. package/dist/registry/delivery/address-feedback.md +83 -0
  51. package/dist/registry/delivery/retrospective.md +78 -0
  52. package/dist/registry/delivery/submit.md +79 -0
  53. package/dist/registry/providers/ado.json +19 -0
  54. package/dist/registry/providers/delivery-conversation.json +9 -0
  55. package/dist/registry/providers/delivery-pr.json +9 -0
  56. package/dist/registry/providers/github.json +19 -0
  57. package/dist/registry/rules/agent-success-criteria.md +101 -0
  58. package/dist/registry/rules/agent-testing-guidelines.md +502 -0
  59. package/dist/registry/rules/architecture.md +126 -0
  60. package/dist/registry/rules/communication.md +122 -0
  61. package/dist/registry/rules/continuous-learning.md +55 -0
  62. package/dist/registry/rules/debugging-multitenancy-issues.md +85 -0
  63. package/dist/registry/rules/ephemeral-execution.md +54 -0
  64. package/dist/registry/rules/git-safe-commands.md +34 -0
  65. package/dist/registry/rules/hitl-ppe-record-analysis.md +302 -0
  66. package/dist/registry/rules/integrity-and-test-ethics.md +275 -0
  67. package/dist/registry/rules/local-development.md +275 -0
  68. package/dist/registry/rules/mandatory-pre-completion-reflection.md +193 -0
  69. package/dist/registry/rules/merge-requirements.md +238 -0
  70. package/dist/registry/rules/simplicity.md +118 -0
  71. package/dist/registry/rules/software-development-lifecycle.md +105 -0
  72. package/dist/registry/rules/spike-first-development.md +205 -0
  73. package/dist/registry/rules/successful-debugging-patterns.md +488 -0
  74. package/dist/registry/scripts/build-scripts-generator.js +205 -0
  75. package/dist/registry/scripts/cleanup-branch.js +287 -0
  76. package/dist/registry/scripts/evaluate-code-quality.js +66 -0
  77. package/dist/registry/scripts/exec-with-timeout.js +142 -0
  78. package/dist/registry/scripts/fraim-config.js +61 -0
  79. package/dist/registry/scripts/generate-engagement-emails.js +705 -0
  80. package/dist/registry/scripts/generic-issues-api.js +100 -0
  81. package/dist/registry/scripts/newsletter-helpers.js +671 -0
  82. package/dist/registry/scripts/openapi-generator.js +664 -0
  83. package/dist/registry/scripts/performance/profile-server.js +390 -0
  84. package/dist/registry/scripts/profile-server.js +389 -0
  85. package/dist/registry/scripts/run-thank-you-workflow.js +92 -0
  86. package/dist/registry/scripts/send-newsletter-simple.js +85 -0
  87. package/dist/registry/scripts/send-thank-you-emails.js +54 -0
  88. package/dist/registry/scripts/validate-openapi-limits.js +311 -0
  89. package/dist/registry/scripts/validate-test-coverage.js +262 -0
  90. package/dist/registry/scripts/verify-test-coverage.js +66 -0
  91. package/dist/registry/stubs/workflows/azure/cost-optimization.md +11 -0
  92. package/dist/registry/stubs/workflows/bootstrap/create-architecture.md +11 -0
  93. package/dist/registry/stubs/workflows/bootstrap/detect-broken-windows.md +11 -0
  94. package/dist/registry/stubs/workflows/bootstrap/evaluate-code-quality.md +11 -0
  95. package/dist/registry/stubs/workflows/bootstrap/verify-test-coverage.md +11 -0
  96. package/dist/registry/stubs/workflows/brainstorming/blue-sky-brainstorming.md +11 -0
  97. package/dist/registry/stubs/workflows/brainstorming/codebase-brainstorming.md +11 -0
  98. package/dist/registry/stubs/workflows/business-development/create-business-plan.md +11 -0
  99. package/dist/registry/stubs/workflows/business-development/ideate-business-opportunity.md +11 -0
  100. package/dist/registry/stubs/workflows/business-development/price-product.md +18 -0
  101. package/dist/registry/stubs/workflows/compliance/detect-compliance-requirements.md +11 -0
  102. package/dist/registry/stubs/workflows/compliance/generate-audit-evidence.md +11 -0
  103. package/dist/registry/stubs/workflows/compliance/soc2-evidence-generator.md +11 -0
  104. package/dist/registry/stubs/workflows/customer-development/insight-analysis.md +11 -0
  105. package/dist/registry/stubs/workflows/customer-development/insight-triage.md +11 -0
  106. package/dist/registry/stubs/workflows/customer-development/interview-preparation.md +11 -0
  107. package/dist/registry/stubs/workflows/customer-development/linkedin-outreach.md +11 -0
  108. package/dist/registry/stubs/workflows/customer-development/strategic-brainstorming.md +11 -0
  109. package/dist/registry/stubs/workflows/customer-development/thank-customers.md +11 -0
  110. package/dist/registry/stubs/workflows/customer-development/user-survey-dispatch.md +11 -0
  111. package/dist/registry/stubs/workflows/customer-development/users-to-target.md +11 -0
  112. package/dist/registry/stubs/workflows/customer-development/weekly-newsletter.md +11 -0
  113. package/dist/registry/stubs/workflows/deploy/cloud-deployment.md +11 -0
  114. package/dist/registry/stubs/workflows/improve-fraim/contribute.md +11 -0
  115. package/dist/registry/stubs/workflows/improve-fraim/file-issue.md +11 -0
  116. package/dist/registry/stubs/workflows/learning/build-skillset.md +11 -0
  117. package/dist/registry/stubs/workflows/learning/synthesize-learnings.md +11 -0
  118. package/dist/registry/stubs/workflows/legal/contract-review-analysis.md +11 -0
  119. package/dist/registry/stubs/workflows/legal/nda.md +11 -0
  120. package/dist/registry/stubs/workflows/legal/patent-filing.md +11 -0
  121. package/dist/registry/stubs/workflows/legal/saas-contract-development.md +11 -0
  122. package/dist/registry/stubs/workflows/legal/trademark-filing.md +11 -0
  123. package/dist/registry/stubs/workflows/marketing/content-creation.md +11 -0
  124. package/dist/registry/stubs/workflows/marketing/convert-to-pdf.md +11 -0
  125. package/dist/registry/stubs/workflows/marketing/create-modern-website.md +11 -0
  126. package/dist/registry/stubs/workflows/marketing/domain-registration.md +11 -0
  127. package/dist/registry/stubs/workflows/marketing/evangelize.md +11 -0
  128. package/dist/registry/stubs/workflows/marketing/hbr-article.md +11 -0
  129. package/dist/registry/stubs/workflows/marketing/launch-checklist.md +11 -0
  130. package/dist/registry/stubs/workflows/marketing/marketing-strategy.md +11 -0
  131. package/dist/registry/stubs/workflows/marketing/storytelling.md +11 -0
  132. package/dist/registry/stubs/workflows/performance/analyze-performance.md +11 -0
  133. package/dist/registry/stubs/workflows/product-building/design.md +11 -0
  134. package/dist/registry/stubs/workflows/product-building/implement.md +11 -0
  135. package/dist/registry/stubs/workflows/product-building/iterate-on-pr-comments.md +11 -0
  136. package/dist/registry/stubs/workflows/product-building/prep-issue.md +11 -0
  137. package/dist/registry/stubs/workflows/product-building/prototype.md +11 -0
  138. package/dist/registry/stubs/workflows/product-building/resolve.md +11 -0
  139. package/dist/registry/stubs/workflows/product-building/retrospect.md +11 -0
  140. package/dist/registry/stubs/workflows/product-building/spec.md +11 -0
  141. package/dist/registry/stubs/workflows/product-building/test.md +11 -0
  142. package/dist/registry/stubs/workflows/productivity-report/productivity-report.md +11 -0
  143. package/dist/registry/stubs/workflows/quality-assurance/browser-validation.md +11 -0
  144. package/dist/registry/stubs/workflows/quality-assurance/iterative-improvement-cycle.md +11 -0
  145. package/dist/registry/stubs/workflows/replicate/replicate-discovery.md +11 -0
  146. package/dist/registry/stubs/workflows/replicate/replicate-to-issues.md +11 -0
  147. package/dist/registry/stubs/workflows/reviewer/review-implementation-vs-design-spec.md +11 -0
  148. package/dist/registry/stubs/workflows/reviewer/review-implementation-vs-feature-spec.md +11 -0
  149. package/dist/registry/stubs/workflows/startup-credits/aws-activate-application.md +11 -0
  150. package/dist/registry/stubs/workflows/startup-credits/google-cloud-application.md +11 -0
  151. package/dist/registry/stubs/workflows/startup-credits/microsoft-azure-application.md +11 -0
  152. package/dist/registry/templates/bootstrap/ARCHITECTURE-TEMPLATE.md +53 -0
  153. package/dist/registry/templates/bootstrap/CODE-QUALITY-REPORT-TEMPLATE.md +37 -0
  154. package/dist/registry/templates/bootstrap/TEST-COVERAGE-REPORT-TEMPLATE.md +35 -0
  155. package/dist/registry/templates/business-development/IDEATION-REPORT-TEMPLATE.md +29 -0
  156. package/dist/registry/templates/business-development/PRICING-STRATEGY-TEMPLATE.md +126 -0
  157. package/dist/registry/templates/customer-development/customer-interview-template.md +99 -0
  158. package/dist/registry/templates/customer-development/customer-persona-template.md +69 -0
  159. package/dist/registry/templates/customer-development/follow-up-email-templates.md +132 -0
  160. package/dist/registry/templates/customer-development/insight-analysis-template.md +74 -0
  161. package/dist/registry/templates/customer-development/prospect-inventory-template.csv +3 -0
  162. package/dist/registry/templates/customer-development/search-strategy-template.md +123 -0
  163. package/dist/registry/templates/customer-development/strategic-recommendations-template.md +53 -0
  164. package/dist/registry/templates/customer-development/thank-you-email-template.html +124 -0
  165. package/dist/registry/templates/customer-development/thank-you-note-template.md +16 -0
  166. package/dist/registry/templates/customer-development/triage-log-template.md +278 -0
  167. package/dist/registry/templates/customer-development/weekly-newsletter-template.html +204 -0
  168. package/dist/registry/templates/evidence/Design-Evidence.md +30 -0
  169. package/dist/registry/templates/evidence/Implementation-BugEvidence.md +122 -0
  170. package/dist/registry/templates/evidence/Implementation-FeatureEvidence.md +160 -0
  171. package/dist/registry/templates/evidence/Spec-Evidence.md +19 -0
  172. package/dist/registry/templates/help/HelpNeeded.md +14 -0
  173. package/dist/registry/templates/legal/NDA-TEMPLATE.md +170 -0
  174. package/dist/registry/templates/legal/PATENT-TEMPLATE.md +372 -0
  175. package/dist/registry/templates/legal/TRADEMARK-TEMPLATE.md +339 -0
  176. package/dist/registry/templates/legal/contract-review-checklist.md +193 -0
  177. package/dist/registry/templates/legal/review-report-template.md +198 -0
  178. package/dist/registry/templates/legal/saas-terms-template.md +174 -0
  179. package/dist/registry/templates/legal/sow-template.md +117 -0
  180. package/dist/registry/templates/legal/template-variables.md +131 -0
  181. package/dist/registry/templates/marketing/DOMAIN-REGISTRATION-TEMPLATE.md +194 -0
  182. package/dist/registry/templates/marketing/EVANGELIZE-TEMPLATE.md +102 -0
  183. package/dist/registry/templates/marketing/HBR-ARTICLE-TEMPLATE.md +66 -0
  184. package/dist/registry/templates/marketing/STORYTELLING-TEMPLATE.md +130 -0
  185. package/dist/registry/templates/marketing/WEBSITE-TEMPLATE.md +262 -0
  186. package/dist/registry/templates/marketing/github-pages-workflow.yml +64 -0
  187. package/dist/registry/templates/replicate/implementation-checklist.md +39 -0
  188. package/dist/registry/templates/replicate/use-cases-template.md +88 -0
  189. package/dist/registry/templates/retrospective/RETROSPECTIVE-TEMPLATE.md +55 -0
  190. package/dist/registry/templates/specs/BUGSPEC-TEMPLATE.md +37 -0
  191. package/dist/registry/templates/specs/FEATURESPEC-TEMPLATE.md +66 -0
  192. package/dist/registry/templates/specs/TECHSPEC-TEMPLATE.md +39 -0
  193. package/dist/registry/workflows/azure/cost-optimization.md +772 -0
  194. package/dist/registry/workflows/bootstrap/create-architecture.md +37 -0
  195. package/dist/registry/workflows/bootstrap/detect-broken-windows.md +300 -0
  196. package/dist/registry/workflows/bootstrap/evaluate-code-quality.md +35 -0
  197. package/dist/registry/workflows/bootstrap/verify-test-coverage.md +36 -0
  198. package/dist/registry/workflows/brainstorming/blue-sky-brainstorming.md +211 -0
  199. package/dist/registry/workflows/brainstorming/codebase-brainstorming.md +159 -0
  200. package/dist/registry/workflows/business-development/create-business-plan.md +737 -0
  201. package/dist/registry/workflows/business-development/ideate-business-opportunity.md +55 -0
  202. package/dist/registry/workflows/business-development/price-product.md +325 -0
  203. package/dist/registry/workflows/compliance/detect-compliance-requirements.md +80 -0
  204. package/dist/registry/workflows/compliance/generate-audit-evidence.md +80 -0
  205. package/dist/registry/workflows/compliance/soc2-evidence-generator.md +332 -0
  206. package/dist/registry/workflows/customer-development/insight-analysis.md +156 -0
  207. package/dist/registry/workflows/customer-development/insight-triage.md +933 -0
  208. package/dist/registry/workflows/customer-development/interview-preparation.md +452 -0
  209. package/dist/registry/workflows/customer-development/linkedin-outreach.md +599 -0
  210. package/dist/registry/workflows/customer-development/strategic-brainstorming.md +146 -0
  211. package/dist/registry/workflows/customer-development/thank-customers.md +203 -0
  212. package/dist/registry/workflows/customer-development/user-survey-dispatch.md +312 -0
  213. package/dist/registry/workflows/customer-development/users-to-target.md +427 -0
  214. package/dist/registry/workflows/customer-development/weekly-newsletter.md +366 -0
  215. package/dist/registry/workflows/deploy/cloud-deployment.md +310 -0
  216. package/dist/registry/workflows/improve-fraim/contribute.md +32 -0
  217. package/dist/registry/workflows/improve-fraim/file-issue.md +32 -0
  218. package/dist/registry/workflows/learning/build-skillset.md +212 -0
  219. package/dist/registry/workflows/learning/synthesize-learnings.md +369 -0
  220. package/dist/registry/workflows/legal/contract-review-analysis.md +382 -0
  221. package/dist/registry/workflows/legal/nda.md +69 -0
  222. package/dist/registry/workflows/legal/patent-filing.md +76 -0
  223. package/dist/registry/workflows/legal/saas-contract-development.md +204 -0
  224. package/dist/registry/workflows/legal/trademark-filing.md +77 -0
  225. package/dist/registry/workflows/marketing/content-creation.md +40 -0
  226. package/dist/registry/workflows/marketing/convert-to-pdf.md +265 -0
  227. package/dist/registry/workflows/marketing/create-modern-website.md +456 -0
  228. package/dist/registry/workflows/marketing/domain-registration.md +323 -0
  229. package/dist/registry/workflows/marketing/evangelize.md +426 -0
  230. package/dist/registry/workflows/marketing/hbr-article.md +73 -0
  231. package/dist/registry/workflows/marketing/launch-checklist.md +37 -0
  232. package/dist/registry/workflows/marketing/marketing-strategy.md +45 -0
  233. package/dist/registry/workflows/marketing/storytelling.md +65 -0
  234. package/dist/registry/workflows/performance/analyze-performance.md +65 -0
  235. package/dist/registry/workflows/product-building/design.md +263 -0
  236. package/dist/registry/workflows/product-building/implement.md +771 -0
  237. package/dist/registry/workflows/product-building/iterate-on-pr-comments.md +70 -0
  238. package/dist/registry/workflows/product-building/prep-issue.md +41 -0
  239. package/dist/registry/workflows/product-building/prototype.md +60 -0
  240. package/dist/registry/workflows/product-building/resolve.md +175 -0
  241. package/dist/registry/workflows/product-building/retrospect.md +86 -0
  242. package/dist/registry/workflows/product-building/spec.md +303 -0
  243. package/dist/registry/workflows/product-building/test.md +125 -0
  244. package/dist/registry/workflows/productivity-report/productivity-report.md +263 -0
  245. package/dist/registry/workflows/quality-assurance/browser-validation.md +221 -0
  246. package/dist/registry/workflows/quality-assurance/iterative-improvement-cycle.md +562 -0
  247. package/dist/registry/workflows/replicate/replicate-discovery.md +336 -0
  248. package/dist/registry/workflows/replicate/replicate-to-issues.md +319 -0
  249. package/dist/registry/workflows/reviewer/review-implementation-vs-design-spec.md +694 -0
  250. package/dist/registry/workflows/reviewer/review-implementation-vs-feature-spec.md +734 -0
  251. package/dist/registry/workflows/startup-credits/aws-activate-application.md +535 -0
  252. package/dist/registry/workflows/startup-credits/google-cloud-application.md +647 -0
  253. package/dist/registry/workflows/startup-credits/microsoft-azure-application.md +538 -0
  254. package/package.json +2 -1
@@ -0,0 +1,304 @@
1
+ # Phase: Quality Review
2
+
3
+ ## INTENT
4
+ To perform final quality checks ensuring all design aspects are implemented, code quality standards are met, and the work is production-ready.
5
+
6
+ ## OUTCOME
7
+ Confirmation that:
8
+ - All design aspects implemented
9
+ - Code compiles without errors
10
+ - All tests pass
11
+ - Code quality standards met
12
+ - No debugging code remains
13
+ - Git status is clean
14
+
15
+ ## RULES FOR THIS PHASE
16
+
17
+ ### Success Criteria
18
+ Read `registry/rules/agent-success-criteria.md` via `get_fraim_file` for the complete framework. This phase tests ALL criteria:
19
+ - **Integrity** (truthful reporting of all validation results)
20
+ - **Correctness** (code compiles, tests pass, follows architecture)
21
+ - **Completeness** (all requirements implemented, all validation steps completed)
22
+ - **Independence** (thorough self-validation without asking user)
23
+ - **Speed** (efficient validation process)
24
+
25
+ ### Simplicity Principles
26
+ Read `registry/rules/simplicity.md` via `get_fraim_file` for complete guidelines. Key for quality review:
27
+ - **Focus on the assigned issue only** - ensure no unrelated changes
28
+ - **Manual Validation Required** - verify implementation works as expected
29
+ - **Resource Waste Prevention** - efficient validation process
30
+
31
+ ### Architecture Compliance
32
+ Read `.fraim/config.json` for the architecture document path (`customizations.architectureDoc`), then use `get_fraim_file` to read the full architecture guidelines. Verify all architectural standards are met.
33
+
34
+ ### Git Operations (if needed)
35
+ When using git commands directly (if MCP tools unavailable), read `registry/rules/git-safe-commands.md` via `get_fraim_file` to avoid interactive commands that hang agents.
36
+
37
+ ## PRINCIPLES
38
+ - **Comprehensive**: Check all quality dimensions
39
+ - **Standards Compliance**: Follow all coding standards
40
+ - **Production Ready**: Code is ready for deployment
41
+ - **Clean State**: No temporary code or artifacts
42
+
43
+ ## WORKFLOW
44
+
45
+ ### Step 1: TypeScript Compilation Check
46
+ ```bash
47
+ npx tsc --noEmit --skipLibCheck
48
+ ```
49
+
50
+ **Must exit with code 0** (no errors)
51
+
52
+ If compilation fails:
53
+ - Review errors carefully
54
+ - Fix type issues
55
+ - Re-compile to verify
56
+ - Return to implement phase if major issues found
57
+
58
+ ### Step 2: Build Verification
59
+ ```bash
60
+ npm run build
61
+ ```
62
+
63
+ **Must complete successfully:**
64
+ - No build errors
65
+ - All validation steps pass
66
+ - Build artifacts created
67
+
68
+ If build fails:
69
+ - Check build output for specific errors
70
+ - Fix issues found
71
+ - Re-run build to verify
72
+
73
+ ### Step 3: Complete Test Suite
74
+ ```bash
75
+ npm test
76
+ ```
77
+
78
+ **All tests must pass:**
79
+ - No failures (0 failed tests)
80
+ - No timeouts
81
+ - No skipped tests (unless intentional)
82
+
83
+ **Additional test commands:**
84
+ ```bash
85
+ # Run smoke tests
86
+ npm run test-smoke-ci
87
+
88
+ # Run all tests in CI mode
89
+ npm run test-all-ci
90
+ ```
91
+
92
+ If tests fail:
93
+ - Review failure output
94
+ - Fix failing tests
95
+ - Return to appropriate phase if needed
96
+
97
+ ### Step 4: Code Quality Verification
98
+
99
+ **Check for type bypassing:**
100
+ ```bash
101
+ grep -r "as any" src/ || echo "✅ No type bypassing found"
102
+ ```
103
+ **Must find zero instances** (or only justified ones with comments)
104
+
105
+ **Check for debugging code:**
106
+ ```bash
107
+ grep -r "console.log" src/ | grep -v "// OK" | grep -v "logger" || echo "✅ No debug logs found"
108
+ ```
109
+ **Should find zero or only intentional logging**
110
+
111
+ **Check for TODO comments:**
112
+ ```bash
113
+ grep -r "TODO" src/ || echo "✅ No TODOs found"
114
+ ```
115
+ **Core functionality should have no TODOs**
116
+
117
+ **Validate registry paths:**
118
+ ```bash
119
+ npm run validate:registry
120
+ ```
121
+ **Must pass without errors**
122
+
123
+ ### Step 5: Git Status Verification
124
+ ```bash
125
+ git status
126
+ ```
127
+
128
+ **Should show:**
129
+ - Only intended changes
130
+ - No untracked files (except evidence docs)
131
+ - No accidentally modified files
132
+ - Clean working directory
133
+
134
+ **Check recent commits:**
135
+ ```bash
136
+ git log --oneline -5
137
+ ```
138
+ **Verify commits are meaningful and related to the issue**
139
+
140
+ ### Step 6: Design Completeness Check (Features)
141
+
142
+ For features, verify all design aspects implemented:
143
+
144
+ **API Contracts:**
145
+ ```bash
146
+ # Test all API endpoints mentioned in spec
147
+ curl -X GET http://localhost:3000/api/endpoint1
148
+ curl -X POST http://localhost:3000/api/endpoint2 -d '{"test":"data"}'
149
+ ```
150
+
151
+ **Data Models:**
152
+ - Check database schemas match design
153
+ - Verify data validation rules
154
+ - Test data persistence
155
+
156
+ **User Interfaces:**
157
+ - All UI components from design implemented
158
+ - Responsive behavior works
159
+ - Error states handled
160
+
161
+ **Integration Points:**
162
+ - External API integrations work
163
+ - Internal service communication works
164
+ - Authentication/authorization implemented
165
+
166
+ ### Step 7: Bug Fix Verification (Bugs)
167
+
168
+ For bugs, verify:
169
+
170
+ **Minimal Changes:**
171
+ ```bash
172
+ git diff HEAD~1 --stat
173
+ ```
174
+ **Should show focused, minimal changes**
175
+
176
+ **Root Cause Addressed:**
177
+ - Review the fix against original bug report
178
+ - Ensure fix addresses cause, not just symptoms
179
+ - Verify no new issues introduced
180
+
181
+ **Regression Testing:**
182
+ ```bash
183
+ # Run tests related to the bug area
184
+ npm test -- --grep "related-functionality"
185
+ ```
186
+
187
+ ### Step 8: Comprehensive Health Check
188
+
189
+ **One-liner health check:**
190
+ ```bash
191
+ npx tsc --noEmit --skipLibCheck && npm test && git status
192
+ ```
193
+
194
+ **Full validation suite:**
195
+ ```bash
196
+ npm run build && npm run test-all-ci && npm run validate:registry
197
+ ```
198
+
199
+ **API health check (if applicable):**
200
+ ```bash
201
+ curl -f http://localhost:3000/health && echo "✅ API healthy"
202
+ ```
203
+
204
+ ### Step 9: Mandatory Pre-Completion Reflection
205
+
206
+ **🚨 CRITICAL - Minimum 10 minutes required**
207
+
208
+ Read and complete reflection from `rules/mandatory-pre-completion-reflection.md` via `get_fraim_file`:
209
+
210
+ **Phase 1: Claim Verification (3 min)**
211
+ - What am I claiming works?
212
+ - What evidence do I have?
213
+ - Have I actually tested these claims?
214
+ - Are ALL tests passing (100%)?
215
+ - Have I investigated every error in the logs?
216
+
217
+ **Phase 2: Risk Analysis (3 min)**
218
+ - What could go wrong?
219
+ - What didn't I test?
220
+ - What edge cases might exist?
221
+ - What would a user experience if they tried this?
222
+
223
+ **Phase 3: Validation Plan Check (2 min)**
224
+ - Do I cover all spec scenarios?
225
+ - Are there gaps in my testing?
226
+ - Did I validate manually?
227
+ - Would I ship this to customers right now?
228
+ - Would I bet money this works end-to-end?
229
+
230
+ **Phase 4: Self-Audit (2 min)**
231
+ - Did I follow all rules?
232
+ - Would I bet money this works?
233
+ - Am I being honest about status?
234
+ - Am I rushing to claim completion?
235
+
236
+ **Document reflection analysis and address any blockers identified.**
237
+
238
+ ## VALIDATION
239
+
240
+ ### Phase Complete When:
241
+ - ✅ TypeScript compiles (exit code 0)
242
+ - ✅ All tests pass
243
+ - ✅ No "as any" type bypassing
244
+ - ✅ No debugging code remains
245
+ - ✅ Git status clean
246
+ - ✅ (Features) All design aspects implemented
247
+ - ✅ (Bugs) Changes minimal and focused
248
+ - ✅ (If applicable) Design feedback addressed
249
+ - ✅ Test integrity verified (no modified test criteria)
250
+ - ✅ Mandatory reflection completed
251
+ - ✅ All reflection blockers addressed
252
+
253
+ ### Phase Incomplete If:
254
+ - ❌ TypeScript compilation errors
255
+ - ❌ Any tests fail
256
+ - ❌ Code quality issues found
257
+ - ❌ Design aspects incomplete
258
+ - ❌ Unintended changes in git
259
+ - ❌ Design feedback not addressed
260
+ - ❌ Test criteria were modified without approval
261
+ - ❌ Reflection not completed
262
+ - ❌ Reflection identified unaddressed blockers
263
+
264
+ **Full quality check:**
265
+ ```bash
266
+ npx tsc --noEmit --skipLibCheck && npm test && grep -r "as any" src/ && git status
267
+ ```
268
+
269
+ ### Report Back:
270
+ When you complete this phase, call:
271
+
272
+ ```javascript
273
+ seekCoachingOnNextStep({
274
+ workflowType: "implement",
275
+ issueNumber: "{issue_number}",
276
+ currentPhase: "quality-review",
277
+ status: "complete",
278
+ evidence: {
279
+ typescriptCompiles: "YES", // Did `npx tsc --noEmit --skipLibCheck` succeed?
280
+ buildSucceeds: "YES", // Did `npm run build` succeed?
281
+ allTestsPass: "YES", // Did `npm test` show 100% pass rate?
282
+ noTypeBypass: "YES", // Did `grep -r "as any" src/` find zero instances?
283
+ noDebugCode: "YES", // Did you remove console.log statements?
284
+ gitStatusClean: "YES", // Does `git status` show only intended changes?
285
+ designComplete: "YES", // (Features) All design aspects implemented?
286
+ changesMinimal: "YES", // (Bugs) Changes are focused and minimal?
287
+ reflectionDone: "YES", // Did you complete the mandatory reflection?
288
+ commandsRun: "npx tsc --noEmit --skipLibCheck && npm run build && npm test && git status",
289
+ summary: "All quality checks passed. TypeScript compiles clean, all tests pass, git status clean, reflection completed."
290
+ },
291
+ iterationCount: 1
292
+ })
293
+ ```
294
+
295
+ ## QUALITY STANDARDS
296
+ Read `.fraim/config.json` for the architecture document path (`customizations.architectureDoc`), then use `get_fraim_file` to read the full quality standards. Key requirements include:
297
+ - No 'as any' type bypassing
298
+ - Proper error handling
299
+ - Consistent code style
300
+ - Meaningful variable names
301
+ - Appropriate code comments
302
+ - Tests follow architecture standards
303
+ - Tests validate real functionality
304
+ - No tests that default to passing
@@ -0,0 +1,159 @@
1
+ # Phase: Regression
2
+
3
+ ## INTENT
4
+ For bugs: Verify the repro test now passes. For features: Write comprehensive regression tests to prevent future breakage.
5
+
6
+ ## OUTCOME
7
+ **For Bugs:**
8
+ - Repro test from repro phase now PASSES
9
+ - Bug is confirmed fixed
10
+ - Test serves as regression protection
11
+
12
+ **For Features:**
13
+ - New regression tests written
14
+ - All key functionality covered
15
+ - Tests verify acceptance criteria
16
+ - All tests pass
17
+
18
+ ## PRINCIPLES
19
+ - **Test Quality**: Write meaningful tests, not checkbox tests
20
+ - **Coverage**: Test main scenarios and edge cases
21
+ - **Real Testing**: Test actual functionality, not mocks
22
+ - **Maintainable**: Tests should be clear and maintainable
23
+
24
+ ## WORKFLOW
25
+
26
+ ### For Bug Fixes:
27
+
28
+ #### Step 1: Run Repro Test
29
+ ```bash
30
+ npm test -- path/to/repro/test.test.ts
31
+ ```
32
+
33
+ #### Step 2: Verify Test Passes
34
+ - Test should now PASS (was failing in repro phase)
35
+ - Confirms bug is fixed
36
+ - Test serves as regression protection
37
+
38
+ #### Step 3: If Test Still Fails
39
+ **Return to implement phase:**
40
+ - Bug is not actually fixed
41
+ - Review the fix
42
+ - Debug why test still fails
43
+ - Fix and re-validate
44
+
45
+ ### For Features:
46
+
47
+ #### Step 1: Identify Test Coverage Needed
48
+ Based on acceptance criteria:
49
+ - Main user scenarios
50
+ - Edge cases
51
+ - Error conditions
52
+ - Integration points
53
+
54
+ #### Step 2: Write Regression Tests
55
+ - Create tests for all key functionality
56
+ - Test main user workflows
57
+ - Cover edge cases
58
+ - Test error handling
59
+
60
+ #### Step 3: Follow Test Architecture
61
+ Read `.fraim/config.json` for the architecture document path (`customizations.architectureDoc`), then use `get_fraim_file` to read the full architecture guidelines. Key requirements:
62
+ - Use shared-server-utils.ts
63
+ - Unique API keys per test
64
+ - Proper cleanup in finally blocks
65
+ - No individual server instances
66
+ - Proper timeouts (5-10s for network calls)
67
+
68
+ #### Step 4: Run All New Tests
69
+ ```bash
70
+ npm test -- path/to/new/tests.test.ts
71
+ ```
72
+
73
+ Verify all tests pass
74
+
75
+ #### Step 5: Tag Tests Appropriately
76
+ - `smoke`: If testing core functionality
77
+ - `integration`: If testing multiple components
78
+ - `unit`: If testing individual functions
79
+ - `e2e`: If testing complete workflows
80
+
81
+ ## VALIDATION
82
+
83
+ ### Phase Complete When (Bugs):
84
+ - ✅ Repro test now PASSES
85
+ - ✅ Bug confirmed fixed
86
+ - ✅ Test output documented
87
+
88
+ ### Phase Complete When (Features):
89
+ - ✅ Regression tests written
90
+ - ✅ All acceptance criteria covered
91
+ - ✅ Tests follow architecture standards
92
+ - ✅ All tests pass
93
+ - ✅ Tests appropriately tagged
94
+
95
+ ### Phase Incomplete If:
96
+ - ❌ (Bugs) Repro test still fails
97
+ - ❌ (Features) No regression tests written
98
+ - ❌ (Features) Tests don't cover acceptance criteria
99
+ - ❌ Any tests fail
100
+ - ❌ Tests violate architecture standards
101
+
102
+ ## RULES FOR THIS PHASE
103
+ - Read `.fraim/config.json` for the architecture document path (`customizations.architectureDoc`), then use `get_fraim_file` to read the full test architecture guidelines
104
+ - Follow test requirements from the implement workflow (use `get_fraim_file({ path: "workflows/product-building/implement.md" })`)
105
+ - Use Successful Debugging Patterns from `rules/successful-debugging-patterns.md` via `get_fraim_file`
106
+ - Follow Git Safe Commands from `rules/git-safe-commands.md` via `get_fraim_file`
107
+
108
+ ## TEST QUALITY REQUIREMENTS
109
+ - Tests must validate real functionality, not mocked behavior
110
+ - No tests that default to passing without validation
111
+ - Use flow testing, not just static analysis
112
+ - Tests should fail if code is broken
113
+
114
+ ## SCRIPTS
115
+
116
+ **Run tests:**
117
+ ```bash
118
+ npm test -- path/to/test.test.ts
119
+ ```
120
+
121
+ **Run all tests:**
122
+ ```bash
123
+ npm test
124
+ ```
125
+
126
+ ### Report Back (Bugs):
127
+ When you complete this phase for a bug fix, call:
128
+
129
+ ```javascript
130
+ seekCoachingOnNextStep({
131
+ workflowType: "implement",
132
+ issueNumber: "{issue_number}",
133
+ currentPhase: "regression",
134
+ status: "complete",
135
+ evidence: {
136
+ reproTestResult: "Repro test at test/sync.test.ts:45 now PASSES",
137
+ bugStatus: "Bug confirmed fixed",
138
+ regressionProtection: "Test serves as regression protection"
139
+ }
140
+ })
141
+ ```
142
+
143
+ ### Report Back (Features):
144
+ When you complete this phase for a feature, call:
145
+
146
+ ```javascript
147
+ seekCoachingOnNextStep({
148
+ workflowType: "implement",
149
+ issueNumber: "{issue_number}",
150
+ currentPhase: "regression",
151
+ status: "complete",
152
+ evidence: {
153
+ testLocation: "test/auth.test.ts",
154
+ testCoverage: "All acceptance criteria covered",
155
+ testResults: "8/8 tests passing",
156
+ testTags: "Tagged as integration"
157
+ }
158
+ })
159
+ ```
@@ -0,0 +1,101 @@
1
+ # Phase: Repro (Bug Fixes Only)
2
+
3
+ ## INTENT
4
+ To create a failing test that reproduces the reported bug, demonstrating that the issue exists and providing a clear success criterion for the fix.
5
+
6
+ ## OUTCOME
7
+ A test that:
8
+ - **FAILS** when run, reproducing the bug
9
+ - Clearly demonstrates the incorrect behavior
10
+ - Will pass once the bug is fixed
11
+ - Serves as a regression test
12
+
13
+ ## PRINCIPLES
14
+ - **Test-First**: Create the failing test before fixing
15
+ - **Actual Reproduction**: Use real reproduction, not hypothetical scenarios
16
+ - **Clear Failure**: Test should fail obviously and consistently
17
+ - **No Assumptions**: If reproduction steps are unclear, escalate to user
18
+ - **Minimal Test**: Focus on reproducing the specific bug
19
+
20
+ ## WORKFLOW
21
+
22
+ ### Step 1: Review Bug Spec
23
+ - Read the bug description thoroughly
24
+ - Note the reproduction steps
25
+ - Understand the expected vs actual behavior
26
+ - Identify the failure conditions
27
+
28
+ ### Step 2: Check Reproduction Steps
29
+ **If reproduction steps are clear:**
30
+ - Proceed to create test
31
+
32
+ **If reproduction steps are unclear or missing:**
33
+ - **DO NOT** hypothesize about the issue
34
+ - **ESCALATE** to user with specific questions:
35
+ - What exact steps trigger the bug?
36
+ - What is the expected behavior?
37
+ - What is the actual (incorrect) behavior?
38
+ - Are there specific inputs or conditions?
39
+
40
+ ### Step 3: Create Failing Test
41
+ - Choose appropriate test file location
42
+ - Write test that follows reproduction steps
43
+ - Test should demonstrate the bug clearly
44
+ - Use descriptive test name: `test: reproduces bug #{issue_number} - {description}`
45
+
46
+ ### Step 4: Run the Test
47
+ - Execute the test
48
+ - **Verify it FAILS** as expected
49
+ - Capture the failure output
50
+ - Confirm it fails for the right reason (reproducing the bug, not test errors)
51
+
52
+ ### Step 5: Document Test Location
53
+ In your evidence, include:
54
+ - Path to the test file
55
+ - Test name/description
56
+ - Failure output showing the bug
57
+ - Confirmation that test reproduces the issue
58
+
59
+ ## VALIDATION
60
+
61
+ ### Phase Complete When:
62
+ - ✅ Test created that reproduces the bug
63
+ - ✅ Test FAILS when run
64
+ - ✅ Failure clearly demonstrates the bug
65
+ - ✅ Test will pass once bug is fixed
66
+ - ✅ Test location documented
67
+
68
+ ### Phase Incomplete If:
69
+ - ❌ Test passes (not reproducing the bug)
70
+ - ❌ Test fails for wrong reason (test error, not bug)
71
+ - ❌ Reproduction steps were unclear and not escalated
72
+ - ❌ Test is hypothetical, not based on actual reproduction
73
+
74
+ ## RULES FOR THIS PHASE
75
+ - Read `.fraim/config.json` for the architecture document path (`customizations.architectureDoc`), then use `get_fraim_file` to read the full test architecture standards
76
+ - Use Successful Debugging Patterns from `rules/successful-debugging-patterns.md` via `get_fraim_file`
77
+ - Follow Git Safe Commands from `rules/git-safe-commands.md` via `get_fraim_file`
78
+
79
+ ## SCRIPTS
80
+ Run test:
81
+ ```bash
82
+ npm test -- path/to/test/file.test.ts
83
+ ```
84
+
85
+ ### Report Back:
86
+ When you complete this phase, call:
87
+
88
+ ```javascript
89
+ seekCoachingOnNextStep({
90
+ workflowType: "implement",
91
+ issueNumber: "{issue_number}",
92
+ currentPhase: "repro",
93
+ status: "complete",
94
+ evidence: {
95
+ testLocation: "test/sync.test.ts:45",
96
+ testResult: "FAILS with timeout after 30s",
97
+ reproductionConfirmed: true,
98
+ testOutput: "Include actual test failure output here"
99
+ }
100
+ })
101
+ ```
@@ -0,0 +1,93 @@
1
+ # Phase: Scoping
2
+
3
+ ## INTENT
4
+ To understand the issue requirements and determine whether it's a bug fix or feature implementation.
5
+
6
+ ## OUTCOME
7
+ Clear understanding of:
8
+ - Issue type (bug or feature)
9
+ - All requirements and acceptance criteria
10
+ - Ready to proceed to next phase (repro for bugs, spike for features)
11
+
12
+ ## PRINCIPLES
13
+ - **Thorough Understanding**: Read all linked documents and context
14
+ - **Clear Classification**: Accurately determine bug vs feature
15
+ - **Question Early**: Escalate if requirements are unclear
16
+
17
+ ## RULES FOR THIS PHASE
18
+
19
+ ### Success Criteria
20
+ Read `registry/rules/agent-success-criteria.md` via `get_fraim_file` for the complete 5-criteria success framework. Focus especially on **Integrity** (truthfulness in reporting) and **Independence** (smart decision making).
21
+
22
+ ### Simplicity Principles
23
+ Read `registry/rules/simplicity.md` via `get_fraim_file` for complete guidelines. Key principles for scoping:
24
+ - **Focus on the assigned issue only** - don't scope other issues
25
+ - **Don't over-think it** - understand the specific need being addressed
26
+
27
+ ### Architecture Compliance
28
+ Read `.fraim/config.json` for the architecture document path (`customizations.architectureDoc`), then use `get_fraim_file` to read the full architecture guidelines. Understanding the architecture helps with proper scoping.
29
+
30
+ ## WORKFLOW
31
+
32
+ ### Step 1: Read Issue Description
33
+ - Read the full issue description in GitHub (use MCP where available)
34
+ - Note the issue title, labels, and any linked documents
35
+ - Identify if there's a spec, RFC, or design document
36
+
37
+ ### Step 2: Review Linked Documents
38
+ - If spec/RFC exists: Read it thoroughly
39
+ - If design document exists: Review the technical approach
40
+ - Note all acceptance criteria and requirements
41
+
42
+ ### Step 3: Determine Issue Type
43
+ **Bug indicators:**
44
+ - Issue describes broken/incorrect behavior
45
+ - References a regression or failure
46
+ - Has reproduction steps
47
+ - Reports unexpected behavior
48
+
49
+ **Feature indicators:**
50
+ - Issue describes new functionality
51
+ - Adds capabilities that don't exist
52
+ - Enhances existing features
53
+ - Has acceptance criteria for new behavior
54
+
55
+ ### Step 4: Understand Requirements
56
+ - List all acceptance criteria
57
+ - Identify edge cases mentioned
58
+ - Note any constraints or limitations
59
+ - Understand success criteria
60
+
61
+ ### Step 5: Identify Uncertainties
62
+ If anything is unclear:
63
+ - **DO NOT** make assumptions
64
+ - **DO NOT** hypothesize requirements
65
+ - **ESCALATE** to user with specific questions
66
+ - Wait for clarification before proceeding
67
+
68
+ ## VALIDATION
69
+
70
+ ### Phase Complete When:
71
+ - ✅ Issue type determined (bug or feature)
72
+ - ✅ All requirements understood
73
+ - ✅ No blocking uncertainties remain
74
+ - ✅ Ready to proceed to next phase
75
+
76
+ ### Report Back:
77
+ When you complete scoping, call:
78
+
79
+ ```javascript
80
+ seekCoachingOnNextStep({
81
+ workflowType: "implement",
82
+ issueNumber: "{issue_number}",
83
+ currentPhase: "scoping",
84
+ status: "complete",
85
+ findings: {
86
+ issueType: "bug", // or "feature"
87
+ requirements: "Brief summary of what you understood",
88
+ uncertainties: [] // List any unclear aspects, or empty array if none
89
+ }
90
+ })
91
+ ```
92
+
93
+ The AI Coach will provide instructions for your next phase based on the issue type you determined.