EchoLabs33/qwen2.5-14b-instruct-hxq
093
Qwen2.5-14B-Instruct-HXQ
3.4x smaller. Beats AWQ by 15.4%. Largest HXQ model. Qwen2.5-14B-Instruct compressed from 28.8 GB to ~8.4 GB. Beats AWQ Int4 PPL (3.78 vs 4.47) with zero calibration data. 336 HelixLinear layers, no architecture changes. Justpip installandfrom_pretrained().
Install and Run
pip install "helix-substrate[hf]"import helix_substrate # registers the HXQ quantizer with HuggingFace
from transformers import AutoModelForCausalLM, AutoTokenizer
model = AutoModelForCausalLM.from_pretrained("EchoLabs33/qwen2.5-14b-instruct-helix", device_map="auto")
tokenizer = AutoTokenizer.from_pretrained("EchoLabs33/qwen2.5-14b-instruct-helix")
inputs = tokenizer("Explain quantum computing in simple terms:", return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=128)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))That's it. import helix_substrate registers the quantizer. from_pretrained() handles the rest automatically.
Compression Benchmark
Eval: WikiText-2, 1024 tokens, stride 512, BF16 on NVIDIA 4090.
Quality vs AWQ
HXQ beats AWQ by 15.4% on PPL — with zero calibration data. Dense FP16 baseline OOMs on 24 GB; the quality gap widens as model size increases.
Good to Know
- GPU and CPU supported — runs on any CUDA GPU or CPU via standard PyTorch. Fused kernels for additional speedup are in progress.
- Fine-tunable via LoRA — compressed weights remain frozen, but LoRA adapters attach to each
HelixLinearlayer viaHelixLinearSTE. Seehelix-substratefor training infrastructure. - Requires `helix-substrate` — the quantizer is not built into transformers. You need
pip install "helix-substrate[hf]". - Tied embeddings —
lm_headsharesembed_tokens, stored at full precision. - Requires 12+ GB VRAM — fits on RTX 3060 12GB, RTX 4070, or higher. Use
device_map="auto"for multi-GPU. - Dense baseline pending — FP16 dense OOMs on 24 GB. PPL delta will be added once measured on 48 GB+ GPU.
What is HelixCode?
HelixCode is a universal weight compression codec based on vector quantization:
- Each weight matrix is replaced by a 256-entry codebook (float32) + uint8 index matrix + optional sidecar corrections for outlier values
- The compressed form is the executable —
HelixLinearperformscodebook[indices] @ xdirectly, no decompression step - Works on any
nn.Linearregardless of architecture (Transformer, Mamba, MLP, CNN) - No calibration data required — unlike GPTQ/AWQ, codebooks are fit from the weights alone
How It Works
import helix_substrateregisters thehxqquantizer with HuggingFacefrom_pretrained()readsquantization_config.quant_method = "hxq"fromconfig.json- The quantizer replaces 336
nn.Linearmodules withHelixLinearshells before weight loading - Safetensors populates the codebook, indices, and sidecar buffers directly
- The model runs in compressed form — no decompression needed
Compression Receipt
Compressed tensors: 336
Exact tensors: 243 (norms, embeddings)
Dense size: 28.8 GB (BF16)
Compressed size: ~8.4 GB
Compression ratio: 3.4x
Helix PPL: 5.58 (dense baseline pending — OOMs on 24 GB)
AWQ PPL: 4.47 (published)
Eval: WikiText-2, 1024 tokens, stride=512, BF16, NVIDIA 4090Companion Models
Same codec, same pip install, multiple architectures:
Citation
@software{helix_substrate_2026,
title={Helix Substrate: Universal Weight Compression via HelixCode},
author={EchoLabs},
year={2026},
url={https://github.com/echo313unfolding/helix-substrate}
}License
Apache 2.0 (inherited from Qwen/Qwen2.5-14B-Instruct).
Native GGUF (llama.cpp)
A native GGUF HXQAFFINE6 quantization is also available in this repo:
- File:
qwen2.5-14b-instruct-hxq-affine6.gguf(10.8 GB, 6.27 bpw) - Compatibility: Requires llama.cpp HXQ fork (
hxq-affine-typebranch) - Note: This GGUF was produced via Q8_0 intermediate +
--allow-requantizedue to pod storage constraints. The safetensors HXQ artifact above remains the primary, clean-source product. For the highest quality, use the safetensors version withhelix-substrate.
# With llama.cpp (HXQ fork)
./llama-cli -m qwen2.5-14b-instruct-hxq-affine6.gguf -p "Explain:" -n 128