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:
- User Input: Login/Signup → Authentication → JWT Token
- Dashboard: Fetch Business Data → Process Statistics → Render Charts
- Data Entry: CSV Upload / Manual Entry → Validation → Database Storage
- AI Query: User Question → NLP Processing → Intent Recognition
- Analysis: Data Retrieval → Statistical Analysis → Anomaly Detection
- Results: Generate Insights → Format Response → Display to User
- History: Log Activity → Store Analysis → Enable Backup/Restore
User Journey
1. First Time User
- Visit homepage
- Click "Sign Up"
- Choose email signup or Google OAuth
- Complete registration
- Redirected to dashboard
- View empty state with "Add Data" prompt
2. Adding Business Data
- Click "Add Data" button
- Fill in the form (date, category, sales, expenses)
- Profit auto-calculated
- Submit data
- Dashboard updates with new charts
3. AI Analysis
- Navigate to "AI Analysis" page
- Type question or click suggestion chip
- AI processes query
- Receive insights with charts
- Ask follow-up questions
4. Data Import/Export
- Navigate to "Dashboard" page
- Click "Upload Data" button
- Select CSV file with business data
- System validates and imports data
- View imported data in dashboard charts
- Export data anytime for backup