rewrite
Method
This is a method of the QueryRewriterAgent class in the query_rewriter_agent module.Rewrite a query using the specified strategy. All operations go through an internal Agent which automatically handles tool calling when tools are provided. The agent decides when to use tools based on the query context.
Signature
Parameters
The original user query
Rewriting strategy to use
Previous conversation messages for contextual rewriting
Additional context about the knowledge base
Number of queries for multi-query strategy
Returns
RewriteResult containing rewritten queries

