Generate songs, instrumentals, or lyrics-driven tracks through a structured OpenClaw-native workflow with anti-sparse prompt engineering and quality verification. Provider-agnostic — works with any music backend the runtime exposes (ACE-Step, MusicGen, Stable Audio, mmx).
Coding
Gen Music
Try itGenerate songs from prompts or lyrics through an ACE-Step-compatible API backend. Use when users want text-to-music, lyrics-to-song, fast prompt iteration, s...
What it does
Generate songs from prompts or lyrics through an ACE-Step-compatible API backend. Use when users want text-to-music, lyrics-to-song, fast prompt iteration, s...
The skill document
ACE-Step Text To Music
Use an ACE-Step-compatible API backend for prompt-to-song and lyrics-to-song requests. This skill does not install or bundle ACE-Step, model weights, or the API server.
Prerequisite
Before using this skill, make sure you already have access to an ACE-Step-compatible API backend. This can be a local server, usually at http://127.0.0.1:8001, or a remote compatible endpoint. If the backend is missing or stopped, this skill cannot generate music.
Quick start
python3 {baseDir}/scripts/generate.py --prompt "playful beach pop song about rising waves"
python3 {baseDir}/scripts/generate.py --prompt "happy indie pop with bright guitars" --lyrics-file /path/to/lyrics.txt --duration 60
Defaults are tuned for fast local iteration:
batch_size=1to avoid duplicate variants unless explicitly requestedaudio_format=mp3sample_mode=text2musicthinking=falseunless the user asks for heavier LM-assisted generation- finished audio is copied into a stable output folder instead of leaving only temp API paths
When to use
- An ACE-Step-compatible API backend is already available, commonly a local server at
http://127.0.0.1:8001but possibly a remote endpoint - The user wants text-to-music, lyrics-to-song, or quick style variations
- The user wants a single command that submits, polls, and returns saved files
- The user wants music generated locally and then played on Clawatch
- The user already has access to a local or remote ACE-Step-compatible backend
Run
# Basic prompt
python3 {baseDir}/scripts/generate.py --prompt "playful synth-pop song about sunrise waves"
# With lyrics
python3 {baseDir}/scripts/generate.py \
--prompt "cute upbeat summer beach song" \
--lyrics-file /path/to/lyrics.txt \
--duration 60
# Two variants
python3 {baseDir}/scripts/generate.py \
--prompt "dreamy city-pop ocean groove" \
--duration 45 \
--batch-size 2
# Enable heavier LM planning only when needed
python3 {baseDir}/scripts/generate.py \
--prompt "cinematic anthem about a storm becoming calm" \
--duration 60 \
--thinking
Useful flags:
--duration 10..600--lyricsor--lyrics-file--batch-size 1..8--thinking--model acestep-v15-turbo--out-dir /path/to/output--base-url http://127.0.0.1:8001for local backends--base-url https://your-remote-endpointfor remote backends
Clawatch playback
If the user also wants the result played on Clawatch:
- Run the generator and wait for the saved output file paths.
- Pick the final
.mp3path from the script output ormanifest.json. - Call
clawatch_play_audiowith:imei: the explicit watch IMEIfilePath: the saved local audio pathtitle: optional short label
Do not pass ACE-Step temp URLs directly if the helper already copied a stable local file. Prefer the saved file path.
Config
The script accepts CLI flags first, then env vars, then OpenClaw skill config.
Supported env vars:
ACESTEP_API_BASE_URLACESTEP_API_KEYACESTEP_OUTPUT_DIR
Use ACESTEP_API_BASE_URL or the OpenClaw config entry to switch between local and remote ACE-Step-compatible backends.
Optional OpenClaw config in ~/.openclaw/openclaw.json:
{
skills: {
entries: {
"gen-music": {
baseUrl: "http://127.0.0.1:8001",
apiKey: "",
outputDir: "~/Projects/tmp/ace-step"
}
}
}
}
Notes
- Check backend health first if needed:
curl http://127.0.0.1:8001/healthor the same path on your remote endpoint - If the API returns temp
/v1/audio?path=...URLs, the helper copies those files into the chosen output directory and writes amanifest.json - Prefer
batch-size 1for efficient prompt iteration; raise it only when the user explicitly wants variants
Related skills
Create original songs, AI-generated music, lyrics-to-song tracks, instrumentals, background music, video soundtracks, jingles, multilingual songs, and reference-led arrangements from a clear creative brief. This AI music generator and AI song maker develops genre, mood, structure, singable lyrics, vocal direction, and production style, then creates reviewable audio with Suno 5.5 or another model you explicitly choose. Use it as an AI music studio for songwriting, an AI lyrics writer, text-to-music creation, BGM generation, brand music, podcast themes, game music, bilingual songs, or focused new versions of reference audio. Review vocals, pronunciation, duration, loop points, and arrangement fit after generation, then refine the strongest result.
Turn complete lyrics, a rough lyric draft, loose lines, or an existing hook into a structured, listenable Suno song. This Suno lyrics-to-song workflow works as an AI song generator from lyrics and AI music generator from lyrics: choose Preserve mode to keep every original line or Refine mode to improve rhythm, rhyme, singability, and hook strength. Build the song structure across verses, chorus, bridge, and purposeful repetition, then create a style prompt for music with genre, mood, arrangement, and vocal direction for Suno custom lyrics. Use it to turn lyrics into a song, make a song from lyrics, convert lyrics to music, get help from a lyrics songwriting assistant, or take rough lyrics to song-ready form through a custom lyrics-to-song process.
Create original songs, AI-generated music, lyrics-to-song tracks, instrumentals, background music, video soundtracks, jingles, multilingual songs, and reference-led arrangements from a clear creative brief. This AI music generator and AI song maker develops genre, mood, structure, singable lyrics, vocal direction, and production style, then creates reviewable audio with Suno 5.5 or another model you explicitly choose. Use it as an AI music studio for songwriting, an AI lyrics writer, text-to-music creation, BGM generation, brand music, podcast themes, game music, bilingual songs, or focused new versions of reference audio. Review vocals, pronunciation, duration, loop points, and arrangement fit after generation, then refine the strongest result.
Music discovery and creative audio planning companion for finding songs, checking singing range, drafting lyrics, and preparing AI music generation briefs.
Crafts Suno style prompts, structured lyrics, and full generation pipelines via API, browser, or manual paste.