A/B Testing

An Overview
1
02 · The A/B test

Every new ranker gets an A/B test.

Half the users see the production policy πp, half see the treatment πt.

Δ = V(πt) − V(πp)

That difference in means is unbiased. The trouble is how much it wobbles.

Details

The difference in their average rewards estimates the effect of switching.

03 · Noise

Unbiased, and still noisy.

Run the same test again and the estimate moves. When the true effect is small, many runs point the wrong way, and the worse policy ships.

Illustration · toy numbers
Details

Illustration with toy numbers: two policies over six items, 2,000 users per test, true Δ = 0.004. Not the paper's data.

04 · Where the signal is

Most of that traffic carries no signal.

Both policies often pick the same item with nearly the same probability. Only the policy contrast matters:

d(x,a) = πt(a|x) − πp(a|x)

Grey channels: items where d = 0. Balanced A/B still sends them half of the users here.

Illustration · toy numbers
Details

Those users add noise but say nothing about the difference.

05 · The usual fixes

The usual fixes turn one global knob.

Overlap-aware designs tune one traffic split ρ between the two policies.

qρ = ρ πt + (1 − ρ) πp
more productionmore treatment

Moving ρ rescales every item together. The grey channels never empty.

Details

CUPED and regression adjustment clean up the estimator after the data are collected.

06 · The optimal logger

Send each user where the policies disagree.

For any fixed control variate m, the variance-optimal logger has a closed form (Theorem 3.2):

q∗m(a|x) =|d(x,a)| √sm(x,a)Σb |d(x,b)| √sm(x,b)

Items where the policies agree get nothing; noisier items get more.

Details

sm is the residual reward's second moment, E[(Y − m)² | x, a]. Channels here use toy numbers.

07 · The control variate

Then pick the control variate, and the logger follows.

Zm = gm(x) +d(x,a)q(a|x){y − m(x,a)}

Each m brings its own optimal logger, so only m is optimized: a scalar β (Scalar joint) or a logistic model per action (Model-CV).

β = 0β = 1
Illustration · toy numbers
Details

The correction keeps the estimate unbiased for any m fitted on historical logs. A 5% uniform backoff keeps every item sampled.

08 · Side by side

Same users, two designs.

Drag the divider across the picture. Left: balanced A/B with pairwise IPS. Right: the variance-optimal logger with an optimized scalar β.

Illustration · toy numbers
Details

Same users, same random draws; both are unbiased.

Illustration with the toy numbers from earlier, 2,000 users per test. The paper's own results come next.

09 · Results

In the paper's simulated A/B tests, it is more accurate everywhere.

39–51%
of balanced A/B's traffic is enough for Model-CV to reach the same MSE
1.5–2.1×
the power of balanced A/B for Model-CV at 10,000 users, highest in every panel
42–63%
fewer wrong-sign picks than balanced A/B at 10,000 users
26–41%
lower MSE than the stronger traffic-split baseline; 81–88% lower than standard A/B
Details

Ranges span six panels: K ∈ {25, 50, 75} actions × 10,000 or 30,000 historical interactions; 500 replications each; true Δ ≈ 0.005 (Sections 4 and 5.1, Figures 1 to 3).

10 · Limits

What it does not claim.

11 · Takeaway

Spend traffic where the policies disagree.

Variance-Optimal Counterfactual Policy Design for Sample-Efficient Online A/B Testing
Shashank Gupta, Subhadeep Maji · Preprint, 2026
Balanced A/B⇆Variance-optimal