Skip to lesson
Exit
Reliability Analytics & Self-Serve Tooling1 / 3

1 min lesson

The semantic / metric layer

Show why this lesson detail matters. "Without a metric layer, every team writes its own SQL for 'success rate,' and three dashboards disagree by lunch."

Step 1 of 3

The semantic / metric layerdefine once, agree everywhere

Without a metric layer, every team writes its own SQL for "success rate," and three dashboards disagree by lunch. A semantic layer defines each metric once, with its exact filter, denominator and sessionization, so every dashboard, alert and query resolves to the same definition. It kills the "whose number is right" debate that quietly drains trust.

Learn more

Full explanation

Full explanation

A metric defined once in the semantic layer, which every consumer inherits
metric: agent_success_rate
  description: Share of admitted agent runs that reach a success outcome
  source: agent_interactions
  entity: run_id                 # sessionized: one row per logical attempt
  filter: surface = 'agent' AND is_bot = false
  numerator:   count(run_id) where outcome = 'success'
  denominator: count(run_id)     # admitted attempts, includes censored = failure
  dimensions: [model, region, client_version, surface]
  owner: reliability-ds