Quick Start
1
Simple Usage
Point the agent at a folder of documents and it answers from them.
2
With Configuration
Tune how many passages come back and how similar they must be.
How It Works
Related
Knowledge Base Setup
Create and configure knowledge bases
Chunking Strategies
Optimize document chunking
Retrieval Methods
Configure retrieval strategies
Best Practices
Start with a folder of clean sources
Start with a folder of clean sources
KnowledgeConfig(sources=["./docs"]) indexes a directory directly. Remove boilerplate and duplicates first so retrieval returns signal, not noise.Raise the similarity threshold to cut noise
Raise the similarity threshold to cut noise
A higher
similarity_threshold filters weak matches. Start at 0.7 and adjust based on whether answers miss context or cite irrelevant passages.Keep top_k small for focused answers
Keep top_k small for focused answers
Fewer, stronger passages usually beat many weak ones. Increase
top_k only when answers lack coverage.
