Skip to content

Self-Improve Code Loop

Runs an autonomous loop that proposes, benchmarks and keeps code changes that raise a target score.

Stars
40,512
Licence
MIT
Files
13 files

What it does

This skill turns the agent into a controller for an automated improvement loop on a code repository. It sets a goal and a benchmark command, then repeatedly researches ideas, writes plans, has agents implement them, runs the benchmark, and keeps the best-scoring changes, recording history and charting progress along the way. Once started, it is designed to run without pausing for user input until a stop condition is met.

Great for

  • Developers who want to automatically tune a codebase against a measurable metric such as test speed or a benchmark score
  • Teams experimenting with evolutionary, tournament-style code search over many iterations
  • Users already set up with the oh-my-claudecode agent framework

Skip it if

  • Repositories you have not reviewed: the loop executes the benchmark command as-is inside the repo, so untrusted code can run on your machine
  • Tasks without a reliable numeric benchmark, since the loop selects winners by score and cannot judge quality otherwise
  • Anyone wanting tight manual control, because the loop is built to run unattended and skip confirmation between iterations

Try asking

  • “Set up a self-improve run to reduce the runtime of my test suite, using pytest duration as the benchmark”
  • “Start a self-improvement loop on this repo with a target of 95% benchmark accuracy and stop after 20 iterations”
  • “Resume the self-improve session on the performance topic and show me the progress chart”
  • “Build a benchmark for this project and validate it before starting the improvement loop”
Step-by-step guide: how to use Self-Improve Code LoopInstall, first run, examples, tips and FAQs

Install in 3 steps

  1. 1

    Download the skill

    The ZIP contains the 13 original files, the MIT licence and an attribution note.

    self-improve.zip
  2. 2

    Add it to your agent

    Claude Code (all projects)

    mkdir -p ~/.claude/skills && unzip self-improve.zip -d ~/.claude/skills/

    Claude Code / Agent SDK (this project only)

    mkdir -p .claude/skills && unzip self-improve.zip -d .claude/skills/

    Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.

  3. 3

    Ask for the task

    No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.

Get better results

  • Review the benchmark command and target repo path carefully before confirming trust, since they will be executed.
  • Start with a small max_iterations value to check behaviour and cost before a long unattended run.
  • Keep the benchmark deterministic and use the sealed_files setting to protect evaluation code from modification.

What's inside

  • data_contracts.md
  • scripts/plot_progress.py
  • scripts/resolve-paths.mjs
  • scripts/validate.sh
  • si-benchmark-builder.md
  • si-goal-clarifier.md
  • si-researcher.md
  • SKILL.md
  • templates/agent-settings.json
  • templates/goal.md
  • templates/harness.md
  • templates/idea.md
  • templates/settings.json

Redistributed unmodified from Yeachan-Heo/oh-my-claudecode under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.