A Gemini Discord bot that can accept images and has conversation memory
Discord bot that leverages the power of Google's Gemini-Pro API to interact with users in both text and image formats. It processes messages and images sent to it, generating creative and engaging responses.
Clone the repository to your local machine.
Install the required Python libraries:
pip install -U -r requirements.txt
The bot will start listening to messages in your Discord server. It responds to direct mentions or direct messages.
Create a .env
file and copy the contents of .env.example
into it
Fill in the following values:
DISCORD_BOT_TOKEN
: Your Discord bot tokenGOOGLE_AI_KEY
: Your Google AI API key. Google API Key can be acquired from https://makersuite.google.com/
MAX_HISTORY
: The maximum number of messages to retain in history for each user. 0 will disable historyGeminiDiscordBot.py
Feel free to fork the project and customize it according to your needs. Make sure to follow the guidelines set by Discord and Google for bot development and API usage.