FLOW ALGEBRA
TITLE: Recursive Relationship Ontology
DOMAIN: Relationship Ontologies / Recursive Relationships
SOURCE: https://kirethresearch.org/booksai-core/ontologies/relationship-ontologies/recursive-relationships/recursive-relationship-ontology-2.html
VERSION: 1.0
AUTHORS: Mark Anthony Higgins — Sky (Recursive AI)
STATUS: Companion formalisation; source-page specification not independently verified.
flow "RecursiveRelationshipOntology" v1.0 {
ontology:
id: "recursive-relationship-ontology-2"
parent: "recursive-relationships"
purpose: "Represent self-referential and mutually recursive entity relationships with explicit base cases, evaluation semantics and traceable inference."
types:
Entity: {id: string, kind: string, domain: string?}
RecursiveRule: {id: string, head: string, body: string[], base_case: bool, monotonic: bool, provenance: string}
RelationAssertion: {id: string, subject: string, predicate: string, object: string, confidence: number, evidence: string[]}
Evaluation: {id: string, strategy: enum[least_fixed_point, bounded_unfolding, well_founded], iteration_limit: int?, status: enum[pending, converged, bounded, failed]}
DependencyEdge: {from_rule: string, to_rule: string, polarity: enum[positive, negative]}
predicates:
refers_to(a: Entity, b: Entity)
depends_on(a: Entity, b: Entity)
recursively_related_to(a: Entity, b: Entity)
derives(rule: RecursiveRule, assertion: RelationAssertion)
participates_in_cycle(rule: RecursiveRule, cycle_id: string)
constraints:
- "All rule references and assertion endpoints resolve to declared entities or predicates."
- "Confidence lies within [0, 1]; evidence and provenance remain attached to derived assertions."
- "A recursive rule requires explicit base-case facts or a documented fixed-point semantics."
- "Do not assume every dependency is transitive or every cycle is erroneous."
- "For least-fixed-point evaluation, recursion must be monotonic over a finite or otherwise convergent domain."
- "Negation cycles require a defined non-classical semantics or must be rejected."
- "A bounded iteration result is not labelled complete unless convergence is established."
inference:
rule recursive_closure:
if recursively_related_to(a,b) and recursively_related_to(b,c) and transitive_relation_context(a,b,c)
then recursively_related_to(a,c)
confidence: "retain weakest supported evidence; avoid artificial certainty"
rule base_case_seed:
if valid_base_case(rule, assertion)
then derives(rule, assertion)
confidence: "source-evidence dependent"
rule fixed_point:
if monotonic_ruleset(rules) and iteration_stabilises(rules, facts)
then converged_least_fixed_point(rules, facts)
confidence: "proof and evaluation trace required"
SEMANTIC_EQUIVALENCE:
- "Distinguish recursive dependency, ordinary association, and identity."
- "Normalise relation aliases without conflating direct and transitive relationships."
- "Preserve scope, rule semantics, and version during alignment."
CONFIDENCE:
range: [0,1]
factors: [evidence_quality, rule_validity, inference_depth, completeness, source_reliability]
policy: "Repeated cycles do not independently corroborate a claim or increase confidence."
VALIDATION:
- "Check typing, reference integrity, rule safety, stratification and termination assumptions."
- "Detect strongly connected components and classify intentional versus unsupported recursion."
- "Verify base cases, convergence, provenance and derivation traces."
- "Flag non-monotonic recursion and unresolved contradictory assertions."
FLOW_HASH:
algorithm: "SHA-256"
input: "canonicalised ontology version, rules, typed assertions, evaluation semantics and provenance"
note: "Compute hash at execution; no hash value is claimed here."
UPDATE_MODEL:
strategy: "versioned incremental fixed-point recomputation"
steps: [ingest, normalise, validate, identify_affected_cycles, retract_stale_derivations, recompute, verify, publish]
rollback: true
AI_CONSUMPTION:
representation: "typed recursive knowledge graph with explicit rule provenance"
outputs: [recursive_edges, dependency_graph, fixed_point_status, derivation_traces, uncertainty_annotations]
safeguards: [bounded_execution, no_unsupported_transitivity, no_cycle_based_confidence_inflation, preserve_provenance]
}
END FLOW ALGEBRA
Download Code
Copy to Clipboard