Separate a song into stems
jj_stems_separateUpload a local audio file to start asynchronous stem separation into vocals and instrumental, or four stems (drums, bass, other); then poll the job and download the results.
Instructions
Uploads a local audio file (path, or base64 content) and starts its separation into vocals + instrumental (stems=2) or vocals + drums + bass + other (stems=4) (POST /stem-tool/jobs). Asynchronous and slow (minutes, up to hours for a long file): by default this returns at once with the job, then follow it with jj_stems_get_job and fetch the files with jj_stems_get_file; pass maxWaitMs to wait for a short file instead. Needs the stems:write scope and an API key from a Premium account (403 otherwise). Limits on Premium: a file of at most 1 h 30 and under 2 GB (5 minutes and 100 MB without Premium). Quotas, in UTC days and calendar months, with ONE counter per account shared by both models and by the website: 30 jobs/day and 500/month on Premium (81000 s of audio/day, 540000 s/month). Only one separation can run at a time per account. A 429 states when the counter resets; a 413 means the file is too large or too long. Stems come as MP3 320 kb/s by default, or as FLAC 24-bit with format="flac" (lossless, about 4 times larger). Check jj_stems_capabilities first.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "jj_stems_separate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | Absolute or relative local path to the audio file. Mutually exclusive with contentBase64. | |
| model | No | "fast" (default) or "quality" (SCNet-large, slower, same quota). | |
| stems | No | 2 = vocals + instrumental (default); 4 = vocals + drums + bass + other. | |
| format | No | "mp3" (default, 320 kb/s) or "flac" (24-bit lossless, for mixing or mastering). | |
| filename | No | File name (with extension). Required with contentBase64; defaults to the basename of "path". | |
| maxWaitMs | No | Wait up to this long (milliseconds, cap 600000) for the separation to finish. Default 0: return at once. Waiting needs a key with convert:read, otherwise the job is returned at once. The job keeps running if it is exceeded. | |
| contentBase64 | No | Base64-encoded audio content. Mutually exclusive with path. Requires "filename". |