自然语言查询服务

一个允许用户通过自然语言查询数据的自定义MCP服务器,适用于数据分析和开发测试场景。

  • by jefmono
  • TypeScript
  • 本地部署
  • 更新于
在 GitHub 查看 jfzhou5/wrenai-mcp-server

使用说明

为wrenai定制MCP服务器

开始

yarn

yarn build

# if you want to test the mcp server
SERVER_PORT=3002 npx @modelcontextprotocol/inspector node dist/index.js -e APP_KEY=MID-E53wKKWTqNzK7ccC -e ENDPOINT=http://localhost:3000

环境

# APP_ID of matchid developer
APP_KEY=MID-E53wKKWTqNzK7ccC
# ENDPOINT of matchid wrenai server
ENDPOINT=

工具

query

创建NL查询 内容数组:

{
    "answerDatail": "The table \"binance_account_balances\" contains a total of 10 rows.",
    "previewData": {
        "correlationId": "afdbbce1-af51-4b74-ac2b-a7001db17bf8",
        "columns": [
            {
                "name": "count()",
                "type": "uint64"
            }
        ],
        "data": [
            [
                10
            ]
        ]
    }
}

这 threadResponse.answerDetail.content 这就是答案。还有 previewData.data 就是数据。