self-healing-agents

self-healing-agents is a skill for Claude Code from itallstartedwithaidea/agent-skills. It costs 27 tokens per session (2,045 once invoked), scanned A, original, MIT.

A design for software agents that detect failures and try to recover from them automatically. An agent is a program that uses models and tools to complete tasks.

In plain words
What is it for?
Use it to plan failure detection, diagnose errors, choose recovery strategies, and validate an agent's results.
Why use it?
It reduces the need for a person to restart or repair an agent when network requests fail, APIs change, or generated results do not match the expected format.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions Claude Code; mentions Codex; mentions Gemini CLI.

Part of the claude-mythos-skills plugin — 10 skills shipped together , and of all-skills

Good fit Use it to plan failure detection, diagnose errors, choose recovery strategies, and validate an agent's results.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/itallstartedwithaidea/agent-skills/self-healing-agents
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add itallstartedwithaidea/agent-skills --skill self-healing-agents
Clone the repo
git clone --depth 1 https://github.com/itallstartedwithaidea/agent-skills

Made for: Claude Code.

Or install claude-mythos-skills, the plugin that ships this one along with the rest of its 10 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for self-healing-agents

README.md
[![agentmods](https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/self-healing-agents/github.svg)](https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/self-healing-agents)
Your own site
<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/self-healing-agents"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/self-healing-agents/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for self-healing-agents

Your own site · 80×15
<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/self-healing-agents"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/self-healing-agents.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 27 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,045 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00027 $0.02045
Opus 5 $0.00014 $0.01022
Sonnet 5 $0.00005 $0.00409
Haiku 4.5 $0.00003 $0.00204

Measured 9d ago against content hash 385c193168e7, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

self-healing-agents scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/claude-mythos/self-healing-agents/SKILL.md · 219 lines

How it starts

The opening of the file, as written. The whole thing — 219 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Self-Healing Agents

Part of Agent Skills™ by googleadsagent.ai™

Description

Self-Healing Agents are autonomous systems that detect their own failure modes and self-correct without human intervention. In production environments, agent failures are not exceptional — they are expected. Network calls timeout, APIs return unexpected schemas, models hallucinate confidently, and tool outputs violate assumptions. The difference between a prototype and a production agent is the ability to recover gracefully from every category of failure.

This skill encodes the self-healing patterns developed for the Buddy™ agent at googleadsagent.ai™, where autonomous Google Ads analysis must complete reliably even when upstream APIs change, rate limits are hit, or model outputs contain structural errors. The system operates on a detect-diagnose-repair cycle that mirrors biological immune responses: identify the pathogen, classify the threat, and deploy the appropriate countermeasure.

Self-healing is not merely retry logic. It encompasses error classification, strategy mutation (retrying with a different approach rather than the same one), fallback model selection, output validation with automatic repair, and graceful degradation when full recovery is impossible. Agents built with these patterns achieve 99%+ task completion rates in production.

Use When

  • Building agents that must operate autonomously without human oversight
  • Tool calls or API integrations are unreliable or subject to rate limits
  • Model outputs must conform to strict schemas and occasionally don't
  • Long-running workflows cannot afford to fail mid-execution
  • You need to maintain SLA commitments for agent-powered features
  • The agent must handle novel error types it hasn't encountered before

How It Works

graph TD
    A[Agent Action] --> B[Output Validation]
    B -->|Valid| C[Continue Execution]
    B -->|Invalid| D[Error Classifier]
    D --> E{Error Type}
    E -->|Transient| F[Retry with Backoff]
    E -->|Structural| G[Mutate Strategy]
    E -->|Model Error| H[Fallback Model]
    E -->|Unrecoverable| I[Graceful Degradation]
    F --> J{Retry Budget Remaining?}
    J -->|Yes| A
    J -->|No| G
    G --> K[Modified Prompt/Approach]
    K --> A
    H --> L[Alternative Model Execution]
    L --> B
    I --> M[Partial Result + Error Report]

Read the full file on GitHub · 219 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 219 lines · 27 tokens per session scan A 385c193168e7

Subscribe to this mod's changes

self-healing-agents is a skill published in the GitHub repository itallstartedwithaidea/agent-skills (37 stars, last pushed 4mo ago), licensed MIT. It adds 27 tokens to every session and 2,045 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories