Work / Case study 002
Market Day
Who’s at the market this weekend.
- 614vendors tagged across 9 markets
- 109vendors matched across markets
- 2¢to tag every vendor from scratch (517 calls, with prompt caching)
01 — The problem
To find out whether the crab cake stand is at Olney this Sunday, you read the market’s weekly newsletter, somewhere between the band announcement and the Pokémon card trader.
02 — The messy data
“PLUS, RUCHA'S KITCHEN MAKES ITS DEBUT … FARMERS MacBride & Gill Falcon Ridge Farm Pleitez Produce Leedstown Farm … Spring Hollow (now every Sunday) … And in a category of his own: Daryl Witt....trade or buy Pokemon or Sports cards! … TAKING A BREAK: Flash Crab Cakes and Tucker's Predatory Plants are due back in a week.”
Olney Farmers Market newsletter, Oct 15, 2026
Olney · Sunday, Oct 18
On the list, with the newsletter’s notes
- Rucha’s Kitchen: debut this week
- Daryl Witt: trade or buy Pokemon or Sports cards
From the newsletter
It's Olney Time takes place this Sunday with free samples, a raffle, and nonprofits showcasing their work. The Sandra Dean Band plays from 10 am.
A line-by-line parser found 27 names in that email. The newsletter reader found 29, including the two newcomers the parser missed.
03 — How it works
Sources
Five different vendor systems (FRESHFARM’s WordPress API, MarketSpread, Central Farm Markets’ vendor page, ManageMyMarket booth maps and Olney’s newsletter), plus county open data for 24 more markets on the map.
Every morning at 7, and Thursday and Friday evenings
GitHub Actions fetches each list and runs the tests.
Smart tagging, with checks
Tags each vendor from a fixed list of 13, reads the Olney newsletter, matches the same farm across markets and writes one highlight per market day. If it fails, a keyword tagger and the line parser take over.
Static site
On Cloudflare Pages.
04 — Decisions worth noting
Every tag has to show its work.
“Organic” and “pasture-raised” stick only if the vendor’s own description says so. Every name pulled from the newsletter has to appear in the email, and if the reader finds fewer than 80% of what the plain parser found, its whole answer is thrown out.
Matches only show when they’re near certain.
“Pleitez Produce” in Olney’s newsletter and “Pleitez Produce Farm” at Dupont and Mosaic match at 0.9 confidence, so all three listings now say “Also at…”. Anything under 0.8 goes to a review list, and two vendors at the same market are never matched.
Prompt caching keeps it cheap.
The instructions are frozen and cached, so on the first full run 97% of the input was cache reads: about 2¢ instead of about 11¢. After that, answers are cached by content and a normal day costs a fraction of a cent.
05 — What’s next
Filling in this winter’s closure dates in the scraper health check, so a skipped week doesn’t look like a broken source.