Application Workflow

Understanding how DataXpert processes data and user interactions

System Workflow Overview

DataXpert follows a multi-layered architecture that processes user requests through several stages:

1

User Authentication

User logs in via email/password or Google OAuth

  • JWT token generation
  • Session management
  • Google OAuth flow
2

Dashboard Access

User accesses dashboard with business data

  • Load business statistics
  • Render charts and visualizations
  • Display recent activity
3

Data Input

User enters business data or uploads CSV

  • Sales data entry
  • Expense tracking
  • Profit calculation
4

AI Analysis

User queries AI for insights

  • NLP processing
  • Intent extraction
  • Entity recognition
5

Data Analysis

AI engine analyzes business data

  • Statistical analysis
  • Trend detection
  • Anomaly detection
6

Results & Insights

AI generates insights and recommendations

  • Natural language response
  • Visualizations
  • Actionable recommendations
7

Activity History

View and manage all data activities

  • Track data uploads
  • View analysis history
  • Backup and restore data

AI Analysis Workflow

Detailed flow of how AI processes user queries:

Analysis Pipeline

User Query
    ↓
[NLP Processor]
    • Tokenization
    • Intent Extraction
    • Entity Recognition
    ↓
[Analysis Engine]
    • Determine Analysis Type
    • Fetch Relevant Data
    • Perform Calculations
    ↓
[Anomaly Detector]
    • Z-Score Analysis
    • IQR Method
    • Trend Changes
    ↓
[Response Generator]
    • Format Insights
    • Generate Recommendations
    • Create Visualizations
    ↓
User Response

Data Flow Diagram

Data Flow Architecture

The complete data flow in DataXpert follows this sequence:

  1. User Input: Login/Signup → Authentication → JWT Token
  2. Dashboard: Fetch Business Data → Process Statistics → Render Charts
  3. Data Entry: CSV Upload / Manual Entry → Validation → Database Storage
  4. AI Query: User Question → NLP Processing → Intent Recognition
  5. Analysis: Data Retrieval → Statistical Analysis → Anomaly Detection
  6. Results: Generate Insights → Format Response → Display to User
  7. History: Log Activity → Store Analysis → Enable Backup/Restore

User Journey

1. First Time User

  1. Visit homepage
  2. Click "Sign Up"
  3. Choose email signup or Google OAuth
  4. Complete registration
  5. Redirected to dashboard
  6. View empty state with "Add Data" prompt

2. Adding Business Data

  1. Click "Add Data" button
  2. Fill in the form (date, category, sales, expenses)
  3. Profit auto-calculated
  4. Submit data
  5. Dashboard updates with new charts

3. AI Analysis

  1. Navigate to "AI Analysis" page
  2. Type question or click suggestion chip
  3. AI processes query
  4. Receive insights with charts
  5. Ask follow-up questions

4. Data Import/Export

  1. Navigate to "Dashboard" page
  2. Click "Upload Data" button
  3. Select CSV file with business data
  4. System validates and imports data
  5. View imported data in dashboard charts
  6. Export data anytime for backup