A fundamental insight connecting data compression and artificial intelligence
Based on Hacker News Discussion
2025
Understanding the deep connection between compression and prediction
Identify patterns and regularities in the input
Create a predictive model based on those patterns
Store only what the model cannot predict
Result: smaller file size through prediction
From everyday technology to cutting-edge AI
ZIP, PNG, MP3 all use prediction to remove redundancy from files
LLMs are trained by predicting the next word — they're compression engines
Good theories compress observations into elegant predictions
Netflix and YouTube predict frame changes to reduce bandwidth
Our brains predict sensory input — perception is a form of compression
Shannon's work established the mathematical foundation for this relationship
The best compression algorithmFundamental insight from information theory
is indistinguishable from
the best prediction algorithm.
Compression and prediction: two sides of the same coin