agentleFS
Arnie016Arnie016/fable-mythos/skills/skill-repair-loop/SKILL.md

skill-repair-loop

Skill0 starsChanged 4 months agoMITView on GitHub

Repairs a Claude Skill after a bad output by identifying the exact failure, patching SKILL.md, and adding a regression test. Use when a skill output is generic, wrong, overhyped, off-format, or fails the user's expectations.

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    If the bad output itself is missing, ask for it.

    line 16
  2. Distinctive:

    Patch minimally: keep it short, make it operational, no vague style adjectives.

    line 29

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill Repair Loop

Mission

Improve a Claude Skill based on a real failed output. Do not rewrite the whole skill unless necessary — patch the smallest instruction that would have prevented the failure.

Required input

  • The current SKILL.md
  • The bad output
  • What was wrong with it (infer from the output if unstated)

If the bad output itself is missing, ask for it. You cannot diagnose a failure you haven't seen — do not repair from a description alone.

Workflow

  1. Classify the failure:
    • Trigger failure — skill didn't fire, or fired wrongly (fix: description)
    • Format failure — wrong sections/structure (fix: output format)
    • Voice failure — generic or off-tone (fix: examples file, not more adjectives)
    • Reasoning failure — wrong angle, bad judgment (fix: workflow step)
    • Overclaiming — invented facts/hype (fix: hard constraint)
    • Missing constraint — did something the skill never forbade
    • Capability gap — the executor model can't follow the instruction as written (fix: simplify it or replace prose with a worked example — do NOT add more prose)
    • Instruction bloat — the skill is so long the model skimmed it (fix: cut)
  2. Locate the single missing or weak instruction responsible.
  3. Patch minimally: keep it short, make it operational, no vague style adjectives. Add an example only if the instruction can't carry the fix alone.
  4. Replay mentally: would the patched skill have produced the right output on the original failing input? If not, the diagnosis is wrong — go back to step 1.
  5. Add one regression test to the skill's evals: input, expected behavior, the failure it prevents.

Output format

Diagnosis

The exact failure and its type.

Minimal patch

The changed lines of SKILL.md, before/after.

Regression test

One new eval case in the repo's JSONL format.

Why this patch works

Two sentences max.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.