*Continent · 2 territory* ## Summary A specification for how fact values are represented and compared — number facts as intervals closed on whole numbers, boolean/day/enum facts as finite subsets, string facts as everything-except or a finite set — with intersection, emptiness and subset decided exactly, and a changelog entry restating that integer ranges are exact. ## Explanation - In SPEC.md, a number fact's universe is [min, max] (±∞ when absent), integers only if `integer`, represented as an interval with open/closed ends and excluded points or a finite set (==, in); for integer facts > v means >= v+1 and < v means <= v-1. - A number fact's universe is [min, max] (±∞ when absent), integers only if `integer`, represented as an interval with open/closed ends and excluded points or a… - In SPEC.md, a boolean, day or enum fact's universe is the finite value set, represented as a finite subset. - A boolean, day or enum fact's universe is the finite value set, represented as a finite subset. - In SPEC.md, a string fact's universe is all non-empty strings, represented as "everything except" a finite set or a finite set. - A string fact's universe is all non-empty strings, represented as "everything except" a finite set or a finite set. - In SPEC.md, for an integer fact every range is kept closed on whole numbers (> v becomes ≥ ⌊v⌋+1, < v becomes ≤ ⌈v⌉−1), and an integer range is empty when it is inverted or every whole number in it is excluded; a real range with lo < hi is never emptied by finitely many excluded points. - For an integer fact every range is kept closed on whole numbers (> v becomes ≥ ⌊v⌋+1, < v becomes ≤ ⌈v⌉−1), and an integer range is empty when it is inverted o… - In SPEC.md, intersection, emptiness and subset over these representations are exact for every pair of shapes, including an integer range (or a single closed point) inside a finite set, so overlap and coverage are decided exactly. - Intersection, emptiness and subset over these representations are exact for every pair of shapes, including an integer range (or a single closed point) inside… - In robot-domain-rules-CHANGELOG.md, integer ranges are exact: closed on whole numbers, and every-whole-number-excluded is empty. - Integer ranges are exact: closed on whole numbers, and every-whole-number-excluded is empty. - The two definitions give the shape of a universe for finite-valued facts and for string facts, and neither says what happens to a value that falls outside it. - A boolean, day or enum fact's universe is the finite value set, represented as a finite subset. - A string fact's universe is all non-empty strings, represented as "everything except" a finite set or a finite set. ## Threads - How a number fact's universe is shaped: [min, max], integer ranges closed on whole numbers, real ranges open to excluded points. - A number fact's universe is [min, max] (±∞ when absent), integers only if `integer`, represented as an interval with open/closed ends and excluded points or a… - For an integer fact every range is kept closed on whole numbers (> v becomes ≥ ⌊v⌋+1, < v becomes ≤ ⌈v⌉−1), and an integer range is empty when it is inverted o… - How boolean, day, enum and string facts get their universes: finite subsets, or everything-except a finite set. - A boolean, day or enum fact's universe is the finite value set, represented as a finite subset. - A string fact's universe is all non-empty strings, represented as "everything except" a finite set or a finite set. - Exact intersection, emptiness and subset across every pair of shapes. - Intersection, emptiness and subset over these representations are exact for every pair of shapes, including an integer range (or a single closed point) inside… - A changelog entry restating that integer ranges are exact. - Integer ranges are exact: closed on whole numbers, and every-whole-number-excluded is empty. ## Consultant **Where it shows up** — The rules for how a fact's universe is shaped keep coming up: number facts as [min, max] with integer ranges closed on whole numbers, boolean, day and enum facts as finite subsets, string facts as everything-except. **A question to sit with** — When a value falls outside its universe, what should the system do with it — and where would that rule live? **A way forward** — Keep the exactness rule where it is and add one line to SPEC.md saying what happens to a value outside a finite-valued or string universe. ## Territories - [[Bevia/World/Territories/Number fact ranges and exact overlap checks|Number fact ranges and exact overlap checks]] - [[Bevia/World/Territories/Finite and non-empty-string fact universes|Finite and non-empty-string fact universes]]