Skip to content

A fast, modular, asynchronous, highly-configurable, plug and play Telegram bot 🤖

License

Notifications You must be signed in to change notification settings

obviyus/SuperSeriousBot

Repository files navigation

Logo

GitHub commit activity Build Docker Image Size

GitHub license GitHub release (latest by date including pre-releases)

Telegram Link

SuperSeriousBot

A modular, asynchronous, highly-configurable, plug and play Telegram bot built using the fantastic python-telegram-bot library.

Introduction

A recent rewrite has just wrapped up, making SuperSeriousBot completely asynchronous. The rewrite also included:

  • a general clean up of all functions
  • combining the many different database files into a single SQLite file
  • using poetry for dependency management
  • warn and disable functions with missing API keys
  • improved logging to develpoment channel

✨ Features

By adding this bot to your group you can use this growing set of functions. Notable ones include:

  • Granular chat statistics of any group
  • An obect-store to save any image, video, GIF, audio etc. with a key
  • Send a random image generated by MidJourney
  • Live weather and predictions for any location
  • Generate text-to-speech using translatepy
  • Translate a text from any language to any other
  • Generate a TLDR of any article
  • QuoteDB for adding and retreiving messages
  • A social graph of all members in a chat using visjs
  • Audio transcription using OpenAI Whisper

... and many more! To see a complete list of commands send /help to @SuperSeriousBot

🏗 Usage

Configuration

Before you can begin, you'll need to get a token and API keys for your bot. You can get the token from @BotFather.

Run the following command to generate an empty environment file:

$ git clone https://github.com/obviyus/SuperSeriousBot
$ cp .env.example ssgbot.env
  1. Now fill up the .env file with all the API keys you need. The only mandatory key is the Telegram bot token.

Running

SuperSeriousBot is run via Docker. The latest image can always be found at: http://ghcr.io/obviyus/SuperSeriousBot.

To start the bot you only need the docker-compose.yml and a valid ssgbot.env file.

$ docker-compose up

Development

We also use Docker as the preferred development environment:

$ docker-compose up

Any changes to the code persist through container restarts, no need to rebuild the image for a single change. In the future I may experiment with adding nodemon for watching files.

Recommended Reading

Contributing

This repository uses the automated semantic-release suite of tools to generate version numbers. All commit messages must conform to the Angular Commit Message conventions.