Empowering Public Data Analysis with AI & Multi-Language Support
A modern, open-source AI-powered analytics platform designed for exploring public datasets with advanced visualization, multi-language insights, and actionable recommendations. Built on top of Google Gemini AI, it combines powerful analytics with accessibility.
- Google Gemini Integration - Advanced AI models (3.5 Flash & 3.1 Pro)
- Smart Analysis - Automatic insights, trends, anomalies, and risk assessment
- Customizable Prompts - Pre-built templates or create your own
- Confidence Scoring - Track AI confidence on each analysis
Insights available in 12+ Indian languages:
- English, Hindi (हिन्दी), Bengali (বাংলা)
- Tamil (தமிழ்), Telugu (తెలుగు), Kannada (ಕನ್ನಡ)
- Marathi (मराठी), Gujarati (ગુજરાતી), Malayalam (മലയാളം)
- Punjabi (ਪੰਜਾਬਿ), Odia (ଓଡ଼ିଆ), Urdu (اردو)
- Multi-Format Support - CSV, JSON, Excel (XLSX)
- Automatic Parsing - Smart type detection and data cleaning
- Statistics Generation - Headers, duplicates, missing values, distributions
- Persistent Storage - Local JSON database
- Interactive Charts - Recharts-powered visualizations
- Report Generation - Download as Markdown files
- Data Exploration - Trends, patterns, comparisons
- Export Options - Multiple format support
- Dark Theme - Eye-friendly glass-morphism design
- Responsive Layout - Optimized for desktop and tablet
- Intuitive Navigation - Sidebar-based tab system
- Real-time Updates - Hot module reloading
| Requirement | Version | Link |
|---|---|---|
| Node.js | v18+ | Download |
| npm | v9+ | Included with Node.js |
| Gemini API Key | - | Get API Key |
cd KrishiSathi_AInpm installCreate .env.local file in the project root:
GEMINI_API_KEY=your_gemini_api_key_herenpm run devhttp://localhost:3000
Note: If port 3000 is busy, the server automatically uses the next available port (3001, 3002, etc.)
| Command | Description | Output |
|---|---|---|
npm run dev |
Development server with hot reload | Localhost dev mode |
npm run build |
Production build (Vite + esbuild) | dist/ folder |
npm start |
Run production build | Compiled app |
npm run clean |
Remove build artifacts | Clean slate |
npm run lint |
TypeScript type checking | Type errors only |
KrishiSathi_AI/
│
├── src/
│ ├── components/
│ │ ├── AIStudio.tsx # Main AI analysis interface
│ │ ├── DashboardHome.tsx # Home dashboard
│ │ ├── UploadPage.tsx # File upload portal
│ │ ├── DatasetLibrary.tsx # Dataset browser
│ │ ├── VisualizationStudio.tsx # Chart visualization
│ │ ├── ReportGenerator.tsx # Report builder
│ │ ├── HistoryTab.tsx # ⏱Analysis history
│ │ ├── SettingsTab.tsx # User settings
│ │ ├── ProfileTab.tsx # User profile
│ │ ├── Navbar.tsx # Top navigation
│ │ ├── Sidebar.tsx # Main sidebar
│ │ ├── AILoading.tsx # Loading state
│ │ ├── EmptyState.tsx # Empty placeholders
│ │ └── PromptBuilder.tsx # Custom prompt editor
│ ├── App.tsx # Main app component
│ ├── main.tsx # React entry point
│ ├── index.css # Global styles & theme
│ ├── types.ts # TypeScript interfaces
│ └── assets/
│ └── images/
│
├── data/
│ ├── db.json # Local data store
│ └── Daily Retail Price of Potato.csv
│
├── server.ts # Express backend
├── vite.config.ts # Vite configuration
├── tsconfig.json # TypeScript config
├── package.json # Dependencies
└── README.md # This file
http://localhost:3000/api
GET /api/datasetsResponse:
[
{
"id": "dataset_123",
"name": "Potato Prices",
"rowCount": 1000,
"headers": ["Date", "Price", "Region"],
"data": [...]
}
]POST /api/datasets
Content-Type: multipart/form-dataParameters:
file(required) - CSV, JSON, or XLSX filename(optional) - Custom dataset name
DELETE /api/datasets/:idPOST /api/ai/analyze
Content-Type: application/jsonRequest Body:
{
"datasetId": "dataset_123",
"promptText": "Find trends in this data",
"promptName": "Find Trends",
"language": "English",
"temperature": 0.4,
"model": "gemini-3.5-flash"
}Response:
{
"id": "analysis_456",
"timestamp": "2024-01-15T10:30:00Z",
"response": {
"summary": "Executive summary...",
"insights": ["Insight 1", "Insight 2"],
"reasoning": "Analysis reasoning...",
"evidence": "Supporting data...",
"confidenceScore": 85,
"limitations": "Data limitations...",
"recommendedActions": ["Action 1", "Action 2"],
"exploreQuestions": ["Question 1"]
}
}GET /api/historyDELETE /api/history/:idGET /api/reportsPOST /api/reportsDELETE /api/reports/:idGET /api/settingsPUT /api/settingsGET /api/profilePUT /api/profile- Click "Upload" in the sidebar
- Select CSV, JSON, or Excel file
- System auto-parses and validates data
- Dataset appears in library
- Go to "Gemma" (AI Studio)
- Select dataset from dropdown
- Choose prompt template or write custom
- Adjust temperature (0.1 = factual, 1.0 = creative)
- Select output language
- Click "Initiate Audit Analysis"
- Executive summary
- Key factual insights
- Analytical reasoning
- Evidence utilization
- Risk warnings & gaps
- Recommended actions
- Copy - Copy full text to clipboard
- Download - Get Markdown report
- View all past analyses
- Timestamps & models used
- Re-run previous prompts
Date,Price,Region
2024-01-01,150,North
2024-01-02,152,South- ✅ Automatic header detection
- ✅ Quote & escape handling
- ✅ Type inference (numeric, categorical, text)
- ✅ Null value detection
[
{"Date": "2024-01-01", "Price": 150, "Region": "North"},
{"Date": "2024-01-02", "Price": 152, "Region": "South"}
]- ✅ Array of objects
- ✅ Nested structures
- ✅ Mixed types
Workbook → Sheet → Table
- ✅ Multiple sheets
- ✅ Formula values
- ✅ Cell formatting
| # | Template | Purpose | Creativity |
|---|---|---|---|
| 1️⃣ | Generate Summary | Dataset overview | 0.3 |
| 2️⃣ | Find Trends | Correlations & patterns | 0.4 |
| 3️⃣ | Find Anomalies | Outliers & spikes | 0.3 |
| 4️⃣ | Compare Categories | Class distributions | 0.4 |
| 5️⃣ | Risk Analysis | Policy risks & gaps | 0.3 |
| 6️⃣ | Recommendations | Strategic advice | 0.5 |
| 7️⃣ | Question Answering | Specific queries | 0.4 |
| 8️⃣ | Explain Dataset | Layman terms | 0.4 |
| 9️⃣ | Translate Results | Localized insights | 0.2 |
| 🔟 | Executive Report | Comprehensive paper | 0.4 |
- Settings → Custom Prompts
- Name your template
- Write system & user prompts
- Set creativity level
- Save for future use
- React 19 - UI framework
- TypeScript 5.8 - Type safety
- Vite 6 - Lightning-fast build tool
- Tailwind CSS 4 - Utility-first styling
- Express.js - Server framework
- Node.js - Runtime
- Google Gemini API - AI models
- XLSX - Excel parsing
- Recharts - Data visualization
- Lucide React - Icon library
- Motion - Animations
- tsx - TypeScript executor
- esbuild - Bundler
- ESLint - Linting
data/db.json
├── datasets[] # Uploaded datasets
├── history[] # Analysis history
├── reports[] # Generated reports
├── customPrompts[] # User templates
├── settings{} # App configuration
└── profile{} # User profile
{
"datasets": [
{
"id": "dataset_abc123",
"name": "Potato Prices 2024",
"rowCount": 365,
"uploadedAt": "2024-01-15T10:30:00Z",
"headers": ["Date", "Price", "Region"],
"statistics": {
"columns": [...],
"duplicateCount": 0,
"totalMissing": 5
},
"data": [...]
}
]
}Error: listen EADDRINUSE: address already in use
Solution: Server auto-selects next port. Check console for actual URL.
Error: GEMINI_API_KEY is not defined
Solution:
- Create
.env.localfile - Add:
GEMINI_API_KEY=your_key_here - Restart server
@import must precede all other statements
Solution: Ensure @import statements are at top of src/index.css
# Clear and reinstall
npm run clean
npm install
npm run build# Disable HMR temporarily
DISABLE_HMR=true npm run dev- ✅ Local data storage (no cloud sync)
- ✅ No personal data collection
- ✅ API key stored locally only
- ✅ Datasets never shared
- ✅ Privacy mode available in settings
We welcome contributions! Please:
- Fork the repository
- Create feature branch:
git checkout -b feature/amazing-feature - Commit changes:
git commit -m 'Add amazing feature' - Push branch:
git push origin feature/amazing-feature - Open Pull Request
This project is open-source and available under the MIT License. See LICENSE for details.
- Google Gemini AI - Powering intelligent analysis
- React & Vite - Modern frontend development
- Tailwind CSS - Beautiful UI styling
- Open Data Community - Supporting public data initiatives
- Email: support@krishisathi.com
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Documentation: Full docs available in
/docs
- Multi-user support with authentication
- Cloud data sync
- Real-time collaboration
- Advanced filtering & search
- Custom visualization builder
- API rate limiting & quotas
- Mobile app (React Native)
- More language support
Built with ❤️ for public data analysis