Akash98Sky / gemi-bot

Gemi is a telegram chat bot assistant with text, image and file handling capabilities.
https://t.me/MyGemibot
MIT License
1 stars 4 forks source link
assistant chatbot chatgpt gemini-api gemini-pro image-generation llm telegram-bot telegram-chat-bot

Gemi Chat Bot

Gemi is a Telegram chat bot that leverages the gemini-pro API for text-based message generation and Bing for image generation. It is designed to interact with users by processing text and image inputs and responding appropriately.

Features

One-Click Deployment

Use the button below to deploy your own Gemi bot on Render.

Deploy to Render

Note: You need a Render account to use this. Or, create your free account here.

Quick Start

To get started with Gemi chat bot, follow these steps:

Prerequisites

Installation

  1. Clone the repository:
git clone https://github.com/Akash98Sky/gemi-chat-bot.git
cd gemi-chat-bot
  1. Install the required dependencies:
pip install -r requirements.txt

Configuration

Create a .env file at the root of the project directory with the following environment variables:

BOT_TOKEN=<your_telegram_bot_token>
GOOGLE_API_KEY=<your_gemini_pro_api_key>
BING_COOKIE=<your_bing_auth_cookie>

# Webhook settings to wake up the bot (optional) - required only if your service spins down while idle (e.g.: Heroku, Render)
APP_HOSTNAME=<your_webhook_host> (e.g.: abc.xyz.com)
WEBHOOK_SECRET=<your_webhook_secret>

# Voice API settings
VOICE_API_URL=<your_voice_api_url>
TTS_VOICE=festival:cmu_us_slt_arctic_hts
STT_ENGINE=vosk

Running the bot

Use gunicorn to launch the application:

gunicorn main:web_app --bind 0.0.0.0:8080 -k aiohttp.GunicornWebWorker

Replace 8080 with the port you want to run your web server on.

Running the Gemi voice API

If you want to use the Gemi voice API, follow the instructions below:

Webhook on localhost

Documentation

For more details on how to use and extend the bot, refer to the inline documentation within the code and the official aiogram and google-generativeai libraries documentation.

Contributing

Contributions are welcome. Please submit pull requests or create issues for any features or fixes.

License

This project is open-sourced under the MIT License.