Skip to content

Set checks and thresholds

Use a set check when a requirement applies to a slice or to the whole eval.

import { rate, tag, wilson } from '@trialkit/core';
const baseline = wilson(222, 240);
export const checks = [
rate({ name: 'no regressions', where: tag('regression') }).atLeast(1),
rate({ name: 'overall', over: 'trials' }).atLeast(Math.floor(baseline.low * 100) / 100),
];
  • Set a threshold from the low bound of a baseline, not one observed rate.
  • over: 'cases' is the default; over: 'trials' needs fixed trials (earlyStop: false).
  • A check over unrun cases is skip, not pass. A check with no covered case is error, and a covered error case makes the check error.

Give checks to describeEval or the definition. The core reference has predicates and result rules.