Config file locations
Docmancer uses YAML config files. It checks in this order:
--config <path>on any command (explicit path)../docmancer.yamlin the current directory (project-local).~/.docmancer/docmancer.yaml(global, auto-created on first use).
Global config
Created automatically when you first run docmancer setup or docmancer docs add. Located at ~/.docmancer/docmancer.yaml.
The default stack uses the vendored potion-base-8M model, sqlite-vec, and hybrid retrieval. It requires no API key, daemon, or model download.
Minimal docs-index override:
index:
db_path: ~/.docmancer/docmancer.db
extracted_dir: ~/.docmancer/extracted/
Project-local config
Create a project-specific config by writing a docmancer.yaml in the project directory. When present, it takes precedence over the global config for any command run from that directory. Relative index.db_path values resolve against the config file's directory, not the shell's current directory.
index
Controls the SQLite FTS5 index.
| Key | Default | Description |
|---|---|---|
index.provider | sqlite | Index backend (only sqlite is supported) |
index.db_path | ~/.docmancer/docmancer.db | Path to the SQLite database |
index.extracted_dir | ~/.docmancer/extracted | Directory for extracted Markdown / JSON inspection files |
vector_store
Controls the vector backend. sqlite-vec is the default local path. Qdrant is an optional heavy compatibility backend.
| Key | Default | Description |
|---|---|---|
vector_store.provider | sqlite-vec | Default local sqlite-vec backend, or optional qdrant |
vector_store.url | auto | Override for an existing Qdrant URL (e.g. http://localhost:6333). Honours DOCMANCER_QDRANT_URL. |
vector_store.collection | derived | Collection name. Qdrant refuses foreign collections without the ownership sentinel. |
vector_store.options.db_path | ~/.docmancer/sqlite-vec.db | File used by the default sqlite-vec backend. |
embeddings
Selects the dense embeddings provider. Sparse retrieval is available only on the optional heavy Qdrant path.
| Key | Default | Description |
|---|---|---|
embeddings.provider | model2vec | Vendored local model, or explicit fastembed, openai, voyage, or cohere |
embeddings.model | minishlab/potion-base-8M | Dense model identifier |
embeddings.dimensions | 256 | Dense vector dimensions |
Content-hash-keyed cache at ~/.docmancer/embeddings-cache/ skips re-embedding unchanged chunks. Cloud providers retry on 429/5xx with bounded exponential backoff; when a configured cloud provider has no API key in env, ingest falls back to FTS5-only with a warning rather than aborting.
retrieval
Controls the retrieval dispatcher: hybrid fusion, hierarchical two-stage retrieval, query routing, and neighbor expansion.
| Key | Default | Description |
|---|---|---|
retrieval.profile | local | local for the zero-daemon sqlite-vec and model2vec stack, or scale for Qdrant, FastEmbed, and sparse SPLADE. Set it with docmancer setup --profile <name>. |
retrieval.default_mode | hybrid | One of lexical, dense, sparse, hybrid |
retrieval.expand | null | Override neighbor expansion for the dispatcher path. Falls back to query.default_expand. |
retrieval.hierarchical.enabled | false | Force the two-stage retrieval pass on |
retrieval.hierarchical.auto | true | Auto-enable two-stage retrieval per index once the corpus has at least auto_min_documents distinct documents |
retrieval.hierarchical.auto_min_documents | 10 | Threshold for the auto path |
retrieval.hierarchical.documents_limit | 5 | Top-N documents kept after stage 1 |
retrieval.hierarchical.candidate_pool | 200 | Wide-net size for stage 1 |
retrieval.hierarchical.sections_per_document | 10 | Stage 2 cap on sections per surviving document |
retrieval.routers | [] | Ordered {match, filters} entries. First regex match merges filters into the dispatcher call. Only fires under dispatcher modes (dense, sparse, hybrid). See Router recipes. |
retrieval.fusion.method | rrf | rrf or weighted_rrf |
retrieval.fusion.rrf_k | 60 | RRF constant |
query
Defaults for docmancer docs query.
| Key | Default | Description |
|---|---|---|
query.default_budget | 2400 | Default token budget for context packs |
query.default_limit | 8 | Maximum sections returned per query |
query.default_expand | adjacent | none, adjacent, or page |
discovery, capture, and providers
These three sections describe the memory harness rather than docs retrieval, and are normally written by docmancer setup, docmancer agent install, and docmancer providers rather than by hand.
| Key | Default | Description |
|---|---|---|
discovery.disabled | [] | Harness source IDs to skip during discovery |
discovery.extra_sources | [] | Additional local paths to treat as agent evidence |
capture.enabled | {} | Per-agent lifecycle capture switches, set by hook installation |
providers.default_llm | openrouter | Default generation provider |
providers.models | {} | Per-provider model choice |
providers.base_urls | {} | Compatible base URL per provider |
providers.generation | per task | Sampling and output limits for ask, brief, review, and consolidate |
Provider API keys are never stored here. They live in the operating-system keyring.
web_fetch
Defaults for URL-based docmancer docs add.
| Key | Default | Description |
|---|---|---|
web_fetch.workers | 8 | Parallelism for web page fetching |
web_fetch.default_page_cap | 500 | Default page limit |
web_fetch.browser_fallback | false | Enable Playwright browser fallback by default |
Environment variables
Any field above can be overridden via its prefixed environment variable.
| Variable prefix | Scope |
|---|---|
DOCMANCER_INDEX_* | index.* fields |
DOCMANCER_VECTOR_STORE_* | vector_store.* fields |
DOCMANCER_EMBEDDINGS_* | embeddings.* fields |
DOCMANCER_RETRIEVAL_* | retrieval.* fields |
DOCMANCER_QUERY_* | query.* fields |
DOCMANCER_WEB_FETCH_* | web_fetch.* fields |
DOCMANCER_HOME | Override the local storage root |
DOCMANCER_MEMORY_DB | Override the memory index database |
DOCMANCER_HOOK_TIMEOUT_MS | Bound recall hooks, default 1000 ms |
OPENROUTER_API_KEY | Enable optional redacted consolidation maintenance |
DOCMANCER_QDRANT_URL | Override optional Qdrant URL |
DOCMANCER_AUTO_VECTORS | 0 to disable auto vector sync; 1 to force it on |
Example: full hybrid config
index:
provider: sqlite
db_path: ~/.docmancer/docmancer.db
extracted_dir: ~/.docmancer/extracted
vector_store:
provider: sqlite-vec
collection: docmancer
options:
db_path: ~/.docmancer/sqlite-vec.db
embeddings:
provider: model2vec
model: minishlab/potion-base-8M
dimensions: 256
retrieval:
default_mode: hybrid
hierarchical:
auto: true
auto_min_documents: 10
fusion:
method: rrf
rrf_k: 60
query:
default_budget: 2400
default_limit: 8
default_expand: adjacent
Deprecated and removed keys
registry:andpacks:are retired hosted API-pack configuration and should be removed.bench:was removed in 0.5.0 along with thedocmancer benchcommand. YAML that still contains it loads with a deprecation warning.eval:was removed in 0.5.0. Same warning behaviour asbench:.
Data locations
| Path | Content |
|---|---|
~/.docmancer/docmancer.yaml | Global config |
~/.docmancer/docmancer.db | SQLite FTS5 index |
~/.docmancer/sqlite-vec.db | Default docs vector store |
~/.docmancer/memory.db | Rebuildable memory index |
~/.docmancer/tree/ | Machine-wide Shared Memory under profile/, principles/, projects/, and shared/ |
| Docmancer internal state directory | Combination manifest and revision history |
~/.docmancer/memories/ | Durable personal and project Markdown records, including captured ones |
~/.docmancer/memory-tombstones.json | Content-free suppression records |
~/.docmancer/embeddings-cache/ | Content-addressed embedding cache |
~/.docmancer/extracted/ | Extracted Markdown / JSON (inspectable) |
<repo>/.docmancer/tree/ | Curated project memory under decisions/, constraints/, workflows/, and lessons/ |
<repo>/.docmancer/inbox/ | Markdown imported for optional curation |
<repo>/.docmancer/trash/ | Recoverable deleted memory files |
<repo>/.docmancer/state/decision-journal.jsonl | Append-only curated-file history |
<repo>/.docmancer/context/ | Revisioned generated Context (legacy) |
DOCMANCER_HOME moves everything under ~/.docmancer to another root.
Resetting
To clear the docs index but keep everything else:
docmancer docs remove --all
To remove all machine-wide Docmancer state, including config, indexes, the memory tree, caches, and vendored models:
docmancer clear
clear prints an itemised size table and waits for confirmation. It does not touch project-local .docmancer/ directories or Cloud credentials in the OS keyring. Rebuild afterwards with docmancer setup.