Randomness in large language models: What researchers need to know (and report)
Guillaume Coqueret, Joan Llull, Florian Oswald, Christophe Pérignon, Christoph Scheuch, Lars Vilhuber
Abstract
Large language models (LLMs) are increasingly used to generate data for research. Typical use cases are classifications, annotations, information extraction, and generation of numerical scores. Unlike conventional measurements, LLM outputs can vary across repeated requests even when the prompt and apparent model settings remain unchanged. This variation arises from deliberate sampling, silent model updates, numerical rounding, or expert routing. Setting a dedicated temperature parameter to zero removes deliberate sampling when that option is available, but it does not eliminate the other sources of randomness. Exact reproduction is therefore generally not possible when using proprietary application programming interfaces. Local execution of open-weight models offers greater control, but reproducibility still depends on the complete hardware and software stack. We illustrate these issues through sentiment classifications of corporate filings and examine their consequences for downstream regression results. We then propose a reporting standard for articles and replication packages, as well as guidance for data editors and authors. Together, these findings and recommendations establish that LLM outputs should be treated as draws from a distribution rather than as fixed measurements.
Create a lesson
Related papers
Wrong and More Confident: A Field Experiment on Large Language Models Taking a Graduate Economics Exam
Shared title terminology · Piyush Akimitsu
Complexity Beyond Incentives: The Critical Role of Reporting Language
Shared title terminology · Rustamdjan Hakimov, Manshu Khanna
AI-Augmented Research: Free to Write, Costly to Read
Shared title terminology · Wolfgang Kuhle
TRACE: Governing AI-Assisted Research with Principles from Computer Science
Shared title terminology · Amirhossein Zohrehvand, Aldona Kapacinskaite
Safety Research and the Allocation of Frontier Compute
Shared title terminology · Li Gan
Who Leads and Who Collects:Algorithmic Collusion in Markets of Heterogeneous Language Models
Shared title terminology · Jun Yeong Lee