sag
Use sag for ElevenLabs TTS with local playback.
API key (required)
- -
ELEVENLABS_API_KEY (preferred) - INLINECODE2 also supported by the CLI
Quick start
- - INLINECODE3
- INLINECODE4
- INLINECODE5
- INLINECODE6 (model-specific tips)
Model notes
- - Default:
eleven_v3 (expressive) - Stable: INLINECODE8
- Fast: INLINECODE9
Pronunciation + delivery rules
- - First fix: respell (e.g. "key-note"), add hyphens, adjust casing.
- Numbers/units/URLs:
--normalize auto (or off if it harms names). - Language bias:
--lang en|de|fr|... to guide normalization. - v3: SSML
<break> not supported; use [pause], [short pause], [long pause]. - v2/v2.5: SSML
<break time="1.5s" /> supported; <phoneme> not exposed in sag.
v3 audio tags (put at the entrance of a line)
- -
[whispers], [shouts], INLINECODE22 - INLINECODE23 ,
[starts laughing], [sighs], INLINECODE26 - INLINECODE27 ,
[curious], [excited], [crying], INLINECODE31 - Example: INLINECODE32
Voice defaults
- -
ELEVENLABS_VOICE_ID or INLINECODE34
Confirm voice + speaker before long output.
Chat voice responses
When Peter asks for a "voice" reply (e.g., "crazy scientist voice", "explain in voice"), generate audio and send it:
CODEBLOCK0
Voice character tips:
- - Crazy scientist: Use
[excited] tags, dramatic pauses [short pause], vary intensity - Calm: Use
[whispers] or slower pacing - Dramatic: Use
[sings] or [shouts] sparingly
Default voice for Clawd: lj2rcrvANS3gaWWnczSX (or just -v Clawd)
sag
使用 sag 进行 ElevenLabs TTS 并实现本地播放。
API 密钥(必需)
- - ELEVENLABSAPIKEY(推荐)
- CLI 也支持 SAGAPIKEY
快速开始
- - sag Hello there
- sag speak -v Roger Hello
- sag voices
- sag prompting(模型特定提示)
模型说明
- - 默认:elevenv3(富有表现力)
- 稳定:elevenmultilingualv2
- 快速:elevenflashv25
发音 + 表达规则
- - 首要修正:重新拼写(例如 key-note),添加连字符,调整大小写。
- 数字/单位/URL:--normalize auto(如果影响名称则使用 off)。
- 语言偏好:--lang en|de|fr|... 用于指导规范化。
- v3:不支持 SSML ;请使用 [pause]、[short pause]、[long pause]。
- v2/v2.5:支持 SSML ; 在 sag 中不可用。
v3 音频标签(放在行首)
- - [whispers]、[shouts]、[sings]
- [laughs]、[starts laughing]、[sighs]、[exhales]
- [sarcastic]、[curious]、[excited]、[crying]、[mischievously]
- 示例:sag [whispers] keep this quiet. [short pause] ok?
默认语音
- - ELEVENLABSVOICEID 或 SAGVOICEID
在生成长文本输出前确认语音和说话人。
聊天语音回复
当 Peter 要求语音回复时(例如疯狂科学家语音、用语音解释),生成音频并发送:
bash
生成音频文件
sag -v Clawd -o /tmp/voice-reply.mp3 你的消息内容
然后在回复中包含:
MEDIA:/tmp/voice-reply.mp3
语音角色提示:
- - 疯狂科学家:使用 [excited] 标签,戏剧性停顿 [short pause],变化强度
- 平静:使用 [whispers] 或较慢语速
- 戏剧性:适度使用 [sings] 或 [shouts]
Clawd 的默认语音:lj2rcrvANS3gaWWnczSX(或直接使用 -v Clawd)