CountLineage

A semantic layer for AI: give the model your definitions, not just your tables

AI for data and analytics · Facts checked 22 October 2026

A semantic layer stores your metric definitions, joins and business rules in one place, so an AI assistant queries "net revenue" as your team defined it instead of guessing from column names. Snowflake, Google, Microsoft and dbt all ground their AI answers this way. It cuts guessing; it doesn't remove ambiguity, wrong definitions or questions the layer doesn't cover.

Give a model only a schema and it invents your business logic

Point an assistant at a warehouse and ask for revenue last month. It finds orders.amount, sums it and gives you a figure. It doesn't know that finance excludes refunds, recognises annual plans monthly, reports in GBP, and stopped counting the reseller channel in March. None of that is in the schema. All of it is in someone's head, a dbt model or a LookML file.

The vendors building AI analytics say this outright. Snowflake: "Generic AI solutions often struggle with text-to-SQL conversions when given only a database schema", which is why Cortex Analyst reads semantic views (Snowflake docs). Microsoft: without a prepared semantic model, "Copilot can misinterpret the data and return generic or inaccurate results" (Power BI docs). dbt: assistants connected to its Semantic Layer through the dbt MCP server "use your governed metrics instead of guessing at raw tables" (dbt docs). Looker's Conversational Analytics goes furthest: it doesn't query your database directly at all, but selects fields and filters and lets Looker compose the query from LookML (Google Cloud docs).

The research points the same way, from an unexpected angle. A 2026 audit of two leading text-to-SQL benchmarks found annotation errors in 52.8% of BIRD Mini-Dev items and 62.8% of Spider 2.0-Snow items, many of them questions ambiguous enough to have more than one reasonable answer (Jin et al., January 2026). If the experts writing the answer key couldn't agree what a question meant, the model was never going to work it out from column names. Definitions have to be written down somewhere a model can read them.

What goes in a semantic layer an AI can use

A semantic layer for AI is the same thing as a semantic layer for people, with more attention paid to the words. The parts that matter:

Part What it holds Why the model needs it
Metrics Each measure's formula, filters and default time grain So "revenue" means one thing
Dimensions The fields you slice by, with allowed values So "region" isn't guessed from three similar columns
Joins and entities How tables relate, at what grain So a join doesn't fan out and double a total
Descriptions and synonyms Plain-language meaning; what people call it So "ARR", "annual run rate" and "recurring revenue" land on the same metric
Verified queries Questions with known-good answers So the tool can reuse a checked pattern, and you can test it
Access rules Who can see which rows and columns So an assistant answers with the asker's permissions

An illustrative metric, not any one vendor's syntax:

metric: net_revenue_retention
description: >
  Recurring revenue this month from customers who were paying
  12 months ago, divided by their recurring revenue then.
  Includes expansion and contraction; excludes new customers.
synonyms: [NRR, net dollar retention, NDR]
grain: month
filters: exclude internal and test accounts
owner: finance-analytics

The description and synonyms lines are the ones teams skip and models need most. A human analyst asks what "NDR" means; a model maps it to whatever looks closest.

See whether the answer used your definition

A semantic layer makes the number consistent. Count shows what the answer actually rests on: connect it to Claude or ChatGPT, audit the answer, and trace each claim to the metric, query or assumption behind it.

Use the semantic layer you already have

We'd almost always start with the layer you already maintain. Count's own experience converting customers' LookML and Snowflake models taught us that "no one really wants to maintain more than one semantic layer" (semantic interoperability), and an AI project is a poor reason to start a second.

Where your definitions live How AI reaches them Worth knowing
dbt Semantic Layer dbt MCP server (remote or self-hosted) into Claude, ChatGPT or other clients Needs dbt Starter, Enterprise or Enterprise+. The remote server can't run dbt CLI commands; headers switch off whole toolsets
Snowflake semantic views Cortex Analyst, including through the Snowflake-managed MCP server The MCP server supports semantic views only, not the older semantic model files
Looker (LookML) Conversational Analytics in Looker, powered by Gemini Answers are composed from LookML fields; up to 50,000 rows per query
Power BI semantic model Copilot for Power BI Needs Fabric F2 or Premium P1 capacity; questions outside the model fall back to general knowledge
Databricks metric views Genie agents An agent covers up to 50 tables, views or metric views
Cube or Omni Their own MCP servers, for Claude, ChatGPT and others Cube is a standalone semantic layer; Omni's sits inside its BI tool

Details from each vendor's documentation, checked 22 October 2026.

If you have nothing yet, a dbt Semantic Layer is the most portable choice because so many tools can read it, but a written glossary in a Claude project is a respectable start and takes an afternoon. Standards are moving too: the Open Semantic Interchange (OSI) specification aims to make models portable between tools, though as our post notes, adoption is early.

Connect your semantic layer to Claude

Using dbt as the example, because it's the most widely readable. Steps from dbt's and Anthropic's own docs:

  1. Copy the MCP URL from dbt: Account settings → Access URLs → MCP Endpoint URL. The format is https://YOUR_DBT_HOST_URL/api/ai/v1/mcp (dbt remote MCP docs).
  2. Add it in Claude under Customize → Connectors → + → Add custom connector, paste the URL and sign in through OAuth (public beta). On Team or Enterprise, an Owner adds it under Organization settings → Connectors first (Claude help centre).
  3. Decide what it may do. With token auth, dbt's headers x-dbt-disable-toolsets and x-dbt-disable-tools narrow access, for example switching off the sql toolset so Claude can only query governed metrics. With OAuth, use Claude's own Search and tools menu to switch off tools you don't want.
  4. Tell the project to prefer metrics. A few lines of instructions do most of the work:
For any number about our business, use the dbt Semantic Layer first
(list_metrics, then query_metrics). Quote the metric's description
before the value. If no metric fits, say so and ask before writing SQL.
Never answer a business number from general knowledge.

On Snowflake the equivalent is a Cortex Agent or Cortex Analyst tool over semantic views, exposed through Snowflake's MCP server. Snowflake recommends making the agent the only client-facing tool for governed questions, because direct SQL can bypass the agent's governance (Snowflake docs). More on each in dbt MCP and Snowflake MCP, and the whole stack in AI for data teams.

What a semantic layer doesn't fix

A semantic layer moves the guessing; it doesn't end it. Four gaps stay open.

  • The model still chooses the metric. Ask "how are we doing on retention?" and it has to pick between gross revenue retention, net revenue retention and logo retention. Good synonyms and descriptions help. They don't decide for it.
  • The definition can be wrong. A governed metric is consistently computed, which isn't the same as correct. If the layer counts trial accounts as customers, every AI answer will too, with total confidence.
  • Questions fall off the edge. Ask about something the layer doesn't model and the assistant either writes raw SQL or, in Copilot for Power BI's case by Microsoft's own description, answers from general knowledge. Instruct it to say when it has left the governed metrics.
  • The narrative isn't governed. The number can come from the layer while the sentence explaining it ("retention rose because of the pricing change") comes from nowhere.

This is why grounding and checking are different jobs. The semantic layer makes the number consistent; you still need to see which number it used and what the explanation rests on.

A two-minute check for answers built on a semantic layer

  1. Did it use a governed metric? Look for the metric's name in the tool call. If the answer came from SQL the model wrote, treat it as unreviewed.
  2. Is it the right metric? Read the description it used. NRR or GRR? Customer or revenue churn?
  3. Check the filters it added. Governed metrics take filters at query time; a stray date or segment filter changes the answer without changing the definition.
  4. Separate number from narrative. The value may be governed; the "because" usually isn't. Ask what data supports the explanation.
  5. Run the same question phrased differently. If two phrasings hit two metrics, add a synonym to the layer.

To do this claim by claim, connect Count to Claude or ChatGPT and ask it to audit the answer. Each claim is labelled as a citation, an assumption, model knowledge or a hallucination, and the reasoning chain shows whether it rests on a query, a definition or nothing at all. For checking AI answers more generally, see how to check AI answers.

Questions people ask

What is a semantic layer?

A single place where a company defines its metrics, dimensions, joins and business rules, so every tool that queries the data computes "revenue" or "active customer" the same way. dbt's Semantic Layer, Snowflake semantic views, LookML and Power BI semantic models are all examples.

Does AI need a semantic layer?

It needs your definitions written down, and a semantic layer is the most dependable place for them. Without one, an assistant guesses the meaning of a metric from table and column names. Snowflake, Microsoft, Google and dbt all ground their AI analytics in a semantic model for this reason.

Can Claude use the dbt Semantic Layer?

Yes. Add dbt's remote MCP server as a custom connector in Claude, and Claude can list governed metrics and query them, with dbt building the SQL from your definitions. You can switch off the SQL toolset so Claude can't bypass the metrics. More in dbt MCP.

Is a semantic layer the same as a data catalog?

No. A catalog describes what data exists and where; a semantic layer defines how to compute business metrics from it, and tools query through it. An AI assistant benefits from both, but only the semantic layer stops it inventing a metric's formula.

Sources

  1. dbt Labs: dbt Semantic Layer
  2. dbt Labs: Set up remote MCP
  3. dbt Labs: About the dbt MCP server
  4. Snowflake: Cortex Analyst
  5. Snowflake: Snowflake-managed MCP server
  6. Google Cloud: Conversational Analytics in Looker
  7. Microsoft Learn: Copilot for Power BI overview (updated August 2026)
  8. Databricks: Set up a Genie agent
  9. Cube: homepage (checked 22 October 2026)
  10. Omni: homepage (checked 22 October 2026)
  11. Anthropic: Getting started with custom connectors using remote MCP
  12. Jin, Choi, Zhu and Kang: Pervasive Annotation Errors Break Text-to-SQL Benchmarks and Leaderboards (January 2026)

Early access

Count Lineage isn't ready to download yet.

Count Lineage is coming to Claude Desktop in the next few weeks. Leave your work email and we'll send you the download the day it's ready.

Where should Lineage go after Claude? Optional

One email when it's ready. No newsletter.