Inspiration
In Pakistan, millions of small business owners (SMEs, retail shops, and traders) run essential businesses every day. However, most rely on fragile paper registers (khata), mental math, or scattered receipts. Professional ERP systems are prohibitively expensive, overly complex, and English-only.
We built Elevate to give small business owners an accessible, intelligent, and affordable business copilot. Our goal was clear: bridge the digital and financial divide with accessible AI that understands English, Urdu, and Roman Urdu, turning scattered receipts and daily sales into clear, actionable business intelligence.
What it does
Elevate is an all-in-one, AI-powered business management copilot engineered specifically for retail and trading businesses:
- Bilingual & Roman Urdu First: Chat and navigate effortlessly in English, Urdu, and Roman Urdu.
- Grounded AI Business Assistant: An AI consultant that answers queries directly grounded in the owner's actual business data (stock levels, profit margins, sales trends) — with zero hallucination of financial numbers.
- Automated Invoice & Receipt Extraction: Owners can snap or upload supplier invoices. The system automatically extracts line items, quantities, and prices for owner review before committing stock.
- Idempotent Inventory & Real-Time Stock Tracking: Atomic Firestore transactions prevent overselling and track stock movements with automatic low-stock alerts.
- Accurate Financial Calculations: Authoritative deterministic math (calculated in integer paisas) for Gross Profit, Net Profit, Sales, and Expenses.
- AI Forecasting & Marketing Assistant: Predictive restock suggestions, sales forecasting, and instant social media marketing campaign generators.
- Security & Multi-Tenant Isolation: Complete enterprise-grade workspace isolation, HTTP-only authenticated session cookies, and TOTP Two-Factor Authentication (2FA).
How we built it
- Frontend & Server: Built on Next.js 16 (App Router) with React, TypeScript, and Tailwind CSS, designed with an Electric Lime & Carbon high-contrast theme meeting WCAG AA standards.
- Database & Auth: Google Cloud Firestore with strict workspace-isolation security rules and Firebase Authentication hardened with server-verified session cookies and RFC 6238 TOTP two-factor authentication.
- Deterministic Engine: Isolated, pure calculation modules ensuring financial arithmetic is never left to LLM probability.
- Hosted AI Pipeline: A secure server-side AI adapter connecting to hosted LLM endpoints with prompt engineering tailored for Pakistani commerce and Roman Urdu understanding.
- Testing: 194 automated unit and integration tests using Vitest testing calculation accuracy, RBAC authorization, and API boundary security.
Challenges we ran into
- Hallucination-Proof Financial Calculations: AI models are notorious for making arithmetic errors. We designed a strict boundary: all math (profit margins, totals, taxes, COGS) is calculated deterministically in TypeScript, and only sanitized summaries are fed into the LLM context.
- Roman Urdu NLP Nuances: Structuring system prompts to accurately interpret informal Roman Urdu business terms ("kya stock khatam hone wala hai", "kitna munafa hua") while preserving high-precision business reasoning.
- Atomic Stock Movements: Ensuring that retried network requests or high concurrency never deduct inventory twice or corrupt stock history through atomic Firestore transactions.
Accomplishments that we're proud of
- 194 Passing Unit & Integration Tests: 100% test pass rate covering authorization, invoice parsing, profit calculations, and TOTP security.
- Zero-Friction Mobile First Experience: Fully responsive layout with sleek navigation that works smoothly on budget smartphones.
- Accessible AI Assistance: A real, persistent AI assistant that remembers past conversations and gives localized, practical advice to small shopkeepers.
What we learned
- Designing for regional small business owners requires radical simplicity—removing enterprise jargon and replacing it with familiar, high-contrast, fast-loading visual feedback.
- Strict multi-tenant security cannot rely on client-side state; verifying workspace ownership on the server on every request is paramount.
What's next for Elevate
- Direct WhatsApp Bot integration for voice-note expense logging.
- Offline-first progressive web app (PWA) sync for locations with unstable internet.
- Integration with local payment gateways (Raast, JazzCash, EasyPaisa).
Built With
- artificial-intelligence
- firebase
- firebase-auth
- firestore
- gemini-api
- groq
- llm
- next.js
- node.js
- react
- tailwind-css
- typescript
- vitest
Log in or sign up for Devpost to join the conversation.