Inspiration
Amazon cashierless checkout. The store knows what you took. We wanted that for the parts shelf in a small shop, where someone sees the empty box, forgets to order more and the job stops.
What it does
A camera watches a board of parts and counts what's on it. Take two off and the count drops. When a part gets low reup shops the live web. It checks the price at Home Hardware and Canadian Tire, fills a cart at our supplier and shows you one order. Nothing is bought until you say yes.
Put a part it has never seen on the teach spot and Gemini names it in a few seconds.
The supplier, Offcut Supply, is a store we built, so reup can finish a real checkout without spending real money.
How we built it
A Python program on the laptop counts the parts from one example picture of each. A Cloudflare Worker keeps the counts and decides when to order. TinyFish drives real browsers to do the shopping, a cart takes about 40 seconds. Gemini names new parts from a photo and the store's catalog, and answers questions about the board's own numbers. A Raspberry Pi 5 on QNX runs QNX's own hand tracker on the board's video and writes every reach to disk before it sends it.
Challenges we ran into
For almost two hours every cart failed. We told the agent to press Checkout and it pressed Empty cart, as the two sat side by side. It was pretty good at emptying carts though.
We also wanted the Pi to own the camera. Its USB only gave us 6 pictures a second on QNX, so the laptop keeps the camera and passes the video over.
Accomplishments that we're proud of
It does the whole job on its own. It counts, shops, waits for a yes and places the order about 26 seconds later.
What we learned
A button in the wrong spot cost us more hours than the vision did. We learned to watch the agent's browser while it works, that's how we caught it.
What's next for reup
We'd like the Pi to do the counting itself. After that a real supplier, with a spend cap.
Built With
- cloudflare-workers
- gemini
- opencv
- python
- qnx
- raspberry-pi
- react
- tinyfish
- typescript
