Expand description
Stable RDFS/OWL reasoning and schema-coherence API.
Structs§
- Inconsistency
- One detected incoherent point (a logical contradiction in the graph).
- Reasoning
- The result of reasoning over a base graph.
Constants§
- REASON_
RULESET - Version tag of this reasoner’s rule set. Stamped into a baked coherence card so
a
coherent: truecan never be misread as a guarantee from a different set of rules. Bump this whenevermaterialize/detect_inconsistencieschanges (a rule added/removed/altered), sorete reason --verify-cardrejects a stale stamp.
Functions§
- eval_
query_ reasoned - Like
eval_query, but with OWL 2 QL entailment on: the lowered plan is rewritten by the internal QL lowering pass so the answer includes ontology-entailed solutions (Stage 1a:rdfs:subClassOf), computed over the raw data with no materialization. Opt-in — a plaineval_queryis byte-identical to before. - eval_
sparql_ reasoned - Like
eval_sparql, but with OWL 2 QL entailment on (seeeval_query_reasoned). - read_
schema_ coherence_ ranged - Dictionary-free Tier-0 coherence read. Fetch only the header and the
pyramid-meta range (2 small range reads) and run
schema_coherenceover the schema pyramid — never touching the dictionary (which a literal-heavy file makes large) or the triple index.Ok(None)if the file ships no pyramid. - reason
- Forward-chain the supported RDFS/OWL rules to a fixpoint, then scan for
inconsistencies over the closed graph.
inferredexcludes triples already present inbase_triples. - schema_
coherence - Compute T-Box coherence points from the schema-pyramid fields alone — no
dictionary, no index, no instance data. Shared by
SummaryView::tbox_coherenceand the dictionary-freeread_schema_coherence_ranged. Emitssubclass-cycleandunsatisfiable-class(a class whose ancestor closure — over all parents, folded throughowl:equivalentClass— contains both ends of a disjoint pair). - schema_
summary - An ontology-aware coarse graph: instead of structural communities, group
entities by their
rdf:typeclass and aggregate relations between classes. Returns(subject_class, predicate, object_class, count)over the default graph. Entities with no type are(untyped); literals are(literal).rdf:typetriples themselves define the classes and are not counted as relations. This is the dataset’s effective schema with instance volumes.
Type Aliases§
- Term
Triple - A resolved triple as terms.