import type { ParsedDocument } from '../model/parser-utils.js'; import type { CompiledConstraint } from './constraint-eval.js'; /** A rule that could not be loaded, or that conflicts with another rule. */ export interface ConstraintDiagnostic { kind: 'compile-failed' | 'duplicate-id'; ruleId: string; file: string; message: string; } /** * Walk all parsed documents and compile every native constraint def found. * * De-duplication by rule id is legitimate for the SAME rule seen twice: the * same ontology file appears in both the ontology load and the project parse. * Two DIFFERENT rules sharing an id is a defect, and is reported rather than * silently resolved by document order. * * A rule whose predicate fails to compile is skipped and reported. It used to * throw, which took down the entire command: one malformed * `predicateExpression` anywhere in a resolved dependency meant `memo validate` * exited with a stack trace and validated nothing. A broken rule must be loud, * but it must not be fatal — the other rules still have work to do. * * Callers are expected to surface `diagnostics`; a skipped rule that nobody * reports is a silently disabled check, which is worse than a crash. */ export declare function collectNativeConstraints(docs: ParsedDocument[], diagnostics?: ConstraintDiagnostic[]): CompiledConstraint[]; //# sourceMappingURL=constraint-loader.d.ts.map