TurboVault
   
终极Rust SDK和高性能MCP服务器,适用于黑曜石口味的Markdown(.ofm)和标准.md保管库。
TurboVault是一个为开发人员和用户设计的两用工具包。它提供了一个强大的模块化 Rust SDK 用于构建使用markdown目录的应用程序,以及 全功能MCP服务器 它与Claude和其他人工智能代理一起开箱即用。
______________________________________________________________________
使用TurboVault的两种方法
1.作为Rust SDK(面向开发人员)
使用我们的模块化机箱构建您自己的应用程序、搜索引擎或自定义MCP服务器。TurboVault处理解析的繁重任务 .md 和 .ofm 文件、构建知识图和管理多vault环境。
- 模块化架构:只使用你需要的东西(解析器、图形、搜索等)。
- 高性能:大多数任务的操作低于1000毫秒。
- 可扩展:在我们的核心逻辑之上轻松构建自己的专用MCP服务器。
- SOTA标准:完全支持黑曜石口味的Markdown(维基链接、嵌入、标注)。
2.作为即用型MCP服务器(面向用户)
立即将您的黑曜石金库转化为智能知识系统。将TurboVault连接到Claude Desktop或任何兼容MCP的客户端,以获得 47种专用工具 为了你的笔记。
- 需要零编码:安装二进制文件并将其指向您的保管库。
- 47专用工具:搜索、链接分析、SQL frontmatter查询、健康检查等。
- 多保险库支持:在运行时无缝切换个人笔记和工作笔记。
______________________________________________________________________
核心板条箱(SDK)
TurboVault是一个由专用板条箱组成的模块化系统。您可以依赖各个组件来构建自己的工具:
| 箱子 | 目的 | 文件 |
|---|
为什么选择TurboVault?
与基本的笔记阅读器不同,TurboVault了解您的金库 知识结构:
- 全文搜索 在所有BM25排名的笔记中
- 链接图分析 发现关系、中心、孤儿和周期
- 保险库情报 具有健康评分和自动推荐功能
- 原子批处理操作 用于安全、事务性的多文件编辑
- 多保险库支持 具有即时上下文切换功能
- 运行库添加 --启动时不需要保管库,可根据需要添加
由TurboMCP提供动力
TurboVault基于 TurboMCP,一个用于构建生产级MCP服务器的Rust框架。TurboMCP提供:
- 类型安全工具定义 --宏驱动的MCP工具实现
- 标准化请求/响应处理 --一致的信封格式
- 运输抽象 --HTTP、WebSocket、TCP、Unix套接字(可配置功能)
- 中间件支持 --日志记录、指标、错误处理
- 零拷贝流媒体 --高效的大有效载荷处理
这意味着TurboVault开箱即用,具有久经考验的可靠性和可扩展性。想要添加自定义工具吗?TurboMCP的人体工程学宏使其变得简单明了。
快速开始
安装
来自crates.io
# Minimal install (7.0 MB, STDIO only - perfect for Claude Desktop)
cargo install turbovault
# With HTTP server (~8.2 MB)
cargo install turbovault --features http
# With all cross-platform transports (~8.8 MB)
# Includes: STDIO, HTTP, WebSocket, TCP (Unix sockets only on Unix/macOS/Linux)
cargo install turbovault --features full
# With SQL frontmatter queries (adds GlueSQL-powered query_frontmatter_sql tool)
cargo install turbovault --features sql
# Binary installed to: ~/.cargo/bin/turbovault来源:
git clone https://github.com/epistates/turbovault.git
cd turbovault
make release
# Binary: ./target/release/turbovault选项1:静态保险库(建议用于单个保险库)
turbovault --vault /path/to/your/vault --profile production然后添加到 ~/.config/claude/claude_desktop_config.json:
{
"mcpServers": {
"turbovault": {
"command": "/path/to/turbovault",
"args": ["--vault", "/path/to/your/vault", "--profile", "production"]
}
}
}选项2:运行时保险库添加(建议用于多个保险库)
在没有vault的情况下启动服务器:
turbovault --profile production然后动态添加保险库:
{
"mcpServers": {
"turbovault": {
"command": "/path/to/turbovault",
"args": ["--profile", "production"]
}
}
}一旦连接到克劳德:
You: "Add my vault at ~/Documents/Notes"
Claude: [Calls add_vault("personal", "~/Documents/Notes")]
You: "Search for machine learning notes"
Claude: [Uses search() across the indexed vault]
You: "What are my most important notes?"
Claude: [Uses get_hub_notes() to find key concepts]克劳德能做什么?
搜索与发现
You: "Find all notes about async Rust and show how they connect"
Claude: search() -> recommend_related() -> get_related_notes() -> explain relationships保险库智能
You: "What's the health of my vault? Any issues I should fix?"
Claude: quick_health_check() -> full_health_analysis() -> get_broken_links() -> generate fixes知识图谱导航
You: "What are my most important notes? Which ones are isolated?"
Claude: get_hub_notes() -> get_isolated_clusters() -> suggest connections结构化笔记创建
You: "Create a project note for the TurboVault launch with status tracking"
Claude: list_templates() -> create_from_template() -> write auto-formatted note批量内容操作
You: "Move my 'MLOps' note to 'AI/Operations' and update all links"
Claude: move_note() + batch operations -> atomic multi-file update链接建议
You: "Based on my vault, what notes should I link this to?"
Claude: suggest_links() -> get_link_strength() -> recommend cross-references47 MCP工具按类别组织
文件操作(5)
read_note--使用哈希获取笔记内容以进行冲突检测write_note--创建/覆盖笔记(自动创建目录)edit_note--通过搜索/替换块进行手术编辑delete_note--使用链接跟踪进行安全删除move_note--通过自动更新维基链接重命名/重新定位
链接分析(6)
get_backlinks--链接到此笔记的所有笔记get_forward_links--此笔记链接到的所有笔记get_related_notes--多跳图遍历(查找不明显的连接)get_hub_notes--十大最相关笔记(关键概念)get_dead_end_notes--带有传入链接但没有传出链接的笔记get_isolated_clusters--vault中已断开连接的子图
保险库健康与分析(5)
quick_health_check--快速0-100健康评分(\ anyhow::Result {
// 1. Initialize the MultiVault manager let manager = MultiVaultManager::new();
// 2. Add and initialize a vault (scans files, builds graph) manager.add_vault("notes", "/home/user/notes").await?;
// 3. Perform high-level operations let vault = manager.get_vault("notes")?; let results = vault.search("machine learning")?;
// 4. Use these components to build your own custom MCP server // or integrate into existing Rust applications. Ok(()) }
每个crate都发布到crates.io,因此您可以依赖单个组件或整个堆栈。
## 建筑
构建为模块化Rust工作区:
turbovault-core — Core types, MultiVaultManager, configuration turbovault-parser — OFM (Obsidian Flavored Markdown) parsing turbovault-graph — Link graph analysis with petgraph turbovault-vault — Vault operations, file I/O, atomic writes turbovault-batch — Transactional batch operations turbovault-export — JSON/CSV/Markdown export turbovault-sql — SQL frontmatter queries (GlueSQL, feature-gated) turbovault-tools — 47 MCP tool implementations turbovault (binary) — CLI and MCP server entry point
所有板条箱均已发布至 [克拉特斯.io](https://crates.io/crates/turbovault-core) 供公众使用。
## 黑曜石风味Markdown(OFM)支持
TurboVault完全理解Obsidian的语法:
- **维基链接**: `[[note]]`, `[[note|alias]]`, `[[note#section]]`, `[[note#^block]]`
- **派遣**: `![[image.png]]`, `![[note]]`, `![[note#section]]`
- **标签**: `#tag`, `#parent/child/tag`
- **任务**: `- [ ] Task`, `- [x] Done`
- **标注**: `> [!type] Title`
- **前言**:具有自动解析功能的YAML元数据
- **标题**:层次结构提取
## 安全
- **路径遍历保护** --保险库边界外无访问权限
- **类型安全反序列化** --Rust的类型系统可防止注入
- **原子写入** --临时文件→ 原子重命名(失败时不会损坏)
- **基于哈希的冲突检测** — `edit_note` 检测并发修改
- **文件大小限制** --默认每个文件5MB(可配置)
- **不执行shell** --零指令注入风险
- **安全审计** --生产模式下的详细日志
## 系统要求
- **锈**:1.90.0或更高版本
- **操作系统**:Linux、macOS、Windows
- **记忆**:100MB基本+每10k张约80MB
- **磁盘**:可忽略(索引在内存中)
## 从源头构建
git clone https://github.com/epistates/turbovault.git cd turbovault
Development build
cargo build
Production build (optimized)
cargo build --release
Run tests
cargo test --all
或者使用Makefile:
make build # Debug build make release # Production build make test # Run tests make clean # Clean build artifacts
## 文档
[文档](./docs/README.md)
## 例子
### 示例1:搜索驱动型组织
You: "What topics do I have the most notes on?" Claude: 1. get_hub_notes() -> [AI, Project Management, Rust, Python] 2. For each hub: - get_related_notes() -> related topics - get_backlinks() -> importance/connectivity 3. Report: "Your core topics are AI (23 notes) and Rust (18 notes)"
### 示例2:保险库健康改善
You: "My vault feels disorganized. Help me improve it." Claude: 1. quick_health_check() -> Health: 42/100 2. full_health_analysis() -> Issues: 12 broken links, 8 orphaned notes 3. get_broken_links() -> List of specific broken links 4. suggest_links() -> AI-powered link recommendations 5. batch_execute() -> Atomic fixes 6. explain_vault() -> New health: 78/100
### 示例3:基于模板的内容创建
You: "Create project notes for Q4 initiatives" Claude: 1. list_templates() -> "project", "task", "meeting" 2. create_from_template("project", { "title": "Q4 Planning", "status": "In Progress", "deadline": "2024-12-31" }) 3. Creates structured note with auto-formatting 4. Returns path for follow-up edits
## 基准测试
M1 MacBook Pro,10k笔记,生产版本:
- **文件的读取**:\<10ms
- **文件写入**:\<20ms
- **简单搜索**:\<50ms
- **图分析**:\<200ms
- **保险库初始化**:~500ms
- **内存使用**:~80MB
## 路线图
- \[\]实时金库监控(VaultWatcher框架就绪)
- \[\]跨vault链接解析
- \[\]加密保管库支持
- \[\]协同锁定
- \[\]WebSocket传输(超出MCP stdio)
## 贡献
欢迎投稿!请确保:
- 所有测试均通过: `cargo test --all`
- 代码格式: `cargo fmt --all`
- 无剪贴警告: `cargo clippy --all -- -D warnings`
## 许可证
MIT许可证-请参阅 [许可证](LICENSE) 详情
## 链接
- **仓库**: https://github.com/epistates/turbovault
- **问题**: https://github.com/epistates/turbovault/issues
- **MCP协议**: https://modelcontextprotocol.io
- **黑曜石**: https://obsidian.md
- **相关**: [TurboMCP](https://github.com/epistates/turbomcp)
______________________________________________________________________
**立即开始**: `./target/release/turbovault --profile production`