An agent loop for Claude Code where "done" means proven Claude does
Localix released localix-loop, a free Claude Code plugin that uses an external scorekeeper instead of Claude's judgment to decide when a task is truly done.
By Dillip Chowdary • Dec 02, 2026 • Source: github.com

At a glance
- Product
- localix-loop
- Price
- free
- Requires
- Node.js 20 or newer
- License
- MIT
- Made by
- Localix (small lab, no investors)
- Storage
- git snapshots under refs/localix-loop/
In this post
Localix, a small lab without outside investors, released localix-loop, a free Claude Code plugin that redefines what "done" means in an AI-assisted coding session. Instead of trusting Claude's self-report that a task is finished, the loop runs an external scorekeeper after every change, keeps the change only if the score improved, and rolls back anything that did not.
The plugin targets developers who already use Claude Code and want a tighter quality gate on agentic work — particularly on projects with test suites, build pipelines, or benchmarks. This piece covers the three mechanics that make the loop independent of Claude's judgment, the benchmark and simulation numbers Localix published, and the install steps a developer needs to get started.
01The scorekeeper Claude cannot change
The core idea is that Claude never controls the judge. After every change, a hook with no model in it runs the developer's scorekeeper — a test suite, a build, a benchmark — and keeps the change only if the score went up. The loop ends when the score reaches the target the developer set, not when the model declares success.
On projects with no existing tests, a separate examiner subagent writes them from the developer's goal or spec before any code exists. Claude cannot edit those tests during a run, and hidden checks the model never sees catch code fitted to pass only the visible ones. That separation means a passing score reflects the goal, not Claude's ability to game the measurement.
A third guarantee covers regression. Each new goal in the same project extends the existing test suite rather than replacing it, so a later change cannot quietly break earlier work. Localix calls the gap between "done" and "proven" the expensive round trip: trying the result, finding something off, explaining it, waiting for the fix, and checking the fix broke nothing.
02Install in two commands, Node 20 required
Getting the plugin into Claude Code takes two terminal lines run from any directory, followed by a Claude Code restart:
claude plugin marketplace add localixai/localix-loop
claude plugin install localix-loop@localix-loopAfter the restart, open a git repository — an empty folder needs only git init — and start a session with a goal:
/localix-loop:start make the login test suite passAdvertisement
Tech Pulse Daily
Get tomorrow's pulse first
Join engineers who read Tech Pulse before stand-up. Free, weekday mornings.
Claude finds a scorekeeper or has the examiner write one, shows the baseline score, and waits for the developer to agree before starting. When a session ends, git diff shows the full change and REPORT.md lists what was checked; the developer commits it themselves. The plugin requires Node.js 20 or newer and is released under the MIT license.
03Sonnet 5.5 quality bench, five rounds
Localix ran a quality benchmark that builds one project from an empty folder and changes it five times, scoring each round with an acceptance test no approach sees during the run. Results for Sonnet 5.5, one chain each:
| Approach | Right first time | Correction rounds | Regressions | False "done" |
|---|---|---|---|---|
| one plain prompt | 6 / 6 | 0 | 0 | 0 |
| Claude Code /goal | 5 / 6 | 1 | 0 | 0 |
| localix-loop | 5 / 6 | 1 | 0 | 0 |
| ralph-loop plugin | 3 / 6 | 6 | 0 | 9 |
On this project and model, a plain prompt was correct every time without any loop at all. localix-loop matched the built-in /goal command and never reported done while acceptance was still failing. Its weak point surfaced in the examiner's own tests: across three runs, a wrong test — a date in the wrong time zone, a page test that raced the page — stopped the loop with a correct application rather than declaring success. A wrong test stops the loop; it never passes bad work through.
04Forty simulation runs, six failure modes
To separate what the loop adds from what the model already gets right, Localix built npm run sim: a seeded agent making the same mistakes in the same order through the real judge and without it. No model is involved, and identical seeds produce identical numbers. Accepted / false "done", 40 runs each:
| Agent behavior | Without loop | With localix-loop |
|---|---|---|
| never wrong | 100% / 0% | 100% / 0% |
| wrong a third of the time, runs its tests | 100% / 0% | 100% / 0% |
| breaks what worked, runs tests half the time | 68% / 33% | 100% / 0% |
| fits the visible test | 10% / 90% | 80% / 0% |
| edits a test it keeps failing | 53% / 48% | 98% / 0% |
| says done while seeing failures | 5% / 95% | 100% / 0% |
| all of these, milder | 10% / 90% | 73% / 0% |
Where the agent's own tests would catch the mistake, the loop changes nothing. Where they would not, runs without the loop reported done with defects left; runs with the loop either passed or stopped with the goal declared not yet reached, at the cost of up to four more turns.
05Five commands and no commits to main
| Command | What it does |
|---|---|
| /localix-loop:start [goal] | Sets up goal, scorekeeper, protected paths, budget, then starts |
| /localix-loop:status | Shows goal, score, iterations kept and rolled back |
| /localix-loop:stop | Stops; working tree keeps the best version |
| /localix-loop:resume [answer] [--more N] | Continues after a pause or stop |
| /localix-loop | Opens the panel |
The loop never commits to the main working tree. Kept versions are stored as git snapshots under refs/localix-loop/, so signing and pre-commit hooks never block an unattended run. Full documentation covering the definition file, the judge, the guard, hidden checks, subagents, and long runs is at loop.localix.ai/docs.
Frequently asked questions
How do I install localix-loop in Claude Code?
Run claude plugin marketplace add localixai/localix-loop then claude plugin install localix-loop@localix-loop, restart Claude Code, and open any git repository.
Does localix-loop commit code to my repository?
No. The plugin stores kept versions as git snapshots under refs/localix-loop/ and never commits to the main working tree, so pre-commit hooks and signing requirements are never triggered during an unattended run.
How does localix-loop prevent false "done" signals from Claude?
A hook with no model in it runs the developer's external scorekeeper after every change and rolls back any change that did not improve the score. The session ends only when the score reaches the developer's stated target.
What happens on a project with no existing test suite?
A separate examiner subagent writes tests from the developer's goal or spec before any code is written. Claude cannot edit those tests during the run, and additional hidden checks the model never sees catch test-fitting.
Does the loop make Claude more correct on simple projects?
Not on Localix's benchmark: a plain Sonnet 5.5 prompt passed all six acceptance tests without any loop. The plugin adds verified checking and regression protection, not additional model intelligence, and takes considerably longer on well-specified small projects.
Sources
Author
Dillip Chowdary
Writes Tech Bytes coverage of AI, engineering, and the tools that actually ship. Editor of Tech Pulse Daily.
Related on Tech Bytes
Advertisement