Open-source merge gateway, Apache-2.0

One decision per merge,
at swarm scale

When agents write most of your commits, deciding what merges is the bottleneck. mergeone asks five typed, calibrated questions per pull request and returns a verdict through a policy file you own.

curl -fsSL https://mergeone.dev/install.sh | sh
Read the benchmarkStar
mergeone
30M / daydecisions on one 2-vCPU box, p99 441 ms, zero errors, re-proved by CI on every push
~350 msper pull request with a System One model, five questions in one call
$0.07 / 1kmeasured cost per thousand decisions at list price
0.96 AUC"does this PR weaken tests?" against a strong LLM judge, 1,200 Kubernetes PRs
Latest from the benchmark

One entry per run, whichever way it falls.

All updates →
01 Context

A study on top of Anthropic's source-control redesign.

Anthropic described rebuilding source control around agents: a system called Scion built for roughly thirty thousand merges a day, where most commits are written by models and humans no longer sit in the loop of every merge. — Redesigning source control at Anthropic, Anthropic Engineering, 13 Oct 2026. Paraphrased; read the original.

That post is about storage and history. It leaves one question open, and it is the one mergeone exists to test: at thirty thousand merges a day, who decides what merges? A human cannot read them. A frontier model is too slow and too expensive to ask about every PR, and it answers in prose that cannot be put behind a rule. This site is the write-up of an experiment on the alternative: a small, fast, typed decision layer — a System One model that answers fixed questions with calibrated probabilities — placed in front of trunk as a gate. mergeone is the open-source gateway that came out of it. Everything below is reported the way it came out, including the three runs that failed.

Source · anthropic.com/engineeringRedesigning source control at Anthropic

"As our merges per day grew more than tenfold, source control became our biggest development bottleneck." How a small team built and migrated to Scion, an in-house, server-centric version control system, in five months.

Read the post →
Two days later the Claude Code team described how code is reviewed at that volume: daily landed changes went from about 2,500 in May to over 30,000 in September, most PRs merge with at most one human in the loop, and a classifier — not the author — sets each change's risk tier. — How the Claude Code team does code review, claude.dev, 15 Oct 2026. Paraphrased; read the original.

That is the layer mergeone measures, and the number this site calls ×1 is their September. The post stacks seven layers in front of trunk; the fifth is a classifier deciding how many humans a change needs, and mergeone is that decision as a typed, calibrated, logged call with a policy on top. What the post leaves open is the case run 3 found most often: two agents landing the same change twice. Run 6B is the measurement of that gap; notes.

Source · claude.dev/blogHow the Claude Code team does code review

"Daily landed changes rose from about 2,500 in May to over 30,000 in September." Seven layers, risk tiers set from the change, at most one human per PR; reverts down 40%.

Read the post →
The seven review layers in the Claude Code team's post, left to right; layer five, risk tier to human approval, is highlighted as the one mergeone implements as a typed gate, with PR memory for duplicates noted as the case the post does not cover

Our reading of a public post, not an affiliation. The seven layers are theirs; the highlight is where this benchmark's question sits.

02 Design

Many agents, many PRs, one gate.

Fig 2 is the system under test. Agents open PRs; each PR is rendered once and sent to a decision model that answers five typed questions in a single call; calibration turns answers into probabilities; a policy file turns probabilities into a verdict; a planner groups open PRs into waves that can land together. Every box is a file in the repository; every number is measured. The feedback loop at the bottom is the part that makes it a study rather than a product: a pre-registered benchmark decides whether any of this is allowed to claim anything.

Agents open PRs through GitHub or ask the gate directly over MCP. Each PR is rendered once and sent to a System One model that answers five typed questions in a single call; isotonic maps turn the answers into calibrated probabilities; your .mergeone.yaml turns probabilities into a verdict. Open PRs are grouped into non-conflicting waves so hundreds can land in parallel. Every verdict and its exact input land in the gatelog. Human outcomes and the pre-registered benchmark feed back into calibration and thresholds — which is why the policy file is the only thing you ever edit.

03 The gate

Not a queue. A gate.

dec/s
The puck in the gate: the one decision being madeThree feed chutes: the agent swarmThree chutes feed one rotary gate. Each puck gets a single verdict: green rides the exit belt (main), amber is set on the side shelf (a human), red drops through the trap (blocked). The gate turns one third per puck however fast the chutes feed it; the dial reads decisions per second.
PR state ──▶ decision model ──▶ calibrated probabilities ──▶ policy rules ──▶ verdict + route
             (Jev / Haiku)        is_logic_change      0.91     .mergeone.yaml     pass · hold · block
                                  weakens_tests        0.07                        auto-merge · human · domain-review
                                  message_matches_diff 0.88
                                  touches_concurrency  0.63
                                  needs_human_review   0.41
                                             └── every decision + its input → gatelog
Typed, not prose

The model returns probabilities, not a review comment. A rule like weakens_tests >= 0.6 → block is one line of YAML.

Calibrated before rules run

0.6 means sixty percent. Isotonic maps fitted on labelled history ship with the binary; raw ECE 0.17 becomes 0.03.

Fail closed, log everything

Model down? The PR holds for a human. Every verdict is stored with its exact input, because a System One model gives no rationale.

Landing plans, not serialisation

Hundreds of open agent PRs become waves of non-conflicting changes that land in parallel; one typed question catches semantic conflicts files cannot.

04 The portal

The gate's log, on three screens.

Sign in with GitHub, install the mergeone-gate GitHub App on your repositories, and run mergeone init --portal <token> in your clone. Your gateway then posts its gatelog to the portal; the App is used only for labels and comments, and the portal never merges or closes a PR. Three screens: Needs you for the PRs the gate stopped, The braid for how related PRs tie together — as lanes over time, or as a map of dots where only the related ones draw an edge — and Health for agreement, drift and cost. Light or dark, your choice.

The braid screen of the mergeone portal on sample data: three branch lanes running left to right into a purple gate bar, with related pull requests tied together by same-fix, competing, builds-on and backport links
The braid: lanes are branches, the purple bar is the gate; related PRs braid their lanes.
The map view of the same PRs: one dot per open pull request, coloured by verdict and sized by diff; only related PRs are joined by an edge, and the two braids are outlined
The map: one dot per open PR; unrelated PRs stay quiet, the braids stand out.
05 Evidence

Eleven runs, twenty-four results, pre-registered. Sixteen failed, two half-failed, six passed.

gatebench is the protocol: every run's hypotheses, thresholds and data rules are committed before any model is called, and every deviation is dated in a changelog. Results are published whichever way they fall. Candidates are System One models (Jev; from run 4, Perplexity's open-weight deciders), a small LLM (Claude Haiku 5.5) and a rules floor; frontier models are never candidates.

Run 1, negative
Can a diff predict a 30-day revert?
0.010PR-AUC · base 0.0075

40,000 Kubernetes merges. Rules, gradient boosting, Haiku and Jev are indistinguishable from chance. The signal is not in the pre-merge state.

results/run1
Run 2, positive
Can it answer typed triage questions?
0.87–0.96ROC-AUC vs judge

Five questions in one call. Jev meets the bar on 5/5 at 347 ms and $0.074 per thousand; Haiku 4/5 at 1,067 ms. Calibrated ECE under 0.05.

results/run2
Run 3, negative
Does it predict rejection of real agent PRs?
0.55ROC-AUC · bar 0.70

2,196 agent PRs across 26 public repos. Of 200 closures classified, 67% were superseded, duplicate or direction; 19% quality. A diff cannot see that someone else landed it. Jev did pass 100× load: p99 417 ms, zero errors.

results/run3
Run 4, mixed
Can a PR memory catch the duplicates?
0.83–0.87pair ROC-AUC · bar 0.80

Three System One models tell two PRs are the same change on held-out repos; the LLM judge (0.76) does not. The retrieval that proposes the pairs finds only 55% of confirmed duplicates (bar 60%), so memory ships opt-in.

results/run4
Run 5, mixed
Does a flag mean more review?
0.76flag ⇒ more review, AUC · bar 0.70

Pre-registered this time: calibrated needs_human_review predicts ≥ 2 force-push rounds for Jev and the 4B open-weight pplx-flash. Retrieval v2 reaches recall@5 0.66 (bar 0.70) in 3.3 ms p99. Hosted Perplexity loses 71% of calls at 100× to a per-org rate limit.

results/run5
Run 6A, negative
Does self-hosting the open weights clear the scale bar?
160 msp99 at 30× on one H100 · 100× ✕

Same 4B model, our GPU, vendor code. It answers like the hosted endpoint on 95% of argmaxes but not within the Δp bar; one L4 breaks at 10×, one H100 carries 30× at 160 ms and times out 30% at 100×. Batching did nothing — the limit is compute per request.

results/run6
Run 6B, positive
When it holds a PR as a duplicate, is it right?
98 / 100holds that were right · bar 0.60

100 blind-labelled holds: 44 are the same change (bar 0.30), 54 are pointers the author should have seen first — backports, promotes, competing fixes, follow-ups — and 2 are false alarms. A second labeller agrees at κ 0.77. The pool size is not the lever; $0.0004 per PR. A hold never closes a PR: half the time the right move is a link.

results/run6 · part B
Run 7, negative ×4
Compact state, tuned prompt, structure alone, a typed relation?
2 / 10questions that drifted · same version string

Four pre-registered bars, four misses: compact state −0.049 and the tuned prompt −0.059 against run 5's numbers, seven structural features at 0.48 AUC, the relation question at 0.73 against 0.80. The lasting result: the same prompt on the same 1,491 PRs got different answers from the hosted 4B model six days later. Same-day controls put compact at +0.007 and tuning at −0.008; the verdicts stand, nothing ships, run 8 pre-registers a control for every comparison.

results/run7
Run 8, two pass, one fail
Asked fairly: compact state, relation v2, a drift monitor?
−0.018worst compact Δ vs same-day control · bar −0.02

Every comparison against a full-state control made the same day. Compact state holds: v4 +0.010 / −0.001, pair −0.018 / −0.015, 32–42% fewer tokens — the pair call goes compact. Relation v2 misses again, 0.74 against 0.80; competing fixes stay unreadable. The drift monitor, replayed on runs 5 and 7, flags exactly the two questions that moved and nothing else.

results/run8
Run 9, one pass, three fails
FP8, a shared pair call, ×10 on one L4 — and was run 7's drift the request?
0.990hosted joint vs local single-question · agreement

The hosted endpoint asked ten questions at once answers like the local checkpoint asked one at a time, at 7.27× the tokens: run 7's drift was the provider's request decomposition. FP8 is slower on the L4 (0.64×) and not the same answers; the shared pair call is 2.46× faster but reads ten candidates worse (AUC −0.136); one L4 is ≈ 1.9 decisions/s and no configuration carries ×10. Nothing ships.

Run 10, one pass, three fails
Is a stronger decider worth it — the full 26B, the open d3-flash, Haiku on relation?
0.792d3-flash needs_human_review AUC · control 0.759 · 10× the cost

d3-flash reads "needs a human" better than the same-day hosted 4B control (+0.034, CI [0.003, 0.068]) and costs $0.0025 per PR on a 48 GB A40 at 0.37 PR/s — 10× the control against a 5× bar, so the review rule keeps pplx-flash. Competing fixes become readable to the full model (4/7) and Haiku (5/7); same-area pairs to nobody (≤ 2/10): 6/17 at best against 0.40. Nothing ships.

Run 11, two fails, one waiting
Three cheaper calls: compact main call, a model-free pair prefilter, team recalibration.
−0.032tests_cover_change under compact state · clause −0.03 · mean −0.003

Compact state for the main call keeps the mean (0.707 vs 0.710, 0.675× the tokens) and loses one question by 0.002 more than the per-question clause allows; the full state stays. The memory's retrieval order keeps the adjudicated duplicate in its top five for 42 of 46 PRs against a 0.95 bar; ten pair calls stay. Recalibration from a team's own outcomes waits for 200 of them. $0.03.

p99 latency per decision versus load multiplier for six decision-model rows; each line runs as far as the model answered every call
One line per decision model behind one API key or one GPU; the line runs as far as every call was answered, ✕ is the first load with failures. Only the hosted System One model reaches 100× (3M decisions/day) clean; one H100 is the fastest row and stops at 30×.

Run 3's labels are worth a second look: when agent PRs are closed, it is mostly not because the code is wrong. That finding did more to shape the product than run 2's good numbers — it is why run 4 exists. Run 4 then split cleanly: the uncertain part (can a cheap model tell two PRs are the same change?) is a yes from three vendors; the part built in an afternoon with fixed weights (which PR to compare against) is the bottleneck, and it caps everything downstream. Run 5 replaced the retrieval and found the next wall: the answer is usually in the top 20, one cut-off too deep. Run 6 rented the GPUs and found that open weights move the ceiling from the vendor's rate limit to your card count; its second half widens the pool and asks two blind labellers whether the holds are right — they are, 98 times in 100. Run 7 tried four cheap improvements at once and got none of them; what it got instead was the drift finding, which now sits inside every number on this page that compares two dates. Run 8 asked again with same-day controls: compact state passes, the relation question does not, and the drift monitor would have caught run 7.

06 What survives

Claims this page is allowed to make.

✓
Typed triage works at System One speed and cost.

Five calibrated questions per PR, ~350 ms, $0.07–0.09 per thousand, 0.87–0.96 AUC against a strong judge (run 2); 100× agent-scale load with zero errors (runs 1–3).

✓
One 2-vCPU box handles 30 million decisions a day.

Open-loop replay at 350/s, p99 441 ms, re-proved by CI on every push. The Anthropic figure is 30 thousand.

✕
The gate does not predict reverts.

Run 1. Nothing in the diff does; we stopped trying.

✕
The gate does not predict whether a project will take an agent's PR.

Run 3. Most rejections are coordination — superseded, duplicate, direction — which one diff cannot show.

✓
A cheap model can tell two PRs are the same change.

Run 4: same_change(A,B) at 0.83–0.87 AUC for three System One models, including an open-weight one, on maintainer-confirmed supersedes. The LLM judge fails the bar.

✕
The memory does not yet find the right PR to compare.

Run 4: retrieval recall@5 0.55 against 0.60, p99 198 ms against 20. Verdict-level gains land at a third of the bar. Shipped behind memory.enabled, opt-in until a retrieval passes.

✓
Flagged PRs go through more review rounds.

Run 5, pre-registered: AUC 0.76 for two System One models; the free rules floor is 0.73, so the model's value is the typed reason, not the score.

✕
No single box clears 100× — hosted or self-hosted.

Run 5: hosted Perplexity refuses 71% of calls above 10 rps/org. Run 6A: the same weights on one L4 break at 10×, on one H100 at 100× (30% timeouts). Batching does not help; compute per request does. Only the hosted System One model passes 100× on one key.

✓
Self-hosted open weights are the fastest row that exists.

Run 6A: one H100 answers at 160 ms p99 through 30× with zero errors — under the hosted endpoint at every load it survives — for $0.11 per 1k PRs, 4.6× hosted list price. What you buy is the absence of a per-org ceiling, not a discount.

07 Use it, or check it

The agent asks before it merges.

mergeone is an MCP server. Register it once, add one line to your agent's instructions, and every merge goes through the gate instead of around it. The same calls exist over HTTP for everything else.

# register
claude mcp add mergeone -- mergeone mcp --policy .mergeone.yaml

# CLAUDE.md
Before merging, call gate_decide. Merge only on "pass".

# response
{ "verdict": "hold", "route": "human",
  "rule": "message-mismatch",
  "probs": { "message_matches_diff": 0.31, … } }

# replicate the benchmark (every table, one command each)
git clone https://github.com/haalp/mergeone && cd mergeone
python -m mergeone.cli report results/run2 --v2
python -m mergeone.cli report results/run3 --run3