library_name: transformers license: other license_name: glm-5.3 license_link: https://huggingface.co/kitaniai/GLM-5.3-UNCENSORED-MXFP4/blob/main/LICENSE pipeline_tag: text-generation base_model:
- dealignai/GLM-5.3-UNCENSORED-FP8 base_model_relation: quantized tags:
- glm
- glm_moe_dsa
- mxfp4
- quark
- quantized
- mixture-of-experts
- safetensors
- text-generation
Use GLM Uncensored at kitani.ai — hosted inference for your apps and coding tools.
GLM-5.3-UNCENSORED-MXFP4
An MXFP4 quantized version of dealignai/GLM-5.3-UNCENSORED-FP8, published by Kitani.
This release uses AMD Quark's GLM MoE DSA recipe and standard Hugging Face safetensors. Expert matrices use OCP MXFP4; attention, routers, the initial dense MLPs, embeddings, normalization tensors, and the output head remain at higher precision. This is a mixed-precision checkpoint, not a claim that every tensor is four-bit.
Source and provenance
- Immediate source:
dealignai/GLM-5.3-UNCENSORED-FP8. - Exact source revision:
12170112d07e50d7dbe8e5ca1691f4fd8c1179e1. - The source model card identifies
JANGQ-AI/GLM-5.3-FP8as its base andzai-org/GLM-5.3as the upstream model. - This is FP8 → MXFP4 requantization. Source FP8 weights are dequantized using their original block scales before MXFP4 conversion. It does not recover precision already lost in the FP8 source.
- No additional training was performed. The tokenizer and chat template are inherited from the source.
- Conversion completed: 2026-10-06T14:45:24.988739+00:00.
Measured checkpoint statistics
| Item | Value |
|---|---|
| Source safetensors size | 755.632 GB / 703.737 GiB |
| MXFP4 safetensors size | 423.753 GB / 394.651 GiB |
| Size reduction vs supplied FP8 source | 43.92% |
| Compression ratio vs supplied FP8 source | 1.783× |
| Source tensor elements, excluding FP8 scales | 753,329,940,480 |
| MXFP4 weight elements | 737,308,311,552 |
| MXFP4 weight matrices | 58,596 |
| Higher-precision tensor elements | 16,021,628,928 |
| MXFP4 bits/weight including block scales | 4.25 |
| Overall storage bits/source tensor element | 4.5001 |
| Safetensors shards | 282 |
| Output tensors, including quantization scales | 118,181 |
| Conversion time, excluding download/validation/upload | 7.89 minutes |
Sizes above count safetensors files, including their headers. Tensor-element counts include non-scale buffers and are not a separately audited trainable-parameter count. Overall storage includes higher-precision tensors and quantization metadata. Exact values are in quantization_stats.json; per-shard sizes and SHA-256 hashes are in artifact_manifest.json.
Quantization details
- Toolkit: AMD Quark 0.13, PyTorch
2.14.1+rocm7.2, ROCm7.2.53211. - Method: file-to-file round-to-nearest quantization; no calibration dataset, GPTQ, AWQ, or fine-tuning.
- Weight format: FP4 E2M1 values, two values per byte, with one E8M0 scale per group of 32 consecutive weights.
- Activation policy for quantized layers: dynamic MXFP4, as specified in
config.json. - Quark recipe:
LLMTemplate.get("glm_moe_dsa").get_config(scheme="mxfp4"), with*eh_projadditionally excluded to preserve the MTP auxiliary projection in BF16. - Excluded source FP8 linear weights are recovered to BF16. Existing floating-point excluded tensors retain their source dtype.
- Hardware available: 8× AMD Instinct MI355X; this file-to-file FP8 conversion used one GPU (
AMD Radeon Graphics), following Quark's supported single-device FP8 recovery path.
Architecture
| Item | Source configuration |
|---|---|
| Architecture | GlmMoeDsaForCausalLM |
| Model type | glm_moe_dsa |
| Hidden layers | 78 |
| Hidden size | 6144 |
| Routed experts | 256 |
| Experts selected per token | 8 |
| Shared experts | 1 |
| Initial dense layers | 3 |
| Vocabulary size | 154,880 |
| Configured maximum positions | 1,048,576 |
The configured context limit is inherited metadata, not a measured serving capacity. Actual context and memory requirements depend on the runtime, KV cache, batch size, and hardware.
Validation
- Passed complete shard/index consistency, file-length, tensor-coverage, dtype, packing-shape, and scale-shape checks.
- Passed independent FP4 decoding and finite-value checks on 64 matrices / 4,980,736 weight elements, sampled across the checkpoint.
- Sampled weight reconstruction relative RMSE vs recovered FP8 source: 0.111689; absolute RMSE: 0.00184817. Sampling uses the first 16 rows of evenly spaced matrix names; this is not a random or exhaustive quality estimate.
- End-to-end inference, perplexity, downstream accuracy, tokens/second, and runtime VRAM consumption have not been measured for this export. Upstream benchmark scores are not results for this quantization.
See sample_validation.json for individual matrices and conversion.json for environment and timing details.
Usage
Use a runtime supporting both GLM-5.3 / glm_moe_dsa and AMD Quark MXFP4. The intended serving path is vLLM with ROCm on supported AMD Instinct hardware. A generic Transformers installation or a runtime supporting only GPT-OSS MXFP4 is not sufficient evidence of compatibility.
Download the checkpoint:
hf download kitaniai/GLM-5.3-UNCENSORED-MXFP4 --local-dir ./GLM-5.3-UNCENSORED-MXFP4
Runtime references: vLLM Quark support and AMD Quark file-to-file quantization. The exact end-to-end serving combination remains unverified for this release.
Reproduce
Install ROCm-enabled PyTorch matching the recorded version, then install amd-quark==0.13, transformers==5.16.0, safetensors==0.8.0, and accelerate.
hf download dealignai/GLM-5.3-UNCENSORED-FP8 --revision 12170112d07e50d7dbe8e5ca1691f4fd8c1179e1 --local-dir ./source
python quantize.py --source ./source --output ./output
python validate.py --source ./source --output ./output --hash
python sample_check.py --source ./source --output ./output
License and attribution
The upstream model uses the GLM-5.3 License, preserved verbatim in this repository. The immediate source repository is tagged MIT, but the upstream model includes its own license conditions; this release is not labeled MIT-only. See LICENSE and LICENSE_PROVENANCE.json. Credit to Z.ai for GLM-5.3, JANGQ-AI for the FP8 base, dealignai for the supplied source checkpoint, and AMD for Quark. Kitani performed this MXFP4 conversion and packaging.