# sanoTTS-jp

A 559,000-parameter Japanese text-to-speech engine that runs in real time on a three-dollar ESP32-S3 microcontroller, doing morpheme analysis and pitch-accent estimation on the device with dependency-free C code, with a browser demo of the same engine compiled to WebAssembly.

sanoTTS-jp is a clean-room Japanese implementation of the sanoTTS distillation recipe, which trains small duration, acoustic and vocoder models from a larger teacher model. Inference runs as dependency-free C code that only needs the standard math library and performs no dynamic memory allocation, so the same code that runs on a microcontroller also compiles to WebAssembly for an in-browser demo that speaks typed Japanese text with no installation.

A firmware build for the M5Stack CoreS3 board reads text typed over a serial connection, performs kanji-to-phoneme conversion and morpheme analysis on the device, and speaks the result, with measured latency and memory figures published in the repository. The project includes an Arduino and PlatformIO library for embedding the engine in other sketches, and its code is MIT licensed, though the distributed model weights carry separate usage restrictions.

Website: https://ayutaz.github.io/sanoTTS-jp/
