🔍 RAG (Retrieval-Augmented Generation)
Purpose: Enhances LLMs by retrieving relevant documents from a knowledge base to ground answers in factual content.
Components:
- A vector database or retrieval tool (e.g., OpenSearch).
- Embedding model to convert documents and queries into vectors.
- A language model (like Amazon Titan, Anthropic Claude, or Meta LLaMA) to generate answers based on retrieved documents.
Typical Use Case: Answering user questions by pulling and summarizing information from a static or dynamic document store.
🤖 Agent (Autonomous LLM Agent)
Purpose: Performs multi-step reasoning and can autonomously execute tools or APIs to achieve a task.
Components:
- A planner or orchestrator that can decide what action to take.
- Tool usage (e.g., calling APIs, database queries, invoking functions).
- Often reactive to changing context and capable of handling open-ended workflows.
Typical Use Case: Completing tasks like “Book me a flight” or “Analyze this sales report and generate a presentation” by choosing from available tools.
📽️ Watch the video on how to Set Up a RAG Chatbot in Bedrock? HERE: https://www.youtube.com/watch?v=Munrg_qYW-E
Feature RAG Agent
Retrieves documents ✅ 🔸 (sometimes)
Uses vector store ✅ ❌
Executes tools/APIs ❌ ✅
Multi-step reasoning ❌ ✅
Dynamic decision making ❌ ✅