How dbt-labs/jaffle-shop-classic works
Main Components
a) Data Sources Layer:
• Raw Data Files (Seeds)
• raw_customers.csv
• raw_orders.csv
• raw_payments.csv
b) Staging Layer:
• stg_customers
• stg_orders
• stg_payments
c) Core Transformation Layer:
• customers (final model)
• orders (final model)
Key Elements to Highlight
a) Configuration Components:
• dbt_project.yml (project configuration)
• schema.yml files (model specifications)
• Documentation files (docs.md, overview.md)
b) Data Flow:
• How raw data is loaded via dbt seed
• Transformations from staging to final models
• Testing and documentation generation flows
Specific Implementation Details
[Data Sources]
• ▼
[Staging Layer]
• ▼
[Core Models]
• ▼
[Documentation & Testing]
Relationships:
• raw_customers.csv → stg_customers.sql → customers.sql
• raw_orders.csv → stg_orders.sql → orders.sql
• raw_payments.csv → stg_payments.sql → orders.sql
Technical Details to Note
• How the dbt project structure enforces modularity
• Where tests are defined (schema.yml files)
• Documentation generation flow
• Reference to the target data warehouse