/group_responder

A telegram bot for telegram groups

Primary LanguagePython

Pencilbot

Telegram Chatbot with OpenAI ChatGPT This Telegram chatbot uses OpenAI's ChatGPT to provide natural language responses to user inputs. The bot is built with Python, and uses the Telegram Bot API to communicate with users. User IDs are stored in a MongoDB database for personalized interactions.

Requirements

To run this Telegram bot, you will need:

Python 3.x python-telegram-bot library OpenAI API key MongoDB

Installation

Installation

  1. Clone this repository to your local machine.
  2. Install the required libraries using pip:
  3. pip install -r requirements.txt
  4. Set the environment variables:
  5. TELEGRAM_TOKEN: Your Telegram bot token
  6. OPENAI_API_KEY: Your OpenAI API key
  7. MONGODB_URI: Your MongoDB URI

Run the bot:

python main.py

Usage

To use the bot, simply start a chat with it on Telegram. The bot will respond to user inputs with natural language responses generated by OpenAI's ChatGPT. The bot will also save the user ID in the MongoDB database for personalized interactions.

Contributing If you would like to contribute to this project, please open a pull request or submit an issue. All contributions are welcome!

License This project is licensed under the MIT License - see the LICENSE file for details.