{"id":53951,"date":"2025-08-12T20:00:00","date_gmt":"2025-08-12T12:00:00","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/53951.html"},"modified":"2025-08-12T20:00:00","modified_gmt":"2025-08-12T12:00:00","slug":"%e6%96%b0%e6%89%8b%e4%b9%9f%e8%83%bd%e5%bc%80%e5%8f%91mcp%e6%9c%8d%e5%8a%a1%ef%bc%9a%e4%bb%8e0%e5%86%99%e4%bb%a3%e7%a0%81%e5%88%b0%e5%ae%a2%e6%88%b7%e7%ab%af%e8%b0%83%e7%94%a8%ef%bc%8c%e5%85%a8","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/53951.html","title":{"rendered":"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357"},"content":{"rendered":"<p>\u6ce8&#xff1a;\u6b64\u6587\u7ae0\u5185\u5bb9\u5747\u8282\u9009\u81ea\u5145\u7535\u4e86\u4e48\u521b\u59cb\u4eba&#xff0c;CEO\u517cCTO\u9648\u656c\u96f7\u8001\u5e08\u7684\u65b0\u4e66\u300aGPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u300b&#xff08;\u8ddf\u6211\u4e00\u8d77\u5b66\u4eba\u5de5\u667a\u80fd&#xff09;\u3010\u9648\u656c\u96f7\u7f16\u8457\u3011\u3010\u6e05\u534e\u5927\u5b66\u51fa\u7248\u793e\u3011<\/p>\n<p>\u6e05\u534e\u300aGPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u300b\u4e66\u7c4d\u914d\u5957\u89c6\u9891\u8bfe\u7a0b\u3010\u9648\u656c\u96f7\u3011<\/p>\n<\/p>\n<h4>\u6587\u7ae0\u76ee\u5f55<\/h4>\n<ul>\n<li>GPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u7cfb\u5217\u516b\u5341\u4e5d<\/li>\n<li>\n<ul>\n<li>\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1&#xff1a;\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528&#xff0c;\u5168\u6d41\u7a0b&#043;\u907f\u5751\u6307\u5357<\/li>\n<li>\n<ul>\n<li>\n<ul>\n<li>\u4e00\u3001\u5148\u641e\u61c2&#xff1a;MCP\u5230\u5e95\u80fd\u89e3\u51b3\u4ec0\u4e48\u95ee\u9898&#xff1f;<\/li>\n<li>\u4e8c\u30015\u5206\u949f\u5f00\u53d1MCP\u670d\u52a1&#xff1a;\u4ece\u73af\u5883\u51c6\u5907\u5230\u4ee3\u7801\u5b9e\u73b0<\/li>\n<li>\n<ul>\n<li>1. \u73af\u5883\u51c6\u5907&#xff1a;3\u6b65\u642d\u597d\u5f00\u53d1\u57fa\u7840<\/li>\n<li>2. \u6838\u5fc3\u5f00\u53d1&#xff1a;\u5b9a\u4e49\u4f60\u7684\u201c\u5927\u6a21\u578b\u53ef\u7528\u5de5\u5177\u201d<\/li>\n<li>\n<ul>\n<li>&#xff08;1&#xff09;\u5b9a\u4e49\u5de5\u5177\u51fd\u6570&#xff08;Tools&#xff09;&#xff1a;\u8ba9\u5927\u6a21\u578b\u80fd\u201c\u6267\u884c\u64cd\u4f5c\u201d<\/li>\n<li>&#xff08;2&#xff09;\u5b9a\u4e49\u8d44\u6e90&#xff08;Resources&#xff09;&#xff1a;\u8ba9\u5927\u6a21\u578b\u80fd\u201c\u8bfb\u53d6\u6570\u636e\u201d<\/li>\n<li>&#xff08;3&#xff09;\u5b9a\u4e49\u63d0\u793a\u8bcd\u6a21\u677f&#xff08;Prompts&#xff09;&#xff1a;\u8ba9\u5927\u6a21\u578b\u201c\u6309\u6a21\u677f\u5bf9\u8bdd\u201d<\/li>\n<li>&#xff08;4&#xff09;\u542f\u52a8\u670d\u52a1&#xff1a;\u9009\u5bf9\u4f20\u8f93\u534f\u8bae\u5f88\u91cd\u8981<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>\u4e09\u3001\u5ba2\u6237\u7aef\u914d\u7f6e&#xff1a;\u8ba9\u5927\u6a21\u578b\u201c\u627e\u5230\u5e76\u8c03\u7528\u4f60\u7684\u670d\u52a1\u201d<\/li>\n<li>\n<ul>\n<li>1. \u914d\u7f6e\u670d\u52a1\u8def\u5f84<\/li>\n<li>2. \u6d4b\u8bd5\u8c03\u7528&#xff1a;\u7528\u81ea\u7136\u8bed\u8a00\u89e6\u53d1\u670d\u52a1<\/li>\n<li>3. \u53ef\u89c6\u5316\u8c03\u8bd5&#xff1a;\u7528MCP Inspector\u67e5\u95ee\u9898<\/li>\n<\/ul>\n<\/li>\n<li>\u56db\u3001\u9ad8\u7ea7\u73a9\u6cd5&#xff1a;\u8ba9\u4f60\u7684MCP\u670d\u52a1\u66f4\u5b9e\u7528<\/li>\n<li>\n<ul>\n<li>1. \u5b89\u5168\u6027\u63a7\u5236&#xff1a;\u907f\u514d\u5de5\u5177\u201c\u8d8a\u6743\u64cd\u4f5c\u201d<\/li>\n<li>2. \u96c6\u6210\u73b0\u6709API&#xff1a;\u8ba9MCP\u670d\u52a1\u5bf9\u63a5\u5916\u90e8\u80fd\u529b<\/li>\n<li>3. \u52a8\u6001\u6269\u5c55&#xff1a;\u76f4\u63a5\u590d\u7528\u516c\u5171MCP\u670d\u52a1<\/li>\n<\/ul>\n<\/li>\n<li>\u4e94\u3001\u907f\u5751\u6307\u5357&#xff1a;\u65b0\u624b\u5e38\u8e29\u76845\u4e2a\u5751\u53ca\u89e3\u51b3\u65b9\u6848<\/li>\n<li>\u516d\u3001\u603b\u7ed3&#xff1a;MCP\u662f\u5927\u6a21\u578b\u843d\u5730\u7684\u201c\u5fc5\u5907\u6280\u80fd\u201d<\/li>\n<\/ul>\n<\/li>\n<li>\u66f4\u591a\u6280\u672f\u5185\u5bb9<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>\u603b\u7ed3<\/li>\n<\/ul>\n<h2>GPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u7cfb\u5217\u516b\u5341\u4e5d<\/h2>\n<h3>\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1&#xff1a;\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528&#xff0c;\u5168\u6d41\u7a0b&#043;\u907f\u5751\u6307\u5357<\/h3>\n<p>\u5728\u5927\u6a21\u578b\u5e94\u7528\u7206\u53d1\u7684\u5f53\u4e0b&#xff0c;\u4e00\u4e2a\u5173\u952e\u75db\u70b9\u65e5\u76ca\u51f8\u663e&#xff1a;\u5982\u4f55\u8ba9AI\u6a21\u578b\u8f7b\u677e\u8c03\u7528\u672c\u5730\u6587\u4ef6\u3001\u81ea\u5b9a\u4e49\u5de5\u5177\u6216\u5916\u90e8API&#xff1f;Anthropic\u63a8\u51fa\u7684MCP&#xff08;Model Context Protocol&#xff0c;\u6a21\u578b\u4e0a\u4e0b\u6587\u534f\u8bae&#xff09;\u7ed9\u51fa\u4e86\u7b54\u6848\u2014\u2014\u5b83\u50cf\u4e00\u5957\u201c\u901a\u7528\u63a5\u53e3\u6807\u51c6\u201d&#xff0c;\u8ba9\u5927\u6a21\u578b\u4e0e\u5916\u90e8\u8d44\u6e90\u7684\u534f\u4f5c\u4ece\u201c\u5b9a\u5236\u5316\u5f00\u53d1\u201d\u53d8\u6210\u201c\u5373\u63d2\u5373\u7528\u201d\u3002<\/p>\n<p>\u672c\u6587\u57fa\u4e8ePython\u6280\u672f\u6808&#xff0c;\u4ee5\u201c5\u5206\u949f\u5feb\u901f\u5f00\u53d1\u201d\u4e3a\u6838\u5fc3&#xff0c;\u624b\u628a\u624b\u62c6\u89e3MCP\u670d\u52a1\u7684\u5f00\u53d1\u5168\u6d41\u7a0b\u3002\u65e0\u8bba\u4f60\u662fAI\u65b0\u624b\u8fd8\u662f\u60f3\u5feb\u901f\u843d\u5730\u5de5\u5177\u96c6\u6210\u7684\u5f00\u53d1\u8005&#xff0c;\u90fd\u80fd\u8ddf\u7740\u6b65\u9aa4\u4ece0\u5b9e\u73b0\u4e00\u4e2a\u80fd\u88ab\u5927\u6a21\u578b\u8c03\u7528\u7684MCP\u670d\u52a1&#xff0c;\u8fd8\u80fd\u907f\u5f0090%\u7684\u5165\u95e8\u5751\u3002<\/p>\n<h5>\u4e00\u3001\u5148\u641e\u61c2&#xff1a;MCP\u5230\u5e95\u80fd\u89e3\u51b3\u4ec0\u4e48\u95ee\u9898&#xff1f;<\/h5>\n<p>\u7b80\u5355\u8bf4&#xff0c;MCP\u662f\u5927\u6a21\u578b\u4e0e\u5916\u90e8\u4e16\u754c\u7684\u201c\u7ffb\u8bd1\u5b98\u201d\u3002\u6ca1\u6709MCP\u65f6&#xff0c;\u8ba9\u5927\u6a21\u578b\u8c03\u7528\u672c\u5730\u6587\u4ef6\u3001\u8ba1\u7b97\u5668\u6216\u4f01\u4e1aAPI&#xff0c;\u9700\u8981\u9488\u5bf9\u4e0d\u540c\u6a21\u578b\u5199\u4e0d\u540c\u63a5\u53e3&#xff0c;\u8017\u65f6\u4e14\u517c\u5bb9\u6027\u5dee&#xff1b;\u6709\u4e86MCP\u540e&#xff0c;\u53ea\u9700\u6309\u7edf\u4e00\u89c4\u5219\u5f00\u53d1\u4e00\u6b21\u670d\u52a1&#xff0c;Claude\u3001Cursor\u3001CLINE\u7b49\u4e3b\u6d41\u5de5\u5177\u90fd\u80fd\u8bc6\u522b\u8c03\u7528\u3002<\/p>\n<p>\u5b83\u7684\u6838\u5fc3\u4ef7\u503c\u4f53\u73b0\u5728&#xff1a;<\/p>\n<ul>\n<li>\u6807\u51c6\u5316\u534f\u4f5c&#xff1a;\u7edf\u4e00\u5927\u6a21\u578b\u4e0e\u5de5\u5177\u7684\u4ea4\u4e92\u89c4\u5219&#xff0c;\u907f\u514d\u201c\u4e00\u4e2a\u6a21\u578b\u4e00\u5957\u63a5\u53e3\u201d\u7684\u91cd\u590d\u52b3\u52a8&#xff1b;<\/li>\n<li>\u4f4e\u95e8\u69db\u6269\u5c55&#xff1a;\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1\u81ea\u5b9a\u4e49\u670d\u52a1&#xff0c;\u8ba9\u5927\u6a21\u578b\u62e5\u6709\u8c03\u7528\u672c\u5730\u6587\u4ef6\u3001\u6267\u884c\u7279\u5b9a\u51fd\u6570\u7684\u80fd\u529b&#xff1b;<\/li>\n<li>\u8de8\u573a\u666f\u9002\u914d&#xff1a;\u652f\u6301\u672c\u5730\u901a\u4fe1&#xff08;\u5982IDE\u5185\u8c03\u7528&#xff09;\u548c\u8fdc\u7a0b\u534f\u4f5c&#xff08;\u8de8\u8bbe\u5907\u8c03\u7528\u670d\u52a1&#xff09;&#xff0c;\u8986\u76d6\u4e2a\u4eba\u4e0e\u4f01\u4e1a\u573a\u666f\u3002<\/li>\n<\/ul>\n<h5>\u4e8c\u30015\u5206\u949f\u5f00\u53d1MCP\u670d\u52a1&#xff1a;\u4ece\u73af\u5883\u51c6\u5907\u5230\u4ee3\u7801\u5b9e\u73b0<\/h5>\n<h6>1. \u73af\u5883\u51c6\u5907&#xff1a;3\u6b65\u642d\u597d\u5f00\u53d1\u57fa\u7840<\/h6>\n<p>MCP\u5f00\u53d1\u4f9d\u8d56Python\u73af\u5883\u548c\u5b98\u65b9SDK&#xff0c;\u65b0\u624b\u6309\u4ee5\u4e0b\u6b65\u9aa4\u64cd\u4f5c&#xff0c;5\u5206\u949f\u5185\u5373\u53ef\u5c31\u7eea&#xff1a;<\/p>\n<ul>\n<li>\n<p>Step 1&#xff1a;\u5b89\u88c5Python&#xff08;\u22653.10&#xff09; MCP\u5bf9Python\u7248\u672c\u6709\u8981\u6c42&#xff08;\u63a8\u83503.10\u53ca\u4ee5\u4e0a&#xff09;&#xff0c;\u786e\u4fdd\u73af\u5883\u8fbe\u6807\u3002\u53ef\u901a\u8fc7python &#8211;version\u68c0\u67e5\u7248\u672c&#xff0c;\u82e5\u4e0d\u6ee1\u8db3&#xff0c;\u5b98\u7f51\u4e0b\u8f7d\u5bf9\u5e94\u7248\u672c\u5373\u53ef\u3002<\/p>\n<\/li>\n<li>\n<p>Step 2&#xff1a;\u7528\u865a\u62df\u73af\u5883\u9694\u79bb\u4f9d\u8d56&#xff08;\u63a8\u8350&#xff09; \u4e3a\u907f\u514d\u4f9d\u8d56\u51b2\u7a81&#xff0c;\u5efa\u8bae\u521b\u5efa\u4e13\u7528\u865a\u62df\u73af\u5883&#xff1a;<\/p>\n<p> <span class=\"token comment\"># \u521b\u5efa\u865a\u62df\u73af\u5883<\/span><br \/>\npython <span class=\"token parameter variable\">-m<\/span> venv mcp-env<br \/>\n<span class=\"token comment\"># \u6fc0\u6d3b\u73af\u5883&#xff08;Linux\/Mac&#xff09;<\/span><br \/>\n<span class=\"token builtin class-name\">source<\/span> mcp-env\/bin\/activate<br \/>\n<span class=\"token comment\"># \u6fc0\u6d3b\u73af\u5883&#xff08;Windows&#xff09;<\/span><br \/>\nmcp-env<span class=\"token punctuation\">\\\\<\/span>Scripts<span class=\"token punctuation\">\\\\<\/span>activate\n <\/li>\n<li>\n<p>Step 3&#xff1a;\u5b89\u88c5MCP SDK \u5b98\u65b9\u63d0\u4f9b\u7684SDK\u5df2\u5c01\u88c5\u6838\u5fc3\u529f\u80fd&#xff0c;\u4e00\u884c\u547d\u4ee4\u5373\u53ef\u5b89\u88c5&#xff1a;<\/p>\n<p> pip <span class=\"token function\">install<\/span> mcp  <\/p>\n<p>\u5b89\u88c5\u5b8c\u6210\u540e&#xff0c;\u8fd0\u884cmcp version&#xff0c;\u82e5\u8fd4\u56de\u7248\u672c\u53f7&#xff08;\u59821.5.0&#xff09;&#xff0c;\u8bf4\u660e\u73af\u5883\u51c6\u5907\u5c31\u7eea\u3002<\/p>\n<\/li>\n<li>\n<p>\u9009\u5bf9\u5f00\u53d1\u5de5\u5177 \u5f00\u53d1\u9636\u6bb5\u53ef\u76f4\u63a5\u7528\u8bb0\u4e8b\u672c\u6216VS Code\u5199\u4ee3\u7801&#xff1b;\u6d4b\u8bd5\u9636\u6bb5\u9700\u7528\u652f\u6301MCP\u7684\u5ba2\u6237\u7aef&#xff08;\u5982CLINE\u3001Cursor\u3001Claude Desktop&#xff09;&#xff0c;\u4e5f\u53ef\u642d\u914d\u5b98\u65b9\u8c03\u8bd5\u5de5\u5177MCP Inspector\u3002<\/p>\n<\/li>\n<\/ul>\n<h6>2. \u6838\u5fc3\u5f00\u53d1&#xff1a;\u5b9a\u4e49\u4f60\u7684\u201c\u5927\u6a21\u578b\u53ef\u7528\u5de5\u5177\u201d<\/h6>\n<p>MCP\u670d\u52a1\u7684\u6838\u5fc3\u662f\u5411\u5927\u6a21\u578b\u66b4\u9732\u201c\u53ef\u8c03\u7528\u7684\u80fd\u529b\u201d&#xff0c;\u4e3b\u8981\u901a\u8fc7\u4e09\u5927\u201c\u534f\u8bae\u539f\u8bed\u201d\u5b9e\u73b0&#xff1a;Tools&#xff08;\u5de5\u5177\u51fd\u6570&#xff09;\u3001Resources&#xff08;\u8d44\u6e90&#xff09;\u3001Prompts&#xff08;\u63d0\u793a\u8bcd\u6a21\u677f&#xff09;\u3002\u4ee5\u4e0b\u7528\u5b9e\u4f8b\u9010\u4e2a\u62c6\u89e3\u3002<\/p>\n<h6>&#xff08;1&#xff09;\u5b9a\u4e49\u5de5\u5177\u51fd\u6570&#xff08;Tools&#xff09;&#xff1a;\u8ba9\u5927\u6a21\u578b\u80fd\u201c\u6267\u884c\u64cd\u4f5c\u201d<\/h6>\n<p>\u5de5\u5177\u51fd\u6570\u662fMCP\u670d\u52a1\u7684\u201c\u6838\u5fc3\u529f\u80fd\u4f53\u201d&#xff0c;\u6bd4\u5982\u201c\u83b7\u53d6\u684c\u9762\u6587\u4ef6\u5217\u8868\u201d\u201c\u751f\u6210\u95ee\u5019\u8bed\u201d\u7b49&#xff0c;\u5927\u6a21\u578b\u53ef\u901a\u8fc7\u81ea\u7136\u8bed\u8a00\u8c03\u7528\u8fd9\u4e9b\u51fd\u6570\u5e76\u83b7\u53d6\u7ed3\u679c\u3002<\/p>\n<p>\u793a\u4f8b\u4ee3\u7801&#xff08;custom_mcp.py&#xff09;&#xff1a;<\/p>\n<p><span class=\"token comment\"># \u4ece\u5b98\u65b9SDK\u5bfc\u5165FastMCP<\/span><br \/>\n<span class=\"token keyword\">from<\/span> mcp<span class=\"token punctuation\">.<\/span>server<span class=\"token punctuation\">.<\/span>fastmcp <span class=\"token keyword\">import<\/span> FastMCP<br \/>\n<span class=\"token keyword\">import<\/span> os<\/p>\n<p><span class=\"token comment\"># \u521b\u5efaMCP\u5b9e\u4f8b&#xff08;\u53ef\u81ea\u5b9a\u4e49\u540d\u79f0&#xff09;<\/span><br \/>\nmcp <span class=\"token operator\">&#061;<\/span> FastMCP<span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><\/p>\n<p><span class=\"token comment\"># \u5b9a\u4e49\u201c\u83b7\u53d6\u684c\u9762\u6587\u4ef6\u5217\u8868\u201d\u5de5\u5177&#xff08;\u4ec5\u652f\u6301macOS&#xff09;<\/span><br \/>\n<span class=\"token decorator annotation punctuation\">&#064;mcp<span class=\"token punctuation\">.<\/span>tool<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span>  <span class=\"token comment\"># \u7528\u88c5\u9970\u5668\u6807\u8bb0\u4e3a\u5de5\u5177<\/span><br \/>\n<span class=\"token keyword\">def<\/span> <span class=\"token function\">list_desktop_files<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token operator\">&#8211;<\/span><span class=\"token operator\">&gt;<\/span> <span class=\"token builtin\">list<\/span><span class=\"token punctuation\">:<\/span><br \/>\n    <span class=\"token triple-quoted-string string\">&#034;&#034;&#034;\u83b7\u53d6\u5f53\u524d\u7528\u6237\u684c\u9762\u4e0a\u7684\u6240\u6709\u6587\u4ef6\u5217\u8868&#xff08;macOS\u4e13\u5c5e\u5b9e\u73b0&#xff09;&#034;&#034;&#034;<\/span><br \/>\n    <span class=\"token comment\"># \u62fc\u63a5\u684c\u9762\u8def\u5f84&#xff08;macOS\u7528\u6237\u684c\u9762\u8def\u5f84\u56fa\u5b9a\u4e3a&#034;~\/Desktop&#034;&#xff09;<\/span><br \/>\n    desktop_path <span class=\"token operator\">&#061;<\/span> os<span class=\"token punctuation\">.<\/span>path<span class=\"token punctuation\">.<\/span>expanduser<span class=\"token punctuation\">(<\/span><span class=\"token string\">&#034;~\/Desktop&#034;<\/span><span class=\"token punctuation\">)<\/span><br \/>\n    <span class=\"token comment\"># \u8fd4\u56de\u6587\u4ef6\u5217\u8868&#xff08;\u9700\u4e3aJSON\u517c\u5bb9\u7c7b\u578b&#xff1a;\u5217\u8868\u3001\u5b57\u7b26\u4e32\u3001\u5b57\u5178\u7b49&#xff09;<\/span><br \/>\n    <span class=\"token keyword\">return<\/span> os<span class=\"token punctuation\">.<\/span>listdir<span class=\"token punctuation\">(<\/span>desktop_path<span class=\"token punctuation\">)<\/span><\/p>\n<p><span class=\"token comment\"># \u5b9a\u4e49\u201c\u751f\u6210\u53cc\u8bed\u95ee\u5019\u8bed\u201d\u5de5\u5177<\/span><br \/>\n<span class=\"token decorator annotation punctuation\">&#064;mcp<span class=\"token punctuation\">.<\/span>tool<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span><br \/>\n<span class=\"token keyword\">def<\/span> <span class=\"token function\">say_hello<\/span><span class=\"token punctuation\">(<\/span>name<span class=\"token punctuation\">:<\/span> <span class=\"token builtin\">str<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token operator\">&#8211;<\/span><span class=\"token operator\">&gt;<\/span> <span class=\"token builtin\">str<\/span><span class=\"token punctuation\">:<\/span><br \/>\n    <span class=\"token triple-quoted-string string\">&#034;&#034;&#034;\u751f\u6210\u4e2a\u6027\u5316\u95ee\u5019\u8bed&#xff08;\u4e2d\u82f1\u53cc\u8bed\u7248&#xff09;&#034;&#034;&#034;<\/span><br \/>\n    <span class=\"token keyword\">return<\/span> <span class=\"token string-interpolation\"><span class=\"token string\">f&#034;&#x1f389; \u4f60\u597d <\/span><span class=\"token interpolation\"><span class=\"token punctuation\">{<\/span>name<span class=\"token punctuation\">}<\/span><\/span><span class=\"token string\">! (Hello <\/span><span class=\"token interpolation\"><span class=\"token punctuation\">{<\/span>name<span class=\"token punctuation\">}<\/span><\/span><span class=\"token string\">!)&#034;<\/span><\/span><\/p>\n<p>\u5173\u952e\u7ec6\u8282&#xff1a;<\/p>\n<ul>\n<li>\u5de5\u5177\u51fd\u6570\u9700\u7528&#064;mcp.tool()\u88c5\u9970\u5668\u6807\u8bb0&#xff0c;\u5927\u6a21\u578b\u4f1a\u901a\u8fc7\u6587\u6863\u5b57\u7b26\u4e32&#xff08;\u51fd\u6570\u6ce8\u91ca&#xff09;\u7406\u89e3\u5176\u529f\u80fd&#xff1b;<\/li>\n<li>\u8fd4\u56de\u503c\u5fc5\u987b\u662fJSON\u53ef\u5e8f\u5217\u5316\u7c7b\u578b&#xff08;\u5982\u5217\u8868\u3001\u5b57\u7b26\u4e32\u3001\u5b57\u5178&#xff09;&#xff0c;\u5426\u5219\u5927\u6a21\u578b\u65e0\u6cd5\u89e3\u6790&#xff1b;<\/li>\n<li>\u53c2\u6570\u7c7b\u578b\u9700\u660e\u786e&#xff08;\u5982name: str&#xff09;&#xff0c;\u5e2e\u52a9\u5927\u6a21\u578b\u6b63\u786e\u4f20\u53c2\u3002<\/li>\n<\/ul>\n<h6>&#xff08;2&#xff09;\u5b9a\u4e49\u8d44\u6e90&#xff08;Resources&#xff09;&#xff1a;\u8ba9\u5927\u6a21\u578b\u80fd\u201c\u8bfb\u53d6\u6570\u636e\u201d<\/h6>\n<p>\u8d44\u6e90\u662f\u9759\u6001\u6216\u52a8\u6001\u7684\u6570\u636e\u5757&#xff08;\u5982\u914d\u7f6e\u4fe1\u606f\u3001\u6570\u636e\u5e93\u67e5\u8be2\u7ed3\u679c&#xff09;&#xff0c;\u5927\u6a21\u578b\u53ef\u901a\u8fc7\u7c7b\u4f3c\u201cURL\u201d\u7684\u8def\u5f84\u8c03\u7528\u3002<\/p>\n<p>\u793a\u4f8b\u4ee3\u7801&#xff08;\u63a5\u4e0a\u9762\u7684custom_mcp.py&#xff09;&#xff1a;<\/p>\n<p><span class=\"token decorator annotation punctuation\">&#064;mcp<span class=\"token punctuation\">.<\/span>resource<\/span><span class=\"token punctuation\">(<\/span><span class=\"token string\">&#034;config:\/\/app_settings&#034;<\/span><span class=\"token punctuation\">)<\/span>  <span class=\"token comment\"># \u5b9a\u4e49\u8d44\u6e90\u8def\u7531&#xff08;\u7c7b\u4f3cURL&#xff09;<\/span><br \/>\n<span class=\"token keyword\">def<\/span> <span class=\"token function\">get_app_config<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token operator\">&#8211;<\/span><span class=\"token operator\">&gt;<\/span> <span class=\"token builtin\">dict<\/span><span class=\"token punctuation\">:<\/span><br \/>\n    <span class=\"token triple-quoted-string string\">&#034;&#034;&#034;\u8fd4\u56de\u5e94\u7528\u7684\u57fa\u7840\u914d\u7f6e\u4fe1\u606f&#034;&#034;&#034;<\/span><br \/>\n    <span class=\"token keyword\">return<\/span> <span class=\"token punctuation\">{<\/span><span class=\"token string\">&#034;theme&#034;<\/span><span class=\"token punctuation\">:<\/span> <span class=\"token string\">&#034;dark&#034;<\/span><span class=\"token punctuation\">,<\/span> <span class=\"token string\">&#034;language&#034;<\/span><span class=\"token punctuation\">:<\/span> <span class=\"token string\">&#034;zh-CN&#034;<\/span><span class=\"token punctuation\">}<\/span><\/p>\n<p>\u540e\u7eed\u5927\u6a21\u578b\u8f93\u5165\u201c\u83b7\u53d6app\u8bbe\u7f6e\u201d&#xff0c;\u4f1a\u81ea\u52a8\u8c03\u7528config:\/\/app_settings\u8d44\u6e90&#xff0c;\u8fd4\u56de\u914d\u7f6e\u5b57\u5178\u3002<\/p>\n<h6>&#xff08;3&#xff09;\u5b9a\u4e49\u63d0\u793a\u8bcd\u6a21\u677f&#xff08;Prompts&#xff09;&#xff1a;\u8ba9\u5927\u6a21\u578b\u201c\u6309\u6a21\u677f\u5bf9\u8bdd\u201d<\/h6>\n<p>\u63d0\u793a\u8bcd\u6a21\u677f\u662f\u9884\u8bbe\u7684\u4ea4\u4e92\u6d41\u7a0b&#xff0c;\u80fd\u8ba9\u5927\u6a21\u578b\u6309\u56fa\u5b9a\u683c\u5f0f\u5904\u7406\u4efb\u52a1&#xff08;\u5982\u4ee3\u7801\u5ba1\u67e5\u3001\u5185\u5bb9\u751f\u6210&#xff09;\u3002<\/p>\n<p>\u793a\u4f8b\u4ee3\u7801&#xff08;\u63a5\u4e0a\u9762\u7684custom_mcp.py&#xff09;&#xff1a;<\/p>\n<p><span class=\"token decorator annotation punctuation\">&#064;mcp<span class=\"token punctuation\">.<\/span>prompt<\/span><span class=\"token punctuation\">(<\/span><span class=\"token punctuation\">)<\/span>  <span class=\"token comment\"># \u6807\u8bb0\u4e3a\u63d0\u793a\u8bcd\u6a21\u677f<\/span><br \/>\n<span class=\"token keyword\">def<\/span> <span class=\"token function\">code_review_prompt<\/span><span class=\"token punctuation\">(<\/span>code<span class=\"token punctuation\">:<\/span> <span class=\"token builtin\">str<\/span><span class=\"token punctuation\">)<\/span> <span class=\"token operator\">&#8211;<\/span><span class=\"token operator\">&gt;<\/span> <span class=\"token builtin\">str<\/span><span class=\"token punctuation\">:<\/span><br \/>\n    <span class=\"token triple-quoted-string string\">&#034;&#034;&#034;\u751f\u6210\u4ee3\u7801\u5ba1\u67e5\u7684\u63d0\u793a\u8bcd\u6a21\u677f&#034;&#034;&#034;<\/span><br \/>\n    <span class=\"token keyword\">return<\/span> <span class=\"token string-interpolation\"><span class=\"token string\">f&#034;\u8bf7\u5ba1\u67e5\u4ee5\u4e0b\u4ee3\u7801\u5e76\u6307\u51fa\u95ee\u9898&#xff1a;\\\\n\\\\n<\/span><span class=\"token interpolation\"><span class=\"token punctuation\">{<\/span>code<span class=\"token punctuation\">}<\/span><\/span><span class=\"token string\">&#034;<\/span><\/span><\/p>\n<p>\u5f53\u5927\u6a21\u578b\u9700\u8981\u5ba1\u67e5\u4ee3\u7801\u65f6&#xff0c;\u4f1a\u81ea\u52a8\u5957\u7528\u8fd9\u4e2a\u6a21\u677f&#xff0c;\u786e\u4fdd\u8f93\u51fa\u683c\u5f0f\u7edf\u4e00\u3002<\/p>\n<h6>&#xff08;4&#xff09;\u542f\u52a8\u670d\u52a1&#xff1a;\u9009\u5bf9\u4f20\u8f93\u534f\u8bae\u5f88\u91cd\u8981<\/h6>\n<p>\u5f00\u53d1\u5b8c\u529f\u80fd\u540e&#xff0c;\u9700\u901a\u8fc7mcp.run()\u542f\u52a8\u670d\u52a1&#xff0c;\u5173\u952e\u662f\u9009\u5bf9\u201c\u4f20\u8f93\u534f\u8bae\u201d\u2014\u2014\u5b83\u51b3\u5b9a\u4e86\u670d\u52a1\u5982\u4f55\u4e0e\u5927\u6a21\u578b\u901a\u4fe1&#xff1a;<\/p>\n<ul>\n<li>stdio\u534f\u8bae&#xff1a;\u901a\u8fc7\u6807\u51c6\u8f93\u5165\/\u8f93\u51fa\u901a\u4fe1&#xff0c;\u9002\u5408\u672c\u5730\u5f00\u53d1&#xff08;\u5982IDE\u5185\u8c03\u7528&#xff09;&#xff0c;\u7b80\u5355\u65e0\u9700\u914d\u7f6e&#xff1b;<\/li>\n<li>sse\u534f\u8bae&#xff1a;\u57fa\u4e8eHTTP\u4e8b\u4ef6\u6d41&#xff0c;\u9002\u5408\u8fdc\u7a0b\u8c03\u7528&#xff08;\u8de8\u8bbe\u5907\u534f\u4f5c&#xff09;&#xff0c;\u9700\u90e8\u7f72\u4e3aWeb\u670d\u52a1\u3002<\/li>\n<\/ul>\n<p>\u65b0\u624b\u5165\u95e8\u63a8\u8350\u5148\u7528\u6c34\u5370stdio\u534f\u8bae&#xff0c;\u5b8c\u6574\u542f\u52a8\u4ee3\u7801\u5982\u4e0b&#xff08;\u63a5\u4e0a\u9762\u7684custom_mcp.py&#xff09;&#xff1a;<\/p>\n<p><span class=\"token keyword\">if<\/span> __name__ <span class=\"token operator\">&#061;&#061;<\/span> <span class=\"token string\">&#034;__main__&#034;<\/span><span class=\"token punctuation\">:<\/span><br \/>\n    mcp<span class=\"token punctuation\">.<\/span>run<span class=\"token punctuation\">(<\/span>transport<span class=\"token operator\">&#061;<\/span><span class=\"token string\">&#039;stdio&#039;<\/span><span class=\"token punctuation\">)<\/span>  <span class=\"token comment\"># \u542f\u7528stdio\u4f20\u8f93&#xff0c;\u672c\u5730\u8c03\u8bd5\u66f4\u65b9\u4fbf<\/span><\/p>\n<h5>\u4e09\u3001\u5ba2\u6237\u7aef\u914d\u7f6e&#xff1a;\u8ba9\u5927\u6a21\u578b\u201c\u627e\u5230\u5e76\u8c03\u7528\u4f60\u7684\u670d\u52a1\u201d<\/h5>\n<p>\u670d\u52a1\u5f00\u53d1\u5b8c\u6210\u540e&#xff0c;\u9700\u5728\u5ba2\u6237\u7aef&#xff08;\u5982CLINE&#xff09;\u4e2d\u914d\u7f6e&#xff0c;\u8ba9\u5927\u6a21\u578b\u80fd\u8bc6\u522b\u5e76\u8c03\u7528\u3002\u4ee5CLINE\u4e3a\u4f8b&#xff0c;\u6b65\u9aa4\u5982\u4e0b&#xff1a;<\/p>\n<h6>1. \u914d\u7f6e\u670d\u52a1\u8def\u5f84<\/h6>\n<p>\u5728CLINE\u4e2d\u627e\u5230\u201cMCP\u8bbe\u7f6e\u201d&#xff0c;\u6dfb\u52a0\u670d\u52a1\u914d\u7f6e\u6587\u4ef6&#xff08;\u5982cline_mcp_settings.json&#xff09;&#xff0c;\u683c\u5f0f\u5982\u4e0b&#xff1a;<\/p>\n<p><span class=\"token punctuation\">{<\/span><br \/>\n  <span class=\"token string-property property\">&#034;mcpServers&#034;<\/span><span class=\"token operator\">:<\/span> <span class=\"token punctuation\">{<\/span><br \/>\n    <span class=\"token string-property property\">&#034;my_first_mcp_service&#034;<\/span><span class=\"token operator\">:<\/span> <span class=\"token punctuation\">{<\/span>  <span class=\"token comment\">\/\/ \u670d\u52a1\u540d\u79f0&#xff08;\u81ea\u5b9a\u4e49&#xff0c;\u9700\u552f\u4e00&#xff09;<\/span><br \/>\n      <span class=\"token string-property property\">&#034;command&#034;<\/span><span class=\"token operator\">:<\/span> <span class=\"token string\">&#034;python3&#034;<\/span><span class=\"token punctuation\">,<\/span>  <span class=\"token comment\">\/\/ \u542f\u52a8\u547d\u4ee4&#xff08;\u7528python3\u8fd0\u884c\u4ee3\u7801&#xff09;<\/span><br \/>\n      <span class=\"token string-property property\">&#034;args&#034;<\/span><span class=\"token operator\">:<\/span> <span class=\"token punctuation\">[<\/span><br \/>\n        <span class=\"token string\">&#034;\/Users\/\u4f60\u7684\u7528\u6237\u540d\/\u4ee3\u7801\u8def\u5f84\/custom_mcp.py&#034;<\/span>  <span class=\"token comment\">\/\/ \u4ee3\u7801\u6587\u4ef6\u7684\u7edd\u5bf9\u8def\u5f84<\/span><br \/>\n      <span class=\"token punctuation\">]<\/span><br \/>\n    <span class=\"token punctuation\">}<\/span><br \/>\n  <span class=\"token punctuation\">}<\/span><br \/>\n<span class=\"token punctuation\">}<\/span><\/p>\n<p>\u914d\u7f6e\u65f6\u6ce8\u610f&#xff1a;\u8def\u5f84\u9700\u7528\u7edd\u5bf9\u8def\u5f84&#xff0c;Windows\u7cfb\u7edf\u9700\u7528\u53cc\u659c\u6760&#xff08;\\\\\\\\&#xff09;&#xff1b;\u547d\u4ee4\u9700\u4e0e\u73af\u5883\u5339\u914d&#xff08;\u5982Windows\u7528python&#xff0c;Mac\/Linux\u7528python3&#xff09;\u3002<\/p>\n<h6>2. \u6d4b\u8bd5\u8c03\u7528&#xff1a;\u7528\u81ea\u7136\u8bed\u8a00\u89e6\u53d1\u670d\u52a1<\/h6>\n<p>\u914d\u7f6e\u5b8c\u6210\u540e&#xff0c;\u5237\u65b0CLINE\u5ba2\u6237\u7aef&#xff0c;\u5411\u5927\u6a21\u578b\u53d1\u9001\u6307\u4ee4\u5373\u53ef\u8c03\u7528\u670d\u52a1&#xff1a;<\/p>\n<ul>\n<li>\u8f93\u5165\u201c\u6211\u7684\u684c\u9762\u6709\u54ea\u4e9b\u6587\u4ef6\u201d&#xff0c;\u4f1a\u89e6\u53d1list_desktop_files\u5de5\u5177&#xff0c;\u8fd4\u56de\u684c\u9762\u6587\u4ef6\u5217\u8868&#xff1b;<\/li>\n<li>\u8f93\u5165\u201c\u95ee\u5019\u7528\u6237\u5c0f\u660e\u201d&#xff0c;\u4f1a\u8c03\u7528say_hello\u5de5\u5177&#xff0c;\u8fd4\u56de\u201c&#x1f389; \u4f60\u597d \u5c0f\u660e! (Hello \u5c0f\u660e!)\u201d&#xff1b;<\/li>\n<li>\u8f93\u5165\u201c\u83b7\u53d6app\u8bbe\u7f6e\u201d&#xff0c;\u4f1a\u8fd4\u56deconfig:\/\/app_settings\u8d44\u6e90\u5b9a\u4e49\u7684\u914d\u7f6e\u4fe1\u606f\u3002<\/li>\n<\/ul>\n<h6>3. \u53ef\u89c6\u5316\u8c03\u8bd5&#xff1a;\u7528MCP Inspector\u67e5\u95ee\u9898<\/h6>\n<p>\u82e5\u8c03\u7528\u5931\u8d25&#xff08;\u5982\u5de5\u5177\u672a\u8bc6\u522b\u3001\u8fd4\u56de\u9519\u8bef&#xff09;&#xff0c;\u53ef\u7528\u5b98\u65b9\u8c03\u8bd5\u5de5\u5177MCP Inspector\u6392\u67e5&#xff1a;<\/p>\n<li>\u6253\u5f00\u7ec8\u7aef&#xff0c;\u8fd0\u884c\u8c03\u8bd5\u547d\u4ee4&#xff08;\u9700\u63d0\u524d\u5b89\u88c5Node.js&#xff09;&#xff1a;npx &#064;modelcontextprotocol\/inspector python custom_mcp.py\n <\/li>\n<li>\u547d\u4ee4\u8fd0\u884c\u540e&#xff0c;\u5728\u6d4f\u89c8\u5668\u6253\u5f00http:\/\/127.0.0.1:6274\/&#xff0c;\u4f1a\u770b\u5230\u670d\u52a1\u7684\u5de5\u5177\u3001\u8d44\u6e90\u5217\u8868&#xff1b;<\/li>\n<li>\u76f4\u63a5\u5728\u7f51\u9875\u4e2d\u8f93\u5165\u53c2\u6570\u6d4b\u8bd5\u8c03\u7528&#xff0c;\u5b9e\u65f6\u67e5\u770b\u8f93\u5165\u8f93\u51fa\u65e5\u5fd7&#xff0c;\u5feb\u901f\u5b9a\u4f4d\u95ee\u9898&#xff08;\u5982\u8def\u5f84\u9519\u8bef\u3001\u8fd4\u56de\u503c\u7c7b\u578b\u4e0d\u517c\u5bb9&#xff09;\u3002<\/li>\n<h5>\u56db\u3001\u9ad8\u7ea7\u73a9\u6cd5&#xff1a;\u8ba9\u4f60\u7684MCP\u670d\u52a1\u66f4\u5b9e\u7528<\/h5>\n<p>\u638c\u63e1\u57fa\u7840\u5f00\u53d1\u540e&#xff0c;\u8fd9\u4e9b\u6280\u5de7\u80fd\u8ba9\u670d\u52a1\u66f4\u9002\u914d\u5b9e\u9645\u573a\u666f&#xff1a;<\/p>\n<h6>1. \u5b89\u5168\u6027\u63a7\u5236&#xff1a;\u907f\u514d\u5de5\u5177\u201c\u8d8a\u6743\u64cd\u4f5c\u201d<\/h6>\n<p>\u81ea\u5b9a\u4e49\u5de5\u5177\u53ef\u80fd\u6d89\u53ca\u672c\u5730\u6587\u4ef6\u6216\u7cfb\u7edf\u64cd\u4f5c&#xff0c;\u9700\u9650\u5236\u6743\u9650&#xff1a;<\/p>\n<ul>\n<li>\u6bd4\u5982list_desktop_files\u5de5\u5177&#xff0c;\u4ec5\u5141\u8bb8\u8bbf\u95ee~\/Desktop\u8def\u5f84&#xff0c;\u4e0d\u6269\u5c55\u5230\u5176\u4ed6\u76ee\u5f55&#xff1b;<\/li>\n<li>\u654f\u611f\u64cd\u4f5c&#xff08;\u5982\u6570\u636e\u5e93\u67e5\u8be2&#xff09;\u53ef\u901a\u8fc7Nacos\u7b49\u5de5\u5177\u7ba1\u7406\u5bc6\u94a5&#xff0c;\u907f\u514d\u786c\u7f16\u7801\u5728\u4ee3\u7801\u4e2d\u3002<\/li>\n<\/ul>\n<h6>2. \u96c6\u6210\u73b0\u6709API&#xff1a;\u8ba9MCP\u670d\u52a1\u5bf9\u63a5\u5916\u90e8\u80fd\u529b<\/h6>\n<p>\u65e0\u9700\u91cd\u5199\u4ee3\u7801&#xff0c;\u53ef\u901a\u8fc7\u201c\u534f\u8bae\u8f6c\u6362\u201d\u8ba9MCP\u670d\u52a1\u8c03\u7528\u73b0\u6709HTTP API\u3002\u4f8b\u5982&#xff0c;\u5c06\u9ad8\u5fb7\u5730\u56feAPI\u5c01\u88c5\u4e3aMCP\u670d\u52a1&#xff1a;<\/p>\n<li>\u7528Nacos\u6ce8\u518cAPI\u5143\u6570\u636e&#xff08;\u5982\u63a5\u53e3\u5730\u5740\u3001\u5bc6\u94a5&#xff09;&#xff1b;<\/li>\n<li>\u901a\u8fc7Higress\u7f51\u5173\u5c06HTTP\u534f\u8bae\u8f6c\u6362\u4e3aMCP\u534f\u8bae&#xff1b;<\/li>\n<li>\u5f00\u53d1\u7b80\u5355\u7684MCP\u5de5\u5177\u51fd\u6570&#xff0c;\u63a5\u6536\u81ea\u7136\u8bed\u8a00\u6307\u4ee4&#xff08;\u5982\u201c\u67e5\u5317\u4eac\u5929\u6c14\u201d&#xff09;&#xff0c;\u8c03\u7528\u8f6c\u6362\u540e\u7684API\u8fd4\u56de\u7ed3\u679c\u3002<\/li>\n<h6>3. \u52a8\u6001\u6269\u5c55&#xff1a;\u76f4\u63a5\u590d\u7528\u516c\u5171MCP\u670d\u52a1<\/h6>\n<p>\u4e0d\u60f3\u81ea\u5df1\u5f00\u53d1&#xff1f;\u53ef\u901a\u8fc7MCP\u5e02\u573a&#xff08;\u5982AIbase\u3001mcp.so&#xff09;\u83b7\u53d6\u73b0\u6210\u670d\u52a1&#xff1a;<\/p>\n<ul>\n<li>\u5e02\u573a\u4e2d\u6709\u5927\u91cf\u5b98\u65b9\u6216\u7b2c\u4e09\u65b9\u5f00\u53d1\u7684MCP\u670d\u52a1&#xff08;\u5982\u8ba1\u7b97\u5668\u3001\u7ffb\u8bd1\u3001\u683c\u5f0f\u8f6c\u6362&#xff09;&#xff1b;<\/li>\n<li>\u5728\u5ba2\u6237\u7aef\u4e2d\u76f4\u63a5\u6dfb\u52a0\u670d\u52a1\u5730\u5740&#xff0c;\u65e0\u9700\u4ee3\u7801\u5373\u53ef\u8c03\u7528&#xff0c;\u5b9e\u73b0\u201c\u96f6\u5f00\u53d1\u96c6\u6210\u201d\u3002<\/li>\n<\/ul>\n<h5>\u4e94\u3001\u907f\u5751\u6307\u5357&#xff1a;\u65b0\u624b\u5e38\u8e29\u76845\u4e2a\u5751\u53ca\u89e3\u51b3\u65b9\u6848<\/h5>\n<table>\n<tr>\u95ee\u9898\u539f\u56e0\u89e3\u51b3\u65b9\u6848<\/tr>\n<tbody>\n<tr>\n<td>\u5de5\u5177\u672a\u88ab\u5ba2\u6237\u7aef\u8bc6\u522b<\/td>\n<td>\u672a\u7528&#064;mcp.tool()\u88c5\u9970\u5668&#xff0c;\u6216\u6587\u6863\u5b57\u7b26\u4e32\u683c\u5f0f\u9519\u8bef<\/td>\n<td>\u68c0\u67e5\u88c5\u9970\u5668\u662f\u5426\u9057\u6f0f&#xff0c;\u786e\u4fdd\u51fd\u6570\u6ce8\u91ca\u6e05\u6670\u63cf\u8ff0\u529f\u80fd<\/td>\n<\/tr>\n<tr>\n<td>\u670d\u52a1\u542f\u52a8\u5931\u8d25<\/td>\n<td>\u4ee3\u7801\u8def\u5f84\u9519\u8bef&#xff0c;\u6216Python\u73af\u5883\u672a\u6fc0\u6d3b<\/td>\n<td>\u7528\u7edd\u5bf9\u8def\u5f84&#xff1b;\u542f\u52a8\u524d\u6fc0\u6d3b\u865a\u62df\u73af\u5883&#xff08;source mcp-env\/bin\/activate&#xff09;<\/td>\n<\/tr>\n<tr>\n<td>\u8fd4\u56de\u503c\u62a5\u9519<\/td>\n<td>\u8fd4\u56de\u4e86\u975eJSON\u517c\u5bb9\u7c7b\u578b&#xff08;\u5982\u96c6\u5408\u3001\u81ea\u5b9a\u4e49\u5bf9\u8c61&#xff09;<\/td>\n<td>\u786e\u4fdd\u8fd4\u56de\u503c\u4e3a\u5217\u8868\u3001\u5b57\u7b26\u4e32\u3001\u5b57\u5178\u7b49\u57fa\u7840\u7c7b\u578b<\/td>\n<\/tr>\n<tr>\n<td>\u8fdc\u7a0b\u8c03\u7528\u5931\u8d25<\/td>\n<td>\u672a\u7528sse\u534f\u8bae&#xff0c;\u6216\u7aef\u53e3\u88ab\u5360\u7528<\/td>\n<td>\u6539\u7528sse\u4f20\u8f93\u534f\u8bae&#xff1b;\u66f4\u6362\u7aef\u53e3&#xff08;\u5982port&#061;18080\u6539\u4e3aport&#061;18081&#xff09;<\/td>\n<\/tr>\n<tr>\n<td>\u6743\u9650\u4e0d\u8db3<\/td>\n<td>\u5de5\u5177\u51fd\u6570\u8bbf\u95ee\u4e86\u53d7\u9650\u76ee\u5f55&#xff08;\u5982\u7cfb\u7edf\u76d8\u6839\u76ee\u5f55&#xff09;<\/td>\n<td>\u9650\u5236\u8def\u5f84\u8303\u56f4&#xff0c;\u4ec5\u5141\u8bb8\u8bbf\u95ee\u5fc5\u8981\u76ee\u5f55<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h5>\u516d\u3001\u603b\u7ed3&#xff1a;MCP\u662f\u5927\u6a21\u578b\u843d\u5730\u7684\u201c\u5fc5\u5907\u6280\u80fd\u201d<\/h5>\n<p>\u4ece\u672c\u8d28\u4e0a\u770b&#xff0c;MCP\u7684\u4ef7\u503c\u4e0d\u4ec5\u662f\u201c\u6807\u51c6\u5316\u534f\u8bae\u201d&#xff0c;\u66f4\u662f\u964d\u4f4eAI\u5de5\u5177\u96c6\u6210\u95e8\u69db\u7684\u201c\u666e\u60e0\u6280\u672f\u201d\u3002\u54ea\u6015\u4f60\u53ea\u4f1a\u5199\u7b80\u5355\u7684Python\u51fd\u6570&#xff0c;\u4e5f\u80fd\u901a\u8fc7\u5b83\u8ba9\u5927\u6a21\u578b\u62e5\u6709\u8c03\u7528\u672c\u5730\u6587\u4ef6\u3001\u81ea\u5b9a\u4e49\u5de5\u5177\u7684\u80fd\u529b\u2014\u2014\u6bd4\u5982\u8ba9AI\u81ea\u52a8\u6574\u7406\u684c\u9762\u6587\u4ef6\u3001\u6309\u6a21\u677f\u751f\u6210\u62a5\u544a&#xff0c;\u751a\u81f3\u5bf9\u63a5\u4f01\u4e1a\u5185\u90e8\u7cfb\u7edf\u3002<\/p>\n<p>\u8ddf\u7740\u672c\u6587\u7684\u6b65\u9aa4&#xff0c;\u4f60\u5df2\u638c\u63e1\u4ece\u201c\u73af\u5883\u51c6\u5907\u2192\u4ee3\u7801\u5f00\u53d1\u2192\u5ba2\u6237\u7aef\u8c03\u7528\u2192\u8c03\u8bd5\u4f18\u5316\u201d\u7684\u5168\u6d41\u7a0b\u3002\u4e0b\u4e00\u6b65&#xff0c;\u4e0d\u59a8\u4ece\u4e00\u4e2a\u7b80\u5355\u9700\u6c42&#xff08;\u5982\u201c\u8ba9\u5927\u6a21\u578b\u8c03\u7528\u8ba1\u7b97\u5668\u201d&#xff09;\u5f00\u59cb\u5b9e\u8df5&#xff0c;\u9010\u6b65\u6269\u5c55\u5230\u66f4\u590d\u6742\u7684\u573a\u666f\u3002\u5728AI\u5e94\u7528\u843d\u5730\u7684\u6d6a\u6f6e\u4e2d&#xff0c;\u80fd\u8ba9\u5927\u6a21\u578b\u201c\u52a8\u624b\u5e72\u6d3b\u201d\u7684\u80fd\u529b&#xff0c;\u4f1a\u6210\u4e3a\u4f60\u4e0d\u53ef\u66ff\u4ee3\u7684\u7ade\u4e89\u529b\u3002<\/p>\n<h4>\u66f4\u591a\u6280\u672f\u5185\u5bb9<\/h4>\n<p>\u66f4\u591a\u6280\u672f\u5185\u5bb9\u53ef\u53c2\u89c1 \u6e05\u534e\u300aGPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u300b\u4e66\u7c4d\u914d\u5957\u89c6\u9891\u3010\u9648\u656c\u96f7\u3011\u3002 \u66f4\u591a\u7684\u6280\u672f\u4ea4\u6d41\u548c\u63a2\u8ba8\u4e5f\u6b22\u8fce\u52a0\u6211\u4e2a\u4eba\u5fae\u4fe1chenjinglei66\u3002<\/p>\n<h2>\u603b\u7ed3<\/h2>\n<p>\u6b64\u6587\u7ae0\u6709\u5bf9\u5e94\u7684\u914d\u5957\u65b0\u4e66\u6559\u6750\u548c\u89c6\u9891&#xff1a;<\/p>\n<p>\u3010\u914d\u5957\u65b0\u4e66\u6559\u6750\u3011 \u300aGPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u300b&#xff08;\u8ddf\u6211\u4e00\u8d77\u5b66\u4eba\u5de5\u667a\u80fd&#xff09;\u3010\u9648\u656c\u96f7\u7f16\u8457\u3011\u3010\u6e05\u534e\u5927\u5b66\u51fa\u7248\u793e\u3011 \u65b0\u4e66\u7279\u8272&#xff1a;\u300aGPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u300b&#xff08;\u8ddf\u6211\u4e00\u8d77\u5b66\u4eba\u5de5\u667a\u80fd&#xff09;\u662f\u4e00\u672c2025\u5e74\u6e05\u534e\u5927\u5b66\u51fa\u7248\u793e\u51fa\u7248\u7684\u56fe\u4e66&#xff0c;\u4f5c\u8005\u662f\u9648\u656c\u96f7&#xff0c;\u672c\u4e66\u6df1\u5165\u63a2\u8ba8\u4e86GPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u7684\u6280\u672f\u539f\u7406\u53ca\u5176\u5728\u4f01\u4e1a\u4e2d\u7684\u5e94\u7528\u843d\u5730\u3002 \u5168\u4e66\u51718\u7ae0&#xff0c;\u4ece\u5927\u6a21\u578b\u6280\u672f\u539f\u7406\u5207\u5165&#xff0c;\u9010\u6b65\u6df1\u5165\u5927\u6a21\u578b\u8bad\u7ec3\u53ca\u5fae\u8c03&#xff0c;\u8fd8\u4ecb\u7ecd\u4e86\u4f17\u591a\u56fd\u5185\u5916\u4e3b\u6d41\u5927\u6a21\u578b\u3002LangChain\u6280\u672f\u3001RAG\u68c0\u7d22\u589e\u5f3a\u751f\u6210\u3001\u591a\u6a21\u6001\u5927\u6a21\u578b\u7b49\u5747\u6709\u6df1\u5165\u8bb2\u89e3\u3002\u5bf9AI Agent\u667a\u80fd\u4f53&#xff0c;\u4ece\u5b9a\u4e49\u3001\u539f\u7406\u5230\u4e3b\u6d41\u6846\u67b6\u4e5f\u90fd\u8fdb\u884c\u4e86\u6df1\u5165\u8bb2\u89e3\u3002\u5728\u4f01\u4e1a\u5e94\u7528\u843d\u5730\u65b9\u9762&#xff0c;\u672c\u4e66\u63d0\u4f9b\u4e86\u4e30\u5bcc\u7684\u6848\u4f8b\u5206\u6790&#xff0c;\u5982\u57fa\u4e8e\u5927\u6a21\u578b\u7684\u5bf9\u8bdd\u5f0f\u63a8\u8350\u7cfb\u7edf\u3001\u591a\u6a21\u6001\u641c\u7d22\u3001NL2SQL\u6570\u636e\u5373\u5e2d\u67e5\u8be2\u3001\u667a\u80fd\u5ba2\u670d\u5bf9\u8bdd\u673a\u5668\u4eba\u3001\u591a\u6a21\u6001\u6570\u5b57\u4eba&#xff0c;\u4ee5\u53ca\u591a\u6a21\u6001\u5177\u8eab\u667a\u80fd\u7b49\u3002\u8fd9\u4e9b\u6848\u4f8b\u4e0d\u4ec5\u5c55\u793a\u4e86\u5927\u6a21\u578b\u6280\u672f\u7684\u5b9e\u9645\u5e94\u7528&#xff0c;\u4e5f\u4e3a\u8bfb\u8005\u63d0\u4f9b\u4e86\u5b9d\u8d35\u7684\u5b9e\u8df5\u7ecf\u9a8c\u3002 \u672c\u4e66\u9002\u5408\u5bf9\u5927\u6a21\u578b\u3001\u591a\u6a21\u6001\u6280\u672f\u53caAI Agent\u611f\u5174\u8da3\u7684\u8bfb\u8005\u9605\u8bfb&#xff0c;\u4e5f\u7279\u522b\u9002\u5408\u4f5c\u4e3a\u9ad8\u7b49\u9662\u6821\u672c\u79d1\u751f\u548c\u7814\u7a76\u751f\u7684\u6559\u6750\u6216\u53c2\u8003\u4e66\u3002\u4e66\u4e2d\u5185\u5bb9\u4e30\u5bcc\u3001\u7cfb\u7edf&#xff0c;\u65e2\u6709\u7406\u8bba\u77e5\u8bc6\u7684\u6df1\u5165\u8bb2\u89e3&#xff0c;\u4e5f\u6709\u5927\u91cf\u7684\u5b9e\u8df5\u6848\u4f8b\u548c\u4ee3\u7801\u793a\u4f8b&#xff0c;\u80fd\u591f\u5e2e\u52a9\u5b66\u751f\u5728\u638c\u63e1\u7406\u8bba\u77e5\u8bc6\u7684\u540c\u65f6&#xff0c;\u57f9\u517b\u5b9e\u9645\u64cd\u4f5c\u80fd\u529b\u548c\u89e3\u51b3\u95ee\u9898\u7684\u80fd\u529b\u3002\u901a\u8fc7\u9605\u8bfb\u672c\u4e66&#xff0c;\u8bfb\u8005\u5c06\u80fd\u591f\u66f4\u597d\u5730\u7406\u89e3\u5927\u6a21\u578b\u6280\u672f\u7684\u524d\u6cbf\u53d1\u5c55&#xff0c;\u5e76\u5c06\u5176\u5e94\u7528\u4e8e\u5b9e\u9645\u5de5\u4f5c\u4e2d&#xff0c;\u63a8\u52a8\u4eba\u5de5\u667a\u80fd\u6280\u672f\u7684\u8fdb\u6b65\u548c\u521b\u65b0\u3002<\/p>\n<p>\u3010\u914d\u5957\u89c6\u9891\u3011<\/p>\n<p>\u6e05\u534e\u300aGPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u300b\u4e66\u7c4d\u914d\u5957\u89c6\u9891\u3010\u9648\u656c\u96f7\u3011 \u89c6\u9891\u7279\u8272&#xff1a; \u524d\u6cbf\u6280\u672f\u6df1\u5ea6\u89e3\u6790&#xff0c;\u628a\u63e1\u884c\u4e1a\u8109\u640f<\/p>\n<p>\u5b9e\u6218\u9a71\u52a8&#xff0c;\u638c\u63e1\u5927\u6a21\u578b\u5f00\u53d1\u5168\u6d41\u7a0b<\/p>\n<p>\u667a\u80fd\u6d8c\u73b0\u4e0e AGI \u524d\u77bb&#xff0c;\u62a2\u5360\u6280\u672f\u9ad8\u5730<\/p>\n<p>\u4e0a\u4e00\u7bc7&#xff1a;\u300aGPT\u591a\u6a21\u6001\u5927\u6a21\u578b\u4e0eAI Agent\u667a\u80fd\u4f53\u300b\u7cfb\u5217\u4e00\u300b\u5927\u6a21\u578b\u6280\u672f\u539f\u7406 &#8211; \u5927\u6a21\u578b\u6280\u672f\u7684\u8d77\u6e90\u3001\u601d\u60f3 \u4e0b\u4e00\u7bc7&#xff1a;DeepSeek\u5927\u6a21\u578b\u6280\u672f\u7cfb\u5217\u4e94\u300bDeepSeek\u5927\u6a21\u578b\u57fa\u7840\u8bbe\u65bd\u5168\u89e3\u6790&#xff1a;\u652f\u6491\u4e07\u4ebf\u53c2\u6570\u6a21\u578b\u7684\u5e55\u540e\u82f1\u96c4<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb724\u6b21\uff0c\u70b9\u8d5e13\u6b21\uff0c\u6536\u85cf17\u6b21\u3002\u6458\u8981\uff1a MCP\uff08Model Context Protocol\uff09\u4f5c\u4e3a\u5927\u6a21\u578b\u4e0e\u5916\u90e8\u8d44\u6e90\u7684\u6807\u51c6\u5316\u63a5\u53e3\u534f\u8bae\uff0c\u89e3\u51b3\u4e86AI\u6a21\u578b\u8c03\u7528\u672c\u5730\u6587\u4ef6\u3001\u5de5\u5177\u6216API\u7684\u517c\u5bb9\u6027\u95ee\u9898\u3002\u672c\u6587\u57fa\u4e8ePython\u6280\u672f\u6808\uff0c\u8be6\u7ec6\u62c6\u89e3MCP\u670d\u52a1\u7684\u5f00\u53d1\u5168\u6d41\u7a0b\uff1a\u4ece\u73af\u5883\u914d\u7f6e\uff08Python\u22653.10\u3001\u865a\u62df\u73af\u5883\u3001SDK\u5b89\u88c5\uff09\u5230\u6838\u5fc3\u5f00\u53d1\uff08\u5de5\u5177\u51fd\u6570\u3001\u8d44\u6e90\u3001\u63d0\u793a\u8bcd\u6a21\u677f\u7684\u5b9a\u4e49\uff09\uff0c\u518d\u5230\u5ba2\u6237\u7aef\u8c03\u7528\u4e0e\u8c03\u8bd5\uff08CLINE\u914d\u7f6e\u3001MCP Inspector\u6392\u67e5\uff09\u3002\u901a\u8fc7\u5177\u4f53\u4ee3\u7801\u793a\u4f8b\uff08\u5982\u83b7\u53d6\u684c\u9762\u6587\u4ef6\u5217\u8868\u3001\u751f\u6210\u95ee\u5019\u8bed\u7b49\uff09\uff0c\u6f14\u793a\u5982\u4f55\u5b9e\u73b0\u201c5\u5206\u949f\u5feb\u901f\u5f00\u53d1\u201d\uff0c\u5e76\u7ed9\u51fa\u9ad8\u7ea7\u5e94\u7528\u5efa\u8bae\uff08\u6743\u9650\u63a7\u5236\u3001AP<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[5490,175,1646,99,81,98,50,207],"topic":[],"class_list":["post-53951","post","type-post","status-publish","format-standard","hentry","category-server","tag-gptai-agent","tag-chatgpt","tag-gpt","tag-java","tag-python","tag-spring-boot","tag-50","tag-207"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/53951.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb724\u6b21\uff0c\u70b9\u8d5e13\u6b21\uff0c\u6536\u85cf17\u6b21\u3002\u6458\u8981\uff1a MCP\uff08Model Context Protocol\uff09\u4f5c\u4e3a\u5927\u6a21\u578b\u4e0e\u5916\u90e8\u8d44\u6e90\u7684\u6807\u51c6\u5316\u63a5\u53e3\u534f\u8bae\uff0c\u89e3\u51b3\u4e86AI\u6a21\u578b\u8c03\u7528\u672c\u5730\u6587\u4ef6\u3001\u5de5\u5177\u6216API\u7684\u517c\u5bb9\u6027\u95ee\u9898\u3002\u672c\u6587\u57fa\u4e8ePython\u6280\u672f\u6808\uff0c\u8be6\u7ec6\u62c6\u89e3MCP\u670d\u52a1\u7684\u5f00\u53d1\u5168\u6d41\u7a0b\uff1a\u4ece\u73af\u5883\u914d\u7f6e\uff08Python\u22653.10\u3001\u865a\u62df\u73af\u5883\u3001SDK\u5b89\u88c5\uff09\u5230\u6838\u5fc3\u5f00\u53d1\uff08\u5de5\u5177\u51fd\u6570\u3001\u8d44\u6e90\u3001\u63d0\u793a\u8bcd\u6a21\u677f\u7684\u5b9a\u4e49\uff09\uff0c\u518d\u5230\u5ba2\u6237\u7aef\u8c03\u7528\u4e0e\u8c03\u8bd5\uff08CLINE\u914d\u7f6e\u3001MCP Inspector\u6392\u67e5\uff09\u3002\u901a\u8fc7\u5177\u4f53\u4ee3\u7801\u793a\u4f8b\uff08\u5982\u83b7\u53d6\u684c\u9762\u6587\u4ef6\u5217\u8868\u3001\u751f\u6210\u95ee\u5019\u8bed\u7b49\uff09\uff0c\u6f14\u793a\u5982\u4f55\u5b9e\u73b0\u201c5\u5206\u949f\u5feb\u901f\u5f00\u53d1\u201d\uff0c\u5e76\u7ed9\u51fa\u9ad8\u7ea7\u5e94\u7528\u5efa\u8bae\uff08\u6743\u9650\u63a7\u5236\u3001AP\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/53951.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2025-08-12T12:00:00+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/53951.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/53951.html\",\"name\":\"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2025-08-12T12:00:00+00:00\",\"dateModified\":\"2025-08-12T12:00:00+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/53951.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/53951.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/53951.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/53951.html","og_locale":"zh_CN","og_type":"article","og_title":"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb724\u6b21\uff0c\u70b9\u8d5e13\u6b21\uff0c\u6536\u85cf17\u6b21\u3002\u6458\u8981\uff1a MCP\uff08Model Context Protocol\uff09\u4f5c\u4e3a\u5927\u6a21\u578b\u4e0e\u5916\u90e8\u8d44\u6e90\u7684\u6807\u51c6\u5316\u63a5\u53e3\u534f\u8bae\uff0c\u89e3\u51b3\u4e86AI\u6a21\u578b\u8c03\u7528\u672c\u5730\u6587\u4ef6\u3001\u5de5\u5177\u6216API\u7684\u517c\u5bb9\u6027\u95ee\u9898\u3002\u672c\u6587\u57fa\u4e8ePython\u6280\u672f\u6808\uff0c\u8be6\u7ec6\u62c6\u89e3MCP\u670d\u52a1\u7684\u5f00\u53d1\u5168\u6d41\u7a0b\uff1a\u4ece\u73af\u5883\u914d\u7f6e\uff08Python\u22653.10\u3001\u865a\u62df\u73af\u5883\u3001SDK\u5b89\u88c5\uff09\u5230\u6838\u5fc3\u5f00\u53d1\uff08\u5de5\u5177\u51fd\u6570\u3001\u8d44\u6e90\u3001\u63d0\u793a\u8bcd\u6a21\u677f\u7684\u5b9a\u4e49\uff09\uff0c\u518d\u5230\u5ba2\u6237\u7aef\u8c03\u7528\u4e0e\u8c03\u8bd5\uff08CLINE\u914d\u7f6e\u3001MCP Inspector\u6392\u67e5\uff09\u3002\u901a\u8fc7\u5177\u4f53\u4ee3\u7801\u793a\u4f8b\uff08\u5982\u83b7\u53d6\u684c\u9762\u6587\u4ef6\u5217\u8868\u3001\u751f\u6210\u95ee\u5019\u8bed\u7b49\uff09\uff0c\u6f14\u793a\u5982\u4f55\u5b9e\u73b0\u201c5\u5206\u949f\u5feb\u901f\u5f00\u53d1\u201d\uff0c\u5e76\u7ed9\u51fa\u9ad8\u7ea7\u5e94\u7528\u5efa\u8bae\uff08\u6743\u9650\u63a7\u5236\u3001AP","og_url":"https:\/\/www.wsisp.com\/helps\/53951.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2025-08-12T12:00:00+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"5 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/53951.html","url":"https:\/\/www.wsisp.com\/helps\/53951.html","name":"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2025-08-12T12:00:00+00:00","dateModified":"2025-08-12T12:00:00+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/53951.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/53951.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/53951.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u65b0\u624b\u4e5f\u80fd\u5f00\u53d1MCP\u670d\u52a1\uff1a\u4ece0\u5199\u4ee3\u7801\u5230\u5ba2\u6237\u7aef\u8c03\u7528\uff0c\u5168\u6d41\u7a0b+\u907f\u5751\u6307\u5357"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/53951","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=53951"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/53951\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=53951"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=53951"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=53951"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=53951"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}