Aether / Osmium
Osmium
A context-mixing compressor for text, written in Rust and measured on the Hutter Prize data: the first gigabyte of English Wikipedia. One small program compresses and decompresses, and every number on this page is a verified round trip.
Try it
The same code, compiled to WebAssembly, runs below in a background worker. Each compression is decompressed again and compared before the file is offered. .osm files made here open with the command-line tool and the other way round. It needs about 300 MB of memory, so a desktop browser works best.
Results
Apple M4 MacBook Air, one core; peak memory from /usr/bin/time -l. Decompressed output compared byte for byte with the original. Version 0.2.0 has not been run on enwik9 yet; that row is 0.1.0.
| File | gzip -9 | bzip2 -9 | xz -9e | Osmium | Time (c / d) | Memory |
|---|---|---|---|---|---|---|
| enwik8, 100 MB | 36,475,811 | 29,008,758 | 24,831,648 | 18,485,784 (0.2.0) | 267 s / 269 s | 2.1 GB |
| enwik9, 1 GB | 322,789,249 | 253,977,891 | 211,776,220 | 168,149,041 (0.1.0) | 1,347 s / 1,001 s | 3.5 GB |
Against the Hutter Prize
The prize scores the compressed enwik9 plus the decompressor. The record listed on July 24, 2026 is 100,424,672 bytes (Vladimir Ivanov, fx2-cmix-T). Osmium 0.1.0's total is 168,311,575 bytes (archive plus the zipped decompressor), so it is not a contender: record entries run thousands of models, LSTM mixers and large preprocessing dictionaries over days of CPU time. Osmium is a compact, readable member of the same family that beats the general-purpose tools by a wide margin, and a base to build on.
How it works
- Predict every bit. Nineteen context models (byte orders 0–6 and 8, several word and word-pair contexts, wiki markup, line column and two indirect contexts) keep a one-byte bit history per context, four contexts per cache line, turned into probabilities by adaptive state maps. A run model remembers which byte last followed each context.
- Long matches. Two match models (7-byte and 24-byte) find the last occurrence of the recent text and predict that it continues the same way, with confidence learned per match length.
- Mix and refine. Four gated logistic mixers and a final mixer combine 62 inputs; four SSE stages correct the result in context, and a small mixer learns how to weigh them.
- Code. A binary arithmetic coder turns the probabilities into bits. Everything is integer arithmetic, so archives are identical on every machine and in the browser.
Source on GitHub · MIT license.