cursor-debug-bundle
Debug AI suggestion quality, context issues, and code generation problems in Cursor. Triggers on "debug cursor ai", "cursor suggestions wrong", "bad cursor completion", "cursor ai debug", "cursor hallucination".
Best use case
cursor-debug-bundle is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Debug AI suggestion quality, context issues, and code generation problems in Cursor. Triggers on "debug cursor ai", "cursor suggestions wrong", "bad cursor completion", "cursor ai debug", "cursor hallucination".
Teams using cursor-debug-bundle should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/cursor-debug-bundle/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How cursor-debug-bundle Compares
| Feature / Agent | cursor-debug-bundle | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Debug AI suggestion quality, context issues, and code generation problems in Cursor. Triggers on "debug cursor ai", "cursor suggestions wrong", "bad cursor completion", "cursor ai debug", "cursor hallucination".
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
AI Agents for Coding
Browse AI agent skills for coding, debugging, testing, refactoring, code review, and developer workflows across Claude, Cursor, and Codex.
Cursor vs Codex for AI Workflows
Compare Cursor and Codex for AI coding workflows, repository assistance, debugging, refactoring, and reusable developer skills.
SKILL.md Source
# Cursor Debug Bundle Diagnose and fix AI suggestion quality issues in Cursor. Covers why AI generates wrong code, how to improve context, and systematic debugging workflows. ## Diagnostic Framework When AI suggestions are wrong, the cause is almost always one of these: ``` ┌─ Context Problems (80% of issues) ───────────────────────┐ │ 1. Missing context: AI doesn't have the relevant code │ │ 2. Wrong context: AI has stale or irrelevant files │ │ 3. Too much context: context window overflow │ │ 4. No project rules: AI doesn't know your conventions │ └──────────────────────────────────────────────────────────┘ ┌─ Model Problems (15% of issues) ─────────────────────────┐ │ 5. Wrong model for the task │ │ 6. Model hallucinating APIs or patterns │ └──────────────────────────────────────────────────────────┘ ┌─ Prompt Problems (5% of issues) ─────────────────────────┐ │ 7. Ambiguous or vague instructions │ │ 8. Conflicting requirements in prompt │ └──────────────────────────────────────────────────────────┘ ``` ## Debugging by Symptom ### AI Uses Wrong API or Library Version **Symptom:** Generated code uses `React.createClass`, old Express syntax, or deprecated patterns. **Root cause:** Model training data includes old code. No project rules specifying versions. **Fix:** ```yaml # .cursor/rules/stack-versions.mdc --- description: "Tech stack version pinning" globs: "" alwaysApply: true --- # Stack Versions (ALWAYS use these) - React 19 with Server Components (NOT class components) - Next.js 15 App Router (NOT Pages Router) - TypeScript 5.7 strict mode - Prisma 6 (NOT Sequelize or TypeORM) - Tailwind CSS 4 (NOT styled-components) - Node.js 22 (ESM, NOT CommonJS require()) ``` ### AI Generates Code That Doesn't Match Your Patterns **Symptom:** Generated code uses different naming, structure, or patterns than your codebase. **Root cause:** AI does not have your existing code as context. **Fix:** Reference your existing patterns explicitly: ``` @src/api/users/route.ts Create src/api/products/route.ts following the EXACT same patterns: same error handling, same response format, same validation approach. ``` ### AI Hallucinates Non-Existent Functions **Symptom:** AI calls functions or uses imports that do not exist in your project or in the library. **Root cause:** Model confuses similar libraries or invents plausible-sounding APIs. **Fix:** 1. Add `@Docs` context: `@Docs Prisma` gives the AI real API documentation 2. Verify generated imports: run `npm run build` immediately after applying 3. Use `@Files` to show the actual module interface: `@src/lib/database.ts` ### AI Ignores Your Instructions **Symptom:** You ask for one thing, AI does something different. **Root cause:** Context window overflow -- your instructions get pushed out by file contents. **Fix:** 1. Start a **new chat** (Cmd+N) -- conversation history may be using too much context 2. Use fewer `@` references -- each consumes context budget 3. Put instructions at the **end** of the prompt (models attend more to recent text) 4. Use `@Files` instead of `@Codebase` to reduce context volume ### Tab Completion is Repetitive or Wrong **Symptom:** Tab keeps suggesting the same wrong pattern. **Root cause:** Tab has limited context compared to Chat/Composer. **Fix:** 1. Open related files in editor tabs (Tab reads open tabs) 2. Add a comment above your cursor describing what you want 3. Reject bad suggestions with `Esc` (trains the model) 4. If persistently wrong, use Cmd+K inline edit instead ## Systematic Debug Workflow When AI output is consistently wrong: ``` Step 1: Check context - Open Chat, look at context pills at top - Are the right files included? - Are stale files adding noise? Step 2: Check rules - @Cursor Rules in chat -- what rules are active? - Do rules conflict with each other? - Are glob patterns matching the right files? Step 3: Test with minimal context - Start new chat - Add ONLY the most relevant file: @src/the-file.ts - Ask your question with explicit constraints - If this works, the issue was context pollution Step 4: Test with different model - Switch from Sonnet to Opus or GPT-5 - If better model gives better results, the task needs more reasoning power Step 5: Check indexing - Is the codebase indexed? (status bar shows "Indexed") - Is the relevant file excluded by .cursorignore? - Run Cmd+Shift+P > "Cursor: Resync Index" ``` ## Logs and Diagnostics ### Opening Developer Tools `Cmd+Shift+P` > `Developer: Toggle Developer Tools` Check the Console tab for: - API request errors (red) - Context assembly logs - Extension errors ### Verbose Logging Enable verbose output: `Cursor Settings` > search "log level" > set to "Debug" Logs location: - macOS: `~/Library/Application Support/Cursor/logs/` - Linux: `~/.config/Cursor/logs/` ### Reproducing Issues for Bug Reports ``` 1. Note Cursor version: Help > About 2. Note model used (from Chat/Composer header) 3. Copy the exact prompt that produced wrong output 4. Copy the wrong output 5. List active extensions: Cmd+Shift+P > "Extensions: Show Installed" 6. Note if Privacy Mode is on (affects model behavior) 7. Report at forum.cursor.com or github.com/getcursor/cursor/issues ``` ## Enterprise Considerations - **Quality baselines**: Track AI suggestion accuracy over time per team/project - **Model pinning**: If a model update degrades quality, temporarily switch to a different model while reporting - **Rule audits**: Periodically review `.cursor/rules/` for outdated or conflicting rules - **Training**: Ensure team knows the difference between context, model, and prompt issues ## Resources - [Cursor Forum - Troubleshooting](https://forum.cursor.com/c/help) - [Cursor GitHub Issues](https://github.com/getcursor/cursor/issues) - [Context Management Docs](https://docs.cursor.com/context/@-symbols/overview)
Related Skills
exa-debug-bundle
Collect Exa debug evidence for support tickets and troubleshooting. Use when encountering persistent issues, preparing support tickets, or collecting diagnostic information for Exa problems. Trigger with phrases like "exa debug", "exa support bundle", "collect exa logs", "exa diagnostic".
evernote-debug-bundle
Debug Evernote API issues with diagnostic tools and techniques. Use when troubleshooting API calls, inspecting requests/responses, or diagnosing integration problems. Trigger with phrases like "debug evernote", "evernote diagnostic", "troubleshoot evernote", "evernote logs", "inspect evernote".
documenso-debug-bundle
Comprehensive debugging toolkit for Documenso integrations. Use when troubleshooting complex issues, gathering diagnostic information, or creating support tickets for Documenso problems. Trigger with phrases like "debug documenso", "documenso diagnostics", "troubleshoot documenso", "documenso support ticket".
deepgram-debug-bundle
Collect Deepgram debug evidence for support and troubleshooting. Use when preparing support tickets, investigating issues, or collecting diagnostic information for Deepgram problems. Trigger: "deepgram debug", "deepgram support ticket", "collect deepgram logs", "deepgram diagnostic", "deepgram debug bundle".
databricks-debug-bundle
Collect Databricks debug evidence for support tickets and troubleshooting. Use when encountering persistent issues, preparing support tickets, or collecting diagnostic information for Databricks problems. Trigger with phrases like "databricks debug", "databricks support bundle", "collect databricks logs", "databricks diagnostic".
customerio-debug-bundle
Collect Customer.io debug evidence for support tickets. Use when creating support requests, investigating delivery failures, or documenting integration issues. Trigger: "customer.io debug", "customer.io support ticket", "collect customer.io logs", "customer.io diagnostics".
cursor-usage-analytics
Track and analyze Cursor usage metrics via admin dashboard: requests, model usage, team productivity, and cost optimization. Triggers on "cursor analytics", "cursor usage", "cursor metrics", "cursor reporting", "cursor dashboard", "cursor ROI".
cursor-upgrade-migration
Upgrade Cursor versions, migrate from VS Code, and transfer settings between machines. Triggers on "upgrade cursor", "update cursor", "cursor migration", "cursor new version", "vs code to cursor", "cursor changelog".
cursor-team-setup
Set up Cursor for teams: plan selection, member management, shared rules, admin dashboard, and onboarding. Triggers on "cursor team", "cursor organization", "cursor business", "cursor enterprise setup", "cursor admin".
cursor-tab-completion
Master Cursor Tab autocomplete, ghost text, and AI code suggestions. Triggers on "cursor completion", "cursor tab", "cursor suggestions", "cursor autocomplete", "cursor ghost text", "cursor copilot".
cursor-sso-integration
Configure SAML 2.0 and OIDC SSO for Cursor with Okta, Microsoft Entra ID, and Google Workspace. Triggers on "cursor sso", "cursor saml", "cursor oauth", "enterprise cursor auth", "cursor okta", "cursor entra", "cursor scim".
cursor-rules-config
Configure Cursor project rules using .cursor/rules/*.mdc files and legacy .cursorrules. Triggers on "cursorrules", ".cursorrules", "cursor rules", "cursor config", "cursor project settings", ".mdc rules", "project rules".