Lossless Compression of Large Language Model-Generated Text via Next-Token Prediction
Yu Mao, Holger Pirk, Chun Jason Xue

TL;DR
This paper demonstrates that large language models can be used as highly effective lossless compressors for their own generated text, achieving over 20x compression rates compared to traditional methods like Gzip.
Contribution
The study systematically investigates LLM-based lossless compression, revealing that next-token prediction enables models to serve as efficient compressors for their outputs, outperforming traditional algorithms.
Findings
LLMs achieve over 20x compression rates on their generated text.
LLM-based prediction methods outperform Gzip by a significant margin.
The approach is robust across different models and datasets.
Abstract
As large language models (LLMs) continue to be deployed and utilized across domains, the volume of LLM-generated data is growing rapidly. This trend highlights the increasing importance of effective and lossless compression for such data in modern text management systems. However, compressing LLM-generated data presents unique challenges compared to traditional human- or machine-generated content. Traditional machine-generated data is typically derived from computational processes or device outputs, often highly structured and limited to low-level elements like labels or numerical values. This structure enables conventional lossless compressors to perform efficiently. In contrast, LLM-generated data is more complex and diverse, requiring new approaches for effective compression. In this work, we conduct the first systematic investigation of lossless compression techniques tailored…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsAlgorithms and Data Compression · Big Data and Digital Economy · Natural Language Processing Techniques
