Skip to main content
Give your agents access to documents for retrieval-augmented generation. TurnCall supports three retrieval modes so you can choose the right strategy for your use case.

Retrieval Modes

Setup

1

Create a knowledge base

2

Upload a document

Supported file types: PDF, TXT, Markdown, DOCX, CSV, JSON, YAML, XML, TSV. Max 10 MB.
3

Link to an agent

Choose the retrieval mode that fits your content:
On a speech-to-speech agent (pipeline_mode: "s2s") prompt and tool mode work and auto does not: the agent read warns about it. See Speech-to-speech.

Inline agents

An inline agent — a call-init response that answers agent instead of agent_id, or an eval inline target — has no agent to link a knowledge base to. It names its own in knowledge_bases, with the same fields as a link:
Each id is checked against the call’s project. A knowledge base from another project, or one that does not exist, is skipped with a warning, and the call still connects. A stored agent cannot carry the field: creating or updating one with it is a 422, because its links are the one place its knowledge bases live. Debug your knowledge base by running a test search:

Configuration

Knowledge Base Settings

Architecture

Requires PostgreSQL with the pgvector extension: CREATE EXTENSION IF NOT EXISTS vector;