Traditional RAG systems simply retrieve relevant documents and generate answers based on those documents. Agentset’s Agentic RAG approach takes this further:
Query Planning: The agent analyzes the user query and determines what information is needed
Strategic Retrieval: Instead of a single retrieval step, the agent can make multiple targeted retrievals
Answer Synthesis: The agent combines information from multiple sources to create a comprehensive answer
Citation Generation: Sources are accurately cited so users can verify information
Self-Verification: The agent checks its answer against source documents for accuracy
Query: “How did our Q1 sales in Europe compare to Q4 last year, and what factors contributed to the change?”Traditional RAG:
Would try to find documents that specifically mention both Q1 Europe sales and Q4 sales. If such a direct comparison doesn’t exist in the documents, the answer will be incomplete or inaccurate.Agentic RAG:
Plans to first find Q1 Europe sales data
Then separately retrieves Q4 sales data
Performs a comparison calculation
Searches for factors that may have influenced the change
Synthesizes a comprehensive answer with all supporting evidence
Reasoning Example
Query: “Based on our financial reports, should we increase investment in our Asia-Pacific division?”Traditional RAG:
Might retrieve documents about Asia-Pacific performance, but would struggle to make a reasoned recommendation based on financial principles.Agentic RAG:
Retrieves relevant financial data about Asia-Pacific division
Identifies key performance metrics
Compares with other divisions and industry benchmarks
Considers growth trends and market conditions
Provides a reasoned recommendation with supporting evidence
You can customize the agentic RAG approach when creating a namespace or during chat:
Copy
// Configure when creating a namespaceconst namespace = await agentset.namespaces.create({ name: "Financial Reports", description: "Contains financial reports and analysis", options: { // Configure retrieval behavior retrieval: { // Number of documents to retrieve in each step docsPerRetrieval: 5, // Maximum number of retrieval steps maxRetrievalSteps: 3, }, // Configure reasoning behavior reasoning: { // Whether to enable multi-step reasoning enableMultiStep: true, // Whether to verify answers against sources verifyAnswers: true, } }});// Or configure during chatconst response = await agentset.chat({ namespaceId: namespace.id, messages: [{ role: "user", content: "Analyze our Q1 performance" }], options: { agentic: { // Whether to enable agentic RAG features enabled: true, // Maximum time to spend on deep research maxProcessingTime: 60, // seconds } }});
Assistant
Responses are generated using AI and may contain mistakes.