The Wren Journal
Product

Your dbt Models Are Your Context Layer: Native dbt Integration in Wren AI

Wren AI's new dbt integration is here. Connect your existing dbt project and turn your dbt models into your Wren AI context layer, no duplicate setup required. Your governed dbt models are instantly ready for natural language querying, accelerating your time-to-insight and democratizing access to trustworthy data across your organization.

Pin Chang

Pin Chang

Updated: Jan 06, 2026
Published: Jan 06, 2026

Your dbt Models Are Your Context Layer: Native dbt Integration in Wren AI

In the world of data, transformation is key. Data teams invest significant effort in modeling and preparing data to ensure its reliability and meaning. But often, a gap remains between this meticulously crafted data and the business users who need to act on it. We're thrilled to announce a powerful step forward in bridging this gap: native dbt (data build tool) integration in Wren AI. This feature allows you to leverage your existing dbt models directly within Wren AI's Generative BI platform, turning natural language questions into governed, trustworthy answers.

What is dbt?

dbt(data build tool) is an open-source command-line tool that has become a foundational component of the modern data stack. It's the "T" in ELT (Extract, Load, Transform), allowing analytics engineers and data analysts to transform data within their data warehouse.

  • SQL-Based Transformation: dbt allows you to write all your transformation logic using simple SQL SELECT statements.
  • Software Engineering Best Practices: It brings concepts like version control, modularity (using ref() to build dependent models), documentation, and testing to the analytics code layer.
  • The Semantic Layer: Through its robust model definitions, dbt effectively acts as an organizational context layer, defining governed metrics, logic, and data lineage for the entire organization.

In short, dbt empowers analysts to work like engineers, ensuring data transformations are reliable, well-documented, and scalable.

How to Integrate dbt to Wren AI

The integration between dbt and Wren AI is designed to be semantic-first and seamless. Wren AI connects directly to your dbt project, automatically syncing models and metadata to power its Text-to-SQL engine.

Key Features of the Integration:

  1. Automatic Metadata Sync: Wren AI automatically imports your dbt models, column descriptions, and relationships. This eliminates manual semantic mapping and ensures the AI is always operating on your most current, governed definitions.
  2. Governed Analytics: By querying your dbt models, Wren AI ensures that every insight adheres to the transformation logic and metric definitions your team has already defined in dbt.

End-to-End Demo Steps: 

  1. Build and Materialize Your dbt Models: Simply run your standard dbt command (like dbt build or dbt run) to ensure your models are materialized in your data warehouse. This process automatically generates all the essential metadata, such as relationships, column definitions, and logic, that Wren AI uses.

    截圖 2025-12-11 上午3.02.38.png
    截圖 2025-12-11 上午3.02.38.png

  2. Generate dbt Documentation: Execute the dbt docs generate command. This step creates the necessary catalog.json file in your target/ directory. This file contains crucial metadata, including column types, which Wren AI requires for accurate model import and semantic mapping.

    截圖 2025-12-11 上午3.33.24.png
    截圖 2025-12-11 上午3.33.24.png

  3. Sync dbt models to Wren AI: Using the Wren AI CLI (Installation and Login guide), link your dbt project to your Wren AI project. This typically involves pointing Wren AI to your dbt project directory or a repository.

截圖 2025-12-11 上午3.39.24.png
截圖 2025-12-11 上午3.39.24.png
4. Start Conversational Analysis: Once the sync is complete, you will see your dbt models automatically imported into Wren AI, complete with all defined relationships and column descriptions. The context layer is built for you! Any user can immediately begin asking complex, natural-language questions.
models-2a1f7225277758678b5bc2bb087694f9.png
models-2a1f7225277758678b5bc2bb087694f9.png
5. Update existing data: Execute the sync operation (e.g., a wren dbt update command in the CLI). Wren AI will ingest the metadata (model names, column names, descriptions, tests) from your dbt project.


Integrating your dbt project with Wren AI isn't just about connecting two tools; it's about accelerating the time-to-insight and democratizing access to governed data. You do the hard work of building and testing reliable data models in dbt, and Wren AI instantly unlocks that work for the entire organization through the power of conversation.

Check the full dbt integration with Wren AI documentation here

Ready to transform how your organization accesses data? Request a demo or start your free trial at getwren.ai

Keep reading