Inspiration

Twenty-four dollars. That's the minimum monthly SNAP benefit for a DC household today — about a week of groceries, if you buy smart. And if you live in Ward 7 or 8, you're often doing that shopping at a corner store with one fridge, no produce manager, and no dynamic pricing technology. We met this problem through the story of Yonas Haile, who runs Stanton Supermarket in Ward 8. With support from DC Central Kitchen's Healthy Corners program, he expanded from one open-air fridge to six refrigerators of fresh produce, serving 85,000 neighbors. But every day, he still guesses. Which bananas are still fresh? When should prices come down? How much will end up in the trash? Corner stores are the last mile of the US food system. They serve the communities with the highest food insecurity — and they have none of the retail technology that big-box grocery takes for granted. VitalShelf exists to close that gap.

What it does

VitalShelf is a shelf-edge device that turns any corner-store produce shelf into a smart shelf. It measures freshness in real time using weight, temperature, humidity, and computer vision, then dynamically prices produce so it sells before it spoils. Store owners recover margin that would otherwise become waste. SNAP shoppers see transparent, downward-only pricing they can trust. Food-access programs like DCCK Healthy Corners get auto-generated scorecard data without counting by hand. The system is policy-aware by design. Prices are bounded by a SNAP-compatible floor — so the economics of SNAP Match are preserved — and an anti-gouging ceiling tied to big-box grocery benchmarks. Prices only move downward. A customer who sees a price will never see it rise.

How we built it

Hardware: An ESP32-WROOM-32E reads a 1kg HX711 load cell (weight), a DHT11 sensor (temperature + humidity), and an optional USB camera (vision). An Arduino prototype shield serves as the 5V power distribution hub. Output displays on an LCD1602 via I²C. Total prototype BOM: ~$150 in retail parts, projected ~$50 per unit at scale. Firmware: Non-blocking C++ scheduler on the ESP32 runs three independent tasks — fast local weight polling at 5Hz, environment polling every 2s, and backend POST every 3s. Persistent HTTPS client with connection reuse. Offline fallback keeps the device operational if Wi-Fi or backend fails. Backend: Flask API on Render receives sensor payloads, runs the pricing engine, and persists every reading in MongoDB. Pricing is computed as a function of freshness, time-on-shelf, sell-through velocity, anchor price, and SNAP-aware guardrails. Vision: Google Gemini classifies produce type and ripeness stage from a USB camera feed running on a paired laptop. Decoupled from the sensor pipeline so vision failures don't block sensor data. Data: MongoDB persists every reading and pricing event. Sales, waste, variety, and delivery data are exportable as CSV or JSON for DCCK Healthy Corners scorecard automation. Open source: MIT for firmware, backend, and dashboard. Apache 2.0 where appropriate. CERN-OHL-S v2 for hardware schematics. CC BY-SA 4.0 for documentation. Meets all 9 Digital Public Goods Standard indicators.

Challenges we ran into

Rohan had never built hardware before this weekend. He treated the hackathon as a deep-end personal challenge — learned ESP32, HX711 load cell calibration, I²C wiring, Wi-Fi debugging, and housing assembly in 24 hours. Dane wrestled with the camera and vision logic. Integrating Gemini into the classification pipeline while keeping it decoupled from the ESP32 sensor stream took iteration. The solution was isolating the vision pipeline to a laptop reading from the Render backend, so vision failures never block sensor data. Nicholas built the scoring and pricing logic against live sensor streams. The freshness score is a weighted fusion of weight change, temperature, and humidity. The pricing logic layers SNAP-aware guardrails on top. Iteration happened live against streaming sensor data, not simulated inputs. iPhone hotspot Wi-Fi failure. The ESP32 couldn't see the hotspot's SSID broadcast at first. We wrote diagnostic firmware that scanned networks and logged status codes — surfaced iOS broadcast suppression, which we worked around by keeping the hotspot screen active during testing. Load cell drift at zero. HX711 readings jittered ±2g at rest, which would have been sent as real data. We calibrated to SCALE_FACTOR 387.02 against a known test weight and added a ±5g deadband filter to suppress noise.

Accomplishments that we're proud of

  • Shipped a working end-to-end system in 24 hours: sensors → ESP32 → HTTPS → Flask on Render → MongoDB → LCD.
  • Live demo that judges can physically interact with — pick up a fresh, ripe, or markdown banana, watch the price change in real time.
  • SNAP-aware pricing framework that is novel, not just a dynamic pricing system. Downward-only, SNAP-compatible, anti-gouging.
  • Full DPG alignment across all 9 indicators of the Digital Public Goods Standard.
  • Real partner in mind. We didn't invent a fake persona — we built for Yonas Haile at Stanton Supermarket, a real DC Central Kitchen Healthy Corners store.
  • Built for scale from day one. ~$150 prototype, ~$50/unit at 1,000-unit procurement, under 3-month payback per store.

What we learned

That hardware-software integration under time pressure is a discipline, not an improvisation. That open-source design choices made at hour one compound through hour 24. That a pitch lands harder when you've named a real person whose life gets better because of what you built.

What's next for VitalShelf

Pilot deployment. Three to five Healthy Corners stores for an eight-week pilot. Validate waste recovery, measure how owners and shoppers actually adapt to dynamic pricing. Research partnership. Work with the GW Global Food Institute to study how dynamic pricing changes shopper behavior and SNAP spending patterns. Co-author the evidence base for scale. Replication. Any Healthy Corners-style program in any city can fork the repo tonight. MIT-licensed, DPG-aligned, open to all.

Built With

Share this project:

Updates