一切搜索 MCP 服务器
MCP 服务器提供与 Everything Search Engine 的集成,通过模型上下文协议实现强大的文件搜索功能。
特征
- 跨文件和目录的全文搜索
- 高级搜索选项:
- 排序选项:
- 结果格式:
先决条件
- Node.js 16 或更高版本
- 启用 HTTP 服务器的 Everything 搜索引擎
一切搜索配置
- 打开所有搜索
- 转至工具 > 选项 > HTTP 服务器
- 启用 HTTP 服务器
- 将 HTTP 服务器端口设置为 8011(这是此 MCP 服务器使用的默认端口)
- 单击“确定”保存更改
注意:如果需要使用其他端口,则需要修改src/server.ts
中连接到http://127.0.0.1:8011/
端口
安装
npm install
npm run build
用法
服务器通过 MCP 提供单一工具:
use_mcp_tool:
- server_name: everything-search
- tool_name: search
- arguments:
{
"query": "search string", // Required: Text to search for
"scope": "C:", // Optional: Search scope (default: C:)
"caseSensitive": false, // Optional: Match case
"wholeWord": false, // Optional: Match whole words only
"regex": false, // Optional: Use regular expressions
"path": false, // Optional: Search in paths
"maxResults": 100, // Optional: Max results (1-1000, default: 100)
"sortBy": "name", // Optional: Sort by name/path/size/date_modified
"ascending": true // Optional: Sort direction
}
示例搜索
- 基本文件搜索:
{
"query": "*.txt",
"maxResults": 5
}
- 带有过滤器的高级搜索:
{
"query": "test",
"scope": "C:\\Users",
"caseSensitive": true,
"wholeWord": true,
"maxResults": 10,
"sortBy": "date_modified",
"ascending": false
}
- 正则表达式在路径中搜索:
{
"query": ".*\\.js$",
"regex": true,
"path": true,
"maxResults": 5
}
执照
国际学习中心