# Meta AudioCraft (MusicGen, AudioGen) — card for AI agents

Meta's self-hosted MusicGen and AudioGen models; code MIT, weights CC BY-NC 4.0.

Category: AI music and sound generators · maker Meta (FAIR) · checked 2026-10-20

## Price
- Price: Free
- Free tier: Free open weights.

## License
Code MIT; weights CC-BY-NC 4.0 — https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights

- commercial: **no** (Non-commercial only)
  > reproduce and Share the Licensed Material, in whole or in part, for NonCommercial purposes only
  (https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights)
- attribution: **required** (Credit required)
  > If You Share the Licensed Material (including in modified form), You must:
  (https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights)
- in app: **conditions** (Ship inside your app with conditions)
  > produce, reproduce, and Share Adapted Material for NonCommercial purposes only
  (https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights)
- youtube: **conditions** (Monetized YouTube with conditions)
  > produce, reproduce, and Share Adapted Material for NonCommercial purposes only
  (https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights)

## Rules to follow
- Use the weights for non-commercial purposes only; treat monetized output as not allowed.

## Can an AI agent use it by itself?
**No** · package: Agent installs a package or loads it from a CDN

## How an agent gets files
- Self-hosted: python -m pip install -U audiocraft (needs Python 3.9 and PyTorch 2.1.0); weights download from the model hub on first use. (sign-in: none)
- Not allowed: Model weights are CC-BY-NC 4.0: non-commercial use only.
- Not allowed: Code is MIT; the weights are under a separate license (LICENSE_weights).
- Not allowed: Attribution under CC BY: creator, copyright notice, license link, and a note if modified.

## How to connect
- Package (npm/PyPI)
- PyPI: `pip install audiocraft`
- Repository: https://github.com/facebookresearch/audiocraft
- Website: https://github.com/facebookresearch/audiocraft

## Numbers (AgentGid data)
- Gid Score: 22
- GitHub stars: 23,973
- Downloads last week: 2,041

## Lines to paste into your prompt or AGENTS.md

```
- Meta AudioCraft (MusicGen, AudioGen) (AI music and sound generators). Meta's self-hosted MusicGen and AudioGen models; code MIT, weights CC BY-NC 4.0. Price: free; non-commercial only; credit required; ship inside your app with conditions.
  Connect: PyPI audiocraft.
  Get files: Self-hosted: python -m pip install -U audiocraft (needs Python 3.9 and PyTorch 2.1.0); weights download from the model hub on first use.
  Not allowed: Model weights are CC-BY-NC 4.0: non-commercial use only.
  Not allowed: Code is MIT; the weights are under a separate license (LICENSE_weights).
  Not allowed: Attribution under CC BY: creator, copyright notice, license link, and a note if modified.
  Rule: Use the weights for non-commercial purposes only; treat monetized output as not allowed.
  License: https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights (checked 2026-10-20; details: https://agentgid.com/assets/audiocraft/)
```

Not verified: Whether output from NC weights counts as commercial use is a legal question.

## Links
- AgentGid page: https://agentgid.com/assets/audiocraft/
- Is it free for commercial use? https://agentgid.com/assets/audiocraft/commercial-use/
- Source: https://github.com/facebookresearch/audiocraft
- Source: https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights


## AudioCraft: music and sound effects from text, self-hosted

AudioCraft is Meta's free research toolkit for making audio with AI. Its MusicGen model writes short music clips from a text description, and AudioGen makes sound effects such as a dog barking. You run it on your own computer with a strong graphics card, and the ready models may only be used for non-commercial work.

### Where to use it
- Music clips from a description: Type a short description such as "sad jazz" or "energetic EDM" and get a few seconds of music without vocals for a student film, a game jam or a prototype.
- Sound effects from a description: Describe a sound, for example footsteps in a corridor or a siren, and get a short clip of it for a video or a game level you build for fun.
- Music that follows a tune: Hum or upload a melody, and get music in a new style that follows that tune, for example a rock version of a classical piece.
- Try it in a local web page: Start a small page on your own computer where you type a description and listen to the result, before writing any code.
- Research on audio models: Train your own music or sound models, or study how the released ones behave, with the training code Meta provides.
- Placeholder music in prototypes: Fill a game or app prototype with temporary music while you test it, then replace it with licensed tracks before any paid release. (idea, not from the official pages)

### How to start
- On a computer with a graphics card, install PyTorch 2.1.0 first and then AudioCraft. ffmpeg is also recommended.

```
python -m pip install 'torch==2.1.0'
python -m pip install setuptools wheel
python -m pip install -U audiocraft  # stable release
```

- Load a model by name and generate audio from text. The model files download by themselves on first use.

```
model = MusicGen.get_pretrained('facebook/musicgen-melody')
model.set_generation_params(duration=8)  # generate 8 seconds.
```


### License
The AudioCraft code is MIT and may be used in any project. The ready-made model weights are CC BY-NC 4.0, so they are for non-commercial use only and need credit when shared.

### Good to know
- You need a graphics card. Meta recommends 16 GB of graphics memory; smaller cards can make short clips with the small model.
- MusicGen cannot make realistic singing, and it works best with English descriptions.
- Meta built MusicGen for research and says it should not go into products without further checks of its risks.
- The last release on the Python package index is 1.3.0 from June 2024, and it requires exactly PyTorch 2.1.0.

Checked 2026-11-12 against: https://github.com/facebookresearch/audiocraft, https://github.com/facebookresearch/audiocraft/blob/main/README.md, https://github.com/facebookresearch/audiocraft/blob/main/LICENSE, https://github.com/facebookresearch/audiocraft/blob/main/LICENSE_weights, https://github.com/facebookresearch/audiocraft/blob/main/docs/MUSICGEN.md, https://github.com/facebookresearch/audiocraft/blob/main/docs/AUDIOGEN.md, https://github.com/facebookresearch/audiocraft/blob/main/model_cards/MUSICGEN_MODEL_CARD.md, https://pypi.org/pypi/audiocraft/json

### Mistakes to avoid
- Don't: pip install audiocraft into an environment that already has a newer PyTorch → Do: Install torch==2.1.0 first in a fresh environment, then audiocraft (The package pins torch==2.1.0 and xformers, which must match the installed PyTorch.)
- Don't: Treating the MIT license of the code as permission to sell or monetize the generated music → Do: Use the released weights only for non-commercial work, or pick a model whose weights allow commercial use (The weights are under CC BY-NC 4.0, separate from the MIT code.)
- Don't: Calling generate_with_chroma on facebook/musicgen-small → Do: Use facebook/musicgen-melody or musicgen-melody-large for melody-guided music (Only the melody models take a tune as input; small, medium and large are text to music only.)
- Don't: Writing prompts in other languages or asking for sung lyrics → Do: Write descriptions in English and plan for instrumental results (The model was trained on English descriptions with vocals removed.)

### Questions
- Can I use music made with it in a monetized video or a paid app? Not with the released weights. They are CC BY-NC 4.0, which allows only non-commercial use.
- Does it run without a graphics card? Meta says you must have a graphics card to run MusicGen locally.
- Can it sing? No. The training music had its vocals removed, and the model card says it cannot make realistic vocals.
- Which MusicGen model should I start with? Meta names the medium and melody models as the best balance of quality and computing cost; the small one fits smaller cards.
- Where are the model files stored? In the Hugging Face cache; set AUDIOCRAFT_CACHE_DIR to choose another folder.

---
AgentGid's catalog is curated: every entry was checked against the maker's official pages (registry, repository, license and pricing pages) on the date shown; a license value shows the quote it stands on wherever AgentGid has one. Usage numbers come from AgentGid's own scan of public repositories set up for AI coding agents. Claims by makers are reported, not tested by AgentGid.
