简介
ElevenLabs Voice Design 从文字 prompt 生成全新合成嗓音 —— 描述年龄、口音、性别、活力、音色,拿到独有的、你拥有的、能在 TTS API 里复用的嗓音。不需要源音频、没克隆同意问题。适合音频小说角色、播客主持人、没真实参考嗓音的应用人物、嗓音库稀薄的语言。在 ElevenLabs Voice Lab 仪表盘或 API 用。装机时间 5 分钟。
API 生成嗓音
import requests, json
resp = requests.post(
"https://api.elevenlabs.io/v1/voice-generation/generate-voice",
headers={"xi-api-key": os.environ["ELEVENLABS_API_KEY"]},
json={
"voice_description": "一位苏格兰老人,嗓音温暖带烟熏感 —— 像退休船长在炉火边讲故事",
"text": "Aye, that was the night the lighthouse went dark, and we were three miles off the rocks.",
},
)
generated_voice_id = resp.headers["voice_id"]
with open("preview.mp3", "wb") as f:
f.write(resp.content)把设计存到嗓音库
requests.post(
"https://api.elevenlabs.io/v1/voice-generation/create-voice",
headers={"xi-api-key": API_KEY},
json={
"voice_name": "Captain Hamish",
"voice_description": "苏格兰老船长,温暖带烟熏",
"generated_voice_id": generated_voice_id,
"labels": {"accent": "Scottish", "age": "elderly", "use": "narration"},
},
)在 TTS 里用存好的嗓音
from elevenlabs.client import ElevenLabs
from elevenlabs import play
client = ElevenLabs()
audio = client.text_to_speech.convert(
voice_id="Captain Hamish", # 嗓音库里的名字或 ID
model_id="eleven_turbo_v2_5",
text="Ah, you wouldn't believe what we saw that morning on Skye.",
)
play(audio)好用的 prompt 模板
| 目标 | Prompt 模板 |
|---|---|
| 旁白 | "Calm, mid-40s, neutral American accent, warm timbre" |
| 活力主持 | "High-energy mid-20s podcast host, slight rasp, fast pace" |
| 权威感 | "Deep-voiced 50s news anchor, RP British accent, measured" |
| 儿童角色 | "8-year-old curious child, light pitch, occasional giggle" |
| 反派 | "Cold, controlled, low-pitched, slight whisper, mid-30s" |
成本
Voice Design 生成约 1,000 credit 一次(preview);保存嗓音免费;TTS 使用按标准字符费率。Starter 套餐($5/月)覆盖约 50 个设计。
FAQ
Q: 生成的嗓音商用免版权吗? A: 是 —— Voice Design 生成的嗓音按你套餐绑定的 ElevenLabs 商用授权归你。看当前条款 —— Creator 及以上明确允许商用发布。免费档仅非商用。
Q: 生成后能微调吗? A: 能 —— 保存的嗓音有 stability 和 similarity 滑块。要更剧烈变化就用更精细的描述文本重新 prompt Voice Design。平台不允许直接混合两个设计的嗓音,但迭代 prompt 接近。
Q: 跟克隆真人嗓音比? A: Voice Cloning 需要 1-3 分钟源音频和同意;输出贴近源。Voice Design 只要 prompt;输出是全新合成嗓音。没源或要伦理干净的角色用 Design。