Build-Time AI: How We Validate 5,000 Prices Across 8 Languages Without a Server
The problem We run a transport booking site in Morocco — navetteforyou.com . Eight languages, 641 pages, thousands of prices. One wrong number and a customer books a ride expecting 300 MAD when it costs 600. Manual QA across 5,000+ price points in eight languages is not viable. So we built an AI-assisted build-time validation pipeline. The pipeline Every deployment runs three checks before it…
Morocco's transport booking site, navetteforyou.com, validates 5,000 prices in eight languages without using a server. Manual QA is unfeasible, so an AI-assisted build-time validation pipeline was developed. This pipeline operates during each deployment with three checks: extracting prices, enforcing minimum prices, and ensuring cross-language price consistency.
The TypeScript script crawls HTML pages and extracts numbers followed by MAD, €, or other currency markers, as well as structured data like JSON-LD offers. Prices are compared against a floor price, and if any drop below the minimum, the build fails. Prices are also checked for consistency across languages, flagging any mismatches as warnings.
The AI component includes translation draft generation, structured data generation, and price check script validation using pattern matching. Since deploying, there have been zero pricing errors in production, with the build time added being only about 4 seconds, and no false positives. This demonstrates that AI in production does not necessarily mean chatbots or recommendation engines, but rather can be a simple script that runs at build time to catch errors that could result in lost customers.
Navetteforyou.com offers private airport transfers and day trips across Morocco, and can be contacted via WhatsApp at +212 701 664 704.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.