MCP Catalogs
首页

filesystem vs lean-ctx

并排对比,帮你在这两个 MCP server 之间做选择。

filesystem
by modelcontextprotocol
lean-ctx
by yvgude
Stars★ 85,748★ 1,676
30天用量
综合分7757
官方
分类
本地文件系统开发者工具效率工具
开发者工具AI / LLM 工具效率工具
实现语言TypeScriptRust
最近提交本月本月

filesystem · 概述

功能丰富的文件系统操作 MCP 服务器,具有动态目录访问控制功能。

lean-ctx · 概述

lean-ctx 是一个 MCP server,通过智能上下文压缩和缓存,在 AI 编码工具中减少 60-95% 的 token 消耗。

filesystem · 使用场景

  • 使 AI 模型能够读取和写入项目文件进行开发
  • 允许 Claude 或其他 MCP 客户端浏览和分析代码库
  • 为内容生成提供对特定目录的安全沙盒访问

lean-ctx · 使用场景

  • 在 AI 编码助手减少 token 使用同时保持完整上下文感知
  • 优化大型代码库和 monorepo 的上下文管理
  • 创建可共享的上下文包供团队协作使用

filesystem · 安装

安装

使用 NPX

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/path/to/allowed/directory"
      ]
    }
  }
}

使用 Docker

{
  "mcpServers": {
    "filesystem": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "--mount", "type=bind,src=/path/to/allowed/dir,dst=/projects/allowed/dir",
        "mcp/filesystem",
        "/projects"
      ]
    }
  }
}

VS Code 扩展

点击 README 中的安装按钮直接在 VS Code 中安装。

lean-ctx · 安装

使用以下方法之一安装 lean-ctx:

# 通用安装程序(不需要 Rust)
curl -fsSL https://leanctx.com/install.sh | sh

# macOS / Linux 通过 Homebrew
brew tap yvgude/lean-ctx && brew install lean-ctx

# Node.js
npm install -g lean-ctx-bin

# Rust
cargo install lean-ctx

# Pi 编码代理
pi install npm:pi-lean-ctx

安装后,设置:

lean-ctx setup

然后重启您的 shell 和 AI 工具。对于 Claude Desktop,添加到 config.json:

{
  "mcpServers": {
    "lean-ctx": {
      "command": "lean-ctx",
      "args": ["mcp"]
    }
  }
}
对比内容由 README + GitHub 公开数据自动生成,定期更新。