Smart Vendor
AI powered retail management system
Created on 15th August 2026
โข
Smart Vendor
AI powered retail management system
The problem Smart Vendor solves
๐ SmartVendor AI
Transforming any Android smartphone into an AI-powered Point of Sale (POS) system for small retailers.
๐ Overview
SmartVendor AI is an AI-powered retail assistant that converts any Android smartphone into a complete Point of Sale (POS) system.
Instead of relying on expensive barcode scanners and dedicated billing hardware, SmartVendor AI uses Computer Vision and Artificial Intelligence to recognize products directly through the phone's camera, automatically generate bills, update inventory, analyze sales, and recommend future stock requirements.
Designed especially for:
- Kirana Stores
- Grocery Shops
- Bakeries
- Medical Stores
- Small Retail Businesses
๐ฏ Problem Statement
Millions of small retailers still rely on:
- Manual billing
- Paper notebooks
- Expensive POS systems
- Barcode scanners
- Manual inventory tracking
These methods are slow, error-prone, and difficult to manage.
SmartVendor AI provides an affordable AI-powered alternative using only a smartphone.
๐ก Our Solution
SmartVendor AI replaces traditional billing systems with AI-powered product recognition.
Simply point the phone camera at a product.
The system automatically:
๐ท Detects the product
โ
๐ง Identifies it using AI
โ
๐งพ Creates the bill
โ
๐ฆ Updates inventory
โ
๐ Stores sales history
โ
๐ Predicts future stock requirements
โญ Features
๐ท AI Product Recognition
- Camera-based product detection
- No barcode scanner required
- Real-time object detection using YOLO
๐งพ Smart Billing
- Automatic bill generation
- Quantity adjustment
- GST support
- Instant total calculation
๐ฆ Inventory Management
- Automatic stock updates
- Product database
- Low-stock alerts
- Inventory history
๐ Sales Analytics
- Daily sales
- Weekly sales
- Monthly sales
- Best-selling products
- Revenue tracking
๐ AI Demand Forecasting
Machine Learning predicts:
- Future demand
- Inventory requirements
- Restocking recommendations
๐ Digital Bill
- PDF Bill Generation
- WhatsApp Sharing
- Digital Receipt Storage
๐ฑ Offline Support
Basic billing and inventory continue to work even without an internet connection.
Data syncs automatically when connectivity is restored.
๐๏ธ System Workflow
Customer Product
โ
Phone Camera
โ
YOLO Object Detection
โ
Product Identification
โ
Billing Engine
โ
Inventory Engine
โ
Database
โ
Sales Analytics
โ
Demand Forecasting
โ
Dashboard
๐ System Architecture
Flutter Mobile App
โ
REST API (FastAPI)
โ
โโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโ
โ โ โ
YOLO Detection Billing Engine Inventory Engine
โ โ โ
โโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโ
โ
Analytics Engine
โ
Demand Forecast Model
โ
SQLite / PostgreSQL
๐ Technology Stack
Frontend
- Kotlin
- Android studio
Backend
- FastAPI
- SQL
- Python
AI & Computer Vision
- YOLOv8n
- OpenCV
OCR
- Google ML Kit OCR
Machine Learning
- Scikit-learn
Database
Development
- SQLite
Production
- PostgreSQL
Version Control
- Git
- GitHub
๐ Repository Structure
SmartVendor-AI/
โ
โโโ frontend/
โ
โโโ backend/
โ
โโโ datasets/
โ
โโโ trained_models/
โ
โโโ docs/
โ
โโโ presentations/
โ
โโโ README.md
โ
โโโ LICENSE
๐ Development Roadmap
Phase 1
- Project Setup
- GitHub Repository
- Folder Structure
Phase 2
- Kotlin UI
- Product Database
- FastAPI Backend
- OCR
Phase 3
- YOLO Dataset
- Image Annotation
- Model Training
Phase 4
- Product Detection
- Billing Engine
- Inventory Engine
Phase 5
- Analytics Dashboard
- Demand Forecasting
- Reports
Phase 6
- Testing
- Optimization
- Deployment
๐ฏ Target Users
- Grocery Shops
- Kirana Stores
- Supermarkets
- Bakeries
- Medical Stores
- Stationery Shops
๐ Future Scope
- Multi-store Management
- Cloud Synchronization
- UPI Payment Integration
- Voice Billing
- Customer Loyalty Program
- Business Insights Dashboard
๐ฅ Team
| Module | Responsibility |
|---|---|
| Mobile App | Kotlin |
| Backend | FastAPI |
| AI Model | YOLOv8 |
| Database | SQLite / PostgreSQL |
| ML | Demand Forecasting |
| Integration | API & Testing |
Challenges we ran into
๐ ๏ธ Challenges We Ran Into
Building SmartVendor AI for real-world retail environments presented several tough engineering hurdles:
1. Specular Glare & Letter Distortion on Reflective Foil Packaging
- The Hurdle: Real Kirana store items (like Maggi yellow foil, Snickers wrappers, and Lays chips bags) reflect bright overhead lights. This created specular whiteout glare on camera frames, causing the OCR engine to extract garbled or duplicated letter noise (e.g., reading
"maazza"instead of"maaza"). - How We Solved It: We engineered a custom YUV frame processor in Kotlin (
OcrScannerManager) that calculates pixel luminance ($Y$) and filters out whiteout glare spots ($Y > 235$) before sampling colors. We also added a regular expression character compressor (replace(Regex("(.)\\1+"), "$1")) to normalize glare-duplicated letters back into clean text before candidate evaluation.
2. Phonetic & Visual Brand Cross-Match Confusion (Maggi vs. Maaza, Soya Sticks vs. Snickers)
- The Hurdle: Short FMCG brand names with overlapping letter counts produced high Levenshtein fuzzy similarity scores under fast camera motion. Scanning a Maggi packet would occasionally misidentify as Maaza, while Soya Sticks would cross-match with Snickers.
- How We Solved It: We created a multi-layered verification engine combining an explicit Anti-Confusion Guard Matrix (hard-blocking known negative brand pairs) with a Packaging Color Classifier (YUV $\rightarrow$ HSV hue mapping: Yellow for Maggi, Blue for Oreo, Red for KitKat). This ensured a +20% score boost on correct packaging colors while immediately dropping conflicting pairs.
3. Camera Scanner Re-Triggering & User Interaction Ergonomics
- The Hurdle: When a vendor tapped Add to Bill, holding the packet in front of the lens while putting it into a customer's bag caused the camera to continuously spam duplicate item cards. Conversely, tapping Cancel on a misread item caused the camera to freeze up.
- How We Solved It: We built a dual-state interaction engine in
ScanViewModel:- Add to Bill: Triggers a 5-second duplicate suppression cooldown for that item ID.
- Cancel: Records the rejected candidate in an ignored set and instantly displays candidate #2 (the next highest-ranked alternative recommendation) without interrupting the live camera stream.
4. Cold-Start Camera & ML Native Binary Latency
- The Hurdle: Initializing Google ML Kit C++ native libraries and fetching store inventory from the database on first camera render caused a noticeable 2.8-second cold-start lag.
- How We Solved It: Implemented an application-level pre-warming pipeline (
SmartVendorApplication.kt) that asynchronously pre-loads inventory products into an in-memory RAM cache (InventoryCache) and executes a dummy 0ms ML Kit initialization pass on app startup, dropping startup latency down to under 0.4 seconds.
Tracks Applied (1)
