ReLMCodec is an open-weight model from Wanzixiang, released under MIT License. Its published files total 6.3 GB.
Single-stream, 50 Hz speech coding at 650 / 800 bps. This model repository contains the complete ReLMCodec inference release: both codec checkpoints, their matching YAML configs, the frozen W2v-BERT 2.0 parameters embedded in each checkpoint, and the code…
Model Card
By Wanzixiang, published under mit, revision ba3ad9721d93.
Single-stream, 50 Hz speech coding at 650 / 800 bps. This model repository contains the complete ReLMCodec inference release: both codec checkpoints, their matching YAML configs, the frozen W2v-BERT 2.0 parameters embedded in each checkpoint, and the code needed to reconstruct audio. The weights have no optimizer, scheduler, discriminator, or RNG state. The 8K checkpoint is the 200K perceptual-stage export. The 64K checkpoint is the available 50K additional fine-tune, selected by Log-Mel/PESQ/STOI on a separate 50-file dev set. The closest retained record to the paper's 64K table used an unavailable 30K fine-tune weight. Checkpoint provenance records this distinction and the actual…
Read Wanzixiang's full model card
ReLMCodec · Inference checkpoints
Single-stream, 50 Hz speech coding at 650 / 800 bps.
Paper · Project page · Reproduction results
This model repository contains the complete ReLMCodec inference release: both codec checkpoints, their matching YAML configs, the frozen W2v-BERT 2.0 parameters embedded in each checkpoint, and the code needed to reconstruct audio. The weights have no optimizer, scheduler, discriminator, or RNG state.
| Variant | Codebook | Rate | Checkpoint | Size | SHA-256 |
|---|---|---|---|---|---|
| 8K | 8,192 | 650 bps | models/relmcodec_8k.pt |
3.13 GB | b55ee1aa176a7a9b3e00b952a07f4932c1770103e6e6e4e4bd91e0d6345d3335 |
| 64K | 65,536 | 800 bps | models/relmcodec_64k.pt |
3.14 GB | 951abb8e1b8af372c963b9ca360c3246ee9ed255a6c0f251018fe3223846231a |
The 8K checkpoint is the 200K perceptual-stage export. The 64K checkpoint is the available 50K additional fine-tune, selected by Log-Mel/PESQ/STOI on a separate 50-file dev set. The closest retained record to the paper's 64K table used an unavailable 30K fine-tune weight. Checkpoint provenance records this distinction and the actual Euclidean VQ assignment rule used by the released weights.
Quick inference
Use Python 3.10 or 3.11 on Linux. From a local snapshot of this model repository:
python -m venv .venv
source .venv/bin/activate
python -m pip install torch==2.9.0 torchaudio==2.9.0 \
--index-url https://download.pytorch.org/whl/cu128
python -m pip install -e .
export USE_TF=0
python scripts/smoke_test.py --variant 64k
python infer.py reconstruct \
--config configs/relmcodec_64k.yaml \
--checkpoint models/relmcodec_64k.pt \
--input input.wav --output reconstructed.wav
The model file and its config must match. Input audio is downmixed and resampled to 16 kHz. infer.py encode saves token IDs; infer.py decode reconstructs them. See Inference for commands and token format.
From the paper
Across 24 representations under a matched quantizer and language model, pre-quantization phoneme separability correlates with next-token accuracy (Spearman ρ = 0.911). Figure 3 shows how ReLMCodec preserves frozen SSL phoneme structure, controls acoustic adaptation with PAPA, and refines the latent space with a training-only WavLM teacher.
These images are cropped from the paper PDF. Table 2 gives the paper's LibriSpeech reconstruction results. The released checkpoints were rerun on all 5,559 test-clean + test-other utterances; verified release results include exact metrics, per-file JSON, and checkpoint hashes. Evaluation gives the reproduction protocol and external WER, SIM, and UTMOS evaluators. Those three external metrics were not freshly rerun for the packaged weights.
Scope and license
These weights are for speech reconstruction and token extraction, with mono 16 kHz input. The paper's predictability probes and downstream TTS models are not included. Code is MIT licensed; third-party notices cover embedded W2v-BERT parameters and vendored components.
@misc{wan2026relmcodec,
title = {ReLMCodec: Designing Predictable Speech Tokens from Pre-Quantization Phoneme Structure},
author = {Zixiang Wan and Xusheng Yang and Zheng Wang and Peiji Yang},
year = {2026},
eprint = {2608.08286},
archivePrefix = {arXiv},
primaryClass = {eess.AS},
url = {https://arxiv.org/abs/2608.08286}
}
Identity and Version
- Repository
- hf-wzx1205/ReLMCodec
- Publisher
- Wanzixiang
- Task
- Not stated by the source
- Modality
- Other
- Library
- Not stated by the source
- Parameters
- Not stated by the source
- Languages
- en
- Revision
- ba3ad9721d933e5e5bc9965df7f080e72b2b26c9
- First published
- 2026-09-25
- Last updated
- 2026-09-25
Files and Weights
58 files, 6.3 GB in total. The weights are 2 files totalling 6.3 GB in pt.
Every file
| File | Type | Size | SHA-256 |
|---|---|---|---|
| models/relmcodec_64k.pt | Weights | 3.1 GB | 951abb8e1b8a |
| models/relmcodec_8k.pt | Weights | 3.1 GB | b55ee1aa176a |
| configs/relmcodec_64k.yaml | Configuration | 658 B | — |
| configs/relmcodec_8k.yaml | Configuration | 657 B | — |
| docs/results/historical_64k_30k.json | Configuration | 3.4 KB | — |
| docs/results/historical_8k_200k.json | Configuration | 3.3 KB | — |
| docs/results/reproduced_64k.json | Configuration | 881.6 KB | — |
| docs/results/reproduced_8k.json | Configuration | 881.7 KB | — |
| evaluate.py | Configuration | 7.5 KB | — |
| infer.py | Configuration | 2.2 KB | — |
| models/w2v-bert-2.0/config.json | Configuration | 2.0 KB | — |
| models/w2v-bert-2.0/preprocessor_config.json | Configuration | 286 B | — |
| relmcodec/__init__.py | Configuration | 209 B | — |
| relmcodec/audio.py | Configuration | 1.0 KB | — |
| relmcodec/checkpoint.py | Configuration | 1.4 KB | — |
| relmcodec/config.py | Configuration | 2.9 KB | — |
| relmcodec/data.py | Configuration | 796 B | — |
| relmcodec/decoder/__init__.py | Configuration | 149 B | — |
| relmcodec/decoder/backbone.py | Configuration | 5.9 KB | — |
| relmcodec/decoder/heads.py | Configuration | 736 B | — |
| relmcodec/decoder/modules.py | Configuration | 7.9 KB | — |
| relmcodec/decoder/spectral_ops.py | Configuration | 3.1 KB | — |
| relmcodec/encoder/__init__.py | Configuration | 166 B | — |
| relmcodec/encoder/w2vbert_encoder.py | Configuration | 2.5 KB | — |
| relmcodec/encoder/xcodec2_encoder.py | Configuration | 722 B | — |
| relmcodec/mel_loss.py | Configuration | 1.6 KB | — |
| relmcodec/model.py | Configuration | 5.7 KB | — |
| relmcodec/quantizer/__init__.py | Configuration | 67 B | — |
| relmcodec/quantizer/vq.py | Configuration | 20.3 KB | — |
| relmcodec/vendor/__init__.py | Configuration | 45 B | — |
| relmcodec/vendor/xcodec2/__init__.py | Configuration | 47 B | — |
| relmcodec/vendor/xcodec2/vq/__init__.py | Configuration | 56 B | — |
| relmcodec/vendor/xcodec2/vq/activations.py | Configuration | 4.5 KB | — |
| relmcodec/vendor/xcodec2/vq/alias_free_torch/__init__.py | Configuration | 199 B | — |
| relmcodec/vendor/xcodec2/vq/alias_free_torch/act.py | Configuration | 854 B | — |
| relmcodec/vendor/xcodec2/vq/alias_free_torch/filter.py | Configuration | 3.5 KB | — |
| relmcodec/vendor/xcodec2/vq/alias_free_torch/resample.py | Configuration | 1.9 KB | — |
| relmcodec/vendor/xcodec2/vq/codec_encoder.py | Configuration | 10.0 KB | — |
| relmcodec/vendor/xcodec2/vq/module.py | Configuration | 14.9 KB | — |
| scripts/download_weights.py | Configuration | 2.8 KB | — |
| scripts/prepare_librispeech_eval.py | Configuration | 2.2 KB | — |
| scripts/score_utmos.py | Configuration | 2.2 KB | — |
| scripts/smoke_test.py | Configuration | 1.8 KB | — |
| LICENSE | Documentation | 1.1 KB | — |
| README.md | Documentation | 4.1 KB | — |
| THIRD_PARTY_NOTICES.md | Documentation | 1.0 KB | — |
| docs/CHECKPOINTS.md | Documentation | 4.4 KB | — |
| docs/EVALUATION.md | Documentation | 6.5 KB | — |
| docs/INFERENCE.md | Documentation | 2.5 KB | — |
| docs/RESULTS.md | Documentation | 3.6 KB | — |
| relmcodec/vendor/xcodec2/LICENSE | Documentation | 1.1 KB | — |
| SHA256SUMS | Other | 181 B | — |
| assets/paper-figure-3-architecture.png | Other | 162.6 KB | 3eb5629eb1c5 |
| assets/paper-table-2-reconstruction.png | Other | 140.7 KB | a3bd6cf2db94 |
| docs/dev_selection_ids.txt | Other | 1.5 KB | — |
| pyproject.toml | Other | 785 B | — |
| requirements.txt | Other | 159 B | — |
| .gitattributes | Repository | 1.7 KB | — |
License and Download
- License
- mit
- Access
- Open weights, no gate
- Download size
- 6.3 GB
Released by Wanzixiang through its official repository on Hugging Face. Read the license.
Built From
- Described by arXiv:2608.08286
Memory Requirements
| Precision | Weights in memory |
|---|---|
| As published | 6.3 GB |
Weights only, from the published parameter count; the key-value cache and runtime add to this.
Questions About ReLMCodec
Can I use ReLMCodec commercially?
Yes. ReLMCodec is released under MIT License. The MIT License is a short permissive license. It permits commercial use, modification and redistribution, provided the copyright notice and permission notice are included.