Kokoro Swedish — multi-speaker voice pack (10 named voices)
A Swedish Kokoro-82M model fine-tuned on 23 real Swedish speakers (NST + LibriVox, ~8.6 h), shipped with 10 named voicepacks. One model, many voices — each voice is a 512 KB style tensor; the model reproduces each speaker's prosody, so the voices are genuinely dynamic (not the flat prosody typical of single-speaker distillation).
Voices
| voice | voice | ||
|---|---|---|---|
| Alice ♀ calm | Björn ♂ deep | ||
| Elsa ♀ | Lars ♂ | ||
| Ebba ♀ | Nils ♂ | ||
| Stina ♀ expressive | Anton ♂ | ||
| Greta ♀ (skånska accent) | Oskar ♂ |
Prosody-responsiveness is measured: feeding a monotone speaker's voicepack yields ~4.9 semitone F0-variation; an expressive one yields ~9.5 — the style vector genuinely steers delivery.
Files
| file | what |
|---|---|
kokoro_sv.pth | KModel-format multi-speaker weights |
voices/<Name>.pt | [510,1,256] voicepack per named voice |
config.json | Swedish 178-token Kokoro config |
samples/<Name>.wav | one sample line per voice |
The neural Swedish G2P (required — inference must phonemize identically to
training) lives in Joakim/swedish-kokoro.
Usage
import torch, soundfile as sf
from kokoro import KModel
from scipy.signal import iirnotch, filtfilt
from g2p_sv import SwedishG2P # SV_NEURAL_G2P=nst_g2p
model = KModel(repo_id="hexgrad/Kokoro-82M", config="config.json", model="kokoro_sv.pth").eval()
voice = torch.load("voices/Stina.pt", weights_only=True) # pick any voice
g2p = SwedishG2P(backend="neural")
ipa = g2p("Hej, jag är CandyTron, din godisrobot!")
ids = [i for i in (model.vocab.get(p) for p in ipa) if i is not None]
audio = model.forward_with_tokens(torch.LongTensor([[0]+ids+[0]]), voice[len(ids)-1], speed=1.0)[0].squeeze().numpy()
for f0 in (2400, 4800, 7200, 9600): # notch the fine-tune upsampler tones
b, a = iirnotch(f0, Q=35, fs=24000); audio = filtfilt(b, a, audio)
sf.write("out.wav", audio, 24000)
Voicepacks interpolate: 0.6*voiceA + 0.4*voiceB gives an intermediate voice/intensity.
Known limitations (this is v1)
- Male voices are a touch soft. The training mix is ~66% female, so the decoder leans female and renders male voices less fully male than a dedicated model would. A gender-balanced v2 base is planned. Björn is the deepest/most-male here.
- A residual decoder "comb" (~1.5 on our metric vs ~0.4 for single-speaker) is reduced by the four notch filters in the usage snippet; some remains.
Provenance
- Speakers: NST Swedish ASR corpus (CC0, via HF
KTH/nst)- Swedish LibriVox (
datadriven-company/TTS-Swedish, CC0).
- Swedish LibriVox (
- Training: kikiri-tts two-stage recipe
(StyleTTS2), multispeaker, mel-GAN + WavLM SLM,
max_len800, decoder-lr 1e-5. Checkpoints selected by ASR-gated evaluation (KBLab VoxRex CER + DNSMOS), never loss alone. - Trained on an NVIDIA GB10.
Credits
hexgrad/Kokoro-82M · semidark/kikiri-tts · yl4579/StyleTTS2 · Språkbanken/NST · KBLab VoxRex (eval)