Replicate nateraw/musicgen-songstarter-v0.2
AI-generated loops for producers
- input_audio
- AUDIO
This isn't general-purpose MusicGen - it's a version fine-tuned specifically to spit out short instrumental loops you can build a track around: drum-and-melody starters for producers who want a seed idea rather than a finished song. nateraw fine-tuned it on top of Meta's MusicGen and put it on Replicate; this node calls that hosted model. Type a genre/mood/instrument description, get back a short audio loop.
Notice the schema has no required inputs at all - every field, including prompt, is optional. You genuinely can queue this node with nothing set and it'll generate something (an unguided default loop), though in practice you'll almost always want to at least fill in a prompt to point it somewhere specific.
How it works
MusicGen generates audio as discrete tokens conditioned on your text description (and optionally an audio clip), sampling its way through a sequence the way a language model samples text tokens, then decoding that sequence back into waveform. The songstarter fine-tune biases it toward short, loopable, producer-friendly output rather than full compositions. Everything runs on Replicate - you send the request, get AUDIO back.
The inputs and outputs that matter
prompt- describe the loop: genre, instruments, mood, tempo. More specific gets you more usable results ("dark trap beat, 808 bass, hi-hats, moody piano" beats "cool beat").input_audio- feed an existing clip to continue or reference instead of generating from scratch.continuation(default false) pluscontinuation_start/continuation_end- when true, treatsinput_audioas something to extend from a specific point rather than just a style reference.duration(default 8, seconds) - how long the loop runs.output_format(defaultwav, ormp3).
Sampling knobs: top_k (250), top_p (0, meaning it samples via top-k by default, not nucleus sampling), temperature (1), classifier_free_guidance (3) - leave these at defaults until you have a reason to touch them. normalization_strategy (default loudness, also clip/peak/rms) controls how the output level gets normalized. seed and force_rerun round it out. Output is AUDIO.
How to install it
One install covers every node in this pack.
cd ComfyUI/custom_nodes
git clone https://github.com/replicate/comfyui-replicate
cd comfyui-replicate
pip install -r requirements.txt
Restart, or via ComfyUI Manager: search ComfyUI-Replicate, install, restart. Set your token first:
export REPLICATE_API_TOKEN="r8_************"; python main.py
Token from replicate.com/account/api-tokens. Nothing runs locally - this is entirely Replicate's compute.
Common issues & troubleshooting
Flag this up front: the pack's README states it's built for models returning simple text or image output and specifically warns that audio-returning models "will not work as expected" - audio support is called out as still on the roadmap. This node returns AUDIO, so if saving or previewing the clip acts up, that's the pack's documented rough edge, not something wrong with your workflow.
Node errors immediately. Missing REPLICATE_API_TOKEN in the environment ComfyUI launched from - the most common first-run issue in this whole pack. On portable Windows builds specifically, a token set as a global environment variable has been reported not to get picked up automatically; set it in the launch .bat instead.
Loop sounds generic. Put more detail in the prompt before touching sampling parameters - instruments, genre, tempo, mood get you further than adjusting temperature or classifier_free_guidance.
Continuation didn't work as expected. continuation has to be explicitly set to true, and continuation_start/continuation_end need to point at valid points inside input_audio - leaving these unset while expecting an extension is the usual mistake.
Cost adds up on iteration. A longer duration and more variations both mean more billed Replicate predictions - iterate short, extend once you like the direction.
Inputs (14)
| Name | Type | Default | Description |
|---|---|---|---|
| promptopt | STRING | — | |
| input_audioopt | AUDIO | — | |
| durationopt | INT | 8 | — |
| continuationopt | BOOLEAN | false | — |
| continuation_startopt | INT | 0 | — |
| continuation_endopt | INT | — | |
| normalization_strategyopt | COMBO | loudness | 4 options: loudness, clip, peak, rms |
| top_kopt | INT | 250 | — |
| top_popt | FLOAT | 0.00 | — |
| temperatureopt | FLOAT | 1.00 | — |
| classifier_free_guidanceopt | INT | 3 | — |
| output_formatopt | COMBO | wav | 2 options: wav, mp3 |
| seedopt | INT | — | |
| force_rerunopt | BOOLEAN | false | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| AUDIO | AUDIO | — |