Skip to content

Model checks

What happens when a check on my model fails?

Section titled “What happens when a check on my model fails?”

Every night Cortex checks each model. What a failure does depends on the kind of check, and it is the same everywhere. Info: it is shown and nobody is told. Warn: it is shown and the model owners are told. Block: it is shown, the owners are told, and the certified figures it proves lose their badge until a later night passes. A figure that no longer matches its own table is block. A duplicate key or grain on a table (W1, W2) is block and also stops queries on that table. A row count that differs from the source is warn, and IT is told too. A rule on your data is the severity you gave it, warn unless you set it. A night that was skipped, failed to run or could not be checked never changes a badge.

Why did a certified figure lose its badge?

Section titled “Why did a certified figure lose its badge?”

A certified figure loses its badge in Ask, on dashboards and in the MCP answer when its newest nightly check found that it no longer matches the reference derived from its own table. The model owners get one message that morning. The badge comes back by itself after a night on which the figure matches again. A night on which the check was skipped, ran out of time, or could not read the source does not take the badge off and does not give it back: the last night that gave a verdict stands. Open the figure in Models to see the reference, the allowed difference and the last nights.

How do I make a rule on my data checked every night?

Section titled “How do I make a rule on my data checked every night?”

A validation rule describes what a good row looks like, for example “good count is at most the total count”. Every night Cortex counts how many rows break it and how many are unknown because a value is empty; empty values are never counted as broken. A rule has a severity (info, warn or block, warn by default) and an allowed number of rows or share of rows, 0 by default. The check fails only when more rows break the rule than allowed. A rule cannot read a hidden, masked or restricted property. Model owners can ask for the keys of up to 20 breaking rows; they are read at that moment under your own access and never stored. On a model with row security you only see the counts.

When does a model check tell me, and what is a plausibility check?

Section titled “When does a model check tell me, and what is a plausibility check?”

The model owners get one message a morning, and only when something changed overnight: a check turned red or is back to normal. There is no daily message when everything stays the same. The message covers figures that lost their certified badge, rules on your data, record counts against the source and plausibility. A plausibility check has two parts. A certified figure is flagged when its last closed month lies outside the usual range of its previous 8 months, by default the median plus or minus 50 percent. With fewer than 8 months of data it says there is not enough history. A table is flagged when its newest row is older than twice the sync interval of its source, or 2 days when that is unknown. You can change the range per figure and the age per table, or switch the check off. A plausibility check never takes a badge off.