---
title: "Semantic layer: WTF is it anyway? | Rig"
description: "A semantic layer is a dictionary of definitions for business numbers. Each BI tool used to keep its own, in a format agents could not read. Apache Ossie opens it up."
canonical: "https://rig.so/blog/wtf-is-a-semantic-layer"
format: markdown
---

[Data context and governance](https://rig.so/blog/data-context)

# WTF is a semantic layer anyway?

A semantic layer is a dictionary of definitions for business numbers. It records what revenue, churn or an active customer means, with the SQL behind each one, so every report and every agent uses the same calculation for the same term. For years those dictionaries sat inside one BI tool, in a format no other tool could read.

By [Toby Mather](https://rig.so/blog/authors/toby-mather) · Published 20 November 2026

[Request an architecture diagram for your stack](https://rig.so/book-demo?offer=architecture_diagram&from=%2Fblog%2Fwtf-is-a-semantic-layer)

## Key takeaways

- A semantic layer holds metric definitions: the name, a description, the SQL, the joins and the filters, agreed once and reused by every tool.
- Definitions written inside one BI tool have to be rebuilt by hand when you change tools, and agents usually cannot read them at all.
- Apache Ossie (Incubating), formerly Open Semantic Interchange, is a vendor-neutral YAML format for metrics, dimensions and relationships, now in the Apache Incubator.
- dbt, Snowflake, Databricks, Cube and Power BI all offer a semantic layer of some kind, and they differ mainly in where the definition lives and which tools can read it.
- Agents need the dictionary, plus the wider context around it and a governed way into the warehouse.

1. 01**Warehouse tables**
   
   Orders, refunds, accounts
2. 02**Semantic layer**
   
   Named metrics, SQL, joins and filters
3. 03**BI tools**
   
   Ask for metrics by name
4. 04**Gateway**
   
   A role, row limits and a log per agent
5. 05**AI agents**
   
   Query certified metrics over MCP

Metric definitions sit between the warehouse tables and every tool that reports on them, and agents reach them through a gateway.

## WTF is a semantic layer, in one paragraph?

Ask three teams for last quarter's revenue and you can get three numbers. Finance excludes refunds, sales counts contract value at signature, and the board pack uses a spreadsheet somebody built two years ago. Each number is correct by its own rule. A semantic layer writes the rule down once: the metric name, a plain description, the SQL expression, the tables it joins and the filters it applies. Reports, notebooks and AI agents then ask for net revenue by name and get the same calculation.

The warehouse holds the rows, and the semantic layer records how to turn those rows into the numbers people quote, without storing any data of its own. That is why people call it a layer.

Without one, the disagreements are small and constant. Novakid, an online English school, found one referral measure coming out at 1.7% in one tool and 6.91% in another, and nobody on the commercial side could tell which to believe.

## Where did these dictionaries live before?

They mostly lived inside the BI tool. SAP BusinessObjects had universes, Looker has LookML, Power BI has semantic models with DAX measures, and Tableau workbooks carry their own calculated fields. Each was a sensible design at the time, because the BI tool was the only thing that needed to know what revenue meant.

The formats were proprietary because each vendor built the dictionary for its own query engine. A LookML model compiles to SQL for Looker, and a DAX measure runs in the Power BI engine. Neither was written to be read by another product, so the definitions stayed where they were written.

That worked while one BI tool served the whole company. It stops working when you add a second BI tool, a data app, a notebook or an agent, because each one either re-implements the metric or goes without it.

## What is Apache Ossie, and how is it related to Open Semantic Interchange?

Apache Ossie (Incubating) is the new name for Open Semantic Interchange (OSI), an open specification for semantic layers and ontologies. It describes metrics, dimensions and relationships in YAML, so any tool can read the same definition. The project was accepted into the Apache Incubator and renamed so the OSI acronym would not clash with other open-source projects, and the specification did not change with the rename.

The repository opened in November 2025. Snowflake was a founding organisation and remains a contributor, and the project's announcement says the coalition has grown from 17 launch partners to more than 50 organisations. Ossie is still incubating at the Apache Software Foundation, so treat it as a format that tools are adopting over time.

You do not have to wait for it. A team that keeps its definitions in a structured form it can export today will be able to move them into Ossie documents without starting again.

## What do you lose if the dictionary is locked into one vendor?

The first cost shows up at migration time. Moving off a BI tool whose measures exist only in its own format means reading every measure, working out what it does and rewriting it in the new tool. Teams that skip that step and lift the dashboards across end up with two definitions of the same metric, and the two drift apart as each gets edited separately.

The second cost is that everything outside that tool goes without. A Python notebook, a reverse ETL job or a Claude session pointed at the warehouse cannot read a DAX measure, so it writes its own SQL for revenue and gets a slightly different answer. With a copy of revenue in every tool, there is also no single place to review a change before it reaches the board pack.

## How does a semantic layer work?

Most implementations follow the same loop, whichever vendor you pick.

1. A data team defines each metric with a name, a description, the SQL expression, the grain and the filters.
2. Someone checks the result against a number they already trust, such as the finance report, and marks the metric as certified.
3. A tool or an agent asks for the metric by name, with the dimensions and time range it needs.
4. The semantic layer turns that request into SQL against the warehouse tables and returns the result.
5. When the definition changes, it changes in one place and every consumer picks up the new version.

## What does an open format give you across tools?

An open format lets the definition live in one place while many tools read it. You can keep the metrics in Git, review each change as a pull request, and sync the same file into the BI tool and the agent layer. When finance changes how refunds are treated, somebody edits one definition and every consumer follows.

It also gives you a way out. If your definitions sit in a documented format you can export, choosing a BI tool or a semantic layer vendor stops being a ten-year decision, because the dictionary leaves with you.

## Why do AI agents need a semantic layer?

An agent pointed at raw warehouse tables guesses. It reads column names, finds three tables with revenue in the name and picks one. The SQL runs, the number looks plausible, and nobody notices that it included test transactions. A certified metric removes that guess for every question the metric covers.

The semantic layer is only part of what an agent needs. Cleo, which runs AI agents on its Redshift warehouse through Rig, found that a fixed semantic layer would not have been enough, because the questions were often ambiguous and answering them took context beyond metric definitions. Agents also need the map of the systems and tables around the metrics, which is the context layer, and a governed way into the warehouse with their own role, row limits and a log of every call.

## How Rig does it

Rig Map holds the semantic layer alongside the ontology and the context layer, on the warehouse you already run. Each metric carries its description, its SQL and its certification status, and the metrics view shows certified and draft definitions side by side. A team can describe a metric in plain English, let Rig's agent find the tables and write the SQL, and check the result against a figure it trusts before certifying it.

Rig stores metrics in an OSI-compatible format. The whole model exports as one OSI document through a pull request, so each change gets a human review, and an existing LookML layer or a set of Lightdash metrics can be imported instead of rewritten. Certified metrics also sync into Omni as native measures. Birdie took this route when it retired its legacy BI tool, moving its metric definitions and dbt models onto its own Snowflake as certified metrics.

Gateway is how people and agents reach those metrics. Each agent gets its own role, token and daily call limit, sees only the rows its role allows, and every call it makes lands in a named audit trail. Claude, Cursor and other MCP clients then query the same certified definitions as the dashboards.

## Tools and approaches

[Apache Ossie (Incubating)](https://ossie.apache.org/updates/ossie-enters-apache-incubator/)

An open, vendor-neutral YAML specification for metrics, dimensions and relationships, formerly called Open Semantic Interchange. It is incubating at the Apache Software Foundation so that no single company controls it.

[dbt Semantic Layer](https://docs.getdbt.com/docs/use-dbt-semantic-layer/dbt-semantic-layer)

Metrics defined in the dbt project, on top of existing models, and served through MetricFlow. Downstream tools use the Semantic Layer APIs and integrations, and Claude and ChatGPT can connect through the dbt MCP server. It needs a dbt Starter or Enterprise-tier account.

[Snowflake semantic views](https://docs.snowflake.com/en/user-guide/views-semantic/overview)

Schema-level objects that hold logical tables, relationships, facts, dimensions and metrics inside Snowflake. You query them in SQL, and Cortex Analyst and Cortex Agents use them for natural-language questions.

[Databricks metric views](https://docs.databricks.com/aws/en/metric-views/)

Unity Catalog objects that define measures separately from the fields used to group and filter them, so users can group by any available field at query time. Genie, dashboards and external BI tools can query them.

[Cube](https://cube.dev/product/semantic-layer)

A semantic layer that holds metrics, dimensions, joins and access rules, and serves the same governed model to AI clients such as Claude, ChatGPT and Cursor over MCP.

[Power BI semantic models](https://learn.microsoft.com/en-us/power-bi/connect-data/service-datasets-understand)

Analysis Services tabular models with tables, relationships and DAX measures, built to serve Power BI reports. They can enforce row-level security for report users.

## Common questions

Is a semantic layer the same as a data warehouse?

No. The warehouse stores the data, and the semantic layer holds the definitions used to compute business numbers from it. When someone asks for a metric, the semantic layer sends SQL to the warehouse.

Do I need dbt to have a semantic layer?

dbt is one option. Snowflake semantic views, Databricks metric views, Cube and Rig Map all hold metric definitions without a dbt project. If you already use dbt, its Semantic Layer keeps metrics next to your models.

Can a Power BI semantic model replace a semantic layer?

A Power BI semantic model works well for Power BI reports. Other BI tools and agents usually cannot reuse its DAX measures, so teams that add agents tend to define the metrics again in the warehouse. Our Power BI post covers the trade-off in detail.

What is Ossie, and do I have to wait for it?

Apache Ossie is the open format for semantic layers that used to be called Open Semantic Interchange, and it is incubating at Apache. You can keep your definitions in a structured, exportable form now and move them into Ossie documents later.

What happens if my definitions only exist inside one vendor model?

You rewrite them by hand when you change tools, and every tool that cannot read that model writes its own version in the meantime. Exporting them to a shared format, or rebuilding them once in the warehouse, avoids both.

How do AI agents use a semantic layer?

An agent asks for a metric by name, usually through an MCP tool, and the semantic layer returns the agreed calculation. The agent still needs its own role and an audit trail for that access, which is the job of a gateway.

## Related reading

[Data context and governance](https://rig.so/use-cases/data-context-and-governance)[Rig Map](https://rig.so/products/rig-map)[Gateway](https://rig.so/products/gateway)[Semantics, ontology, context... buzzword bingo, or business value?](https://rig.so/blog/semantics-ontology-context-buzzword-bingo)[Everyone's banging on about context, but what actually is it?](https://rig.so/blog/what-actually-is-context)[How far do Snowflake Semantic Views actually get you?](https://rig.so/blog/snowflake-context-layer-and-semantic-views)[If dbt holds the metrics, who decides who can query them?](https://rig.so/blog/dbt-semantic-layer-vs-warehouse-native-semantic-views)[I'd stop treating a Power BI model like the company brain](https://rig.so/blog/power-bi-semantic-model-vs-warehouse-semantic-layer)[How to create a Snowflake semantic view](https://rig.so/semantic-layer/snowflake)[Semantic layer](https://rig.so/compare/semantic-layer)[Birdie case study](https://rig.so/case-studies/birdie)

## Sources

Vendor documentation checked on 20 November 2026. Confirm current features and terms with the vendor.

- [Apache Ossie enters the Apache Incubator](https://ossie.apache.org/updates/ossie-enters-apache-incubator/)
- [dbt Semantic Layer (dbt docs)](https://docs.getdbt.com/docs/use-dbt-semantic-layer/dbt-semantic-layer)
- [Overview of semantic views (Snowflake docs)](https://docs.snowflake.com/en/user-guide/views-semantic/overview)
- [Unity Catalog metric views (Databricks docs)](https://docs.databricks.com/aws/en/metric-views/)
- [Cube semantic layer](https://cube.dev/product/semantic-layer)
- [Semantic models in the Power BI service (Microsoft Learn)](https://learn.microsoft.com/en-us/power-bi/connect-data/service-datasets-understand)

## About the author

[Toby Mather](https://rig.so/blog/authors/toby-mather), Co-founder and CEO, Rig. Toby co-founded Rig after seeing how hard it was for business teams and AI to work with complex internal data. He was previously co-founder and CEO of Lingumi and CPO at Novakid.

Talk to Rig

## See your stack drawn as one diagram

An architect drafts a one-page diagram of your warehouse, sources and access path, then offers a 30-minute walkthrough.

[Request an architecture diagram for your stack](https://rig.so/book-demo?offer=architecture_diagram&from=%2Fblog%2Fwtf-is-a-semantic-layer)[Book a call with an architect](https://rig.so/book-demo?offer=architect_call&from=%2Fblog%2Fwtf-is-a-semantic-layer)

---

- [This page as HTML](https://rig.so/blog/wtf-is-a-semantic-layer)
- [Site map for language models](https://rig.so/llms.txt)
- [API and agent documentation](https://rig.so/developers)
