Skip to content

Commit fbac3b3

Browse files
authored
Merge pull request #13 from MiniMax-AI/dev/format_code
feat: format dependencies and tool desc
2 parents a075768 + 358fdd9 commit fbac3b3

6 files changed

Lines changed: 23 additions & 353 deletions

File tree

mcp_server_config_demo.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"minimax-coding-plan-mcp"
77
],
88
"env": {
9-
"MINIMAX_API_KEY": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiYWRtaW4iOnRydWUsImlhdCI6MTc0NTM3NjU1N30.nrmwo6orXJfyf63IqJCK4LiUXrq9r9ZELCY530Mu6sLyx_qNAVsJ3Q828Rqy6pwoQl6VFMMFaJG3kc6aIMEfVLo7xlB-4NbwMxYKhwtxyQL8g_agYqw-1aY4zr3uvgTZxafXt1dEjcuS5i9O9SuOXXofeqb0jAnb_dssaLfgHNKlKthJpjsg8G76ZULS7KCpm6GvPWR4mwIdH-i0IhBU6CVSWpBAYKVNHJ-FVN_HzN5UgGvHkDbOOggg6Ib1illYbx6zkb7_JYZ7Tek1erjvJi7IG8Keh4NHq5kcyROWBetO9W8_2if_nfO6XBhlJRECpEmYBONwroGw0nH6xNblQw",
9+
"MINIMAX_API_KEY": "sk-cp-test123",
1010
"MINIMAX_API_HOST": "https://api.minimax.chat"
1111
}
1212
}

minimax_mcp/server.py

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,18 @@
4040
@mcp.tool(
4141
description="""
4242
43-
Web Search API, works like Google Search.
43+
You MUST use this tool whenever you need to search for real-time or external information on the web.
44+
45+
A web search API that works just like Google Search.
4446
4547
Args:
46-
query (str): The search query string. Use 3-5 keywords. Add the current date for time-sensitive queries, e.g. `latest iPhone 2025`
48+
query (str): The search query. Aim for 3-5 keywords for best results. For time-sensitive topics, include the current date (e.g. `latest iPhone 2025`).
4749
4850
Search Strategy:
49-
- If no valid results found, try changing search keywords
51+
- If no useful results are returned, try rephrasing your query with different keywords.
5052
5153
Returns:
52-
Text content with search results in JSON format. The response structure is:
54+
A JSON object containing the search results, structured as follows:
5355
{
5456
"organic": [
5557
{
@@ -102,26 +104,28 @@ def web_search(
102104
@mcp.tool(
103105
description="""
104106
105-
A powerful LLM that can analyze and understand image content from files or URLs, follow your instruction.
106-
Use this tool to understand images by LLM.
107-
Only support jpeg, png, webp formats. Other formats like pdf/gif/psd/svg and so on are not supported.
107+
You MUST use this tool whenever you need to analyze, describe, or extract information from an image,
108+
including when you get an image from user input or any task-related image.
109+
110+
An LLM-powered vision tool that can analyze and interpret image content from local files or URLs based on your instructions.
111+
Only JPEG, PNG, and WebP formats are supported. Other formats (e.g. PDF, GIF, PSD, SVG) are not supported.
108112
109113
Args:
110-
prompt (str): The text prompt describing what you want to analyze or extract from the image.
111-
image_source (str): The source location of the image to analyze.
114+
prompt (str): A text prompt describing what you want to analyze or extract from the image.
115+
image_source (str): The location of the image to analyze.
112116
Accepts:
113117
- HTTP/HTTPS URL: "https://example.com/image.jpg"
114118
- Local file path:
115119
- Relative path: "images/photo.png"
116120
- Absolute path: "/Users/username/Documents/image.jpg"
117-
IMPORTANT: If the file path starts with @ symbol, you MUST remove the @ prefix before passing to this function.
121+
IMPORTANT: If the file path starts with an @ symbol, you MUST strip the @ prefix before passing it to this function.
118122
For example:
119-
- If you see "@Documents/photo.jpg", use "Documents/photo.jpg"
120-
- If you see "@/Users/username/image.png", use "/Users/username/image.png"
123+
- "@Documents/photo.jpg" "Documents/photo.jpg"
124+
- "@/Users/username/image.png" "/Users/username/image.png"
121125
Supported formats: JPEG, PNG, WebP
122126
123127
Returns:
124-
Text content with the image analysis result.
128+
A text description of the image analysis result.
125129
"""
126130
)
127131
def understand_image(

minimax_mcp/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import base64
33
import requests
44
from minimax_mcp.const import *
5-
from minimax_mcp.exceptions import MinimaxMcpError, MinimaxRequestError
5+
from minimax_mcp.exceptions import MinimaxRequestError
66

77

88

pyproject.toml

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "minimax-coding-plan-mcp"
3-
version = "0.0.3"
3+
version = "0.0.4"
44
description = "Specialized MiniMax Model Context Protocol (MCP) server designed for coding-plan users"
55
authors = [
66
{ name = "Roy Wu", email = "zhengyu@minimax.chat" },
@@ -23,15 +23,7 @@ keywords = [
2323
requires-python = ">=3.10"
2424
dependencies = [
2525
"mcp[cli]>=1.6.0",
26-
"fastapi>=0.109.2",
27-
"uvicorn>=0.27.1",
2826
"python-dotenv>=1.0.1",
29-
"pydantic>=2.6.1",
30-
"httpx>=0.28.1",
31-
"fuzzywuzzy>=0.18.0",
32-
"python-Levenshtein>=0.25.0",
33-
"sounddevice>=0.5.1",
34-
"soundfile>=0.13.1",
3527
"requests>=2.31.0",
3628
]
3729

scripts/dev.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/bin/bash
2-
uv run fastmcp dev minimax_mcp/server.py --with python-dotenv --with fuzzywuzzy --with python-Levenshtein --with sounddevice --with soundfile --with-editable .
2+
uv run --extra dev fastmcp dev minimax_mcp/server.py

0 commit comments

Comments
 (0)