Codebook Lossless LLM Compression: 10-25% RAM Reduction with Bitwise Packing

A developer has published proof-of-concept code for lossless LLM compression that reduces memory usage by 10-25% through bitwise generic packing of indexed weights. The technique trades some inference speed for smaller model size, making it possible to run larger models on hardware with limited VRAM.
How It Works
The developer started by asking how many unique values actually exist in LLM layers. Analysis revealed that while fp16 uses 16 bits, most models only utilize about 12-13 bits of unique values. By packing these values into blocks, the technique achieves compression without losing precision.
Performance Characteristics
- RAM reduction: 10-25%+ across tested models
- Speed impact: Inference speed approximately halved in example tests
- Test hardware: NVIDIA P2200 (5GB) and CPU, with updates being developed for AMD MI50 (32GB)
Implementation Details
The developer worked on this project for several weeks using AI coding assistants including Claude, Qwen, and Gemini. The repository includes both lossless and lossy/balanced versions, though the lossy version hasn't been extensively tested yet.
The developer suggests this compression approach might serve as a way to measure a model's "compactness" - how efficiently it uses its parameter space.
Code Availability
The proof-of-concept code is available on GitHub: https://github.com/bigattichouse/Codebook-Quantization
📖 Read the full source: r/LocalLLaMA
👀 See Also

OpenLobster: Self-Hosted AI Agent in Go with 30MB RAM Footprint
OpenLobster is a self-hosted AI assistant written in Go that runs as a single binary with 30MB RAM usage and 200ms cold start. It supports multiple LLM providers including Ollama, OpenRouter, and any OpenAI-compatible endpoint, with memory stored in a graph database.

Local Qwen Models Achieve Browser Automation with Stepwise Planning and Compact DOM
A developer found small local LLMs like Qwen 8B and 4B succeed at browser automation using stepwise planning instead of upfront multi-step plans, combined with a compact semantic DOM representation that reduces token usage from 50-100K+ to ~15K for full flows.

CC-Canary: Detect Regressions in Claude Code with Local JSONL Analysis
CC-Canary reads Claude Code session logs and produces a forensic report on model drift, including read:edit ratio, reasoning loops, cost trends, and auto-detected inflection dates.

Comparison of 14 Claw AI Agent Variants Across 10 Categories
A detailed comparison of 14 popular Claw AI agent variants including OpenClaw, NanoClaw, NemoClaw, ZeroClaw, PicoClaw, Moltis, IronClaw, and NullClaw, scored across 53 sub-parameters with composite rankings and ideal use cases for each.