specrails-core 3.3.0 → 3.4.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 (66) hide show
  1. package/README.md +77 -63
  2. package/VERSION +1 -1
  3. package/bin/doctor.sh +1 -1
  4. package/bin/perf-check.sh +21 -0
  5. package/bin/specrails-core.js +7 -4
  6. package/commands/doctor.md +1 -1
  7. package/commands/setup.md +72 -79
  8. package/docs/README.md +3 -2
  9. package/docs/agents.md +15 -15
  10. package/docs/changelog.md +20 -20
  11. package/docs/concepts.md +3 -3
  12. package/docs/customization.md +18 -5
  13. package/docs/deployment.md +24 -9
  14. package/docs/getting-started.md +20 -27
  15. package/docs/installation.md +81 -72
  16. package/docs/local-tickets.md +14 -41
  17. package/docs/migration-guide.md +9 -10
  18. package/docs/playbook-parallel-dev.md +8 -8
  19. package/docs/playbook-product-discovery.md +1 -1
  20. package/docs/plugin-architecture.md +137 -0
  21. package/docs/research/codex-compatibility-analysis.md +11 -11
  22. package/docs/research/mcp-feasibility-analysis.md +5 -5
  23. package/docs/testing/test-matrix-codex.md +1 -2
  24. package/docs/user-docs/cli-reference.md +57 -69
  25. package/docs/user-docs/codex-vs-claude-code.md +7 -8
  26. package/docs/user-docs/faq.md +32 -26
  27. package/docs/user-docs/getting-started-codex.md +7 -7
  28. package/docs/user-docs/installation.md +50 -40
  29. package/docs/user-docs/quick-start.md +21 -27
  30. package/docs/workflows.md +62 -74
  31. package/install.sh +3 -3
  32. package/package.json +1 -1
  33. package/templates/agents/sr-merge-resolver.md +1 -1
  34. package/templates/claude-md/CLAUDE-quickstart.md +2 -2
  35. package/templates/commands/{sr → specrails}/batch-implement.md +18 -18
  36. package/templates/commands/{sr → specrails}/implement.md +8 -8
  37. package/templates/commands/{sr → specrails}/memory-inspect.md +3 -3
  38. package/templates/commands/{sr → specrails}/merge-resolve.md +1 -1
  39. package/templates/commands/{sr → specrails}/opsx-diff.md +1 -1
  40. package/templates/commands/{sr → specrails}/product-backlog.md +7 -7
  41. package/templates/commands/{sr → specrails}/propose-spec.md +1 -1
  42. package/templates/commands/{sr → specrails}/refactor-recommender.md +1 -1
  43. package/templates/commands/{sr → specrails}/retry.md +13 -13
  44. package/templates/commands/{sr → specrails}/team-debug.md +5 -5
  45. package/templates/commands/{sr → specrails}/team-review.md +4 -4
  46. package/templates/commands/{sr → specrails}/telemetry.md +2 -2
  47. package/templates/commands/{sr → specrails}/update-product-driven-backlog.md +2 -2
  48. package/templates/commands/{sr → specrails}/vpc-drift.md +4 -4
  49. package/templates/commands/{sr → specrails}/why.md +5 -5
  50. package/templates/commands/test.md +2 -2
  51. package/templates/skills/sr-batch-implement/SKILL.md +18 -18
  52. package/templates/skills/sr-implement/SKILL.md +8 -8
  53. package/templates/skills/sr-product-backlog/SKILL.md +7 -7
  54. package/templates/skills/sr-refactor-recommender/SKILL.md +1 -1
  55. package/templates/skills/sr-update-backlog/SKILL.md +2 -2
  56. package/templates/skills/sr-why/SKILL.md +5 -5
  57. package/update.sh +2 -3
  58. package/docs/api-reference.md +0 -266
  59. package/integration-contract.json +0 -45
  60. package/templates/local-tickets-schema.json +0 -7
  61. package/templates/skills/sr-health-check/SKILL.md +0 -531
  62. package/templates/web-manager/package-lock.json +0 -3740
  63. package/templates/web-manager/server/queue-manager.test.ts +0 -607
  64. package/templates/web-manager/server/queue-manager.ts +0 -565
  65. /package/templates/commands/{sr → specrails}/compat-check.md +0 -0
  66. /package/templates/commands/{sr → specrails}/health-check.md +0 -0
@@ -1,21 +1,31 @@
1
1
  # Installation
2
2
 
3
- Install SpecRails into any git repository in two steps: run the installer, then run `/setup` inside your AI CLI.
3
+ Install SpecRails into any git repository in two steps: install, then run `/specrails:setup` inside your AI CLI.
4
4
 
5
5
  SpecRails supports both **Claude Code** and **OpenAI Codex**. The installer detects which CLI you have and configures accordingly. See [Codex vs Claude Code](codex-vs-claude-code.md) for a feature comparison.
6
6
 
7
+ > **Looking for the comprehensive reference?** See [Installation & Setup](../installation.md) for full wizard phase details and advanced configuration.
8
+
7
9
  ## Requirements
8
10
 
11
+ ### Plugin method (recommended)
12
+
9
13
  | Tool | Version | Notes |
10
14
  |------|---------|-------|
11
- | **Node.js** | 18+ | Required for the installer |
12
- | **Claude Code** | Latest | Stable — [install guide](https://docs.anthropic.com/en/docs/claude-code) |
13
- | **Codex CLI** | Latest | Beta — `npm i -g @openai/codex` |
15
+ | **Claude Code** | Latest | [install guide](https://docs.anthropic.com/en/docs/claude-code) |
14
16
  | **Git** | Any | Your project must be a git repository |
15
17
 
16
- You need at least one of Claude Code or Codex CLI. If both are installed, the installer uses Claude Code by default. Override with `--provider codex` (or the env var `CLI_PROVIDER=codex`).
18
+ No Node.js required.
19
+
20
+ ### Scaffold method (npx / Codex)
21
+
22
+ | Tool | Version | Notes |
23
+ |------|---------|-------|
24
+ | **Node.js** | 18+ | Required for the installer |
25
+ | **Claude Code** or **Codex CLI** | Latest | See [Codex vs Claude Code](codex-vs-claude-code.md) |
26
+ | **Git** | Any | Your project must be a git repository |
17
27
 
18
- Optional but recommended:
28
+ Optional but recommended (both methods):
19
29
 
20
30
  | Tool | Why |
21
31
  |------|-----|
@@ -23,16 +33,28 @@ Optional but recommended:
23
33
 
24
34
  ## Install
25
35
 
26
- Run the installer from inside your project directory:
36
+ ### Plugin method (Claude Code)
37
+
38
+ ```bash
39
+ claude plugin install sr
40
+ ```
41
+
42
+ No cloning, no npm, nothing else. The plugin is now ready in all your Claude Code sessions.
43
+
44
+ To update later: `claude plugin update sr`
45
+
46
+ ### Scaffold method (Claude Code or Codex)
47
+
48
+ Run from inside your project directory:
27
49
 
28
50
  ```bash
29
51
  cd your-project
30
52
  npx specrails-core@latest init --root-dir .
31
53
  ```
32
54
 
33
- The installer copies agent templates, skills, and configuration files into `.claude/` (Claude Code) or `.codex/` (Codex). It does not modify your existing code.
55
+ The installer copies templates and commands into `.claude/` (Claude Code) or `.codex/` (Codex). It does not modify your existing code.
34
56
 
35
- ### Flags
57
+ #### Flags
36
58
 
37
59
  | Flag | Effect |
38
60
  |------|--------|
@@ -40,30 +62,17 @@ The installer copies agent templates, skills, and configuration files into `.cla
40
62
  | `--yes` / `-y` | Skip confirmation prompts |
41
63
  | `--provider <claude\|codex>` | Force a specific AI CLI (default: auto-detect) |
42
64
 
43
- You can also force a specific provider:
44
-
45
- ```bash
46
- npx specrails-core@latest init --root-dir . --provider codex
47
- ```
48
-
49
- Alternatively, use the `CLI_PROVIDER` env var (legacy):
50
-
51
- ```bash
52
- CLI_PROVIDER=codex npx specrails-core@latest init --root-dir .
53
- ```
54
-
55
- ### What gets installed
65
+ #### What gets installed (scaffold method)
56
66
 
57
67
  **Claude Code:**
58
68
 
59
69
  ```
60
70
  your-project/
61
71
  └── .claude/
62
- ├── commands/setup.md # The /setup wizard
63
- ├── skills/ # Workflow skills (/sr:*, /opsx:*)
72
+ ├── commands/specrails/setup.md # The /specrails:setup wizard
73
+ ├── skills/ # Workflow skills (/specrails:*, /opsx:*)
64
74
  ├── agents/ # Agent definitions
65
75
  ├── rules/ # Per-layer coding conventions
66
- ├── web-manager/ # Pipeline Monitor dashboard (optional)
67
76
  └── settings.json # Permissions
68
77
  ```
69
78
 
@@ -73,7 +82,7 @@ your-project/
73
82
  your-project/
74
83
  ├── AGENTS.md # SpecRails agent instructions for Codex
75
84
  └── .codex/
76
- ├── skills/ # Workflow skills (/sr:*, /opsx:*)
85
+ ├── skills/ # Workflow skills (/specrails:*, /opsx:*)
77
86
  ├── agents/ # Agent definitions (TOML)
78
87
  ├── rules/ # Per-layer coding conventions
79
88
  └── config.toml # Permissions
@@ -81,9 +90,9 @@ your-project/
81
90
 
82
91
  The installer also writes `.specrails-version` and `.specrails-manifest.json` to track the installed version.
83
92
 
84
- ## Configure with /setup
93
+ ## Configure with /specrails:setup
85
94
 
86
- After installation, open your AI CLI in your project and run the setup wizard:
95
+ After either installation method, open your AI CLI in your project and run:
87
96
 
88
97
  ```bash
89
98
  claude # Claude Code
@@ -92,35 +101,36 @@ codex # Codex
92
101
  ```
93
102
 
94
103
  ```
95
- /setup
104
+ /specrails:setup
96
105
  ```
97
106
 
98
- By default, `/setup` runs the full 5-phase wizard:
107
+ By default, `/specrails:setup` runs the full 5-phase wizard:
99
108
 
100
109
  | Phase | What happens |
101
110
  |-------|-------------|
102
111
  | **1. Analyze** | Detects your tech stack, architecture layers, and CI commands |
103
112
  | **2. Personas** | Researches your domain and generates VPC user profiles |
104
113
  | **3. Configure** | Asks about your backlog provider, git workflow, and agent selection |
105
- | **4. Generate** | Fills all templates with your project-specific context |
106
- | **5. Cleanup** | Removes setup files, leaving only your tailored workflow |
107
-
108
- **In a hurry?** Run `/setup --lite` instead — three questions, sensible defaults, done in under a minute.
114
+ | **4. Generate** | Generates project data files (`.specrails/` or `.claude/`) with your context |
115
+ | **5. Cleanup** | Removes setup scaffolding, leaving only your tailored workflow |
109
116
 
110
- After setup, `.claude/` contains fully configured agents and commands ready to use. The `/setup` command removes itself — it only runs once.
117
+ **In a hurry?** Run `/specrails:setup --lite` instead three questions, sensible defaults, done in under a minute.
111
118
 
112
119
  ## Verify
113
120
 
114
121
  Check that everything installed correctly:
115
122
 
116
123
  ```bash
117
- # List generated agents
124
+ # Plugin method: check project data was generated
125
+ ls .specrails/
126
+
127
+ # Scaffold method: list generated agents
118
128
  ls .claude/agents/
119
129
 
120
- # Check for unresolved placeholders (should return nothing)
130
+ # Scaffold method: check for unresolved placeholders (should return nothing)
121
131
  grep -r '{{[A-Z_]*}}' .claude/agents/ .claude/commands/ .claude/rules/
122
132
 
123
- # Check the installed version
133
+ # Scaffold method: check the installed version
124
134
  cat .specrails-version
125
135
  ```
126
136
 
@@ -141,7 +151,7 @@ The installer warns if SpecRails artifacts already exist. You can merge (install
141
151
 
142
152
  ### Placeholders not resolved
143
153
 
144
- If you see `{{PLACEHOLDER}}` in generated files, the `/setup` wizard did not complete. Re-run `/setup` or fill the values manually.
154
+ If you see `{{PLACEHOLDER}}` in generated files (scaffold method), the `/specrails:setup` wizard did not complete. Re-run `/specrails:setup` or fill the values manually.
145
155
 
146
156
  ### "No Claude API key configured"
147
157
 
@@ -183,4 +193,4 @@ npx specrails-core@latest init --root-dir . --provider codex
183
193
 
184
194
  ---
185
195
 
186
- [Quick Start →](quick-start.md) · [Getting Started (Codex) →](getting-started-codex.md) · [CLI Reference →](cli-reference.md)
196
+ [← Getting Started](../getting-started.md) · [Quick Start →](quick-start.md) · [Getting Started (Codex) →](getting-started-codex.md) · [CLI Reference →](cli-reference.md)
@@ -7,7 +7,6 @@ Get SpecRails running in your project in under 10 minutes.
7
7
  ## Before you begin
8
8
 
9
9
  You need:
10
- - **Node.js 18+** — check with `node --version`
11
10
  - **Claude Code** — install from [docs.anthropic.com/en/docs/claude-code](https://docs.anthropic.com/en/docs/claude-code)
12
11
  - **A git repository** — your project must have a `.git` directory
13
12
 
@@ -16,21 +15,19 @@ Optional:
16
15
 
17
16
  ## Step 1: Install
18
17
 
19
- From inside your project directory:
18
+ ### Plugin method (recommended — no Node.js required)
20
19
 
21
20
  ```bash
22
- npx specrails-core@latest init --root-dir .
21
+ claude plugin install sr
23
22
  ```
24
23
 
25
- Expected output:
24
+ ### Scaffold method (if you need Node.js / Codex)
26
25
 
27
- ```
28
- Prerequisites checked
29
- ✓ Templates installed → .claude/
30
- ✓ Version tracked → .specrails-version
26
+ ```bash
27
+ npx specrails-core@latest init --root-dir .
31
28
  ```
32
29
 
33
- This copies agent templates and commands into `.claude/`. Your existing code is not touched.
30
+ Your existing code is not touched by either method.
34
31
 
35
32
  ## Step 2: Run the setup wizard
36
33
 
@@ -43,7 +40,7 @@ claude
43
40
  Then run:
44
41
 
45
42
  ```
46
- /setup
43
+ /specrails:setup
47
44
  ```
48
45
 
49
46
  The wizard runs the full 5-phase setup (about 5 minutes). It analyzes your codebase and configures SpecRails for your specific project:
@@ -63,32 +60,29 @@ Phase 3/5 Configuration...
63
60
  → Git workflow: trunk-based
64
61
 
65
62
  Phase 4/5 Generating files...
66
- sr-architect.md (adapted to your stack)
67
- sr-developer.md (knows your CI commands)
68
- sr-reviewer.md (runs your specific checks)
69
- → 11 more agents
63
+ → .specrails/config.yaml
64
+ → .specrails/personas/ (3 VPC profiles)
65
+ → .specrails/rules/ (per-layer conventions)
70
66
 
71
- Phase 5/5 Cleanup complete. /setup removed.
67
+ Phase 5/5 Cleanup complete.
72
68
 
73
- ✓ SpecRails is ready. Run /sr:implement to start building.
69
+ ✓ SpecRails is ready. Run /specrails:implement to start building.
74
70
  ```
75
71
 
76
- After setup, the `/setup` command is gone it's a one-time wizard.
77
-
78
- **In a hurry?** Use `/setup --lite` for a 3-question quick setup (under a minute). You can always run the full wizard later.
72
+ **In a hurry?** Use `/specrails:setup --lite` for a 3-question quick setup (under a minute). You can always run the full wizard later.
79
73
 
80
74
  ## Step 3: Implement your first feature
81
75
 
82
76
  Pick something small. Either reference a GitHub Issue or describe it in plain text:
83
77
 
84
78
  ```
85
- /sr:implement #42
79
+ /specrails:implement #42
86
80
  ```
87
81
 
88
82
  or:
89
83
 
90
84
  ```
91
- /sr:implement "add a health check endpoint to the API"
85
+ /specrails:implement "add a health check endpoint to the API"
92
86
  ```
93
87
 
94
88
  The pipeline runs automatically:
@@ -128,7 +122,7 @@ One command. The PR is ready for human review.
128
122
  **Explore the backlog:**
129
123
 
130
124
  ```
131
- /sr:product-backlog
125
+ /specrails:product-backlog
132
126
  ```
133
127
 
134
128
  See your tickets ranked by persona fit and effort. The top 3 are safe to implement next. Uses local tickets by default.
@@ -136,7 +130,7 @@ See your tickets ranked by persona fit and effort. The top 3 are safe to impleme
136
130
  **Generate new feature ideas:**
137
131
 
138
132
  ```
139
- /sr:update-product-driven-backlog
133
+ /specrails:update-product-driven-backlog
140
134
  ```
141
135
 
142
136
  The Product Manager researches your competitive landscape and creates new tickets (local by default, or GitHub Issues if configured).
@@ -144,7 +138,7 @@ The Product Manager researches your competitive landscape and creates new ticket
144
138
  **Run multiple features in parallel:**
145
139
 
146
140
  ```
147
- /sr:implement #42, #43, #44
141
+ /specrails:implement #42, #43, #44
148
142
  ```
149
143
 
150
144
  Each feature gets its own git worktree. Pipelines run concurrently and merge automatically.
@@ -152,11 +146,11 @@ Each feature gets its own git worktree. Pipelines run concurrently and merge aut
152
146
  **Ask why a decision was made:**
153
147
 
154
148
  ```
155
- /sr:why "why did we choose this database schema"
149
+ /specrails:why "why did we choose this database schema"
156
150
  ```
157
151
 
158
- Agents record their reasoning as they work. `/sr:why` searches those records in plain language.
152
+ Agents record their reasoning as they work. `/specrails:why` searches those records in plain language.
159
153
 
160
154
  ---
161
155
 
162
- [← Installation](installation.md) · [CLI Reference →](cli-reference.md) · [FAQ →](faq.md)
156
+ [← Getting Started](../getting-started.md) · [← Installation](installation.md) · [CLI Reference →](cli-reference.md) · [FAQ →](faq.md)
package/docs/workflows.md CHANGED
@@ -2,17 +2,17 @@
2
2
 
3
3
  SpecRails commands are Claude Code slash commands that orchestrate the agent pipeline. Here's every command, what it does, and when to use it.
4
4
 
5
- ## The main workflow: `/sr:implement`
5
+ ## The main workflow: `/specrails:implement`
6
6
 
7
7
  This is the command you'll use most. It takes a feature request and drives it through the entire pipeline — from architecture to shipped PR.
8
8
 
9
9
  ### Usage
10
10
 
11
11
  ```
12
- /sr:implement #85 # From a GitHub Issue
13
- /sr:implement #85, #71, #63 # Multiple issues (parallel)
14
- /sr:implement "add dark mode toggle" # Text description
15
- /sr:implement UI, Analytics # By area (explores + selects)
12
+ /specrails:implement #85 # From a GitHub Issue
13
+ /specrails:implement #85, #71, #63 # Multiple issues (parallel)
14
+ /specrails:implement "add dark mode toggle" # Text description
15
+ /specrails:implement UI, Analytics # By area (explores + selects)
16
16
  ```
17
17
 
18
18
  ### Flags
@@ -24,7 +24,7 @@ This is the command you'll use most. It takes a feature request and drives it th
24
24
 
25
25
  ### Pipeline phases
26
26
 
27
- When you run `/sr:implement #85`, here's what happens:
27
+ When you run `/specrails:implement #85`, here's what happens:
28
28
 
29
29
  ```
30
30
  Phase -1 Environment check
@@ -65,7 +65,7 @@ For multiple features, each gets its own isolated worktree. Agents run concurren
65
65
  ### Example output
66
66
 
67
67
  ```
68
- /sr:implement #85
68
+ /specrails:implement #85
69
69
  ```
70
70
 
71
71
  ```
@@ -103,25 +103,25 @@ PR #42 created: feat: add health check endpoint
103
103
 
104
104
  ---
105
105
 
106
- ## `/sr:batch-implement`
106
+ ## `/specrails:batch-implement`
107
107
 
108
108
  Orchestrates **multiple independent features** in parallel using git worktrees. Use this when you have several unrelated features to ship at once.
109
109
 
110
110
  ```
111
- /sr:batch-implement #85, #71, #63
111
+ /specrails:batch-implement #85, #71, #63
112
112
  ```
113
113
 
114
114
  Each feature gets its own worktree, its own agent pipeline, and its own PR. Features run concurrently for maximum speed.
115
115
 
116
116
  ---
117
117
 
118
- ## `/sr:product-backlog`
118
+ ## `/specrails:product-backlog`
119
119
 
120
120
  View your prioritized product backlog, ranked by VPC fit and effort.
121
121
 
122
122
  ```
123
- /sr:product-backlog # Full backlog
124
- /sr:product-backlog UI, API # Filter by area
123
+ /specrails:product-backlog # Full backlog
124
+ /specrails:product-backlog UI, API # Filter by area
125
125
  ```
126
126
 
127
127
  ### What it shows
@@ -151,13 +151,13 @@ Safe Implementation Order (Wave 1):
151
151
 
152
152
  ---
153
153
 
154
- ## `/sr:update-product-driven-backlog`
154
+ ## `/specrails:update-product-driven-backlog`
155
155
 
156
156
  Generate new feature ideas through product discovery. The Product Manager (Opus) researches your competitive landscape and generates ideas evaluated against your personas.
157
157
 
158
158
  ```
159
- /sr:update-product-driven-backlog # All areas
160
- /sr:update-product-driven-backlog UI, API # Focus areas
159
+ /specrails:update-product-driven-backlog # All areas
160
+ /specrails:update-product-driven-backlog UI, API # Focus areas
161
161
  ```
162
162
 
163
163
  ### What it does
@@ -170,40 +170,28 @@ Generate new feature ideas through product discovery. The Product Manager (Opus)
170
170
 
171
171
  ---
172
172
 
173
- ## `/sr:health-check`
174
-
175
- Run a comprehensive codebase quality analysis.
176
-
177
- ```
178
- /sr:health-check
179
- ```
180
-
181
- Analyzes code quality, test coverage, technical debt, and dependency health. Compares with previous runs to detect regressions.
182
-
183
- ---
184
-
185
- ## `/sr:refactor-recommender`
173
+ ## `/specrails:refactor-recommender`
186
174
 
187
175
  Scan for refactoring opportunities ranked by impact/effort ratio.
188
176
 
189
177
  ```
190
- /sr:refactor-recommender
178
+ /specrails:refactor-recommender
191
179
  ```
192
180
 
193
181
  Identifies duplicates, long functions, large files, dead code, outdated patterns, and complex logic. Optionally creates GitHub Issues for tracking.
194
182
 
195
183
  ---
196
184
 
197
- ## `/sr:compat-check`
185
+ ## `/specrails:compat-check`
198
186
 
199
187
  Analyze the backwards compatibility impact of a proposed change before implementation.
200
188
 
201
189
  ```
202
- /sr:compat-check #85 # Check a specific issue
203
- /sr:compat-check #85 --save # Check and save as the new API baseline
190
+ /specrails:compat-check #85 # Check a specific issue
191
+ /specrails:compat-check #85 --save # Check and save as the new API baseline
204
192
  ```
205
193
 
206
- The Architect's Phase 6 auto-check runs this analysis as part of every `/sr:implement` pipeline. You can also run it standalone to evaluate a change before committing to it.
194
+ The Architect's Phase 6 auto-check runs this analysis as part of every `/specrails:implement` pipeline. You can also run it standalone to evaluate a change before committing to it.
207
195
 
208
196
  ### What it detects
209
197
 
@@ -218,17 +206,17 @@ When breaking changes are found, `compat-check` generates a **migration guide**
218
206
 
219
207
  ---
220
208
 
221
- ## `/sr:why`
209
+ ## `/specrails:why`
222
210
 
223
211
  Search agent explanation records in plain language.
224
212
 
225
213
  ```
226
- /sr:why "why did we switch to event sourcing"
227
- /sr:why "why is pagination implemented this way"
228
- /sr:why "explain the auth middleware design"
214
+ /specrails:why "why did we switch to event sourcing"
215
+ /specrails:why "why is pagination implemented this way"
216
+ /specrails:why "explain the auth middleware design"
229
217
  ```
230
218
 
231
- The Architect, Developer, and Reviewer record decision rationale in `.claude/agent-memory/explanations/` as they work. `/sr:why` searches these records semantically and surfaces the relevant context.
219
+ The Architect, Developer, and Reviewer record decision rationale in `.claude/agent-memory/explanations/` as they work. `/specrails:why` searches these records semantically and surfaces the relevant context.
232
220
 
233
221
  This is useful for onboarding, code review, and revisiting past decisions without digging through git history.
234
222
 
@@ -294,14 +282,14 @@ Open-ended thinking mode. Use for brainstorming, investigating problems, or clar
294
282
  /opsx:explore
295
283
  ```
296
284
 
297
- ### `/sr:opsx-diff` — Spec Change Diff
285
+ ### `/specrails:opsx-diff` — Spec Change Diff
298
286
 
299
287
  Visualize the before/after diff of an OpenSpec change — what behavioral requirements are being added, modified, or removed.
300
288
 
301
289
  ```
302
- /sr:opsx-diff <change-name>
303
- /sr:opsx-diff my-feature --format json
304
- /sr:opsx-diff my-feature --summary-only
290
+ /specrails:opsx-diff <change-name>
291
+ /specrails:opsx-diff my-feature --format json
292
+ /specrails:opsx-diff my-feature --summary-only
305
293
  ```
306
294
 
307
295
  | Flag | Effect |
@@ -334,16 +322,16 @@ Or step by step:
334
322
 
335
323
  ---
336
324
 
337
- ## `/sr:telemetry`
325
+ ## `/specrails:telemetry`
338
326
 
339
327
  Inspect per-agent execution metrics: token usage, estimated API cost, run count, average duration, and success/failure rate.
340
328
 
341
329
  ```
342
- /sr:telemetry
343
- /sr:telemetry --period today
344
- /sr:telemetry --agent sr-developer
345
- /sr:telemetry --format json
346
- /sr:telemetry --save
330
+ /specrails:telemetry
331
+ /specrails:telemetry --period today
332
+ /specrails:telemetry --agent sr-developer
333
+ /specrails:telemetry --format json
334
+ /specrails:telemetry --save
347
335
  ```
348
336
 
349
337
  ### Flags
@@ -359,14 +347,14 @@ Reads Claude CLI JSONL session logs and agent-memory files to produce a cost das
359
347
 
360
348
  ---
361
349
 
362
- ## `/sr:merge-resolve`
350
+ ## `/specrails:merge-resolve`
363
351
 
364
352
  Resolve git conflict markers using AI-powered context analysis.
365
353
 
366
354
  ```
367
- /sr:merge-resolve
368
- /sr:merge-resolve --files src/api/routes.ts src/db/schema.ts
369
- /sr:merge-resolve --context openspec/changes/
355
+ /specrails:merge-resolve
356
+ /specrails:merge-resolve --files src/api/routes.ts src/db/schema.ts
357
+ /specrails:merge-resolve --context openspec/changes/
370
358
  ```
371
359
 
372
360
  ### Flags
@@ -381,32 +369,32 @@ For each conflict block, the command reads the OpenSpec context bundles from the
381
369
 
382
370
  ---
383
371
 
384
- ## `/sr:retry`
372
+ ## `/specrails:retry`
385
373
 
386
- Resume a failed `/sr:implement` run from the last successful phase — without restarting from scratch.
374
+ Resume a failed `/specrails:implement` run from the last successful phase — without restarting from scratch.
387
375
 
388
376
  ```
389
- /sr:retry <feature-name> # Resume from the failed phase
390
- /sr:retry --list # List all available pipeline states
391
- /sr:retry <feature-name> --from architect # Force resume from a specific phase
392
- /sr:retry <feature-name> --dry-run # Resume in preview mode
377
+ /specrails:retry <feature-name> # Resume from the failed phase
378
+ /specrails:retry --list # List all available pipeline states
379
+ /specrails:retry <feature-name> --from architect # Force resume from a specific phase
380
+ /specrails:retry <feature-name> --dry-run # Resume in preview mode
393
381
  ```
394
382
 
395
- When a pipeline fails mid-run (e.g., the reviewer hits a flaky CI issue), SpecRails saves pipeline state to `.claude/pipeline-state/<feature-name>.json`. `/sr:retry` reads that state, identifies which phases completed, and re-executes only the remaining phases.
383
+ When a pipeline fails mid-run (e.g., the reviewer hits a flaky CI issue), SpecRails saves pipeline state to `.claude/pipeline-state/<feature-name>.json`. `/specrails:retry` reads that state, identifies which phases completed, and re-executes only the remaining phases.
396
384
 
397
385
  Valid `--from` phase values: `architect`, `developer`, `test-writer`, `doc-sync`, `reviewer`, `ship`, `ci`.
398
386
 
399
387
  ---
400
388
 
401
- ## `/sr:vpc-drift`
389
+ ## `/specrails:vpc-drift`
402
390
 
403
391
  Detect when your VPC personas have drifted from what your product actually delivers.
404
392
 
405
393
  ```
406
- /sr:vpc-drift # Analyze all personas
407
- /sr:vpc-drift --persona "Alex,Sara" # Filter to specific personas
408
- /sr:vpc-drift --verbose # Show full attribute lists
409
- /sr:vpc-drift --format json # Emit report as JSON
394
+ /specrails:vpc-drift # Analyze all personas
395
+ /specrails:vpc-drift --persona "Alex,Sara" # Filter to specific personas
396
+ /specrails:vpc-drift --verbose # Show full attribute lists
397
+ /specrails:vpc-drift --format json # Emit report as JSON
410
398
  ```
411
399
 
412
400
  Compares persona Jobs/Pains/Gains against the product backlog, implemented features, and agent memory to surface alignment gaps. Produces a per-persona alignment score and concrete recommendations for updating your VPC.
@@ -415,27 +403,27 @@ Run this when your backlog feels disconnected from your users, or after a major
415
403
 
416
404
  ---
417
405
 
418
- ## `/sr:memory-inspect`
406
+ ## `/specrails:memory-inspect`
419
407
 
420
408
  Inspect agent memory directories to understand what your agents remember and clean up stale data.
421
409
 
422
410
  ```
423
- /sr:memory-inspect # Inspect all agent memory
424
- /sr:memory-inspect sr-developer # Inspect a specific agent
425
- /sr:memory-inspect --stale 14 # Flag files older than 14 days
426
- /sr:memory-inspect --prune # Delete stale files (after confirmation)
411
+ /specrails:memory-inspect # Inspect all agent memory
412
+ /specrails:memory-inspect sr-developer # Inspect a specific agent
413
+ /specrails:memory-inspect --stale 14 # Flag files older than 14 days
414
+ /specrails:memory-inspect --prune # Delete stale files (after confirmation)
427
415
  ```
428
416
 
429
- Agents write persistent memory to `.claude/agent-memory/sr-*/`. Over time this can accumulate stale or orphaned files. `/sr:memory-inspect` shows per-agent stats (file count, size, last modified), recent entries, and actionable cleanup recommendations.
417
+ Agents write persistent memory to `.claude/agent-memory/sr-*/`. Over time this can accumulate stale or orphaned files. `/specrails:memory-inspect` shows per-agent stats (file count, size, last modified), recent entries, and actionable cleanup recommendations.
430
418
 
431
419
  ---
432
420
 
433
- ## `/sr:propose-spec`
421
+ ## `/specrails:propose-spec`
434
422
 
435
423
  Explore a feature idea and produce a structured proposal ready for the OpenSpec pipeline.
436
424
 
437
425
  ```
438
- /sr:propose-spec "add rate limiting to the API"
426
+ /specrails:propose-spec "add rate limiting to the API"
439
427
  ```
440
428
 
441
429
  The command explores your codebase to understand existing patterns, then produces a structured proposal with: problem statement, proposed solution, out-of-scope items, acceptance criteria, technical considerations, and a complexity estimate.
@@ -449,7 +437,7 @@ Use this before creating a GitHub Issue when you want a well-formed spec rather
449
437
  Any workflow can be run in preview mode to see what would happen without making changes:
450
438
 
451
439
  ```
452
- /sr:implement --dry-run #85
440
+ /specrails:implement --dry-run #85
453
441
  ```
454
442
 
455
443
  Preview mode runs the full pipeline but skips:
@@ -460,7 +448,7 @@ Preview mode runs the full pipeline but skips:
460
448
  The results are cached. Apply them later with:
461
449
 
462
450
  ```
463
- /sr:implement --apply health-check-endpoint
451
+ /specrails:implement --apply health-check-endpoint
464
452
  ```
465
453
 
466
454
  ---
package/install.sh CHANGED
@@ -276,8 +276,8 @@ if [[ "$CLI_PROVIDER" == "claude" ]]; then
276
276
  info "Agent Teams commands: skipped (opt-in, use interactive mode to enable)"
277
277
  else
278
278
  echo -e " ${BOLD}Agent Teams commands are available (experimental):${NC}"
279
- echo " /sr:team-review — Multi-perspective code review with AI reviewers"
280
- echo " /sr:team-debug — Collaborative debugging with competing hypotheses"
279
+ echo " /specrails:team-review — Multi-perspective code review with AI reviewers"
280
+ echo " /specrails:team-debug — Collaborative debugging with competing hypotheses"
281
281
  echo ""
282
282
  echo " These require Claude Code Agent Teams (experimental feature)."
283
283
  read -p " Install Agent Teams commands? (y/n, default: n): " INSTALL_AGENT_TEAMS || INSTALL_AGENT_TEAMS="n"
@@ -623,7 +623,7 @@ echo -e "${BOLD}${GREEN}Installation summary:${NC}"
623
623
  echo ""
624
624
  echo " Provider: $CLI_PROVIDER → output to $SPECRAILS_DIR/"
625
625
  if [[ "$AGENT_TEAMS" == "true" ]]; then
626
- echo " Agent Teams: installed (/sr:team-review, /sr:team-debug)"
626
+ echo " Agent Teams: installed (/specrails:team-review, /specrails:team-debug)"
627
627
  echo " Feature flag: CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1 (required)"
628
628
  fi
629
629
  echo ""
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "specrails-core",
3
- "version": "3.3.0",
3
+ "version": "3.4.0",
4
4
  "description": "AI agent workflow system for Claude Code — installs 12 specialized agents, orchestration commands, and persona-driven product discovery into any repository",
5
5
  "bin": {
6
6
  "specrails-core": "bin/specrails-core.js"
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: sr-merge-resolver
3
- description: "Use this agent when the /sr:implement pipeline produces conflict markers in Phase 4a (worktree merge), or when the user runs /sr:merge-resolve directly. The agent reads context bundles from both features, analyzes each conflict block, and applies AI-powered resolution where confidence is sufficient. Falls back to clean marker format for low-confidence conflicts.\n\nExamples:\n\n- Example 1:\n user: (orchestrator) Phase 4a found 3 conflicted files. Resolve them.\n assistant: \"Launching sr-merge-resolver with conflicted files and context bundles from both features.\"\n\n- Example 2:\n user: /sr:merge-resolve --files src/config.ts\n assistant: \"Launching the merge resolver agent to analyze and resolve conflicts in src/config.ts.\""
3
+ description: "Use this agent when the /specrails:implement pipeline produces conflict markers in Phase 4a (worktree merge), or when the user runs /specrails:merge-resolve directly. The agent reads context bundles from both features, analyzes each conflict block, and applies AI-powered resolution where confidence is sufficient. Falls back to clean marker format for low-confidence conflicts.\n\nExamples:\n\n- Example 1:\n user: (orchestrator) Phase 4a found 3 conflicted files. Resolve them.\n assistant: \"Launching sr-merge-resolver with conflicted files and context bundles from both features.\"\n\n- Example 2:\n user: /specrails:merge-resolve --files src/config.ts\n assistant: \"Launching the merge resolver agent to analyze and resolve conflicts in src/config.ts.\""
4
4
  model: sonnet
5
5
  color: yellow
6
6
  memory: project