AudioCraft is an open-source audio processing and generation library under Meta's facebookresearch, based on PyTorch, aimed at deep learning research for audio generation, providing inference and training code.
Purpose AudioCraft is used for deep learning audio generation research, can perform generation tasks such as text-to-music and text-to-sound effects, and includes supporting components such as audio compression/tokenization and audio watermarking.
Main capabilities The repository contains training and inference code for the following models:
- MusicGen: a controllable text-to-music model.
- AudioGen: a text-to-sound effects model.
- EnCodec: a high-fidelity neural audio codec.
- Multi Band Diffusion: a diffusion decoder compatible with EnCodec.
- MAGNeT: a non-autoregressive text-to-music and text-to-sound effects model.
- AudioSeal: audio watermarking.
- MusicGen Style: a text-and-style-to-music model.
- JASCO: a text-to-music model conditioned on chords, melodies, and drum tracks. In addition, AudioCraft provides training code for EnCodec, MusicGen, Multi Band Diffusion, and JASCO, as well as some API documentation.
Usage Environment requirements: Python 3.9, PyTorch 2.1.0; installing ffmpeg is recommended (can be installed via the system or Anaconda). To install AudioCraft, you can run the installation command given in the repository (the materials do not provide the specific command content). Model cache: Hugging Face stores models in a specific location, and the cache location for AudioCraft models can be overridden by setting the AUDIOCRAFT_CACHE_DIR environment variable; adjusting the cache location for other Hugging Face models requires referring to the Hugging Face Transformers documentation; if using models that depend on Demucs (such as musicgen-melody) and you want to change the Demucs download location, you need to refer to the Torch Hub documentation. Training and reproduction: the repository provides AudioCraft training documentation for understanding the design principles and developing your own training pipeline; when reproducing existing work and using the training pipeline, you can refer to the README of each model (such as docs/MUSICGEN.md, docs/AUDIOGEN.md, etc.) for configuration, example grids, model/task information, and FAQ.
Applicable scenarios Suitable for deep learning research and experiments in the direction of audio generation, including tasks such as text-to-music generation, text-to-sound effects generation, audio codec, diffusion decoding, and audio watermarking, as well as carrying out custom training pipelines based on the repository's training code.
Limitations
- The code uses the MIT license; the model weights use the CC-BY-NC 4.0 license, for non-commercial use.
- The repository has no longer been maintained since early 2025.
- The materials do not provide specific descriptions of online demos, fees, prices, platform support scope, or generation results.