CoolFace
Apppublic

K2-k2/SpeakSync-AI

sourceHugging Facemitupdated 6mo agoView on Hugging Face
0likes
App README

๐ŸŽ™๏ธ SpeakSync AI

A powerful, real-time voice translation bridge built with Streamlit, OpenAI Whisper, and Google Gemini 2.5 Flash. Speak in your native tongue and let AI handle the transcription, translation, and vocal synthesis instantly.

๐ŸŒŸ Overview

SpeakSync AI is designed to break language barriers by combining state-of-the-art Speech-to-Text (STT), Large Language Models (LLM), and Text-to-Speech (TTS) technologies. Whether you're recording live or uploading a file, the app detects your language and speaks back to you in your chosen target dialect.

๐Ÿ› ๏ธ Key Features

  • โ€”Dual Input Modes: Record directly via your microphone or upload audio files (mp3, wav, m4a).
  • โ€”Whisper Powered: Uses OpenAI's Whisper (Base) for high-accuracy, multilingual transcription.
  • โ€”Gemini 2.5 Flash: Leverages Google's fastest model for nuanced, context-aware translations.
  • โ€”Auto-Detect: Not sure what language is being spoken? The AI identifies it for you.
  • โ€”Instant Playback: Automatically generates and plays the translated audio using Google Text-to-Speech (gTTS).
  • โ€”Smart UI: Features a seamless language swap toggle and persistent session states.

๐Ÿš€ Deployment on Hugging Face Spaces

  1. 1.SDK: Select Streamlit when creating your Space.
  2. 2.Secret Keys: Go to Settings > Variables and Secrets*.
  3. 3.Add GOOGLE_API_KEY_N with your Gemini API Key from Google AI Studio.
  4. 4.Requirements: Ensure your requirements.txt includes:
text
    streamlit
    openai-whisper
    torch
    google-generativeai
    gTTS
  1. 1.System Packages: Create a packages.txt file (required for Whisper/Audio) and add:
text
    ffmpeg

๐Ÿ—๏ธ The Tech Stack

  • โ€”Frontend: Streamlit
  • โ€”STT (Speech-to-Text): OpenAI Whisper
  • โ€”Translation Engine: Google Gemini 2.5 Flash
  • โ€”TTS (Text-to-Speech): gTTS (Google Text-to-Speech)
  • โ€”Processing: Torch (CPU/CUDA optimized)

๐Ÿ’ป Local Setup

bash
# Clone the repository
git clone [https://huggingface.co/spaces/K2-k2/SpeakSync-AI](https://huggingface.co/spaces/K2-k2/SpeakSync-AI)

# Install dependencies
pip install -r requirements.txt

# Run the app
streamlit run app.py

Developed by Kesar Agarwal an aspiring AI Engineer focused on creating accessible, agentic AI tools.

Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference