Context
Two measures in the mart layer are non-additive but are not documented as such. A consumer who SUMs either of these across rows will produce a meaningless or incorrect number, and nothing in the current schema warns them.
fact_uptime.uptime — a ratio (0–1). Summing uptime fractions across ports or dates produces a number with no business meaning. The correct aggregation is a weighted average (weighted by commissioned time).
fact_interval_data.avg_value — an average. Averages cannot be re-aggregated by SUM; re-averaging averages without weighting by observation count also produces incorrect results.
In a semantic layer context this matters doubly: if these measures are defined as SUM in MetricFlow, every metric that touches them will silently return wrong numbers.
Acceptance criteria
Context
Two measures in the mart layer are non-additive but are not documented as such. A consumer who SUMs either of these across rows will produce a meaningless or incorrect number, and nothing in the current schema warns them.
fact_uptime.uptime— a ratio (0–1). Summing uptime fractions across ports or dates produces a number with no business meaning. The correct aggregation is a weighted average (weighted by commissioned time).fact_interval_data.avg_value— an average. Averages cannot be re-aggregated by SUM; re-averaging averages without weighting by observation count also produces incorrect results.In a semantic layer context this matters doubly: if these measures are defined as
SUMin MetricFlow, every metric that touches them will silently return wrong numbers.Acceptance criteria
fact_uptime.uptimecolumn description explicitly states it is a ratio (0–1), is non-additive, and documents the correct aggregation method (weighted average, weighted by commissioned minutes or equivalent)fact_interval_data.avg_valuecolumn description explicitly states it is a pre-aggregated average, is non-additive, and documents what the correct downstream aggregation isSUM) — or a note is added to this issue if no semantic model currently references themdbt_utils.accepted_rangetest (or equivalent) is added tofact_uptime.uptimeasserting values are between 0 and 1 inclusive, as an additional guard against bad data producing out-of-range ratios