lyria — Claude Code skill: generate music with Google Lyria
A skill for Claude Code and Codex that builds prompts and checks music from Google Lyria through the Gemini API. Fits into OpenMontage google_music calls and audio prep for video.
AGPL-3.0 ★ 78,316 updated 2026-11-10
npx skills add calesthio/OpenMontage --skill lyria -a claude-codeWhat lyria does
The lyria skill walks through a fixed workflow before any generation call. First the role gets confirmed: underscore, loop, instrumental cue, or full song. Then vocals, language, target duration, structure, and delivery format.\n\nPrompts follow a nine-part contract: purpose and duration, genre and era, tempo and harmony, instrumentation, sectioned structure, dynamics tied to edit times, vocal policy, mix and ending, exclusions. Instrumental-only output has a ready-made block that bans vocals, choir, humming, and spoken samples. Custom lyrics go into a separate Lyrics: block with section labels, and performance direction sits above it.\n\nDuration is treated as untrusted until probed. The OpenMontage adapter bounds requests to 5–184 seconds, but its duration_seconds field is the request, not a media probe. The skill checks the actual file with ffprobe. For exact-duration video work it keeps the provider source untouched, trims at a musical boundary, applies a short fade, and probes the master again. A Gemini key is required before use; GOOGLE_API_KEY takes precedence over GEMINI_API_KEY when both are set.
What it helps with
- build a structured prompt for Lyria 3.5 or Clip
- measure the real duration of a generated file
- produce an instrumental track with no vocal artifacts
- fit music to an exact video timestamp
- diagnose a failed Lyria call
Example prompts for the agent
- Prepare a Lyria prompt for a 30-second instrumental loop as video background
- Generate a song with female vocals in Spanish, lyrics in a Lyrics block
- Check output.mp3 with ffprobe and report the actual duration
How to install lyria
1Skills CLI (Vercel)
npx skills add calesthio/OpenMontage --skill lyria -a claude-code2Manually: put the files in place
~/.claude/skills/lyria/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/lyria/
1Skills CLI (Vercel)
npx skills add calesthio/OpenMontage --skill lyria -a codex2Manually: put the files in place
.agents/skills/lyria/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add calesthio/OpenMontage --skill lyria -a cursor2Manually: put the files in place
.cursor/skills/lyria/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install calesthio/OpenMontage .agents/skills/lyria2Manually: put the files in place
.github/skills/lyria/SKILL.md1Skills CLI (Vercel)
npx skills add calesthio/OpenMontage --skill lyria -a gemini-cli2Platform CLI
gemini skills install https://github.com/calesthio/OpenMontage --path .agents/skills/lyriaManually: put the files in place
.devin/skills/lyria/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about lyria
How do I install lyria in Claude Code?
Run npx skills add calesthio/OpenMontage --skill lyria -a claude-code. The skill file lands in ~/.claude/skills/lyria/SKILL.md.
How do I install lyria in Codex?
Run npx skills add calesthio/OpenMontage --skill lyria -a codex. The skill file lands in .agents/skills/lyria/SKILL.md.
Which Lyria models does the skill cover?
lyria-3-clip-preview for iterations and 30-second loops, lyria-3.5 for full songs with vocals. The OpenMontage google_music adapter accepts model="lyria-3.5" or model="lyria-3-pro-preview"; Clip and RealTime do not route through it.
How does the skill verify track duration?
With an ffprobe command that outputs JSON: codec, bitrate, sample rate, channels, and duration. The adapter's duration_seconds field is the requested length, not a probe.