Installation
Ajoutez ceci à la configuration MCP de votre client (Claude Desktop : claude_desktop_config.json ; Cursor : .cursor/mcp.json ; VS Code et les autres utilisent la même forme « mcpServers »).
markdown-vault-mcpclaude mcp add markdown-vault-mcp -e 'MARKDOWN_VAULT_MCP_KV_STORE_URL=file:///data/state' -e 'MARKDOWN_VAULT_MCP_TOOLS_ALLOW=<MARKDOWN_VAULT_MCP_TOOLS_ALLOW>' -e 'MARKDOWN_VAULT_MCP_TOOLS_DENY=<MARKDOWN_VAULT_MCP_TOOLS_DENY>' -e 'MARKDOWN_VAULT_MCP_SERVER_NAME=<MARKDOWN_VAULT_MCP_SERVER_NAME>' -e 'MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION=<MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION>' -e 'MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA=<MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA>' -e 'MARKDOWN_VAULT_MCP_INSTRUCTIONS=<MARKDOWN_VAULT_MCP_INSTRUCTIONS>' -e 'MARKDOWN_VAULT_MCP_LOG_LEVEL=INFO' -e 'MARKDOWN_VAULT_MCP_LOG_FORMAT=<MARKDOWN_VAULT_MCP_LOG_FORMAT>' -e 'OLLAMA_HOST=http://localhost:11434' -e 'OPENAI_API_KEY=<your openai_api_key>' -e 'VOYAGE_API_KEY=<your voyage_api_key>' -e 'OPENAI_BASE_URL=<OPENAI_BASE_URL>' -e 'OPENAI_EMBEDDING_MODEL=<OPENAI_EMBEDDING_MODEL>' -e 'MARKDOWN_VAULT_MCP_BUILD_TIMEOUT_S=60' -e 'MARKDOWN_VAULT_MCP_DRAIN_TIMEOUT_S=60' -e 'MARKDOWN_VAULT_MCP_SOURCE_DIR=/data/vault' -e 'MARKDOWN_VAULT_MCP_READ_ONLY=false' -e 'MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTING=true' -e 'MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKS=false' -e 'MARKDOWN_VAULT_MCP_DISABLE_APPS_UI=false' -e 'MARKDOWN_VAULT_MCP_INDEX_PATH=<MARKDOWN_VAULT_MCP_INDEX_PATH>' -e 'MARKDOWN_VAULT_MCP_STATE_PATH=<MARKDOWN_VAULT_MCP_STATE_PATH>' -e 'MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH=<MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH>' -e 'MARKDOWN_VAULT_MCP_INDEXED_FIELDS=<MARKDOWN_VAULT_MCP_INDEXED_FIELDS>' -e 'MARKDOWN_VAULT_MCP_REQUIRED_FIELDS=<MARKDOWN_VAULT_MCP_REQUIRED_FIELDS>' -e 'MARKDOWN_VAULT_MCP_EXCLUDE=<MARKDOWN_VAULT_MCP_EXCLUDE>' -e 'MARKDOWN_VAULT_MCP_TITLE_FIELD=title' -e 'MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS=<MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS>' -e 'MARKDOWN_VAULT_MCP_TEMPLATES_FOLDER=_templates' -e 'MARKDOWN_VAULT_MCP_PROMPTS_FOLDER=<MARKDOWN_VAULT_MCP_PROMPTS_FOLDER>' -e 'MARKDOWN_VAULT_MCP_CONVENTIONS_FILE=_conventions.md' -e 'MARKDOWN_VAULT_MCP_OKF_MODE=auto' -e 'MARKDOWN_VAULT_MCP_OKF_WRITE=false' -e 'MARKDOWN_VAULT_MCP_OKF_VERIFY=elicit' -e 'MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS=<MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS>' -e 'MARKDOWN_VAULT_MCP_MAX_ATTACHMENT_SIZE_MB=1.0' -e 'MARKDOWN_VAULT_MCP_MAX_NOTE_READ_BYTES=262144' -e 'MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODE=auto' -e 'MARKDOWN_VAULT_MCP_CHUNKS_PER_FILE=2' -e 'MARKDOWN_VAULT_MCP_SNIPPET_WORDS=200' -e 'MARKDOWN_VAULT_MCP_LENGTH_DOWNWEIGHT_ALPHA=0.25' -e 'MARKDOWN_VAULT_MCP_MAX_CHUNK_WORDS=400' -e 'MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS=<MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS>' -e 'MARKDOWN_VAULT_MCP_CHUNK_OVERLAP_WORDS=40' -e 'MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS=<MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS>' -e 'MARKDOWN_VAULT_MCP_FTS_WEIGHTS=<MARKDOWN_VAULT_MCP_FTS_WEIGHTS>' -e 'MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER=<MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER>' -e 'MARKDOWN_VAULT_MCP_OLLAMA_MODEL=nomic-embed-text' -e 'MARKDOWN_VAULT_MCP_OLLAMA_CPU_ONLY=false' -e 'MARKDOWN_VAULT_MCP_VOYAGE_MODEL=voyage-4' -e 'MARKDOWN_VAULT_MCP_OPENAI_BASE_URL=https://api.openai.com/v1' -e 'MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODEL=text-embedding-3-small' -e 'MARKDOWN_VAULT_MCP_FASTEMBED_MODEL=BAAI/bge-small-en-v1.5' -e 'MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR=<MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR>' -e 'MARKDOWN_VAULT_MCP_EMBED_CONTEXT=false' -e 'MARKDOWN_VAULT_MCP_EMBED_TIMEOUT_S=30.0' -e 'MARKDOWN_VAULT_MCP_EMBEDDING_BATCH_SIZE=4' -e 'MARKDOWN_VAULT_MCP_GIT_TOKEN=<your markdown_vault_mcp_git_token>' -e 'MARKDOWN_VAULT_MCP_GIT_REPO_URL=<MARKDOWN_VAULT_MCP_GIT_REPO_URL>' -e 'MARKDOWN_VAULT_MCP_GIT_USERNAME=x-access-token' -e 'MARKDOWN_VAULT_MCP_GIT_PULL_INTERVAL_S=600' -e 'MARKDOWN_VAULT_MCP_GIT_PUSH_DELAY_S=30.0' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME=markdown-vault-mcp' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL=noreply@markdown-vault-mcp' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM=<MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM>' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM=<MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM>' -e 'MARKDOWN_VAULT_MCP_GIT_LFS=true' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER=true' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER_DEBOUNCE_S=2.0' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER_ROOT_FLOOR=true' -e 'MARKDOWN_VAULT_MCP_BOOT_REINDEX=true' -e 'MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRET=<your markdown_vault_mcp_github_webhook_secret>' -e 'MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKEN=<your markdown_vault_mcp_gitlab_webhook_signing_token>' -e 'MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKEN=<your markdown_vault_mcp_gitlab_webhook_secret_token>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER=<MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY=<your markdown_vault_mcp_summarize_openai_api_key>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL=<MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_MODEL=gpt-5-mini' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_TOKENS=8192' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_NOTES=50' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_INPUT_CHARS=200000' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_TIMEOUT=120.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_TTL_DEFAULT_S=3600.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_TTL_MAX_S=86400.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_GRACE_TTL_S=60.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_LEASE_S=60.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_MAX_UPLOAD_BYTES=104857600' -e 'MARKDOWN_VAULT_MCP_JOBS_SOFT_DEADLINE_S=25.0' -e 'MARKDOWN_VAULT_MCP_JOBS_RESULT_TTL_S=3600.0' -e 'MARKDOWN_VAULT_MCP_JOBS_MAX_PER_SUBJECT=256' -- uvx markdown-vault-mcp==5.1.0
{
"mcpServers": {
"markdown-vault-mcp": {
"command": "uvx",
"args": [
"markdown-vault-mcp==5.1.0"
],
"env": {
"MARKDOWN_VAULT_MCP_KV_STORE_URL": "file:///data/state",
"MARKDOWN_VAULT_MCP_TOOLS_ALLOW": "<MARKDOWN_VAULT_MCP_TOOLS_ALLOW>",
"MARKDOWN_VAULT_MCP_TOOLS_DENY": "<MARKDOWN_VAULT_MCP_TOOLS_DENY>",
"MARKDOWN_VAULT_MCP_SERVER_NAME": "<MARKDOWN_VAULT_MCP_SERVER_NAME>",
"MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION": "<MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION>",
"MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA": "<MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA>",
"MARKDOWN_VAULT_MCP_INSTRUCTIONS": "<MARKDOWN_VAULT_MCP_INSTRUCTIONS>",
"MARKDOWN_VAULT_MCP_LOG_LEVEL": "INFO",
"MARKDOWN_VAULT_MCP_LOG_FORMAT": "<MARKDOWN_VAULT_MCP_LOG_FORMAT>",
"OLLAMA_HOST": "http://localhost:11434",
"OPENAI_API_KEY": "<your openai_api_key>",
"VOYAGE_API_KEY": "<your voyage_api_key>",
"OPENAI_BASE_URL": "<OPENAI_BASE_URL>",
"OPENAI_EMBEDDING_MODEL": "<OPENAI_EMBEDDING_MODEL>",
"MARKDOWN_VAULT_MCP_BUILD_TIMEOUT_S": "60",
"MARKDOWN_VAULT_MCP_DRAIN_TIMEOUT_S": "60",
"MARKDOWN_VAULT_MCP_SOURCE_DIR": "/data/vault",
"MARKDOWN_VAULT_MCP_READ_ONLY": "false",
"MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTING": "true",
"MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKS": "false",
"MARKDOWN_VAULT_MCP_DISABLE_APPS_UI": "false",
"MARKDOWN_VAULT_MCP_INDEX_PATH": "<MARKDOWN_VAULT_MCP_INDEX_PATH>",
"MARKDOWN_VAULT_MCP_STATE_PATH": "<MARKDOWN_VAULT_MCP_STATE_PATH>",
"MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH": "<MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH>",
"MARKDOWN_VAULT_MCP_INDEXED_FIELDS": "<MARKDOWN_VAULT_MCP_INDEXED_FIELDS>",
"MARKDOWN_VAULT_MCP_REQUIRED_FIELDS": "<MARKDOWN_VAULT_MCP_REQUIRED_FIELDS>",
"MARKDOWN_VAULT_MCP_EXCLUDE": "<MARKDOWN_VAULT_MCP_EXCLUDE>",
"MARKDOWN_VAULT_MCP_TITLE_FIELD": "title",
"MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS": "<MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS>",
"MARKDOWN_VAULT_MCP_TEMPLATES_FOLDER": "_templates",
"MARKDOWN_VAULT_MCP_PROMPTS_FOLDER": "<MARKDOWN_VAULT_MCP_PROMPTS_FOLDER>",
"MARKDOWN_VAULT_MCP_CONVENTIONS_FILE": "_conventions.md",
"MARKDOWN_VAULT_MCP_OKF_MODE": "auto",
"MARKDOWN_VAULT_MCP_OKF_WRITE": "false",
"MARKDOWN_VAULT_MCP_OKF_VERIFY": "elicit",
"MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS": "<MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS>",
"MARKDOWN_VAULT_MCP_MAX_ATTACHMENT_SIZE_MB": "1.0",
"MARKDOWN_VAULT_MCP_MAX_NOTE_READ_BYTES": "262144",
"MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODE": "auto",
"MARKDOWN_VAULT_MCP_CHUNKS_PER_FILE": "2",
"MARKDOWN_VAULT_MCP_SNIPPET_WORDS": "200",
"MARKDOWN_VAULT_MCP_LENGTH_DOWNWEIGHT_ALPHA": "0.25",
"MARKDOWN_VAULT_MCP_MAX_CHUNK_WORDS": "400",
"MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS": "<MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS>",
"MARKDOWN_VAULT_MCP_CHUNK_OVERLAP_WORDS": "40",
"MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS": "<MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS>",
"MARKDOWN_VAULT_MCP_FTS_WEIGHTS": "<MARKDOWN_VAULT_MCP_FTS_WEIGHTS>",
"MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER": "<MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER>",
"MARKDOWN_VAULT_MCP_OLLAMA_MODEL": "nomic-embed-text",
"MARKDOWN_VAULT_MCP_OLLAMA_CPU_ONLY": "false",
"MARKDOWN_VAULT_MCP_VOYAGE_MODEL": "voyage-4",
"MARKDOWN_VAULT_MCP_OPENAI_BASE_URL": "https://api.openai.com/v1",
"MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODEL": "text-embedding-3-small",
"MARKDOWN_VAULT_MCP_FASTEMBED_MODEL": "BAAI/bge-small-en-v1.5",
"MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR": "<MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR>",
"MARKDOWN_VAULT_MCP_EMBED_CONTEXT": "false",
"MARKDOWN_VAULT_MCP_EMBED_TIMEOUT_S": "30.0",
"MARKDOWN_VAULT_MCP_EMBEDDING_BATCH_SIZE": "4",
"MARKDOWN_VAULT_MCP_GIT_TOKEN": "<your markdown_vault_mcp_git_token>",
"MARKDOWN_VAULT_MCP_GIT_REPO_URL": "<MARKDOWN_VAULT_MCP_GIT_REPO_URL>",
"MARKDOWN_VAULT_MCP_GIT_USERNAME": "x-access-token",
"MARKDOWN_VAULT_MCP_GIT_PULL_INTERVAL_S": "600",
"MARKDOWN_VAULT_MCP_GIT_PUSH_DELAY_S": "30.0",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME": "markdown-vault-mcp",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL": "noreply@markdown-vault-mcp",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM": "<MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM>",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM": "<MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM>",
"MARKDOWN_VAULT_MCP_GIT_LFS": "true",
"MARKDOWN_VAULT_MCP_FILE_WATCHER": "true",
"MARKDOWN_VAULT_MCP_FILE_WATCHER_DEBOUNCE_S": "2.0",
"MARKDOWN_VAULT_MCP_FILE_WATCHER_ROOT_FLOOR": "true",
"MARKDOWN_VAULT_MCP_BOOT_REINDEX": "true",
"MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRET": "<your markdown_vault_mcp_github_webhook_secret>",
"MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKEN": "<your markdown_vault_mcp_gitlab_webhook_signing_token>",
"MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKEN": "<your markdown_vault_mcp_gitlab_webhook_secret_token>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER": "<MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY": "<your markdown_vault_mcp_summarize_openai_api_key>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL": "<MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_MODEL": "gpt-5-mini",
"MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_TOKENS": "8192",
"MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_NOTES": "50",
"MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_INPUT_CHARS": "200000",
"MARKDOWN_VAULT_MCP_SUMMARIZE_TIMEOUT": "120.0",
"MARKDOWN_VAULT_MCP_TRANSFER_TTL_DEFAULT_S": "3600.0",
"MARKDOWN_VAULT_MCP_TRANSFER_TTL_MAX_S": "86400.0",
"MARKDOWN_VAULT_MCP_TRANSFER_GRACE_TTL_S": "60.0",
"MARKDOWN_VAULT_MCP_TRANSFER_LEASE_S": "60.0",
"MARKDOWN_VAULT_MCP_TRANSFER_MAX_UPLOAD_BYTES": "104857600",
"MARKDOWN_VAULT_MCP_JOBS_SOFT_DEADLINE_S": "25.0",
"MARKDOWN_VAULT_MCP_JOBS_RESULT_TTL_S": "3600.0",
"MARKDOWN_VAULT_MCP_JOBS_MAX_PER_SUBJECT": "256"
}
}
}
}
Variables d'environnement
MARKDOWN_VAULT_MCP_KV_STORE_URLPersistent-state backend URL shared by every pvl-core subsystem that needs state. `memory://` is in-process and lost on restart; `file:///path` persists on one server; `redis://`, `dynamodb://` and `mongodb://` each need their matching extra. When unset, defaults to `file:///data/state` (the volume family Docker images mount), or to `memory://` (with a warning) on a host where that directory is not usable.MARKDOWN_VAULT_MCP_TOOLS_ALLOWComma-separated explicit tool names this instance exposes; every other tool is hidden from listings and cannot be invoked. Names matching no registered tool are inert. Mutually exclusive with `tools_deny`. Takes effect through `apply_tool_visibility`.MARKDOWN_VAULT_MCP_TOOLS_DENYComma-separated explicit tool names hidden from this instance (absent from listings, cannot be invoked). Names matching no registered tool are inert. Mutually exclusive with `tools_allow`. Takes effect through `apply_tool_visibility`.MARKDOWN_VAULT_MCP_SERVER_NAMERename this server instance; defaults to the project name.MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTIONConcise routing context that distinguishes this deployment's material or responsibility.MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRADeployment-specific behavioral policy added to the generated MCP instructions.MARKDOWN_VAULT_MCP_INSTRUCTIONSLegacy: replaces all generated MCP instructions (deprecated; use _INSTANCE_DESCRIPTION for routing and _INSTRUCTIONS_EXTRA for policy).MARKDOWN_VAULT_MCP_LOG_LEVELLog level for every logger in the process, FastMCP's included (DEBUG / INFO / WARNING / ERROR / CRITICAL). The -v CLI flag overrides to DEBUG. The unprefixed FASTMCP_LOG_LEVEL still works for one major version and logs a deprecation warning.MARKDOWN_VAULT_MCP_LOG_FORMATLog rendering. rich is one colour event key=value line per record, for a terminal; json is one JSON object per record, for a collector. Unset picks rich when stderr is a terminal and json everywhere else, so a container or journald gets JSON with no configuration.OLLAMA_HOSTOllama server URL for the ollama embedding provider. Bare (not MARKDOWN_VAULT_MCP_-prefixed), matching the Ollama ecosystem convention.OPENAI_API_KEYsecret OpenAI API key for the openai embedding provider, and the fallback key for the summarize tool when MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY is unset. Bare (not MARKDOWN_VAULT_MCP_-prefixed), matching the OpenAI ecosystem convention.VOYAGE_API_KEYsecret Voyage AI API key for the voyage embedding provider. Bare (not MARKDOWN_VAULT_MCP_-prefixed), matching the OPENAI_API_KEY / OLLAMA_HOST convention. Setting it never auto-selects the provider; choose it explicitly with MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER=voyage.OPENAI_BASE_URLBare fallback for MARKDOWN_VAULT_MCP_OPENAI_BASE_URL (embeddings). For the summarize tool it only routes traffic when an API key already enables the feature; it never enables summarize by itself.OPENAI_EMBEDDING_MODELBare fallback for MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODEL.MARKDOWN_VAULT_MCP_BUILD_TIMEOUT_SMaximum seconds an index-backed tool or resource waits for the FTS index to become queryable during a cold-start background build before raising IndexUnavailableError(reason="timeout"). Increase for large vaults.MARKDOWN_VAULT_MCP_DRAIN_TIMEOUT_SMaximum seconds an index-querying read tool waits for the IndexWriter to drain when called with wait_for_pending_writes=true. On timeout the tool answers from the current index and reports index_stale=true in the response _meta.MARKDOWN_VAULT_MCP_SOURCE_DIRPath to the markdown vault directory. When it does not exist, or the server cannot access it, the server starts but every tool fails with a message saying which until it is fixed (managed git mode clones into it). Symbolic links inside the vault are followed on Python 3.13+.MARKDOWN_VAULT_MCP_READ_ONLYSet to true to hide the write tools (write, edit, append, delete, rename, move_folder, fetch, git_sync, the okf_* tools, create_upload_link) and serve a search-only vault.MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTINGRefuse a write that would overwrite an existing file when no if_match etag is supplied. Deliberate replacement still works: read the file first, then pass if_match. Unaffected: edit, append, delete, rename. Set to false to allow blind overwrites.MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKSSet to true to have write, edit and append list, under unresolved_links, the target of each link the call added that get_broken_links reports. Links the note already held are left out. Off by default, leaving those responses unchanged.MARKDOWN_VAULT_MCP_DISABLE_APPS_UIHide the MCP Apps UI tools (browse_vault, show_context) from the tool listing for clients that do not render MCP Apps panels.MARKDOWN_VAULT_MCP_INDEX_PATHPath to the SQLite FTS5 index file; unset keeps the index in memory. Set it for persistence across restarts.MARKDOWN_VAULT_MCP_STATE_PATHPath to the change-tracking state file. Defaults to INDEX_PATH plus .state.json (index.db.state.json beside index.db); without INDEX_PATH the state is kept in memory. Never written into the vault by default.MARKDOWN_VAULT_MCP_EMBEDDINGS_PATHBase path for the embeddings files. Defaults beside INDEX_PATH (index-db-embeddings.npy and .json beside index.db); without INDEX_PATH the vectors are kept in memory and rebuilt at each start. Setting it also lets the provider be auto-detected.MARKDOWN_VAULT_MCP_INDEXED_FIELDSComma-separated frontmatter fields promoted to the tag index for structured filtering. Changing it cold-rebuilds the index once on next startup; SEARCHABLE_FIELDS inherits this value when unset.MARKDOWN_VAULT_MCP_REQUIRED_FIELDSComma-separated frontmatter fields required on every document; documents missing any are excluded from the index.MARKDOWN_VAULT_MCP_EXCLUDEComma-separated glob patterns excluded from scanning, e.g. .obsidian/**,.trash/**.MARKDOWN_VAULT_MCP_TITLE_FIELDFrontmatter field used as the document title (falls back to title, the first H1, then the filename). Changing it cold-rebuilds the index once on next startup.MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDSComma-separated frontmatter fields whose text values become keyword-searchable and enrich first-chunk embeddings. Inherits INDEXED_FIELDS when unset; the sentinel none means filterable but not searchable. Changing it cold-rebuilds the index and re-embeds once on next startup.MARKDOWN_VAULT_MCP_TEMPLATES_FOLDERRelative folder where note templates live (used by the create_from_template prompt).MARKDOWN_VAULT_MCP_PROMPTS_FOLDERDirectory of .md prompt files that extend or override built-in prompts; a relative path is resolved against SOURCE_DIR.MARKDOWN_VAULT_MCP_CONVENTIONS_FILEFilename of the per-folder conventions files surfaced to clients at write time (bare .md filename without glob characters). Set to none to disable folder conventions.MARKDOWN_VAULT_MCP_OKF_MODEOKF (Open Knowledge Format) read semantics. With auto (the default), read annotations switch on when the vault declares an OKF version in its root index.md. Use off to disable OKF semantics entirely, or on to force them for an undeclared vault. Annotations are read-only; write behavior is never affected.MARKDOWN_VAULT_MCP_OKF_WRITEOKF (Open Knowledge Format) enforced write layer. When true on an OKF-active vault, the server stamps generated provenance on each write and clears any verified attestation when a note's content changes. It also keeps each written folder's log.md and index.md current, and exposes the okf_verify tool. Requires OKF_MODE to be auto or on (a true value with OKF_MODE=off is a config error). Off by default.MARKDOWN_VAULT_MCP_OKF_VERIFYHow the okf_verify tool attributes a human review. This applies only when OKF_WRITE is on, which gates the tool. With elicit (the default), okf_verify asks the human to confirm the review through an MCP elicitation, then records the attestation only on an affirmative reply. It fails closed when the client cannot elicit or the human declines, so a model holding the human's token cannot self-attest. Set trust-auth instead to attribute to a token's sub claim with no confirmation; it rejects static bearer credentials and other client-ID-only identities. This is safe only when the sole caller is a human-driven UI. Set off to hide the tool, leaving attestation to external tooling. A non-default value with OKF_WRITE off is a config error.MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONSComma-separated allowed attachment extensions (e.g. pdf,png,jpg); case and a leading dot are ignored, so PDF and .pdf name the same type. Use * to allow every non-markdown file. Unset selects the built-in allowlist. A link whose target has a listed extension is not part of the link graph; changing the list rebuilds the index once.MARKDOWN_VAULT_MCP_MAX_ATTACHMENT_SIZE_MBMaximum attachment size in MB returned by read / accepted by write; 0 disables the limit.MARKDOWN_VAULT_MCP_MAX_NOTE_READ_BYTESMaximum bytes returned by a full-document read of a note; use `read(path, section=…)` for partial reads. 0 disables the limit.MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODEMode used when a search call omits 'mode': auto, keyword, semantic, or hybrid. The default 'auto' picks hybrid when embeddings are configured and keyword when they are not. Pin 'keyword' to keep unqualified searches off the embedding provider (each hybrid or semantic search embeds the query, which costs an API call on a metered provider). A configured semantic/hybrid default also degrades to keyword without embeddings, so no setting can make a vault unsearchable; an explicit mode= argument is never downgraded.MARKDOWN_VAULT_MCP_CHUNKS_PER_FILEMaximum chunks returned per document in search results.MARKDOWN_VAULT_MCP_SNIPPET_WORDSWidth of the snippet window (words) in search results; 0 returns full chunk content.MARKDOWN_VAULT_MCP_LENGTH_DOWNWEIGHT_ALPHADown-weights longer chunks in ranking: score / (1 + alpha * log(chunk_count)).MARKDOWN_VAULT_MCP_MAX_CHUNK_WORDSWord cap per chunk; the adaptive chunker splits at deeper heading levels, then paragraph/word boundaries, to respect it. Match it to the embedding model's context. A reindex applies a new value.MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARSCharacter cap enforced alongside MAX_CHUNK_WORDS to bound token-dense chunks. Unset derives min(1500, model context * 2.8). Set a positive value for an exact cap, or -1 to scale with the model's full context (can exhaust memory on long-context models). A reindex applies a new value.MARKDOWN_VAULT_MCP_CHUNK_OVERLAP_WORDSWords of overlap between adjacent budget-split fragments of the same heading section (0 disables). A reindex applies a new value.MARKDOWN_VAULT_MCP_FOLDER_WEIGHTSFolder-prefix score multipliers (`prefix:weight` pairs, comma-separated, weights > 0) applied to all search modes; the deepest matching prefix wins (sessions:0.5 demotes sessions/**).MARKDOWN_VAULT_MCP_FTS_WEIGHTSPer-column BM25 weights (`column:weight` pairs, comma-separated, weights >= 0) for keyword ranking. Columns: path, title, folder, heading, content, summary.MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDEREmbedding provider: openai, voyage, ollama, or fastembed; setting it turns on search by meaning. Unset auto-detects from the environment (never voyage), but only when EMBEDDINGS_PATH is set. Any OpenAI-compatible endpoint works with openai plus OPENAI_BASE_URL; see the embeddings guide.MARKDOWN_VAULT_MCP_OLLAMA_MODELOllama embedding model name.MARKDOWN_VAULT_MCP_OLLAMA_CPU_ONLYForce Ollama to embed on CPU only.MARKDOWN_VAULT_MCP_VOYAGE_MODELVoyage AI embedding model name.MARKDOWN_VAULT_MCP_OPENAI_BASE_URLOpenAI-compatible API base URL for embeddings; the bare OPENAI_BASE_URL is honoured as a fallback.MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODELOpenAI-compatible embedding model name; the bare OPENAI_EMBEDDING_MODEL is honoured as a fallback.MARKDOWN_VAULT_MCP_FASTEMBED_MODELFastEmbed model name.MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIRFastEmbed model cache directory (in Docker, stored under /data/state/fastembed).MARKDOWN_VAULT_MCP_EMBED_CONTEXTEnrich embedding input with the note title, chunk heading, and (first chunk) searchable-field values. Flipping it re-embeds the whole vault once on next startup.MARKDOWN_VAULT_MCP_EMBED_TIMEOUT_SPer-request wall-clock budget in seconds for a single embedding HTTP call (OpenAI/Ollama). The local FastEmbed backend runs in-process with no network call and ignores this. CPU-only or large-model workloads may need 60-120 s; raise this if batches time out.MARKDOWN_VAULT_MCP_EMBEDDING_BATCH_SIZENumber of chunks sent per embedding request. Smaller batches shorten each request (useful under a tight timeout on slow models) at the cost of more round-trips.MARKDOWN_VAULT_MCP_GIT_TOKENsecret Token/password for HTTPS git auth; remotes must be HTTPS when set.MARKDOWN_VAULT_MCP_GIT_REPO_URLHTTPS remote URL for managed git mode: the server clones into an empty SOURCE_DIR on startup (or validates an existing origin) and enables the pull loop, auto-commit, and deferred push.MARKDOWN_VAULT_MCP_GIT_USERNAMEUsername for HTTPS git auth prompts (x-access-token for GitHub, oauth2 for GitLab, the account name for Bitbucket).MARKDOWN_VAULT_MCP_GIT_PULL_INTERVAL_SSeconds between git fetch + fast-forward update attempts; 0 disables periodic pull.MARKDOWN_VAULT_MCP_GIT_PUSH_DELAY_SSeconds of write-idle time before pushing; 0 pushes only on shutdown.MARKDOWN_VAULT_MCP_GIT_COMMIT_NAMEGit committer name for auto-commits, and the author name too unless an OIDC claim supplies one; set this in Docker where git config user.name is empty.MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAILGit committer email for auto-commits, and the author email too unless an OIDC claim supplies one.MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIMOIDC claim key used as the commit author name (e.g. name) when an OIDC token is present; the committer stays GIT_COMMIT_NAME. The claim is resolved when the tool call arrives and carried to the background commit, so it applies on every write. A configured claim the token does not carry is reported once at WARNING and the static identity is used.MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIMOIDC claim key used as the commit author email (e.g. email) when an OIDC token is present; the committer stays GIT_COMMIT_EMAIL. Resolved and carried the same way as the name claim.MARKDOWN_VAULT_MCP_GIT_LFSRun git lfs pull on startup to fetch LFS-tracked attachments; set to false for repos without LFS.MARKDOWN_VAULT_MCP_FILE_WATCHERWatch the vault for external filesystem changes; auto-disabled when git pull is active or a webhook can deliver (HTTP/SSE transports only). Requires the file-watcher extra.MARKDOWN_VAULT_MCP_FILE_WATCHER_DEBOUNCE_SSeconds of quiet after the last filesystem event before reindexing.MARKDOWN_VAULT_MCP_FILE_WATCHER_ROOT_FLOORKeep the non-recursive watch on the vault root; set false to register zero source-dir-rooted FSEvents streams (avoids repeated macOS access prompts on a home-rooted vault) at the cost of root-level files relying on scans.MARKDOWN_VAULT_MCP_BOOT_REINDEXReconcile offline changes at startup by reindexing once the initial build completes. Set false on a large vault to start without paying a full filesystem scan per server start; changes made while no server was running are then invisible until a reindex runs (the reindex tool, or 'markdown-vault-mcp reindex'). Note that `index_stale` reports writer idleness, not agreement with disk, so it reads false while the index may still differ from the vault.MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRETsecret Shared secret for the GitHub push-event webhook; when set, mounts POST /github-webhook on HTTP/SSE transports to trigger an immediate pull + reindex on push events.MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKENsecret Signing token for the GitLab push-event webhook (GitLab 19.0+); when set, mounts POST /gitlab-webhook on HTTP/SSE transports to trigger an immediate pull + reindex on push events. GitLab generates this value; copy the `whsec_` token it shows under Generate signing token rather than inventing one. Deliveries are authenticated by HMAC-SHA256 over the webhook id, timestamp and body, and a delivery older than 5 minutes is rejected.MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKENsecret Secret token for the GitLab push-event webhook, GitLab's plain-text form and the only one below 19.0; also mounts POST /gitlab-webhook. It proves nothing about the body and cannot expire, so prefer the signing token where the GitLab version offers it. Setting both accepts either, which is how an existing webhook migrates.MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDERSummarization backend (only openai is recognised). Unset auto-detects: the backend activates when credentials or an explicit endpoint are present.MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEYsecret API key for the OpenAI-compatible summarize endpoint; the bare OPENAI_API_KEY is honoured as a fallback. Unset works for keyless local endpoints (Ollama).MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URLOpenAI-compatible endpoint base URL for the summarize tool; setting it enables the tool even without an API key. The bare OPENAI_BASE_URL routes traffic only when a key already enables the feature.MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_MODELChat model id used for summaries.MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_TOKENSUpper bound on generated tokens per summarize call; on reasoning models this budget also covers internal reasoning tokens.MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_NOTESCap on the number of notes summarised in one call (subtree expansion truncates to this many).MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_INPUT_CHARSAggregate cap on note characters sent to the model in one call; excess is truncated with a flag on the result.MARKDOWN_VAULT_MCP_SUMMARIZE_TIMEOUTPer-request wall-clock budget in seconds for a single summarize backend call; keep it below the MCP client's request timeout so the server-side error wins the race.MARKDOWN_VAULT_MCP_TRANSFER_TTL_DEFAULT_SLink lifetime in seconds when the caller requests no explicit TTL.MARKDOWN_VAULT_MCP_TRANSFER_TTL_MAX_SCeiling in seconds a caller-requested link TTL is clamped to.MARKDOWN_VAULT_MCP_TRANSFER_GRACE_TTL_SPost-success grace window in seconds: a served token's TTL shrinks to this so a stalled transfer can retry within it.MARKDOWN_VAULT_MCP_TRANSFER_LEASE_SCrashed-handler reclaim window in seconds for an in-flight reservation.MARKDOWN_VAULT_MCP_TRANSFER_MAX_UPLOAD_BYTESMaximum size in bytes of a single upload.MARKDOWN_VAULT_MCP_JOBS_SOFT_DEADLINE_SSeconds a long-running tool call may run in the foreground before it is promoted to a background job and a job handle is returned instead.MARKDOWN_VAULT_MCP_JOBS_RESULT_TTL_SSeconds a background-job record (working or finished) is retained for polling before it expires from the store.MARKDOWN_VAULT_MCP_JOBS_MAX_PER_SUBJECTMaximum live background jobs per calling subject; further promotions are rejected until older records expire.
ghcr.io/pvliesdonk/markdown-vault-mcp:v5.1.0claude mcp add markdown-vault-mcp -e 'MARKDOWN_VAULT_MCP_SHUTDOWN_GRACE_S=3' -e 'MARKDOWN_VAULT_MCP_BASE_URL=<MARKDOWN_VAULT_MCP_BASE_URL>' -e 'MARKDOWN_VAULT_MCP_BEARER_TOKEN=<your markdown_vault_mcp_bearer_token>' -e 'MARKDOWN_VAULT_MCP_OIDC_CONFIG_URL=<MARKDOWN_VAULT_MCP_OIDC_CONFIG_URL>' -e 'MARKDOWN_VAULT_MCP_OIDC_CLIENT_ID=<MARKDOWN_VAULT_MCP_OIDC_CLIENT_ID>' -e 'MARKDOWN_VAULT_MCP_OIDC_CLIENT_SECRET=<your markdown_vault_mcp_oidc_client_secret>' -e 'MARKDOWN_VAULT_MCP_OIDC_AUDIENCE=<MARKDOWN_VAULT_MCP_OIDC_AUDIENCE>' -e 'MARKDOWN_VAULT_MCP_OIDC_REQUIRED_SCOPES=openid' -e 'MARKDOWN_VAULT_MCP_OIDC_ADVERTISED_SCOPES=openid offline_access' -e 'MARKDOWN_VAULT_MCP_OIDC_JWT_SIGNING_KEY=<your markdown_vault_mcp_oidc_jwt_signing_key>' -e 'MARKDOWN_VAULT_MCP_OIDC_VERIFY_ACCESS_TOKEN=false' -e 'MARKDOWN_VAULT_MCP_KV_STORE_URL=file:///data/state' -e 'MARKDOWN_VAULT_MCP_APP_DOMAIN=<MARKDOWN_VAULT_MCP_APP_DOMAIN>' -e 'MARKDOWN_VAULT_MCP_TOOLS_ALLOW=<MARKDOWN_VAULT_MCP_TOOLS_ALLOW>' -e 'MARKDOWN_VAULT_MCP_TOOLS_DENY=<MARKDOWN_VAULT_MCP_TOOLS_DENY>' -e 'MARKDOWN_VAULT_MCP_AUTH_MODE=<MARKDOWN_VAULT_MCP_AUTH_MODE>' -e 'MARKDOWN_VAULT_MCP_BEARER_TOKENS_FILE=<MARKDOWN_VAULT_MCP_BEARER_TOKENS_FILE>' -e 'MARKDOWN_VAULT_MCP_BEARER_DEFAULT_SUBJECT=bearer-anon' -e 'MARKDOWN_VAULT_MCP_SERVER_NAME=<MARKDOWN_VAULT_MCP_SERVER_NAME>' -e 'MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION=<MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION>' -e 'MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA=<MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA>' -e 'MARKDOWN_VAULT_MCP_INSTRUCTIONS=<MARKDOWN_VAULT_MCP_INSTRUCTIONS>' -e 'MARKDOWN_VAULT_MCP_HTTP_PATH=/mcp' -e 'MARKDOWN_VAULT_MCP_HEALTH_DETAIL=standard' -e 'PUID=1000' -e 'PGID=1000' -e 'MARKDOWN_VAULT_MCP_LOG_LEVEL=INFO' -e 'MARKDOWN_VAULT_MCP_LOG_FORMAT=<MARKDOWN_VAULT_MCP_LOG_FORMAT>' -e 'OLLAMA_HOST=http://localhost:11434' -e 'OPENAI_API_KEY=<your openai_api_key>' -e 'VOYAGE_API_KEY=<your voyage_api_key>' -e 'OPENAI_BASE_URL=<OPENAI_BASE_URL>' -e 'OPENAI_EMBEDDING_MODEL=<OPENAI_EMBEDDING_MODEL>' -e 'MARKDOWN_VAULT_MCP_BUILD_TIMEOUT_S=60' -e 'MARKDOWN_VAULT_MCP_DRAIN_TIMEOUT_S=60' -e 'MARKDOWN_VAULT_MCP_SOURCE_DIR=/data/vault' -e 'MARKDOWN_VAULT_MCP_READ_ONLY=false' -e 'MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTING=true' -e 'MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKS=false' -e 'MARKDOWN_VAULT_MCP_DISABLE_APPS_UI=false' -e 'MARKDOWN_VAULT_MCP_INDEX_PATH=<MARKDOWN_VAULT_MCP_INDEX_PATH>' -e 'MARKDOWN_VAULT_MCP_STATE_PATH=<MARKDOWN_VAULT_MCP_STATE_PATH>' -e 'MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH=<MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH>' -e 'MARKDOWN_VAULT_MCP_INDEXED_FIELDS=<MARKDOWN_VAULT_MCP_INDEXED_FIELDS>' -e 'MARKDOWN_VAULT_MCP_REQUIRED_FIELDS=<MARKDOWN_VAULT_MCP_REQUIRED_FIELDS>' -e 'MARKDOWN_VAULT_MCP_EXCLUDE=<MARKDOWN_VAULT_MCP_EXCLUDE>' -e 'MARKDOWN_VAULT_MCP_TITLE_FIELD=title' -e 'MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS=<MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS>' -e 'MARKDOWN_VAULT_MCP_TEMPLATES_FOLDER=_templates' -e 'MARKDOWN_VAULT_MCP_PROMPTS_FOLDER=<MARKDOWN_VAULT_MCP_PROMPTS_FOLDER>' -e 'MARKDOWN_VAULT_MCP_CONVENTIONS_FILE=_conventions.md' -e 'MARKDOWN_VAULT_MCP_OKF_MODE=auto' -e 'MARKDOWN_VAULT_MCP_OKF_WRITE=false' -e 'MARKDOWN_VAULT_MCP_OKF_VERIFY=elicit' -e 'MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS=<MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS>' -e 'MARKDOWN_VAULT_MCP_MAX_ATTACHMENT_SIZE_MB=1.0' -e 'MARKDOWN_VAULT_MCP_MAX_NOTE_READ_BYTES=262144' -e 'MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODE=auto' -e 'MARKDOWN_VAULT_MCP_CHUNKS_PER_FILE=2' -e 'MARKDOWN_VAULT_MCP_SNIPPET_WORDS=200' -e 'MARKDOWN_VAULT_MCP_LENGTH_DOWNWEIGHT_ALPHA=0.25' -e 'MARKDOWN_VAULT_MCP_MAX_CHUNK_WORDS=400' -e 'MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS=<MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS>' -e 'MARKDOWN_VAULT_MCP_CHUNK_OVERLAP_WORDS=40' -e 'MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS=<MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS>' -e 'MARKDOWN_VAULT_MCP_FTS_WEIGHTS=<MARKDOWN_VAULT_MCP_FTS_WEIGHTS>' -e 'MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER=<MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER>' -e 'MARKDOWN_VAULT_MCP_OLLAMA_MODEL=nomic-embed-text' -e 'MARKDOWN_VAULT_MCP_OLLAMA_CPU_ONLY=false' -e 'MARKDOWN_VAULT_MCP_VOYAGE_MODEL=voyage-4' -e 'MARKDOWN_VAULT_MCP_OPENAI_BASE_URL=https://api.openai.com/v1' -e 'MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODEL=text-embedding-3-small' -e 'MARKDOWN_VAULT_MCP_FASTEMBED_MODEL=BAAI/bge-small-en-v1.5' -e 'MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR=<MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR>' -e 'MARKDOWN_VAULT_MCP_EMBED_CONTEXT=false' -e 'MARKDOWN_VAULT_MCP_EMBED_TIMEOUT_S=30.0' -e 'MARKDOWN_VAULT_MCP_EMBEDDING_BATCH_SIZE=4' -e 'MARKDOWN_VAULT_MCP_GIT_TOKEN=<your markdown_vault_mcp_git_token>' -e 'MARKDOWN_VAULT_MCP_GIT_REPO_URL=<MARKDOWN_VAULT_MCP_GIT_REPO_URL>' -e 'MARKDOWN_VAULT_MCP_GIT_USERNAME=x-access-token' -e 'MARKDOWN_VAULT_MCP_GIT_PULL_INTERVAL_S=600' -e 'MARKDOWN_VAULT_MCP_GIT_PUSH_DELAY_S=30.0' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME=markdown-vault-mcp' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL=noreply@markdown-vault-mcp' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM=<MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM>' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM=<MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM>' -e 'MARKDOWN_VAULT_MCP_GIT_LFS=true' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER=true' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER_DEBOUNCE_S=2.0' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER_ROOT_FLOOR=true' -e 'MARKDOWN_VAULT_MCP_BOOT_REINDEX=true' -e 'MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRET=<your markdown_vault_mcp_github_webhook_secret>' -e 'MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKEN=<your markdown_vault_mcp_gitlab_webhook_signing_token>' -e 'MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKEN=<your markdown_vault_mcp_gitlab_webhook_secret_token>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER=<MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY=<your markdown_vault_mcp_summarize_openai_api_key>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL=<MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_MODEL=gpt-5-mini' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_TOKENS=8192' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_NOTES=50' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_INPUT_CHARS=200000' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_TIMEOUT=120.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_TTL_DEFAULT_S=3600.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_TTL_MAX_S=86400.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_GRACE_TTL_S=60.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_LEASE_S=60.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_MAX_UPLOAD_BYTES=104857600' -e 'MARKDOWN_VAULT_MCP_JOBS_SOFT_DEADLINE_S=25.0' -e 'MARKDOWN_VAULT_MCP_JOBS_RESULT_TTL_S=3600.0' -e 'MARKDOWN_VAULT_MCP_JOBS_MAX_PER_SUBJECT=256' -- docker run -i --rm ghcr.io/pvliesdonk/markdown-vault-mcp:v5.1.0 --port
{
"mcpServers": {
"markdown-vault-mcp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/pvliesdonk/markdown-vault-mcp:v5.1.0",
"--port"
],
"env": {
"MARKDOWN_VAULT_MCP_SHUTDOWN_GRACE_S": "3",
"MARKDOWN_VAULT_MCP_BASE_URL": "<MARKDOWN_VAULT_MCP_BASE_URL>",
"MARKDOWN_VAULT_MCP_BEARER_TOKEN": "<your markdown_vault_mcp_bearer_token>",
"MARKDOWN_VAULT_MCP_OIDC_CONFIG_URL": "<MARKDOWN_VAULT_MCP_OIDC_CONFIG_URL>",
"MARKDOWN_VAULT_MCP_OIDC_CLIENT_ID": "<MARKDOWN_VAULT_MCP_OIDC_CLIENT_ID>",
"MARKDOWN_VAULT_MCP_OIDC_CLIENT_SECRET": "<your markdown_vault_mcp_oidc_client_secret>",
"MARKDOWN_VAULT_MCP_OIDC_AUDIENCE": "<MARKDOWN_VAULT_MCP_OIDC_AUDIENCE>",
"MARKDOWN_VAULT_MCP_OIDC_REQUIRED_SCOPES": "openid",
"MARKDOWN_VAULT_MCP_OIDC_ADVERTISED_SCOPES": "openid offline_access",
"MARKDOWN_VAULT_MCP_OIDC_JWT_SIGNING_KEY": "<your markdown_vault_mcp_oidc_jwt_signing_key>",
"MARKDOWN_VAULT_MCP_OIDC_VERIFY_ACCESS_TOKEN": "false",
"MARKDOWN_VAULT_MCP_KV_STORE_URL": "file:///data/state",
"MARKDOWN_VAULT_MCP_APP_DOMAIN": "<MARKDOWN_VAULT_MCP_APP_DOMAIN>",
"MARKDOWN_VAULT_MCP_TOOLS_ALLOW": "<MARKDOWN_VAULT_MCP_TOOLS_ALLOW>",
"MARKDOWN_VAULT_MCP_TOOLS_DENY": "<MARKDOWN_VAULT_MCP_TOOLS_DENY>",
"MARKDOWN_VAULT_MCP_AUTH_MODE": "<MARKDOWN_VAULT_MCP_AUTH_MODE>",
"MARKDOWN_VAULT_MCP_BEARER_TOKENS_FILE": "<MARKDOWN_VAULT_MCP_BEARER_TOKENS_FILE>",
"MARKDOWN_VAULT_MCP_BEARER_DEFAULT_SUBJECT": "bearer-anon",
"MARKDOWN_VAULT_MCP_SERVER_NAME": "<MARKDOWN_VAULT_MCP_SERVER_NAME>",
"MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION": "<MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION>",
"MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA": "<MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA>",
"MARKDOWN_VAULT_MCP_INSTRUCTIONS": "<MARKDOWN_VAULT_MCP_INSTRUCTIONS>",
"MARKDOWN_VAULT_MCP_HTTP_PATH": "/mcp",
"MARKDOWN_VAULT_MCP_HEALTH_DETAIL": "standard",
"PUID": "1000",
"PGID": "1000",
"MARKDOWN_VAULT_MCP_LOG_LEVEL": "INFO",
"MARKDOWN_VAULT_MCP_LOG_FORMAT": "<MARKDOWN_VAULT_MCP_LOG_FORMAT>",
"OLLAMA_HOST": "http://localhost:11434",
"OPENAI_API_KEY": "<your openai_api_key>",
"VOYAGE_API_KEY": "<your voyage_api_key>",
"OPENAI_BASE_URL": "<OPENAI_BASE_URL>",
"OPENAI_EMBEDDING_MODEL": "<OPENAI_EMBEDDING_MODEL>",
"MARKDOWN_VAULT_MCP_BUILD_TIMEOUT_S": "60",
"MARKDOWN_VAULT_MCP_DRAIN_TIMEOUT_S": "60",
"MARKDOWN_VAULT_MCP_SOURCE_DIR": "/data/vault",
"MARKDOWN_VAULT_MCP_READ_ONLY": "false",
"MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTING": "true",
"MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKS": "false",
"MARKDOWN_VAULT_MCP_DISABLE_APPS_UI": "false",
"MARKDOWN_VAULT_MCP_INDEX_PATH": "<MARKDOWN_VAULT_MCP_INDEX_PATH>",
"MARKDOWN_VAULT_MCP_STATE_PATH": "<MARKDOWN_VAULT_MCP_STATE_PATH>",
"MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH": "<MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH>",
"MARKDOWN_VAULT_MCP_INDEXED_FIELDS": "<MARKDOWN_VAULT_MCP_INDEXED_FIELDS>",
"MARKDOWN_VAULT_MCP_REQUIRED_FIELDS": "<MARKDOWN_VAULT_MCP_REQUIRED_FIELDS>",
"MARKDOWN_VAULT_MCP_EXCLUDE": "<MARKDOWN_VAULT_MCP_EXCLUDE>",
"MARKDOWN_VAULT_MCP_TITLE_FIELD": "title",
"MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS": "<MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS>",
"MARKDOWN_VAULT_MCP_TEMPLATES_FOLDER": "_templates",
"MARKDOWN_VAULT_MCP_PROMPTS_FOLDER": "<MARKDOWN_VAULT_MCP_PROMPTS_FOLDER>",
"MARKDOWN_VAULT_MCP_CONVENTIONS_FILE": "_conventions.md",
"MARKDOWN_VAULT_MCP_OKF_MODE": "auto",
"MARKDOWN_VAULT_MCP_OKF_WRITE": "false",
"MARKDOWN_VAULT_MCP_OKF_VERIFY": "elicit",
"MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS": "<MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS>",
"MARKDOWN_VAULT_MCP_MAX_ATTACHMENT_SIZE_MB": "1.0",
"MARKDOWN_VAULT_MCP_MAX_NOTE_READ_BYTES": "262144",
"MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODE": "auto",
"MARKDOWN_VAULT_MCP_CHUNKS_PER_FILE": "2",
"MARKDOWN_VAULT_MCP_SNIPPET_WORDS": "200",
"MARKDOWN_VAULT_MCP_LENGTH_DOWNWEIGHT_ALPHA": "0.25",
"MARKDOWN_VAULT_MCP_MAX_CHUNK_WORDS": "400",
"MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS": "<MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS>",
"MARKDOWN_VAULT_MCP_CHUNK_OVERLAP_WORDS": "40",
"MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS": "<MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS>",
"MARKDOWN_VAULT_MCP_FTS_WEIGHTS": "<MARKDOWN_VAULT_MCP_FTS_WEIGHTS>",
"MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER": "<MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER>",
"MARKDOWN_VAULT_MCP_OLLAMA_MODEL": "nomic-embed-text",
"MARKDOWN_VAULT_MCP_OLLAMA_CPU_ONLY": "false",
"MARKDOWN_VAULT_MCP_VOYAGE_MODEL": "voyage-4",
"MARKDOWN_VAULT_MCP_OPENAI_BASE_URL": "https://api.openai.com/v1",
"MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODEL": "text-embedding-3-small",
"MARKDOWN_VAULT_MCP_FASTEMBED_MODEL": "BAAI/bge-small-en-v1.5",
"MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR": "<MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR>",
"MARKDOWN_VAULT_MCP_EMBED_CONTEXT": "false",
"MARKDOWN_VAULT_MCP_EMBED_TIMEOUT_S": "30.0",
"MARKDOWN_VAULT_MCP_EMBEDDING_BATCH_SIZE": "4",
"MARKDOWN_VAULT_MCP_GIT_TOKEN": "<your markdown_vault_mcp_git_token>",
"MARKDOWN_VAULT_MCP_GIT_REPO_URL": "<MARKDOWN_VAULT_MCP_GIT_REPO_URL>",
"MARKDOWN_VAULT_MCP_GIT_USERNAME": "x-access-token",
"MARKDOWN_VAULT_MCP_GIT_PULL_INTERVAL_S": "600",
"MARKDOWN_VAULT_MCP_GIT_PUSH_DELAY_S": "30.0",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME": "markdown-vault-mcp",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL": "noreply@markdown-vault-mcp",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM": "<MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM>",
"MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM": "<MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM>",
"MARKDOWN_VAULT_MCP_GIT_LFS": "true",
"MARKDOWN_VAULT_MCP_FILE_WATCHER": "true",
"MARKDOWN_VAULT_MCP_FILE_WATCHER_DEBOUNCE_S": "2.0",
"MARKDOWN_VAULT_MCP_FILE_WATCHER_ROOT_FLOOR": "true",
"MARKDOWN_VAULT_MCP_BOOT_REINDEX": "true",
"MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRET": "<your markdown_vault_mcp_github_webhook_secret>",
"MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKEN": "<your markdown_vault_mcp_gitlab_webhook_signing_token>",
"MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKEN": "<your markdown_vault_mcp_gitlab_webhook_secret_token>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER": "<MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY": "<your markdown_vault_mcp_summarize_openai_api_key>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL": "<MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL>",
"MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_MODEL": "gpt-5-mini",
"MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_TOKENS": "8192",
"MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_NOTES": "50",
"MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_INPUT_CHARS": "200000",
"MARKDOWN_VAULT_MCP_SUMMARIZE_TIMEOUT": "120.0",
"MARKDOWN_VAULT_MCP_TRANSFER_TTL_DEFAULT_S": "3600.0",
"MARKDOWN_VAULT_MCP_TRANSFER_TTL_MAX_S": "86400.0",
"MARKDOWN_VAULT_MCP_TRANSFER_GRACE_TTL_S": "60.0",
"MARKDOWN_VAULT_MCP_TRANSFER_LEASE_S": "60.0",
"MARKDOWN_VAULT_MCP_TRANSFER_MAX_UPLOAD_BYTES": "104857600",
"MARKDOWN_VAULT_MCP_JOBS_SOFT_DEADLINE_S": "25.0",
"MARKDOWN_VAULT_MCP_JOBS_RESULT_TTL_S": "3600.0",
"MARKDOWN_VAULT_MCP_JOBS_MAX_PER_SUBJECT": "256"
}
}
}
}
Variables d'environnement
MARKDOWN_VAULT_MCP_SHUTDOWN_GRACE_SSeconds SIGTERM may spend draining in-flight requests before the HTTP server exits. Keep it at or below the termination grace period the orchestrator allows. `0` drops in-flight requests immediately.MARKDOWN_VAULT_MCP_BASE_URLPublic base URL of the deployed server, for example `https://mcp.example.com`. Required for OIDC. Also the fallback source of the MCP Apps domain when `app_domain` is unset.MARKDOWN_VAULT_MCP_BEARER_TOKENsecret Single shared bearer token; enables bearer auth unless `bearer_tokens_file` is set, which takes precedence.MARKDOWN_VAULT_MCP_OIDC_CONFIG_URLOIDC discovery document URL, for example `https://auth.example.com/.well-known/openid-configuration`.MARKDOWN_VAULT_MCP_OIDC_CLIENT_IDOIDC client identifier registered with the provider.MARKDOWN_VAULT_MCP_OIDC_CLIENT_SECRETsecret OIDC client secret registered with the provider.MARKDOWN_VAULT_MCP_OIDC_AUDIENCEExpected `aud` claim; tokens issued for another audience are rejected.MARKDOWN_VAULT_MCP_OIDC_REQUIRED_SCOPESScopes a caller must present, space- or comma-separated. Defaults to `openid` in oidc-proxy mode.MARKDOWN_VAULT_MCP_OIDC_ADVERTISED_SCOPESScopes advertised to MCP clients in protected-resource metadata, space- or comma-separated. Overrides the default `openid offline_access`; `oidc_required_scopes` is always added on top. Set this when the registered client is not permitted `offline_access`, or to have clients request extra claim scopes (such as `groups`) without also requiring them in every token.MARKDOWN_VAULT_MCP_OIDC_JWT_SIGNING_KEYsecret Signing key for issued tokens; used in oidc-proxy mode only. When unset, the key is derived deterministically from `oidc_client_secret`, so tokens survive a restart. Rotating that secret then invalidates every issued token. Set this explicitly to decouple token validity from secret rotation. Generate with `openssl rand -hex 32`.MARKDOWN_VAULT_MCP_OIDC_VERIFY_ACCESS_TOKENValidate the access token instead of the id token.MARKDOWN_VAULT_MCP_KV_STORE_URLPersistent-state backend URL shared by every pvl-core subsystem that needs state. `memory://` is in-process and lost on restart; `file:///path` persists on one server; `redis://`, `dynamodb://` and `mongodb://` each need their matching extra. When unset, defaults to `file:///data/state` (the volume family Docker images mount), or to `memory://` (with a warning) on a host where that directory is not usable.MARKDOWN_VAULT_MCP_APP_DOMAINMCP Apps iframe domain, used for CSP sandboxing. Overrides the host derived from `base_url`.MARKDOWN_VAULT_MCP_TOOLS_ALLOWComma-separated explicit tool names this instance exposes; every other tool is hidden from listings and cannot be invoked. Names matching no registered tool are inert. Mutually exclusive with `tools_deny`. Takes effect through `apply_tool_visibility`.MARKDOWN_VAULT_MCP_TOOLS_DENYComma-separated explicit tool names hidden from this instance (absent from listings, cannot be invoked). Names matching no registered tool are inert. Mutually exclusive with `tools_allow`. Takes effect through `apply_tool_visibility`.MARKDOWN_VAULT_MCP_AUTH_MODEExplicit auth-mode override, accepting `remote` or `oidc-proxy` (case- and whitespace-insensitive). When unset the mode is auto-detected from which auth variables are set; the override exists because having all four OIDC variables set is ambiguous between those two modes. Other values are ignored with a warning.MARKDOWN_VAULT_MCP_BEARER_TOKENS_FILEPath to a TOML file mapping bearer tokens to subjects; overrides the single-token `bearer_token` mode.MARKDOWN_VAULT_MCP_BEARER_DEFAULT_SUBJECTSubject assigned to the single-token bearer mode; ignored when `bearer_tokens_file` is set, since mapped mode carries per-token subjects.MARKDOWN_VAULT_MCP_SERVER_NAMERename this server instance; defaults to the project name.MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTIONConcise routing context that distinguishes this deployment's material or responsibility.MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRADeployment-specific behavioral policy added to the generated MCP instructions.MARKDOWN_VAULT_MCP_INSTRUCTIONSLegacy: replaces all generated MCP instructions (deprecated; use _INSTANCE_DESCRIPTION for routing and _INSTRUCTIONS_EXTRA for policy).MARKDOWN_VAULT_MCP_HTTP_PATHMount path for the MCP endpoint; the health routes derive their prefix from it.MARKDOWN_VAULT_MCP_HEALTH_DETAILHow much the unauthenticated /health and /health/ready bodies say: status, standard (adds name, version and per-check verdicts), or full (adds redacted reasons; trusted networks only).PUIDRun the server process as this UID; the container entrypoint reassigns ownership of writable paths to match.PGIDRun the server process as this GID; pair with PUID to match the owner of a mounted volume.MARKDOWN_VAULT_MCP_LOG_LEVELLog level for every logger in the process, FastMCP's included (DEBUG / INFO / WARNING / ERROR / CRITICAL). The -v CLI flag overrides to DEBUG. The unprefixed FASTMCP_LOG_LEVEL still works for one major version and logs a deprecation warning.MARKDOWN_VAULT_MCP_LOG_FORMATLog rendering. rich is one colour event key=value line per record, for a terminal; json is one JSON object per record, for a collector. Unset picks rich when stderr is a terminal and json everywhere else, so a container or journald gets JSON with no configuration.OLLAMA_HOSTOllama server URL for the ollama embedding provider. Bare (not MARKDOWN_VAULT_MCP_-prefixed), matching the Ollama ecosystem convention.OPENAI_API_KEYsecret OpenAI API key for the openai embedding provider, and the fallback key for the summarize tool when MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY is unset. Bare (not MARKDOWN_VAULT_MCP_-prefixed), matching the OpenAI ecosystem convention.VOYAGE_API_KEYsecret Voyage AI API key for the voyage embedding provider. Bare (not MARKDOWN_VAULT_MCP_-prefixed), matching the OPENAI_API_KEY / OLLAMA_HOST convention. Setting it never auto-selects the provider; choose it explicitly with MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER=voyage.OPENAI_BASE_URLBare fallback for MARKDOWN_VAULT_MCP_OPENAI_BASE_URL (embeddings). For the summarize tool it only routes traffic when an API key already enables the feature; it never enables summarize by itself.OPENAI_EMBEDDING_MODELBare fallback for MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODEL.MARKDOWN_VAULT_MCP_BUILD_TIMEOUT_SMaximum seconds an index-backed tool or resource waits for the FTS index to become queryable during a cold-start background build before raising IndexUnavailableError(reason="timeout"). Increase for large vaults.MARKDOWN_VAULT_MCP_DRAIN_TIMEOUT_SMaximum seconds an index-querying read tool waits for the IndexWriter to drain when called with wait_for_pending_writes=true. On timeout the tool answers from the current index and reports index_stale=true in the response _meta.MARKDOWN_VAULT_MCP_SOURCE_DIRPath to the markdown vault directory. When it does not exist, or the server cannot access it, the server starts but every tool fails with a message saying which until it is fixed (managed git mode clones into it). Symbolic links inside the vault are followed on Python 3.13+.MARKDOWN_VAULT_MCP_READ_ONLYSet to true to hide the write tools (write, edit, append, delete, rename, move_folder, fetch, git_sync, the okf_* tools, create_upload_link) and serve a search-only vault.MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTINGRefuse a write that would overwrite an existing file when no if_match etag is supplied. Deliberate replacement still works: read the file first, then pass if_match. Unaffected: edit, append, delete, rename. Set to false to allow blind overwrites.MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKSSet to true to have write, edit and append list, under unresolved_links, the target of each link the call added that get_broken_links reports. Links the note already held are left out. Off by default, leaving those responses unchanged.MARKDOWN_VAULT_MCP_DISABLE_APPS_UIHide the MCP Apps UI tools (browse_vault, show_context) from the tool listing for clients that do not render MCP Apps panels.MARKDOWN_VAULT_MCP_INDEX_PATHPath to the SQLite FTS5 index file; unset keeps the index in memory. Set it for persistence across restarts.MARKDOWN_VAULT_MCP_STATE_PATHPath to the change-tracking state file. Defaults to INDEX_PATH plus .state.json (index.db.state.json beside index.db); without INDEX_PATH the state is kept in memory. Never written into the vault by default.MARKDOWN_VAULT_MCP_EMBEDDINGS_PATHBase path for the embeddings files. Defaults beside INDEX_PATH (index-db-embeddings.npy and .json beside index.db); without INDEX_PATH the vectors are kept in memory and rebuilt at each start. Setting it also lets the provider be auto-detected.MARKDOWN_VAULT_MCP_INDEXED_FIELDSComma-separated frontmatter fields promoted to the tag index for structured filtering. Changing it cold-rebuilds the index once on next startup; SEARCHABLE_FIELDS inherits this value when unset.MARKDOWN_VAULT_MCP_REQUIRED_FIELDSComma-separated frontmatter fields required on every document; documents missing any are excluded from the index.MARKDOWN_VAULT_MCP_EXCLUDEComma-separated glob patterns excluded from scanning, e.g. .obsidian/**,.trash/**.MARKDOWN_VAULT_MCP_TITLE_FIELDFrontmatter field used as the document title (falls back to title, the first H1, then the filename). Changing it cold-rebuilds the index once on next startup.MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDSComma-separated frontmatter fields whose text values become keyword-searchable and enrich first-chunk embeddings. Inherits INDEXED_FIELDS when unset; the sentinel none means filterable but not searchable. Changing it cold-rebuilds the index and re-embeds once on next startup.MARKDOWN_VAULT_MCP_TEMPLATES_FOLDERRelative folder where note templates live (used by the create_from_template prompt).MARKDOWN_VAULT_MCP_PROMPTS_FOLDERDirectory of .md prompt files that extend or override built-in prompts; a relative path is resolved against SOURCE_DIR.MARKDOWN_VAULT_MCP_CONVENTIONS_FILEFilename of the per-folder conventions files surfaced to clients at write time (bare .md filename without glob characters). Set to none to disable folder conventions.MARKDOWN_VAULT_MCP_OKF_MODEOKF (Open Knowledge Format) read semantics. With auto (the default), read annotations switch on when the vault declares an OKF version in its root index.md. Use off to disable OKF semantics entirely, or on to force them for an undeclared vault. Annotations are read-only; write behavior is never affected.MARKDOWN_VAULT_MCP_OKF_WRITEOKF (Open Knowledge Format) enforced write layer. When true on an OKF-active vault, the server stamps generated provenance on each write and clears any verified attestation when a note's content changes. It also keeps each written folder's log.md and index.md current, and exposes the okf_verify tool. Requires OKF_MODE to be auto or on (a true value with OKF_MODE=off is a config error). Off by default.MARKDOWN_VAULT_MCP_OKF_VERIFYHow the okf_verify tool attributes a human review. This applies only when OKF_WRITE is on, which gates the tool. With elicit (the default), okf_verify asks the human to confirm the review through an MCP elicitation, then records the attestation only on an affirmative reply. It fails closed when the client cannot elicit or the human declines, so a model holding the human's token cannot self-attest. Set trust-auth instead to attribute to a token's sub claim with no confirmation; it rejects static bearer credentials and other client-ID-only identities. This is safe only when the sole caller is a human-driven UI. Set off to hide the tool, leaving attestation to external tooling. A non-default value with OKF_WRITE off is a config error.MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONSComma-separated allowed attachment extensions (e.g. pdf,png,jpg); case and a leading dot are ignored, so PDF and .pdf name the same type. Use * to allow every non-markdown file. Unset selects the built-in allowlist. A link whose target has a listed extension is not part of the link graph; changing the list rebuilds the index once.MARKDOWN_VAULT_MCP_MAX_ATTACHMENT_SIZE_MBMaximum attachment size in MB returned by read / accepted by write; 0 disables the limit.MARKDOWN_VAULT_MCP_MAX_NOTE_READ_BYTESMaximum bytes returned by a full-document read of a note; use `read(path, section=…)` for partial reads. 0 disables the limit.MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODEMode used when a search call omits 'mode': auto, keyword, semantic, or hybrid. The default 'auto' picks hybrid when embeddings are configured and keyword when they are not. Pin 'keyword' to keep unqualified searches off the embedding provider (each hybrid or semantic search embeds the query, which costs an API call on a metered provider). A configured semantic/hybrid default also degrades to keyword without embeddings, so no setting can make a vault unsearchable; an explicit mode= argument is never downgraded.MARKDOWN_VAULT_MCP_CHUNKS_PER_FILEMaximum chunks returned per document in search results.MARKDOWN_VAULT_MCP_SNIPPET_WORDSWidth of the snippet window (words) in search results; 0 returns full chunk content.MARKDOWN_VAULT_MCP_LENGTH_DOWNWEIGHT_ALPHADown-weights longer chunks in ranking: score / (1 + alpha * log(chunk_count)).MARKDOWN_VAULT_MCP_MAX_CHUNK_WORDSWord cap per chunk; the adaptive chunker splits at deeper heading levels, then paragraph/word boundaries, to respect it. Match it to the embedding model's context. A reindex applies a new value.MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARSCharacter cap enforced alongside MAX_CHUNK_WORDS to bound token-dense chunks. Unset derives min(1500, model context * 2.8). Set a positive value for an exact cap, or -1 to scale with the model's full context (can exhaust memory on long-context models). A reindex applies a new value.MARKDOWN_VAULT_MCP_CHUNK_OVERLAP_WORDSWords of overlap between adjacent budget-split fragments of the same heading section (0 disables). A reindex applies a new value.MARKDOWN_VAULT_MCP_FOLDER_WEIGHTSFolder-prefix score multipliers (`prefix:weight` pairs, comma-separated, weights > 0) applied to all search modes; the deepest matching prefix wins (sessions:0.5 demotes sessions/**).MARKDOWN_VAULT_MCP_FTS_WEIGHTSPer-column BM25 weights (`column:weight` pairs, comma-separated, weights >= 0) for keyword ranking. Columns: path, title, folder, heading, content, summary.MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDEREmbedding provider: openai, voyage, ollama, or fastembed; setting it turns on search by meaning. Unset auto-detects from the environment (never voyage), but only when EMBEDDINGS_PATH is set. Any OpenAI-compatible endpoint works with openai plus OPENAI_BASE_URL; see the embeddings guide.MARKDOWN_VAULT_MCP_OLLAMA_MODELOllama embedding model name.MARKDOWN_VAULT_MCP_OLLAMA_CPU_ONLYForce Ollama to embed on CPU only.MARKDOWN_VAULT_MCP_VOYAGE_MODELVoyage AI embedding model name.MARKDOWN_VAULT_MCP_OPENAI_BASE_URLOpenAI-compatible API base URL for embeddings; the bare OPENAI_BASE_URL is honoured as a fallback.MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODELOpenAI-compatible embedding model name; the bare OPENAI_EMBEDDING_MODEL is honoured as a fallback.MARKDOWN_VAULT_MCP_FASTEMBED_MODELFastEmbed model name.MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIRFastEmbed model cache directory (in Docker, stored under /data/state/fastembed).MARKDOWN_VAULT_MCP_EMBED_CONTEXTEnrich embedding input with the note title, chunk heading, and (first chunk) searchable-field values. Flipping it re-embeds the whole vault once on next startup.MARKDOWN_VAULT_MCP_EMBED_TIMEOUT_SPer-request wall-clock budget in seconds for a single embedding HTTP call (OpenAI/Ollama). The local FastEmbed backend runs in-process with no network call and ignores this. CPU-only or large-model workloads may need 60-120 s; raise this if batches time out.MARKDOWN_VAULT_MCP_EMBEDDING_BATCH_SIZENumber of chunks sent per embedding request. Smaller batches shorten each request (useful under a tight timeout on slow models) at the cost of more round-trips.MARKDOWN_VAULT_MCP_GIT_TOKENsecret Token/password for HTTPS git auth; remotes must be HTTPS when set.MARKDOWN_VAULT_MCP_GIT_REPO_URLHTTPS remote URL for managed git mode: the server clones into an empty SOURCE_DIR on startup (or validates an existing origin) and enables the pull loop, auto-commit, and deferred push.MARKDOWN_VAULT_MCP_GIT_USERNAMEUsername for HTTPS git auth prompts (x-access-token for GitHub, oauth2 for GitLab, the account name for Bitbucket).MARKDOWN_VAULT_MCP_GIT_PULL_INTERVAL_SSeconds between git fetch + fast-forward update attempts; 0 disables periodic pull.MARKDOWN_VAULT_MCP_GIT_PUSH_DELAY_SSeconds of write-idle time before pushing; 0 pushes only on shutdown.MARKDOWN_VAULT_MCP_GIT_COMMIT_NAMEGit committer name for auto-commits, and the author name too unless an OIDC claim supplies one; set this in Docker where git config user.name is empty.MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAILGit committer email for auto-commits, and the author email too unless an OIDC claim supplies one.MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIMOIDC claim key used as the commit author name (e.g. name) when an OIDC token is present; the committer stays GIT_COMMIT_NAME. The claim is resolved when the tool call arrives and carried to the background commit, so it applies on every write. A configured claim the token does not carry is reported once at WARNING and the static identity is used.MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIMOIDC claim key used as the commit author email (e.g. email) when an OIDC token is present; the committer stays GIT_COMMIT_EMAIL. Resolved and carried the same way as the name claim.MARKDOWN_VAULT_MCP_GIT_LFSRun git lfs pull on startup to fetch LFS-tracked attachments; set to false for repos without LFS.MARKDOWN_VAULT_MCP_FILE_WATCHERWatch the vault for external filesystem changes; auto-disabled when git pull is active or a webhook can deliver (HTTP/SSE transports only). Requires the file-watcher extra.MARKDOWN_VAULT_MCP_FILE_WATCHER_DEBOUNCE_SSeconds of quiet after the last filesystem event before reindexing.MARKDOWN_VAULT_MCP_FILE_WATCHER_ROOT_FLOORKeep the non-recursive watch on the vault root; set false to register zero source-dir-rooted FSEvents streams (avoids repeated macOS access prompts on a home-rooted vault) at the cost of root-level files relying on scans.MARKDOWN_VAULT_MCP_BOOT_REINDEXReconcile offline changes at startup by reindexing once the initial build completes. Set false on a large vault to start without paying a full filesystem scan per server start; changes made while no server was running are then invisible until a reindex runs (the reindex tool, or 'markdown-vault-mcp reindex'). Note that `index_stale` reports writer idleness, not agreement with disk, so it reads false while the index may still differ from the vault.MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRETsecret Shared secret for the GitHub push-event webhook; when set, mounts POST /github-webhook on HTTP/SSE transports to trigger an immediate pull + reindex on push events.MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKENsecret Signing token for the GitLab push-event webhook (GitLab 19.0+); when set, mounts POST /gitlab-webhook on HTTP/SSE transports to trigger an immediate pull + reindex on push events. GitLab generates this value; copy the `whsec_` token it shows under Generate signing token rather than inventing one. Deliveries are authenticated by HMAC-SHA256 over the webhook id, timestamp and body, and a delivery older than 5 minutes is rejected.MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKENsecret Secret token for the GitLab push-event webhook, GitLab's plain-text form and the only one below 19.0; also mounts POST /gitlab-webhook. It proves nothing about the body and cannot expire, so prefer the signing token where the GitLab version offers it. Setting both accepts either, which is how an existing webhook migrates.MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDERSummarization backend (only openai is recognised). Unset auto-detects: the backend activates when credentials or an explicit endpoint are present.MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEYsecret API key for the OpenAI-compatible summarize endpoint; the bare OPENAI_API_KEY is honoured as a fallback. Unset works for keyless local endpoints (Ollama).MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URLOpenAI-compatible endpoint base URL for the summarize tool; setting it enables the tool even without an API key. The bare OPENAI_BASE_URL routes traffic only when a key already enables the feature.MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_MODELChat model id used for summaries.MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_TOKENSUpper bound on generated tokens per summarize call; on reasoning models this budget also covers internal reasoning tokens.MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_NOTESCap on the number of notes summarised in one call (subtree expansion truncates to this many).MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_INPUT_CHARSAggregate cap on note characters sent to the model in one call; excess is truncated with a flag on the result.MARKDOWN_VAULT_MCP_SUMMARIZE_TIMEOUTPer-request wall-clock budget in seconds for a single summarize backend call; keep it below the MCP client's request timeout so the server-side error wins the race.MARKDOWN_VAULT_MCP_TRANSFER_TTL_DEFAULT_SLink lifetime in seconds when the caller requests no explicit TTL.MARKDOWN_VAULT_MCP_TRANSFER_TTL_MAX_SCeiling in seconds a caller-requested link TTL is clamped to.MARKDOWN_VAULT_MCP_TRANSFER_GRACE_TTL_SPost-success grace window in seconds: a served token's TTL shrinks to this so a stalled transfer can retry within it.MARKDOWN_VAULT_MCP_TRANSFER_LEASE_SCrashed-handler reclaim window in seconds for an in-flight reservation.MARKDOWN_VAULT_MCP_TRANSFER_MAX_UPLOAD_BYTESMaximum size in bytes of a single upload.MARKDOWN_VAULT_MCP_JOBS_SOFT_DEADLINE_SSeconds a long-running tool call may run in the foreground before it is promoted to a background job and a job handle is returned instead.MARKDOWN_VAULT_MCP_JOBS_RESULT_TTL_SSeconds a background-job record (working or finished) is retained for polling before it expires from the store.MARKDOWN_VAULT_MCP_JOBS_MAX_PER_SUBJECTMaximum live background jobs per calling subject; further promotions are rejected until older records expire.
Documentation
Tirée du README du projet sur GitHub, actualisée chaque semaine. Les liens ouvrent GitHub.
Markdown Vault MCP
Generic markdown vault MCP with hybrid search
Documentation | Config wizard | PyPI | Docker
Give Claude, or any MCP client, a folder of Markdown notes to search, read and write. An Obsidian vault works as it is.
- Hybrid search. Keyword search with SQLite FTS5 and, once an embedding provider is configured, search by meaning, fused by Reciprocal Rank Fusion, with the vectors kept in files, SQLite or PostgreSQL. Results are short snippets;
readfetches the whole section. See Embeddings. - Frontmatter as data. YAML frontmatter fields become search filters, and long notes are split at their headings.
- Careful writes. The write tools (
write,edit,append,delete,rename,move_folder,fetch,git_sync, theokf_*tools,create_upload_link) are on by default and hidden whenMARKDOWN_VAULT_MCP_READ_ONLY=true. Replacing a file takes the etag from reading it, and per-folder_conventions.mdrules reach the client as it writes. - Git. Optional commit per write with a delayed push, pull or webhook sync, and history and diffs; an overwritten note can be read back at the revision it replaced. See Git integration.
- Links. Backlinks, outlinks, broken links and the path between two notes, for wikilinks and Markdown links alike, with interactive views in clients that render MCP Apps. With
MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKS=true,write,editandappendname each link they added that doesn't resolve. - Open Knowledge Format. OKF bundles are recognized, and results carry each note's type, status and trust tier. See OKF.
The tools reference lists every tool. The same engine is a Python library: see the Vault API.
Does it fit?
What the server can reach, what it changes and who gets in is set out in the security model; the block below says who it serves and where it stops.
It suits one person or a small team who keep notes as Markdown files and want Claude to search them, follow their links and write back into them, on their own machine or as a shared server. It reaches the vault folder, plus only what you configure: a git remote, an embedding or summarizing model, and the URLs a fetch call names.
What it assumes:
- One vault per server. Several vaults take one server each, for now (#1232); give each a
MARKDOWN_VAULT_MCP_SERVER_NAME. - Markdown is what gets searched. Other files, such as PDFs and images, can be read and written as attachments, but their contents are not indexed yet (#1234).
- Embeddings live in memory. Search by meaning holds every vector at 4 bytes × chunks × dimensions: about 70 MB for 23,000 chunks at 768 dimensions, about 900 MiB at ten times that and 1,024 dimensions. Memory, not query time, is the first limit (#1377).
- State sits on local disk. The index and embeddings are files, and the change-tracking file sits beside the index, never inside the vault. Without
MARKDOWN_VAULT_MCP_INDEX_PATH, the index and that file stay in memory and are rebuilt at each start.
Reach for something else for a corpus of hundreds of thousands of chunks (a vector database behind a retrieval pipeline), for mostly scanned or office documents (a document management system with text recognition), or for many users who must not see each other's notes (a multi-tenant knowledge platform): every caller the server admits gets every tool it exposes.
Quick start
Pick the client you use. Each line installs the released version; the Get started tutorials carry on from there.
Claude Desktop. Download the .mcpb bundle from the releases page and open it with Claude Desktop (or Settings › Extensions › Advanced settings › Install Extension…). Claude Desktop asks for the required settings itself. Tutorial.
Claude Code. Two commands inside Claude Code; the second asks for a scope. Tutorial.
/plugin marketplace add pvliesdonk/claude-plugins
/plugin install markdown-vault-mcp@pvliesdonk
A client that runs a command (stdio). To register it in Claude Code, see the Claude Code tutorial.
uv tool install "markdown-vault-mcp"
markdown-vault-mcp serve
A server for remote clients (streamable HTTP). A remote server connects the clients.
docker run --rm -p 8000:8000 --env-file .env ghcr.io/pvliesdonk/markdown-vault-mcp:latest
A compose.yml ships at the repository root and runs as-is: copy .env.example to .env, then docker compose up -d. Deploy covers authentication, OIDC, a reverse proxy and system packages (.deb/.rpm on the releases page). The server answers /health and /health/ready outside the MCP mount, and its get_server_info tool reports the running version.
The plain package covers keyword search, the write tools and git. Search by meaning, the file watcher, the summarize tool and keeping embeddings in PostgreSQL need extras; [all] installs every one:
uv tool install "markdown-vault-mcp[all]"
The Docker image, the .mcpb bundle and the Claude Code plugin already include them. Installation lists each extra.
Configuration
Everything is configured through environment variables with the MARKDOWN_VAULT_MCP_ prefix. The ones most installs set:
| Variable | Default | Required | Description |
|---|---|---|---|
MARKDOWN_VAULT_MCP_SOURCE_DIR | /data/vault | No | Path to the markdown vault directory. When it does not exist, or the server cannot access it, the server starts but every tool fails with a message saying which until it is fixed (managed git mode clones into it). Symbolic links inside the vault are followed on Python 3.13+. |
MARKDOWN_VAULT_MCP_READ_ONLY | false | No | Set to true to hide the write tools (write, edit, append, delete, rename, move_folder, fetch, git_sync, the okf_* tools, create_upload_link) and serve a search-only vault. |
MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTING | true | No | Refuse a write that would overwrite an existing file when no if_match etag is supplied. Deliberate replacement still works: read the file first, then pass if_match. Unaffected: edit, append, delete, rename. Set to false to allow blind overwrites. |
MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKS | false | No | Set to true to have write, edit and append list, under unresolved_links, the target of each link the call added that get_broken_links reports. Links the note already held are left out. Off by default, leaving those responses unchanged. |
MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODE | auto | No | Mode used when a search call omits 'mode': auto, keyword, semantic, or hybrid. The default 'auto' picks hybrid when embeddings are configured and keyword when they are not. Pin 'keyword' to keep unqualified searches off the embedding provider (each hybrid or semantic search embeds the query, which costs an API call on a metered provider). A configured semantic/hybrid default also degrades to keyword without embeddings, so no setting can make a vault unsearchable; an explicit mode= argument is never downgraded. |
MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER | (none) | No | Embedding provider: openai, voyage, ollama, or fastembed; setting it turns on search by meaning. Unset auto-detects from the environment (never voyage), but only when EMBEDDINGS_PATH is set or EMBEDDING_STORE=postgres. Any OpenAI-compatible endpoint works with openai plus OPENAI_BASE_URL; see the embeddings guide. |
MARKDOWN_VAULT_MCP_GIT_REPO_URL | (none) | No | HTTPS remote URL for managed git mode: the server clones into an empty SOURCE_DIR on startup (or validates an existing origin) and enables the pull loop, auto-commit, and deferred push. |
MARKDOWN_VAULT_MCP_FILE_WATCHER | true | No | Watch the vault for external filesystem changes; auto-disabled when git pull is active or a webhook can deliver (HTTP/SSE transports only). Requires the file-watcher extra. |
MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL | (none) | No | OpenAI-compatible endpoint base URL for the summarize tool; setting it enables the tool even without an API key. The bare OPENAI_BASE_URL routes traffic only when a key already enables the feature. |
Every variable the server reads, the shared ones included, is in the configuration reference; .env.example lists the same surface in copy-paste form, and the config wizard writes one for your deployment.
Documentation
- Security model: what the server can reach, what it changes and who gets in.
- Get started: a first success with your client.
- Deploy: Docker, authentication, OIDC, reverse proxy.
- Use: the features, for real tasks.
- Reference: configuration, tools, resources, prompts, command line.
- Upgrade: release channels, and what an upgrade changes for your clients and your data.
- Contribute: local development, secrets, where a fix belongs;
CONTRIBUTING.mdandSECURITY.mdat the root.
Design decisions
- Document identity is the relative path with
.mdextension; frontmatter is optional by default (REQUIRED_FIELDSopts into enforcement). - Hybrid search uses Reciprocal Rank Fusion over the FTS5 and vector result lists, with diversity-aware ranking capping chunks per document.
- Tool semantics mirror Claude Code's Read/Write/Edit patterns, so LLM clients drive the vault with habits they already have.
- The library is synchronous; the MCP layer wraps calls in
asyncio.to_thread(). File writes return after saving, while index updates run in the background. Index-dependent mutations wait for prior writes; see index freshness. - Indexing is hash-based: unchanged files are never re-parsed, and any change to how stored rows derive from a note's bytes bumps
INDEX_SEMANTICS_VERSIONso deployed vaults rebuild themselves once on upgrade.
The full decision log lives in the design document.
Links
- Documentation and its llms.txt
- FastMCP and fastmcp-pvl-core, which this server is built on
- fastmcp-server-template, which generated this repository
Questions fréquentes
Qu'est-ce que Markdown Vault MCP ?
Generic markdown vault MCP with hybrid search
Comment installer Markdown Vault MCP ?
Il s'exécute sur votre machine. Dans Claude Code : claude mcp add markdown-vault-mcp -e 'MARKDOWN_VAULT_MCP_KV_STORE_URL=file:///data/state' -e 'MARKDOWN_VAULT_MCP_TOOLS_ALLOW=<MARKDOWN_VAULT_MCP_TOOLS_ALLOW>' -e 'MARKDOWN_VAULT_MCP_TOOLS_DENY=<MARKDOWN_VAULT_MCP_TOOLS_DENY>' -e 'MARKDOWN_VAULT_MCP_SERVER_NAME=<MARKDOWN_VAULT_MCP_SERVER_NAME>' -e 'MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION=<MARKDOWN_VAULT_MCP_INSTANCE_DESCRIPTION>' -e 'MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA=<MARKDOWN_VAULT_MCP_INSTRUCTIONS_EXTRA>' -e 'MARKDOWN_VAULT_MCP_INSTRUCTIONS=<MARKDOWN_VAULT_MCP_INSTRUCTIONS>' -e 'MARKDOWN_VAULT_MCP_LOG_LEVEL=INFO' -e 'MARKDOWN_VAULT_MCP_LOG_FORMAT=<MARKDOWN_VAULT_MCP_LOG_FORMAT>' -e 'OLLAMA_HOST=http://localhost:11434' -e 'OPENAI_API_KEY=<your openai_api_key>' -e 'VOYAGE_API_KEY=<your voyage_api_key>' -e 'OPENAI_BASE_URL=<OPENAI_BASE_URL>' -e 'OPENAI_EMBEDDING_MODEL=<OPENAI_EMBEDDING_MODEL>' -e 'MARKDOWN_VAULT_MCP_BUILD_TIMEOUT_S=60' -e 'MARKDOWN_VAULT_MCP_DRAIN_TIMEOUT_S=60' -e 'MARKDOWN_VAULT_MCP_SOURCE_DIR=/data/vault' -e 'MARKDOWN_VAULT_MCP_READ_ONLY=false' -e 'MARKDOWN_VAULT_MCP_WRITE_PROTECT_EXISTING=true' -e 'MARKDOWN_VAULT_MCP_REPORT_UNRESOLVED_LINKS=false' -e 'MARKDOWN_VAULT_MCP_DISABLE_APPS_UI=false' -e 'MARKDOWN_VAULT_MCP_INDEX_PATH=<MARKDOWN_VAULT_MCP_INDEX_PATH>' -e 'MARKDOWN_VAULT_MCP_STATE_PATH=<MARKDOWN_VAULT_MCP_STATE_PATH>' -e 'MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH=<MARKDOWN_VAULT_MCP_EMBEDDINGS_PATH>' -e 'MARKDOWN_VAULT_MCP_INDEXED_FIELDS=<MARKDOWN_VAULT_MCP_INDEXED_FIELDS>' -e 'MARKDOWN_VAULT_MCP_REQUIRED_FIELDS=<MARKDOWN_VAULT_MCP_REQUIRED_FIELDS>' -e 'MARKDOWN_VAULT_MCP_EXCLUDE=<MARKDOWN_VAULT_MCP_EXCLUDE>' -e 'MARKDOWN_VAULT_MCP_TITLE_FIELD=title' -e 'MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS=<MARKDOWN_VAULT_MCP_SEARCHABLE_FIELDS>' -e 'MARKDOWN_VAULT_MCP_TEMPLATES_FOLDER=_templates' -e 'MARKDOWN_VAULT_MCP_PROMPTS_FOLDER=<MARKDOWN_VAULT_MCP_PROMPTS_FOLDER>' -e 'MARKDOWN_VAULT_MCP_CONVENTIONS_FILE=_conventions.md' -e 'MARKDOWN_VAULT_MCP_OKF_MODE=auto' -e 'MARKDOWN_VAULT_MCP_OKF_WRITE=false' -e 'MARKDOWN_VAULT_MCP_OKF_VERIFY=elicit' -e 'MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS=<MARKDOWN_VAULT_MCP_ATTACHMENT_EXTENSIONS>' -e 'MARKDOWN_VAULT_MCP_MAX_ATTACHMENT_SIZE_MB=1.0' -e 'MARKDOWN_VAULT_MCP_MAX_NOTE_READ_BYTES=262144' -e 'MARKDOWN_VAULT_MCP_DEFAULT_SEARCH_MODE=auto' -e 'MARKDOWN_VAULT_MCP_CHUNKS_PER_FILE=2' -e 'MARKDOWN_VAULT_MCP_SNIPPET_WORDS=200' -e 'MARKDOWN_VAULT_MCP_LENGTH_DOWNWEIGHT_ALPHA=0.25' -e 'MARKDOWN_VAULT_MCP_MAX_CHUNK_WORDS=400' -e 'MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS=<MARKDOWN_VAULT_MCP_MAX_CHUNK_CHARS>' -e 'MARKDOWN_VAULT_MCP_CHUNK_OVERLAP_WORDS=40' -e 'MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS=<MARKDOWN_VAULT_MCP_FOLDER_WEIGHTS>' -e 'MARKDOWN_VAULT_MCP_FTS_WEIGHTS=<MARKDOWN_VAULT_MCP_FTS_WEIGHTS>' -e 'MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER=<MARKDOWN_VAULT_MCP_EMBEDDING_PROVIDER>' -e 'MARKDOWN_VAULT_MCP_OLLAMA_MODEL=nomic-embed-text' -e 'MARKDOWN_VAULT_MCP_OLLAMA_CPU_ONLY=false' -e 'MARKDOWN_VAULT_MCP_VOYAGE_MODEL=voyage-4' -e 'MARKDOWN_VAULT_MCP_OPENAI_BASE_URL=https://api.openai.com/v1' -e 'MARKDOWN_VAULT_MCP_OPENAI_EMBEDDING_MODEL=text-embedding-3-small' -e 'MARKDOWN_VAULT_MCP_FASTEMBED_MODEL=BAAI/bge-small-en-v1.5' -e 'MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR=<MARKDOWN_VAULT_MCP_FASTEMBED_CACHE_DIR>' -e 'MARKDOWN_VAULT_MCP_EMBED_CONTEXT=false' -e 'MARKDOWN_VAULT_MCP_EMBED_TIMEOUT_S=30.0' -e 'MARKDOWN_VAULT_MCP_EMBEDDING_BATCH_SIZE=4' -e 'MARKDOWN_VAULT_MCP_GIT_TOKEN=<your markdown_vault_mcp_git_token>' -e 'MARKDOWN_VAULT_MCP_GIT_REPO_URL=<MARKDOWN_VAULT_MCP_GIT_REPO_URL>' -e 'MARKDOWN_VAULT_MCP_GIT_USERNAME=x-access-token' -e 'MARKDOWN_VAULT_MCP_GIT_PULL_INTERVAL_S=600' -e 'MARKDOWN_VAULT_MCP_GIT_PUSH_DELAY_S=30.0' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME=markdown-vault-mcp' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL=noreply@markdown-vault-mcp' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM=<MARKDOWN_VAULT_MCP_GIT_COMMIT_NAME_CLAIM>' -e 'MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM=<MARKDOWN_VAULT_MCP_GIT_COMMIT_EMAIL_CLAIM>' -e 'MARKDOWN_VAULT_MCP_GIT_LFS=true' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER=true' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER_DEBOUNCE_S=2.0' -e 'MARKDOWN_VAULT_MCP_FILE_WATCHER_ROOT_FLOOR=true' -e 'MARKDOWN_VAULT_MCP_BOOT_REINDEX=true' -e 'MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRET=<your markdown_vault_mcp_github_webhook_secret>' -e 'MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKEN=<your markdown_vault_mcp_gitlab_webhook_signing_token>' -e 'MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKEN=<your markdown_vault_mcp_gitlab_webhook_secret_token>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER=<MARKDOWN_VAULT_MCP_SUMMARIZE_PROVIDER>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY=<your markdown_vault_mcp_summarize_openai_api_key>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL=<MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_BASE_URL>' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_MODEL=gpt-5-mini' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_TOKENS=8192' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_NOTES=50' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_MAX_INPUT_CHARS=200000' -e 'MARKDOWN_VAULT_MCP_SUMMARIZE_TIMEOUT=120.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_TTL_DEFAULT_S=3600.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_TTL_MAX_S=86400.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_GRACE_TTL_S=60.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_LEASE_S=60.0' -e 'MARKDOWN_VAULT_MCP_TRANSFER_MAX_UPLOAD_BYTES=104857600' -e 'MARKDOWN_VAULT_MCP_JOBS_SOFT_DEADLINE_S=25.0' -e 'MARKDOWN_VAULT_MCP_JOBS_RESULT_TTL_S=3600.0' -e 'MARKDOWN_VAULT_MCP_JOBS_MAX_PER_SUBJECT=256' -- uvx markdown-vault-mcp==5.1.0. Pour les autres clients, collez la configuration JSON de cette page dans leurs réglages MCP.
Faut-il une clé API pour Markdown Vault MCP ?
Oui. Il attend OPENAI_API_KEY, VOYAGE_API_KEY, MARKDOWN_VAULT_MCP_GIT_TOKEN, MARKDOWN_VAULT_MCP_GITHUB_WEBHOOK_SECRET, MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SIGNING_TOKEN, MARKDOWN_VAULT_MCP_GITLAB_WEBHOOK_SECRET_TOKEN, MARKDOWN_VAULT_MCP_SUMMARIZE_OPENAI_API_KEY, MARKDOWN_VAULT_MCP_BEARER_TOKEN, MARKDOWN_VAULT_MCP_OIDC_CLIENT_SECRET, MARKDOWN_VAULT_MCP_OIDC_JWT_SIGNING_KEY, à renseigner dans sa configuration.
Markdown Vault MCP est-il open source ?
Oui. Son code est sur GitHub sous licence MIT.
Qui maintient Markdown Vault MCP ?
Il est publié par pvliesdonk. AI.tn le référence sans le maintenir ni le recommander.
Issu du registre MCP officiel. Être listé n'est pas une recommandation : vérifiez le code et les permissions d'un serveur avant de lui donner accès à vos données.