Real-time speech transcription and multilingual translation API supporting African and international languages. Built with OpenAI Whisper, Helsinki-NLP MarianMT, FastAPI, and Docker. Zero cloud cost β fully local inference.
# ποΈ Multilingual Speech Translation API
> Real-time speech transcription and translation pipeline supporting African and international languages β built with OpenAI Whisper, Helsinki-NLP, and FastAPI.
---
## π Overview
This project provides a fully containerised, production-ready pipeline that:
1. **Accepts audio input** in any common format (`.wav`, `.mp3`, `.m4a`, `.ogg`, `.flac`)
2. **Transcribes speech to text** using OpenAI Whisper running entirely locally β no API key required
3. **Translates the transcript** using Helsinki-NLP MarianMT models via HuggingFace Transformers
4. **Returns structured JSON** with the transcript, detected language, and translation
5. **Exposes a Streamlit UI** for non-technical users to upload audio and view results instantly
The architecture mirrors real-world multilingual conferencing and communication platforms, with specific support for **African languages** (Yoruba, Swahili) alongside French, Spanish, German, and English.
> **Zero cloud cost.** All inference runs locally. No OpenAI API key, no Google Cloud billing, no hidden charges.
---
## ποΈ Architecture
```
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Docker Network β
β β
β ββββββββββββββββ POST /transcribe βββββββββββββββββ β
β β Streamlit β βββββββββββββββββββββββΆβ FastAPI β β
β β Frontend β β Backend β β
β β :8501 β ββββββββββββββββββββββββ :8000 β β
β ββββββββββββββββ JSON response ββββββββ¬βββββββββ β
β β β
β ββββββββββββββΌββββββββββ β
β β OpenAI Whisper β β
β β (Speech β Text) β β
β ββββββββββββββ¬ββββββββββ β
β β¦