/debugFinds the bug and tells you exactly where it is, not what bugs look like in general.
Category: Coding & Technical
Before / After
Why is my test failing?
/debug Here's the failing test and the code under test: [paste both]
What changes in Claude's response
Claude reads the actual failure mode, traces through the code path that produced it, and points at the exact line. Without /debug, you get 'common reasons tests fail include...'. With it, you get 'line 42 — you're mocking userId as a string but the type is now number after last week's migration'.
When NOT to use /debug
Don't /debug if you haven't pasted the actual error. The code requires concrete failure data — without it, you'll get generic debugging advice and waste your turn.
Codes that stack with /debug
/debug is one of 120 tested prompt prefixes. The full cheat sheet has before/after examples, warnings, combos, and 10 workflow playbooks.
See the full cheat sheet — from $5More Coding & Technical codes
REFACTORCleans up messy code without changing what it does. Tells you what changed and why.
/shipitAdds the production-readiness layer Claude usually skips: error handling, edge cases, types, logging.
ARCHITECTDesigns system structure before any code is written. Forces decisions, doesn't just list options.
/convertRewrites code in another language idiomatically — not transliterated.
AUTOMATETurns a manual process you described in English into a runnable script.