
Use when planning QA, choosing review methods, designing tests, or debugging fails. Triggers on: defects found late, tests pass but production bugs, coverage disputes, review ineffective, spending excessive time debugging.
Use when modifying existing code, improving structure without changing behavior, or deciding between refactor, rewrite, or fix-first.
Decompose user intent through structured brainstorming. Detects underspecification, ambiguity, and false premises through hypothesis-driven questioning. Use when a request is unclear, could have multiple valid interpretations, or critical details are missing.
Standard/Full planning pipeline for plan command. Steps: discover, classify, explore, detail, save, check, confirm, handoff. Use when dispatched from plan command for Medium/Complex tasks. Triggers on 'planning pipeline', 'standard track', 'full track'.
Use when designing routines or classes, reviewing class interfaces, choosing between inheritance and containment, or evaluating routine cohesion. Also trigger when inheritance is used without LSP verification, or when design issues are present despite passing tests
Generate or update docs/code-standards.md by scanning codebase conventions. Produces example-rich standards that help LLMs write consistent code. Use when starting a planning or build task. Triggers on 'code standards', 'codebase scan', 'scan conventions'.
Use when auditing defensive code, designing barricades, choosing assertion vs error handling, or deciding correctness vs robustness strategy. Triggers on: empty catch blocks, missing input validation, assertions with side effects, wrong exception abstraction level, garbage in garbage out mentality, deadline pressure to skip validation, trusted source rationalization.
--- name: performance-optimization description: Use when code is too slow, has performance issues, timeouts, OOM errors, high CPU/memory, or doesn't scale. Triggers on: profiler hot spots, latency complaints, needs optimization, critical path analysis. --- # Skill: performance-optimization ## STOP - Measure First (MANDATORY GATE) **Do not optimize based on intuition -- profile first.** - **Correctness before speed** -- make it work, then make it fast - **<4% of code causes >50% of runtime**
Use when designing routines, stuck on where to start coding, caught in compile-debug loops, or code works but you don't understand why. Triggers on: starting a new coding task
Use when reviewing code, assessing interfaces, during PR review, or evaluating 'is this too complex?' Triggers on: code review, design review, module complexity, interface assessment, PR review, structural analysis.
Use when code has deep nesting (3+ levels), complex conditionals, loop design questions, high cyclomatic complexity (McCabe >10), or callback hell. Symptoms: arrow-shaped code, repeated conditions, confusing loop exits, lengthy if-else chains
Use when applying or selecting a Gang of Four design pattern. Triggers on: design pattern, strategy pattern, factory, observer, decorator, command, adapter, composite, singleton, builder, proxy, facade, template method, state pattern, visitor, refactoring to a pattern, if/else chain on type, subclass explosion, dispatcher, event notification.
Use after implementing code. Triggers on: is it done, ready to commit, verify correctness, did I miss anything, pre-commit check.
Use when designing modules, APIs, or classes before implementation.
Use when code is too complex, has scattered error handling, configuration explosion, or callers doing module work. Triggers on: too complex, simplify, scattered errors, configuration proliferation, verbose error handling
Use when investigating a bug, diagnosing a failure, debugging a flaky test, or tracing the root cause of unexpected behavior. Triggers on: debugging, bug, defect, broken test, flaky test, intermittent failure, root cause, can't reproduce, weird behavior, race condition.
Standard/Full planning pipeline for whiteboarding. Steps: discover, classify, explore, detail, save, check, confirm, handoff. Use when dispatched from whiteboarding command for Medium/Complex tasks. Triggers on 'planning pipeline', 'standard track', 'full track'.
--- name: code-clarity-and-docs description: Use when reviewing code clarity, writing comments, checking documentation accuracy, or auditing AI-facing docs. Triggers on: naming, comments, documentation, README, CLAUDE.md. --- # Code Clarity and Documentation ## STOP - The Obviousness Rule **If a code reviewer says your code is not obvious, it is not obvious** -- regardless of how clear it seems to you. **For new code:** Write comments BEFORE implementation. If the comment is hard to write, f
Use when facing untested legacy code, test harness problems, dependency issues, or time pressure. Triggers on: legacy code, no tests, can't test, afraid to change, need to modify untested code.
Use when designing system architecture, drawing boundaries between business logic and infrastructure, or when changes touch many unrelated files. Triggers on: architecture design, dependency direction, separating business rules from database/UI/frameworks.
Apply visual design principles when building or reviewing UI/frontend code. Based on Design for Hackers by David Kadavy. Use when: choosing fonts, colors, or layout proportions; reviewing designs for visual issues; establishing visual hierarchy; creating color palettes or type scales; adding motion or interaction; making responsive design decisions; building any user-facing interface.