Data Processing
Query Expansion
Rewrite a conversational query into several dense, keyword-optimized search queries for more precise document retrieval
Category: Data Processing · Plans: Trial, Starter, Pro, Premium, Enterprise · Type: QueryExpansion · Beta
Inputs#
| Field | Type | Required | Default | What it does |
|---|---|---|---|---|
| Input | Text | No | {input} | The conversational query to expand. Use {input} for connected step output. |
| Model | Choice | No | gpt-4.1-mini | LLM used to rewrite the query into dense search queries Options: default, flowhunt-recommended, flowhunt-cheapest, flowhunt-smartest, gpt-4o-mini, gpt-4.1, gpt-5, gpt-5-mini, gpt-5-nano, gpt-5.2, gpt-5.4, gpt-5.4-mini and 59 more |
| Number of Queries | Number | No | 3 | How many search queries to generate |
| System Prompt | Text | No | You are a search query optimizer for a vector-search … | System prompt override for the query-expansion LLM call (Advanced) |
Outputs#
| Output | Type |
|---|---|
| Queries | List |
| Original Query | Text |
Use as an agent tool#
Tool name: query_expansion
Rewrite a conversational or messy user query into several dense, keyword-optimized search queries for more precise vector-based document retrieval. Use before calling a document retriever when the user message is conversational, contains filler, or mixes multiple intents.