Inspiration

This project was inspired by noticing people being stressed about managing their work-life balance while also worrying about overusing their AI limits.

What it does

The project gathers real-time accessibility screen captures to analyze the amount of words being typed, gains valuable information about the prompts, such as the character/word count, punctuation ratio, symbol ratio, etc., and sends a formatted .csv file to the backend, which is then fed onto a trained machine learning model to predict regression token values. Furthermore, we have created a physical display that the users can interact with so that they can keep their token usage in check at all times while also getting to see the cute emotes of the TokBot as it reacts to the tokens.

How we built it

The machine learning model and heuristic calculation have been added and implemented using the DataBricks platform. For the Python backend, we utilized the Flask framework, through which it communicates with the frontend interface, prompt reading, and the ML algorithm. The web app is made using Python and Streamlit, which is an open-source Python framework that helps turn data scripts into interactive web applications. The hardware was built using a Raspberry Pi 4 with a Grove base hat mounted on top of it, which helps connect Grove modules easier. The modules include a touch sensor and a button sensor, and we also used an OLED .96-inch display.

Challenges we ran into

The biggest challenge for us was the sheer amount of bugs we ran into everywhere in our code. From the OLED display not showing content and lagging to performance bugs when analyzing prompts, we spent hours debugging and building a robust program.

Accomplishments that we're proud of

We are proud that we built a system that has a wide coverage of different tools/frameworks, especially topics that were not relevant to our careers. Testing ourselves with concepts that we have never worked with before became our biggest challenge and yet our biggest accomplishment.

What we learned

Overall, we got accustomed to new tools, especially Databricks, which greatly helped organize our ML backend. Additionally, we learned a great deal about connecting hardware components to our software project, making them communicate and be able to create a product that is the best of both worlds.

What's next for TOK

Apart from expanding TOK to other languages, the next step is to turn this proof of concept into a tool that analyzes prompts on more robust factors than simply screen capture, incorporating previous chat history in the calculation, and build a sleek detachable design for our hardware with a 3D-printed final product.

Built With

Share this project:

Updates

Submission history