An intelligent audio studio for speech-to-text and text-to-speech processing, with full support for the Persian language.
| Section | Description | Type |
|---|---|---|
| STT — Speech to Text | Convert audio files to text using Whisper or Vosk | Local |
| Online STT | Convert speech to text using Gemini | Online |
| TTS — Text to Speech | Convert Persian text to speech with 5 distinct voices | Local |
| Podcast | Generate a two-person dialogue with two different voices | Local |
| Tone Lab | Generate speech with a variety of tones | Local |
| Voice Cloning | Clone a voice using Gemini | Online |
| ID | Persian Name |
|---|---|
amir |
Amir |
ganji |
Ganji |
gyro |
Gyro |
reza |
Reza Ebrahim |
mana |
Mana |
- Python 3.9+
- Node.js 18+
- FFmpeg (for audio processing)
git clone <your-repo-url>
cd "Voice2Voice"cd BackEnd
# Setup venv
python -m venv venv
\venv\Scripts\activate
# Install dependencies
pip install -r requirements.txt
# Automatically download models
python download_models.pyCreate a .env file (for online STT and voice cloning):
GEMINI_API_KEY=your_api_key_here
To get a Gemini API key: https://aistudio.google.com/app/apikey
Run the server:
uvicorn api_whisper_vosk:app --host 0.0.0.0 --port 8000cd Frontend
npm install
npm run devThen open your browser at http://localhost:5173.
Voice2Voice/
├── BackEnd/
│ ├── api_whisper_vosk.py # FastAPI — Local STT + TTS
│ ├── download_models.py # Script for automatic model downloads
│ ├── requirements.txt # Python dependencies
│ ├── .env # Gemini API key
│ └── models/
│ ├── tts/ # Piper TTS models (5 voices)
│ │ ├── amir/
│ │ ├── ganji/
│ │ ├── gyro/
│ │ ├── reza/
│ │ └── mana/
│ └── vosk-model-fa-0.42/ # Persian Vosk model
├── Frontend/
│ ├── components/ # React components
│ ├── services/
│ │ └── geminiService.ts # STT/TTS services
│ └── types.ts
├── tts/ # Standalone Streamlit TTS app
├── docs/
│ └── image.png # README image
└── README.md
MIT
