DoorDash engineers described a new way to give large language models (LLMs) fresh facts without locking retrieval inside one vendor's API. They call it Decoupled Search Grounding, or DSG.
In plain words, grounding means giving an AI model evidence from catalogs or the web so it does not guess. DoorDash's query intent understanding (QIU) system uses that evidence to interpret messy marketplace searches. In the team's QIU evaluation, DSG matched or slightly beat native-search accuracy while cutting search costs by more than 98%.
Why a short search like “450 north” needs grounding
Marketplace queries are often short and unclear. DoorDash shared a QIU case study for “450 north.” Without grounding, the model treated it as a restaurant. Catalog evidence plus web search pointed to a craft brewery, and the system resolved the intent to Alcohol. That choice sends later retrieval toward the right inventory instead of restaurant results.
Native search made grounding easy to turn on, but DoorDash says it kept retrieval decisions inside the model provider's API. The company needed to pick search providers, reuse evidence across apps, tune how much evidence to fetch, and measure search cost and latency apart from the reasoning model.
Simple idea: let one team improve search infrastructure without rewriting every agent, and let another team change the reasoning model without rebuilding search.
The three problems DSG tries to fix
DoorDash frames native search as one opaque request: the provider runs its own search stack and folds results into generation. That can work for a chat window. It is harder when the model call is only one step in a larger pipeline.
- ControlThere is no clean seam between the model that reasons and the backend that finds evidence. Changing models or reacting to price changes means touching the model integration.
- ReuseTwo agents asking the same question can pay for two searches. There is nowhere shared to intercept the query.
- Observability and contract safetyPer-query cost and latency stay hard to see, and turning search on can break strict output formats.
DSG puts control, reuse, and observability into one shared layer instead of rebuilding them inside every agent.
Search-induced verbosity: when answers get too chatty
Many DoorDash LLM calls are middle steps. Their output must be parsed as JSON, matched to a fixed list of values, or read as a simple yes/no. Prompts often say: give only the final answer, with no explanation.
Without search, models often obey. With native search on, DoorDash says they often do not. In one comparison, native search returned a long answer that began with “Based on the search results…” DSG returned three characters: “Yes.” Both answers were correct; only one was easy to parse.
On HotpotQA, Claude Sonnet 4's native-search answers broke an explicit “answer only” rule 78.1% of the time by opening with explanatory framing. DoorDash says it did not see the same pattern with DSG, where evidence comes back as a structured tool response instead of mixing into the generation stream.
How the DSG architecture works
DSG sits between agents, the reasoning model, and a registry of search backends. DoorDash lists providers such as Serper, BrightData, Firecrawl, Exa, and Tavily. Native search can also register as one more provider behind the same interface.
The gateway is compatible with the Model Context Protocol (MCP), an open standard for connecting AI apps to tools and data sources. Agents get one shared interface. The gateway can reuse exact or semantic cache hits, fall back across providers, and return normalized, source-aware results so no agent hard-codes a search integration.
What that split unlocks
- The reasoning model stays swappable; grounding policy does not move when the model does.
- Provider choice, fallback order, cache policy, and retrieval depth become configuration, not one-off code.
- One platform team can tune grounding for every agent at once.
- Cache warmth compounds across workloads instead of resetting per agent.
What happens on one search request
DoorDash describes a request lifecycle that prefers cached evidence before calling a live provider:
- Normalize the queryTrivial phrasing differences can share one cache entry.
- Check the exact cacheA hit returns immediately with no provider call.
- Check the semantic cacheReuse a prior result if its embedding is similar enough.
- Walk the provider fallback chainOnly on cache misses. Timeouts and errors move to the next provider.
- Normalize the responseShared title, URL, and snippet schema for every provider.
- Write both cachesScoped per provider, with time-to-live tuned to how quickly the answer goes stale.
- Return a structured tool responseHelps protect the output contract that native search can blur.
Every step emits telemetry such as branch taken, provider, latency, and cost. DoorDash says that visibility turned search spend into something the team can measure on a dashboard.
Source-aware results and YAML providers
Different search APIs return different shapes. DSG normalizes them into title, source URL, and content snippet. That gives the model clear provenance and gives the platform an inspectable artifact for logging, debugging, and source filtering.
New HTTP providers can onboard through a YAML adapter covering endpoint, request template, response mapping, and cost metadata—without application code changes. If one provider fails, the configured fallback chain keeps grounding available.
Cache note: a high hit rate does not have to mean stale answers. Entries are scoped per provider and carry their own time-to-live—short for fast-changing facts, longer for stable ones.
The results: accuracy held, search bills fell
DoorDash evaluated DSG against native search across five frontier models—GPT-4o, GPT-4o-mini, Gemini 2.5 Flash, Gemini 2.5 Pro, and Claude Sonnet 4—plus public QA benchmarks and the production QIU workload.
On public benchmarks, DoorDash reports DSG configurations around 83% to 86% accuracy, near native search's about 87.7%, at roughly 10 to 30 times lower cost. DSG with BrightData landed within about 1.6 accuracy points of native search at roughly 11 times lower cost. DSG with Serper, described as the cheapest setup that still clearly beat no search, cost under 70 cents per 1,000 queries.
On FreshQA, which focuses on recency-sensitive questions, native search outperformed DSG across all five models. DoorDash's conclusion is not that grounding should always be decoupled. It is that the backend should be a routing decision, with native search kept as one option behind the same interface.
Production QIU numbers
For query intent understanding, DoorDash tested 7,988 general non-food retail queries and 2,335 synthetic long-tail queries. Accuracy measures the final resolved intent. With Gemini Flash as the reasoning model, reported search-provider costs (excluding model inference) looked like this:
- Retail: DSG+Serper reached 93.90% accuracy at $0.110 per 1K queries, versus native search at 93.40% / $7.90.
- Tail: DSG reached 87.79% at $0.146 per 1K, versus native at 87.62% / $10.37.
Across those sets, DSG matched or slightly exceeded native accuracy while reducing search costs by more than 98%. The native baseline was Gemini Flash with integrated Google search grounding.
Warm cache effect
With a warm cache, DoorDash reports a 99.4% hit rate, average latency down about 68% (from 4,570 ms cold to 1,465 ms warm), and search cost per 1,000 queries falling from about $0.7385 to about $0.0045. Because the cache is shared, it warms faster as more workloads use the gateway.
Retrieval depth as a dial
Decoupling also turns retrieval depth into a tunable parameter. Across three models on SimpleQA, raising depth from 2 to 6 results lifted average accuracy from 78.7% to 84.9%. Going further to 10 results added only about 0.6 points more. That gives DoorDash an evidence-backed default and a way to trade depth for latency or cost.
Native search vs DSG, in one glance
DoorDash does not claim native search is worse. It sits at a different point on the trade-off curve: strong accuracy, especially for freshness-sensitive queries, but with retrieval decisions bundled into the model provider. DSG aims for near-parity accuracy while making cost, caching, latency, provider choice, and output reliability controllable per workload.
Limitations and next steps
The team is clear about what DSG does not solve yet:
- It depends on third-party vendors for stability, latency, and data quality; pricing can shift the measured trade-off.
- Multi-hop reasoning benefits less than single-hop lookup; HotpotQA gains were modest for either search style.
- Search-induced verbosity is reduced by the structured tool boundary, not fully eliminated.
Planned follow-ups include adaptive routing that learns depth and provider per query, contract-aware output validation, and iterative retrieval for multi-hop workloads.
What It Means for Developers
The DoorDash write-up is a production architecture lesson: treat evidence retrieval as a platform interface, not a hidden side effect of one model API.
What It Means for Backend Developers
Backend engineers who call LLMs as pipeline steps care about parseable outputs and stable contracts. DSG's structured tool response is a reminder that search evidence and final answers should not always share the same text stream.
- Keep intermediate model outputs machine-readable with clear schemas, especially JSON enums and Booleans.
- Put shared search behind a gateway instead of embedding provider SDKs in every service.
- Log provider, cache hit/miss, latency, and cost on every retrieval call.
- If you build APIs with Node.js or Express, treat search as a dependency with timeouts and fallbacks, just like any other remote service.
What It Means for Full-Stack Developers
Full-stack teams often ship chat or search UIs that need both a smart answer and a reliable format for the rest of the app. Decoupling grounding helps keep the UI responsive while the platform tunes retrieval.
- Design product flows around tool-returned evidence, then a short model decision.
- Reuse cached answers across features that ask similar questions.
- Expose source titles and URLs when users need trust and provenance.
What It Means for DevOps Engineers
DSG turns search into something you can operate: cache hit rates, provider health, fallback behavior, and spend dashboards.
- Track warm-cache hit rate and cost per 1,000 queries as first-class SLIs.
- Configure provider fallback so one outage does not remove grounding for every agent.
- Tune TTL by query class so freshness-sensitive traffic does not inherit long-lived cache entries.
- Keep network and access controls tight around outbound search providers, using patterns similar to AWS security groups when services run in the cloud.
What It Means for Software Developers
The broader engineering lesson is portable: reasoning models and evidence retrieval evolve at different speeds. Separating them lets teams improve either side independently and choose quality, freshness, latency, and cost per workload.
- Prefer an explicit grounding interface over a hidden vendor default.
- Benchmark accuracy and cost together; cheap search that breaks parse contracts is not a win.
- Keep native search available when freshness matters more than control.
- Learn how open tool interfaces such as MCP architecture can standardize those seams across agents.
What to watch next
A few practical checkpoints stand out from DoorDash's write-up:
- Adaptive routingLearning depth and provider per query could push cost and accuracy further.
- Contract validatorsGateway-level checks can catch chatty or off-format answers before they break pipelines.
- Multi-hop retrievalIterative loops may matter more than one-shot search for hard reasoning tasks.
Bottom line
DoorDash's Decoupled Search Grounding architecture separates LLM reasoning from search evidence. On the company's query intent workload, that separation preserved accuracy while cutting search-provider costs by more than 98%, with shared caching, provider fallback, and structured tool responses doing much of the work.
For developers, the lasting lesson is architectural: make grounding an explicit, measurable interface. Keep the model swappable, keep retrieval tunable, and choose native search only when a workload truly needs that trade-off.

