wrg32786/aigent-os/learn-from-failure

Claude Code and agent skill by wrg32786/aigent-os

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Convert failures into reusable artifacts and check repetition. Use when analyzing a failure mode or a recurring failure.

Install

npx vskill@latest install wrg32786/aigent-os/learn-from-failure

SKILL.md

The same SKILL.md was published earlier as wrg32786/aigent-os/learn-from-failure.

/learn-from-failure — Convert failure to reusable artifact

When a failure occurs, classify it, check for repetition, and produce a durable artifact that prevents recurrence.

Trigger

/learn-from-failure or /learn-from-failure <failure description>

Use on: "same issue", "happened again", "recurring", "third time", "keeps happening"

Flow

1. Identify failure
  • If argument provided: use it
  • If no argument: ask "What failed?"
2. Classify failure mode
ModeDescriptionExample
routingTask sent to wrong agent/model/toolOpus used for a read-only task
verificationOutput accepted without checking data flowVideo "looked fine" but spec was wrong
toolTool unavailable, broken API, wrong usageGmail MCP auth expired
knowledgeAgent lacked domain knowledgeDidn't know SDK v6 changed type strings
authorityAgent acted outside delegation zonethe AIgent made a Level 3 decision
3. Check for repetition

Read $AIGENT_VAULT/memory/FAILURE_MODES.md. Search for Pattern lines matching the current failure's root cause.

  • 0-1 prior occurrences: Phase 1 — log and monitor
  • 2+ occurrences: Phase 2 — mandatory artifact. A log entry is not enough.
  • 3+ occurrences: The prior artifact failed. Diagnose why and fix or replace it.
4. Log to FAILURE_MODES.md

Append a new entry following the existing format:

markdown
## {YYYY-MM-DD} — {short symptom name}
**Symptom:** {what went wrong, user-visible}
**Verified cause:** {exact mechanism}
**Fix:** {what was done}
**Layer:** {which system layer}
**Pattern:** {one-line category — this is the load-bearing piece for repetition detection}
5. Determine artifact type
Failure modeArtifactTarget
routingSkill description or hookthe skill's SKILL.md description, or .claude/hooks/
verificationChecklist item in doctrineRelevant doctrine note
toolSKILL_GAPS entry + skill specmemory/SKILL_GAPS.md
knowledgeVault note or memory candidateconcepts/ or memory/
authorityFlag to the operatoraigent_authority_matrix.md
6. Create artifact
  • For routing: add 3+ trigger phrases to the skill's description ("Use when ...")
  • For verification: append a concrete, runnable check to the relevant doctrine
  • For tool: log to SKILL_GAPS.md, suggest /skill-hunt if external capability needed
  • For knowledge: write a memory candidate or vault note
  • For authority: surface to the operator with recommendation
7. Output
Failure logged: {classification}
Pattern: {pattern line}
Repeated: {yes/no, count}
Artifact: {type} at {path}

Boundary

Per [[Self-Learning Doctrine]]: a failure logged without an artifact is a false resolution. The ledger grows, the failure recurs, the system learns nothing.

Bounded procedure experiment (fixture only)

A Finding is an observation, not a verified cause or authority to edit a procedure. The fixture mechanics use a declarative grammar and a pinned historical corpus. Freeze the candidate, evidence, corpus, size budgets and rollback before evaluating. Require a passing verdict and a caller-supplied approval bound to the candidate and base. Distinct identity strings are not authenticated review. This proves mechanics on a fixture, not natural-language procedure compliance or live behavior.

Related

  • [[concepts/Self-Learning Doctrine]] — the doctrine this skill implements
  • [[memory/FAILURE_MODES.md]] — the ledger
  • [[concepts/Capability Expansion Doctrine]] — tool failures feed the expansion loop
  • [[Self-Improving CLAUDE.md]] — the broader self-improvement cycle

Security

  • Security scanPassed, 95 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

Repository stars
18
Repository forks
5
7-day trend score
15

Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/wrg32786/aigent-os/learn-from-failure/badge)](https://verified-skill.com/skills/wrg32786/aigent-os/learn-from-failure)

Something wrong with this skill or its page? Tell us.