- Rust 96%
- Shell 4%
The 4.1+4.2+4.4 composite (Method::Phase4) passed its enwik9 gate: parent column-word-token-reverse 180,079,678 1.4406 bpc exact candidate phase4 176,204,762 1.4096 bpc exact archive_delta -3,874,916 ; DeltaS -3,869,716 at the 5,200 B charged in the run ACCEPTED_METHOD = Phase4; long-match, sparse-match and match-byte joined the default build. Fully accounted marginal is 5,576 B (previous accepted stub 346,208 -> 351,784): the receipt's 5,200 predates the final 4.5-4.10 shared scaffolding (+376 B), and the refined DeltaS is -3,869,340. Decision unchanged. Phase 4 verdicts: adopted 4.1 (long-distance), 4.2 (sparse), 4.4 (matched-literal); rejected 4.3 (repeat-offset), 4.5 (distance floors), 4.6 (stemming), 4.7 (word-class), 4.8 (affix entries), 4.9 (phrases), 4.10 (front-coding, neutral); 4.11 is satisfied by A1.1. Every rejection has a control and a dose-response in PHASE4_PLAN.md. Architecture/roadmap updated: Phase 4 COMPLETE; enwik9 176,204,762 (1.4096 bpc); scored stub 351,784 B; enwik6 S = 970,868 / 970,845. 86 tests + 7 courts pass. |
||
|---|---|---|
| docs | ||
| evidence | ||
| src | ||
| tools | ||
| .gitignore | ||
| build.rs | ||
| Cargo.lock | ||
| Cargo.toml | ||
| LICENSE-MIT | ||
| README.md | ||
Zentropy
Find the smallest executable explanation of enwik9. Persist the
explanation, encode only the irreducible innovation, and charge every
explanatory mechanism for every byte required to reconstruct the exact original.
Zentropy is a legitimate, rules-compliant Hutter Prize contender written in Rust. Its objective is not "an interesting compressor"; it is a valid submission that beats the strongest applicable predecessor by enough margin to win.
S = submitted_compressor_bytes + self_extracting_archive_bytes
subject to: decode(archive9) == enwik9 (byte-for-byte)
and every Hutter resource, portability, publication and
self-containment constraint.
S is authority. Bits-per-byte, compression ratio and model cross-entropy are
diagnostics. A mechanism is admitted only when its complete marginal cost
ΔS < 0.
Status at a glance
| Exactness | Every transform and archive round-trips exactly; 51 unit/property tests + 7 scripted courts pass |
| enwik9 | exact full-corpus reconstruction at 182,949,204 bytes (1.4636 bpc), 3.58 GB peak RAM |
| enwik8 | exact reconstruction at 22,313,281 bytes (1.7851 bpc) (accepted config: struct-hoist + column expert + tune 7) |
| Reference | gzip 36.4 MB · bzip2 29.0 MB · xz -9e 24.8 MB · brotli 25.7 MB · zentropy 22.5 MB |
| Submission path | scored stub (324,328 B) compresses/decompresses; self-extracting archive9 reconstructs with no inputs; OOM-protected (--max-ram, ZENTROPY_MAX_RAM_BYTES) |
| Phase | 0–2 measured; 3–12 in progress / proposed (see the architecture doc) |
No claim of competitiveness against the 110 MB record is made yet. The Phase-2 floor exists so every later mechanism can be attributed by ablation.
Quick start
# exactness + property tests
cargo test
# end-to-end self test
cargo build --release
./target/release/zentropy selftest
# corpus provenance
./target/release/zentropy hash evidence/corpus/enwik8
# reversible Wikipedia IR statistics
./target/release/zentropy tokenize evidence/corpus/enwik6
# compression / reconstruction with a full report
./target/release/zentropy bench evidence/corpus/enwik7
# leave-one-out ablation of the word experts
./target/release/zentropy ablate evidence/corpus/enwik7
# build the submission-plane artefact and measure the real Hutter split
sh tools/package_sfx.sh evidence/corpus/enwik6
# convene all automated courts
sh tools/courts.sh
Repository map
docs/ HUTTER_RULES, COMPETITIVE_BASELINE, ZENTROPY_ARCHITECTURE,
PRIOR_ART_MECHANISMS, STACK_TECH_TRANSFER
src/ single Rust package, zero external dependencies
corpus/ provenance, SHA-256 (in-tree), ladder
score/ S, gate, resource limits (single source of truth)
evidence/ immutable receipts, Gemel research memory
entropy/ binary range coder, rANS side-stream backend
mixer/ squash/stretch, adaptive mixer, APM/SSE
context/ context models, word/bigram experts, match model
ir/ ZIR-0 exactly-reversible Wikipedia tokenisation
archive/ the scored container + SFX packing format
bin/ `zentropy` (driver), `zentropy-sfx` (submission stub)
tools/ baseline, courts, packaging harnesses
evidence/ pinned digests, run receipts, baselines
research/ third-party reference material (gitignored)
Why zero dependencies
Binary size is a scored metric, determinism must be demonstrated, and the licence inventory must be trivial. The crate carries its own SHA-256, range coder, rANS and context-mixing stack. Nothing in the scored path is fetched, linked, or assumed.
Licence
MIT. See LICENSE-MIT and Cargo.toml. Any submission will ship under an
OSI-approved licence with a complete inventory, as the rules require.