AI-based Retail Shelf Analytics System
The client was a national FMCG manufacturer that distributed across roughly four thousand retail locations and lacked visibility into in-store execution. Field representatives audited shelves on a roughly six-week cycle, which left stockouts unaddressed for weeks and planogram violations undetected until the next audit. Lost sales from out-of-stocks were estimated at low single-digit percentage of revenue per quarter, but the company had no way to attribute store-level performance to execution rather than demand.
Computer Vision Solutions
FMCG/Retail
16 weeks from kickoff to pilot complete, full rollout over the following quarter
5 specialists
The full story
The practical problem was that retailers controlled the shelf and the manufacturer had no real-time signal short of in-person audits. The existing audit data was sparse and stale, decisions about which stores to prioritize for replenishment were essentially guesses, and the trade-marketing team could not measure whether secondary placement promotions were actually being executed in-store.
We deployed a camera-based system that captured shelf images at hourly intervals, ran on-prem inference for stockout and planogram-compliance detection, and pushed structured events into the manufacturer’s ERP for replenishment routing. The detection model was tuned per SKU and per store geometry, with a feedback loop where field reps validated edge cases and their corrections re-trained the model weekly.
What shipped was a real-time shelf dashboard at the manufacturer’s HQ showing live out-of-stock alerts, planogram compliance scores per location, and trade-promotion execution rates. Replenishment routing shifted from a six-week audit cycle to hourly signal. Field reps stopped doing routine audits and shifted to interventions where the system flagged sustained execution gaps, which expanded the effective coverage of the field team without expanding headcount.
Field reps audited shelves every six weeks, so stockouts and planogram violations went uncaught for weeks at a time.
Out-of-stock incidents lasted on average eleven days before detection, costing low-single-digit revenue percentage per quarter.
Planogram violations were invisible until the next audit, which made trade-marketing investment unmeasurable per store.
Field reps spent eighty percent of time on routine audits and twenty percent on interventions, the wrong ratio for impact.
Replenishment routing relied on retailer point-of-sale data, which arrived weekly and missed within-week stockout signal.
Secondary placement promotions paid to retailers had no execution verification, so the manufacturer paid for placements that did not appear.
How we structured the engagement
Captured shelf state as a structured event stream so every downstream decision could move at hourly cadence instead of weekly.
- 01Phase 01Weeks 1-3
Discovery
Visited eight pilot stores across three retail formats, captured baseline imagery, and tagged the failure modes of off-the-shelf models on these conditions. Worked with trade marketing to define a planogram-compliance score and with operations on the replenishment routing API contract.
- 02Phase 02Weeks 4-5
Architecture
Designed an edge-first system where a small fanless PC per store ran YOLOv8-derived models for stockout and planogram detection, then pushed only structured events to the cloud. Avoided streaming raw video for bandwidth and privacy reasons. Picked a per-SKU fine-tune approach with a shared backbone.
- 03Phase 03Weeks 6-13
Build
Shipped the edge inference stack first, then the cloud event ingester, then the ERP integration. Built the field-rep correction app so reps could photograph an edge case and label it in under thirty seconds. Wired the weekly retraining pipeline against the correction stream.
- 04Phase 04Weeks 14-16
Launch
Rolled out to twenty pilot stores for six weeks, measured detection precision per SKU, then waved across the four-thousand-store footprint over the following quarter. Set the alert thresholds per retail format because store noise and shelf layout differed meaningfully between formats.
What we built, component by component
- 01
In-store camera array
Per-aisle wide-angle cameras with fixed positioning and lighting calibration, capturing shelf state at hourly cadence.
- 02
Edge inference node
Small fanless PC running YOLOv8-derived models for stockout and planogram detection with per-store calibration profiles.
- 03
Event ingester
Receives structured detection events from edge nodes, deduplicates against the prior hour, and writes to the time-series store.
- 04
ERP replenishment connector
Pushes stockout events into the manufacturer’s ERP with store, SKU, and severity for automated replenishment routing.
- 05
Field-rep correction app
Mobile app for reps to label edge cases in under thirty seconds, feeding the weekly retraining pipeline with ground truth.
- 06
Operations dashboard
Real-time view of stockouts, planogram compliance, and trade-promotion execution across the four-thousand-store footprint.
Cameras capture imagery hourly and the edge inference node runs detection locally, sending only structured events to the cloud. The event ingester deduplicates and writes to the time-series store, the ERP connector pushes high-severity stockouts for replenishment routing, and field-rep corrections flow into the weekly retraining pipeline that updates the edge models.
The trade-offs we made and why
Ran inference on edge nodes, not in the cloud
Streaming raw video from four thousand stores would have been bandwidth-impossible and privacy-fraught. Edge inference sent only structured events upstream, kept raw imagery on-site, and made the per-store unit economics workable.
Per-SKU fine-tunes on a shared backbone
A generic object detector confused similar SKUs in adjacent flavors or sizes. Per-SKU fine-tunes on a shared backbone gave the precision the trade-marketing team needed without exploding model footprint per edge node.
Built the field-rep correction app as part of the platform
Without a structured way to capture corrections, edge-case errors would persist forever. Making correction a thirty-second mobile interaction kept the labeling cost low and turned every field rep into a continuous source of ground truth for retraining.
Set alert thresholds per retail format
Convenience stores and supermarkets had different baseline shelf noise and customer behavior. A single threshold either over-alerted in convenience or missed real stockouts in supermarkets. Per-format thresholds gave operations a manageable alert volume.
What changed for the client
detection accuracy
Precision-recall harmonic mean for stockout detection on a held-out store sample across the three retail formats.
stockout incidents
Reduction in average stockout duration across the rollout cohort over the first full quarter after deployment.
sales lift
Year-over-year sales increase on the rollout cohort versus a matched holdout group during the first full quarter.
shelf-state cadence
Replacement for the prior six-week audit cycle, with hourly events flowing into ERP and the operations dashboard.
“We finally see the shelf the way our customers do, hourly. The field-rep app is what made the model keep getting better after launch.”
The tools behind the system
Built with a deliberate stack chosen for production reliability and operational velocity.
Lessons learned from the build
Edge inference was the only economically viable choice at this footprint, and we should have committed to it in week one. We spent three days exploring a cloud-streaming architecture out of habit and the answer was already obvious from the bandwidth math.
Per-format threshold tuning was more important than per-SKU model tuning for alert quality. Operations could tolerate per-SKU edge cases but could not tolerate alert floods. We would invest in threshold tuning earlier in the pilot cycle.
The field-rep correction loop made the system get better instead of worse over time. Models in production usually degrade without active labeling investment, and turning the field team into labelers reversed that drift. We would build a correction app into any vision project from the start.
Similar delivery work usually starts in these service areas
If you are exploring a similar product, workflow, or implementation challenge, these are the service tracks that usually fit best.
Where this project sits in the bigger market picture
AI use cases for retail, commerce, personalization, pricing, and customer support.
Build a result-driven AI product with a team that has shipped before
If you are exploring a similar product, workflow, or AI use case, we can help scope the right architecture, delivery model, and first milestone.
Related case studies worth reviewing next
Have an AI idea, messy workflow, or product vision? Let's make it buildable.
Bring the problem. We'll help shape the product, define the architecture, and show the fastest path to a serious first version.
A practical first roadmap in the discovery call
Architecture, timeline, and delivery options in plain English
Security, scalability, and reliability discussed upfront
Model registry
softus-rag-v4.2
187ms
Latency
128k
Context
$0.004
Cost / req
Evaluation suite
Deploy pipeline
prod / canary 25% — healthy
