hi @Logan M
i tried using agent to rewrite the query from index engine but its not working, its passaing the original query only
agent_prompt = """
For each user input, you will:
1. Generate two search queries:
- The first query will be the original user input, unmodified.
- The second query will be a rephrased or expanded version of the original, aimed at capturing additional relevant information.
2. Use both queries to gather information and formulate your response.
3. Provide a comprehensive answer based on the combined results of both queries.
Remember to tailor your responses to the context of mortgage business and loan application management.
Input: {query}
Please process the input according to the steps above and provide your response.
"""
query_engine_tools = [
QueryEngineTool(
query_engine=mloflo_engine,
metadata=ToolMetadata(
name="tool-name",
description=(
"Provides information about ..., Use this to address user queries"
"Use a detailed plain text question as input to the tool."
),
),
)
]
from llama_index.agent.openai import OpenAIAgent
agent = OpenAIAgent.from_tools(query_engine_tools, verbose=True, system_propmt=agent_prompt)
it running the toll only once with the same query as input