跳到正文
Skillpedia
音频与语音75k · #2652

elevenlabs

它能做什么

这项技能使用 ElevenLabs 生成音频,包括旁白、对话、音效和音乐。适合需要为视频、播客或游戏配上声音的创作者。

适用场景

  • ✓当你需要为视频或播客制作配音或旁白时。
  • ✓当你想根据一段文字描述生成一个音效时。
  • ✓当你的项目需要背景音乐或配乐时。

技能链接

https://github.com/calesthio/OpenMontage/blob/main/.agents/skills/elevenlabs/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/calesthio/OpenMontage/blob/main/.agents/skills/elevenlabs/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请帮我用亲切的声音,以温暖的语气为我的产品视频朗读这段脚本。”

每周 5 个新技能,1 分钟读完。

工作原理

智能体会选择声音或音效选项,把文字或描述发送给 ElevenLabs,然后保存生成的音频文件。如果团队已有统一设置,这项技能会使用集中管理的服务商,而不会再要求你提供密钥。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

ElevenLabs Audio Generation

Current v4 transports

For v4, v4 Turbo, Instant Soundtracks and realtime models, read the October integration guide. v4 uses Text to Dialogue; Turbo uses the dialogue WebSocket. Do not send those models to the legacy text-to-speech endpoint.

OpenMontage provider routing

Inspect the OpenMontage registry before choosing an authentication path.

  • Prefer fal_elevenlabs_tts when it is available. It provides Eleven v3, Multilingual v2, and Turbo v2.5 through the centrally managed fal.ai connection; no separate ElevenLabs credential is needed.
  • Use elevenlabs_tts only when that direct provider is already reported as available by the registry.
  • In a shared installation, never tell the user to create a .env, export a key, or paste a credential. Report missing direct-provider access as an administrator setup request.

The direct API examples below require a centrally configured ELEVENLABS_API_KEY; they are not the default path when the fal.ai provider is available.

Text-to-Speech

from elevenlabs.client import ElevenLabs
from elevenlabs import save, VoiceSettings
import os

client = ElevenLabs(api_key=os.getenv("ELEVENLABS_API_KEY"))

audio = client.text_to_speech.convert(
    text="Welcome to my video!",
    voice_id="JBFqnCBsd6RMkjVDRZzb",
    model_id="eleven_multilingual_v2",
    voice_settings=VoiceSettings(
        stability=0.5,
        similarity_boost=0.75,
        style=0.5,
        speed=1.0
    )
)
save(audio, "voiceover.mp3")

Models

Model Quality SSML Support Notes
eleven_multilingual_v2 Highest consistency None Stable, production-ready, 29 languages
eleven_flash_v2_5 Good <break>, <phoneme> Fast, supports pause/pronunciation tags
eleven_turbo_v2_5 Good <break>, <phoneme> Fastest latency
eleven_v3 Most expressive None Alpha — unreliable, needs prompt engineering

Choose: multilingual_v2 for reliability, flash/turbo for SSML control, v3 for maximum expressiveness (expect retakes).

Voice Settings by Style

Style stability similarity style speed
Natural/professional 0.75-0.85 0.9 0.0-0.1 1.0
Conversational 0.5-0.6 0.85 0.3-0.4 0.9-1.0
Energetic/YouTuber 0.3-0.5 0.75 0.5-0.7 1.0-1.1

Pauses Between Sections

With flash/turbo models: Use SSML break tags inline:

...end of section. <break time="1.5s" /> Start of next...

Max 3 seconds per break. Excessive breaks can cause speed artifacts.

With multilingual_v2 / v3: No SSML support. Options:

  • Paragraph breaks (blank lines) — creates ~0.3-0.5s natural pause
  • Post-process with ffmpeg: split audio and insert silence

WARNING: ... (ellipsis) is NOT a reliable pause — it can be vocalized as a word/sound. Do not use ellipsis as a pause mechanism.

Pronunciation Control

Phonetic spelling (any model): Write words as you want them pronounced:

  • Janus → Jan-us
  • nginx → engine-x
  • Use dashes, capitals, apostrophes to guide pronunciation

SSML phoneme tags (flash/turbo only):

<phoneme alphabet="ipa" ph="ˈdʒeɪnəs">Janus</phoneme>

Iterative Workflow

  1. Generate → listen → identify pronunciation/pacing issues
  2. Adjust: phonetic spellings, break tags, voice settings
  3. Regenerate. If pauses aren't precise enough, add silence in post with ffmpeg rather than fighting the TTS engine.

Voice Cloning

Instant Voice Clone

with open("sample.mp3", "rb") as f:
    voice = client.voices.ivc.create(
        name="My Voice",
        files=[f],
        remove_background_noise=True
    )
print(f"Voice ID: {voice.voice_id}")
  • Use client.voices.ivc.create() (not client.voices.clone())
  • Pass file handles in binary mode ("rb"), not paths
  • Convert m4a first: ffmpeg -i input.m4a -codec:a libmp3lame -qscale:a 2 output.mp3
  • Multiple samples (2-3 clips) improve accuracy
  • Save voice ID for reuse

Professional Voice Clone: Requires Creator plan+, 30+ min audio. See reference.md.

Sound Effects

Max 22 seconds per generation.

result = client.text_to_sound_effects.convert(
    text="Thunder rumbling followed by heavy rain",
    duration_seconds=10,
    prompt_influence=0.3
)
with open("thunder.mp3", "wb") as f:
    for chunk in result:
        f.wr
常见问题

我一定要有自己的 ElevenLabs 密钥吗?

不一定。如果有集中管理的服务商,这项技能会优先使用;如果没有,它会请管理员完成设置。

它可以克隆声音吗?

可以。声音克隆是这项技能涵盖的音频任务之一。

它使用哪些模型?

它涵盖较新的 v4 模型和较早的文本转语音接口,并说明每个模型需要使用哪个接口。

详情

作者的原始描述

Generate AI voiceovers, sound effects, and music using ElevenLabs APIs. Use when creating audio content for videos, podcasts, or games. Triggers include generating voiceovers, narration, dialogue, sound effects from descriptions, background music, soundtrack generation, voice cloning, or any audio synthesis task.

repo: calesthio/OpenMontage

热度

GitHub 星标
75k
排名
#2652
许可证
AGPL-3.0
更新时间
2026/10/28

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能