Skip to content

VARA4u-tech/MAIL-MIND-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

147 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

MailMind AI Logo

MAILMIND AI

Next-Generation Intelligent Email & Calendar Orchestration Engine

Status Architecture AI Engine

Overview β€’ Architecture β€’ Features β€’ Tech Stack β€’ Engineering β€’ Roadmap


πŸ“Œ Project Overview

MailMind AI was engineered to solve the chronic problem of "Cognitive Load in Communication." Modern professionals spend over 28% of their workday managing emails. MailMind AI transforms the inbox from a passive data silo into an active, AI-orchestrated command center.

  • Problem Statement: Inbox overload leads to missed opportunities, delayed responses, and decision fatigue.
  • The Mission: To build a low-latency, privacy-first AI layer that sits atop Gmail, distilling complex threads into actionable intelligence and synchronizing communication with scheduling.
  • Business Value: Increases executive productivity by automating 60% of routine email triage and scheduling tasks.

πŸ— System Architecture

The application follows a Decoupled Client-Server Architecture optimized for high-throughput AI operations and real-time synchronization.

graph TD
    User((User)) -->|React + Framer Motion| Frontend[Frontend SPA - Vite]
    Frontend -->|JWT Auth| Gateway[Express API Gateway]
    Gateway -->|OAuth 2.0| GmailAPI[Google Gmail API]
    Gateway -->|Calendar Scopes| CalAPI[Google Calendar API]
    Gateway -->|Inference| AI[AI Engine - Gemma 2 via OpenAIs]
    Gateway -->|Persistence| DB[(MongoDB Atlas)]

    subgraph "Intelligent Processing"
    AI -->|Summarization| Gateway
    AI -->|Intent Extraction| Gateway
    AI -->|Meeting Detection| Gateway
    end
Loading

βš™οΈ Development Methodology: Agile (Scrum)

This project was developed using a rigorous Agile Methodology, divided into three distinct 2-week sprints.

  1. Sprint 1 (Infrastructure & Security): Focused on the OAuth 2.0 handshake, secure token storage, and the "Premium Brutalist" design system.
  2. Sprint 2 (AI Orchestration): Integration of the LLM layer, context-window management, and the proprietary "Schedule Recognition" engine.
  3. Sprint 3 (Performance & Polish): Solving the "Rendering Paradox" on mobile, implementing backdrop-blur optimizations, and stabilizing background polling.
  • Iteration Strategy: Used daily "Virtual Standups" (self-led) and weekly retrospective analysis to pivot UI/UX decisions based on performance benchmarks on low-end devices.

✨ Features Breakdown

1. 🧠 AI Smart Context Hub

  • Summarization: Uses chain-of-thought prompting to condense long threads into 3 critical bullet points.
  • Intent Recognition: Detects if an email requires a meeting, a professional reply, or just an acknowledgment.

2. πŸ“… One-Click Calendar Orchestration

  • Automatically parses physical addresses, Zoom links, and time slots from unstructured email bodies.
  • Generates Google Calendar event payloads with 100% ISO-8601 date accuracy.

3. πŸ“± High-Performance Responsive Dashboard

  • Mobile: Dedicated tab-based navigation with background polling protection (prevents DOM crashes during refreshes).
  • Tablet: Side-by-side folder switching and AI assistant drawer.
  • Desktop: Full-width brutalist workspace with magnetic interactions.

4. πŸ“‚ Folder Management

  • Complete Gmail folder support: Inbox, Starred, Sent, and Trash with real-time status syncing.

πŸ›  Tech Stack

Layer Technology
Frontend React 18, Vite, TypeScript, Framer Motion, Tailwind CSS, Lucide React
Backend Node.js, Express, OpenAis (Gemma 2 27B), JWT
Database MongoDB Atlas (NoSQL for flexible AI log storage)
APIs Google OAuth2, Gmail API v1, Google Calendar API v3
Performance TanStack Query (Caching), Custom Background Polling Engine
Tools VS Code, Vercel,Render, Git, MongoDB Compass, Google Cloud Console

πŸ“‚ Folder Structure

mail-mind-ai/
β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ config/         # Google OAuth & Database initializers
β”‚   β”œβ”€β”€ controllers/    # Core logic: AI extraction, Gmail proxying, Calendar logic
β”‚   β”œβ”€β”€ middleware/     # Auth guards, Rate limiters, Error handlers
β”‚   β”œβ”€β”€ models/         # MongoDB schemas for User profiles & AI history
β”‚   └── utils/          # HTML stripping, Date parsing, Token refreshers
└── frontend/
    β”œβ”€β”€ src/
    β”‚   β”œβ”€β”€ components/ # Atomic UI components (Navbar, Hero, Modals)
    β”‚   β”œβ”€β”€ hooks/      # Custom React hooks for device detection & sounds
    β”‚   β”œβ”€β”€ pages/      # Dashboard (Main logic hub) & Landing Page
    β”‚   └── store/      # State management (Context API / Local)

πŸ“Š Engineering Decisions

  • Why Vite instead of CRA?: Reduced cold-start time from 15s to <500ms and significantly faster HMR for rapid UI iteration.
  • LLM Choice (Gemma 2 27B): Chosen for its superior reasoning-to-latency ratio, ensuring that email summaries are generated in under 2 seconds.
  • Security Posture: Implemented Helmet.js for secure headers, CORS white-listing, and a rate-limiting firewall to prevent API abuse.
  • Mobile Stability: Solved the removeChild DOM crash by gating state updates during Framer Motion animationsβ€”a common pitfall in complex React apps.

πŸ§ͺ Testing & Validation

  • Responsive Integrity: Verified across 300px (Mobile S) to 2560px (Ultra-Wide).
  • Performance: Optimized for the Samsung M11 (entry-level device) by disabling heavy filters and animations on low-performance hardware.
  • Date Robustness: 100+ edge cases tested for AI date parsing (e.g., "Next Tuesday at 4", "10/05/2026").

πŸ† Achievements

  • Successfully integrated a production-grade Google OAuth flow with sensitive scopes.
  • Engineered a custom "Premium Brutalist" CSS system using Tailwind variables.
  • Implemented a seamless AI history logging system that tracks 100+ daily summaries.

πŸš€ Future Enhancements

  1. Multi-Agent Support: Assign different AI personalities for different email folders.
  2. Offline Cache: Use Service Workers to allow reading cached summaries without internet.
  3. Vector Search: Integrate Pinecone/RAG to search across all emails using natural language.

Developed with Precision by VARA
"Transforming Information Overload into Actionable Clarity."

About

"πŸ’ŒMailMind AI is a professional-grade, AI-powered email assistant designed to streamline your communication workflow. By leveraging advanced Large Language Models (Gemma 2 27B), it transforms your inbox from a static list of messages into a dynamic command center."

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors