Skip to content

A web application for real-time speech-to-text translation.

License

Notifications You must be signed in to change notification settings

peelajanu/AI-Voice-Assistant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Real-time Speech and Text Translation 🗣️➡️📜

Screenshot 2025-06-26 at 2 54 55 PM Screenshot 2025-06-26 at 2 55 26 PM

This is a web application that provides real-time speech and text translation. It combines a Python backend using the Flask framework with a JavaScript frontend to capture audio, translate spoken words into text, and display the results.

✨ Features

  • Real-time Speech-to-Text: Captures audio input from a microphone and converts it into text.
  • Live Text Translation: Translates the recognized text into another language.
  • Web-based Interface: A user-friendly, responsive interface built with HTML, CSS, and JavaScript.
  • Modular Design: The project is organized into separate files for different functionalities, such as speech processing (speech.py), translation (translate.py), and the main application logic (app.py).

⚙️ Technologies Used

  • Python: The core language for the backend.
  • Flask: A micro web framework for the backend server.
  • SpeechRecognition: A library to perform speech recognition with support for various engines and APIs.
  • Googletrans: A Python library for translating text using the Google Translate API.
  • JavaScript: The scripting language for the frontend, handling user interactions and API calls.
  • HTML & CSS: Used to structure and style the web application's interface.

🚀 Getting Started

Prerequisites

You need Python 3.x and pip installed on your system.

Installation

  1. Clone the repository:

    git clone [https://github.com/YOUR_USERNAME/your-repo-name.git](https://github.com/YOUR_USERNAME/your-repo-name.git)
    cd your-repo-name
  2. Set up the Python environment: It's recommended to create a virtual environment.

    python -m venv venv
    source venv/bin/activate  # On Windows, use `venv\Scripts\activate`
  3. Install the necessary Python libraries:

    pip install Flask SpeechRecognition googletrans==4.0.0-rc1

    Note: The specific version of googletrans is recommended for stability.

Usage

  1. Run the Flask application:
    python app.py
  2. Access the web application: Open your web browser and navigate to http://127.0.0.1:5000. The interface will be displayed, and you can begin speaking into your microphone to see the real-time translation.

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

🤝 Contribution

Contributions are welcome! If you find a bug or have an idea for an improvement, please open an issue or submit a pull request.


Note: This project relies on external APIs (like Google Translate), so an active internet connection is required for full functionality.

About

A web application for real-time speech-to-text translation.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published