From dbt-pipeline-toolkit
Generate and serve dbt documentation including model lineage, column descriptions, and test results. Use when creating dbt documentation, viewing model relationships, exploring data lineage, or sharing documentation with stakeholders. Supports generating static sites, serving locally, and exporting documentation artifacts.
How this skill is triggered — by the user, by Claude, or both
Slash command
/dbt-pipeline-toolkit:dbt-docs-generatorThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Generate comprehensive dbt documentation with model lineage, descriptions, and test results.
Generate comprehensive dbt documentation with model lineage, descriptions, and test results.
This skill helps you:
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate
Runs dbt docs generate to create:
manifest.json - Model metadata and lineagecatalog.json - Column information from databaseindex.html - Documentation siteOutput location: target/ directory
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" serve
Starts a local web server to browse documentation interactively.
Features:
Access: Opens browser to http://localhost:8080
Stop server: Press Ctrl+C
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" all
Runs both generate and serve in sequence.
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" export --output-dir ./docs-export
Exports a static HTML site that can be:
Output: Complete static site in specified directory
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" serve --port 8081
Start docs server on a different port (useful if 8080 is in use).
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate --no-catalog
Generates only manifest.json, skips catalog.json (database query).
Use when:
Requires: Active database connection
For each model, documentation shows:
Interactive graph showing:
For each column:
Ensure models have descriptions in schema.yml:
models:
- name: fct_sales
description: Daily sales transactions with customer and product information
columns:
- name: sales_key
description: Surrogate primary key for sales transactions
data_tests:
- unique
- not_null
Regenerate docs after:
Before sharing with stakeholders:
DO commit:
DON'T commit (add to .gitignore):
Exception: You may commit these for static site hosting.
Generate docs in CI/CD pipeline:
# GitHub Actions example
- name: Generate dbt Docs
run: |
dbt docs generate
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./target
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate
Running: dbt docs generate
15:23:45 Running with dbt=1.7.4
15:23:46 Found 45 models, 120 tests, 3 sources
15:23:47
15:23:47 Concurrency: 4 threads
15:23:47
15:23:48 Building catalog
15:23:52 Catalog written to target/catalog.json
15:23:52 Done.
SUCCESS: Documentation generated
Files created:
- target/manifest.json (523 KB)
- target/catalog.json (145 KB)
- target/index.html (89 KB)
View docs: python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" serve
If catalog generation fails:
WARNING: Could not generate catalog.json
Reason: Database connection failed
Documentation generated with manifest only.
Catalog.json will be missing column information.
To fix:
1. Check database connection in profiles.yml
2. Ensure models have been run (tables exist in database)
3. Run 'dbt run' to create tables, then regenerate docs
# After creating new models
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" all
# Browse locally
# Verify lineage is correct
# Check model descriptions are clear
# Generate clean docs
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate
# Export static site
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" export --output-dir ./stakeholder-docs
# Share folder with stakeholders
# Or upload to web hosting
# In PR workflow
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate
# Check if manifest.json generated successfully
# Validates that all refs are correct
# Ensures no circular dependencies
# Start docs server
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" serve
# New team member can:
# - Browse all models and their purpose
# - Understand data lineage
# - See what tests exist
# - View example SQL queries
dbt-orchestrator: Generate docs after model creation workflow dbt-staging-builder: Verify source documentation exists dbt-test-writer: Document tests that were added All model builders: Validate model descriptions are complete
Error: Port 8080 is already in use
Solution:
# Use different port
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" serve --port 8081
Error: Could not connect to database
Solution:
--no-catalog flag to skip catalog generationError: No models found in project
Solution:
Error: Circular dependency detected
Solution:
Default locations:
target/
├── manifest.json # Model metadata and lineage
├── catalog.json # Column info from database
├── index.html # Documentation website
├── graph.gpickle # Dependency graph (binary)
└── run/ # Compiled SQL
Exported site (if using export):
docs-export/
├── manifest.json
├── catalog.json
├── index.html
└── [other static assets]
Generation time:
Catalog generation is the slowest part:
--no-catalog to skip for faster generationpython "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate --project-dir /path/to/project
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate --target prod
Uses prod target from profiles.yml instead of default.
python "${CLAUDE_PLUGIN_ROOT}/skills/dbt-docs-generator/scripts/generate_docs.py" generate --warn-error
Treats warnings as errors (stricter validation).
Use this skill when:
Typical workflow:
generate_docs.py generategenerate_docs.py serve to reviewPython Dependencies:
dbt Requirements:
System Requirements:
Best Practice: Generate docs regularly and review lineage Target Audience: Developers, analysts, stakeholders Update Frequency: After every significant model change
npx claudepluginhub kavasimihaly/ai-plugins --plugin dbt-pipeline-toolkitGuides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.