This Telegram bot utilizes Large Language Models (LLM) for summarizing and answering questions about YouTube videos. It provides users with concise summaries and responses based on the content of the videos.
- Summarize YouTube videos: The bot can generate brief summaries of YouTube videos.
- Answer questions: Users can ask questions about the video content, and the bot will attempt to provide relevant answers.
- Telegram integration: The bot is integrated with Telegram messenger, allowing users to interact with it seamlessly.
The application is deployed using Docker Compose, with two containers for Redis and Python.
- Docker
- Docker Compose
- Install Git and Docker Compose
sudo apt install git docker-compose
- Add current user to Docker group
sudo usermod $(whoami) -a -G docker
- Clone the current repository
git clone https://github.com/stepvg/youtubot.git
- Navigate to the project directory:
cd youtubot/
- Add a Telegram token and change the necessary parameters in the .env file.
editor .env
- Run containers
docker-compose up -d --build
- The bot should now be running and accessible via Telegram.
- Start a conversation with the bot on Telegram.
- Send a YouTube video link to the bot.
- Optionally, ask questions about the video content.
- The bot will respond with a summary or answers based on the provided video.
The bot's behavior and settings can be configured via environment variables or a .env
file. The following variables are available:
HUGGING_FACE_EMBEDDINGS
: The name of the embeddings model, which can be obtained from the huggingface.TELEGRAM_BOT_TOKEN
: Telegram bot token obtained from BotFather.GIGACHAT_CREDENTIALS
: API key for accessing the GigaChat Large Language Model service.REDIS_HOST
: Hostname for the Redis container.REDIS_PORT
: Port for accessing the Redis container.REDIS_PASSWORD
: Password for accessing the Redis container.
Contributions to the project are welcome! Please fork the repository, make your changes, and submit a pull request.
This project is licensed under the MIT License.
- Docker Compose file describes the Redis server and the bot application.
- Python file contains the entry point to the bot application.
- Dockerfile describes the Docker image that is used to run the bot application.