GenSelect: A Generative Approach to Best-of-N

Shubham Toshniwal, Ivan Sorokin, Aleksander Ficek, Ivan Moshkov, Igor Gitman

TL;DR

Current test-time scaling often pairs parallel sampling (Best-of-$N$) with verifiers that either judge solutions individually (pointwise) or compare them two at a time (pairwise). GenSelect reformulates response selection by prompting a reasoning LLM to evaluate $N$ candidate solutions simultaneously in an $N$-ary comparison. Using simple prompting and $N$-ary knockout tournaments, GenSelect consistently outperforms standard majority voting, discriminative reward models, and pointwise generative verifiers on challenging math competitions.

What Problem Does This Paper Address?

Parallel sampling generates multiple candidate answers to a reasoning problem, but identifying the correct one remains a bottleneck:

  1. Pointwise scoring evaluates solutions in isolation. LLMs are notoriously weaker at standalone verification than comparative judgment.
  2. Pairwise comparison leverages comparative reasoning, but scaling it to large candidate pools ($N$) requires either $O(N^2)$ comparisons or binary knockout tournaments that incur high latency ($O(\log_2 N)$ sequential rounds)—an issue magnified when each match requires long chain-of-thought reasoning.

The authors explore whether reasoning LLMs can directly evaluate multiple solutions at once ($N$-ary comparison) to select the best answer accurately and efficiently.

Methods

  • $N$-ary Selection via Prompting: Rather than assigning absolute scores or running pairwise matches, the model receives the problem and $N$ indexed candidate solutions simultaneously. The prompt instructs the LLM to group answers, identify logical contradictions, screen out clear errors, and output the index of the most mathematically sound approach (Judgment: [IDX]).
  • Solution Summarization: Rather than feeding full, messy thinking trajectories into the context window, solutions are compressed into clean summaries using an instruction model (Qwen2.5-32B-Instruct). The authors found this preserved performance while keeping prompt sizes compact.
  • $N$-ary Knockout Tournaments: When sampling budgets exceed context limits (e.g., evaluating 64 candidates), the authors run an $N$-ary tournament. For instance, evaluating 64 candidates with 16-way comparisons requires only two rounds (four 16-way matches followed by one 4-way match), compared to 63 binary comparisons across 6 rounds.
  • Ensembling (GenSelect@$K$): The GenSelect procedure is repeated $K$ times with shuffled solution candidate orderings, followed by majority voting over the selected answers.
       [64 Candidate Solutions]
                  │
        (Round 1: 4 × 16-way matches)
                  ▼
         [4 Semi-Finalists]
                  │
        (Round 2: 1 × 4-way match)
                  ▼
            [Best Solution]

Datasets

The authors evaluated methods on Comp-Math-24-25, a curated benchmark of 256 competition-level math problems from 2024 and 2025:

  • AIME 2024 & 2025: 30 questions each (60 total).
  • HMMT (Harvard-MIT Math Tournament): November 2024 (62), February 2024 (68), and February 2025 (66).
  • Proof-based problems and partial-credit questions were excluded to ensure objective evaluation.

Key Insights and Ideas

  • LLMs excel at multi-candidate comparison out of the box: Off-the-shelf reasoning models (QwQ-32B, DeepSeek-R1-0528) perform $N$-ary comparisons effectively using simple zero-shot prompts—no fine-tuning required.
  • Stability across $N$: Accuracy remains remarkably consistent whether $N=2, 4, 8,$ or $16$ (e.g., single-run accuracy ranges between 72.1% and 72.6% for QwQ). This means practitioners can set $N$ as large as context windows allow, drastically reducing tournament rounds without sacrificing quality.
  • Verification vs. Generation compute allocation: When dividing a fixed inference compute budget between generating more answers ($2N$ candidates + majority vote) versus verification ($N$ candidates + $N$ GenSelect runs), GenSelect is consistently better for moderate-to-large budgets ($N \ge 8$), and across all settings for weaker generator models.

Key Results

  • Outperforming Baselines (QwQ-32B on Comp-Math-24-25, 64 candidates):
  • Pass@64 (Oracle upper bound): 85.2%
  • Majority Voting @64: 68.4%
  • Qwen2.5-Math-RM-72B: 66.8%
  • Pointwise QwQ GenRM: 69.1%
  • QwQ GenSelect@1: 72.1%
  • QwQ GenSelect@8: 73.4%
  • Overall Benchmark Performance (GenSelect@32):
  • DeepSeek-R1-0528: Increases from an average pass@1 of 71.2% (and majority@64 of 84.0%) to 87.1% with Self-GenSelect@32 (achieving 93.3% on AIME 2024 and 90.0% on AIME 2025).
  • QwQ-32B: Increases from pass@1 of 60.0% (majority@64 of 68.4%) to 73.0% with Self-GenSelect@32.

Limitations and Future Work

  • Context Window Constraints: Context limits prevent evaluating huge candidate sets in a single prompt (e.g., $N > 16$), necessitating multi-round knockout tournaments.
  • Sequential Latency: GenSelect cannot start until candidate generation is fully finished, introducing pipeline latency compared to pure parallel generation.
  • Scope: The evaluation focused exclusively on competition mathematics; general reasoning and open-ended generation remain unexamined.
  • Future RL Opportunities: The authors utilized existing models zero-shot. Training verifiers specifically on $N$-ary comparative tasks via reinforcement learning—or distilling large reasoning models' comparative judgments into smaller models—is an open direction.

Summary updated

BibTeX
@inproceedings{toshniwal2025genselect,
  author = {Shubham Toshniwal and Ivan Sorokin and Aleksander Ficek and Ivan Moshkov and Igor Gitman},
  title = {{GenSelect: A Generative Approach to Best-of-N}},
  booktitle = {AI4MATH @ ICML},
  year = {2025},
  url = {https://openreview.net/forum?id=8LhnmNmUDb},
}
Figure