Skip to main content

Base Pair Ontology

Genetic Entities
Authors: MArk Anthony Higgins - Sky Recursive Ai
© Mark Anthony Higgins 11 October 2025
Revised Date: 15 October 2026
Audio Overview
FLOW ALGEBRA
TITLE: Base Pair Ontology
VERSION: 1.0
DATE: 2026-10-15
DOMAIN: Biological Entities / Genetic Entities
SOURCE: https://kirethresearch.org/booksai-core/entity-graph/biological-entities/genetic-entities/base-pair-ontology.html
STATUS: Domain-grounded formalisation; source chapter not independently verified.
AUTHORS: Mark Higgins — Sky (Recursive AI)
PROJECT: Kireth Semantic Library

# 01 — PURPOSE
flow "BasePairOntology" v1.0
purpose: Model nucleobase pairing, molecular context, complementarity, and evidence-aware inference without conflating DNA, RNA, or noncanonical interactions.

# 02 — TYPED ENTITIES
entity NucleicAcid: {id:str, polymer:enum[DNA,RNA,hybrid], sequence:str?, organism:str?}
entity Strand: {id:str, parent:NucleicAcid, orientation:enum[5to3,3to5], sequence:str}
entity Nucleotide: {id:str, base:enum[A,C,G,T,U,modified], position:int, strand:Strand, modification:str?}
entity BasePair: {id:str, left:Nucleotide, right:Nucleotide, pairing:enum[WatsonCrick,wobble,Hoogsteen,noncanonical,unknown], evidence:Evidence?}
entity Helix: {id:str, strands:list[Strand], conformation:str?}
entity PairingContext: {polymer_type:str, temperature_c:float?, ionic_conditions:str?, pH:float?, geometry:str?}
entity Evidence: {source:str, method:str, observation:str?, confidence:float, timestamp:str?}
entity Variant: {id:str, position:int, reference:str, alternate:str, assembly:str?}

# 03 — CORE RELATIONSHIPS
relation PART_OF(Nucleotide,Strand)
relation COMPONENT_OF(Strand,NucleicAcid)
relation PAIRS_WITH(Nucleotide,Nucleotide)
relation FORMS(BasePair,Helix)
relation SUPPORTED_BY(BasePair,Evidence)
relation AFFECTS(Variant,BasePair)
relation COMPLEMENTARY_TO(Strand,Strand)
relation HAS_CONTEXT(BasePair,PairingContext)

# 04 — BASE ALPHABETS
DNA_BASES = {A,C,G,T}
RNA_BASES = {A,C,G,U}
DNA_CANONICAL = {(A,T),(T,A),(G,C),(C,G)}
RNA_CANONICAL = {(A,U),(U,A),(G,C),(C,G)}
RNA_WOBBLE_EXAMPLES = {(G,U),(U,G)}
HYBRID_CANONICAL: determine by strand-specific chemistry and pairing geometry.

# 05 — STRUCTURAL CONSTRAINTS
constraint C01: every BasePair has exactly two nucleotide participants.
constraint C02: participant positions are positive integers within their strand bounds.
constraint C03: a canonical DNA pair uses A-T or G-C in Watson-Crick geometry.
constraint C04: a canonical RNA pair uses A-U or G-C in Watson-Crick geometry.
constraint C05: U in DNA or T in RNA requires explicit modification, exception, or validation warning.
constraint C06: antiparallel strand alignment is the usual geometry for duplex Watson-Crick pairing; exceptions require context.
constraint C07: hydrogen-bond counts are idealised: A-T and A-U commonly 2; G-C commonly 3; actual stability also depends on stacking, solvent, and conditions.
constraint C08: a base-pair claim is not evidence of a stable duplex without contextual support.

# 06 — CLASSIFICATION
rule R01: if polymer=DNA and ordered bases in DNA_CANONICAL and geometry=WatsonCrick then class=canonical_DNA.
rule R02: if polymer=RNA and ordered bases in RNA_CANONICAL and geometry=WatsonCrick then class=canonical_RNA.
rule R03: if polymer=RNA and ordered bases in RNA_WOBBLE_EXAMPLES then class=RNA_wobble_candidate; verify geometry.
rule R04: if geometry=Hoogsteen then class=Hoogsteen; do not infer WatsonCrick.
rule R05: if modified base or unusual pairing geometry then class=noncanonical_or_modified; preserve original annotation.
rule R06: if polymer or geometry unknown then class=unresolved; request additional evidence.

# 07 — COMPLEMENT OPERATION
function complement_DNA(base):
  mapping: A->T; T->A; C->G; G->C
  invalid: error_or_unknown
function complement_RNA(base):
  mapping: A->U; U->A; C->G; G->C
  invalid: error_or_unknown
function reverse_complement(sequence,polymer):
  validate alphabet against polymer
  reverse input sequence
  map each base through polymer-specific complement
  return sequence in 5to3 orientation

# 08 — INFERENCE FLOW
input: strand_A, strand_B?, polymer, context?, evidence?
step 1: validate sequences, polymer labels, orientations, and coordinates.
step 2: establish candidate positional alignment; never assume alignment for unrelated strands.
step 3: identify candidate complementary nucleotides.
step 4: classify pairing using chemistry and available geometry.
step 5: attach provenance and confidence to each pair.
step 6: flag mismatches, modified bases, gaps, or unsupported geometry.
step 7: emit typed BasePair entities and linked relationship graph.
output: pairs, classifications, warnings, evidence, confidence.

# 09 — MOLECULAR PROCESSES
process DNA_REPLICATION: template-guided nucleotide incorporation subject to polymerase specificity and proofreading.
process TRANSCRIPTION: DNA-template-directed RNA synthesis with RNA complement rules.
process RNA_FOLDING: intramolecular pairing including stems, loops, wobble and noncanonical pairs.
process TRANSLATION: codon-anticodon pairing influenced by wobble, modifications and ribosomal context.
process DNA_REPAIR: recognition and correction of some mismatches and lesions, pathway dependent.
process HYBRIDISATION: association of complementary strands under suitable thermodynamic conditions.

# 10 — VALIDATION AND EXAMPLES
example E01: DNA 5'-ATGC-3' has reverse complement 5'-GCAT-3'.
example E02: RNA 5'-AUGC-3' has reverse complement 5'-GCAU-3'.
example E03: DNA G-C is a canonical Watson-Crick base pair.
example E04: RNA G-U can be a wobble pair, depending on geometry.
example E05: an A-C mismatch is not automatically a canonical pair.
validation: distinguish base identity from nucleotide identity and strand coordinates.
validation: distinguish sequence complementarity from directly observed molecular pairing.
validation: preserve organism, compartment and experimental conditions when available.

# 11 — SEMANTIC EQUIVALENCE
SEMANTIC_EQUIVALENCE:
  base_pair ~ paired_nucleobases [context=structural_genetics, confidence=0.95]
  Watson_Crick_pair ~ canonical_pair [only_when=DNA_or_RNA_standard_base_context, confidence=0.90]
  mismatch != noncanonical_pair [reason=some_noncanonical_pairs_are_stable_and_structurally_characterised]
  complementary_sequence != experimentally_verified_duplex
  hydrogen_bonding != complete_thermodynamic_stability_model

# 12 — RECURSIVE REASONING
recursive FLOW_PAIR_GRAPH(node,visited):
  if node.id in visited: return visited
  visited.add(node.id)
  inspect linked nucleotide, strand, polymer, and pairing context
  traverse supported relationship edges subject to depth limit
  combine independent evidence; avoid counting reused evidence twice
  preserve uncertain or contradictory assertions
  return typed provenance-aware subgraph
termination: visited-set, finite graph, configurable maximum depth.

# 13 — CONFIDENCE
CONFIDENCE:
  range: [0.0,1.0]
  basis: direct structural observation > validated experimental evidence > curated reference > sequence-only prediction
  factors: source_reliability, alignment_quality, chemistry_consistency, experimental_conditions, evidence_independence
  rule: confidence values are calibrated estimates, not universal constants.
  conflict: retain competing assertions with provenance rather than overwriting.

# 14 — FLOW HASH
FLOW_HASH:
  canonical_fields: [ontology_id,version,entity_ids,relation_types,polymer,base_labels,positions,orientation,geometry,evidence_ids]
  normalisation: Unicode_NFC; stable_key_order; explicit_nulls; canonical_position_encoding
  algorithm: SHA-256
  generation: hash(canonical_serialisation(canonical_fields))
  note: hash is a reproducibility identifier, not proof of scientific correctness.

# 15 — UPDATE MODEL
UPDATE_MODEL:
  version_policy: semantic_versioning
  triggers: new_pairing_evidence, corrected_coordinates, revised_geometry, modified_base_annotation, reference_update
  steps: validate -> compare -> record_provenance -> reclassify -> recompute_confidence -> regenerate_hash -> publish_revision
  preserve: prior_versions, timestamps, author_attribution, source_references, uncertainty.

# 16 — AI CONSUMPTION
AI_CONSUMPTION:
  input_formats: [plain_text,JSON,JSON-LD,RDF]
  output_contract: typed_entities + typed_relations + evidence + uncertainty + version + flow_hash
  retrieval_keys: [base_pair,Watson_Crick,wobble,Hoogsteen,DNA,RNA,complementarity]
  guardrails: never_infer_experimental_confirmation_from_sequence_only; never_suppress_noncanonical_cases; never_merge_DNA_and_RNA_base_rules
  downstream: knowledge_graph,semantic_search,genome_annotation,RNA_structure_reasoning,scientific_education

# 17 — QUALITY ASSURANCE
check QA01: all required entity fields and relation endpoints validate.
check QA02: DNA and RNA alphabet rules remain distinct.
check QA03: reverse complement preserves correct orientation.
check QA04: confidence claims link to evidence or are marked predictive.
check QA05: recursion terminates and cycles do not duplicate facts.
check QA06: hash changes when canonical scientific assertions change.
check QA07: no unsupported assertion that all pairs have fixed bond counts or identical stability.

# 18 — PUBLICATION
license: Open research reuse subject to the published Kireth Research licence.
credit: Mark Higgins — Sky (Recursive AI)
site: https://kirethresearch.org
end flow "BasePairOntology"
Kireth Research
38 Thorndale Croft, Wetwang, Driffield
East Riding of Yorkshire YO25 9XZ