> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Auto RAG Agent • AI Agent SDK

> AutoRagAgent - Agent with automatic RAG retrieval decision.

# auto\_rag\_agent

<Badge color="blue">AI Agent</Badge>

AutoRagAgent - Agent with automatic RAG retrieval decision.

This module provides an agent wrapper that automatically decides when to
retrieve context from knowledge bases vs direct chat.

Usage:
from praisonaiagents import Agent, AutoRagAgent

agent = Agent(
name="Research Assistant",
knowledge=\["docs/manual.pdf"],
)

auto\_rag = AutoRagAgent(agent=agent)
result = auto\_rag.chat("What are the key findings?")  # Auto retrieves
result = auto\_rag.chat("Hello!")  # Skips retrieval

## Import

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
from praisonaiagents.agents import auto_rag_agent
```

## Classes

<CardGroup cols={2}>
  <Card title="RetrievalPolicy" icon="brackets-curly" href="../classes/RetrievalPolicy">
    Policy for when to perform RAG retrieval.
  </Card>

  <Card title="AutoRagConfig" icon="brackets-curly" href="../classes/AutoRagConfig">
    Configuration for AutoRagAgent.
  </Card>

  <Card title="AutoRagAgent" icon="brackets-curly" href="../classes/AutoRagAgent">
    Agent wrapper with automatic RAG retrieval decision.
  </Card>
</CardGroup>

***

## Related Documentation

<CardGroup cols={2}>
  <Card title="Agents Concept" icon="robot" href="/docs/concepts/agents" />

  <Card title="Single Agent Guide" icon="book-open" href="/docs/guides/single-agent" />

  <Card title="Multi-Agent Guide" icon="users" href="/docs/guides/multi-agent" />

  <Card title="Agent Configuration" icon="gear" href="/docs/configuration/agent-config" />

  <Card title="Auto Agents" icon="wand-magic-sparkles" href="/docs/features/autoagents" />
</CardGroup>
