Quantization recipe
Table with columns: Parameter, Value| Parameter | Value |
|---|
| Algorithm | GPTQ-Pro (gptqmodel) |
| Bits / group size | 4 / 64 |
| Preset | quality (QuantizeConfig.quality_4bit) |
| Calibration | text, 64 samples ≈ 315k tokens, avg ~19.7k chars/sample |
| Calibration device | CPU (--calib-device cpu) |
| Offload | disk (--offload-disk) |
| Source precision | BF16 (18 safetensors shards) |
Architecture notes (measured from config)
model_type=qwen3_5, Qwen3_5ForConditionalGeneration — Qwen3.8-27B reuses the
exact 64-layer/400-linear contract of Qwen3.6/3.5-27B.
- 64 decoder layers: 48 linear attention + 16 full attention (interval 4).
- hidden 5120, head_dim 256, intermediate 17408.
- The release wrapper enforces fail-closed architecture/version gates before
quantizing (no trust-remote-code, official checkpoint only).
Quality gate (run post-quant before upload)
Structural checks (bits=4, g=64, 64 layers intact, tokenizer present, shard sizes),
CPU load + deterministic 24-token generation, degenerate-output detection.
Full log: qwen3_8_27b_preflight.json in this repo.
Findings / notes
- Quantization loop: ~1.07 min/layer on one 3090 at 250 W power cap → ~70 min for
the 64-layer loop, plus calibration capture and final disk pack (~80 min total).
- The power cap matters: at the factory 220 W cap the same GPU runs the loop ~2x
slower. 250 W is the stable ceiling for GPU0 on this host (270 W historically
crashed it).
- A higher-quality variant (
--preset max_quality, --nsample 128, ~2x runtime,
8 h budget) is being quantized next and will be published separately as
…-GPTQ-Pro-4bit-g64-maxq when its quality gate passes.
Usage
from transformers import AutoTokenizer, AutoModelForCausalLM
model_id = "groxaxo/Huihui-Qwen3.8-27B-abliterated-GPTQ-Pro-4bit-g64"
tok = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id, device_map="auto")
GPTQ-Pro inference requires gptqmodel (or any GPTQ kernel that reads
quantization_config); vLLM ≥ current stable also loads these checkpoints.
License
Apache-2.0 (inherited from the base model). Abliteration disclaimer: this build has
safety-refusal conditioning removed by the upstream Huihui project; use responsibly
and in accordance with your local regulations.