Audio generation with gen-ai (CLI & MCP)
Audio is the cheapest modality — typically cents per line — and the fastest to iterate on. This skill covers every audio task you can accomplish via the Picsart gen-ai CLI or the @picsart/gen-ai-mcp MCP server.
When to use
Activate whenever the user asks to:
- Record / generate a voiceover, VO, narration, spoken line, ad read, or podcast intro
- Produce an explainer voice, audiobook snippet, dialogue, or character read
- Localize speech across languages
- Clone a voice or dub an existing line (speech-to-speech)
- Generate music — backing track, jingle, sting, loop
- Generate SFX — UI sounds, whooshes, impacts, ambiences
- Sync audio to a video (video-to-audio / foley)
CLI vs MCP — both work
- CLI when installed — best for scripting multi-market batches, JSON output, and video-audio handoff.
- MCP server (
@picsart/gen-ai-mcp) when the user is in Claude Code, Codex, Cursor, Windsurf, or ChatGPT and the CLI isn't installed — the agent calls gen-ai_generate natively.
Model selection cheat sheet
Run gen-ai models --mode audio to see current models.
| Model / alias |
Type |
Strength |
When to pick |
eleven-v3 |
TTS |
Highest-quality ElevenLabs voice |
Hero voiceovers, ads, product intros |
eleven-multilingual-v2 |
TTS |
32 languages, consistent voice across locales |
Localized campaigns |
eleven-sts-v2 |
STS |
Speech-to-speech — same voice, new words |
Dubbing, voice matching |
eleven-multilingual-sts-v2 |
STS |
Multilingual speech-to-speech |
Localized dubbing |
elevenlabs-sfx |
SFX |
Sound effects from text |
UI sounds, stingers, Foley |
minimax-music-v2 |
Music |
Text-to-music (with structure) |
Backing tracks, jingles, reels |
kling-t2a |
T2A |
Alt text-to-audio |
Provider diversity for music/SFX |
kling-v2a |
V2A |
Generate audio that matches a video |
Sync foley / ambient sound to a clip |
Future-proofing: when new audio models arrive (e.g., new ElevenLabs voice families), gen-ai models --mode audio reflects them. Honor specific voices/models the user names; otherwise pick by intent.
Quick decision tree
Single voiceover line? → eleven-v3
Localized voiceover across markets? → eleven-multilingual-v2 (batch)
Dub / voice-match an existing take? → eleven-sts-v2 (pass --audio source.mp3)
Backing music for a reel? → minimax-music
UI / foley sound effect? → elevenlabs-sfx
Music-fill a video automatically? → kling-v2a (pass --video clip.mp4)
Produce a podcast intro? → eleven-v3 + minimax-music stems; optional editor/local mix
Prompting best practices
Voice (TTS) — the character line is everything
Every VO prompt has three layers: voice character, delivery, and the text itself. Missing any one produces robotic output.
- Voice character:
warm, calm, 30s female, mid-range, confident — describe the persona you want.
- Delivery:
measured pace, friendly / urgent, energetic / intimate, breathy.
- The text: end every sentence with proper punctuation. Commas and periods determine pacing. Ellipses = pause.
Template:
[VOICE_CHARACTER] [DELIVERY_NOTE] [TEXT]
Example:
warm, calm, 30s female, mid-range, confident. measured pace, friendly tone.
"Welcome to Picsart. Generate anything, from your terminal."
For ad reads: write short sentences. Voice models read punctuation literally — a long run-on sentence will rush.
Music — genre, tempo, mood, structure
Specify all four:
- Genre:
lo-fi piano, synthwave, orchestral, trap, acoustic folk.
- Tempo: BPM —
80bpm, 128bpm.
- Mood:
melancholy, triumphant, meditative, tense.
- Structure (optional):
intro swells, drops at :15, outro fades.
Example:
lo-fi piano, rainy evening, 80bpm, melancholy. intro swells, soft drum enters at :10, outro fades.
For reel backing tracks, target 30s (--duration 30 where supported).
SFX — short and literal
SFX prompts should be concrete and named:
glass shatter, close mic, high frequency
whoosh, fast sweep, low-to-high pitch
UI confirm ding, short, high quality, clean
heavy mechanical thunk, bass, reverb
Under 1 second unless you explicitly want a longer ambience.
Common recipes
Single voiceover line
gen-ai generate -m eleven-v3 \
-p "warm, calm, 30s female, confident, measured pace. \"Welcome to Picsart. Generate anything, from your terminal.\"" \
--json --no-input | jq -r '.url' | xargs curl -L -o vo.mp3
Voiceover with a specific voice
gen-ai generate -m eleven-v3 --voice 21m00Tcm4TlvDq8ikWAM \
-p "\"Welcome. Let's build.\"" \
--json --no-input | jq -r '.url' | xargs curl -L -o vo.mp3
# See available voices:
gen-ai models info eleven-v3
Multilingual VO (5 markets, one batch)
cat > voice.json <<EOF
{
"defaults": { "model": "eleven-multilingual-v2" },
"jobs": [
{ "id": "en", "prompt": "Welcome to the show." },
{ "id": "de", "prompt": "Willkommen zur Show." },
{ "id": "ja", "prompt": "ようこそ、ショーへ。" },
{ "id": "pt", "prompt": "Bem-vindo ao show." },
{ "id": "es", "prompt": "Bienvenido al show." }
]
}
EOF
gen-ai batch run voice.json -o ./voice
Voice cloning / dubbing (STS)
Preserve a voice identity; change the words:
gen-ai generate -m eleven-sts-v2 \
--audio source-take.mp3 \
-p "\"This is the new line that should sound exactly like the source voice.\"" \
--json --no-input | jq -r '.url' | xargs curl -L -o new-line.mp3
For localized dubbing with voice consistency:
gen-ai generate -m eleven-multilingual-sts-v2 \
--audio source-en.mp3 --locale de \
-p "\"Neue Zeile auf Deutsch.\"" \
--json --no-input | jq -r '.url' | xargs curl -L -o new-line-de.mp3
Backing music for a 30s reel
gen-ai generate -m minimax-music \
-p "upbeat confident synth, 120bpm, uplifting. intro drums, melody enters at :08, outro fades." \
--duration 30 --json --no-input | jq -r '.url' | xargs curl -L -o music.mp3
SFX set for a UI
cat > ui-sfx.json <<EOF
{
"defaults": { "model": "elevenlabs-sfx" },
"jobs": [
{ "id": "confirm", "prompt": "soft UI confirm ding, short, high quality" },
{ "id": "error", "prompt": "subtle UI error buzz, short, low frequency" },
{ "id": "success", "prompt": "bright UI success chime, short, cheerful" },
{ "id": "hover", "prompt": "very subtle UI hover tick, tiny" }
]
}
EOF
gen-ai batch run ui-sfx.json -o ./sfx
Auto-matched audio for a video
gen-ai generate -m kling-v2a --video reel.mp4 --json --no-input \
| jq -r '.url' | xargs curl -L -o reel-with-sound.mp4
Podcast intro — voice + music stems
# 1. VO line
gen-ai generate -m eleven-v3 \
-p "warm, confident, energetic. \"This week on the show…\"" \
--json --no-input | jq -r '.url' | xargs curl -L -o intro-vo.mp3
# 2. Backing music
gen-ai generate -m minimax-music \
-p "cinematic opener, 110bpm, rising, 8s" --duration 8 \
--json --no-input | jq -r '.url' | xargs curl -L -o intro-music.mp3
# 3. Deliver intro-vo.mp3 + intro-music.mp3 as stems, or mix in any DAW/editor.
# Optional preview mix if you already have ffmpeg:
ffmpeg -i intro-music.mp3 -i intro-vo.mp3 \
-filter_complex "[1:a]volume=1.0[a1];[0:a]volume=0.35[a0];[a0][a1]amix=inputs=2:duration=longest" \
-c:a libmp3lame intro.mp3
MCP / natural-language patterns
When the CLI isn't installed, the MCP server gives the agent the same capabilities:
- "Voice this line in a warm, confident read with Eleven v3: 'Welcome to Picsart.' Save as vo.mp3."
- "Localize this ad read across DE, FR, JP, BR, ES using Eleven Multilingual v2 — one batch."
- "Dub this source take into German, preserving the same voice character. Use Eleven STS."
- "Generate a 30-second uplifting synth backing track at 120bpm. Use MiniMax Music."
- "Make me a set of 4 UI sounds: confirm, error, success, hover. Short, clean."
- "Add AI-matched foley to reel.mp4."
The agent should:
- Always include the voice character line for TTS — without it, reads sound robotic.
- Batch multilingual requests rather than firing N serial calls.
- Prefer
eleven-v3 as the default TTS unless the user names another voice.
- Call
gen-ai_pricing on large batches (50+ lines) — character counts add up.
Voice catalog
ElevenLabs models accept --voice <id>:
gen-ai models info eleven-v3 # list available voices
gen-ai config set defaultModel eleven-v3 # set the default model if desired
Popular voice archetypes (IDs rotate; always verify with models info):
- Warm, mid-30s female, US English — default ad-read voice
- Deep, mid-40s male, US English — authoritative narration
- Bright, 20s female, US English — explainer / onboarding
- Neutral, 30s, RP British English — editorial / product launch
- Japanese / Spanish / German native speakers — see
models info eleven-multilingual-v2
Cost control
Audio is cheap, but character counts add up on campaigns:
- Eleven v3 / Multilingual v2: ~1 credit per 250 characters
- Eleven STS: ~2 credits per 250 characters (costlier — voice-preserving)
- ElevenLabs SFX: ~1 credit per SFX
- MiniMax Music: ~5 credits per 30 seconds
- Kling T2A / V2A: varies — check pricing first
Check pricing and validate manifests before large batches:
gen-ai pricing eleven-multilingual-v2
gen-ai pricing minimax-music
gen-ai batch run voice.json --dry-run
Output hygiene
- Format:
.mp3 for web delivery; .wav when downstream editing needs lossless; .m4a for iOS-first.
- Loudness: generated assets are usable as-is; normalize in a DAW/editor when needed. Optional local polish if ffmpeg is already available:
ffmpeg -i in.mp3 -af loudnorm=I=-16:LRA=11:TP=-1.5 out.mp3.
- Silence trim: trim in a DAW/editor when needed. Optional local trim if ffmpeg is already available:
ffmpeg -af silenceremove=1:0:-50dB.
- Stereo vs mono: VO is usually mono; music stereo. TTS models emit mono by default.
Troubleshooting
| Symptom |
Fix |
| Robotic / flat read |
Add the voice-character line and delivery note at the start of the prompt |
| Wrong emphasis |
Add explicit punctuation — commas = micro-pauses, periods = full stops, ellipses = long pause |
| Pronunciation off |
Spell the word phonetically in the prompt, e.g., "Pics-Art" instead of "Picsart" |
| Voice drifts across lines |
Use eleven-multilingual-v2 (consistent-voice mode) or STS for the whole batch |
| Music too "AI-sounding" |
Add structure cues ("intro swells at :05") and a concrete genre, not just a mood |
| SFX is too long |
Add "short" and "tight" to the prompt; trim in post if needed |
| V2A audio mismatches video |
Use kling-v2a with a clean --video source — compressed / low-res video degrades matching |
| Multilingual voice sounds off |
Use the multilingual variant (eleven-multilingual-v2), not the base eleven-v3 |
For agents
- Default TTS:
eleven-v3 unless the user specifies another voice.
- For ads and marketing, always include the voice-character line — without it, reads sound robotic.
- For multilingual, prefer one batch over N serial calls — saves latency and keeps voice identity consistent.
- For STS (dubbing), require the source audio via
--audio — STS cannot generate a voice from scratch.
- If the CLI isn't installed and MCP is available, call MCP tools directly.
- Never assume a voice ID — look it up via
gen-ai models info eleven-v3 or the gen-ai_model_info MCP tool before committing.
1---2name: gen-ai-audio3description: Generate audio via the Picsart gen-ai CLI or MCP server. AUTO-TRIGGER whenever the user asks to record / generate / create / produce a voiceover, voice-over, VO, narration, spoken line, ad read, explainer voice, podcast intro, audiobook snippet, dialogue, music track, backing track, jingle, sting, sound effect, SFX, UI sound, foley, or multi-language speech; or wants ElevenLabs voices, MiniMax Music, Kling T2A/V2A, speech-to-speech dubbing, or localized voiceovers.4---56# Audio generation with gen-ai (CLI & MCP)78Audio is the cheapest modality — typically cents per line — and the fastest to iterate on. This skill covers **every audio task** you can accomplish via the Picsart gen-ai CLI or the `@picsart/gen-ai-mcp` MCP server.910## When to use1112Activate whenever the user asks to:1314- Record / generate a voiceover, VO, narration, spoken line, ad read, or podcast intro15- Produce an explainer voice, audiobook snippet, dialogue, or character read16- Localize speech across languages17- Clone a voice or dub an existing line (speech-to-speech)18- Generate music — backing track, jingle, sting, loop19- Generate SFX — UI sounds, whooshes, impacts, ambiences20- Sync audio to a video (video-to-audio / foley)2122## CLI vs MCP — both work2324- **CLI** when installed — best for scripting multi-market batches, JSON output, and video-audio handoff.25- **MCP server** (`@picsart/gen-ai-mcp`) when the user is in Claude Code, Codex, Cursor, Windsurf, or ChatGPT and the CLI isn't installed — the agent calls `gen-ai_generate` natively.2627## Model selection cheat sheet2829Run `gen-ai models --mode audio` to see current models.3031| Model / alias | Type | Strength | When to pick |32|---|---|---|---|33| `eleven-v3` | TTS | Highest-quality ElevenLabs voice | Hero voiceovers, ads, product intros |34| `eleven-multilingual-v2` | TTS | 32 languages, consistent voice across locales | Localized campaigns |35| `eleven-sts-v2` | STS | Speech-to-speech — same voice, new words | Dubbing, voice matching |36| `eleven-multilingual-sts-v2` | STS | Multilingual speech-to-speech | Localized dubbing |37| `elevenlabs-sfx` | SFX | Sound effects from text | UI sounds, stingers, Foley |38| `minimax-music-v2` | Music | Text-to-music (with structure) | Backing tracks, jingles, reels |39| `kling-t2a` | T2A | Alt text-to-audio | Provider diversity for music/SFX |40| `kling-v2a` | V2A | Generate audio that matches a video | Sync foley / ambient sound to a clip |4142**Future-proofing:** when new audio models arrive (e.g., new ElevenLabs voice families), `gen-ai models --mode audio` reflects them. Honor specific voices/models the user names; otherwise pick by intent.4344## Quick decision tree4546```47Single voiceover line? → eleven-v348Localized voiceover across markets? → eleven-multilingual-v2 (batch)49Dub / voice-match an existing take? → eleven-sts-v2 (pass --audio source.mp3)50Backing music for a reel? → minimax-music51UI / foley sound effect? → elevenlabs-sfx52Music-fill a video automatically? → kling-v2a (pass --video clip.mp4)53Produce a podcast intro? → eleven-v3 + minimax-music stems; optional editor/local mix54```5556## Prompting best practices5758### Voice (TTS) — the character line is everything5960Every VO prompt has **three layers**: voice character, delivery, and the text itself. Missing any one produces robotic output.61621. **Voice character**: `warm, calm, 30s female, mid-range, confident` — describe the persona you want.632. **Delivery**: `measured pace, friendly` / `urgent, energetic` / `intimate, breathy`.643. **The text**: end every sentence with proper punctuation. Commas and periods determine pacing. Ellipses = pause.6566**Template:**67```68[VOICE_CHARACTER] [DELIVERY_NOTE] [TEXT]69```7071**Example:**72```73warm, calm, 30s female, mid-range, confident. measured pace, friendly tone.7475"Welcome to Picsart. Generate anything, from your terminal."76```7778For ad reads: write short sentences. Voice models read punctuation literally — a long run-on sentence will rush.7980### Music — genre, tempo, mood, structure8182Specify all four:83841. **Genre**: `lo-fi piano`, `synthwave`, `orchestral`, `trap`, `acoustic folk`.852. **Tempo**: BPM — `80bpm`, `128bpm`.863. **Mood**: `melancholy`, `triumphant`, `meditative`, `tense`.874. **Structure** (optional): `intro swells`, `drops at :15`, `outro fades`.8889**Example:**90```91lo-fi piano, rainy evening, 80bpm, melancholy. intro swells, soft drum enters at :10, outro fades.92```9394For reel backing tracks, target 30s (`--duration 30` where supported).9596### SFX — short and literal9798SFX prompts should be concrete and named:99100- `glass shatter, close mic, high frequency`101- `whoosh, fast sweep, low-to-high pitch`102- `UI confirm ding, short, high quality, clean`103- `heavy mechanical thunk, bass, reverb`104105Under 1 second unless you explicitly want a longer ambience.106107## Common recipes108109### Single voiceover line110111```bash112gen-ai generate -m eleven-v3 \113 -p "warm, calm, 30s female, confident, measured pace. \"Welcome to Picsart. Generate anything, from your terminal.\"" \114 --json --no-input | jq -r '.url' | xargs curl -L -o vo.mp3115```116117### Voiceover with a specific voice118119```bash120gen-ai generate -m eleven-v3 --voice 21m00Tcm4TlvDq8ikWAM \121 -p "\"Welcome. Let's build.\"" \122 --json --no-input | jq -r '.url' | xargs curl -L -o vo.mp3123124# See available voices:125gen-ai models info eleven-v3126```127128### Multilingual VO (5 markets, one batch)129130```bash131cat > voice.json <<EOF132{133 "defaults": { "model": "eleven-multilingual-v2" },134 "jobs": [135 { "id": "en", "prompt": "Welcome to the show." },136 { "id": "de", "prompt": "Willkommen zur Show." },137 { "id": "ja", "prompt": "ようこそ、ショーへ。" },138 { "id": "pt", "prompt": "Bem-vindo ao show." },139 { "id": "es", "prompt": "Bienvenido al show." }140 ]141}142EOF143gen-ai batch run voice.json -o ./voice144```145146### Voice cloning / dubbing (STS)147148Preserve a voice identity; change the words:149150```bash151gen-ai generate -m eleven-sts-v2 \152 --audio source-take.mp3 \153 -p "\"This is the new line that should sound exactly like the source voice.\"" \154 --json --no-input | jq -r '.url' | xargs curl -L -o new-line.mp3155```156157For localized dubbing with voice consistency:158159```bash160gen-ai generate -m eleven-multilingual-sts-v2 \161 --audio source-en.mp3 --locale de \162 -p "\"Neue Zeile auf Deutsch.\"" \163 --json --no-input | jq -r '.url' | xargs curl -L -o new-line-de.mp3164```165166### Backing music for a 30s reel167168```bash169gen-ai generate -m minimax-music \170 -p "upbeat confident synth, 120bpm, uplifting. intro drums, melody enters at :08, outro fades." \171 --duration 30 --json --no-input | jq -r '.url' | xargs curl -L -o music.mp3172```173174### SFX set for a UI175176```bash177cat > ui-sfx.json <<EOF178{179 "defaults": { "model": "elevenlabs-sfx" },180 "jobs": [181 { "id": "confirm", "prompt": "soft UI confirm ding, short, high quality" },182 { "id": "error", "prompt": "subtle UI error buzz, short, low frequency" },183 { "id": "success", "prompt": "bright UI success chime, short, cheerful" },184 { "id": "hover", "prompt": "very subtle UI hover tick, tiny" }185 ]186}187EOF188gen-ai batch run ui-sfx.json -o ./sfx189```190191### Auto-matched audio for a video192193```bash194gen-ai generate -m kling-v2a --video reel.mp4 --json --no-input \195 | jq -r '.url' | xargs curl -L -o reel-with-sound.mp4196```197198### Podcast intro — voice + music stems199200```bash201# 1. VO line202gen-ai generate -m eleven-v3 \203 -p "warm, confident, energetic. \"This week on the show…\"" \204 --json --no-input | jq -r '.url' | xargs curl -L -o intro-vo.mp3205206# 2. Backing music207gen-ai generate -m minimax-music \208 -p "cinematic opener, 110bpm, rising, 8s" --duration 8 \209 --json --no-input | jq -r '.url' | xargs curl -L -o intro-music.mp3210211# 3. Deliver intro-vo.mp3 + intro-music.mp3 as stems, or mix in any DAW/editor.212# Optional preview mix if you already have ffmpeg:213ffmpeg -i intro-music.mp3 -i intro-vo.mp3 \214 -filter_complex "[1:a]volume=1.0[a1];[0:a]volume=0.35[a0];[a0][a1]amix=inputs=2:duration=longest" \215 -c:a libmp3lame intro.mp3216```217218## MCP / natural-language patterns219220When the CLI isn't installed, the MCP server gives the agent the same capabilities:221222- *"Voice this line in a warm, confident read with Eleven v3: 'Welcome to Picsart.' Save as vo.mp3."*223- *"Localize this ad read across DE, FR, JP, BR, ES using Eleven Multilingual v2 — one batch."*224- *"Dub this source take into German, preserving the same voice character. Use Eleven STS."*225- *"Generate a 30-second uplifting synth backing track at 120bpm. Use MiniMax Music."*226- *"Make me a set of 4 UI sounds: confirm, error, success, hover. Short, clean."*227- *"Add AI-matched foley to reel.mp4."*228229The agent should:2302311. Always include the **voice character** line for TTS — without it, reads sound robotic.2322. Batch multilingual requests rather than firing N serial calls.2333. Prefer `eleven-v3` as the default TTS unless the user names another voice.2344. Call `gen-ai_pricing` on large batches (50+ lines) — character counts add up.235236## Voice catalog237238ElevenLabs models accept `--voice <id>`:239240```bash241gen-ai models info eleven-v3 # list available voices242gen-ai config set defaultModel eleven-v3 # set the default model if desired243```244245**Popular voice archetypes** (IDs rotate; always verify with `models info`):246247- Warm, mid-30s female, US English — default ad-read voice248- Deep, mid-40s male, US English — authoritative narration249- Bright, 20s female, US English — explainer / onboarding250- Neutral, 30s, RP British English — editorial / product launch251- Japanese / Spanish / German native speakers — see `models info eleven-multilingual-v2`252253## Cost control254255Audio is cheap, but character counts add up on campaigns:256257- **Eleven v3 / Multilingual v2**: ~1 credit per 250 characters258- **Eleven STS**: ~2 credits per 250 characters (costlier — voice-preserving)259- **ElevenLabs SFX**: ~1 credit per SFX260- **MiniMax Music**: ~5 credits per 30 seconds261- **Kling T2A / V2A**: varies — check pricing first262263Check pricing and validate manifests before large batches:264265```bash266gen-ai pricing eleven-multilingual-v2267gen-ai pricing minimax-music268gen-ai batch run voice.json --dry-run269```270271## Output hygiene272273- **Format**: `.mp3` for web delivery; `.wav` when downstream editing needs lossless; `.m4a` for iOS-first.274- **Loudness**: generated assets are usable as-is; normalize in a DAW/editor when needed. Optional local polish if ffmpeg is already available: `ffmpeg -i in.mp3 -af loudnorm=I=-16:LRA=11:TP=-1.5 out.mp3`.275- **Silence trim**: trim in a DAW/editor when needed. Optional local trim if ffmpeg is already available: `ffmpeg -af silenceremove=1:0:-50dB`.276- **Stereo vs mono**: VO is usually mono; music stereo. TTS models emit mono by default.277278## Troubleshooting279280| Symptom | Fix |281|---|---|282| Robotic / flat read | Add the voice-character line and delivery note at the start of the prompt |283| Wrong emphasis | Add explicit punctuation — commas = micro-pauses, periods = full stops, ellipses = long pause |284| Pronunciation off | Spell the word phonetically in the prompt, e.g., "Pics-Art" instead of "Picsart" |285| Voice drifts across lines | Use `eleven-multilingual-v2` (consistent-voice mode) or STS for the whole batch |286| Music too "AI-sounding" | Add structure cues ("intro swells at :05") and a concrete genre, not just a mood |287| SFX is too long | Add "short" and "tight" to the prompt; trim in post if needed |288| V2A audio mismatches video | Use `kling-v2a` with a clean `--video` source — compressed / low-res video degrades matching |289| Multilingual voice sounds off | Use the multilingual variant (`eleven-multilingual-v2`), not the base `eleven-v3` |290291## For agents292293- **Default TTS**: `eleven-v3` unless the user specifies another voice.294- **For ads and marketing**, always include the voice-character line — without it, reads sound robotic.295- **For multilingual**, prefer one batch over N serial calls — saves latency and keeps voice identity consistent.296- **For STS (dubbing)**, require the source audio via `--audio` — STS cannot generate a voice from scratch.297- **If the CLI isn't installed and MCP is available**, call MCP tools directly.298- **Never assume a voice ID** — look it up via `gen-ai models info eleven-v3` or the `gen-ai_model_info` MCP tool before committing.