Language Modeling Is Compression [pdf] proceedings.iclr.cc · 28 points · 5 comme...

@best

Language Modeling Is Compression [pdf] proceedings.iclr.cc · 28 points · 5 comments · HN thread

TL;DR The ICLR 2024 paper by Google DeepMind and collaborators argues that language models and lossless compressors are equivalent via arithmetic coding, and evaluates large pretrained LLMs as general-purpose compressors. It reports that Chinchilla 70B compresses ImageNet patches and LibriSpeech audio better than PNG and FLAC, but that model size must be counted, which makes scaling beyond a dataset's size counterproductive.

  • Arithmetic coding turns any predictive model into a lossless compressor, and minimizing log-loss during LLM training is equivalent to optimizing compression.
  • Chinchilla 70B, trained mostly on text, reaches 43.4% on ImageNet patches (PNG 58.5%) and 16.4% on LibriSpeech (FLAC 30.3%) when model size is ignored.
  • When the parameter count is counted (adjusted rate on 1GB data), large models are far worse than classical compressors, e.g. Chinchilla 70B exceeds 14000%.
  • Small Transformers trained on enwik8 show an optimal model size per dataset size, so scaling laws depend on the amount of data available.
  • Compressors such as gzip can be used as autoregressive generative models, though their samples are noisier than Chinchilla's.
  • Tokenization acts as pre-compression; the paper finds larger vocabularies help small models but can hurt larger ones.

Discussion The thread is small and mostly appreciative rather than argumentative. Commenters point to related explanations, especially 3Blue1Brown's multi-part video series on compression and intelligence, and connect the paper to a recent OpenAI blog post that uses the word compression several times. One commenter reasons that a model trained on one language should transfer to others in proportion to how similar their structure is, and another recalls the older finding that compression ratios track language families. A final commenter notes the paper is from 2023 and is glad to see it again.

  • Compression and prediction are deeply linked, and this paper makes that concrete (many): Commenters treat the equivalence between prediction and compression as the key idea, linking it to intelligence and to recent LLM discussions.
  • Language-family compression ratios hint at why LLMs generalize (some): One commenter recalls that early compression experiments predicted similarity between language families, and suggests LLMs act like building shared compression dictionaries.
  • Cross-lingual transfer follows structural similarity (some): A commenter argues it is logical that a model trained on one language works on another, with effectiveness depending on how similar the rules are.
  • The paper is old and its finding is not new (a few): One commenter notes the paper was published in 2023 and calls it a breeze from the past, reflecting limited interest in it as news.

Links from the comments

#compression #languageModels #informationTheory #arithmeticCoding #scalingLaws