Debugging Prompts
Use structured prompts to investigate errors, run codebase audits, handle fragile updates safely, and resolve persistent issues systematically.
Use structured prompts to investigate errors, run codebase audits, handle fragile updates safely, and resolve persistent issues systematically.
Building with AI is fast and fun—until something goes wrong. Errors, unexpected behaviors, or "the AI did something weird" moments are part of the process. This guide will help you navigate AI-based debugging workflows in Prototyper.
The Debugging Mindset
Avoid generic prompts like:
Nothing works, fix it!Instead, be specific:
Now the screen has gone blank and I am no longer able to make edits.
Can you check what happened?The more context you provide about what broke and when, the faster you'll get to a solution.
Quick Debugging Steps
- Describe the problem clearly — What did you expect? What happened instead?
- Share the error message — Copy the exact error from console or terminal
- Mention recent changes — What did you do right before it broke?
- Ask for explanation first — Understand the problem before applying fixes
When to Use Each Approach
| Situation | Approach |
|---|---|
| Simple error with clear message | Ask for explanation and fix |
| Complex bug with no obvious cause | Request step-by-step analysis |
| Performance issues | Use performance audit prompt |
| Structural concerns | Run a codebase audit |
| Delicate code changes | Use safe approach prompt |
| Persistent recurring errors | Look for root cause, consider rollback |
Key Principles
Focus on Root Cause
Don't just fix symptoms. Ask "why did this happen?" to prevent the same issue from recurring.
Preserve What Works
When fixing one thing, be explicit about what should stay the same. Don't let fixes introduce new bugs.
Progressive Enhancement
Build features in small, testable increments. If something breaks, you know exactly which step caused it.
Document Your Fixes
After resolving a tough bug, ask: "Summarize what the issue was and how we fixed it." Save this for future reference.