Code Monkey home page Code Monkey logo

kaishnik-bot's Introduction

Каист Бот

telegram & vk bot for students of KNRTU-KAI to make their daily routine more pleasant

Stack

On Telegram

On Telegram

On VK

On VK

Reason

The bot might be considered as kai.ru wrapper. Official mobile-unfriendly ugly inconvenient website had to be replaced by something usable. Here the @kaishnik_bot comes in.

Setup

Since the university is located in Kazan which is the Moscow time zone, the time zone should be set to Europe/Moscow.

Data

There should be data/ folder in the root directory of the bot. It should contain keys non-extension file with tokens & keys accessed using config module.

Launch setup

The requirements.txt file is included to the repository. So, use pip3 install -r requirements.txt to get all the necessities. Use python3 ./ to launch.

Architecture

The bot is stored in project root directory folder called bot/. The bot/ contains 3 subdirectories:

  • platforms/ - implementation of the bot on a variety of social networks.
  • models/ - classes of peewee models of data stored in PostgreSQL database.
  • utilities/ - additional code that takes student data from the university servers, connects the bot to the database, and so on.

Each command has its own directory:

*command_name*/
├── __init__.py
├── *commands_file*.py
├── *commands_file*.py
├── guard.py
└── utilities/
    ├── keyboards.py
    ├── helpers.py
    ├── constants.py
    └── types.py

The structure is essential meanwhile all the noted files are optional. One-file commands are exceptions, and are located in bot/platforms/<platform>/commands/others/ directory. bot/platforms/<platform>/commands/schedule/ directory is also an exception, and may be considered as a super-command which consists of 3 similar, but separate commands.

Other stuff

  • update-logs/ folder contains notes which were sent to users as update announcements.
  • design/ folder contains .pxd & .png files with all the bot associated design.

Design

All the stuff was drawn using Pixelmator Pro.

kaishnik_bot poster

kaishnik-bot's People

Contributors

airatk avatar dependabot[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.