
Metabase Ai Assistant
io.github.enessari由 GitHub 帳號 enessari 發布v3.2.0更新於 Oct 24, 2026
MCP Server for Metabase - 111 tools for SQL generation, dashboards & PostgreSQL
概覽
把 AI 助理連接到 Metabase BI 執行個體,用於 SQL、儀表板、卡片、集合以及 dbt 語意層相關工作。
- 可以做什麼
- 提供大量工具(README 聲稱有 143 至 152 個),涵蓋 SQL 與查詢執行、自然語言轉 SQL、卡片與視覺化設定、儀表板建立與版面配置、集合整理、結構描述與資料建模、使用者與權限管理,以及警示、訂閱與動作。也包含 dbt 與語意層功能,例如模型檢查、血緣連結、預聚合建議、YAML 轉儀表板,以及具備提出、核准、棄用與還原步驟的治理式語意記憶。自癒 SQL 迴圈會重試失敗的查詢,PII 遮罩會處理電子郵件、電話、證件號、信用卡、IP 與權杖。
- 適用情境
- 當助理需要在既有 Metabase 部署中工作時適用:瀏覽結構描述、撰寫並執行 SQL、建立或修改問題與儀表板、整理集合,或管理使用者與權限。也適合維護 dbt 或 MetricFlow 語意模型、希望助理讀取它們並產生儀表板或 YAML 的團隊。
- 執行需求
- 以 stdio 方式在本機執行,通常透過 npx 或全域 npm 安裝,因此需要 Node.js。需要 METABASE_URL,以及 METABASE_API_KEY 或 METABASE_USERNAME 搭配 METABASE_PASSWORD。直接執行 PostgreSQL SQL 需要 DATABASE_HOST、DATABASE_NAME、DATABASE_PORT、DATABASE_USER 和 DATABASE_PASSWORD。需要能連線到 Metabase 執行個體的網路。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Metabase Ai Assistant,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Metabase AI Assistant — Model Context Protocol (MCP) Server
[npm version] [License] [Node.js] [MCP SDK]
Metabase AI Assistant is an enterprise-grade Model Context Protocol (MCP) server that connects Large Language Models (LLMs), AI coding assistants, and automated data workflows directly to your Metabase Business Intelligence instance.
Featuring 152 dedicated tools, native dbt Metadata & Metrics Auto-Syncer, Metabase to dbt Reverse Lineage Exposures, dbt-Smart Question Creator, Lightdash Code-as-BI YAML-to-Dashboard generation, Cube.js-style Pre-aggregations & Multi-Hop Lineage Joins, Omni.co Controlled Semantic-to-YAML bridge, autonomous self-healing SQL execution, full-scale dashboard architecting, proactive anomaly detection, query index advisory, zero-leak PII masking, and strict security guardrails. Works seamlessly with Claude, Cursor, ChatGPT, Gemini, and Google Antigravity.
🌍 Language Versions / Dil Seçenekleri / 语言版本 / النسخ اللغوية
- 🇬🇧 English (Main Documentation)
- 🇹🇷 Türkçe Dokümantasyon
- 🇨🇳 中文文档 (Chinese)
- 🇸🇦 التوثيق باللغة العربية (Arabic)
Table of Contents
- Core Architectural Highlights
- Next-Gen Autonomous Features (v5.3)
- Metabase Version Compatibility
- Quick Start & Installation
- Client Configuration & Desktop Setup
- Tool Categories Overview (152 Tools)
- Testing & Quality Assurance
- Project Roadmap & Upcoming Features
- License
Core Architectural Highlights
Metabase AI Assistant transforms standard AI interfaces (Claude Desktop, Cursor, VS Code, ChatGPT, Gemini, automated agent frameworks) into full-fledged Metabase power users:
- dbt Deep Scanning & MetricFlow Integration (
dbt_project_scan_deep): 9-tier architectural classification,doc('...')resolution, andcatalog.jsontable/column profiling. - Cube.js Multi-Hop Lineage Joins (
dbt_lineage_joins_graph): Resolves shortest join paths via Dijkstra Min-Heap algorithms with 3-color DAG cycle detection. - Cube.js Pre-Aggregation & Rollup Advisor (
dbt_semantic_preagg_advisor): Generates multi-dialect Materialized View DDLs (Postgres, BigQuery, Snowflake, ClickHouse, DuckDB, Redshift, MySQL) with HyperLogLog distinct counts. - Lightdash Code-as-BI Dashboard Builder (
dbt_build_dashboard_from_yaml): Translatesmeta.metabaseandmeta.lightdashformatting options into collision-free 24-column Metabase Dashboards. - Omni.co Controlled Semantic-to-YAML Exporter (
dbt_semantic_export_yaml): Serializes approved business rules into clean dbtschema.yml/semantic_models.ymlcode blocks. - Autonomous Self-Healing SQL Engine (
ai_sql_execute_and_heal): 3-iteration automated error-recovery loop for resilient querying. - Zero-Leak Enterprise PII Masker: Real-time sanitization of emails, phone numbers, national IDs, credit cards, IP addresses, and tokens.
Next-Gen Autonomous Features (v5.1)
1. dbt Architectural Hierarchy & Source Prioritization
$$\mathbf{Gold;Marts;(fct_,;dim_,;rpt_)} ;\gg; \mathbf{Silver;(int_)} ;\gg; \mathbf{Bronze;Staging;(stg_)}$$
dbt_inspect_models: Parses dbtmanifest.jsonand MetricFlow semantic models.dbt_prioritize_sources: Dynamically routes natural language questions to pre-aggregated, tested dimensional and fact tables.
2. Governance-First Semantic Memory (No Silent Learning, No Hard-Deletes)
semantic_memory_propose: Proposes a business rule inPENDING_APPROVALstatus.semantic_memory_approve: Explicitly activates the rule with required data steward comments.semantic_memory_deprecate: Safely soft-archives rules with mandatory audit reasons (DEPRECATED).semantic_memory_restore: Instantly restores archived rules.semantic_memory_list: Lists all rules with complete audit history and timestamps.
3. Autonomous Self-Healing SQL Engine (ai_sql_execute_and_heal)
- Catches syntax errors, Levenshtein-distance column misspellings, missing
GROUP BYclauses, and dialect quirks across Postgres, MySQL, BigQuery, Snowflake, and SQLite. - Preserves fix history in
_provenance.healing_trail.
Metabase Version Compatibility
Metabase AI Assistant provides backward and forward compatibility across all major Metabase architectures:
Quick Start & Installation
Global Execution via NPX
Manual Installation via NPM
Client Configuration & Desktop Setup
1. Claude Desktop
Option A: One-Click Extension (DXT / MCPB)
- Open Claude Desktop Settings -> Developer / Extensions -> Install Local Extension.
- Select this repository folder.
- Or install via Smithery CLI:
Option B: Manual JSON Configuration
Add the server definition to claude_desktop_config.json:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
2. Cursor IDE, Windsurf & VS Code
Add to .cursor/mcp.json or VS Code MCP settings:
3. ChatGPT Custom GPTs & Actions
Expose Metabase AI Assistant as an OpenAPI Action for ChatGPT Plus / Team / Enterprise:
- Start the Remote SSE/HTTP server:
npm run start:sse - In ChatGPT, create a Custom GPT -> Actions -> Import from URL:
https://your-domain.com/tools/openapi.json - Detailed setup guide: docs/integrations/CHATGPT_ACTIONS_GUIDE.md
4. Google Gemini & Google AI Studio
Pass tool definitions to Gemini Function Calling SDKs (@google/genai or google-generativeai):
- Detailed setup guide: docs/integrations/GOOGLE_GEMINI_GUIDE.md
5. Cloudflare Workers (Serverless Edge)
Deploy directly to Cloudflare's edge network for free:
Tool Categories Overview (143 Tools)
The 143 MCP tools are categorized into 10 operational domains:
- dbt & Semantic Layer (6 tools): Model hierarchy inspection, lineage resolution, source prioritization, governance-first business memory (propose, approve, soft-deprecate, restore).
- Autonomous AI BI Operations (4 tools): Self-healing SQL engine, end-to-end dashboard architect, query index advisor, proactive anomaly detector.
- SQL & Query Execution (14 tools): Direct SQL queries, async execution jobs, query status tracking, pagination, and speed benchmarks.
- AI Query Intelligence (6 tools): Natural language to SQL, query performance optimizer, query explainer, automated table description.
- Cards & Visualizations (34 tools): Question creation, query execution, parametric filtering, card cloning, visualization settings.
- Dashboards & Layouts (22 tools): Dashboard creation, grid placement, filter linking, tab management, executive templates.
- Collections & Organization (8 tools): Collection tree traversal, hierarchical moves, permission graphs, item listing.
- Schema & Data Modeling (18 tools): Schema retrieval, foreign key inference, data profiling, table definitions.
- User & Permission Administration (12 tools): User invitations, group assignments, membership controls, status toggling.
- Actions & Documentation (19 tools): Metabase actions execution, pulses, alerts, webhooks, metrics, segment definitions, workspace migration.
Testing & Quality Assurance
Backed by an automated multi-tier test suite covering unit logic, integration workflows, and security fuzzing:
License
Licensed under the Apache License 2.0. See the LICENSE file for details.
Developed and maintained by Abdullah Enes SARI (ONMARTECH LLC).
來源:README.md,提交 009ae02
工具
0版本歷史
1- v3.2.0最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分