Skip to content
mlmentorship

Test-time compute, search, and verifiers

Spend extra inference compute on several candidate solutions, search, tools, or revision, then select results with evidence.

Published · 8 min read ·Role-specific ·Advanced

Visual quick review

Separate proposal coverage from selection quality by explaining how extra compute can generate a correct candidate yet still return a wrong answer when the verifier ranks a proxy instead of correctness.

Same candidates; different selection evidence

The same candidate set succeeds with a direct checker and fails with a weak proxy verifier

The same candidate set succeeds with a direct checker and fails with a weak proxy verifier Two panels contain the same four sampled candidates: A has wrong arithmetic, B is correct, C is incomplete, and D is a polished shortcut with a wrong answer. In the upper panel, protected tests directly check the task and select candidate B, so the returned answer is correct. In the lower panel, a weak model judge rewards plausibility and selects candidate D, so the returned answer is wrong even though candidate B was available. Candidate letters, truth labels, verifier labels, selection text, and solid versus dashed arrows communicate the result without color. 1 · DIRECT CHECK: FINDS AND SELECTS B SAME FOUR SAMPLES A · wrongarithmetic B · CORRECTsolution C · incomplete D · polishedwrong shortcut PROTECTED TESTS check task outcome SELECT B · 3/3 return correct answer Sampling found B; direct evidence preserved it. 2 · PROXY CHECK: FINDS B, SELECTS D SAME FOUR SAMPLES A · wrongarithmetic B · CORRECTsolution C · incomplete D · polishedwrong shortcut WEAK MODEL JUDGE rewards plausibility SELECT D · FAIL return wrong answer Sampling still found B; the proxy discarded it.
sampling already found B. The three checks retain B; the proxy discards it for D, which passes only one check.
Check: Was candidate generation the failure in the lower panel? What evidence caused the selector to discard the correct candidate?
Full explanation 8 min read
Reading depth

Summary

Test-time compute adds sampling, search, tools or revision while answering a request; selection must retain any correct candidate found.

For nonnegative integer , a task asks for . Four hypothetical programs produce these outputs on three checks:

CandidateRule
A
B
COnly handles MissingMissing
DAlways returns

Expected outputs are [0, 6, 55]. A plausibility scorer assigns A/B/C/D scores [0.60, 0.80, 0.40, 0.95]. Which program does each selector return?

Hold proposal coverage fixed: B exists in both panels.

Same candidates; different selection evidence

Generating a correct candidate is insufficient when the verifier discards it

Generating a correct answer is insufficient if the verifier rejects itCandidate A is correct but discarded; B is wrong but selected. More generation alone does not repair this selection bottleneck.Every required gate must pass on thesame route✓correctxselectedCorrect A is discarded.xcorrect✓selectedWrong B is selected; the releasedresult remains wrong.
Read it this way: Candidate A is correct but discarded; B is wrong but selected. More generation alone does not repair this selection bottleneck. Can additional generation alone repair a verifier that chooses B instead of correct A?
Reference drawing

Same candidates; different selection evidence

Generating a correct candidate is insufficient when the verifier discards it

Generating a correct answer is insufficient if the verifier rejects itCandidate A is correct but discarded; B is wrong but selected. More generation alone does not repair this selection bottleneck.Every required gate must pass on thesame route✓correctxselectedCorrect A is discarded.xcorrect✓selectedWrong B is selected; the releasedresult remains wrong.
Derivation
The same candidate set succeeds with a direct checker and fails with a weak proxy verifier Two panels contain the same four sampled candidates: A has wrong arithmetic, B is correct, C is incomplete, and D is a polished shortcut with a wrong answer. In the upper panel, protected tests directly check the task and select candidate B, so the returned answer is correct. In the lower panel, a weak model judge rewards plausibility and selects candidate D, so the returned answer is wrong even though candidate B was available. Candidate letters, truth labels, verifier labels, selection text, and solid versus dashed arrows communicate the result without color. 1 · DIRECT CHECK: FINDS AND SELECTS B SAME FOUR SAMPLES A · wrongarithmetic B · CORRECTsolution C · incomplete D · polishedwrong shortcut PROTECTED TESTS check task outcome SELECT B · 3/3 return correct answer Sampling found B; direct evidence preserved it. 2 · PROXY CHECK: FINDS B, SELECTS D SAME FOUR SAMPLES A · wrongarithmetic B · CORRECTsolution C · incomplete D · polishedwrong shortcut WEAK MODEL JUDGE rewards plausibility SELECT D · FAIL return wrong answer Sampling still found B; the proxy discarded it.
sampling already found B. The three checks retain B; the proxy discards it for D, which passes only one check.
Check: Was candidate generation the failure in the lower panel? What evidence caused the selector to discard the correct candidate?
Read it this way: Candidate A is correct but discarded; B is wrong but selected. More generation alone does not repair this selection bottleneck. Can additional generation alone repair a verifier that chooses B instead of correct A?

The verifier is the bottleneck

The following executable fixture checks the actual functions, not their written explanations. These illustrative tests are finite evidence, not a proof for every input.

proposals = {
	"A": lambda count: count * (count - 1) // 2,
	"B": lambda count: count * (count + 1) // 2,
	"C": lambda count: 6 if count == 3 else None,
	"D": lambda count: 6,
}
checks = [(0, 0), (3, 6), (10, 55)]
proxy_scores = {"A": 0.60, "B": 0.80, "C": 0.40, "D": 0.95}

def choose_checked(candidates, cases):
	passing = [
		name for name, function in candidates.items()
		if all(function(count) == expected for count, expected in cases)
	]
	return passing[0] if passing else None

assert choose_checked(proposals, checks) == "B"
assert max(proxy_scores, key=proxy_scores.get) == "D"
without_correct = {name: function for name, function in proposals.items() if name != "B"}
assert choose_checked(without_correct, checks) is None

For a selector returning one candidate:

The proxy fails selection, so more proposals alone do not repair this demonstrated fault. Use reliable direct checks where possible; validate model judges and test false accepts, false rejects and unusual valid solutions.

Change the sample budget or verification result

1. Increase from four candidates to eight

Picture and change: under hypothetical independent success probability , coverage is for samples. Retain a reliable selector and account for its cost too.

Check: coverage rises from to . Perfectly correlated samples remain at coverage.

A separate model-verifier accounting fixture charges 100 generation tokens and 50 verification tokens per candidate. Four candidates cost 600 tokens; eight cost 1,200, versus 150 for one. These are invented charges, not measured usage; Python execution itself does not imply model tokens.

Use when: coverage, not selection, limits quality; compare equal-cost alternatives, including a stronger base model.

2. B is absent and the budget is exhausted

Picture and change: return an explicit unverified/escalation result instead of silently selecting the highest proxy score.

Check: choose_checked(without_correct, checks) returns None; A/C/D each pass only one check.

Use when: unsupported answers cost more than abstention or qualified escalation.

Failure and transfer

Protect evaluation from candidate modification; repeated feedback can overfit even hidden selection tests. Keep separate confirmation data.

Does eight-way majority agreement establish correctness when every candidate repeats the same wrong formula?

Check your answer

No. Test a discriminating boundary or obtain independent evidence; repeated agreement is not independent correctness evidence.

Main methods

Best-of-n sampling

Generate candidates and apply a selector; independence is an assumption for the coverage formula, not a sampling guarantee.

Self-consistency

Aggregate answers; agreement can preserve correlated errors.

Iterative revision

Revise against available evidence; unsupported critique can introduce errors.

Define states, expansion, score, pruning and stopping. An early weak score can prune the only correct path.

Tool use

Programs, symbolic solvers, environment checks and human review provide evidence only within their own assumptions. Sandbox untrusted code and bound tool resources.

Small example: coding assistant

Run focused tests, revise from failures, then run regressions and static checks. Consider another plan for high risk; stop within scope or escalate missing requirements/checks.

Allocate compute by request

Use task risk, difficulty, expected gain and remaining budget. Disagreement or failed checks can trigger bounded escalation, not endless revision.

Measure the compute-quality curve

Report success, verifier errors, tokens, tool calls, latency tails, cost and difficulty slices at completed budgets. Compare equal total cost as well as sample count.

Main failure modes

Bound loops, inspect latency tails and overload behavior, and retain consequential held-out slices.

Scope the answer

Define task, risk, method, verifier, allocation, stopping and measurement; do not infer correctness from additional compute.

References: verifier training, self-consistency, process supervision, allocation.

Related: train and serve a reasoning model under a fixed budget, annotated reasoning-strategy mock, evaluate an agent, and RL with verifiable rewards and GRPO.