Skip to content
RohithdgrrPublic

About

AI-powered inventory management system with voice commands, WhatsApp integration, and intelligent analytics for Indian retail businesses.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

Β 

History

4 Commits

Folders and files

Repository files navigation

StockShield Pro πŸ›‘οΈ

AI-powered inventory management system with voice commands, WhatsApp integration, and intelligent analytics for Indian retail businesses.

✨ Features

  • 🎀 Voice Commands - Control inventory with voice in English, Hindi, Tamil
  • πŸ“± WhatsApp Integration - Automatic invoice sending via WhatsApp
  • πŸ€– ASTA AI Assistant - Natural language queries and insights
  • πŸ“Š Real-time Analytics - Profit tracking, low stock alerts
  • πŸ‘οΈ Vision AI - Shelf image analysis and invoice scanning
  • πŸ“ˆ Smart Reports - Automated inventory reports

πŸš€ Quick Start

Prerequisites

  • Node.js 18+
  • Docker & Docker Compose
  • WhatsApp mobile app

Installation

# 1. Clone repository
git clone <repository-url>
cd stockshield

# 2. Install dependencies
cd stockshield/server && npm install
cd ../src && npm install

# 3. Start Evolution API (WhatsApp)
cd ../../evolution-api
docker-compose up -d

# 4. Configure environment
cp stockshield/.env.example stockshield/.env
# Edit .env with your API keys

# 5. Start services
cd stockshield/server && node index.js
cd ../src && npm run dev

Access Application

πŸ“š Documentation

Complete documentation available in docs/ folder:

🎯 Key Capabilities

Voice Commands

"Add 10 kg rice"           β†’ Adds stock
"Sold 5 kg dal"            β†’ Records sale
"Check stock of sugar"     β†’ Shows inventory
"Show low stock"           β†’ Lists low items
"Generate report"          β†’ Creates report

WhatsApp Invoice Sending

  1. Connect WhatsApp - Scan QR code once
  2. Automatic Sending - Invoices sent for sales > β‚Ή5000
  3. Manual Sending - Click "Send Invoice" on any transaction
  4. Formatted Messages - Professional invoice format with GST

AI Assistant (ASTA)

  • "What are my profits this month?"
  • "Which items are low in stock?"
  • "Show me sales trends"
  • "Recommend reorder quantities"

πŸ› οΈ Technology Stack

  • Frontend: Next.js 14, React, TailwindCSS
  • Backend: Express.js, Node.js
  • WhatsApp: Evolution API, Baileys
  • Voice AI: Sarvam AI (STT/TTS)
  • Database: PostgreSQL, Redis
  • Deployment: Docker, Docker Compose

πŸ“± WhatsApp Integration

Setup (3 Steps)

  1. Start Evolution API

    cd evolution-api && docker-compose up -d
  2. Connect WhatsApp

    • Open app β†’ Click WhatsApp icon
    • Click "Scan QR Code to Connect"
    • Scan with WhatsApp mobile app
  3. Configure Settings

    • Enter WhatsApp number
    • Set auto-send threshold
    • Save settings

Features

  • βœ… Automatic invoice generation
  • βœ… GST calculation (18%)
  • βœ… Formatted WhatsApp messages
  • βœ… Delivery confirmation
  • βœ… Disconnect/reconnect support
  • βœ… Manual and automatic sending

🎀 Voice Features

Supported Languages

  • English (en-IN)
  • Hindi (hi-IN)
  • Tamil (ta-IN)

Commands

  • Inventory management
  • Stock queries
  • Report generation
  • Transaction recording

Wake Word

Say "ASTA AI" to activate voice assistant

πŸ”§ Configuration

Environment Variables

stockshield/.env:

EVOLUTION_API_URL=http://localhost:8080
EVOLUTION_API_KEY=429683C4C977415CAAFCCE10F7D57E11
WHATSAPP_INSTANCE=stockshield
SARVAM_API_KEY=your_sarvam_key
PORT=3001

evolution-api/.env:

SERVER_PORT=8080
DATABASE_PROVIDER=postgresql
AUTHENTICATION_API_KEY=429683C4C977415CAAFCCE10F7D57E11

πŸ› Troubleshooting

WhatsApp Not Connecting

  1. Check Evolution API: docker ps
  2. Click "Disconnect" in settings
  3. Click "Scan QR Code to Connect"
  4. Scan with mobile app

Invoice Not Sending

  1. Verify WhatsApp status shows "Connected"
  2. Check phone number format (+919876543210)
  3. Ensure transaction exists
  4. Check server logs

Voice Not Working

  1. Allow microphone permissions
  2. Check Sarvam API key
  3. Test with simple commands
  4. Verify language selection

πŸ“Š System Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Next.js        β”‚  ← User Interface
β”‚  Frontend       β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
         β”‚
         β”‚ HTTP API
         β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Express.js     β”‚  ← Business Logic
β”‚  Server         β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
         β”‚
         β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
         β”‚              β”‚             β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Evolution API  β”‚ β”‚  Sarvam AI  β”‚ β”‚Database β”‚
β”‚  (WhatsApp)     β”‚ β”‚  (Voice)    β”‚ β”‚         β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

πŸš€ Deployment

Development

npm run dev

Production

npm run build
npm start

Docker

docker-compose up -d

πŸ“ˆ Recent Updates

v2.0.0 (April 2026)

  • βœ… Fixed WhatsApp QR code display
  • βœ… Fixed connection status detection
  • βœ… Added disconnect/logout feature
  • βœ… Fixed invoice sending functionality
  • βœ… Improved error handling
  • βœ… Enhanced user feedback
  • βœ… Updated documentation

🀝 Contributing

  1. Fork the repository
  2. Create feature branch
  3. Commit changes
  4. Push to branch
  5. Create Pull Request

πŸ“ License

Proprietary - All rights reserved

πŸ†˜ Support

🎯 Roadmap

  • Multi-store support
  • Advanced analytics dashboard
  • Mobile app (React Native)
  • Barcode scanning
  • Supplier management
  • Purchase order automation
  • Multi-currency support
  • Cloud deployment

Made with ❀️ for Indian Retail Businesses

Version: 2.0.0 | Last Updated: April 7, 2026

About

AI-powered inventory management system with voice commands, WhatsApp integration, and intelligent analytics for Indian retail businesses.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages