mcpField
E
elevenlabs-music

elevenlabs-music

github.com/inference-sh创意与媒体789799 次安装2 周前更新
代码仓库

关于 elevenlabs-music

elevenlabs-music 是一项通过 inference.sh CLI 根据文本提示生成音乐的技能,面向需要配乐的音视频创作者。它支持描述音乐风格并设置生成时长,涵盖背景音乐、影视配乐和游戏音频等示例。

主要功能

  1. 01根据文本提示生成音乐
  2. 02设置生成时长
  3. 03提示中描述流派、情绪与乐器
  4. 04提供音乐与旁白工作流示例

适用场景

  1. 01为视频制作背景配乐
  2. 02制作播客片头或片尾音乐
  3. 03为游戏制作主题音乐
  4. 04为演示文稿添加背景音乐

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/inference-sh/skills --skill elevenlabs-music

安装后在 Claude Code 中输入/elevenlabs-music确认已加载。

详细介绍

安装 belt CLI 技能: npx skills add belt-sh/cli

ElevenLabs 音乐生成

通过 inference.sh CLI,根据文本提示生成原创音乐。

音乐生成

快速开始

需要 inference.sh CLI(belt)。安装说明

belt login

# Generate music
belt app run elevenlabs/music --input '{"prompt": "Upbeat electronic dance track with driving synths"}'

参数

参数类型默认值描述
prompt字符串必填对所需音乐的描述(最多 2000 个字符)
duration_seconds数字30时长,单位为秒(5-600,最长 10 分钟)

示例

背景音乐
# Lo-fi study beats
belt app run elevenlabs/music --input '{
  "prompt": "Lo-fi hip hop beat, chill study music, vinyl crackle, mellow piano",
  "duration_seconds": 120
}'

# Corporate background
belt app run elevenlabs/music --input '{
  "prompt": "Light corporate background music, positive, motivational, clean",
  "duration_seconds": 60
}'
电影配乐
# Epic trailer
belt app run elevenlabs/music --input '{
  "prompt": "Epic cinematic orchestral score, dramatic build-up, brass and strings, trailer music",
  "duration_seconds": 45
}'

# Suspense
belt app run elevenlabs/music --input '{
  "prompt": "Dark suspenseful score, tension building, minimal piano, horror atmosphere",
  "duration_seconds": 60
}'
特定流派
# Jazz
belt app run elevenlabs/music --input '{
  "prompt": "Smooth jazz quartet, saxophone lead, walking bass, brushed drums",
  "duration_seconds": 90
}'

# Electronic
belt app run elevenlabs/music --input '{
  "prompt": "Techno beat, 128 BPM, driving bass, atmospheric synths, club music",
  "duration_seconds": 120
}'

# Acoustic
belt app run elevenlabs/music --input '{
  "prompt": "Acoustic guitar folk song, fingerpicking, warm and intimate",
  "duration_seconds": 60
}'
短视频内容
# Podcast intro (10 seconds)
belt app run elevenlabs/music --input '{
  "prompt": "Podcast intro jingle, professional, tech-themed, catchy",
  "duration_seconds": 10
}'

# Social media clip
belt app run elevenlabs/music --input '{
  "prompt": "Trendy upbeat pop, social media vibe, energetic, youthful",
  "duration_seconds": 15
}'

# Notification sound
belt app run elevenlabs/music --input '{
  "prompt": "Short positive notification melody, clean, satisfying",
  "duration_seconds": 5
}'
游戏音频
# Battle theme
belt app run elevenlabs/music --input '{
  "prompt": "Intense battle music, fast tempo, orchestral with electric guitar, boss fight",
  "duration_seconds": 120
}'

# Exploration theme
belt app run elevenlabs/music --input '{
  "prompt": "Peaceful exploration music, fantasy RPG, harp and flute, magical atmosphere",
  "duration_seconds": 180
}'

# Menu music
belt app run elevenlabs/music --input '{
  "prompt": "Ambient menu screen music, sci-fi, ethereal synths, space theme",
  "duration_seconds": 60
}'

提示词技巧

流派:流行、摇滚、电子、爵士、古典、嘻哈、lo-fi、氛围音乐、管弦乐、民谣、R&B、金属、乡村

情绪:欢快、悲伤、充满活力、平静、戏剧性、史诗感、神秘、振奋、黑暗、浪漫、紧张

乐器:钢琴、吉他、合成器、鼓、贝斯、弦乐、铜管乐器、合唱团、萨克斯管、小提琴、长笛、竖琴

节奏:慢速、中速、快速、80 BPM、120 BPM、140 BPM

风格:电影感、极简、层次丰富、氛围感、节奏鲜明、旋律优美、氛围音乐

工作流:音乐 + 配音

# 1. Generate background music
belt app run elevenlabs/music --input '{
  "prompt": "Soft ambient background music for narration, non-intrusive",
  "duration_seconds": 60
}' > music.json

# 2. Generate voiceover
belt app run elevenlabs/tts --input '{
  "text": "Welcome to our product tour. Let me show you what we have built.",
  "voice": "george"
}' > voice.json

# 3. Mix together (no inference.sh app mixes audio; use ffmpeg locally)
curl -L -o music.mp3 "<music-url>"
curl -L -o voice.mp3 "<voice-url>"
ffmpeg -i voice.mp3 -i music.mp3 -filter_complex \
  "[1]volume=0.2[bg];[0][bg]amix=inputs=2:duration=first" mixed.mp3

使用场景

  • 视频制作:背景配乐、转场
  • 播客:片头/片尾、段落间隔
  • 游戏:原声音乐、菜单音乐、战斗主题曲
  • 广告:广告短曲、商业背景音乐
  • 社交媒体:适用于短视频内容的热门音频
  • 演示文稿:专业背景音乐
  • 电影:配乐、营造氛围

相关技能

# ElevenLabs sound effects (combine with music)
npx skills add inference-sh/skills@elevenlabs-sound-effects

# ElevenLabs TTS (add voice over music)
npx skills add inference-sh/skills@elevenlabs-tts

# Other music models (Diffrythm, Tencent)
npx skills add inference-sh/skills@ai-music-generation

# Full platform skill (all apps)
npx skills add inference-sh/skills@infsh-cli

浏览所有音频应用:belt app list --category audio

评论

支持 Markdown