Inspiration

We realized many people, especially students and young adults, struggle to keep track of their spending. Manually logging expenses is tedious, and existing apps can be complex or lack insightful feedback. We wanted to create a simple, visually engaging tool that not only tracks spending effortlessly through receipt scanning but also educates users about their financial habits using the power of AI, making personal finance less intimidating and more actionable.

What it does

FinSight acts as a personal finance coach. Users can upload or take pictures of receipts, and the app uses Mindee OCR to automatically extract item details and prices. It then categorizes these expenses (like Groceries, Snacks, Household) and even attempts to classify them as 'Wants' or 'Needs' using Google Gemini AI. The dashboard provides a clear overview of spending patterns (weekly, monthly), compares spending against a user-set budget goal, and visualizes spending by category. Crucially, it offers an AI Insights page that analyzes the spending data to provide concise, actionable tips on potential savings and smarter spending habits.

How we built it

We chose Python as our core language and Streamlit to rapidly build the interactive web application interface. For receipt scanning, we integrated the Mindee API for its specialized OCR capabilities. The core intelligence comes from Google's Gemini API, which we use for item categorization (Want/Need, Category type) and generating personalized financial insights and tips. We used Pandas for data manipulation and storing the expense data within the Streamlit session state. Plotly was used to create the interactive pie chart for visualizing spending breakdowns. The project structure utilizes Streamlit's multi-page app format, separating the Dashboard, Upload Receipt, and AI Insights functionalities into different pages. API keys and sensitive information are managed using a .env file and the python-dotenv library.

Challenges we ran into

Integrating multiple external APIs (Mindee and Gemini) smoothly presented challenges, requiring careful handling of API keys and potential errors. Ensuring the OCR accuracy from Mindee across various receipt formats was an iterative process. Prompt engineering for the Gemini API was key – getting the AI to provide consistently useful, concise, and correctly formatted insights and categorizations required experimentation. Managing application state (like the list of expenses and budget goals) across different pages and user interactions in Streamlit required careful use of st.session_state. We also needed to handle data serialization correctly when passing data (like dates) to the AI model.

Accomplishments that we’re proud of

We're proud of creating a seamless user experience, from uploading a receipt to seeing actionable insights with just a few clicks. Successfully integrating both OCR and generative AI to provide automated expense tracking and personalized financial advice is a key accomplishment. Building an intuitive dashboard with clear visualizations and budget tracking helps users quickly understand their financial picture. The AI-driven categorization of wants vs. needs adds a unique educational layer.

What we learned

This project taught us a lot about integrating third-party APIs effectively and handling potential failures gracefully. We gained significant experience with Streamlit for building data-centric web applications and managing its state model. We learned valuable skills in prompt engineering to elicit specific, structured responses from large language models like Gemini. Furthermore, we deepened our understanding of data processing with Pandas and data visualization techniques with Plotly. Building FinSight reinforced the importance of user-centered design in making complex topics like finance accessible.

What’s next for FinSight

We envision several future enhancements for FinSight. Adding more sophisticated analytics, like trend analysis over longer periods or spending comparisons month-over-month, would be valuable. Exploring secure integration with bank accounts (using services like Plaid) could automate expense tracking further. Refining the AI categorization and insight generation based on user feedback is also a priority. We could also introduce features like setting specific savings goals (e.g., for a vacation) and tracking progress towards them.

Built With

Share this project:

Updates