Metadata-Version: 2.4
Name: persian-speech
Version: 1.1.1
Summary: Natural Persian Text-to-Speech. One command.
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: piper-tts>=1.4.0
Requires-Dist: numpy

# Persian Speech 🎙️

Natural Persian Text-to-Speech. **Zero config, one command.**

> Built on Mana-Persian-Piper, trained on 114 hours of high-quality Persian speech.  
> Runs on servers, laptops, Raspberry Pi, and mobile devices. Entirely offline.

## Why Persian Speech?

- **Natural voice** — Trained on the largest Persian speech dataset (Mana-TTS)
- **Runs anywhere** — Linux, Windows, macOS, Raspberry Pi, Android, iOS
- **Edge & mobile ready** — ONNX runtime, lightweight model, no GPU needed
- **Offline first** — No internet after initial model download
- **Blazing fast** — 25x faster than realtime on CPU
- **One command** — `speech "سلام"` and you're done

## Install

```bash
pip install persian-speech
```

Model downloads automatically on first use. That's it.

## Usage

**Command line:**

```bash
speech "سلام به همگی"
speech "سلام دنیا" hello.wav
```

**Python:**

```python
from persian_speech_runtime import talk
talk("سلام به همگی", "output.wav")
```

**Server:**

```bash
python server.py
# http://localhost:8000/tts?text=سلام
```

## API

```python
from persian_speech_runtime import PiperSpeechEngine, talk

talk("سلام", "out.wav")              # One-liner

tts = PiperSpeechEngine()
tts.save("سلام", "out.wav")          # Save WAV
tts.stream("سلام")                   # WAV bytes
tts.synthesize("سلام")               # NumPy array
```

## License

MIT — Use it anywhere. Built on [Mana-Persian-Piper](https://huggingface.co/MahtaFetrat/Mana-Persian-Piper) (MIT) and [Mana-TTS](https://huggingface.co/datasets/MahtaFetrat/Mana-TTS) (CC0).
