Skip to content

How I bring my 'RAGStringQueryEngine' to Agentic RAG? #14291

Answered by dosubot bot
mraguth asked this question in Q&A
Discussion options

You must be logged in to vote

To incorporate your already indexed RAGStringQueryEngine into the agentic RAG framework, you can directly use your query_engine in place of the rag_query_engine in the provided code. Here is how you can do it:

  1. Ensure your query_engine is properly initialized and indexed.
  2. Replace the rag_query_engine assignment with your query_engine.
  3. Use this query_engine to create the QueryEngineTool.

Here is the modified code snippet:

from llama_index.core.tools import ToolMetadata, QueryEngineTool
from llama_index.core.agents import OpenAIAgent
from llama_index.core import Settings

# Assuming your RAGStringQueryEngine is already initialized and indexed
query_engine = RAGStringQueryEngine(
    retri…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@mraguth
Comment options

@dosubot
Comment options

Answer selected by mraguth
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant