Inspiration

The problem is old: livestock auctions still run on paper, manual re-entry, and legacy DOS- and Microsoft-based systems built decades ago. SmartBarn AI is our answer — a mobile-first system that replaces the paper trail with real-time data capture, from the moment an animal arrives to the moment it's settled.

Two pain points drove the build. First, intake: staff record tag, sex, breed, and notes on paper before an animal reaches the ring, then someone re-keys it into the office system — slow, and error-prone right where accuracy matters most. Second, settlement: federal Packers and Stockyards Act rules require barns to pay buyers and sellers by the close of the next business day, and duplicate tags or mid-sale retags are the biggest thing that slows that down.

What it does

SmartBarn AI runs the full sale-day workflow, end to end:

  • Intake — staff record tag, sex, breed, and notes on the mobile device they already carry — no paper, no re-entry later. A photo of the consignor's driver's license autofills their name and address.
  • Weigh-in — the Weigh Master approves final weight and sends the lot to the ring.
  • Live ring — the current bid is tracked and pushed to a real-time scoreboard.
  • Sold / closing — price and buyer are recorded and a pen is assigned automatically, respecting rules for bulls, pairs, cut sales, and retags.
  • Yard sorting — the yard crew is alerted on their phone the moment an animal sells, showing exactly which pen it goes to — no more walkie-talkies. Crew can close a pen from their device, and the system stops assigning animals there until it's reopened.
  • Office & invoicing — settlement, checks, reports, and account management.

Ring Retag solves the retag problem directly: instead of a yard crew member finding the animal, writing down its new tag, and digging through paperwork in the office to find the original, staff photograph the scrapie tag and Gemini matches it to the record automatically — one photo instead of a multi-person search.

How we built it

SmartBarn AI is a Streamlit/Python app backed by Postgres/Supabase, with automatic fallback to local SQLite. Four processes run together during a live sale: a video server streaming the barn's real cameras, a Postgres LISTEN/NOTIFY cache listener for the scoreboard, a Deepgram real-time transcription relay for ring audio, and the main app.

Gemini 2.5 Flash, via Vertex AI on Google Cloud, powers driver's-license OCR at intake and tag-photo OCR for retags. We built it with Claude Code as a pair-programmer for both the app and the underlying auction logic, and also built a rule-based parser plus a Gemini-based engine that listens to the auctioneer's live chant to track bids automatically.

Challenges we ran into

This runs during real auctions with real money, so we couldn't treat bugs casually — we tested with disposable, clearly-tagged data and verified fixes against real barn audio and logs, not just code review.

The hardest problem was the live AI auction clerk: auctioneer chants are fast and easy to mis-transcribe, and we hit issues like weight being confused for price, digit-by-digit buyer numbers, and "now" versus "not" corrupting the tracked price. We fixed each as it surfaced, but ultimately paused AI as the live clerk in favor of a fast manual-entry flow, keeping the AI pipeline in the codebase for later. Knowing when a "smarter" path wasn't yet reliable enough for real money — and shipping the pragmatic version instead — was its own challenge.

We also had to handle real barn infrastructure: a Mac's IP address changing after sleep/wake, and background processes silently dying and needing a restart.

What's next for SmartBarn AI

Most barns run online bidding on a system separate from their in-ring clerk, creating lag for remote bidders. Phase 2 builds an online bidding portal wired directly into our own clerking system, cutting that lag and letting online bidders settle payments online too. We're also finishing what we started with AI-assisted clerking: perfecting Gemini's ability to listen to the chant in real time so remote bidders see the bid update as fast as someone standing in the barn.

Growth plan and market opportunity

We're live at one sale barn today, and treating it as our reference site, not our ceiling. The plan: use its results as proof, then using video and or invite other auction houses to compare SmartBarn AI to the legacy DOS- and Microsoft-based systems most still run on — using a questionnaire or traveling to their sales and customizing the system the way we did for our first barn. There are roughly 1,600 active sale barns in the U.S. running on that same paper-and-legacy-software workflow — a large, underserved market for a system already proven live.

We also see an adjacent opportunity in local slaughterhouses and small meat processing plants with small teams still largely using paper. We want to extend the same mobile-first, AI-assisted approach to them as we grow.

Built With

Share this project:

Updates