Non-Vacuous Generalization Bounds for Large Language Models
Sanae Lotfi, Marc Finzi, Yilun Kuang, Tim G. J. Rudner, Micah Goldblum, Andrew Gordon Wilson
TL;DR
This work delivers the first non-vacuous generalization bounds for pretrained large language models by coupling PAC-Bayes compression bounds with a novel nonlinear SubLoRA parameterization and prediction smoothing to handle the unbounded negative log-likelihood objective. It introduces practical tools—including document-level independence assumptions and subsampling-based bound computation—to scale bound evaluation to datasets with billions of tokens, and demonstrates non-vacuous bounds for GPT-2 architectures up to nearly a billion parameters. Empirically, larger models exhibit tighter bounds and greater compressibility, suggesting genuine generalization beyond memorization, and the framework reveals how text structure influences generalization. The approach provides a quantitative, compressibility-based lens on LLM generalization with a scalable pipeline applicable to future, larger models and datasets, offering a principled benchmark for understanding and certifying LLM generalization performance.
Abstract
Modern language models can contain billions of parameters, raising the question of whether they can generalize beyond the training data or simply parrot their training corpora. We provide the first non-vacuous generalization bounds for pretrained large language models (LLMs), indicating that language models are capable of discovering regularities that generalize to unseen data. In particular, we derive a compression bound that is valid for the unbounded log-likelihood loss using prediction smoothing, and we extend the bound to handle subsampling, accelerating bound computation by orders of magnitude on massive datasets. To achieve the extreme level of compression required for non-vacuous bounds, we devise SubLoRA, a simple low-dimensional nonlinear parameterization that leads to non-vacuous generalization bounds for models with nearly a billion parameters. Finally, we use our bounds to understand LLM generalization and find that larger models have better generalization bounds and are more compressible than smaller models.
