TLDR: This research paper investigates how much contamination (noise and omissions) language generation algorithms can tolerate. It finds that basic language generation is highly robust, even with infinite vanishing noise. However, ‘dense generation,’ which aims for broad language coverage, is much more sensitive to contamination, especially for set-based density. The study introduces a ‘beyond-worst-case’ model with ‘M-bounded adversaries’ (inspired by curriculum learning) where dense generation becomes achievable even with infinite vanishing noise, suggesting that structured data presentation is key to learning from imperfect datasets. The paper provides comprehensive characterizations and algorithmic templates for different contamination regimes.
Large language models (LLMs) have transformed how we interact with text, from generating creative content to assisting in complex problem-solving. This rapid advancement has spurred a wave of theoretical research aimed at understanding the fundamental principles behind their remarkable abilities. A central question in this field revolves around ‘language generation in the limit’ – a model where an algorithm learns from a stream of examples from an unknown language and must eventually generate new, valid strings from it.
Early work by Kleinberg and Mullainathan (KM24) showed that this generation is surprisingly achievable even for vast collections of languages. However, their model often suffered from ‘mode collapse,’ meaning the generator would produce strings from an increasingly narrow subset of the target language. To address this, Kleinberg and Wei (KW25) introduced ‘dense generation,’ which demands that the generator’s output not just be valid, but also ‘dense’ – asymptotically covering a significant fraction of the target language. They found that dense generation was also achievable for many countable collections.
A critical limitation of these foundational models, however, was the assumption of ‘perfect data.’ In reality, the training data for LLMs is far from perfect. It’s often riddled with ‘contamination’ – noise (irrelevant or incorrect strings) and omissions (missing strings from the target language). This discrepancy between theoretical models and practical reality led researchers Anay Mehrotra, Grigoris Velegkas, Xifan Yu, and Felix Zhou to ask a fundamental question: How much contamination can language generation truly tolerate?
The Challenge of Contaminated Data
The researchers explored various scenarios of contamination, from finite amounts of noise and omissions to infinite quantities where the fraction of errors either vanishes over time (o(1)-noise) or remains constant (c-noise). Previous studies had only made partial progress, focusing on either finite noise or omissions in isolation. This new work aimed to provide a comprehensive understanding of generation under both types of contamination simultaneously.
Key Findings on Contamination Tolerance
The research yielded several significant insights into how different forms of language generation cope with imperfect data:
Basic Language Generation (Non-Dense): The study found that basic language generation is remarkably resilient. Even with an infinite amount of contamination, if the fraction of noisy examples eventually converges to zero (o(1)-noise), and there are arbitrary omissions, generation remains achievable for all countable collections of languages. This is a substantial generalization of prior work.
However, this tolerance has limits. If the noise rate remains constant (c-noise), generation is only possible for specific types of language collections that satisfy a newly defined ‘c-constant noise generation property.’ This means not all collections can be learned under persistent, non-vanishing noise.
Dense Language Generation: Achieving ‘dense’ generation, which requires broader coverage of the target language, proved to be much more sensitive to contamination. Unlike basic generation, dense generation is significantly less robust.
- Under finite contamination (finite noise and omissions), ‘set-based upper density’ (meaning the generator can, infinitely often, produce a set that covers the entire language) is achievable. However, ‘set-based lower density’ (requiring consistent broad coverage) becomes much harder to achieve, even with finite contamination. The paper shows that for some collections with just two languages, achieving any non-trivial lower density is impossible.
- With vanishing noise (o(1)-noise) and arbitrary omissions, the conditions for achieving set-based density become even stricter, requiring a ‘vanishing noise ρ-dense set-generation property.’
- For ‘element-based density’ (focusing on the sequence of individual outputs), the picture is mixed. Under finite contamination, it surprisingly remains as robust as in the noiseless setting, achieving the same density guarantees (e.g., 1/2 for upper density, 1/8 for lower density). However, with vanishing noise, it becomes impossible to achieve any positive element-based upper density for certain collections.
Beyond the Worst-Case: The Role of Curriculum Learning
Given the challenges dense generation faces with infinite contamination, the researchers explored a ‘beyond-worst-case’ model. This model introduces a ‘M-bounded adversary,’ which restricts the order in which elements of a language can be presented. Conceptually, this means the adversary cannot present very complex or ‘hard’ examples too early in the training stream, aligning with the real-world practice of ‘curriculum learning’ in LLM training.
In this more realistic setting, dense generation becomes significantly more tractable. With M-bounded adversaries and vanishing noise, both set-based and element-based lower densities become achievable for all countable collections. For instance, set-based lower density can reach approximately 1/M. This suggests that the structured presentation of data, as seen in curriculum learning, can be crucial for models to learn effectively despite high contamination rates.
Also Read:
- Improving AI Reliability: Predicting When Models Lack Sufficient Data
- SofT-GRPO: Advancing LLM Reasoning with Gumbel-Reparameterized Soft-Thinking
How the Algorithms Work
The researchers developed two main algorithmic templates:
- Finite-Expansion Sub-Routine: This simpler method is used for scenarios with finite contamination. It effectively expands the collection of known languages to include all possible versions that could result from finite noise and omissions. This approach even resolved an open question regarding generation with only membership oracle access.
- Priority-Based Intersection Algorithm: For infinite contamination, a more sophisticated approach was needed. This algorithm assigns a ‘priority’ to each candidate language. Languages that are inconsistent with the observed data or violate noise/boundedness conditions are penalized by having their priority decreased. This ensures that the true target language eventually rises to the top of the priority list, allowing the generator to focus on it.
This comprehensive study, detailed in the paper “Language Generation with Infinite Contamination”, provides a deeper theoretical understanding of how large language models might cope with the imperfect, noisy data they encounter in the real world. It highlights the surprising resilience of basic generation, the vulnerability of dense generation, and the potential of structured data presentation (like curriculum learning) to overcome these challenges.


