feat(music): add structured flags for music generation#34
Merged
MiniMax-AI-Dev merged 2 commits intoMiniMax-AI:mainfrom Apr 6, 2026
Merged
feat(music): add structured flags for music generation#34MiniMax-AI-Dev merged 2 commits intoMiniMax-AI:mainfrom
MiniMax-AI-Dev merged 2 commits intoMiniMax-AI:mainfrom
Conversation
added 2 commits
April 6, 2026 10:48
Add 14 structured flags to music generate command for better UX: --vocals : Vocal style (e.g. "warm male and female duet") --genre : Music genre (e.g. folk, pop, jazz) --mood : Mood or emotion (e.g. warm, melancholic) --instruments : Instruments to feature --tempo : Tempo description (e.g. fast, slow) --bpm : Exact tempo in beats per minute --key : Musical key (e.g. C major, A minor) --use-case : Use case context (e.g. "background music") --structure : Song structure --references : Reference tracks/artists --avoid : Elements to avoid --extra : Additional fine-grained requirements --instrumental: Generate instrumental music (no vocals) --aigc-watermark: Embed AI watermark for provenance Breaking changes: - --instrumental and --lyrics are now mutually exclusive - Use --lyrics "无歌词" or --lyrics "no lyrics" for instrumental This provides full parity with skill's generate_music.sh plus one extra flag (--extra) for any additional requirements.
Add clearer examples showing valid vocal descriptors: - "warm male baritone" (single voice) - "bright female soprano" (single voice) - "duet with harmonies" (multiple voices) This helps users understand what kind of descriptors the model responds to.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add 14 structured flags to
music generatecommand. All flags are merged into--promptbefore the API call — no new API parameters, just structured helpers.Source
Inspired by the skill script
generate_music.shwhich has the same structured parameters (--genre,--mood,--tempo,--bpm,--key,--instruments,--vocals,--use-case,--structure,--avoid,--references) and the same prompt-concatenation logic.New Flags
--vocals"warm male baritone","bright female soprano","duet with harmonies"--genrefolk,pop,jazz--moodwarm,melancholic,uplifting--instruments"acoustic guitar, piano"--tempofast,slow,moderate--bpm95--keyC major,A minor--use-case"background music for video"--structure"verse-chorus-verse-bridge-chorus"--references"similar to Ed Sheeran"--avoid"electronic beats"--instrumental--instrumental--aigc-watermark--aigc-watermark--extra"verse 1 male solo, chorus layered harmonies"Why
--extra(CLI Exclusive)The 12 skill flags cover fixed categories, but real music generation often needs details that don't fit those categories:
verse 1 male solo, verse 2 female solo, chorus with harmoniesbridge builds tension with rising intensityguitar solo with blues slide technique--extrais an open-ended catch-all for these fine-grained requirements.Breaking Changes
--instrumentaland--lyricsare now mutually exclusive (conflicting intent)--lyrics "无歌词"or--lyrics "no lyrics"for instrumental instead--lyrics-filealso conflicts with--instrumentalTesting
9 tests in
test/commands/music/generate.test.ts, all passing.