Introduction
Language Models (LMs) are fundamental to Statistical Machine Translation (SMT), providing the probabilistic framework to ensure target language fluency. However, state-of-the-art LMs often require training on trillions of words, leading to massive memory footprints. Furthermore, traditional Randomized LMs (RLMs) are static; incorporating new data typically requires computationally expensive batch retraining. This paper introduces the Online Randomised Language Model (O-RLM), a memory-efficient, dynamically updatable data structure designed to learn from unbounded text streams in real-time.
The O-RLM Architecture
The core innovation of this work is the adaptation of Bloomier filters into an online, incremental format. Unlike standard filters that require precomputed hash tables, the O-RLM utilizes a hybrid two-part structure to handle updates without full reconstruction.
- Structure A (The Bucket Array): This primary component stores $n$-gram fingerprints within an array of buckets. When a new $n$-gram is encountered, it is hashed to a specific bucket.
- Structure D (The Overflow Dictionary): To maintain the "perfect hashing" property dynamically, the system employs a small, lossless dictionary. If an update causes a collision in Structure A that cannot be resolved, the entry is diverted to Structure D.
This architecture allows the model to process text in "epochs" (e.g., weekly intervals), aggregating counts before updating the randomized structure. To prevent the model from growing indefinitely, the authors implemented adaptation strategies, such as deleting $n$-grams not recently requested by the translation decoder, effectively keeping the memory footprint stable.
Experimental Evaluation
The researchers tested the O-RLM across several large-scale datasets, including the Reuters RCV1 news stream (800,000 stories), the Gigaword corpus (1.25 billion $n$-grams), and a massive stream of 18 billion tokens from blog posts.
The Advantage of Recency
A key finding of the study is that "stale" data can actually hinder performance. Language use evolves, and models trained on a sliding window of recent data often outperform much larger models trained on older, static corpora.
As shown in the perplexity analysis of the Reuters dataset, a 20-week subset test consistently improved model fit as the stream progressed, compared to a static 51-week baseline. This validates the O-RLM's design goal: providing a mechanism to continuously integrate new information while discarding the obsolete.
Key Results and Performance
The O-RLM demonstrates that randomization does not have to come at the cost of translation quality.
- Translation Quality: In head-to-head tests, the O-RLM achieved BLEU scores nearly identical to batch-retrained models. For instance, on a specific test set, the O-RLM scored 37.17 BLEU, matching the 37.12 BLEU of a traditional batch-retrained model (TB-LM).
- Memory Efficiency: The O-RLM achieved a roughly 10x reduction in memory usage. It represented a model in just 705MB of RAM that would otherwise require 7450MB in a standard lossless format.
- Stability: By utilizing the overflow dictionary (which typically holds less than 1% of the total data), the model maintains a constant false-positive rate even as the total volume of processed text increases.
Conclusion and Future Directions
The O-RLM provides a scalable solution for SMT systems to adapt to the "firehose" of web data. While the current implementation uses "Stupid Backoff" smoothing due to the complexities of streaming more advanced algorithms like Kneser-Ney, it sets a benchmark for online LM adaptation. Future work involves developing more sophisticated streaming-friendly smoothing techniques and exploring hybrid architectures that combine large static background models with highly dynamic O-RLMs to capture both general linguistic rules and emerging real-time trends.
Summary updated