Skip to content

Latest commit

ย 

History

21 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Bantuaku SaaS

AI-Chat-First Forecasting Assistant untuk UMKM Indonesia

Bantuaku Go React PostgreSQL Kolosal.ai CodeRabbit Reviews

๐ŸŽฏ Overview

Bantuaku adalah platform SaaS yang membantu UMKM Indonesia membuat keputusan bisnis berbasis data melalui AI chat sebagai interface utama. Platform ini mengumpulkan informasi bisnis secara conversational dan menghasilkan insights praktis.

๐Ÿ–ผ๏ธ Visual Showcase

โœจ Modern "Neon Finance" UI Design โœจ

Dashboard
Dashboard

Comprehensive business overview with KPIs, charts, and quick actions

Login Page
Login Page

Beautiful split-screen design with tech animations

Mobile Chat Experience
Mobile Chat

Floating chat widget with seamless mobile navigation

โœจ Fitur Utama

๐Ÿค– AI Assistant Chat

  • Conversational Interface - Chat dengan AI untuk mengumpulkan data bisnis (powered by Kolosal.ai)
  • Floating Chat Widget - Akses cepat AI Assistant dari halaman manapun
  • File Upload Support - Upload CSV, XLSX, atau PDF untuk ekstraksi data otomatis (OCR powered by Kolosal.ai)
  • Conversation History - Riwayat percakapan tersimpan dan dapat diakses kapan saja

๐Ÿ“Š Forecast

  • Sales Projections - Proyeksi penjualan 30/60/90 hari ke depan berdasarkan data penjualan yang diinput user
  • Interactive Charts - Visualisasi trend historis vs prediksi AI dengan AreaChart
  • Confidence Metrics - Tingkat akurasi prediksi ditampilkan dengan jelas
  • AI Insights Panel - Rekomendasi strategis berdasarkan analisis forecast

๐ŸŒ Market Prediction

  • Local & Global Trends - Prediksi tren pasar lokal (Indonesia) dan global untuk produk Anda
  • Trending Products - Daftar produk yang sedang naik daun dengan growth metrics
  • Market Intelligence - Analisis kompetisi dan peluang pasar
  • Interactive Tabs - Switch antara analisis lokal dan global dengan mudah

๐Ÿ“ข Marketing Recommendation

  • Personalized Strategies - Rekomendasi kampanye marketing yang dipersonalisasi
  • Multi-Channel Approach - Strategi untuk Social Media, Email, dan Paid Ads
  • Campaign Performance - Estimasi dampak dan ROI untuk setiap rekomendasi
  • Content Generation - Generate konten iklan dengan AI

โš–๏ธ Government Regulation

  • Compliance Dashboard - Monitor status kepatuhan bisnis terhadap regulasi terbaru
  • Regulation Alerts - Notifikasi untuk peraturan urgent yang perlu perhatian
  • Compliance Score - Skor kepatuhan bisnis dengan breakdown detail
  • Action Items - Daftar peraturan yang perlu ditindaklanjuti

๐Ÿ”” Smart Notifications

  • Real-time Updates - Notifikasi untuk forecast selesai, update regulasi, dan tren pasar baru
  • Priority Indicators - Badge untuk notifikasi urgent dan penting
  • Dark Glass UI - Desain modern dengan dark glass mode untuk readability optimal

๐Ÿš€ Quick Start

Prerequisites

  • Docker & Docker Compose
  • Node.js 20+ (untuk development)
  • Go 1.25+ (untuk development)

Running with Docker

# Clone repository
git clone https://github.com/your-org/bantuaku.git
cd bantuaku

# Start all services
make dev

# Or manually:
docker-compose up --build

Aplikasi akan berjalan di:

Demo Account

Email: demo@bantuaku.id
Password: demo123

๐Ÿ“ Project Structure

bantuaku/
โ”œโ”€โ”€ backend/                    # Go backend API
โ”‚   โ”œโ”€โ”€ config/                 # Configuration
โ”‚   โ”œโ”€โ”€ handlers/               # HTTP handlers
โ”‚   โ”‚   โ”œโ”€โ”€ chat.go            # Chat & conversation handlers
โ”‚   โ”‚   โ”œโ”€โ”€ files.go           # File upload handlers
โ”‚   โ”‚   โ”œโ”€โ”€ insights.go        # Insights generation handlers
โ”‚   โ”‚   โ”œโ”€โ”€ dashboard.go       # Dashboard summary handler
โ”‚   โ”‚   โ””โ”€โ”€ companies.go       # Company profile handlers
โ”‚   โ”œโ”€โ”€ middleware/             # Auth, CORS, logging
โ”‚   โ”œโ”€โ”€ models/                 # Data models
โ”‚   โ”‚   โ”œโ”€โ”€ company.go         # Company & CompanyProfile
โ”‚   โ”‚   โ”œโ”€โ”€ conversation.go    # Conversation & Message
โ”‚   โ”‚   โ”œโ”€โ”€ file_upload.go     # FileUpload & ExtractedData
โ”‚   โ”‚   โ”œโ”€โ”€ data_source.go     # DataSource
โ”‚   โ”‚   โ””โ”€โ”€ insight.go         # Insight & result types
โ”‚   โ”œโ”€โ”€ services/               # Business logic
โ”‚   โ”‚   โ”œโ”€โ”€ kolosal/           # Kolosal.ai client (Chat & OCR)
โ”‚   โ”‚   โ”œโ”€โ”€ storage/            # Database & Redis
โ”‚   โ”‚   โ”œโ”€โ”€ chat/               # Chat service (TODO)
โ”‚   โ”‚   โ”œโ”€โ”€ ingestion/         # File processing service (TODO)
โ”‚   โ”‚   โ”œโ”€โ”€ forecasting/       # Forecast service (TODO)
โ”‚   โ”‚   โ”œโ”€โ”€ connectors/        # External data connectors (TODO)
โ”‚   โ”‚   โ””โ”€โ”€ insights/          # Insights generation (TODO)
โ”‚   โ””โ”€โ”€ main.go
โ”œโ”€โ”€ frontend/                   # React frontend
โ”‚   โ”œโ”€โ”€ src/
โ”‚   โ”‚   โ”œโ”€โ”€ components/        # UI components
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ layout/       # Layout components (Sidebar, Header)
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ chat/         # Chat components (ChatInterface, ChatWidget)
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ ui/           # shadcn/ui components
โ”‚   โ”‚   โ”œโ”€โ”€ pages/             # Page components
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ AIChatPage.tsx        # AI Chat interface
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ DashboardPage.tsx     # Dashboard overview
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ ForecastPage.tsx      # Forecast insights
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ MarketPredictionPage.tsx  # Market predictions
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ MarketingPage.tsx     # Marketing recommendations
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ RegulationPage.tsx    # Government regulations
โ”‚   โ”‚   โ”œโ”€โ”€ state/             # State management (Zustand)
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ auth.ts       # Authentication state
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ chat.ts       # Chat state (messages, loading)
โ”‚   โ”‚   โ””โ”€โ”€ lib/               # Utilities & API clients
โ”‚   โ””โ”€โ”€ package.json
โ”œโ”€โ”€ database/
โ”‚   โ””โ”€โ”€ migrations/            # SQL migrations
โ”‚       โ””โ”€โ”€ 003_add_chat_tables.sql  # Chat, ingestion, insights tables
โ”œโ”€โ”€ gh-assets/                 # GitHub assets (screenshots)
โ”‚   โ”œโ”€โ”€ dashboard.png
โ”‚   โ”œโ”€โ”€ login-page.png
โ”‚   โ””โ”€โ”€ mobile-chat.png
โ”œโ”€โ”€ .docs-private/              # Product & technical documentation
โ”œโ”€โ”€ docker-compose.yml
โ”œโ”€โ”€ .env.example                # Environment variables template
โ””โ”€โ”€ Makefile

๐Ÿ”ง Development

Backend (Go)

cd backend
go mod download
go run main.go

Frontend (React)

cd frontend
npm install
npm run dev

Environment Variables

Copy the example environment file and configure it:

# Copy the example file
cp .env.example .env

# Edit .env and add your values (especially KOLOSAL_API_KEY)
# See .env.example for all available configuration options

Required variables:

  • KOLOSAL_API_KEY - Get from https://api.kolosal.ai (optional for basic features)
  • JWT_SECRET - Generate with: openssl rand -base64 32 (change from default!)

Quick setup:

# Minimum required for local development
KOLOSAL_API_KEY=your-api-key-here
JWT_SECRET=your-secure-secret-here

See .env.example for complete configuration options and documentation.

๐Ÿ“š API Endpoints

Authentication

  • POST /api/v1/auth/register - Register new user
  • POST /api/v1/auth/login - Login

Chat & Conversations (AI-First Interface)

  • POST /api/v1/chat/start - Start new conversation
  • POST /api/v1/chat/message - Send message to AI assistant
  • GET /api/v1/chat/conversations - List all conversations
  • GET /api/v1/chat/messages - Get messages from a conversation

File Uploads

  • POST /api/v1/files/upload - Upload CSV/XLSX/PDF files (with OCR processing)
  • GET /api/v1/files/{id} - Get file upload information
  • GET /api/v1/files - List all file uploads

Insights (Four Outcome Types)

  • POST /api/v1/insights/forecast - Generate forecast insights
  • POST /api/v1/insights/market - Generate market prediction insights
  • POST /api/v1/insights/marketing - Generate marketing recommendations
  • POST /api/v1/insights/regulation - Generate government regulation insights
  • GET /api/v1/insights - Get insight history

Companies

  • GET /api/v1/companies - List user's companies
  • GET /api/v1/companies/{id} - Get company profile (aggregated data)

Dashboard

  • GET /api/v1/dashboard/summary - Get dashboard KPIs and summaries

Legacy AI (Deprecated)

  • POST /api/v1/ai/analyze - Legacy AI analyze endpoint

๐ŸŽจ Tech Stack

Component Technology
Backend Go 1.25 (net/http)
Frontend React 18 + Vite + TypeScript + Tailwind CSS
UI Components shadcn/ui (Radix UI primitives)
State Management Zustand
Charts Recharts
Database PostgreSQL 18
Cache Redis 7
AI Kolosal.ai (Chat & OCR)
Deployment Docker & Docker Compose

๐Ÿ“Š Features

MVP (Hackathon) - AI-Chat-First Architecture

โœ… Core Features

  • โœ… AI Chat Interface - Conversational data collection in Bahasa Indonesia
  • โœ… Floating Chat Widget - Persistent chat button accessible from any page
  • โœ… File Upload & OCR - CSV/XLSX/PDF upload with automatic text extraction (Kolosal.ai OCR)
  • โœ… Forecast Insights - 30/60/90-day sales forecasting with interactive charts
  • โœ… Market Prediction - Local (Indonesia) and global market trend analysis
  • โœ… Marketing Recommendations - AI-generated campaign ideas and strategies
  • โœ… Government Regulations - Indonesia-specific regulatory information with compliance tracking
  • โœ… Company Profile - Aggregated business data from all sources
  • โœ… Dashboard - Comprehensive overview with KPIs, charts, and quick actions
  • โœ… Smart Notifications - Real-time updates with priority indicators

โœ… UI/UX Enhancements

  • โœ… "Neon Finance" Design System - Modern dark theme with emerald accents
  • โœ… Glassmorphism Effects - Beautiful glass-like UI elements
  • โœ… Responsive Design - Optimized for desktop and mobile devices
  • โœ… Smooth Animations - Fade-in, slide transitions, and hover effects
  • โœ… Mobile Navigation - Hamburger menu with slide-out sidebar
  • โœ… Matrix Background - Tech animation effects on AI Chat page

Roadmap

  • External Data Connectors - Tokopedia, Shopee, Bukalapak marketplace scraping
  • Google Trends Integration - Real-time market trend data
  • Regulation Scraper - Automated peraturan.go.id monitoring
  • Advanced Forecasting - ML-based time-series forecasting
  • Mobile App - React Native mobile application
  • Billing & Subscriptions - 3-tier pricing (Free, Pro, Enterprise)
  • Multi-Company Management - Support for multiple businesses per user
  • Export Reports - PDF/Excel export for forecasts and insights

๐Ÿ—๏ธ Architecture

High-Level Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚   Frontend  โ”‚โ”€โ”€โ”€โ”€โ–ถโ”‚           Backend (Go)              โ”‚โ”€โ”€โ”€โ”€โ–ถโ”‚  PostgreSQL โ”‚
โ”‚   (React)   โ”‚     โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”         โ”‚     โ”‚             โ”‚
โ”‚             โ”‚     โ”‚  โ”‚  Chat   โ”‚  โ”‚Ingestionโ”‚         โ”‚     โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
โ”‚  - AI Chat  โ”‚     โ”‚  โ”‚ Service โ”‚  โ”‚ Service โ”‚         โ”‚
โ”‚  - Forecast โ”‚     โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜         โ”‚     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  - Market   โ”‚     โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”         โ”‚โ”€โ”€โ”€โ”€โ–ถโ”‚   Redis     โ”‚
โ”‚  - Marketingโ”‚     โ”‚  โ”‚Forecast โ”‚  โ”‚Connectorโ”‚         โ”‚     โ”‚   (Cache)   โ”‚
โ”‚  - Regulationโ”‚    โ”‚  โ”‚ Service โ”‚  โ”‚ Service โ”‚         โ”‚     โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
โ”‚  - Dashboardโ”‚     โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜         โ”‚
โ”‚  - Widget   โ”‚     โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”                       โ”‚     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ”‚  โ”‚ Insightsโ”‚                       โ”‚โ”€โ”€โ”€โ”€โ–ถโ”‚ Kolosal.ai  โ”‚
                    โ”‚  โ”‚ Service โ”‚                       โ”‚     โ”‚  (Chat+OCR) โ”‚
                    โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜                       โ”‚     โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Key Components

  • Chat Service - Handles AI conversations and message history
  • Ingestion Service - Processes file uploads (CSV/XLSX/PDF) with OCR
  • Forecast Service - Generates sales forecasts based on user-provided sales data
  • Connector Service - External data sources (marketplaces, trends, regulations)
  • Insights Service - Generates four types of insights (forecast, market, marketing, regulation)

Frontend Architecture

  • Component-Based - Reusable UI components with shadcn/ui
  • State Management - Zustand for global state (auth, chat)
  • Routing - React Router for navigation
  • Styling - Tailwind CSS with custom "Neon Finance" theme
  • Charts - Recharts for data visualization

๐ŸŒŸ How It Works

  1. Start Chat - User begins conversation with AI Assistant (via floating widget or dedicated page)
  2. Data Collection - AI asks about company, products, location, business model
  3. File Upload - User can upload CSV/XLSX/PDF files for automatic data extraction
  4. Profile Building - System builds comprehensive Company Profile from conversations and files
  5. Generate Insights - User navigates to four outcome pages:
    • Forecast - Sales projections with interactive charts (generated if user provides sales data via chat or file upload)
    • Market Prediction - Local and global market trends with trending products
    • Marketing Recommendation - Campaign ideas and strategies with performance estimates
    • Government Regulation - Relevant Indonesian regulations with compliance tracking
  6. Dashboard Overview - Centralized view of all KPIs, recent conversations, insights, and file uploads

All powered by Kolosal.ai for natural language understanding and OCR processing.

๐Ÿ“ License

Apache License 2.0 - see LICENSE file for details.

๐Ÿ”’ Security

We take security seriously. Please see our Security Policy for details on how to report vulnerabilities.

Security Scanning

This repository uses automated security scanning:

  • CodeQL - Static code analysis for security vulnerabilities
  • CodeRabbit - AI-powered code reviews for security and quality
  • Dependency Review - PR dependency scanning
  • Security Workflows - npm audit and Go security scanners

To enable these features:

  1. Go to your repository Settings โ†’ Code security and analysis
  2. Enable Code scanning (CodeQL)
  3. Enable Secret scanning
  4. Install CodeRabbit GitHub App (see CodeRabbit Setup Guide)

All security workflows are configured in .github/workflows/ and will run automatically on push and pull requests.

Note: Dependabot is disabled. Dependency updates are managed manually or through CodeRabbit reviews.

๐Ÿค– Code Review with CodeRabbit

We use CodeRabbit for AI-powered code reviews that complement our security scanning tools.

Features

  • AI-Powered Reviews - Context-aware code analysis for Go and React/TypeScript
  • Automated PR Summaries - Quick understanding of changes
  • Line-by-Line Suggestions - Detailed feedback on code quality and best practices
  • Natural Language Chat - Ask questions about code changes directly in PRs
  • Cursor IDE Integration - Real-time code reviews in your editor

Configuration

CodeRabbit is configured via .coderabbit.yaml with:

  • Go backend review guidelines (error handling, security, concurrency)
  • React/TypeScript frontend review guidelines (performance, accessibility, type safety)
  • Path filters to focus on source code
  • Integration with ESLint and Gitleaks

See CodeRabbit Setup Guide for detailed setup instructions.

๐Ÿ‘ฅ Team

Enggan Ngoding, Pecut AI

Built with โค๏ธ for IMPHNEN x Kolosal.ai Hackathon 2025

Team Members


Bantuaku - Membantu UMKM Indonesia tumbuh dengan AI dan data ๐Ÿ‡ฎ๐Ÿ‡ฉ


๐Ÿ™ Acknowledgments

  • Kolosal.ai - For providing powerful AI chat and OCR capabilities
  • CodeRabbit - For AI-powered code reviews and quality assurance
  • shadcn/ui - For beautiful, accessible UI components
  • Recharts - For elegant data visualization
  • Tailwind CSS - For rapid UI development

About

AI-Chat-First Forecasting Assistant untuk UMKM Indonesia. Sales forecasting, market prediction, marketing recommendations, dan government regulations melalui conversational AI (Kolosal.ai)

Topics

Resources

Security policy

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages