Matih

ai.matih由 matih.ai 發布官方發布者v0.2.1更新於 Oct 24, 2026

The grounded data layer for any LLM: governed SQL, metrics, lineage and catalog over your data.

已驗證Streamable HTTP可網頁執行資料庫知識與記憶資料與分析

概覽

AI 產生的概覽

將 AI 助理連接到 Matih 資料平台,以執行受治理的 SQL、指標、目錄與血緣查詢,並建立儀表板。

可以做什麼
透過 MCP 暴露 Matih 資料平台,提供 34 個穩定工具與一個 Beta 工具。查詢與 SQL 工具包括 ask(自然語言轉為有依據的答案並附上所執行的 SQL)、run_sql、run_analysis、get_query_result 與 export_result。目錄工具可列出連線、資料庫、結構描述與資料表,並描述或剖析資料表;語意層工具可檢索本體、實體、關聯、語意模型、詞彙表與關聯圖。受治理的指標與分類工具可讀取與起草指標,儀表板工具可建立圖表與儀表板,上傳工具則處理檔案。此外還提供目錄與血緣資源以及 explain_metric 提示。
適用情境
當助理需要針對 Matih 工作區作業時適用:以受治理的 SQL 回答資料問題、探索資料表與血緣、讀取或起草指標,或產出圖表與儀表板。它面向已將 Matih 作為資料層的團隊,而非一般用途的資料庫存取。
執行需求
需要形如 https:// .app.matih.ai/api/v1/mcp 的 Matih 工作區端點,以及透過 MATIH_MCP_TOKEN 環境變數提供的 Matih 開發者權杖(mat_agt_…)。本機 stdio 橋接透過 npx 執行,需要 Node.js 20 或更新版本。也可用帶 PKCE 的 OAuth 取代靜態權杖。租戶必須已接受資料處理協議,才能將資料傳出給第三方 LLM。
安裝前請注意
必須提供 MATIH_MCP_TOKEN 持有者憑證,且應透過環境變數而非命令列參數傳遞。部分工具會寫入:draft_metric 會將指標定義草稿提交到需人工審核的流程,create_chart、create_dashboard、publish_dashboard 與上傳工具會變更工作區中的資料。每個工具都受權杖範圍限制,應只授予所需的連線與能力。將資料傳出給第三方 LLM 依租戶管控,在協議被接受前會傳回 EGESS_CONSENT_REQUIRED。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Matih,將其新增到工作區。
  2. 連接 所需的 憑證。它們會被私密儲存,絕不會在公開頁面上展示。
  3. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/ai.matih%2Fmcp/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。 客戶端會在首次連接時完成 OAuth 登入。

{
  "mcpServers": {
    "matih": {
      "type": "http",
      "url": "https://mcp.matih.ai/api/v1/mcp"
    }
  }
}

README

@matihlabs/mcp

Connect AI clients (Claude Desktop, ChatGPT, Cursor, …) to the Matih data platform over the Model Context Protocol. Write SQL, profile tables, run analyses + charts, manage dashboards, and upload files — all through MCP tools, with OAuth/PKCE auth and PII-safe egress.

New here? See QUICKSTART.md for a step-by-step customer guide — create a token, connect Claude Desktop / Cursor, and copy-paste curl smoke tests — plus a troubleshooting table.

Use as a stdio MCP server (Claude Desktop / Cursor)

Add to your client's MCP config. The token is delivered via the environment — never as a CLI flag (which leaks into the OS process list):

json
{  "mcpServers": {    "matih": {      "command": "npx",      "args": ["-y", "@matihlabs/mcp", "https://<slug>.app.matih.ai/api/v1/mcp"],      "env": { "MATIH_MCP_TOKEN": "<your Matih bearer token>" }    }  }}

The bridge turns the remote Matih HTTP MCP endpoint into a local stdio MCP server, forwarding every tools/call, resources/read, and prompts/get to Matih.

Endpoint: replace <slug> with your workspace slug — your Matih app lives at https://<slug>.app.matih.ai (the bare app.matih.ai host does not resolve). Get a mat_agt_… token from Settings → Developer Tokens. See QUICKSTART.md for the full walkthrough.

Use as a library

ts
import { McpClient, MatihTools, StaticTokenProvider } from "@matihlabs/mcp";
const client = new McpClient({  endpoint: "https://<slug>.app.matih.ai/api/v1/mcp",  tokenProvider: new StaticTokenProvider(process.env.MATIH_MCP_TOKEN!),});
// discovery-first: fetch the LIVE tool surface (auto-initializes + caches)const live = await client.tools();console.log(live.map((t) => t.name));
// call ANY tool generically — including Beta tools with no typed wrapperconst hot = await client.callTool("get_hot_context", {});
// typed convenience wrappers for the 34 STABLE toolsconst graph = await new MatihTools(client).exploreGraph({ query: "orders", depth: 2 });const matih = new MatihTools(client);const result = await matih.runSql({ connection_id: "<id>", sql: "select 1" });

OAuth (PKCE) instead of a static token

ts
import { McpClient, OAuthTokenProvider } from "@matihlabs/mcp";
const tokenProvider = new OAuthTokenProvider({  resourceMetadataUrl: "https://<slug>.app.matih.ai/.well-known/oauth-protected-resource/api/v1/mcp",  clientId: "<registered client id>",  acquire: async ({ metadata, clientId, resource }) => {    // open metadata.authorization_endpoint (PKCE S256, resource=<resource>),    // capture the code at your redirect_uri, return { code, verifier, redirectUri }.  },});

The provider runs RFC 9728 → RFC 8414 discovery, PKCE S256, RFC 8707 resource-bound tokens, caches, and refreshes; a 401 invalid_token triggers one re-auth.

Tools

Discovery is the primary API — await client.tools() returns the live tool descriptors and client.callTool(name, args) reaches every advertised tool. The typed facade (MatihTools) covers the 34 stable tools (STABLE_TOOL_NAMES):

  • Query & SQL: ask (natural-language → grounded answer + the SQL it ran), run_sql, run_analysis, get_query_result, export_result
  • Catalog & discovery: list_connections, list_databases, list_schemas, list_tables, describe_table, profile_table
  • Ontology & semantic layer: search_ontology, get_entity, get_relationships, get_semantic_model, get_glossary, explore_graph
  • Governed metrics & taxonomy: get_metric, run_metric, draft_metric (write-class — proposes a DRAFT metric_def into the human-gated DRAFT → REVIEW → APPROVED → SHIP pipeline), list_metric_drafts, export_semantic_model (OSI), get_taxonomy, export_taxonomy (SKOS)
  • Dashboards & charts: create_chart, create_dashboard, get_dashboard, publish_dashboard
  • Uploads: upload_file, upload_status, create_upload_url, finalize_upload
  • Identity & scope: whoami, get_scope

The 1 Beta tool (BETA_TOOL_NAMES: get_hot_context) is deliberately not hard-typed while its shape may evolve — call it via client.callTool(name, args). The governed metrics & taxonomy group and explore_graph were promoted from Beta to stable in July 2026 (PDR W3-1).

Plus catalog / lineage resources and the explain_metric prompt. Every tool is bounded by the developer token's scope (connections + capabilities you grant in Settings) and never exceeds your own permissions — get_scope shows exactly what a token allows.

Notes

  • Egress consent. Matih gates third-party-LLM data egress per tenant. If your tenant hasn't accepted the data-processing agreement, calls return a clear EGRESS_CONSENT_REQUIRED error with a link to accept it.
  • Node ≥ 20 (uses native fetch + node:crypto; zero runtime dependencies).

License: Apache-2.0 · https://matih.ai

來源:README.md,提交 8a2ca5d

工具

0
該伺服器需要登入,因此 SourceWeft 無法在沒有帳號的情況下讀取其工具,也未收錄。已連接帳號所能看到的內容可能因帳號及其權限而異。

版本歷史

1
  1. v0.2.1最新Sep 16, 2026

評分

已滿足適用檢查項的 75%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。