Skip to content

Commit c9fc207

Browse files
committed
chore: remove empty name parameter from mcp.tool decorator
1 parent 336bb8c commit c9fc207

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

apps/common/utils/tool_code.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ def _generate_mcp_server_code(self, _code, params, name=None, description=None):
184184

185185
func_code = ast.unparse(node)
186186
# 有些模型不支持name是中文,例如: deepseek, 其他模型未知
187-
functions.append(f"@mcp.tool(name='', description='{description}')\n{func_code}\n")
187+
functions.append(f"@mcp.tool(description='{description}')\n{func_code}\n")
188188
else:
189189
other_code.append(ast.unparse(node))
190190

0 commit comments

Comments
 (0)