Instructions to use MusicForge/magnet-medium-8bit with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use MusicForge/magnet-medium-8bit with MLX:
# Download the model from the Hub pip install huggingface_hub[hf_xet] hf download MusicForge/magnet-medium-8bit --local-dir magnet-medium-8bit
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Atomic Chat
|
Download README.md from MusicForge/magnet-medium-8bit: direct link, hf CLI and curl.
- Browser
- Download file 1.94 kB
-
https://huggingface.co/MusicForge/magnet-medium-8bit/resolve/main/README.md
- Command line
-
hf download hf://MusicForge/magnet-medium-8bit/README.md
-
curl -L -o README.md https://huggingface.co/MusicForge/magnet-medium-8bit/resolve/main/README.md
1.94 kB
metadata
license: cc-by-nc-4.0
language:
- en
tags:
- mlx
- audio
- music
- text-to-music
- magnet
- quantized
- int8
base_model: facebook/magnet-medium-30secs
library_name: mlx
pipeline_tag: text-to-audio
MAGNeT-Medium-30secs-MLX-8bit
- speech-swift — Apple SDK
- soniqo.audio — website
- blog — blog
MLX port of Meta's MAGNeT — a masked parallel text-to-music model — quantized to INT8 weight-only for on-device generation on Apple Silicon. EnCodec 32 kHz audio decoder; T5-base text encoder; per-codebook iterative decoding with restricted-context self-attention.
Model
| Parameters (LM) | 1.5B |
| Quantization | INT8 weight-only, group size 64 |
| Format | MLX safetensors |
| Sample rate | 32 kHz mono |
| Output length | 30 s per generation (fixed) |
| Decoding steps | 50 total ([20, 10, 10, 10] across 4 RVQ codebooks) |
| Bundle size | 2221 MB on disk |
| Source | facebook/magnet-medium-30secs |
Performance (Apple Silicon, 30 s audio)
| Metric | Value |
|---|---|
| Real-time factor (wall / audio) | 1.20 |
| Peak RSS | 3045 MB |
| CLAP score (laion/clap-htsat-unfused, 5 prompts) | 0.345 |
Usage
from huggingface_hub import snapshot_download
bundle = snapshot_download("aufklarer/MAGNeT-Medium-30secs-MLX-8bit")
# See https://github.com/soniqo/speech-swift for production usage.
Source
- Upstream: facebook/magnet-medium-30secs
- Paper: MAGNeT (arxiv 2401.04577)
- Audiocraft: facebookresearch/audiocraft
License
CC-BY-NC 4.0 — inherited from upstream MAGNeT weights. Non-commercial use only.