v0.4.41

KoljaB/RealtimeTTSv0.4.41Jan 11, 2025by KoljaB

AI Summary

Introduces the new KokoroEngine to the library, enabling users to utilize the Kokoro 82M text-to-speech model with various voice options.

Key Highlights

  • New KokoroEngine integration (Kokoro 82M)
  • Installation guide and usage examples
  • Access to Kokoro voice models

New Features

  • KokoroEngine (Kokoro 82M) support

Full Release Notes

# RealtimeTTS v0.4.41 Release Notes

### New Feature: KokoroEngine Support

- **KokoroEngine Integration**  
  - Introduces support for the Kokoro 82M TTS engine.
  - Provides access to a variety of Kokoro voice models.

- **Installation**:  
  ```bash
  pip install realtimetts[all]==0.4.41
  ```

- **Setup Resources**:
  - Kokoro installation guide: [Kokoro Installation](https://huggingface.co/hexgrad/Kokoro-82M#usage)
  - Test script: [kokoro_test.py](https://github.com/KoljaB/RealtimeTTS/blob/master/tests/kokoro_test.py)
  - Engine implementation: [kokoro_engine.py](https://github.com/KoljaB/RealtimeTTS/blob/master/RealtimeTTS/engines/kokoro_engine.py)

### Usage Overview

```python
from RealtimeTTS import TextToAudioStream, KokoroEngine

# Initialize Kokoro engine
engine = KokoroEngine(kokoro_root="path/to/Kokoro-82M")

# Switch voice as needed
engine.set_voice("af_sky")

# Create audio stream
stream = TextToAudioStream(engine)

# Feed and play audio using Kokoro voices
stream.feed("Hello world")
stream.play()

```