Skip to main content
QUICK REVIEW

[Paper Review] The Good, The Bad, and The Greedy: Evaluation of LLMs Should Not Ignore Non-Determinism

Yifan Song, Guoyin Wang|arXiv (Cornell University)|Jul 15, 2024
Law, AI, and Intellectual PropertyComputer Science7 citations
TL;DR

The paper investigates non-determinism in LLM generations by comparing greedy decoding and sampling across diverse benchmarks and models, showing greedy often wins, with notable exceptions, and highlighting the impact of alignment, scaling, and best-of-N strategies.

ABSTRACT

Current evaluations of large language models (LLMs) often overlook non-determinism, typically focusing on a single output per example. This limits our understanding of LLM performance variability in real-world applications. Our study addresses this issue by exploring key questions about the performance differences between greedy decoding and sampling, identifying benchmarks' consistency regarding non-determinism, and examining unique model behaviors. Through extensive experiments, we observe that greedy decoding generally outperforms sampling methods for most evaluated tasks. We also observe consistent performance across different LLM sizes and alignment methods, noting that alignment can reduce sampling variance. Moreover, our best-of-N sampling approach demonstrates that smaller LLMs can match or surpass larger models such as GPT-4-Turbo, highlighting the untapped potential of smaller LLMs. This research shows the importance of considering non-determinism in LLM evaluations and provides insights for future LLM development and evaluation.

Motivation & Objective

  • Motivate the need to evaluate non-determinism in LLM outputs rather than a single deterministic result.
  • Characterize when greedy decoding outperforms sampling and when it does not across diverse benchmarks.
  • Assess consistency of non-determinism effects across model sizes and alignment methods.
  • Explore factors such as scaling, alignment, temperature, and repetition on non-deterministic generation.
  • Demonstrate the potential of best-of-N sampling to unlock the capabilities of smaller LLMs.

Proposed method

  • Compare greedy decoding and nucleus sampling across seven benchmarks including AlpacaEval 2, Arena-Hard, WildBench v2, MixEval, MMLU-Redux, GSM8K, and HumanEval.
  • Evaluate multiple open-weight LLMs and a proprietary GPT-4-Turbo baseline.
  • Sample 16 completions for most benchmarks, 32 for MMLU-Redux, and 128 for GSM8K and HumanEval.
  • Investigate scaling, alignment methods (e.g., DPO, KTO, SimPO), temperature, and repetition penalty effects.
  • Use best-of-N sampling with reward models to rank and select top responses, benchmarking against oracle upper bounds.
Figure 1: Alignment effects on non-determinism.
Figure 1: Alignment effects on non-determinism.

Experimental results

Research questions

  • RQ1Q1: How does the performance gap between greedy decoding and sampling differ across benchmarks and models?
  • RQ2Q2: When is greedy decoding better than sampling, and vice versa, and why?
  • RQ3Q3: Which benchmarks are most/least consistent with respect to non-determinism?
  • RQ4Q4: Do any models exhibit distinctive non-deterministic patterns across tasks?

Key findings

  • Greedy decoding generally outperforms sampling on most benchmarks, though rankings can change by configuration.
  • AlpacaEval is an exception where sampling shows higher win rate.
  • Benchmarks with constrained output spaces (e.g., MixEval, MMLU) show more stability, while math and coding tasks (GSM8K, HumanEval) are more affected by sampling variance.
  • Results are consistent across different model sizes and families; alignment methods can reduce sampling variance in many tasks.
  • Best-of-N sampling with reward models can let smaller LLMs match or exceed GPT-4-Turbo on several tasks, with oracle best-of-N illustrating upper-bound potential.
Figure 2: (a) Temperature effects on non-determinism. (b) Repetition penalty effects on generation. We compare performance of Llama-3-8B-Instruct with different generation parameters.
Figure 2: (a) Temperature effects on non-determinism. (b) Repetition penalty effects on generation. We compare performance of Llama-3-8B-Instruct with different generation parameters.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.