Skip to main content
A CLI agent that analyzes personal spending data and provides AI-powered financial coaching. Built with LangGraph for multi-step workflows.

What it does

This agent acts as a personal financial coach through a command-line interface. Users can:
  • Ask questions about their spending in natural language
  • Get breakdowns by category, merchant, or time period
  • Receive personalized recommendations and savings opportunities
  • Have multi-turn conversations with conversation memory
Example interaction:

Architecture

The agent uses a 4-node LangGraph workflow:
  1. Enrich query - Adds context about time period, categories, and merchants
  2. Query Snow Leopard - Converts natural language to SQL and retrieves data
  3. Analyze and coach - Generates insights, recommendations, and follow-up questions
  4. Format response - Creates formatted CLI output with Rich

Key components

  • LangGraph orchestrates the multi-step workflow
  • Snow Leopard handles natural language to SQL conversion
  • Coaching analyzer generates personalized financial insights
  • Memory manager maintains conversation context across turns
  • Rich CLI provides formatted terminal output

Run the example

Prerequisites

The example includes a script to generate sample financial data, or you can use your own SQLite database with transaction data.

Setup

Clone the repository:
Install dependencies:
Generate sample data (optional):
Create a .env file:
Run the agent:

Example queries

  • “Show me my spending by category”
  • “Which merchants did I spend the most at?”
  • “Compare this month vs last month”
  • “How much did I spend on groceries?”

Next steps