Skip to main content

Overview

Knowledge Base integration allows your voice agent to access your company documents, FAQs, product manuals, and other information sources during conversations. Using RAG (Retrieval Augmented Generation), the agent automatically retrieves relevant information and incorporates it into responses. Best for:
  • Customer support with product documentation
  • Internal helpdesks with company policies
  • Technical support with manuals and guides
  • Any agent that needs accurate, up-to-date information

How It Works


Step 1: Create a Knowledge Base

Upload Documents

Knowledge Base — create form
  1. Go to Studio → Knowledge Base → Create New
  2. Fill in the details:
  1. Click Upload & Process
Supported file types: PDF, TXT, DOCX, MD, CSV Max file size: 50MB per file (actual limit may vary by deployment) Processing time: Typically 1-5 minutes depending on file size and system load Chunk defaults: 1000 characters with 200 character overlap (configurable)

Document Processing

After upload, your document is automatically:
  1. Chunked into smaller pieces based on your settings
  2. Embedded using vector embeddings
  3. Indexed for fast similarity search
  4. Status changes from processingready

Knowledge Base linked to agent
  1. Go to Agent Settings → Knowledge Base
  2. Click Link Knowledge Base
  3. Select from available knowledge bases
  4. Configure retrieval settings (see below)
  5. Click Link
Response:

Step 3: Configure Retrieval Settings

After linking, configure how the agent searches your knowledge base:

Chunks to Retrieve

Default: 5 chunks
Too many chunks can confuse the agent and increase response latency. Start with 5 and adjust based on testing.UI Range: The Studio UI allows 1-10 chunks. For values outside this range, use the API.

Similarity Threshold

Default: 0.7 (range: 0.0 - 1.0) How it works:
  • User question is converted to vector embedding
  • System searches for chunks with similarity score > threshold
  • Higher threshold = more precise but may miss relevant info
  • Lower threshold = more results but may include noise

Update Settings via API


Step 4: Update Agent System Prompt

Add instructions to use the knowledge base:

Multiple Knowledge Bases

You can link multiple knowledge bases to a single agent: Example Setup:
Search Behavior:
  • Agent searches all linked knowledge bases simultaneously
  • Results are ranked by similarity score across all sources
  • Top N chunks are retrieved (based on “chunks to retrieve” setting)

Via Studio

  1. Go to Agent Settings → Knowledge Base
  2. Find the linked knowledge base
  3. Click Unlink (trash icon)
  4. Confirm unlinking

Via API

Unlinking doesn’t delete the knowledge base — it just removes the connection. The KB can be linked to other agents or re-linked later.

Best Practices

Organize by Topic

Create separate knowledge bases for different topics (e.g., “Product Docs”, “HR Policies”, “Technical Guides”). This makes retrieval more accurate.

Keep Documents Updated

Regularly update your knowledge base with current information. Outdated docs lead to incorrect answers.

Use Clear Structure

Documents with clear headings, sections, and formatting chunk better than unstructured text.

Test Retrieval

After linking, test with real questions. Adjust chunks/threshold if answers are incomplete or irrelevant.

Start Conservative

Begin with 5 chunks and 0.7 threshold. Increase chunks if answers lack context, decrease if responses are too long.

Remove Duplicates

Duplicate information across KBs confuses retrieval. Keep each piece of info in one place.

Troubleshooting

Check:
  1. Is KB status ready (not processing)?
  2. Is KB actually linked to the agent?
  3. Does system prompt instruct agent to use KB?
  4. Are chunks being retrieved? (Check agent logs)
Fix: Add explicit instructions: “Always search the knowledge base before answering questions about [topic].”
Problem: Similarity threshold too low or chunks too large.Fix:
  • Increase threshold to 0.8 or 0.85
  • Reduce chunk size to 800 characters
  • Check if KB contains relevant content
Problem: Information not in KB or threshold too high.Fix:
  • Lower threshold to 0.6 or 0.65
  • Add the missing document to KB
  • Increase chunks to retrieve
Problem: Too many chunks retrieved.Fix:
  • Reduce chunks to retrieve (from 10 to 5, for example)
  • Add to prompt: “Keep responses concise — maximum 3 sentences”

API Reference

List Linked Knowledge Bases

Response:

List All Knowledge Bases


Next Steps

Create Knowledge Base

Upload your first document and start building your knowledge base.

Test Agent with KB

Test your agent with questions that require knowledge base lookup.

Custom Functions

Combine KB with custom functions for even more powerful agents.