speaches is an OpenAI API-compatible server supporting streaming transcription, translation, and speech generation. This project aims to be Ollama for TTS/STT models - making it easy to run multiple speech models with a unified API.
- Speech-to-Text: faster-whisper
- Text-to-Speech:
For full documentation, visit: speaches.ai
- OpenAI API Compatible - All tools and SDKs that work with OpenAI's API work with Speaches
- Streaming Support - Real-time transcription via SSE (no waiting for full audio processing)
- Dynamic Model Management - Automatic model loading/unloading based on usage
- GPU & CPU Support - Run on your preferred hardware
- Docker Ready - Easy deployment via Docker Compose
- Highly Configurable - Extensive configuration options
Audio Generation (Realtime API)
- Text → Audio: Generate spoken summaries
- Audio → Text: Transcription and sentiment analysis
- Audio → Audio: Speech-to-speech model interactions
- Kokoro - Ranked #1 in the TTS Arena
- StyleTTS2 - 24kHz high-quality synthesis, voice cloning, 18+ languages, 14 preset voices
- Piper - Fast and lightweight TTS
2025-05-29_21-40-00.webm
(Excuse the breathing lol. Didn't have enough time to record a better demo)
TODO
2025-01-12_13-20-58.webm
curl -X POST http://localhost:8000/v1/audio/speech \
-H "Content-Type: application/json" \
-d '{
"model": "jakezp/StyleTTS2-LibriTTS",
"input": "Hello world! This is high-quality neural speech synthesis.",
"voice": "female_anna"
}' \
--output speech.wavAvailable Voices: female_anna, male_gavin, female_emily, male_thomas, and 10 more preset voices.
Voice Cloning: Use "voice": "file:///path/to/reference.wav" to clone any voice.
Custom Parameters: Adjust alpha (0-1), beta (0-1), and diffusion_steps (1-20) for fine control.
This project builds upon and integrates several excellent open-source projects:
- Speaches - The foundation of this OpenAI-compatible TTS/STT server (MIT License)
- StyleTTS2 - High-quality neural text-to-speech synthesis with style modeling (MIT License)
- StyleTTS2 HuggingFace Space - Reference implementation and inspiration for integration
- faster-whisper - Fast speech-to-text transcription
- Kokoro - State-of-the-art TTS model
- Piper - Lightweight TTS engine
This project is a combination and integration of the above works. All original projects retain their respective licenses (primarily MIT License). This derivative work is provided as-is for research and development purposes.
We express our gratitude to all the original authors and contributors of these projects. Their excellent work makes this integration possible.
Please create an issue if you:
- Find a bug
- Have a question
- Want to suggest a feature
Contributions are welcome! Please feel free to submit issues or pull requests.
Note: This is a community integration project combining multiple open-source TTS/STT engines into a unified OpenAI-compatible API. It is not affiliated with OpenAI.