Bonsai-27B-GGUF
lmstudio-community · Kit
A GGUF conversion of the 27B Bonsai model for LM Studio, with a 3.80 GB Q1_0 language file and a 0.93 GB BF16 vision projector. Tested for text, vision and par…
Generates short music clips from a text description or an audio prompt, in the small checkpoint of facebook's MusicGen. It suits developers and music hobbyists who want to try text-to-music on their own computer.
MusicGen Small is a kit in the Developer category, listed by Mindket. It is free. This is version 1, last updated on . Download it on this page, a zip of its files. Nothing in it runs by itself.
pip install --upgrade pip pip install --upgrade transformers scipy
MusicGen Small is a text-to-music model from facebook. It makes music samples from a written description or an audio prompt. It is one of four released checkpoints, and it predicts all four codebooks of its audio tokens in a single pass.
Developers, hobby producers and audio researchers who want to try music generation from text suit it best. It runs in Python through the transformers library.
| Industry | Who uses it | How they use it | Example |
|---|---|---|---|
| Music production | Hobby producers | Sketch short musical ideas from a written description | A prompt such as happy rock returns a short clip |
| Software development | Developers | Add text-to-music to a Python app through the transformers pipeline | Save the generated audio as a wav file |
| Research | Audio researchers | Study a single-stage music generation model | Compare the four released checkpoints |
Anyone who plans commercial use can skip it, because the license is non-commercial.
You run it yourself in Python, and you can listen to the results in a notebook or save them as files.
| Use case | Who | What they get back |
|---|---|---|
| Text-to-music clips | Hobby producers | A short audio sample that follows the description |
| Two prompts at once | Developers | One mono 32 kHz waveform for each prompt |
| Saving a result | Anyone | A wav file you can open in any audio player |
You need Python with pip, and the transformers library at version 4.31.0 or newer, plus scipy.
pip install --upgrade pip pip install --upgrade transformers scipy
pip install -U huggingface_hub hf download facebook/musicgen-small
The quickest route is the text-to-audio pipeline, which takes a sentence and writes a wav file.
from transformers import pipeline
import scipy
synthesiser = pipeline("text-to-audio", "facebook/musicgen-small")
music = synthesiser("lo-fi music with a soothing melody", forward_params={"do_sample": True})
scipy.io.wavfile.write("musicgen_out.wav", rate=music["sampling_rate"], data=music["audio"])For finer control, use the processor and the generate call from the modelling code. It turns text into a mono 32 kHz waveform.
from transformers import AutoProcessor, MusicgenForConditionalGeneration
processor = AutoProcessor.from_pretrained("facebook/musicgen-small")
model = MusicgenForConditionalGeneration.from_pretrained("facebook/musicgen-small")
inputs = processor(
text=["80s pop track with bassy drums and synth", "90s rock song with loud guitars and heavy drums"],
padding=True,
return_tensors="pt",
)
audio_values = model.generate(**inputs, max_new_tokens=256)| Tool | What it does |
|---|---|
| pipeline | Runs the text-to-audio task in a few lines |
| AutoProcessor | Turns your text prompts into model inputs |
| MusicgenForConditionalGeneration | Loads the model and generates the audio values |
| scipy.io.wavfile.write | Saves the audio as a wav file |
You give the pipeline the prompt "lo-fi music with a soothing melody". It generates a clip and writes it to a wav file named musicgen_out.wav, which you open in any audio player.
You type a sentence that describes the music you want, and the model returns a short audio clip. Your first small try is to run the pipeline snippet with the lo-fi prompt and play the file it saves.
Under the hood, one Transformer predicts audio tokens step by step. The tokens come from an EnCodec tokenizer running at 32 kHz, with four codebooks and a 50 Hz rate. Offsetting the codebooks slightly in time lets the model predict them side by side, which means 50 steps for each second of audio. It needs no separate semantic representation, unlike some earlier methods.
The license limits what you may do with the generated clips.
Generates short music clips from a text description or an audio prompt, in the small checkpoint of facebook's MusicGen. It suits developers and music hobbyists who want to try text-to-music on their own computer.
Made by facebook on Hugging Face. These notes are Mindket's, written from its model page and model card; the model's own files and license are on Hugging Face.
What it is: MusicGen Small is a text-to-music model from facebook. It makes music samples from a written description or an audio prompt. It is one of four released checkpoints, and it predicts all four codebooks of its audio tokens in a single pass.
Who it suits: Developers, hobby producers and audio researchers who want to try music generation from text suit it best. It runs in Python through the transformers library.
Industry | Who uses it | How they use it | Example
Music production | Hobby producers | Sketch short musical ideas from a written description | A prompt such as happy rock returns a short clip
Software development | Developers | Add text-to-music to a Python app through the transformers pipeline | Save the generated audio as a wav file
Research | Audio researchers | Study a single-stage music generation model | Compare the four released checkpoints
Anyone who plans commercial use can skip it, because the license is non-commercial.
Where to use it: You run it yourself in Python, and you can listen to the results in a notebook or save them as files.
Use case | Who | What they get back
Text-to-music clips | Hobby producers | A short audio sample that follows the description
Two prompts at once | Developers | One mono 32 kHz waveform for each prompt
Saving a result | Anyone | A wav file you can open in any audio player
How to set it up: You need Python with pip, and the transformers library at version 4.31.0 or newer, plus scipy.
pip install --upgrade pip
pip install --upgrade transformers scipy
pip install -U huggingface_hub
hf download facebook/musicgen-small
How to use it: The quickest route is the text-to-audio pipeline, which takes a sentence and writes a wav file.
from transformers import pipeline
import scipy
synthesiser = pipeline("text-to-audio", "facebook/musicgen-small")
music = synthesiser("lo-fi music with a soothing melody", forward_params={"do_sample": True})
scipy.io.wavfile.write("musicgen_out.wav", rate=music["sampling_rate"], data=music["audio"])
For finer control, use the processor and the generate call from the modelling code. It turns text into a mono 32 kHz waveform.
from transformers import AutoProcessor, MusicgenForConditionalGeneration
processor = AutoProcessor.from_pretrained("facebook/musicgen-small")
model = MusicgenForConditionalGeneration.from_pretrained("facebook/musicgen-small")
inputs = processor(
text=["80s pop track with bassy drums and synth", "90s rock song with loud guitars and heavy drums"],
padding=True,
return_tensors="pt",
)
audio_values = model.generate(**inputs, max_new_tokens=256)
Tool | What it does
pipeline | Runs the text-to-audio task in a few lines
AutoProcessor | Turns your text prompts into model inputs
MusicgenForConditionalGeneration | Loads the model and generates the audio values
scipy.io.wavfile.write | Saves the audio as a wav file
Example: You give the pipeline the prompt "lo-fi music with a soothing melody". It generates a clip and writes it to a wav file named musicgen_out.wav, which you open in any audio player.
For newcomers and experts: You type a sentence that describes the music you want, and the model returns a short audio clip. Your first small try is to run the pipeline snippet with the lo-fi prompt and play the file it saves.
Under the hood, one Transformer predicts audio tokens step by step. The tokens come from an EnCodec tokenizer running at 32 kHz, with four codebooks and a 50 Hz rate. Offsetting the codebooks slightly in time lets the model predict them side by side, which means 50 steps for each second of audio. It needs no separate semantic representation, unlike some earlier methods.
Text description or audio prompt in
Transformer predicts four codebooks per step
A small delay lets the codebooks run in parallel
Mono 32 kHz audio waveform out
Good to know: The license limits what you may do with the generated clips.
Download its files with Hugging Face's command line:
pip install -U huggingface_hub
hf download facebook/musicgen-small
Then follow the usage in its model card. Nothing in this kit runs by itself.
README.md 6 KB
Listed Hugging Face models in the same category that share the most tags with this one.
| Product | Downloads, last 30 days | Likes | Parameters | License | Last change |
|---|---|---|---|---|---|
| MusicGen Small This page | 184,008 | 532 | 591M | cc-by-nc-4.0 | |
| phonon-31m-enShares text-to-audio · transformers · safetensors | 248,578 | 160 | 41.1M | apache-2.0 | |
| VibeVoice-1.5BShares text-to-audio · transformers · safetensors | 217,923 | 2,520 | 2.7B | mit | |
| ACE-Step 1.5Shares text-to-audio · transformers · safetensors | 98,086 | 952 | — | mit | |
| YuE2-3BShares text-to-audio · safetensors | 22,317 | 1,253 | 3.6B | cc-by-nc-4.0 | |
| MOSS-SoundEffect-v2.0Shares text-to-audio · safetensors | 6,096 | 158 | 1.4B | apache-2.0 |
Posts and comments that name this project on Hacker News, Bluesky, X, Reddit, Facebook and YouTube, found by a weekly search and on Trendshift. Mindket doesn’t write or check them. Open one to read it where it was posted.
lmstudio-community · Kit
A GGUF conversion of the 27B Bonsai model for LM Studio, with a 3.80 GB Q1_0 language file and a 0.93 GB BF16 vision projector. Tested for text, vision and par…
LibertAIDAI · Kit
Runs DeepSeek-V4.1-Flash-1017 as a 2.9 bits-per-weight EXL3 quantization, a 196 GiB copy for people serving large models on their own hardware. Perplexity stay…
alpindale · Kit
Tags every character of C source code for syntax highlighting with a tiny neural network of about 984 weights, run through a small C program. For developers an…
prithivMLmods · Kit
Try a set of LoRAs for the FLUX.2 Klein image model in a Gradio app that runs in your browser or on your own computer. Made for people who make or test AI imag…
Sokheng · Kit
Reads Khmer and English text from documents, receipts and photos of signs, using a detector for text lines and a recogniser for each line. Suits developers who…
Qwen · Kit
Qwen2.5-7B-Instruct as GGUF files in eight quantization sizes, to chat with locally through llama.cpp. For people who want a capable 7.6B model on their own co…