{
 "schema_version": 1,
 "generated": "2026-10-24",
 "id": "kittenml-kittentts--add-local-tts-to-python-app",
 "repo": "KittenML/KittenTTS",
 "repo_url": "https://github.com/KittenML/KittenTTS",
 "repo_slug": "kittenml-kittentts",
 "title": "Add natural speech to a Python app in a few lines",
 "page_title": "Kitten TTS tutorial: add local text to speech to a Python app",
 "summary": "Install kittenml, load Kitten-TTS 2 and write speech to a WAV file with a preset voice.",
 "who": "A developer building a voice assistant prototype on a laptop without a GPU.",
 "problem": "Cloud TTS adds latency, cost and a dependency.",
 "outcome": "WAV files generated locally from text with a chosen voice.",
 "steps": [
  "Install with `pip install kittenml`",
  "Load the model with Kitten TTS(\"KittenML/kitten-tts-2\")",
  "Call generate with your text and a voice such as WeatherPresenterCheerful",
  "Write the audio with soundfile at m.sample_rate"
 ],
 "agent_prompt": "Using KittenML/KittenTTS, install kittenml, generate <text> with voice \"Matthew\" and save output.wav. Confirm the file plays and its sample rate equals m.sample_rate.",
 "agents": [
  "any"
 ],
 "difficulty": "Intermediate",
 "time": "15 minutes",
 "basis": "readme",
 "caveat": "Use weights=\"emb4\" to halve the download if bandwidth or disk is tight.",
 "category": "Content",
 "tags": [
  "Content"
 ],
 "lang": "python",
 "requirements": [
  "Python with pip",
  "A CPU is enough for the lightweight models; Kitten-TTS 2 runs realtime on CPUs and consumer GPUs per the README"
 ],
 "risk": "none",
 "seen_in_the_wild": false,
 "mentioned_publicly": false,
 "risks": [],
 "best": true,
 "score": 1.0,
 "evidence": [],
 "url": "https://dedupedai.com/use-cases/kittenml-kittentts/add-local-tts-to-python-app/",
 "md": "https://dedupedai.com/use-cases/kittenml-kittentts/add-local-tts-to-python-app/index.md",
 "disclaimer": "Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked \"Seen in the wild\", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email hello@dedupedai.com and we will look at it promptly.",
 "api": "https://dedupedai.com/api/v1/usecases/kittenml-kittentts--add-local-tts-to-python-app.json",
 "api_version": "v1"
}
