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.
- package/README.md +77 -63
- package/VERSION +1 -1
- package/bin/doctor.sh +1 -1
- package/bin/perf-check.sh +21 -0
- package/bin/specrails-core.js +7 -4
- package/commands/doctor.md +1 -1
- package/commands/setup.md +72 -79
- package/docs/README.md +3 -2
- package/docs/agents.md +15 -15
- package/docs/changelog.md +20 -20
- package/docs/concepts.md +3 -3
- package/docs/customization.md +18 -5
- package/docs/deployment.md +24 -9
- package/docs/getting-started.md +20 -27
- package/docs/installation.md +81 -72
- package/docs/local-tickets.md +14 -41
- package/docs/migration-guide.md +9 -10
- package/docs/playbook-parallel-dev.md +8 -8
- package/docs/playbook-product-discovery.md +1 -1
- package/docs/plugin-architecture.md +137 -0
- package/docs/research/codex-compatibility-analysis.md +11 -11
- package/docs/research/mcp-feasibility-analysis.md +5 -5
- package/docs/testing/test-matrix-codex.md +1 -2
- package/docs/user-docs/cli-reference.md +57 -69
- package/docs/user-docs/codex-vs-claude-code.md +7 -8
- package/docs/user-docs/faq.md +32 -26
- package/docs/user-docs/getting-started-codex.md +7 -7
- package/docs/user-docs/installation.md +50 -40
- package/docs/user-docs/quick-start.md +21 -27
- package/docs/workflows.md +62 -74
- package/install.sh +3 -3
- package/package.json +1 -1
- package/templates/agents/sr-merge-resolver.md +1 -1
- package/templates/claude-md/CLAUDE-quickstart.md +2 -2
- package/templates/commands/{sr → specrails}/batch-implement.md +18 -18
- package/templates/commands/{sr → specrails}/implement.md +8 -8
- package/templates/commands/{sr → specrails}/memory-inspect.md +3 -3
- package/templates/commands/{sr → specrails}/merge-resolve.md +1 -1
- package/templates/commands/{sr → specrails}/opsx-diff.md +1 -1
- package/templates/commands/{sr → specrails}/product-backlog.md +7 -7
- package/templates/commands/{sr → specrails}/propose-spec.md +1 -1
- package/templates/commands/{sr → specrails}/refactor-recommender.md +1 -1
- package/templates/commands/{sr → specrails}/retry.md +13 -13
- package/templates/commands/{sr → specrails}/team-debug.md +5 -5
- package/templates/commands/{sr → specrails}/team-review.md +4 -4
- package/templates/commands/{sr → specrails}/telemetry.md +2 -2
- package/templates/commands/{sr → specrails}/update-product-driven-backlog.md +2 -2
- package/templates/commands/{sr → specrails}/vpc-drift.md +4 -4
- package/templates/commands/{sr → specrails}/why.md +5 -5
- package/templates/commands/test.md +2 -2
- package/templates/skills/sr-batch-implement/SKILL.md +18 -18
- package/templates/skills/sr-implement/SKILL.md +8 -8
- package/templates/skills/sr-product-backlog/SKILL.md +7 -7
- package/templates/skills/sr-refactor-recommender/SKILL.md +1 -1
- package/templates/skills/sr-update-backlog/SKILL.md +2 -2
- package/templates/skills/sr-why/SKILL.md +5 -5
- package/update.sh +2 -3
- package/docs/api-reference.md +0 -266
- package/integration-contract.json +0 -45
- package/templates/local-tickets-schema.json +0 -7
- package/templates/skills/sr-health-check/SKILL.md +0 -531
- package/templates/web-manager/package-lock.json +0 -3740
- package/templates/web-manager/server/queue-manager.test.ts +0 -607
- package/templates/web-manager/server/queue-manager.ts +0 -565
- /package/templates/commands/{sr → specrails}/compat-check.md +0 -0
- /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:
|
|
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
|
-
| **
|
|
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
|
-
|
|
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
|
-
|
|
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
|
|
55
|
+
The installer copies templates and commands into `.claude/` (Claude Code) or `.codex/` (Codex). It does not modify your existing code.
|
|
34
56
|
|
|
35
|
-
|
|
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
|
-
|
|
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
|
|
63
|
-
├── skills/ # Workflow skills (/
|
|
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 (/
|
|
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
|
|
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** |
|
|
106
|
-
| **5. Cleanup** | Removes setup
|
|
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
|
-
|
|
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
|
-
#
|
|
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
|
-
#
|
|
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
|
-
#
|
|
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
|
-
|
|
18
|
+
### Plugin method (recommended — no Node.js required)
|
|
20
19
|
|
|
21
20
|
```bash
|
|
22
|
-
|
|
21
|
+
claude plugin install sr
|
|
23
22
|
```
|
|
24
23
|
|
|
25
|
-
|
|
24
|
+
### Scaffold method (if you need Node.js / Codex)
|
|
26
25
|
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
✓ Templates installed → .claude/
|
|
30
|
-
✓ Version tracked → .specrails-version
|
|
26
|
+
```bash
|
|
27
|
+
npx specrails-core@latest init --root-dir .
|
|
31
28
|
```
|
|
32
29
|
|
|
33
|
-
|
|
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
|
-
→
|
|
67
|
-
→
|
|
68
|
-
→
|
|
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.
|
|
67
|
+
Phase 5/5 Cleanup complete.
|
|
72
68
|
|
|
73
|
-
✓ SpecRails is ready. Run /
|
|
69
|
+
✓ SpecRails is ready. Run /specrails:implement to start building.
|
|
74
70
|
```
|
|
75
71
|
|
|
76
|
-
|
|
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
|
-
/
|
|
79
|
+
/specrails:implement #42
|
|
86
80
|
```
|
|
87
81
|
|
|
88
82
|
or:
|
|
89
83
|
|
|
90
84
|
```
|
|
91
|
-
/
|
|
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
|
-
/
|
|
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
|
-
/
|
|
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
|
-
/
|
|
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
|
-
/
|
|
149
|
+
/specrails:why "why did we choose this database schema"
|
|
156
150
|
```
|
|
157
151
|
|
|
158
|
-
Agents record their reasoning as they work. `/
|
|
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: `/
|
|
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
|
-
/
|
|
13
|
-
/
|
|
14
|
-
/
|
|
15
|
-
/
|
|
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 `/
|
|
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
|
-
/
|
|
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
|
-
## `/
|
|
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
|
-
/
|
|
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
|
-
## `/
|
|
118
|
+
## `/specrails:product-backlog`
|
|
119
119
|
|
|
120
120
|
View your prioritized product backlog, ranked by VPC fit and effort.
|
|
121
121
|
|
|
122
122
|
```
|
|
123
|
-
/
|
|
124
|
-
/
|
|
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
|
-
## `/
|
|
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
|
-
/
|
|
160
|
-
/
|
|
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
|
-
## `/
|
|
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
|
-
/
|
|
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
|
-
## `/
|
|
185
|
+
## `/specrails:compat-check`
|
|
198
186
|
|
|
199
187
|
Analyze the backwards compatibility impact of a proposed change before implementation.
|
|
200
188
|
|
|
201
189
|
```
|
|
202
|
-
/
|
|
203
|
-
/
|
|
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 `/
|
|
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
|
-
## `/
|
|
209
|
+
## `/specrails:why`
|
|
222
210
|
|
|
223
211
|
Search agent explanation records in plain language.
|
|
224
212
|
|
|
225
213
|
```
|
|
226
|
-
/
|
|
227
|
-
/
|
|
228
|
-
/
|
|
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. `/
|
|
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
|
-
### `/
|
|
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
|
-
/
|
|
303
|
-
/
|
|
304
|
-
/
|
|
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
|
-
## `/
|
|
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
|
-
/
|
|
343
|
-
/
|
|
344
|
-
/
|
|
345
|
-
/
|
|
346
|
-
/
|
|
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
|
-
## `/
|
|
350
|
+
## `/specrails:merge-resolve`
|
|
363
351
|
|
|
364
352
|
Resolve git conflict markers using AI-powered context analysis.
|
|
365
353
|
|
|
366
354
|
```
|
|
367
|
-
/
|
|
368
|
-
/
|
|
369
|
-
/
|
|
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
|
-
## `/
|
|
372
|
+
## `/specrails:retry`
|
|
385
373
|
|
|
386
|
-
Resume a failed `/
|
|
374
|
+
Resume a failed `/specrails:implement` run from the last successful phase — without restarting from scratch.
|
|
387
375
|
|
|
388
376
|
```
|
|
389
|
-
/
|
|
390
|
-
/
|
|
391
|
-
/
|
|
392
|
-
/
|
|
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`. `/
|
|
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
|
-
## `/
|
|
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
|
-
/
|
|
407
|
-
/
|
|
408
|
-
/
|
|
409
|
-
/
|
|
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
|
-
## `/
|
|
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
|
-
/
|
|
424
|
-
/
|
|
425
|
-
/
|
|
426
|
-
/
|
|
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. `/
|
|
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
|
-
## `/
|
|
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
|
-
/
|
|
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
|
-
/
|
|
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
|
-
/
|
|
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 " /
|
|
280
|
-
echo " /
|
|
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 (/
|
|
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
|
+
"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 /
|
|
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
|