Inspiration

We have completed one term of Computer Systems Technology at BCIT and we all come from various backgrounds/levels of programming, but one thing we all had in common was the need to keep track of all of the assignments that we got throughout our term. Ahead of our next term which starts just after the New Year, we wanted to create a bot that our class could utilize to keep track of all of the inevitable deadlines.

What it does

Spreadsheet Bot

  • Creates a spreadsheet of deadlines for specified courses.
  • Adds to the spreadsheet when a user inputs specified courses with the "add assignment" keyphrase.
  • Sends a message with the information for each assignment and it's due date when either "deadlines" or "due" keywords are entered into the channel.
  • Sends a message with the information for a specific course when the keyphrase "deadlines [course number]" is input.

Database Bot

  • Creates a database of deadlines for specified courses.
  • Adds to the database when the user inputs a specific keyphrase.
  • Updates database (removes old assignments) when the keyphrase "$UPDATE" is input.
  • Sends a message with information of assignments when "deadlines" is input.

How we built it

Using agile methodology and Python, we learned and utilized new Python modules in order to add functionality for our bot as we went along. We began by identifying the MVP as being the ability for the bot to read from an Excel file and send the data in the file as a message to the Discord channel when the designated keywords "deadlines" or "due" were entered into a test channel. In order to do this, the project utilizes the discord, dotenv, gspread, os, pandas, oauth2client, and datetime modules. Once this requirement was met, we determined additional functionality that we felt would create a more user-friendly bot and something that we would be able to utilize for our upcoming school term. We added the functionality for students to add to the spreadsheet by entering new information using a keyword.

In addition to this, our team member also created a bot which utilizes firebase to store assignment information in a database. This bot utilized the firebase_admin module for functionality. This allowed our program (and bot) to connect to a designated firebase database to read and write the data that we wanted.

Challenges we ran into

  • Coming up with a project that was not too ambitious for our skill level and experience in hackathons (this was our first).
  • Figuring out what we wanted to integrate into our project and it's functionality.
  • Determining the MVP portion of our project.
  • Determining how we wanted to implement our project: we initially worked with excel, then moved to google sheets, and also firebase.

Accomplishments that we're proud of

  • Being part of this first hackathon and coming up with an idea that we could implement even at just the basic level.
  • Learning about new Python modules which we had never used before such as openpyxl which can read from an external excel file.
  • Creating our first bot and being able to connect it to Discord.
  • All of the things that we learned over this 2-day hackathon!

What we learned

  • The functionality of new modules which we had not previously used with Python (discord, openpyxl, gspread, ezsheets, etc.)
  • Access to excel files and how to pull information from them to display as a bot message.
  • Access to firebase databases and how to pull information from them to display as a bot message.
  • How to create a Discord bot.

What's next for HomeworkBot

We would like to continue to grow it and add functionality to it in order to continue our understanding of Python. Additionally, as we continue through school we will likely add additional functions to further automate our bot and make it more effective in tracking our homework.

Built With

Share this project:

Updates