fraim-framework 1.0.12 β 2.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.ai-agents/agent-guardrails.md +58 -0
- package/.ai-agents/mcp-template.jsonc +34 -0
- package/.ai-agents/rules/agent-testing-guidelines.md +545 -0
- package/.ai-agents/rules/architecture.md +52 -0
- package/.ai-agents/rules/communication.md +122 -0
- package/.ai-agents/rules/continuous-learning.md +55 -0
- package/.ai-agents/rules/git-safe-commands.md +34 -0
- package/.ai-agents/rules/integrity-and-test-ethics.md +223 -0
- package/.ai-agents/rules/local-development.md +252 -0
- package/.ai-agents/rules/merge-requirements.md +231 -0
- package/.ai-agents/rules/pr-workflow-completeness.md +191 -0
- package/.ai-agents/rules/simplicity.md +112 -0
- package/.ai-agents/rules/software-development-lifecycle.md +276 -0
- package/.ai-agents/rules/spike-first-development.md +199 -0
- package/.ai-agents/rules/successful-debugging-patterns.md +313 -0
- package/.ai-agents/scripts/cleanup-branch.ts +278 -0
- package/.ai-agents/scripts/exec-with-timeout.ts +122 -0
- package/.ai-agents/scripts/prep-issue.sh +162 -0
- package/.ai-agents/templates/evidence/Design-Evidence.md +30 -0
- package/.ai-agents/templates/evidence/Implementation-BugEvidence.md +48 -0
- package/.ai-agents/templates/evidence/Implementation-FeatureEvidence.md +54 -0
- package/.ai-agents/templates/evidence/Spec-Evidence.md +19 -0
- package/.ai-agents/templates/help/HelpNeeded.md +14 -0
- package/.ai-agents/templates/retrospective/RETROSPECTIVE-TEMPLATE.md +55 -0
- package/.ai-agents/templates/specs/BUGSPEC-TEMPLATE.md +37 -0
- package/.ai-agents/templates/specs/FEATURESPEC-TEMPLATE.md +29 -0
- package/.ai-agents/templates/specs/TECHSPEC-TEMPLATE.md +39 -0
- package/.ai-agents/workflows/design.md +121 -0
- package/.ai-agents/workflows/implement.md +170 -0
- package/.ai-agents/workflows/resolve.md +152 -0
- package/.ai-agents/workflows/retrospect.md +84 -0
- package/.ai-agents/workflows/spec.md +103 -0
- package/.ai-agents/workflows/test.md +90 -0
- package/.cursor/rules/cursor-rules.mdc +8 -0
- package/.cursor/rules/design.mdc +4 -0
- package/.cursor/rules/implement.mdc +6 -0
- package/.cursor/rules/resolve.mdc +5 -0
- package/.cursor/rules/retrospect.mdc +4 -0
- package/.cursor/rules/spec.mdc +4 -0
- package/.cursor/rules/test.mdc +5 -0
- package/.windsurf/rules/windsurf-rules.md +7 -0
- package/.windsurf/workflows/resolve-issue.md +6 -0
- package/.windsurf/workflows/retrospect.md +6 -0
- package/.windsurf/workflows/start-design.md +6 -0
- package/.windsurf/workflows/start-impl.md +6 -0
- package/.windsurf/workflows/start-spec.md +6 -0
- package/.windsurf/workflows/start-tests.md +6 -0
- package/CHANGELOG.md +66 -0
- package/CODEOWNERS +24 -0
- package/DISTRIBUTION.md +6 -6
- package/PUBLISH_INSTRUCTIONS.md +93 -0
- package/README.md +330 -104
- package/bin/fraim.js +49 -3
- package/index.js +30 -3
- package/install.sh +58 -58
- package/labels.json +52 -0
- package/linkedin-post.md +23 -0
- package/package.json +12 -7
- package/sample_package.json +18 -0
- package/setup.js +733 -384
- package/test-utils.ts +118 -0
- package/tsconfig.json +22 -0
- package/agents/claude/CLAUDE.md +0 -42
- package/agents/cursor/rules/architecture.mdc +0 -49
- package/agents/cursor/rules/continuous-learning.mdc +0 -48
- package/agents/cursor/rules/cursor-workflow.mdc +0 -29
- package/agents/cursor/rules/design.mdc +0 -25
- package/agents/cursor/rules/implement.mdc +0 -26
- package/agents/cursor/rules/local-development.mdc +0 -104
- package/agents/cursor/rules/prep.mdc +0 -15
- package/agents/cursor/rules/resolve.mdc +0 -46
- package/agents/cursor/rules/simplicity.mdc +0 -18
- package/agents/cursor/rules/software-development-lifecycle.mdc +0 -41
- package/agents/cursor/rules/test.mdc +0 -25
- package/agents/windsurf/rules/architecture.md +0 -49
- package/agents/windsurf/rules/continuous-learning.md +0 -47
- package/agents/windsurf/rules/local-development.md +0 -103
- package/agents/windsurf/rules/remote-development.md +0 -22
- package/agents/windsurf/rules/simplicity.md +0 -17
- package/agents/windsurf/rules/windsurf-workflow.md +0 -28
- package/agents/windsurf/workflows/prep.md +0 -20
- package/agents/windsurf/workflows/resolve-issue.md +0 -47
- package/agents/windsurf/workflows/start-design.md +0 -26
- package/agents/windsurf/workflows/start-impl.md +0 -27
- package/agents/windsurf/workflows/start-tests.md +0 -26
- package/github/phase-change.yml +0 -218
- package/github/status-change.yml +0 -68
- package/github/sync-on-pr-review.yml +0 -66
- package/scripts/__init__.py +0 -10
- package/scripts/cli.py +0 -141
- package/setup.py +0 -0
- package/test-config.json +0 -32
- package/workflows/setup-fraim.yml +0 -147
package/README.md
CHANGED
|
@@ -1,159 +1,385 @@
|
|
|
1
1
|
# π FRAIM: Framework for Rigor-based AI Management
|
|
2
|
+
**"FRAIM is a step towards the future of how we work."** - Transforming ideas into production code by converting you into an AI manager orchestrating multiple agents with enterprise-grade discipline.
|
|
2
3
|
|
|
3
|
-
**Where humans become AI managers through rigorous methodology**
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
π **The Problem with AI Coding Today**
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Current "vibe coding" frameworks are great at getting from idea to prototype. They fail spectacularly at going from prototype to production or evolving complex codebases.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
AI agents are like brilliant but inexperienced developers. They need:
|
|
10
|
+
β’ Clear guardrails to prevent costly mistakes
|
|
11
|
+
β’ Structured workflows to avoid chaos
|
|
12
|
+
β’ Evidence-based validation (not "looks good" claims)
|
|
13
|
+
β’ Learning systems to improve over time
|
|
14
|
+
β’ Balance between determinism and creativity
|
|
10
15
|
|
|
11
|
-
**
|
|
16
|
+
π― **Introducing FRAIM: Framework for Rigor-based AI Management**
|
|
12
17
|
|
|
13
|
-
|
|
18
|
+
FRAIM transforms you from a solo developer into an AI manager orchestrating multiple agents with enterprise-grade discipline.
|
|
14
19
|
|
|
15
|
-
**
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
**O**bservability: Complete visibility into AI activities
|
|
19
|
-
**R**etrospectives: Continuous learning from mistakes and positive experiences
|
|
20
|
+
**The Transformation:**
|
|
21
|
+
β Before: "It's working now. The login button exists."
|
|
22
|
+
β
After: "Implementation complete. 12/12 tests pass, API endpoint validated, UI screenshots provided."
|
|
20
23
|
|
|
21
|
-
|
|
24
|
+
**Real Results:**
|
|
25
|
+
β’ Dramatic reduction in AI-generated code that needs rework
|
|
26
|
+
β’ Faster delivery through structured workflows
|
|
27
|
+
β’ Higher test coverage through mandatory evidence collection
|
|
28
|
+
β’ Zero agent conflicts through phase-based coordination
|
|
22
29
|
|
|
23
|
-
|
|
30
|
+
**The RIGOR Methodology:**
|
|
31
|
+
R - Reviews: Structured feedback with evidence
|
|
32
|
+
I - Isolation: Agents don't interfere unless coordinated
|
|
33
|
+
G - GitOps: Git as single source of truth
|
|
34
|
+
O - Observability: Complete visibility into AI activities
|
|
35
|
+
R - Retrospectives: Continuous learning from experience
|
|
36
|
+
|
|
37
|
+
π€ **Works with any AI agent** (Cursor, Claude, Windsurf) - no vendor lock-in.
|
|
38
|
+
|
|
39
|
+
**The bottom line:** FRAIM isn't just about using AIβit's about managing AI teams with the same discipline you'd apply to human developers.
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
### The Human-Developer Parallel
|
|
44
|
+
|
|
45
|
+
| **Human Development** | **AI Agent Development** | **FRAIM Solution** |
|
|
46
|
+
|----------------------|-------------------------|-------------------|
|
|
47
|
+
| **Code Reviews** | Random quality checks | Structured review workflows with evidence requirements |
|
|
48
|
+
| **Testing Standards** | "Looks good" claims | Mandatory test evidence with failure reproduction |
|
|
49
|
+
| **Team Coordination** | Agent conflicts and overlaps | Phase-based isolation with clear handoffs |
|
|
50
|
+
| **Learning Culture** | Repeated mistakes | Retrospective-driven improvement system |
|
|
51
|
+
| **Process Discipline** | Ad-hoc approaches | Proven workflows and deterministic scripts from real projects |
|
|
52
|
+
| **Quality Gates** | Unreliable outcomes | Deterministic validation with rollback capabilities |
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
## π₯ The Problems FRAIM Solves
|
|
56
|
+
|
|
57
|
+
### β **The Current State of AI Development**
|
|
58
|
+
- **"Looks Good" Syndrome**: Agents claim success without evidence
|
|
59
|
+
- **Quality Lottery**: Inconsistent code quality and reliability
|
|
60
|
+
- **Agent Chaos**: Multiple agents stepping on each other's work
|
|
61
|
+
- **No Learning**: Repeated mistakes without improvement
|
|
62
|
+
- **Ad-hoc Processes**: Every project reinvents the wheel
|
|
63
|
+
- **False Confidence**: Broken code marked as "working"
|
|
64
|
+
- **Hanging Agents**: Commands that hang requiring human intervention
|
|
65
|
+
- **Lost Output**: No visibility into long-running task progress
|
|
66
|
+
|
|
67
|
+
### β
**The FRAIM Solution**
|
|
68
|
+
|
|
69
|
+
#### π‘οΈ **Agent Integrity & Test Ethics** (`.ai-agents/rules/integrity-and-test-ethics.md`)
|
|
70
|
+
**Problem**: Agents claim "tests pass" when they actually fail
|
|
71
|
+
**Solution**: Mandatory evidence collection, test immutability rules, and accountability frameworks
|
|
24
72
|
```bash
|
|
25
|
-
|
|
73
|
+
# Before FRAIM: "Tests look good!"
|
|
74
|
+
# After FRAIM: "Here's the test output proving all 47 tests pass"
|
|
26
75
|
```
|
|
27
76
|
|
|
28
|
-
|
|
77
|
+
#### π§ͺ **Comprehensive Testing Guidelines** (`.ai-agents/rules/agent-testing-guidelines.md`)
|
|
78
|
+
**Problem**: Superficial testing that misses real issues
|
|
79
|
+
**Solution**: Multi-layer validation (database, API, UI, integration) with mandatory evidence
|
|
29
80
|
```bash
|
|
30
|
-
|
|
81
|
+
# Before: Mock everything, hope it works
|
|
82
|
+
# After: Test real systems, prove it works, show evidence
|
|
31
83
|
```
|
|
32
84
|
|
|
33
|
-
|
|
85
|
+
#### π£οΈ **Clear Communication Standards** (`.ai-agents/rules/communication.md`)
|
|
86
|
+
**Problem**: Vague progress reports and unclear accountability
|
|
87
|
+
**Solution**: Structured progress updates with concrete evidence and absolute accountability
|
|
34
88
|
```bash
|
|
35
|
-
|
|
36
|
-
|
|
89
|
+
# Before: "Working on it, almost done"
|
|
90
|
+
# After: "Fixed API timeout, tests passing, evidence attached, ready for review"
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
#### ποΈ **Architectural Discipline** (`.ai-agents/rules/architecture.md`)
|
|
94
|
+
**Problem**: Agents create architectural chaos and technical debt
|
|
95
|
+
**Solution**: Clean separation of concerns, type safety, and testability patterns
|
|
96
|
+
```bash
|
|
97
|
+
# Before: Spaghetti code with mixed responsibilities
|
|
98
|
+
# After: Clean layers with proper boundaries and validation
|
|
37
99
|
```
|
|
38
100
|
|
|
39
|
-
|
|
40
|
-
|
|
101
|
+
#### π― **Spike-First Development** (`.ai-agents/rules/spike-first-development.md`)
|
|
102
|
+
**Problem**: Agents build complex solutions without validating assumptions
|
|
103
|
+
**Solution**: 5-15 minute proof-of-concepts before major implementation
|
|
104
|
+
```bash
|
|
105
|
+
# Before: Build 3-week solution, discover it doesn't work
|
|
106
|
+
# After: 10-minute spike, validate approach, then build confidently
|
|
107
|
+
```
|
|
41
108
|
|
|
42
|
-
|
|
109
|
+
#### π **Continuous Learning System** (`.ai-agents/rules/continuous-learning.md`)
|
|
110
|
+
**Problem**: Same mistakes repeated across projects
|
|
111
|
+
**Solution**: Retrospective-driven knowledge capture and pattern recognition
|
|
112
|
+
```bash
|
|
113
|
+
# Before: Every agent learns the same lessons from scratch
|
|
114
|
+
# After: Knowledge accumulates, patterns emerge, quality improves
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
#### π§Ή **Simplicity Discipline** (`.ai-agents/rules/simplicity.md`)
|
|
118
|
+
**Problem**: Over-engineered solutions that are hard to maintain
|
|
119
|
+
**Solution**: "Keep it simple" principles with complexity budgets
|
|
120
|
+
```bash
|
|
121
|
+
# Before: 500-line solution to a 10-line problem
|
|
122
|
+
# After: Minimal, focused solution that actually works
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
#### π§ **Git Safety & Timeout Management** (`.ai-agents/rules/git-safe-commands.md`)
|
|
126
|
+
**Problem**: Agents hang on interactive Git commands and long-running tasks, requiring human intervention
|
|
127
|
+
**Solution**: Safe Git commands and timeout scripts with output visibility
|
|
128
|
+
```bash
|
|
129
|
+
# Before: Agent hangs on "git log" (opens pager) or tests run forever
|
|
130
|
+
# After: Non-interactive commands with timeouts and log files for visibility
|
|
131
|
+
# Example: exec-with-timeout.ts runs tests with timeout and saves output to files
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
#### π **Merge Requirements & Branch Safety** (`.ai-agents/rules/merge-requirements.md`)
|
|
135
|
+
**Problem**: Agents accidentally overwrite master branch or create merge conflicts
|
|
136
|
+
**Solution**: Mandatory rebase workflows with conflict resolution patterns
|
|
137
|
+
```bash
|
|
138
|
+
# Before: Force pushes that destroy other work
|
|
139
|
+
# After: Rebase-on-master with force-with-lease for safety
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
#### π **Systematic Debugging Patterns** (`.ai-agents/rules/successful-debugging-patterns.md`)
|
|
143
|
+
**Problem**: Agents struggle with complex debugging and repeat the same mistakes
|
|
144
|
+
**Solution**: Structured debugging methodology with evidence collection and pattern recognition
|
|
145
|
+
```bash
|
|
146
|
+
# Before: Random debugging attempts, no learning
|
|
147
|
+
# After: Systematic approach with documented patterns and regression tests
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
#### π **Package Scripts & Output Visibility** (`.ai-agents/scripts/` and `sample_package.json`)
|
|
151
|
+
**Problem**: Long-running tasks hang agents and provide no visibility into progress
|
|
152
|
+
**Solution**: Background execution with log files and timeout management
|
|
153
|
+
```bash
|
|
154
|
+
# Before: "npm test" hangs agent, no output visibility
|
|
155
|
+
# After: "npm test" runs in background, saves to test.log, agent can observe progress
|
|
156
|
+
# Example: exec-with-timeout.ts prevents hangs and provides output visibility
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
## π **Proven Benefits from Real Projects**
|
|
160
|
+
|
|
161
|
+
- **Dramatic reduction** in AI-generated code that needs rework through evidence-based validation
|
|
162
|
+
- **Faster delivery** through structured workflows and clear handoffs
|
|
163
|
+
- **Higher test coverage** through mandatory testing guidelines and evidence collection
|
|
164
|
+
- **Zero agent conflicts** through phase-based isolation and coordination
|
|
165
|
+
- **Complete accountability** - agents fix their own mistakes with evidence
|
|
166
|
+
|
|
167
|
+
## π¬ **The FRAIM Experience: From Chaos to Clarity**
|
|
168
|
+
|
|
169
|
+
### **Before FRAIM: Single Agent Chaos**
|
|
170
|
+
```bash
|
|
171
|
+
# You: "Add user authentication to the app"
|
|
172
|
+
# Agent: "I'll add login functionality"
|
|
173
|
+
#
|
|
174
|
+
# 10 minutes later...
|
|
175
|
+
# Agent: "I've designed the UX to be modern and beautiful. What do you think?"
|
|
176
|
+
# You: "It's way too complex and does not work with the rest of the product. Just make it simple"
|
|
177
|
+
# Agent: "You are right. I've made it too complex, let me simplify it right now"
|
|
178
|
+
# You: "I've told you this 10 times already!!!! "
|
|
179
|
+
#
|
|
180
|
+
# 1 hour later...
|
|
181
|
+
# Agent: "Implementation complete. Solution looks good."
|
|
182
|
+
# You: "I get an error on the first screen."
|
|
183
|
+
# Agent: "What error do you see? Can you write it out for me or give me a screenshot?"
|
|
184
|
+
# You: "C'mon, do this yourself."
|
|
185
|
+
#
|
|
186
|
+
# 2 hours later...
|
|
187
|
+
# Agent: <Stuck waiting for a playwright test which hasn't relinquished control>
|
|
188
|
+
# You: "You've made no progress"
|
|
189
|
+
# Agent: "You are right. I keep getting stuck. Could you test the implementation for me?"
|
|
190
|
+
#
|
|
191
|
+
# 3 hours later...
|
|
192
|
+
# Agent: "Ok I'm all done, test cases are passing"
|
|
193
|
+
# You: "Wait, what... you changed existing tests to make them pass ... everything is broken!!"
|
|
194
|
+
```
|
|
195
|
+
|
|
196
|
+
### **After FRAIM: Single Agent Excellence**
|
|
197
|
+
```bash
|
|
198
|
+
# You: "Add user authentication to the app"
|
|
199
|
+
# Agent: "Starting design phase. Creating RFC with UX mockups, validation rules, and API specs"
|
|
200
|
+
#
|
|
201
|
+
# 10 minutes later...
|
|
202
|
+
# Agent: "Design complete. UX mockups created, validation rules defined, API endpoints specified.
|
|
203
|
+
# Evidence: 3 mockup images, validation requirements document, API spec ready for review"
|
|
204
|
+
# You: "Looks good, proceed to implementation"
|
|
205
|
+
#
|
|
206
|
+
# 1 hour later...
|
|
207
|
+
# Agent: "Implementation complete. Code written, tests created, all tests passing.
|
|
208
|
+
# Evidence: Test output showing existing 120/120 tests pass, new 12/12 tests pass, API endpoint tested with curl,
|
|
209
|
+
# UI tested with screenshots showing login form and error states"
|
|
210
|
+
# During PR review...
|
|
211
|
+
# Reviewer: "Password validation is too strict"
|
|
212
|
+
# Agent: "Fixed password validation rules, updated tests, evidence provided.
|
|
213
|
+
# Evidence: New test output showing updated validation, UI screenshots with new rules"
|
|
214
|
+
#
|
|
215
|
+
# Result: In best case, hours of frustration, rework saved. In worst case, reputation saved from deploying broken code to production.
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
## ποΈ **Enterprise-Grade Framework Structure**
|
|
43
219
|
|
|
44
220
|
```
|
|
45
221
|
FRAIM/
|
|
46
|
-
βββ
|
|
47
|
-
βββ
|
|
48
|
-
βββ
|
|
49
|
-
βββ
|
|
50
|
-
βββ
|
|
51
|
-
βββ
|
|
52
|
-
βββ
|
|
53
|
-
β
|
|
54
|
-
βββ
|
|
55
|
-
β
|
|
56
|
-
β
|
|
57
|
-
βββ
|
|
58
|
-
β βββ
|
|
59
|
-
β
|
|
60
|
-
β β βββ rules/ # Modular rule files
|
|
61
|
-
β βββ claude/ # Claude agent configuration (TESTED)
|
|
62
|
-
β β βββ CLAUDE.md # Main configuration
|
|
63
|
-
β β βββ rules/ # Modular rule files
|
|
64
|
-
β βββ windsurf/ # Windsurf agent configuration (TESTED)
|
|
65
|
-
β βββ .windsurfrules # Main configuration
|
|
66
|
-
β βββ rules/ # Modular rule files
|
|
222
|
+
βββ π§ .ai-agents/rules/ # Guardrails - The "HR Handbook" for AI agents
|
|
223
|
+
β βββ integrity-and-test-ethics.md # Prevents "fake it till you make it"
|
|
224
|
+
β βββ agent-testing-guidelines.md # Ensures real validation, not claims
|
|
225
|
+
β βββ communication.md # Clear accountability and progress
|
|
226
|
+
β βββ architecture.md # Prevents technical debt
|
|
227
|
+
β βββ spike-first-development.md # Validates before building
|
|
228
|
+
β βββ continuous-learning.md # Learns from mistakes
|
|
229
|
+
β βββ simplicity.md # Prevents over-engineering
|
|
230
|
+
β βββ git-safe-commands.md # Prevents agent hangs on Git commands
|
|
231
|
+
β βββ merge-requirements.md # Safe branch management and rebasing
|
|
232
|
+
β βββ successful-debugging-patterns.md # Systematic debugging approach
|
|
233
|
+
β βββ local-development.md # Local development best practices
|
|
234
|
+
β βββ pr-workflow-completeness.md # PR workflow validation
|
|
235
|
+
β βββ software-development-lifecycle.md # Full SDLC integration
|
|
67
236
|
β
|
|
68
|
-
βββ workflows/
|
|
69
|
-
β
|
|
237
|
+
βββ π .ai-agents/workflows/ # Process - The "Project Management Office"
|
|
238
|
+
β βββ spec.md # Specification and requirements phase
|
|
239
|
+
β βββ design.md # Structured design phase
|
|
240
|
+
β βββ implement.md # Implementation with validation
|
|
241
|
+
β βββ test.md # Comprehensive testing
|
|
242
|
+
β βββ resolve.md # Issue resolution workflow
|
|
243
|
+
β βββ retrospect.md # Learning and improvement
|
|
70
244
|
β
|
|
71
|
-
βββ
|
|
72
|
-
β βββ
|
|
73
|
-
β βββ
|
|
74
|
-
β βββ
|
|
245
|
+
βββ π .ai-agents/templates/ # Human Interfaces - The "Standard Operating Procedures"
|
|
246
|
+
β βββ evidence/ # Proof of work templates
|
|
247
|
+
β βββ retrospective/ # Learning capture templates
|
|
248
|
+
β βββ specs/ # Specification templates
|
|
75
249
|
β
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
βββ examples/ # Example implementations
|
|
81
|
-
βββ simple-webapp/ # Sample project with FRAIM config
|
|
82
|
-
βββ README.md # Project documentation
|
|
83
|
-
βββ fraim-config.json # Sample configuration
|
|
250
|
+
βββ π οΈ Scripts & Automation # Determinism - The "DevOps Pipeline"
|
|
251
|
+
βββ prep-issue.sh # Issue preparation
|
|
252
|
+
βββ exec-with-timeout.ts # Command execution with timeout & output visibility
|
|
253
|
+
βββ cleanup-branch.ts # Branch management
|
|
84
254
|
```
|
|
85
255
|
|
|
86
|
-
##
|
|
256
|
+
## π **Get Started in 60 Seconds**
|
|
87
257
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
258
|
+
### **Install & Initialize**
|
|
259
|
+
```bash
|
|
260
|
+
npm install -g fraim-framework
|
|
261
|
+
fraim init
|
|
262
|
+
```
|
|
91
263
|
|
|
92
|
-
|
|
264
|
+
### **π§ Customize for Your Project**
|
|
93
265
|
|
|
94
|
-
|
|
95
|
-
- **Automated Setup**: Single command to bootstrap FRAIM in any repository
|
|
96
|
-
- **GitHub Integration**: Native GitHub workflows, labels, and automation
|
|
97
|
-
- **Agent Coordination**: Seamless coordination between multiple AI agents
|
|
98
|
-
- **Phase Management**: Structured design β implementation β testing workflows
|
|
99
|
-
- **Enterprise Ready**: Observability, rollbacks, and audit trails built-in
|
|
266
|
+
After installation, customize these files for your specific project:
|
|
100
267
|
|
|
101
|
-
|
|
268
|
+
#### **1. Architecture Rules** (`.ai-agents/rules/architecture.md`)
|
|
269
|
+
- **Purpose**: Define your system's architectural patterns and boundaries
|
|
270
|
+
- **Customize**: Replace generic examples with your specific architecture patterns
|
|
271
|
+
- **Example**: Add your database patterns, API structures, service boundaries
|
|
102
272
|
|
|
103
|
-
|
|
104
|
-
- **
|
|
105
|
-
- **
|
|
106
|
-
- **
|
|
273
|
+
#### **2. Branch Cleanup Script** (`.ai-agents/scripts/cleanup-branch.ts`)
|
|
274
|
+
- **Purpose**: Project-specific cleanup when branches are deleted
|
|
275
|
+
- **Customize**: Add your cleanup logic in the `insertYourCodeHere()` method
|
|
276
|
+
- **Example**: Database cleanup, cache invalidation, temporary file removal
|
|
107
277
|
|
|
108
|
-
|
|
278
|
+
#### **3. Package Scripts** (`sample_package.json` β `package.json`)
|
|
279
|
+
- **Purpose**: Testing and build scripts for your project
|
|
280
|
+
- **Adopt**: Copy relevant scripts from `sample_package.json` into your main `package.json`
|
|
281
|
+
- **Customize**: Update test commands, build processes, and framework-specific commands
|
|
282
|
+
- **Example**: Replace `baml-cli generate` with your framework's generate command
|
|
109
283
|
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
284
|
+
#### **4. Test Utilities** (`test-utils.ts` β your project)
|
|
285
|
+
- **Purpose**: Generic test framework with tagging system
|
|
286
|
+
- **Adopt**: Copy `test-utils.ts` into your project and import in your test files
|
|
287
|
+
- **Customize**: Extend `BaseTestCase` interface for your specific test needs
|
|
288
|
+
- **Example**: Create domain-specific test cases using the tagging system
|
|
289
|
+
|
|
290
|
+
#### **5. Test Structure** (`examples/simple-webapp/example-test.ts`)
|
|
291
|
+
- **Purpose**: Example test cases with proper tagging
|
|
292
|
+
- **Adopt**: Use as a template for your project's test structure
|
|
293
|
+
- **Customize**: Replace with your project's test cases and domain-specific tags
|
|
294
|
+
- **Example**: Add your specific test scenarios and validation patterns
|
|
114
295
|
|
|
115
|
-
|
|
116
|
-
npx fraim-framework rigor
|
|
296
|
+
## π― **The Transformation: From Developer to AI Manager**
|
|
117
297
|
|
|
118
|
-
|
|
119
|
-
|
|
298
|
+
### **Phase 1: Setup (5 minutes)**
|
|
299
|
+
```bash
|
|
300
|
+
npx fraim-framework init
|
|
301
|
+
# β
Repository configured with AI management rules
|
|
302
|
+
# β
Agents assigned to specific roles (Design, Implementation, Testing)
|
|
303
|
+
# β
Workflows and templates installed
|
|
120
304
|
```
|
|
121
305
|
|
|
122
|
-
###
|
|
306
|
+
### **Phase 2: Issue Management (30 seconds per issue)**
|
|
123
307
|
```bash
|
|
124
|
-
|
|
125
|
-
|
|
308
|
+
gh issue create --title "Add user authentication" --label "ai-agent:cursor"
|
|
309
|
+
# β
Git issue is centralized coordination point
|
|
310
|
+
# β
Agent assignment handled
|
|
311
|
+
# β
Ready for work
|
|
312
|
+
```
|
|
126
313
|
|
|
127
|
-
|
|
128
|
-
|
|
314
|
+
### **Phase 3: Orchestrated Development**
|
|
315
|
+
```bash
|
|
316
|
+
scripts/development/prep-issue.sh #issue_number
|
|
317
|
+
# β
Local clone and new branch created
|
|
318
|
+
# β
Coding agent initiated
|
|
319
|
+
# β
Tell coding agent which phase it should proceed with
|
|
129
320
|
```
|
|
130
321
|
|
|
131
|
-
##
|
|
322
|
+
## π **Why FRAIM is the Future**
|
|
132
323
|
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
- **Workflow Efficiency**: 50% reduction in development cycle time
|
|
136
|
-
- **Quality**: Built-in reviews and validation at every phase
|
|
137
|
-
- **Reliability**: Tested rules prevent common coordination failures
|
|
324
|
+
### **1. Proven in Production**
|
|
325
|
+
Every rule, workflow, and pattern has been tested in real projects. This isn't theoreticalβit's battle-tested.
|
|
138
326
|
|
|
139
|
-
|
|
327
|
+
### **2. Enterprise Discipline**
|
|
328
|
+
The same rigor you'd apply to managing human developers, applied to AI agents.
|
|
140
329
|
|
|
141
|
-
|
|
142
|
-
-
|
|
143
|
-
- **Documentation**: [Framework Docs](https://github.com/mathursrus/Ashley-Calendar-AI/tree/master/FRAIM/docs)
|
|
144
|
-
- **Distribution**: [DISTRIBUTION.md](DISTRIBUTION.md)
|
|
330
|
+
### **3. Continuous Improvement**
|
|
331
|
+
Built-in learning systems that make your AI agents better over time.
|
|
145
332
|
|
|
146
|
-
|
|
333
|
+
### **4. Complete Transparency**
|
|
334
|
+
Full visibility into what each agent is doing, with evidence-based validation.
|
|
147
335
|
|
|
148
|
-
|
|
336
|
+
### **5. Zero Vendor Lock-in**
|
|
337
|
+
Works with any AI agent (Cursor, Claude, Windsurf, future agents).
|
|
338
|
+
|
|
339
|
+
|
|
340
|
+
## π **Ready to Transform Your Development?**
|
|
341
|
+
|
|
342
|
+
### **Start Your AI Management Journey**
|
|
149
343
|
|
|
150
|
-
**Start your journey today:**
|
|
151
344
|
```bash
|
|
152
|
-
|
|
345
|
+
# Watch the magic happen
|
|
346
|
+
gh issue create --title "Add API rate limiting" --label "phase:design"
|
|
347
|
+
# β Agent: "RFC created, architecture validated, ready for implementation"
|
|
348
|
+
|
|
349
|
+
gh issue edit 123 --remove-label "phase:design" --add-label "phase:impl"
|
|
350
|
+
# β Agent: "Implementation complete, tests passing, evidence provided"
|
|
351
|
+
|
|
352
|
+
gh issue edit 123 --remove-label "phase:impl" --add-label "phase:tests"
|
|
353
|
+
# β Agent: "Performance validated, security checked, ready for production"
|
|
354
|
+
|
|
355
|
+
# Result: Production-ready feature in 2 hours instead of 2 days
|
|
153
356
|
```
|
|
154
357
|
|
|
358
|
+
|
|
359
|
+
|
|
360
|
+
### **Join the Future of Development**
|
|
361
|
+
|
|
362
|
+
- π [**GitHub Repository**](https://github.com/mathursrus/FRAIM) - Star us to follow development
|
|
363
|
+
- π [**Issue Tracker**](https://github.com/mathursrus/FRAIM/issues) - Report bugs or request features
|
|
364
|
+
|
|
155
365
|
---
|
|
156
366
|
|
|
157
|
-
|
|
367
|
+
## π― **The Bottom Line**
|
|
368
|
+
|
|
369
|
+
**FRAIM isn't just about using AIβit's about managing AI teams with the same discipline you'd apply to human teams.**
|
|
370
|
+
|
|
371
|
+
Stop fighting with AI agents. Start orchestrating them.
|
|
372
|
+
|
|
373
|
+
**This is the future of how we work.**
|
|
374
|
+
|
|
375
|
+
---
|
|
376
|
+
|
|
377
|
+
<div align="center">
|
|
378
|
+
|
|
379
|
+
**π Ready to become an AI manager? Start with FRAIM today.**
|
|
380
|
+
|
|
381
|
+
[](https://www.npmjs.com/package/fraim-framework)
|
|
382
|
+
[](https://github.com/mathursrus/FRAIM/stargazers)
|
|
383
|
+
[](https://opensource.org/licenses/MIT)
|
|
158
384
|
|
|
159
|
-
|
|
385
|
+
</div>
|
package/bin/fraim.js
CHANGED
|
@@ -28,7 +28,7 @@ function showHelp() {
|
|
|
28
28
|
console.log(' O - Observability: Complete visibility into AI activities');
|
|
29
29
|
console.log(' R - Retrospectives: Continuous learning from experience\n');
|
|
30
30
|
|
|
31
|
-
console.log('π Documentation: https://github.com/mathursrus/
|
|
31
|
+
console.log('π Documentation: https://github.com/mathursrus/FRAIM');
|
|
32
32
|
console.log('π― Ready to become an AI manager? Run: npx fraim-framework init');
|
|
33
33
|
}
|
|
34
34
|
|
|
@@ -70,6 +70,42 @@ function showRigor() {
|
|
|
70
70
|
console.log('β¨ Every rule has been tested and proven in real project environments.');
|
|
71
71
|
}
|
|
72
72
|
|
|
73
|
+
function showStructure() {
|
|
74
|
+
console.log(banner);
|
|
75
|
+
console.log('π FRAIM Framework Structure\n');
|
|
76
|
+
|
|
77
|
+
console.log('π /rules/ - Centralized rules for all AI agents');
|
|
78
|
+
console.log(' β’ integrity-and-test-ethics.md - Core ethical principles');
|
|
79
|
+
console.log(' β’ simplicity.md - Keep solutions simple and focused');
|
|
80
|
+
console.log(' β’ architecture.md - Technical architecture principles');
|
|
81
|
+
console.log(' β’ continuous-learning.md - Learn from retrospectives and RFCs');
|
|
82
|
+
console.log(' β’ successful-debugging-patterns.md - Debug issues systematically\n');
|
|
83
|
+
|
|
84
|
+
console.log('π /workflows/ - Development phase workflows');
|
|
85
|
+
console.log(' β’ design.md - Design phase workflow');
|
|
86
|
+
console.log(' β’ implement.md - Implementation phase workflow');
|
|
87
|
+
console.log(' β’ test.md - Testing phase workflow');
|
|
88
|
+
console.log(' β’ resolve.md - Issue resolution workflow');
|
|
89
|
+
console.log(' β’ retrospect.md - Retrospective workflow\n');
|
|
90
|
+
|
|
91
|
+
console.log('π /templates/ - Standardized templates');
|
|
92
|
+
console.log(' β’ /evidence/ - Test evidence templates');
|
|
93
|
+
console.log(' β’ /retrospective/ - Retrospective templates');
|
|
94
|
+
console.log(' β’ /specs/ - Specification templates');
|
|
95
|
+
console.log(' β’ /help/ - Help documentation templates\n');
|
|
96
|
+
|
|
97
|
+
console.log('π /.github/ - GitHub configuration');
|
|
98
|
+
console.log(' β’ /workflows/ - GitHub Actions workflows');
|
|
99
|
+
console.log(' β’ pull_request_template.md - PR template\n');
|
|
100
|
+
|
|
101
|
+
console.log('π /scripts/ - Automation scripts');
|
|
102
|
+
console.log(' β’ ensure-tests-present.sh - Test validation script');
|
|
103
|
+
console.log(' β’ exec-with-timeout.sh - Command execution with timeout');
|
|
104
|
+
console.log(' β’ prep-issue.sh - Issue preparation for AI agents\n');
|
|
105
|
+
|
|
106
|
+
console.log('π― This structure provides a comprehensive framework for AI agent management!');
|
|
107
|
+
}
|
|
108
|
+
|
|
73
109
|
async function runSetup() {
|
|
74
110
|
try {
|
|
75
111
|
// Import and run the setup script
|
|
@@ -109,6 +145,11 @@ async function main() {
|
|
|
109
145
|
return;
|
|
110
146
|
}
|
|
111
147
|
|
|
148
|
+
if (args.includes('structure')) {
|
|
149
|
+
showStructure();
|
|
150
|
+
return;
|
|
151
|
+
}
|
|
152
|
+
|
|
112
153
|
if (args.includes('init') || args.includes('setup')) {
|
|
113
154
|
console.log(banner);
|
|
114
155
|
console.log('π Setting up FRAIM in current repository...\n');
|
|
@@ -129,5 +170,10 @@ async function main() {
|
|
|
129
170
|
showHelp();
|
|
130
171
|
}
|
|
131
172
|
|
|
132
|
-
//
|
|
133
|
-
main
|
|
173
|
+
// Export the main function for use in other files
|
|
174
|
+
module.exports = { main };
|
|
175
|
+
|
|
176
|
+
// Run the CLI if this file is executed directly
|
|
177
|
+
if (require.main === module) {
|
|
178
|
+
main();
|
|
179
|
+
}
|
package/index.js
CHANGED
|
@@ -35,6 +35,33 @@ module.exports.FRAIM_INFO = {
|
|
|
35
35
|
'Retrospectives: Continuous learning from mistakes and positive experiences'
|
|
36
36
|
],
|
|
37
37
|
supportedAgents: ['cursor', 'claude', 'windsurf'],
|
|
38
|
-
repository: 'https://github.com/mathursrus/
|
|
39
|
-
note: 'All rules and workflows have been tested and proven in real project environments'
|
|
40
|
-
|
|
38
|
+
repository: 'https://github.com/mathursrus/FRAIM',
|
|
39
|
+
note: 'All rules and workflows have been tested and proven in real project environments',
|
|
40
|
+
|
|
41
|
+
// New structure information
|
|
42
|
+
structure: {
|
|
43
|
+
rules: '/rules/',
|
|
44
|
+
workflows: '/workflows/',
|
|
45
|
+
templates: '/templates/',
|
|
46
|
+
scripts: '/scripts/',
|
|
47
|
+
github: '/.github/'
|
|
48
|
+
},
|
|
49
|
+
|
|
50
|
+
// Centralized rules
|
|
51
|
+
centralizedRules: [
|
|
52
|
+
'integrity-and-test-ethics.md',
|
|
53
|
+
'simplicity.md',
|
|
54
|
+
'architecture.md',
|
|
55
|
+
'continuous-learning.md',
|
|
56
|
+
'successful-debugging-patterns.md'
|
|
57
|
+
],
|
|
58
|
+
|
|
59
|
+
// Workflow templates
|
|
60
|
+
workflowTemplates: [
|
|
61
|
+
'design.md',
|
|
62
|
+
'implement.md',
|
|
63
|
+
'test.md',
|
|
64
|
+
'resolve.md',
|
|
65
|
+
'retrospect.md'
|
|
66
|
+
]
|
|
67
|
+
};
|