Nov 9, 2026

darwin-skill: Optimize Your Agent Skills the Way You Train Models

A 7k-star skill that scores your SKILL.md files on a 9-dimension rubric, tests each edit with independent judge agents, and keeps only the changes that measurably improve output, reverting the rest.

#tutorial#skill-creation#skill-management

One or two agent skills you can review by hand. Once your SKILL.md folder grows past that, eyeball review stops scaling. darwin-skill is a 7k-star optimizer skill whose README puts the pitch in one line: "Optimize your Agent Skills the way you train models."

Why This Skill Matters

The README's threshold: 10 skills are maintainable by hand, 60+ need a system. Traditional skill review is purely structural — does the frontmatter look right, are the steps numbered, do the paths exist — and "a perfectly formatted skill can still produce terrible output." darwin-skill evaluates both structure and real-world effectiveness, then keeps only the changes that actually improve things.

The core loop is one line: Evaluate → Improve → Test → Human Confirm → Keep or Revert. Repeat. The design is directly inspired by Andrej Karpathy's autoresearch, and version 2.0 absorbed two Microsoft Research papers, SkillLens and SkillOpt — widening the rubric from 8 to 9 dimensions with SkillLens's empirically validated recipe, which the SKILL.md credits with lifting LLM-judge accuracy from 46.4% (near random) to 73.8%. On 2026-06-03, Microsoft's official SkillOpt repo listed darwin-skill as an integration. The README credits 花叔 (Huashu) as the author; the repo sits on the same GitHub account as the huashu-motion skill SkillMap covered earlier.

Installation

npx skills add alchaincyf/darwin-skill

After installing, tell your agent "optimize all skills" or "optimize [skill-name]". The README says it works with any tool that supports the SKILL.md format, naming Claude Code, Codex, OpenClaw, Trae, CodeBuddy, and more as tools that support the format. No GitHub access? The README links a zip download — extract it and place SKILL.md in ~/.claude/skills/darwin-skill/.

Two safety notes from the README before the first run: optimize from inside a git repository, with local skill edits committed or stashed first; and review each checkpoint diff before continuing, especially when a skill touches shell commands, git operations, credentials, local files, or publishing workflows.

Real Workflow: Optimize Every Skill You Maintain

  1. Ask for the run:
optimize all skills
  1. Test prompts come first. For each skill, darwin-skill designs 2-3 typical prompts and saves them to test-prompts.json — the SKILL.md is explicit that without them the live-effectiveness dimension cannot be scored. It shows you the prompts and waits for confirmation before evaluating anything.
  2. Baseline evaluation. Every skill is scored on a 9-dimension rubric totaling 100 points: six structure dimensions (59 points) checked by static analysis, two effectiveness dimensions (35 points), and one meta-skill blacklist dimension (6 points). Effectiveness is measured, not estimated: a sub-agent runs each test prompt twice — once with the skill, once without — and the two outputs are compared.
  3. Then the optimization loop, one dimension per round. Each round finds the dimension with the largest weighted gap (weighted_gap = weight × (10 − score) / 10), makes exactly one targeted edit, commits it, and has independent judge agents compare the before and after versions. Better, keep; worse, git revert — never git reset --hard. A round that gains less than 1 point stops early, and a CHECKPOINT pause shows the diff and the score delta and waits for your confirmation.
  4. This is where the ratchet comes in: scores can only go up. The README's example — a round scoring 75 against a current best of 78 is auto-reverted, and later improvements build from 78. When a skill (or the whole run) finishes, it generates a visual result card as a PNG, randomly picking one of three styles: Warm Swiss, Dark Terminal, or Newspaper.

Real Workflow: Score Your Collection Without Changing It

Ask only for the evaluation:

评估所有skills的质量

(evaluate the quality of all skills) and darwin-skill stops after test-prompt design and baseline scoring — a benchmark of where the collection stands, with no edits. The SKILL.md also documents a history mode that reads and shows past optimization records from results.tsv.

Tips

  • Distrust absolute scores — the skill distrusts them itself. The SKILL.md reports that re-judging the same unchanged text can swing the total by ±8 points, so absolute totals are used only for triage; keep/revert decisions rest on paired before/after comparisons voted by an odd panel of judges, three by default. That refinement is the SKILL.md's v2.1 note; the README's v2.0 section describes two independent judges per round.
  • Expect the rubric to punish vague wording. Actionable Specificity bans hedge phrases like "suggest / could consider / depending on / use judgment / case by case"; Failure Mechanism Encoding wants known failure paths written into the skill, not "be careful" reminders; and the ninth dimension, High-Risk Action Blacklist, requires destructive operations (rm, git reset --hard, force push) to be explicitly forbidden in the skill itself.
  • Real tests are not optional. If dry runs exceed 30% of evaluations, the skill warns that the evaluation is invalid; when sub-agents are unavailable, it degrades to simulated dry runs and marks them dry_run in the log.
  • It will not change what your skills do. The SKILL.md's constraint rules forbid altering a skill's core function and purpose, adding new dependencies, or letting the optimized file exceed 150% of its original size.
  • The README's own numbers: optimizing huashu-gpt-image moved it 80.8 → 91.5 → 91.65 (+10.85, consensus across 6 independent judges), and darwin-skill's self-eval went 86.05 → 92.05 → 92.7.

When Not to Use This

The SKILL.md is candid about its own rubric: it identifies gross degradation, but fine-grained quality differences remain untrustworthy, and important decisions need human review. The loop is also deliberately not autonomous — one dimension per round, with pauses between phases — and the README draws that boundary itself, describing Microsoft's SkillOpt as the fully autonomous alternative. Its unit of work is the SKILL.md file: the README positions it for tools that support that format.


See the leaderboard for more skills.