systematic-debugging · dshakes — скилл для Claude Code: отладка
Скилл помогает найти причину сбоя до правки кода, затем внести минимальное исправление и закрепить его тестом. Пригодится при падающих тестах, паниках и неожиданном поведении.
npx skills add dshakes/compass --skill systematic-debugging -a claude-codeЧто делает systematic-debugging
Сначала агент воспроизводит сбой и формулирует проверяемую гипотезу о причине. Затем собирает подтверждения — например, изучает код или добавляет логирование — и только после этого меняет код. Правка должна затрагивать минимум, необходимый для устранения доказанной причины.
После исправления скилл предлагает повторить воспроизведение и запустить соседние тесты, а затем добавить регрессионный тест. Если случай сложный, он может передать его субагенту debugger или команде triage. Без воспроизводимого сбоя этот метод не считает исправление проверенным; несколько правок за раз затруднят поиск причины.
Какие задачи решает
- воспроизвести сбой перед правкой кода
- проверить гипотезу о причине ошибки
- исправить первопричину без лишних изменений
- добавить тест против повторного сбоя
Примеры запросов агенту
- Разберись, почему падает этот тест: сначала воспроизведи сбой и докажи причину.
- Найди причину этой паники, внеси минимальную правку и добавь регрессионный тест.
- Проверь ошибку по шагам и передай сложный случай субагенту
debugger.
Как установить systematic-debugging
1Через Skills CLI (Vercel)
npx skills add dshakes/compass --skill systematic-debugging -a claude-code2Вручную: положить файлы
~/.claude/skills/systematic-debugging/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/systematic-debugging/
1Через Skills CLI (Vercel)
npx skills add dshakes/compass --skill systematic-debugging -a codex2Вручную: положить файлы
.agents/skills/systematic-debugging/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add dshakes/compass --skill systematic-debugging -a cursor2Вручную: положить файлы
.cursor/skills/systematic-debugging/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install dshakes/compass systematic-debugging2Вручную: положить файлы
.github/skills/systematic-debugging/SKILL.md1Через Skills CLI (Vercel)
npx skills add dshakes/compass --skill systematic-debugging -a gemini-cli2Командой платформы
gemini skills install https://github.com/dshakes/compass --path claude/skills/systematic-debuggingВручную: положить файлы
.devin/skills/systematic-debugging/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add dshakes/compass --skill systematic-debugging -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Вопросы о systematic-debugging
Как установить systematic-debugging в Claude Code?
Выполните npx skills add dshakes/compass --skill systematic-debugging -a claude-code. Файл скилла находится по пути ~/.claude/skills/systematic-debugging/SKILL.md.
Что делает systematic-debugging?
Скилл ведёт от воспроизведения ошибки и проверки гипотезы к минимальной правке и регрессионному тесту. Он призывает подтвердить причину до изменения кода.
Когда systematic-debugging передаёт задачу субагенту?
Для сложного случая скилл предлагает делегировать разбор субагенту debugger или команде triage.
Исходный текст
SKILL.md · MIT
---
name: systematic-debugging
description: Use when something is broken — a failing test, panic, stack trace, error log, or wrong behavior whose cause isn't obvious. Reproduce it, form a hypothesis, PROVE the cause before changing code, then make the minimal root-cause fix and guard it with a test. For deep cases, hand off to the debugger subagent.
allowed-tools: Read, Grep, Glob, Bash, Edit
---
# Systematic debugging
Fix the cause, not the symptom — and prove the cause before you touch code.
## The method
1. **Reproduce** — get a reliable, minimal repro (a failing test is ideal). No repro → no fix.
2. **Hypothesize** — one specific, falsifiable guess about the cause ("X is null because Y").
3. **Prove it** — instrument/log/inspect to confirm the hypothesis *before* editing. If the
evidence contradicts it, form a new hypothesis. Don't guess-and-change.
4. **Minimal fix** — change the smallest thing that addresses the proven root cause.
5. **Verify** — re-run the repro; it passes. Run the surrounding tests; nothing regressed.
(See `verification-before-completion`.)
6. **Guard** — add/extend a test that would have caught it, so it can't silently return.
For a nasty one, delegate to the **`debugger`** subagent (or the `triage` command) — it
forms a hypothesis, proves it, and proposes the minimal fix.
## Red flags — you're not debugging, you're flailing
- **Changing code before reproducing** the problem.
- **Fixing the symptom** (swallow the error, bump the timeout) instead of the cause.
- **Several changes at once** — you won't know which one mattered.
- "It went away" with **no explanation of why** — it'll come back.
- Re-running hoping for a different result without changing your hypothesis.
## Done means
Root cause **proven** (not assumed) · minimal fix · repro now green · a regression test
added · no new failures. Anything less is **UNVERIFIED**.
© dshakes · MIT · dshakes/compass
Похожие скиллы
Все скиллы по теме «Тесты и QA» →Сначала — systematic-debugging от других авторов.