Logo Lanfrica

Naome12/Kinyarwanda_Voice-Assistant

Domaine:

natural language processing

Type de record:

softwareproject
Créateur:
Nao
Hôte:
Kinyarwanda voice assistant # 🗣️ Kinyarwanda Voice Assistant (ASR + TTS) This project is a simple voice assistant that listens to `.wav` audio recordings in **Kinyarwanda**, transcribes them using a **Whisper ASR model**, finds a matching response, and replies using a **VITS text-to-speech model**. --- ## 🔧 Features - 🎙️ Transcribes spoken Kinyarwanda using `mbazaNLP/Whisper-Small-Kinyarwanda` - 🗣️ Responds with natural Kinyarwanda speech using `facebook/mms-tts-kin` - ✅ Matches predefined questions and answers - 📁 Saves and plays generated responses --- ## 📦 Installation ### 1. Clone the Repository ```bash git clone github.com cd Kinyarwanda_Voice-Assistant ## 📦 2. Install Dependencies Make sure you are using **Python 3.8+**, then install the required packages: ```bash pip install torch torchaudio transformers soundfile ``` --- ## 🖥️ FFmpeg Setup (Windows Only) To enable audio playback from the script, FFmpeg must be installed. ### 🔽 Steps to Install: 1. Download FFmpeg from gyan.dev 2. Extract the ZIP file 3. Locate the `bin` folder inside the extracted directory ### ⚙️ Choose One of the Following: **Option A — Add to System Environment Variables:** - Open "Environment Variables" - Add the full path to `ffmpeg\bin` to your system `PATH` **Option B — Modify the Script Directly:** In your Python script (`main.py`), add: ```python os.environ["PATH"] += os.pathsep + r"C:\path\to\ffmpeg\bin" ``` --- ## 🧠 Pretrained Models These models are automatically downloaded from Hugging Face when you run the script for the first time: | Task | Model Name | |---------------------|----------------------------------------| | ASR (Transcription) | `mbazaNLP/Whisper-Small-Kinyarwanda` | | TTS (Speech) | `facebook/mms-tts-kin` | --- ## 📂 Project Structure ```plaintext kinyarwanda-voice-assistant/ │ ├── data/ │ ├── audio/ # Input .wav audio fi …