# LLM-as-a-Judge: Using a Model as the Grader, Its Biases and Calibration

> LLM-as-a-Judge lets a strong model score answers or compare them in pairs: cheap and scalable, but prone to position bias, length bias and misjudged math. Covers the judging modes, bias mitigation, measuring agreement with humans, and Bradley–Terry ranking.

- URL: https://dmxsf.com/en/wiki/evaluation/llm-as-judge/
- [DMXSF](https://dmxsf.com/en/about/)
- Intermediate
- Updated: 2026-11-15
- Tags: Evaluation, Alignment

## After this page you will be able to

- Tell pairwise comparison, single-answer grading and reference-guided grading apart, and name the main problem of each.
- Name the common judge biases (position bias, length bias, misjudged math answers) and see in an experiment how they stack.
- Mitigate bias by swapping the order and similar tricks, and measure whether a judge is reliable with agreement and Cohen's κ.
- Turn pairwise results into a leaderboard with Bradley–Terry and Elo.

LLM-as-a-Judge means using a language model, usually a stronger one, instead of humans to score candidate answers or to compare which of two is better. It is cheap, scalable and can explain its verdicts, so it became the mainstream way to evaluate open-ended Q&A and dialogue. But the judge itself is biased: it favors answers shown first, favors longer answers, and misjudges math and reasoning questions. This page covers how to use a judge, where it goes wrong, how to mitigate and measure that, and how to turn a pile of pairwise comparisons into a leaderboard.

## Why use a judge

Open-ended questions have no standard answer. Metrics such as ROUGE and BLEU, which compare similarity with a reference answer, are largely ineffective for them, while human annotation is expensive and slow. Zheng et al. (2023) therefore studied using a strong model as the judge. It has two advantages: scalability (less human effort and faster iteration) and explainability (the judge gives a rationale along with its verdict). Their conclusion was that a strong judge such as GPT-4 agrees with human preferences more than 80% of the time, the same level as the agreement between humans. The paper also lists the judges' biases, which form the main thread of this page.

## Three ways to judge

| Mode | What it does | Advantage | Main problem |
| --- | --- | --- | --- |
| Pairwise comparison | Give the judge a question and two answers and ask which is better, or a tie | Relative comparison is more stable | The number of pairs grows with the square of the number of models, so it scales poorly |
| Single-answer scoring | The judge scores one answer directly (MT-Bench uses 1 to 10) | Scalable; each answer is judged once | Hard to separate small differences; absolute scores drift more when the judge changes |
| Reference-guided | Put a reference solution in the prompt first, then have the judge score; common for math | More accurate on questions with a standard solution | Needs a reference solution, which can itself be wrong |

The three can be used alone or combined (Zheng et al., 2023, Section 3.1).

## Where judges go wrong

All numbers below come from Zheng et al. (2023), where the judges were the GPT-4, GPT-3.5 and Claude-v1 of the time. They illustrate the kinds and the size of the biases and do not describe current models.

| Bias | What happens | Evidence in the paper |
| --- | --- | --- |
| Position bias | Favors the answer in a certain slot, most often the first | After swapping the order of two similar answers, GPT-4 gave a consistent verdict in only 65.0% of cases, GPT-3.5 in 46.2% and Claude-v1 in 23.8% (Table 2) |
| Length bias | Favors longer, wordier answers even when they are no clearer or more accurate | Under the "repetitive list" attack, which restates a list without adding information, Claude-v1 and GPT-3.5 failed 91.3% of the time and GPT-4 8.7% (23 answers, Table 3) |
| Self-preference | Favors answers it generated itself | GPT-4 gave itself a 10% higher win rate and Claude-v1 a 25% higher one, but GPT-3.5 did not favor itself; the data are limited and the paper says it cannot determine whether this bias exists |
| Misjudged math and reasoning | Questions the judge can solve itself are misjudged after it is led astray by a wrong answer | On 10 math questions judged in both orders (20 judgments), GPT-4 with the default prompt misjudged 14 of them (Table 4) |

The paper speculates that position bias may come from the training data or from the left-to-right structure of the causal Transformer, and does not investigate further. What to remember is that these biases stack up, and each needs a different mitigation.

### Hands-on: how position bias, length bias and noise combine

The widget below simulates a judge. Its score for "the first answer wins" equals the true quality gap plus a preference for the first slot, a preference for the longer answer, and random noise. Three practices are compared side by side: judge once, swap the order and keep only the consistent verdicts, and swap the order and average the scores. All slider values are illustrative and do not represent any real model.

Things to try:

- Drag both the preference for the first answer and the preference for the longer answer to 0, and set the typical size of the quality gap to 1.0 and the noise to 0.8. Agreement for "judge once" is then about 78.5%, which equals $\tfrac12+\tfrac1\pi\arctan(s/\sigma)$, where $s$ is the standard deviation of the quality gap and $\sigma$ the standard deviation of the noise. Swapping the order and averaging cuts the effective noise to $\sigma/\sqrt2$ and raises agreement to about 83.6%.
- Turn on the preference for the first answer only: agreement for "judge once" drops and the share of "picked the first answer" moves away from 50%; both order-swapping practices remove the effect of position.
- Turn on the preference for the longer answer only: swapping the order does not help, and the share of "picked the longer answer" stays far above 50%. The length bias points the same way in both orders, and only position bias cancels after the swap.
- Look at the curve below the table: the closer the quality of the two answers, the closer all three practices get to a coin flip. The paper sees a similar trend in real data: agreement between GPT-4 and humans rises from 70% to nearly 100% as the win-rate gap of the model pair widens (Figure 2).

## Mitigating the biases

The most basic measure is swapping the order (Zheng et al., 2023, Section 3.4). The conservative version judges each pair twice and counts an answer as the winner only if both calls pick it; otherwise the result is a tie:

*Figure: The conservative way to swap the order (Zheng et al., 2023): the judge decides once with X first and once with Y first, and an answer wins only if both calls pick it; otherwise the result is a tie.*

A stand-in function replaces the real judge call; the logic is the same. The stand-in favors the first slot (preference 0.5), has noise 0.8, and the true quality gap of the two answers follows a standard normal distribution:

```python
import numpy as np

rng = np.random.default_rng(0)

def make_judge(position_bias: float, noise: float):
    """A stand-in for a real judge call: it sees both answers' quality but favors the one shown first."""
    def judge(quality_first: float, quality_second: float) -> str:
        score = quality_first - quality_second + position_bias + noise * rng.normal()
        return "first" if score > 0 else "second"
    return judge

def judge_once(judge, quality_x: float, quality_y: float) -> str:
    """One call per pair, with the order chosen at random."""
    if rng.random() < 0.5:
        return "x" if judge(quality_x, quality_y) == "first" else "y"
    return "y" if judge(quality_y, quality_x) == "first" else "x"

def judge_swapped(judge, quality_x: float, quality_y: float) -> str:
    """Two calls with the order swapped; a win needs both to agree, otherwise a tie."""
    one = judge(quality_x, quality_y)      # x shown first
    two = judge(quality_y, quality_x)      # y shown first
    if one == "first" and two == "second":
        return "x"
    if one == "second" and two == "first":
        return "y"
    return "tie"

judge = make_judge(position_bias=0.5, noise=0.8)
gap = rng.normal(size=20000)               # true quality gap x - y for each pair
truth = np.where(gap > 0, "x", "y")

once = np.array([judge_once(judge, g, 0.0) for g in gap])
swapped = np.array([judge_swapped(judge, g, 0.0) for g in gap])
decided = swapped != "tie"

print(f"single call:   agrees with the true preference {np.mean(once == truth):.3f}")
print(f"order swapped: ties {1 - decided.mean():.3f}, agreement on the rest {np.mean(swapped[decided] == truth[decided]):.3f}")

# Output:
# single call:   agrees with the true preference 0.753
# order swapped: ties 0.380, agreement on the rest 0.914
```

After the swap, among the comparisons where the judge gives a verdict, agreement with the true preference rises from 75.3% to 91.4%, at the cost of 38.0% of the comparisons becoming ties with no verdict. A more aggressive alternative is to assign positions at random, so that with enough samples the position bias cancels out. Besides swapping, these are the common mitigations:

| Problem | Practice | Cost or limitation |
| --- | --- | --- |
| Position bias | Few-shot judge: put three examples in the prompt (A better, B better, tie); in the paper GPT-4's consistency rose from 65.0% to 77.5% | The prompt gets longer and each call costs about 4 times more; consistent is not the same as accurate, and new biases may appear |
| Length bias | State "no extra credit for length" in the rubric; or control for length in the win rate: fit a regression model that predicts the judge's preference, then predict with the length difference set to 0 | Needs an extra fitted model and assumes the effect of length can be separated out; Length-Controlled AlpacaEval raised the Spearman correlation with Chatbot Arena from 0.94 to 0.98 (Dubois et al., 2024) |
| Misjudged math and reasoning | Have the judge solve the problem independently first (chain of thought), or put an independently obtained answer into the prompt as the reference | With the default prompt 14 of 20 were misjudged, chain of thought brought it to 6 of 20 and reference guidance to 3 of 20; if the judge solves it wrongly, the reference is wrong too |
| Self-preference | Use a judge from a different family than the models under test, or several judges | Higher cost; the data do not prove that the bias exists, but it is a cheap safeguard |
| Judge version changes | Fix the judge model's version, prompt and temperature, and state them in the report | After the judge is upgraded, old and new scores cannot be compared directly |

## How reliable is the judge: how to measure it

Put the judge's verdicts next to human annotations. Three quantities are common:

- **Agreement rate**: the share of cases where the judge and the humans reach the same verdict. The MT-Bench paper defines it as the probability that two individuals drawn at random, one from each of two groups of judges, give the same verdict on a random question; agreement among humans is a reference for what a judge can reach. On first-turn data, GPT-4 and human experts agree 85% of the time without ties, and human experts agree among themselves 81% of the time; with ties the figures are 66% and 63%. Two random judges would agree 50% of the time without ties and 33% with ties (Table 5, 58 expert annotators, about 3K votes).
- **Cohen's κ**: with unbalanced classes, agreement can look inflated, since a judge that always guesses the majority class can score a high agreement. $\kappa=(p_o-p_e)/(1-p_e)$ subtracts the agreement that happens by chance: $p_o$ is the observed agreement and $p_e$ is the agreement when each side labels at random with its own label frequencies. Kappa is also pushed down by class balance: the same two annotators with the same error rate can go from 0.811 to 0.144; see [Building Evaluation Sets](https://dmxsf.com/en/wiki/evaluation/building-eval-sets/).
- **Stratify by difficulty**: the same judge is accurate when the two answers differ a lot and close to a coin flip when they are close. A single overall agreement rate hides this.

```python
import numpy as np

#                 judge: A wins  B wins  tie
confusion = np.array([[40,   6,   4],      # human: A wins
                      [ 8,  30,   2],      # human: B wins
                      [ 3,   2,   5]])     # human: tie

n = confusion.sum()
p_observed = np.trace(confusion) / n
p_expected = (confusion.sum(axis=1) / n) @ (confusion.sum(axis=0) / n)   # agreement if both label at random with their own frequencies
kappa = (p_observed - p_expected) / (1 - p_expected)
print(f"agreement {p_observed:.3f}, chance agreement {p_expected:.3f}, Cohen's kappa {kappa:.3f}")

# A judge that always guesses the majority class: high agreement, kappa of 0
confusion = np.array([[90, 0], [10, 0]])
n = confusion.sum()
p_observed = np.trace(confusion) / n
p_expected = (confusion.sum(axis=1) / n) @ (confusion.sum(axis=0) / n)
print(f"always the majority class: agreement {p_observed:.3f}, kappa {(p_observed - p_expected) / (1 - p_expected):.3f}")

# Output:
# agreement 0.750, chance agreement 0.418, Cohen's kappa 0.570
# always the majority class: agreement 0.900, kappa 0.000
```

How many human annotations do you need? To estimate the agreement to within an error $\varepsilon$ you need about $z^2p(1-p)/\varepsilon^2$ of them ($z=1.96$). With agreement around 80% and $\varepsilon=5$ points that is about 246; with agreement around 50% it is about 385. A few dozen spot checks can therefore reveal only obvious problems and cannot show that a judge is reliable. This is the same formula as the confidence interval in [The Statistics of Evaluation](https://dmxsf.com/en/wiki/evaluation/eval-statistics/).

## From pairwise comparisons to a leaderboard: Bradley–Terry and Elo

Pairwise comparison, whether the judge is a human or a model, yields a pile of "who beat whom" records. To turn them into a leaderboard you need a model that translates wins into strength. The Bradley–Terry model gives each model a strength coefficient $\xi$, and model $i$ beats model $j$ with probability

$$
P(i \succ j)=\frac{1}{1+e^{-(\xi_i-\xi_j)}}
$$

The same formula underlies reward-model training: replace "model" by "answer" and the strength coefficient by the reward, and you get the preference probability of the [Reward Models](https://dmxsf.com/en/wiki/post-training/reward-models/) page, which [Preference Optimization: From RLHF to DPO](https://dmxsf.com/en/wiki/post-training/preference-optimization/) also builds on. The coefficients are fitted by maximum likelihood (that is, logistic regression) over all battles together. Only differences are meaningful, so one model is fixed at 0. An Elo score is just a different scale: $\mathrm{Elo}=\tfrac{400}{\ln 10}\,\xi\approx 173.7\,\xi$, and a gap of 400 points means odds of 10 to 1.

*Figure: Drawn from P = 1 / (1 + 10^(−Δ/400)), where Δ is the Elo difference between two models. A Bradley–Terry coefficient ξ converts to an Elo score as Elo = (400 / ln 10) × ξ ≈ 173.7 × ξ.*

Chatbot Arena lets users compare the answers of two anonymous models and vote; by the time of the paper it had received about 240K votes from about 90K users. Its ranking uses Bradley–Terry coefficients rather than online-updated Elo scores, because the former suit statistical estimation better; the confidence intervals use a bootstrap or a sandwich variance estimator (Chiang et al., 2024). The code below does the same on simulated battles: it generates 3,000 battles, fits the coefficients with Newton's method, then estimates intervals with a bootstrap.

```python
import numpy as np

rng = np.random.default_rng(0)
names = ["A", "B", "C", "D"]
true_elo = np.array([1000.0, 1050.0, 1120.0, 1250.0])      # true strengths on the Elo scale
beta_true = true_elo * np.log(10) / 400                    # converted to Bradley–Terry coefficients

m, n_battles = 4, 3000
i = rng.integers(m, size=n_battles)                        # each battle draws two different models at random
j = (i + rng.integers(1, m, size=n_battles)) % m
p_i_wins = 1 / (1 + np.exp(-(beta_true[i] - beta_true[j])))
win = (rng.random(n_battles) < p_i_wins).astype(float)     # 1 means i wins

def fit_bt(i, j, win, m: int, iters: int = 50) -> np.ndarray:
    """Maximum-likelihood Bradley–Terry coefficients (Newton's method), with model 0 fixed at 0."""
    beta = np.zeros(m)
    for _ in range(iters):
        p = 1 / (1 + np.exp(-(beta[i] - beta[j])))
        g = win - p
        grad = np.bincount(i, g, m) - np.bincount(j, g, m)
        w = p * (1 - p)
        hess = np.zeros((m, m))
        np.add.at(hess, (i, i), -w)
        np.add.at(hess, (j, j), -w)
        np.add.at(hess, (i, j), w)
        np.add.at(hess, (j, i), w)
        step = np.linalg.solve(-hess[1:, 1:], grad[1:])
        beta[1:] += step
        if np.abs(step).max() < 1e-9:
            break
    return beta

to_elo = lambda beta: 400 / np.log(10) * (beta - beta[0]) + 1000    # model 0 is pinned at 1000

estimate = to_elo(fit_bt(i, j, win, m))

boot = []                                                  # bootstrap: resample battles to get intervals
for _ in range(500):
    k = rng.integers(n_battles, size=n_battles)
    boot.append(to_elo(fit_bt(i[k], j[k], win[k], m)))
low, high = np.percentile(boot, [2.5, 97.5], axis=0)

for k, name in enumerate(names):
    print(f"{name}: true {true_elo[k]:6.0f}   estimate {estimate[k]:7.1f}   95% interval [{low[k]:7.1f}, {high[k]:7.1f}]")

# Output:
# A: true   1000   estimate  1000.0   95% interval [ 1000.0,  1000.0]
# B: true   1050   estimate  1031.0   95% interval [ 1006.8,  1052.3]
# C: true   1120   estimate  1118.6   95% interval [ 1095.0,  1140.9]
# D: true   1250   estimate  1246.8   95% interval [ 1223.2,  1270.5]
```

A is the reference pinned at 1000, so its interval has no width; the others are relative to A. With 3,000 battles the intervals of B, C and D have a half-width of about 23 points and contain the true values. To judge whether the ranking of two models is reliable, compute an interval for their difference and see whether it contains 0, rather than checking whether the two intervals overlap; B is about 31 points above A, and the interval of that difference, [6.8, 52.3], excludes 0. Wins and losses produced by a judge model can be ranked the same way, but the judge's biases go straight into the leaderboard, so calibrate the judge first.

## A practical checklist

1. Write a clear rubric: say "no extra credit for length", use temperature 0 or a low one, and fix the version of the judge model.
2. Swap the order in pairwise comparisons; for single-answer scoring report the distribution of scores, not just the mean.
3. For math, code and factual questions, use reference answers or executable verification instead of the judge's subjective judgment.
4. Have humans label a sample, compute agreement and Cohen's κ, and look at them by difficulty or category.
5. Use a judge from a different family than the models under test, and several judges where you can.
6. Report results with confidence intervals and compare two models with a paired analysis (see [The Statistics of Evaluation](https://dmxsf.com/en/wiki/evaluation/eval-statistics/)).
7. Treat the judge as an approximation, not ground truth: its biases are known, so keep calibrating it with human spot checks.

## Summary and exercises

- A judge is cheap, scalable and explainable, but it has position, length, self-preference and reasoning-misjudgment biases, and each has to be mitigated.
- Swapping the order removes position bias, not length bias.
- Measure a judge by its agreement (against the agreement among humans), Cohen's κ and a breakdown by difficulty, and use enough samples for the spot check.
- Fit pairwise comparisons into a leaderboard with the Bradley–Terry model and attach bootstrap intervals.

**1. Which practice removes the judge's preference for the answer in the first slot?**

- [ ] Raise the judge's sampling temperature
- [x] Judge twice with the order swapped, and count a win only if both calls agree
- [ ] Ask the judge to write a longer rationale
- [ ] Write a longer prompt

> Position bias comes from "who is shown first"; after swapping, the preference cancels across the two calls. A higher temperature only adds randomness, and longer rationales or prompts do not change the bias that position brings.

**2. Which statements are supported by data in the MT-Bench paper (Zheng et al., 2023)? (select all that apply)**

- [x] After swapping the order of two similar answers, GPT-4 gave a consistent verdict in only 65.0% of cases
- [x] Under the "repetitive list" attack, GPT-4's failure rate (8.7%) was far lower than GPT-3.5's (91.3%)
- [ ] The paper proved that GPT-4 has a self-preference
- [x] With reference-guided judging, the judge's misjudgments on math questions dropped from 14 of 20 to 3 of 20

> The paper observed that GPT-4 gave itself a 10% higher win rate, but because the data were limited and the difference small, it said explicitly that it cannot determine whether models have a self-preference.

**3. 90% of the true labels are "A wins" and the judge always answers "A wins". What are its agreement and Cohen's κ?**

- [ ] 90% and 0.9
- [x] 90% and 0
- [ ] 50% and 0
- [ ] 100% and 1

> The agreement is 90%. The chance agreement is $p_e=0.9\times1+0.1\times0=0.9$, so $\kappa=(0.9-0.9)/(1-0.9)=0$: the judge provides no information beyond guessing the majority class.

**4. In a Bradley–Terry model, model A's coefficient is 1 higher than B's. What is the probability that A beats B?**

- [ ] 50%
- [ ] 63.2%
- [x] 73.1%
- [ ] 84.1%

> $P=1/(1+e^{-1})\approx 0.731$. 63.2% is $1-1/e$ and 84.1% is the standard normal cumulative probability at 1; neither is the result of this formula.

**5. To estimate a judge's agreement with humans to within ±5 points (95% confidence), with agreement around 80%, about how many human annotations do you need?**

- [ ] About 60
- [x] About 250
- [ ] About 1,000
- [ ] About 5,000

> $n\approx z^2p(1-p)/\varepsilon^2=1.96^2\times0.8\times0.2/0.05^2\approx 246$.

### Exercises

1. In the widget above, set the preference for the first answer to 0 and the preference for the longer answer to 0.6, and leave the noise and the quality gap at their defaults. Does swapping the order change the share of "picked the longer answer"? Why?
2. Two models are 100 Elo points apart. What is the probability that A beats B, and what is the corresponding Bradley–Terry coefficient gap?
3. You want to use a judge model to compare two versions of a customer-service reply template. Write the evaluation plan: how to set up the judge, how to calibrate it and how to report the results.

<details>
<summary>Reference answers</summary>

1. No, not noticeably. Length bias pushes in the same direction in both orders, and the judge always tends to pick the longer answer; swapping the order cancels only the bias that depends on the order, namely the preference for the first slot. To control length bias, state in the rubric that length earns no extra credit, or control for length statistically.
2. $P=1/(1+10^{-100/400})\approx 64.0\%$; the coefficient gap is $\xi=100/173.7\approx 0.576$.
3. One plan: use a strong model from a different family than the models under test as the judge, at temperature 0, with the version and the prompt fixed. Compare in pairs, swap the order, and count a win only if both calls agree; record the rest as ties. State in the rubric that length earns no extra credit and that factual correctness matters. Have humans label 250 or more samples, compute agreement and Cohen's κ, and break them down by question category. Finally report the win rate, the tie rate and confidence intervals, and use a paired analysis of the two versions on the same questions.

</details>

## Further reading

- Zheng et al., [Judging LLM-as-a-Judge with MT-Bench and Chatbot Arena](https://arxiv.org/abs/2306.05685) (2023); judge types, biases and mitigations; most numbers on this page come from this paper
- Chiang et al., [Chatbot Arena: An Open Platform for Evaluating LLMs by Human Preference](https://arxiv.org/abs/2403.04132) (2024); anonymous pairwise voting and Bradley–Terry ranking
- Dubois et al., [Length-Controlled AlpacaEval: A Simple Way to Debias Automatic Evaluators](https://arxiv.org/abs/2404.04475) (2024); a regression correction for the judge's length bias
- Miller, [Adding Error Bars to Evals](https://arxiv.org/abs/2411.00640) (2024); statistical methods for putting error bars on evaluation results
- [LLM Evaluation Methodology: Benchmarks, Contamination and a Workflow](https://dmxsf.com/en/wiki/evaluation/llm-evaluation/)
- [Preference Optimization: From RLHF to DPO](https://dmxsf.com/en/wiki/post-training/preference-optimization/): how pairwise preference data is used in training; it is the same kind of data as the pairwise comparisons here
- [QLoRA paper breakdown](https://dmxsf.com/en/blog/qlora-efficient-finetuning-of-quantized-llms/): the GPT-4 judge's order bias and self-preference, its agreement with humans (Kendall tau 0.43, Fleiss kappa 0.25), and the arithmetic of turning Elo gaps into win rates.

- Zhou et al., [IFEval](https://arxiv.org/abs/2311.07911) (2023): instruction-following rules that are verified programmatically, sidestepping the judge's subjectivity and bias.

## Companion code

[LLM-as-a-judge: bias, agreement, and Bradley-Terry leaderboards](https://github.com/dmxsf/dmxsf/tree/main/labs/evaluation/llm-as-judge): A judge stand-in with chosen biases, so every number has an exact answer: swapping the order cancels position bias but not length bias, Cohen's kappa exposes a judge that always guesses the majority class, and a Bradley-Terry leaderboard is corrected for length.

- Run it in the companion repository (add --quick for a fast pass): `uv run dmxsf run evaluation/llm-as-judge`
- [View the lab script](https://github.com/dmxsf/dmxsf/blob/main/labs/evaluation/llm-as-judge/run.py)
- [Lab write-up](https://github.com/dmxsf/dmxsf/blob/main/labs/evaluation/llm-as-judge/README.en.md)
- [`judge.py`](https://github.com/dmxsf/dmxsf/blob/main/src/dmxsf/evaluation/judge.py)
- [Find this lab in the catalog](https://dmxsf.com/en/code/#llm-as-judge)

## FAQ

### Is LLM-as-a-Judge reliable?

Under the right setup, quite: in the MT-Bench paper, GPT-4 agreed with human experts 85% of the time on non-tie votes, versus 81% between two human experts. But judges have position bias, length bias and misjudge math answers, so use order swapping, reference answers and human spot checks to mitigate and calibrate, and treat the judge as an approximation rather than ground truth.

### How do I reduce a judge's position bias?

Judge each pair twice with the order swapped and count a win only if both calls pick the same answer; otherwise record a tie. You can also assign positions at random and rely on a large sample to cancel the bias. Few-shot examples in the prompt help too: in the paper GPT-4's consistency rose from 65.0% to 77.5%, but the longer prompt raises the cost of each call by about 4 times.

### Can the model under test serve as its own judge?

Better not. A judge may favor its own answers: the MT-Bench paper observed that GPT-4 gave itself a 10% higher win rate and Claude-v1 a 25% higher win rate, but the samples were limited and the paper could not tell whether this self-preference is general. A safer practice is to use a judge from a different model family than the models under test, or to use several judges.

### Should I use pairwise comparison or single-answer scoring?

Pairwise comparison is more sensitive to small differences and its relative results are more stable, but the number of pairs grows with the square of the number of models. Single-answer scoring scales and costs less, but it struggles to separate close answers and its absolute scores drift more when the judge is replaced. For questions with a standard solution, such as math and code, prefer a reference answer or executable verification.

### How do I turn many pairwise comparisons into a leaderboard?

Use the Bradley–Terry model: give each model a strength coefficient, so that A beats B with probability 1/(1+exp(−(ξA−ξB))), fit all coefficients together by maximum likelihood over all battles, and give confidence intervals with a bootstrap. An Elo score is just a different scale. Chatbot Arena uses Bradley–Terry coefficients because they suit statistical estimation better.
