text-to-speech
Skill73 starsChanged 2 months agoApache-2.0View on GitHub
Write correct Sarvam Bulbul TTS code — REST, HTTP stream, WebSocket, pronunciation dictionaries, and v3 parameter traps (pitch/loudness, speaker compatibility). Use this skill when generating speech in an app with Python or JS/TS. For live TTS in chat via MCP, use sarvam-mcp instead.
- Reads credentials
13 other projects use a version of this.
Adopted by
Most recently taken up by
- calesthio/OpenMontagetheir own version, first seen Oct 3, 2026
- pjmuller/skillstheir own version, first seen Oct 3, 2026
- RobStrayer/voice-agent-skillstheir own version, first seen Oct 1, 2026
- elevenlabs/skillstheir own version, first seen Sep 30, 2026
- dmccreary/ibook-skillstheir own version, first seen Sep 27, 2026
- elevenlabs/plugintheir own version, first seen Aug 28, 2026
Used with
Projects with it also use voice-changer, sound-effects and 5 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
wlzhSkillvoice-changer
音频变声处理工具 - 使用 RVC AI 模型进行真实的声音转换,支持视频直接输入
Also in 4 projects that use this
awesome-genmediaSkillsound-effects
Generate custom sound effects using each::sense AI. Create realistic and stylized audio for any scenario including impacts, ambiences, foley, UI sounds, nature, mechanical effects, and transitions. Powered by stable-audio-2-5 for precise audio generation. Use for: video production, game development, podcasts, apps, UI/UX, presentations, film. Triggers: sound effect, sfx, audio effect, foley, generate sound, ambient sound, ui sound, impact sound, whoosh, explosion, nature sound, notification sound, create audio
Also in 4 projects that use this
elevenlabsSkillspeech-engine
Add real-time voice conversations to a custom agent runtime with ElevenLabs Speech Engine. Use when building Speech Engine servers, WebSocket handlers, WebRTC browser clients, conversation token endpoints, interruption-aware streaming responses, or voice-enabled chat agents that connect developer-owned server logic to ElevenLabs speech-to-text and text-to-speech.
Also in 3 projects that use this
elevenlabsSkillvoice-isolator
Remove background noise and isolate vocals/speech from audio using ElevenLabs Voice Isolator (audio isolation) API. Use when cleaning up noisy recordings, removing music or background ambience from dialogue, isolating speech from field recordings, preparing audio for transcription, extracting vocals, or any "denoise / clean up / isolate voice" task.
Also in 3 projects that use this
sonilo-aiSkillsetup-api-key
Guides users through connecting to Sonilo — signing in with `sonilo login` (OAuth, no key), the remote OAuth plugin for Claude Code or Muse Code, or an API key for CI and headless use. Use when the user needs to configure Sonilo, wants to sign in or connect their Sonilo account, when Sonilo tools are missing, or when a call fails because no key or credential is available. First checks what already works, and only runs full setup when needed.
Also in 3 projects that use this
marswaveaiSkillmusic
Generate, remix, extend, edit, and analyze AI music (Mureka). Triggers on: "音乐", "music", "生成音乐", "generate music", "翻唱", "cover", "混音", "remix", "续写", "extend", "纯音乐", "instrumental", "配乐", "soundtrack", "分轨", "stem", "识别歌词", "recognize lyrics", "作曲", "compose", "create a song", "做一首歌".
Also in 3 projects that use this
Other versions13 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 13
- calesthio/OpenMontage★ 63ksame name
- wlzh/skills★ 617same name
- elevenlabs/skills★ 472same name
- dmccreary/ibook-skills★ 105same name
- martinholovsky/claude-skills-generator★ 47same name
- awesome-genmedia/skills★ 36same name
- Harmeet10000/skills★ 7same name
- claude-world/claude-agent★ 4same name
- eins78/agent-skills★ 2same name
- elevenlabs/plugin★ 1same name
3 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository7 other files it gives its agents.
- chatSkill
- doc-aiSkill
- dubbingSkill
- sarvam-mcpSkill
- speech-to-textSkill
- vibe-codingSkill
- voice-agentsSkill
The file
Files
Text-to-Speech — Bulbul
Live in-chat TTS → sarvam-mcp (
sarvam_tools_tts_*). This skill = SDK code.
[!IMPORTANT] Auth:
api-subscription-keyheader — NOTAuthorization: Bearer. Base URL:https://api.sarvam.ai(NOT/v1— that prefix is only for the OpenAI-compatible chat endpoint) SDK floor for the code below: Pythonsarvamai>=0.1.29, JSsarvamai@>=1.1.8. On older versions the TTS param istarget_language_code— see Gotchas.
Model
bulbul:v3 — 11 languages, 37 voices (23 male, 14 female; default: shubh), REST/HTTP stream/WebSocket.
Quick Start (Python)
from sarvamai import SarvamAI
from sarvamai.play import save
client = SarvamAI()
response = client.text_to_speech.convert(
text="नमस्ते, आप कैसे हैं?",
language_code="hi-IN",
model="bulbul:v3",
speaker="shubh"
)
save(response, "output.wav")
# HTTP Stream (lower latency, binary audio)
chunks = []
for chunk in client.text_to_speech.convert_stream(
text="Hello from Sarvam AI",
language_code="en-IN",
speaker="shubh",
model="bulbul:v3"
):
chunks.append(chunk)
audio = b"".join(chunks)Quick Start (JavaScript/TypeScript)
import { SarvamAIClient } from "sarvamai";
import { writeFile } from "fs/promises";
const client = new SarvamAIClient({ apiSubscriptionKey: "YOUR_SARVAM_API_KEY" });
// REST
const response = await client.textToSpeech.convert({
text: "नमस्ते, आप कैसे हैं?",
language_code: "hi-IN",
model: "bulbul:v3",
speaker: "shubh"
});
// HTTP Stream (lower latency, returns BinaryResponse)
const streamResponse = await client.textToSpeech.convertStream({
text: "Hello from Sarvam AI",
language_code: "en-IN",
speaker: "shubh",
model: "bulbul:v3"
});
const bytes = await streamResponse.bytes();
await writeFile("output.wav", bytes);WebSocket Streaming
import asyncio
from sarvamai import AsyncSarvamAI
async def tts_stream():
client = AsyncSarvamAI()
async with client.text_to_speech_streaming.connect(model="bulbul:v3") as ws:
await ws.configure(target_language_code="hi-IN", speaker="shubh")
await ws.convert("Your text here")
await ws.flush()
async for message in ws:
pass # base64 audio chunks
asyncio.run(tts_stream())Character Limits
| Method | Max Text |
REST (convert) | 2,500 chars |
HTTP Stream (convert_stream) | 3,500 chars |
| WebSocket | 2,500 chars/msg (keep <500 for lowest latency; send many messages per connection) |
Gotchas
| Gotcha | Detail |
language_code is version-gated | Python >=0.1.29 and JS >=1.1.8 (both 2026-08-03) take language_code; earlier versions take target_language_code. Hard rename — no alias, no deprecation shim, and the JSON body key changed too, so the wrong name raises TypeError before any request goes out. Check with pip show sarvamai / npm ls sarvamai if you hit that. |
| WebSocket was not renamed | Python ws.configure() still takes target_language_code (mapped to language_code on the wire); JS configureConnection() takes language_code. REST and WebSocket disagree inside the Python SDK. |
| JS method name | client.textToSpeech.convert({...}) and .convertStream({...}) — camelCase. Stream returns BinaryResponse with .stream(), .bytes(), .blob(). |
pitch/loudness rejected | SDK accepts these but API returns 400 for v3. Only pace (0.5–2.0) works. |
| v2 voices incompatible | anushka, abhilash, arya, etc. don't work with v3. Use shubh (default). |
| Sample rate >24kHz | 32kHz, 44.1kHz, 48kHz only via REST, not streaming. |
| REST response | Base64-encoded audio in response.audios[0]. Use sarvamai.play.save() or base64.b64decode(). |
| No SSML | SSML markup is NOT supported. Use pace for speed control and the pronunciation dictionary for word-level fixes. |
| Use native script | Romanized Indic input ("Aapka order confirm ho gaya hai") degrades quality. Write Indic words in native script. |
| Pronunciation dictionary | dict_id param teaches custom word pronunciations (bulbul:v3 only; 10 dicts/user, 100 words/dict). Create via Python client.pronunciation_dictionary.create(file=f). JS SDK upload is broken (missing multipart Content-Type) — use raw fetch + FormData with an explicit Blob type. |
Full Docs
Fetch voice catalog, streaming protocol, pronunciation dictionary CRUD, and codec options from:
- https://docs.sarvam.ai/llms.txt — comprehensive docs index
- TTS Overview
- Voice Catalog
- HTTP Stream
- Pronunciation Dictionary
- Rate Limits
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

