Mise · Engineering Kickoff · July 2026

System Structure & Build Path

Companion to EDITH_STARTER_BRIEF.md. Top: the full structure and its two clocks. Bottom: the pathway — what gets built, in what order, and the proof gate for each move.

Hot path — live request, milliseconds, touches our store only Cold path — scheduled copy, nightly/weekly, the only thing that ever touches a client DB Proof gate — objective exit test before the next move

01The Picture — ten-second version

ChefTec client DBs — 350 hosted · one blueprint 127 on-prem out of reach — by design READ-ONLY WALL · ONE-WAY COPY Translator copy → stage → merge → canonical catalog P3 nightly / weekly KNOWLEDGE BASE Tenant store · private recipes · menu prices ask-once answers (kitchen memory) own purchase history Corpus · aggregate, anonymized canonical catalog + conversions price facts — location-tagged reference yields & each→weight BLEND WALL reads ENGINE · PORTED CHEFTEC MATH · DETERMINISTIC cost_recipe get_unit_cost conversions yield / waste margins simulate_batch match_ingredient save_answer corpus_price_lookup returns cost + ledger API — one surface · every answer carries the ledger MISE · THE RECIPE MANAGER — FIRST ROLE NEXT: Inventory Clerk · LATER: Steward React app renders the ledger Mise agent · LLM photos in · phrasing out Voice / SMS later — same API chef answers & uploads — memory grows cold — scheduled copy, the only thing that touches client DBs hot — live requests, our store only

02The Structure — detail per layer

Consumers — equal clients of one API

React app

Mobile-first web. Dumb renderer: draws the ledger, posts answers. No logic.

Mise agent LLM

Reads photos in (extract_recipe), phrases ledger out (questions, narration, Ask Mise). Decides nothing about money.

Voice / SMS / digest later

Same API, new skin. Zero engine changes required.

hot · request

API layer

One surface · every costing answer returns cost + ledger · apps call tools — raw reads never carry a dollar sign

hot · tool call

Engine — ported math, our code (Delphi logic, Python body)

Deterministic tools no LLM inside

Every dollar figure comes from a unit-tested function, verified against 35 years of ChefTec's own cached answers.

cost_recipe → cost + ledger get_unit_cost match_ingredient unit conversions yield / waste margin_report simulate_batch generate_questions save_answer corpus_price_lookup
hot · reads

Knowledge — two stores, one wall

Tenant store — private, scoped

  • Their recipes & menu prices
  • Ask-once answers (kitchen memory)
  • Their own purchase history

Corpus — aggregate, anonymized

  • Canonical ingredient catalog + conversions
  • Price facts, site- & location-tagged
  • Reference yields · each→weight ranges

blend wall · recipes never enter the corpus · kitchens anonymized, vendors exposed

price ladder 1 own history 2 own answers 3 corpus range, recency-filtered 4 no price → ledger error → ask the chef
cold · merge lands here

Supply line — the only crossing, one-way, on a timer

Client ChefTec DBs

350 hosted on CSS servers · one shared blueprint · plus internal CSS DB & dump site

read-only

Raw staging

Rows copied as-is, tagged by site + date. Extractor does zero math.

Merge / canonicalize

Fuzzy match onto the canonical catalog · human-review queue for the uncertain tail · re-runnable forever against stored raw.

Cold clock: scheduled per site (nightly/weekly). No product request ever crosses the wall — copy raw once per cycle, recompute derived views for free.

Out of reach by design: 127 on-prem customers (their machines, not ours). The corpus is the 350 hosted sites — 241 actively invoicing.

03The Pathway

Order is dependency, not preference: each phase produces the proof the next one stands on. Phases 1–2 have zero blockers. The gate that matters most is the diff — the day the new engine reproduces ChefTec's own cached numbers on a real customer's book, everything above it becomes trustworthy.

P1▲ you are here

Skeleton

Edith builds: spine
  • Django + Postgres + pytest + CI.
  • Tenancy spine day one: Org → Location, every row scoped. Corpus = a system-owned tenant, not a special case.
  • Before first domain model: 90-min ledger-schema session with Vash. The ledger is engine output, UI data, and agent vocabulary — freeze it early.
Gate — CI green · ledger schema agreed.
P2

Port the costing chain

Edith builds: engine
  • In dependency order: units + conversions → catalog + yields → purchase facts → get_unit_cost → recursive recipe costing (sub-recipes, Q-factors, labor) → margins + batch view.
  • Fixture: the sample dump (Pricing.txt / Conversions.txt) — 954 priced items, real mess included.
  • Port legacy query filters verbatim: cost = line total, drop zero-qty rows, honor ignore-for-costing.
  • Emit the ledger from the first commit — never a bare number.
Gate — every formula spec-tested · dump costs recipes end-to-end.
P3

Translator + diff harness

Edith Mitch: .bak files blocked on 2 backups builds: supply line
  • Internal CSS DB first — zero-risk crash-test dummy. Learn the real schema, build the importer. Idempotent: re-import same site, nothing duplicates.
  • Client DB #1 (ideally the dump site) — real recipes, real invoices, and RecpCost: ChefTec's cached answer key.
  • Day one of client DB: run the cost-method distribution query — port the ~3 methods actually used, stub the rest.
  • Diff runs on legacy data as-is (1.0 yields, per-batch labor). It verifies the engine, not the data — yield seeding is a later, separate data layer.
The gate — clean diff vs. legacy cached costs, every mismatch category explained. This is the milestone worth announcing: the engine stops being claimed correct and becomes proven correct. Mismatch report = the data-cleanup worklist, free.
P4

Extraction spike

Edith Vash: 10 recipe photos via Jeff builds: agent edge
  • Timeboxed 2–3 days, runs parallel whenever. Photo → structured lines (qty, unit, ingredient text) on ~10 real photos.
  • De-risking only — results go to Vash and shape the Verify screen. Not the capture build; nothing merges to main.
Gate — measured line-level accuracy → Verify design proceeds on facts.

Then: the same pipeline at three scales

Mike: consent Mitch: export routine

Beta · ~13 sites

Pilot clients' books ported by the same importer. First real merge stress test — measure the human-review tail.

unlocks: greenfield cold-start (Jeff's kitchens)

Wave 2 · ~50 sites

Picked for geography + segment around the beta kitchens. Rerun coverage sim per batch; stop widening when the curve flattens.

unlocks: "prices near you" for real

Wave 3 · all 350

A loop and a scheduler around proven machinery. Administration, not engineering.

unlocks: the moat, aggregated

Two rules that override everything

  1. Money math never comes from a model. LLMs read photos in and phrase sentences out. Every dollar is a deterministic, tested function.
  2. The engine never returns a bare number. Cost + assumption ledger, always — the ledger is the contract that lets scoping churn above while the engine stays still below.