qa-workflow-cc 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/README.md +461 -0
  2. package/VERSION +1 -0
  3. package/bin/install.js +116 -0
  4. package/commands/qa/continue.md +77 -0
  5. package/commands/qa/full.md +149 -0
  6. package/commands/qa/init.md +105 -0
  7. package/commands/qa/resume.md +91 -0
  8. package/commands/qa/status.md +66 -0
  9. package/package.json +28 -0
  10. package/skills/qa/SKILL.md +420 -0
  11. package/skills/qa/references/continuation-format.md +58 -0
  12. package/skills/qa/references/exit-criteria.md +53 -0
  13. package/skills/qa/references/lifecycle.md +181 -0
  14. package/skills/qa/references/model-profiles.md +77 -0
  15. package/skills/qa/templates/agent-skeleton.md +733 -0
  16. package/skills/qa/templates/component-test.md +1088 -0
  17. package/skills/qa/templates/domain-research-queries.md +101 -0
  18. package/skills/qa/templates/domain-security-profiles.md +182 -0
  19. package/skills/qa/templates/e2e-test.md +1200 -0
  20. package/skills/qa/templates/nielsen-heuristics.md +274 -0
  21. package/skills/qa/templates/performance-benchmarks-base.md +321 -0
  22. package/skills/qa/templates/qa-report-template.md +271 -0
  23. package/skills/qa/templates/security-checklist-owasp.md +451 -0
  24. package/skills/qa/templates/stop-points/bootstrap-complete.md +36 -0
  25. package/skills/qa/templates/stop-points/certified.md +25 -0
  26. package/skills/qa/templates/stop-points/escalated.md +32 -0
  27. package/skills/qa/templates/stop-points/fix-ready.md +43 -0
  28. package/skills/qa/templates/stop-points/phase-transition.md +4 -0
  29. package/skills/qa/templates/stop-points/status-dashboard.md +32 -0
  30. package/skills/qa/templates/test-standards.md +652 -0
  31. package/skills/qa/templates/unit-test.md +998 -0
  32. package/skills/qa/templates/visual-regression.md +418 -0
  33. package/skills/qa/workflows/bootstrap.md +45 -0
  34. package/skills/qa/workflows/decision-gate.md +66 -0
  35. package/skills/qa/workflows/fix-execute.md +132 -0
  36. package/skills/qa/workflows/fix-plan.md +52 -0
  37. package/skills/qa/workflows/report-phase.md +64 -0
  38. package/skills/qa/workflows/test-phase.md +86 -0
  39. package/skills/qa/workflows/verify-phase.md +65 -0
package/README.md ADDED
@@ -0,0 +1,461 @@
1
+ <div align="center">
2
+
3
+ # QA Workflow
4
+
5
+ **Autonomous QA orchestrator for Claude Code — test-fix-verify cycles that run themselves.**
6
+
7
+ [![Version](https://img.shields.io/badge/version-1.0.0-green?style=for-the-badge)](VERSION)
8
+ [![License](https://img.shields.io/badge/license-MIT-blue?style=for-the-badge)](LICENSE)
9
+
10
+ <br>
11
+
12
+ ```bash
13
+ npx qa-workflow-cc
14
+ ```
15
+
16
+ **Works on Mac, Windows, and Linux. Any tech stack.**
17
+
18
+ <br>
19
+
20
+ *"Point it at your project, walk away, come back to a QA report with a fix plan ready to approve."*
21
+
22
+ <br>
23
+
24
+ [How It Works](#how-it-works) · [Commands](#commands) · [Architecture](#architecture) · [Model Profiles](#model-profiles) · [Getting Started](#getting-started)
25
+
26
+ </div>
27
+
28
+ ---
29
+
30
+ ## The Problem
31
+
32
+ Manual QA in AI-assisted development is a bottleneck. You build features fast with Claude Code, but then spend hours manually testing, triaging bugs, writing fixes, and re-testing. Every context reset loses your progress. Every new session starts from scratch.
33
+
34
+ **QA Workflow fixes that.** It discovers your tech stack, spawns specialized test agents, consolidates results into a structured report, and plans fixes — all autonomously. When it needs your input, it stops cleanly and waits. When you approve, it picks up exactly where it left off.
35
+
36
+ ---
37
+
38
+ ## Who This Is For
39
+
40
+ Developers using Claude Code who want real QA — not just "run the test suite." QA Workflow covers:
41
+
42
+ - **Unit, component, and E2E tests** — generated from your actual codebase
43
+ - **Security audits** — OWASP checklist, auth boundary testing, tenant isolation
44
+ - **UX heuristic evaluation** — Nielsen's 10 heuristics scored and reported
45
+ - **Performance benchmarks** — Lighthouse scores, load testing baselines
46
+ - **Visual regression** — screenshot-based change detection
47
+
48
+ All of it automated. All of it resumable.
49
+
50
+ ---
51
+
52
+ ## How It Works
53
+
54
+ ### 1. Bootstrap your project
55
+
56
+ ```
57
+ /qa:init
58
+ ```
59
+
60
+ QA Workflow discovers your tech stack — languages, frameworks, test runners, auth patterns, database setup. It generates specialized test agents tailored to your project. This runs once per project.
61
+
62
+ ### 2. Run a full QA cycle
63
+
64
+ ```
65
+ /qa:full
66
+ ```
67
+
68
+ The orchestrator takes over:
69
+
70
+ ```
71
+ Phase 0: Bootstrap (if needed)
72
+ Phase 1: Load resources & profile
73
+ Phase 2: Parse scope
74
+ Phase 3: Execute tests ← spawns parallel test agents
75
+ Phase 4: Consolidate report ← merges all results
76
+ Phase 5: Decision gate ← PASS / FAIL / ESCALATE
77
+ Phase 6: Plan fixes ← ■ STOPS here for your review
78
+ ```
79
+
80
+ You get a structured report and a prioritized fix plan. Review it, then continue.
81
+
82
+ ### 3. Approve and let it fix
83
+
84
+ ```
85
+ /qa:continue
86
+ ```
87
+
88
+ The system executes fixes in priority order, verifies each batch, then automatically re-runs the failing tests:
89
+
90
+ ```
91
+ Phase 7: Execute fixes ← batch checkpoints per priority
92
+ Phase 7b: Verify ← type-check + build + re-test
93
+ └─→ Loop back to Phase 3 ← next cycle (max 3)
94
+ ```
95
+
96
+ If everything passes → **Certified.** If defects persist after 3 cycles → **Escalated** with a detailed report.
97
+
98
+ ### 4. Resume from anywhere
99
+
100
+ ```
101
+ /qa:resume
102
+ ```
103
+
104
+ Context reset mid-cycle? Machine restarted? No problem. QA Workflow writes state before every phase. `/qa:resume` reads `cycle-state.json` and re-enters at the exact right phase.
105
+
106
+ ---
107
+
108
+ ## Commands
109
+
110
+ | Command | What it does |
111
+ |---------|--------------|
112
+ | `/qa:init` | Bootstrap QA infrastructure — discover tech stack, generate agents |
113
+ | `/qa:full` | Run complete QA cycle — test, report, decision gate, fix plan |
114
+ | `/qa:full api` | API/backend tests only |
115
+ | `/qa:full security` | Security audit only |
116
+ | `/qa:full ux` | UX heuristic evaluation only |
117
+ | `/qa:continue` | Execute approved fix plan — applies fixes, verifies, re-tests |
118
+ | `/qa:resume` | Resume from any interrupted state |
119
+ | `/qa:status` | View current QA progress dashboard |
120
+
121
+ ---
122
+
123
+ ## The Lifecycle
124
+
125
+ QA Workflow is a state machine. Every phase writes its state before executing, so nothing is ever lost.
126
+
127
+ ```
128
+ /qa:full
129
+
130
+ ┌─────────────┤
131
+ │ │
132
+ Phase 0 Phase 1─2
133
+ Bootstrap Load & Parse
134
+ (if needed) │
135
+ │ │
136
+ └─────────────┤
137
+
138
+ ╔═════════════════╧══════════════════╗
139
+ ║ CYCLE LOOP (max 3) ║
140
+ ║ ║
141
+ ║ Phase 3: Execute Tests ║
142
+ ║ └─ Parallel test agents ║
143
+ ║ Phase 4: Consolidate Report ║
144
+ ║ └─ Merge raw results ║
145
+ ║ Phase 5: Decision Gate ║
146
+ ║ ├─ PASS → Phase 8 (certify) ║
147
+ ║ ├─ FAIL → Phase 6 (plan) ║
148
+ ║ └─ STUCK → Phase 9 (escalate) ║
149
+ ║ ║
150
+ ║ Phase 6: Plan Fixes ║
151
+ ║ └─ ■ STOP — review plan ║
152
+ ║ run: /qa:continue ║
153
+ ║ ║
154
+ ║ Phase 7: Execute Fixes ║
155
+ ║ └─ Batch by priority ║
156
+ ║ Phase 7b: Verify & Re-test ║
157
+ ║ └─ → back to Phase 3 ║
158
+ ║ ║
159
+ ╚════════════════════════════════════╝
160
+
161
+ ┌──────────────┴──────────────┐
162
+ │ │
163
+ Phase 8 Phase 9
164
+ Certified ✓ Escalated ⚠
165
+ (all criteria pass) (stuck after 3 cycles)
166
+ ```
167
+
168
+ ### Stop Points
169
+
170
+ The system pauses at well-defined points — you're always in control.
171
+
172
+ | Stop Point | When | What to do |
173
+ |-----------|------|------------|
174
+ | **Bootstrap Complete** | After `/qa:init` | Run `/qa:full` to start testing |
175
+ | **Fix Plan Ready** | After Phase 6 | Review the plan, then `/qa:continue` |
176
+ | **Certified** | Phase 8 | Done — all exit criteria passed |
177
+ | **Escalated** | Phase 9 | Manual intervention needed for stuck defects |
178
+ | **Phase Transition** | Between phases | Recovery checkpoint (automatic) |
179
+
180
+ ---
181
+
182
+ ## Exit Criteria
183
+
184
+ QA certification requires all gates to pass:
185
+
186
+ | Gate | Threshold |
187
+ |------|-----------|
188
+ | P0 features pass | 100% |
189
+ | P1 features pass | 100% (or documented workarounds) |
190
+ | Critical defects open | 0 |
191
+ | Major defects open | 0 |
192
+ | Minor defects open | < 10 |
193
+ | UX Score (Nielsen avg) | >= 3.5 / 5.0 |
194
+ | WCAG 2.1 AA critical violations | 0 |
195
+ | Lighthouse Performance | >= 80 (if frontend) |
196
+ | Lighthouse Accessibility | >= 85 (if frontend) |
197
+ | Auth boundary tests | 100% pass (if auth exists) |
198
+ | Tenant isolation verified | All routers (if multi-tenant) |
199
+
200
+ ---
201
+
202
+ ## Architecture
203
+
204
+ ```
205
+ Command (thin dispatcher, ~65-150 lines)
206
+
207
+ ├─ Resolves model profile from references/model-profiles.md
208
+ ├─ Reads state from cycle-state.json
209
+ ├─ Routes to appropriate workflow
210
+
211
+ └─ Workflow (thick execution logic, ~50-100 lines)
212
+
213
+ ├─ Inlines profile + state into Task() prompts
214
+ ├─ Spawns specialized agents (parallel where possible)
215
+ ├─ Writes state checkpoints before each phase
216
+
217
+ └─ Outputs stop-point template
218
+ └─ templates/stop-points/*.md
219
+ ```
220
+
221
+ ### Design Principles
222
+
223
+ | Principle | Why |
224
+ |-----------|-----|
225
+ | **Thin commands, thick workflows** | Commands parse args and route. Workflows contain logic. Clean separation. |
226
+ | **Context inlining** | All `Task()` spawns include inlined profile/state data — no cross-boundary `@` references that break in subagents. |
227
+ | **Extracted templates** | Stop-point output is defined in template files — single source of truth, not buried in code. |
228
+ | **State-before-execute** | Every phase writes to `cycle-state.json` before running. If context resets, `/qa:resume` knows exactly where to continue. |
229
+
230
+ ### Test Agent Templates
231
+
232
+ QA Workflow generates specialized agents from these templates:
233
+
234
+ | Template | Coverage |
235
+ |----------|----------|
236
+ | `unit-test.md` | Unit test generation and execution |
237
+ | `component-test.md` | Component/integration testing |
238
+ | `e2e-test.md` | End-to-end user flow testing |
239
+ | `security-checklist-owasp.md` | OWASP top 10 security audit |
240
+ | `nielsen-heuristics.md` | UX heuristic evaluation (Nielsen's 10) |
241
+ | `performance-benchmarks-base.md` | Performance and Lighthouse scoring |
242
+ | `visual-regression.md` | Screenshot-based regression detection |
243
+ | `domain-security-profiles.md` | Domain-specific security rules |
244
+ | `domain-research-queries.md` | Domain-aware test generation |
245
+
246
+ ---
247
+
248
+ ## Model Profiles
249
+
250
+ Control cost and quality by routing agents to different Claude models.
251
+
252
+ Set in `.claude/qa-profile.json`:
253
+
254
+ ```json
255
+ { "config": { "model_profile": "balanced" } }
256
+ ```
257
+
258
+ | Profile | Philosophy | Best for |
259
+ |---------|-----------|----------|
260
+ | **quality** | Maximum reasoning — Opus for test execution, security, fix planning | Production releases, security-critical apps |
261
+ | **balanced** | Smart allocation — Opus for fix planning only, Sonnet elsewhere | Daily development, most projects |
262
+ | **budget** | Minimal Opus — Sonnet for code, Haiku for research/reports | Rapid iteration, cost-sensitive workflows |
263
+
264
+ > [!TIP]
265
+ > Start with `balanced`. Switch to `quality` before shipping. Use `budget` when iterating fast on early-stage features.
266
+
267
+ <details>
268
+ <summary><strong>Full agent-to-model mapping</strong></summary>
269
+
270
+ See `skills/qa/references/model-profiles.md` for the complete table showing which model handles each agent role across all three profiles.
271
+
272
+ </details>
273
+
274
+ ---
275
+
276
+ ## Getting Started
277
+
278
+ ### Installation
279
+
280
+ ```bash
281
+ npx qa-workflow-cc
282
+ ```
283
+
284
+ That's it. The installer copies commands and skills into `~/.claude/` and backs up any existing files.
285
+
286
+ <details>
287
+ <summary><strong>Non-interactive install (Docker, CI, Scripts)</strong></summary>
288
+
289
+ ```bash
290
+ npx qa-workflow-cc --global # Install to ~/.claude/
291
+ npx qa-workflow-cc --local # Install to ./.claude/
292
+ ```
293
+
294
+ Use `--global` (`-g`) or `--local` (`-l`) to skip the interactive prompt.
295
+
296
+ </details>
297
+
298
+ <details>
299
+ <summary><strong>Development installation</strong></summary>
300
+
301
+ Clone the repository and use symlinks for live editing:
302
+
303
+ ```bash
304
+ git clone https://github.com/desland01/qa-workflow.git ~/qa-workflow
305
+ cd ~/qa-workflow
306
+ chmod +x install.sh
307
+ ./install.sh
308
+ ```
309
+
310
+ Changes in `~/qa-workflow/` are live immediately via symlinks — no reinstall needed.
311
+
312
+ </details>
313
+
314
+ ### First Run
315
+
316
+ ```bash
317
+ # 1. Open your project in Claude Code
318
+ claude
319
+
320
+ # 2. Bootstrap QA for this project
321
+ /qa:init
322
+
323
+ # 3. Run the full QA cycle
324
+ /qa:full
325
+
326
+ # 4. When the fix plan appears, review it, then:
327
+ /qa:continue
328
+ ```
329
+
330
+ ### Recommended: Skip Permissions
331
+
332
+ QA Workflow spawns multiple agents that run tests, read files, and write reports. For a smooth experience:
333
+
334
+ ```bash
335
+ claude --dangerously-skip-permissions
336
+ ```
337
+
338
+ <details>
339
+ <summary><strong>Alternative: Granular Permissions</strong></summary>
340
+
341
+ Add to your project's `.claude/settings.json`:
342
+
343
+ ```json
344
+ {
345
+ "permissions": {
346
+ "allow": [
347
+ "Bash(date:*)",
348
+ "Bash(echo:*)",
349
+ "Bash(cat:*)",
350
+ "Bash(ls:*)",
351
+ "Bash(mkdir:*)",
352
+ "Bash(wc:*)",
353
+ "Bash(head:*)",
354
+ "Bash(tail:*)",
355
+ "Bash(git add:*)",
356
+ "Bash(git commit:*)",
357
+ "Bash(git status:*)",
358
+ "Bash(git log:*)",
359
+ "Bash(git diff:*)",
360
+ "Bash(npm test:*)",
361
+ "Bash(npx:*)",
362
+ "Bash(pytest:*)",
363
+ "Bash(cargo test:*)"
364
+ ]
365
+ }
366
+ }
367
+ ```
368
+
369
+ </details>
370
+
371
+ ---
372
+
373
+ ## Directory Structure
374
+
375
+ ```
376
+ qa-workflow/
377
+ ├── README.md
378
+ ├── VERSION
379
+ ├── install.sh
380
+
381
+ ├── commands/qa/ # Thin dispatchers
382
+ │ ├── full.md # Main QA cycle orchestrator
383
+ │ ├── continue.md # Fix execution entry point
384
+ │ ├── init.md # Bootstrap-only command
385
+ │ ├── resume.md # Universal recovery command
386
+ │ └── status.md # Read-only dashboard
387
+
388
+ └── skills/qa/ # Thick execution layer
389
+ ├── SKILL.md # Bootstrap protocol (B1-B9)
390
+ ├── references/
391
+ │ ├── continuation-format.md # Format rules + template index
392
+ │ ├── exit-criteria.md # Pass/fail thresholds
393
+ │ ├── lifecycle.md # Phase definitions + state machine
394
+ │ └── model-profiles.md # Agent-to-model mapping
395
+ ├── templates/
396
+ │ ├── agent-skeleton.md # Base agent template
397
+ │ ├── unit-test.md # Unit test agent
398
+ │ ├── component-test.md # Component test agent
399
+ │ ├── e2e-test.md # E2E test agent
400
+ │ ├── security-checklist-owasp.md
401
+ │ ├── nielsen-heuristics.md # UX evaluation
402
+ │ ├── performance-benchmarks-base.md
403
+ │ ├── visual-regression.md
404
+ │ ├── qa-report-template.md
405
+ │ ├── test-standards.md
406
+ │ ├── domain-research-queries.md
407
+ │ ├── domain-security-profiles.md
408
+ │ └── stop-points/ # Output templates
409
+ │ ├── bootstrap-complete.md
410
+ │ ├── fix-ready.md
411
+ │ ├── certified.md
412
+ │ ├── escalated.md
413
+ │ ├── status-dashboard.md
414
+ │ └── phase-transition.md
415
+ └── workflows/ # Thick execution logic
416
+ ├── bootstrap.md # Phase 0
417
+ ├── test-phase.md # Phase 3
418
+ ├── report-phase.md # Phase 4
419
+ ├── decision-gate.md # Phase 5
420
+ ├── fix-plan.md # Phase 6
421
+ ├── fix-execute.md # Phase 7
422
+ └── verify-phase.md # Phase 7b
423
+ ```
424
+
425
+ ---
426
+
427
+ ## Troubleshooting
428
+
429
+ **Commands not found after install?**
430
+ - Restart Claude Code to reload slash commands
431
+ - Verify symlinks exist: `ls -la ~/.claude/commands/qa/` and `ls -la ~/.claude/skills/qa/`
432
+
433
+ **QA cycle stuck or interrupted?**
434
+ - Run `/qa:resume` — it reads `cycle-state.json` and re-enters at the correct phase
435
+ - Run `/qa:status` to see exactly where the cycle stopped
436
+
437
+ **Want to re-run from scratch?**
438
+ - Delete `cycle-state.json` in your project directory, then run `/qa:full`
439
+
440
+ **Tests failing for the wrong reasons?**
441
+ - Run `/qa:init` again to regenerate agents with updated tech stack detection
442
+ - Check that your project builds and tests pass manually first
443
+
444
+ ---
445
+
446
+ ## Contributing
447
+
448
+ 1. Clone the repo and run `./install.sh`
449
+ 2. Edit files in `~/qa-workflow/` — changes are live via symlinks
450
+ 3. Test with `/qa:status` (read-only, safe) to verify nothing breaks
451
+ 4. For command changes, test the full flow with `/qa:full` in a test project
452
+
453
+ ---
454
+
455
+ <div align="center">
456
+
457
+ **Claude Code is powerful. QA Workflow makes it thorough.**
458
+
459
+ *Autonomous test-fix-verify cycles — so you can build, not babysit.*
460
+
461
+ </div>
package/VERSION ADDED
@@ -0,0 +1 @@
1
+ 1.0.0
package/bin/install.js ADDED
@@ -0,0 +1,116 @@
1
+ #!/usr/bin/env node
2
+
3
+ const fs = require("fs");
4
+ const path = require("path");
5
+ const os = require("os");
6
+ const readline = require("readline");
7
+
8
+ const VERSION = fs
9
+ .readFileSync(path.join(__dirname, "..", "VERSION"), "utf8")
10
+ .trim();
11
+ const PKG_ROOT = path.join(__dirname, "..");
12
+ const HOME = os.homedir();
13
+
14
+ const TARGETS = {
15
+ global: path.join(HOME, ".claude"),
16
+ local: path.join(process.cwd(), ".claude"),
17
+ };
18
+
19
+ const DIRS_TO_COPY = ["commands/qa", "skills/qa"];
20
+
21
+ // ── Helpers ──────────────────────────────────────────────────────────
22
+
23
+ function copyDirSync(src, dest) {
24
+ fs.mkdirSync(dest, { recursive: true });
25
+ for (const entry of fs.readdirSync(src, { withFileTypes: true })) {
26
+ const srcPath = path.join(src, entry.name);
27
+ const destPath = path.join(dest, entry.name);
28
+ if (entry.isDirectory()) {
29
+ copyDirSync(srcPath, destPath);
30
+ } else {
31
+ fs.copyFileSync(srcPath, destPath);
32
+ }
33
+ }
34
+ }
35
+
36
+ function backupIfExists(target) {
37
+ if (fs.existsSync(target)) {
38
+ const timestamp = new Date()
39
+ .toISOString()
40
+ .replace(/[-:T]/g, "")
41
+ .slice(0, 14);
42
+ const backup = `${target}.backup.${timestamp}`;
43
+ console.log(` Backing up existing → ${path.basename(backup)}`);
44
+ fs.renameSync(target, backup);
45
+ }
46
+ }
47
+
48
+ function install(claudeDir) {
49
+ console.log(`\nInstalling to ${claudeDir}/\n`);
50
+
51
+ for (const rel of DIRS_TO_COPY) {
52
+ const src = path.join(PKG_ROOT, rel);
53
+ const dest = path.join(claudeDir, rel);
54
+
55
+ // Ensure parent dir exists
56
+ fs.mkdirSync(path.dirname(dest), { recursive: true });
57
+
58
+ backupIfExists(dest);
59
+ copyDirSync(src, dest);
60
+ console.log(` Copied: ${rel}`);
61
+ }
62
+
63
+ console.log(`
64
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
65
+ Install complete.
66
+
67
+ Commands available:
68
+ /qa:init — Bootstrap QA infrastructure
69
+ /qa:full — Run complete QA cycle
70
+ /qa:continue — Execute approved fix plan
71
+ /qa:resume — Resume from any interrupted state
72
+ /qa:status — View current QA progress
73
+
74
+ Restart Claude Code to load the new commands.
75
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━`);
76
+ }
77
+
78
+ // ── Main ─────────────────────────────────────────────────────────────
79
+
80
+ console.log(`
81
+ QA Workflow Installer v${VERSION}
82
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━`);
83
+
84
+ const args = process.argv.slice(2);
85
+
86
+ if (args.includes("--global") || args.includes("-g")) {
87
+ install(TARGETS.global);
88
+ } else if (args.includes("--local") || args.includes("-l")) {
89
+ install(TARGETS.local);
90
+ } else {
91
+ // Interactive prompt
92
+ const rl = readline.createInterface({
93
+ input: process.stdin,
94
+ output: process.stdout,
95
+ });
96
+
97
+ console.log(`
98
+ Where would you like to install?
99
+
100
+ 1) Global (~/.claude/) — available in all projects
101
+ 2) Local (./.claude/) — this project only
102
+ `);
103
+
104
+ rl.question("Choose [1/2]: ", (answer) => {
105
+ rl.close();
106
+ const choice = answer.trim();
107
+ if (choice === "1" || choice.toLowerCase() === "global") {
108
+ install(TARGETS.global);
109
+ } else if (choice === "2" || choice.toLowerCase() === "local") {
110
+ install(TARGETS.local);
111
+ } else {
112
+ console.log("Invalid choice. Use --global or --local flag, or enter 1 or 2.");
113
+ process.exit(1);
114
+ }
115
+ });
116
+ }
@@ -0,0 +1,77 @@
1
+ ---
2
+ name: qa:continue
3
+ description: Execute approved fix plan — applies fixes, verifies, then re-tests automatically
4
+ argument-hint: ""
5
+ allowed-tools:
6
+ - Read
7
+ - Write
8
+ - Edit
9
+ - Bash
10
+ - Glob
11
+ - Grep
12
+ - Task
13
+ ---
14
+
15
+ <execution_context>
16
+ @.claude/qa-profile.json
17
+ @docs/qa-reports/cycle-state.json
18
+ </execution_context>
19
+
20
+ <objective>
21
+ Execute the approved fix plan from Phase 6. This is the ONLY entry point for fix execution.
22
+
23
+ Flow: Read fix plan → Execute fixes (P0 → P1 → P2) → Verify → Re-test (next cycle) → Decision → STOP or certify.
24
+
25
+ **Orchestrator role:** Dispatch fix agents, validate results, manage batch checkpoints. NEVER write code directly.
26
+ </objective>
27
+
28
+ <process>
29
+
30
+ ## 1. Validate State
31
+
32
+ Read cycle-state.json from auto-context.
33
+
34
+ **If state.phase is NOT "awaiting_fix_approval":**
35
+ - Error: "No pending fix plan. Current state: {state.phase}."
36
+ - Suggest: `/qa:full` to start a new cycle, or `/qa:resume` to continue from current state.
37
+ - STOP
38
+
39
+ **If state.phase IS "awaiting_fix_approval":** Continue.
40
+
41
+ ## 2. Resolve Model Profile
42
+
43
+ Read `config.model_profile` from qa-profile.json (default: "balanced").
44
+ Resolve per-agent models from `~/.claude/skills/qa/references/model-profiles.md`.
45
+
46
+ ## Context Inlining (GSD Pattern)
47
+
48
+ Before any Task() spawn, the orchestrator MUST:
49
+ 1. Read .claude/qa-profile.json → PROFILE (already auto-loaded)
50
+ 2. Read docs/qa-reports/cycle-state.json → STATE (already auto-loaded)
51
+ 3. Read ~/.claude/skills/qa/references/model-profiles.md → resolve per-agent model
52
+ 4. Inline relevant PROFILE and STATE sections into each Task() prompt
53
+ 5. Do NOT rely on @ references crossing Task() boundaries
54
+
55
+ ## 3. Load Fix Plan
56
+
57
+ Read fix plan from `state.fixPlanPath`.
58
+ Read agent routing from `profile.agentRouting.fixRoutes`.
59
+
60
+ ## 4. Phase 7: Execute Fixes
61
+
62
+ Follow `~/.claude/skills/qa/workflows/fix-execute.md`
63
+
64
+ ## 5. Phase 7b: Verify Fixes
65
+
66
+ Follow `~/.claude/skills/qa/workflows/verify-phase.md`
67
+
68
+ ## 6. Next Cycle (Phase 3 → 4 → 5)
69
+
70
+ Run full test suite (not just previously failed tests) to catch regressions.
71
+ Consolidate report. Evaluate decision gate.
72
+
73
+ **If PASS:** Certify (Phase 8 output).
74
+ **If FAIL:** Plan fixes (Phase 6 output — STOP again for approval).
75
+ **If ESCALATE:** Escalation report (Phase 9 output).
76
+
77
+ </process>