Skip to main content
The Elementary dbt package includes uploading and modeling of dbt artifacts.
Each dbt invocation generates artifacts, with details about the project resources, configuration and execution. Most are in json format. The artifacts are practically the metadata and logs of the dbt project.

How Elementary uploads dbt artifacts

The Elementary dbt package includes macros that extract specific fields from the artifacts during the execution, and insert to tables. These tables are defined as models of the package. Some artifacts are updated by an on-run-end hook when you run dbt run / test / build, and some only when you run the models:
  • On run end:
    • elementary_test_results - Results of all dbt tests (including elementary and other packages, such as dbt_expectations and dbt_utils).
    • dbt_run_results - Results of all dbt executions.
  • dbt run that includes elementary models:
    • dbt_models, dbt_tests, dbt_sources, dbt_exposures, dbt_metrics - Metadata and configuration. It is recommended to run these models when you make changes in your projects.

Which artifacts are uploaded and modeled?

Elementary uploads fields from the run-results, and the graph object (includes data of manifest, catalog and sources). You can disable or enable the relevant models in the Elementary package if you want to limit the artifacts that are loaded to your data warehouse (under elementary/models/edr/dbt_artifacts).

dbt artifacts models

Elementary loads data from dbt artifacts to models that can be found under dbt_artifacts folder of the package. For dbt_run_results data is inserted at the on-run-end, and for the rest of the models it’s a post-hook on the model itself. The dbt artifacts models include:
  • Metadata tables - dbt_models, dbt_tests, dbt_sources, dbt_exposures, dbt_metrics, dbt_snapshots, dbt_seeds, dbt_columns, dbt_groups - These provide a comprehensive view of your dbt project structure and configurations. Each time these models are executed, the data is replaced with data from the project’s current graph.
  • Run results tables - dbt_run_results, dbt_invocations, elementary_test_results, model_run_results, snapshot_run_results, seed_run_results, job_run_results, dbt_source_freshness_results - These track execution details, test outcomes, and performance metrics from your dbt runs.
For detailed schema documentation including all columns and their descriptions, see the package models documentation.