Instructions to use mlx-community/SongGeneration-v2-large with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use mlx-community/SongGeneration-v2-large with MLX:
# Download the model from the Hub pip install huggingface_hub[hf_xet] huggingface-cli download --local-dir SongGeneration-v2-large mlx-community/SongGeneration-v2-large
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
Update default README.md
Browse files
README.md
CHANGED
|
@@ -14,10 +14,12 @@ tags:
|
|
| 14 |
|
| 15 |
Part of the SongGeneration MLX conversion set. Collection: https://huggingface.co/collections/mlx-community/songgeneration-v2-mlx-6a1bf9342dd0806419737229
|
| 16 |
|
| 17 |
-
# SongGeneration-v2-large
|
| 18 |
|
| 19 |
Apple MLX weights for the autoregressive `audiolm` token generator from Tencent SongGeneration v2-large.
|
| 20 |
|
|
|
|
|
|
|
| 21 |
This is not a full-stack pure MLX audio pipeline yet: token generation runs with MLX, while FLAC decoding currently uses the official PyTorch Flow1dVAE / separate-tokenizer bridge in [`ailuntx/SongGeneration-MLX`](https://github.com/ailuntx/SongGeneration-MLX).
|
| 22 |
|
| 23 |
## TL;DR
|
|
@@ -40,10 +42,10 @@ python -m venv .venv
|
|
| 40 |
.venv/bin/pip install -e .
|
| 41 |
.venv/bin/pip install -U huggingface_hub hf_transfer
|
| 42 |
|
| 43 |
-
HF_HUB_ENABLE_HF_TRANSFER=1 .venv/bin/hf download mlx-community/SongGeneration-v2-large
|
| 44 |
|
| 45 |
.venv/bin/python -m songgeneration_mlx.cli \
|
| 46 |
-
--model ./models/SongGeneration-v2-large
|
| 47 |
--lyrics '[verse] hello from mlx [chorus] sing it again' \
|
| 48 |
--description 'Pop, female vocal, bright production, [Musicality-medium].' \
|
| 49 |
--duration 2 \
|
|
@@ -70,7 +72,7 @@ HF_HUB_ENABLE_HF_TRANSFER=1 .venv/bin/hf download tencent/SongGeneration \
|
|
| 70 |
|
| 71 |
PYTORCH_ENABLE_MPS_FALLBACK=1 SONGGEN_DEVICE=mps \
|
| 72 |
.venv-decoder/bin/python scripts/decode_tokens_official.py \
|
| 73 |
-
--mlx-model ./models/SongGeneration-v2-large
|
| 74 |
--tokens ./tokens_2s.npz \
|
| 75 |
--output ./output_2s.flac \
|
| 76 |
--device mps
|
|
@@ -85,7 +87,8 @@ PYTORCH_ENABLE_MPS_FALLBACK=1 SONGGEN_DEVICE=mps \
|
|
| 85 |
| `SongGeneration-v2-medium-8bit` | 2.8G | smaller medium checkpoint |
|
| 86 |
| `SongGeneration-v2-medium-4bit` | 1.5G | smallest medium checkpoint |
|
| 87 |
| `SongGeneration-v2-large-fp32` | 19G | high-precision large baseline |
|
| 88 |
-
| `SongGeneration-v2-large
|
|
|
|
| 89 |
| `SongGeneration-v2-large-8bit` | 5.0G | smaller large checkpoint |
|
| 90 |
| `SongGeneration-v2-large-4bit` | 2.7G | smallest large checkpoint |
|
| 91 |
| `SongGeneration-v2-fast-*` | pending | upstream fast weights were not publicly available when checked on 2026-05-31 |
|
|
@@ -93,7 +96,7 @@ PYTORCH_ENABLE_MPS_FALLBACK=1 SONGGEN_DEVICE=mps \
|
|
| 93 |
## Layout
|
| 94 |
|
| 95 |
```text
|
| 96 |
-
SongGeneration-v2-large
|
| 97 |
|-- model-00001-of-000xx.safetensors
|
| 98 |
|-- model.safetensors.index.json
|
| 99 |
|-- config.json
|
|
|
|
| 14 |
|
| 15 |
Part of the SongGeneration MLX conversion set. Collection: https://huggingface.co/collections/mlx-community/songgeneration-v2-mlx-6a1bf9342dd0806419737229
|
| 16 |
|
| 17 |
+
# SongGeneration-v2-large
|
| 18 |
|
| 19 |
Apple MLX weights for the autoregressive `audiolm` token generator from Tencent SongGeneration v2-large.
|
| 20 |
|
| 21 |
+
This default repository is the bf16 variant and is equivalent to [`mlx-community/SongGeneration-v2-large-bf16`](https://huggingface.co/mlx-community/SongGeneration-v2-large-bf16). Use this repo when you want the recommended default checkpoint.
|
| 22 |
+
|
| 23 |
This is not a full-stack pure MLX audio pipeline yet: token generation runs with MLX, while FLAC decoding currently uses the official PyTorch Flow1dVAE / separate-tokenizer bridge in [`ailuntx/SongGeneration-MLX`](https://github.com/ailuntx/SongGeneration-MLX).
|
| 24 |
|
| 25 |
## TL;DR
|
|
|
|
| 42 |
.venv/bin/pip install -e .
|
| 43 |
.venv/bin/pip install -U huggingface_hub hf_transfer
|
| 44 |
|
| 45 |
+
HF_HUB_ENABLE_HF_TRANSFER=1 .venv/bin/hf download mlx-community/SongGeneration-v2-large --local-dir ./models/SongGeneration-v2-large
|
| 46 |
|
| 47 |
.venv/bin/python -m songgeneration_mlx.cli \
|
| 48 |
+
--model ./models/SongGeneration-v2-large \
|
| 49 |
--lyrics '[verse] hello from mlx [chorus] sing it again' \
|
| 50 |
--description 'Pop, female vocal, bright production, [Musicality-medium].' \
|
| 51 |
--duration 2 \
|
|
|
|
| 72 |
|
| 73 |
PYTORCH_ENABLE_MPS_FALLBACK=1 SONGGEN_DEVICE=mps \
|
| 74 |
.venv-decoder/bin/python scripts/decode_tokens_official.py \
|
| 75 |
+
--mlx-model ./models/SongGeneration-v2-large \
|
| 76 |
--tokens ./tokens_2s.npz \
|
| 77 |
--output ./output_2s.flac \
|
| 78 |
--device mps
|
|
|
|
| 87 |
| `SongGeneration-v2-medium-8bit` | 2.8G | smaller medium checkpoint |
|
| 88 |
| `SongGeneration-v2-medium-4bit` | 1.5G | smallest medium checkpoint |
|
| 89 |
| `SongGeneration-v2-large-fp32` | 19G | high-precision large baseline |
|
| 90 |
+
| `SongGeneration-v2-large` | 9.5G | default large checkpoint, same weights as bf16 |
|
| 91 |
+
| `SongGeneration-v2-large-bf16` | 9.5G | explicit large bf16 quality baseline |
|
| 92 |
| `SongGeneration-v2-large-8bit` | 5.0G | smaller large checkpoint |
|
| 93 |
| `SongGeneration-v2-large-4bit` | 2.7G | smallest large checkpoint |
|
| 94 |
| `SongGeneration-v2-fast-*` | pending | upstream fast weights were not publicly available when checked on 2026-05-31 |
|
|
|
|
| 96 |
## Layout
|
| 97 |
|
| 98 |
```text
|
| 99 |
+
SongGeneration-v2-large/
|
| 100 |
|-- model-00001-of-000xx.safetensors
|
| 101 |
|-- model.safetensors.index.json
|
| 102 |
|-- config.json
|