Skip to main content
A knowledge-centric workflow where RAG (Retrieval Augmented Generation) agents interact with vector databases to store and retrieve information efficiently, enabling sophisticated question-answering and information retrieval capabilities.

Quick Start

1

Install Package

Install PraisonAI Agents with knowledge support:
2

Set API Key

Set your OpenAI API key:
3

Create Script

Create a new file app.py:

Data Indexing and Retrieval Agents

Indexing and Ingestion are relatively the same.
The simplest way to create a knowledge-based agent is without any configuration:

Advanced Configuration

For more control over the knowledge base, you can specify a configuration:

Multi-Agent Knowledge System

For more complex scenarios, you can create a knowledge-based system with multiple agents:

Retrieval Agents

Retrieval is the process of querying the vector database for information. Considering there is data already in the Vector Database.
1

Install Package

First, install the PraisonAI Agents package:
2

Set API Key

Set your OpenAI API key as an environment variable in your terminal:
3

Create a file

Create a new file rag_agent.py with the basic setup:
4

Start Agents

Type this in your terminal to run your agents:
Requirements
  • Python 3.10 or higher
  • OpenAI API key. Generate OpenAI API key here. Use Other models using this guide.
  • ChromaDB or other supported vector database

Adding Knowledge to RAG Agents

Understanding RAG Agents

What are RAG Agents?

RAG (Retrieval Augmented Generation) agents enable:
  • Efficient knowledge retrieval
  • Semantic search capabilities
  • Persistent knowledge storage
  • Context-aware responses

Features

RAG Architecture

Store and manage vector embeddings efficiently.

Semantic Search

Find relevant information using semantic similarity.

Knowledge Integration

Seamlessly integrate with existing knowledge bases.

Context Management

Handle complex contextual queries and responses.

Troubleshooting

RAG Issues

If RAG system isn’t working:
  • Check database configuration
  • Verify connection settings
  • Enable verbose mode for debugging

Query Issues

If queries aren’t returning expected results:
  • Check embedding quality
  • Verify search parameters
  • Monitor similarity thresholds

Next Steps

AutoAgents

Learn about automatically created and managed AI agents

Mini Agents

Explore lightweight, focused AI agents
For optimal results, ensure your vector database is properly configured and indexed for your specific use case.