Paper Reading AI Learner

Nacrith: Neural Lossless Compression via Ensemble Context Modeling and High-Precision CDF Coding

2026-02-23 09:14:05
Roberto Tacconelli

Abstract

We present Nacrith, a lossless compression system that combines a 135M-parameter transformer language model (SmolLM2-135M) with an ensemble of lightweight online predictors and a 32-bit arithmetic coder. Beyond the base LLM-plus-arithmetic-coding paradigm, Nacrith introduces several contributions: (1) a CDF precision upgrade from 2^16 to 2^24 that eliminates ~75% of quantization overhead caused by minimum-probability floors in large vocabularies; (2) a token-level N-gram model for fast local predictions; (3) an adaptive log-space bias head correcting per-document LLM errors via online gradient descent; (4) confidence-based LLM skip for accelerating highly predictable tokens; (5) a hybrid binary format (NC06) extending neural compression to arbitrary binary files--to our knowledge a first among LLM-based compressors; (6) a this http URL inference backend achieving ~7x faster single-token decode than PyTorch; (7) parallel multi-GPU compression across up to 8 workers; and (8) native KV cache sliding window reducing per-slide cost by ~37x. The system requires only ~500 MB of GGUF weights and ~1.2 GB VRAM per worker, running on consumer GPUs. On this http URL (Canterbury Corpus, 152 KB), Nacrith achieves 0.918 bits per byte (bpb)--outperforming gzip by 3.1x, bzip2 by 2.5x, CMIX v21 by 44%, and ts_zip by 20%, while compressing below the 0th-, 1st-, and 2nd-order byte-level Shannon entropy bounds. On enwik8 (100 MB), Nacrith achieves 0.9389 bpb (11.74%), surpassing ts_zip (~1.11 bpb) by 15% and FineZip (1.024 bpb) by 8% despite using a 60x smaller model with no fine-tuning. An out-of-distribution evaluation on a document published after the model's training cutoff confirms these gains are not memorization artifacts, achieving 0.723 bpb on unseen text.

Abstract (translated)

我们介绍了Nacrith,这是一个结合了1.35亿参数的变压器语言模型(SmolLM2-135M)、一组轻量级在线预测器以及一个32位算术编码器的无损压缩系统。除了基础的大规模语言模型(LLM)加算术编码的基本框架之外,Nacrith还引入了以下几项创新: 1. 将CDF精度从\(2^{16}\)提升到\(2^{24}\),消除了大约75%由于大型词汇表中最小概率地板导致的量化开销。 2. 一种用于快速局部预测的令牌级N-gram模型。 3. 一个自适应对数空间偏置头,通过在线梯度下降纠正每份文档中的LLM错误。 4. 基于置信度的LLM跳过机制,以加速高度可预测的令牌。 5. 混合二进制格式(NC06),将神经压缩扩展到任意二进制文件中——据我们所知,在基于大模型的压缩器中是首创。 6. 一个推理后端,实现了比PyTorch快约7倍的单令牌解码速度。 7. 在多达8个工作线程上进行跨多个GPU的并行压缩。 8. 原生KV缓存滑动窗口,将每次滑动的成本降低了大约37倍。 该系统仅需约500 MB GGUF权重和每个工作线程1.2 GB VRAM,在消费级GPU上运行。在Canterbury语料库(152 KB)测试中,Nacrith实现了每字节0.918比特的压缩率——比gzip高出3.1倍、bzip2高出2.5倍、CMIX v21高出44%,以及ts_zip高出20%。同时,它还低于零次、一次和二次字级香农熵限值。 在enwik8(100 MB)测试中,Nacrith实现了每字节0.9389比特的压缩率——比ts_zip(约1.11比特/字节)高出15%,并比FineZip(1.024比特/字节)高出8%。值得注意的是,它使用了一个比后者小60倍且未进行微调的模型。 一项超出训练截止日期后发布文档的数据分布评估证实了这些性能提升并非记忆效应的结果,在未知文本上的压缩率为每字节0.723比特。

URL

https://arxiv.org/abs/2602.19626

PDF

https://arxiv.org/pdf/2602.19626.pdf


Tags
3D Action Action_Localization Action_Recognition Activity Adversarial Agent Attention Autonomous Bert Boundary_Detection Caption Chat Classification CNN Compressive_Sensing Contour Contrastive_Learning Deep_Learning Denoising Detection Dialog Diffusion Drone Dynamic_Memory_Network Edge_Detection Embedding Embodied Emotion Enhancement Face Face_Detection Face_Recognition Facial_Landmark Few-Shot Gait_Recognition GAN Gaze_Estimation Gesture Gradient_Descent Handwriting Human_Parsing Image_Caption Image_Classification Image_Compression Image_Enhancement Image_Generation Image_Matting Image_Retrieval Inference Inpainting Intelligent_Chip Knowledge Knowledge_Graph Language_Model LLM Matching Medical Memory_Networks Multi_Modal Multi_Task NAS NMT Object_Detection Object_Tracking OCR Ontology Optical_Character Optical_Flow Optimization Person_Re-identification Point_Cloud Portrait_Generation Pose Pose_Estimation Prediction QA Quantitative Quantitative_Finance Quantization Re-identification Recognition Recommendation Reconstruction Regularization Reinforcement_Learning Relation Relation_Extraction Represenation Represenation_Learning Restoration Review RNN Robot Salient Scene_Classification Scene_Generation Scene_Parsing Scene_Text Segmentation Self-Supervised Semantic_Instance_Segmentation Semantic_Segmentation Semi_Global Semi_Supervised Sence_graph Sentiment Sentiment_Classification Sketch SLAM Sparse Speech Speech_Recognition Style_Transfer Summarization Super_Resolution Surveillance Survey Text_Classification Text_Generation Time_Series Tracking Transfer_Learning Transformer Unsupervised Video_Caption Video_Classification Video_Indexing Video_Prediction Video_Retrieval Visual_Relation VQA Weakly_Supervised Zero-Shot