Model Behavior Regression Explorer
Compare eval results of two model versions: accuracy, regressions, McNemar p-value, flaky items.
How it works
Paste eval results for two model versions on the same items (CSV or JSONL with id, input, expected, output_a, output_b and optional category). Each output is scored with your metric – exact, normalised exact, contains, numeric tolerance or regex – then accuracy is compared per version and category, regressions and improvements are listed, an exact McNemar test tells whether the difference is more than noise, and flaky (inconsistent repeated runs) or ambiguous items are flagged.
- Metrics: exact (trimmed), normalised exact (Unicode NFKC, lower case, punctuation/symbols and the articles a/an/the removed, whitespace collapsed), contains (normalised expected appears as whole words in the normalised output), numeric (last number in the output vs the expected number, absolute tolerance; thousands separators removed), regex (expected is a case-insensitive regular expression).
- Repeated ids are repeated runs: an item counts as correct for a version when the majority of its runs are correct; items whose runs disagree are flaky and excluded from the McNemar test.
- Accuracy = correct / scored items per version. Regression = A correct, B wrong; improvement = A wrong, B correct.
- Exact McNemar test: two-sided binomial test of the discordant pairs (b = only A correct, c = only B correct) against p = 0.5: p = min(1, 2·Σ_{i≤min(b,c)} C(b+c, i)/2^(b+c)). Significant at α = 0.05.
- Ambiguous: empty expected value, unparsable regex/number, or a near miss that only fails because of formatting (e.g. would pass under the normalised or contains metric).
Use this tool in an app
These free programs for your browser have this tool built in, next to everything else the task needs.
-
Agentlab AI-agent & LLM workbench
Test an AI agent before release: permissions, traces, costs, citations and output checks.
Related tools
- AI Model Compatibility Explorer – Which LLMs take images, audio or files, fit your context and support tools or structured outputs?
- LLM Cost Explorer – Monthly LLM API cost per model for your workload, with prompt-caching and batch savings.
- RAG Citation Debugger – Check a RAG answer's citations against the retrieved chunks: uncited claims, wrong sources, numbers.
How to use the Model Behavior Regression Explorer
Compare two model or prompt versions on the same eval items, see every regression, and test whether the difference is real or noise.
What it is for
You changed the prompt, swapped the model or upgraded to a new version, and the eval score dropped five points. Is that a real regression, or just noise from a small test set? And which items actually broke?
Paste eval results for two versions run on the same items, as CSV or JSONL with id, input, expected, output_a, output_b and an optional category. The explorer scores each output with the metric you choose (exact, normalised, contains, numeric with tolerance, or regex). It then compares accuracy overall and per category, lists regressions (A right, B wrong) and improvements, runs an exact McNemar test on the paired results, and flags flaky items and near misses.
It does not judge meaning. These are lexical metrics, so a correct paraphrase can count as wrong. Use it to find what to look at, then read those items yourself.
Worked example
The first built-in example compares prompt-v1 and prompt-v2 on 12 geography and maths questions using the normalised metric. Item m7 (9×9) appears twice, meaning two runs.
Result: prompt-v2 scores 58.33 % vs prompt-v1 83.33 % on 12 items: 4 regressions, 2 improvements, McNemar p = 0.688, not statistically significant.
A 25-point drop sounds alarming. Look at the four regressions, though:
q3Volga → "Danube": a real error.m3sqrt(144) → "11": a real error.q5"Mount Kilimanjaro" andm2"36.0": both flagged as ambiguous near misses. They fail the normalised metric but passcontains.
So two of the four "regressions" are formatting, and the two improvements (Canberra, 12.5) are real fixes. m7 is flaky: version B answered 81 once and 18 once, so it is left out of the paired test. With only 4 versus 2 discordant pairs, a p-value of 0.688 says this could easily be chance.
How to read the result
- Accuracy A / B and delta — correct divided by scored items per version. For repeated runs, an item counts as correct when the majority of its runs are.
- Contingency — both correct, only A, only B, both wrong, excluded. Only the "only A" and "only B" cells drive the McNemar test.
- McNemar p — below 0.05 means the difference is unlikely to be noise. Above it means you can't tell yet, which is not the same as "no difference".
- Categories — where the change hurts or helps. A flat overall score can hide a drop in one category.
- Flaky and ambiguous — check these items by hand before you blame the model.
Tips and common mistakes
- Pick the metric for the task:
numericwith a tolerance for maths ("Total: 1,250" matches 1250),containsfor short facts inside longer answers,regexwhen several forms are acceptable. - Small evals almost never reach significance. The tool warns you about this. Add items before deciding, rather than re-running until p dips.
- Both versions must be scored on exactly the same items. Missing outputs are excluded from the paired test.
- Run each item two or three times at your production temperature. Flaky items show where the model is unstable, not where it got better or worse.
- A version can tie on accuracy and still change behaviour. The numeric example scored 75 % vs 75 %, with one regression and one improvement.
FAQ
Why McNemar and not just comparing accuracies?
Both versions answered the same items, so the results are paired. McNemar uses only the items where they disagree, which makes it far more sensitive than comparing two independent percentages.
What makes an item "ambiguous"?
An empty expected value, an unparsable regex or number, or a near miss that fails only because of formatting and would pass under a looser metric.
Can I compare more than two versions?
Not in one run. Compare them pairwise, keeping one baseline as version A.
How are repeated runs handled?
Rows with the same id are runs of one item. Majority correct counts as correct, and items whose runs disagree are flagged as flaky and left out of the significance test.
Guide last updated:
For scripts and AI agents
- JSON API:
POST https://modelbehaviorregressionexplorer.usefulweb.site/api/v1/calculate(same calculation as this page) - Interface description: OpenAPI 3.1 · AI guide: llms.txt
- MCP server (Streamable HTTP):
https://modelbehaviorregressionexplorer.usefulweb.site/mcp· tool namemodel_behavior_regression_explorer
Example request
curl -s -X POST https://modelbehaviorregressionexplorer.usefulweb.site/api/v1/calculate \
-H 'content-type: application/json' \
-d '{"labelA":"prompt-v1","labelB":"prompt-v2","data":"id,category,input,expected,output_a,output_b\nq1,geo,Capital of France?,Paris,Paris,Paris.\nq2,geo,Capital of Australia?,Canberra,Sydney,Canberra\nq3,geo,Longest river in Europe?,Volga,The Volga,Danube\nq4,geo,Capital of Canada?,Ottawa,Ottawa,Ottawa\nq5,geo,Highest mountain in Africa?,Kilimanjaro,Kilimanjaro,Mount Kilimanjaro\nm1,math,12*7,84,84,84\nm2,math,15% of 240,36,36,36.0\nm3,math,sqrt(144),12,12,11\nm4,math,2^10,1024,1024,1024\nm5,math,100/8,12.5,12,12.5\nm6,math,17+26,43,43,43\nm7,math,9*9,81,81,81\nm7,math,9*9,81,81,18"}'