eval-loop
Skill1 starsChanged 2 months agoMITView on GitHub
Runs a bounded improvement loop on a chemistry model or pipeline (measure, cluster failures, fix one cluster at the root, re-measure, gate, log), maximising one metric while every other stays a bound. Use when the user says "improve accuracy", "work the loop", "run the eval loop", "what should we fix next", or wants measurable progress across iterations. Also use when an accuracy push has no stated objective and no bounds, or when an iteration moved the headline number by zero and the next step is unclear. Not for a single before/after measurement (use run-eval) or a goal judged against a named reference (use gauntlet-loop).
1 other project uses a version of this.
Adopted by
Most recently taken up by
- malloydata/publishertheir own version, first seen Oct 1, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- malloydata/publisher★ 116same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository21 other files it gives its agents.
- bounded-goalsSkill
- change-asserted-valueSkill
- check-targetSkill
- cluster-failuresSkill
- councilSkill
- enumerate-firstSkill
- fable-reviewSkill
- gauntlet-loopSkill
- handoffSkill
- kickoffSkill
- promo-videoSkill
- prove-invariantSkill
- refusal-censusSkill
- reuse-before-rerunSkill
- run-evalSkill
- run-gateSkill
- spy-siteSkill
- test-gateSkill
- understand-before-mergeSkill
- verify-sourceSkill
- watching-background-jobsSkill
The file
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 4 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
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
- Distinctive: line 15
Enforce your goals/bounds file mechanically, not by eye: After a re-run, evaluate the bounded contract with an enforcer script (or, at …
- Very specific: line 42
1. Measure: Use the run-eval skill (or your project's equivalent).
- Very specific: line 51
2. Diagnose: Use the cluster-failures skill (or equivalent) on the diagnostic run.
- Distinctive: line 64
3. Fix at the root: Follow your project's fix-methodology doc if you have one (the governing rule, restated: build the whole class of cases …
- Distinctive: line 77
4. Re-measure, cheaply: If your project has a cheap re-measurement tool — one that re-runs the pipeline but only re-invokes an expensive …
- Distinctive: line 163
Stop at a small fixed number of iterations (e.g.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
The evaluation loop
One iteration = one failure cluster. Stop after a small fixed number of iterations (e.g. 3) or when the goal threshold in your goals/bounds file is met, then report.
run eval -> cluster failures -> fix ONE cluster -> re-run -> check goals -> logEnforce your goals/bounds file mechanically, not by eye. After a re-run, evaluate the bounded contract with an enforcer script (or, at minimum, a checklist you actually run through every time) that derives every hard and relaxable bound from the run + gate artifacts and fails loudly on any hard-bound violation:
<your-goals-enforcer> --run <runs-directory>/<id>.json --gate <gate-verdict-file>A hard-bound violation (e.g. a wrong-structure/wrong-prediction rate rising, a
protected-set regression, or an exact-match requirement breaking) means revert, do
not trade: if a change makes a hard bound worse, undo the change, full stop, no
matter what else it improved elsewhere. Write that rule down once in your own project's
docs (an eval/LOOP-CONTRACT.md or equivalent) and read it alongside the goals file, so
a fix that trades away a hard bound for a soft one is never mistaken for progress. The
failure curriculum for the next iteration should be minted from the run or a wider
audit — never by touching your protected splits.
This is a developer workflow. Do not implant any part of it into the product/library itself: no self-correction loop, no retry ladder, no agentic behaviour inside the inference path just because your dev loop uses one. If your pipeline already calls an external validator at inference time (e.g. a round-trip parser gate), that is an existing design decision — this loop is not a licence to add more inference-time machinery.
Per iteration
1. Measure. Use the run-eval skill (or your project's equivalent). Run the
shipped config for the headline number, and an ungated/diagnostic config for a
clusterable run:
<your-eval-command> --split <dev-split> --tag "iter-N-before"
<your-eval-command> --split <dev-split> --gates off --tag "iter-N-before-diag"2. Diagnose. Use the cluster-failures skill (or equivalent) on the diagnostic
run. Take the largest cluster — but read its actual examples first. A cluster can look
large because a totally different layer fails on inputs that merely happen to share
one surface feature (same scaffold class, same ring system, same functional group) —
sharing that feature doesn't mean sharing a cause.
Then locate the actual code site by measurement, with the spy-site skill (or
equivalent): a site named in a comment, roadmap, or design doc is often called zero
times for the cases it was meant to fix. Count calls on the site for the target rows,
and validate the counter against two or more known positives before trusting a
zero-calls reading, because a single positive can mislead (for example, one served
from a warm cache).
3. Fix at the root. Follow your project's fix-methodology doc if you have one (the governing rule, restated: build the whole class of cases correctly, or fail closed on the whole class — never a regex post-processor, never a per-case special case, never a string rewrite bolted onto an already-generated output).
Removing a wrong output is not automatically progress — check what the pipeline actually emits afterward, not just that the bad path stopped firing. A guard that blocks a fabricated output can unmask a different, equally wrong path underneath it (seen repeatedly across real projects: a rejected bad prefix silently drops atoms instead of refusing; an over-broad refusal turns a correct answer into a merely-valid but non-preferred one; denying one bad case falls through to an even more generic, wrong default).
4. Re-measure, cheaply. If your project has a cheap re-measurement tool — one that re-runs the pipeline but only re-invokes an expensive external validator for outputs that actually changed since the baseline run — use it:
<your-cheap-remeasure-command> --baseline <iter-N-before run id>This should print churn in both directions (how many rows got better, how many got worse), so a "net +0" result that actually moved many rows each way stays visible instead of looking like nothing happened. Then run the full eval command for the iteration's headline number.
5. Gate. A change must not regress your protected-set metric: run the fast pre-gate
(see the run-gate skill) and read the actual pass count against a current
baseline — a bare PASS verdict is not sufficient if the baseline it's compared against
is stale.
6. Log. Append one row to your project's eval log: iteration number, cluster worked, run ids before and after, the delta on every tracked bound, the commit, and one line on what actually changed. Log a negative result too — an iteration that moved nothing is one of the most useful entries in the log, because it stops the next session from repeating the same attempt.
Bounded objectives — maximise one, bound the rest
Per iteration, declare one objective and hold every other tracked number as a bound,
relaxing a bound only deliberately and visibly. Optimising several metrics at once
stalls the loop, because any change that regresses any metric gets reverted and no
necessary trade-off is ever made (the bounded-goals skill covers writing that
contract).
Example table (substitute your project's actual metrics — a property predictor might use MAE-on-holdout as the objective with calibration/coverage as bounds; a retrosynthesis model might use top-k accuracy as the objective with route-validity as a bound):
| metric | role this iteration | |
| maximise | your headline correctness metric | the objective |
| bound | protected-set pass count ≥ current baseline | hard, never relaxed |
| bound | precision/coverage on produced outputs ≥ current | relax only with a stated reason |
| bound | output size/length/complexity ≤ current mean | a bound, never an objective |
| bound | runtime/inference cost ≤ current | relax deliberately, and say so |
Bound a cheap proxy like output length; never make it an objective. Pressure that
shortens outputs also truncates them into wrong ones (e.g. caffein instead of
caffeine, or a truncated systematic name for a simple structure) that can still pass a
validity check. An agent that rewarded shorter outputs this way scored an order of
magnitude lower on held-out correctness than a project that only bounded length.
Plateau trigger — hand it to a fresh agent
On an iteration that moves the objective by zero, hand the next step to a fresh context instead of iterating in the one that plateaued: a reviewer role analyses the code and writes an improvement plan to a file, and a fresh implementer executes it. The reviewer role should also hold sole authority to edit your goals/bounds file and this loop's own rules; an implementer that can move its own goalposts mid-iteration is not measurable.
A zero-movement iteration on your headline objective is not automatically a failure — check which bound the work actually targeted. A batch of fixes that holds the headline metric exactly flat while clearing a different bound (e.g. a spelling/formatting-layer correctness class that a round-trip-validity check literally cannot see) is real progress on that bound's axis, not a plateau. Confirm which axis the work was on before calling anything a plateau.
Rules that make the loop mean something
- One cluster per iteration. Two unrelated fixes in one iteration destroy the attribution the next decision depends on.
- Never touch your held-out split unless the user asks in so many words. It exists to be spent exactly once, at the end.
- Never re-sample a split. Split files are the contract; a good harness records their content hash and refuses to compare runs across a hash change.
- Watch coverage and precision together. A headline correctness metric rising while precision-on-produced falls usually means abstention/coverage widened, not that outputs got better — especially when the headline metric is reference-free and measured identical whether validity gates are on or off, in which case a move that only shifts coverage/precision changed honesty, not correctness.
- You may run alongside other read-only measurement work, provided you're not
writing to the same gate/verdict artifact. If concurrent runs contend over a shared
external resource (a license, a GPU, a validator subprocess), use an explicit
budgeting mechanism, not
pgrep(self-matches, can't count available slots).
Stopping
Stop at a small fixed number of iterations (e.g. 3) or when your headline metric clears its goal-file threshold. Then report: the trajectory across every tracked bound, which clusters were worked, which were tried and refuted, and the next-largest remaining cluster. If several iterations moved nothing, say so plainly — that's a finding about where the real difficulty is, not a failure to report.
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
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.

