Skip to main content

Add your description here

Project description

SQL Schema MCP 服务器 一个用于查询需求分析对应的SQL table scheme信息的模型上下文协议服务器。该服务器包装了原始的get_schema_info API,让AI应用能够通过MCP协议获取SQL表结构信息。

主要功能

根据用户查询需求,分析需要用到的数据表、字段、枚举值、关联方式和易错点等信息。

可用工具

analyze_sql_schema - 分析SQL表结构和数据需求

必需参数:

  • user (字符串): 用户信息,用于身份识别和权限控制
  • business_id (字符串): 业务ID,标识具体的业务场景
  • query (字符串): 用户的数据需求描述,例如"我需要查询最近一个月的用户活跃度数据"
  • appkey (字符串): API密钥,用于接口认证

可选参数:

  • document_id (字符串): 可选的文档ID,关联特定的文档上下文
  • extra_result_params (列表): 额外的结果参数,用于定制返回结果

使用示例

  • "查询用户最近30天的购买行为数据"
  • "分析不同地区的销售业绩情况"
  • "获取商品库存和销量的关联分析"

安装

使用 PIP

你可以通过 pip 安装 fit-growth-mcp-tools:

pip install fit-growth-mcp-tools

安装完成后,可以使用以下命令作为脚本运行:

python -m fit_growth_mcp_tools

配置

为 Claude.app 配置

在你的 Claude 设置中添加:

{
  "mcpServers": {
    "sql-schema": {
      "command": "python",
      "args": ["-m", "fit_growth_mcp_tools"]
    }
  }
}

为 Zed 配置

在你的 Zed settings.json 中添加:

{
  "assistant": {
    "version": "2",
    "provider": {
      "name": "anthropic",
      "default_model": "claude-3-5-sonnet-20241022",
      "low_speed_timeout_read_timeout": 30,
      "low_speed_timeout": 30
    }
  },
  "context_servers": [
    {
      "id": "sql-schema",
      "type": "mcp",
      "settings": {
        "command": "python",
        "args": ["-m", "fit_growth_mcp_tools"]
      }
    }
  ]
}

API 配置

服务器连接到内部API服务,需要确保:

注意事项

  • 确保提供有效的appkey进行身份认证
  • query描述应该明确具体,便于准确分析
  • 网络连接需要能访问内部API服务
  • 服务会自动处理网络连接失败、API认证失败等错误情况

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fit_growth_mcp_tools-0.1.2.tar.gz (2.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fit_growth_mcp_tools-0.1.2-py3-none-any.whl (3.2 kB view details)

Uploaded Python 3

File details

Details for the file fit_growth_mcp_tools-0.1.2.tar.gz.

File metadata

File hashes

Hashes for fit_growth_mcp_tools-0.1.2.tar.gz
Algorithm Hash digest
SHA256 3182b0982dd94aa2cbe8d9b21eab9ba6a04911432e10d4d1334d2d0e880dbfb7
MD5 e568572f2d123b4c8247b5f1c3c0809e
BLAKE2b-256 44ffe79e902c0d13e21b8900336f4e00210c6065f9d46ece50ec57e368b85d00

See more details on using hashes here.

File details

Details for the file fit_growth_mcp_tools-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for fit_growth_mcp_tools-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9bc40ae6fd02456e4874d3933867bb16218388157604553c912109c1c6a94942
MD5 76ea19cd2b86fe59fdcf8c8ba96faab4
BLAKE2b-256 aeddee7d1f70e4e115d7c4114d9ec023c35d62ed4f567d83e4f224fc6cd0bdf5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page