Hackathon Judge Architecture Guide

How RetaiLens AI Works

RetaiLens AI is an autonomous agentic operations platform—not a passive dashboard or a Q&A chatbot. Every perception triggers validated reasoning, memory retrieval, deterministic tool execution, and human-governed approvals.

End-to-End Execution Pipeline

STAGE 01 • CAMERA / POS INPUT

Live aisle cameras (CAM-01..04), checkout lane video (CAM-CHK-01/02), and POS barcode scans.

STAGE 02 • COMPUTER VISION AND EVENT DETECTION

FastAPI + OpenCV / YOLO interface extracts shelf occupancy %, bounding boxes, and confidence scores.

STAGE 03 • AI AGENT PERCEPTION

Agent ingests structured detection events, inventory deltas, and upcoming product expiry dates.

STAGE 04 • REASONING AND PLANNING

ReAct planner retrieves persistent PostgreSQL memory (velocity, lead-time drift, past approvals) before planning.

STAGE 05 • DETERMINISTIC TOOL EXECUTION

Server validates Zod tool arguments against RBAC & safety thresholds—never allowing raw LLM SQL.

STAGE 06 • HUMAN APPROVAL WHEN REQUIRED

High-value POs (>₹5,000), checkout overrides (<80% confidence), and discounts >15% pause for Store Manager review.

STAGE 07 • DATABASE MUTATION

Idempotent transactional updates mutate stock, purchase orders, pricing, and GST-preview receipts.

STAGE 08 • PERSISTENT MEMORY

Outcomes and human decisions persist to agent_memory across sessions for continuously smarter planning.

STAGE 09 • OPERATIONAL INSIGHTS

Executive Command Center, Event Timeline, Analytics, and Audit Logs update in real time.

Traditional Retail Software vs. RetaiLens AI

Traditional Retail Software

  • Reactive — managers discover stockouts hours too late
  • Manual monitoring across disconnected CCTV and POS tools
  • Static threshold alerts with zero supplier lead-time context
  • Manual workflows for PO creation and expiry discounting
  • Limited historical memory for recurring SKU velocity surges

RetaiLens AI

  • Proactive — detects low shelf occupancy and expiry risk early
  • Automated CV + POS cross-verification at checkout lanes
  • Context-aware ReAct reasoning with 13 validated backend tools
  • Autonomous routine operations (verified sales, PO drafts, scans)
  • Persistent PostgreSQL memory across inventory, supplier & pricing
  • Human-controlled sensitive actions via Store Manager Approval Center