{"id":37699,"date":"2025-05-17T02:25:55","date_gmt":"2025-05-16T18:25:55","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/37699.html"},"modified":"2025-05-17T02:25:55","modified_gmt":"2025-05-16T18:25:55","slug":"mcp-rag-%e6%9c%8d%e5%8a%a1%e5%99%a8%ef%bc%9a%e5%ae%8c%e6%95%b4%e8%ae%be%e7%bd%ae%e5%92%8c%e4%bd%bf%e7%94%a8%e6%8c%87%e5%8d%97","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/37699.html","title":{"rendered":"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\u6307\u5357"},"content":{"rendered":"<p>\u5728\u5feb\u901f\u53d1\u5c55\u7684\u4eba\u5de5\u667a\u80fd\u5e94\u7528\u65f6\u4ee3&#xff0c;\u7ed3\u5408\u9759\u6001\u9886\u57df\u77e5\u8bc6\u548c\u5b9e\u65f6\u7f51\u7edc\u4fe1\u606f\u7684\u7cfb\u7edf\u9700\u6c42\u6bd4\u4ee5\u5f80\u4efb\u4f55\u65f6\u5019\u90fd\u66f4\u52a0\u8feb\u5207\u3002\u4f20\u7edf\u7684\u68c0\u7d22\u589e\u5f3a\u751f\u6210&#xff08;RAG&#xff09;\u6a21\u578b\u901a\u5e38\u4f9d\u8d56\u4e8e\u9884\u5148\u7d22\u5f15\u7684\u6570\u636e&#xff0c;\u8fd9\u9650\u5236\u4e86\u5b83\u4eec\u5bf9\u65b0\u53d1\u5c55\u7684\u53cd\u5e94\u80fd\u529b\u3002MCP-RAG Server\u901a\u8fc7\u5c06\u57fa\u4e8e\u8bed\u4e49\u7684\u5411\u91cf\u641c\u7d22&#xff08;\u901a\u8fc7Qdrant&#xff09;\u4e0e\u5b9e\u65f6\u7f51\u9875\u641c\u7d22\u80fd\u529b&#xff08;\u901a\u8fc7Scrapeless&#xff09;\u96c6\u6210&#xff0c;\u5f25\u8865\u4e86\u8fd9\u4e00\u5dee\u8ddd&#xff0c;\u4e3a\u667a\u80fd\u95ee\u7b54\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e00\u4e2a\u751f\u4ea7\u5c31\u7eea\u7684\u57fa\u7840\u3002\u65e0\u8bba\u60a8\u662f\u6784\u5efa\u5185\u90e8\u77e5\u8bc6\u4ee3\u7406\u7684\u4f01\u4e1a&#xff0c;\u8fd8\u662f\u6b63\u5728\u5b9e\u9a8cLLM\u96c6\u6210\u7684\u5f00\u53d1\u4eba\u5458&#xff0c;\u672c\u6307\u5357\u5c06\u5e26\u60a8\u5b8c\u6210MCP-RAG\u7684\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\u2014\u2014\u786e\u4fdd\u60a8\u80fd\u591f\u90e8\u7f72\u4e00\u4e2a\u73b0\u4ee3\u5316\u3001\u54cd\u5e94\u7075\u654f\u7684\u4eba\u5de5\u667a\u80fd\u77e5\u8bc6\u7cfb\u7edf\u3002<\/p>\n<h3 id=\"\u4ec0\u4e48\u662fMCP-RAG Server&#xff1f;\">\u4ec0\u4e48\u662fMCP-RAG Server&#xff1f;<\/h3>\n<p>MCP-RAG Server\u662f\u4e00\u4e2a\u57fa\u4e8eTypeScript\u7684\u7cfb\u7edf&#xff0c;\u7ed3\u5408\u4e86\u5411\u91cf\u641c\u7d22\u80fd\u529b\u548c\u5b9e\u65f6\u7f51\u7edc\u641c\u7d22&#xff0c;\u4ee5\u521b\u5efa\u589e\u5f3a\u7684\u4eba\u5de5\u667a\u80fd\u77e5\u8bc6\u7cfb\u7edf\u3002\u5b83\u63d0\u4f9b\u4e09\u4e2a\u4e3b\u8981\u5de5\u5177&#xff1a;<\/p>\n<li>\u673a\u5668\u5b66\u4e60\u5e38\u89c1\u95ee\u9898\u68c0\u7d22 &#8211; \u901a\u8fc7\u60a8\u7684\u5411\u91cf\u6570\u636e\u5e93\u8fdb\u884c\u8bed\u4e49\u641c\u7d22<\/li>\n<li>\u6587\u6863\u6dfb\u52a0 &#8211; \u4f7f\u7528\u65b0\u4fe1\u606f\u6269\u5c55\u77e5\u8bc6\u5e93<\/li>\n<li>\u7f51\u7edc\u641c\u7d22 &#8211; \u4ece\u4e92\u8054\u7f51\u4e0a\u83b7\u53d6\u5f53\u524d\u4fe1\u606f<\/li>\n<p>\u8be5\u7cfb\u7edf\u89e3\u51b3\u4e86\u5173\u952e\u7684AI\u5c40\u9650\u6027&#xff1a;\u8fc7\u65f6\u7684\u77e5\u8bc6\u3001\u7f3a\u4e4f\u9886\u57df\u4e13\u957f\u548c\u4f4e\u6548\u7684\u4fe1\u606f\u68c0\u7d22\u3002<\/p>\n<h3 id=\"Scrapeless\u4ecb\u7ecd&#xff1a;RAG\u7684\u7f51\u9875\u667a\u80fd\u589e\u5f3a\u5f15\u64ce\">Scrapeless\u4ecb\u7ecd&#xff1a;RAG\u7684\u7f51\u9875\u667a\u80fd\u589e\u5f3a\u5f15\u64ce<\/h3>\n<p>Scrapeless Google\u641c\u7d22\u6293\u53d6API\u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u7f51\u9875\u6293\u53d6API&#xff0c;\u63d0\u4f9b\u7a33\u5b9a\u7684\u641c\u7d22\u5f15\u64ce\u7ed3\u679c\u8bbf\u95ee&#xff0c;\u800c\u65e0\u9700\u62c5\u5fc3\u88ab\u4f20\u7edf\u722c\u866b\u963b\u585e\u3002<\/p>\n<p>\u4e3a\u4ec0\u4e48Scrapeless\u5bf9RAG\u7cfb\u7edf\u81f3\u5173\u91cd\u8981<\/p>\n<p>\u4f20\u7edf\u7684RAG\u7cfb\u7edf\u53d7\u9650\u4e8e\u5b83\u4eec\u7684\u9759\u6001\u77e5\u8bc6\u5e93\u3002Scrapeless\u901a\u8fc7\u4ee5\u4e0b\u65b9\u5f0f\u8f6c\u53d8\u4e86MCP-RAG Server&#xff1a;<\/p>\n<li>\u5b9e\u65f6\u4fe1\u606f\u68c0\u7d22&#xff1a;\u8bbf\u95ee\u6700\u65b0\u7684\u7f51\u9875\u4fe1\u606f<\/li>\n<li>\u77e5\u8bc6\u5e93\u589e\u5f3a&#xff1a;\u6301\u7eed\u7528\u5f53\u524d\u6570\u636e\u66f4\u65b0\u60a8\u7684\u5411\u91cf\u6570\u636e\u5e93<\/li>\n<li>\u8865\u5145\u641c\u7d22&#xff1a;\u5728\u5185\u90e8\u77e5\u8bc6\u4e0d\u8db3\u65f6\u586b\u8865\u7a7a\u767d<\/li>\n<li>\u591a\u5143\u89c6\u89d2&#xff1a;\u4ece\u4e0d\u540c\u5730\u7406\u533a\u57df\u548c\u8bed\u8a00\u4e2d\u641c\u7d22<\/li>\n<h3 id=\"Scrapeless\u5728MCP-RAG\u4e2d\u7684\u5de5\u4f5c\u539f\u7406\u662f\u4ec0\u4e48&#xff1f;\">Scrapeless\u5728MCP-RAG\u4e2d\u7684\u5de5\u4f5c\u539f\u7406\u662f\u4ec0\u4e48&#xff1f;<\/h3>\n<p>Scrapeless\u901a\u8fc7TypeScript\u5c01\u88c5\u7c7bScrapelessClient\u4e0eMCP-RAG Server\u96c6\u6210&#xff0c;\u4ee5\u5b9e\u73b0\u4ee5\u4e0b\u529f\u80fd&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>export class ScrapelessClient {<br \/>\n  private api: AxiosInstance;<\/p>\n<p>  constructor(config: ScrapelessConfig) {<br \/>\n    this.api &#061; axios.create({<br \/>\n      baseURL: config.baseURL,<br \/>\n      headers: {<br \/>\n        &#034;Content-Type&#034;: &#034;application\/json&#034;,<br \/>\n        &#034;x-api-token&#034;: config.token,<br \/>\n      },<br \/>\n    });<br \/>\n  }<\/p>\n<p>  async searchWeb(params: WebSearchParams) {<br \/>\n    try {<br \/>\n      const response &#061; await this.api.post(&#034;\/api\/v1\/scraper\/request&#034;, {<br \/>\n        actor: &#034;scraper.google.search&#034;,<br \/>\n        input: {<br \/>\n          q: params.query,<br \/>\n          gl: params.country || &#034;us&#034;,<br \/>\n          hl: params.language || &#034;en&#034;,<br \/>\n          google_domain: params.domain || &#034;google.com&#034;<br \/>\n        }<br \/>\n      });<\/p>\n<p>      return {<br \/>\n        query: params.query,<br \/>\n        results: response.data<br \/>\n      };<br \/>\n    } catch (error) {<br \/>\n      \/\/ \u9519\u8bef\u5904\u7406&#8230;<br \/>\n    }<br \/>\n  }<br \/>\n} <\/p>\n<h4 id=\"\u652f\u6301\u7684\u9ad8\u7ea7\u529f\u80fd\">\u652f\u6301\u7684\u9ad8\u7ea7\u529f\u80fd<\/h4>\n<table>\n<tr>\u529f\u80fd\u63cf\u8ff0<\/tr>\n<tbody>\n<tr>\n<td>Google\u641c\u7d22\u96c6\u6210<\/td>\n<td>\u4f7f\u7528scraper.google.search\u89d2\u8272\u83b7\u53d6\u641c\u7d22\u7ed3\u679c<\/td>\n<\/tr>\n<tr>\n<td>\u5730\u7406\u76ee\u6807\u5b9a\u4f4d<\/td>\n<td>\u4f7f\u7528gl\u53c2\u6570\u63a7\u5236\u56fd\u5bb6\/\u5730\u533a<\/td>\n<\/tr>\n<tr>\n<td>\u591a\u8bed\u8a00\u652f\u6301<\/td>\n<td>\u4f7f\u7528hl\u53c2\u6570\u4ee5\u4e0d\u540c\u8bed\u8a00\u8fd4\u56de\u7ed3\u679c<\/td>\n<\/tr>\n<tr>\n<td>\u641c\u7d22\u5f15\u64ce\u57df\u540d\u5207\u6362<\/td>\n<td>\u652f\u6301\u591a\u4e2a\u57df\u540d&#xff0c;\u5982google.de\u3001google.fr\u7b49<\/td>\n<\/tr>\n<tr>\n<td>\u4ee3\u7406\u81ea\u52a8\u7ba1\u7406<\/td>\n<td>\u9ed8\u8ba4\u542f\u7528\u4ee3\u7406\u8f6e\u6362\u4ee5\u907f\u514dIP\u963b\u585e<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3 id=\"\u667a\u80fd\u95ee\u7b54\u7cfb\u7edf\u90e8\u7f72\u6307\u5357&#xff08;\u57fa\u4e8e\u5411\u91cf\u641c\u7d22 &#043; \u5b9e\u65f6\u7f51\u9875\u641c\u7d22&#xff09;\">\u667a\u80fd\u95ee\u7b54\u7cfb\u7edf\u90e8\u7f72\u6307\u5357&#xff08;\u57fa\u4e8e\u5411\u91cf\u641c\u7d22 &#043; \u5b9e\u65f6\u7f51\u9875\u641c\u7d22&#xff09;<\/h3>\n<h4 id=\"\u7b2c1\u6b65&#xff1a;\u521d\u59cb\u5316\u9879\u76ee\u7ed3\u6784\u5e76\u5b89\u88c5\u4f9d\u8d56\">\u7b2c1\u6b65&#xff1a;\u521d\u59cb\u5316\u9879\u76ee\u7ed3\u6784\u5e76\u5b89\u88c5\u4f9d\u8d56<\/h4>\n<p>\u514b\u9686\u5e76\u8bbe\u7f6e\u9879\u76ee&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>git clone git&#064;github.com:scrapeless-ai\/mcp-rag-server.git<br \/>\ncd mcp-rag-server <\/p>\n<p>\u5206\u6790\u9879\u76ee\u7ed3\u6784&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>mcp-rag-server\/<br \/>\n\u251c\u2500\u2500 src\/<br \/>\n\u2502   \u251c\u2500\u2500 config.ts<br \/>\n\u2502   \u251c\u2500\u2500 index.ts<br \/>\n\u2502   \u251c\u2500\u2500 server.ts<br \/>\n\u2502   \u251c\u2500\u2500 qdrant-client.ts<br \/>\n\u2502   \u2514\u2500\u2500 scrapeless-client.ts<br \/>\n\u251c\u2500\u2500 package.json<br \/>\n\u251c\u2500\u2500 tsconfig.json<br \/>\n\u2514\u2500\u2500 .env <\/p>\n<p>\u5b89\u88c5\u4f9d\u8d56&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>npm install <\/p>\n<p>&#x1f4a1;\u89e3\u51b3\u7684\u95ee\u9898&#xff1a; \u786e\u4fddTypeScript\u9879\u76ee\u73af\u5883\u5df2\u51c6\u5907\u5c31\u7eea&#xff0c;\u5fc5\u8981\u7684\u4f9d\u8d56&#xff08;\u5982&#064;modelcontextprotocol\/sdk\u3001axios\u3001zod\u7b49&#xff09;\u5df2\u96c6\u6210&#xff0c;\u5e76\u4e14\u5f00\u53d1\u6240\u9700\u7684\u7c7b\u578b\u5b9a\u4e49\u4e5f\u5df2\u81ea\u52a8\u914d\u7f6e\u3002<\/p>\n<h4 id=\"\u7b2c2\u6b65&#xff1a;\u73af\u5883\u914d\u7f6e\">\u7b2c2\u6b65&#xff1a;\u73af\u5883\u914d\u7f6e<\/h4>\n<p>\u521b\u5efa.env\u6587\u4ef6&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>QDRANT_URL&#061;http:\/\/localhost:6333<br \/>\nQDRANT_API_KEY&#061;<br \/>\nQDRANT_COLLECTION&#061;ml_faq_collection<br \/>\nSCRAPELESS_KEY&#061;\u4f60\u7684_scrapeless_api_key<br \/>\nSCRAPELESS_BASE_URL&#061;https:\/\/api.scrapeless.com   <\/p>\n<p>\u7406\u89e3\u914d\u7f6e&#xff08;\u6765\u81ea config.ts&#xff09;&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>const QDRANT_URL &#061; process.env.QDRANT_URL?.trim() || &#034;http:\/\/localhost:6333&#034;;<br \/>\nconst QDRANT_API_KEY &#061; process.env.QDRANT_API_KEY?.trim() || &#034;&#034;;<br \/>\nconst QDRANT_COLLECTION &#061; process.env.QDRANT_COLLECTION?.trim() || &#034;ml_faq_collection&#034;;<br \/>\nconst SCRAPELESS_KEY &#061; process.env.SCRAPELESS_KEY?.trim();<br \/>\nconst SCRAPELESS_BASE_URL &#061; process.env.SCRAPELESS_BASE_URL?.trim() || &#034;https:\/\/api.scrapeless.com&#034;; <\/p>\n<p>&#x1f4a1;\u95ee\u9898\u89e3\u51b3&#xff1a;<\/p>\n<p>\u63d0\u4f9b\u5916\u90e8\u4f9d\u8d56\u9879\u7684\u6b63\u786e\u8fde\u63a5\u53c2\u6570&#xff08;Qdrant \u5411\u91cf\u6570\u636e\u5e93\u548c Scrapeless \u5b9e\u65f6\u641c\u7d22&#xff09;\u3002\u914d\u7f6e\u4ee3\u7801\u4e2d\u5185\u7f6e\u4e86\u9ed8\u8ba4\u503c\u548c trim() \u5904\u7406\u4ee5\u9632\u6b62\u53d8\u91cf\u683c\u5f0f\u9519\u8bef\u3002\u5982\u679c\u7f3a\u5c11 Scrapeless \u5bc6\u94a5&#xff0c;\u5c06\u53d1\u51fa\u8b66\u544a\u3002<\/p>\n<h4 id=\"\u7b2c 3 \u6b65&#xff1a;\u8bbe\u7f6e Qdrant \u5411\u91cf\u6570\u636e\u5e93\">\u7b2c 3 \u6b65&#xff1a;\u8bbe\u7f6e Qdrant \u5411\u91cf\u6570\u636e\u5e93<\/h4>\n<p>\u4f7f\u7528 Docker \u542f\u52a8 Qdrant&#xff1a;<\/p>\n<p>Copy<\/p>\n<p># \u62c9\u53d6 Qdrant \u955c\u50cf<br \/>\ndocker pull qdrant\/qdrant  <\/p>\n<p># \u8fd0\u884c\u5177\u6709\u6570\u636e\u6301\u4e45\u6027\u7684 Qdrant \u5bb9\u5668<br \/>\ndocker run -d \\\\<br \/>\n  &#8211;name qdrant-server \\\\<br \/>\n  -p 6333:6333 \\\\<br \/>\n  -p 6334:6334 \\\\<br \/>\n  -v $(pwd)\/qdrant_storage:\/qdrant\/storage \\\\<br \/>\n  qdrant\/qdrant   <\/p>\n<p>\u521b\u5efa FAQ \u5411\u91cf\u96c6\u5408&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>curl -X PUT &#039;http:\/\/localhost:6333\/collections\/ml_faq_collection&#039; \\\\<br \/>\n  -H &#039;Content-Type: application\/json&#039; \\\\<br \/>\n  &#8211;data-raw &#039;{<br \/>\n    &#034;vectors&#034;: {<br \/>\n      &#034;size&#034;: 1536,<br \/>\n      &#034;distance&#034;: &#034;Cosine&#034;<br \/>\n    }<br \/>\n  }&#039;   <\/p>\n<p>&#x1f4a1;\u95ee\u9898\u89e3\u51b3&#xff1a;<\/p>\n<p>\u914d\u7f6e\u8bed\u4e49\u5411\u91cf\u68c0\u7d22\u5b58\u50a8&#xff0c;\u4f7f\u7528 1536 \u7ef4\u548c\u4f59\u5f26\u76f8\u4f3c\u5ea6&#xff0c;\u5e76\u4e0e\u5d4c\u5165\u751f\u6210\u5668\u8f93\u51fa\u548c QdrantClient \u8c03\u7528\u517c\u5bb9\u3002<\/p>\n<h4 id=\"\u7b2c 4 \u6b65&#xff1a;\u96c6\u6210 Scrapeless \u5b9e\u65f6\u7f51\u9875\u641c\u7d22\">\u7b2c 4 \u6b65&#xff1a;\u96c6\u6210 Scrapeless \u5b9e\u65f6\u7f51\u9875\u641c\u7d22<\/h4>\n<p>\u83b7\u53d6 Scrapeless API \u5bc6\u94a5&#xff1a;<\/p>\n<li>\u8bbf\u95ee\u00a0Scrapeless\u00a0\u5e76\u521b\u5efa\u4e00\u4e2a\u5e10\u6237<\/li>\n<li>\u4ece\u4eea\u8868\u677f\u4e2d\u68c0\u7d22\u60a8\u7684 API \u4ee4\u724c<\/li>\n<p class=\"img-center\"><img loading=\"lazy\" decoding=\"async\" alt=\"\u68c0\u7d22\u60a8\u7684 API \u4ee4\u724c\" height=\"1320\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250516182552-6827833094441.png\" width=\"2584\" \/><\/p>\n<li>\u5c06\u5176\u6dfb\u52a0\u5230 .env \u6587\u4ef6\u4e0b\u7684 SCRAPELESS_KEY<\/li>\n<p>\u6d4b\u8bd5 Scrapeless \u8fde\u63a5&#xff1a;<\/p>\n<p>Copy<\/p>\n<p># \u6d4b\u8bd5 API \u8fde\u63a5&#xff08;\u53ef\u9009&#xff09;<br \/>\ncurl -X POST &#039;https:\/\/api.scrapeless.com\/api\/v1\/scraper\/request&#039; \\\\<br \/>\n  -H &#039;Content-Type: application\/json&#039; \\\\<br \/>\n  -H &#039;x-api-token: YOUR_API_KEY&#039; \\\\<br \/>\n  -d &#039;{&#034;actor&#034;: &#034;scraper.google.search&#034;, &#034;input&#034;: {&#034;q&#034;: &#034;test query&#034;}}&#039;   <\/p>\n<p>\u95ee\u9898\u89e3\u51b3&#xff1a;\u6b64\u6b65\u9aa4\u786e\u4fdd Scrapeless API \u6b63\u786e\u914d\u7f6e\u3002\u7cfb\u7edf\u5305\u62ec\u9a8c\u8bc1\u4ee5\u68c0\u67e5 API \u5bc6\u94a5\u662f\u5426\u5df2\u8bbe\u7f6e&#xff0c;\u9632\u6b62\u5728\u7f51\u9875\u641c\u7d22\u671f\u95f4\u51fa\u73b0\u8fd0\u884c\u65f6\u9519\u8bef\u3002<\/p>\n<h4 id=\"\u7b2c 5 \u6b65&#xff1a;\u6784\u5efa TypeScript \u9879\u76ee\">\u7b2c 5 \u6b65&#xff1a;\u6784\u5efa TypeScript \u9879\u76ee<\/h4>\n<p>\u5c06 TypeScript \u7f16\u8bd1\u4e3a JavaScript&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>npm run build   <\/p>\n<p>\u6784\u5efa\u671f\u95f4\u53d1\u751f\u7684\u4e8b\u60c5&#xff08;\u6765\u81ea package.json&#xff09;&#xff1a;<\/p>\n<p>languageCopy<\/p>\n<p>{<br \/>\n  &#034;scripts&#034;: {<br \/>\n    &#034;build&#034;: &#034;tsc &amp;&amp; chmod 755 build\/index.js&#034;,<br \/>\n    &#034;start&#034;: &#034;node build\/index.js&#034;<br \/>\n  }<br \/>\n}   <\/p>\n<p>\u9a8c\u8bc1\u6784\u5efa\u8f93\u51fa&#xff1a;<\/p>\n<p>languageCopy<\/p>\n<p>ls build\/<br \/>\n# \u5e94\u663e\u793a&#xff1a;index.js, server.js, config.js, qdrant-client.js, scrapeless-client.js   <\/p>\n<p>\u95ee\u9898\u89e3\u51b3&#xff1a;<\/p>\n<p>\u6b64\u6b65\u9aa4\u5c06 TypeScript \u7f16\u8bd1\u4e3a JavaScript&#xff0c;\u5e76\u786e\u4fdd\u4e3b\u5165\u53e3\u70b9\u53ef\u6267\u884c\u3002\u6784\u5efa\u8fc7\u7a0b\u8f93\u51fa\u4e0e Node.js \u517c\u5bb9\u7684 ES \u6a21\u5757&#xff08;\u5982 package.json \u4e2d\u6240\u6307\u5b9a\u7684\u00a0&#034;type&#034;: &#034;module&#034;&#xff09;\u3002<\/p>\n<h4 id=\"\u7b2c 6 \u6b65&#xff1a;\u542f\u52a8 MCP \u670d\u52a1\u5668\">\u7b2c 6 \u6b65&#xff1a;\u542f\u52a8 MCP \u670d\u52a1\u5668<\/h4>\n<p>languageCopy<\/p>\n<p>\u8fd0\u884c\u670d\u52a1\u5668&#xff1a;<br \/>\nnpm start   <\/p>\n<p>\u542f\u52a8\u671f\u95f4\u53d1\u751f\u7684\u4e8b\u60c5&#xff08;\u6765\u81ea index.ts&#xff09;&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>async function main() {<br \/>\n  try {<br \/>\n    console.log(&#034;\u542f\u52a8 MCP Agentic RAG \u670d\u52a1\u5668&#8230;&#034;);<br \/>\n    const transport &#061; new StdioServerTransport();<br \/>\n    await server.connect(transport);<br \/>\n    console.log(&#034;MCP \u670d\u52a1\u5668\u6b63\u5728\u7aef\u53e3 8080 \u4e0a\u8fd0\u884c&#034;);<br \/>\n  } catch (error) {<br \/>\n    console.error(&#034;main() \u4e2d\u7684\u81f4\u547d\u9519\u8bef:&#034;, error);<br \/>\n    process.exit(1);<br \/>\n  }<br \/>\n}   <\/p>\n<p>\u95ee\u9898\u89e3\u51b3&#xff1a;<\/p>\n<p>\u6b64\u6b65\u9aa4\u542f\u52a8 MCP \u670d\u52a1\u5668&#xff0c;\u4f7f\u7528 STDIO \u4f20\u8f93\u8fdb\u884c\u901a\u4fe1\u3002\u670d\u52a1\u5668\u4ee5\u9002\u5f53\u7684\u9519\u8bef\u5904\u7406\u548c\u65e5\u5fd7\u8bb0\u5f55\u8fdb\u884c\u521d\u59cb\u5316\u3002<\/p>\n<p>\u901a\u8fc7\u9075\u5faa\u4e0a\u8ff0\u516d\u4e2a\u6b65\u9aa4&#xff0c;\u60a8\u5c06\u6784\u5efa\u4e00\u4e2a\u5177\u6709\u4ee5\u4e0b\u529f\u80fd\u7684 AI \u9a71\u52a8\u95ee\u7b54\u7cfb\u7edf&#xff1a;<\/p>\n<ul>\n<li>\u8bed\u4e49\u95ee\u7b54\u80fd\u529b&#xff08;\u7531 Qdrant \u5411\u91cf\u6570\u636e\u5e93\u63d0\u4f9b\u652f\u6301&#xff09;<\/li>\n<li>\u5b9e\u65f6\u7f51\u9875\u589e\u5f3a&#xff08;\u901a\u8fc7 Scrapeless API \u96c6\u6210&#xff09;<\/li>\n<li>LLM \u51c6\u5907\u5c31\u7eea\u7684\u57fa\u7840\u8bbe\u65bd&#xff08;\u57fa\u4e8e MCP \u534f\u8bae\u6807\u51c6&#xff09; \u8fd9\u4e3a\u4f01\u4e1a\u6216\u5f00\u53d1\u4eba\u5458\u5feb\u901f\u90e8\u7f72\u751f\u4ea7\u5c31\u7eea\u7684 RAG&#xff08;\u68c0\u7d22\u589e\u5f3a\u751f\u6210&#xff09;\u7cfb\u7edf\u6253\u4e0b\u4e86\u575a\u5b9e\u7684\u57fa\u7840\u3002<\/li>\n<\/ul>\n<h3 id=\"\u6838\u5fc3\u7ec4\u4ef6\u7684\u8be6\u7ec6\u8bf4\u660e\">\u6838\u5fc3\u7ec4\u4ef6\u7684\u8be6\u7ec6\u8bf4\u660e<\/h3>\n<h4 id=\"QdrantClient&#xff1a;\u5411\u91cf\u5904\u7406\u5f15\u64ce\">QdrantClient&#xff1a;\u5411\u91cf\u5904\u7406\u5f15\u64ce<\/h4>\n<p>QdrantClient \u63d0\u4f9b\u5d4c\u5165\u751f\u6210\u548c\u5411\u91cf\u6570\u636e\u5e93\u4ea4\u4e92\u529f\u80fd\u3002\u793a\u4f8b\u4f7f\u7528\u4e00\u79cd\u7b80\u5355\u7684\u786e\u5b9a\u6027\u5d4c\u5165\u65b9\u6cd5\u8fdb\u884c\u6f14\u793a&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>private generateEmbedding(text: string): number[] {<br \/>\n  const seed &#061; [&#8230;text].reduce((sum, char) &#061;&gt; sum &#043; char.charCodeAt(0), 0) % 10000;<br \/>\n  const vector: number[] &#061; [];  <\/p>\n<p>  let value &#061; seed;<br \/>\n  for (let i &#061; 0; i &lt; 1536; i&#043;&#043;) {<br \/>\n    value &#061; (value * 48271) % 2147483647;<br \/>\n    vector.push((value \/ 2147483647) * 2 &#8211; 1);<br \/>\n  }  <\/p>\n<p>  return vector;<br \/>\n}   <\/p>\n<p>\u4e3b\u8981\u7279\u70b9&#xff1a;<\/p>\n<ul>\n<li>\u7b80\u5355\u7684\u786e\u5b9a\u6027\u5d4c\u5165\u751f\u6210<\/li>\n<li>\u6dfb\u52a0\u6587\u6863\u7684 Upsert \u64cd\u4f5c<\/li>\n<li>\u5177\u6709\u53ef\u914d\u7f6e\u8bc4\u5206\u9608\u503c\u7684\u8bed\u4e49\u641c\u7d22<\/li>\n<li>\u5408\u9002\u7684\u9519\u8bef\u5904\u7406\u548c\u540e\u5907\u54cd\u5e94<\/li>\n<\/ul>\n<h4 id=\"ScrapelessClient&#xff1a;\u7f51\u7edc\u641c\u7d22\u5f15\u64ce\u63a5\u53e3\">ScrapelessClient&#xff1a;\u7f51\u7edc\u641c\u7d22\u5f15\u64ce\u63a5\u53e3<\/h4>\n<p>ScrapelessClient \u8bbf\u95ee Scrapeless API \u4ee5\u5b9e\u73b0\u7f51\u7edc\u641c\u7d22&#xff0c;\u5e76\u652f\u6301\u9ad8\u7ea7\u641c\u7d22\u53c2\u6570&#xff1a;<\/p>\n<p>Copy<\/p>\n<p>async searchWeb(params: WebSearchParams) {<br \/>\n  try {<br \/>\n    if (!this.api.defaults.headers.common[&#034;x-api-token&#034;]) {<br \/>\n      throw new Error(&#034;Scrapeless API \u5bc6\u94a5\u672a\u8bbe\u7f6e&#034;);<br \/>\n    }<\/p>\n<p>    const response &#061; await this.api.post(&#034;\/api\/v1\/scraper\/request&#034;, {<br \/>\n      actor: &#034;scraper.google.search&#034;,<br \/>\n      input: {<br \/>\n        q: params.query,<br \/>\n        gl: params.country || &#034;us&#034;,<br \/>\n        hl: params.language || &#034;en&#034;,<br \/>\n        google_domain: params.domain || &#034;google.com&#034;<br \/>\n      }<br \/>\n    });<\/p>\n<p>    return {<br \/>\n      query: params.query,<br \/>\n      results: response.data<br \/>\n    };<br \/>\n  } catch (error) {<br \/>\n    \/\/ \u9519\u8bef\u5904\u7406&#8230;<br \/>\n  }<br \/>\n} <\/p>\n<p>\u4e3b\u8981\u7279\u70b9&#xff1a;<\/p>\n<ul>\n<li>\u901a\u8fc7 Scrapeless \u96c6\u6210\u8c37\u6b4c\u641c\u7d22<\/li>\n<li>\u53ef\u914d\u7f6e\u7684\u56fd\u5bb6\u3001\u8bed\u8a00\u548c\u57df\u540d<\/li>\n<li>\u5168\u9762\u7684\u9519\u8bef\u5904\u7406<\/li>\n<li>API \u5bc6\u94a5\u9a8c\u8bc1<\/li>\n<\/ul>\n<h4 id=\"MCP \u670d\u52a1\u5668\u5de5\u5177\">MCP \u670d\u52a1\u5668\u5de5\u5177<\/h4>\n<p>server.ts \u6587\u4ef6\u5b9a\u4e49\u4e86\u4e09\u4e2a\u4e3b\u8981\u5de5\u5177&#xff1a;<\/p>\n<li>machine-learning-faq-retrieval:<\/li>\n<ul>\n<li>\u5728\u5411\u91cf\u6570\u636e\u5e93\u4e2d\u641c\u7d22 ML \u6982\u5ff5<\/li>\n<li>\u4f7f\u7528\u8bed\u4e49\u76f8\u4f3c\u5ea6\u5339\u914d<\/li>\n<li>\u8fd4\u56de\u5e26\u6709\u5206\u6570\u7684\u683c\u5f0f\u5316\u7ed3\u679c<\/li>\n<\/ul>\n<li>add-document-to-faq:<\/li>\n<ul>\n<li>\u5411\u77e5\u8bc6\u5e93\u6dfb\u52a0\u65b0\u6587\u6863<\/li>\n<li>\u652f\u6301\u5143\u6570\u636e&#xff08;\u7c7b\u522b\u3001\u6765\u6e90\u3001\u6807\u7b7e&#xff09;<\/li>\n<li>\u9002\u5f53\u7684\u9519\u8bef\u5904\u7406&#xff0c;\u63d0\u4f9b\u8be6\u7ec6\u54cd\u5e94<\/li>\n<\/ul>\n<li>scrapeless-web-search:<\/li>\n<ul>\n<li>\u901a\u8fc7 Scrapeless API \u6267\u884c\u7f51\u7edc\u641c\u7d22<\/li>\n<li>\u53ef\u914d\u7f6e\u7684\u641c\u7d22\u53c2\u6570<\/li>\n<li>\u5b9e\u65f6\u4fe1\u606f\u68c0\u7d22<\/li>\n<\/ul>\n<h3 id=\"\u4f7f\u7528\u6307\u5357&#xff1a;\u4f7f\u7528 Scrapeless \u7cfb\u7edf\">\u4f7f\u7528\u6307\u5357&#xff1a;\u4f7f\u7528 Scrapeless \u7cfb\u7edf<\/h3>\n<h4 id=\"\u57fa\u672c\u7528\u6cd5\u793a\u4f8b\">\u57fa\u672c\u7528\u6cd5\u793a\u4f8b<\/h4>\n<p>\u641c\u7d22\u77e5\u8bc6\u5e93&#xff1a;<\/p>\n<p>\u4f7f\u7528 machine-learning-faq-retrieval \u67e5\u627e\u5173\u4e8e\u795e\u7ecf\u7f51\u7edc\u7684\u4fe1\u606f <\/p>\n<p>\u6dfb\u52a0\u65b0\u4fe1\u606f&#xff1a;<\/p>\n<p>\u4f7f\u7528 add-document-to-faq \u6dfb\u52a0\u4ee5\u4e0b\u5185\u5bb9&#xff1a;<br \/>\n\u6587\u672c&#xff1a;\u201c\u968f\u673a\u68ee\u6797\u662f\u96c6\u6210\u5b66\u4e60\u65b9\u6cd5\u2026\u201d<br \/>\n\u7c7b\u522b&#xff1a;\u201c\u96c6\u6210\u65b9\u6cd5\u201d<br \/>\n\u6807\u7b7e&#xff1a;[\u201c\u968f\u673a\u68ee\u6797\u201d&#xff0c;\u201c\u96c6\u6210\u5b66\u4e60\u201d] <\/p>\n<p>\u901a\u8fc7 Scrapeless \u641c\u7d22\u7f51\u7edc&#xff1a;<\/p>\n<p>\u4f7f\u7528 scrapeless-web-search \u67e5\u627e AI \u7684\u6700\u65b0\u8fdb\u5c55 <\/p>\n<p>\u9ad8\u7ea7 Scrapeless \u7528\u6cd5&#xff1a;<\/p>\n<p>\u4f7f\u7528 scrapeless-web-search&#xff0c;\u53c2\u6570\u5982\u4e0b&#xff1a;<br \/>\n\u67e5\u8be2&#xff1a;\u201c\u6700\u65b0\u7684 PyTorch \u7279\u6027\u201d<br \/>\n\u56fd\u5bb6&#xff1a;\u201cuk\u201d<br \/>\n\u8bed\u8a00&#xff1a;\u201cen\u201d<br \/>\n\u57df\u540d&#xff1a;\u201cgoogle.co.uk\u201d <\/p>\n<h4 id=\"\u4e0e Scrapeless \u96c6\u6210\u7684\u9ad8\u7ea7\u5de5\u4f5c\u6d41\u7a0b\">\u4e0e Scrapeless \u96c6\u6210\u7684\u9ad8\u7ea7\u5de5\u4f5c\u6d41\u7a0b<\/h4>\n<p>\u77e5\u8bc6\u5e93\u589e\u5f3a&#xff1a;<\/p>\n<p>1. \u4f7f\u7528 scrapeless-web-search \u67e5\u627e\u201c\u6700\u65b0\u7684\u53d8\u538b\u5668\u6a21\u578b2024\u201d<br \/>\n2. \u4f7f\u7528 add-document-to-faq \u6dfb\u52a0\u76f8\u5173\u53d1\u73b0<br \/>\n3. \u4f7f\u7528 machine-learning-faq-retrieval \u9a8c\u8bc1\u4fe1\u606f\u662f\u5426\u53ef\u641c\u7d22 <\/p>\n<p>\u4fe1\u606f\u9a8c\u8bc1&#xff1a;<\/p>\n<p>1. \u4f7f\u7528 machine-learning-faq-retrieval \u68c0\u67e5\u73b0\u6709\u77e5\u8bc6<br \/>\n2. \u4f7f\u7528 scrapeless-web-search \u67e5\u627e\u5f53\u524d\u4fe1\u606f<br \/>\n3. \u5bf9\u6bd4\u5e76\u76f8\u5e94\u66f4\u65b0\u77e5\u8bc6\u5e93 <\/p>\n<p>\u591a\u8bed\u8a00\u77e5\u8bc6\u6784\u5efa&#xff1a;<\/p>\n<p>1. \u4f7f\u7528 scrapeless-web-search \u7684 country&#061;&#034;de&#034; \u548c language&#061;&#034;de&#034; \u67e5\u627e\u5fb7\u56fd\u7684 AI \u7814\u7a76<br \/>\n2. \u4f7f\u7528 add-document-to-faq \u6dfb\u52a0\u7ffb\u8bd1\u6458\u8981<br \/>\n3. \u6784\u5efa\u591a\u8bed\u8a00\u77e5\u8bc6\u5e93 <\/p>\n<p>\u4e0e Claude Desktop \u96c6\u6210<\/p>\n<p>\u8be5\u9879\u76ee\u5305\u62ec Claude Desktop \u96c6\u6210\u7684\u793a\u4f8b\u914d\u7f6e&#xff1a;<\/p>\n<p>{<br \/>\n  &#034;mcpServers&#034;: {<br \/>\n    &#034;MCP-RAG-app&#034;: {<br \/>\n      &#034;command&#034;: &#034;node&#034;,<br \/>\n      &#034;args&#034;: [&#034;your-path\/to\/build\/index.js&#034;],<br \/>\n      &#034;host&#034;: &#034;127.0.0.1&#034;,<br \/>\n      &#034;port&#034;: 8080,<br \/>\n      &#034;timeout&#034;: 30000,<br \/>\n      &#034;env&#034;: {<br \/>\n        &#034;QDRANT_URL&#034;: &#034;http:\/\/localhost:6333&#034;,<br \/>\n        &#034;QDRANT_API_KEY&#034;: &#034;&#034;,<br \/>\n        &#034;QDRANT_COLLECTION&#034;: &#034;ml_faq_collection&#034;,<br \/>\n        &#034;SCRAPELESS_KEY&#034;: &#034;SCRAPELESS_KEY&#034;<br \/>\n      }<br \/>\n    }<br \/>\n  }<br \/>\n} <\/p>\n<h3 id=\"\u5e38\u89c1\u95ee\u9898\u53ca\u89e3\u51b3\u65b9\u6848\">\u5e38\u89c1\u95ee\u9898\u53ca\u89e3\u51b3\u65b9\u6848<\/h3>\n<li>\u6784\u5efa\u9519\u8bef&#xff1a;<\/li>\n<ul>\n<li>\u786e\u4fdd Node.js \u7248\u672c &gt;&#061; 18<\/li>\n<li>\u68c0\u67e5 TypeScript \u7f16\u8bd1&#xff1a;npx tsc &#8211;noEmit<\/li>\n<\/ul>\n<li>\u8fd0\u884c\u65f6\u9519\u8bef&#xff1a;<\/li>\n<ul>\n<li>\u9a8c\u8bc1 Qdrant \u662f\u5426\u6b63\u5728\u8fd0\u884c&#xff1a;curl\u00a0http:\/\/localhost:6333\/health<\/li>\n<li>\u68c0\u67e5\u73af\u5883\u53d8\u91cf\u662f\u5426\u6b63\u786e\u8bbe\u7f6e<\/li>\n<li>\u786e\u4fdd Scrapeless API \u5bc6\u94a5\u6709\u6548<\/li>\n<\/ul>\n<li>Scrapeless \u7279\u5b9a\u95ee\u9898&#xff1a;<\/li>\n<ul>\n<li>\u9a8c\u8bc1 API \u5bc6\u94a5\u662f\u5426\u5728\u73af\u5883\u4e2d\u6b63\u786e\u8bbe\u7f6e<\/li>\n<li>\u68c0\u67e5 Scrapeless \u63a7\u5236\u9762\u677f\u4e2d\u7684 API \u914d\u989d\u548c\u9650\u5236<\/li>\n<li>\u786e\u4fdd\u6b63\u786e\u914d\u7f6e API \u7aef\u70b9<\/li>\n<\/ul>\n<li>\u8fde\u63a5\u95ee\u9898&#xff1a;<\/li>\n<ul>\n<li>\u9a8c\u8bc1\u7aef\u53e3\u662f\u5426\u53ef\u7528&#xff08;Qdrant \u7684\u7aef\u53e3\u4e3a 6333&#xff09;<\/li>\n<li>\u68c0\u67e5\u9632\u706b\u5899\u8bbe\u7f6e<\/li>\n<li>\u786e\u4fdd Docker \u5bb9\u5668\u6b63\u5728\u8fd0\u884c<\/li>\n<\/ul>\n<h3 id=\"\u7ec4\u5408\u7cfb\u7edf\u7684\u597d\u5904\">\u7ec4\u5408\u7cfb\u7edf\u7684\u597d\u5904<\/h3>\n<p>Scrapeless \u4e0e Qdrant \u7684\u96c6\u6210\u521b\u5efa\u4e86\u4e00\u4e2a\u5f3a\u5927\u7684\u6df7\u5408\u7cfb\u7edf&#xff1a;<\/p>\n<li>\u9759\u6001 &#043; \u52a8\u6001\u77e5\u8bc6&#xff1a;\u5c06\u60a8\u7684\u7b56\u5212\u77e5\u8bc6\u5e93\u4e0e\u5b9e\u65f6\u7f51\u7edc\u6570\u636e\u76f8\u7ed3\u5408<\/li>\n<li>\u667a\u80fd\u641c\u7d22&#xff1a;\u5bf9\u5185\u90e8\u6570\u636e\u4f7f\u7528\u8bed\u4e49\u641c\u7d22&#xff0c;\u5bf9\u7f51\u7edc\u5185\u5bb9\u4f7f\u7528\u5173\u952e\u5b57\u641c\u7d22<\/li>\n<li>\u6301\u7eed\u589e\u5f3a&#xff1a;\u81ea\u52a8\u66f4\u65b0\u60a8\u7684\u77e5\u8bc6\u5e93&#xff0c;\u63d0\u4f9b\u65b0\u4fe1\u606f<\/li>\n<li>\u5168\u7403\u89c6\u89d2&#xff1a;\u83b7\u53d6\u6765\u81ea\u4e0d\u540c\u5730\u533a\u548c\u8bed\u8a00\u7684\u4fe1\u606f<\/li>\n<li>\u53ef\u9760\u6027&#xff1a;Scrapeless \u786e\u4fdd\u7a33\u5b9a\u7684\u7f51\u7edc\u8bbf\u95ee\u800c\u65e0\u963b\u585e\u95ee\u9898<\/li>\n<h3 id=\"\u7ed3\u8bba\">\u7ed3\u8bba<\/h3>\n<p>MCP-RAG \u670d\u52a1\u5668\u4e0e Scrapeless \u5b9e\u73b0\u4e86\u4e00\u4e2a\u9ad8\u5ea6\u53ef\u6269\u5c55\u3001\u5b9e\u65f6\u66f4\u65b0\u7684\u667a\u80fd\u95ee\u7b54\u7cfb\u7edf\u3002\u5176\u6838\u5fc3\u4ef7\u503c\u5305\u62ec&#xff1a;<\/p>\n<ul>\n<li>\u8bed\u4e49\u7406\u89e3&#xff1a;\u901a\u8fc7\u5411\u91cf\u76f8\u4f3c\u5ea6\u7406\u89e3\u4e0a\u4e0b\u6587<\/li>\n<li>\u5b9e\u65f6\u4fe1\u606f\u8bbf\u95ee&#xff1a;\u8bbf\u95ee Scrapeless \u83b7\u53d6\u6700\u65b0 web \u5185\u5bb9<\/li>\n<li>\u6807\u51c6\u534f\u8bae\u96c6\u6210&#xff1a;\u4f7f\u7528 MCP \u534f\u8bae&#xff0c;\u8f7b\u677e\u8fde\u63a5\u5230 Claude \u7b49\u5e73\u53f0<\/li>\n<li>\u7075\u6d3b\u914d\u7f6e&#xff1a;\u53ef\u5b9a\u5236\u7684\u77e5\u8bc6\u5e93\u96c6\u5408\u548c\u641c\u7d22\u5de5\u5177<\/li>\n<li>\u9762\u5411\u672a\u6765\u7684\u667a\u80fd\u5e73\u53f0&#xff1a;\u652f\u6301\u52a8\u6001\u77e5\u8bc6\u589e\u5f3a\u3001\u591a\u8bed\u8a00\u652f\u6301\u548c\u7f51\u7edc\u667a\u80fd\u722c\u53d6\u3002<\/li>\n<\/ul>\n<p>Scrapeless\u7684\u52a0\u5165\u4f7f\u7cfb\u7edf\u4e0d\u518d\u4ec5\u4ec5\u662f\u4e00\u4e2a\u9759\u6001\u7684\u77e5\u8bc6\u5e93&#xff0c;\u800c\u662f\u4e00\u4e2a\u5177\u6709\u5168\u7403\u89c6\u91ce\u548c\u6301\u7eed\u5b66\u4e60\u80fd\u529b\u7684AI\u77e5\u8bc6\u5f15\u64ce\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb912\u6b21\uff0c\u70b9\u8d5e9\u6b21\uff0c\u6536\u85cf11\u6b21\u3002MCP-RAG Server\u662f\u4e00\u4e2a\u57fa\u4e8eTypeScript\u7684\u7cfb\u7edf\uff0c\u7ed3\u5408\u4e86\u5411\u91cf\u641c\u7d22\u80fd\u529b\u548c\u5b9e\u65f6\u7f51\u7edc\u641c\u7d22\uff0c\u4ee5\u521b\u5efa\u589e\u5f3a\u7684\u4eba\u5de5\u667a\u80fd\u77e5\u8bc6\u7cfb\u7edf\u3002\u673a\u5668\u5b66\u4e60\u5e38\u89c1\u95ee\u9898\u68c0\u7d22 &#8211; \u901a\u8fc7\u60a8\u7684\u5411\u91cf\u6570\u636e\u5e93\u8fdb\u884c\u8bed\u4e49\u641c\u7d22\u6587\u6863\u6dfb\u52a0 &#8211; \u4f7f\u7528\u65b0\u4fe1\u606f\u6269\u5c55\u77e5\u8bc6\u5e93\u7f51\u7edc\u641c\u7d22 &#8211; \u4ece\u4e92\u8054\u7f51\u4e0a\u83b7\u53d6\u5f53\u524d\u4fe1\u606f\u8be5\u7cfb\u7edf\u89e3\u51b3\u4e86\u5173\u952e\u7684AI\u5c40\u9650\u6027\uff1a\u8fc7\u65f6\u7684\u77e5\u8bc6\u3001\u7f3a\u4e4f\u9886\u57df\u4e13\u957f\u548c\u4f4e\u6548\u7684\u4fe1\u606f\u68c0\u7d22\u3002Scrapeless Google\u641c\u7d22\u6293\u53d6API\u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u7f51\u9875\u6293\u53d6API\uff0c\u63d0\u4f9b\u7a33\u5b9a\u7684\u641c\u7d22\u5f15\u64ce\u7ed3\u679c\u8bbf\u95ee\uff0c\u800c\u65e0\u9700\u62c5\u5fc3\u88ab\u4f20\u7edf\u722c\u866b\u963b\u585e\u3002<\/p>\n","protected":false},"author":2,"featured_media":37698,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[43,44],"topic":[],"class_list":["post-37699","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-43","tag-44"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\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\/37699.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb912\u6b21\uff0c\u70b9\u8d5e9\u6b21\uff0c\u6536\u85cf11\u6b21\u3002MCP-RAG Server\u662f\u4e00\u4e2a\u57fa\u4e8eTypeScript\u7684\u7cfb\u7edf\uff0c\u7ed3\u5408\u4e86\u5411\u91cf\u641c\u7d22\u80fd\u529b\u548c\u5b9e\u65f6\u7f51\u7edc\u641c\u7d22\uff0c\u4ee5\u521b\u5efa\u589e\u5f3a\u7684\u4eba\u5de5\u667a\u80fd\u77e5\u8bc6\u7cfb\u7edf\u3002\u673a\u5668\u5b66\u4e60\u5e38\u89c1\u95ee\u9898\u68c0\u7d22 - \u901a\u8fc7\u60a8\u7684\u5411\u91cf\u6570\u636e\u5e93\u8fdb\u884c\u8bed\u4e49\u641c\u7d22\u6587\u6863\u6dfb\u52a0 - \u4f7f\u7528\u65b0\u4fe1\u606f\u6269\u5c55\u77e5\u8bc6\u5e93\u7f51\u7edc\u641c\u7d22 - \u4ece\u4e92\u8054\u7f51\u4e0a\u83b7\u53d6\u5f53\u524d\u4fe1\u606f\u8be5\u7cfb\u7edf\u89e3\u51b3\u4e86\u5173\u952e\u7684AI\u5c40\u9650\u6027\uff1a\u8fc7\u65f6\u7684\u77e5\u8bc6\u3001\u7f3a\u4e4f\u9886\u57df\u4e13\u957f\u548c\u4f4e\u6548\u7684\u4fe1\u606f\u68c0\u7d22\u3002Scrapeless Google\u641c\u7d22\u6293\u53d6API\u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u7f51\u9875\u6293\u53d6API\uff0c\u63d0\u4f9b\u7a33\u5b9a\u7684\u641c\u7d22\u5f15\u64ce\u7ed3\u679c\u8bbf\u95ee\uff0c\u800c\u65e0\u9700\u62c5\u5fc3\u88ab\u4f20\u7edf\u722c\u866b\u963b\u585e\u3002\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/37699.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2025-05-16T18:25:55+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250516182552-6827833094441.png\" \/>\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=\"4 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/37699.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/37699.html\",\"name\":\"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2025-05-16T18:25:55+00:00\",\"dateModified\":\"2025-05-16T18:25:55+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/37699.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/37699.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/37699.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\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":"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\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\/37699.html","og_locale":"zh_CN","og_type":"article","og_title":"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb912\u6b21\uff0c\u70b9\u8d5e9\u6b21\uff0c\u6536\u85cf11\u6b21\u3002MCP-RAG Server\u662f\u4e00\u4e2a\u57fa\u4e8eTypeScript\u7684\u7cfb\u7edf\uff0c\u7ed3\u5408\u4e86\u5411\u91cf\u641c\u7d22\u80fd\u529b\u548c\u5b9e\u65f6\u7f51\u7edc\u641c\u7d22\uff0c\u4ee5\u521b\u5efa\u589e\u5f3a\u7684\u4eba\u5de5\u667a\u80fd\u77e5\u8bc6\u7cfb\u7edf\u3002\u673a\u5668\u5b66\u4e60\u5e38\u89c1\u95ee\u9898\u68c0\u7d22 - \u901a\u8fc7\u60a8\u7684\u5411\u91cf\u6570\u636e\u5e93\u8fdb\u884c\u8bed\u4e49\u641c\u7d22\u6587\u6863\u6dfb\u52a0 - \u4f7f\u7528\u65b0\u4fe1\u606f\u6269\u5c55\u77e5\u8bc6\u5e93\u7f51\u7edc\u641c\u7d22 - \u4ece\u4e92\u8054\u7f51\u4e0a\u83b7\u53d6\u5f53\u524d\u4fe1\u606f\u8be5\u7cfb\u7edf\u89e3\u51b3\u4e86\u5173\u952e\u7684AI\u5c40\u9650\u6027\uff1a\u8fc7\u65f6\u7684\u77e5\u8bc6\u3001\u7f3a\u4e4f\u9886\u57df\u4e13\u957f\u548c\u4f4e\u6548\u7684\u4fe1\u606f\u68c0\u7d22\u3002Scrapeless Google\u641c\u7d22\u6293\u53d6API\u662f\u4e00\u4e2a\u5f3a\u5927\u7684\u7f51\u9875\u6293\u53d6API\uff0c\u63d0\u4f9b\u7a33\u5b9a\u7684\u641c\u7d22\u5f15\u64ce\u7ed3\u679c\u8bbf\u95ee\uff0c\u800c\u65e0\u9700\u62c5\u5fc3\u88ab\u4f20\u7edf\u722c\u866b\u963b\u585e\u3002","og_url":"https:\/\/www.wsisp.com\/helps\/37699.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2025-05-16T18:25:55+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250516182552-6827833094441.png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"4 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/37699.html","url":"https:\/\/www.wsisp.com\/helps\/37699.html","name":"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\u6307\u5357 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2025-05-16T18:25:55+00:00","dateModified":"2025-05-16T18:25:55+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/37699.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/37699.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/37699.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"MCP-RAG \u670d\u52a1\u5668\uff1a\u5b8c\u6574\u8bbe\u7f6e\u548c\u4f7f\u7528\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\/37699","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=37699"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/37699\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/37698"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=37699"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=37699"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=37699"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=37699"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}