Method
From README.md at modelpin 0.5.7.
How it works
scenarios/*.json ──► modelpin baseline ──► N runs on your current model (saved)
│
modelpin check --to <candidate> ──► N runs on the candidate
│
compare the two sets of runs, signal by signal:
• tool calls (which tools, in what order) • refusals
• meaning, judged by a separate LLM • your must_contain / must_not_contain checks
│
a regression must be (1) statistically significant, (2) large enough to matter,
and (3) reproduce on N fresh candidate runs
│
verdict per scenario + exit code + .modelpin/last-report.md
Models are random: the same prompt gives different words every time, so comparing single answers
is useless. Modelpin compares distributions — "the old model called the refund tool on 5 of 5
runs, the new one on 0 of 5" — with an exact permutation test, a minimum effect size per signal,
and a confirmation replay that stops one unlucky candidate sample from turning a build red.
It does not re-record the baseline: if the same scenario flags again and again against the same
model, the recorded baseline itself may be unusual — re-record it with modelpin baseline.
The full explanation, in plain language, with the exact rule at the end: How Modelpin works.
Limits, and the evidence behind the design
Modelpin is designed so that if it says it broke, it broke, and it prefers to stay quiet on a borderline change rather than raise a false alarm. Know the trade-offs:
- It can miss subtle changes — a behavior that shifts on only one run in five, or a meaning change the judge considers equivalent. Missing a borderline change is the deliberate direction of error.
- It only measures your scenarios. Behavior no scenario exercises is invisible. Coverage gaps are disclosed in every report.
- The judge is a model too. Its sensitivity depends on the model you pick. The project's
semantic threshold was calibrated with an OpenAI judge; re-scoring the published measurements
with a Gemini judge changed no alarm decision on 732 paired trials, but other judges are
unmeasured. The judges
initnow writes for OpenAI and OpenRouter (gpt-5.6-terra, orgpt-5.6-luna) and Claude's fallback (claude-sonnet-5-5) are among them, and they run withouttemperature: 0. - It measures change, not quality. It never says one model is better.
What happened when it was run at scale, live: 972 same-model scenario-checks across six
Gemini models raised 0 false alarms. They are 82 scenarios re-used across models and
repeats, not 972 independent trials, and many of those scenarios answered so consistently at
these settings that no signal could have fired (a harness run on two of the same models put
that at 230 of 240 trials). So this says the tool did not cry wolf in ordinary use on this
suite; it is not a false-positive rate, and the bounds are in docs/fp-measurement.md.
Separately, on the channels that can fail a build, the run of record (7 Sep 2026, same model
against itself) saw 0 false alarms in 9 exposed trials: a one-sided 95% upper bound of 28.3% over
trials, or 39.3% over the 6 distinct scenarios behind them. Those 9 trials were 8 on judged
meaning and 1 on refusals; none was on tool calls. 671 of the 710 trials that reached a verdict
could not have fired at all. The tool-call channel, measured separately on a corpus built for it,
had 1 false alarm in 26 scored trials: a one-sided 95% upper bound of 17.0% over trials, with 24
of the 26 from one scenario.
Across six real Gemini upgrades it flagged 28
regressions, and a second language model asked to judge materiality rated every one a
material behavior change, which is an opinion, not ground truth —
docs/live-validation.md,
with the bugs that campaign found in Modelpin itself.
The project publishes its own false-positive and detection measurements — how they were run, the confidence bounds, the same-model false alarms it has observed (four so far: one on tool calls, two from the semantic judge, one on a text assertion), and what the numbers do not show — in docs/fp-measurement.md. Those measurements describe the engine without the confirmation replay, which can only remove alarms. A worked multi-model example is the Drift Map #1.