What is query expansion in web search?
Query expansion rewrites or multiplies a search query into several variants: synonyms, related terms, or decomposed sub-questions. A single query often misses relevant pages because different sources use different vocabulary for the same concept. Expanding the query improves recall without changing the underlying intent. This matters most in LLM pipelines, where a narrow query may return too few sources for the model to reason from accurately.
| Technique | How it works | Best for |
|---|---|---|
| Synonym expansion | Substitutes alternative terms for key words | Queries with domain-specific jargon |
| Intent decomposition | Splits a complex question into sub-queries | Multi-part research questions |
| Query broadening | Removes overly specific constraints | When narrow queries return zero results |
| Multi-query parallel search | Runs several reformulations simultaneously | High-recall agent research pipelines |
Query expansion is most valuable in agentic research pipelines. A single query rarely surfaces all relevant sources on a complex topic. Running three to five reformulations in parallel increases coverage without adding latency. The results can then be deduplicated and ranked before being passed to the LLM. Expansion also reduces the risk of the agent drawing conclusions from an incomplete evidence set.
Firecrawl's Search API returns full page markdown per result, so each expanded query yields content the agent can reason from directly. For fully autonomous workflows, the agent endpoint handles query expansion, search, and extraction in one step, without requiring manual reformulation logic.
data from the web