debug
Skill1.5k starsChanged 4 days agoMITView on GitHub
Systematic debugging for gemma-macos-tuner: consult `README/` and `README.md` first, pull current library docs via Context7 MCP, parallelize investigation with multiple subagents when stuck, prove fixes before calling success, then capture one consolidated note (e.g. `README/notes/debug-notes.md` via **write-notes**) as the **final** step before ending the session. For extreme cases, delegate a multi-agent audit via the Claude Code CLI. Use when the user invokes **debug**, **use debug**, asks to debug or fix a tricky bug, or work is blocked by unclear failure modes after quick local checks.
We split this skill into the rules it gives an agent
16 rules. 0 are common, 14 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 171 edited versions we read keep these.
14
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 21
CLI multi-agent audit: only for exceptional escalation.
- Distinctive: line 41
Before writing code or deep-diving the stack:
- Distinctive: line 50
When the bug touches specific libraries, CLIs, or cloud products (PyTorch, Transformers, PEFT, librosa, GCP clients, Typer, etc.):
- Distinctive: line 53
Use the Context7 MCP server: resolve the library ID, then fetch focused docs for the API or behavior in question (errors, limits, migration …
- Distinctive: line 55
Prefer Context7 over memory or generic web search for API shape and version-sensitive behavior.
- Distinctive: line 58
If Context7 is unavailable, say so briefly and fall back to official docs in the browser or MCP fetch—do not invent APIs.
- Distinctive: line 70
If the problem is hard, cross-cutting, or you have been going in circles after the reproduce-and-narrow pass (step 3):
- Distinctive: line 75
Ask each for plausible hypotheses ranked by likelihood and concrete next checks (files, logs, experiments)—not generic advice.
- Distinctive: line 84
When you are still stuck after parallel investigation, or the blast radius is high (money, data loss, production):
- Very specific: line 87
Use the Claude Code CLI from the repo root (or the user’s preferred invocation) to run a multi-agent audit over the scoped slice that …
- Distinctive: line 102
Do not say the bug is fixed, resolved, done, or imply victory until there is objective proof the original failure mode is gone: e.g.
- Distinctive: line 107
If you cannot verify yet, state unverified or needs proof and list the exact check still missing.
- Distinctive: line 121
Skip: only when the user explicitly wants no note or the outcome is a trivial obvious one-liner.
- Distinctive: line 130
Leading hypothesis(es): if still open, else root cause summary.
- Distinctive: line 131
If CLI audit was invoked: scope given to Claude Code and what you need back (graded findings, P0 list).
- Very specific: line 150
write-notes: follow write-notes once at the end of the debug session (step 7), after honest verification status.
“Common” is measured: kept by at least 6 in 10 of the 171 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Debug
Purpose
Reduce guesswork and wheel-spinning: README/ and existing notes first,
Context7 when library behavior is uncertain, parallel hypotheses when
stuck, proof before “fixed”, one write-notes pass at session end,
CLI multi-agent audit only for exceptional escalation.
Use When
- The user says debug, use the debug skill, debug this, or equivalent, or the task is clearly bug investigation / root-cause analysis that is stalling.
- Failures involve frameworks, SDKs, or cloud APIs where training data may be stale—Context7 should be used before assuming APIs.
Do Not Use When
- The user only wants a trivial fix with an obvious stack trace and no
doc ambiguity (still skim
README/if the area is known to be finicky). - The task is greenfield feature build with no defect—use normal dev flow.
Workflow (in order)
1. Read repo knowledge first (mandatory)
Before writing code or deep-diving the stack:
- Skim
README/— especiallyREADME/notes/debug-notes.mdand relevant guides underREADME/guides/— for subsystem match (MPS, collators, wizard, BigQuery/GCS paths). Look for known issues, workarounds, and checklists. - Skim
README.mdfor structure, scripts, and links to other docs. UseREADME/skills/when debugging agent/plan routing.
Many answers live here; do not skip this step to “save time.”
2. Context7 MCP (library and platform docs)
When the bug touches specific libraries, CLIs, or cloud products (PyTorch, Transformers, PEFT, librosa, GCP clients, Typer, etc.):
- Use the Context7 MCP server: resolve the library ID, then fetch focused docs for the API or behavior in question (errors, limits, migration notes).
- Prefer Context7 over memory or generic web search for API shape and version-sensitive behavior.
If Context7 is unavailable, say so briefly and fall back to official docs in the browser or MCP fetch—do not invent APIs.
3. Reproduce and narrow
- Confirm minimal repro or the exact request / job / log line that fails.
- State a one-sentence current hypothesis and what evidence would falsify it.
4. Parallel investigation when stuck
If the problem is hard, cross-cutting, or you have been going in circles after the reproduce-and-narrow pass (step 3):
- In one turn, spin up multiple
Tasksubagents withreadonly: trueand narrow charters (e.g. “collator only”, “config/INI only”, “MPS device path only”). - Ask each for plausible hypotheses ranked by likelihood and concrete next checks (files, logs, experiments)—not generic advice.
- Merge overlapping hypotheses; avoid duplicate deep reads of the same file.
When in doubt, parallelize (same posture as audit, but
hypothesis-driven and allowed to propose experiments).
5. Exceptionally frustrating or elusive bugs — CLI + audit
When you are still stuck after parallel investigation, or the blast radius is high (money, data loss, production):
- Use the Claude Code CLI from the repo root (or the user’s preferred
invocation) to run a multi-agent
auditover the scoped slice that matters (paths, feature, or git range). - In the CLI handoff prompt, explicitly attach or cite:
- The relevant files under
README/(and optionalREADME/Guides//README/Notes/if present) (paths or paste key excerpts), - A short symptom + what was already ruled out,
- Instruction to use the
auditskill with multiple readonly subagents and findings-first output.
- The relevant files under
This is for escalation, not first resort—after README/, notes, Context7,
and a fair parallel pass.
6. Prove the fix (before claiming success)
Do not say the bug is fixed, resolved, done, or imply victory until there is objective proof the original failure mode is gone: e.g. failing test passes, manual repro clean, bad log line absent, pipeline green— whatever matches the bug—not because a change ought to work.
If you cannot verify yet, state unverified or needs proof and list the exact check still missing.
7. Write notes once (mandatory last step before ending the session)
After steps 2–6, perform a single notes update using
write-notes (typically appending or restructuring
README/notes/debug-notes.md; consolidate the whole session; do not dribble edits earlier).
- Do not repeatedly open or patch note files while investigating; keep working detail in memory or chat until this step.
- One pass should capture: symptom, repro fingerprint, what was ruled out, root
cause (
TBDif unknown), fix (if any), verification (proven / not proven / not run), pointers to relevant docs. - Skip only when the user explicitly wants no note or the outcome is a trivial obvious one-liner; when in doubt, write once here.
Output expectations
- What was read from
README// notes (document names or paths). - Verification: what proved the fix (or honest unverified / blocked).
- Which notes file(s) were updated in step 7 (or why skipped).
- Whether Context7 was used and for which library/topic.
- Leading hypothesis(es) if still open, else root cause summary.
- If CLI audit was invoked: scope given to Claude Code and what you need back (graded findings, P0 list).
Anti-patterns
- Jumping straight to code changes without
README//README.md. - Assuming API behavior without Context7 or official docs when versions matter.
- Serial thrashing (same file, same guess) instead of parallel charters.
- Calling audit for every small typo—keep escalation proportionate.
- Declaring victory without verification (step 6).
- Patching notes throughout the session instead of one end-of-session pass (step 7).
Relation to other skills
audit: structured repo review; use via CLI escalation when debug skill maxes out.write-notes: followwrite-notesonce at the end of the debug session (step 7), after honest verification status; consolidates the full investigation for the next engineer’s step 1 (preferREADME/notes/debug-notes.mdin this repo unless a different notes layout exists).phase-audit: plan-phase checks—not the same as production debugging.
Other versions192 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 192
- Yeachan-Heo/oh-my-claude-sisyphus★ 40ksame name
- Yeachan-Heo/oh-my-claudecode★ 40ksame name
- anthropics/knowledge-work-plugins★ 34ksame name
- qwibitai/nanoclaw★ 31ksame name
- gavrielc/nanoclaw★ 31ksame name
- nanocoai/nanoclaw★ 31ksame name
- openai/symphony★ 27ksame name
- FalkorDB/FalkorDB★ 11ksame name
- NVIDIA/TensorRT-Model-Optimizer★ 5.5ksame name
- NVIDIA/Model-Optimizer★ 5.5ksame name
182 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
Used alongsideProjects with it also use add-discord, add-slack and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
MicrosoftSkilladd-discord
Add Discord bot channel integration via Chat SDK.
Also in 11 projects that use this
MicrosoftSkilladd-slack
Add Slack channel integration via Chat SDK.
Also in 11 projects that use this
- +10 more from microsoft
In this repository20 other files it gives its agents.
- audit-fix-hardcoreSkill
- audit-fix-loopSkill
- auditSkill
- build-vs-buySkill
- create-planSkill
- create-skillSkill
- deploySkill
- documentationSkill
- elon-muskSkill
- execute-plan-hardcoreSkill
- execute-planSkill
- git-commitSkill
- git-pushSkill
- guide-ingestSkill
- ilya-sutskeverSkill
- markdownSkill
- phase-auditSkill
- research-debuggingSkill
- research-planningSkill
- write-notesSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

