nextjs-claude-code
Advanced tools
| # Lead Engineer — Auto-fix & Build Error Resolution | ||
| > Read when a build or type error occurs. | ||
| ## Diagnostic Process | ||
| **Step 1 — Collect all errors** | ||
| ```bash | ||
| npx tsc --noEmit 2>&1 | head -50 | ||
| ``` | ||
| Collect the full error list before fixing anything. | ||
| **Step 2 — Categorize errors** | ||
| | TypeScript error | Minimal fix | | ||
| |-----------------|-------------| | ||
| | `Property does not exist on type` | Add type annotation or null check | | ||
| | `Cannot find module` | Fix import path or add missing file | | ||
| | `Type 'X' is not assignable to 'Y'` | Fix type annotation or assertion | | ||
| | `Object is possibly 'undefined'` | Add optional chaining (`?.`) or null check | | ||
| | `Argument of type mismatch` | Fix call site or update type signature | | ||
| | `Circular dependency detected` | Reorder imports (minimum change only) | | ||
| **Step 3 — Apply minimal fixes in order of impact** | ||
| Budget tracking: | ||
| ``` | ||
| Attempt 1/3: Analyze all errors -> targeted fix for root cause | ||
| Attempt 2/3: Different approach for remaining errors | ||
| Attempt 3/3: Last minimal change | ||
| Exceeded: STOP. Report to user: | ||
| [Escalation] Cannot resolve error after 3 attempts. | ||
| Error: [exact error message] | ||
| Please advise on how to proceed. | ||
| ``` | ||
| **Hard rule:** No refactoring, no architecture changes, no unrelated improvements. Fix only what prevents the build from passing. | ||
| Update PLAN.md after each attempt: `Auto-fix Budget: Max retries: 3 / Used: N` | ||
| Update STATE.md with blocker info (e.g., `Auto-fix: 2/3 used`). |
| # Lead Engineer — Completion & Checkpoint Reference | ||
| > Read when a checkpoint is triggered OR when all tasks in PLAN.md are marked [x]. | ||
| ## Checkpoint Protocol | ||
| **`checkpoint:decision`** — implementation direction unclear | ||
| ``` | ||
| [checkpoint:decision] | ||
| Situation: [describe the ambiguity] | ||
| Options: | ||
| A) [option] — [tradeoffs] | ||
| B) [option] — [tradeoffs] | ||
| Which approach should I take? | ||
| ``` | ||
| **`checkpoint:human-verify`** — UI implementation complete | ||
| ``` | ||
| [checkpoint:human-verify] | ||
| UI implementation complete for: [feature/component name] | ||
| Please verify in browser: | ||
| - [ ] [specific thing to check] | ||
| Reply "done" when verified, or describe any issues. | ||
| ``` | ||
| **`checkpoint:auth-gate`** — manual action required | ||
| ``` | ||
| [checkpoint:auth-gate] | ||
| Manual action required: [describe what needs to be done manually] | ||
| This cannot be automated. Please complete the action and reply "done". | ||
| ``` | ||
| ### Checkpoint behavior | ||
| - Checkpoints are **blocking** — waits for user input. | ||
| - `checkpoint:auth-gate` is **never skippable**. | ||
| - Others can be skipped with "skip" — record in CONTEXT.md. | ||
| ## TDD mode integration | ||
| If `spec/TEST_STRATEGY.md` exists with `approach: tdd` AND `spec/feature/[name]/TEST.md` exists: | ||
| - Read TEST.md before starting tasks | ||
| - Write test code FIRST (failing tests), then implement to pass | ||
| ## On completion | ||
| 1. Verify all tasks in PLAN.md are checked `[x]` | ||
| 2. **Post-dev test generation** — if `spec/TEST_STRATEGY.md` has `approach: post-dev`: | ||
| - Spawn `tester` agent: | ||
| ``` | ||
| [HANDOFF] | ||
| TO: tester (sonnet) | ||
| TASK: Generate tests for feature "[feature-name]" (post-dev mode) | ||
| DONE-WHEN: | ||
| - TEST.md created in spec/feature/[feature-name]/ | ||
| - Test files created and passing | ||
| MUST-NOT: | ||
| - Modify implementation code | ||
| READS: | ||
| - spec/feature/[feature-name]/spec.md | ||
| - spec/feature/[feature-name]/PLAN.md | ||
| [/HANDOFF] | ||
| ``` | ||
| 3. **Check testing requirement** from spec.md frontmatter `testing` field: | ||
| - `required` → run tests (unit + E2E per spec/rules/testing.md) | ||
| - `optional` → advisory, skip to verification | ||
| - `none` or missing → skip to verification | ||
| 4. Update STATE.md phase to `verifying` | ||
| 5. Spawn `verifier` agent (read model from PLAN.md `## Model Assignment`): | ||
| ``` | ||
| [HANDOFF] | ||
| TO: verifier ({model from PLAN.md}) | ||
| TASK: Verify feature "[feature-name]" implementation | ||
| DONE-WHEN: | ||
| - Level 1-3 all pass | ||
| - Level 4 checkpoint:human-verify presented | ||
| MUST-NOT: | ||
| - Modify any file | ||
| READS: | ||
| - spec/feature/[feature-name]/PLAN.md | ||
| - spec/feature/[feature-name]/spec.md | ||
| [/HANDOFF] | ||
| ``` | ||
| 6. If verifier fails: apply fix (counts toward auto-fix budget), re-spawn verifier | ||
| 7. After verification passes: move feature to `## Completed` in STATE.md with date | ||
| 8. Write history entry `spec/feature/[name]/history/YYYY-MM-DD-[description].md` | ||
| 9. Reset CONTEXT.md to: `# Context\n\nNo active context.` |
| # Lead Engineer — MSW Mock Generation | ||
| > Read when a task targets `mocks/` files (mock setup or mock handler in PLAN.md). | ||
| ## Mock Setup (one-time, Layer 0) | ||
| Only create if `mocks/` directory does not exist. Generate these files: | ||
| **`mocks/server.ts`**: | ||
| ```typescript | ||
| import { setupServer } from "msw/node"; | ||
| import { handlers } from "./handlers"; | ||
| export const server = setupServer(...handlers); | ||
| ``` | ||
| **`mocks/browser.ts`**: | ||
| ```typescript | ||
| import { setupWorker } from "msw/browser"; | ||
| import { handlers } from "./handlers"; | ||
| export const worker = setupWorker(...handlers); | ||
| ``` | ||
| **`mocks/index.ts`**: | ||
| ```typescript | ||
| export async function initMocks() { | ||
| if (process.env.NEXT_PUBLIC_API_MOCKING !== "enabled") return; | ||
| if (typeof window === "undefined") { | ||
| const { server } = await import("./server"); | ||
| server.listen({ onUnhandledRequest: "bypass" }); | ||
| } else { | ||
| const { worker } = await import("./browser"); | ||
| await worker.start({ onUnhandledRequest: "bypass" }); | ||
| } | ||
| } | ||
| ``` | ||
| **`mocks/handlers/index.ts`**: | ||
| ```typescript | ||
| export const handlers = [ | ||
| // Feature handlers will be spread here | ||
| ]; | ||
| ``` | ||
| After creating, check if `msw` is in `package.json`. If not: `npm install msw --save-dev` | ||
| ## Mock Handlers (per feature, Layer 2.5) | ||
| Read `## API Contracts` from `spec/feature/[name]/spec.md`. For each endpoint: | ||
| **`mocks/fixtures/[feature].ts`** — Type-safe mock data: | ||
| - Success, error, and edge-case fixtures from API Contract response shapes | ||
| - Realistic but deterministic values (no Math.random) | ||
| **`mocks/handlers/[feature].ts`** — MSW request handlers: | ||
| - Import `http` and `HttpResponse` from `msw` | ||
| - One handler per endpoint | ||
| - Default to success; include commented error variants | ||
| Update `mocks/handlers/index.ts` to import and spread new handlers. | ||
| ## Mock toggle in Next.js | ||
| **App Router** — add to `app/layout.tsx` or `app/providers.tsx`: | ||
| ```typescript | ||
| import { initMocks } from "@/mocks"; | ||
| ``` | ||
| **Pages Router** — add to `pages/_app.tsx`: | ||
| ```typescript | ||
| import { initMocks } from "@/mocks"; | ||
| ``` | ||
| Prefer conditional dynamic import for production: | ||
| ```typescript | ||
| if (process.env.NEXT_PUBLIC_API_MOCKING === "enabled") { | ||
| require("@/mocks").initMocks(); | ||
| } | ||
| ``` |
| # Lead Engineer — Team Mode Reference | ||
| > Read when PLAN.md contains `## Team Composition`. | ||
| ## Team Leader Mode | ||
| > **Experimental:** Team mode requires `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1`. If team creation fails, log "Team creation failed. Falling back to solo mode." and switch to Solo Mode. | ||
| When `## Team Composition` is present in PLAN.md, you are the **team leader** using Claude Code Agent Teams. | ||
| ### Step 1 — Create the agent team | ||
| Create a Claude Code agent team. You are the leader. | ||
| ### Step 2 — Spawn teammates | ||
| For each engineer listed in `## Team Composition` under `Engineers:`: | ||
| **db-engineer** (if listed): | ||
| ``` | ||
| Create a teammate named "db-engineer". | ||
| You are the db-engineer for feature "[feature-name]". | ||
| Read your full instructions from .claude/agents/db-engineer.md. | ||
| Your tasks in spec/feature/[feature-name]/PLAN.md are tagged [db]. | ||
| Implement tasks: [task numbers from Team Composition]. | ||
| Rules: | ||
| - Only work on [db]-tagged tasks | ||
| - Message me before attempting any auto-fix (I manage the budget) | ||
| - Message me when all tasks are complete or if you are blocked | ||
| - My decisions take priority | ||
| ``` | ||
| **ui-engineer** (if listed): | ||
| ``` | ||
| Create a teammate named "ui-engineer". | ||
| You are the ui-engineer for feature "[feature-name]". | ||
| Read your full instructions from .claude/agents/ui-engineer.md. | ||
| Your tasks in spec/feature/[feature-name]/PLAN.md are tagged [ui]. | ||
| Implement tasks: [task numbers from Team Composition]. | ||
| Rules: | ||
| - Only work on [ui]-tagged tasks | ||
| - Message me before attempting any auto-fix (I manage the budget) | ||
| - Message me when all tasks are complete or if you are blocked | ||
| - My decisions take priority | ||
| ``` | ||
| **worker-engineer** — always spawn as **subagent** (not a teammate): | ||
| - Use the Agent tool with model: haiku, same as solo mode | ||
| ### Step 3 — Work on your own tasks | ||
| While teammates work: | ||
| 1. Implement `[lead]` tasks yourself, following solo execution protocol | ||
| 2. Delegate `[worker]` tasks to worker-engineer subagents | ||
| 3. Respect Task Dependencies from PLAN.md | ||
| ### Step 4 — Coordinate | ||
| - **Monitor teammates**: Check shared task list for completion | ||
| - **Handle auto-fix requests**: Check budget in PLAN.md (`Used: N`), approve if < 3, increment | ||
| - **Resolve conflicts**: Your decision is final | ||
| - **No broadcast**: Point-to-point messages only | ||
| - **Worker failures**: Implement the task yourself | ||
| ### Step 5 — All tasks complete | ||
| After all teammates report completion and all tasks are `[x]`: | ||
| 1. Shut down teammates gracefully | ||
| 2. Proceed to standard completion flow |
| # Loop — Completion Reference | ||
| > Read when all REQs pass (step 7) or max iterations reached (step 8). | ||
| ## On success (all REQs pass) | ||
| After all REQs pass, run verification (Level 1-3) before declaring completion: | ||
| - Spawn `verifier` agent: | ||
| ``` | ||
| [HANDOFF] | ||
| TO: verifier (haiku) | ||
| TASK: Verify feature "[name]" post-loop implementation | ||
| DONE-WHEN: | ||
| - Level 1-3 all pass | ||
| MUST-NOT: | ||
| - Modify any file | ||
| READS: | ||
| - spec/feature/[name]/PLAN.md | ||
| - spec/feature/[name]/spec.md | ||
| [/HANDOFF] | ||
| ``` | ||
| - If verifier fails and auto-fix budget is still available for this iteration: apply fix and re-verify | ||
| - If verifier fails and auto-fix budget is exhausted: exit with partial success — report: `All REQs passed review but verification failed with budget exhausted. Failing verification: [details]. Manual fix needed.` Update STATE.md to `idle` with failing verification info. | ||
| - Level 4 (human-verify) is optional in `/loop` — ask user: "All REQs pass and Level 1-3 verified. Would you like to do a browser check (Level 4)?" (Level 4 is mandatory in `/dev` flow but optional in `/loop` since the user has already seen the feature iterating.) | ||
| ``` | ||
| [Loop Complete — All REQs Satisfied] | ||
| Feature: [name] | ||
| Iterations: N/5 | ||
| Verification: Level 1-3 passed | ||
| Final status: | ||
| REQ-001: PASS | ||
| REQ-002: PASS | ||
| REQ-003: PASS | ||
| All requirements in spec.md are implemented and verified. | ||
| ``` | ||
| - Update `spec/STATE.md`: | ||
| - Move feature from `## Features` to `## Completed` with date | ||
| - Write history entry to `spec/feature/[name]/history/YYYY-MM-DD-loop-complete.md` | ||
| - Delete `spec/feature/[name]/LOOP_NOTES.md` (no longer needed) | ||
| ## On max iterations reached (some REQs still failing) | ||
| ``` | ||
| [Loop Exhausted — Max Iterations Reached] | ||
| Feature: [name] | ||
| Iterations: 5/5 | ||
| Passing: X/Y REQs | ||
| Still failing: | ||
| REQ-002: [reason from last review] | ||
| REQ-005: [reason from last review] | ||
| Previous attempts summary: | ||
| [condensed history from LOOP_NOTES.md] | ||
| These requirements could not be automatically resolved. | ||
| Manual intervention required. | ||
| ``` | ||
| - Update `spec/STATE.md`: | ||
| - Change the feature's phase: `### [feature-name] [idle]` | ||
| - Add failing REQs info under the feature entry | ||
| - Keep `spec/feature/[name]/LOOP_NOTES.md` intact — it contains valuable failure context for manual debugging | ||
| - Do NOT write a completion history entry (feature is not complete) |
| # Planner — Team Mode Reference | ||
| > Read when the handoff from /dev includes MODE: team. | ||
| ## Team Composition (only when MODE: team) | ||
| If the handoff from `/dev` includes `MODE: team`: | ||
| Determine which engineers are needed: | ||
| ``` | ||
| - [db] tasks exist → include db-engineer | ||
| - [ui] tasks ≥ 2 → include ui-engineer | ||
| - [ui] tasks = 1 → lead handles it directly (no ui-engineer) | ||
| - [worker] tasks → NOT included in Team Composition (always subagent) | ||
| - lead-engineer → always included | ||
| ``` | ||
| Add `## Team Composition` section to PLAN.md: | ||
| ```markdown | ||
| ## Team Composition | ||
| Mode: team | ||
| Engineers: | ||
| - lead-engineer (sonnet) — tasks: [numbers] | ||
| - db-engineer (sonnet) — tasks: [numbers] | ||
| - ui-engineer (sonnet) — tasks: [numbers] | ||
| Workers (subagent): | ||
| - worker-engineer (haiku) — tasks: [numbers] | ||
| Task Dependencies: | ||
| - Task N [tag] → Task M [tag] | ||
| ``` | ||
| If MODE is not `team` (solo mode): | ||
| - Still tag tasks with `[worker]` where applicable (lead will spawn worker subagents) | ||
| - Do NOT add `## Team Composition` section | ||
| - Other domain tags (`[lead]`, `[db]`, `[ui]`) are optional in solo mode but can be included for clarity |
| --- | ||
| title: Split Combined Hook Computations | ||
| impact: MEDIUM | ||
| impactDescription: avoids recomputing independent steps | ||
| tags: rerender, useMemo, useEffect, dependencies, optimization | ||
| --- | ||
| ## Split Combined Hook Computations | ||
| When a hook contains multiple independent tasks with different dependencies, split them into separate hooks. A combined hook reruns all tasks when any dependency changes, even if some tasks don't use the changed value. | ||
| **Incorrect (changing `sortOrder` recomputes filtering):** | ||
| ```tsx | ||
| const sortedProducts = useMemo(() => { | ||
| const filtered = products.filter((p) => p.category === category) | ||
| const sorted = filtered.toSorted((a, b) => | ||
| sortOrder === "asc" ? a.price - b.price : b.price - a.price | ||
| ) | ||
| return sorted | ||
| }, [products, category, sortOrder]) | ||
| ``` | ||
| **Correct (filtering only recomputes when products or category change):** | ||
| ```tsx | ||
| const filteredProducts = useMemo( | ||
| () => products.filter((p) => p.category === category), | ||
| [products, category] | ||
| ) | ||
| const sortedProducts = useMemo( | ||
| () => | ||
| filteredProducts.toSorted((a, b) => | ||
| sortOrder === "asc" ? a.price - b.price : b.price - a.price | ||
| ), | ||
| [filteredProducts, sortOrder] | ||
| ) | ||
| ``` | ||
| This pattern also applies to `useEffect` when combining unrelated side effects: | ||
| **Incorrect (both effects run when either dependency changes):** | ||
| ```tsx | ||
| useEffect(() => { | ||
| analytics.trackPageView(pathname) | ||
| document.title = `${pageTitle} | My App` | ||
| }, [pathname, pageTitle]) | ||
| ``` | ||
| **Correct (effects run independently):** | ||
| ```tsx | ||
| useEffect(() => { | ||
| analytics.trackPageView(pathname) | ||
| }, [pathname]) | ||
| useEffect(() => { | ||
| document.title = `${pageTitle} | My App` | ||
| }, [pageTitle]) | ||
| ``` | ||
| **Note:** If your project has [React Compiler](https://react.dev/learn/react-compiler) enabled, it automatically optimizes dependency tracking and may handle some of these cases for you. |
| --- | ||
| title: Use useDeferredValue for Expensive Derived Renders | ||
| impact: MEDIUM | ||
| impactDescription: keeps input responsive during heavy computation | ||
| tags: rerender, useDeferredValue, optimization, concurrent | ||
| --- | ||
| ## Use useDeferredValue for Expensive Derived Renders | ||
| When user input triggers expensive computations or renders, use `useDeferredValue` to keep the input responsive. The deferred value lags behind, allowing React to prioritize the input update and render the expensive result when idle. | ||
| **Incorrect (input feels laggy while filtering):** | ||
| ```tsx | ||
| function Search({ items }: { items: Item[] }) { | ||
| const [query, setQuery] = useState('') | ||
| const filtered = items.filter(item => fuzzyMatch(item, query)) | ||
| return ( | ||
| <> | ||
| <input value={query} onChange={e => setQuery(e.target.value)} /> | ||
| <ResultsList results={filtered} /> | ||
| </> | ||
| ) | ||
| } | ||
| ``` | ||
| **Correct (input stays snappy, results render when ready):** | ||
| ```tsx | ||
| function Search({ items }: { items: Item[] }) { | ||
| const [query, setQuery] = useState('') | ||
| const deferredQuery = useDeferredValue(query) | ||
| const filtered = useMemo( | ||
| () => items.filter(item => fuzzyMatch(item, deferredQuery)), | ||
| [items, deferredQuery] | ||
| ) | ||
| const isStale = query !== deferredQuery | ||
| return ( | ||
| <> | ||
| <input value={query} onChange={e => setQuery(e.target.value)} /> | ||
| <div style={{ opacity: isStale ? 0.7 : 1 }}> | ||
| <ResultsList results={filtered} /> | ||
| </div> | ||
| </> | ||
| ) | ||
| } | ||
| ``` | ||
| **When to use:** | ||
| - Filtering/searching large lists | ||
| - Expensive visualizations (charts, graphs) reacting to input | ||
| - Any derived state that causes noticeable render delays | ||
| **Note:** Wrap the expensive computation in `useMemo` with the deferred value as a dependency, otherwise it still runs on every render. | ||
| Reference: [React useDeferredValue](https://react.dev/reference/react/useDeferredValue) |
| --- | ||
| name: changelog-maintenance | ||
| description: Maintain a clear and informative changelog for software releases. Use when documenting version changes, tracking features, or communicating updates to users. Handles semantic versioning, changelog formats, and release notes. | ||
| metadata: | ||
| tags: changelog, release-notes, versioning, semantic-versioning, documentation | ||
| platforms: Claude, ChatGPT, Gemini | ||
| --- | ||
| # Changelog Maintenance | ||
| ## When to use this skill | ||
| - **Before release**: organize changes before shipping a version | ||
| - **Continuous**: update whenever significant changes occur | ||
| - **Migration guide**: document breaking changes | ||
| ## Instructions | ||
| ### Step 1: Keep a Changelog format | ||
| **CHANGELOG.md**: | ||
| ```markdown | ||
| # Changelog | ||
| All notable changes to this project will be documented in this file. | ||
| The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), | ||
| and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
| ## [Unreleased] | ||
| ### Added | ||
| - New user profile customization options | ||
| - Dark mode support | ||
| ### Changed | ||
| - Improved performance of search feature | ||
| ### Fixed | ||
| - Bug in password reset email | ||
| ## [1.2.0] - 2025-01-15 | ||
| ### Added | ||
| - Two-factor authentication (2FA) | ||
| - Export user data feature (GDPR compliance) | ||
| - API rate limiting | ||
| - Webhook support for order events | ||
| ### Changed | ||
| - Updated UI design for dashboard | ||
| - Improved email templates | ||
| - Database query optimization (40% faster) | ||
| ### Deprecated | ||
| - `GET /api/v1/users/list` (use `GET /api/v2/users` instead) | ||
| ### Removed | ||
| - Legacy authentication method (Basic Auth) | ||
| ### Fixed | ||
| - Memory leak in background job processor | ||
| - CORS issue with Safari browser | ||
| - Timezone bug in date picker | ||
| ### Security | ||
| - Updated dependencies (fixes CVE-2024-12345) | ||
| - Implemented CSRF protection | ||
| - Added helmet.js security headers | ||
| ## [1.1.2] - 2025-01-08 | ||
| ### Fixed | ||
| - Critical bug in payment processing | ||
| - Session timeout issue | ||
| ## [1.1.0] - 2024-12-20 | ||
| ### Added | ||
| - User profile pictures | ||
| - Email notifications | ||
| - Search functionality | ||
| ### Changed | ||
| - Redesigned login page | ||
| - Improved mobile responsiveness | ||
| ## [1.0.0] - 2024-12-01 | ||
| Initial release | ||
| ### Added | ||
| - User registration and authentication | ||
| - Basic profile management | ||
| - Product catalog | ||
| - Shopping cart | ||
| - Order management | ||
| [Unreleased]: https://github.com/username/repo/compare/v1.2.0...HEAD | ||
| [1.2.0]: https://github.com/username/repo/compare/v1.1.2...v1.2.0 | ||
| [1.1.2]: https://github.com/username/repo/compare/v1.1.0...v1.1.2 | ||
| [1.1.0]: https://github.com/username/repo/compare/v1.0.0...v1.1.0 | ||
| [1.0.0]: https://github.com/username/repo/releases/tag/v1.0.0 | ||
| ``` | ||
| ### Step 2: Semantic Versioning | ||
| **Version number**: `MAJOR.MINOR.PATCH` | ||
| ``` | ||
| Given a version number MAJOR.MINOR.PATCH, increment: | ||
| MAJOR (1.0.0 → 2.0.0): Breaking changes | ||
| - API changes break existing code | ||
| - Example: adding required parameters, changing response structure | ||
| MINOR (1.1.0 → 1.2.0): Backward-compatible features | ||
| - Add new features | ||
| - Existing functionality continues to work | ||
| - Example: new API endpoints, optional parameters | ||
| PATCH (1.1.1 → 1.1.2): Backward-compatible bug fixes | ||
| - Bug fixes | ||
| - Security patches | ||
| - Example: fixing memory leaks, fixing typos | ||
| ``` | ||
| **Examples**: | ||
| - `1.0.0` → `1.0.1`: bug fix | ||
| - `1.0.1` → `1.1.0`: new feature | ||
| - `1.1.0` → `2.0.0`: Breaking change | ||
| ### Step 3: Release Notes (user-friendly) | ||
| ```markdown | ||
| # Release Notes v1.2.0 | ||
| **Released**: January 15, 2025 | ||
| ## 🎉 What's New | ||
| ### Two-Factor Authentication | ||
| You can now enable 2FA for enhanced security. Go to Settings > Security to set it up. | ||
|  | ||
| ### Export Your Data | ||
| We've added the ability to export all your data in JSON format. Perfect for backing up or migrating your account. | ||
| ## ✨ Improvements | ||
| - **Faster Search**: Search is now 40% faster thanks to database optimizations | ||
| - **Better Emails**: Redesigned email templates for a cleaner look | ||
| - **Dashboard Refresh**: Updated UI with modern design | ||
| ## 🐛 Bug Fixes | ||
| - Fixed a bug where password reset emails weren't being sent | ||
| - Resolved timezone issues in the date picker | ||
| - Fixed memory leak in background jobs | ||
| ## ⚠️ Breaking Changes | ||
| If you're using our API: | ||
| - **Removed**: Basic Authentication is no longer supported | ||
| - **Migration**: Use JWT tokens instead (see [Auth Guide](docs/auth.md)) | ||
| - **Deprecated**: `GET /api/v1/users/list` | ||
| - **Migration**: Use `GET /api/v2/users` with pagination | ||
| ## 🔒 Security | ||
| - Updated all dependencies to latest versions | ||
| - Added CSRF protection to all forms | ||
| - Implemented security headers with helmet.js | ||
| ## 📝 Full Changelog | ||
| See [CHANGELOG.md](CHANGELOG.md) for complete details. | ||
| --- | ||
| **Upgrade Instructions**: [docs/upgrade-to-v1.2.md](docs/upgrade-to-v1.2.md) | ||
| ``` | ||
| ### Step 4: Breaking Changes migration guide | ||
| ```markdown | ||
| # Migration Guide: v1.x to v2.0 | ||
| ## Breaking Changes | ||
| ### 1. Authentication Method Changed | ||
| **Before** (v1.x): | ||
| \`\`\`javascript | ||
| fetch('/api/users', { | ||
| headers: { | ||
| 'Authorization': 'Basic ' + btoa(username + ':' + password) | ||
| } | ||
| }); | ||
| \`\`\` | ||
| **After** (v2.0): | ||
| \`\`\`javascript | ||
| // 1. Get JWT token | ||
| const { accessToken } = await fetch('/api/auth/login', { | ||
| method: 'POST', | ||
| body: JSON.stringify({ email, password }) | ||
| }).then(r => r.json()); | ||
| // 2. Use token | ||
| fetch('/api/users', { | ||
| headers: { | ||
| 'Authorization': 'Bearer ' + accessToken | ||
| } | ||
| }); | ||
| \`\`\` | ||
| ### 2. User List API Response Format | ||
| **Before** (v1.x): | ||
| \`\`\`json | ||
| { | ||
| "users": [...] | ||
| } | ||
| \`\`\` | ||
| **After** (v2.0): | ||
| \`\`\`json | ||
| { | ||
| "data": [...], | ||
| "pagination": { | ||
| "page": 1, | ||
| "limit": 20, | ||
| "total": 100 | ||
| } | ||
| } | ||
| \`\`\` | ||
| **Migration**: | ||
| \`\`\`javascript | ||
| // v1.x | ||
| const users = response.users; | ||
| // v2.0 | ||
| const users = response.data; | ||
| \`\`\` | ||
| ## Deprecation Timeline | ||
| - v2.0 (Jan 2025): Basic Auth marked as deprecated | ||
| - v2.1 (Feb 2025): Warning logs for Basic Auth usage | ||
| - v2.2 (Mar 2025): Basic Auth removed | ||
| ``` | ||
| ## Output format | ||
| ``` | ||
| CHANGELOG.md # Developer-facing detailed log | ||
| RELEASES.md # User-facing release notes | ||
| docs/migration/ | ||
| ├── v1-to-v2.md # Migration guide | ||
| └── v2-to-v3.md | ||
| ``` | ||
| ## Constraints | ||
| ### Required rules (MUST) | ||
| 1. **Reverse chronological**: latest version at the top | ||
| 2. **Include dates**: ISO 8601 format (YYYY-MM-DD) | ||
| 3. **Categorize entries**: Added, Changed, Fixed, etc. | ||
| ### Prohibited items (MUST NOT) | ||
| 1. **No copying Git logs**: write from the user's perspective | ||
| 2. **Vague wording**: "Bug fixes", "Performance improvements" (be specific) | ||
| ## Best practices | ||
| 1. **Keep a Changelog**: follow the standard format | ||
| 2. **Semantic Versioning**: consistent version management | ||
| 3. **Breaking Changes**: provide a migration guide | ||
| ## References | ||
| - [Keep a Changelog](https://keepachangelog.com/) | ||
| - [Semantic Versioning](https://semver.org/) | ||
| ## Metadata | ||
| ### Version | ||
| - **Current version**: 1.0.0 | ||
| - **Last updated**: 2025-01-01 | ||
| - **Compatible platforms**: Claude, ChatGPT, Gemini | ||
| ### Tags | ||
| `#changelog` `#release-notes` `#versioning` `#semantic-versioning` `#documentation` | ||
| ## Examples | ||
| ### Example 1: Basic usage | ||
| <!-- Add example content here --> | ||
| ### Example 2: Advanced usage | ||
| <!-- Add advanced example content here --> |
Sorry, the diff of this file is not supported yet
| --- | ||
| name: find-skills | ||
| description: Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill. | ||
| --- | ||
| # Find Skills | ||
| This skill helps you discover and install skills from the open agent skills ecosystem. | ||
| ## When to Use This Skill | ||
| Use this skill when the user: | ||
| - Asks "how do I do X" where X might be a common task with an existing skill | ||
| - Says "find a skill for X" or "is there a skill for X" | ||
| - Asks "can you do X" where X is a specialized capability | ||
| - Expresses interest in extending agent capabilities | ||
| - Wants to search for tools, templates, or workflows | ||
| - Mentions they wish they had help with a specific domain (design, testing, deployment, etc.) | ||
| ## What is the Skills CLI? | ||
| The Skills CLI (`npx skills`) is the package manager for the open agent skills ecosystem. Skills are modular packages that extend agent capabilities with specialized knowledge, workflows, and tools. | ||
| **Key commands:** | ||
| - `npx skills find [query]` - Search for skills interactively or by keyword | ||
| - `npx skills add <package>` - Install a skill from GitHub or other sources | ||
| - `npx skills check` - Check for skill updates | ||
| - `npx skills update` - Update all installed skills | ||
| **Browse skills at:** https://skills.sh/ | ||
| ## How to Help Users Find Skills | ||
| ### Step 1: Understand What They Need | ||
| When a user asks for help with something, identify: | ||
| 1. The domain (e.g., React, testing, design, deployment) | ||
| 2. The specific task (e.g., writing tests, creating animations, reviewing PRs) | ||
| 3. Whether this is a common enough task that a skill likely exists | ||
| ### Step 2: Check the Leaderboard First | ||
| Before running a CLI search, check the [skills.sh leaderboard](https://skills.sh/) to see if a well-known skill already exists for the domain. The leaderboard ranks skills by total installs, surfacing the most popular and battle-tested options. | ||
| For example, top skills for web development include: | ||
| - `vercel-labs/agent-skills` — React, Next.js, web design (100K+ installs each) | ||
| - `anthropics/skills` — Frontend design, document processing (100K+ installs) | ||
| ### Step 3: Search for Skills | ||
| If the leaderboard doesn't cover the user's need, run the find command: | ||
| ```bash | ||
| npx skills find [query] | ||
| ``` | ||
| For example: | ||
| - User asks "how do I make my React app faster?" → `npx skills find react performance` | ||
| - User asks "can you help me with PR reviews?" → `npx skills find pr review` | ||
| - User asks "I need to create a changelog" → `npx skills find changelog` | ||
| ### Step 4: Verify Quality Before Recommending | ||
| **Do not recommend a skill based solely on search results.** Always verify: | ||
| 1. **Install count** — Prefer skills with 1K+ installs. Be cautious with anything under 100. | ||
| 2. **Source reputation** — Official sources (`vercel-labs`, `anthropics`, `microsoft`) are more trustworthy than unknown authors. | ||
| 3. **GitHub stars** — Check the source repository. A skill from a repo with <100 stars should be treated with skepticism. | ||
| ### Step 5: Present Options to the User | ||
| When you find relevant skills, present them to the user with: | ||
| 1. The skill name and what it does | ||
| 2. The install count and source | ||
| 3. The install command they can run | ||
| 4. A link to learn more at skills.sh | ||
| Example response: | ||
| ``` | ||
| I found a skill that might help! The "react-best-practices" skill provides | ||
| React and Next.js performance optimization guidelines from Vercel Engineering. | ||
| (185K installs) | ||
| To install it: | ||
| npx skills add vercel-labs/agent-skills@react-best-practices | ||
| Learn more: https://skills.sh/vercel-labs/agent-skills/react-best-practices | ||
| ``` | ||
| ### Step 6: Offer to Install | ||
| If the user wants to proceed, you can install the skill for them: | ||
| ```bash | ||
| npx skills add <owner/repo@skill> -g -y | ||
| ``` | ||
| The `-g` flag installs globally (user-level) and `-y` skips confirmation prompts. | ||
| ## Common Skill Categories | ||
| When searching, consider these common categories: | ||
| | Category | Example Queries | | ||
| | --------------- | ---------------------------------------- | | ||
| | Web Development | react, nextjs, typescript, css, tailwind | | ||
| | Testing | testing, jest, playwright, e2e | | ||
| | DevOps | deploy, docker, kubernetes, ci-cd | | ||
| | Documentation | docs, readme, changelog, api-docs | | ||
| | Code Quality | review, lint, refactor, best-practices | | ||
| | Design | ui, ux, design-system, accessibility | | ||
| | Productivity | workflow, automation, git | | ||
| ## Tips for Effective Searches | ||
| 1. **Use specific keywords**: "react testing" is better than just "testing" | ||
| 2. **Try alternative terms**: If "deploy" doesn't work, try "deployment" or "ci-cd" | ||
| 3. **Check popular sources**: Many skills come from `vercel-labs/agent-skills` or `ComposioHQ/awesome-claude-skills` | ||
| ## When No Skills Are Found | ||
| If no relevant skills exist: | ||
| 1. Acknowledge that no existing skill was found | ||
| 2. Offer to help with the task directly using your general capabilities | ||
| 3. Suggest the user could create their own skill with `npx skills init` | ||
| Example: | ||
| ``` | ||
| I searched for skills related to "xyz" but didn't find any matches. | ||
| I can still help you with this task directly! Would you like me to proceed? | ||
| If this is something you do often, you could create your own skill: | ||
| npx skills init my-xyz-skill | ||
| ``` |
| # Agent Role Boundaries | ||
| > **Immutable.** Read when checking which agents can modify which files. | ||
| ## Permission Matrix | ||
| | Agent | Can modify source code | Can modify spec/ docs | Read-only | | ||
| |---|---|---|---| | ||
| | `init` | No | Yes | — | | ||
| | `spec-writer` | No | Yes (spec.md, design.md) | — | | ||
| | `planner` | No | Yes (CONTEXT.md, PLAN.md) | — | | ||
| | `lead-engineer` | **Yes** | Partial (STATE.md, PLAN.md, history) | — | | ||
| | `db-engineer` | **Yes** (DB files only) | Partial (PLAN.md budget via lead) | — | | ||
| | `ui-engineer` | **Yes** (UI files only) | Partial (PLAN.md budget via lead) | — | | ||
| | `worker-engineer` | **Yes** (assigned file only) | No | — | | ||
| | `verifier` | No | No | **Yes** | | ||
| | `reviewer` | No | No | **Yes** | | ||
| | `code-quality-reviewer` | No | No | **Yes** | | ||
| | `status` | No | No | **Yes** | | ||
| | `debugger` | **Yes** | Yes (DEBUG.md, STATE.md) | — | | ||
| | `rule-writer` | No | Yes (spec/rules/) | — | | ||
| | `loop` | **Yes** (via lead-engineer) | Partial (STATE.md, PLAN.md, LOOP_NOTES.md, history) | — | | ||
| - `/review` runs `reviewer` then `code-quality-reviewer` sequentially | ||
| - Read-only agents never modify any file | ||
| ## Responsibility Matrix | ||
| | Domain | Primary Agent | Trigger | | ||
| |--------|--------------|---------| | ||
| | Test execution | `tester` | `/test`, `/review` (if TEST_STRATEGY.md exists) | | ||
| | Test generation | `tester` | post-dev or TDD mode | | ||
| | Security audit | `security-reviewer` | `/security`, `/review` (if SECURITY_STRATEGY.md exists) | | ||
| | Logging audit | `log-auditor` | `/log`, `/review` (if LOG_STRATEGY.md exists) | | ||
| | Code quality | `code-quality-reviewer` | `/review` | | ||
| | Spec compliance | `reviewer` | `/review`, `/loop` | | ||
| ## Team Mode (`/dev --team`) | ||
| | Role | Domain | Spawned when | Model | | ||
| |------|--------|-------------|-------| | ||
| | `lead-engineer` | Types, utils, hooks, API, server actions, page wiring | Always (leader) | sonnet | | ||
| | `db-engineer` | Schema, migrations, queries, RLS, seed data | Feature has `[db]` tasks | sonnet | | ||
| | `ui-engineer` | Components, styling, animations, responsive | Feature has 2+ `[ui]` tasks | sonnet | | ||
| | `worker-engineer` | Simple utilities, type defs, config | Feature has `[worker]` tasks | haiku | | ||
| Coordination: | ||
| - Lead has authority over all other engineers | ||
| - Auto-fix budget is centralized: teammates message lead before fix attempts | ||
| - Worker is always subagent (not a team member) for token optimization | ||
| - Same file must never be assigned to multiple engineers |
| # Delegation Protocol | ||
| > **Immutable.** Read when spawning sub-agents or resuming interrupted sessions. | ||
| ## HANDOFF Format | ||
| When spawning a sub-agent via the Agent tool, use this format: | ||
| ``` | ||
| [HANDOFF] | ||
| TO: agent-name (model) | ||
| TASK: One-line imperative description | ||
| DONE-WHEN: | ||
| - Observable completion criterion 1 | ||
| - Observable completion criterion 2 | ||
| MUST-NOT: | ||
| - Explicit constraint 1 | ||
| - Explicit constraint 2 | ||
| READS: | ||
| - file path the sub-agent must read | ||
| [/HANDOFF] | ||
| ``` | ||
| Rules: | ||
| - DONE-WHEN must be observable (file exists, test passes, build succeeds) — not subjective | ||
| - MUST-NOT applies only to this specific handoff | ||
| - READS lists only essential files the agent doesn't already know to read | ||
| - Keep each handoff under 15 lines total | ||
| - All agent spawns must use this format — free-form prompts are not allowed | ||
| ## Resume Protocol | ||
| If `/dev` is interrupted (session crash, timeout, context limit), running `/dev` again resumes: | ||
| - STATE.md tracks each feature's phase: `idle` -> `planning` -> `executing` -> `verifying` -> `idle` | ||
| - `/dev` reads the feature's phase and routes to the appropriate agent | ||
| - Completed tasks (`- [x]`) in PLAN.md are skipped on resume | ||
| - Auto-fix budget (`Used: N`) persists across sessions | ||
| | Phase | On `/dev` resume | | ||
| |---|---| | ||
| | `idle` | Fresh start -> planner | | ||
| | `planning` | Check PLAN.md -> resume or skip to lead-engineer | | ||
| | `executing` | Skip completed tasks -> continue from first `- [ ]` | | ||
| | `verifying` | Re-run verifier | |
| # Document Format Rules | ||
| > **Immutable.** Read when writing spec.md, design.md, or history entries. | ||
| ## Writing Rules | ||
| Both `spec.md` and `design.md` must follow these rules: | ||
| - Both files must begin with YAML frontmatter (`---`) | ||
| - No inline formatting in document body: `**bold**`, `_italic_`, `` `code` ``, `~~strikethrough~~` are prohibited | ||
| - Requirements use `REQ-NNN: statement` format — no bullet prefix, one declarative statement per line | ||
| - All content must be declarative — no prose, no explanatory sentences | ||
| - Prose is only allowed in `## Purpose`, limited to 1-3 sentences | ||
| ## spec.md | ||
| Frontmatter (required): | ||
| ```yaml | ||
| --- | ||
| feature: [name] | ||
| deps: [feature-name, ...] # features this spec depends on; [] if none | ||
| api: [METHOD /path, ...] # API endpoints; omit if none | ||
| testing: none # none | optional | required | ||
| --- | ||
| ``` | ||
| `testing` field values: | ||
| - `required`: lead-engineer writes tests; verifier Level 2b blocks if missing | ||
| - `optional`: skip test phase; verifier Level 2b warns but does not block | ||
| - `none`: no test expectations | ||
| - Default if omitted: `none` | ||
| `max-iterations` field (optional): | ||
| - Controls `/loop` max iteration count. Default: 5 if omitted. | ||
| Sections (required): | ||
| ``` | ||
| ## Purpose | ||
| ## Requirements | ||
| ## Behaviors | ||
| ## Out of Scope | ||
| ``` | ||
| ## design.md | ||
| Frontmatter (required): | ||
| ```yaml | ||
| --- | ||
| feature: [name] | ||
| figma: "url or empty string" # "" if UI but no Figma; "N/A" if backend | ||
| --- | ||
| ``` | ||
| Sections (required): | ||
| ``` | ||
| ## Components | ||
| ## State | ||
| ## Data Flow | ||
| ## Technical Decisions | ||
| ``` | ||
| - All sections are required; write `N/A` if not applicable | ||
| - Section headers must match exactly (English) or accepted Korean equivalents | ||
| ## History Entry Format | ||
| History entries in `spec/feature/[name]/history/` are validated by PostToolUse hook. | ||
| Written **only after verification passes** (all 4 levels). | ||
| Required: | ||
| - **Filename**: `YYYY-MM-DD-[description].md` | ||
| - **Top-level heading**: `# [Change description]` | ||
| - **Date field**: `Date: YYYY-MM-DD` | ||
| - **Required sections**: `## Reason`, `## Changes`, `## Files Modified` | ||
| - **Optional section**: `## Figma` |
| # Loop Protocol | ||
| > **Immutable.** Read when running `/loop` or understanding loop behavior. | ||
| `/loop` enforces REQ-level compliance through iterative review -> fix cycles: | ||
| ``` | ||
| /loop "feature name" | ||
| -> reviewer checks each REQ (PASS/FAIL) | ||
| -> lead-engineer fixes only failing REQs (with context from previous attempts) | ||
| -> cleanup included in fix step (console.log, commented-out code, unused imports) | ||
| -> update LOOP_NOTES.md with results and next strategy | ||
| -> re-review | ||
| -> repeat until 100% or max iterations | ||
| ``` | ||
| - Default max iterations: **5** (configurable via `max-iterations` in spec.md frontmatter) | ||
| - Each iteration has its own auto-fix budget of 3 (resets per iteration) | ||
| - Only failing REQs are targeted — passing code is never modified | ||
| - If max iterations reached with failing REQs: stop and report to user | ||
| - Resumable: if interrupted, re-running reads LOOP_NOTES.md to continue | ||
| ## Cross-iteration context | ||
| `spec/feature/[name]/LOOP_NOTES.md`: | ||
| - Updated after each iteration with REQ status, failure analysis, and next strategy | ||
| - Prevents repeating the same failed approach across iterations | ||
| - Deleted on loop completion; kept on exhaustion (useful for manual debugging) | ||
| ## Cleanup rules (integrated into fix step) | ||
| The fix step's DONE-WHEN includes cleanup. After fixing failing REQs, also ensure: | ||
| - No `console.log` in changed files | ||
| - No commented-out code in changed files | ||
| - No unused imports in changed files | ||
| - Cleanup does NOT count toward auto-fix budget | ||
| | Phase in STATE.md | Meaning | | ||
| |---|---| | ||
| | `looping` | Loop agent is running review -> fix cycles | |
| # Model Routing | ||
| > **Immutable.** Read when deciding which model to assign to an agent. | ||
| Default model for all agents is **sonnet**. Opus is never used. | ||
| ## Who decides the model | ||
| | Flow | Who decides | How | | ||
| |------|------------|-----| | ||
| | `/dev` | **planner** | Analyzes task size -> writes `## Model Assignment` in PLAN.md | | ||
| | `/loop` | **loop agent** | Assesses failing REQ count per iteration | | ||
| | `/review`, `/spec`, `/debug` | **skill** | Assesses task size before spawning | | ||
| | `/status`, `/rule` | **fixed** | Always haiku (frontmatter) | | ||
| | `/init` | **fixed** | Always sonnet (frontmatter) | | ||
| ## Size criteria | ||
| | Size | Criteria | Model | | ||
| |------|----------|-------| | ||
| | **Small** | ≤3 files AND ≤3 tasks AND no checkpoints | `haiku` | | ||
| | **Large** | >3 files OR >3 tasks OR checkpoints present | `sonnet` | | ||
| ## Agent-specific guidance | ||
| | Agent | When to use haiku | | ||
| |-------|-------------------| | ||
| | `planner` | Never — always sonnet | | ||
| | `lead-engineer` | ≤3 simple tasks AND no checkpoints | | ||
| | `db-engineer` | ≤2 DB tasks, all single-file | | ||
| | `ui-engineer` | ≤2 UI tasks, all single-file | | ||
| | `worker-engineer` | Always haiku (fixed) | | ||
| | `verifier` | Always haiku | | ||
| | `code-quality-reviewer` | Always haiku | | ||
| | `reviewer` | ≤5 REQs AND <5 files | | ||
| | `spec-writer` | Minor updates to existing spec | | ||
| | `debugger` | Single-file bug with clear steps | | ||
| | `rule-writer` | Always haiku (fixed) | | ||
| | `loop` | Never — orchestrates multiple agents | | ||
| | `init` | Never — full codebase analysis | | ||
| If unsure, default to sonnet — correctness over cost savings. |
| # Next.js Task Ordering | ||
| > **Immutable.** Read when the project uses Next.js (App Router or Pages Router). | ||
| ## Dependency Layers | ||
| Order tasks following these dependency layers: | ||
| | Layer | Files | Notes | | ||
| |-------|-------|-------| | ||
| | 0. Mock Setup | `mocks/server.ts`, `mocks/browser.ts`, `mocks/index.ts` | Only when `mock: true` AND `mocks/` does not exist | | ||
| | 1. Types | `types/`, `[feature]/types/` | Define interfaces first | | ||
| | 2. Utilities | `lib/`, `[feature]/utils/` | Pure functions, no side effects | | ||
| | 2.5 Mock Handlers | `mocks/handlers/[feature].ts`, `mocks/fixtures/` | Only when `mock: true` | | ||
| | 3. API / Server Actions | `api/`, `actions.ts` | Server-side data access | | ||
| | 4. Hooks | `hooks/`, `[feature]/hooks/` | Client-side data access | | ||
| | 5. Base Components | `components/`, Server Components | Non-interactive UI | | ||
| | 6. Client Components | Interactive UI with `'use client'` | Forms, event handlers | | ||
| | 7. Page / Layout | `app/.../page.tsx`, `layout.tsx` | Wire everything together | | ||
| ## App Router considerations | ||
| - Mark tasks requiring `'use client'` (hooks, event handlers, browser APIs) | ||
| - Mark tasks that are Server Actions (`'use server'`) | ||
| ## Server vs Client Components | ||
| - Default to Server Components — only add `'use client'` when required | ||
| - Add `'use client'` for: `useState`, `useEffect`, event handlers, browser APIs | ||
| - Keep `'use client'` boundary as deep (leaf) as possible | ||
| - Never add `'use client'` to layout files unless necessary | ||
| ## Server Actions | ||
| - Add `'use server'` directive at top of action file or inline | ||
| - Use `revalidatePath()` or `revalidateTag()` after mutations | ||
| - Validate with zod before database operations | ||
| ## API Routes | ||
| - App Router: `app/api/[route]/route.ts` with named exports (GET, POST, etc.) | ||
| - Pages Router: `pages/api/[route].ts` with default handler | ||
| ## Import paths | ||
| - Use `@/` alias (verify `tsconfig.json` paths) | ||
| - Never use relative imports going up more than 2 levels | ||
| ## Checkpoint guidance for planners | ||
| **When to insert `checkpoint:decision`:** | ||
| - Server vs Client Component choice is unclear | ||
| - Modifying `layout.tsx` (affects all child routes) | ||
| - Modifying shared code (`components/`, `lib/`) | ||
| - Breaking changes to existing type structure | ||
| **When to insert `checkpoint:human-verify`:** | ||
| - Only for intermediate UI milestones | ||
| - Do NOT insert after the final UI task (verifier's Level 4 already does this) | ||
| ## Analysis patterns (for /init) | ||
| App Router patterns to detect: | ||
| - `'use client'` directives, `async function Page()`, `'use server'` | ||
| - `export const dynamic = 'force-dynamic'` | ||
| - `loading.tsx`, `error.tsx`, `not-found.tsx` | ||
| Data fetching patterns: | ||
| - `fetch()` in Server Components, `useQuery`/`useSuspenseQuery`, `useSWR` | ||
| - Server Actions with `revalidatePath` |
| # Verification Protocol | ||
| > **Immutable.** Read when running or understanding verification levels. | ||
| After every `/dev` completion, the verifier runs automatically with 4 levels: | ||
| | Level | Check | Pass Criteria | | ||
| |---|---|---| | ||
| | 1 — Existence | All planned files exist | Every file in PLAN.md is present | | ||
| | 2 — Substantive | No stubs or placeholders | No TODO, empty bodies, dummy values | | ||
| | 2b — Tests | Test files exist (if `testing: required`) | Blocking when required; advisory otherwise | | ||
| | 3 — Wired | Components/hooks/APIs connected | Imports exist, endpoints called, state propagates | | ||
| | 4 — Human | Feature actually works | User confirms in browser | | ||
| - Levels 1-3 run automatically; Level 4 triggers `checkpoint:human-verify` | ||
| - Level 2b depends on spec.md `testing` frontmatter: `required` = blocking, `optional`/`none` = advisory | ||
| - When `testing: required`, lead-engineer writes tests before spawning verifier | ||
| - Verifier failures count toward the shared auto-fix budget (3 retries) | ||
| - Verifier never modifies code — it only reports |
| # FeatureSpec Workflow Rules (Core) | ||
| > **Immutable.** Do not modify after `/init`. Project-specific coding rules belong in non-prefixed files in this directory. | ||
| ## Folder Structure | ||
| ``` | ||
| spec/ | ||
| PROJECT.md <- project purpose, tech stack, testing setup | ||
| ARCHITECTURE.md <- feature map, cross-feature dependencies | ||
| STATE.md <- all features and their current phases (multi-feature) | ||
| DEBUG.md <- debug log (created by /debug) | ||
| rules/ | ||
| _workflow.md <- THIS FILE (core workflow rules, immutable) | ||
| _document-format.md <- spec.md, design.md, history format | ||
| _model-routing.md <- model selection criteria | ||
| _delegation.md <- HANDOFF format, agent spawning rules | ||
| _verification.md <- 4-level verification protocol | ||
| _loop-protocol.md <- /loop rules and cross-iteration context | ||
| _agent-roles.md <- agent role boundaries and responsibilities | ||
| _nextjs-ordering.md <- Next.js task dependency ordering | ||
| code-style.md <- project coding rules (mutable) | ||
| testing.md <- project testing rules (mutable) | ||
| feature/ | ||
| [name]/ | ||
| spec.md <- what to build | ||
| design.md <- how to build it | ||
| PLAN.md <- task list, checkpoints, auto-fix budget | ||
| CONTEXT.md <- locked decisions, constraints | ||
| LOOP_NOTES.md <- cross-iteration context for /loop | ||
| history/ <- change history archive | ||
| ``` | ||
| ## STATE.md Format | ||
| STATE.md tracks multiple features independently. Each feature has its own phase. | ||
| ```markdown | ||
| # State | ||
| Updated: YYYY-MM-DD | ||
| ## Features | ||
| ### [feature-name] [phase] | ||
| Started: YYYY-MM-DD | ||
| ## Completed | ||
| - [feature-name] (YYYY-MM-DD) | ||
| ## Blockers | ||
| - [feature-name]: [blocker description] | ||
| ``` | ||
| Valid phases: `idle`, `planning`, `executing`, `verifying`, `looping` | ||
| Rules: | ||
| - Each feature's phase is independent | ||
| - When a feature completes, move it from `## Features` to `## Completed` with date | ||
| - Keep STATE.md under 100 lines — archive old completed entries | ||
| ## Available Skills | ||
| | Skill | Purpose | | ||
| |---|---| | ||
| | `/init` | First-time setup: analyze codebase, populate spec docs | | ||
| | `/spec` | Define or update a feature spec | | ||
| | `/dev` | Plan, implement, verify a feature. `--team` for parallel team mode | | ||
| | `/review` | Check spec compliance + code quality | | ||
| | `/status` | Show project status | | ||
| | `/debug` | Systematic bug fixing | | ||
| | `/rule` | Add or update a project coding rule | | ||
| | `/loop` | Loop until all REQs in spec.md are satisfied | | ||
| ## Checkpoint Conditions | ||
| | Type | Condition | Action | | ||
| |---|---|---| | ||
| | `checkpoint:decision` | Implementation direction unclear, type structure change | Present options, wait | | ||
| | `checkpoint:human-verify` | UI implementation complete | Request browser verification, wait | | ||
| | `checkpoint:auth-gate` | Payment or auth manual steps required | Always stop, never simulate | | ||
| ## Auto-fix Budget | ||
| Maximum retries: **3** | ||
| - `/dev`: shared counter across session. Persists via PLAN.md `Used: N`. | ||
| - `/loop`: resets per iteration. Each iteration gets budget of 3. | ||
| - `/debug`: 3 attempts per bug. Tracked in DEBUG.md. | ||
| After 3 failed attempts: stop and escalate to user. | ||
| ## Language | ||
| - Default language for spec documents is **English** | ||
| - If user writes in another language, match that language | ||
| - Section headers: **English or Korean** (recognized by `validate-spec.sh`) | ||
| ## Context Management | ||
| - Mark each task `[x]` in PLAN.md immediately upon completion | ||
| - Keep STATE.md under 100 lines — archive old entries to feature history | ||
| ## Excluded Paths | ||
| Do not read: `node_modules/`, `.next/`, `dist/`, `.turbo/`, `.cache/`, lock files | ||
| ## Plan Approval Protocol | ||
| - PLAN.md must include `## Approval` with `Status:` and `Approved-at:` fields | ||
| - Planner sets `Status: pending`; updates to `approved` only after user confirmation | ||
| - Lead-engineer must verify `Status: approved` before starting | ||
| ## Prohibited Actions | ||
| - Do not modify immutable `_` prefixed rule files | ||
| - Do not modify spec.md or design.md during `/dev` without user approval | ||
| - Do not skip `checkpoint:auth-gate` under any circumstances | ||
| - Do not commit directly to main/master | ||
| ## Extended References | ||
| Read ONLY when the condition applies to your current task: | ||
| - `spec/rules/_document-format.md` — when writing spec.md, design.md, or history entries | ||
| - `spec/rules/_model-routing.md` — when deciding which model to assign to an agent | ||
| - `spec/rules/_delegation.md` — when spawning sub-agents or resuming interrupted sessions | ||
| - `spec/rules/_verification.md` — when running or understanding verification levels | ||
| - `spec/rules/_loop-protocol.md` — when running /loop | ||
| - `spec/rules/_agent-roles.md` — when checking agent boundaries or responsibilities | ||
| - `spec/rules/_nextjs-ordering.md` — when project is Next.js |
@@ -36,2 +36,12 @@ { | ||
| "statusMessage": "Checking spec reflection..." | ||
| }, | ||
| { | ||
| "type": "command", | ||
| "command": "bash \"${CLAUDE_PLUGIN_ROOT}/template/.claude/scripts/suggest-skills.sh\"", | ||
| "statusMessage": "Checking for matching skills..." | ||
| }, | ||
| { | ||
| "type": "command", | ||
| "command": "bash \"${CLAUDE_PLUGIN_ROOT}/template/.claude/scripts/security-suggest.sh\"", | ||
| "statusMessage": "Checking security-sensitive changes..." | ||
| } | ||
@@ -38,0 +48,0 @@ ] |
+31
-10
@@ -23,3 +23,3 @@ "use strict"; | ||
| 1. \`spec/STATE.md\` — current progress and active features | ||
| 2. \`spec/RULE.md\` — workflow rules, checkpoint conditions, team mode rules | ||
| 2. \`spec/rules/_workflow.md\` — core workflow rules (extended rules in \`spec/rules/_*.md\`) | ||
@@ -126,12 +126,33 @@ Before modifying code: | ||
| const existing = JSON.parse(fs_1.default.readFileSync(destPath, 'utf-8')); | ||
| const existingPostToolUse = existing.hooks?.PostToolUse ?? []; | ||
| const hasFsHook = existingPostToolUse.some((h) => h.matcher === 'Write|Edit' && JSON.stringify(h).includes('validate-spec')); | ||
| if (hasFsHook) | ||
| return; | ||
| if (!existing.hooks) | ||
| existing.hooks = {}; | ||
| if (!existing.hooks.PostToolUse) | ||
| existing.hooks.PostToolUse = []; | ||
| const existingPostToolUse = existing.hooks.PostToolUse; | ||
| // Collect all existing hook commands across all matcher groups | ||
| const existingCommands = new Set(); | ||
| for (const group of existingPostToolUse) { | ||
| for (const h of group.hooks ?? []) { | ||
| if (h.command) | ||
| existingCommands.add(h.command); | ||
| } | ||
| } | ||
| // For each template hook group, merge missing hooks into matching existing group or add new group | ||
| for (const templateGroup of fsHooks) { | ||
| const templateHooks = templateGroup.hooks ?? []; | ||
| const newHooks = templateHooks.filter((h) => h.command && !existingCommands.has(h.command)); | ||
| if (newHooks.length === 0) | ||
| continue; | ||
| // Find existing group with same matcher | ||
| const matchingGroup = existingPostToolUse.find((g) => g.matcher === templateGroup.matcher); | ||
| if (matchingGroup) { | ||
| if (!matchingGroup.hooks) | ||
| matchingGroup.hooks = []; | ||
| matchingGroup.hooks.push(...newHooks); | ||
| } | ||
| else { | ||
| existingPostToolUse.push({ ...templateGroup, hooks: newHooks }); | ||
| } | ||
| } | ||
| if (!dryRun) { | ||
| if (!existing.hooks) | ||
| existing.hooks = {}; | ||
| if (!existing.hooks.PostToolUse) | ||
| existing.hooks.PostToolUse = []; | ||
| existing.hooks.PostToolUse.push(...fsHooks); | ||
| fs_1.default.writeFileSync(destPath, JSON.stringify(existing, null, 2) + '\n', 'utf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AAC;QACN,IAAI,CAAC,MAAM,EAAE,CAAC;YACZ,YAAE,CAAC,SAAS,CAAC,cAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;YAC1D,YAAE,CAAC,aAAa,CAAC,QAAQ,EAAE,KAAK,CAAC,IAAI,EAAE,GAAG,IAAI,EAAE,OAAO,CAAC,CAAC;QAC3D,CAAC;IACH,CAAC;AACH,CAAC"} |
| import { TemplateVars, UserAnswers } from './types'; | ||
| export declare function render(content: string, vars: TemplateVars): string; | ||
| export declare function buildTemplateVars(answers: UserAnswers): TemplateVars; | ||
| export declare function sanitizeFeatureName(name: string): string; | ||
| //# sourceMappingURL=renderer.d.ts.map |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"renderer.d.ts","sourceRoot":"","sources":["../src/renderer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAEpD,wBAAgB,MAAM,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,YAAY,GAAG,MAAM,CAIlE;AAED,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,WAAW,GAAG,YAAY,CAQpE;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAMxD"} | ||
| {"version":3,"file":"renderer.d.ts","sourceRoot":"","sources":["../src/renderer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAEpD,wBAAgB,MAAM,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,YAAY,GAAG,MAAM,CAIlE;AAED,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,WAAW,GAAG,YAAY,CAQpE"} |
+0
-8
@@ -5,3 +5,2 @@ "use strict"; | ||
| exports.buildTemplateVars = buildTemplateVars; | ||
| exports.sanitizeFeatureName = sanitizeFeatureName; | ||
| function render(content, vars) { | ||
@@ -20,9 +19,2 @@ return content.replace(/\{\{(\w+)\}\}/g, (_, key) => { | ||
| } | ||
| function sanitizeFeatureName(name) { | ||
| return name | ||
| .trim() | ||
| .toLowerCase() | ||
| .replace(/\s+/g, '-') | ||
| .replace(/[^a-z0-9-]/g, ''); | ||
| } | ||
| //# sourceMappingURL=renderer.js.map |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"renderer.js","sourceRoot":"","sources":["../src/renderer.ts"],"names":[],"mappings":";;AAEA,wBAIC;AAED,8CAQC;AAED,kDAMC;AAtBD,SAAgB,MAAM,CAAC,OAAe,EAAE,IAAkB;IACxD,OAAO,OAAO,CAAC,OAAO,CAAC,gBAAgB,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,EAAE;QAClD,OAAO,GAAG,IAAI,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,IAAI,CAAC;IAChD,CAAC,CAAC,CAAC;AACL,CAAC;AAED,SAAgB,iBAAiB,CAAC,OAAoB;IACpD,MAAM,KAAK,GAAG,IAAI,IAAI,EAAE,CAAC;IACzB,MAAM,WAAW,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;IAEtD,OAAO;QACL,YAAY,EAAQ,OAAO,CAAC,WAAW;QACvC,YAAY,EAAQ,WAAW;KAChC,CAAC;AACJ,CAAC;AAED,SAAgB,mBAAmB,CAAC,IAAY;IAC9C,OAAO,IAAI;SACR,IAAI,EAAE;SACN,WAAW,EAAE;SACb,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC;SACpB,OAAO,CAAC,aAAa,EAAE,EAAE,CAAC,CAAC;AAChC,CAAC"} | ||
| {"version":3,"file":"renderer.js","sourceRoot":"","sources":["../src/renderer.ts"],"names":[],"mappings":";;AAEA,wBAIC;AAED,8CAQC;AAdD,SAAgB,MAAM,CAAC,OAAe,EA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AS,EAAE,MAAM,GAAG,IAAI,CAoB3D;AAID,wBAAsB,uBAAuB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAgD9E;AAID,wBAAsB,YAAY,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAyCnE"} | ||
| {"version":3,"file":"skills-installer.d.ts","sourceRoot":"","sources":["../src/skills-installer.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,QAAQ,EAAyC,aAAa,EAAE,MAAM,SAAS,CAAC;AASzF,eAAO,MAAM,MAAM,EAAE,QAAQ,EA+Q5B,CAAC;AAIF,wBAAgB,aAAa,CAAC,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,EAAE,GAAG,OAAO,CAIrG;AAuBD,wBAAgB,kBAAkB,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,CAE5D;AAkCD,wBAAsB,aAAa,CACjC,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,aAAa,EACxB,SAAS,EAAE,MAAM,EAAE,EACnB,MAAM,EAAE,OAAO,GACd,OAAO,CAAC,IAAI,CAAC,CA0Cf;AAID,wBAAsB,kBAAkB,CAAC,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CA+B/F;AA6BD,wBAAgB,mBAAmB,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,CAoB3D;AAID,wBAAsB,uBAAuB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAgD9E;AAID,wBAAsB,YAAY,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAyCnE"} |
@@ -112,3 +112,3 @@ "use strict"; | ||
| }, | ||
| // ── Core: Skill Discovery ─────────────────────────────────────────────────── | ||
| // ── On-demand: Skill Discovery ────────────────────────────────────────────── | ||
| { | ||
@@ -119,5 +119,5 @@ name: 'find-skills', | ||
| description: 'Skill finder — search and install skills dynamically', | ||
| tier: 'core', | ||
| tier: 'on-demand', | ||
| }, | ||
| // ── Core: Changelog ──────────────────────────────────────────────────────── | ||
| // ── On-demand: Changelog ────────────────────────────────────────────────── | ||
| { | ||
@@ -128,3 +128,3 @@ name: 'changelog-maintenance', | ||
| description: 'Keep a Changelog + Semantic Versioning maintenance', | ||
| tier: 'core', | ||
| tier: 'on-demand', | ||
| }, | ||
@@ -369,3 +369,2 @@ // ── Core: DevOps / CI ─────────────────────────────────────────────────────── | ||
| else { | ||
| installed++; | ||
| continue; | ||
@@ -372,0 +371,0 @@ } |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"skills-installer.js","sourceRoot":"","sources":["../src/skills-installer.ts"],"names":[],"mappings":";;;;;;AAiSA,sCAIC;AAuBD,gDAEC;AAkCD,sCAgDC;AAID,gDA+BC;AA6BD,kDAoBC;AAID,0DAgDC;AAID,oCAyCC;AArkBD,4CAAoB;AACpB,gDAAwB;AACxB,iDAAyC;AACzC,4DAA4B;AAC5B,sDAA8B;AAE9B,qCAAiD;AACjD,qCAAyC;AAEzC,MAAM,YAAY,GAAG,cAAI,CAAC,OAAO,CAAC,SAAS,EAAE,aAAa,CAAC,CAAC;AAC5D,MAAM,kBAAkB,GAAG,cAAI,CAAC,IAAI,CAAC,YAAY,EAAE,gBAAgB,CAAC,CAAC;AAErE,kFAAkF;AAErE,QAAA,MAAM,GAAe;IAChC,sEAAsE;IACtE;QACE,IAAI,EAAE,6BAA6B;QACnC,GAAG,EAAE,wEAAwE;QAC7E,GAAG,EAAE,8GAA8G;QACnH,WAAW,EAAE,mDAAmD;QAChE,IAAI,EAAE,MAAM;KACb;IACD;QACE,IAAI,EAAE,6BAA6B;QACnC,GAAG,EAAE,wEAAwE;QAC7E,GAAG,EAAE,8GAA8G;QACnH,WAAW,EAAE,sCAAsC;QACnD,IAAI,EAAE,MAAM;KACb;IACD;QACE,IAAI,EAAE,iBAAiB;QACv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E,MAAM,EAAE,CAAC,CAAC;YACvE,OAAO,EAAE,CAAC;QACZ,CAAC;QAAC,MAAM,CAAC;YACP,MAAM,EAAE,CAAC;QACX,CAAC;IACH,CAAC;IAED,cAAc;IACd,IAAI,YAAE,CAAC,UAAU,CAAC,YAAY,CAAC,EAAE,CAAC;QAChC,MAAM,QAAQ,GAAyB,IAAI,CAAC,KAAK,CAAC,YAAE,CAAC,YAAY,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC,CAAC;QAC1F,MAAM,GAAG,GAAG,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC;QACrC,KAAK,MAAM,KAAK,IAAI,QAAQ,EAAE,CAAC;YAC7B,KAAK,CAAC,WAAW,GAAG,GAAG,CAAC;YACxB,KAAK,CAAC,MAAM,GAAG,KAAK,CAAC;QACvB,CAAC;QACD,YAAE,CAAC,aAAa,CAAC,YAAY,EAAE,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,GAAG,IAAI,EAAE,OAAO,CAAC,CAAC;IACpF,CAAC;IAED,IAAI,MAAM,GAAG,CAAC,EAAE,CAAC;QACf,iBAAQ,CAAC,OAAO,CAAC,mBAAmB,OAAO,QAAQ,MAAM,UAAU,CAAC,CAAC;IACvE,CAAC;SAAM,CAAC;QACN,iBAAQ,CAAC,OAAO,CAAC,mBAAmB,OAAO,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAC;IACrE,CAAC;AACH,CAAC"} |
+1
-1
| { | ||
| "name": "nextjs-claude-code", | ||
| "version": "1.0.0", | ||
| "version": "1.0.1", | ||
| "description": "Spec-Driven AI Development workflow for Next.js & React with Claude Code", | ||
@@ -5,0 +5,0 @@ "author": "ByeongminLee", |
+41
-9
@@ -14,8 +14,8 @@ # NCC — nextjs-claude-code | ||
| - **Spec-Driven**: Feature specs with REQ-NNN traceability, compliance reporting | ||
| - **Curated skills** from [skills.sh](https://skills.sh) (community skill registry for Claude Code) — includes React, Next.js, UI/UX, testing, and library-specific best practices | ||
| - **Architecture guides** — Flat, Feature-Based, FSD, Monorepo (chosen by team size) | ||
| - **Curated skills** from [skills.sh](https://skills.sh) (community skill registry for Claude Code) — bundled core skills installed automatically, on-demand skills for library-specific best practices. Includes React, Next.js, UI/UX, testing patterns | ||
| - **Architecture guides** — Flat, Feature-Based, FSD, Monorepo (auto-detected from project structure; refined via `/init`) | ||
| - **Library-aware agents** — agents read your selected stack and follow its patterns | ||
| - **Next.js native** — App Router, Server Components, Server Actions, Pages Router | ||
| - **React support** — Vite and other React setups | ||
| - **Monorepo ready** — Turborepo workspace-aware installation | ||
| - **Monorepo ready** — detects monorepo patterns (Turborepo, apps/packages) and adapts skills/rules during `/init` | ||
| - **Claude Code native** — slash commands, multi-agent coordination, PostToolUse hooks (validation scripts that run after Claude writes or edits files) | ||
@@ -44,2 +44,13 @@ | ||
| ## Quick Start | ||
| ```bash | ||
| npx nextjs-claude-code@latest # install SDD workflow | ||
| /init # analyze codebase, populate spec docs | ||
| /spec auth "user login with email" # define a feature spec | ||
| /dev auth # implement the feature | ||
| ``` | ||
| --- | ||
| ## Why SDD? | ||
@@ -140,3 +151,3 @@ | ||
| |---------|-------------| | ||
| | `/cicd` | Set up CI/CD pipeline. Uses find-skills for platform-specific skill discovery. Generates spec/CICD.md. | | ||
| | `/cicd` | (experimental) Set up CI/CD pipeline. Uses find-skills for platform-specific skill discovery. Generates spec/CICD.md. | | ||
@@ -172,4 +183,6 @@ ### Dev Utilities | ||
| | `ui-engineer` | Components, styling, animations, responsive | sonnet | Yes (UI files only) | | ||
| | `worker-engineer` | Simple utils, types, config (~200 lines) | haiku | Yes (assigned file only) | | ||
| | `worker-engineer` | Simple utils, types, config (≤200 lines) | haiku | Yes (assigned file only) | | ||
| > **Note:** Team mode requires `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` environment variable. npx install sets this in `.claude/settings.json`; plugin install provides it via `plugin.json` env. | ||
| ### Ops Agents | ||
@@ -182,3 +195,3 @@ | ||
| | `tester` | Test execution + TEST.md management | Creates test files only | Yes (TEST.md) | | ||
| | `browser-tester` | Browser tests + Figma comparison | No | No (read-only) | | ||
| | `browser-tester` | (experimental) Browser tests + Figma comparison | No | No (read-only) | | ||
| | `committer` | Auto-generate commit messages | No | No | | ||
@@ -189,3 +202,3 @@ | `pr-creator` | PR creation + changelog + version bump | No (CHANGELOG.md + version only) | Yes (CHANGELOG.md) | | ||
| | `security-reviewer` | Security audit (OWASP Top 10) | No | No (read-only) | | ||
| | `cicd-builder` | CI/CD pipeline generation | Yes | Yes (CICD.md) | | ||
| | `cicd-builder` | (experimental) CI/CD pipeline generation | Yes | Yes (CICD.md) | | ||
| | `loop` | Force-complete REQ compliance | Yes (via lead-engineer) | Partial (STATE, history) | | ||
@@ -240,2 +253,9 @@ | `status` | Project status summary | No | No (read-only) | | ||
| - `spec/STATE.md` tracks each feature's phase independently: `idle` → `planning` → `executing` → `verifying` → `idle` (or `looping` during `/loop`) | ||
| - `/dev` reads the feature's phase and routes to the appropriate agent instead of restarting from scratch | ||
| - Completed tasks (`- [x]`) in `spec/feature/[name]/PLAN.md` are skipped on resume | ||
| - Auto-fix budget (`Used: N`) persists across sessions | ||
| - If spec.md was modified after PLAN.md was created, a warning is shown with a re-planning suggestion | ||
| - **Model routing**: sonnet by default, haiku for small/mechanical tasks (verifier, cleanup, simple fixes). Opus is never used. See `spec/rules/_model-routing.md` for criteria. | ||
| | Phase | Resume behavior | | ||
@@ -247,3 +267,3 @@ |-------|----------------| | ||
| | `verifying` | Re-run verifier via lead-engineer | | ||
| | `looping` | Redirect to `/loop` command | | ||
| | `looping` | Read LOOP_NOTES.md and resume from current iteration | | ||
@@ -255,3 +275,3 @@ ### Additional safeguards | ||
| - **Plan staleness check**: `/dev` warns if spec.md has been modified since the feature's PLAN.md was created | ||
| - **Model routing**: agents use sonnet by default, haiku for small/mechanical tasks (verifier, cleanup, simple fixes). Opus is never used. See `spec/RULE.md` Model Routing for criteria. | ||
| - **Model routing**: agents use sonnet by default, haiku for small/mechanical tasks (verifier, cleanup, simple fixes). Opus is never used. See `spec/rules/_model-routing.md` for criteria. | ||
| - **Branch strategy awareness**: `/commit` and `/pr` auto-detect branch strategy and enforce commit conventions | ||
@@ -263,2 +283,14 @@ - **Conditional review agents**: tester, log-auditor, and security-reviewer only join `/review` when their strategy files exist (TEST_STRATEGY.md, LOG_STRATEGY.md, SECURITY_STRATEGY.md) | ||
| ## Troubleshooting | ||
| | Issue | Solution | | ||
| |-------|----------| | ||
| | Plan approval stuck at "pending" | Re-run `/dev [name]` to restart the planning flow | | ||
| | Auto-fix budget exhausted | Lead-engineer stops after 3 attempts. Review the error manually and provide guidance | | ||
| | Team mode not working | Verify `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` is set in `.claude/settings.json` | | ||
| | Spec validation blocking writes | Check that section headers match the expected format (English or Korean) | | ||
| | Hook errors on every file write | Edit `.claude/settings.json` to remove or disable specific hooks | | ||
| --- | ||
| ## Contributing | ||
@@ -265,0 +297,0 @@ |
@@ -18,7 +18,6 @@ --- | ||
| 4. **Read `spec/feature/[name]/CONTEXT.md`** — locked decisions are non-negotiable | ||
| 5. **Read `spec/RULE.md`** — workflow rules | ||
| 6. **Read all files in `spec/rules/`** — project coding rules | ||
| 5. **Read `spec/rules/_workflow.md`** — core workflow rules | ||
| 6. **Read `spec/rules/code-style.md`** and any database-related rule files in `spec/rules/` — skip UI/component rule files | ||
| 7. **Read feature `spec.md` and `design.md`** — understand what you are building | ||
| 8. **Read `spec/PROJECT.md`** — detect ORM and database platform | ||
| 9. **Read `AGENTS.md`** in target directories — understand codebase layout | ||
@@ -100,5 +99,2 @@ ## Skill scope | ||
| 6. Mark task done in PLAN.md: `- [x] Task N` | ||
| 7. **Update `AGENTS.md`** — same rules as lead-engineer: | ||
| - New file → add entry, file changed → update entry, file deleted → remove entry | ||
| - Directory has 3+ source files but no AGENTS.md → create one | ||
@@ -105,0 +101,0 @@ ## Auto-fix protocol |
@@ -14,3 +14,3 @@ --- | ||
| 2. **Read `spec/RULE.md`** — FeatureSpec workflow rules (checkpoints, prohibited actions) | ||
| 2. **Read `spec/rules/_workflow.md`** — core workflow rules | ||
@@ -20,3 +20,2 @@ 3. **Read relevant feature's `spec.md`** — establish expected behavior (source of truth) | ||
| - If you can't identify the feature, ask the user | ||
| - Read `AGENTS.md` in relevant source directories to quickly locate related files before grepping | ||
@@ -23,0 +22,0 @@ 4. **Create / open `spec/DEBUG.md`** |
@@ -20,8 +20,8 @@ --- | ||
| - `spec/RULE.md` — if missing, copy from the bundled reference file. | ||
| Search in this order (stop at first found): | ||
| 1. `.claude/RULE.md` (bundled with NCC plugin/npx install) | ||
| 2. Glob for `**/RULE.md.template` anywhere in the project | ||
| Read the found file and write its content to `spec/RULE.md` verbatim. | ||
| If no source found, report: "RULE.md not found. Run `npx nextjs-claude-code@latest` to install all template files." Continue with other steps. | ||
| - `spec/rules/_workflow.md` — if missing, search for `_*.md` workflow rule files in this order: | ||
| 1. Project `spec/rules/` (already installed by npx) | ||
| 2. `.claude/` bundled path — Glob for `**/spec/rules/_workflow.md` in `.claude/` directory | ||
| 3. Plugin path — Glob for `**/template/spec/rules/_workflow.md` anywhere in the project (plugin installs use `${CLAUDE_PLUGIN_ROOT}`) | ||
| Copy all found `_*.md` files to `spec/rules/`. | ||
| If no source found in any path, report: "Workflow rules not found. Run `npx nextjs-claude-code@latest` to install or check your plugin installation." Continue with other steps. | ||
@@ -134,3 +134,3 @@ - `spec/STATE.md` — if missing, create: | ||
| - If a `docs/` directory exists, read each file and create corresponding `spec/rules/[topic].md` | ||
| - Do NOT modify `spec/RULE.md` — it is immutable | ||
| - Do NOT modify `spec/rules/_*.md` files — they are immutable | ||
@@ -148,16 +148,4 @@ 8. **Write draft `spec/feature/[name]/spec.md` for each discovered feature** | ||
| 10. **Generate `AGENTS.md` navigation indices** | ||
| - Scan for source directories: `src/`, `app/`, `components/`, `lib/`, `hooks/`, `features/`, `pages/`, `utils/`, `services/`, `actions/`, `types/` and their subdirectories | ||
| - For each directory that exists AND has 3+ source files (`.ts`, `.tsx`, `.js`, `.jsx`): | ||
| - Read each file's first 20 lines (imports, exports, component name) | ||
| - Write `AGENTS.md` in that directory following the format in `spec/RULE.md` → `## AGENTS.md Navigation Index` | ||
| - `## Files` — 1-2 lines per file (name, purpose, key exports/props) | ||
| - `## Directories` — 1 line per subdirectory (name, purpose) | ||
| - Do NOT generate for: `node_modules/`, `.next/`, `dist/`, `.turbo/`, `spec/`, `.claude/` | ||
| - Do NOT generate for directories with fewer than 3 source files | ||
| - If a directory has 50+ files, group by pattern instead of listing each | ||
| - Log: "Generated AGENTS.md in N directories" | ||
| 10. **Detect git branch strategy (optional)** | ||
| 11. **Detect git branch strategy (optional)** | ||
| Check if `spec/GIT_STRATEGY.md` exists. If it does NOT exist and git remote is configured: | ||
@@ -174,6 +162,6 @@ - Run `git branch -r` to check for remote branches | ||
| 12. **Suggest on-demand skills based on detected libraries** | ||
| 11. **Suggest on-demand skills based on detected libraries** | ||
| After completing analysis, check if there are matching on-demand skills: | ||
| - Also check if `find-skills` is installed (it should be core). If not, note it for the user. | ||
| - Also check if `find-skills` is installed (it is an on-demand skill). If not, suggest: `npx nextjs-claude-code skill-add find-skills` | ||
| - Read `.claude/skills/skill-catalog.json` (list of available on-demand skills) | ||
@@ -193,3 +181,3 @@ - Read `.claude/skills/skills-manifest.json` (already installed skills) | ||
| 13. **Present summary to user** | ||
| 12. **Present summary to user** | ||
| - List all files written | ||
@@ -203,15 +191,4 @@ - Show detected stack: framework, router, libraries, architecture | ||
| **App Router patterns to detect** | ||
| - `'use client'` directives → identifies Client Components | ||
| - `async function Page()` → Server Component pages | ||
| - `'use server'` → Server Actions | ||
| - `export const dynamic = 'force-dynamic'` → opted out of caching | ||
| - `loading.tsx`, `error.tsx`, `not-found.tsx` → file-based UI states | ||
| For Next.js patterns to detect during analysis, read `spec/rules/_nextjs-ordering.md`. | ||
| **Data fetching patterns** | ||
| - `fetch()` in Server Components → native server-side fetching | ||
| - `useQuery` / `useSuspenseQuery` → TanStack Query | ||
| - `useSWR` → SWR | ||
| - Server Actions with `revalidatePath` → mutation + revalidation pattern | ||
| ## Hard constraints | ||
@@ -218,0 +195,0 @@ - Never modify source code files (`.ts`, `.tsx`, `.js`, `.jsx`, `.css`, etc.) |
| --- | ||
| name: lead-engineer | ||
| description: Lead implementation engineer for Next.js/React projects. Handles business logic, API routes, server actions, hooks, utilities, types. In solo mode, implements all tasks sequentially. In team mode (/dev --team), creates and coordinates an agent team with DB and UI engineers. Has authority over all other engineers. | ||
| description: Lead implementation engineer for Next.js/React projects. Handles business logic, API routes, server actions, hooks, utilities, types. In solo mode, implements all tasks sequentially. In team mode (/dev --team), coordinates an agent team. Has authority over all other engineers. | ||
| tools: Read, Write, Edit, Glob, Bash, Agent | ||
@@ -18,14 +18,13 @@ model: sonnet | ||
| - If `Status: approved` and `Approved-at:` timestamp exists → proceed | ||
| - If `Status: pending` or missing → **STOP immediately**. Report: "PLAN.md has not been approved. Please run `/dev` again so the planner can present the plan for approval." | ||
| - If `Status: pending` or missing → **STOP immediately**. Report: "PLAN.md has not been approved." | ||
| 4. **Read `spec/feature/[name]/CONTEXT.md`** — all decisions here are non-negotiable | ||
| 5. **Read `spec/RULE.md`** — workflow rules (immutable) | ||
| 5. **Read `spec/rules/_workflow.md`** — core workflow rules | ||
| 6. **Read all files in `spec/rules/`** — project coding rules. Follow these when writing code. | ||
| 7. **Read feature `spec.md` and `design.md`** — understand what you are building | ||
| - If `design.md` has a non-empty `figma` URL and Figma MCP is available, use `get_design_context` or `get_screenshot` to read design context before implementing UI components | ||
| 7b. **Read `AGENTS.md` navigation indices** — if target directories have `AGENTS.md`, read them first to understand the directory layout before globbing or grepping | ||
| 8. **Update `spec/STATE.md`** — set the feature's phase to `executing`: `### [feature-name] [executing]` | ||
| 9. **Restore auto-fix budget** — read `Auto-fix Budget: Max retries: 3 / Used: N` from PLAN.md. Start counter at N. | ||
| - If `design.md` has a non-empty `figma` URL and Figma MCP is available, use `get_design_context` or `get_screenshot` | ||
| 8. **Update `spec/STATE.md`** — set phase to `executing`: `### [feature-name] [executing]` | ||
| 9. **Restore auto-fix budget** — read `Auto-fix Budget: Max retries: 3 / Used: N` from PLAN.md | ||
| 10. **Determine mode** — check PLAN.md for `## Team Composition`: | ||
| - If present → **Team Leader Mode** | ||
| - If absent → **Solo Mode** | ||
| - If present → read `.claude/agents/lead-engineer-team-mode.md` and follow **Team Leader Mode** | ||
| - If absent → **Solo Mode** (below) | ||
@@ -36,3 +35,3 @@ --- | ||
| When `## Team Composition` is absent from PLAN.md, you work alone — implementing all tasks sequentially. | ||
| When `## Team Composition` is absent from PLAN.md, you work alone. | ||
@@ -42,3 +41,3 @@ ### Worker delegation in solo mode | ||
| If any tasks are tagged `[worker]` in PLAN.md: | ||
| - When you reach a `[worker]` task in the execution order, spawn `worker-engineer` as a **subagent** (via Agent tool with model: haiku): | ||
| - Spawn `worker-engineer` as a **subagent** (via Agent tool with model: haiku): | ||
| ``` | ||
@@ -58,4 +57,4 @@ [HANDOFF] | ||
| ``` | ||
| - After worker completes, verify the output (quick read of the file) and mark the task `[x]` in PLAN.md | ||
| - If worker fails, implement the task yourself. **Worker failures count toward the shared auto-fix budget** — increment `Used: N+1` in PLAN.md before retrying. | ||
| - After worker completes, verify output and mark task `[x]` in PLAN.md | ||
| - If worker fails, implement yourself. Worker failures count toward auto-fix budget. | ||
@@ -65,93 +64,28 @@ ### Solo task execution | ||
| For each task in PLAN.md (in order): | ||
| 1. **Check if already completed** — if marked `- [x]`, skip entirely | ||
| 2. If tagged `[worker]` → delegate to worker-engineer subagent (see above) | ||
| 3. If the task targets `mocks/` files (mock setup or mock handler) → follow the **MSW Mock generation** section below | ||
| 1. **Check if already completed** — if marked `- [x]`, skip | ||
| 2. If tagged `[worker]` → delegate to worker-engineer subagent | ||
| 3. If the task targets `mocks/` files → read `.claude/agents/lead-engineer-msw-mock.md` | ||
| 4. Otherwise, read the target files first | ||
| 5. Implement the change following `spec/rules/` conventions | ||
| 5. Run type check: `npx tsc --noEmit` | ||
| 6. Mark task done in PLAN.md: `- [x] Task N` | ||
| 6b. **Update `AGENTS.md`** — if the target file's directory has an `AGENTS.md`: | ||
| - New file created → add a 1-2 line entry to `## Files` | ||
| - File purpose changed (new exports, renamed, major refactor) → update its entry | ||
| - File deleted → remove its entry | ||
| - Directory has no `AGENTS.md` but now has 3+ source files → create one following the format in `spec/RULE.md` | ||
| - Keep updates minimal — update only the changed entry, do not re-scan the directory | ||
| 7. If a checkpoint is defined after this task, trigger it now | ||
| 6. Run type check: `npx tsc --noEmit` | ||
| 7. Mark task done in PLAN.md: `- [x] Task N` | ||
| 8. If a checkpoint is defined after this task → read `.claude/agents/lead-engineer-completion.md` for protocol | ||
| --- | ||
| ## Team Leader Mode | ||
| ## Build & type check commands | ||
| > **Experimental:** Team mode requires `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1`. If team creation fails (e.g., experimental flag not set, API error), log "Team creation failed. Falling back to solo mode." and switch to Solo Mode for all tasks (ignore team tags, execute sequentially). | ||
| After each task, run the appropriate check: | ||
| When `## Team Composition` is present in PLAN.md, you are the **team leader** using Claude Code Agent Teams. | ||
| | Scenario | Command | | ||
| |----------|---------| | ||
| | Next.js (preferred) | `npx next build --no-lint` | | ||
| | TypeScript only | `npx tsc --noEmit` | | ||
| | Linting | `npx next lint` or `npx eslint . --ext .ts,.tsx` | | ||
| | Tests | `npx vitest run` or `npx jest --passWithNoTests` | | ||
| ### Step 1 — Create the agent team | ||
| Run `tsc --noEmit` first — faster than a full build and catches most errors. | ||
| Create a Claude Code agent team. You are the leader. | ||
| When a build error occurs → read `.claude/agents/lead-engineer-autofix.md` for resolution protocol. | ||
| ### Step 2 — Spawn teammates | ||
| For each engineer listed in `## Team Composition` under `Engineers:`: | ||
| **db-engineer** (if listed): | ||
| ``` | ||
| Create a teammate named "db-engineer". | ||
| You are the db-engineer for feature "[feature-name]". | ||
| Read your full instructions from .claude/agents/db-engineer.md. | ||
| Your tasks in spec/feature/[feature-name]/PLAN.md are tagged [db]. | ||
| Implement tasks: [task numbers from Team Composition]. | ||
| Rules: | ||
| - Only work on [db]-tagged tasks | ||
| - Message me before attempting any auto-fix (I manage the budget) | ||
| - Message me when all tasks are complete or if you are blocked | ||
| - My decisions take priority — follow my instructions if I override anything | ||
| ``` | ||
| **ui-engineer** (if listed): | ||
| ``` | ||
| Create a teammate named "ui-engineer". | ||
| You are the ui-engineer for feature "[feature-name]". | ||
| Read your full instructions from .claude/agents/ui-engineer.md. | ||
| Your tasks in spec/feature/[feature-name]/PLAN.md are tagged [ui]. | ||
| Implement tasks: [task numbers from Team Composition]. | ||
| Rules: | ||
| - Only work on [ui]-tagged tasks | ||
| - Message me before attempting any auto-fix (I manage the budget) | ||
| - Message me when all tasks are complete or if you are blocked | ||
| - My decisions take priority — follow my instructions if I override anything | ||
| ``` | ||
| **worker-engineer** — always spawn as **subagent** (not a teammate): | ||
| - Use the Agent tool with model: haiku, same as solo mode | ||
| - Worker tasks are handled by you directly via subagent delegation | ||
| ### Step 3 — Work on your own tasks | ||
| While teammates work on their tasks: | ||
| 1. Implement `[lead]` tasks yourself, following the same execution protocol as solo mode | ||
| 2. Delegate `[worker]` tasks to worker-engineer subagents as they come up in order | ||
| 3. Respect Task Dependencies from PLAN.md — do not start a task until its dependencies are complete | ||
| ### Step 4 — Coordinate | ||
| - **Monitor teammates**: Check the shared task list for completion status | ||
| - **Handle auto-fix requests**: When a teammate messages you about a build error: | ||
| 1. Check the current auto-fix budget in PLAN.md (`Used: N`) | ||
| 2. If budget available (Used < 3): approve the fix attempt, increment `Used: N+1` in PLAN.md | ||
| 3. If budget exhausted: instruct the teammate to stop and report the error | ||
| - **Resolve conflicts**: If teammates disagree or face ambiguity, your decision is final | ||
| - **No broadcast**: Always use point-to-point messages to specific teammates | ||
| - **Worker failures**: If a worker subagent fails, implement the task yourself | ||
| ### Step 5 — All tasks complete | ||
| After all teammates report completion and all tasks are marked `[x]`: | ||
| 1. Shut down teammates gracefully | ||
| 2. Proceed to the standard completion flow (same as solo mode) | ||
| --- | ||
| ## Skill scope | ||
@@ -170,220 +104,6 @@ | ||
| **Do NOT read** (other engineers' domain — unless handling `[ui]`-tagged tasks in solo mode): | ||
| - `.claude/skills/frontend-design/` — UI engineer's domain (read when handling [ui] tasks yourself) | ||
| - `.claude/skills/web-design-guidelines/` — UI engineer's domain (read when handling [ui] tasks yourself) | ||
| - `.claude/skills/image-optimizer/` — UI engineer's domain | ||
| - `.claude/skills/seo-audit/` — marketing-specific | ||
| - `.claude/skills/marketing-psychology/` — marketing-specific | ||
| **Do NOT read** (unless handling `[ui]` tasks in solo mode): | ||
| - `.claude/skills/frontend-design/`, `.claude/skills/web-design-guidelines/` | ||
| - `.claude/skills/image-optimizer/`, `.claude/skills/seo-audit/`, `.claude/skills/marketing-psychology/` | ||
| --- | ||
| ## MSW Mock generation | ||
| When a task is tagged as mock setup or mock handler in PLAN.md (from `mock: true` in spec.md): | ||
| ### Mock Setup (one-time, Layer 0) | ||
| Only create if `mocks/` directory does not exist. Generate these files: | ||
| **`mocks/server.ts`** — Node.js server for Server Components / SSR: | ||
| ```typescript | ||
| import { setupServer } from "msw/node"; | ||
| import { handlers } from "./handlers"; | ||
| export const server = setupServer(...handlers); | ||
| ``` | ||
| **`mocks/browser.ts`** — Browser worker for Client Components: | ||
| ```typescript | ||
| import { setupWorker } from "msw/browser"; | ||
| import { handlers } from "./handlers"; | ||
| export const worker = setupWorker(...handlers); | ||
| ``` | ||
| **`mocks/index.ts`** — Environment-toggled initializer: | ||
| ```typescript | ||
| export async function initMocks() { | ||
| if (process.env.NEXT_PUBLIC_API_MOCKING !== "enabled") return; | ||
| if (typeof window === "undefined") { | ||
| const { server } = await import("./server"); | ||
| server.listen({ onUnhandledRequest: "bypass" }); | ||
| } else { | ||
| const { worker } = await import("./browser"); | ||
| await worker.start({ onUnhandledRequest: "bypass" }); | ||
| } | ||
| } | ||
| ``` | ||
| **`mocks/handlers/index.ts`** — Handler aggregator: | ||
| ```typescript | ||
| export const handlers = [ | ||
| // Feature handlers will be spread here | ||
| ]; | ||
| ``` | ||
| After creating mock setup files, check if `msw` is in `package.json` dependencies. If not, run: `npm install msw --save-dev` | ||
| ### Mock Handlers (per feature, Layer 2.5) | ||
| Read `## API Contracts` from `spec/feature/[name]/spec.md`. For each endpoint: | ||
| **`mocks/fixtures/[feature].ts`** — Type-safe mock data: | ||
| - Create success, error, and edge-case fixtures based on the response shapes in API Contracts | ||
| - Use realistic but deterministic values (no Math.random) | ||
| - Export each fixture as a named const | ||
| **`mocks/handlers/[feature].ts`** — MSW request handlers: | ||
| - Import `http` and `HttpResponse` from `msw` | ||
| - Import fixtures from `../fixtures/[feature]` | ||
| - Create one handler per endpoint using `http.get()`, `http.post()`, etc. | ||
| - Default to success response; include commented variants for error scenarios | ||
| After creating handler file, update `mocks/handlers/index.ts` to import and spread the new handlers. | ||
| ### Mock toggle in Next.js | ||
| If mock setup was just created, the engineer should also add the MSW initialization call. The approach depends on the router: | ||
| **App Router** — add to `app/layout.tsx` or a dedicated `app/providers.tsx`: | ||
| ```typescript | ||
| import { initMocks } from "@/mocks"; | ||
| // Call at module level for server-side, or in useEffect for client-side | ||
| ``` | ||
| **Pages Router** — add to `pages/_app.tsx`: | ||
| ```typescript | ||
| import { initMocks } from "@/mocks"; | ||
| ``` | ||
| The `initMocks()` function is a no-op when `NEXT_PUBLIC_API_MOCKING` is not `"enabled"`, so it is safe to leave in production code. However, prefer conditional dynamic import to exclude mock code from production bundles: | ||
| ```typescript | ||
| if (process.env.NEXT_PUBLIC_API_MOCKING === "enabled") { | ||
| require("@/mocks").initMocks(); | ||
| } | ||
| ``` | ||
| --- | ||
| ## Build & type check commands | ||
| After each task, run the appropriate check. Read `package.json` scripts to determine which to use: | ||
| | Scenario | Command | | ||
| |----------|---------| | ||
| | Next.js (preferred) | `npx next build --no-lint` (fastest type check) | | ||
| | TypeScript only | `npx tsc --noEmit` | | ||
| | Linting | `npx next lint` or `npx eslint . --ext .ts,.tsx` | | ||
| | Tests | `npx vitest run` or `npx jest --passWithNoTests` | | ||
| Run `tsc --noEmit` first — it's faster than a full build and catches most errors. | ||
| ## Auto-fix Budget & Build Error Resolution | ||
| Track retries internally. When a build or type error occurs, follow this diagnostic process: | ||
| **Step 1 — Collect all errors** | ||
| ```bash | ||
| npx tsc --noEmit 2>&1 | head -50 | ||
| ``` | ||
| Collect the full error list before fixing anything. | ||
| **Step 2 — Categorize errors by type** | ||
| | TypeScript error | Minimal fix | | ||
| |-----------------|-------------| | ||
| | `Property does not exist on type` | Add type annotation or null check | | ||
| | `Cannot find module` | Fix import path or add missing file | | ||
| | `Type 'X' is not assignable to 'Y'` | Fix type annotation or add type assertion | | ||
| | `Object is possibly 'undefined'` | Add optional chaining (`?.`) or null check | | ||
| | `Argument of type mismatch` | Fix call site arguments or update type signature | | ||
| | `Circular dependency detected` | Reorder imports (minimum change only) | | ||
| **Step 3 — Apply minimal fixes in order of impact (most errors fixed first)** | ||
| Budget tracking: | ||
| ``` | ||
| Attempt 1/3: Analyze all errors → targeted fix for root cause | ||
| Attempt 2/3: Different approach for remaining errors | ||
| Attempt 3/3: Last minimal change | ||
| Exceeded: STOP. Report to user: | ||
| [Escalation] Cannot resolve error after 3 attempts. | ||
| Error: [exact error message] | ||
| Please advise on how to proceed. | ||
| ``` | ||
| **Hard rule:** When fixing build errors — no refactoring, no architecture changes, no unrelated improvements. Fix only what prevents the build from passing. | ||
| Update `spec/feature/[name]/PLAN.md` after each attempt: `Auto-fix Budget: Max retries: 3 / Used: N` | ||
| Also update `spec/STATE.md` — add blocker info under the feature entry (e.g., `Auto-fix: 2/3 used`) so it persists across agent boundaries. | ||
| ## Checkpoint Protocol | ||
| **`checkpoint:decision`** — implementation direction unclear | ||
| ``` | ||
| [checkpoint:decision] | ||
| Situation: [describe the ambiguity] | ||
| Options: | ||
| A) [option] — [tradeoffs] | ||
| B) [option] — [tradeoffs] | ||
| Which approach should I take? | ||
| ``` | ||
| **`checkpoint:human-verify`** — UI implementation complete, needs visual check | ||
| ``` | ||
| [checkpoint:human-verify] | ||
| UI implementation complete for: [feature/component name] | ||
| Please verify in browser: | ||
| - [ ] [specific thing to check] | ||
| - [ ] [specific thing to check] | ||
| Reply "done" when verified, or describe any issues. | ||
| ``` | ||
| **`checkpoint:auth-gate`** — manual authentication or payment action required | ||
| ``` | ||
| [checkpoint:auth-gate] | ||
| Manual action required: [describe what needs to be done manually] | ||
| This cannot be automated. Please complete the action and reply "done". | ||
| ``` | ||
| ### Checkpoint behavior | ||
| - Checkpoints are **blocking** — the agent waits for user input indefinitely (by design, for safety). | ||
| - `checkpoint:auth-gate` is **never skippable** under any circumstances. | ||
| - `checkpoint:decision` and `checkpoint:human-verify` can be skipped if the user replies "skip" — record the skip in CONTEXT.md and proceed with the default option (option A for decisions, "unverified" for human-verify). | ||
| ## Next.js specific rules | ||
| **Server vs Client Components** | ||
| - Default to Server Components — only add `'use client'` when required | ||
| - Add `'use client'` when the component uses: `useState`, `useEffect`, event handlers, browser APIs, external client libraries | ||
| - Keep `'use client'` boundary as deep (leaf) as possible | ||
| - Never add `'use client'` to layout files unless absolutely necessary | ||
| **Server Actions** | ||
| - Add `'use server'` directive at top of action file or inline | ||
| - Use `revalidatePath()` or `revalidateTag()` after mutations | ||
| - Validate with zod before database operations | ||
| **API Routes (Route Handlers)** | ||
| - Place in `app/api/[route]/route.ts` | ||
| - Export named functions: `GET`, `POST`, `PUT`, `DELETE`, `PATCH` | ||
| - Use `NextResponse.json()` for responses | ||
| **Next.js Pages API (Pages Router)** | ||
| - Place in `pages/api/[route].ts` | ||
| - Export default handler function | ||
| **Import paths** | ||
| - Use `@/` alias for project root imports (verify `tsconfig.json` paths) | ||
| - Never use relative imports that go up more than 2 levels (`../../..`) | ||
| ## Task ordering for Next.js features | ||
| Respect this dependency order when planning task execution: | ||
| 1. Types / interfaces (`types/`) | ||
| 2. Utilities / helpers (`lib/`) | ||
| 3. API calls / Server Actions (`api/`, `actions/`) | ||
| 4. Custom hooks (`hooks/`) | ||
| 5. Base UI components (non-interactive Server Components) | ||
| 6. Client Components (interactive, form handlers) | ||
| 7. Page / layout files (`app/.../page.tsx`) | ||
| ## Design change rule | ||
@@ -396,71 +116,5 @@ | ||
| ## TDD mode integration | ||
| If `spec/TEST_STRATEGY.md` exists with `approach: tdd` AND `spec/feature/[name]/TEST.md` exists: | ||
| - Read TEST.md before starting tasks | ||
| - For each test case in TEST.md, write the test code FIRST (test file with failing tests) | ||
| - Then implement the production code to make the tests pass | ||
| - The planner should have already included "write tests" tasks in PLAN.md when TDD is active | ||
| ## On completion | ||
| 1. Verify all tasks in PLAN.md are checked `[x]` | ||
| 2. **Post-dev test generation** — if `spec/TEST_STRATEGY.md` exists with `approach: post-dev`: | ||
| - Spawn `tester` agent with: | ||
| ``` | ||
| [HANDOFF] | ||
| TO: tester (sonnet) | ||
| TASK: Generate tests for feature "[feature-name]" (post-dev mode) | ||
| DONE-WHEN: | ||
| - TEST.md created in spec/feature/[feature-name]/ | ||
| - Test files created and passing | ||
| MUST-NOT: | ||
| - Modify implementation code | ||
| - Test framework/language behavior instead of business logic | ||
| READS: | ||
| - spec/feature/[feature-name]/spec.md | ||
| - spec/feature/[feature-name]/PLAN.md | ||
| [/HANDOFF] | ||
| ``` | ||
| - Wait for tester to complete before proceeding to verification | ||
| 4. **Check testing requirement** — read the `testing` field from `spec/feature/[name]/spec.md` frontmatter: | ||
| - `testing: required` → proceed to Testing Phase (step 5) | ||
| - `testing: optional` → output advisory: "Tests recommended but not required. Skipping test phase." → skip to step 6 | ||
| - `testing: none` or missing → skip to step 6 | ||
| 5. **Testing Phase** (only when `testing: required` or user requests): | ||
| - Read `spec/rules/testing.md` and `spec/PROJECT.md` `## Testing` for framework/strategy | ||
| - Write tests following the project's testing strategy: | ||
| - Unit tests for business logic (utils, services, hooks with side effects) | ||
| - E2E tests for critical user flows mapped to REQ items in spec.md | ||
| - Run tests: use the command from `package.json` scripts (e.g., `npx vitest run`, `npx jest`, `npx playwright test`) | ||
| - Test failures count toward the shared auto-fix budget | ||
| - After tests pass, continue to step 6 | ||
| 6. Update `spec/STATE.md` — change the feature's phase to `verifying`: `### [feature-name] [verifying]` | ||
| 7. Spawn `verifier` agent via Agent tool — read `verifier:` from `spec/feature/[name]/PLAN.md` `## Model Assignment` for the model to use (typically haiku): | ||
| ``` | ||
| [HANDOFF] | ||
| TO: verifier ({model from PLAN.md}) | ||
| TASK: Verify feature "[feature-name]" implementation | ||
| DONE-WHEN: | ||
| - Level 1-3 all pass | ||
| - Level 4 checkpoint:human-verify presented | ||
| MUST-NOT: | ||
| - Modify any file | ||
| - Skip any verification level | ||
| READS: | ||
| - spec/feature/[feature-name]/PLAN.md | ||
| - spec/feature/[feature-name]/spec.md | ||
| [/HANDOFF] | ||
| ``` | ||
| 8. If verifier reports failure (Level 1-3): | ||
| - Apply the suggested fix (counts toward shared auto-fix budget) | ||
| - Update `spec/feature/[name]/PLAN.md` budget counter | ||
| - Re-spawn `verifier` agent | ||
| - Repeat until passes or budget exhausted | ||
| 9. After verification passes, update `spec/STATE.md`: | ||
| - Change the feature's phase: `### [feature-name] [idle]` | ||
| - Move the feature entry from `## Features` to `## Completed` with date | ||
| 10. Write history entry `spec/feature/[name]/history/YYYY-MM-DD-[description].md` | ||
| - Include key decisions from `spec/feature/[name]/CONTEXT.md` in the history entry | ||
| 11. Reset `spec/feature/[name]/CONTEXT.md` to: `# Context\n\nNo active context.` | ||
| When all tasks are marked `[x]` → read `.claude/agents/lead-engineer-completion.md` for the full completion flow (testing, verification, history entry). | ||
@@ -472,1 +126,9 @@ ## Hard constraints | ||
| - Do not commit directly to main/master | ||
| ## Conditional References | ||
| - `.claude/agents/lead-engineer-team-mode.md` — when PLAN.md contains `## Team Composition` | ||
| - `.claude/agents/lead-engineer-msw-mock.md` — when a task targets `mocks/` files | ||
| - `.claude/agents/lead-engineer-autofix.md` — when a build or type error occurs | ||
| - `.claude/agents/lead-engineer-completion.md` — when a checkpoint is triggered OR all tasks done | ||
| - `spec/rules/_nextjs-ordering.md` — when project is Next.js | ||
| - `spec/rules/_delegation.md` — when spawning sub-agents |
| --- | ||
| name: loop | ||
| description: REQ-level compliance loop. Runs reviewer to check each REQ in spec.md, then spawns lead-engineer to fix only failing REQs, runs a de-sloppify cleanup pass, and repeats until 100% compliance or max iterations. Uses LOOP_NOTES.md to bridge context across iterations. Invoked by the /loop skill. | ||
| description: REQ-level compliance loop. Runs reviewer to check each REQ in spec.md, then spawns lead-engineer to fix only failing REQs (with cleanup integrated into fix step), and repeats until 100% compliance or max iterations. Uses LOOP_NOTES.md to bridge context across iterations. Invoked by the /loop skill. | ||
| tools: Read, Write, Edit, Glob, Grep, Agent | ||
@@ -26,3 +26,3 @@ model: sonnet | ||
| 3. **Read `spec/RULE.md`** and `spec/rules/` — understand constraints | ||
| 3. **Read `spec/rules/_workflow.md`** and `spec/rules/_loop-protocol.md` — understand constraints | ||
@@ -104,2 +104,3 @@ 4. **Check for resume** — read `spec/feature/[name]/LOOP_NOTES.md` if it exists | ||
| - npx tsc --noEmit passes | ||
| - No console.log, commented-out code, or unused imports in changed files | ||
| MUST-NOT: | ||
@@ -123,28 +124,3 @@ - Re-implement passing requirements | ||
| **Step F — De-Sloppify (cleanup pass)** | ||
| **Skip this step** if lead-engineer reported a build failure or auto-fix budget exhaustion in Step E. Only run cleanup when the fix step completed successfully (`tsc --noEmit` passes). | ||
| After lead-engineer completes successfully, spawn lead-engineer again with `model: haiku` (cleanup is mechanical): | ||
| ``` | ||
| [HANDOFF] | ||
| TO: lead-engineer (haiku) | ||
| TASK: Cleanup pass for feature "[name]" — remove slop from recent fix | ||
| DONE-WHEN: | ||
| - No console.log, commented-out code, or unused imports remain in changed files | ||
| - npx tsc --noEmit passes | ||
| MUST-NOT: | ||
| - Add new functionality | ||
| - Remove business logic or change behavior | ||
| - Touch files not changed by the previous fix | ||
| READS: | ||
| - (no spec files needed — review only changed files in working tree) | ||
| [/HANDOFF] | ||
| Remove: tests that verify language/framework behavior, redundant type checks, | ||
| over-defensive error handling, console.log, commented-out code, empty catch blocks, unused imports. | ||
| Keep all business logic tests and code. | ||
| ``` | ||
| **Step G — Update LOOP_NOTES.md** | ||
| **Step F — Update LOOP_NOTES.md** | ||
| Write/update `spec/feature/[name]/LOOP_NOTES.md` with the current iteration's results: | ||
@@ -173,3 +149,3 @@ | ||
| **Step H — Update STATE.md** | ||
| **Step G — Update STATE.md** | ||
| - Increment iteration counter | ||
@@ -187,67 +163,4 @@ - Update `spec/STATE.md` with progress under the feature entry: | ||
| 7. **On success (all REQs pass)** | ||
| 7. **On loop exit** — read `.claude/agents/loop-completion.md` for success (all REQs pass) or exhaustion (max iterations) handling. | ||
| After all REQs pass, run verification (Level 1-3) before declaring completion: | ||
| - Spawn `verifier` agent: | ||
| ``` | ||
| [HANDOFF] | ||
| TO: verifier (haiku) | ||
| TASK: Verify feature "[name]" post-loop implementation | ||
| DONE-WHEN: | ||
| - Level 1-3 all pass | ||
| MUST-NOT: | ||
| - Modify any file | ||
| READS: | ||
| - spec/feature/[name]/PLAN.md | ||
| - spec/feature/[name]/spec.md | ||
| [/HANDOFF] | ||
| ``` | ||
| - If verifier fails and auto-fix budget is still available for this iteration: apply fix and re-verify | ||
| - If verifier fails and auto-fix budget is exhausted: exit with partial success — report: `All REQs passed review but verification failed with budget exhausted. Failing verification: [details]. Manual fix needed.` Update STATE.md to `idle` with failing verification info. | ||
| - Level 4 (human-verify) is optional in `/loop` — ask user: "All REQs pass and Level 1-3 verified. Would you like to do a browser check (Level 4)?" (Level 4 is mandatory in `/dev` flow but optional in `/loop` since the user has already seen the feature iterating.) | ||
| ``` | ||
| [Loop Complete — All REQs Satisfied] | ||
| Feature: [name] | ||
| Iterations: N/5 | ||
| Verification: Level 1-3 passed | ||
| Final status: | ||
| REQ-001: PASS | ||
| REQ-002: PASS | ||
| REQ-003: PASS | ||
| All requirements in spec.md are implemented and verified. | ||
| ``` | ||
| - Update `spec/STATE.md`: | ||
| - Move feature from `## Features` to `## Completed` with date | ||
| - Write history entry to `spec/feature/[name]/history/YYYY-MM-DD-loop-complete.md` | ||
| - Delete `spec/feature/[name]/LOOP_NOTES.md` (no longer needed) | ||
| 8. **On max iterations reached (some REQs still failing)** | ||
| ``` | ||
| [Loop Exhausted — Max Iterations Reached] | ||
| Feature: [name] | ||
| Iterations: 5/5 | ||
| Passing: X/Y REQs | ||
| Still failing: | ||
| REQ-002: [reason from last review] | ||
| REQ-005: [reason from last review] | ||
| Previous attempts summary: | ||
| [condensed history from LOOP_NOTES.md] | ||
| These requirements could not be automatically resolved. | ||
| Manual intervention required. | ||
| ``` | ||
| - Update `spec/STATE.md`: | ||
| - Change the feature's phase: `### [feature-name] [idle]` | ||
| - Add failing REQs info under the feature entry | ||
| - Keep `spec/feature/[name]/LOOP_NOTES.md` intact — it contains valuable failure context for manual debugging | ||
| - Do NOT write a completion history entry (feature is not complete) | ||
| ## Auto-fix budget interaction | ||
@@ -258,3 +171,3 @@ | ||
| - This prevents a single stubborn build error from exhausting the entire loop | ||
| - The de-sloppify pass does NOT count toward the budget (it's a cleanup, not a fix) | ||
| - Cleanup (console.log, commented-out code, unused imports removal) is part of the fix step and does NOT count toward the budget | ||
@@ -266,3 +179,7 @@ ## Hard constraints | ||
| - Always update LOOP_NOTES.md after each iteration — this is the cross-iteration memory | ||
| - De-sloppify must not remove business logic or change behavior — only clean up | ||
| - Do not read: `node_modules/`, `.next/`, `dist/`, `.turbo/` | ||
| ## Conditional References | ||
| - `.claude/agents/loop-completion.md` — when all REQs pass or max iterations reached | ||
| - `spec/rules/_model-routing.md` — when choosing model for spawns | ||
| - `spec/rules/_delegation.md` — when spawning sub-agents |
@@ -21,3 +21,3 @@ --- | ||
| 2. **Read `spec/RULE.md`** — workflow rules (checkpoints, auto-fix budget, prohibited actions) | ||
| 2. **Read `spec/rules/_workflow.md`** — core workflow rules | ||
@@ -47,3 +47,2 @@ 3. **Read all files in `spec/rules/`** — project coding rules. Consider these when planning tasks. | ||
| - Read `spec/PROJECT.md` to determine: framework (App Router / Pages Router / React), architecture pattern, libraries | ||
| - Read `AGENTS.md` in relevant source directories to understand codebase layout before globbing | ||
| - This determines task ordering and file placement | ||
@@ -94,3 +93,3 @@ | ||
| - Single file change only | ||
| - Expected output ~200 lines or less | ||
| - Expected output ≤200 lines | ||
| - No architectural decisions required | ||
@@ -102,35 +101,4 @@ - Low dependency on other tasks | ||
| 8c. **Team Composition (only when MODE: team)** | ||
| 8c. **Team Composition** — when MODE: team, read `.claude/agents/planner-team-mode.md` for team composition rules. | ||
| If the handoff from `/dev` includes `MODE: team`: | ||
| Determine which engineers are needed: | ||
| ``` | ||
| - [db] tasks exist → include db-engineer | ||
| - [ui] tasks ≥ 2 → include ui-engineer | ||
| - [ui] tasks = 1 → lead handles it directly (no ui-engineer) | ||
| - [worker] tasks → NOT included in Team Composition (always subagent) | ||
| - lead-engineer → always included | ||
| ``` | ||
| Add `## Team Composition` section to PLAN.md: | ||
| ```markdown | ||
| ## Team Composition | ||
| Mode: team | ||
| Engineers: | ||
| - lead-engineer (sonnet) — tasks: [numbers] | ||
| - db-engineer (sonnet) — tasks: [numbers] | ||
| - ui-engineer (sonnet) — tasks: [numbers] | ||
| Workers (subagent): | ||
| - worker-engineer (haiku) — tasks: [numbers] | ||
| Task Dependencies: | ||
| - Task N [tag] → Task M [tag] | ||
| ``` | ||
| If MODE is not `team` (solo mode): | ||
| - Still tag tasks with `[worker]` where applicable (lead will spawn worker subagents) | ||
| - Do NOT add `## Team Composition` section | ||
| - Other domain tags (`[lead]`, `[db]`, `[ui]`) are optional in solo mode but can be included for clarity | ||
| 8d. **Write `spec/feature/[name]/PLAN.md`** | ||
@@ -177,52 +145,9 @@ | ||
| After creating the task list, decide which model each agent should use. | ||
| Refer to `spec/RULE.md` **Model Routing** for criteria. Write the result in `## Model Assignment`. | ||
| Read `spec/rules/_model-routing.md` for criteria. Write the result in PLAN.md `## Model Assignment`. | ||
| **Decision rules:** | ||
| - `lead-engineer`: If the plan has ≤3 lead tasks, all single-file changes, and no checkpoint conditions → `haiku`. Otherwise → `sonnet`. | ||
| - `db-engineer`: If ≤2 DB tasks, all single-file changes → `haiku`. Otherwise → `sonnet`. | ||
| - `ui-engineer`: If ≤2 UI tasks, all single-file changes → `haiku`. Otherwise → `sonnet`. | ||
| - `worker-engineer`: Always `haiku` (fixed). | ||
| - `verifier`: Always `haiku` (pattern matching, grep, file existence checks). | ||
| ## Task ordering | ||
| Only include model assignments for engineers that will actually be used: | ||
| - Solo mode: only `lead-engineer`, `worker-engineer` (if worker tasks exist), and `verifier` | ||
| - Team mode: all applicable engineers | ||
| For Next.js projects, read `spec/rules/_nextjs-ordering.md` for dependency layers and checkpoint guidance. | ||
| For task-to-file mapping: each task maps to 1-3 files maximum with exact paths. | ||
| The `/dev` skill and lead-engineer agent will read these values when spawning agents. | ||
| ## Task ordering for Next.js projects | ||
| Order tasks following these dependency layers: | ||
| | Layer | Files | Notes | | ||
| |-------|-------|-------| | ||
| | 0. Mock Setup | `mocks/server.ts`, `mocks/browser.ts`, `mocks/index.ts` | Only when `mock: true` AND `mocks/` dir does not exist. One-time MSW infrastructure. | | ||
| | 1. Types | `types/`, `[feature]/types/` | Define interfaces first | | ||
| | 2. Utilities | `lib/`, `[feature]/utils/` | Pure functions, no side effects | | ||
| | 2.5 Mock Handlers | `mocks/handlers/[feature].ts`, `mocks/fixtures/[feature].ts` | Only when `mock: true`. Generate from `## API Contracts` in spec.md. | | ||
| | 3. API / Server Actions | `api/`, `actions.ts` | Server-side data access | | ||
| | 4. Hooks | `hooks/`, `[feature]/hooks/` | Client-side data access | | ||
| | 5. Base Components | `components/`, Server Components | Non-interactive UI | | ||
| | 6. Client Components | Interactive UI with `'use client'` | Forms, event handlers | | ||
| | 7. Page / Layout | `app/.../page.tsx`, `layout.tsx` | Wire everything together | | ||
| **Next.js App Router considerations:** | ||
| - Mark tasks that require `'use client'` (hooks, event handlers, browser APIs) | ||
| - Mark tasks that are Server Actions (`'use server'`) | ||
| **When to insert `checkpoint:decision`:** | ||
| - Server vs Client Component choice is unclear: a component needs both hooks/events and async data fetching | ||
| - Modifying `layout.tsx`: affects all child routes — confirm side effects before proceeding | ||
| - Modifying shared code (`components/`, `shared/`, `lib/`): may impact other features | ||
| - Existing type structure needs breaking changes: affects downstream consumers | ||
| **When to insert `checkpoint:human-verify`:** | ||
| - Only for **intermediate** UI milestones where feedback is needed before continuing (e.g., a base layout must be confirmed before building child components on top of it) | ||
| - Do NOT insert `checkpoint:human-verify` after the **final** UI task — the verifier's Level 4 already requests browser verification at the end of `/dev`. Adding one here would cause the user to verify the same thing twice. | ||
| **Task file mapping** | ||
| - Each task maps to 1–3 files maximum | ||
| - Include exact target file paths (e.g., `features/auth/components/LoginForm.tsx`) | ||
| 9. **Present plan to user** | ||
@@ -261,7 +186,2 @@ - Show the full PLAN.md content | ||
| ## Checkpoint types | ||
| - `checkpoint:decision` — implementation direction unclear; stop and present options | ||
| - `checkpoint:human-verify` — UI work complete; stop and ask user to verify in browser | ||
| - `checkpoint:auth-gate` — manual auth/payment action required; always stop | ||
| ## Hard constraints | ||
@@ -273,1 +193,6 @@ - Never start implementation before user confirms the plan | ||
| - Task Dependencies must explicitly list cross-engineer dependencies (e.g., `Task 5 [lead] → Task 2 [db]`) | ||
| ## Conditional References | ||
| - `.claude/agents/planner-team-mode.md` — when MODE: team | ||
| - `spec/rules/_nextjs-ordering.md` — when project is Next.js | ||
| - `spec/rules/_delegation.md` — when spawning lead-engineer |
| --- | ||
| name: rule-writer | ||
| description: Creates or updates project coding rules in spec/rules/. Each rule is a separate markdown file. Never modifies source code or spec/RULE.md. Invoked by the /rule skill. | ||
| description: Creates or updates project coding rules in spec/rules/. Each rule is a separate markdown file. Never modifies source code or spec/rules/_workflow.md. Invoked by the /rule skill. | ||
| tools: Read, Write, Edit, Glob | ||
@@ -10,3 +10,3 @@ model: haiku | ||
| You do NOT modify source code. You do NOT modify `spec/RULE.md` (that file is immutable). | ||
| You do NOT modify source code. You do NOT modify `spec/rules/_*.md` files (they are immutable workflow rules). | ||
@@ -46,3 +46,3 @@ ## Work sequence | ||
| ## Hard constraints | ||
| - Never modify `spec/RULE.md` — it is immutable | ||
| - Never modify `spec/rules/_*.md` files — they are immutable | ||
| - Never modify source code files | ||
@@ -49,0 +49,0 @@ - Rules must be actionable and specific — no vague guidance |
@@ -18,4 +18,4 @@ --- | ||
| 4. **Read `spec/feature/[name]/CONTEXT.md`** — locked decisions are non-negotiable | ||
| 5. **Read `spec/RULE.md`** — workflow rules | ||
| 6. **Read all files in `spec/rules/`** — project coding rules | ||
| 5. **Read `spec/rules/_workflow.md`** — core workflow rules | ||
| 6. **Read `spec/rules/code-style.md`** and any UI/component-related rule files in `spec/rules/` — skip database rule files | ||
| 7. **Read feature `spec.md` and `design.md`** — understand what you are building | ||
@@ -27,3 +27,2 @@ 8. **Load design context** — if `design.md` has a non-empty `figma` URL and Figma MCP is available: | ||
| 9. **Read `spec/PROJECT.md`** — detect UI framework and component library | ||
| 10. **Read `AGENTS.md`** in target directories — understand codebase layout | ||
@@ -97,4 +96,3 @@ ## UI Framework Detection | ||
| 7. Mark task done in PLAN.md: `- [x] Task N` | ||
| 8. **Update `AGENTS.md`** — same rules as lead-engineer | ||
| 9. After completing UI-heavy tasks, prepare `checkpoint:human-verify` items for the lead: | ||
| 8. After completing UI-heavy tasks, prepare `checkpoint:human-verify` items for the lead: | ||
| ``` | ||
@@ -101,0 +99,0 @@ [UI Verify Items] |
| --- | ||
| name: worker-engineer | ||
| description: Haiku-based worker for simple, self-contained tasks (~200 lines). Handles utility functions, type definitions, simple components, config files. Always spawned as a subagent (never as a team member) for token optimization. | ||
| description: Haiku-based worker for simple, self-contained tasks (≤200 lines). Handles utility functions, type definitions, simple components, config files. Always spawned as a subagent (never as a team member) for token optimization. | ||
| tools: Read, Write, Edit, Glob, Bash | ||
@@ -13,6 +13,5 @@ model: haiku | ||
| 1. **Read the task description** from the lead-engineer's spawn prompt — this is your only task | ||
| 2. **Read `spec/RULE.md`** — workflow rules | ||
| 2. **Read `spec/rules/_workflow.md`** — core workflow rules | ||
| 3. **Read all files in `spec/rules/`** — project coding rules | ||
| 4. **Read target files** — if modifying an existing file, read it first | ||
| 5. **Read `AGENTS.md`** — if the target directory has one, read it before starting | ||
@@ -19,0 +18,0 @@ ## Skill scope |
@@ -41,3 +41,3 @@ #!/usr/bin/env bash | ||
| const phase = match[2]; | ||
| if (phase !== "idle") { | ||
| if (phase === "executing" || phase === "looping") { | ||
| features.push(name); | ||
@@ -44,0 +44,0 @@ } |
@@ -45,3 +45,18 @@ #!/usr/bin/env bash | ||
| })); | ||
| return; | ||
| } | ||
| // Advisory: check REQ-NNN format in Requirements section | ||
| const reqMatch = content.split(/^## (?:Requirements|요구사항)/m); | ||
| if (reqMatch.length > 1) { | ||
| const reqSection = reqMatch[1].split(/^## /m)[0] || ""; | ||
| const lines = reqSection.split("\n").filter((l) => l.trim() && !l.startsWith("#")); | ||
| const nonReqLines = lines.filter((l) => !l.trim().match(/^REQ-\d{3}:/)); | ||
| if (nonReqLines.length > 0) { | ||
| console.log(JSON.stringify({ | ||
| decision: "approve", | ||
| reason: "[Advisory] Some lines in ## Requirements do not follow REQ-NNN format. Expected: REQ-001: statement", | ||
| })); | ||
| } | ||
| } | ||
| return; | ||
@@ -48,0 +63,0 @@ } |
@@ -29,7 +29,2 @@ { | ||
| "statusMessage": "Checking security-sensitive changes..." | ||
| }, | ||
| { | ||
| "type": "command", | ||
| "command": "bash .claude/scripts/update-agents-index.sh", | ||
| "statusMessage": "Checking AGENTS.md freshness..." | ||
| } | ||
@@ -36,0 +31,0 @@ ] |
@@ -10,3 +10,3 @@ --- | ||
| Assess task size per `spec/RULE.md` Model Routing rules: | ||
| Assess task size per `spec/rules/_model-routing.md`: | ||
| - If the bug description references a single file or a clear, localized symptom → spawn `debugger` with `model: haiku` | ||
@@ -13,0 +13,0 @@ - If the bug is cross-feature, involves unclear reproduction, or could have multiple root causes → spawn `debugger` with `model: sonnet` |
@@ -10,3 +10,3 @@ --- | ||
| Before spawning agents, assess task size per `spec/RULE.md` Model Routing rules: | ||
| Before spawning agents, assess task size per `spec/rules/_model-routing.md`: | ||
| - **reviewer**: Read spec.md REQ count and count implementation files. If ≤5 REQs AND <5 files → haiku. Otherwise → sonnet. | ||
@@ -13,0 +13,0 @@ - **code-quality-reviewer**: always haiku (static analysis, pattern detection). |
@@ -10,3 +10,3 @@ --- | ||
| Assess task size per `spec/RULE.md` Model Routing rules: | ||
| Assess task size per `spec/rules/_model-routing.md`: | ||
| - If updating an existing spec with minor changes (feature directory already exists, spec.md present) → spawn `spec-writer` with `model: haiku` | ||
@@ -13,0 +13,0 @@ - If creating a new feature spec from scratch → spawn `spec-writer` with `model: sonnet` |
@@ -12,3 +12,3 @@ --- | ||
| Comprehensive performance optimization guide for React and Next.js applications, maintained by Vercel. Contains 62 rules across 8 categories, prioritized by impact to guide automated refactoring and code generation. | ||
| Comprehensive performance optimization guide for React and Next.js applications, maintained by Vercel. Contains 64 rules across 8 categories, prioritized by impact to guide automated refactoring and code generation. | ||
@@ -84,4 +84,6 @@ ## When to Apply | ||
| - `rerender-simple-expression-in-memo` - Avoid memo for simple primitives | ||
| - `rerender-split-combined-hooks` - Split hooks with independent dependencies | ||
| - `rerender-move-effect-to-event` - Put interaction logic in event handlers | ||
| - `rerender-transitions` - Use startTransition for non-urgent updates | ||
| - `rerender-use-deferred-value` - Defer expensive renders to keep input responsive | ||
| - `rerender-use-ref-transient-values` - Use refs for transient frequent values | ||
@@ -88,0 +90,0 @@ - `rerender-no-inline-components` - Don't define components inside components |
@@ -180,6 +180,32 @@ # Command Reference | ||
| ```bash | ||
| agent-browser frame "#iframe" # Switch to iframe | ||
| agent-browser frame "#iframe" # Switch to iframe by CSS selector | ||
| agent-browser frame @e3 # Switch to iframe by element ref | ||
| agent-browser frame main # Back to main frame | ||
| ``` | ||
| ### Iframe support | ||
| Iframes are detected automatically during snapshots. When the main-frame snapshot runs, `Iframe` nodes are resolved and their content is inlined beneath the iframe element in the output (one level of nesting; iframes within iframes are not expanded). | ||
| ```bash | ||
| agent-browser snapshot -i | ||
| # @e3 [Iframe] "payment-frame" | ||
| # @e4 [input] "Card number" | ||
| # @e5 [button] "Pay" | ||
| # Interact directly — refs inside iframes already work | ||
| agent-browser fill @e4 "4111111111111111" | ||
| agent-browser click @e5 | ||
| # Or switch frame context for scoped snapshots | ||
| agent-browser frame @e3 # Switch using element ref | ||
| agent-browser snapshot -i # Snapshot scoped to that iframe | ||
| agent-browser frame main # Return to main frame | ||
| ``` | ||
| The `frame` command accepts: | ||
| - **Element refs** — `frame @e3` resolves the ref to an iframe element | ||
| - **CSS selectors** — `frame "#payment-iframe"` finds the iframe by selector | ||
| - **Frame name/URL** — matches against the browser's frame tree | ||
| ## Dialogs | ||
@@ -186,0 +212,0 @@ |
@@ -165,2 +165,27 @@ # Snapshot and Refs | ||
| ## Iframes | ||
| Snapshots automatically detect and inline iframe content. When the main-frame snapshot runs, each `Iframe` node is resolved and its child accessibility tree is included directly beneath it in the output. Refs assigned to elements inside iframes carry frame context, so interactions like `click`, `fill`, and `type` work without manually switching frames. | ||
| ```bash | ||
| agent-browser snapshot -i | ||
| # @e1 [heading] "Checkout" | ||
| # @e2 [Iframe] "payment-frame" | ||
| # @e3 [input] "Card number" | ||
| # @e4 [input] "Expiry" | ||
| # @e5 [button] "Pay" | ||
| # @e6 [button] "Cancel" | ||
| # Interact with iframe elements directly using their refs | ||
| agent-browser fill @e3 "4111111111111111" | ||
| agent-browser fill @e4 "12/28" | ||
| agent-browser click @e5 | ||
| ``` | ||
| **Key details:** | ||
| - Only one level of iframe nesting is expanded (iframes within iframes are not recursed) | ||
| - Cross-origin iframes that block accessibility tree access are silently skipped | ||
| - Empty iframes or iframes with no interactive content are omitted from the output | ||
| - To scope a snapshot to a single iframe, use `frame @ref` then `snapshot -i` | ||
| ## Troubleshooting | ||
@@ -167,0 +192,0 @@ |
@@ -9,3 +9,3 @@ --- | ||
| The CLI uses Chrome/Chromium via CDP directly. Install via `npm i -g agent-browser`, `brew install agent-browser`, or `cargo install agent-browser`. Run `agent-browser install` to download Chrome. | ||
| The CLI uses Chrome/Chromium via CDP directly. Install via `npm i -g agent-browser`, `brew install agent-browser`, or `cargo install agent-browser`. Run `agent-browser install` to download Chrome. Run `agent-browser upgrade` to update to the latest version. | ||
@@ -151,2 +151,8 @@ ## Core Workflow | ||
| # Network | ||
| agent-browser network requests # Inspect tracked requests | ||
| agent-browser network route "**/api/*" --abort # Block matching requests | ||
| agent-browser network har start # Start HAR recording | ||
| agent-browser network har stop ./capture.har # Stop and save HAR file | ||
| # Viewport & Device Emulation | ||
@@ -180,2 +186,20 @@ agent-browser set viewport 1920 1080 # Set viewport size (default: 1280x720) | ||
| ## Batch Execution | ||
| Execute multiple commands in a single invocation by piping a JSON array of string arrays to `batch`. This avoids per-command process startup overhead when running multi-step workflows. | ||
| ```bash | ||
| echo '[ | ||
| ["open", "https://example.com"], | ||
| ["snapshot", "-i"], | ||
| ["click", "@e1"], | ||
| ["screenshot", "result.png"] | ||
| ]' | agent-browser batch --json | ||
| # Stop on first error | ||
| agent-browser batch --bail < commands.json | ||
| ``` | ||
| Use `batch` when you have a known sequence of commands that don't depend on intermediate output. Use separate commands or `&&` chaining when you need to parse output between steps (e.g., snapshot to discover refs, then interact). | ||
| ## Common Patterns | ||
@@ -251,2 +275,26 @@ | ||
| ### Working with Iframes | ||
| Iframe content is automatically inlined in snapshots. Refs inside iframes carry frame context, so you can interact with them directly. | ||
| ```bash | ||
| agent-browser open https://example.com/checkout | ||
| agent-browser snapshot -i | ||
| # @e1 [heading] "Checkout" | ||
| # @e2 [Iframe] "payment-frame" | ||
| # @e3 [input] "Card number" | ||
| # @e4 [input] "Expiry" | ||
| # @e5 [button] "Pay" | ||
| # Interact directly — no frame switch needed | ||
| agent-browser fill @e3 "4111111111111111" | ||
| agent-browser fill @e4 "12/28" | ||
| agent-browser click @e5 | ||
| # To scope a snapshot to one iframe: | ||
| agent-browser frame @e2 | ||
| agent-browser snapshot -i # Only iframe content | ||
| agent-browser frame main # Return to main frame | ||
| ``` | ||
| ### Data Extraction | ||
@@ -288,2 +336,4 @@ | ||
| Auto-connect discovers Chrome via `DevToolsActivePort`, common debugging ports (9222, 9229), and falls back to a direct WebSocket connection if HTTP-based CDP discovery fails. | ||
| ### Color Scheme (Dark Mode) | ||
@@ -290,0 +340,0 @@ |
@@ -98,3 +98,3 @@ # Repository Structure | ||
| { | ||
| "$schema": "https://v2-8-18-canary-17.turborepo.dev/schema.json", | ||
| "$schema": "https://v2-8-19.turborepo.dev/schema.json", | ||
| "tasks": { | ||
@@ -101,0 +101,0 @@ "build": { |
@@ -76,3 +76,3 @@ # turbo.json Configuration Overview | ||
| { | ||
| "$schema": "https://v2-8-18-canary-17.turborepo.dev/schema.json", | ||
| "$schema": "https://v2-8-19.turborepo.dev/schema.json", | ||
| "globalEnv": ["CI"], | ||
@@ -79,0 +79,0 @@ "globalDependencies": ["tsconfig.json"], |
@@ -115,3 +115,3 @@ # Environment Variable Gotchas | ||
| { | ||
| "$schema": "https://v2-8-18-canary-17.turborepo.dev/schema.json", | ||
| "$schema": "https://v2-8-19.turborepo.dev/schema.json", | ||
| "globalEnv": ["CI", "NODE_ENV", "VERCEL"], | ||
@@ -118,0 +118,0 @@ "globalPassThroughEnv": ["GITHUB_TOKEN", "VERCEL_URL"], |
@@ -83,3 +83,3 @@ # Environment Variables in Turborepo | ||
| { | ||
| "$schema": "https://v2-8-18-canary-17.turborepo.dev/schema.json", | ||
| "$schema": "https://v2-8-19.turborepo.dev/schema.json", | ||
| "globalEnv": ["CI", "NODE_ENV"], | ||
@@ -86,0 +86,0 @@ "globalPassThroughEnv": ["GITHUB_TOKEN", "NPM_TOKEN"], |
@@ -12,3 +12,3 @@ --- | ||
| metadata: | ||
| version: 2.8.18-canary.17 | ||
| version: 2.8.19 | ||
| --- | ||
@@ -726,3 +726,3 @@ | ||
| { | ||
| "$schema": "https://v2-8-18-canary-17.turborepo.dev/schema.json", | ||
| "$schema": "https://v2-8-19.turborepo.dev/schema.json", | ||
| "tasks": { | ||
@@ -729,0 +729,0 @@ "build": { |
@@ -7,3 +7,3 @@ { | ||
| "sourceType": "github", | ||
| "computedHash": "3c1e3549339c98c44c8c75f676f56ebc0adcd4494ec27b7f1851f7c5a7c2deaf" | ||
| "computedHash": "9dcf7342a0a051445137a279855f6ed9b1fb342e46291b799c344ac20e34d409" | ||
| }, | ||
@@ -158,3 +158,3 @@ "analytics-tracking": { | ||
| "sourceType": "github", | ||
| "computedHash": "d7627ca835eecd04fc6bafdf06e43130db197162a57254042d7d59d042faf73b" | ||
| "computedHash": "7ffd0c504279d479f75816b14eb7855ac6de2ae494a97bbe6e43e973ded5dbd9" | ||
| }, | ||
@@ -174,3 +174,3 @@ "ui-ux-pro-max": { | ||
| "sourceType": "github", | ||
| "computedHash": "afeca00ac2f492d88fdd010e73d91719a5b57c564bb4a73325b0bd77e11323ab" | ||
| "computedHash": "c858d2d9023e73edb4e5504868cb0e36313e58fd56af12ef888b43c5634a3c17" | ||
| }, | ||
@@ -177,0 +177,0 @@ "web-design-guidelines": { |
| # FeatureSpec Workflow Rules | ||
| > **This file is immutable.** Do not modify after `/init`. These are FeatureSpec workflow rules, not project coding rules. | ||
| > Project-specific coding rules belong in `spec/rules/`. | ||
| ## Folder Structure | ||
| ``` | ||
| spec/ | ||
| PROJECT.md ← project purpose, tech stack, testing setup | ||
| ARCHITECTURE.md ← feature map, cross-feature dependencies | ||
| RULE.md ← THIS FILE (FeatureSpec workflow rules, immutable) | ||
| STATE.md ← all features and their current phases (multi-feature) | ||
| DEBUG.md ← debug log (created by /debug) | ||
| rules/ ← project coding rules (managed by /rule) | ||
| feature/ | ||
| [name]/ | ||
| spec.md ← what to build | ||
| design.md ← how to build it | ||
| PLAN.md ← WHAT to do — task list, checkpoints, auto-fix budget (planner writes, lead-engineer executes) | ||
| CONTEXT.md ← WHY — locked decisions, constraints, non-negotiables (planner writes, lead-engineer references) | ||
| LOOP_NOTES.md ← cross-iteration context for /loop (created/deleted by loop agent) | ||
| history/ ← change history archive | ||
| ``` | ||
| ## STATE.md Format | ||
| STATE.md tracks multiple features independently. Each feature has its own phase. | ||
| ```markdown | ||
| # State | ||
| Updated: YYYY-MM-DD | ||
| ## Features | ||
| ### [feature-name] [phase] | ||
| Started: YYYY-MM-DD | ||
| ### [feature-name] [phase] | ||
| Started: YYYY-MM-DD | ||
| Loop: 2/5 — 3/5 REQs passing | ||
| ## Completed | ||
| - [feature-name] (YYYY-MM-DD) | ||
| ## Blockers | ||
| - [feature-name]: [blocker description] | ||
| ``` | ||
| Valid phases: `idle`, `planning`, `executing`, `verifying`, `looping` | ||
| **Rules:** | ||
| - Each feature's phase is independent — one feature can be `executing` while another is `idle` | ||
| - When a feature completes, move it from `## Features` to `## Completed` with date | ||
| - Keep `## Features` section clean — remove completed features from it | ||
| - Keep STATE.md under 100 lines — archive old completed entries | ||
| ## Available Skills | ||
| | Skill | Purpose | | ||
| |---|---| | ||
| | `/init` | First-time setup: analyze codebase, populate spec docs | | ||
| | `/spec` | Define or update a feature spec (usage: `/spec [feature-name] [description]`) | | ||
| | `/dev` | Plan → implement → verify a feature. Use `--team` for parallel team mode | | ||
| | `/review` | Check spec compliance | | ||
| | `/status` | Show project status | | ||
| | `/debug` | Systematic bug fixing | | ||
| | `/rule` | Add or update a project coding rule | | ||
| | `/loop` | Force-complete: loop until all REQs in spec.md are satisfied | | ||
| ## Loop Protocol | ||
| `/loop` enforces REQ-level compliance through iterative review → fix → cleanup cycles: | ||
| ``` | ||
| /loop "feature name" | ||
| → reviewer checks each REQ (PASS/FAIL) | ||
| → lead-engineer fixes only failing REQs (with context from previous attempts) | ||
| → de-sloppify: cleanup pass removes unnecessary code/tests | ||
| → update LOOP_NOTES.md with results and next strategy | ||
| → re-review | ||
| → repeat until 100% or max iterations | ||
| ``` | ||
| - Default max iterations: **5** (configurable via `max-iterations` in spec.md frontmatter) | ||
| - Each iteration has its own auto-fix budget of 3 (resets per iteration) | ||
| - Only failing REQs are targeted — passing code is never modified | ||
| - If max iterations reached with failing REQs: stop and report to user | ||
| - Use `/loop` after `/dev` when you want guaranteed spec compliance | ||
| - Resumable: if `/loop` is interrupted, re-running reads LOOP_NOTES.md to continue | ||
| **Cross-iteration context**: `spec/feature/[name]/LOOP_NOTES.md` | ||
| - Updated after each iteration with REQ status, failure analysis, and next strategy | ||
| - Prevents repeating the same failed approach across iterations | ||
| - Deleted on loop completion; kept on exhaustion (useful for manual debugging) | ||
| **De-Sloppify pass**: after each fix, a separate cleanup step removes: | ||
| - Tests that verify language/framework behavior (not business logic) | ||
| - Over-defensive error handling, console.log, commented-out code | ||
| - Does NOT count toward auto-fix budget | ||
| | Phase in STATE.md | Meaning | | ||
| |---|---| | ||
| | `looping` | Loop agent is running review → fix → cleanup cycles | | ||
| ## Team Mode (`/dev --team`) | ||
| When a feature requires work across multiple domains (business logic, database, UI), the user can invoke `/dev feature-name --team` to activate team mode. The planner performs domain analysis and creates a `## Team Composition` section in PLAN.md. The lead-engineer then creates a Claude Code agent team. | ||
| ### Engineer Roles | ||
| | Role | Domain | Spawned when | Model | | ||
| |------|--------|-------------|-------| | ||
| | `lead-engineer` | Types, utils, hooks, API, server actions, page wiring | Always (team leader) | sonnet | | ||
| | `db-engineer` | Schema, migrations, queries, RLS, seed data | Feature has `[db]` tasks | sonnet | | ||
| | `ui-engineer` | Components, styling, animations, responsive design | Feature has 2+ `[ui]` tasks | sonnet | | ||
| | `worker-engineer` | Simple utilities, type defs, config files | Feature has `[worker]` tasks | haiku | | ||
| ### Task Tagging | ||
| The planner tags each task in PLAN.md: `[lead]`, `[db]`, `[ui]`, or `[worker]`. | ||
| - `[worker]`: single-sentence definition, single file, ~200 lines, no architecture decisions | ||
| - Tasks touching the same file must be assigned to the same engineer | ||
| ### Coordination Rules | ||
| - **Lead has authority**: lead-engineer's decisions override all other engineers | ||
| - **Auto-fix budget is centralized**: teammates message lead before fix attempts; lead manages the shared budget (3 total) | ||
| - **No broadcast**: all team communication is point-to-point (lead ↔ teammate) | ||
| - **Worker is always subagent**: worker-engineer is spawned via Agent tool (not as a team member) for token optimization | ||
| - **File conflict prevention**: planner ensures no two engineers modify the same file | ||
| ### Token Optimization | ||
| - `/dev` (solo) uses lead-engineer alone + worker subagents — minimal cost | ||
| - `/dev --team` adds independent context windows per teammate — use only when parallelism justifies the cost | ||
| - Worker is always a subagent (results summarized back) — never a team member | ||
| ## Checkpoint Conditions | ||
| | Type | Condition | Action | | ||
| |---|---|---| | ||
| | `checkpoint:decision` | Implementation direction unclear, existing type structure change required | Present options, wait for user | | ||
| | `checkpoint:human-verify` | UI implementation complete | Request browser verification, wait | | ||
| | `checkpoint:auth-gate` | Payment or auth manual steps required | Always stop, never simulate | | ||
| ## Auto-fix Budget | ||
| Maximum retries: **3** | ||
| - **`/dev` mode**: single shared counter across the entire session. Persists across agent boundaries via feature's PLAN.md `Used: N`. | ||
| - **`/loop` mode**: resets to 0 at the start of each iteration. Each iteration gets its own budget of 3. | ||
| - **`/debug` mode**: 3 attempts per bug. Tracked in DEBUG.md. | ||
| All retries — whether from build errors, type errors, or verifier failures — share the budget within their mode. | ||
| After 3 failed attempts: stop and escalate to user. | ||
| ## Model Routing | ||
| Default model for all agents is **sonnet**. Opus is never used. | ||
| ### Who decides the model | ||
| | Flow | Who decides | How | | ||
| |------|------------|-----| | ||
| | `/dev` | **planner** | Analyzes task size → writes `## Model Assignment` in feature's PLAN.md → dev skill and lead-engineer read it | | ||
| | `/loop` | **loop agent** | Assesses failing REQ count per iteration → chooses model for lead-engineer/reviewer spawns | | ||
| | `/review`, `/spec`, `/debug` | **skill** | Assesses task size before spawning agent | | ||
| | `/status`, `/rule` | **fixed** | Always haiku (frontmatter) | | ||
| | `/init` | **fixed** | Always sonnet (frontmatter) | | ||
| ### Size criteria | ||
| | Size | Criteria | Model | | ||
| |------|----------|-------| | ||
| | **Small** | Single file change, ≤3 tasks, single REQ fix, read-only analysis of <5 files, no checkpoints | `haiku` | | ||
| | **Medium/Large** | Multi-file change, new feature, complex logic, cross-feature impact, >3 tasks, checkpoints present | `sonnet` | | ||
| ### Agent-specific guidance | ||
| | Agent | When to use haiku | | ||
| |-------|-------------------| | ||
| | `planner` | Never — always sonnet (architectural decisions need deeper reasoning) | | ||
| | `lead-engineer` | Planner assigns in PLAN.md: ≤3 simple tasks AND no checkpoint conditions | | ||
| | `db-engineer` | ≤2 DB tasks, all single-file changes | | ||
| | `ui-engineer` | ≤2 UI tasks, all single-file changes | | ||
| | `worker-engineer` | Always haiku (fixed — token optimization for trivial tasks) | | ||
| | `verifier` | Always haiku — pattern matching, grep, file existence checks | | ||
| | `code-quality-reviewer` | Always haiku — static analysis, pattern detection | | ||
| | `reviewer` | Feature has ≤5 REQs AND implementation is <5 files | | ||
| | `spec-writer` | Updating existing spec with minor changes (not new feature) | | ||
| | `debugger` | Single-file bug with clear reproduction steps | | ||
| | `rule-writer` | Always haiku (frontmatter) | | ||
| | `loop` | Never — orchestrates multiple agents, needs sonnet for strategy | | ||
| | `init` | Never — full codebase analysis needs sonnet | | ||
| If unsure, default to sonnet — correctness over cost savings. | ||
| ## Language | ||
| - Default language for all spec documents (spec.md, design.md) is **English** | ||
| - If the user writes instructions in another language, match that language for the generated content | ||
| - Section headers must use one of the accepted formats recognized by `validate-spec.sh`: **English or Korean** | ||
| - Document body text may be written in any language the user prefers | ||
| ## Resume Protocol | ||
| If `/dev` is interrupted (session crash, timeout, context limit), running `/dev` again will resume from where it left off: | ||
| - `spec/STATE.md` tracks each feature's phase independently: `idle` → `planning` → `executing` → `verifying` → `idle` (or `looping` when `/loop` is active) | ||
| - `/dev` reads the target feature's phase from STATE.md and routes to the appropriate agent instead of restarting from scratch | ||
| - Completed tasks (`- [x]`) in the feature's PLAN.md are skipped on resume | ||
| - Auto-fix budget (`Used: N`) in PLAN.md persists across sessions | ||
| | Phase | On `/dev` resume | | ||
| |---|---| | ||
| | `idle` | Fresh start → planner | | ||
| | `planning` | Check feature's PLAN.md status → resume planning or skip to lead-engineer | | ||
| | `executing` | Skip completed tasks → continue from first `- [ ]` | | ||
| | `verifying` | Re-run verifier | | ||
| ## Context Management | ||
| - Lead-engineer marks each task `[x]` in `spec/feature/[name]/PLAN.md` immediately upon completion — this enables resume after interruption | ||
| - On team mode resume: PLAN.md `## Team Composition` auto-detected — only engineers with uncompleted tasks are re-spawned | ||
| - Before long operations, save current state so work is recoverable after context compaction | ||
| - Keep `spec/STATE.md` under 100 lines — archive old entries to feature history | ||
| ## Excluded Paths | ||
| Do not read or analyze these directories: | ||
| - `node_modules/`, `.next/`, `dist/`, `.turbo/`, `.cache/` | ||
| - Binary files, lock files (`package-lock.json`, `pnpm-lock.yaml`) | ||
| ## Verification Protocol | ||
| After every `/dev` completion, the verifier runs automatically with 4 levels: | ||
| | Level | Check | Pass Criteria | | ||
| |---|---|---| | ||
| | 1 — Existence | All planned files exist | Every file in PLAN.md is present | | ||
| | 2 — Substantive | No stubs or placeholders | No TODO, empty bodies, dummy values, `not implemented` patterns | | ||
| | 2b — Tests | Test files exist (if `testing: required`) | Blocking when required; advisory otherwise | | ||
| | 3 — Wired | Components/hooks/APIs connected | Imports exist, endpoints called, state propagates to UI | | ||
| | 4 — Human | Feature actually works | User confirms in browser | | ||
| - Levels 1-3 run automatically; Level 4 triggers `checkpoint:human-verify` | ||
| - Level 2b behavior depends on `spec.md` `testing` frontmatter: `required` = blocking, `optional`/`none` = advisory | ||
| - When `testing: required`, lead-engineer writes tests after implementation and before spawning verifier | ||
| - Verifier failures count toward the shared auto-fix budget (3 retries total) | ||
| - Verifier never modifies code — it only reports | ||
| ## Agent Role Boundaries | ||
| | Agent | Can modify source code | Can modify spec/ docs | Read-only | | ||
| |---|---|---|---| | ||
| | `init` | No | Yes | — | | ||
| | `spec-writer` | No | Yes (spec.md, design.md) | — | | ||
| | `planner` | No | Yes (CONTEXT.md, PLAN.md in feature dir) | — | | ||
| | `lead-engineer` | **Yes** | Partial (STATE.md, feature PLAN.md, history) | — | | ||
| | `db-engineer` | **Yes** (DB files only) | Partial (PLAN.md budget via lead) | — | | ||
| | `ui-engineer` | **Yes** (UI files only) | Partial (PLAN.md budget via lead) | — | | ||
| | `worker-engineer` | **Yes** (assigned file only) | No | — | | ||
| | `verifier` | No | No | **Yes** | | ||
| | `reviewer` | No | No | **Yes** | | ||
| | `code-quality-reviewer` | No | No | **Yes** | | ||
| | `status` | No | No | **Yes** | | ||
| | `debugger` | **Yes** | Yes (DEBUG.md, STATE.md) | — | | ||
| | `rule-writer` | No | Yes (spec/rules/) | — | | ||
| | `loop` | **Yes** (via lead-engineer) | Partial (STATE.md, feature PLAN.md, LOOP_NOTES.md, history) | — | | ||
| - Only `lead-engineer`, `db-engineer`, `ui-engineer`, `worker-engineer`, `debugger`, and `loop` (which spawns lead-engineer) may modify source code | ||
| - `verifier`, `reviewer`, `code-quality-reviewer`, `status` are strictly read-only — they never modify any file | ||
| - `/review` runs `reviewer` (spec compliance) then `code-quality-reviewer` (code quality) sequentially | ||
| - `debugger` shares the same auto-fix budget concept: after 3 failed fix attempts, stop and escalate to user | ||
| ## Agent Responsibility Matrix | ||
| | Domain | Primary Agent | Trigger | Secondary | | ||
| |--------|--------------|---------|-----------| | ||
| | Test execution | `tester` | `/test`, `/review` (if TEST_STRATEGY.md exists) | `lead-engineer` runs tests only for build verification | | ||
| | Test generation | `tester` | post-dev or TDD mode (via lead-engineer) | — | | ||
| | Security audit | `security-reviewer` | `/security`, `/review` (if SECURITY_STRATEGY.md exists) | `code-quality-reviewer` flags obvious hardcoded secrets only | | ||
| | Logging audit | `log-auditor` | `/log`, `/review` (if LOG_STRATEGY.md exists) | — | | ||
| | Code quality | `code-quality-reviewer` | `/review` | — | | ||
| | Spec compliance | `reviewer` | `/review`, `/loop` | — | | ||
| ## Delegation Protocol | ||
| When spawning a sub-agent via the Agent tool, use this format in the prompt: | ||
| ``` | ||
| [HANDOFF] | ||
| TO: agent-name (model) | ||
| TASK: One-line imperative description | ||
| DONE-WHEN: | ||
| - Observable completion criterion 1 | ||
| - Observable completion criterion 2 | ||
| MUST-NOT: | ||
| - Explicit constraint 1 | ||
| - Explicit constraint 2 | ||
| READS: | ||
| - file path the sub-agent must read | ||
| [/HANDOFF] | ||
| ``` | ||
| Rules: | ||
| - DONE-WHEN items must be observable (file exists, test passes, build succeeds) — not subjective | ||
| - MUST-NOT applies only to this specific handoff — agent-level constraints are already in the agent definition | ||
| - READS lists only essential files — do not list files the agent already knows to read from its own instructions | ||
| - Keep each handoff under 15 lines total | ||
| - All agent spawns must use this format — free-form prompts are not allowed | ||
| ## AGENTS.md Navigation Index | ||
| `AGENTS.md` files are per-directory navigation indices in the project source directories. | ||
| Format: | ||
| ```markdown | ||
| # [directory-path]/ | ||
| ## Files | ||
| - FileName.tsx — One-line purpose description. Key exports or props | ||
| - utils.ts — Two-line description if needed | ||
| Helpers for X and Y | ||
| ## Directories | ||
| - sub-dir/ — One-line purpose | ||
| ``` | ||
| Rules: | ||
| - Generated during `/init` for source directories with 3+ files | ||
| - Updated by lead-engineer (or db-engineer/ui-engineer in team mode) when files are created, modified significantly, or deleted | ||
| - Max 300 lines per file — if too many files, group by pattern | ||
| - File entries: 1-2 lines max (name + purpose + key exports/props) | ||
| - Directory entries: 1 line (name + purpose) | ||
| - Cover only direct children — not recursive | ||
| - No frontmatter, no prose — navigation only | ||
| - Target directories: `src/`, `app/`, `components/`, `lib/`, `hooks/`, `features/`, `pages/`, `utils/`, `services/`, and their subdirectories | ||
| - Excluded: `node_modules/`, `.next/`, `dist/`, `.turbo/`, `spec/`, `.claude/` | ||
| - Agents should read `AGENTS.md` before globbing/grepping a directory | ||
| ## Required Document Format | ||
| ### Writing Rules | ||
| Both `spec.md` and `design.md` must follow these rules: | ||
| - Both files must begin with YAML frontmatter (`---`) | ||
| - No inline formatting in document body: `**bold**`, `_italic_`, `` `code` ``, `~~strikethrough~~` are prohibited | ||
| - Requirements use `REQ-NNN: statement` format — no bullet prefix, one declarative statement per line | ||
| - All content must be declarative — no prose, no explanatory sentences | ||
| - Prose is only allowed in `## Purpose`, limited to 1–3 sentences | ||
| ### spec.md | ||
| Frontmatter (required): | ||
| ```yaml | ||
| --- | ||
| feature: [name] | ||
| deps: [feature-name, ...] # features this spec depends on; [] if none | ||
| api: [METHOD /path, ...] # API endpoints this feature depends on or relates to; omit if none | ||
| testing: none # none | optional | required | ||
| --- | ||
| ``` | ||
| `testing` field values: | ||
| - `required`: lead-engineer writes tests after implementation; verifier Level 2b blocks if tests missing | ||
| - `optional`: lead-engineer skips test phase; verifier Level 2b warns but does not block | ||
| - `none`: no test expectations for this feature | ||
| `max-iterations` field (optional): | ||
| - Controls `/loop` max iteration count. Default: 5 if omitted. | ||
| Sections (required): | ||
| ``` | ||
| ## Purpose | ||
| ## Requirements | ||
| ## Behaviors | ||
| ## Out of Scope | ||
| ``` | ||
| ### design.md | ||
| Frontmatter (required): | ||
| ```yaml | ||
| --- | ||
| feature: [name] | ||
| figma: "url or empty string" # "" if UI feature but no Figma link; "N/A" if purely backend | ||
| --- | ||
| ``` | ||
| Sections (required): | ||
| ``` | ||
| ## Components | ||
| ## State | ||
| ## Data Flow | ||
| ## Technical Decisions | ||
| ``` | ||
| - All sections are required; write `N/A` if not applicable | ||
| - Section headers must match exactly (English) or use accepted localized equivalents recognized by `validate-spec.sh` | ||
| ## Plan Approval Protocol | ||
| - PLAN.md (inside the feature directory) must include an `## Approval` section with `Status:` and `Approved-at:` fields | ||
| - Planner must set `Status: pending` on creation and update to `Status: approved` with timestamp only after explicit user confirmation | ||
| - Lead-engineer must verify `Status: approved` before starting any work — if pending or missing, lead-engineer must stop immediately | ||
| ## History Entry Format | ||
| History entries in `spec/feature/[name]/history/` are validated by PostToolUse hook. | ||
| History entries are written **only after verification passes** (all 4 levels). Partial implementations or interrupted sessions do not generate history entries. | ||
| Required: | ||
| - **Filename**: `YYYY-MM-DD-[description].md` | ||
| - **Top-level heading**: `# [Change description]` | ||
| - **Date field**: `Date: YYYY-MM-DD` | ||
| - **Required sections**: `## Reason`, `## Changes`, `## Files Modified` | ||
| - **Optional section**: `## Figma` | ||
| ## Prohibited Actions | ||
| - Do not modify `spec/RULE.md` — this file is immutable after setup | ||
| - Do not modify `spec/feature/[name]/spec.md` or `design.md` during `/dev` without user approval | ||
| - Do not skip `checkpoint:auth-gate` under any circumstances | ||
| - Do not commit directly to main/master |
| #!/usr/bin/env bash | ||
| # NCC — PostToolUse hook: reminds to update AGENTS.md when source files change | ||
| # Advisory only — outputs a reminder, never blocks. | ||
| node -e ' | ||
| const fs = require("fs"); | ||
| const path = require("path"); | ||
| const chunks = []; | ||
| process.stdin.on("data", (c) => chunks.push(c)); | ||
| process.stdin.on("end", () => { | ||
| try { | ||
| const input = JSON.parse(Buffer.concat(chunks).toString()); | ||
| const filePath = (input.tool_input && input.tool_input.file_path) || ""; | ||
| // Skip if no file path | ||
| if (!filePath) return; | ||
| // Skip non-source files | ||
| const sourceExts = [".ts", ".tsx", ".js", ".jsx", ".mts", ".cts"]; | ||
| if (!sourceExts.some((ext) => filePath.endsWith(ext))) return; | ||
| // Skip excluded directories | ||
| const skipDirs = ["node_modules/", ".next/", "dist/", ".turbo/", "spec/", ".claude/"]; | ||
| if (skipDirs.some((d) => filePath.includes(d))) return; | ||
| // Skip AGENTS.md itself | ||
| if (filePath.endsWith("AGENTS.md")) return; | ||
| const dir = path.dirname(filePath); | ||
| const agentsPath = path.join(dir, "AGENTS.md"); | ||
| const fileName = path.basename(filePath); | ||
| // Check if AGENTS.md exists in the same directory | ||
| if (fs.existsSync(agentsPath)) { | ||
| // Check if the file is mentioned in AGENTS.md | ||
| const content = fs.readFileSync(agentsPath, "utf-8"); | ||
| if (!content.includes(fileName)) { | ||
| console.log("[AGENTS.md] " + fileName + " is not listed in " + agentsPath + " — consider updating it."); | ||
| } | ||
| } else { | ||
| // Check if directory has 3+ source files (worth creating AGENTS.md) | ||
| try { | ||
| const files = fs.readdirSync(dir).filter((f) => | ||
| sourceExts.some((ext) => f.endsWith(ext)) | ||
| ); | ||
| if (files.length >= 3) { | ||
| console.log("[AGENTS.md] " + dir + " has " + files.length + " source files but no AGENTS.md — consider creating one."); | ||
| } | ||
| } catch (e) { | ||
| // Directory read failed, skip silently | ||
| } | ||
| } | ||
| } catch (e) { | ||
| // Parse failed, skip silently | ||
| } | ||
| }); | ||
| ' |
| --- | ||
| name: changelog-maintenance | ||
| description: Maintain a clear and informative changelog for software releases. Use when documenting version changes, tracking features, or communicating updates to users. Handles semantic versioning, changelog formats, and release notes. | ||
| metadata: | ||
| tags: changelog, release-notes, versioning, semantic-versioning, documentation | ||
| platforms: Claude, ChatGPT, Gemini | ||
| --- | ||
| # Changelog Maintenance | ||
| ## When to use this skill | ||
| - **Before release**: organize changes before shipping a version | ||
| - **Continuous**: update whenever significant changes occur | ||
| - **Migration guide**: document breaking changes | ||
| ## Instructions | ||
| ### Step 1: Keep a Changelog format | ||
| **CHANGELOG.md**: | ||
| ```markdown | ||
| # Changelog | ||
| All notable changes to this project will be documented in this file. | ||
| The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), | ||
| and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
| ## [Unreleased] | ||
| ### Added | ||
| - New user profile customization options | ||
| - Dark mode support | ||
| ### Changed | ||
| - Improved performance of search feature | ||
| ### Fixed | ||
| - Bug in password reset email | ||
| ## [1.2.0] - 2025-01-15 | ||
| ### Added | ||
| - Two-factor authentication (2FA) | ||
| - Export user data feature (GDPR compliance) | ||
| - API rate limiting | ||
| - Webhook support for order events | ||
| ### Changed | ||
| - Updated UI design for dashboard | ||
| - Improved email templates | ||
| - Database query optimization (40% faster) | ||
| ### Deprecated | ||
| - `GET /api/v1/users/list` (use `GET /api/v2/users` instead) | ||
| ### Removed | ||
| - Legacy authentication method (Basic Auth) | ||
| ### Fixed | ||
| - Memory leak in background job processor | ||
| - CORS issue with Safari browser | ||
| - Timezone bug in date picker | ||
| ### Security | ||
| - Updated dependencies (fixes CVE-2024-12345) | ||
| - Implemented CSRF protection | ||
| - Added helmet.js security headers | ||
| ## [1.1.2] - 2025-01-08 | ||
| ### Fixed | ||
| - Critical bug in payment processing | ||
| - Session timeout issue | ||
| ## [1.1.0] - 2024-12-20 | ||
| ### Added | ||
| - User profile pictures | ||
| - Email notifications | ||
| - Search functionality | ||
| ### Changed | ||
| - Redesigned login page | ||
| - Improved mobile responsiveness | ||
| ## [1.0.0] - 2024-12-01 | ||
| Initial release | ||
| ### Added | ||
| - User registration and authentication | ||
| - Basic profile management | ||
| - Product catalog | ||
| - Shopping cart | ||
| - Order management | ||
| [Unreleased]: https://github.com/username/repo/compare/v1.2.0...HEAD | ||
| [1.2.0]: https://github.com/username/repo/compare/v1.1.2...v1.2.0 | ||
| [1.1.2]: https://github.com/username/repo/compare/v1.1.0...v1.1.2 | ||
| [1.1.0]: https://github.com/username/repo/compare/v1.0.0...v1.1.0 | ||
| [1.0.0]: https://github.com/username/repo/releases/tag/v1.0.0 | ||
| ``` | ||
| ### Step 2: Semantic Versioning | ||
| **Version number**: `MAJOR.MINOR.PATCH` | ||
| ``` | ||
| Given a version number MAJOR.MINOR.PATCH, increment: | ||
| MAJOR (1.0.0 → 2.0.0): Breaking changes | ||
| - API changes break existing code | ||
| - Example: adding required parameters, changing response structure | ||
| MINOR (1.1.0 → 1.2.0): Backward-compatible features | ||
| - Add new features | ||
| - Existing functionality continues to work | ||
| - Example: new API endpoints, optional parameters | ||
| PATCH (1.1.1 → 1.1.2): Backward-compatible bug fixes | ||
| - Bug fixes | ||
| - Security patches | ||
| - Example: fixing memory leaks, fixing typos | ||
| ``` | ||
| **Examples**: | ||
| - `1.0.0` → `1.0.1`: bug fix | ||
| - `1.0.1` → `1.1.0`: new feature | ||
| - `1.1.0` → `2.0.0`: Breaking change | ||
| ### Step 3: Release Notes (user-friendly) | ||
| ```markdown | ||
| # Release Notes v1.2.0 | ||
| **Released**: January 15, 2025 | ||
| ## 🎉 What's New | ||
| ### Two-Factor Authentication | ||
| You can now enable 2FA for enhanced security. Go to Settings > Security to set it up. | ||
|  | ||
| ### Export Your Data | ||
| We've added the ability to export all your data in JSON format. Perfect for backing up or migrating your account. | ||
| ## ✨ Improvements | ||
| - **Faster Search**: Search is now 40% faster thanks to database optimizations | ||
| - **Better Emails**: Redesigned email templates for a cleaner look | ||
| - **Dashboard Refresh**: Updated UI with modern design | ||
| ## 🐛 Bug Fixes | ||
| - Fixed a bug where password reset emails weren't being sent | ||
| - Resolved timezone issues in the date picker | ||
| - Fixed memory leak in background jobs | ||
| ## ⚠️ Breaking Changes | ||
| If you're using our API: | ||
| - **Removed**: Basic Authentication is no longer supported | ||
| - **Migration**: Use JWT tokens instead (see [Auth Guide](docs/auth.md)) | ||
| - **Deprecated**: `GET /api/v1/users/list` | ||
| - **Migration**: Use `GET /api/v2/users` with pagination | ||
| ## 🔒 Security | ||
| - Updated all dependencies to latest versions | ||
| - Added CSRF protection to all forms | ||
| - Implemented security headers with helmet.js | ||
| ## 📝 Full Changelog | ||
| See [CHANGELOG.md](CHANGELOG.md) for complete details. | ||
| --- | ||
| **Upgrade Instructions**: [docs/upgrade-to-v1.2.md](docs/upgrade-to-v1.2.md) | ||
| ``` | ||
| ### Step 4: Breaking Changes migration guide | ||
| ```markdown | ||
| # Migration Guide: v1.x to v2.0 | ||
| ## Breaking Changes | ||
| ### 1. Authentication Method Changed | ||
| **Before** (v1.x): | ||
| \`\`\`javascript | ||
| fetch('/api/users', { | ||
| headers: { | ||
| 'Authorization': 'Basic ' + btoa(username + ':' + password) | ||
| } | ||
| }); | ||
| \`\`\` | ||
| **After** (v2.0): | ||
| \`\`\`javascript | ||
| // 1. Get JWT token | ||
| const { accessToken } = await fetch('/api/auth/login', { | ||
| method: 'POST', | ||
| body: JSON.stringify({ email, password }) | ||
| }).then(r => r.json()); | ||
| // 2. Use token | ||
| fetch('/api/users', { | ||
| headers: { | ||
| 'Authorization': 'Bearer ' + accessToken | ||
| } | ||
| }); | ||
| \`\`\` | ||
| ### 2. User List API Response Format | ||
| **Before** (v1.x): | ||
| \`\`\`json | ||
| { | ||
| "users": [...] | ||
| } | ||
| \`\`\` | ||
| **After** (v2.0): | ||
| \`\`\`json | ||
| { | ||
| "data": [...], | ||
| "pagination": { | ||
| "page": 1, | ||
| "limit": 20, | ||
| "total": 100 | ||
| } | ||
| } | ||
| \`\`\` | ||
| **Migration**: | ||
| \`\`\`javascript | ||
| // v1.x | ||
| const users = response.users; | ||
| // v2.0 | ||
| const users = response.data; | ||
| \`\`\` | ||
| ## Deprecation Timeline | ||
| - v2.0 (Jan 2025): Basic Auth marked as deprecated | ||
| - v2.1 (Feb 2025): Warning logs for Basic Auth usage | ||
| - v2.2 (Mar 2025): Basic Auth removed | ||
| ``` | ||
| ## Output format | ||
| ``` | ||
| CHANGELOG.md # Developer-facing detailed log | ||
| RELEASES.md # User-facing release notes | ||
| docs/migration/ | ||
| ├── v1-to-v2.md # Migration guide | ||
| └── v2-to-v3.md | ||
| ``` | ||
| ## Constraints | ||
| ### Required rules (MUST) | ||
| 1. **Reverse chronological**: latest version at the top | ||
| 2. **Include dates**: ISO 8601 format (YYYY-MM-DD) | ||
| 3. **Categorize entries**: Added, Changed, Fixed, etc. | ||
| ### Prohibited items (MUST NOT) | ||
| 1. **No copying Git logs**: write from the user's perspective | ||
| 2. **Vague wording**: "Bug fixes", "Performance improvements" (be specific) | ||
| ## Best practices | ||
| 1. **Keep a Changelog**: follow the standard format | ||
| 2. **Semantic Versioning**: consistent version management | ||
| 3. **Breaking Changes**: provide a migration guide | ||
| ## References | ||
| - [Keep a Changelog](https://keepachangelog.com/) | ||
| - [Semantic Versioning](https://semver.org/) | ||
| ## Metadata | ||
| ### Version | ||
| - **Current version**: 1.0.0 | ||
| - **Last updated**: 2025-01-01 | ||
| - **Compatible platforms**: Claude, ChatGPT, Gemini | ||
| ### Tags | ||
| `#changelog` `#release-notes` `#versioning` `#semantic-versioning` `#documentation` | ||
| ## Examples | ||
| ### Example 1: Basic usage | ||
| <!-- Add example content here --> | ||
| ### Example 2: Advanced usage | ||
| <!-- Add advanced example content here --> |
Sorry, the diff of this file is not supported yet
| --- | ||
| name: find-skills | ||
| description: Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill. | ||
| --- | ||
| # Find Skills | ||
| This skill helps you discover and install skills from the open agent skills ecosystem. | ||
| ## When to Use This Skill | ||
| Use this skill when the user: | ||
| - Asks "how do I do X" where X might be a common task with an existing skill | ||
| - Says "find a skill for X" or "is there a skill for X" | ||
| - Asks "can you do X" where X is a specialized capability | ||
| - Expresses interest in extending agent capabilities | ||
| - Wants to search for tools, templates, or workflows | ||
| - Mentions they wish they had help with a specific domain (design, testing, deployment, etc.) | ||
| ## What is the Skills CLI? | ||
| The Skills CLI (`npx skills`) is the package manager for the open agent skills ecosystem. Skills are modular packages that extend agent capabilities with specialized knowledge, workflows, and tools. | ||
| **Key commands:** | ||
| - `npx skills find [query]` - Search for skills interactively or by keyword | ||
| - `npx skills add <package>` - Install a skill from GitHub or other sources | ||
| - `npx skills check` - Check for skill updates | ||
| - `npx skills update` - Update all installed skills | ||
| **Browse skills at:** https://skills.sh/ | ||
| ## How to Help Users Find Skills | ||
| ### Step 1: Understand What They Need | ||
| When a user asks for help with something, identify: | ||
| 1. The domain (e.g., React, testing, design, deployment) | ||
| 2. The specific task (e.g., writing tests, creating animations, reviewing PRs) | ||
| 3. Whether this is a common enough task that a skill likely exists | ||
| ### Step 2: Check the Leaderboard First | ||
| Before running a CLI search, check the [skills.sh leaderboard](https://skills.sh/) to see if a well-known skill already exists for the domain. The leaderboard ranks skills by total installs, surfacing the most popular and battle-tested options. | ||
| For example, top skills for web development include: | ||
| - `vercel-labs/agent-skills` — React, Next.js, web design (100K+ installs each) | ||
| - `anthropics/skills` — Frontend design, document processing (100K+ installs) | ||
| ### Step 3: Search for Skills | ||
| If the leaderboard doesn't cover the user's need, run the find command: | ||
| ```bash | ||
| npx skills find [query] | ||
| ``` | ||
| For example: | ||
| - User asks "how do I make my React app faster?" → `npx skills find react performance` | ||
| - User asks "can you help me with PR reviews?" → `npx skills find pr review` | ||
| - User asks "I need to create a changelog" → `npx skills find changelog` | ||
| ### Step 4: Verify Quality Before Recommending | ||
| **Do not recommend a skill based solely on search results.** Always verify: | ||
| 1. **Install count** — Prefer skills with 1K+ installs. Be cautious with anything under 100. | ||
| 2. **Source reputation** — Official sources (`vercel-labs`, `anthropics`, `microsoft`) are more trustworthy than unknown authors. | ||
| 3. **GitHub stars** — Check the source repository. A skill from a repo with <100 stars should be treated with skepticism. | ||
| ### Step 5: Present Options to the User | ||
| When you find relevant skills, present them to the user with: | ||
| 1. The skill name and what it does | ||
| 2. The install count and source | ||
| 3. The install command they can run | ||
| 4. A link to learn more at skills.sh | ||
| Example response: | ||
| ``` | ||
| I found a skill that might help! The "react-best-practices" skill provides | ||
| React and Next.js performance optimization guidelines from Vercel Engineering. | ||
| (185K installs) | ||
| To install it: | ||
| npx skills add vercel-labs/agent-skills@react-best-practices | ||
| Learn more: https://skills.sh/vercel-labs/agent-skills/react-best-practices | ||
| ``` | ||
| ### Step 6: Offer to Install | ||
| If the user wants to proceed, you can install the skill for them: | ||
| ```bash | ||
| npx skills add <owner/repo@skill> -g -y | ||
| ``` | ||
| The `-g` flag installs globally (user-level) and `-y` skips confirmation prompts. | ||
| ## Common Skill Categories | ||
| When searching, consider these common categories: | ||
| | Category | Example Queries | | ||
| | --------------- | ---------------------------------------- | | ||
| | Web Development | react, nextjs, typescript, css, tailwind | | ||
| | Testing | testing, jest, playwright, e2e | | ||
| | DevOps | deploy, docker, kubernetes, ci-cd | | ||
| | Documentation | docs, readme, changelog, api-docs | | ||
| | Code Quality | review, lint, refactor, best-practices | | ||
| | Design | ui, ux, design-system, accessibility | | ||
| | Productivity | workflow, automation, git | | ||
| ## Tips for Effective Searches | ||
| 1. **Use specific keywords**: "react testing" is better than just "testing" | ||
| 2. **Try alternative terms**: If "deploy" doesn't work, try "deployment" or "ci-cd" | ||
| 3. **Check popular sources**: Many skills come from `vercel-labs/agent-skills` or `ComposioHQ/awesome-claude-skills` | ||
| ## When No Skills Are Found | ||
| If no relevant skills exist: | ||
| 1. Acknowledge that no existing skill was found | ||
| 2. Offer to help with the task directly using your general capabilities | ||
| 3. Suggest the user could create their own skill with `npx skills init` | ||
| Example: | ||
| ``` | ||
| I searched for skills related to "xyz" but didn't find any matches. | ||
| I can still help you with this task directly! Would you like me to proceed? | ||
| If this is something you do often, you could create your own skill: | ||
| npx skills init my-xyz-skill | ||
| ``` |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
439
3.05%5982
0.27%297
12.08%7
-12.5%3933695
-0.35%