Skip to content

LexiBot is a Discord bot designed to transcribe and translate audio from video URLs. With support for Whisper AI and Deep Translator, this bot can convert speech from videos into text and translate it into a target language.

Notifications You must be signed in to change notification settings

Xerx81/Transcribe-X-Translate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LexiBot - Discord Transcription & Translation Bot


Overview

LexiBot is a Discord bot that transcribes and translates audio from videos into text. Users provide a video URL, and the bot:

  1. Downloads the video's audio.
  2. Transcribes the audio using OpenAI's Whisper AI model.
  3. Translates the transcription into the desired language using Google Translate.
  4. Sends the transcription and translation as downloadable .txt files in Discord.

Features

  • Slash command (/lexibot) for ease of use.
  • Supports multiple languages for translation.
  • Handles large transcriptions and translations by saving them as .txt files.
  • Powered by Whisper AI for accurate transcription.

Setup Instructions

  1. Clone the repository:

    git clone https://github.com/Xerx81/Transcribe-X-Translate.git
    cd Transcribe-X-Translate
  2. Create and activate virtual environment:

    python3 -m venv .venv
    source .venv/bin/activate

    For windows:

    source .venv\Scripts\activate
  3. Install dependencies:

    pip install -r requirements.txt
  4. Whisper and yt-dlp requires FFmpeg to work properly. Install here

  5. Add your bot's token in the .env file:

    TOKEN=your_discord_bot_token
    
  6. Run the bot:

    python main.py

Bot Command Details

  • Command: /lexibot
    • Parameters:
      • video_url: URL of the video for transcription (e.g., YouTube link).
      • translate_lang: Language code for translation (e.g., en for English, fr for French).

Credits

  • Transcription: Whisper AI by OpenAI.
  • Translation: Google Translate API.
  • Audio Download: yt-dlp.
  • Discord Bot Framework: discord.py.

Screenshot

image


About

LexiBot is a Discord bot designed to transcribe and translate audio from video URLs. With support for Whisper AI and Deep Translator, this bot can convert speech from videos into text and translate it into a target language.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages