[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-112406":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":14,"stars7d":16,"stars30d":17,"stars90d":15,"forks30d":15,"starsTrendScore":18,"compositeScore":19,"rankGlobal":9,"rankLanguage":9,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":21,"hasPages":21,"topics":23,"createdAt":9,"pushedAt":42,"updatedAt":43,"readmeContent":44,"aiSummary":45,"trendingCount":15,"starSnapshotCount":15,"syncStatus":46,"lastSyncTime":47,"discoverSource":48},112406,"Hill-Climb","Bil0000\u002FHill-Climb","Bil0000","Make your coding agent prove \"done\". Each change is kept only if a locked test or benchmark scores it better. Claude Code and Codex skill.",null,"Python",147,6,61,1,0,9,58,5,54.84,"MIT License",false,"main",[24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41],"agent-skills","ai-agents","ai-coding","autonomous-agents","benchmarking","claude-code","claude-code-plugin","claude-skills","cli","codex","coding-agent","developer-tools","hill-climbing","llm","performance","python","test-automation","testing","2026-11-12 21:08:48","2026-11-23 13:48:12","\u003Cdiv align=\"center\">\n\n# Hill Climb\n\n**Your coding agent says \"done\". Hill Climb makes it prove it.**\n\nGive the agent a goal and a command that scores it. The agent works in small steps.\nEvery step that improves the score is committed. Every other step is undone.\nA step that edits the check is refused.\n\n[![tests](https:\u002F\u002Fgithub.com\u002FBil0000\u002FHill-Climb\u002Factions\u002Fworkflows\u002Ftest.yml\u002Fbadge.svg)](https:\u002F\u002Fgithub.com\u002FBil0000\u002FHill-Climb\u002Factions\u002Fworkflows\u002Ftest.yml)\n![python](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fpython-3.9%2B-blue?style=flat-square)\n![deps](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fdependencies-0-brightgreen?style=flat-square)\n![license](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Flicense-MIT-green?style=flat-square)\n\n**[Install](#install) · [How it works](#how-it-works) · [Any goal](#any-goal-is-a-number) · [Real runs](#real-runs) · [Why not just ask the agent?](#why-not-just-ask-the-agent)**\n\n\u003Cimg src=\"assets\u002Fdemo.svg\" alt=\"A hill climb: the score goes 4 to 0, a step with no gain is undone, a step that breaks an old feature is caught, and an attempt to edit the test is blocked\" width=\"860\">\n\n\u003Csub>Output of \u003Ca href=\"examples\u002Fdemo.sh\">\u003Ccode>examples\u002Fdemo.sh\u003C\u002Fcode>\u003C\u002Fa>, with the commands shortened. Run it yourself.\u003C\u002Fsub>\n\n\u003C\u002Fdiv>\n\n## The problem\n\nYou ask an agent to fix the 12 bugs from an audit. An hour later it says \"all fixed\". Then you find out:\n\n- 3 were \"fixed\" by changing what the test expects.\n- One fix broke a feature that no one asked it to touch.\n- Halfway through, its context was compacted, and it forgot what it already tried. It tried those ideas again.\n- You can't tell which change fixed what, because it is all one big diff.\n\nThe agent was not lying. It had no score, no memory on disk, and nothing to stop it from grading its own work.\n\n## The fix\n\nHill Climb is a skill for agents and a single Python file that keeps the score. The agent changes code. The script decides.\n\n```\nclimb.py try \"cache the parser\"\n```\n\nThat one command does all of this:\n\n1. Checks that no locked file changed (the tests, the benchmark, the fixtures). If one did, it refuses.\n2. Runs your check, all of your checks in parallel, and reads the score.\n3. Runs your guards: the old tests, typecheck, lint. All must still pass.\n4. **Better and safe?** It commits the step, in every repo the climb touches. It commits exactly the code that was scored.\n5. **Worse, equal, or a guard failed?** It resets the tree, in every repo. The bad idea never lands.\n6. Writes the step to a log on disk, with the full output in `last.txt`.\n\nThe branch only ever holds proven steps. One commit per win, with the idea as the message.\n\n## Install\n\n**Claude Code** (plugin):\n\n```\n\u002Fplugin marketplace add Bil0000\u002FHill-Climb\n\u002Fplugin install hill-climb@hill-climb\n```\n\n**Any agent that reads skills** (Claude Code, Codex, and others that use `SKILL.md`):\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FBil0000\u002FHill-Climb.git\nmkdir -p ~\u002F.claude\u002Fskills && cp -R Hill-Climb\u002Fskills\u002Fhill-climb ~\u002F.claude\u002Fskills\u002F   # Claude Code\nmkdir -p ~\u002F.codex\u002Fskills && cp -R Hill-Climb\u002Fskills\u002Fhill-climb ~\u002F.codex\u002Fskills\u002F     # Codex\n```\n\nThen just ask:\n\n```\n\u002Fhill-climb make the test suite 2x faster\n\u002Fhill-climb fix every finding from the billing audit, backend and frontend\n\u002Fhill-climb keep going until every test passes\n```\n\nWith the plugin install, the command is `\u002Fhill-climb:hill-climb`. In Codex, name the skill in your prompt.\n\nThe agent builds the check and climbs. For a big goal, it first shows you a one-screen plan (the \"card\") and waits for you to say **go**. A small goal starts at once.\n\nNeeds Python 3.9+ and git. Nothing else. No packages, no server, no account.\n\n**Update.** Claude Code does not update a plugin from this marketplace by itself. In your shell, run `claude plugin marketplace update hill-climb`, then `claude plugin update hill-climb@hill-climb`, then restart Claude Code. To get new versions on their own, open `\u002Fplugin`, go to **Marketplaces**, pick **hill-climb**, and select **Enable auto-update**. With the copy install, `git pull` the clone and copy `skills\u002Fhill-climb` again. A climb you started on an older version carries on after the update.\n\n## How it works\n\n\u003Cimg src=\"assets\u002Fhow-it-works.svg\" alt=\"How Hill Climb works: the agent writes a check that prints a number, climb.py init locks it, then each small change goes through climb.py try. A better score with passing guards is committed. Anything else is undone. It stops at the bar or when gains stop, with a report of measured numbers.\" width=\"860\">\n\nThe agent never writes a score itself. It never decides that a step \"basically\" passed. The script measures, and the log on disk is the truth.\n\n## Any goal is a number\n\nIf you can write a command that tells you how close you are, you can climb it.\n\n| Goal | The check prints |\n| --- | --- |\n| Fix a bug, build a feature | Failing tests written from the spec |\n| Audit, \"make billing stable\" | Failing tests, one per finding. New finding? Add a test, `relock` |\n| Faster | Milliseconds, or better, a count of the work (queries, round trips) |\n| Smaller | Bytes of the bundle or the image |\n| Port or clone a tool | Outputs that match the real tool, byte for byte |\n| UI, copy, API shape | A score from a panel of model judges with your rubric (`judge.py`) |\n\nNo wrapper scripts needed. Point `--score` at any test runner's output:\n\n```bash\nclimb.py init billing-audit --goal \"every billing finding fixed\" \\\n  --check \"pytest tests\u002Fbilling -q\" \\\n  --check \"cd ..\u002Fweb && npx vitest run billing\" \\\n  --score '(\\d+) failed' --direction min --target 0 \\\n  --repo ..\u002Fweb --guard \"pytest tests\u002Flegacy -q\" \\\n  --lock tests\u002Fbilling --lock ..\u002Fweb\u002Fsrc\u002Fbilling\u002F__tests__\n```\n\nTwo repos, two test suites in parallel, one score. Patterns for pytest, vitest, jest, rspec, unittest, node, cargo, and go are in [`references\u002Fchecks.md`](skills\u002Fhill-climb\u002Freferences\u002Fchecks.md).\n\n## What it catches\n\nAll of these happen in the demo above:\n\n| The agent... | Without Hill Climb | With Hill Climb |\n| --- | --- | --- |\n| tries an idea that makes it worse | stays in the diff unless someone notices | `step 2 undone`, tree reset |\n| fixes 2 bugs and breaks an old feature | ships, found later | `guard failed: test_old`, undone |\n| edits the test so it passes | looks like a win | `Locked files changed`, refused |\n| makes a real fix | mixed into one big diff | `step 4 kept`, its own commit |\n\nAnd over a long run:\n\n| | Without | With |\n| --- | --- | --- |\n| Context compacted, session crashed | Starts over, repeats ideas | `climb.py status` shows the score, trail, and notes. `last.txt` holds the check output |\n| Noisy benchmark | A lucky run counts as a win | `--runs 3 --paired --min-gain 3%` cut lucky wins |\n| Overfitting to the test cases | Invisible | A holdout check the agent never sees |\n| Stuck | Keeps trying the same thing | `PLATEAU` after 5 flat steps, forces a blocker review |\n| \"Is it done?\" | The agent's opinion | `BAR REACHED: 0 meets 0` |\n| Next time, same kind of goal | Build the check again | Saved as a kit, `climb.py reuse` |\n\n## Real runs\n\nSmall trial projects, run by an agent that had only the skill and no help:\n\n| Goal | Result |\n| --- | --- |\n| Audit an orders feature across an API repo and a web repo | 12 failing spec tests → **0**, 2 commits, both repos in step |\n| Make a user lookup faster, same output | 190.5 ms → **0.66 ms**, about **290x**, equivalence guard green |\n| The demo in this README | 4 → **0**, 1 bad idea undone, 1 regression caught, 1 cheat blocked |\n\nThese are small, honest examples, not a benchmark. The value grows with the size of the goal: the more steps, the more there is to undo, guard, and remember.\n\n## Why not just ask the agent?\n\n\"I can tell my agent to run the tests after each change.\"\n\nYou can. Here is what you still don't get:\n\n- **Undo is automatic and complete.** A step that doesn't win is reset in every repo, including new files. Nothing half-done is left behind.\n- **The check is locked.** The script hashes the test files and refuses to score a step that changed them. A weakened test can't sneak in as a win.\n- **Guards protect what you didn't ask about.** The score only measures the goal. Guards make sure the rest still works.\n- **State lives on disk, not in context.** The card, the log, notes, and the last output survive compaction, crashes, and new sessions.\n- **Every win is a separate commit.** You review 19 small commits with clear messages, not one mystery diff.\n- **It knows when to stop.** At the bar, at a plateau, or when the holdout disagrees with the score. Not when the agent feels done.\n\n## Commands\n\n| Command | Does |\n| --- | --- |\n| `init \u003Cname> --goal --check --direction min\\|max` | Baseline, branch, lock, kit |\n| `try \"\u003Cidea>\" [--fix]` | Score the change, keep or undo it |\n| `status` | Score, trail, last steps, PLATEAU or STUCK |\n| `relock [name] --why \"...\"` | Accept a changed check (a new finding, a better test) |\n| `holdout --why \"...\"` | Run the hidden cases |\n| `raise \u003Cbar> --why \"...\"` | Set a harder bar after reaching this one |\n| `review \"\u003Cfound>\"` | Log a blocker review |\n| `budget`, `drop`, `list`, `save`, `kits`, `reuse` | Limits, start over, and reusable check kits |\n\nUseful `init` options: `--repo` (more repos), `--check` (repeat, runs in parallel), `--score '\u003Cregex>'`, `--guard`, `--lock`, `--target 0` or `--target 2x`, `--runs 3 --paired` for noisy timers, `--holdout`, `--max-hours` (soft unless `--hard`).\n\nThe full guide for the agent is [`skills\u002Fhill-climb\u002FSKILL.md`](skills\u002Fhill-climb\u002FSKILL.md).\n\n## Safety\n\n- A climb runs on its own branch, `climb\u002F\u003Cname>`. Your branch is not touched.\n- An undo resets the climb branch and deletes untracked files that git does not ignore. If you work in the same checkout at the same time, run the climb in a separate worktree.\n- `drop` goes back to your branch and keeps the old climb on a renamed branch.\n- Only one command that changes a climb runs at a time in a checkout. An interrupted command that is still running blocks the next one, so two runs never score at once.\n- `init` and `try` refuse to commit a file over 10 MB.\n- A kept step is exactly the code that was scored. If the check or a guard edits a file, like `prettier --write`, the step is refused. New files they write, like reports, are never committed, and deleted unless git ignores them.\n- The lock catches mistakes, not a determined cheat. An agent with a shell can edit anything, so review the branch before you merge it.\n- Locks hash every file name, but not the content of files git ignores, so caches like `.pyc` don't trip them. Don't lock data that git ignores. Put it under `.hill-climb\u002F\u003Cname>\u002F`, where content is always hashed.\n- `judge.py` tells each judge to ignore instructions inside the work it scores. A model judge can still be fooled. Prefer an exact check when one exists.\n- Climb only repos you trust. The check and the guards are shell commands, and the climb state in `.hill-climb\u002F` is read as-is.\n- Nothing is sent anywhere. `judge.py` calls the `claude` or `codex` CLI only if you use model judges.\n\n## Try it\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002FBil0000\u002FHill-Climb.git && bash Hill-Climb\u002Fexamples\u002Fdemo.sh\n```\n\nIt builds a tiny shop in a temp folder, runs a full climb, and deletes it.\n\n## Development\n\n```bash\npython3 tests\u002Ftest_hill_climb.py\n```\n\n44 tests. They run real git repos in temp folders and cover multi-repo commits, rollback, locks, guards, paired timing, holdouts, and kits.\n\n## License\n\nMIT\n","Hill Climb 是一个轻量级代码优化验证框架，用于约束AI编码代理（如Claude Code、Codex）的迭代修改行为，确保每次代码变更必须通过预设测试或基准评分才被保留。其核心采用爬山算法思想：仅接受能提升分数且不破坏既有约束（如测试、类型检查、代码风格）的增量修改；自动拒绝篡改测试逻辑、降低分数或导致守卫失败的变更，并在Git中按步提交可追溯的‘已验证’变更。适用于AI辅助开发中需严格保障正确性与可审计性的场景，如自动化缺陷修复、渐进式重构和LLM驱动的持续集成增强。",2,"2026-11-24 04:43:22","CREATED_QUERY"]