focus_mcp_sql
FOCUS DATA MCP サーバー [中文]
モデル コンテキスト プロトコル (MCP) サーバーにより、人工知能アシスタントは自然言語を SQL ステートメントに変換できます。
Text-to-SQLフレームワークはすでに数多く存在します。なぜさらにもう1つ必要なのでしょうか?
簡単に言えば、focus_mcp_sql は 2 段階の SQL 生成ソリューションを採用しており、これにより LLM の幻覚を制御し、生成された SQL 結果に対する非技術者ユーザーの信頼を真に構築できます。
以下は focus_mcp_sql とその他の比較表です。
比較分析表
以下は focus_mcp_sql と他の LLM ベースのフレームワークとの比較です。
特徴 | 従来のLLMフレームワーク | focus_mcp_sql |
生成プロセス | ブラックボックス、直接SQL生成 | 透過的な2段階(キーワード + SQL) |
幻覚リスク | 高い(モデルの品質により異なる) | 低い、制御可能(キーワード検証) |
スピード | 遅く、大規模なモデル推論に依存 | 高速で決定論的なキーワードからSQLへの変換 |
料金 | 高、高度なモデルが必要 | 低い、大規模モデルへの依存を減らす |
非技術的なユーザーフレンドリーさ | 結果が低く、検証が難しい | 高度で簡単なキーワードチェック |
特徴
- モデルを初期化する - 自然言語をSQL文に変換する
Related MCP server: database-explorer-mcp
前提条件
jdk 23以上。jdkをダウンロード
gradle 8.12以降。gradleをダウンロード
ベアラートークンを取得するには、 Datafocusを登録します。
Datafocusにアカウントを登録する
アプリケーションを作成する
アプリケーションを入力してください
管理 -> インターフェース認証 -> ベアラートークン -> 新しいベアラートークン

インストール
このリポジトリをクローンします:
git clone https://github.com/FocusSearch/focus_mcp_sql.git
cd focus_mcp_sqlサーバーを構築します。
gradle clean
gradle bootJar
The jar path: build/libs/focus_mcp_sql.jarMCP構成
サーバーを MCP 設定ファイルに追加します。
{
"mcpServers": {
"focus_mcp_data": {
"command": "java",
"args": [
"-jar",
"path/to/focus_mcp_sql/focus_mcp_sql.jar"
],
"autoApprove": [
"gptText2sqlStart",
"gptText2sqlChat"
]
}
}
}利用可能なツール
1. gptText2sqlStart
初期モデル。
パラメータ:
model(必須): テーブルモデルbearer(必須):ベアラートークンlanguage(オプション):言語 ['english','chinese']
例:
{
"model": {
"tables": [
{
"columns": [
{
"columnDisplayName": "name",
"dataType": "string",
"aggregation": "",
"columnName": "name"
},
{
"columnDisplayName": "address",
"dataType": "string",
"aggregation": "",
"columnName": "address"
},
{
"columnDisplayName": "age",
"dataType": "int",
"aggregation": "SUM",
"columnName": "age"
},
{
"columnDisplayName": "date",
"dataType": "timestamp",
"aggregation": "",
"columnName": "date"
}
],
"tableDisplayName": "test",
"tableName": "test"
}
],
"relations": [
],
"type": "mysql",
"version": "8.0"
},
"bearer": "ZTllYzAzZjM2YzA3NDA0ZGE3ZjguNDJhNDjNGU4NzkyYjY1OTY0YzUxYWU5NmU="
}モデルパラメータの説明:
名称 | 位置 | 種類 | 必ず選択 | 説明 |
モデル | 体 | 物体 | 是 | なし |
" タイプ | 体 | 弦 | 是 | データストアタイプ |
» バージョン | 体 | 弦 | 是 | データバンク版 |
» テーブル | 体 | [物体] | 是 | テーブル構造リスト |
»» テーブル表示名 | 体 | 弦 | 否 | 表の表示名 |
»» テーブル名 | 体 | 弦 | 否 | 表元の開始名 |
»» 列 | 体 | [物体] | 否 | 表一覧表 |
»»» 列表示名 | 体 | 弦 | 是 | 列表示名 |
»»» 列名 | 体 | 弦 | 是 | 列原始名 |
»»» データ型 | 体 | 弦 | 是 | 列データタイプ |
»»» 集約 | 体 | 弦 | 是 | 列結合方式 |
» 関係 | 体 | [物体] | 是 | 表とシリーズ一覧 |
»» 条件 | 体 | [物体] | 否 | 結合条件 |
»»» dstColName | 体 | 弦 | 否 | 寸法表关联列原始名 |
»»» ソース列名 | 体 | 弦 | 否 | 事実 表の関連原文 |
»» ディメンションテーブル | 体 | 弦 | 否 | ディメンション表元名 |
»» ファクトテーブル | 体 | 弦 | 否 | 事実 表原名 |
»» 結合タイプ | 体 | 弦 | 否 | 結合されたタイプ |
2. gptText2sqlチャット
自然言語を SQL に変換します。
パラメータ:
chatId(必須): チャットIDinput(必須): 自然言語bearer(必須):ベアラートークン
例:
{
"chatId": "03975af5de4b4562938a985403f206d4",
"input": "what is the max age",
"bearer": "ZTllYzAzZjM2YzA3NDA0ZGE3ZjguNDJhNDjNGU4NzkyYjY1OTY0YzUxYWU5NmU="
}応答フォーマット
すべてのツールは次の形式で応答を返します。
{
"errCode": 0,
"exception": "",
"msgParams": null,
"promptMsg": null,
"success": true,
"data": {
}
}Visual Studio Code Cline サンプル
vsCode で cline プラグインをインストールする
mcp サーバー構成

使用
初期モデル


譲渡:最大年齢は何歳ですか

接触:
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Ask data questions in natural language. Get SQL, insights, and charts from your databases.
Ask business questions in plain English. Get instant answers from your database, no SQL needed.
Query BigQuery, Snowflake, Redshift & Azure Synapse with natural language
Your Databricks Lakehouse in natural language: run SQL on your SQL warehouses, track long-running qu
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI agents to interact with a MySQL database using natural language, automating SQL tasks like querying, inserting, updating, and deleting data.1
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to connect to and interact with PostgreSQL, MySQL, SQLite, and MongoDB databases through natural language, supporting schema exploration, query execution, data export, and more.MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to directly query MySQL databases, list tables, and view table structures through natural language.33MIT
- AlicenseNot gradedqualityDmaintenanceEnables natural language querying of SQL databases using AI, supporting multiple database types and automatic schema discovery.1MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/FocusSearch/focus_mcp_sql'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
