creating-dbt-models

Create and update dbt models with dbt build and dbt show validation.

2|Updated Apr 8, 2026
One-click install
npx skills add https://github.com/miptah21/skills --skill creating-dbt-models
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: creating-dbt-models
Source: https://github.com/miptah21/skills/tree/main/.agents/skills/creating-dbt-models
Command: npx skills add https://github.com/miptah21/skills --skill creating-dbt-models

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It solves the problem of reliably creating and updating dbt models without introducing schema mistakes or incorrect transformations by enforcing build-and-verify discipline.

Core Features & Use Cases

  • Conventions-first model creation: Discovers naming, config, and SQL patterns from your existing project before writing new logic.
  • End-to-end validation: Runs dbt build (not compile) and then verifies the resulting relations and sample data using dbt show.
  • Correctness checks against requirements: Confirms grain, column names, NULL expectations, and calculation outputs against sample rows and schema.yml test expectations.
  • Use case: When you need to add a new fact or intermediate model (or modify joins, transformations, or columns) based on task requirements or schema.yml specs, this ensures the model matches both structure and logic.

Quick Start

Use the creating-dbt-models skill to create or modify a dbt model following project conventions, run dbt build for verification, and then confirm the output with dbt show using the requested columns and grain.

Frequently Asked Questions about creating-dbt-models

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create dbt models that match existing project conventions?

To create dbt models that match project conventions, discover existing naming, config, and SQL patterns from your project before writing new logic. This ensures new model structure aligns with established warehouse transformations.

What is the best way to validate dbt model logic and output?

The best way to validate dbt model logic is by running dbt build for execution and then using dbt show to verify relations. This confirms output calculations, grain, and NULL expectations against sample rows.

Can I generate a dbt model directly from a schema.yml specification?

Yes, you can generate a dbt model directly from a schema.yml specification. The creation process implements logic from test expectations and verifies correctness against requested columns and grain.

Why does my dbt model fail correctness checks after compiling?

Your dbt model may fail correctness checks if you only compile rather than executing dbt build. Correctness requires running dbt build, verifying output with dbt show, and cross-checking calculations and grain against requirements.

Do I need to run dbt build or dbt compile when modifying SQL transformations?

You need to run dbt build, not compile, when modifying SQL transformations. Running dbt build enforces verification discipline by executing the model logic against your data warehouse for validation.