Inspiration
In the vast sea of digital information, it's easy to get lost in the waves, spending countless hours sifting through messages, articles, and chats that offer little in return. We live in an era where staying informed is crucial, but so is efficiency. How do we strike a balance between staying up-to-date and not drowning in unnecessary information?
Imagine being part of a bustling discussion group with hundreds of members, each contributing their thoughts and ideas. It's a vibrant community, but it can also be overwhelming to keep pace with the constant flow of messages. Enter Brevitii.
Brevitii is more than just a solution; it's a revolution in how we consume information. Powered by Google Gemini's cutting-edge LLM technology, Brevitii is your personal assistant in the digital realm. It doesn't just filter out noise; it distills the essence of every message, chat, or conversation, presenting you with only the most relevant and important insights.
What it does
It can highlight the most important information in a chat history.
How we built it
Clone
git clone https://github.com/brevitii/brevitii.gitChange dir to root
cd brevitii/Download and install dependencies
python -m pip install -r requirements.txtRun the project
python brevitii.pyOpen Discord and add the bot to one of your servers using this invite: https://discord.com/oauth2/authorize?client_id=1230505478967005224&permissions=68608&scope=bot
Call Brevitii by using this command in the server:
$brief 1000000Wait until Brevitii finishes her magic.
Challenges we ran into
Limited number of tokens for
gemini-promodel. It offers a maximum of 30'720 tokens. This means the request prompt length must not exceed 122'880 characters as each token is equivalent to about 4 characters. See Model Variations for more information. During our prompt testing, we encountered an edge case where the maximum number of tokens was not 30'720 as expected, but rather 30'712. We've shared this feedback with the Gemini developers for further review.Quality of prompt. The quality of LLMs' prompts is always a problem.
Limited single message length in Discord. In Discord's free tier, messages are limited to 2'000 characters each, while the "gemini-pro" model can generate approximately 8'192 characters, equivalent to 2'048 tokens. However, in Discord's Nitro, messages are limited to 4'000 characters each which is still a problem. See Model Variations for more information. We solved this by sending the response in batches if the message length exceeded the limit.
Accomplishments that we're proud of
The results were unbelievable. Thanks to Gemini, Brevitii can understand and abbreviate many languages including Arabic. We tested Brevitii in Arabic and English Discord servers and she proved to be very unique, useful, and productive. We would like to share some test cases however, we can't due to privacy concerns.
What we learned
- We learned about Google Gemini which is enough of course.
- We learned how to use Discord SDK.
What's next for Brevitii
While deploying Brevitii for continuous operation is our top priority, our current student status means we're unable to invest in a cloud service at this time.
Enhance the Discord prompt to better suit Gemini's analysis. Remove irrelevant elements like user IDs (mentions) and replace them with
Global Namesto ensure greater accuracy in the analysis process.Enhance Brevitii by integrating support for the
gemini-pro-visionmodel, enabling it to process images along with text in the chat. Additionally, empower Brevitii to forward these images to the requester if deemed relevant by the Gemini model.Enhance Brevitii by integrating support for the
gemini-1.5-pro-latestmodel, enabling it to process videos (stream of images + audio) along with text in the chat. Additionally, empower Brevitii to forward these videos to the requester if deemed relevant by the Gemini model.Address the issue of prompt truncation. If the token count surpasses the limit, truncate the prompt accordingly to ensure it remains within the specified boundaries.
Limit the usage for each user by integrating a Database.
Built With
- discord
- discord-sdk
- python
- replit
Log in or sign up for Devpost to join the conversation.