id, the natural-language text to vectorize, and typed metadata.
Adding Documents
Single Document
Batch Indexing
addMany validates every document, enforces maxBatchSize, and prevents duplicates.
Type-Safe Metadata
Define your metadata interface for compile-time safety:Updating Documents
Update Metadata Only
Metadata-only updates are instant and don’t trigger re-embedding:Update Text and Metadata
When text changes, VectoriaDB re-embeds the document:Batch Updates
Removing Documents
Checking for Documents
Document Limits
VectoriaDB enforces limits to prevent DoS attacks:Embedding Generation
Embeddings are generated automatically when you add or update documents. The process:- Text is tokenized using the configured model
- Embeddings are generated (~100-200 documents/second)
- Embeddings are stored in memory (and optionally persisted)
addMany with appropriate maxBatchSize to avoid memory spikes.
Related
Search
Querying the index
Persistence
Persisting embeddings
Overview
Getting started