This project is a Telegeam bot that uses OpenAI for maintaining conversations. The bot is able to participate in group chats, follow the conversation context, and post comments when asked (it reacts to personal mentions and replies to its messages). The bot is also able to reply to private messages and follow the conversation context just like in group chats.
-
Clone the repository:
git clone https://github.com/khmarochos/dovbobot.git cd dovbobot
-
Create a virtual environment and activate it:
python3 -m venv venv source venv/bin/activate
-
Install the required dependencies:
pip install -r requirements.txt
-
Configure the bot by editing the
etc/.default.secrets.yaml
file with your OpenAI API key and Telegram token:openai: api_key: "your-openai-api-key" telegram: token: "your-telegram-bot-token"
To start the bot, run the following command:
python main.py
The bot's behavior and responses can be configured in the etc/default.yaml
file. You can adjust the logging level, system prompt, and common phrases used
by the bot.
Contributions are welcome! Please fork the repository and create a pull request with your changes.
This project is licensed under the MIT License. See the LICENSE
file for more
details.
If you encounter any issues or have questions, please open an issue on GitHub.
If the source code has helped you, consider making a donation to the "Democratic Axe" volunteer fund to support Ukrainian armed forces. Donate here.