failure-recovery

Diagnose AI agent failures and apply targeted recovery solutions.

Updated Feb 10, 2026
One-click install
npx skills add https://github.com/0r0loo/my-claude-code-toolkit --skill failure-recovery-0r0loo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: failure-recovery
Source: https://github.com/0r0loo/my-claude-code-toolkit/tree/main/.claude/skills/FailureRecovery
Command: npx skills add https://github.com/0r0loo/my-claude-code-toolkit --skill failure-recovery-0r0loo

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the inefficiency of simply retrying AI tasks when they fail, by providing a structured protocol for diagnosing the root cause of failure and applying targeted solutions before re-attempting.

Core Features & Use Cases

  • Failure Classification: Identifies common failure types like "Direction Error," "Pattern Mismatch," "Partial Implementation," and "Type/Runtime Errors."
  • Root Cause Analysis: Guides the AI to analyze the discrepancy between expected and actual results.
  • Prescriptive Solutions: Offers specific remedies tailored to each failure type, such as redefining requirements, providing reference files, breaking down tasks, or including error messages and types.
  • Escalation Protocol: Defines clear criteria for when to escalate issues to a human user.
  • Use Case: When an AI-generated code snippet doesn't compile due to a type error, this Skill helps the AI identify the specific error message and relevant types, then guides it to fix the issue before resubmitting.

Quick Start

Use the failure-recovery skill to diagnose and fix the AI's last incorrect output.

Frequently Asked Questions about failure-recovery

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug AI agent failures instead of just retrying the task?

To debug AI agent failures, you need a systematic protocol that classifies the error type, analyzes the root cause, and applies targeted solutions before re-attempting the task.

What is the best way to fix React hydration mismatches generated by AI?

Fixing React hydration mismatches involves classifying the failure as a type or runtime error, analyzing the discrepancy, and applying prescriptive solutions like including relevant types before resubmitting.

How do I resolve NestJS circular dependency errors in AI-generated code?

Resolving NestJS circular dependency errors requires diagnosing the failure type, applying tailored remedies such as providing reference files, and escalating to a human user if the issue repeats.

When should I escalate repeated AI code generation errors to a human?

You should escalate repeated AI code generation errors to a human when the failure recovery protocol identifies complex issues that cannot be resolved through targeted solutions like task breakdown.

Why does my AI code snippet fail to compile due to a type error?

An AI code snippet fails to compile due to a type error when the output has a pattern mismatch; the AI must identify the specific error message and relevant types to fix the issue.

Can I use a failure classification protocol for TypeORM migration failures?

Yes, you can use a failure classification protocol for TypeORM migration failures by identifying the error as a partial implementation and applying targeted solutions before re-attempting.