Skip to main content

Exon 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: Exon Ontology
VERSION: 1.0
DATE: 2026-10-15
DOMAIN: Biological Entities / Genetic Entities
SOURCE_PAGE: https://kirethresearch.org/booksai-core/entity-graph/biological-entities/genetic-entities/exon-ontology.html
AUTHORS: Mark Higgins — Sky (Recursive AI)
STATUS: Domain-grounded formalisation; source-page contents not independently verified.

# 01 — PURPOSE
flow "ExonOntology" v1.0
purpose: Model exons as genomic intervals represented in mature RNA transcripts, their context-dependent coding roles, splice relationships, evidence and provenance.

# 02 — TYPES
type GenomeAssembly { accession:str; version:str }
type GenomicInterval { assembly:GenomeAssembly; seq_id:str; start:int; end:int; strand:enum(+,-); coordinate_system:enum(0_based_half_open,1_based_closed) }
type Gene { id:str; organism_taxon:str; locus:GenomicInterval }
type Transcript { id:str; gene_id:str; biotype:str; strand:enum(+,-); exon_ids:list[str] }
type Exon { id:str; interval:GenomicInterval; gene_id:str; transcript_ids:list[str]; evidence_ids:list[str] }
type Intron { id:str; interval:GenomicInterval; transcript_id:str }
type SpliceJunction { id:str; donor:GenomicInterval; acceptor:GenomicInterval; transcript_id:str }
type CodingSequence { transcript_id:str; segments:list[GenomicInterval]; reading_frame:int? }
type UTR { transcript_id:str; region:enum(5_prime,3_prime); segments:list[GenomicInterval] }
type Variant { id:str; interval:GenomicInterval; reference:str; alternate:str }
type Evidence { id:str; method:str; source:str; observed_at:str?; quality:float? }
type Assertion { subject:str; predicate:str; object:str; evidence_ids:list[str]; confidence:float; context:str }

# 03 — ONTOLOGICAL CLASSIFICATION
class Exon <: GenomicFeature
class ConstitutiveExon <: Exon
class AlternativeExon <: Exon
class CassetteExon <: AlternativeExon
class MutuallyExclusiveExon <: AlternativeExon
class FirstExon <: Exon
class InternalExon <: Exon
class LastExon <: Exon
class CodingExonRole <: TranscriptSpecificRole
class NonCodingExonRole <: TranscriptSpecificRole
class RetainedIntronEvent <: AlternativeSplicingEvent

# 04 — RELATIONSHIPS
relation part_of_gene(Exon,Gene)
relation included_in_transcript(Exon,Transcript)
relation precedes_in_transcript(Exon,Exon,Transcript)
relation joined_by_splicing(Exon,Exon,SpliceJunction)
relation separated_by_intron(Exon,Exon,Intron,Transcript)
relation overlaps_cds(Exon,CodingSequence)
relation overlaps_utr(Exon,UTR)
relation overlaps_variant(Exon,Variant)
relation supported_by(Assertion,Evidence)
relation alternative_to(Exon,Exon,Gene)

# 05 — INVARIANTS
invariant interval_valid(e:Exon): e.interval.start < e.interval.end
invariant assembly_defined(e:Exon): e.interval.assembly.accession != ""
invariant coordinates_explicit(e:Exon): e.interval.coordinate_system != null
invariant transcript_membership(e:Exon,t:Transcript): included_in_transcript(e,t) -> e.gene_id == t.gene_id
invariant same_reference(e1:Exon,e2:Exon): genomic_comparison(e1,e2) -> compatible_assembly_and_sequence(e1.interval,e2.interval)
invariant confidence_range(a:Assertion): 0.0 <= a.confidence <= 1.0
invariant strand_order: exon_order_is_transcript_5prime_to_3prime_not_unconditionally_ascending_genomic_coordinates

# 06 — CLASSIFICATION RULES
rule constitutive(e,g,transcripts):
  if transcripts are a defined, sufficiently complete isoform set for g
  and forall t in transcripts: included_in_transcript(e,t)
  then classify(e,ConstitutiveExon,context=transcripts)
rule cassette(e,isoforms):
  if observed_isoform_includes(e) and observed_isoform_skips(e)
  and flanking_junctions_support_skipping(e)
  then classify(e,CassetteExon,context=isoforms)
rule coding_role(e,t):
  if included_in_transcript(e,t) and overlap(e.interval,cds_segments(t)) > 0
  then assign_role(e,t,CodingExonRole)
rule noncoding_role(e,t):
  if included_in_transcript(e,t) and overlap(e.interval,cds_segments(t)) == 0
  then assign_role(e,t,NonCodingExonRole)
rule transcript_position(e,t):
  if index(e,t.exon_ids) == 0 then assign_role(e,t,FirstExon)
  if index(e,t.exon_ids) == length(t.exon_ids)-1 then assign_role(e,t,LastExon)
  if 0 < index(e,t.exon_ids) < length(t.exon_ids)-1 then assign_role(e,t,InternalExon)

# 07 — EXON / INTRON PROCESS FLOW
flow transcription_and_splicing:
  DNA_gene -> primary_RNA_transcript
  primary_RNA_transcript -> splice_site_recognition
  splice_site_recognition -> spliceosome_assembly [when spliceosomal introns]
  spliceosome_assembly -> intron_excision
  intron_excision -> exon_ligation
  exon_ligation -> processed_transcript
  processed_transcript -> mature_RNA [after relevant maturation steps]
  note: not all transcripts are spliced; some introns use other splicing mechanisms

# 08 — ALTERNATIVE SPLICING FLOW
flow isoform_generation:
  gene -> pre_mRNA
  pre_mRNA -> splice_decision(context=cell_type,development,regulators)
  splice_decision -> exon_inclusion | exon_skipping | alternative_5prime_site | alternative_3prime_site | intron_retention
  splice_decision -> transcript_isoform
  transcript_isoform -> potential_changes_in_CDS_UTR_stability_localisation_or_translation
  note: effect is conditional, not guaranteed

# 09 — SEQUENCE AND COORDINATE OPERATIONS
function exon_length(e):
  if e.interval.coordinate_system == 0_based_half_open: return end-start
  if e.interval.coordinate_system == 1_based_closed: return end-start+1
function overlap(a,b):
  require same_assembly_sequence_and_coordinate_convention(a,b)
  return max(0,min(a.end,b.end)-max(a.start,b.start)) [0_based_half_open]
function transcript_exonic_length(t):
  return sum(exon_length(exon_id) for exon_id in t.exon_ids)
function exon_sequence(e):
  seq = reference_subsequence(e.interval)
  return reverse_complement(seq) if e.interval.strand == '-' else seq
function mature_transcript_sequence(t):
  return concatenate(exon_sequence(e) for e in transcript_order(t.exon_ids))

# 10 — VARIANTS AND EFFECTS
rule splice_site_variant(v,t):
  if overlaps_annotated_splice_donor_or_acceptor(v,t)
  then propose_effect(v,"splice_site_disruption",requires_validation=true)
rule exonic_variant(v,e,t):
  if overlaps(v,e) then assess_context(v,e,t,CDS,UTR,splice_motifs)
rule consequence_uncertainty:
  predicted_splicing_change != experimentally_confirmed_splicing_change
  predicted_protein_change != demonstrated_phenotypic_effect

# 11 — RECURSIVE REASONING
flow recursive_exon_resolution(e,depth,max_depth,visited):
  if depth >= max_depth or e.id in visited: return stop
  visited.add(e.id)
  resolve_gene(e.gene_id)
  for each t in transcripts_containing(e):
    validate_transcript_context(t)
    resolve_adjacent_exons_and_junctions(e,t)
    resolve_coding_or_noncoding_role(e,t)
    collect_evidence(e,t)
  return aggregate_contextual_assertions(e)

# 12 — CONFIDENCE
CONFIDENCE:
  range: [0.0,1.0]
  evidence_factors: [reference_quality,read_support,junction_support,annotation_agreement,experimental_validation]
  calibration: empirical_by_assay_and_organism
  aggregation: avoid_double_counting_correlated_sources
  unknown: null_not_zero
  reporting: preserve_evidence_and_uncertainty

# 13 — SEMANTIC_EQUIVALENCE
SEMANTIC_EQUIVALENCE:
  exact_exon_identity: same_reference_assembly_and_interval_and_strand_and_definition
  transcript_exon_identity: additionally_same_transcript_context
  alias_match: gene_or_exon_names_are_not_sufficient_for_identity
  coordinate_liftover: requires_verified_mapping_and_uncertainty
  overlap: related_not_equivalent
  coding_exon: role_specific_to_transcript
  first_exon: role_specific_to_transcript

# 14 — FLOW_HASH
FLOW_HASH:
  canonicalisation: stable_UTF8_serialisation_sorted_keys_explicit_nulls
  inputs: [flow_name,version,entity_types,relations,rules,source_version]
  algorithm: SHA-256
  output: lowercase_hex_digest
  note: computed_by_implementation_not_a_preassigned_value

# 15 — UPDATE_MODEL
UPDATE_MODEL:
  triggers: [assembly_update,annotation_revision,new_isoform,new_splice_evidence,variant_reinterpretation]
  operations: [validate,version,compare,retain_provenance,recompute_dependencies,rehash]
  identity_policy: never_silently_merge_distinct_assembly_coordinates
  rollback: retain_previous_versions
  conflict_policy: preserve_competing_evidence_and_flag_review

# 16 — AI_CONSUMPTION
AI_CONSUMPTION:
  representation: typed_graph_with_contextual_assertions
  retrieval_keys: [gene_id,transcript_id,exon_id,assembly,interval,organism]
  outputs: [classification,relationships,splicing_paths,sequence_context,variant_hypotheses,evidence,confidence]
  safeguards: [no_unverified_clinical_claims,no_cross_assembly_assumptions,no_isoform_collapsing]
  machine_readable: true
  human_auditable: true

# 17 — VALIDATION TESTS
test exon_coordinate_validation: reject(start >= end) [0_based_half_open]
test negative_strand_order: transcript_order != ascending_genomic_order_by_default
test same_exon_different_isoforms: roles_may_differ
 test coding_overlap: CDS_overlap_requires_transcript_context
 test evidence_trace: every_derived_assertion_retains_provenance
 test hash_determinism: identical_canonical_inputs_produce_identical_hash
 test no_false_equivalence: overlapping_exons_not_necessarily_identical

# 18 — LIMITATIONS
limitations:
  - Exon boundaries and membership depend on annotation version and transcript evidence.
  - Exons are retained in mature RNA; they are not necessarily protein-coding.
  - Alternative promoters and polyadenylation can alter exon composition.
  - Species, organelle and viral transcript processing mechanisms differ.
  - Splicing predictions require validation before clinical interpretation.

# 19 — PROVENANCE AND LICENCE
provenance:
  page: https://kirethresearch.org/booksai-core/entity-graph/biological-entities/genetic-entities/exon-ontology.html
  preparation: independently drafted from established biological concepts
  verification: source chapter not independently checked
  attribution: Mark Higgins — Sky (Recursive AI)
  project: Kireth Semantic Library
  website: https://kirethresearch.org
END FLOW ALGEBRA
Kireth Research
38 Thorndale Croft, Wetwang, Driffield
East Riding of Yorkshire YO25 9XZ