A professional multilingual real-time voice translation application with separate backend and frontend architecture.
Real_time_Voice_translater/
โ
โโโ backend/ # FastAPI Backend
โ โโโ app.py # Main API application
โ โโโ translation_graph.py # Translation engine
โ โโโ audio_handler.py # Audio processing
โ โโโ requirements.txt # Python dependencies
โ โโโ runtime.txt # Python 3.11.0
โ โโโ render.yaml # Render deployment config
โ โโโ .env # Environment variables
โ โโโ README.md # Backend documentation
โ
โโโ frontend/ # Web Frontend
โ โโโ index.html # User interface
โ โโโ app.js # Client-side logic
โ โโโ styles.css # Styling
โ โโโ README.md # Frontend documentation
โ
โโโ docs/ # Documentation
โ โโโ RENDER_DEPLOYMENT_STEPS.md
โ โโโ QUICK_DEPLOY.md
โ โโโ PROJECT_STRUCTURE.md
โ โโโ CLEAN_STRUCTURE.md
โ
โโโ .env # Root environment variables
โโโ .gitignore # Git ignore rules
โโโ serve_frontend.py # Development server
โโโ README.md # This file
- ๐ค Real-time Voice Translation - Speak and hear translations instantly
- ๐ฌ Text Translation - Type and translate between languages
- ๐ Multi-Language Support - English, Hindi, Telugu, Tamil, Kannada
- ๐ WebSocket Communication - Real-time bidirectional translation
- ๐จ Modern UI - Beautiful, responsive interface
- ๐ Secure - Environment-based API key management
- ๐ Free Deployment - Deploy on Render and Vercel for free
- Python 3.11+
- pip
- Git
- Web browser (Chrome/Edge recommended)
git clone https://github.com/YOUR-USERNAME/voice-translator.git
cd voice-translator# Create virtual environment
python -m venv venv
# Activate virtual environment
# Windows:
.\venv\Scripts\Activate
# Mac/Linux:
source venv/bin/activate
# Install dependencies
cd backend
pip install -r requirements.txt
# Create .env file
echo "GROQ_API_KEY=your_api_key_here" > .env
# Run backend
uvicorn app:app --host 0.0.0.0 --port 8000 --reloadBackend will be available at: http://localhost:8000
Open a new terminal:
# From project root
python serve_frontend.pyFrontend will be available at: http://localhost:3000
- Open http://localhost:3000 in two browser windows
- Enter the same room code (e.g.,
room123) - Select different languages in each window
- Start chatting!
- Backend README - API documentation, endpoints, deployment
- Frontend README - UI guide, customization, deployment
- Deployment Guide - Step-by-step deployment
- Quick Deploy - Quick reference commands
- Push code to GitHub
- Create account on Render
- Create new Web Service
- Connect GitHub repository
- Set root directory:
backend - Add environment variable:
GROQ_API_KEY - Deploy!
Detailed guide: RENDER_DEPLOYMENT_STEPS.md
- Create account on Vercel
- Import GitHub repository
- Set root directory:
frontend - Update API URL in
frontend/app.js - Deploy!
Detailed guide: Frontend README
- FastAPI - Modern Python web framework
- LangChain - LLM orchestration
- Groq API - Fast AI inference
- WebSockets - Real-time communication
- Uvicorn - ASGI server
- HTML5/CSS3/JavaScript - Modern web technologies
- WebSocket API - Real-time updates
- Web Speech API - Voice recognition and synthesis
- Glassmorphism UI - Modern design
GET /- Health checkPOST /translate- Translate textPOST /audio/translate- Translate audio
WS /ws/{room_id}- Real-time translation
Full API documentation: http://localhost:8000/docs
Create .env file in backend/:
GROQ_API_KEY=your_groq_api_key_here
PORT=8000Get your Groq API key from: https://console.groq.com
- Language Learning - Practice conversations in different languages
- International Teams - Communicate across language barriers
- Customer Support - Assist customers in their native language
- Travel - Communicate while traveling abroad
- Education - Teach and learn multiple languages
Contributions are welcome! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is open source and available under the MIT License.
- Groq - For fast AI inference
- LangChain - For LLM orchestration
- FastAPI - For the amazing web framework
- Render - For free hosting
- Vercel - For frontend hosting
Your Name - your.email@example.com
Project Link: https://github.com/YOUR-USERNAME/voice-translator
- First request after inactivity may take 30-60 seconds (Render free tier)
- Speech recognition requires HTTPS in production
- Some browsers may not support all features
- Add more languages (Spanish, French, German, etc.)
- Implement conversation history
- Add user authentication
- Support for group conversations (3+ people)
- Mobile app version (React Native)
- Offline mode with local models
- Voice cloning for personalized TTS
- Real-time video translation
- Translation Speed: ~500ms average
- WebSocket Latency: < 100ms
- Concurrent Users: Unlimited
- Uptime: 99.9% (on paid tier)
- API keys stored in environment variables
- CORS configured for security
- WebSocket connections validated
- No sensitive data logged
Free Tier:
- Render: 750 hours/month
- Vercel: Unlimited
- Groq API: Free tier available
Total Cost: $0/month for moderate usage
If you find this project useful, please consider giving it a star! โญ
Made with โค๏ธ by [Your Name]