src/pages/KnowledgeBases.tsx (list + create), src/pages/KnowledgeBaseDetail.tsx (documents), and the bot wizard step src/components/bot/StepKnowledge.tsx. API calls go through src/api/knowledge.ts.
List and create
At/dashboard/knowledge-bases the page lists KBs (listKnowledgeBases) as cards showing name, a status badge (active → success), description, and document_count / chunk_count. An inline form creates a KB (createKnowledgeBase with name, optional description, default_language: 'en'). Cards link to /dashboard/knowledge-bases/:id.
Document detail and status
The detail page (/dashboard/knowledge-bases/:id) loads the KB and its documents in parallel, and supports:
- Editable description — inline textarea (max 2000 chars), saved via
updateKnowledgeBase. - Upload — accepts
.docx, .pdf, .txt, .md, .csv(max 20MB); callsuploadKnowledgeDocument. - Delete — per document via
deleteKnowledgeDocument.
Parse status
Each document carries aparse_status rendered with a status class:
| Status | Meaning |
|---|---|
uploaded | received, not yet processed |
indexing | extracting text, chunking, embedding |
indexed | ready for retrieval |
failed | shows parse_error inline |
While any document is
indexing, the page polls the document list every 5 seconds and stops once nothing is indexing. The empty-state drop zone shows a spinner with “Indexing document…” during the first upload.Attaching a KB to a bot
In the bot wizard,StepKnowledge (the Knowledge Base RAG section) controls retrieval per bot:
| Control | Field |
|---|---|
| Enable knowledge retrieval | knowledge_enabled |
| When should the bot use knowledge? | knowledge_trigger_instructions (passed to the search_knowledge tool) |
| Attached Knowledge Bases | knowledge_kb_ids (checkboxes; only active KBs listed) |
| Top K | knowledge_top_k (1–10) |
| Score Threshold | knowledge_score_threshold (0–1) |
| Strict Mode | knowledge_strict (answer only from KB when retrieval is used) |
| Fallback Message | knowledge_fallback_message |
Related docs
Knowledge pipeline
How VoxBridge chunks, embeds, and indexes documents.
Create a bot
Where the knowledge step fits in bot building.