Coral 0.2.17 candidate API
    Preparing search index...

    Interface RuleDefinition<T>

    interface RuleDefinition<T> {
        check: (
            context: T,
        ) => readonly {
            causes?: readonly RuleCause[];
            message: string;
            subject?: {
                id: string;
                kind: "graph" | "node" | "edge" | "activation" | "note" | "fragment";
            };
        }[];
        evidenceScope: "graph"
        | "node"
        | "edge";
        id: string;
        minimumLevel: "typical" | "strict";
        provenance: { kind: "standard" | "coral"; reference: string };
        remediation: string;
        severity: NotificationLevel;
        strictSeverity?: NotificationLevel;
    }

    Type Parameters

    • T
    Index
    check: (
        context: T,
    ) => readonly {
        causes?: readonly RuleCause[];
        message: string;
        subject?: {
            id: string;
            kind: "graph" | "node" | "edge" | "activation" | "note" | "fragment";
        };
    }[]
    evidenceScope: "graph" | "node" | "edge"
    id: string
    minimumLevel: "typical" | "strict"
    provenance: { kind: "standard" | "coral"; reference: string }
    remediation: string

    Severity at the minimum level, and at strict when no override is given.

    strictSeverity?: NotificationLevel

    A typical rule may become louder under strict without changing meaning.