Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alterxyz/telegram_speech_notebook
Telegram_bot Voice Notebook with Dify and Whisper
https://github.com/alterxyz/telegram_speech_notebook
Last synced: 23 days ago
JSON representation
Telegram_bot Voice Notebook with Dify and Whisper
- Host: GitHub
- URL: https://github.com/alterxyz/telegram_speech_notebook
- Owner: alterxyz
- License: mit
- Created: 2024-06-03T05:45:04.000Z (6 months ago)
- Default Branch: main
- Last Pushed: 2024-06-29T18:19:42.000Z (5 months ago)
- Last Synced: 2024-10-05T09:21:42.246Z (about 1 month ago)
- Language: Python
- Size: 21.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Telegram Speech-to-Text Bot
A simple Telegram bot that converts voice messages to text using Local or OpenAI-API[Whisper](https://github.com/openai/whisper), or Deepgram API.
Fix or refine the transcribed text with the Dify work flow.
## Features
- Your audio files are stored locally where the bot is hosted (when using Local Whisper)
- Transcribe voice messages to text, and it is editable!## Usage
1. Send a voice message or audio file to the bot
2. The bot will reply with the transcribed text
3. Try those buttons!## Requirements
- Python 3.x
- Telegram Bot Token
- Dify API for process transcribed text
- Speech-to-Text Service
- Local Whisper
- OpenAI API
- Deepgram API## Deployment
1. Clone this repository
2. Install the requirements by `pip install -r requirements.txt`
3. Set up the environment variables
1. Put your Telegram Bot Token in `bot.py`
2. Put your Dify API key in `audio_whisper.py` [view more detail](doc/deployment.md#dify)
3. Set up the Speech-to-Text Service and update at `bot.py` [view more detail](doc/deployment.md#speech-to-text-service)- Run `python3 bot.py` or `python bot.py` (run it with tmux to prevent it from stopping when you close the terminal)
## Future Work
- [x] Add GPT refinement to the transcribed text.
- [ ] Groq APIGLHF!