MCP.so
Sign In

mcp

@zhkzly

About mcp

mcp example from webset

Basic information

Category

Other

Runtime

python

Transports

stdio

Publisher

zhkzly

Config

No standard config provided

This server doesn't expose a parseable MCP config block in its README. See the repository for install instructions.

Repository

Tools

No tools detected

We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.

Overview

What is mcp?

mcp是一个MCP(Model Context Protocol)参考实现,演示如何通过客户端(如Cline)与LLM交互,并利用MCP server定义和调用自定义工具(Python脚本)。它基于微信文章和知乎链接的内容,补充了Cline客户端配置和Gemini模型的使用示例。

How to use mcp?

克隆仓库后安装uv(https://docs.astral.sh/uv/getting-started/installation/),用uv run script.py自动管理环境。在VS Code中安装Cline插件,选择合适的LLM模型,在Cline的MCP Server配置中添加绝对路径的命令,例如/Users/{username}/.local/bin/uv --directory /Users/{username}... run txt_counter.py。也可直接运行脚本并修改端口。

Key features of mcp

  • 通过MCP server定义可调用的Python工具
  • 支持多种客户端(如Cline、自定义client)
  • 可配合Gemini等LLM使用
  • 提供prompt模板和参数定义能力
  • 工具示例包含计算、数据爬取等

Use cases of mcp

  • 在VS Code中通过Cline让LLM调用自定义Python工具
  • 学习如何配置MCP客户端与LLM交互
  • 将已有的Python脚本快速封装为MCP工具供LLM使用
  • 利用prompt模板标准化与LLM的交互流程

FAQ from mcp

mcp server的主要作用是什么?

server用于生成工具,工具示例位于/src/calculate.py/src/datawale.py中,是LLM可调用的具体功能。

如何配置Cline中的MCP server command?

command必须使用绝对路径,相对路径会导致错误。典型格式为/Users/{username}/.local/bin/uv --directory /Users/{username}... run txt_counter.py

需要安装哪些运行时依赖?

需要安装uv(Python包管理器),它会自动在项目目录下的./.venv中创建环境并安装依赖。

有哪些可选的MCP客户端?

README提到llms-full.txt中列出了可选的client列表,此外也可以自己编写客户端(参考src/mcp_client.py和Python SDK快速入门)。

如何运行server以支持工具调用?

需要持续运行server以便与LLM通信。可以通过在Cline配置中使用uv run命令,或者直接运行脚本(需自行修改端口)。

Comments

More Other MCP servers