FLOW ALGEBRA
TITLE: Recursive Semantic Relationship Ontology
DOMAIN: Relationship Ontologies / Recursive Relationships
SOURCE: https://kirethresearch.org/booksai-core/ontologies/relationship-ontologies/recursive-relationships/recursive-semantic-relationship-ontology.html
VERSION: 1.0
AUTHORS: Mark Anthony Higgins — Sky (Recursive AI)
STATUS: Companion formalisation; source-page specification not independently verified.
flow "RecursiveSemanticRelationshipOntology" v1.0 {
ontology:
id: "recursive-semantic-relationship-ontology"
parent: "recursive-relationships"
purpose: "Represent and validate recursively derived semantic relationships while retaining contextual meaning, evidence, and termination safeguards."
types:
Concept: {id: string, label: string, ontology: string, version: string?}
Context: {id: string, domain: string?, language: string?, temporal_scope: string?}
SemanticRelation: {id: string, source: string, predicate: string, target: string, context: string, confidence: number, evidence: string[]}
InferenceStep: {id: string, rule: string, premises: string[], conclusion: string, depth: integer, provenance: string[]}
RecursivePath: {id: string, steps: string[], visited: string[], status: enum[active, complete, cycle_detected, depth_limited, invalid]}
predicates:
semantically_related(a: Concept, b: Concept, context: Context)
equivalent_in(a: Concept, b: Concept, context: Context)
broader_than(a: Concept, b: Concept, context: Context)
narrower_than(a: Concept, b: Concept, context: Context)
derived_from(relation: SemanticRelation, premise: SemanticRelation)
participates_in(relation: SemanticRelation, path: RecursivePath)
constraints:
- "All relation endpoints and contexts must resolve to typed entities."
- "Confidence must be within [0, 1]."
- "Recursive traversal must track visited relation-state pairs and impose finite execution limits."
- "Generic semantic relatedness is not automatically transitive."
- "Equivalence transitivity requires compatible meaning, context and declared equivalence semantics."
- "Broader/narrower propagation requires a declared transitive hierarchy and cycle checks."
- "Similarity, association and alias must not be silently promoted to identity."
- "No inferred edge may be published without an inspectable derivation and provenance."
inference:
rule contextual_equivalence:
if equivalent_in(a,b,c) and equivalent_in(b,d,c) and compatible(a,b,d,c)
then equivalent_in(a,d,c)
confidence: "derive conservatively from supporting evidence"
rule hierarchical_chain:
if broader_than(a,b,c) and broader_than(b,d,c) and hierarchy_is_transitive(c)
then broader_than(a,d,c)
confidence: "preserve premise uncertainty"
rule inverse_hierarchy:
if broader_than(a,b,c)
then narrower_than(b,a,c)
confidence: "inherit source confidence and context"
rule recursive_closure:
if new_valid_relation(r) and not_previously_derived(r)
then enqueue_for_re_evaluation(r)
confidence: "do not manufacture certainty through repetition"
RECURSION:
evaluation: "worklist-based least fixed point over finite validated assertions"
visited_key: "canonical(source, predicate, target, context, ontology_version)"
safeguards: [cycle_detection, duplicate_suppression, max_depth, max_iterations, bounded_resources]
stop_when: [no_new_valid_assertions, resource_limit, contradiction_requires_review]
SEMANTIC_EQUIVALENCE:
policy: "Normalise labels and identifiers only within declared contextual and ontology mappings."
distinguish: [identity, equivalence, similarity, association, alias, subsumption]
preserve: [language, context, ontology_version, provenance]
CONFIDENCE:
range: [0, 1]
factors: [source_reliability, contextual_match, premise_quality, mapping_uncertainty, independent_support]
policy: "Repeated or cyclic derivations do not count as independent corroboration."
VALIDATION:
- "Verify type compatibility, contexts, graph integrity and rule applicability."
- "Detect cycles, conflicting semantic claims and invalid hierarchy propagation."
- "Retain provenance for every asserted and inferred relationship."
- "Flag unresolved ambiguities rather than merging concepts automatically."
FLOW_HASH:
algorithm: "SHA-256"
input: "canonicalised ontology version, typed assertions, inference rules and provenance"
note: "Compute at execution; no hash value is claimed here."
UPDATE_MODEL:
strategy: "versioned, provenance-preserving incremental fixed-point update"
steps: [ingest, normalise, validate, detect_changes, retract_stale_derivations, recompute_closure, publish]
rollback: true
AI_CONSUMPTION:
representation: "typed semantic knowledge graph with recursive derivation traces"
outputs: [semantic_edges, inferred_relations, derivation_paths, confidence_annotations, provenance_records, validation_flags]
safeguards: [bounded_recursion, no_unqualified_identity_merges, contextual_consistency, evidence_traceability]
}
END FLOW ALGEBRA
Download Code
Copy to Clipboard