LLMQueryExpansion
Models & Types ยท AiDotNet.RetrievalAugmentedGeneration.QueryExpansion
LLM-based query expansion: rewrites a query into several alternative phrasings that capture the same information need. When a real text generator is supplied the variations are produced by the LLM; otherwise a deterministic template set is used as an offline fallback.
Inheritance: QueryExpansionBase โ LLMQueryExpansion
Constructors
| Constructor | Summary |
|---|---|
LLMQueryExpansion(string llmEndpoint, string apiKey, int numExpansions, ITextGenerator generator) |
Initializes a new instance of the LLMQueryExpansion class. |
Methods
| Method | Summary |
|---|---|
List<string> ExpandQuery(string query) |
Expands a query using LLM-generated variations. |