mcpField
A
Assistant MCP Server

Assistant MCP Server

本地服务
github.com/nodlabAI 与智能体270 周前更新

关于 Assistant MCP Server

Assistant MCP Server 是面向开发的 MCP 服务,README 介绍了项目设置和工具配置示例。它适用于将工具接入 MCP 服务的开发者;现有资料未说明更多功能。

主要功能

  1. 01在 tools.json 中配置工具
  2. 02使用 yarn 构建
  3. 03作为本地 MCP 服务连接

适用场景

  1. 01搭建本地开发用 MCP 服务
  2. 02为前端架构项目配置工具

MCP 相关

Assistant MCP Server 是可通过 MCP 客户端配置进行本地连接的 MCP 服务。README 提供了用于获取前端应用架构信息的 architecture_info 工具示例。

配置

本地服务的配置在各客户端中通用,复制后粘贴到客户端的 MCP 配置文件即可。

mcp.json · 通用配置
{
"mcpServers": {
"assistant": {
"command": "npx",
"args": [
"-y",
"tsx"
],
"env": {
"TOOLS_PATH": "<TOOLS_PATH>"
}
}
}
}
启动命令npx -y tsx
需要配置的环境变量
TOOLS_PATH

本地服务需要在你的电脑上安装运行环境(如 Node.js 18+)。各客户端的配置文件位置不同,请参考客户端文档。

安装包
npmtsx

工具

还没有获取到工具列表

本地服务需要在你的电脑上运行后才能读取工具,维护者暂未提供工具列表。

详细介绍

Assistant MCP Server

开发

克隆仓库后,运行以下命令安装依赖:

yarn install

你还应将 tools.json 文件添加到项目根目录,例如:

{
  "tools": [
    {
      "name": "architecture_info",
      "description": "Obtaining mandatory information about the architecture of frontend application projects",
      "inputSchema": {},
      "plugin": {
        "name": "file",
        "args": {
          "path": "/path/to/folder/public/architecture.md"
        }
      }
    },
    {
      "name": "search_tasks",
      "description": "Before executing this function, you must retrieve the project architecture information from 'architecture_info'. This is mandatory information and you must respect it. After that you need to find the task you are talking about, analyze what needs to be done and implement it in the project according to the architecture and requirements. You don't need to invent anything additional from yourself, just what is required",
      "inputSchema": {},
      "plugin": {
        "name": "file",
        "args": {
          "path": "/path/to/folder/public/tasks.txt"
        }
      }
    },
    {
        "name": "optimize_prompt",
        "description": "Generates a final, structured prompt for the AI model based on the provided context sections and instructions. This tool should be called after all relevant data has been collected. The result is intended to be used as the FINAL prompt for the AI. Clients must use the returned prompt as the input for the AI model.",
        "inputSchema": {
          "type": "object",
          "properties": {
            "sections": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "title": { "type": "string" },
                  "content": { "type": "string" }
                },
                "required": ["title", "content"]
              }
            },
            "instructions": { "type": "string" }
          },
          "required": ["sections"]
        },
        "plugin": {
          "name": "promptOptimizer",
          "args": {}
        }
      }
  ]
}

要构建项目,必须执行以下命令:

yarn build
连接到本地服务
{
  "mcpServers": {
    "mcp-assistant-local": {
      "command": "npx",
      "args": [
        "tsx",
        "/path/to/folder/src/index.ts"
      ],
      "env": {
        "TOOLS_PATH": "/path/to/folder/tools.json"
      }
    }
  }
}

许可证

此 MCP 服务采用 MIT License 许可。这意味着你可以自由使用、修改和分发该软件,但须遵守 MIT License 的条款和条件。更多详情请参阅项目仓库中的 LICENSE 文件。

评论

支持 Markdown

第一次接触 MCP?

从协议是什么,到在客户端里装上第一个服务,这几条回答覆盖了大多数入门问题。

一个开放协议,规定了 AI 应用如何以统一方式连接外部工具与数据源。客户端负责与模型对话,MCP 服务负责提供工具、资源和提示模板,两者通过标准消息通信,同一个服务可以被不同客户端复用。