/ Модель

Характеристики

Лицензия
Apache 2.0
Архитектура
nano_tts · dense
Базовая модель
Kokoro-82M
Библиотека
pytorch
Опубликована
20 ноя 2026

nano-edge-tts-standalone

Синтез речиТекст → аудио3 профессии

Компактная дистиллированная модель преобразует английский текст в речь, поддерживая 28 американских и британских голосов Kokoro.

289скачиваний за 30 дней2лайкавеса обновлены28 ноя 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

nano-edge-tts-standalone — компактная модель синтеза речи, разработанная автором репозитория drmhse и дистиллированная из Kokoro-82M. Она содержит 3,27 млн обучаемых параметров и занимает около 13 МБ. Архитектура включает текстовый компонент, который обрабатывает фонемы, части речи и голос, а также маппер и рендерер, формирующие аудио из импульсного сигнала и шума; для восстановления аудио используются два обратных STFT. Модель не запускает сети Kokoro и не требует его программных зависимостей.

Модель предназначена для преобразования английского текста в речь на локальном устройстве. Доступны 28 голосовых векторов Kokoro с американскими и британскими голосами; поддерживаются потоковая и пакетная генерация. По данным README, генерация четырёхсекундной фразы на одном потоке CPU занимает около 23 мс, а первый потоковый блок формируется примерно за 12 мс. Репозиторий содержит веса в safetensors и ONNX-графы. Лицензия — Apache-2.0.

Модель рассчитана только на английский язык, а её звучание ограничено качеством целевой модели Kokoro-82M. README отмечает возможные отклонения в расстановке акцентов, артефакты в отдельных частотных диапазонах и менее надёжное произношение редких имён, отсутствующих в словарях фронтенда. Оценки прослушивания выполнены одним слушателем; скорость измерялась на CPU ноутбука.

Сценарии применения

  • локальная озвучка английских текстов
  • потоковое озвучивание коротких фраз
  • генерация речи с американскими голосами
  • генерация речи с британскими голосами

Ограничения

Поддерживается только английский язык; редкие имена и слова вне словарей фронтенда могут произноситься менее надёжно. Возможны отклонения в акцентах и артефакты звучания, а заявленные оценки прослушивания основаны на одном слушателе.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

nano-edge-tts-standalone

Text to speech in 3.27M parameters, distilled from Kokoro-82M without running any of its networks or installing any of its software. It builds on nano-edge-tts v1, which replaced Kokoro's decoder and kept Kokoro's 28.5M-parameter text side; here the text side is replaced too.

From Kokoro it keeps only data: the phoneme vocabulary, the 28 English voice vectors, and the text front end. Everything learned is new:

  • a text side (1.52M) that turns phonemes, their words' part-of-speech tags and the voice into features, durations, pitch and energy;
  • a mapper (0.96M, 80 frames/s) and a renderer (0.79M, 160 frames/s) that set per-frequency gains on a pulse train and on white noise. Two inverse STFTs make the audio, and no network runs at audio rate.

Learned parameters: Kokoro-82M 81.8M, nano-edge-tts v1 30.2M, nano-edge-tts v2 (this model) 3.27M

Paper: Distilling Kokoro-82M into a 3.3M-Parameter Text-to-Speech Model. To rebuild it: every checkpoint of the training chain with its arguments and logs (chain/), the exact code, and one script from public books to these weights (code/).

Kokoro-82Mv2.0v2.3 (this)
learned parameters81.8M3.27M3.27M
weights on disk327 MB13 MB13 MB
Kokoro software to installmisaki, spaCy, espeak-ngmisaki, spaCy, espeak-ngnone
real-time factor, one CPU thread¹: PyTorch0.14150.0048 (29× faster)0.0050 (28× faster)
real-time factor, one CPU thread¹: ONNX Runtime0.0045 (31× faster)
peak memory with the front end¹: PyTorch1.78 GB0.60 GB0.71 GB
peak memory with the front end¹: ONNX Runtime0.60 GB
Whisper small.en word errors, 60 unseen sentences²363935
hard target words said, two recognisers, 27 voices³81.8 %59.3 %78.9 %
Open TTS Leaderboard English sets, word error / UTMOS⁴0.66 % / 4.510.77 % / 4.4410.69 % / 4.465

¹ Phonemes to audio for the six sample sentences (about 45 s of audio), best of three, on an Apple-silicon laptop CPU (code/eval/release_bench.py).
² Test sentences from three books used in no training set.
³ 4,806 targets: 34 words with rare or easily confused sounds (/ɔɪ/ as in "boy", pairs such as "voices"/"vices", consonant clusters, possessives), alone, mid-sentence and sentence-final, and 20 short questions; a target counts as said only if faster-whisper small.en and wav2vec2-large-960h both find it.
⁴ Every row of the four English sets, scored with the leaderboard's own pipeline. Ours run locally on one CPU thread; Kokoro's as published on the leaderboard (version 1.7.0, other hardware).
Raw numbers in results/.

Versions

versionwhat changedwhere
2.3 (this one)The weights of 2.2, new code. tts.stream() gives the audio in blocks while the rest renders: the first block of a 4 s sentence in about 12 ms on one CPU thread (whole sentence 23 ms), about 20 ms on a CUDA GPU; joined, the blocks are the same audio as one call. Apple GPUs (device='mps') work again (2.1 and 2.2 stopped on a float64 operation they lack). The same seed now gives the same audio on every device: single sentences draw their noise on the CPU, as batches already did (CPU output bit-identical to 2.2).main
2.2The decoder fine-tuned with its post-filter switched on during training (G5S), so the filter no longer brightens the 4–8 kHz band: that band's level is now within ±0.5 dB of Kokoro's on all ten voices measured (v2.1: +2.1 to +5.0 dB), and its 160 Hz grain is about halved. Leaderboard word error 0.71 → 0.69 %, UTMOS 4.467 → 4.465, hard words 78.7 → 78.9 %. Judged even with 2.1 in 13 blind trials of 55–88 s passages (6 to 6, 1 the same).tag v2.2
2.1The text side fine-tuned (FT4_map) so that it no longer loses words such as "boy" and "noise"; preferred over 2.0 in all 20 blind trials on such words (16 + 4 hidden repeats). The front end packaged, with the same leaderboard word error as Kokoro's own. Batched synthesis, a transformers wrapper, ONNX graphs. Updated 2026-11-24 with a decoder fine-tuned on this text side's features (G3_ft4_hb_sharp): leaderboard UTMOS 4.451 → 4.467, word error 0.72 → 0.71 %; heard as the same as the first 2.1 weights in all 24 blind trials.tag v2.1; first 2.1 weights: tag v2.1-g2
2.0First release: text side T6_small. The version the Open TTS Leaderboard measures.tag v2.0

Version 2.0 and the first 2.1 weights use the decoder G2_t6_hb_sharp, 2.1 G3_ft4_hb_sharp. Earlier files load with revision='v2.0', revision='v2.1-g2', revision='v2.1' or revision='v2.2'.

How it sounds

The same sentence through Kokoro-82M and this model:

voiceKokoro-82Mnano-edge-tts-standalone
af_heart
af_bella
am_michael
am_fenrir
bf_emma
bm_george

Quick start

pip install torch safetensors huggingface_hub numpy soundfile
hf download drmhse/nano-edge-tts-standalone --local-dir nano-tts \
  --include "nano_*.py" --include config.json --include nano-tts.safetensors --include "frontend/*"
cd nano-tts
python nano_tts.py "Hello from a very small model." --voice af_heart --out hello.wav
import soundfile as sf
from nano_tts import load

tts = load()                                    # CPU; load(device='mps') or 'cuda' also work
audio = tts('Hello from a very small model.', voice='bm_george')   # 24 kHz float32
sf.write('hello.wav', audio, 24000)

clips = tts.batch(['First sentence.', 'A second, longer one.'], voices='af_heart')   # many texts at once

for block in tts.stream('A long paragraph to play while it renders.', voice='af_heart'):   # first block in ~10 ms
    play(block)                                 # numpy blocks; joined, they equal tts(...) to rounding

Voices are Kokoro's: af_*, am_* (American), bf_*, bm_* (British); only the one you ask for is downloaded. If nano_frontend.py and frontend/ are not next to nano_tts.py, they are downloaded from this repository on first use.

transformers:

from transformers import AutoModel
model = AutoModel.from_pretrained('drmhse/nano-edge-tts-standalone', trust_remote_code=True)
audio = model.generate('Hello from a very small model.', voice='af_heart')   # float32 tensor, 24 kHz

ONNX Runtime (no PyTorch):

pip install onnxruntime safetensors numpy
hf download drmhse/nano-edge-tts-standalone --local-dir nano-tts-onnx --include onnx_tts.py --include nano_frontend.py \
  --include config.json --include voices.safetensors --include "frontend/*" --include "onnx/text_*" --include "onnx/decoder*"
cd nano-tts-onnx && python onnx_tts.py "Hello from a very small model." --voice af_heart --out hello.wav

The graphs draw no random numbers: onnx_tts.py passes the noise and shows the whole call sequence. Their output is within 0.003 of PyTorch's on the same input.

Files

pathcontents
nano_tts.pyThe whole model in one file: text side, mapper, renderer with its post-filter, batching, loader, command line
nano_frontend.py, frontend/Kokoro's text front end without its dependencies: spaCy's tokenizer and tagger as exported data, misaki's rules and lexicons, number reading; for words no lexicon covers, espeak-ng's pronunciations precomputed for 915,000 words, else the g2p_en network
nano-tts.safetensors, config.jsonThe weights (text side FT4_map, decoder G5S) and their sizes, phoneme vocabulary and tag set
configuration_nano_tts.py, modeling_nano_tts.pyThe transformers wrapper: same files, same output
onnx_tts.py, voices.safetensors, onnx/The ONNX runner, Kokoro's 28 English voices as one file, and the graphs: text_encoder, text_frames and decoder for the model, tagger and g2p_* for the front end's two small networks
samples/The clips above
paper/The paper (PDF, Typst source, figures)
results/End-to-end reports, voice and accent measures, listening results; results/v2.1/, results/v2.2/: the hard-word test, the leaderboard runs, the listening pages, the high-band measures, the front end's checks against Kokoro's
chain/Every checkpoint of the training chain and the ablations, each with log.jsonl (its arguments first) and train.log
code/The training code as it ran, reproduce_v2.sh, the lab notebooks (code/notes/)

The training chain

stagestarts fromwhat it addssteps
T6_smallnothingthe text side: distils Kokoro's text side on 91,812 sentences20,000
R0_mappernothingthe mapper alone, matched to Kokoro's decoder features18,000
v2_pairedR0mapper + renderer on spectral losses (expected power over four noise draws)15,000
v2_criticv2_pairedmapper frozen and cached; a critic on frozen WavLM layers30,000
F1 → F4the one beforetexture and periodicity losses, critic carried over35,000
F4_sharpF4the inference post-filter on the noise gains (no training)—
G2_t6_hbF4the small text side's features as input, a 4–12 kHz critic10,000
G2_t6_hb_sharpG2_t6_hbthe post-filter (no training): the v2.0 decoder—
FT4_mapT6_small30,000 more sentences (short lines, questions, rare sounds), and a loss measured through the decoder's frozen mapper: the text side since v2.14,000
G3_ft4_hbG2_t6_hbthe same recipe on FT4_map's features10,000
G3_ft4_hb_sharpG3_ft4_hbthe post-filter (no training): the v2.1 decoder—
G5SG3_ft4_hbthe post-filter switched on during training, so every loss and both critics judge the filtered output; 3,000 steps at half G3's learning rate: the released decoder3,000

G1_t6 (G2 without the 4–12 kHz critic) and the text-side ablations T1–T10 are in chain/G1_t6 and chain/ablations. Every checkpoint loads with torch.load(path, weights_only=True) and holds the optimiser and critic states, so any stage can be resumed or rerun from the one before and compared.

To rebuild everything (about 22 h on one Apple-silicon GPU, ~45 GB of disk):

hf download drmhse/nano-edge-tts-standalone --local-dir nts --include "code/*"
cd nts/code && pip install -r requirements.txt
zsh reproduce_v2.sh                 # ABLATIONS=1 zsh reproduce_v2.sh adds G1 and the text-side ablations

It downloads Kokoro-82M and 43 public-domain books from Project Gutenberg, rebuilds the data, runs every stage with its recorded arguments, exports the weights with an output check against the training code, and measures them. Version 2.0's data steps were checked against the originals: sentences, voices and training windows bit-identical, Kokoro's features equal to float16 precision. GPU training is not bit-deterministic, so a rerun reproduces the recipe rather than the exact weights. release_v2/build_espeak_lexicon.py rebuilds the front end's precomputed pronunciations (it needs espeak-ng and misaki).

Limitations

  • English only: Kokoro's 28 American and British voices. Other languages and new voices are untested.
  • Kokoro-82M is the target, so at best this model sounds like Kokoro.
  • The post-filter that closed most of the audible gap adds some 4–8 kHz flutter and overshoots 2–4 kHz contrast (see the paper).
  • Accent placement is measurably further from Kokoro's than Kokoro is from itself; long or very expressive passages may show it.
  • Words outside the front end's lexicons and its precomputed words are guessed by a small network, less reliably than espeak-ng would read them (mostly rare names).
  • Listening results come from one listener. Speed was measured on a laptop CPU, not on a phone.

Licence and credit

Apache-2.0, the same as Kokoro-82M. Kokoro-82M, its voices and the misaki front end are by hexgrad (Apache-2.0); this model was distilled from it. The packaged front end contains data exported from spaCy's en_core_web_sm (MIT), the g2p_en network (Apache-2.0, frontend/g2p.LICENSE), and pronunciations computed with espeak-ng (GPL-3.0) for a word list drawn from CMUdict (BSD-2), US first-name and surname lists (public domain), English Wikipedia word frequencies (IlyaSemenov/wikipedia-word-frequency, MIT) and Project Gutenberg books; no espeak-ng code is included. WavLM (Microsoft) was used only as a frozen feature extractor during training.

@misc{chumba2026nanottsstandalone,
  title  = {Kokoro-82M in 3.3M Parameters: A Small Text Side and a Frame-Rate Decoder, Reproducible End to End},
  author = {Mike Chumba},
  year   = {2026},
  url    = {https://huggingface.co/drmhse/nano-edge-tts-standalone}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · pytorch

Нельзя запустить

Модели нужен код из репозитория; запуск откроется после проверки совместимости.

Класс архитектуры
NanoTTSModel
Ревизия весов
ad9bbdb

0 моделей