MCP tool
crystal_import_knowledge — for moderate amounts of material. Embedding and graph enrichment happen synchronously as part of the import.HTTP bulk-insert
POST /api/knowledge-bases/:id/bulk-insert — for high-volume migrations. Rows are inserted immediately; embedding and enrichment run in the background.Method 1: crystal_import_knowledge tool
Use the MCP tool when importing a few dozen chunks or fewer. Each chunk is embedded and graph-enriched as it is written, so results are immediately searchable.
The tool maps to
POST /api/knowledge-bases/:knowledgeBaseId/import under the hood. Embedding and salience scoring run synchronously, so larger batches take longer. For anything over a few hundred chunks, use the bulk-insert endpoint instead.Method 2: HTTP bulk import
For large migrations — thousands of chunks or more — use the HTTP endpoints directly. The bulk-insert endpoint writes rows without blocking on embedding, so it completes quickly even for large payloads. Embedding and graph enrichment are scheduled automatically and finish in the background.Full bulk import flow
Create a Knowledge Base
Create the KB first if you don’t have one yet.Save the returned
knowledgeBaseId — you’ll need it for the import steps.Import with embedding (normal ingest)
For moderate batches where you want chunks to be immediately searchable, use the
/import endpoint. Embedding and enrichment run synchronously.Background enrichment
After bulk insert, embedding and graph backfill run automatically via background jobs. You don’t need to trigger these manually. The backfill scheduler retries automatically if the embedding provider is temporarily unavailable.Freshly bulk-inserted chunks are not immediately searchable. Allow a few minutes after insert for the background embedding jobs to complete before querying the KB.
Scoping imports
When you create a Knowledge Base, you can set ascope to restrict access to a specific workspace, client, or agent lane. Chunks inherit the scope of their parent KB.
client:globex channel will see this KB when listing or querying. KBs without a scope are visible to all your agents.
