TufaZip Compresses 1 GB of Wikipedia to 105.4 MB Losslessly with a Single Neural Network
Tufa Labs has released TufaZip: a single standard transformer that compresses text losslessly, training itself as it goes. It shrank a gigabyte of English Wikipedia (the enwik9 test) to 105.4 MB, about 10% of the original size, and ranks 13th on the leaderboard. The idea is simple: the more confidently the network guesses the next token, the fewer bits it takes to record that token. It is not suited to everyday archives, but it works very well as a demonstration of what language models can do.
AI-processed from TG: @data_secrets (Data Secrets); edited by Hamidun News
Researchers at Tufa Labs have shown that an ordinary language model can work as a lossless archiver: after decompression, you get exactly the same text, byte for byte. Their TufaZip took enwik9, the first gigabyte of English Wikipedia and a standard test from the Large Text Compression Benchmark, and compressed it to 105.4 MB.
That is about 10% of the original size, a compression ratio of almost 9.5x. For comparison, gzip, bzip2 and xz use no neural networks at all.
The whole result comes from a single transformer, with no ensemble of other algorithms, and it ranks 13th on the leaderboard. If you build models or store large text corpora, this work shows clearly that prediction quality translates directly into megabytes saved.
Why compression is prediction
Classical algorithms look for repeated chunks of text, build dictionaries and encode frequent symbols with shorter codes than rare ones. This works well, but such methods do not understand language.
Here is a simple example. You see the start of a phrase: "Moscow is the capital of Rus…". The continuation is obvious, so there is no need to spell it out letter by letter: a couple of bits will do. If the next word could be anything, recording it costs more. An arithmetic coder does exactly this: the more confidently the model predicts the next token, the fewer bits the coder spends on it. In other words, the next-token prediction that powers chatbots can be used as compression.
The idea itself is not new, and researchers have been developing it for several years. What is new in TufaZip is something else: it is the first time this result has been achieved losslessly and with just one neural network rather than a set of different algorithms.
How the network learns while it compresses
The scheme works like this:
- Take an architecture and random initial weights with a fixed seed.
- The model reads the text token by token and, at each step, outputs probabilities for the next token.
- An arithmetic coder writes the token into a bit stream: the more confident the prediction, the fewer bits it uses.
- After each token, the model takes a training step on the text it has just seen.
So at the start of the file the network knows almost nothing, and tokens are expensive. By the middle of the file it knows the language well, and each following token "costs" less and less.
At the end, only the arithmetic coder's bit stream needs to be saved. The weights are not needed: for decompression, it is enough to know the architecture and the initial seed. That is the main beauty of the approach.
Decompression mirrors compression. The decoder takes the same "blank" network with the same seed and an empty context. Its first probability distribution exactly matches the one from compression. Given the bit stream, the decoder unambiguously recovers the first token and applies the same training step the encoder did. The weights after that step are identical, so the second distribution matches too, and so on down the chain to the end of the file.
The cost of the result and practical takeaways
The honest cost is high. Compressing one gigabyte takes about a week and requires around 74 GB of memory, so TufaZip is far from replacing gzip. The enwik9 leaders are still ahead by about 20 MB, but a single network that learns on the fly has already come very close to the strongest compressors.
What this means in practice:
- for researchers, it is further evidence that a language model is a strong compressor, and that better prediction directly yields a smaller file;
- the shared-seed, learn-on-the-fly trick makes it possible to avoid transmitting weights altogether, which is interesting for work on model efficiency;
- for product use, TufaZip is not an option yet: it is a lab record, not a ready-made tool for archives.
If training can be sped up and memory requirements reduced, the approach could move beyond leaderboards. Details are available on the Tufa Labs project page.
- Nov 30, 2026A Transformer Compressed One Billion Bytes of Wikipedia to 105.39 MB and Took Second Place in the Benchmark
- Jan 22, 2026Wikipedia vs. AI: How to Fight 'Machine' Text
- Oct 30, 2026243,000 texts for a 29M-parameter model: how the author picked data from Wikipedia and psychology books
- May 2, 2026A local AI model on Debian: Project NOMAD for offline work
Key Questions Answered
Why compression is prediction?
Classical algorithms look for repeated chunks of text, build dictionaries and encode frequent symbols with shorter codes than rare ones. This works well, but such methods do not understand language. Here is a simple example. You see the start of a phrase: "Moscow is the capital of Rus…". The continuation is obvious, so there is no need to spell it out letter by letter: a couple of bits will do. If the next word could be anything, recording it costs more.
How the network learns while it compresses?
The scheme works like this: Take an architecture and random initial weights with a fixed seed. The model reads the text token by token and, at each step, outputs probabilities for the next token. An arithmetic coder writes the token into a bit stream: the more confident the prediction, the fewer bits it uses. After each token, the model takes a training step on the text it has just seen. So at the start of the file the network knows almost nothing, and tokens are expensive.
What are the key details on The cost of the result and practical takeaways?
The honest cost is high. Compressing one gigabyte takes about a week and requires around 74 GB of memory, so TufaZip is far from replacing gzip. The enwik9 leaders are still ahead by about 20 MB, but a single network that learns on the fly has already come very close to the strongest compressors.
Test Frontier LLMs & Autonomous Agents in One Workspace
Run Claude Opus 5.5, GPT-6, Gemini 3.1, and DeepSeek side-by-side in Nomad AI (nomadnet.ai) — unified model routing, deep research, and multimodal workflows under one subscription.
Daily 60-sec AI Voice Brief + Weekly Production AI Agent Playbook
Listen to a 60-second AI news brief every morning and get a weekly hands-on playbook for shipping AI agents to production — tools, MCP servers and patterns that work. Curated by Jemal Hamidun, Head of AI at Alpina Digital.
