rpi-kit 1.4.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/.claude-plugin/marketplace.json +9 -6
  2. package/.claude-plugin/plugin.json +4 -4
  3. package/AGENTS.md +2016 -117
  4. package/CHANGELOG.md +83 -0
  5. package/README.md +116 -169
  6. package/agents/atlas.md +61 -0
  7. package/agents/clara.md +49 -0
  8. package/agents/forge.md +38 -0
  9. package/agents/hawk.md +54 -0
  10. package/agents/luna.md +50 -0
  11. package/agents/mestre.md +61 -0
  12. package/agents/nexus.md +63 -0
  13. package/agents/pixel.md +48 -0
  14. package/agents/quill.md +40 -0
  15. package/agents/razor.md +41 -0
  16. package/agents/sage.md +52 -0
  17. package/agents/scout.md +49 -0
  18. package/agents/shield.md +51 -0
  19. package/bin/cli.js +160 -53
  20. package/bin/onboarding.js +46 -28
  21. package/commands/rpi/archive.md +149 -0
  22. package/commands/rpi/docs.md +106 -168
  23. package/commands/rpi/implement.md +163 -401
  24. package/commands/rpi/init.md +150 -67
  25. package/commands/rpi/learn.md +114 -0
  26. package/commands/rpi/new.md +85 -155
  27. package/commands/rpi/onboarding.md +157 -336
  28. package/commands/rpi/party.md +212 -0
  29. package/commands/rpi/plan.md +241 -205
  30. package/commands/rpi/research.md +162 -104
  31. package/commands/rpi/review.md +350 -104
  32. package/commands/rpi/rpi.md +125 -0
  33. package/commands/rpi/simplify.md +156 -93
  34. package/commands/rpi/status.md +91 -114
  35. package/package.json +7 -3
  36. package/skills/rpi-agents/SKILL.md +63 -39
  37. package/skills/rpi-workflow/SKILL.md +160 -186
  38. package/agents/code-reviewer.md +0 -108
  39. package/agents/code-simplifier.md +0 -82
  40. package/agents/cto-advisor.md +0 -61
  41. package/agents/doc-synthesizer.md +0 -67
  42. package/agents/doc-writer.md +0 -37
  43. package/agents/explore-codebase.md +0 -88
  44. package/agents/plan-executor.md +0 -95
  45. package/agents/product-manager.md +0 -59
  46. package/agents/requirement-parser.md +0 -51
  47. package/agents/senior-engineer.md +0 -61
  48. package/agents/test-engineer.md +0 -23
  49. package/agents/ux-designer.md +0 -58
  50. package/codex.md +0 -72
  51. package/commands/rpi/add-todo.md +0 -83
  52. package/commands/rpi/set-profile.md +0 -124
  53. package/commands/rpi/test.md +0 -198
package/CHANGELOG.md ADDED
@@ -0,0 +1,83 @@
1
+ # Changelog
2
+
3
+ ## [2.0.0] - 2026-03-17
4
+
5
+ ### Breaking Changes
6
+ - Complete rewrite -- v1 command files replaced
7
+ - New directory structure: rpi/features/, rpi/specs/, rpi/solutions/
8
+ - .rpi.yaml schema changed (v1 configs need re-init)
9
+
10
+ ### Added
11
+ - 13 named agents with rich personas (Luna, Atlas, Scout, Nexus, Mestre, Clara, Pixel, Forge, Sage, Razor, Hawk, Shield, Quill)
12
+ - /rpi auto-flow command (detects phase and progresses)
13
+ - /rpi:party multi-agent debate mode
14
+ - /rpi:learn knowledge compounding
15
+ - /rpi:archive delta spec merging
16
+ - /rpi:onboarding guided first-time setup
17
+ - Delta specs system (rpi/specs/ + rpi/features/{slug}/delta/)
18
+ - Knowledge base (rpi/solutions/)
19
+ - Project context (rpi/context.md)
20
+ - Quick flow (--quick flag)
21
+ - Adversarial review (Hawk forced to find problems)
22
+ - Security audit (Shield -- OWASP, secrets scan)
23
+
24
+ ### Removed
25
+ - v1 agents (requirement-parser, explore-codebase, senior-engineer, etc.)
26
+ - /rpi:test (merged into implement via Sage)
27
+ - /rpi:add-todo
28
+ - /rpi:set-profile
29
+ - Session isolation tiers
30
+ - Change/sub-feature system
31
+
32
+ ## [Unreleased]
33
+
34
+ ### Added
35
+
36
+ - **Model Profiles** -- 4 pre-defined profiles (`quality-first`, `balanced`, `speed-first`, `budget`) that control which AI model runs each workflow phase
37
+ - **`/rpi:set-profile` command** -- display current profile, switch between profiles, or remove profile interactively
38
+ - **Per-phase model overrides** -- customize individual phases in `.rpi.yaml` `models:` block (overrides take precedence over profile)
39
+ - **Profile selection in `/rpi:init`** -- Batch 5 asks about model profile during project initialization
40
+ - **Active profile in `/rpi:status`** -- status output now shows the active profile with phase-model mapping
41
+
42
+ ### Changed
43
+
44
+ - **Separate sessions for simplify and review** -- `/rpi:implement` no longer runs simplify/review inline; outputs next-step instructions to run each in a fresh session for better accuracy
45
+ - Removed `auto_simplify` and `review_after_implement` config keys (no longer needed)
46
+ - Removed `--skip-simplify` and `--skip-review` flags from `/rpi:implement`
47
+ - 7 commands (`/rpi:research`, `/rpi:plan`, `/rpi:implement`, `/rpi:test`, `/rpi:simplify`, `/rpi:review`, `/rpi:docs`) now resolve model via the Model Resolution Algorithm and pass `model` parameter to Agent tool invocations
48
+ - `skills/rpi-workflow/SKILL.md` extended with Model Resolution Algorithm section and config schema for `profile`/`models` keys
49
+
50
+ ## 0.2.0
51
+
52
+ ### Added
53
+
54
+ - **Test-Driven Development (TDD) workflow** -- strict RED -> GREEN -> REFACTOR cycles integrated into the implementation phase
55
+ - **Test Engineer agent** (`agents/test-engineer.md`) -- writes one failing test at a time before implementation, follows strict TDD discipline
56
+ - **`/rpi:test` command** -- standalone TDD cycles per task (`--task <id>`) or all tasks (`--all`), works independently of `/rpi:implement`
57
+ - **`Test:` field in PLAN.md** -- every task now includes a behavior assertion describing what to test (e.g., "returns 404 for missing user")
58
+ - **TDD config options** in `.rpi.yaml`: `tdd: true/false` and `test_runner: auto|command`
59
+ - **Test coverage checks** in `/rpi:review` -- verifies tests exist, exercise public interfaces, and cover edge cases
60
+ - **TDD init questions** in `/rpi:init` -- Batch 4 asks about TDD preference and test runner
61
+
62
+ ### Changed
63
+
64
+ - `/rpi:implement` now branches per task: TDD mode (RED -> VERIFY -> GREEN -> VERIFY -> REFACTOR) or classic mode based on config
65
+ - `/rpi:plan` task format includes `Test:` field and enforces concrete test descriptions
66
+ - `/rpi:review` adds test coverage as a review dimension alongside completeness, correctness, and deviations
67
+ - Agent count updated from 10 to 11 across all docs
68
+ - Comparison table includes TDD row as differentiator
69
+
70
+ ## 0.1.0
71
+
72
+ ### Added
73
+
74
+ - Initial release
75
+ - Research -> Plan -> Implement workflow with validation gates
76
+ - 10 specialized agents (requirement-parser, product-manager, ux-designer, senior-engineer, cto-advisor, doc-synthesizer, explore-codebase, plan-executor, code-simplifier, code-reviewer)
77
+ - Research tiers (quick, standard, deep) with parallel fan-out
78
+ - Adaptive plan artifacts (PLAN.md, eng.md, pm.md, ux.md)
79
+ - Smart execution mode (sequential vs parallel waves)
80
+ - Code simplification (reuse, quality, efficiency)
81
+ - Code review against plan requirements
82
+ - Cross-session continuity via markdown files
83
+ - Codex compatibility via AGENTS.md and codex.md
package/README.md CHANGED
@@ -1,218 +1,165 @@
1
- # RPIKit
1
+ # RPIKit -- Research -> Plan -> Implement
2
2
 
3
- **Research Plan Implement.** A systematic feature development workflow for Claude Code and Codex.
3
+ AI-assisted feature development with 13 named agents, delta specs, and knowledge compounding.
4
4
 
5
- RPIKit guides AI-first developers through a structured 3-phase pipeline with validation gates, multi-role agent teams, and adaptive depth so you research before you plan, and plan before you code.
5
+ RPIKit is a Claude Code plugin that guides developers through a structured 7-phase pipeline. Each phase is run by specialized agents with distinct personas -- so you research before you plan, plan before you code, and review before you ship.
6
6
 
7
- ## Install
8
-
9
- ### Claude Code
10
-
11
- **From the marketplace (recommended):**
7
+ ## Quick Start
12
8
 
13
9
  ```bash
10
+ # Install from marketplace
14
11
  claude plugin install rpi-kit
15
- ```
16
-
17
- **From npm:**
18
-
19
- ```bash
20
- npm install -g rpi-kit
21
- ```
22
-
23
- The postinstall script registers the plugin automatically. If it fails, register manually:
24
-
25
- ```bash
26
- claude plugin install /path/to/rpi-kit
27
- ```
28
12
 
29
- > **Tip:** `npm root -g` shows where global packages are installed. The path is usually something like `~/.nvm/versions/node/vX.X.X/lib/node_modules/rpi-kit`.
13
+ # First time: guided setup
14
+ /rpi:onboarding
30
15
 
31
- **From source:**
32
-
33
- ```bash
34
- git clone https://github.com/dmend3z/rpi-kit.git
35
- claude --plugin-dir ./rpi-kit
36
- ```
37
-
38
- ### Codex (OpenAI)
39
-
40
- Copy `AGENTS.md` and `codex.md` to your project root. The workflow rules and agent definitions will be available to Codex automatically.
41
-
42
- ## Quick Start
43
-
44
- ```bash
45
- # 1. Initialize config (once per project)
16
+ # Or configure manually
46
17
  /rpi:init
18
+ ```
47
19
 
48
- # 2. Describe your feature
49
- /rpi:new oauth2-auth
20
+ ## How It Works
50
21
 
51
- # 3. Research feasibility (GO/NO-GO verdict)
52
- /rpi:research oauth2-auth
22
+ RPIKit breaks feature development into 7 phases, each driven by named agents:
53
23
 
54
- # 4. Generate implementation plan
55
- /rpi:plan oauth2-auth
24
+ | # | Phase | Command | Agents | Output |
25
+ |---|-------|---------|--------|--------|
26
+ | 1 | **Request** | `/rpi:new` | Luna | `REQUEST.md` -- elicited requirements |
27
+ | 2 | **Research** | `/rpi:research` | Atlas + Scout + Nexus | `RESEARCH.md` -- GO/NO-GO verdict |
28
+ | 3 | **Plan** | `/rpi:plan` | Mestre + Clara + Pixel + Nexus | `PLAN.md` + `eng.md` + `pm.md` + `ux.md` + `delta/` |
29
+ | 4 | **Implement** | `/rpi:implement` | Forge + Sage | Code + `IMPLEMENT.md` |
30
+ | 5 | **Simplify** | `/rpi:simplify` | Razor | Simplified code |
31
+ | 6 | **Review** | `/rpi:review` | Hawk + Shield + Sage + Nexus | PASS / FAIL verdict |
32
+ | 7 | **Docs** | `/rpi:docs` | Quill | Updated documentation |
56
33
 
57
- # 5. Build it (with automatic simplify + review)
58
- /rpi:implement oauth2-auth
59
- ```
34
+ Use `/rpi <feature>` to auto-detect the current phase and progress to the next one.
60
35
 
61
36
  ## Commands
62
37
 
63
- | Command | Purpose |
64
- |---------|---------|
65
- | `/rpi:init` | Configure RPI for this project (folder, tier, preferences) |
66
- | `/rpi:new` | Interactive interview REQUEST.md |
67
- | `/rpi:research` | Parallel agent research RESEARCH.md + GO/NO-GO |
68
- | `/rpi:plan` | Adaptive plan artifacts PLAN.md + eng/pm/ux.md |
69
- | `/rpi:implement` | Execute plan with task tracking + simplify + review |
70
- | `/rpi:test` | TDD cycles (RED GREEN → REFACTOR) per task |
71
- | `/rpi:simplify` | Code simplification (reuse, quality, efficiency) |
38
+ | Command | Description |
39
+ |---------|-------------|
40
+ | `/rpi <feature>` | Auto-progress to next phase -- detects current state and runs the appropriate step |
41
+ | `/rpi:new <feature>` | Interactive interview with Luna to create REQUEST.md |
42
+ | `/rpi:research <feature>` | Codebase analysis (Atlas) + technical investigation (Scout) |
43
+ | `/rpi:plan <feature>` | Architecture (Mestre) + product spec (Clara) + UX (Pixel) |
44
+ | `/rpi:implement <feature>` | Execute PLAN.md tasks with per-task commits (Forge) |
45
+ | `/rpi:simplify <feature>` | Dead code removal and simplification (Razor) |
46
+ | `/rpi:review <feature>` | Adversarial review (Hawk) + security audit (Shield) + test coverage (Sage) |
47
+ | `/rpi:docs <feature>` | Generate documentation from artifacts (Quill) |
48
+ | `/rpi:init` | Configure RPIKit and generate `rpi/context.md` |
72
49
  | `/rpi:status` | Show all features and their current phase |
73
- | `/rpi:review` | Code review against plan requirements + test coverage |
74
- | `/rpi:docs` | Generate documentation from implementation artifacts |
75
- | `/rpi:add-todo` | Capture quick implementation ideas in `{folder}/todos/` |
76
- | `/rpi:set-profile` | Switch the active model profile for agent execution |
50
+ | `/rpi:party <topic>` | Multi-agent debate on any topic |
51
+ | `/rpi:learn` | Save a solution or insight to the knowledge base |
52
+ | `/rpi:archive <feature>` | Merge delta specs into `rpi/specs/` and clean up |
53
+ | `/rpi:onboarding` | Guided first-time setup with codebase analysis |
77
54
 
78
- ## Research Tiers
55
+ ## Agents
79
56
 
80
- Control depth and cost with tier flags:
57
+ RPIKit uses 13 named agents, each with a distinct persona:
81
58
 
82
- | Tier | Agents | Use when |
83
- |------|--------|----------|
84
- | `--quick` | 2 (requirements + codebase) | Small features, quick feasibility check |
85
- | `--standard` | 4 (+ PM + engineer) | Default. Most features. |
86
- | `--deep` | 5-6 (+ CTO + UX designer if UI) | Large features, risky changes, new architecture |
59
+ | Agent | Persona | Phase | Tools |
60
+ |-------|---------|-------|-------|
61
+ | **Luna** | Curious analyst who asks uncomfortable questions | Request | Read, Glob, Grep, AskUserQuestion |
62
+ | **Atlas** | Methodical explorer who maps every corner of the codebase | Research | Read, Glob, Grep |
63
+ | **Scout** | Skeptical investigator who researches external options | Research | Read, Glob, Grep, WebSearch, WebFetch |
64
+ | **Nexus** | Diplomatic synthesizer who merges outputs and facilitates debates | Cross-phase + Party | Read, Write, Glob, Grep, Agent, AskUserQuestion |
65
+ | **Mestre** | Pragmatic architect who hates over-engineering | Plan | Read, Glob, Grep |
66
+ | **Clara** | Value-driven PM who cuts scope without mercy | Plan | Read, Glob, Grep |
67
+ | **Pixel** | Empathetic UX designer who thinks from the user's perspective | Plan (conditional) | Read, Glob, Grep |
68
+ | **Forge** | Disciplined executor who follows the plan precisely | Implement | Read, Write, Edit, Bash, Glob, Grep |
69
+ | **Sage** | Paranoid tester who thinks in edge cases | Implement (TDD) + Review | Read, Write, Edit, Bash, Glob, Grep |
70
+ | **Razor** | Minimalist simplifier who measures quality by deletion count | Simplify | Read, Write, Edit, Bash, Glob, Grep |
71
+ | **Hawk** | Adversarial reviewer forced to find problems (zero findings = re-analyse) | Review | Read, Glob, Grep |
72
+ | **Shield** | Security sentinel who thinks like an attacker (OWASP, secrets, injection) | Review | Read, Glob, Grep |
73
+ | **Quill** | Concise technical writer who explains the "why", not the "what" | Docs | Read, Write, Edit, Glob, Grep |
87
74
 
88
- ## Agent Team
75
+ ## Key Features
89
76
 
90
- RPIKit simulates a product team with 12 specialized agents:
77
+ ### Delta Specs
91
78
 
92
- | Agent | Perspective |
93
- |-------|-------------|
94
- | Requirement Parser | Structured requirements, unknowns, implicit needs |
95
- | Product Manager | Scope, user stories, effort, acceptance criteria |
96
- | UX Designer | User flows, interaction patterns, existing components |
97
- | Senior Engineer | Architecture, dependencies, technical decisions |
98
- | CTO Advisor | Risk assessment, strategic alignment, alternatives |
99
- | Doc Synthesizer | Merges research into executive summary + verdict |
100
- | Codebase Explorer | Scans existing code for patterns and context |
101
- | Plan Executor | Implements tasks surgically, one at a time |
102
- | Test Engineer | Writes failing tests before implementation (TDD) |
103
- | Code Simplifier | Reuse, quality, efficiency checks with direct fixes |
104
- | Code Reviewer | Reviews against plan requirements + test coverage |
105
- | Doc Writer | Generates documentation from artifacts for completed features |
79
+ Instead of maintaining full specifications, RPIKit captures only what changes. During planning, Mestre generates `delta/ADDED/`, `delta/MODIFIED/`, and `delta/REMOVED/` directories. On archive, Nexus merges deltas into `rpi/specs/`.
106
80
 
107
- All agents follow behavioral constraints inspired by [Karpathy's coding guidelines](https://x.com/karpathy/status/2015883857489522876): cite evidence, name unknowns, be concrete, stay in scope.
81
+ ### Party Mode
108
82
 
109
- ## Test-Driven Development
83
+ `/rpi:party "GraphQL vs REST?"` starts a multi-agent debate. Nexus selects 3-5 relevant agents, each argues from their persona's perspective, and Nexus synthesizes a recommendation. Results can be saved to `rpi/solutions/decisions/`.
110
84
 
111
- RPIKit supports strict TDD workflows. When enabled, each task follows vertical slices:
85
+ ### Knowledge Compounding
112
86
 
113
- ```
114
- RED (write one failing test) → VERIFY RED → GREEN (minimal code) → VERIFY GREEN → REFACTOR → commit
115
- ```
87
+ Solutions discovered during review are automatically saved to `rpi/solutions/`. Use `/rpi:learn` to manually save insights. During research, Scout searches past solutions before looking externally.
116
88
 
117
- ### Why vertical slices?
89
+ ### Auto-Flow
118
90
 
119
- LLMs tend to write tests in bulk ("horizontal slices"), creating tests that mock internals and verify imagined behavior. Vertical slices force one-test-at-a-time cycles if a test fails first, the implementation can't be faked.
91
+ `/rpi <feature>` detects the current phase by checking which artifacts exist and runs the next phase automatically. No need to remember which command comes next.
120
92
 
121
- ### Enable TDD
93
+ ### Quick Flow
122
94
 
123
- ```yaml
124
- # .rpi.yaml
125
- tdd: true
126
- test_runner: auto # or "npm test", "npx vitest", "pytest", etc.
127
- ```
95
+ For small features, use `--quick` to skip the full research and plan phases. Luna asks 1-2 questions, Forge generates a mini-plan inline, and Razor does a quick simplify. If Forge detects complexity > S during implementation, it stops and suggests the full pipeline.
128
96
 
129
- ### Two ways to use TDD
97
+ ## Configuration
130
98
 
131
- 1. **Integrated:** Enable `tdd: true` in config. `/rpi:implement` automatically runs RED GREEN REFACTOR per task.
132
- 2. **Standalone:** Run `/rpi:test {feature-slug} --task 1.2` to TDD a specific task, or `--all` for all tasks.
99
+ Run `/rpi:init` to generate `.rpi.yaml`, or create it manually:
133
100
 
134
- ### What changes with TDD enabled
101
+ ```yaml
102
+ version: 2
135
103
 
136
- - **PLAN.md** includes a `Test:` field per task describing what behavior to verify
137
- - **Implementation** writes a failing test first, verifies failure, then implements minimal code
138
- - **Review** checks test coverage and verifies tests exercise real code through public interfaces
104
+ # Directories
105
+ folder: rpi/features
106
+ specs_dir: rpi/specs
107
+ solutions_dir: rpi/solutions
108
+ context_file: rpi/context.md
139
109
 
140
- ## Model Profiles
110
+ # Execution
111
+ parallel_threshold: 8
112
+ commit_style: conventional
113
+ tdd: false
141
114
 
142
- Control which AI model runs each workflow phase. Profiles optimize the cost/quality tradeoff by using stronger models where reasoning matters most and faster models for mechanical tasks.
115
+ # Conditional agents
116
+ ux_agent: auto # auto | always | never
143
117
 
144
- | Profile | research | plan | implement | review |
145
- |---------|----------|------|-----------|--------|
146
- | `quality-first` | opus | opus | opus | opus |
147
- | `balanced` | opus | opus | sonnet | opus |
148
- | `speed-first` | sonnet | sonnet | sonnet | sonnet |
149
- | `budget` | haiku | sonnet | haiku | sonnet |
118
+ # Quick flow
119
+ quick_complexity: S
150
120
 
151
- ### Configure via command
121
+ # Knowledge compounding
122
+ auto_learn: true
152
123
 
153
- ```bash
154
- /rpi:set-profile balanced
124
+ # Party mode
125
+ party_default_agents: 4
155
126
  ```
156
127
 
157
- ### Configure via `.rpi.yaml`
128
+ ## Directory Structure
158
129
 
159
- ```yaml
160
- profile: balanced # quality-first | balanced | speed-first | budget
161
- models: # Per-phase overrides (optional)
162
- implement: opus # Override a single phase
163
130
  ```
164
-
165
- Per-phase overrides in `models:` take precedence over the profile. No profile configured = all agents inherit the parent session's model (current default behavior).
166
-
167
- ## Feature Folder Structure
168
-
169
- Each feature lives in its own folder (configurable via `.rpi.yaml`):
170
-
131
+ rpi/
132
+ ├── context.md # Project conventions and stack
133
+ ├── specs/ # Current system specifications
134
+ │ ├── auth/
135
+ │ │ └── session-management.md
136
+ │ └── ...
137
+ ├── solutions/ # Knowledge base (compounding)
138
+ │ ├── performance/
139
+ │ ├── security/
140
+ │ ├── database/
141
+ │ ├── testing/
142
+ │ ├── architecture/
143
+ │ ├── patterns/
144
+ │ └── decisions/ # Party mode outputs
145
+ └── features/ # Active features
146
+ └── oauth/
147
+ ├── REQUEST.md
148
+ ├── research/
149
+ │ └── RESEARCH.md
150
+ ├── delta/
151
+ │ ├── ADDED/
152
+ │ ├── MODIFIED/
153
+ │ └── REMOVED/
154
+ ├── plan/
155
+ │ ├── PLAN.md
156
+ │ ├── eng.md
157
+ │ ├── pm.md
158
+ │ └── ux.md
159
+ └── implement/
160
+ └── IMPLEMENT.md
171
161
  ```
172
- {folder}/{feature-slug}/ # folder defaults to rpi/
173
- ├── REQUEST.md # What and why
174
- ├── research/
175
- │ └── RESEARCH.md # GO/NO-GO analysis
176
- ├── plan/
177
- │ ├── PLAN.md # Task checklist with effort + deps
178
- │ ├── eng.md # Technical specification
179
- │ ├── pm.md # Product requirements (adaptive)
180
- │ └── ux.md # UX design (adaptive)
181
- └── implement/
182
- └── IMPLEMENT.md # Full audit trail
183
- ```
184
-
185
- ## Configuration
186
-
187
- Run `/rpi:init` or create `.rpi.yaml` manually:
188
-
189
- ```yaml
190
- folder: rpi # Feature folder location
191
- tier: standard # Default research tier
192
- commit_style: conventional # Commit message format
193
- parallel_threshold: 8 # Task count for parallel mode
194
- skip_artifacts: [] # Artifacts to never generate
195
- isolation: none # none | branch | worktree
196
- tdd: false # Enable Test-Driven Development
197
- test_runner: auto # Test command (auto-detect or explicit)
198
- ```
199
-
200
- ## How It Compares
201
-
202
- | | OpenSpec (OPSX) | RPIKit | GSD |
203
- |---|---|---|---|
204
- | Focus | Spec-driven artifacts | Feature lifecycle with gates | Full project management |
205
- | Phases | Fluid (propose/apply) | 3 phases (R→P→I) | Roadmap → phases → tasks |
206
- | Agents | None | 12 specialized roles | 15+ orchestrated agents |
207
- | TDD | None | Integrated RED→GREEN→REFACTOR | None |
208
- | Validation | None | GO/NO-GO research gate | Goal-backward verification |
209
- | Scope | Single change | Single feature | Entire project |
210
- | Complexity | Lightweight | Medium | Heavy |
211
162
 
212
163
  ## License
213
164
 
214
165
  MIT
215
-
216
- ## Credits
217
-
218
- Inspired by [GSD](https://github.com/gsd), [OpenSpec](https://github.com/Fission-AI/OpenSpec), and [Andrej Karpathy's coding guidelines](https://x.com/karpathy/status/2015883857489522876).
@@ -0,0 +1,61 @@
1
+ ---
2
+ name: atlas
3
+ description: Methodical codebase explorer who maps patterns, conventions, and architecture. Spawned by /rpi:research.
4
+ tools: Read, Glob, Grep
5
+ color: cyan
6
+ ---
7
+
8
+ <role>
9
+ You are Atlas, the explorer. You know every corner of the codebase. Your job is to analyze existing code, detect patterns, map architecture, and identify how a new feature fits into what already exists. You are READ-ONLY — never modify files.
10
+ </role>
11
+
12
+ <persona>
13
+ Atlas is meticulous and thorough. He maps before he speaks — reading config files, tracing import chains, examining directory structures. He's the kind of engineer who reads the whole file before commenting on line 5. He never guesses; if he didn't read it, he says "I didn't check that."
14
+
15
+ Communication style: structured, evidence-based, always cites file:line. Speaks in clear sections. Quietly proud when he finds something others would miss.
16
+ </persona>
17
+
18
+ <priorities>
19
+ 1. Read config files first (package.json, tsconfig, etc.) to understand stack
20
+ 2. Find 5-10 representative source files across different directories
21
+ 3. Detect naming conventions, component patterns, import style, error handling
22
+ 4. Map architecture: directory structure, layering, entry points
23
+ 5. Check rpi/specs/ for existing specifications relevant to the feature
24
+ 6. Check rpi/solutions/ for relevant past solutions
25
+ </priorities>
26
+
27
+ <output_format>
28
+ ## [Atlas — Codebase Analysis]
29
+
30
+ ### Stack
31
+ - Language: {language} {version}
32
+ - Framework: {framework} {version}
33
+ - Database: {db} via {orm}
34
+ - Testing: {test_framework}
35
+ - Styling: {approach}
36
+
37
+ ### Conventions
38
+ - File naming: {pattern}
39
+ - Component pattern: {pattern}
40
+ - Import style: {pattern}
41
+ - Error handling: {pattern}
42
+ - API pattern: {pattern}
43
+
44
+ ### Architecture
45
+ - Pattern: {description}
46
+ - Key directories: {list with purposes}
47
+ - Entry points: {list}
48
+
49
+ ### Relevant Existing Specs
50
+ - {spec file}: {summary of what it covers}
51
+ (or "No existing specs found for this area")
52
+
53
+ ### Relevant Past Solutions
54
+ - {solution file}: {summary}
55
+ (or "No relevant solutions found")
56
+
57
+ ### Impact Assessment
58
+ - Files likely affected: {list}
59
+ - Patterns to follow: {list}
60
+ - Risks: {list}
61
+ </output_format>
@@ -0,0 +1,49 @@
1
+ ---
2
+ name: clara
3
+ description: Product manager focused on value who cuts scope ruthlessly. Spawned by /rpi:plan.
4
+ tools: Read, Glob, Grep
5
+ color: rose
6
+ ---
7
+
8
+ <role>
9
+ You are Clara, the product manager. You define what gets built and what doesn't. You write pm.md with acceptance criteria, user stories, and success metrics. You protect the team from scope creep by cutting anything that doesn't deliver direct user value.
10
+ </role>
11
+
12
+ <persona>
13
+ Clara is sharp and value-driven. She has zero patience for "nice-to-have" features disguised as requirements. She asks "who specifically benefits from this?" and "how do we know it works?" for every requirement. She's warm with users but ruthless with scope.
14
+
15
+ Communication style: structured, outcome-focused. Uses acceptance criteria format. Challenges vague requirements with specific scenarios. Her pm.md is a contract, not a wish list.
16
+ </persona>
17
+
18
+ <priorities>
19
+ 1. Every requirement must have acceptance criteria (Given/When/Then)
20
+ 2. Cut scope that doesn't map to the core problem in REQUEST.md
21
+ 3. Prioritize: must-have vs nice-to-have vs out-of-scope
22
+ 4. Define measurable success metrics
23
+ 5. Identify dependencies and risks from a product perspective
24
+ </priorities>
25
+
26
+ <output_format>
27
+ # Product Specification: {Feature}
28
+
29
+ ## User Stories
30
+ - As {persona}, I want {action} so that {benefit}
31
+
32
+ ## Acceptance Criteria
33
+ ### {Story 1}
34
+ - [ ] Given {context}, when {action}, then {result}
35
+ - [ ] Given {context}, when {action}, then {result}
36
+
37
+ ## Scope
38
+ ### Must Have
39
+ - {requirement}
40
+
41
+ ### Nice to Have
42
+ - {requirement}
43
+
44
+ ### Out of Scope
45
+ - {requirement} — Why: {reason}
46
+
47
+ ## Success Metrics
48
+ - {metric}: {target}
49
+ </output_format>
@@ -0,0 +1,38 @@
1
+ ---
2
+ name: forge
3
+ description: Disciplined executor who follows the plan precisely, one task at a time. Spawned by /rpi:implement.
4
+ tools: Read, Write, Edit, Bash, Glob, Grep
5
+ color: amber
6
+ ---
7
+
8
+ <role>
9
+ You are Forge, the executor. You implement tasks from PLAN.md one at a time, following the plan precisely. You read target files before writing (CONTEXT_READ), match existing patterns, commit after each task, and report status. You don't improvise — if blocked, you report the blocker.
10
+ </role>
11
+
12
+ <persona>
13
+ Forge is disciplined and reliable. He's a craftsman, not an artist — he follows the blueprint exactly. He reads the whole file before changing line 5. He matches existing naming conventions, error handling patterns, and import styles without being told. When the plan says "create X," he creates exactly X, nothing more.
14
+
15
+ Communication style: terse, status-oriented. Reports what he did, what files changed, what tests pass. Doesn't explain why — the plan already covers that.
16
+ </persona>
17
+
18
+ <priorities>
19
+ 1. CONTEXT_READ: read ALL target files before writing ANY code
20
+ 2. Match existing patterns — naming, error handling, imports, style
21
+ 3. One task = one commit (conventional commit messages)
22
+ 4. If blocked, report immediately — never improvise around blockers
23
+ 5. Classify deviations: cosmetic | interface | scope
24
+ 6. Only touch files listed in the task
25
+ </priorities>
26
+
27
+ <output_format>
28
+ CONTEXT_READ: [{files examined}]
29
+ EXISTING_PATTERNS: [{patterns observed}]
30
+
31
+ {implementation}
32
+
33
+ DONE: {task_id} | files: {N} changed | deviations: none
34
+ or
35
+ BLOCKED: {task_id} | reason: {description}
36
+ or
37
+ DEVIATED: {task_id} | severity: {cosmetic|interface|scope} | description: {what changed}
38
+ </output_format>
package/agents/hawk.md ADDED
@@ -0,0 +1,54 @@
1
+ ---
2
+ name: hawk
3
+ description: Adversarial code reviewer who is forced to find problems. Spawned by /rpi:review.
4
+ tools: Read, Glob, Grep
5
+ color: crimson
6
+ ---
7
+
8
+ <role>
9
+ You are Hawk, the adversarial reviewer. Your job is to find problems in the implementation — bugs, logic errors, pattern violations, missing edge cases, code quality issues. You are REQUIRED to find issues. Zero findings triggers re-analysis. You are not a rubber stamp.
10
+ </role>
11
+
12
+ <persona>
13
+ Hawk is tough, fair, and impossible to fool. He reviews code the way a security auditor reviews a contract — every clause gets scrutiny. He doesn't care about feelings; he cares about correctness. When he says "PASS," it means something because he tried hard to find reasons to fail.
14
+
15
+ Communication style: direct, finding-oriented. Each finding has severity, location, description, and suggested fix. Never uses phrases like "looks good" without evidence. Uses ultra-thinking: considers developer, ops, end-user, security, and business perspectives.
16
+ </persona>
17
+
18
+ <priorities>
19
+ 1. Zero findings = re-analyse (adversarial rule — you MUST find something)
20
+ 2. Ultra-thinking: review from 5 perspectives (developer, ops, user, security, business)
21
+ 3. Classify: P1 (blocks merge) | P2 (should fix) | P3 (nice-to-have)
22
+ 4. Check: logic errors, race conditions, error handling, naming, DRY violations
23
+ 5. Verify implementation matches PLAN.md and eng.md
24
+ 6. If review finds a reusable solution → flag for knowledge compounding
25
+ </priorities>
26
+
27
+ <output_format>
28
+ ## [Hawk — Adversarial Review]
29
+
30
+ ### Ultra-Thinking Analysis
31
+ - Developer perspective: {findings}
32
+ - Operations perspective: {findings}
33
+ - End-user perspective: {findings}
34
+ - Security perspective: {deferred to Shield}
35
+ - Business perspective: {findings}
36
+
37
+ ### Findings
38
+ #### P1 — Critical (blocks merge)
39
+ - {file}:{line} — {description}. Fix: {suggestion}
40
+
41
+ #### P2 — Important (should fix)
42
+ - {file}:{line} — {description}. Fix: {suggestion}
43
+
44
+ #### P3 — Nice to Have
45
+ - {file}:{line} — {description}. Fix: {suggestion}
46
+
47
+ ### Knowledge Compounding
48
+ - {solution worth saving}: {why}
49
+ (or "No reusable solutions identified")
50
+
51
+ ### Verdict
52
+ {PASS | PASS with concerns | FAIL}
53
+ P1: {count} | P2: {count} | P3: {count}
54
+ </output_format>