Using metrics
Once a metric is saved, you can show it on dashboards, use it in scheduled tasks, and ask the Assistant about it.
On a dashboard
From the dashboard editor:
- Open the dashboard for editing.
- Click Add, then Add metric.
- Search for the metric and select it.
The metric is added as a card that shows its value and trend.
From the Metrics page:
- Open the menu on the metric's card and choose Add to dashboard.
- Choose Value for a single-number card or Trend for a line chart of its history.
- Select the dashboard.
A card added either way is linked to the metric and shows Linked in the dashboard editor. It takes its query from the metric each time it loads, so editing the metric updates the card. To keep a card's current data and stop it following the metric, click Detach from metric on the card in the editor.
See Editing a dashboard.
In scheduled tasks
In the scheduled task builder, the Metrics group has two steps:
- Metric Trigger: starts the scheduled task from a metric's latest value.
- Metric Value: reads a metric's latest value into the scheduled task.
See Building a scheduled task.
With the Assistant
When you ask a question in chat, the Assistant receives your workspace's metric definitions: each metric's key, name, description, calculation, filters, measurement type, reporting period, unit, category, and latest value. It is instructed to reuse a matching definition instead of rebuilding the number from raw columns. Asking for a metric by its name helps it pick the right one.
"Show me net revenue for each of the last six months."
A few rules decide which metrics the Assistant sees:
- Only metrics with a compiled definition are included.
- Metrics built on data you cannot access are left out.
- When there are many metrics, the ones whose name, category, or description share words with your question are listed first.
The same definitions are used when the Assistant generates a dashboard and when Qubit writes Insights. When the Assistant generates a dashboard, it can link single-number cards to existing metrics, or create new metrics for them.
Seeing what uses a metric
In the semantic layer, the Used by tab lists each metric with the dashboard cards and scheduled tasks that read it. Check it before you change or delete a metric. See Viewing the data model.