Getting Started
| Example | Description |
|---|---|
| Basic RAG | Context injection, the simplest way to give an agent access to documents. |
| Agentic RAG | The agent gets a search_knowledge_base tool and decides when to query. |
| Loading Content | Load from local files, URLs, raw text, topics, and batch operations. |
Building Blocks
| Example | Description |
|---|---|
| Chunking Strategies | Side-by-side comparison of document splitting strategies. |
| Search Types | Vector, keyword, and hybrid search compared. |
| Reranking | Rerank results to improve quality on complex queries. |
| Filtering | Narrow search results with document metadata. |
| Agentic Filtering | The agent builds metadata filters from the user query. |
| Embedders | Choose and configure embedding models. |
Production
| Example | Description |
|---|---|
| Multi-Source RAG | Combine PDFs, web pages, and text in one knowledge base. |
| Knowledge Lifecycle | Insert, update, remove, and track content with a contents database. |
| Multi-Tenant | Isolate per-tenant data with isolate_vector_search. |
| AgentOS | Serve agents and knowledge as API endpoints. |
| Error Handling | Ingestion patterns that survive bad files and failed loads. |
| SSRF Hardening | Restrict URL-fetching readers with allowed_hosts. |
Advanced
| Example | Description |
|---|---|
| Custom Retriever | Full control over retrieval logic, bypassing the Knowledge class. |
| Custom Chunking | Implement your own chunking strategy. |
| Graph RAG | Build a knowledge graph from documents with LightRAG. |
| Knowledge Tools | Think, search, and analyze tools for reasoning over knowledge. |
| Knowledge Protocol | Custom knowledge sources via the KnowledgeProtocol interface. |
| Prefix Search | Search-as-you-type matching on partial words. |
Integrations
Cloud
| Example | Description |
|---|---|
| AWS | Load files and folders from S3 buckets. |
| Azure | Load from Azure Blob Storage containers. |
| Azure (SAS Token) | Blob Storage access with SAS token authentication. |
| GCP | Load from Google Cloud Storage buckets. |
| SharePoint | Load from SharePoint document libraries. |
| GitHub Dynamic Repo | Override the source repository per request. |
| Multi-Source | Combine multiple remote sources in one Knowledge instance. |
RAG
| Example | Description |
|---|---|
| Agentic RAG with Infinity Reranker | Agentic RAG with an Infinity reranker backend. |
| Agentic RAG with LightRAG | Agentic RAG backed by LightRAG. |
| Local RAG with LangChain and Qdrant | Fully local RAG with LangChain and Qdrant. |
Readers
| Example | Description |
|---|---|
| Documents | PDF, DOCX, PPTX, and Excel with auto-detected readers. |
| Data | CSV, JSON, and field-labeled CSV readers. |
| Web | Website, YouTube, ArXiv, and Firecrawl readers. |
| Docling: PDF | PDF processing with different output formats. |
| Docling: Office Documents | Microsoft Office document processing. |
| Docling: Images | OCR for image files. |
| Docling: Audio | Speech-to-text transcription for audio files. |
| Docling: Markup | Markup and structured document formats. |
| Docling: Data Files | Spreadsheet and data file processing. |