skillfed

kokoro-onnx

TTS with kokoro and onnx runtime

kokoro-onnx v0.5.0 550.9K downloads/30d#6,052 on PyPI2,672
License unclear Active released

What it is and what it does

Kokoro-onnx is a text-to-speech engine that runs inference using ONNX Runtime, wrapping the Kokoro-TTS model to generate speech from text. It supports multiple languages and offers a selection of voices, with model weights optimized for size while maintaining performance on modern hardware. The package depends on espeakng-loader for phoneme handling, numpy for numerical operations, onnxruntime for model inference, and phonemizer-fork for linguistic processing.

The typical workflow involves installing the package, downloading the model and voice files from the project's releases, then calling the Kokoro class with text, language, voice, and output parameters. It's designed for developers who need embedded speech synthesis without heavy dependencies like full TensorFlow or PyTorch installations, making it suitable for edge deployment or resource-constrained environments.

Use it for:

  • Generate speech for accessibility features in applications that need multiple language support.
  • Create audio narration for content in real-time or batch processing pipelines.
  • Build chatbot or voice assistant backends with lightweight inference on consumer hardware.
  • Produce multilingual voiceovers for media or educational content with minimal model overhead.
  • Prototype or deploy TTS features in resource-limited environments like embedded systems or edge devices.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Converts text to speech using ONNX Runtime, supporting multiple languages and voices with performance optimized for modern hardware.

Yes, if you need lightweight multilingual text-to-speech with ONNX inference. The low installation friction, active maintenance, and zero known vulnerabilities make it a practical choice. However, verify the unclear license treatment against your project's requirements, and plan for the separate download of model files before first use.

Install

kokoro-onnx on PyPI

pip

pip install kokoro-onnx

uv

uv add kokoro-onnx

poetry

poetry add kokoro-onnx

Installing kokoro-onnx

Before you install

Low installation friction with a pure Python wheel and four runtime dependencies. Active maintenance with recent commits.

License in practice

License treatment is unclear in the package metadata, though the description notes the package itself is MIT while the underlying Kokoro model uses Apache 2.0. Verify licensing terms before use in proprietary or restricted contexts.

Quickstart

pip install kokoro-onnx

from kokoro_onnx import Kokoro

kokoro = Kokoro(lang="en-us")
kokoro.create(text="Hello world", voice="af_heart", speed=1.0, outfile="audio.wav")

Requires downloading model files (kokoro-v1.0.onnx and voices-v1.0.bin) separately and placing them in the working directory before first use.

Verify before relying

  • Whether the unclear license treatment poses practical restrictions for commercial or closed-source projects.
  • Performance characteristics on hardware other than macOS M1 mentioned in the description.
  • Whether all supported languages and voices are documented outside the external Hugging Face link.
  • Exact size of downloaded model files in typical deployment scenarios.

Package facts

License not declared (unclear)
Python support supports the current Python release (<3.14,>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 4 — espeakng-loader, numpy, onnxruntime, phonemizer-fork
Maintenance actively maintained — 196 days since the last release
Last repo commit
First released
Downloads 550,894/month — #6,052 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: kokoro_onnx-0.5.0-py3-none-any.whl

Tags

text to speech onnxtts multiple languageskokoro ttsneural speech synthesislightweight tts modelmultilingual voice generationreal-time speech synthesis
ttsspeech-synthesisonnx

More Linguistic packages