All Projects → Amirparsa-Sal → TA-BOT

Amirparsa-Sal / TA-BOT

Licence: other
An open source Telegram bot which can be used as a teaching assistant bot if you are trying to find an easy and secure way to communicate with your students.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to TA-BOT

kubernetes-automation-toolkit
This repository contains code examples and documentation for learning how applications can be developed with Kubernetes
Stars: ✭ 51 (+155%)
Mutual labels:  django-rest-framework
Bistu
集成了 django-simpleui 作为 admin 管理主题,实现的一个小型的管理系统,并且有的 django-rest-framework 使用示例。此外有个 Bistu-Ant-Design-Pro 项目作为配套的前端使用。如果喜欢记得给个🌟star哦。
Stars: ✭ 51 (+155%)
Mutual labels:  django-rest-framework
devops
基于python2.7.10+django1.11.6实现堡垒机,cmdb及批量任务功能
Stars: ✭ 23 (+15%)
Mutual labels:  django-rest-framework
django-rest-framework-files
File download and upload support for Django REST framework
Stars: ✭ 29 (+45%)
Mutual labels:  django-rest-framework
matchering-web
🎚️ Self-Hosted LANDR / eMastered Alternative
Stars: ✭ 25 (+25%)
Mutual labels:  django-rest-framework
django-mobile-app
A batteries-included mobile app backend in Django
Stars: ✭ 52 (+160%)
Mutual labels:  django-rest-framework
django-rest-framework-recaptcha
reCAPTCHA field for Django REST framework serializers
Stars: ✭ 24 (+20%)
Mutual labels:  django-rest-framework
drf-angular-docker-tutorial
Dockerized Django Back-end API using DRF with Angular Front-end Tutorial
Stars: ✭ 53 (+165%)
Mutual labels:  django-rest-framework
drf-addons
Some customised Django classes and functions that one can use in DJango. Collected from internet!
Stars: ✭ 20 (+0%)
Mutual labels:  django-rest-framework
smart-home
Control house using raspberry pi djago based secure REST api. Made using raspberry pi, arduino, django ,django REST and angular.
Stars: ✭ 30 (+50%)
Mutual labels:  django-rest-framework
BrewCenterAPI
An open source api for managing homebrewing related data.
Stars: ✭ 30 (+50%)
Mutual labels:  django-rest-framework
My Dashboard
A dashboard powered by Django, showing a notepad, scraping news articles and finance data with dash.py
Stars: ✭ 54 (+170%)
Mutual labels:  django-rest-framework
grpc-django-book-service
gRPC implementation integrated with Django Application.
Stars: ✭ 28 (+40%)
Mutual labels:  django-rest-framework
recipeyak
🍛 Application to automate the selection of meals and creation of shopping lists.
Stars: ✭ 23 (+15%)
Mutual labels:  django-rest-framework
django-code-generator
Generate code from your Django models for faster development
Stars: ✭ 35 (+75%)
Mutual labels:  django-rest-framework
ska
Sign data using symmetric-key algorithm encryption. Validate signed data and identify possible validation errors. Uses sha-(1, 224, 256, 385 and 512)/hmac for signature encryption. Custom hash algorithms are allowed. Useful shortcut functions for signing (and validating) dictionaries and URLs.
Stars: ✭ 39 (+95%)
Mutual labels:  django-rest-framework
python-wechat-pay
Use Python3, Django, Django-rest-framework to achieve wechat payment. 微信支付、服务器异步通知、订单查询、退款
Stars: ✭ 18 (-10%)
Mutual labels:  django-rest-framework
token-authentication-django
This is django app used to explain the tutorial present on https://medium.com/@shubhambansal_89125/token-based-authentication-for-django-rest-framework-44586a9a56fb
Stars: ✭ 27 (+35%)
Mutual labels:  django-rest-framework
django-flag-app
A pluggable django application that adds the ability for users to flag(or report) your models.
Stars: ✭ 13 (-35%)
Mutual labels:  django-rest-framework
django-test-addons
Testing support for different database system like Mongo, Redis, Neo4j, Memcache, Django Rest Framework for django
Stars: ✭ 20 (+0%)
Mutual labels:  django-rest-framework

TA BOT

This project is an open source Telegram bot which can be used as a teaching assistant bot if you are trying to find an easy and secure way to communicate with your students.

       

Features

  • Configurability

    The bot is designed to be configurable. as a result, you can use the bot for your course, no matter in which university and for which course you are trying to use the bot.

    You can edit all of the bot messages if you want them to be changed.

    You can edit all of the bot buttons if you want them to be changed.

    You can use your own email smtp to send one time passwords (OTP) to authenticate users.

    You can use your own email regex to validate users in registeration.

    You can set up the tables related to students data by uploading a csv,xlsx,json,yaml,... in admin panel very easily.

    You can set up a default secret key for the teacher or teaching assistants to access the telegram admin panel.

    You can set up your own course syllabus for categorizing resources and timeline.

  • Privacy & Security

    Before using the bot, you can upload your students data containing their email, student_id, first name, last name and password to authenticate them. Students then can register using that information.

    They must send their own email in telegram, then the bot sends a one time password to their email (if they have entered a valid email) and after entering that password, the account is created using the predefined passwords which you have uploaded in admin panel to use them as an authentication mean.

    Obviously, there is a login section in which the students can login to their account using an email and a password. Each student has its own account and he/she can login to the account with multiple devices at the same time.

  • Telegram Admin Panel

    There is an admin panel for teachers and teaching assistants in telegram. You can use the admin panel in any private chat or group. The teacher and the teaching assistant team can login to their account using a predefined secret key which you can configure and change it.

    In admin panel, you can access all the bot features such as homeworks, grading, answering questions, sending and receiving notifications and adding some resources for the course. Also there is a full CRUD support for some features like homeworks and grading which you can access all of them in admin panel.

  • Homeworks & Grading

    You can create new homeworks in admin panel and set a title, due date and a file to that homeworks to be shown to the students. Also, you can hide homeworks until you want them to be published.

    You can set a grade link for each homework which containts a link to grading sheet or something like that.

    Students can access the homeworks and the grading for each homework, in their own account.

  • Asking & Answering questions

    Students can ask their questions and you can anonymously answer them.

    The bot will forward the questions to all the chats that have access to admin panel if you have enabled incoming notifications for that chat. This means that you can have a seperate group for answering questions while you have other groups or chats for managing the bot. After answering the question, the bot will forward the answer to the student who had asked the question.

    Furthermore, you have access to a list of unanswered questions which you may want to answer them later.

  • Resources

    You can share some resources to students containing a title and a link. The resources are sorted by course syllabus. Students can access all resources related to a specific chapter of a course.

  • Timeline

    You can set the course timeline so that the students can be informed if a chapter is taught in the class.

  • Notifications (Available on next update)

    You can send notifications to all students to tell them if they have a new homework or a new grading sheet is uploaded anything else.

Deploying TA BOT

install Python(>3)

​ You can download and install the last version of the python from here.

install and Start Redis

​ You can download and install Redis from here.

Create a virtual Environment

​ while you are in the base folder of the project, run this command to create a new virtual environment:

python3 -m venv env

​ You can use any name instead of env.

Activate the Environment

​ Run the following command to activate the virtual environment:

source env/bin/activate

Install The Requirements

​ Inside the root folder of the project, run the following command. to install the python required modules:

pip3 install -r requirements.txt

Create Your Google SMTP Account and Config the Backend

​ You follow this guide to create your Google SMTP account.

​ Next, go to API/TA_BOT/TA_BOT and create a .env file:

touch .env

​ You must specify 4 items in that file. The first three items are related to the smtp account and the last one is the secret key which you use to access the admin panel.

EMAIL_HOST=smtp.gmail.com
[email protected]
EMAIL_HOST_PASSWORD=example_password
SECRET_KEY=example_secret

Migrate the database

​ Go to API/TA_BOT and migrate the database to create a SQLite database:

python3 manage.py migrate

Create a Superuser

​ Go to API/TA_BOT and create a superuser using this command:

python3 manage.py createsuperuser

​ Then you should enter an email and a password for superuser. The bot will use this superuser account to access some restricted APIs. So, remember that email and password because we need to set them in another .env file.

Config the Telegram Bot

​ Go to TelegramBot folder and create another .env file:

touch .env

​ You should specify 4 things in this file. Firstly, you should enter the bot token which you have generated using the BotFather. After that you should specify the email and password you used to create the superuser account, and finally there is an optional field which you can specify your own academic email regex to validate users. If you dont specify the regex, the default regex is for Amirkabir University Of Technology(****@aut.ac.ir)

BOT_TOKEN=example_token

BOT_API_EMAIL=the_email_you_used_to_create_superuser_account
BOT_API_PASSWORD=the_password_you_used_to_create_superuser_account

UNI_EMAIL_REGEX=^[A-Za-z0-9._%+-][email protected]

Run the Django Server

​ Go to API/TA_BOT and run the following command:

python3 manage.py runserver 8000

​ You can use your arbitrary port numbe(instead of 8000) to deploy the backend server.

Fill the Students Authentication Data and Course Chapters

​ You can use Django admin panel to fill the students authentication data. In order to login to the panel you should go to localhost:8000/admin and enter the email and the password for superuser account.

​ Click the section Auth Data. Then you can use import button to import students data using a csv,xlsx,json,yaml,... file. The file must contain the fields id, password, email, first_name, last_name and student_id for each student.

Also, you can enter the course chapters in Categories section. these chapters are used to sort the resources and to show the timeline of the course which you can edit it in telegram admin panel.

Run the Telegram Bot

​ Finally, go to TelegramBot folder and run the following command:

python3 bot.py

Congratulations! The bot is up and running now :)

Admins Secret Commands(Not a secret anymore)

They are just 2 more commands for admins:

/register_admin

This command is used to register a chat as admin. The user should send an arbitrary email and then the bot asks for the secret key and if the secret key is entered correctly the chat will have the admin access to the bot.

/answer

If the admin wants to answer a forwarded question, he/she should reply to that message with /answer command followed by the answer of the question. Ex: /answer this question is not related to this topic...

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].