Skip to main content
Glama
VaultBridge MCP

VaultBridge MCP

by UDvoid

VaultBridge MCP

CI Python 3.10+ Zero Runtime Dependencies License: MIT

Zero-dependency, local-first MCP server for Markdown & Obsidian vaults.

Give Claude Code, Cursor, Codex, and Gemini CLI fast, structured, read-only access to your local Markdown knowledge base — powered purely by Python 3.10+ standard library and SQLite FTS5.

  • Zero Runtime Dependencies: Pure Python stdlib (sqlite3, json, pathlib, re, hashlib, argparse). No pip dependency tree, no vector DB daemon, no Node runtime required.

  • Bilingual FTS5 Retrieval: Weighted BM25 full-text search across English, Chinese (CJK), and mixed technical notes — including 2-character Chinese terms.

  • Incremental Indexing: Fast mtime + sha256 change detection skips untouched files and resolves Obsidian WikiLinks ([[Note]], [[Note|Alias]], [[Note#Heading]]), YAML frontmatter, headings, and #tags.

  • Secure by Default: Strict path-traversal blocking, symlink escape rejection, and built-in exclusion of .git/, .obsidian/, .vaultbridge/, Credentials/, .env*, and private keys.


Architecture

  Markdown / Obsidian Vault
  ├── README.md
  ├── projects/
  │   └── architecture.md   (YAML frontmatter, #headings, [[WikiLinks]], #tags)
  └── [BLOCKED: .git/, .obsidian/, Credentials/, .env*, *.key, ../]
                │
                ▼
  ┌──────────────────────────────────────────────────────────┐
  │  vaultbridge.indexer  (Pure Python 3.10+ stdlib)         │
  │  • mtime + sha256 incremental scanner                    │
  │  • YAML frontmatter, heading tree, WikiLink & tag parser │
  │  • CJK + English FTS5 tokenizer + BM25 ranking           │
  └───────────────────────────┬──────────────────────────────┘
                              │  .vaultbridge/index.db (SQLite WAL + FTS5)
                              ▼
  ┌──────────────────────────────────────────────────────────┐
  │  vaultbridge.server  (MCP stdio JSON-RPC 2.0)            │
  │  vb_brief │ vb_search │ vb_get │ vb_related │ vb_status  │
  └───────────────────────────┬──────────────────────────────┘
                              │  stdin / stdout (NDJSON)
                              ▼
     Claude Code  •  Cursor  •  Codex  •  Gemini CLI

Related MCP server: obsidian-vault-mcp

30-Second Quick Start

1. Install

# Editable local install (zero runtime dependencies)
pip install -e .

# Or run directly from source with zero installation
PYTHONPATH=src python3 -m vaultbridge --version

2. Initialize & Index Your Vault

vaultbridge init --vault /path/to/your/vault
vaultbridge doctor --vault /path/to/your/vault

3. Try It in Your Terminal

# High-signal vault overview
vaultbridge brief --vault /path/to/your/vault

# Bilingual English + Chinese FTS5 search
vaultbridge search "architecture 架构" --vault /path/to/your/vault

# Start MCP stdio server
vaultbridge serve --vault /path/to/your/vault

MCP Client Configuration

Replace /path/to/your/vault with the absolute path to your Markdown or Obsidian vault.

Claude Code

Add via CLI:

claude mcp add vaultbridge -- vaultbridge serve --vault /path/to/your/vault

Or add to .mcp.json / ~/.claude.json:

{
  "mcpServers": {
    "vaultbridge": {
      "command": "vaultbridge",
      "args": ["serve", "--vault", "/path/to/your/vault"]
    }
  }
}

Cursor

Add to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global):

{
  "mcpServers": {
    "vaultbridge": {
      "command": "vaultbridge",
      "args": ["serve", "--vault", "/path/to/your/vault"]
    }
  }
}

OpenAI Codex CLI

Add to ~/.codex/config.toml:

[mcp_servers.vaultbridge]
command = "vaultbridge"
args = ["serve", "--vault", "/path/to/your/vault"]

Gemini CLI

Add to ~/.gemini/settings.json:

{
  "mcpServers": {
    "vaultbridge": {
      "command": "vaultbridge",
      "args": ["serve", "--vault", "/path/to/your/vault"]
    }
  }
}

Running directly from a cloned repo without pip install? Use "command": "python3", "args": ["-m", "vaultbridge", "serve", "--vault", "/path/to/your/vault"], and set "env": { "PYTHONPATH": "/path/to/vaultbridge-mcp/src" }.


Exposed MCP Tools

Tool

Purpose

Key Arguments

vb_brief

One-call vault orientation: stats, folders, top tags, entry/MOC notes, recent notes, and optional topic hits.

topic?, max_notes?

vb_search

Weighted SQLite FTS5 BM25 search supporting English, Chinese (CJK), and mixed queries.

query, limit?, tag?, path_prefix?

vb_get

Read a verified vault-relative Markdown note (full, by heading section, or by line range) with strict boundary checks.

path, heading?, start_line?, end_line?, max_chars?

vb_related

Traverse outgoing WikiLinks, incoming backlinks, shared-tag neighbors, and same-folder peers.

path, limit?

vb_status

Report index health, note/link/tag counts, SQLite FTS5 readiness, staleness, and optional incremental re-index.

check_stale?, reindex?


CLI Reference

vaultbridge init   --vault /path/to/vault          # Create .vaultbridge/config.json and initial index
vaultbridge index  --vault /path/to/vault [--force] # Incremental (or full) FTS5 index update
vaultbridge search "query" --vault /path/to/vault  # Full-text search (--tag, --path-prefix, --json)
vaultbridge brief  [topic] --vault /path/to/vault  # Compact vault or topic briefing (--json)
vaultbridge serve  --vault /path/to/vault          # Start MCP stdio JSON-RPC 2.0 server
vaultbridge doctor --vault /path/to/vault          # Verify Python, FTS5, DB integrity, and security guards

Environment variables VAULTBRIDGE_VAULT and VAULTBRIDGE_DB can also be used instead of --vault and --db.


Security & Privacy Model

VaultBridge Core is strictly local and read-only over MCP:

  • No network calls, no telemetry, no external embeddings API.

  • Path Traversal Defense: vb_get and vb_related reject absolute paths, .. segments, null bytes, non-Markdown targets, and symlinks resolving outside the vault root.

  • Default Sensitive Exclusions: Directories .git/, .obsidian/, .vaultbridge/, .trash/, Credentials/, .secrets/, secrets/, .ssh/, .gnupg/, node_modules/, .venv/ and files .env, .env.*, *.pem, *.key, *.p12, *.pfx, *.secret, id_rsa*, id_ed25519* are excluded from both indexing and reads.

  • Custom Exclusions: Add a .vaultbridgeignore file at the vault root using standard glob patterns.


Development & Tests

Run the full zero-dependency test suite (including a real subprocess MCP stdio JSON-RPC 2.0 end-to-end test):

PYTHONPATH=src python3 -m unittest discover -s tests -v

Also compatible with pytest:

PYTHONPATH=src pytest -v

VaultBridge Core vs. Pro

VaultBridge Core is open-source (MIT) and designed to remain fast, self-contained, and genuinely useful on its own. For power users running multi-agent knowledge workflows across multiple tools, an optional VaultBridge Pro add-on builds on top of the same local-first philosophy:

Capability

VaultBridge Core (MIT)

VaultBridge Pro ($29 One-Time)

Local SQLite FTS5 incremental indexing (EN + CJK)

Included

Included

5 read-only MCP tools (vb_brief, vb_search, vb_get, vb_related, vb_status)

Included

Included

Path traversal & sensitive-directory protection

Included

Included

CLI (init, index, search, brief, serve, doctor)

Included

Included

5-client non-destructive config merger (setup: Claude Code, Cursor, Codex, Gemini CLI, Windsurf)

—

Included

38-rule + Shannon entropy secret_guard scanner & local git pre-commit hooks (zero plaintext echo)

—

Included

Structured capture write pipeline (proposal/decision/handoff/inbox, --supersedes, --commit)

—

Included

Ready-to-use Obsidian Starter Vault & cross-client AI rules templates (init-vault)

—

Included

VaultBridge Pro (v1.0.0 — $29 one-time) checkout via Creem.io is going live shortly — star/watch this repository or follow @udvoid for the live release link.


License

MIT License — Copyright (c) 2026 UDvoid. See LICENSE.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      Not graded
      maintenance
      Enables AI clients like Claude Desktop to search your local Obsidian vault notes via full-text search.
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables read-only, filesystem-based access to Obsidian vault Markdown notes, including full-text search, title/path search, and frontmatter or tag metadata lookup, all without running Obsidian or using a plugin/REST API.
      23 npm
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Gives AI agents fast, read-only access to a local knowledge base of Markdown notes and other text documents via a SQLite full-text index. Enables ranked section-level search, reading whole notes or single sections, heading outlines, note listing, and link/backlink navigation without slow disk walks.
      Apache 2.0
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI agents to run semantic search over local Obsidian or Markdown vaults, returning notes ranked by meaning with paths, headings, scores, and snippets, and to trigger incremental reindexing of changed notes. Everything runs on the user's own machine, so no note content leaves it.
      MIT