Configuration
Every setting of duckdb-vectors is read in src/duckdb_vectors/config.py, and this page is the only place that lists them. The CLI, the Python library and the MCP server resolve them in the same way. The manifest is the file that holds them for one knowledge base.
Settings
Each setting resolves with the precedence flag or explicit argument > DUCKDB_VECTORS_* environment variable > manifest > default. Containers and CI inject variables to override a manifest baked into an image or committed with the pages. The same configuration works from code, from the environment or from a file. duckdb-vectors config shows the origin of each value.
| Setting | Argument | Environment variable | Manifest key | Default |
|---|---|---|---|---|
| Manifest | manifest | DUCKDB_VECTORS_MANIFEST | none | none (walk up from the current folder, for the CLI only) |
| Pages folder | none | DUCKDB_VECTORS_PAGES | pages | . |
| Work folder | none | DUCKDB_VECTORS_WORK | work | .duckdb-vectors |
| Database path | db_path | DUCKDB_VECTORS_DATABASE | database | vectors.duckdb |
| Embeddings model | embeddings (backend too) | DUCKDB_VECTORS_EMBEDDINGS | embeddings.model | local:minishlab/potion-multilingual-128M |
| Generation model | none | DUCKDB_VECTORS_ANNOTATION_MODEL | annotation.model | none |
| Lock wait (seconds) | lock_timeout | DUCKDB_VECTORS_LOCK_TIMEOUT | none | 10 |
| Tags to embed with each chunk | tag_fields | DUCKDB_VECTORS_TAG_FIELDS | tags.fields | none (off) |
| Match tags in keyword search | tag_bm25 | DUCKDB_VECTORS_TAG_BM25 | tags.bm25 | false |
| Results returned per search | top_k | DUCKDB_VECTORS_TOP_K | top_k | 20 |
| Ranking SQL of the vector signal | vector_sql | DUCKDB_VECTORS_VECTOR_SQL | none | none (built-in) |
| Ranking SQL of the text signal | text_sql | DUCKDB_VECTORS_TEXT_SQL | none | none (built-in) |
Settings() without a manifest has no filesystem side effect. The library and the MCP server accept a manifest but never search for one implicitly.
Deprecated aliases
DUCKDB_VECTORS_DB_PATH is an alias of DUCKDB_VECTORS_DATABASE, and DUCKDB_VECTORS_BACKEND of DUCKDB_VECTORS_EMBEDDINGS. The flags --db and --backend are aliases of --database and --embeddings, and the prefixes fastembed: and hf: are aliases of local: and huggingface:. They stay one release.
top_k is the number of results a search returns. It is 20 for the SDK, the CLI and the MCP search tool, and any call can pass its own value. A client that pays prompt tokens for every returned chunk, such as an agent harness, may lower it per call. tag_fields and tag_bm25 control tagged retrieval: tag_fields is an ordered list of label: $.path pairs read from each document's frontmatter, and tag_bm25 also matches those tags in keyword search.
Several processes can share one database file, for example one MCP server per editor window. DuckDB lets one process hold the file at a time, so the store connects lazily, on first use, and when another process holds the file it retries for up to lock_timeout seconds before raising DatabaseLockedError. Each search holds the file only for the call, and re-indexing an unchanged folder holds it for a moment, so in practice sessions wait milliseconds rather than fail.
vector_sql and text_sql replace the built-in ranking SELECT of each signal; the ranking SQL reference explains them.
See also
- Python API reference: the
VectorStorearguments. - Manifest reference: the file that holds these settings.
- Embedders reference: the values of
embeddings. - Tags reference: the values of
tag_fields.