Inspiration

When thinking about our favorite childhood shows/movies, we always noticed one recurring theme among fan-favorite characters: Wisdom. In some way, they would give relevant quotes or advice applicable to the main character's situation. Whether it be Yoda from Star Wars, Master Oogway from Kung Fu Panda, or Uncle Iroh from Avatar: The Last Airbender, these were the characters that would leave a lasting impression and be 'quoted' thereafter when people reflected on their old-time memories.

There’s a kind of “formula” to movie-style quotable advice. First, you come up with some general uplifting theme, and then you word it to fit the current situation. It seemed pretty doable and was a great way to improve our programming experience. And that’s how Aurora was born.


What it does

On the user side, our app first displays a base screen that prompts the user about their day. After talking about how their day went, the app fetches a quote from a prewritten database that most directly addresses the user’s issues. Then, the user plays a relaxing word game to reveal the final quote and author. Afterward, they can restart the program.


How we built it

Quote Selection:

We implemented this overarching formula in a way that is better suited to the specific situation where you have a database of sentences and you want to choose the one most apt for the occasion, as opposed to simply generating the quote. Generative AI can’t do everything right now, especially when referencing pre-existing text in a manner that keeps the same "mysticism" of a quote.

So, we broke this process down into two parts:

  1. Find a few quotes with somewhat similar semantic meaning to the user input using an embedding function.
  2. Select the quote which would be most effective.

Why not skip straight to the end with the embedding function? In the vast majority of cases, this approach works fine. However, sometimes the quote can be insensitive or off-putting because the embedding only focuses on matching sentence meanings. After the number of possible quotes was narrowed down to a select few with the embedding function, we used Gemini to ensure the selected quote would be appropriate for the user.


Back End:

We used FastAPI to quickly set up a local server using Python, including a default response for when the API was reached and an additional response for POST requests containing the user input. We also created a requirements.txt file in case the backend needed to be deployed remotely, allowing for easy installation of all required packages.


Front End:

Our initial prototypes for the UI and game were designed in React Native using the online development environment Snack from Expo. After this initial design, we moved to the local environment and continued development in Android Studio. This simplified the process of communicating between the frontend and backend because we didn’t have to worry about port-forwarding or paying for server hosting.

The app is essentially split into three React components, one for each screen. There is a callback for fetching the correct quote after the user input, and this took some of the most time to get right, as it was difficult to differentiate between when a React state updated incorrectly and when the server wasn’t being reached.


Challenges we ran into

The biggest challenges we encountered involved connecting the backend and frontend elements. After organizing FastAPI and running it locally, a large portion of time was dedicated to constant debugging of fetch request errors and communication between different networks. We anticipated this part to be relatively simple, but we quickly learned that in practice, network connections can be very complicated when working with multiple frameworks and programs.


Accomplishments that we're proud of

  • On the technical side, incorporating NLP embeddings to return relevant quotes to the user's experience was a feature we were particularly proud of.

  • The extensive debugging of backend/frontend communication was challenging, but overcoming this hurdle and seeing the system dynamically change responses was inspiring. This process has prepared us for future app development and software engineering projects.

  • Qualitatively, we’re really pleased with the feel of the product and the user experience. During times when we got frustrated or tired, we would actually find pleasure in telling our app about our situation and receiving meaningful feedback. For instance, we once wrote “I feel like giving up on this very complicated debugging problem” and were returned the quote:

    “Most of the important things in the world have been accomplished by people who have kept on trying when there seemed to be no hope at all.”

These responses genuinely inspired us, validating that our product could be beneficial to users.


What we learned

We learned immensely from this project. Coming into it with almost no app development experience and a limited understanding of natural language processing, we developed skills in handling React Native, implementing data-related back-end libraries, and using collaboration tools and frameworks. It was one of our first experiences properly using GitHub for large project collaboration, giving us a sense of what a real full-stack experience is like.

We also made many mistakes, but each one taught us valuable lessons. We now know how to properly use back-end APIs and connect them to servers for proper app deployment. Understanding GET/POST requests, asynchronous functions, fetching, and many more elements has helped us contextualize how modern software functions today.

This project gave us technical skills, a new paradigm for approaching full-stack development, and the rewarding feeling of making a project that can have an impact.


What's next for Aurora

Going forward, we’d like to continue to expand on Aurora’s UI, and optimize its backend algorithms, to give it a production-ready user experience. We’ve brainstormed other features that we could implement to make it a more full-fledged product and build around the theme of making an application to improve someone’s mood. We can’t wait to see where the future takes us!

Built With

Share this project:

Updates