all-for-claudecode 2.1.0 → 2.2.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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -1
- package/README.md +62 -111
- package/commands/analyze.md +5 -6
- package/commands/architect.md +5 -7
- package/commands/auto.md +14 -12
- package/commands/checkpoint.md +0 -1
- package/commands/debug.md +1 -1
- package/commands/doctor.md +1 -2
- package/commands/ideate.md +191 -0
- package/commands/implement.md +4 -4
- package/commands/init.md +56 -46
- package/commands/launch.md +181 -0
- package/commands/plan.md +1 -7
- package/commands/principles.md +0 -1
- package/commands/resume.md +0 -1
- package/commands/review.md +2 -2
- package/commands/security.md +10 -13
- package/commands/test.md +4 -4
- package/docs/phase-gate-protocol.md +1 -1
- package/package.json +15 -9
- package/scripts/afc-consistency-check.sh +261 -0
- package/scripts/afc-permission-request.sh +11 -1
- package/scripts/afc-pipeline-manage.sh +8 -11
- package/scripts/afc-state.sh +20 -0
- package/scripts/afc-stop-gate.sh +4 -6
- package/scripts/afc-subagent-context.sh +7 -0
- package/scripts/afc-task-completed-gate.sh +4 -6
- package/templates/afc.config.template.md +12 -76
- package/templates/afc.config.express-api.md +0 -99
- package/templates/afc.config.monorepo.md +0 -98
- package/templates/afc.config.nextjs-fsd.md +0 -107
- package/templates/afc.config.react-spa.md +0 -96
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
},
|
|
7
7
|
"metadata": {
|
|
8
8
|
"description": "Automated pipeline for Claude Code — spec → plan → implement → review → clean",
|
|
9
|
-
"version": "2.
|
|
9
|
+
"version": "2.2.0"
|
|
10
10
|
},
|
|
11
11
|
"plugins": [
|
|
12
12
|
{
|
|
13
13
|
"name": "afc",
|
|
14
14
|
"source": "./",
|
|
15
15
|
"description": "Automated pipeline for Claude Code. Automates the full development cycle: spec → plan → implement → review → clean.",
|
|
16
|
-
"version": "2.
|
|
16
|
+
"version": "2.2.0",
|
|
17
17
|
"category": "automation",
|
|
18
18
|
"tags": ["pipeline", "automation", "spec", "plan", "implement", "review", "critic-loop"]
|
|
19
19
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "afc",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"description": "Automated pipeline for Claude Code. Automates the full development cycle: spec → plan → implement → review → clean.",
|
|
5
5
|
"author": { "name": "jhlee0409", "email": "relee6203@gmail.com" },
|
|
6
6
|
"homepage": "https://github.com/jhlee0409/all-for-claudecode",
|
package/README.md
CHANGED
|
@@ -1,82 +1,62 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
<img src="https://github.com/user-attachments/assets/9e23029e-e326-4cfa-b329-3bdd1006aecd" alt="all-for-claudecode" width="640" />
|
|
3
|
+
</div>
|
|
4
|
+
|
|
1
5
|
# all-for-claudecode
|
|
2
6
|
|
|
3
7
|
**Claude Code plugin that automates the full development cycle — spec → plan → implement → review → clean.**
|
|
4
8
|
|
|
5
9
|
[](https://www.npmjs.com/package/all-for-claudecode)
|
|
10
|
+
[](https://www.npmjs.com/package/all-for-claudecode)
|
|
6
11
|
[](./LICENSE)
|
|
7
|
-
[](#15-hook-events)
|
|
9
|
-
[](#18-slash-commands)
|
|
10
|
-
|
|
11
|
-
> Zero-dependency automation pipeline for Claude Code. One command (`/afc:auto`) runs the entire cycle: write specs, design plans, implement code, review quality, and clean up — all with built-in CI gates and critic loops.
|
|
12
|
-
|
|
13
|
-
## What is all-for-claudecode?
|
|
12
|
+
[](#how-it-works)
|
|
14
13
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
- **18 slash commands** for every phase of development
|
|
18
|
-
- **15 hook events** with 3 handler types (shell scripts, LLM prompts, subagents)
|
|
19
|
-
- **5 project presets** for popular stacks (Next.js, React SPA, Express API, Monorepo)
|
|
20
|
-
- **Persistent memory agents** that learn across sessions
|
|
21
|
-
- **Built-in CI gates** that physically prevent skipping quality checks
|
|
14
|
+
> One command (`/afc:auto`) runs the entire cycle. Zero runtime dependencies — pure markdown commands + bash hook scripts.
|
|
22
15
|
|
|
23
16
|
## Quick Start
|
|
24
17
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
```
|
|
18
|
+
```bash
|
|
19
|
+
# Option A: Inside Claude Code
|
|
28
20
|
/plugin marketplace add jhlee0409/all-for-claudecode
|
|
29
21
|
/plugin install afc@all-for-claudecode
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
Or use the interactive UI: type `/plugin` → Manage → Add marketplace → `jhlee0409/all-for-claudecode` → Discover → install **afc**.
|
|
33
22
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
```bash
|
|
23
|
+
# Option B: npx
|
|
37
24
|
npx all-for-claudecode
|
|
38
25
|
```
|
|
39
26
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
### Option C: Claude Code CLI
|
|
43
|
-
|
|
44
|
-
```bash
|
|
45
|
-
claude plugin marketplace add jhlee0409/all-for-claudecode
|
|
46
|
-
claude plugin install afc@all-for-claudecode --scope user
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
### Then, inside Claude Code:
|
|
27
|
+
Then:
|
|
50
28
|
|
|
51
29
|
```
|
|
52
30
|
/afc:init # Detect your stack, generate config
|
|
53
31
|
/afc:auto "Add user authentication" # Run the full pipeline
|
|
54
32
|
```
|
|
55
33
|
|
|
56
|
-
|
|
34
|
+
The pipeline will:
|
|
57
35
|
1. Write a feature spec with acceptance criteria
|
|
58
|
-
2. Design an implementation plan with file change map
|
|
59
|
-
3. Implement
|
|
60
|
-
4. Run
|
|
36
|
+
2. Design an implementation plan with file change map
|
|
37
|
+
3. Implement tasks with CI gates (auto task decomposition + parallel execution)
|
|
38
|
+
4. Run code review with architecture/security agent analysis
|
|
61
39
|
5. Clean up artifacts and prepare for commit
|
|
62
40
|
|
|
63
|
-
##
|
|
64
|
-
|
|
65
|
-
### Full Auto Pipeline
|
|
41
|
+
## How It Works
|
|
66
42
|
|
|
67
43
|
```
|
|
68
|
-
/afc:auto "feature
|
|
69
|
-
```
|
|
70
|
-
|
|
71
|
-
Runs all 5 phases automatically with **Critic Loop** quality checks at each gate:
|
|
44
|
+
/afc:auto "Add feature X"
|
|
72
45
|
|
|
73
|
-
```
|
|
74
46
|
Spec (1/5) → Plan (2/5) → Implement (3/5) → Review (4/5) → Clean (5/5)
|
|
47
|
+
│ │ │ │ │
|
|
48
|
+
│ │ │ │ └─ Artifact cleanup
|
|
49
|
+
│ │ │ └─ 8 perspectives + agent review
|
|
50
|
+
│ │ └─ Auto task decomposition, parallel execution, CI gates
|
|
51
|
+
│ └─ File change map, ADR recording, research persistence
|
|
52
|
+
└─ Acceptance criteria, pre-implementation gates
|
|
53
|
+
|
|
54
|
+
Hooks run automatically at each step.
|
|
55
|
+
CI failure → debug-based RCA (not blind retry).
|
|
56
|
+
Critic Loops verify quality at each gate until convergence.
|
|
75
57
|
```
|
|
76
58
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
**User and model (unrestricted):**
|
|
59
|
+
## Slash Commands
|
|
80
60
|
|
|
81
61
|
| Command | Description |
|
|
82
62
|
|---|---|
|
|
@@ -85,14 +65,9 @@ Spec (1/5) → Plan (2/5) → Implement (3/5) → Review (4/5) → Clean (5/5)
|
|
|
85
65
|
| `/afc:plan` | Design implementation plan with file change map |
|
|
86
66
|
| `/afc:implement` | Execute code implementation with CI gates |
|
|
87
67
|
| `/afc:test` | Test strategy planning and test writing |
|
|
88
|
-
| `/afc:review` | Code review with security scanning |
|
|
68
|
+
| `/afc:review` | Code review with architecture/security scanning |
|
|
89
69
|
| `/afc:research` | Technical research with persistent storage |
|
|
90
70
|
| `/afc:debug` | Bug diagnosis and fix |
|
|
91
|
-
|
|
92
|
-
**User-only** (`disable-model-invocation: true`):
|
|
93
|
-
|
|
94
|
-
| Command | Description |
|
|
95
|
-
|---|---|
|
|
96
71
|
| `/afc:init` | Project setup — detects stack and generates config |
|
|
97
72
|
| `/afc:doctor` | Diagnose project health and plugin setup |
|
|
98
73
|
| `/afc:architect` | Architecture analysis (persistent memory) |
|
|
@@ -100,16 +75,11 @@ Spec (1/5) → Plan (2/5) → Implement (3/5) → Review (4/5) → Clean (5/5)
|
|
|
100
75
|
| `/afc:principles` | Project principles management |
|
|
101
76
|
| `/afc:checkpoint` | Save session state |
|
|
102
77
|
| `/afc:resume` | Restore session state |
|
|
103
|
-
|
|
104
|
-
**Model-only** (`user-invocable: false`):
|
|
105
|
-
|
|
106
|
-
| Command | Description |
|
|
107
|
-
|---|---|
|
|
108
78
|
| `/afc:tasks` | Task decomposition (auto-generated by implement) |
|
|
109
79
|
| `/afc:analyze` | Verify artifact consistency |
|
|
110
80
|
| `/afc:clarify` | Resolve spec ambiguities |
|
|
111
81
|
|
|
112
|
-
|
|
82
|
+
## Hook Events
|
|
113
83
|
|
|
114
84
|
Every hook fires automatically — no configuration needed after install.
|
|
115
85
|
|
|
@@ -120,7 +90,7 @@ Every hook fires automatically — no configuration needed after install.
|
|
|
120
90
|
| `PreToolUse` | Blocks dangerous commands (`push --force`, `reset --hard`) |
|
|
121
91
|
| `PostToolUse` | Tracks file changes + auto-formats code |
|
|
122
92
|
| `SubagentStart` | Injects pipeline context into subagents |
|
|
123
|
-
| `Stop` | CI gate (shell) + code completeness check (
|
|
93
|
+
| `Stop` | CI gate (shell) + code completeness check (agent) |
|
|
124
94
|
| `SessionEnd` | Warns about unfinished pipeline |
|
|
125
95
|
| `PostToolUseFailure` | Diagnostic hints for known error patterns |
|
|
126
96
|
| `Notification` | Desktop alerts (macOS/Linux) |
|
|
@@ -130,25 +100,32 @@ Every hook fires automatically — no configuration needed after install.
|
|
|
130
100
|
| `PermissionRequest` | Auto-allows CI commands during implement/review |
|
|
131
101
|
| `ConfigChange` | Audits/blocks settings changes during active pipeline |
|
|
132
102
|
| `TeammateIdle` | Prevents Agent Teams idle during implement/review |
|
|
103
|
+
| `WorktreeCreate` | Sets up worktree isolation for parallel workers |
|
|
104
|
+
| `WorktreeRemove` | Cleans up worktree after worker completion |
|
|
105
|
+
|
|
106
|
+
Handler types: `command` (shell scripts, all events), `prompt` (LLM single-turn, TaskCompleted), `agent` (subagent with tools, Stop).
|
|
133
107
|
|
|
134
|
-
|
|
108
|
+
## Persistent Memory Agents
|
|
135
109
|
|
|
136
|
-
|
|
|
137
|
-
|
|
138
|
-
| `
|
|
139
|
-
| `
|
|
140
|
-
| `
|
|
110
|
+
| Agent | Role |
|
|
111
|
+
|---|---|
|
|
112
|
+
| `afc-architect` | Remembers ADR decisions and architecture patterns across sessions. Auto-invoked during Plan (ADR recording) and Review (architecture compliance). |
|
|
113
|
+
| `afc-security` | Remembers vulnerability patterns and false positives across sessions. Auto-invoked during Review (security scanning). Runs in isolated worktree. |
|
|
114
|
+
| `afc-impl-worker` | Parallel implementation worker. Receives pre-assigned tasks from orchestrator. Ephemeral (no memory). |
|
|
141
115
|
|
|
142
|
-
|
|
116
|
+
## Task Orchestration
|
|
143
117
|
|
|
144
|
-
|
|
118
|
+
The implement phase automatically selects execution strategy:
|
|
119
|
+
|
|
120
|
+
| Parallel tasks in phase | Mode |
|
|
121
|
+
|---|---|
|
|
122
|
+
| 0 | Sequential — one task at a time |
|
|
123
|
+
| 1–5 | Parallel Batch — concurrent Task() calls |
|
|
124
|
+
| 6+ | Swarm — orchestrator pre-assigns tasks to worker agents (max 5) |
|
|
145
125
|
|
|
146
|
-
|
|
147
|
-
|---|---|---|
|
|
148
|
-
| `afc-architect` | Architecture analysis — remembers ADR decisions and patterns | `.claude/agent-memory/afc-architect/` |
|
|
149
|
-
| `afc-security` | Security scan — remembers vulnerability patterns and false positives | `.claude/agent-memory/afc-security/` |
|
|
126
|
+
Dependencies are tracked via DAG. CI gate + Mini-Review + Auto-Checkpoint run at each phase boundary.
|
|
150
127
|
|
|
151
|
-
|
|
128
|
+
## Project Presets
|
|
152
129
|
|
|
153
130
|
| Preset | Stack |
|
|
154
131
|
|---|---|
|
|
@@ -158,56 +135,30 @@ Two custom agents that **learn across sessions**:
|
|
|
158
135
|
| `express-api` | Express + TypeScript + Prisma + Jest |
|
|
159
136
|
| `monorepo` | Turborepo + pnpm workspace |
|
|
160
137
|
|
|
161
|
-
## How It Works
|
|
162
|
-
|
|
163
|
-
```
|
|
164
|
-
┌─────────────────────────────────────────────┐
|
|
165
|
-
│ /afc:auto "Add feature X" │
|
|
166
|
-
├─────────────────────────────────────────────┤
|
|
167
|
-
│ Phase 1: Spec → Critic Loop → Gate ✓ │
|
|
168
|
-
│ Phase 2: Plan → Critic Loop → Gate ✓ │
|
|
169
|
-
│ Phase 3: Implement → Tasks auto-gen → CI ✓ │
|
|
170
|
-
│ Phase 4: Review → 8 perspectives → Gate ✓│
|
|
171
|
-
│ Phase 5: Clean → Artifacts removed │
|
|
172
|
-
├─────────────────────────────────────────────┤
|
|
173
|
-
│ 15 hooks run automatically at each step │
|
|
174
|
-
│ Stop/TaskCompleted gates block if CI fails │
|
|
175
|
-
└─────────────────────────────────────────────┘
|
|
176
|
-
```
|
|
177
|
-
|
|
178
138
|
## Configuration
|
|
179
139
|
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
```bash
|
|
140
|
+
```
|
|
183
141
|
/afc:init
|
|
184
142
|
```
|
|
185
143
|
|
|
186
|
-
|
|
187
|
-
- CI/lint/test commands
|
|
188
|
-
- Architecture style and layers
|
|
189
|
-
- Framework-specific settings
|
|
190
|
-
- Code style conventions
|
|
144
|
+
Detects your tech stack and generates `.claude/afc.config.md` with CI/lint/test commands, architecture rules, framework settings, and code style conventions.
|
|
191
145
|
|
|
192
146
|
## FAQ
|
|
193
147
|
|
|
194
|
-
### What is all-for-claudecode?
|
|
195
|
-
A Claude Code plugin that automates the entire development cycle (spec → plan → implement → review → clean) through 18 slash commands and 15 hook events.
|
|
196
|
-
|
|
197
|
-
### How does it compare to manual Claude Code workflows?
|
|
198
|
-
Instead of manually prompting each step, all-for-claudecode orchestrates the full cycle with built-in quality gates that physically prevent skipping CI or security checks.
|
|
199
|
-
|
|
200
148
|
### Does it work with any project?
|
|
201
|
-
Yes. Run `/afc:init` to auto-detect your stack, or
|
|
149
|
+
Yes. Run `/afc:init` to auto-detect your stack, or pick a preset.
|
|
202
150
|
|
|
203
151
|
### Does it require any dependencies?
|
|
204
|
-
No.
|
|
152
|
+
No. Pure markdown commands + bash hook scripts.
|
|
153
|
+
|
|
154
|
+
### What happens if CI fails during the pipeline?
|
|
155
|
+
Debug-based RCA: traces the error, forms a hypothesis, applies a targeted fix. Halts after 3 failed attempts with full diagnosis.
|
|
205
156
|
|
|
206
|
-
###
|
|
207
|
-
|
|
157
|
+
### Can I run individual phases?
|
|
158
|
+
Yes. Each phase has its own command (`/afc:spec`, `/afc:plan`, `/afc:implement`, `/afc:review`). `/afc:auto` runs them all.
|
|
208
159
|
|
|
209
|
-
### What
|
|
210
|
-
|
|
160
|
+
### What are Critic Loops?
|
|
161
|
+
Convergence-based quality checks after each phase. They evaluate output against criteria (completeness, feasibility, architecture compliance) and auto-fix issues until stable. 4 verdicts: PASS, FAIL, ESCALATE (asks user), DEFER.
|
|
211
162
|
|
|
212
163
|
## License
|
|
213
164
|
|
package/commands/analyze.md
CHANGED
|
@@ -22,13 +22,12 @@ model: haiku
|
|
|
22
22
|
|
|
23
23
|
## Config Load
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
**Always** read `.claude/afc.config.md` first. This file contains free-form markdown sections:
|
|
26
|
+
- `## Architecture` — architecture pattern, layers, import rules (primary reference for this command)
|
|
27
|
+
- `## Code Style` — language, naming conventions, lint rules
|
|
28
|
+
- `## Project Context` — framework, state management, testing, etc.
|
|
26
29
|
|
|
27
|
-
|
|
28
|
-
config.architecture = the architecture pattern used in the project
|
|
29
|
-
(e.g., "FSD", "Clean Architecture", "Layered", "Modular Monolith")
|
|
30
|
-
→ Architecture standard specified in CLAUDE.md. Assume "Layered Architecture" if not present.
|
|
31
|
-
```
|
|
30
|
+
If config file is missing: read `CLAUDE.md` for architecture info. Assume "Layered Architecture" if neither source has it.
|
|
32
31
|
|
|
33
32
|
## Execution Steps
|
|
34
33
|
|
package/commands/architect.md
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
name: afc:architect
|
|
3
3
|
description: "Architecture analysis and design advice"
|
|
4
4
|
argument-hint: "[analysis target or design question]"
|
|
5
|
-
disable-model-invocation: true
|
|
6
5
|
context: fork
|
|
7
6
|
agent: afc-architect
|
|
8
7
|
allowed-tools:
|
|
@@ -27,13 +26,12 @@ model: sonnet
|
|
|
27
26
|
|
|
28
27
|
## Config Load
|
|
29
28
|
|
|
30
|
-
|
|
29
|
+
**Always** read `.claude/afc.config.md` first. This file contains free-form markdown sections:
|
|
30
|
+
- `## Architecture` — architecture pattern, layers, import rules (primary reference for this command)
|
|
31
|
+
- `## Code Style` — language, naming conventions, lint rules
|
|
32
|
+
- `## Project Context` — framework, state management, testing, etc.
|
|
31
33
|
|
|
32
|
-
|
|
33
|
-
config.architecture = the architecture pattern used in the project
|
|
34
|
-
(e.g., "FSD", "Clean Architecture", "Layered", "Modular Monolith")
|
|
35
|
-
→ Architecture standard specified in CLAUDE.md. Assume "Layered Architecture" if not present.
|
|
36
|
-
```
|
|
34
|
+
If config file is missing: read `CLAUDE.md` for architecture info. Assume "Layered Architecture" if neither source has it.
|
|
37
35
|
|
|
38
36
|
## Execution Steps
|
|
39
37
|
|
package/commands/auto.md
CHANGED
|
@@ -22,13 +22,11 @@ argument-hint: "[feature description in natural language]"
|
|
|
22
22
|
## Config Load
|
|
23
23
|
|
|
24
24
|
**Always** read `.claude/afc.config.md` first (read manually if not auto-loaded above). Values defined in this file are referenced below as `{config.*}`:
|
|
25
|
-
- `{config.ci}` — full CI command
|
|
26
|
-
- `{config.gate}` — phase gate command
|
|
27
|
-
- `{config.
|
|
28
|
-
- `{config.
|
|
29
|
-
- `{config.code_style}` — code style rules
|
|
30
|
-
- `{config.risks}` — project-specific risk patterns
|
|
31
|
-
- `{config.mini_review}` — Mini-Review checklist items
|
|
25
|
+
- `{config.ci}` — full CI command (from `## CI Commands` YAML)
|
|
26
|
+
- `{config.gate}` — phase gate command (from `## CI Commands` YAML)
|
|
27
|
+
- `{config.test}` — test command (from `## CI Commands` YAML)
|
|
28
|
+
- `{config.architecture}` — architecture style and rules (from `## Architecture` section)
|
|
29
|
+
- `{config.code_style}` — code style rules (from `## Code Style` section)
|
|
32
30
|
|
|
33
31
|
If config file is missing:
|
|
34
32
|
1. Ask the user: "`.claude/afc.config.md` not found. Run `/afc:init` to set up the project?"
|
|
@@ -115,7 +113,11 @@ If all checks pass, proceed to Phase 0.8.
|
|
|
115
113
|
2. Run `{config.ci}` verification
|
|
116
114
|
- On fail: **abort fast-path**, restart with full pipeline: `⚠ Fast-path aborted — change is more complex than expected. Running full pipeline.`
|
|
117
115
|
3. If change touches > 2 files OR modifies any `.sh` script: **abort fast-path**, restart with full pipeline
|
|
118
|
-
4. **Checkpoint**:
|
|
116
|
+
4. **Checkpoint**:
|
|
117
|
+
```bash
|
|
118
|
+
"${CLAUDE_PLUGIN_ROOT}/scripts/afc-pipeline-manage.sh" phase fast-path
|
|
119
|
+
"${CLAUDE_PLUGIN_ROOT}/scripts/afc-pipeline-manage.sh" ci-pass
|
|
120
|
+
```
|
|
119
121
|
5. Run `/afc:review` logic inline (mini-review only — single Critic pass)
|
|
120
122
|
6. Run Phase 5 Clean logic (artifact cleanup, CI gate, pipeline flag release)
|
|
121
123
|
7. Final output:
|
|
@@ -204,8 +206,8 @@ Execute `/afc:plan` logic inline:
|
|
|
204
206
|
5. Acceptance anchor alignment: Implementation Context Acceptance Anchors faithfully reflect spec acceptance scenarios
|
|
205
207
|
- **RISK criterion mandatory checks**:
|
|
206
208
|
- Enumerate **at least 3** `{config.ci}` failure scenarios and describe mitigation
|
|
207
|
-
- Check each pattern in
|
|
208
|
-
- Consider
|
|
209
|
+
- Check each risk pattern described in config's Project Context section one by one
|
|
210
|
+
- Consider framework characteristics from config's Project Context (server/client boundary etc.)
|
|
209
211
|
- **ARCHITECTURE criterion**: explicitly describe import paths for moved/created files and pre-validate against `{config.architecture}` rules
|
|
210
212
|
- Each pass must **explicitly explore what was missed in the previous pass** ("Pass 2: {X} was missed in pass 1. Further review: ...")
|
|
211
213
|
- FAIL → auto-fix and continue. ESCALATE → pause, present options, resume after response. DEFER → record reason, mark clean.
|
|
@@ -328,7 +330,7 @@ Execute `/afc:implement` logic inline — **follow all orchestration rules defin
|
|
|
328
330
|
For each acceptance scenario in spec.md:
|
|
329
331
|
- Map GWT to a test case: Given → Arrange, When → Act, Then → Assert
|
|
330
332
|
- Target file: determined by the component/module referenced in the scenario
|
|
331
|
-
- Test file location: follows project convention (
|
|
333
|
+
- Test file location: follows project convention (test framework from Project Context)
|
|
332
334
|
```
|
|
333
335
|
3. Run `{config.test}` to verify tests pass against the implementation
|
|
334
336
|
- If tests fail → this reveals a gap between spec and implementation:
|
|
@@ -402,7 +404,7 @@ Execute `/afc:review` logic inline — **follow all review perspectives defined
|
|
|
402
404
|
- A. Code Quality — `{config.code_style}` compliance (direct review)
|
|
403
405
|
- B. Architecture — **delegated to afc-architect agent** (persistent memory, ADR-aware)
|
|
404
406
|
- C. Security — **delegated to afc-security agent** (persistent memory, false-positive-aware)
|
|
405
|
-
- D. Performance —
|
|
407
|
+
- D. Performance — framework-specific patterns from Project Context (direct review)
|
|
406
408
|
- E. Project Pattern Compliance — conventions and idioms (direct review)
|
|
407
409
|
- **F. Reusability** — DRY, shared utilities, abstraction level (direct review)
|
|
408
410
|
- **G. Maintainability** — AI/human comprehension, naming clarity, self-contained files (direct review)
|
package/commands/checkpoint.md
CHANGED
package/commands/debug.md
CHANGED
|
@@ -48,7 +48,7 @@ Proceed in order:
|
|
|
48
48
|
|
|
49
49
|
1. **Error trace**: extract file:line from error message/stack trace → read that code
|
|
50
50
|
2. **Data flow**: trace backwards from the problem point (where did the bad data come in?)
|
|
51
|
-
3. **State analysis**: check relevant
|
|
51
|
+
3. **State analysis**: check relevant state management cache state (from Project Context)
|
|
52
52
|
4. **Recent changes**: check recent changes with `git log --oneline -10 -- {related files}`
|
|
53
53
|
5. **Race conditions**: check for timing issues between async operations
|
|
54
54
|
|
package/commands/doctor.md
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
name: afc:doctor
|
|
3
3
|
description: "Diagnose project health and plugin setup"
|
|
4
4
|
argument-hint: "[--verbose]"
|
|
5
|
-
disable-model-invocation: true
|
|
6
5
|
allowed-tools:
|
|
7
6
|
- Read
|
|
8
7
|
- Grep
|
|
@@ -49,7 +48,7 @@ Run ALL checks regardless of earlier failures. Do not short-circuit.
|
|
|
49
48
|
| Check | How | Pass | Fail |
|
|
50
49
|
|-------|-----|------|------|
|
|
51
50
|
| Config file exists | Read `.claude/afc.config.md` | File exists | Fix: run `/afc:init` |
|
|
52
|
-
| Required sections present | Grep for `## CI Commands`, `## Architecture`, `## Code Style
|
|
51
|
+
| Required sections present | Grep for `## CI Commands`, `## Architecture`, `## Code Style` | All 3 sections found | Fix: add missing section to `.claude/afc.config.md` or re-run `/afc:init` |
|
|
53
52
|
| Gate command defined | Grep for `gate:` inside `## CI Commands` section | `gate:` field found | Fix: add `gate:` field to `## CI Commands` section |
|
|
54
53
|
| CI command runnable | Extract CI command from config, run it | Exits 0 | ⚠ Warning: CI command failed. Check `{config.ci}` in afc.config.md |
|
|
55
54
|
| Gate command runnable | Extract gate command from config, run it | Exits 0 | ⚠ Warning: gate command failed. Check `{config.gate}` in afc.config.md |
|
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: afc:ideate
|
|
3
|
+
description: "Explore and structure a product idea"
|
|
4
|
+
argument-hint: "[rough idea or problem statement]"
|
|
5
|
+
allowed-tools:
|
|
6
|
+
- Read
|
|
7
|
+
- Write
|
|
8
|
+
- Glob
|
|
9
|
+
- Grep
|
|
10
|
+
- WebSearch
|
|
11
|
+
- WebFetch
|
|
12
|
+
model: sonnet
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# /afc:ideate — Explore and Structure a Product Idea
|
|
16
|
+
|
|
17
|
+
> Transforms a rough idea, problem statement, or inspiration into a structured product brief (ideate.md).
|
|
18
|
+
> This is a **pre-spec exploration** tool — use it when you don't yet know exactly what to build.
|
|
19
|
+
> The output feeds directly into `/afc:spec` as input.
|
|
20
|
+
|
|
21
|
+
## Relationship to Other Commands
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
afc:ideate (what to build?) → afc:spec (how to specify it) → afc:plan → afc:implement → ...
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
- **ideate** = "I have an idea but haven't decided the scope, audience, or approach yet"
|
|
28
|
+
- **spec** = "I know what to build and need a formal specification"
|
|
29
|
+
- ideate is **never** part of the auto pipeline — it's a standalone exploration tool
|
|
30
|
+
|
|
31
|
+
## Arguments
|
|
32
|
+
|
|
33
|
+
- `$ARGUMENTS` — (required) One of:
|
|
34
|
+
- Rough idea: `"real-time collaborative whiteboard"`
|
|
35
|
+
- Problem statement: `"users keep losing unsaved work when the browser crashes"`
|
|
36
|
+
- Reference URL: `"https://example.com/competitor-product"` (fetched and analyzed)
|
|
37
|
+
- File path: `"./meeting-notes.md"` (read and extracted)
|
|
38
|
+
|
|
39
|
+
## Execution Steps
|
|
40
|
+
|
|
41
|
+
### 1. Parse Input
|
|
42
|
+
|
|
43
|
+
Determine the input type and extract raw content:
|
|
44
|
+
|
|
45
|
+
1. **If `$ARGUMENTS` starts with `http://` or `https://`**:
|
|
46
|
+
- Fetch content via WebFetch
|
|
47
|
+
- Extract: product name, key features, target audience, value proposition
|
|
48
|
+
- Frame as: "Build something similar/better that addresses {gap}"
|
|
49
|
+
|
|
50
|
+
2. **If `$ARGUMENTS` is a file path** (contains `/` or ends with `.md`/`.txt`):
|
|
51
|
+
- Read the file content
|
|
52
|
+
- Extract: action items, feature requests, pain points, user feedback
|
|
53
|
+
- Frame as: structured requirements from raw notes
|
|
54
|
+
|
|
55
|
+
3. **Otherwise**: treat as a natural language idea/problem statement
|
|
56
|
+
|
|
57
|
+
### 2. Market & Context Research
|
|
58
|
+
|
|
59
|
+
Perform lightweight research to ground the idea in reality:
|
|
60
|
+
|
|
61
|
+
1. **Competitive landscape** (WebSearch):
|
|
62
|
+
- Search: `"{core concept}" tool OR app OR service {current year}`
|
|
63
|
+
- Identify 3-5 existing solutions
|
|
64
|
+
- Note: what they do well, what gaps exist
|
|
65
|
+
|
|
66
|
+
2. **Technology feasibility** (WebSearch, optional):
|
|
67
|
+
- If the idea involves unfamiliar tech: search for current state and constraints
|
|
68
|
+
- Tag findings with `[RESEARCHED]`
|
|
69
|
+
|
|
70
|
+
3. **Target user validation**:
|
|
71
|
+
- Who would use this? Why? What's their current workaround?
|
|
72
|
+
|
|
73
|
+
### 3. Explore Existing Codebase (if applicable)
|
|
74
|
+
|
|
75
|
+
If running inside a project with source code:
|
|
76
|
+
|
|
77
|
+
1. Check if any related functionality already exists (Glob/Grep)
|
|
78
|
+
2. If found: note as "Existing foundation" — ideate around extending, not rebuilding
|
|
79
|
+
3. If no codebase or greenfield: skip this step
|
|
80
|
+
|
|
81
|
+
### 4. Write Product Brief
|
|
82
|
+
|
|
83
|
+
Create `.claude/afc/ideate.md` (overwrite if exists after confirmation):
|
|
84
|
+
|
|
85
|
+
```markdown
|
|
86
|
+
# Product Brief: {idea name}
|
|
87
|
+
|
|
88
|
+
> Created: {YYYY-MM-DD}
|
|
89
|
+
> Status: Exploration
|
|
90
|
+
> Input: {original $ARGUMENTS summary}
|
|
91
|
+
|
|
92
|
+
## Problem Statement
|
|
93
|
+
{What problem does this solve? Who has this problem? How painful is it?}
|
|
94
|
+
{2-3 sentences, specific and measurable where possible}
|
|
95
|
+
|
|
96
|
+
## Target Users
|
|
97
|
+
|
|
98
|
+
### Primary Persona
|
|
99
|
+
- **Who**: {role/demographic}
|
|
100
|
+
- **Context**: {when/where they encounter the problem}
|
|
101
|
+
- **Current workaround**: {what they do today}
|
|
102
|
+
- **Pain level**: {High/Medium/Low — with justification}
|
|
103
|
+
|
|
104
|
+
### Secondary Persona (if applicable)
|
|
105
|
+
{same format}
|
|
106
|
+
|
|
107
|
+
## Value Proposition
|
|
108
|
+
{One sentence: "For {persona} who {need}, this {product} provides {benefit} unlike {alternatives}"}
|
|
109
|
+
|
|
110
|
+
## Core Features (MoSCoW)
|
|
111
|
+
|
|
112
|
+
### Must Have (MVP)
|
|
113
|
+
1. {feature} — {why it's essential}
|
|
114
|
+
2. {feature} — {why it's essential}
|
|
115
|
+
3. {feature} — {why it's essential}
|
|
116
|
+
|
|
117
|
+
### Should Have (v1.1)
|
|
118
|
+
1. {feature} — {value added}
|
|
119
|
+
|
|
120
|
+
### Could Have (future)
|
|
121
|
+
1. {feature} — {potential value}
|
|
122
|
+
|
|
123
|
+
### Won't Have (explicit scope cut)
|
|
124
|
+
1. {feature} — {why excluded}
|
|
125
|
+
|
|
126
|
+
## User Journey (primary flow)
|
|
127
|
+
|
|
128
|
+
```mermaid
|
|
129
|
+
graph LR
|
|
130
|
+
A[Entry Point] --> B[Core Action]
|
|
131
|
+
B --> C[Key Decision]
|
|
132
|
+
C --> D[Success State]
|
|
133
|
+
C --> E[Error/Edge Case]
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
{Describe the 3-5 step primary user flow in plain text as well}
|
|
137
|
+
|
|
138
|
+
## Competitive Analysis
|
|
139
|
+
|
|
140
|
+
| Aspect | {Competitor 1} | {Competitor 2} | This Product |
|
|
141
|
+
|--------|---------------|---------------|-------------|
|
|
142
|
+
| Core strength | {X} | {X} | {X} |
|
|
143
|
+
| Key weakness | {X} | {X} | {X} |
|
|
144
|
+
| Pricing | {X} | {X} | {X} |
|
|
145
|
+
| Differentiator | — | — | {what makes this unique} |
|
|
146
|
+
|
|
147
|
+
## Open Questions
|
|
148
|
+
- {Decision that needs user input before proceeding to spec}
|
|
149
|
+
- {Technical uncertainty that affects scope}
|
|
150
|
+
- {Business assumption that should be validated}
|
|
151
|
+
|
|
152
|
+
## Suggested Next Steps
|
|
153
|
+
1. Resolve Open Questions above
|
|
154
|
+
2. Run `/afc:spec {refined feature description}` to formalize as a specification
|
|
155
|
+
3. {Any other recommended action}
|
|
156
|
+
|
|
157
|
+
## Research Sources
|
|
158
|
+
- [{source title}]({url}) — {what was learned}
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
### 5. Interactive Refinement
|
|
162
|
+
|
|
163
|
+
After writing the initial brief, present key decisions to the user:
|
|
164
|
+
|
|
165
|
+
1. **Scope check**: "The MVP has {N} features. Does this feel right, or should we cut/add?"
|
|
166
|
+
2. **Persona validation**: "Is {persona} the right primary user?"
|
|
167
|
+
3. **Open questions**: present the top 2 unresolved questions via AskUserQuestion
|
|
168
|
+
|
|
169
|
+
Apply user feedback directly into ideate.md.
|
|
170
|
+
|
|
171
|
+
### 6. Final Output
|
|
172
|
+
|
|
173
|
+
```
|
|
174
|
+
Ideation complete
|
|
175
|
+
├─ .claude/afc/ideate.md
|
|
176
|
+
├─ Personas: {count}
|
|
177
|
+
├─ MVP features: {count}
|
|
178
|
+
├─ Competitors analyzed: {count}
|
|
179
|
+
├─ Open questions: {count}
|
|
180
|
+
├─ Research sources: {count}
|
|
181
|
+
└─ Next step: /afc:spec "{suggested feature description}"
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
## Notes
|
|
185
|
+
|
|
186
|
+
- **This is exploration, not specification**. Do not write acceptance criteria, system requirements, or FR/NFR numbers — that belongs in `/afc:spec`.
|
|
187
|
+
- **ideate.md lives at `.claude/afc/ideate.md`** (project-level, not feature-level) because ideation may span multiple features.
|
|
188
|
+
- **Not part of the auto pipeline**. ideate is manually invoked when a developer needs to think through an idea before committing to a spec.
|
|
189
|
+
- **One ideate.md per project** — overwrite on re-run (with confirmation). If you need to preserve a previous ideation, rename it first.
|
|
190
|
+
- **Competitive analysis is lightweight** — 3-5 competitors max. Deep market research is not the goal; grounding the idea in reality is.
|
|
191
|
+
- **Mermaid diagrams are optional** — only include if the user flow benefits from visualization. Do not force diagrams for simple concepts.
|