Overview
What is a Semantic Layer?
There are a lot of arguments about what a semantic layer is. When we refer to a semantic layer in Buster, we mean a collection of YAML files that define:
- Models: These are the core business objects that you want to analyze. Examples are order, products, customers, etc.
- Dimensions: These are typically non-numeric attributes used for grouping, filtering, or segmenting data like dates, categories, statuses, names, etc.
- Measures: These are quantifiable attibutes like a product cost, duration of a session, temperature, etc.
- Metrics: These are calculations and business logic that typically represent the combination of measures and dimensions. Examples are total revenue, average order value, etc.
- Filters: These are named boolean conditions for common query constraints. Examples are is_active, is_deleted, is_paid, etc.
- Relationships: These are the connections between different models. Like a customer model that connects to an order model.
These definitions allow Buster to generate accurate SQL, understand business metrics consistently, and provide reliable insights from your data.
Unlike other semantic layers, Buster’s semantic layer is not an abstracted compute layer. It resembles a data catalog more closely. We use the configurations from the YAML files to enable the Agent to understand the data and build reliable queries.
Why Use a Semantic Layer?
Centralized Business Logic
Define business logic and metrics once in a versioned state ensuring consistent reuse across all analyses.
Data Relationships
Map connections between tables so Buster can navigate your data model.
Context & Meaning
Add descriptions and metadata to help Buster understand what your data represents.
Data Governance
Control which data is accessible and how it can be used.