
mattijsdp/dbt-docs-mcp
Developer tools이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기
MCP (모델 컨텍스트 프로토콜) 서버는 dbt Docs와 상호 작용
개요
Dbt Docs artifacts (manifest.json, Catalog.json)를 포함한 dbt 프로젝트 메타데이터와 상호 작용하는 모델 Context Protocol (MCP) 서버. 이 서버는 dbt 그래프 정보를 노출하고 노드 세부 사항, 모델/column 선량 및 관련 메타데이터를 쿼리 할 수 있습니다. * 이름(search dbt node names)의 노드(모델, 소스, 테스트 등)를 찾습니다. * 열명(search dbt column names)을 기반으로 노드를 찾습니다. * 노드의 컴파일된 SQL 코드 내에서 검색(search dbt sql code). * 주어진 노드 고유 ID (get dbt node attributes)에 대한 자세한 속성을 검색합니다. * 노드 (get dbt predecessors)의 직접 업스트림 의존성을 찾습니다. * 노드 (get dbt successors)의 직접 다운스트림 의존성을 찾습니다. * 모형 (get column ancestors)에 있는 특정한 란을 위한 모든 상류 근원을 추적하십시오. * 모형 (get column descendants)에 있는 특정한 란의 모든 하류 의존합니다. * SQL 쿼리를 실행할 수 있는 도구.
개요(AI 번역)
Dbt Docs artifacts (manifest.json], catalog.json]를 포함한 dbt 프로젝트 메타데이터와 상호 작용하는 모델 Context Protocol (MCP) 서버. 이 서버는 dbt 그래프 정보를 노출하고 노드 세부 사항, 모델/column 선량 및 관련 메타데이터를 쿼리 할 수 있습니다.
키 기능
이 서버는 다음과 같은 도구를 제공합니다:
- 검색 dbt 노드:
- 이름(
search_dbt_node_names)에 의한 노드(모델, 소스, 테스트 등)를 찾습니다. - 열명(
search_dbt_column_names)을 기반으로 노드를 찾습니다. - 노드의 컴파일된 SQL 코드 내에서 검색([
search_dbt_sql_code). *Inspect 노드: - 주어진 노드 고유 ID(
get_dbt_node_attributes)에 대한 자세한 속성을 검색합니다. - ** 광대역:**
- 노드(
get_dbt_predecessors)의 직접 상류 의존도(predecessors)를 찾습니다. - 노드(
get_dbt_successors])의 직접 다운스트림 의존(successors)를 찾습니다. - **Column-Level Lineage: **
- 모형에 있는 특정한 란을 위한 모든 상류 근원을 추적하십시오 (
get_column_ancestors). - 모형에 있는 특정한 란의 모든 다운스트림 의존합니다 (
get_column_descendants). *Suggested 확장: - SQL 쿼리를 실행할 수 있는 도구.
이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.
README
원문 README의 일부입니다. 원문 보기.
dbt-docs-mcp
Model Context Protocol (MCP) server for interacting with dbt project metadata, including dbt Docs artifacts (manifest.json, catalog.json). This server exposes dbt graph information and allows querying node details, model/column lineage, and related metadata.
Key Functionality
This server provides tools to:
- Search dbt Nodes:
- Find nodes (models, sources, tests, etc.) by name (
search_dbt_node_names). - Locate nodes based on column names (
search_dbt_column_names). - Search within the compiled SQL code of nodes (
search_dbt_sql_code).
- Find nodes (models, sources, tests, etc.) by name (
- Inspect Nodes:
- Retrieve detailed attributes for any given node unique ID (
get_dbt_node_attributes).
- Retrieve detailed attributes for any given node unique ID (
- Explore Lineage:
- Find direct upstream dependencies (predecessors) of a node (
get_dbt_predecessors). - Find direct downstream dependents (successors) of a node (
get_dbt_successors).
- Find direct upstream dependencies (predecessors) of a node (
- Column-Level Lineage:
- Trace all upstream sources for a specific column in a model (
get_column_ancestors). - Trace all downstream dependents of a specific column in a model (
get_column_descendants).
- Trace all upstream sources for a specific column in a model (
- Suggested extensions:
- Tool that allows executing SQL queries.
- Tool that retrieves table/view/column metadata directly from the database.
- Tool to search knowledge-base.
Getting Started
- Prerequisites: Ensure you have Python installed and uv
- Clone the repo:
git clone cd dbt-docs-mcp - Optional: parse dbt manifest for column-level lineage:
- Setup the required Python environment, e.g.:
uv sync- Use the provided script
scripts/create_manifest_cl.pyand simply provide the path to your dbt manifest, dbt catalog and the desired output paths for your schema and column lineage file:
python scripts/create_manifest_cl.py --manifest-path PATH_TO_YOUR_MANIFEST_FILE --catalog-path PATH_TO_YOUR_CATALOG_FILE --schema-mapping-path DESIRED_OUTPUT_PATH_FOR_SCHEMA_MAPPING --manifest-cl-path DESIRED_OUTPUT_PATH_FOR_MANIFEST_CL- Depending on your dbt project size, creating column-lineage can take a while (hours)
- Run the Server:
- If your desired MCP client (Claude desktop, Cursor, etc.) supports mcp.json it would look as below:
{ "mcpServers": { "DBT Docs MCP": { "command": "uv", "args": [ "run", "--with", "networkx,mcp[cli],rapidfuzz,dbt-core,python-decouple,sqlglot,tqdm", "mcp", "run",
설치
This server does not publish a one-line install command.
Open the repository installation guide MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →설정
{
"mcpServers": {
"DBT Docs MCP": {
"command": "uv",
"args": [
"run",
"--with",
"networkx,mcp[cli],rapidfuzz,dbt-core,python-decouple,sqlglot,tqdm",
"mcp",
"run",
"/Users/mattijs/repos/dbt-docs-mcp/src/mcp_server.py"
],
"env": {
"MANIFEST_PATH": "/Users/mattijs/repos/dbt-docs-mcp/inputs/manifest.json",
"SCHEMA_MAPPING_PATH": "/Users/mattijs/repos/dbt-docs-mcp/outputs/schema_mapping.json",
"MANIFEST_CL_PATH": "/Users/mattijs/repos/dbt-docs-mcp/outputs/manifest_column_lineage.json"
}
}
}
}