audiocraft-audio-generation

Generate music and sound effects from text prompts using Meta's AudioCraft models.

1|Updated Aug 11, 2026
One-click install
npx skills add https://github.com/Chia1104/agent-air --skill audiocraft-audio-generation-chia1104
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: audiocraft-audio-generation
Source: https://github.com/Chia1104/agent-air/tree/main/skills/hermes/mlops/models/audiocraft
Command: npx skills add https://github.com/Chia1104/agent-air --skill audiocraft-audio-generation-chia1104

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires audiocraft, torch, transformers, and includes references (resource) components.

What problem does it solve? Creating original music tracks or sound effects normally requires audio production skills, licensed samples, or expensive tools. This Skill lets you generate music, sound effects, and compressed audio directly from text descriptions using Meta's AudioCraft models (MusicGen, AudioGen, EnCodec). ## Core Features & Use Cases - Text-to-Music with MusicGen: Generate music from text prompts with melody conditioning, stereo output, and style transfer via MusicGen-Style, in model sizes from 300M to 3.3B parameters. - Text-to-Sound with AudioGen: Produce sound effects and environmental audio such as thunderstorms, traffic, or footsteps from natural language descriptions. - Audio Compression with EnCodec: Encode and decode audio with a high-fidelity neural codec, including streaming and custom bandwidth settings. - Use Case: A game developer needs background music and ambient sound effects for a prototype. Use this Skill to generate a 30-second orchestral loop with MusicGen and batch-produce footstep and explosion effects with AudioGen, saving each as a WAV file. ## Quick Start Use the audiocraft skill to generate a 10-second upbeat electronic music track from a text description and save it as a WAV file.

Frequently Asked Questions about audiocraft-audio-generation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate music from text with MusicGen?▼

Load a pretrained model with MusicGen.get_pretrained('facebook/musicgen-small'), set generation parameters like duration and temperature, then call model.generate with a list of text descriptions. Save the returned waveform with torchaudio.save at 32000 Hz.

What is the difference between MusicGen and AudioGen?▼

MusicGen generates music from text prompts and supports melody conditioning and stereo output at 32kHz. AudioGen generates sound effects and environmental audio from text at 16kHz. Choose based on whether you need musical content or sound design.

Can I use AudioCraft through HuggingFace Transformers?▼

Yes, MusicGen is available in Transformers as MusicgenForConditionalGeneration with AutoProcessor. Note that parameter names differ: use guidance_scale instead of cfg_coef and max_new_tokens instead of duration.

How much GPU memory does MusicGen need?▼

MusicGen-small needs about 4GB VRAM in FP32 or 2GB in FP16, medium needs about 8GB/4GB, and large needs about 16GB/8GB. Reduce duration or use a smaller model if you hit CUDA out-of-memory errors.

Why is my generated audio silent or poor quality?▼

Silent output usually means the waveform needs normalization to a target loudness. Poor quality improves with a larger model, higher cfg_coef for text adherence, lower temperature, and more specific prompts describing genre, instruments, and tempo.

When should I use Stable Audio or Bark instead of AudioCraft?▼

Use Stable Audio for longer commercial music generation and Bark for text-to-speech combined with music or sound effects. AudioCraft fits text-to-music, melody-conditioned generation, and sound effect synthesis up to about 30 seconds.