Meai
A smart-kitchen platform where the AI is useful because it is constrained: food-recall matching that never says “safe,” dietary filters written in code rather than prompts, and vision that asks before it acts.
Swap the nouns and this is your compliance problem: “never claim safe” is “never auto-approve,” the deterministic filter is your policy engine, the confidence gate is your human-review queue. Meai demonstrates that AI systems can be built where the dangerous simplification is structurally impossible.
Most AI products fail safely: a wrong answer wastes a minute. Meai lives where that is not true. It matches a household's food against government recall feeds, filters recipes for people with dietary restrictions, and logs food from photos — and in each, the dangerous failure is a plausible one: a reassuring “no recalls found,” a recipe that is almost vegetarian, an inventory that silently edited itself. The engineering that matters is the cage.
Photograph groceries and vision proposes what it saw. Below a confidence threshold it asks instead of assuming, and nothing enters or leaves the inventory without explicit user confirmation.
The model generates from what the pantry holds; a deterministic, versioned server-side filter checks every recipe before it reaches the user. The prompt is an optimization; the code is the guarantee.
Government recall feeds sync on their own cadences and are fuzzy-matched against the pantry across brand, product text, and purchase window. Matches surface as possible matches for the user to review — the system is structurally incapable of declaring food safe.
Stack: TypeScript monorepo — typed API over a relational store, shared invariants package used by every app, provider-agnostic vision and generation interfaces, scheduled per-source recall sync.
The claim is unrepresentable in the UI, in field names, and in API responses alike. A recall candidate must clear a 0.40 brand-similarity gate, then a 0.70 composite score that weighs brand at 0.50, product text at 0.35, and purchase window at 0.15 — and even then it surfaces only as a possible match for the user to review. Absence of a match renders as “no matches in our data,” never as reassurance. The optional AI adjudicator can sort matches by plausibility but can never clear one.
The dietary filter is an explicit, versioned list with token-boundary matching (so “collard” never trips on “lard”), an allowlist that wins first, and a hard cap of 2 regeneration attempts. After that, the recipe is discarded, the rejection is logged to improve the list, and the UI is told exactly why there are fewer results. The model never gets unlimited retries at the filter.
Vision output below threshold becomes a question, not a write. Inventory changes only through explicit user action — including in response to a recall. Every review of this codebase asks the same four questions, starting with: can any code path claim an item is safe?
A full working platform — inventory, vision logging, recipe generation, recall sync and matching — with the invariants enforced in a shared package every app imports. Built and operated by us.
This discipline applied to your domain: the invariants workshop first — what must never happen — then a system where those constraints live in code and schema, not in a prompt and a hope.