dataeval.core.OntologyValidationResult

class dataeval.core.OntologyValidationResult

Structural and naming facts about an Ontology artifact.

Reports the ingredients for judging ontology quality, not a pass/fail verdict. An empty finding collection is the raw “clean” signal, but whether a given finding (e.g. a dangling external ancestor) actually constitutes a failure is contextual policy for a downstream evaluator to decide.

roots

Concept ids with no parents.

Type:

Sequence[str]

leaves

Concept ids with no children (most specific concepts).

Type:

Sequence[str]

isolated

Concept ids with neither parents nor children — disconnected singletons.

Type:

Sequence[str]

external_ancestors

For each concept whose is-a path is truncated, the subset of its ancestor ids that are not defined in the ontology (external references / “floating” ancestors). Empty unless the ontology is a subset of a fuller one.

Type:

Mapping[str, Sequence[str]]

redundant_edges

(parent, child) direct is-a edges that are also implied transitively (parent is reachable from child by another, longer path), so the direct edge is a non-reduced restatement of an existing subsumption.

Type:

Sequence[tuple[str, str]]

ancestor_siblings

(concept, ancestor) pairs where a concept shares a parent with one of its own ancestors — a contradictory placement (the concept is-a the ancestor yet is declared alongside it).

Type:

Sequence[tuple[str, str]]

unary_parents

Concept ids with exactly one child — a single-child link adds depth without discriminating, a candidate redundant intermediate.

Type:

Sequence[str]

label_collisions

Normalized (case-folded) name to the more-than-one concept ids it resolves to over preferred labels and synonyms — the artifact-side cause of reconciliation ambiguous results.

Type:

Mapping[str, Sequence[str]]

nonconforming_labels

Concept id to its label, for labels that do not fully match label_pattern. Always empty when label_pattern is None.

Type:

Mapping[str, str]

depth

Concept id to the length of its longest is-a path from a root. The raw material for depth and depth-imbalance analysis.

Type:

Mapping[str, int]

fan_out

Concept id to its number of direct children. The raw material for breadth and over-broad-parent analysis.

Type:

Mapping[str, int]

parent_count

Concept id to its number of declared parents (multiple-inheritance load).

Type:

Mapping[str, int]