Building a Guardrail System for LLM-based Menu Transcription
doordash · E-commerce · 2025 · source Agentic: no · promotional bias: low · source-backed · extracted with prompt 0.5.4 (schema v2)
Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.
Problem
Domain: Restaurant menu transcription automation
DoorDash wanted to automate restaurant menu-photo transcription into structured menu data without sacrificing the high accuracy required for partner menus and consumer ordering.
Constraints:
- manual menu transcription was costly and time-consuming
- restaurants use diverse and inconsistent menu structures
- poor photo quality, incomplete menus, and confusing OCR order cause LLM transcription errors
- the system needed high accuracy before automation could replace human work
- new multimodal models were evolving quickly and the pipeline needed to adapt
Architecture
DoorDash first built an OCR plus LLM transcription MVP that extracts menu text and summarizes it into structured data. Because the LLM alone could not meet quality requirements, they added a traditional ML guardrail model that predicts whether each LLM transcription is accurate enough to automate. Photos that pass the threshold flow automatically; failures route to the human transcription process. The guardrail framework later supported multimodal GenAI transcription models as well.
Diagram confidence: explicit (topology described by the source).
flowchart LR menu-photo-intake[Menu photo intake] --> ocr-extractor[OCR extractor] menu-photo-intake --> multimodal-transcription-model[Multimodal transcription model] ocr-extractor --> llm-transcription-model[LLM transcription model] ocr-extractor --> guardrail-feature-generator[Guardrail feature generator] llm-transcription-model --> guardrail-feature-generator multimodal-transcription-model --> guardrail-feature-generator guardrail-feature-generator --> guardrail-model[Guardrail model] guardrail-model --> automatic-transcription-path[Automatic transcription path] guardrail-model --> human-transcription-process[Human transcription process]
Components
| Component | Role | Interacts with |
|---|---|---|
Menu photo intake |
Restaurant menu photos submitted for transcription and validation. | OCR extractor, Multimodal transcription model |
OCR extractor |
Extracts raw text from menu images for the OCR plus LLM pipeline. | Menu photo intake, LLM transcription model, Guardrail feature generator |
LLM transcription model |
Summarizes OCR text into structured item-level menu data. | OCR extractor, Guardrail feature generator |
Multimodal transcription model |
Alternative GenAI model path that processes menu photos with stronger context understanding but different failure modes. | Menu photo intake, Guardrail feature generator |
Guardrail feature generator |
Builds features from the menu photo, OCR output, and LLM summarization quality signals. | OCR extractor, LLM transcription model, Multimodal transcription model, Guardrail model |
Guardrail model |
Traditional ML classifier that predicts whether transcription accuracy is high enough for automation. | Guardrail feature generator, Automatic transcription path, Human transcription process |
Automatic transcription path |
Publishes structured transcribed menu data for photos that pass the accuracy threshold. | Guardrail model |
Human transcription process |
Fallback path for menus whose predicted transcription quality does not meet the threshold. | Guardrail model |
Data flow
A menu photo is validated and sent through OCR/LLM or multimodal transcription. The system generates features about the photo, OCR output, and LLM summarization. A guardrail model scores whether the transcription meets the accuracy threshold. Passing transcriptions become available automatically; failing menu photos go to the human process.
3 supporting quotes
Why this architecture
DoorDash used a guardrail model because standalone LLM transcription could not meet the required accuracy on messy menus. A lightweight traditional ML classifier was cheaper and lower-latency than repeatedly improving the LLM before production, and it let DoorDash adopt new LLM or multimodal models while preserving a quality gate.
3 supporting quotes
Models used: LLMs · LightGBM · ResNet · Vision Transformers · multimodality models
Scale
- The system targets restaurant partners' menu-photo update workflow.“To ensure accuracy and alignment with their latest offerings, DoorDash’s restaurant partners must actively maintain their menus. This can be challenging, however, for business owners who already are managing demanding daily operations.”article, stated
- DoorDash evaluated a large number of menu photos with humans to find error patterns.“Through human evaluation of a large number of menu photos, a reasonable proportion of menus can be transcribed with various errors”article, stated
- The first guardrail model was followed by six months of rapid GenAI model evolution.“During the six months following the development of our first guardrail model, there was rapid evolution in the generative AI world”article, stated
Alternatives considered (roads not taken)
Manual menu transcription only
Rejected because: Manual work was costly and time-consuming for restaurant menu updates.
Standalone LLM transcription
Rejected because: LLMs lacked menu-structure familiarity and could not reliably handle complicated scenarios at required accuracy.
Complex neural guardrail architectures
Rejected because: LightGBM outperformed the neural models and ran fastest, partly because labeled data was limited.
Use multimodal models without guardrails
Rejected because: Multimodal models had better context understanding but higher failure rates on bad-quality photos.
Patterns
guardrails-io-filtering (safety)
A traditional ML guardrail predicts whether an LLM menu transcription is accurate enough to use automatically.
confidence-thresholding (routing)
Transcriptions that pass the auditing threshold proceed automatically; others route to human work.
human-in-the-loop-gate (workflow)
Human transcription remains the fallback for low-confidence menu-photo cases.
fallback-degradation (reliability)
The pipeline degrades from automated transcription to human transcription when the model predicts quality risk.
fine-tuning-adaptation (modeling)
DoorDash identifies fine-tuning custom LLM/multimodal models on manually transcribed data as the next improvement path.
Tradeoffs
Add a traditional ML guardrail
Chose LightGBM-based quality prediction before automation over waiting for the LLM to become accurate enough alone.
Rationale: The guardrail let DoorDash realize automation value sooner while maintaining quality.
Use partial automation
Chose automatic path only for threshold-passing photos over fully automatic transcription for every menu photo.
Rationale: Routing low-confidence cases to humans improved efficiency without sacrificing quality.
Retain the guardrail across model generations
Chose a model-agnostic quality gate over hard-coding the pipeline to one transcription model.
Rationale: The guardrail let DoorDash quickly adopt newly released AI models while balancing their failure modes.
Gotchas (what bit them)
LLM transcription errors clustered around messy menu photos.
Root cause: Inconsistent menu structure, incomplete menus, and poor photo quality confuse OCR and LLM summarization.
Resolution: Generate guardrail features from the photo, OCR output, and summarization quality signals.
Complex vision models did not beat a simpler guardrail.
Root cause: Limited labeled data made it hard to exploit more complex neural designs.
Resolution: Use LightGBM for the guardrail because it performed best and ran fastest.
New multimodal models changed tradeoffs but did not eliminate quality risk.
Root cause: Multimodal models improved context understanding but failed more on bad-quality photos.
Resolution: Keep the guardrail framework so new models can be tested and routed safely.
Evaluation
DoorDash evaluated menu transcription through human assessment of menu photos, guardrail model accuracy prediction, and comparisons of LightGBM, ResNet, ViT, OCR+LLM, and multimodal model tradeoffs.
Metrics: average transcription accuracy across test menu photos · percentage of transcriptions meeting accuracy requirements · guardrail model runtime · automation ratio while preserving quality
Outcomes
- DoorDash moved from manual-only transcription to a partial automation pipeline
- LightGBM was selected as the best-performing and fastest guardrail model
- the guardrail framework let the team test OCR+LLM and multimodal transcription models while preserving quality routing
- low-confidence menus still route to humans
The source does not publish the exact automation percentage, but it describes restaurant-partner menu updates and a rising automation ratio under guardrail control.