kitten-tts-2-pico

KittenML/kitten-tts-2-pico

作者
KittenML
任务
语音合成
下载量
168
点赞数
7
趋势分
7
许可证
apache-2.0
收录时间
2026/11/15

license: apache-2.0 library_name: onnx pipeline_tag: text-to-speech language: [en, de, es, it, pt, ru, hi, fr] tags: [text-to-speech, onnx, int8, safetensors, pytorch, kittentts]

Kitten TTS 2 Pico

7.2M parameters per language model, 8 languages, 30 voices, 24 kHz. ONNX with int8 weights (8.0 MB; runs on CPU, no PyTorch needed), and the float32 PyTorch weights.

Usage

pip install kittenml
from kittenml import KittenTTS
import soundfile as sf

m = KittenTTS("KittenML/kitten-tts-2-pico")          # or the path of this directory
print(m.available_voices)                 # {"en": ["Eleanor", ...], "de": ["Anna", ...], ...}
for v in m.voices("de"):                  # name and description of each voice
    print(v["name"], v["description"])

audio = m.generate("Hello there, this is Kitten TTS 2 Pico.", voice="Eleanor")
audio = m.generate("Guten Morgen! Wie geht es dir?", voice="Paul", speed=1.1)    # the voice sets the language
audio = m.generate("Guten Morgen! Wie geht es dir?", language="de")          # the language's first voice (Anna)
sf.write("out.wav", audio, 24000)

m = KittenTTS("KittenML/kitten-tts-2-pico", backend="torch")                  # PyTorch, float32 weights
m = KittenTTS("KittenML/kitten-tts-2-pico", backend="torch", device="cuda")   # on a GPU
audio = m.generate("Hello there, this is Kitten TTS 2 Pico.", voice="Eleanor")

backend="onnx" (the default) runs the int8 ONNX graph with ONNX Runtime; backend="torch" runs the float32 weights in PyTorch. Only the files the selected backend needs are downloaded.

voice takes a name from the tables below (any case: "Paul" or "paul") or its description. Without voice, a language's first voice speaks.

Voices

Each voice is a first name; its voice pack is stored under the lowercase name in voices_<lang>.npz. The English voices carry the names of the same characters in KittenTTS 2.

English (en)

voicedescription
EleanorSomber historian (female)
EdithElderly grandmother soft (female)
OtisRumbling blues musician (male)
FrankGrizzled war veteran gravelly (male)

German (de)

voicedescription
AnnaFemale 1
MiaFemale 2
LukasMale 1
PaulMale 2

Spanish (es)

voicedescription
SofiaFemale 1
ElenaFemale 2
PabloMale 1
MateoMale 2

Italian (it)

voicedescription
FrancescaFemale 1
AlessandroMale 1
GiorgioMale 2
DavideMale 3

Portuguese (Brazil) (pt)

voicedescription
JulianaFemale 1
LarissaFemale 2
GustavoMale 1
CaioMale 2

Russian (ru)

voicedescription
OlgaFemale 1
TatianaFemale 2
SergeiMale 1
AlexeiMale 2

Hindi (hi)

voicedescription
PriyaFemale 1
ArjunMale 1

French (fr)

voicedescription
AmelieFemale 1
LeaFemale 2
TheoMale 1
BaptisteMale 2

License

Apache-2.0 (the models, voice packs and the bundled G2P files).

内容来源:Hugging Face 模型卡

在 Hugging Face 查看