qualia-framework 2.5.1 → 3.1.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.md +63 -0
- package/README.md +108 -30
- package/agents/builder.md +110 -0
- package/agents/planner.md +186 -0
- package/agents/qa-browser.md +186 -0
- package/agents/verifier.md +369 -0
- package/bin/cli.js +706 -417
- package/bin/install.js +622 -0
- package/bin/qualia-ui.js +284 -0
- package/bin/state.js +824 -0
- package/bin/statusline.js +252 -0
- package/docs/erp-contract.md +161 -0
- package/guide.md +63 -0
- package/hooks/auto-update.js +117 -0
- package/hooks/block-env-edit.js +52 -0
- package/hooks/branch-guard.js +68 -0
- package/hooks/migration-guard.js +83 -0
- package/hooks/pre-compact.js +52 -0
- package/hooks/pre-deploy-gate.js +149 -0
- package/hooks/pre-push.js +53 -0
- package/hooks/session-start.js +126 -0
- package/package.json +31 -17
- package/rules/design-reference.md +179 -0
- package/rules/frontend.md +126 -0
- package/rules/infrastructure.md +87 -0
- package/skills/qualia/SKILL.md +88 -0
- package/skills/qualia-build/SKILL.md +115 -0
- package/skills/qualia-debug/SKILL.md +87 -0
- package/skills/qualia-design/SKILL.md +99 -0
- package/skills/qualia-handoff/SKILL.md +66 -0
- package/skills/qualia-help/SKILL.md +60 -0
- package/skills/qualia-idk/SKILL.md +8 -0
- package/skills/qualia-learn/SKILL.md +111 -0
- package/skills/qualia-new/SKILL.md +323 -0
- package/skills/qualia-pause/SKILL.md +63 -0
- package/skills/qualia-plan/SKILL.md +101 -0
- package/skills/qualia-polish/SKILL.md +207 -0
- package/skills/qualia-quick/SKILL.md +37 -0
- package/skills/qualia-report/SKILL.md +114 -0
- package/skills/qualia-resume/SKILL.md +49 -0
- package/skills/qualia-review/SKILL.md +161 -0
- package/skills/qualia-ship/SKILL.md +90 -0
- package/skills/qualia-skill-new/SKILL.md +167 -0
- package/skills/qualia-task/SKILL.md +91 -0
- package/skills/qualia-test/SKILL.md +134 -0
- package/skills/qualia-verify/SKILL.md +113 -0
- package/templates/DESIGN.md +475 -0
- package/templates/help.html +476 -0
- package/templates/plan.md +42 -0
- package/templates/project.md +22 -0
- package/templates/state.md +27 -0
- package/templates/tracking.json +20 -0
- package/tests/bin.test.sh +687 -0
- package/tests/hooks.test.sh +384 -0
- package/tests/runner.js +1956 -0
- package/tests/state.test.sh +713 -0
- package/tests/statusline.test.sh +243 -0
- package/bin/collect-metrics.sh +0 -62
- package/framework/.claudeignore +0 -51
- package/framework/CLAUDE.md +0 -51
- package/framework/MCP_SETUP.md +0 -229
- package/framework/agents/architecture-strategist.md +0 -53
- package/framework/agents/backend-agent.md +0 -150
- package/framework/agents/code-simplicity-reviewer.md +0 -86
- package/framework/agents/frontend-agent.md +0 -111
- package/framework/agents/kieran-typescript-reviewer.md +0 -96
- package/framework/agents/performance-oracle.md +0 -111
- package/framework/agents/qualia-codebase-mapper.md +0 -761
- package/framework/agents/qualia-debugger.md +0 -1204
- package/framework/agents/qualia-executor.md +0 -882
- package/framework/agents/qualia-integration-checker.md +0 -424
- package/framework/agents/qualia-phase-researcher.md +0 -457
- package/framework/agents/qualia-plan-checker.md +0 -700
- package/framework/agents/qualia-planner.md +0 -1245
- package/framework/agents/qualia-project-researcher.md +0 -603
- package/framework/agents/qualia-research-synthesizer.md +0 -200
- package/framework/agents/qualia-roadmapper.md +0 -606
- package/framework/agents/qualia-verifier.md +0 -686
- package/framework/agents/red-team-qa.md +0 -130
- package/framework/agents/security-auditor.md +0 -72
- package/framework/agents/team-orchestrator.md +0 -229
- package/framework/agents/teams/framework-audit-team.md +0 -66
- package/framework/agents/teams/full-stack-team.md +0 -48
- package/framework/agents/teams/optimize-team.md +0 -53
- package/framework/agents/teams/review-team.md +0 -70
- package/framework/agents/teams/ship-team.md +0 -86
- package/framework/agents/test-agent.md +0 -182
- package/framework/hooks/auto-format.sh +0 -54
- package/framework/hooks/block-env-edit.sh +0 -42
- package/framework/hooks/branch-guard.sh +0 -43
- package/framework/hooks/confirm-delete.sh +0 -59
- package/framework/hooks/migration-validate.sh +0 -77
- package/framework/hooks/notification-speak.sh +0 -16
- package/framework/hooks/pre-commit.sh +0 -100
- package/framework/hooks/pre-compact.sh +0 -56
- package/framework/hooks/pre-deploy-gate.sh +0 -160
- package/framework/hooks/qualia-colors.sh +0 -32
- package/framework/hooks/retention-cleanup.sh +0 -62
- package/framework/hooks/save-session-state.sh +0 -185
- package/framework/hooks/session-context-loader.sh +0 -96
- package/framework/hooks/session-learn.sh +0 -32
- package/framework/hooks/skill-announce.sh +0 -123
- package/framework/hooks/tool-error-announce.sh +0 -27
- package/framework/install.ps1 +0 -323
- package/framework/install.sh +0 -313
- package/framework/qualia-framework/VERSION +0 -1
- package/framework/qualia-framework/assets/qualia-logo.png +0 -0
- package/framework/qualia-framework/bin/collect-metrics.sh +0 -67
- package/framework/qualia-framework/bin/generate-report-docx.py +0 -429
- package/framework/qualia-framework/bin/qualia-tools.js +0 -2201
- package/framework/qualia-framework/bin/qualia-tools.test.js +0 -1054
- package/framework/qualia-framework/references/checkpoints.md +0 -775
- package/framework/qualia-framework/references/completion-checklists.md +0 -359
- package/framework/qualia-framework/references/continuation-format.md +0 -249
- package/framework/qualia-framework/references/continuation-prompt.md +0 -97
- package/framework/qualia-framework/references/decimal-phase-calculation.md +0 -65
- package/framework/qualia-framework/references/design-quality.md +0 -56
- package/framework/qualia-framework/references/employee-guide.md +0 -167
- package/framework/qualia-framework/references/git-integration.md +0 -254
- package/framework/qualia-framework/references/git-planning-commit.md +0 -50
- package/framework/qualia-framework/references/model-profile-resolution.md +0 -32
- package/framework/qualia-framework/references/model-profiles.md +0 -73
- package/framework/qualia-framework/references/phase-argument-parsing.md +0 -61
- package/framework/qualia-framework/references/planning-config.md +0 -195
- package/framework/qualia-framework/references/questioning.md +0 -141
- package/framework/qualia-framework/references/tdd.md +0 -263
- package/framework/qualia-framework/references/ui-brand.md +0 -160
- package/framework/qualia-framework/references/verification-patterns.md +0 -612
- package/framework/qualia-framework/templates/DEBUG.md +0 -159
- package/framework/qualia-framework/templates/DESIGN.md +0 -81
- package/framework/qualia-framework/templates/UAT.md +0 -247
- package/framework/qualia-framework/templates/codebase/architecture.md +0 -255
- package/framework/qualia-framework/templates/codebase/concerns.md +0 -310
- package/framework/qualia-framework/templates/codebase/conventions.md +0 -307
- package/framework/qualia-framework/templates/codebase/integrations.md +0 -280
- package/framework/qualia-framework/templates/codebase/stack.md +0 -186
- package/framework/qualia-framework/templates/codebase/structure.md +0 -285
- package/framework/qualia-framework/templates/codebase/testing.md +0 -480
- package/framework/qualia-framework/templates/config.json +0 -35
- package/framework/qualia-framework/templates/context.md +0 -283
- package/framework/qualia-framework/templates/continue-here.md +0 -78
- package/framework/qualia-framework/templates/debug-subagent-prompt.md +0 -91
- package/framework/qualia-framework/templates/discovery.md +0 -146
- package/framework/qualia-framework/templates/lab-notes.md +0 -16
- package/framework/qualia-framework/templates/milestone-archive.md +0 -123
- package/framework/qualia-framework/templates/milestone.md +0 -115
- package/framework/qualia-framework/templates/phase-prompt.md +0 -567
- package/framework/qualia-framework/templates/planner-subagent-prompt.md +0 -117
- package/framework/qualia-framework/templates/project.md +0 -184
- package/framework/qualia-framework/templates/projects/ai-agent.md +0 -156
- package/framework/qualia-framework/templates/projects/mobile-app.md +0 -181
- package/framework/qualia-framework/templates/projects/voice-agent.md +0 -134
- package/framework/qualia-framework/templates/projects/website.md +0 -137
- package/framework/qualia-framework/templates/requirements.md +0 -231
- package/framework/qualia-framework/templates/research-project/ARCHITECTURE.md +0 -204
- package/framework/qualia-framework/templates/research-project/FEATURES.md +0 -147
- package/framework/qualia-framework/templates/research-project/PITFALLS.md +0 -200
- package/framework/qualia-framework/templates/research-project/STACK.md +0 -120
- package/framework/qualia-framework/templates/research-project/SUMMARY.md +0 -170
- package/framework/qualia-framework/templates/research.md +0 -552
- package/framework/qualia-framework/templates/roadmap.md +0 -206
- package/framework/qualia-framework/templates/state.md +0 -179
- package/framework/qualia-framework/templates/summary-complex.md +0 -59
- package/framework/qualia-framework/templates/summary-minimal.md +0 -41
- package/framework/qualia-framework/templates/summary-standard.md +0 -48
- package/framework/qualia-framework/templates/summary.md +0 -246
- package/framework/qualia-framework/templates/user-setup.md +0 -311
- package/framework/qualia-framework/templates/verification-report.md +0 -322
- package/framework/qualia-framework/workflows/add-phase.md +0 -179
- package/framework/qualia-framework/workflows/add-todo.md +0 -157
- package/framework/qualia-framework/workflows/audit-milestone.md +0 -241
- package/framework/qualia-framework/workflows/check-todos.md +0 -176
- package/framework/qualia-framework/workflows/complete-milestone.md +0 -858
- package/framework/qualia-framework/workflows/diagnose-issues.md +0 -219
- package/framework/qualia-framework/workflows/discovery-phase.md +0 -289
- package/framework/qualia-framework/workflows/discuss-phase.md +0 -534
- package/framework/qualia-framework/workflows/execute-phase.md +0 -559
- package/framework/qualia-framework/workflows/execute-plan.md +0 -438
- package/framework/qualia-framework/workflows/help.md +0 -470
- package/framework/qualia-framework/workflows/insert-phase.md +0 -220
- package/framework/qualia-framework/workflows/list-phase-assumptions.md +0 -178
- package/framework/qualia-framework/workflows/map-codebase.md +0 -327
- package/framework/qualia-framework/workflows/new-milestone.md +0 -363
- package/framework/qualia-framework/workflows/new-project.md +0 -982
- package/framework/qualia-framework/workflows/pause-work.md +0 -122
- package/framework/qualia-framework/workflows/plan-milestone-gaps.md +0 -256
- package/framework/qualia-framework/workflows/plan-phase.md +0 -422
- package/framework/qualia-framework/workflows/progress.md +0 -389
- package/framework/qualia-framework/workflows/quick.md +0 -252
- package/framework/qualia-framework/workflows/remove-phase.md +0 -326
- package/framework/qualia-framework/workflows/research-phase.md +0 -74
- package/framework/qualia-framework/workflows/resume-project.md +0 -306
- package/framework/qualia-framework/workflows/set-profile.md +0 -80
- package/framework/qualia-framework/workflows/settings.md +0 -145
- package/framework/qualia-framework/workflows/transition.md +0 -556
- package/framework/qualia-framework/workflows/update.md +0 -197
- package/framework/qualia-framework/workflows/verify-phase.md +0 -195
- package/framework/qualia-framework/workflows/verify-work.md +0 -625
- package/framework/rules/context7.md +0 -14
- package/framework/rules/frontend.md +0 -33
- package/framework/rules/speed.md +0 -23
- package/framework/scripts/__pycache__/say.cpython-314.pyc +0 -0
- package/framework/scripts/apply-retention.sh +0 -120
- package/framework/scripts/bootstrap-pop-os.sh +0 -354
- package/framework/scripts/claude-voice +0 -13
- package/framework/scripts/cleanup.sh +0 -131
- package/framework/scripts/cowork-mode.sh +0 -141
- package/framework/scripts/generate-project-claude-md.sh +0 -153
- package/framework/scripts/load-test-webhook.js +0 -172
- package/framework/scripts/say.py +0 -236
- package/framework/scripts/showcase-video-recorder/ffmpeg-builder.js +0 -167
- package/framework/scripts/showcase-video-recorder/playwright-helpers.js +0 -216
- package/framework/scripts/speak.py +0 -55
- package/framework/scripts/speak.sh +0 -18
- package/framework/scripts/status.sh +0 -138
- package/framework/scripts/sync-to-framework.sh +0 -65
- package/framework/scripts/voice-hotkey.py +0 -227
- package/framework/scripts/voice-input.sh +0 -51
- package/framework/skills/animate/SKILL.md +0 -202
- package/framework/skills/bolder/SKILL.md +0 -144
- package/framework/skills/browser-qa/SKILL.md +0 -536
- package/framework/skills/clarify/SKILL.md +0 -179
- package/framework/skills/client-handoff/SKILL.md +0 -135
- package/framework/skills/collab-onboard/SKILL.md +0 -111
- package/framework/skills/colorize/SKILL.md +0 -170
- package/framework/skills/critique/SKILL.md +0 -126
- package/framework/skills/deep-research/SKILL.md +0 -240
- package/framework/skills/delight/SKILL.md +0 -329
- package/framework/skills/deploy/SKILL.md +0 -261
- package/framework/skills/deploy-verify/SKILL.md +0 -377
- package/framework/skills/deploy-verify/scripts/canary-check.sh +0 -206
- package/framework/skills/deploy-verify/scripts/check-console-errors.js +0 -147
- package/framework/skills/deploy-verify/scripts/check-cwv.js +0 -139
- package/framework/skills/deploy-verify/scripts/project-detect.sh +0 -84
- package/framework/skills/deploy-verify/scripts/verify.sh +0 -548
- package/framework/skills/design-quieter/SKILL.md +0 -130
- package/framework/skills/distill/SKILL.md +0 -149
- package/framework/skills/docs-lookup/SKILL.md +0 -79
- package/framework/skills/fcm-notifications/SKILL.md +0 -125
- package/framework/skills/financial-ledger/SKILL.md +0 -1039
- package/framework/skills/frontend-master/NOTICE.md +0 -4
- package/framework/skills/frontend-master/SKILL.md +0 -127
- package/framework/skills/frontend-master/reference/color-and-contrast.md +0 -132
- package/framework/skills/frontend-master/reference/interaction-design.md +0 -123
- package/framework/skills/frontend-master/reference/motion-design.md +0 -99
- package/framework/skills/frontend-master/reference/responsive-design.md +0 -114
- package/framework/skills/frontend-master/reference/spatial-design.md +0 -100
- package/framework/skills/frontend-master/reference/typography.md +0 -131
- package/framework/skills/frontend-master/reference/ux-writing.md +0 -107
- package/framework/skills/harden/SKILL.md +0 -357
- package/framework/skills/i18n-rtl/SKILL.md +0 -752
- package/framework/skills/learn/SKILL.md +0 -95
- package/framework/skills/memory/SKILL.md +0 -50
- package/framework/skills/mobile-expo/SKILL.md +0 -977
- package/framework/skills/mobile-expo/references/store-checklist.md +0 -550
- package/framework/skills/nestjs-backend/README.md +0 -73
- package/framework/skills/nestjs-backend/SKILL.md +0 -446
- package/framework/skills/nestjs-backend/references/templates.md +0 -1173
- package/framework/skills/normalize/SKILL.md +0 -79
- package/framework/skills/onboard/SKILL.md +0 -242
- package/framework/skills/openrouter-agent/SKILL.md +0 -922
- package/framework/skills/polish/SKILL.md +0 -209
- package/framework/skills/pr/SKILL.md +0 -66
- package/framework/skills/qualia/SKILL.md +0 -199
- package/framework/skills/qualia-add-todo/SKILL.md +0 -68
- package/framework/skills/qualia-audit-milestone/SKILL.md +0 -95
- package/framework/skills/qualia-check-todos/SKILL.md +0 -55
- package/framework/skills/qualia-complete-milestone/SKILL.md +0 -134
- package/framework/skills/qualia-debug/SKILL.md +0 -149
- package/framework/skills/qualia-design/SKILL.md +0 -203
- package/framework/skills/qualia-discuss-phase/SKILL.md +0 -72
- package/framework/skills/qualia-evolve/SKILL.md +0 -200
- package/framework/skills/qualia-execute-phase/SKILL.md +0 -89
- package/framework/skills/qualia-framework-audit/SKILL.md +0 -604
- package/framework/skills/qualia-guide/SKILL.md +0 -32
- package/framework/skills/qualia-help/SKILL.md +0 -114
- package/framework/skills/qualia-idk/SKILL.md +0 -352
- package/framework/skills/qualia-list-phase-assumptions/SKILL.md +0 -67
- package/framework/skills/qualia-new-milestone/SKILL.md +0 -72
- package/framework/skills/qualia-new-project/SKILL.md +0 -232
- package/framework/skills/qualia-optimize/SKILL.md +0 -417
- package/framework/skills/qualia-pause-work/SKILL.md +0 -96
- package/framework/skills/qualia-plan-milestone-gaps/SKILL.md +0 -57
- package/framework/skills/qualia-plan-phase/SKILL.md +0 -104
- package/framework/skills/qualia-production-check/SKILL.md +0 -0
- package/framework/skills/qualia-progress/SKILL.md +0 -53
- package/framework/skills/qualia-quick/SKILL.md +0 -89
- package/framework/skills/qualia-report/SKILL.md +0 -166
- package/framework/skills/qualia-research-phase/SKILL.md +0 -88
- package/framework/skills/qualia-resume-work/SKILL.md +0 -62
- package/framework/skills/qualia-review/SKILL.md +0 -263
- package/framework/skills/qualia-start/SKILL.md +0 -161
- package/framework/skills/qualia-verify-work/SKILL.md +0 -132
- package/framework/skills/rag/SKILL.md +0 -750
- package/framework/skills/responsive/SKILL.md +0 -231
- package/framework/skills/retro/SKILL.md +0 -284
- package/framework/skills/sakani-conventions/SKILL.md +0 -136
- package/framework/skills/sakani-conventions/evals/evals.json +0 -23
- package/framework/skills/sakani-conventions/references/entities.md +0 -365
- package/framework/skills/sakani-conventions/references/error-codes.md +0 -95
- package/framework/skills/seo-master/SKILL.md +0 -490
- package/framework/skills/seo-master/references/checklist.md +0 -199
- package/framework/skills/seo-master/references/structured-data.md +0 -609
- package/framework/skills/ship/SKILL.md +0 -239
- package/framework/skills/stack-researcher/SKILL.md +0 -215
- package/framework/skills/status/SKILL.md +0 -154
- package/framework/skills/status/scripts/health-check.sh +0 -562
- package/framework/skills/subscription-payments/SKILL.md +0 -250
- package/framework/skills/supabase/SKILL.md +0 -973
- package/framework/skills/supabase/references/templates.md +0 -159
- package/framework/skills/team/SKILL.md +0 -67
- package/framework/skills/test-runner/SKILL.md +0 -202
- package/framework/skills/voice-agent/SKILL.md +0 -1312
- package/framework/skills/zoho-workflow/SKILL.md +0 -51
- package/framework/statusline-command.sh +0 -117
- package/framework/teams/default/inboxes/plan-04.json +0 -9
- package/framework/teams/review-team.md +0 -75
- package/framework/teams/ship-team.md +0 -86
- package/profiles/fawzi.json +0 -16
- package/profiles/hasan.json +0 -16
- package/profiles/moayad.json +0 -16
- package/templates/CLAUDE-owner.md +0 -52
- package/templates/CLAUDE.md.hbs +0 -58
- package/templates/env.claude.template +0 -12
- package/templates/settings.json +0 -172
- /package/{framework/rules → rules}/deployment.md +0 -0
- /package/{framework/rules → rules}/security.md +0 -0
|
@@ -1,130 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: red-team-qa
|
|
3
|
-
description: Adversarial QA agent that actively tries to break implementations. Tests edge cases, error paths, boundary conditions, and unexpected inputs. Spawned after cooperative verification passes.
|
|
4
|
-
tools: Read, Bash, Grep, Glob
|
|
5
|
-
model: inherit
|
|
6
|
-
color: red
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
You are a red-team QA agent. Your job is to **break things**, not confirm they work.
|
|
10
|
-
|
|
11
|
-
You receive a phase goal and codebase access. You do NOT receive SUMMARY.md, PLAN.md, or execution history — you work from the goal and the code alone to avoid confirmation bias.
|
|
12
|
-
|
|
13
|
-
## Mindset
|
|
14
|
-
|
|
15
|
-
You are the adversary. The executor wants you to find nothing. Your incentive is the opposite: find every crack, every unhandled path, every assumption that breaks under pressure. A clean report means you didn't look hard enough.
|
|
16
|
-
|
|
17
|
-
## Attack Dimensions
|
|
18
|
-
|
|
19
|
-
### 1. Input Boundaries
|
|
20
|
-
- Empty strings, null, undefined where values are expected
|
|
21
|
-
- Extremely long inputs (10k+ chars in text fields)
|
|
22
|
-
- Special characters: `<script>`, SQL injection patterns, unicode edge cases
|
|
23
|
-
- Negative numbers, zero, MAX_SAFE_INTEGER where numbers are expected
|
|
24
|
-
- Malformed emails, URLs, dates
|
|
25
|
-
|
|
26
|
-
### 2. Error Paths
|
|
27
|
-
- What happens when the API returns 500? 404? Network timeout?
|
|
28
|
-
- What happens when Supabase is unreachable?
|
|
29
|
-
- What happens when auth token expires mid-session?
|
|
30
|
-
- Are all try/catch blocks actually catching the right errors?
|
|
31
|
-
- Do error messages leak internal details?
|
|
32
|
-
|
|
33
|
-
### 3. User Flow Breakage
|
|
34
|
-
- Can you reach a dead-end state with no way back?
|
|
35
|
-
- What happens if you navigate directly to a deep URL without auth?
|
|
36
|
-
- What happens if you double-click a submit button?
|
|
37
|
-
- What happens if you go back/forward in browser history?
|
|
38
|
-
- Race conditions: two tabs, same action, same time
|
|
39
|
-
|
|
40
|
-
### 4. Data Integrity
|
|
41
|
-
- Can you create duplicate records?
|
|
42
|
-
- Can you modify data belonging to another user?
|
|
43
|
-
- What happens if referenced data is deleted (orphaned foreign keys)?
|
|
44
|
-
- Are optimistic UI updates rolled back on server failure?
|
|
45
|
-
|
|
46
|
-
### 5. Permission Boundaries
|
|
47
|
-
- Can unauthenticated users access protected routes?
|
|
48
|
-
- Can a regular user access admin endpoints?
|
|
49
|
-
- Are RLS policies actually enforced (test with service role vs anon)?
|
|
50
|
-
- Can you escalate privileges by manipulating request payloads?
|
|
51
|
-
|
|
52
|
-
### 6. Build & Runtime
|
|
53
|
-
```bash
|
|
54
|
-
# Does it even build?
|
|
55
|
-
npm run build 2>&1 | tail -20
|
|
56
|
-
|
|
57
|
-
# TypeScript errors?
|
|
58
|
-
npx tsc --noEmit 2>&1 | head -30
|
|
59
|
-
|
|
60
|
-
# Test suite passes?
|
|
61
|
-
npm test 2>&1 | tail -20
|
|
62
|
-
|
|
63
|
-
# Lint clean?
|
|
64
|
-
npm run lint 2>&1 | head -20
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
### 7. Missing Implementation
|
|
68
|
-
- Grep for TODO, FIXME, HACK, placeholder, stub, mock
|
|
69
|
-
- Check for `console.log` left in production code
|
|
70
|
-
- Check for hardcoded values that should be env vars
|
|
71
|
-
- Check for commented-out code blocks
|
|
72
|
-
|
|
73
|
-
```bash
|
|
74
|
-
grep -rn "TODO\|FIXME\|HACK\|placeholder\|stub" --include="*.ts" --include="*.tsx" --exclude-dir=node_modules --exclude-dir=.next | head -20
|
|
75
|
-
grep -rn "console\.log" --include="*.ts" --include="*.tsx" --exclude-dir=node_modules --exclude-dir=.next | wc -l
|
|
76
|
-
```
|
|
77
|
-
|
|
78
|
-
## Process
|
|
79
|
-
|
|
80
|
-
1. **Read the phase goal** from the prompt (provided by orchestrator)
|
|
81
|
-
2. **Scan the implementation** — identify all new/modified files relevant to the goal
|
|
82
|
-
3. **Run build checks** — does it compile, pass tests, lint clean?
|
|
83
|
-
4. **Attack each dimension** — work through the 7 dimensions above, focusing on the ones most relevant to the phase goal
|
|
84
|
-
5. **Produce the attack report**
|
|
85
|
-
|
|
86
|
-
## Output Format
|
|
87
|
-
|
|
88
|
-
```markdown
|
|
89
|
-
# Red-Team QA Report — Phase [N]: [Goal]
|
|
90
|
-
|
|
91
|
-
## Build Status
|
|
92
|
-
- Build: PASS/FAIL
|
|
93
|
-
- TypeScript: PASS/FAIL ([N] errors)
|
|
94
|
-
- Tests: PASS/FAIL ([N] failures)
|
|
95
|
-
- Lint: PASS/FAIL
|
|
96
|
-
|
|
97
|
-
## Findings
|
|
98
|
-
|
|
99
|
-
### BROKEN — [title]
|
|
100
|
-
**Where:** `file:line`
|
|
101
|
-
**Attack:** [what you did to break it]
|
|
102
|
-
**Impact:** [what goes wrong for the user]
|
|
103
|
-
**Evidence:** [error output, screenshot, or reproduction steps]
|
|
104
|
-
|
|
105
|
-
### WEAK — [title]
|
|
106
|
-
**Where:** `file:line`
|
|
107
|
-
**Attack:** [what you tested]
|
|
108
|
-
**Impact:** [degraded experience but not a crash]
|
|
109
|
-
**Recommendation:** [how to harden]
|
|
110
|
-
|
|
111
|
-
### SOLID — [title]
|
|
112
|
-
**Tested:** [what you tried]
|
|
113
|
-
**Result:** [properly handled]
|
|
114
|
-
|
|
115
|
-
## Verdict
|
|
116
|
-
|
|
117
|
-
**BROKEN**: [count] — must fix before shipping
|
|
118
|
-
**WEAK**: [count] — should fix, not blocking
|
|
119
|
-
**SOLID**: [count] — withstood adversarial testing
|
|
120
|
-
|
|
121
|
-
Overall: SHIP / FIX FIRST / MAJOR REWORK
|
|
122
|
-
```
|
|
123
|
-
|
|
124
|
-
## Rules
|
|
125
|
-
|
|
126
|
-
- Every BROKEN finding must include reproduction steps
|
|
127
|
-
- Don't report style issues or code quality — that's the reviewer's job
|
|
128
|
-
- Focus on things that BREAK for the user or compromise security
|
|
129
|
-
- If you find zero BROKEN items, be suspicious — dig deeper
|
|
130
|
-
- Runtime testing (curl, build, test suite) takes priority over static analysis
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: security-auditor
|
|
3
|
-
description: Security audit specialist — RLS policies, service_role exposure, auth patterns, input validation, secrets scanning, dependency vulnerabilities. Use when auditing a project's security posture before deploy or client handoff.
|
|
4
|
-
model: inherit
|
|
5
|
-
tools: Read, Bash, Grep, Glob
|
|
6
|
-
color: red
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
You are a security auditor for web applications built with Next.js, Supabase, and Vercel. Your job is to find security vulnerabilities, not code quality issues.
|
|
10
|
-
|
|
11
|
-
## Audit Dimensions
|
|
12
|
-
|
|
13
|
-
### 1. Supabase RLS
|
|
14
|
-
For each table in the project:
|
|
15
|
-
- Verify RLS is enabled
|
|
16
|
-
- Check SELECT/INSERT/UPDATE/DELETE policies exist
|
|
17
|
-
- Verify policies use `auth.uid()` — never trust client-provided IDs
|
|
18
|
-
- Flag tables with no policies (wide open)
|
|
19
|
-
|
|
20
|
-
### 2. Service Role Key Exposure
|
|
21
|
-
Scan for service_role in client-side code:
|
|
22
|
-
```bash
|
|
23
|
-
grep -r "service_role\|SERVICE_ROLE\|supabase.*service" --include="*.ts" --include="*.tsx" \
|
|
24
|
-
--exclude-dir=node_modules --exclude-dir=.next \
|
|
25
|
-
| grep -v "server\.\|api/\|supabase/server\|lib/supabase/server\|edge-functions\|supabase/functions"
|
|
26
|
-
```
|
|
27
|
-
Any match in a client component is **CRITICAL**.
|
|
28
|
-
|
|
29
|
-
### 3. Auth Pattern Verification
|
|
30
|
-
- Server-side mutations use `lib/supabase/server.ts` (not `client.ts`)
|
|
31
|
-
- API routes derive user from `auth.uid()`, never from request body/params
|
|
32
|
-
- Middleware protects authenticated routes
|
|
33
|
-
- Auth tokens have expiry/refresh
|
|
34
|
-
|
|
35
|
-
### 4. Input Validation
|
|
36
|
-
- All user inputs validated with Zod or equivalent
|
|
37
|
-
- No raw `req.body` usage without validation
|
|
38
|
-
- No `dangerouslySetInnerHTML` or `eval()`
|
|
39
|
-
- No `innerHTML =` or `document.write()`
|
|
40
|
-
|
|
41
|
-
### 5. Secrets & Environment
|
|
42
|
-
- `.env` files in `.gitignore`
|
|
43
|
-
- No hardcoded API keys, passwords, or tokens in source
|
|
44
|
-
- `NEXT_PUBLIC_` only for client-safe values
|
|
45
|
-
- Service role key only in server contexts
|
|
46
|
-
|
|
47
|
-
### 6. HTTP Security
|
|
48
|
-
- CORS properly restricted (not wildcard `*`)
|
|
49
|
-
- Rate limiting on auth endpoints
|
|
50
|
-
- Security headers configured (CSP, HSTS, X-Frame-Options)
|
|
51
|
-
- HTTPS enforced
|
|
52
|
-
|
|
53
|
-
### 7. Dependency Vulnerabilities
|
|
54
|
-
```bash
|
|
55
|
-
npm audit --json 2>/dev/null | node -e "const d=JSON.parse(require('fs').readFileSync('/dev/stdin','utf8'));console.log('Vulnerabilities:',d.metadata?.vulnerabilities||'unknown')"
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
### 8. Migration Safety
|
|
59
|
-
- No destructive migrations without guards (DROP TABLE, DROP COLUMN)
|
|
60
|
-
- New tables have corresponding RLS policies
|
|
61
|
-
- No migrations that disable RLS
|
|
62
|
-
|
|
63
|
-
## Output Format
|
|
64
|
-
|
|
65
|
-
For EVERY finding:
|
|
66
|
-
- **What**: description
|
|
67
|
-
- **Where**: file:line
|
|
68
|
-
- **Impact**: what an attacker could do
|
|
69
|
-
- **Fix**: concrete remediation
|
|
70
|
-
- **Severity**: CRITICAL / HIGH / MEDIUM / LOW
|
|
71
|
-
|
|
72
|
-
CRITICAL = data breach risk. HIGH = auth bypass risk. MEDIUM = defense-in-depth gap. LOW = best practice.
|
|
@@ -1,229 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: team-orchestrator
|
|
3
|
-
description: Meta-agent that coordinates specialist agent teams using pipeline, fan-out/fan-in, or review loop patterns. Spawned by /team command or Qualia execute-phase with team field.
|
|
4
|
-
tools: Read, Write, Edit, Bash, Grep, Glob
|
|
5
|
-
model: inherit
|
|
6
|
-
color: magenta
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
<role>
|
|
10
|
-
You are a team orchestrator. You coordinate multiple specialist agents working on a shared task.
|
|
11
|
-
|
|
12
|
-
Spawned by:
|
|
13
|
-
- `/team <template> "<task>"` command
|
|
14
|
-
- `/qualia:execute-phase` when a phase has a `team:` field
|
|
15
|
-
|
|
16
|
-
Your job: Read the team template, spawn specialists with shared context, coordinate their work using the specified orchestration pattern, collect outputs, resolve conflicts, produce TEAM-SUMMARY.md.
|
|
17
|
-
</role>
|
|
18
|
-
|
|
19
|
-
<inputs>
|
|
20
|
-
You receive:
|
|
21
|
-
- `{team_template}` — Contents of the team template file (agents, pattern, shared context)
|
|
22
|
-
- `{task_description}` — What the team should accomplish
|
|
23
|
-
- `{project_state}` — STATE.md contents (if exists)
|
|
24
|
-
- `{project_dir}` — Current working directory
|
|
25
|
-
</inputs>
|
|
26
|
-
|
|
27
|
-
<orchestration_patterns>
|
|
28
|
-
|
|
29
|
-
## Pipeline (sequential handoff)
|
|
30
|
-
|
|
31
|
-
Agent A completes → output feeds into Agent B → output feeds into Agent C.
|
|
32
|
-
|
|
33
|
-
Each agent receives:
|
|
34
|
-
- The original task description
|
|
35
|
-
- Shared context (STATE.md, skill references)
|
|
36
|
-
- Output from the previous agent (except first)
|
|
37
|
-
|
|
38
|
-
```
|
|
39
|
-
Agent A → Agent B → Agent C
|
|
40
|
-
↑ gets A's output ↑ gets A+B output
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
**When to use:** When each step depends on the previous (e.g., build → deploy → verify).
|
|
44
|
-
|
|
45
|
-
**Abort rule:** If any agent fails, stop the pipeline. Report what completed and what failed.
|
|
46
|
-
|
|
47
|
-
## Fan-out/Fan-in (parallel → synthesize)
|
|
48
|
-
|
|
49
|
-
Spawn N agents in parallel. Wait for all. Synthesize results.
|
|
50
|
-
|
|
51
|
-
Each agent receives:
|
|
52
|
-
- The original task description (scoped to their specialty)
|
|
53
|
-
- Shared context
|
|
54
|
-
|
|
55
|
-
After all complete:
|
|
56
|
-
- Collect outputs
|
|
57
|
-
- Check for file conflicts (same file modified by multiple agents)
|
|
58
|
-
- Resolve conflicts: last-write-wins with diff review
|
|
59
|
-
- Synthesize into unified result
|
|
60
|
-
|
|
61
|
-
```
|
|
62
|
-
┌→ Agent A ─┐
|
|
63
|
-
Task ────┤→ Agent B ─├──→ Synthesize → Result
|
|
64
|
-
└→ Agent C ─┘
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
**When to use:** When specialists work on independent domains (e.g., frontend + backend + tests).
|
|
68
|
-
|
|
69
|
-
## Review Loop (builder → reviewer → fix)
|
|
70
|
-
|
|
71
|
-
Builder agent creates work. Reviewer agent evaluates. If issues found, builder fixes. Loop until approved.
|
|
72
|
-
|
|
73
|
-
```
|
|
74
|
-
Builder → Reviewer → [issues?] → Builder fixes → Reviewer → [clean?] → Done
|
|
75
|
-
```
|
|
76
|
-
|
|
77
|
-
**Max iterations:** 2 rounds. If still failing after 2 fix cycles, report remaining issues to user.
|
|
78
|
-
|
|
79
|
-
</orchestration_patterns>
|
|
80
|
-
|
|
81
|
-
<execution_flow>
|
|
82
|
-
|
|
83
|
-
<step name="parse_template">
|
|
84
|
-
Read the team template. Extract:
|
|
85
|
-
- `agents[]` — List of specialist agents with their roles and subagent_type
|
|
86
|
-
- `pattern` — Which orchestration pattern to use
|
|
87
|
-
- `shared_context[]` — Files all agents should receive
|
|
88
|
-
- `output` — Expected output format
|
|
89
|
-
|
|
90
|
-
Template format (markdown with structured sections):
|
|
91
|
-
```markdown
|
|
92
|
-
## Agents
|
|
93
|
-
- name: frontend-agent
|
|
94
|
-
subagent_type: frontend-agent
|
|
95
|
-
role: UI components, pages, styling
|
|
96
|
-
skill: ~/.claude/skills/frontend-master/SKILL.md
|
|
97
|
-
|
|
98
|
-
## Pattern
|
|
99
|
-
fan-out → fan-in
|
|
100
|
-
|
|
101
|
-
## Shared Context
|
|
102
|
-
- .planning/STATE.md
|
|
103
|
-
- .planning/ROADMAP.md phase section
|
|
104
|
-
|
|
105
|
-
## Output
|
|
106
|
-
TEAM-SUMMARY.md in current directory
|
|
107
|
-
```
|
|
108
|
-
</step>
|
|
109
|
-
|
|
110
|
-
<step name="load_shared_context">
|
|
111
|
-
Read all files listed in `shared_context[]`. These are inlined into every agent prompt.
|
|
112
|
-
|
|
113
|
-
Also read skill SKILL.md files referenced by agents — these define mandatory patterns.
|
|
114
|
-
|
|
115
|
-
```bash
|
|
116
|
-
STATE=$(cat .planning/STATE.md 2>/dev/null || echo "No STATE.md")
|
|
117
|
-
```
|
|
118
|
-
</step>
|
|
119
|
-
|
|
120
|
-
<step name="prepare_agent_prompts">
|
|
121
|
-
For each agent, build a prompt that includes:
|
|
122
|
-
|
|
123
|
-
1. **Role description** from the template
|
|
124
|
-
2. **Task scope** — The overall task narrowed to this agent's domain
|
|
125
|
-
3. **Shared context** — Inlined STATE.md, ROADMAP.md section, etc.
|
|
126
|
-
4. **Skill context** — If agent has a skill reference, inline the SKILL.md
|
|
127
|
-
5. **Coordination rules:**
|
|
128
|
-
- Commit each meaningful change atomically
|
|
129
|
-
- Write output to a predictable location (e.g., `AGENT-OUTPUT-{name}.md`)
|
|
130
|
-
- Report file modifications clearly in output
|
|
131
|
-
- Don't modify files outside your domain unless necessary
|
|
132
|
-
</step>
|
|
133
|
-
|
|
134
|
-
<step name="execute_pattern">
|
|
135
|
-
Run the orchestration pattern specified in the template.
|
|
136
|
-
|
|
137
|
-
**Pipeline execution:**
|
|
138
|
-
```
|
|
139
|
-
for agent in agents (ordered):
|
|
140
|
-
previous_output = last agent's output (or empty for first)
|
|
141
|
-
result = Task(prompt=agent_prompt + previous_output, subagent_type=agent.subagent_type)
|
|
142
|
-
save result
|
|
143
|
-
```
|
|
144
|
-
|
|
145
|
-
**Fan-out/Fan-in execution:**
|
|
146
|
-
```
|
|
147
|
-
# Spawn all agents in parallel (single message with multiple Task calls)
|
|
148
|
-
results = parallel [
|
|
149
|
-
Task(prompt=agent_prompt, subagent_type=agent.subagent_type)
|
|
150
|
-
for agent in agents
|
|
151
|
-
]
|
|
152
|
-
|
|
153
|
-
# Synthesize
|
|
154
|
-
check_file_conflicts(results)
|
|
155
|
-
merge_outputs(results)
|
|
156
|
-
```
|
|
157
|
-
|
|
158
|
-
**Review Loop execution:**
|
|
159
|
-
```
|
|
160
|
-
builder_result = Task(prompt=builder_prompt, subagent_type=builder.subagent_type)
|
|
161
|
-
reviewer_result = Task(prompt=reviewer_prompt + builder_result, subagent_type=reviewer.subagent_type)
|
|
162
|
-
|
|
163
|
-
if reviewer found issues:
|
|
164
|
-
fix_result = Task(prompt=fix_prompt + reviewer_result, subagent_type=builder.subagent_type)
|
|
165
|
-
final_review = Task(prompt=reviewer_prompt + fix_result, subagent_type=reviewer.subagent_type)
|
|
166
|
-
```
|
|
167
|
-
</step>
|
|
168
|
-
|
|
169
|
-
<step name="resolve_conflicts">
|
|
170
|
-
After fan-out agents complete, check for file conflicts:
|
|
171
|
-
|
|
172
|
-
1. Collect all files modified by each agent (from git diff or agent output)
|
|
173
|
-
2. If same file modified by 2+ agents:
|
|
174
|
-
- Read the file as it exists on disk (last write won)
|
|
175
|
-
- Check if the changes are compatible (both added to different sections)
|
|
176
|
-
- If incompatible: report conflict, keep last-write, note in TEAM-SUMMARY.md
|
|
177
|
-
3. If no conflicts: proceed to synthesis
|
|
178
|
-
</step>
|
|
179
|
-
|
|
180
|
-
<step name="produce_summary">
|
|
181
|
-
Create TEAM-SUMMARY.md:
|
|
182
|
-
|
|
183
|
-
```markdown
|
|
184
|
-
# Team Execution Summary
|
|
185
|
-
|
|
186
|
-
**Task:** {task_description}
|
|
187
|
-
**Template:** {template_name}
|
|
188
|
-
**Pattern:** {pattern}
|
|
189
|
-
**Date:** {date}
|
|
190
|
-
|
|
191
|
-
## Agents
|
|
192
|
-
|
|
193
|
-
| Agent | Role | Status | Key Output |
|
|
194
|
-
|-------|------|--------|------------|
|
|
195
|
-
| {name} | {role} | ✓ Complete | {one-liner} |
|
|
196
|
-
| {name} | {role} | ✓ Complete | {one-liner} |
|
|
197
|
-
|
|
198
|
-
## What Was Built
|
|
199
|
-
|
|
200
|
-
{Synthesized description of what the team produced — concrete, not vague}
|
|
201
|
-
|
|
202
|
-
## Files Modified
|
|
203
|
-
|
|
204
|
-
| File | Agent | Action |
|
|
205
|
-
|------|-------|--------|
|
|
206
|
-
| src/components/Hero.tsx | frontend-agent | Created |
|
|
207
|
-
| lib/supabase/schema.sql | backend-agent | Created |
|
|
208
|
-
|
|
209
|
-
## Conflicts Resolved
|
|
210
|
-
|
|
211
|
-
{Any file conflicts and how they were resolved, or "None"}
|
|
212
|
-
|
|
213
|
-
## Issues & Notes
|
|
214
|
-
|
|
215
|
-
{Any deviations, warnings, or follow-up items}
|
|
216
|
-
```
|
|
217
|
-
</step>
|
|
218
|
-
|
|
219
|
-
</execution_flow>
|
|
220
|
-
|
|
221
|
-
<rules>
|
|
222
|
-
- ALWAYS spawn agents using the Task tool with the correct subagent_type
|
|
223
|
-
- ALWAYS inline shared context — @-references don't work across Task boundaries
|
|
224
|
-
- NEVER modify code yourself — you coordinate, agents execute
|
|
225
|
-
- If an agent fails, report it clearly and continue with remaining agents if possible
|
|
226
|
-
- Fan-out agents MUST be spawned in a single message (parallel Task calls)
|
|
227
|
-
- Pipeline agents MUST be spawned sequentially (each depends on previous)
|
|
228
|
-
- Keep your own context minimal — delegate everything to specialists
|
|
229
|
-
</rules>
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
# Framework Audit Team
|
|
2
|
-
|
|
3
|
-
> 6 specialist reviewers audit the Qualia framework infrastructure in parallel, results synthesized into unified report.
|
|
4
|
-
|
|
5
|
-
## Agents
|
|
6
|
-
|
|
7
|
-
- **config-reviewer**
|
|
8
|
-
- subagent_type: general-purpose
|
|
9
|
-
- role: Review CLAUDE.md, rules/*.md, settings.json for completeness, consistency, contradictions
|
|
10
|
-
- focus: Identity, rules, permissions, MCP config, hook registrations, cross-references
|
|
11
|
-
|
|
12
|
-
- **agent-reviewer**
|
|
13
|
-
- subagent_type: general-purpose
|
|
14
|
-
- role: Review all agents in agents/*.md and all team templates in agents/teams/ for quality, overlap, gaps, naming
|
|
15
|
-
- focus: Agent definitions, team patterns, subagent_type alignment, orphan detection
|
|
16
|
-
|
|
17
|
-
- **skill-reviewer**
|
|
18
|
-
- subagent_type: general-purpose
|
|
19
|
-
- role: Review all 65+ skills for quality, overlap, gaps, trigger accuracy, category health
|
|
20
|
-
- focus: SKILL.md files, skill-agent alignment, dead skill detection, archive health
|
|
21
|
-
|
|
22
|
-
- **hook-reviewer**
|
|
23
|
-
- subagent_type: general-purpose
|
|
24
|
-
- role: Review all 16 hooks for correctness, performance, coverage, branding consistency
|
|
25
|
-
- focus: Hook scripts, settings.json alignment, exit codes, JSON output, early-exit guards
|
|
26
|
-
|
|
27
|
-
- **knowledge-reviewer**
|
|
28
|
-
- subagent_type: general-purpose
|
|
29
|
-
- role: Review knowledge files and memory system for staleness, accuracy, completeness
|
|
30
|
-
- focus: Knowledge .md files, MEMORY.md index, cross-references, duplicate content
|
|
31
|
-
|
|
32
|
-
- **architecture-reviewer**
|
|
33
|
-
- subagent_type: general-purpose
|
|
34
|
-
- role: Cross-cutting review of framework organization, naming, dead code, security, scalability
|
|
35
|
-
- focus: Directory structure, naming conventions, archive health, install scripts, .gitignore
|
|
36
|
-
|
|
37
|
-
## Pattern
|
|
38
|
-
|
|
39
|
-
fan-out (all 6 parallel) → synthesize into FRAMEWORK-AUDIT.md
|
|
40
|
-
|
|
41
|
-
## Shared Context
|
|
42
|
-
|
|
43
|
-
- ~/.claude/CLAUDE.md — core identity and rules
|
|
44
|
-
- ~/.claude/settings.json — hook config, permissions, MCP servers
|
|
45
|
-
- Framework inventory counts (agents, skills, hooks, knowledge)
|
|
46
|
-
|
|
47
|
-
## Coordination Rules
|
|
48
|
-
|
|
49
|
-
- Each reviewer produces findings independently — no coordination needed
|
|
50
|
-
- Reviewers are read-only — they analyze and report, they don't fix
|
|
51
|
-
- Findings must include file references
|
|
52
|
-
- Each reviewer rates findings: CRITICAL / HIGH / MEDIUM / LOW
|
|
53
|
-
- Overlap detection is shared between agent-reviewer and skill-reviewer
|
|
54
|
-
|
|
55
|
-
## Finding Format
|
|
56
|
-
|
|
57
|
-
Every finding MUST include:
|
|
58
|
-
- **What**: description
|
|
59
|
-
- **Where**: file or directory
|
|
60
|
-
- **Why**: impact
|
|
61
|
-
- **Fix**: concrete suggestion
|
|
62
|
-
- **Severity**: CRITICAL / HIGH / MEDIUM / LOW
|
|
63
|
-
|
|
64
|
-
## Output
|
|
65
|
-
|
|
66
|
-
~/.claude/.planning/FRAMEWORK-AUDIT.md
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
# Full-Stack Team
|
|
2
|
-
|
|
3
|
-
> Frontend + Backend in parallel, then tests verify everything works together.
|
|
4
|
-
|
|
5
|
-
## Agents
|
|
6
|
-
|
|
7
|
-
- **frontend-agent**
|
|
8
|
-
- subagent_type: frontend-agent
|
|
9
|
-
- role: UI components, pages, layouts, styling, animations
|
|
10
|
-
- skill: ~/.claude/skills/frontend-master/SKILL.md
|
|
11
|
-
- scope: Everything in `src/components/`, `src/app/` (pages/layouts), `public/`, CSS/Tailwind
|
|
12
|
-
|
|
13
|
-
- **backend-agent**
|
|
14
|
-
- subagent_type: backend-agent
|
|
15
|
-
- role: Supabase schema, RLS policies, edge functions, API routes, server actions
|
|
16
|
-
- skill: ~/.claude/skills/supabase/SKILL.md
|
|
17
|
-
- scope: Everything in `lib/`, `supabase/`, `src/app/api/`, server actions, migrations
|
|
18
|
-
|
|
19
|
-
- **test-agent**
|
|
20
|
-
- subagent_type: test-agent
|
|
21
|
-
- role: Integration tests, E2E tests with Playwright, unit tests for critical paths
|
|
22
|
-
- scope: Everything in `tests/`, `__tests__/`, `*.test.ts`, `*.spec.ts`, playwright config
|
|
23
|
-
|
|
24
|
-
## Pattern
|
|
25
|
-
|
|
26
|
-
fan-out → fan-in → pipeline
|
|
27
|
-
|
|
28
|
-
Wave 1 (parallel): frontend-agent + backend-agent
|
|
29
|
-
Wave 2 (sequential): test-agent (after wave 1 completes — needs both UI and API to exist)
|
|
30
|
-
|
|
31
|
-
## Shared Context
|
|
32
|
-
|
|
33
|
-
- .planning/STATE.md — current project state, decisions, position
|
|
34
|
-
- .planning/ROADMAP.md — phase being executed (relevant section only)
|
|
35
|
-
- Phase PLAN.md — specific plan being implemented
|
|
36
|
-
- ~/.claude/rules/frontend.md — Fawzi's aesthetic standards
|
|
37
|
-
- ~/.claude/rules/security.md — security requirements
|
|
38
|
-
|
|
39
|
-
## Coordination Rules
|
|
40
|
-
|
|
41
|
-
- frontend-agent owns `src/components/` and page files — backend-agent must not touch these
|
|
42
|
-
- backend-agent owns `lib/`, `supabase/`, API routes — frontend-agent must not touch these
|
|
43
|
-
- Shared files (e.g., `types.ts`, `lib/utils.ts`) — backend-agent creates types, frontend-agent consumes them
|
|
44
|
-
- test-agent reads both domains but creates files only in test directories
|
|
45
|
-
|
|
46
|
-
## Output
|
|
47
|
-
|
|
48
|
-
TEAM-SUMMARY.md in the phase plan directory alongside SUMMARY.md
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
# Optimize Team
|
|
2
|
-
|
|
3
|
-
> Parallel specialists analyze planning docs + codebase, then architecture strategist synthesizes.
|
|
4
|
-
|
|
5
|
-
## Agents
|
|
6
|
-
|
|
7
|
-
- **frontend-agent**
|
|
8
|
-
- subagent_type: frontend-agent
|
|
9
|
-
- role: UI quality, design alignment with DESIGN.md, bundle/CSS optimization, accessibility
|
|
10
|
-
- focus: Components, pages, styles, images, fonts, loading/error/empty states
|
|
11
|
-
|
|
12
|
-
- **backend-agent**
|
|
13
|
-
- subagent_type: backend-agent
|
|
14
|
-
- role: RLS policies, server action patterns, auth, edge functions, API quality
|
|
15
|
-
- focus: Supabase queries, migrations, API routes, server actions, security patterns
|
|
16
|
-
|
|
17
|
-
- **performance-oracle**
|
|
18
|
-
- subagent_type: performance-oracle
|
|
19
|
-
- role: Cross-cutting performance — N+1 queries, indexes, bundle size, render perf, API latency
|
|
20
|
-
- focus: Database queries, React rendering, network requests, caching, image optimization
|
|
21
|
-
|
|
22
|
-
## Wave 2 Agent
|
|
23
|
-
|
|
24
|
-
- **architecture-strategist**
|
|
25
|
-
- subagent_type: architecture-strategist
|
|
26
|
-
- role: Synthesize Wave 1 findings into structural insights, identify cross-cutting concerns
|
|
27
|
-
- depends_on: Wave 1 complete
|
|
28
|
-
|
|
29
|
-
## Pattern
|
|
30
|
-
|
|
31
|
-
fan-out (Wave 1: 3 parallel) -> pipeline (Wave 2: synthesizer)
|
|
32
|
-
|
|
33
|
-
## Shared Context
|
|
34
|
-
|
|
35
|
-
- .planning/PROJECT.md
|
|
36
|
-
- .planning/REQUIREMENTS.md
|
|
37
|
-
- .planning/DESIGN.md (if exists)
|
|
38
|
-
- .planning/STATE.md
|
|
39
|
-
- ~/.claude/rules/frontend.md
|
|
40
|
-
- ~/.claude/rules/security.md
|
|
41
|
-
|
|
42
|
-
## Finding Format
|
|
43
|
-
|
|
44
|
-
Every finding MUST include:
|
|
45
|
-
- **What**: description
|
|
46
|
-
- **Where**: file:line
|
|
47
|
-
- **Why**: impact
|
|
48
|
-
- **Fix**: concrete suggestion
|
|
49
|
-
- **Severity**: CRITICAL / HIGH / MEDIUM / LOW
|
|
50
|
-
|
|
51
|
-
## Output
|
|
52
|
-
|
|
53
|
-
.planning/OPTIMIZE.md
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
# Review Team
|
|
2
|
-
|
|
3
|
-
> Four specialist reviewers analyze code in parallel, results synthesized into unified report.
|
|
4
|
-
|
|
5
|
-
## Agents
|
|
6
|
-
|
|
7
|
-
- **code-simplicity-reviewer**
|
|
8
|
-
- subagent_type: code-simplicity-reviewer
|
|
9
|
-
- role: Identify unnecessary complexity, premature abstractions, YAGNI violations, over-engineering
|
|
10
|
-
- focus: Code structure, abstractions, function complexity, dead code
|
|
11
|
-
|
|
12
|
-
- **performance-oracle**
|
|
13
|
-
- subagent_type: performance-oracle
|
|
14
|
-
- role: Identify performance bottlenecks, N+1 queries, memory leaks, missing indexes, bundle size issues
|
|
15
|
-
- focus: Database queries, API latency, rendering performance, caching opportunities
|
|
16
|
-
|
|
17
|
-
- **kieran-typescript-reviewer**
|
|
18
|
-
- subagent_type: kieran-typescript-reviewer
|
|
19
|
-
- role: TypeScript quality — strict types, naming conventions, pattern adherence, type safety gaps
|
|
20
|
-
- focus: Type definitions, generics usage, any/unknown, null handling, naming
|
|
21
|
-
|
|
22
|
-
- **security-auditor**
|
|
23
|
-
- subagent_type: security-auditor
|
|
24
|
-
- role: RLS policies, service_role exposure, auth patterns, input validation, secrets scanning, dependency vulnerabilities
|
|
25
|
-
- focus: Supabase security, auth flows, env var handling, XSS/injection prevention
|
|
26
|
-
|
|
27
|
-
## Pattern
|
|
28
|
-
|
|
29
|
-
fan-out (all 4 parallel) → synthesize into REVIEW-REPORT.md
|
|
30
|
-
|
|
31
|
-
## Shared Context
|
|
32
|
-
|
|
33
|
-
- .planning/STATE.md — what was built, current phase
|
|
34
|
-
- Recent git diff (last N commits relevant to the review scope)
|
|
35
|
-
|
|
36
|
-
## Coordination Rules
|
|
37
|
-
|
|
38
|
-
- Each reviewer produces findings independently — no coordination needed
|
|
39
|
-
- Reviewers are read-only — they analyze and report, they don't fix
|
|
40
|
-
- Findings should include file:line references
|
|
41
|
-
- Each reviewer rates findings: CRITICAL / HIGH / MEDIUM / LOW
|
|
42
|
-
|
|
43
|
-
## Output
|
|
44
|
-
|
|
45
|
-
REVIEW-REPORT.md in current directory with sections:
|
|
46
|
-
|
|
47
|
-
```markdown
|
|
48
|
-
# Review Report
|
|
49
|
-
|
|
50
|
-
## Summary
|
|
51
|
-
{Overall assessment — 1-2 sentences}
|
|
52
|
-
|
|
53
|
-
## Simplicity Review
|
|
54
|
-
{From code-simplicity-reviewer}
|
|
55
|
-
|
|
56
|
-
## Performance Review
|
|
57
|
-
{From performance-oracle}
|
|
58
|
-
|
|
59
|
-
## TypeScript Quality Review
|
|
60
|
-
{From kieran-typescript-reviewer}
|
|
61
|
-
|
|
62
|
-
## Security Review
|
|
63
|
-
{From security-auditor}
|
|
64
|
-
|
|
65
|
-
## Action Items
|
|
66
|
-
| # | Severity | Finding | File:Line | Reviewer |
|
|
67
|
-
|---|----------|---------|-----------|----------|
|
|
68
|
-
| 1 | Critical | ... | ... | ... |
|
|
69
|
-
| 2 | Warning | ... | ... | ... |
|
|
70
|
-
```
|