Skip to main content

Telegram bot for text generation, text-to-image and text-to-audio conversions.

Project description

License Python version PyPi Black Downloads wakatime

Welcome to pytgpt-bot

This is a Telegram bot based on python-tgpt, a powerful tool designed to enhance your interactions with AI. This bot is built on the robust foundation of the pyTelegramBotAPI and offers a wide range of features to make your experience with AI more engaging and interactive. Whether you're looking to chat with AI, generate images and audio from text, pytgpt-bot has got you covered.

Prerequisites

Installation

  1. From Source

Clone repo and install.

git clone https://github.com/Simatwa/pytgpt-bot.git
cd pytgpt-bot
pip install .
  1. From Pypi (recommended)
pip install pytgpt-bot

Usage

Before getting started, ensure you've your Telegram bot token. If that's not the case then purpose to secure one from @BotFather.

Proceed to fill the env configuration file as per the needs and then rename it .env before firing up the server python3 run.py.

Alternatively, using CLI interface::

$ pytgpt-bot run <Your Telegram Token>

Features

1. Chat with AI

  • Command: /chat
  • Description: Engage in a conversation with AI. This feature allows you to interact with the bot in a natural, conversational manner.

2. Generate Images from Text

  • Command: /imager

  • Description: Generate images from text descriptions. This feature uses AI to create visual representations of your text inputs, making it a fun and creative way to explore the capabilities of AI.

  • Variant: /prodia

  • Description: Generate images from text descriptions using the Prodia AI model. This variant offers a different style of image generation, providing a unique twist to your creative endeavors.

3. Generate Audio from Text

  • Command: /audio
  • Description: Generate audio from text. This feature allows you to convert your text inputs into spoken words, enabling you to listen to the AI's voice or use the audio for other purposes.

4. Check Current Chat Introduction

  • Command: /intro
  • Description: Check the current chat introduction. This feature allows you to view the introduction text set for the current chat, providing context and setting the tone for your interactions.

5. Check Chat History

  • Command: /history
  • Description: Check the chat history. This feature allows you to review past interactions within the chat, helping you to recall previous discussions and decisions.

6. Set New Value for Chat Introduction

  • Command: /sintro
  • Description: Set a new value for the chat introduction. This feature enables you to customize the introduction text for the current chat, allowing you to tailor the conversation to your preferences.

7. Start New Chat Thread

  • Command: /reset
  • Description: Start a new chat thread. This feature allows you to begin a fresh conversation with the bot, resetting the chat history and allowing for a new start.

8. Echo Your Telegram ID

  • Command: /myid
  • Description: Echo your Telegram ID. This feature provides you with your unique Telegram ID, useful for personalized interactions or for troubleshooting purposes and configuring admin.

9. Clear chat data

  • Command: /clear_database
  • Description: This is an administrative command for deleting all entries of chat database. The user's Telegram ID must match the one set at the .env config file.

10. Default Chat with AI

  • Command: <Any other text>
  • Description: Engage in a default chat with AI. This command is a shortcut to the /chat command, offering a quick and straightforward way to start a conversation with the bot.

Support and Feedback

If you have any questions, feedback, or suggestions for pytgpt, please feel free to reach out. Your input is valuable in helping us improve and expand the bot's capabilities.

License

pytgpt-bot is open-source and available under the MIT License. Feel free to use, modify, and distribute the code as you see fit.


Thank you for using pytgpt-bot. Enjoy your AI-powered interactions!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytgpt_bot-0.0.3.tar.gz (11.7 kB view hashes)

Uploaded Source

Built Distribution

pytgpt_bot-0.0.3-py3-none-any.whl (10.5 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page