> ## Documentation Index
> Fetch the complete documentation index at: https://docs.synehq.com/llms.txt
> Use this file to discover all available pages before exploring further.

# dbt in Syne

> Connect existing dbt models for analysis, or connect a GitHub project for isolated compilation and reviewed changes.

dbt projects, including dbt Cloud analysis, manifest imports, GitHub compilation, and team-managed runners, require Syne Pro or an eligible trial.

Syne brings dbt model definitions, dependencies, SQL analysis, and change review into one workspace. Your existing dbt environment continues to build and schedule the models.

<Note>
  This integration is a PostgreSQL preview. Your Syne deployment must include the matching dbt app and metadata migrations. Snowflake, BigQuery, and Redshift are outside this preview.
</Note>

## Choose how to connect

| Starting point                        | What to connect                                                                    | What you can do                                                                                           |
| ------------------------------------- | ---------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- |
| Models built by dbt Cloud             | Read token, account, job, and an existing Syne PostgreSQL connection               | Refresh model metadata, browse definitions and dependencies, query built relations, and analyze with Kole |
| Models built elsewhere                | `manifest.json` and an existing Syne PostgreSQL connection                         | Import model metadata and analyze built relations without GitHub or a dbt platform token                  |
| Source you want to compile and govern | GitHub repository, ref, project folder, and an existing Syne PostgreSQL connection | Compile on request, inspect SQL and changes, query data, and create reviewed schema-change tickets        |

dbt Cloud does not serve the model rows to Syne. Models materialize as tables or views in your warehouse, and queries use your existing Syne connection. Syne retains model metadata and artifact history, not a hosted copy of the warehouse.

<CardGroup cols={2}>
  <Card title="Connect existing models" icon="database" href="/features/dbt/connect-existing-models">
    Start with dbt Cloud or a manifest. GitHub and compilation are optional.
  </Card>

  <Card title="Compile and govern source" icon="code" href="/features/dbt/compilation">
    Connect GitHub, inspect generated SQL, and propose reviewed changes.
  </Card>

  <Card title="Install a team runner" icon="server" href="/features/dbt/team-runners">
    Use your own Linux machine for larger compilation jobs.
  </Card>
</CardGroup>

## Query with model context

Open **Database tools > dbt**, choose a project, and select a model. Inspect its declared columns, descriptions, upstream dependencies, and artifact provenance. **Analyze data** accepts read-only SQL for joins and aggregations on built relations. The editor displays up to 200 rows; the API permits up to 1,000. Single-model previews show up to 100 rows.

Queries run through Syne's database bridge under the requesting user's identity, with read-only enforcement, team scoping, masking, and auditing. Use the correct warehouse database and least-privilege connection; importing metadata does not grant access to a relation.

Kole can explain the model, help write an aggregate, and execute read-only dbt analysis through the same app APIs. Compilation and schema-change ticket creation pause for human approval. Analysis-only projects do not expose these source-management actions.

## Know what the artifact proves

An artifact records model definitions at a point in time. A successful compilation does not build a table, execute data tests, or prove freshness. A successful dbt Cloud run identifies the artifact's origin; Syne does not import test results or certify that every model was built by that run. Querying requires the selected relation to exist in the connected database.

Metadata refresh and manifest import are manual. A failed refresh keeps the previous successful snapshot. After project settings change, refresh or import current metadata before querying. Each project permits one active metadata request; compilation, refresh, and import share a limit of 20 requests per team per hour.

Syne deployments may provide a shared managed runner pool. Multiple worker replicas serve team-isolated compilation jobs from a durable queue and create a fresh compiler container per job. Teams keep their existing project connection; they do not register these shared workers.
