agentleFS
0xSoftBoi0xSoftBoi/suwappubot/.claude/skills/evolve/SKILL.md

evolve

Skill4 starsChanged 3 months agoApache-2.0View on GitHub

One iteration of the harness self-improvement loop - digest the session journal, pick the single highest-friction pattern, make ONE surgical patch to a harness artifact (CLAUDE.md, a hook, skill, agent, or lessons promotion), pass the lint gate, commit. Run via /loop or a Routine for continuous improvement, or invoke once as /evolve.

43 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use instinct-export, instinct-import and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • TheKREATORSSkill

    instinct-export

    Export instincts from project/global scope to a file

    Also in 4 projects that use this

  • TheKREATORSSkill

    instinct-import

    Import instincts from file or URL into project/global scope

    Also in 4 projects that use this

  • AWSSkill

    map

    Map verified service capabilities against customer-provided control framework and threat model. Produces mapping-results.json, controls-catalog.md, and framework-mapping.md. Supports pluggable frameworks: CCMv4, NIST 800-53, CIS Benchmarks, ISO 27001, etc. Split into 4 focused sub-skills for better accuracy; this skill orchestrates them.

    Also in 5 projects that use this

  • diego-tobalinaSkill

    build-fix

    Fix build and compilation errors systematically. Run when build fails.

    Also in 3 projects that use this

  • launch52-aiSkill

    skill-create

    Create and validate Claude Code skills with proper structure, checklists, and validation scripts. Use when creating a new skill, auditing existing skills, or ensuring skills meet quality standards. Generates complete skill scaffolds with SKILL.md, check scripts, guides, and templates.

    Also in 3 projects that use this

  • qtzx06Skill

    eval

    Evaluate trained YOLO model accuracy with mAP metrics and per-class error analysis. Identifies failure cases for targeted improvement. Use after training.

    Also in 5 projects that use this

  • +1 more from TheKREATORS

The file

We split this skill into the rules it gives an agent

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

  • 0

    Common

    Most of the 37 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    User-stated friction: if this run was invoked with a focus hint (/evolve <hint> — the hint outranks the digest).

    line 27
  2. Distinctive:

    If the digest is empty AND there's no hint and no recidivism: report "no signal, no change" and STOP.

    line 30
  3. Very specific:

    Must print PASS. If you added/changed a hook, also smoke-test it: echo '{}' | python3 .claude/hooks/<hook>.py.

    line 61
  4. Distinctive:

    If the gate fails, fix or revert — never commit a failing harness.

    line 63

“Common” is measured: kept by at least 6 in 10 of the 37 edited versions of this file we could read. “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

/evolve — one self-improvement iteration

Design: docs/harness/self-improving.md (Hermes self-evolution + pi-reflect patterns). Loop shape: evaluate → reflect → patch → verify → commit. One iteration = ONE change. Small surgical diffs beat rewrites; the git log is the audit trail and the rollback mechanism.

1. Evaluate — read the evidence, never guess

python3 scripts/harness/journal_digest.py --days 30
git log --oneline -15 -- .claude/ CLAUDE.md
git log --oneline -- .claude/harness/lessons.md | head -20

Evidence sources, in priority order:

  1. Recurring error buckets in the digest (same failure across 2+ sessions).
  2. Recidivist lessons — a lessons.md section edited 3+ times means prose isn't working; it needs promotion to an enforcing artifact.
  3. Denial-heavy sessions — repeated permission prompts → allowlist candidates for .claude/settings.json permissions.
  4. User-stated friction if this run was invoked with a focus hint (/evolve <hint> — the hint outranks the digest).

If the digest is empty AND there's no hint and no recidivism: report "no signal, no change" and STOP. An evolution loop that edits without evidence is noise.

2. Reflect — pick ONE target and the right artifact type

Match the friction to the artifact that enforces the fix, preferring the most mechanical option (top = strongest):

Friction patternPatch target
Model keeps doing a forbidden/broken thingNew or edited hook in .claude/hooks/ + settings.json
Multi-step procedure keeps going wrongSkill in .claude/skills/<name>/SKILL.md
Wrong specialist/model routingAgent def in .claude/agents/ or routing table in CLAUDE.md
Permission prompt frictionpermissions.allow in .claude/settings.json
Repo fact the model keeps rediscovering.claude/harness/lessons.md ## Facts
Judgment rule with no mechanical enforcementCLAUDE.md (mind the 4000-word budget — merge, don't append)

3. Patch — surgical rules

  • ONE artifact change per iteration (plus its settings.json wiring if a hook).
  • Edits over rewrites. Never restructure a file you're not fixing.
  • New hooks: must exit 0 on any internal error (never break sessions), parse under python3 -c "import ast; ast.parse(open(f).read())", and follow the style of .claude/hooks/session-journal.py.
  • Deleting/evicting: quote what you removed in the commit body.

4. Verify — the gate is not optional

python3 scripts/harness/harness_lint.py

Must print PASS. If you added/changed a hook, also smoke-test it: echo '{}' | python3 .claude/hooks/<hook>.py; echo "exit=$?" → must exit 0. If the gate fails, fix or revert — never commit a failing harness.

5. Commit

HUSKY=0 git add <changed files>
HUSKY=0 git commit -m "harness(evolve): <what changed and which friction it kills>"

Push only if the user asked for it or a Routine/loop invocation says to.

Continuous mode

  • Manual cadence: /loop 1h /evolve (stops when you stop the loop).
  • Scheduled: a Routine/cron firing /evolve weekly is the sane default — the journal needs sessions to accumulate between iterations.
  • Convergence check every ~5 iterations: if recent harness(evolve) commits keep touching the same artifact, the loop is thrashing — stop and surface it to the user instead of patching again.

Output

Reply ≤8 lines: evidence chosen, artifact patched (path), one-line diff summary, lint result, commit hash. If no-change: the one line "no signal, no change."

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.