fraim-framework 2.0.56 → 2.0.58

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 (224) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/bin/fraim-mcp.js +14 -0
  3. package/bin/fraim.js +23 -0
  4. package/dist/src/cli/commands/init-project.js +10 -4
  5. package/dist/src/cli/commands/mcp.js +65 -0
  6. package/dist/src/cli/setup/mcp-config-generator.js +19 -16
  7. package/dist/src/fraim/issue-tracking/ado-provider.js +304 -0
  8. package/dist/src/fraim/issue-tracking/factory.js +63 -0
  9. package/dist/src/fraim/issue-tracking/github-provider.js +200 -0
  10. package/dist/src/fraim/issue-tracking/types.js +7 -0
  11. package/dist/src/fraim/issue-tracking-config.js +83 -0
  12. package/dist/src/local-mcp-server/stdio-server.js +207 -0
  13. package/dist/src/utils/workflow-parser.js +81 -0
  14. package/package.json +17 -12
  15. package/registry/scripts/pdf-styles.css +172 -0
  16. package/registry/scripts/prep-issue.sh +46 -4
  17. package/registry/scripts/profile-server.ts +131 -130
  18. package/registry/stubs/workflows/customer-development/user-survey-dispatch.md +1 -1
  19. package/registry/stubs/workflows/customer-development/users-to-target.md +1 -1
  20. package/registry/stubs/workflows/product-building/design.md +1 -1
  21. package/registry/stubs/workflows/product-building/implement.md +1 -1
  22. package/Claude.md +0 -1
  23. package/dist/registry/ai-manager-rules/customer-development-phases/phase1-customer-profiling.md +0 -101
  24. package/dist/registry/ai-manager-rules/customer-development-phases/phase2-platform-discovery.md +0 -235
  25. package/dist/registry/ai-manager-rules/customer-development-phases/phase3-prospect-qualification.md +0 -243
  26. package/dist/registry/ai-manager-rules/customer-development-phases/phase4-inventory-compilation.md +0 -206
  27. package/dist/registry/ai-manager-rules/design-phases/design-completeness-review.md +0 -73
  28. package/dist/registry/ai-manager-rules/design-phases/design-design.md +0 -145
  29. package/dist/registry/ai-manager-rules/implement-phases/implement-code.md +0 -283
  30. package/dist/registry/ai-manager-rules/implement-phases/implement-completeness-review.md +0 -120
  31. package/dist/registry/ai-manager-rules/implement-phases/implement-regression.md +0 -173
  32. package/dist/registry/ai-manager-rules/implement-phases/implement-repro.md +0 -104
  33. package/dist/registry/ai-manager-rules/implement-phases/implement-scoping.md +0 -100
  34. package/dist/registry/ai-manager-rules/implement-phases/implement-smoke.md +0 -237
  35. package/dist/registry/ai-manager-rules/implement-phases/implement-spike.md +0 -121
  36. package/dist/registry/ai-manager-rules/implement-phases/implement-validate.md +0 -375
  37. package/dist/registry/ai-manager-rules/retrospective.md +0 -116
  38. package/dist/registry/ai-manager-rules/shared-phases/address-pr-feedback.md +0 -188
  39. package/dist/registry/ai-manager-rules/shared-phases/submit-pr.md +0 -202
  40. package/dist/registry/ai-manager-rules/shared-phases/wait-for-pr-review.md +0 -170
  41. package/dist/registry/ai-manager-rules/spec-phases/spec-competitor-analysis.md +0 -105
  42. package/dist/registry/ai-manager-rules/spec-phases/spec-completeness-review.md +0 -66
  43. package/dist/registry/ai-manager-rules/spec-phases/spec-spec.md +0 -139
  44. package/dist/registry/ai-manager-rules/user-survey-phases/phase1-survey-scoping.md +0 -60
  45. package/dist/registry/ai-manager-rules/user-survey-phases/phase2-survey-build-linkedin.md +0 -23
  46. package/dist/registry/ai-manager-rules/user-survey-phases/phase3-survey-build-reddit.md +0 -22
  47. package/dist/registry/ai-manager-rules/user-survey-phases/phase4-survey-build-x.md +0 -21
  48. package/dist/registry/ai-manager-rules/user-survey-phases/phase5-survey-build-facebook.md +0 -19
  49. package/dist/registry/ai-manager-rules/user-survey-phases/phase6-survey-build-custom.md +0 -15
  50. package/dist/registry/ai-manager-rules/user-survey-phases/phase7-survey-dispatch.md +0 -45
  51. package/dist/registry/providers/ado.json +0 -19
  52. package/dist/registry/providers/github.json +0 -19
  53. package/dist/registry/scripts/cleanup-branch.js +0 -287
  54. package/dist/registry/scripts/evaluate-code-quality.js +0 -66
  55. package/dist/registry/scripts/exec-with-timeout.js +0 -142
  56. package/dist/registry/scripts/generate-engagement-emails.js +0 -705
  57. package/dist/registry/scripts/newsletter-helpers.js +0 -671
  58. package/dist/registry/scripts/profile-server.js +0 -388
  59. package/dist/registry/scripts/run-thank-you-workflow.js +0 -92
  60. package/dist/registry/scripts/send-newsletter-simple.js +0 -85
  61. package/dist/registry/scripts/send-thank-you-emails.js +0 -54
  62. package/dist/registry/scripts/validate-openapi-limits.js +0 -311
  63. package/dist/registry/scripts/validate-test-coverage.js +0 -262
  64. package/dist/registry/scripts/verify-test-coverage.js +0 -66
  65. package/dist/registry/templates/bootstrap/ARCHITECTURE-TEMPLATE.md +0 -53
  66. package/dist/registry/templates/bootstrap/CODE-QUALITY-REPORT-TEMPLATE.md +0 -37
  67. package/dist/registry/templates/bootstrap/TEST-COVERAGE-REPORT-TEMPLATE.md +0 -35
  68. package/dist/registry/templates/business-development/IDEATION-REPORT-TEMPLATE.md +0 -29
  69. package/dist/registry/templates/business-development/PRICING-STRATEGY-TEMPLATE.md +0 -126
  70. package/dist/registry/templates/customer-development/customer-interview-template.md +0 -99
  71. package/dist/registry/templates/customer-development/customer-persona-template.md +0 -69
  72. package/dist/registry/templates/customer-development/follow-up-email-templates.md +0 -132
  73. package/dist/registry/templates/customer-development/insight-analysis-template.md +0 -74
  74. package/dist/registry/templates/customer-development/prospect-inventory-template.csv +0 -3
  75. package/dist/registry/templates/customer-development/search-strategy-template.md +0 -123
  76. package/dist/registry/templates/customer-development/strategic-recommendations-template.md +0 -53
  77. package/dist/registry/templates/customer-development/thank-you-email-template.html +0 -124
  78. package/dist/registry/templates/customer-development/thank-you-note-template.md +0 -16
  79. package/dist/registry/templates/customer-development/triage-log-template.md +0 -278
  80. package/dist/registry/templates/customer-development/weekly-newsletter-template.html +0 -204
  81. package/dist/registry/templates/evidence/Design-Evidence.md +0 -30
  82. package/dist/registry/templates/evidence/Implementation-BugEvidence.md +0 -94
  83. package/dist/registry/templates/evidence/Implementation-FeatureEvidence.md +0 -129
  84. package/dist/registry/templates/evidence/Spec-Evidence.md +0 -19
  85. package/dist/registry/templates/help/HelpNeeded.md +0 -14
  86. package/dist/registry/templates/legal/NDA-TEMPLATE.md +0 -170
  87. package/dist/registry/templates/legal/PATENT-TEMPLATE.md +0 -372
  88. package/dist/registry/templates/legal/TRADEMARK-TEMPLATE.md +0 -339
  89. package/dist/registry/templates/legal/contract-review-checklist.md +0 -193
  90. package/dist/registry/templates/legal/review-report-template.md +0 -198
  91. package/dist/registry/templates/legal/saas-terms-template.md +0 -174
  92. package/dist/registry/templates/legal/sow-template.md +0 -117
  93. package/dist/registry/templates/legal/template-variables.md +0 -131
  94. package/dist/registry/templates/marketing/DOMAIN-REGISTRATION-TEMPLATE.md +0 -194
  95. package/dist/registry/templates/marketing/HBR-ARTICLE-TEMPLATE.md +0 -66
  96. package/dist/registry/templates/marketing/STORYTELLING-TEMPLATE.md +0 -130
  97. package/dist/registry/templates/marketing/WEBSITE-TEMPLATE.md +0 -262
  98. package/dist/registry/templates/marketing/github-pages-workflow.yml +0 -64
  99. package/dist/registry/templates/replicate/implementation-checklist.md +0 -39
  100. package/dist/registry/templates/replicate/use-cases-template.md +0 -88
  101. package/dist/registry/templates/retrospective/RETROSPECTIVE-TEMPLATE.md +0 -55
  102. package/dist/registry/templates/specs/BUGSPEC-TEMPLATE.md +0 -37
  103. package/dist/registry/templates/specs/FEATURESPEC-TEMPLATE.md +0 -66
  104. package/dist/registry/templates/specs/TECHSPEC-TEMPLATE.md +0 -39
  105. package/dist/registry/workflows/bootstrap/create-architecture.md +0 -38
  106. package/dist/registry/workflows/bootstrap/detect-broken-windows.md +0 -300
  107. package/dist/registry/workflows/bootstrap/evaluate-code-quality.md +0 -35
  108. package/dist/registry/workflows/bootstrap/verify-test-coverage.md +0 -36
  109. package/dist/registry/workflows/brainstorming/blue-sky-brainstorming.md +0 -211
  110. package/dist/registry/workflows/brainstorming/codebase-brainstorming.md +0 -165
  111. package/dist/registry/workflows/business-development/create-business-plan.md +0 -737
  112. package/dist/registry/workflows/business-development/ideate-business-opportunity.md +0 -55
  113. package/dist/registry/workflows/business-development/price-product.md +0 -325
  114. package/dist/registry/workflows/compliance/detect-compliance-requirements.md +0 -78
  115. package/dist/registry/workflows/compliance/generate-audit-evidence.md +0 -75
  116. package/dist/registry/workflows/compliance/soc2-evidence-generator.md +0 -332
  117. package/dist/registry/workflows/customer-development/insight-analysis.md +0 -156
  118. package/dist/registry/workflows/customer-development/insight-triage.md +0 -938
  119. package/dist/registry/workflows/customer-development/interview-preparation.md +0 -452
  120. package/dist/registry/workflows/customer-development/linkedin-outreach.md +0 -593
  121. package/dist/registry/workflows/customer-development/strategic-brainstorming.md +0 -146
  122. package/dist/registry/workflows/customer-development/thank-customers.md +0 -203
  123. package/dist/registry/workflows/customer-development/user-survey-dispatch.md +0 -60
  124. package/dist/registry/workflows/customer-development/users-to-target.md +0 -112
  125. package/dist/registry/workflows/customer-development/weekly-newsletter.md +0 -366
  126. package/dist/registry/workflows/deploy/cloud-deployment.md +0 -310
  127. package/dist/registry/workflows/improve-fraim/contribute.md +0 -32
  128. package/dist/registry/workflows/improve-fraim/file-issue.md +0 -32
  129. package/dist/registry/workflows/learning/build-skillset.md +0 -212
  130. package/dist/registry/workflows/learning/synthesize-learnings.md +0 -284
  131. package/dist/registry/workflows/legal/contract-review-analysis.md +0 -382
  132. package/dist/registry/workflows/legal/nda.md +0 -69
  133. package/dist/registry/workflows/legal/patent-filing.md +0 -76
  134. package/dist/registry/workflows/legal/saas-contract-development.md +0 -213
  135. package/dist/registry/workflows/legal/trademark-filing.md +0 -77
  136. package/dist/registry/workflows/marketing/content-creation.md +0 -37
  137. package/dist/registry/workflows/marketing/convert-to-pdf.md +0 -235
  138. package/dist/registry/workflows/marketing/create-modern-website.md +0 -456
  139. package/dist/registry/workflows/marketing/domain-registration.md +0 -323
  140. package/dist/registry/workflows/marketing/hbr-article.md +0 -73
  141. package/dist/registry/workflows/marketing/launch-checklist.md +0 -37
  142. package/dist/registry/workflows/marketing/marketing-strategy.md +0 -45
  143. package/dist/registry/workflows/marketing/storytelling.md +0 -65
  144. package/dist/registry/workflows/performance/analyze-performance.md +0 -65
  145. package/dist/registry/workflows/product-building/design.md +0 -103
  146. package/dist/registry/workflows/product-building/implement.md +0 -74
  147. package/dist/registry/workflows/product-building/iterate-on-pr-comments.md +0 -70
  148. package/dist/registry/workflows/product-building/prep-issue.md +0 -41
  149. package/dist/registry/workflows/product-building/prototype.md +0 -65
  150. package/dist/registry/workflows/product-building/resolve.md +0 -168
  151. package/dist/registry/workflows/product-building/retrospect.md +0 -86
  152. package/dist/registry/workflows/product-building/spec.md +0 -181
  153. package/dist/registry/workflows/product-building/test.md +0 -125
  154. package/dist/registry/workflows/productivity-report/productivity-report.md +0 -263
  155. package/dist/registry/workflows/quality-assurance/browser-validation.md +0 -221
  156. package/dist/registry/workflows/quality-assurance/iterative-improvement-cycle.md +0 -562
  157. package/dist/registry/workflows/replicate/replicate-discovery.md +0 -336
  158. package/dist/registry/workflows/replicate/replicate-to-issues.md +0 -324
  159. package/dist/registry/workflows/reviewer/review-implementation-vs-design-spec.md +0 -638
  160. package/dist/registry/workflows/reviewer/review-implementation-vs-feature-spec.md +0 -675
  161. package/dist/registry/workflows/startup-credits/aws-activate-application.md +0 -535
  162. package/dist/registry/workflows/startup-credits/google-cloud-application.md +0 -647
  163. package/dist/registry/workflows/startup-credits/microsoft-azure-application.md +0 -538
  164. package/dist/scripts/build-stub-registry.js +0 -108
  165. package/dist/src/ai-manager/ai-manager.js +0 -480
  166. package/dist/src/ai-manager/phase-flow.js +0 -357
  167. package/dist/src/ai-manager/types.js +0 -5
  168. package/dist/src/fraim-mcp-server.js +0 -1885
  169. package/dist/tests/debug-tools.js +0 -80
  170. package/dist/tests/shared-server-utils.js +0 -57
  171. package/dist/tests/test-add-ide.js +0 -283
  172. package/dist/tests/test-ai-coach-edge-cases.js +0 -420
  173. package/dist/tests/test-ai-coach-mcp-integration.js +0 -450
  174. package/dist/tests/test-ai-coach-performance.js +0 -328
  175. package/dist/tests/test-ai-coach-phase-content.js +0 -264
  176. package/dist/tests/test-ai-coach-workflows.js +0 -514
  177. package/dist/tests/test-cli.js +0 -228
  178. package/dist/tests/test-client-scripts-validation.js +0 -167
  179. package/dist/tests/test-complete-setup-flow.js +0 -110
  180. package/dist/tests/test-config-system.js +0 -279
  181. package/dist/tests/test-debug-session.js +0 -134
  182. package/dist/tests/test-end-to-end-hybrid-validation.js +0 -328
  183. package/dist/tests/test-enhanced-session-init.js +0 -188
  184. package/dist/tests/test-first-run-journey.js +0 -368
  185. package/dist/tests/test-fraim-issues.js +0 -59
  186. package/dist/tests/test-genericization.js +0 -44
  187. package/dist/tests/test-hybrid-script-execution.js +0 -340
  188. package/dist/tests/test-ide-detector.js +0 -46
  189. package/dist/tests/test-improved-setup.js +0 -121
  190. package/dist/tests/test-mcp-config-generator.js +0 -99
  191. package/dist/tests/test-mcp-connection.js +0 -107
  192. package/dist/tests/test-mcp-issue-integration.js +0 -156
  193. package/dist/tests/test-mcp-lifecycle-methods.js +0 -240
  194. package/dist/tests/test-mcp-shared-server.js +0 -308
  195. package/dist/tests/test-mcp-template-processing.js +0 -160
  196. package/dist/tests/test-modular-issue-tracking.js +0 -165
  197. package/dist/tests/test-node-compatibility.js +0 -95
  198. package/dist/tests/test-npm-install.js +0 -68
  199. package/dist/tests/test-package-size.js +0 -108
  200. package/dist/tests/test-pr-review-workflow.js +0 -307
  201. package/dist/tests/test-prep-issue.js +0 -129
  202. package/dist/tests/test-productivity-integration.js +0 -157
  203. package/dist/tests/test-script-location-independence.js +0 -198
  204. package/dist/tests/test-script-sync.js +0 -557
  205. package/dist/tests/test-server-utils.js +0 -32
  206. package/dist/tests/test-session-rehydration.js +0 -148
  207. package/dist/tests/test-setup-integration.js +0 -98
  208. package/dist/tests/test-setup-scenarios.js +0 -322
  209. package/dist/tests/test-standalone.js +0 -143
  210. package/dist/tests/test-stub-registry.js +0 -136
  211. package/dist/tests/test-sync-stubs.js +0 -143
  212. package/dist/tests/test-sync-version-update.js +0 -93
  213. package/dist/tests/test-telemetry.js +0 -193
  214. package/dist/tests/test-token-validator.js +0 -30
  215. package/dist/tests/test-user-journey.js +0 -236
  216. package/dist/tests/test-users-to-target-workflow.js +0 -253
  217. package/dist/tests/test-utils.js +0 -109
  218. package/dist/tests/test-wizard.js +0 -71
  219. package/dist/tests/test-workflow-discovery.js +0 -242
  220. package/labels.json +0 -52
  221. package/registry/agent-guardrails.md +0 -63
  222. package/registry/fraim.md +0 -48
  223. package/setup.js +0 -171
  224. package/tsconfig.json +0 -23
@@ -1,103 +0,0 @@
1
- # Workflow: design
2
-
3
- **Path:** `workflows/design.md`
4
-
5
- ---
6
-
7
- # Design Workflow - AI Coach Guided
8
-
9
- ## INTENT
10
- To create comprehensive technical design documents using a phase-based approach guided by the AI Coach, ensuring proper architecture, clear requirements, and stakeholder alignment.
11
-
12
- ## HOW IT WORKS
13
- This workflow uses a **coaching approach** where you get guidance on what to do next based on your current progress:
14
-
15
- - **Starting work**: Get initial phase instructions (usually design-design)
16
- - **Completed a phase**: Get next phase instructions immediately
17
- - **Stuck or incomplete**: Get guidance to continue current phase
18
- - **Adaptive guidance**: Different instructions based on design complexity
19
-
20
- The AI Coach provides phase-specific instructions and handles all the workflow progression for you.
21
-
22
- ## PHASE PROGRESSION
23
-
24
- **Typical Design Flow**: `design-design` → `design-completeness-review` → `submit-pr` → `wait-for-pr-review`
25
-
26
- **IMPORTANT**: Always use the exact phase names shown above!
27
-
28
- ## GETTING COACHING
29
-
30
- Use a single tool for all guidance:
31
-
32
- ```javascript
33
- seekCoachingOnNextStep({
34
- workflowType: "design",
35
- issueNumber: "{issue_number}",
36
- currentPhase: "design-design", // IMPORTANT: Use "design-design" for starting phase
37
- status: "starting", // Use "starting" when beginning work
38
- findings: {
39
- // Your results/findings from current phase
40
- designType: "rfc", // or "bugspec"
41
- requirements: "...", // summary of what you learned
42
- uncertainties: ["..."] // any unclear aspects
43
- }
44
- })
45
- ```
46
-
47
- ## PHASE NAMES (IMPORTANT!)
48
-
49
- **You MUST use these exact phase names:**
50
- - **Starting phase**: `design-design` (NOT "design" or "scoping")
51
- - **Review phase**: `design-completeness-review`
52
- - **Submit phase**: `submit-pr`
53
- - **Final phase**: `wait-for-pr-review`
54
-
55
- ## STATUS VALUES
56
-
57
- - **starting**: You're beginning work (get initial design instructions)
58
- - **complete**: You finished a phase successfully (get next phase instructions)
59
- - **incomplete**: You need help with current phase (get guidance to continue)
60
-
61
- ## EVIDENCE TRACKING
62
-
63
- The AI Coach expects evidence of your work:
64
- - **Design documents**: RFC or BUGSPEC files created
65
- - **Stakeholder feedback**: Reviews and approvals received
66
- - **Technical validation**: Architecture compliance verified
67
-
68
- ## QUICK START
69
-
70
- 1. **Start the workflow**: Call `seekCoachingOnNextStep` with `status: "starting"`
71
- 2. **Follow phase instructions**: Complete the specific phase you're guided to
72
- 3. **Report completion**: Call `seekCoachingOnNextStep` with `status: "complete"` and evidence
73
- 4. **Get next phase**: Receive instructions for the next phase automatically
74
- 5. **Repeat**: Continue until workflow completion
75
-
76
- The AI Coach handles all the complexity - you just focus on executing the current phase!
77
-
78
- ## EXAMPLE USAGE
79
-
80
- **Starting the workflow:**
81
- ```javascript
82
- seekCoachingOnNextStep({
83
- workflowType: "design",
84
- issueNumber: "1019",
85
- currentPhase: "design-design",
86
- status: "starting"
87
- })
88
- ```
89
-
90
- **Completing a phase:**
91
- ```javascript
92
- seekCoachingOnNextStep({
93
- workflowType: "design",
94
- issueNumber: "1019",
95
- currentPhase: "design-design",
96
- status: "complete",
97
- findings: {
98
- designType: "rfc",
99
- requirements: "Created comprehensive RFC for feature X",
100
- rfcPath: "docs/rfcs/1019-feature-x.md"
101
- }
102
- })
103
- ```
@@ -1,74 +0,0 @@
1
- # Workflow: implement
2
-
3
- **Path:** `workflows/implement.md`
4
-
5
- ---
6
-
7
- # Implementation Workflow - AI Coach Guided
8
-
9
- ## INTENT
10
- To implement bug fixes and features using a phase-based approach guided by the AI Coach, ensuring high-quality, tested code that meets requirements.
11
-
12
- ## HOW IT WORKS
13
- This workflow uses a **coaching approach** where you get guidance on what to do next based on your current progress:
14
-
15
- - **Starting work**: Get initial phase instructions (usually scoping)
16
- - **Completed a phase**: Get next phase instructions immediately
17
- - **Stuck or incomplete**: Get guidance to continue current phase
18
- - **Adaptive guidance**: Different instructions for bugs vs features
19
-
20
- The AI Coach provides phase-specific instructions and handles all the workflow progression for you.
21
-
22
- ## PHASE PROGRESSION
23
-
24
- **Typical Bug Flow**: implement-scoping → implement-repro → implement-code → implement-validate → implement-smoke → implement-regression → implement-completeness-review → submit-pr → wait-for-pr-review → retrospective
25
-
26
- **Typical Feature Flow**: implement-scoping → implement-spike → implement-code → implement-validate → implement-smoke → implement-regression → implement-completeness-review → submit-pr → wait-for-pr-review → retrospective
27
-
28
- ## GETTING COACHING
29
-
30
- Use a single tool for all guidance:
31
-
32
- ```javascript
33
- seekCoachingOnNextStep({
34
- workflowType: "implement",
35
- issueNumber: "{issue_number}",
36
- currentPhase: "{phase_name}",
37
- status: "{starting|complete|incomplete}",
38
- findings: {
39
- // Your results/findings from current phase
40
- issueType: "bug", // or "feature" (for scoping)
41
- requirements: "...", // summary of what you learned
42
- uncertainties: ["..."] // any unclear aspects
43
- }
44
- })
45
- ```
46
-
47
- ## STATUS VALUES
48
-
49
- - **starting**: You're beginning work (get initial scoping instructions)
50
- - **complete**: You finished a phase successfully (get next phase instructions)
51
- - **incomplete**: You're stuck or need to iterate (get guidance for current phase)
52
-
53
- ## GETTING STARTED
54
-
55
- ### Prerequisites
56
- **IMPORTANT**: Ensure you are aware of the issue you are working on and are on an appropriate feature branch:
57
- - ✅ Know your issue number and description
58
- - ✅ Make sure you are working on a feature branch, not main or master
59
-
60
- ### Start with Scoping
61
-
62
- Unless you are already on a future phase, start with scoping:
63
-
64
- ```javascript
65
- seekCoachingOnNextStep({
66
- workflowType: "implement",
67
- issueNumber: "{issue_number}",
68
- currentPhase: "implement-scoping",
69
- status: "starting"
70
- })
71
- ```
72
-
73
- The AI Coach will provide detailed implement-scoping instructions and guide you through the entire workflow, one phase at a time.
74
-
@@ -1,70 +0,0 @@
1
- # Workflow: iterate-on-pr-comments
2
-
3
- **Path:** `workflows/iterate-on-pr-comments.md`
4
-
5
- ---
6
-
7
- # PR Iteration & Monitoring
8
-
9
- ## INTENT
10
- To ensure AI agents autonomously handle the complete PR lifecycle with proper monitoring, feedback handling, and testing, eliminating gaps that require human intervention.
11
-
12
- ## PRINCIPLES
13
- - **Complete Autonomy**: Agents should handle the PR workflow without requiring human prompting
14
- - **Proactive Monitoring**: Continuously check status of actions and PRs
15
- - **Comprehensive Feedback**: Address all comments before resubmission
16
- - **Evidence-Based Progress**: Document test results and implementation status
17
-
18
- ## WORKFLOW
19
-
20
- ### Step 1: Git Action Monitoring
21
- After pushing changes:
22
- 1. **Monitor Actions**: Check GitHub Actions status every 30 seconds.
23
- 2. **Retry on Failure**: If specific actions fail, analyze logs, debug, fix, and push again.
24
- 3. **Timeout**: If actions run > 10 mins or fail 3x consecutively, notify user with analysis.
25
- 4. **Success**: Only when all actions pass, proceed to Step 2.
26
-
27
- ### Step 2: PR Feedback Polling
28
- After submission (or update):
29
- 1. **Poll**: Check for PR comments/reviews every 1 minute.
30
- 2. **Timeout**: After 24 hours of silence, notify user.
31
- 3. **Active Feedback**: If feedback arrives, proceed to Step 3 immediately.
32
-
33
- ### Step 3: Feedback Processing
34
- 1. **Set Status**: Label issue `status:wip`.
35
- 2. **Analyze**: Read all comments. Use `get_github_pr_comments` or similar tool.
36
- 3. **Address**: For each comment:
37
- * Implement code changes or fixes.
38
- * **Reply** to the comment (using `add_comment_to_pending_review` or `add_issue_comment`) explaining the fix.
39
- 4. **Verify**: Ensure no comments are left unaddressed.
40
-
41
- ### Step 4: Verification & Evidence
42
- Before re-submitting:
43
- 1. **Run Tests**: Execute relevant test suites (Unit + Integration).
44
- 2. **Document**: Add a comment to the PR/Issue with:
45
- * Test commands run.
46
- * Pass/Fail status.
47
- * Coverage summary.
48
- 3. **Clean Up**: Remove temp files/logs.
49
-
50
- ### Step 5: Submission
51
- 1. **Sync**: Push all changes.
52
- 2. **Set Status**: specific label `status:needs-review`.
53
- 3. **Loop**: Return to Step 1 (Monitor Actions).
54
-
55
- ## FAILURE MODES
56
- - **Git Action Timeout**: 10 mins / 20 attempts.
57
- - **Feedback Timeout**: 24 hours.
58
- - **Network Errors**: Exponential backoff needed.
59
-
60
- ## EXAMPLES
61
-
62
- ### Good: Handling Feedback
63
- ```
64
- 1. Detected 3 comments on PR #123.
65
- 2. Comment 1 ("Fix typo"): Fixed in file.ts. Replied "Fixed".
66
- 3. Comment 2 ("Memory leak"): Reproduced, fixed logic. Replied "Fixed with new pattern".
67
- 4. Ran tests: All Pass.
68
- 5. Posted evidence.
69
- 6. Pushed. Labeled status:needs-review.
70
- ```
@@ -1,41 +0,0 @@
1
- # Workflow: Issue Preparation (prep-issue)
2
-
3
- This workflow prepares the local development environment for working on a specific GitHub issue.
4
-
5
- ## Prerequisites
6
-
7
- - GitHub Issue Number (e.g., 56)
8
- - GitHub CLI (gh) installed and authenticated
9
-
10
- ## Action Items
11
-
12
- 1. **Execute Preparation Script**:
13
- Fetch and run cleanup/setup scripts ephemerally.
14
-
15
- ```bash
16
- # Execute the prep-issue script directly from synced location
17
- ~/.fraim/scripts/prep-issue.sh {issue_number}
18
-
19
- # Note: Windows users should use Git Bash terminal
20
- ```
21
-
22
-
23
- 3. **Verify Setup**:
24
- - **Clean Context**: Start fresh to avoid pollution
25
- - **Environment**: Follow "Local Development" guidelines (read `rules/local-development.md` using `get_fraim_file`).
26
- - [ ] Feature branch created and pushed to origin.
27
- - [ ] `npm install` completed.
28
- - [ ] Serena indexing completed (if applicable).
29
-
30
- ## Implementation Detail (Agent Guidance)
31
-
32
- Execute:
33
- ```bash
34
- # Execute the prep-issue script directly from synced location
35
- ~/.fraim/scripts/prep-issue.sh {issue_number}
36
-
37
- # Note: Windows users should use Git Bash terminal
38
- ```
39
-
40
- > [!NOTE]
41
- > The script will automatically handle branch naming based on the issue title using `gh issue view`.
@@ -1,65 +0,0 @@
1
- # Workflow: prototype
2
-
3
- **Path:** `workflows/prototype.md`
4
-
5
- ---
6
-
7
- # Prototype / PoC Phase
8
-
9
- ## INTENT
10
- To quickly explore ideas, validate technologies, or prove concepts using "spike" code. Speed and learning are prioritized over code quality and tests.
11
-
12
- ## PRINCIPLES
13
- - **Speed Over Perfection**: It gets the job done; it doesn't need to be pretty.
14
- - **Disposable Code**: Assume this code will be thrown away or heavily refactored.
15
- - **Time-Boxed**: Spikes should have a clear time limit.
16
- - **Learning Focused**: The goal is to answer a question or prove a capability.
17
-
18
- ## PROTOTYPE WORKFLOW
19
-
20
- ### Step 1: Issue Identification
21
- Ask for {issue_number} (and optional {slug}).
22
-
23
- **GitHub Repository Context**: Before using GitHub MCP tools, read the local `.fraim/config.json` file to get the repository context:
24
- - Use `git.repoOwner` for the GitHub repository owner
25
- - Use `git.repoName` for the GitHub repository name
26
- - These values are required for GitHub MCP API calls (owner/repo parameters)
27
-
28
- ### Step 2: Phase Initiation
29
- Label the issue 'phase:prototype'.
30
-
31
- ### Step 3: Environment Setup
32
- User runs `prep-issue.sh` (or you do if needed).
33
- Switch to a `prototype/...` branch if not already on one.
34
-
35
- ### Step 4: Work Location
36
- Work in the prepared workspace.
37
-
38
- ### Step 5: Prototyping
39
- - **Goal**: Build a working demonstration of the concept.
40
- - **Constraints**:
41
- - **No Tests Required** (unless helpful for you).
42
- - **Hardcoding Allowed**: Use hardcoded values to speed up development.
43
- - **No Cleanup Required**: Formatting/Linting is optional.
44
- - **Focus on the Core**: Ignore edge cases, error handling, and polish.
45
-
46
- ### Step 6: Demonstration
47
- - Verify the prototype works for the "Happy Path".
48
- - Create a screen recording or screenshot of the working prototype.
49
- - Document what was learned:
50
- - Does it work?
51
- - What are the risks?
52
- - How should we implement the real version?
53
- - How should we implement the real version?
54
-
55
- ### Step 7: Transition
56
- **Decide the next step:**
57
- 1. **Discard**: The idea didn't work. Close issue.
58
- 2. **Spec**: The idea works, but needs a full design. Call `get_fraim_workflow({ workflow: "spec" })`.
59
- 3. **Implement**: The prototype is good enough to be the base. **YOU MUST CLEAN IT UP.**
60
- - Call `get_fraim_workflow({ workflow: "implement" })`.
61
- - **CRITICAL**: You must specifically address the "Cleanup" phase where you refactor the prototype code into production-quality code, add tests, and handle edge cases.
62
-
63
- ### Step 8: Completion
64
- - Commit the prototype code (optional, but good for history).
65
- - Label `status:prototype-done`.
@@ -1,168 +0,0 @@
1
- # Workflow: resolve
2
-
3
- **Path:** `workflows/resolve.md`
4
-
5
- ---
6
-
7
- # Issue Resolution Workflow
8
-
9
- ## INTENT
10
- To provide a systematic approach to resolving issues from development through merge verification and cleanup, ensuring no work is lost and all changes are properly integrated into the main codebase.
11
-
12
- ## PRINCIPLES
13
- - **Success Criteria**: Optimize for Integrity (Verify truthfully) and Completeness (Clean up fully) - see `rules/agent-success-criteria.md` (fetch via `get_fraim_file`).
14
- - **Verification First**: Always verify merges before closing issues
15
- - **Complete Cleanup**: Remove all traces of feature branches
16
- - **No Work Loss**: Prevent incidents like Issue #112 through proper verification
17
- - **Systematic Process**: Follow established steps in order
18
- - **Evidence-Based**: Provide concrete verification of completion
19
- - **Git Safety**: Follow "Git Safe Commands" (read `rules/git-safe-commands.md` using `get_fraim_file`)
20
-
21
- ## CRITICAL DEPENDENCY
22
- **This workflow MUST be used in conjunction with "Merge Requirements" rule** (read `rules/merge-requirements.md` via `get_fraim_file`) which contains:
23
- - **Pre-Push Workflow** (for feature branches during development)
24
- - **PR Description Template** (for PR creation)
25
- - **Final Merge Process** (for merging to master - used in this workflow)
26
- - **Conflict Resolution Guide** (for resolving conflicts during rebase)
27
-
28
- **Note**: The Pre-Push workflow applies to feature branch development. This resolve.md workflow focuses on the **final merge into master** and uses the Final Merge Process from merge-requirements.md.
29
-
30
- ## RESOLUTION WORKFLOW
31
-
32
- **PREREQUISITE**: This workflow assumes:
33
- - ✅ All development work is complete
34
- - ✅ All tests have been run on the feature branch
35
- - ✅ PR has been created and approved
36
- - ✅ Feature branch is ready for merge
37
-
38
- **GitHub Repository Context**: Before using GitHub MCP tools, read the local `.fraim/config.json` file to get the repository context:
39
- - Use `git.repoOwner` for the GitHub repository owner
40
- - Use `git.repoName` for the GitHub repository name
41
- - These values are required for GitHub MCP API calls (owner/repo parameters)
42
-
43
- ### 1. Execute the Merge
44
- Use GitHub MCP to merge the PR:
45
-
46
- ```bash
47
- # Merge the PR using GitHub MCP
48
- gh pr merge <PR_NUMBER> --rebase
49
- ```
50
-
51
- **If conflicts occur during merge:**
52
- - GitHub will reject the merge with conflict details
53
- - Use `gh pr view <PR_NUMBER>` to see conflict details
54
- - Resolve conflicts intelligently using the **Conflict Resolution Guide** from `merge-requirements.md`
55
- - Keep master's base implementation and add your enhancements on top
56
- - Test the resolution: Check `.fraim/config.json` for `customizations.validation.smokeTestCommand` and use that, or default to `npm run build && npm run test-smoke test*.ts`
57
- - Push the resolved changes and retry the merge
58
-
59
- ### 2. Wait for Master CI Smoke Tests
60
- After successful merge, monitor the master branch CI:
61
- - Check GitHub Actions for the master branch
62
- - Wait for smoke tests to complete successfully
63
- - **CRITICAL**: Do not proceed until CI passes
64
-
65
- ### 3. Verify Code Made it to Master
66
- **MANDATORY**: Confirm the merge was successful:
67
- ```bash
68
- # Check PR is merged, not just closed
69
- gh pr view <PR_NUMBER> --json merged
70
-
71
- # Verify merge commit in master
72
- git fetch origin master
73
- git log origin/master --oneline | grep "PR #<PR_NUMBER>"
74
-
75
- # Verify files in master
76
- git show origin/master:path/to/expected/file
77
- ```
78
-
79
- ### 4. Handle CI Failures
80
- **If master CI fails:**
81
- - Debug the issue immediately
82
- - Fix the problem in the feature branch
83
- - Push the fix and re-merge
84
- - Repeat until CI passes
85
- - **Do not close the issue until CI passes**
86
-
87
- ### 5. Confirm all good
88
- **Only after CI passes successfully:**
89
-
90
- **Add Resolution Comment if conflicts with master had to be resolved:**
91
- - Add a comment to the issue using GitHub MCP:
92
- ```bash
93
- gh issue comment <ISSUE_NUMBER> --body "✅ Encountered conflicts during merge with master.
94
-
95
- **Conflict Resolution Notes:**
96
- - Resolved conflicts in: [list files with conflicts]
97
- - Resolution strategy: [explain what was done]
98
- - Kept master's base implementation and added enhancements on top"
99
- ```
100
-
101
- **Verify the following:**
102
- 1. ✅ **PR Status**: PR shows "merged" status, not just "closed"
103
- 2. ✅ **Merge Commit**: Verify merge commit exists in master
104
- 3. ✅ **Files in Master**: Confirm expected files are present in master
105
-
106
- ### **Verification Commands**
107
- ```bash
108
- # Check PR is merged, not just closed
109
- gh pr view <PR_NUMBER> --json merged
110
-
111
- # Verify merge commit in master
112
- git fetch origin master
113
- git log origin/master --oneline | grep "PR #<PR_NUMBER>"
114
-
115
- # Verify files in master
116
- git show origin/master:path/to/expected/file
117
- ```
118
-
119
- **CRITICAL**: Do not close the issue until merge verification passes. This prevents work loss incidents
120
-
121
- ### 6. Issue Resolution & Cleanup
122
- **Close the Issue:**
123
- - Close the issue with resolution comment using GitHub MCP:
124
- ```bash
125
- gh issue close <ISSUE_NUMBER> --comment "✅ Issue resolved and merged to master. CI smoke tests passed."
126
- ```
127
-
128
- **Cleanup Branch:**
129
- ```bash
130
- # Execute cleanup script directly from synced location
131
- npx tsx ~/.fraim/scripts/cleanup-branch.ts {branch_name}
132
-
133
- # Note: Windows users should use Git Bash terminal
134
- ```
135
-
136
- ### 7. Celebrate
137
- - Say Hoorah !
138
-
139
-
140
- ## EXAMPLES
141
-
142
- ### Good: Proper Resolution Process
143
- ```
144
- Issue #84: "Fix calendar sync timeout"
145
- PREREQUISITE: ✅ Development complete, tests passed, PR approved
146
- 1. ✅ Merge: Used `gh pr merge <PR_NUMBER> --rebase`
147
- 2. ✅ Conflicts: Resolved conflicts intelligently (kept master's base)
148
- 3. ✅ CI Wait: Waited for master CI smoke tests to pass
149
- 4. ✅ Verification: Confirmed merge commit exists in master
150
- 5. ✅ Schema: Cleaned up database schema BEFORE branch deletion
151
- 6. ✅ Comment: Added resolution comment with conflict resolution notes
152
- 7. ✅ Close: Closed issue with resolution comment using `gh issue close`
153
- 8. ✅ Cleanup: Deleted branch after schema cleanup
154
- Result: Complete resolution with no work loss
155
- ```
156
-
157
- ### Bad: Incomplete Resolution
158
- ```
159
- Issue #84: "Fix calendar sync timeout"
160
- PREREQUISITE: ✅ Development complete, tests passed, PR approved
161
- 1. ✅ Merge: Used `gh pr merge <PR_NUMBER> --rebase`
162
- 2. ❌ Skip: Didn't wait for master CI smoke tests
163
- 3. ❌ Skip: Didn't verify merge commit exists
164
- 4. ❌ Skip: Didn't clean up schema BEFORE branch deletion
165
- 5. ❌ Skip: Didn't add resolution comment with conflict notes
166
- 6. ❌ Close: Closed issue without CI verification
167
- Result: Work lost, schema not cleaned up, CI may have failed
168
- ```
@@ -1,86 +0,0 @@
1
- # Retrospective Creation
2
-
3
- ## INTENT
4
- To capture learnings and insights from completed issues, enabling continuous improvement and preventing future similar problems through systematic analysis and documentation.
5
-
6
- ## PRINCIPLES
7
- - **Success Criteria**: Focus on Integrity (Self-reflection) and Independence (Learning from mistakes) - see `rules/agent-success-criteria.md` (fetch via `get_fraim_file`).
8
- - Every completed issue requires a retrospective
9
- - Focus on root causes, not just symptoms
10
- - Document both successes and failures
11
- - Create actionable prevention measures
12
- - Share learnings with other agents
13
- - Continuous Learning: Follow "Continuous Learning" principles (read `rules/continuous-learning.md` via `get_fraim_file`)
14
-
15
- ## WORKFLOW
16
-
17
- 1. **Label the issue** `status:wip` and remove `status:complete`
18
- 2. **Create retrospective document** using the template
19
- 3. **Complete retrospective** following the quality checklist
20
- 4. **When ready for review**, flip issue to `status:needs-review` and remove `status:wip`
21
- 5. **Iterate** until the PR is approved
22
-
23
- ## RETROSPECTIVE TRIGGERS
24
-
25
- - **All Issues**: Every completed issue requires a retrospective
26
- - **Complex Issues (>3 iterations)**: Must create detailed retrospective
27
- - **Process Violations**: Any workflow rule violations require detailed retrospectives
28
- - **Work Loss Incidents**: Any incidents where work is lost require detailed retrospectives
29
-
30
- ## RETROSPECTIVE CREATION PROCESS
31
-
32
- ### 1. Create Retrospective File
33
- - **File path**: `retrospectives/issue-{issue-number}-{kebab-title}-postmortem.md`
34
- - **Template**: Use Retrospective template: `get_fraim_file({ path: "templates/retrospective/RETROSPECTIVE-TEMPLATE.md" })`
35
- - **Copy template**: Copy the template file and fill in the placeholders
36
-
37
- ### 2. Root Cause Analysis
38
- - Identify underlying causes, not just symptoms
39
- - Document what went wrong and why
40
- - Analyze process failures and human errors
41
- - Look for patterns that could affect other issues
42
-
43
- ### 3. Prevention Measures
44
- - Document specific actions to prevent recurrence
45
- - Update rules and workflows based on learnings
46
- - Share solutions with other agents through issue comments
47
- - Identify process improvements
48
-
49
- ### 4. Document Success Factors
50
- - What worked well and why
51
- - Best practices discovered
52
- - Tools and techniques that helped
53
- - Lessons that can be applied to future issues
54
-
55
- ## RETROSPECTIVE QUALITY CHECKLIST
56
-
57
- Before marking retrospective complete, verify:
58
- - [ ] Root cause analysis completed (not just symptoms)
59
- - [ ] Prevention measures documented
60
- - [ ] Process improvements identified
61
- - [ ] Success factors captured
62
- - [ ] Action items are specific and actionable
63
- - [ ] Template followed completely
64
- - [ ] File saved in correct location
65
- - [ ] All placeholders replaced with actual content
66
- - [ ] Timeline of events is accurate and complete
67
- - [ ] Lessons learned are actionable
68
-
69
- ## EXAMPLES
70
-
71
- ### Good: Comprehensive Retrospective
72
- ```
73
- - Root cause: "Agent didn't verify workspace directory before file operations"
74
- - Prevention: "Added mandatory pwd check before any file operation"
75
- - Learning: "Workspace violations are common without explicit safeguards"
76
- - Git Issues Suggested: "Update local-development.mdc with verification checklist"
77
- ```
78
-
79
- ### Bad: Surface-Level Retrospective
80
- ```
81
- - Problem: "File created in wrong location"
82
- - Solution: "Moved file to correct location"
83
- - Learning: "Need to be more careful"
84
- ```
85
-
86
- **CRITICAL**: Do not close the issue until retrospective is created, reviewed, and approved.