Agent Introspection & Debugging
Implements a structured self-debugging workflow to identify and resolve AI agent failures like infinite loops or context drift.
This skill provides a systematic framework for Claude to debug its own execution path when it encounters repeated failures, tool loops, or context degradation. Instead of blindly retrying, it follows a rigorous four-phase process—Capture, Diagnosis, Contained Recovery, and Introspection—to analyze root causes, minimize token wastage, and produce human-readable reports. This is particularly useful for complex autonomous tasks where environment mismatches or context overflow might otherwise lead to stalled progress or reasoning breakdown.
Key Features
01Structured Four-Phase Loop: Capture, Diagnosis, Recovery, and Introspection
020 GitHub stars
03Safe Contained Recovery Actions to verify hypotheses before full retries
04Automated Failure Pattern Matching for loops, timeouts, and context overflow
05Context Optimization to prevent reasoning degradation from oversized logs
06Standardized Self-Debug Reports for human oversight and transparency
Use Cases
01Mitigating token burn and reasoning drift during long-running autonomous tasks
02Breaking out of infinite tool-call loops or 'no-exit' observer paths
03Diagnosing environment mismatches such as missing files or stale git branches