Skip to content

PhillMckinnon/GO_Whisper_Telegram_Bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GO Whisper Telegram Bot

License: MIT Go Version Docker Python Telegram Bot

This project is a Dockerized Telegram bot written in Go, designed to handle speech transcription and synthesis via a Python backend. The backend code is directly included in this repository, and is based on components from two of my earlier projects.


🔁 Code Reuse Acknowledgement

The Python backend in this repo reuses and adapts functionality from:

These repositories provided the foundation.


🧠 Features

  • Telegram bot built with Go (go-telegram-bot-api)
  • Two main actions triggered via buttons:
    • Transcribe: Upload a small audio or video file and receive a transcript
    • Synthesize: Upload a voice sample, enter text, choose output language, receive speech audio
  • Python backend handles:
    • File validation
    • Whisper transcription
    • Language detection and voice cloning
  • Dockerized and runnable via docker-compose

⚙️ Environment Setup

📁 frontend/bot/.env

Set your Telegram bot token:

TELEGRAM_BOT_TOKEN=your_token_here

📁 backend/.env

Configure backend settings:

PORT=5000
MAX_FILE_MB=20
MAX_FILE_DURATION_SEC=360
CORS_ORIGIN=http://localhost:8080

🚀 Running the Bot

Prerequisites

  • Docker
  • Docker Compose

Start the system:

docker-compose up --build

About

Go + Python, transcribe & synthesize audio files sent via a bot

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published