SmartDazi commited on
Commit
a86a48b
·
verified ·
1 Parent(s): 6c35761

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +55 -0
README.md CHANGED
@@ -48,6 +48,61 @@ As of now, MiniCPM4-MCP supports the following:
48
 
49
  - Cross-tool-calling capability: It can perform single- or multi-step tool calls using different tools that complies with the MCP.
50
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
51
  ## Evaluation
52
  The detailed evaluation script can be found on the [GitHub](https://github.com/OpenBMB/MiniCPM/tree/main/demo/minicpm4/MCP) page. The evaluation results are presented below.
53
 
 
48
 
49
  - Cross-tool-calling capability: It can perform single- or multi-step tool calls using different tools that complies with the MCP.
50
 
51
+
52
+ ## Inference
53
+
54
+ ### MCP Servers Deployment
55
+
56
+ The MCP Servers supported by MiniCPM4-MCP include
57
+ [Airbnb](https://github.com/openbnb-org/mcp-server-airbnb),
58
+ [Amap-Maps](https://github.com/zxypro1/amap-maps-mcp-server),
59
+ [Arxiv-MCP-Server](https://github.com/blazickjp/arxiv-mcp-server),
60
+ [Calculator](https://github.com/githejie/mcp-server-calculator),
61
+ [Computer-Control-MCP](https://github.com/AB498/computer-control-mcp),
62
+ [Desktop-commander](https://github.com/wonderwhy-er/DesktopCommanderMCP),
63
+ [Filesystem](https://github.com/mark3labs/mcp-filesystem-server),
64
+ [Github](https://github.com/modelcontextprotocol/servers/tree/main/src/github),
65
+ [Gaode](https://github.com/perMAIN/gaode),
66
+ [MCP-Code-Executor](https://github.com/bazinga012/mcp_code_executor),
67
+ [MCP-DOCx](https://github.com/MeterLong/MCP-Doc),
68
+ [PPT](https://github.com/GongRzhe/Office-PowerPoint-MCP-Server),
69
+ [PPTx](https://github.com/supercurses/powerpoint),
70
+ [Simple-Time-Server](https://github.com/andybrandt/mcp-simple-timeserver),
71
+ [Slack](https://github.com/modelcontextprotocol/servers/tree/main/src/slack), and
72
+ [Whisper](https://github.com/arcaputo3/mcp-server-whisper). Follow the instructions provided in each server's repository for successful deployment. Note that not all tools in these servers will function properly in every environment. Some tools are unstable and may return errors such as timeouts or HTTP errors. During training data construction, tools with consistently high failure rates (e.g., those for which the LLM fails to produce a successful query even after hundreds of attempts) are filtered out.
73
+
74
+ ### MCP Client Setup
75
+
76
+ We modified the existing MCP Client from the [mcp-cli](https://github.com/chrishayuk/mcp-cli) repository to enable interaction between MiniCPM and MCP Servers.
77
+ After the MCP Client performs a handshake with a Server, it retrieves a list of available tools. An example of tool information contained in this list is provided in [`available_tool_example.json`](https://github.com/OpenBMB/MiniCPM/blob/main/demo/minicpm4/MCP/available_tool_example.json).
78
+
79
+ Once the available tools and user query are obtained, results can be generated using the following script logic:
80
+
81
+ ```bash
82
+ python generate_example.py \
83
+ --tokenizer_path {path to MiniCPM4 tokenizer} \
84
+ --base_url {vllm deployment URL} \
85
+ --model {model name used in vllm deployment} \
86
+ --output_path {path to save results}
87
+ ```
88
+ where the `generate_example.py` is located in [link](https://github.com/OpenBMB/MiniCPM/blob/main/demo/minicpm4/MCP/generate_example.py) and MiniCPM4 generates tool calls in the following format:
89
+
90
+ ```
91
+ <|tool_call_start|>
92
+ ```python
93
+ read_file(path="/path/to/file")
94
+ ```
95
+ <|tool_call_end|>
96
+ ```
97
+ You can build a custom parser for MiniCPM4 tool calls based on this format. The relevant parsing logic is located in `generate_example.py`.
98
+
99
+ Since the [mcp-cli](https://github.com/chrishayuk/mcp-cli) repository supports the vLLM inference framework, MiniCPM4-MCP can also be integrated into `mcp-cli` by modifying vLLM accordingly.
100
+ Specifically, follow the instructions in [this link](https://github.com/OpenBMB/MiniCPM/tree/main/demo/minicpm3/function_call) to enable interaction between a client running the MiniCPM4-MCP model and the MCP Server.
101
+
102
+
103
+
104
+
105
+
106
  ## Evaluation
107
  The detailed evaluation script can be found on the [GitHub](https://github.com/OpenBMB/MiniCPM/tree/main/demo/minicpm4/MCP) page. The evaluation results are presented below.
108