
Agent Introspection Debugging
Teaches an AI agent a structured self-debugging routine for when it is stuck, looping or failing.
- Repository
- affaan-m/ECC
- Stars
- 295,127
- Licence
- MIT
- Files
- 1 file
What it does
When an AI agent gets stuck, for example repeating the same failing command, burning tokens without progress, or drifting from its goal, this skill tells it to stop and follow a four-step routine: record the failure, match it to common failure patterns, make the smallest safe fix, and write a short debugging report. It is a set of instructions for the agent's behaviour, not a separate program that runs in the background. It also tells the agent to escalate to a human when the problem is high-risk or externally blocked.
Great for
- Developers running long autonomous agent sessions that sometimes loop or stall
- Teams who want a consistent written record of how an agent recovered from a failure
- People building their own agent workflows who want a reference pattern for self-diagnosis
Skip it if
- Verifying that code changes work, since the skill points to a separate verification-loop skill for that
- Framework-specific bugs that narrower skills already cover, because the skill says to use those instead
- Anyone expecting it to reset agent memory or change harness settings automatically, since it only describes these actions and the agent must actually perform them with its own tools
Try asking
- “My agent keeps retrying the same npm install command and failing. Use the agent introspection debugging workflow to diagnose it.”
- “The agent has used 80 tool calls without progress on this refactor. Capture the failure and propose a minimal recovery step.”
- “Write a self-debugging report on why the agent got a 429 error and kept retrying.”
Install in 3 steps
- 1
Download the skill
The ZIP contains the 1 original files, the MIT licence and an attribution note.
agent-introspection-debugging.zip - 2
Add it to your agent
Claude Code (all projects)
mkdir -p ~/.claude/skills && unzip agent-introspection-debugging.zip -d ~/.claude/skills/Claude Code / Agent SDK (this project only)
mkdir -p .claude/skills && unzip agent-introspection-debugging.zip -d .claude/skills/Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.
- 3
Ask for the task
No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.
Get better results
- Ask the agent to fill in the failure capture template before it attempts any retry, so the diagnosis is grounded in facts.
- Pair it with verification-loop after any code change, as the skill recommends.
- Review the final debugging report to see whether the failure pattern is worth recording for future sessions.
What's inside
- SKILL.md
Redistributed unmodified from affaan-m/ECC under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.