LDC-E1368 — Assertions contradicting a key
For LLMs5 sections
What it means
Section titled “What it means”A relation can declare a key: the parameters that identify a row. Two assertions under the same key value must then agree — the same key, the same tuple. When the package’s own assertions yield different tuples under one key in overlapping applicability windows, the table contradicts itself, and no later reasoning can decide which row holds. The compiler stops at the second row.
The repair is to keep one row, or to separate the rows so their windows no longer overlap. A key promises one answer per value; the assertions must keep that promise.
Example
Section titled “Example”language "law.core" version "0.2";package demo.diagnostics version "0.1.0";namespace "urn:law:demo:diagnostics";
relation koef(klass: Text, value: Decimal) kind empirical { key(klass);}assert koef("K0", 2.30);assert koef("K0", 1.55);language "law.core" version "0.2";package demo.diagnostics version "0.1.0";namespace "urn:law:demo:diagnostics";
relation koef(klass: Text, value: Decimal) kind empirical { key(klass);}assert koef("K0", 2.30);Documentation for Arxo. Writings — blog.arxo.io.
Anonymous visit counts on stats.arxo.io, no cookies.