💡 Inspiration
Managing personal finance is a major hurdle for college students and young professionals. Spreadsheet formulas are tedious to maintain, traditional budgeting apps feel like chores, and financial advice online is scattered, generic, and dry.
We noticed two major patterns:
- Manual Logging Friction: People stop tracking expenses because opening an app and entering fields is too many clicks.
- Analysis Paralysis: Traditional charts are hard to interpret. Users don't want static graphs; they want a personalized strategy.
We built FinSage to solve this. It's a dark-mode, cyberpunk-aesthetic co-pilot designed to democratize high-quality financial guidance. By moving transaction logging to WhatsApp and synthesizing multi-agent advice into a programmatic video briefing, we make budgeting as simple as texting a friend.
🛠️ How We Built It
FinSage is architected as a full-stack, modular ecosystem. Below is the system flow and database integration mapping:
┌────────────────────────┐
│ USER │◀────────────────────────┐
└────────────────────────┘ │
│ │ │
(WhatsApp) │ │ (React Web / Expo App) │ (Briefing Video)
▼ ▼ │
┌───────────┐ ┌───────────┐ │
│ Twilio │ │ Client UI │ │
└───────────┘ └───────────┘ │
│ (Webhook) │ │
▼ ▼ │
┌────────────────────────────────┐ │
│ Express API Backend │ │
└────────────────────────────────┘ │
│ │ │ │ │
▼ ▼ ▼ ▼ │
┌───────┐ ┌─────────┐ ┌──────┐ ┌───────────────┐ │
│Firebase││ MongoDB │ │Math │ │ Alpha Vantage │ │
│(Auth) ││ (Data) │ │Engine│ │ (Market Data) │ │
└───────┘ └─────────┘ └──────┘ └───────────────┘ │
│ │ │
▼ ▼ │
┌──────────────────┐ │
│ Groq AI Hub │ │
│ (Llama 3.1 LLM) │ │
└──────────────────┘ │
│ │
▼ │
┌──────────────────┐ │
│ AI Agent Council │ │
│ (Multi-Agents) │ │
└──────────────────┘ │
│ │
▼ │
┌──────────────────┐ │
│ Remotion Engine │───────────────────┘
│ (Video Compiler) │
└──────────────────┘
🛰️ The Data Flow Breakdown
- Frictionless Ingestion: The user texts a transaction to our Twilio number (e.g.
expense, food, 350, Lunch). Twilio triggers a secure webhook to our Express API, which parses and records it in MongoDB. - Personalized Analysis: The backend calculates financial projections over a 10-year horizon using our mathematical modeling engine and queries stock details via the Alpha Vantage API.
- AI Agent Debate: Groq AI coordinates a multi-agent system where four specialized agents analyze the data:
- Budgeting Agent: Analyzes spending patterns, sets limits, and flags high-expenditure categories.
- Savings Agent: Optimizes savings progress based on active short-term and long-term goals.
- Debt Agent: Recommends optimal payoff routes (avalanche vs. snowball) based on interest rates.
- Investment Agent: Suggests asset distributions (FDs, Mutual Funds, Equity) matching risk appetite.
- Programmatic Video Generation: The synthesized strategy is compiled into a dynamic 30-second briefing video using Remotion, allowing React components to be rendered directly into MP4 files for the user.
🚧 Challenges We Faced
- Agent Coordination & Consistency: Getting four separate AI agents to output a single, non-conflicting action plan without loop delays was tough. We solved this by creating a centralized JSON-structured schema and using parallel aggregation prompts.
- API Rate-Limiting & Performance: Financial data APIs (like Alpha Vantage) have strict rate limits. We built robust mock fallback engines inside
stockController.jsto ensure the app never crashes for judges, maintaining a seamless UX. - Programmatic Video Generation: Combining live database states with Remotion scene sequences required precise keyframing and state management inside React to make transitions feel fluid and professional.
- Natural Language Parsing over WhatsApp: Parsing user messages accurately was a challenge. We built custom string-matching fallbacks so that if a user writes a typo in a category name (e.g., "groceris" instead of "groceries"), the system automatically maps it to the closest valid transaction category.
📈 What We Learned
- AI Agent Orchestration: We learned how to write strict JSON schemas for LLMs to generate highly predictable data inputs for frontend components.
- Webhooks & Third-party Integrations: Gained deep experience in Twilio webhook security, signature validation, and payload formatting.
- Programmatic Media: Remotion opened our eyes to how React state can render MP4 files, paving the way for automated content generation.
- Financial Modeling: Designing the math behind 10-year compound interest calculations and savings rates:
$$ \text{Savings Rate} = \left( \frac{\text{Monthly Income} - \text{Total Expenses}}{\text{Monthly Income}} \right) \times 100 $$
$$ W_{\text{gap}} = P_{\text{optimized}}(t) - P_{\text{current}}(t) $$
Built With
- ai-powered-multi-agent-financial-planning-system
- express.js
- firebase-authentication
- groq
- javascript-(es6+)
- mongodb-atlas
- mongoose
- node.js
- react.js
- rest-apis
- tailwind-css
- twilio
- vercel
- vite
Log in or sign up for Devpost to join the conversation.