Skip to content

leooladimu/finCoach

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

41 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

FinCoach πŸ’°

AI-Powered Financial Coaching That Adapts to Your Personality

A modern, serverless financial coaching platform that provides personalized guidance based on your unique "Money Style" β€” an MBTI-informed approach to understanding your financial decision-making patterns.

Live Demo TypeScript Next.js License


✨ Features

🎯 Personalized Money Style Assessment

  • 20-question MBTI-based assessment (~3 minutes)
  • 16 unique Money Style profiles with detailed descriptions
  • Tailored coaching approaches for each personality type
  • Full accessibility support (WCAG 2.1 AA compliant)
  • Keyboard navigation with arrow keys, number shortcuts, and screen reader support
  • Mobile-optimized with touch interactions and responsive design

πŸ“Š Comprehensive Financial Dashboard

  • Goals Tab: Track financial goals with visual progress indicators
  • Behavior Tab: Analyze spending patterns and identify behavioral insights
  • Plan Tab: Actionable task management with priority levels
  • Contradiction Detection: AI-powered analysis identifies misalignments between stated goals and actual behavior

πŸ” Secure & Private

  • Clerk authentication with session management
  • Plaid integration for secure bank connections (sandbox mode)
  • All data stored in Vercel KV (serverless Redis)
  • No traditional database β€” fully edge-optimized

πŸš€ Performance & UX

  • Server-side rendering with Next.js App Router
  • Glassmorphism UI with modern dark theme
  • Smooth animations powered by Framer Motion
  • Real-time data visualization with Recharts
  • Progressive Web App (PWA) ready
  • Auto-save progress β€” never lose assessment data on refresh
  • Rate limiting to prevent spam and abuse
  • Comprehensive error handling with user-friendly toast notifications

πŸ—οΈ Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                     User Interface                       β”‚
β”‚  Next.js 16 + React + TypeScript + Tailwind CSS v4     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                           β”‚
                           ↓
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                  Serverless Backend                      β”‚
β”‚  Vercel Edge Functions + API Routes                     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                           β”‚
        β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
        ↓                  ↓                  ↓
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Vercel KV   β”‚  β”‚   Plaid API  β”‚  β”‚ AWS Lambda   β”‚
β”‚  (Redis)     β”‚  β”‚  (Banking)   β”‚  β”‚ (Optional)   β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Tech Stack

Frontend:

Backend:

External Services:

  • Plaid - Bank account integration
  • AWS Lambda - ML-powered contradiction detection (optional)

πŸš€ Getting Started

Prerequisites

  • Node.js 18+ and npm/yarn/pnpm
  • Vercel account (for deployment)
  • Clerk account (for authentication)
  • Plaid account (for banking integration - sandbox mode works)

Installation

  1. Clone the repository

    git clone https://github.com/leooladimu/fincoach.git
    cd fincoach
  2. Install dependencies

    npm install
    # or
    yarn install
    # or
    pnpm install
  3. Set up environment variables

    Create a .env.local file in the root directory:

    # Clerk Authentication
    NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=your_clerk_publishable_key
    CLERK_SECRET_KEY=your_clerk_secret_key
    
    # Vercel KV (Redis)
    KV_REST_API_URL=your_kv_url
    KV_REST_API_TOKEN=your_kv_token
    
    # Plaid (Banking)
    PLAID_CLIENT_ID=your_plaid_client_id
    PLAID_SECRET=your_plaid_secret
    PLAID_ENV=sandbox
    
    # AWS (Optional - for ML features)
    AWS_ACCESS_KEY_ID=your_aws_key
    AWS_SECRET_ACCESS_KEY=your_aws_secret
    AWS_REGION=us-east-1
  4. Run the development server

    npm run dev
  5. Open your browser

    Navigate to http://localhost:3000


πŸ“ Project Structure

fincoach/
β”œβ”€β”€ app/
β”‚   β”œβ”€β”€ (auth)/
β”‚   β”‚   β”œβ”€β”€ onboarding/           # Onboarding flow
β”‚   β”‚   β”‚   β”œβ”€β”€ page.tsx           # User info collection
β”‚   β”‚   β”‚   └── assessment/        # Money Style assessment
β”‚   β”‚   └── layout.tsx
β”‚   β”œβ”€β”€ (dashboard)/
β”‚   β”‚   β”œβ”€β”€ goals/                 # Goals dashboard
β”‚   β”‚   β”œβ”€β”€ behavior/              # Behavior analysis
β”‚   β”‚   β”œβ”€β”€ plan/                  # Action plan & tasks
β”‚   β”‚   β”œβ”€β”€ profile/               # User profile
β”‚   β”‚   └── layout.tsx
β”‚   β”œβ”€β”€ api/
β”‚   β”‚   β”œβ”€β”€ assessment/            # Assessment scoring
β”‚   β”‚   β”œβ”€β”€ plaid/                 # Plaid integration
β”‚   β”‚   └── analyze/               # Contradiction detection
β”‚   β”œβ”€β”€ globals.css                # Global styles + theme
β”‚   β”œβ”€β”€ layout.tsx                 # Root layout
β”‚   └── page.tsx                   # Landing page
β”œβ”€β”€ lib/
β”‚   β”œβ”€β”€ assessment.ts              # Assessment questions & scoring
β”‚   β”œβ”€β”€ contradictions.ts          # Contradiction detection logic
β”‚   β”œβ”€β”€ kv.ts                      # Vercel KV utilities
β”‚   β”œβ”€β”€ plaid.ts                   # Plaid client setup
β”‚   └── hooks/                     # React hooks
β”œβ”€β”€ types/
β”‚   └── index.ts                   # TypeScript type definitions
β”œβ”€β”€ aws/
β”‚   └── lambda/                    # AWS Lambda functions
└── public/                        # Static assets

🎨 Design System

Color Palette

  • Background: #000000 (Pure black)
  • Primary Accent: #10b981 (Emerald-500 - growth/success)
  • Secondary Accent: #3b82f6 (Blue-500 - actions)
  • Tertiary Accent: #8b5cf6 (Violet-500 - highlights)
  • Danger: #ef4444 (Red-500 - warnings)

Typography

  • Font: Geist Sans & Geist Mono (Vercel's font family)
  • Scales: Responsive text sizing (mobile-first)

Components

  • Glassmorphism effects (backdrop-blur-xl + rgba(20,20,20,0.7))
  • Gradient text for emphasis
  • Custom scrollbars
  • Smooth transitions with cubic-bezier easing

πŸ§ͺ Features in Detail

Money Style Assessment

  • Validation: Frontend + backend validation of all answers
  • Rate Limiting: 5 submissions per hour per user+IP
  • Progress Saving: Auto-saves to localStorage
  • Accessibility:
    • Full keyboard navigation (arrow keys, Enter, Space, Backspace, 1-4)
    • ARIA labels and roles
    • Screen reader support
    • Focus management
  • Mobile: Touch-optimized with active states and responsive layouts

Contradiction Detection

  • Compares stated goals vs. actual spending patterns
  • Identifies behavioral misalignments
  • Provides actionable insights
  • Optional AWS Lambda integration for ML-powered analysis

Dashboard

  • Real-time data from Plaid (sandbox)
  • Visual progress tracking with charts
  • Priority-based task management
  • Personalized insights based on Money Style

πŸ”’ Security & Privacy

  • Authentication: Secure session management with Clerk
  • Data Storage: Encrypted at rest in Vercel KV
  • API Security: Rate limiting on all endpoints
  • Input Validation: Comprehensive frontend + backend validation
  • No PII Leakage: Minimal personal data collection
  • HTTPS Only: All connections encrypted

🚒 Deployment

Vercel (Recommended)

  1. Push to GitHub

    git push origin main
  2. Import to Vercel

    • Go to vercel.com/new
    • Import your GitHub repository
    • Add environment variables
    • Deploy!
  3. Configure KV Storage

    • Create a Vercel KV database in your project
    • Copy the connection strings to your environment variables

Environment Variables

Make sure to add all .env.local variables to your Vercel project settings.


πŸ“Š Data Models

User Profile

{
  userId: string;
  email: string;
  name: string;
  createdAt: string;
  moneyStyle?: {
    type: MBTIType; // e.g., "ENFP"
    scores: MBTIScores;
    assessmentDate: string;
  };
  lifeContext?: {
    age?: number;
    employmentStatus?: string;
  };
  statedPreferences?: {
    priorityGoals: string[];
  };
}

Financial Goal

{
  id: string;
  userId: string;
  title: string;
  targetAmount: number;
  currentAmount: number;
  targetDate: string;
  category: string;
  createdAt: string;
}

Contradiction

{
  id: string;
  userId: string;
  type: string;
  severity: 'low' | 'medium' | 'high';
  description: string;
  detectedAt: string;
  resolved: boolean;
}

🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

πŸ“ License

This project is licensed under the MIT License - see the LICENSE file for details.


πŸ™ Acknowledgments

  • MBTI Framework - For personality type methodology
  • Plaid - For secure banking integration
  • Vercel - For hosting and serverless infrastructure
  • Clerk - For authentication
  • Next.js Team - For the amazing framework

πŸ“§ Contact

Leo Oladimu - @leooladimu

Live Demo: https://fincoach.oleo.dev


πŸ—ΊοΈ Roadmap

  • Real Plaid integration (production)
  • Additional Money Style profiles
  • Advanced ML contradiction detection
  • Bill tracking & reminders
  • Investment portfolio analysis
  • Multi-currency support
  • Mobile app (React Native)
  • Social features (community goals)

Built with ❀️ using Next.js, TypeScript, and modern web technologies

About

personalized financial adviser

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •