Inspiration

We were really surprised that in debate tournaments we go to, there isn’t a proper way to create a tournament and automate it to save time. Therefore, we wanted to create a discord bot (since many debate tournaments and organizations broadcast information on discord) that takes user input (teams) and outputs a schedule that corresponds with team wins and losses.

What it does

Quivii is an open-source, modular Discord bot that can organize tournaments for anything and everything. Quivii takes user commands about the tournament and outputs a tournament schedule as well as stored data. It also uses Uptime robot, threading, and flask to stay in the discord channel even after you close the program.

How we built it

We built Quivii using Python. Our many functions were from the discord and commands module which would take user input, store it in a shelve file, then run algorithms to create a schedule based on the number of wins and losses each contestant/team had. We also used replit and Uptime Robot so that the bot does not disconnect after the program stops.

Challenges we ran into

We ran into many challenges during the challenge. At the start, most of us did not know how to use the discord module or anything to do with discord bots and python. We self-learned all of it in one day by going through youtube tutorials and stack overflow help.

We also didn't really know how to make many of the functions we have right now. We created the nextround function using a logic module we made, and a sorting and pairing algorithm.

Also, we had problems with multi-imports, embedding, the help function and the shelve module, which we had to learn and implement to store inputted data. ```import discord from discord.ext import commands import shelve

When we first tried to create the discord bot, we were faced with the problem of where to store the data. Hence, we used shelve, a useful module that creates a data file to store data. 
Later on, we also had to make sure the discord bot looked aesthetically pleasing so we learned and implemented embedding, and created our own help function.
Another difficult challenge was keeping the discord bot after we stopped the python script. To do that, we used Uptime Robot to monitor the bot, and flask to ensure that the bot did not disconnect after the program was stopped. 

## Accomplishments that we're proud of
We are really proud of how much we learned in such a short time frame. At the start of the hackathon, we had no idea how to create a discord bot, limited knowledge on shelve and other modules. We worked really hard going through tutorials, self-learning from sites such as w3schools and using online tools like Stack Overflow. To have a functional, diverse and aesthetically pleasing discord bot that solves our problem in the span of a few days is an accomplishment we'll definitely relish and build upon. 

## What we learned
We learned how to use the discord, commands and shelve module, as well as specific components in each: context, asynchronous or non-blocking, .dat files, await function, and more. Most importantly, we learned to stay calm, focus, and most importantly, self-learn using the abundance of the internet, working together on discord calls, and sharing program files and screen sharing files to each other. 
For most of us, this is our first hackathon, and we really put a lot of effort in creating a foundation before starting to program. That’s why we walked through many tutorials on the first day of the  challenge.

## What's next for Quivii
Quivii can be engineered towards other markets that use tournaments such as Twitch, FIDE chess, Sport Round Robin and can be a quick and convenient tournament planner. The logic component of our program can be made to create different tournament formats such as round robin, elimination, playoffs, etc… 

Built With

Share this project:

Updates