FLOW ALGEBRA
TITLE: Cell Ontology
VERSION: 4.0
DOMAIN: Biological Entities / Cellular Entities / Cell
SOURCE: https://kirethresearch.org/booksai-core/entity-graph/biological-entities/cellular-entities/cell-ontology-3.html
AUTHORS: Mark Higgins — Sky (Recursive AI)
PROJECT: Kireth Semantic Library
SITE: https://kirethresearch.org
1. PURPOSE
Represent cells as typed biological entities with identity, structure, function, lineage, state, environment, evidence and computable relationships. Distinguish universally applicable constraints from organism- and context-dependent properties.
2. TYPE SYSTEM
TYPE BiologicalEntity
TYPE Cell <: BiologicalEntity
TYPE ProkaryoticCell <: Cell
TYPE EukaryoticCell <: Cell
TYPE ArchaealCell <: ProkaryoticCell
TYPE BacterialCell <: ProkaryoticCell
TYPE SomaticCell <: Cell
TYPE GermlineCell <: Cell
TYPE StemCell <: Cell
TYPE DifferentiatedCell <: Cell
TYPE CellComponent <: BiologicalEntity
TYPE Membrane <: CellComponent
TYPE Cytoplasm <: CellComponent
TYPE Genome <: BiologicalEntity
TYPE Organelle <: CellComponent
TYPE Nucleus <: Organelle
TYPE Mitochondrion <: Organelle
TYPE Chloroplast <: Organelle
TYPE Ribosome <: CellComponent
TYPE Molecule <: BiologicalEntity
TYPE Tissue <: BiologicalEntity
TYPE Organism <: BiologicalEntity
TYPE CellularProcess
TYPE CellCyclePhase
TYPE CellState
TYPE Environment
TYPE Observation
TYPE Evidence
TYPE Provenance
TYPE Confidence
TYPE TimePoint
TYPE Measurement
3. ENTITY SCHEMA
ENTITY Cell c {
id: URI;
taxon: URI?;
cell_type: URI?;
lineage_id: URI?;
parent_cell_id: URI?;
organism_id: URI?;
location: URI?;
membrane_boundary: Boolean;
genetic_material: Set<Genome>;
components: Set<CellComponent>;
processes: Set<CellularProcess>;
state: CellState;
observed_at: TimePoint?;
provenance: Provenance;
confidence: Confidence;
}
4. TYPED RELATIONSHIPS
REL is_a(Cell, BiologicalEntity)
REL subtype_of(Cell, Cell)
REL part_of(Cell, Tissue|Organism)
REL contains(Cell, CellComponent|Molecule)
REL bounded_by(Cell, Membrane)
REL has_genome(Cell, Genome)
REL has_component(Cell, CellComponent)
REL performs(Cell, CellularProcess)
REL participates_in(Cell, CellularProcess)
REL derived_from(Cell, Cell)
REL divides_into(Cell, Cell)
REL differentiates_into(Cell, Cell)
REL communicates_with(Cell, Cell)
REL adjacent_to(Cell, Cell)
REL interacts_with(Cell, Environment)
REL responds_to(Cell, Molecule|Environment)
REL measured_by(Cell, Observation)
REL supported_by(Observation, Evidence)
REL has_state(Cell, CellState)
REL changes_state(CellState, CellState)
5. STRUCTURAL CONSTRAINTS
RULE C1: Cell(c) -> BiologicalEntity(c).
RULE C2: EukaryoticCell(c) -> Cell(c).
RULE C3: ProkaryoticCell(c) -> Cell(c).
RULE C4: Nucleus(n) AND contains(c,n) -> EukaryoticCell(c), provided n is a bona fide membrane-bound nucleus.
RULE C5: ProkaryoticCell(c) -> NOT has_membrane_bound_nucleus(c).
RULE C6: Cell(c) -> has_plasma_membrane(c) AND has_genetic_system(c) AND has_translation_machinery(c), within the domain of recognised extant cellular life.
RULE C7: Mitochondrion(m) AND contains(c,m) -> EukaryoticCell(c), subject to observation validity.
RULE C8: Chloroplast(p) AND contains(c,p) -> EukaryoticCell(c), subject to observation validity.
NOTE: Some eukaryotes lack conventional mitochondria; mitochondria or chloroplasts are not universal cell requirements.
NOTE: Cell walls, motility structures and photosynthetic capability are taxon-dependent.
6. CELLULAR PROCESSES
PROCESS Metabolism: inputs -> transformations -> products + energy_exchange.
PROCESS GeneExpression: genetic_template -> RNA -> functional_product, where applicable.
PROCESS MembraneTransport: substance + membrane + driving_force -> transmembrane_flux.
PROCESS SignalTransduction: stimulus -> receptor_or_sensor -> response.
PROCESS Homeostasis: perturbation -> regulation -> constrained_state.
PROCESS CellDivision: parent_cell -> descendant_cells, with mechanism-specific rules.
PROCESS Differentiation: precursor_cell + signals -> altered_cell_identity.
PROCESS Apoptosis: regulated_death_program -> dismantling, when applicable.
PROCESS Autophagy: cellular_material -> sequestration -> degradation_or_recycling, when applicable.
7. STATE TRANSITIONS
STATE_SET = {quiescent, growing, dividing, differentiating, stressed, senescent, dying, dead}.
TRANSITION growing -> dividing WHEN division_prerequisites_met.
TRANSITION dividing -> growing WHEN daughter_cell_viable.
TRANSITION growing -> quiescent WHEN growth_signals_withdrawn AND relevant_cell_type.
TRANSITION quiescent -> growing WHEN reentry_conditions_met.
TRANSITION growing -> differentiating WHEN differentiation_program_active.
TRANSITION growing -> stressed WHEN perturbation_exceeds_response_threshold.
TRANSITION stressed -> growing WHEN stress_resolved AND viable.
TRANSITION stressed -> dying WHEN irreversible_damage AND death_program_activated.
CONSTRAINT: Not every cell can access every state or transition; applicability is cell-type dependent.
8. QUANTITATIVE MODELS
MODEL cell_population_growth:
dN/dt = (birth_rate - death_rate) * N
DOMAIN: Approximate population-level model under stated rate assumptions.
MODEL membrane_flux_fick:
J = -D * grad(C)
DOMAIN: Passive diffusion approximation; geometry and permeability may require refinement.
MODEL membrane_potential_nernst:
E_ion = (R*T/(z*F)) * ln([ion]_outside/[ion]_inside)
DOMAIN: Single-ion electrochemical equilibrium with specified conventions.
MODEL cell_volume:
V = integral_over_cell dV
DOMAIN: Geometric volume of observed cell boundary.
MODEL cell_mass_balance:
dM_i/dt = sum_j(stoichiometry_ij * reaction_rate_j) + transport_i
DOMAIN: Specified compartment and conserved material accounting.
9. LOGICAL INFERENCE
INFER I1: has_component(c,n) AND Nucleus(n) -> candidate_type(c,EukaryoticCell).
INFER I2: divides_into(parent,child) -> derived_from(child,parent).
INFER I3: derived_from(a,b) AND derived_from(b,c) -> lineage_ancestor(c,a).
INFER I4: performs(c,p) AND CellularProcess(p) -> biologically_active(c,p,observation_time), if direct activity evidence exists.
INFER I5: has_state(c,s1,t1) AND has_state(c,s2,t2) AND t2>t1 -> observed_state_change(c,s1,s2), if observations refer to the same cell.
GUARD: Do not infer cell viability from morphology alone.
GUARD: Do not equate transcriptional similarity with lineage identity.
GUARD: Absence of observation does not establish absence of structure.
10. SEMANTIC_EQUIVALENCE
CANONICAL: Cell
ALIAS: biological cell
RELATED: cellular entity; cell type; cell lineage; cell population
RULE: cell_instance != cell_type.
RULE: cell_instance != cell_population.
RULE: nucleus != nucleoid.
RULE: bacterial_cell != archaeal_cell, despite both being prokaryotic.
EQUIVALENCE(a,b) IF same_referent(a,b) AND compatible_taxon(a,b) AND compatible_temporal_scope(a,b).
SIMILARITY(a,b) MAY depend_on shared_markers, morphology, function, lineage and environment.
11. CONFIDENCE
CONFIDENCE claim := calibrated_score in [0,1].
EVIDENCE_LEVELS = {direct_measurement, validated_assay, curated_database, peer_reviewed_report, model_prediction, unverified_assertion}.
CONFIDENCE_UPDATE(claim,new_evidence) -> recompute using source reliability, independence, assay limitations, temporal relevance and contradictions.
CONSTRAINT: Numerical confidence requires a documented calibration method; evidence levels alone are not probabilities.
CONFLICT_RESOLUTION: preserve conflicting assertions with provenance; do not silently overwrite.
12. PROVENANCE AND TEMPORAL MODEL
PROVENANCE = {source_uri, source_type, author, observation_method, collected_at, reviewed_at, licence, version}.
OBSERVATION = {cell_id, feature, value, unit, uncertainty, timestamp, method, evidence_id}.
TEMPORAL_RULE: A cell's state and measurable properties may change over time.
IDENTITY_RULE: Track division explicitly; descendants are not the same individual cell as their parent.
13. RECURSIVE FLOW
FLOW CELL_REASONING(cell_id, depth, visited):
REQUIRE depth >= 0.
IF cell_id IN visited THEN RETURN cycle_reference(cell_id).
FETCH typed_cell(cell_id), provenance(cell_id), observations(cell_id).
VALIDATE entity_identity, temporal_scope, evidence_quality.
DERIVE supported_classifications_and_relationships.
IF depth > 0 THEN:
FOR each related_cell IN bounded_neighbours(cell_id):
CELL_REASONING(related_cell, depth-1, visited UNION {cell_id}).
RETURN {entities, relationships, inferences, uncertainties, provenance}.
TERMINATION: finite depth and visited-set cycle guard.
14. FLOW_HASH
FLOW_HASH = SHA256(canonical_serialisation({ontology_version, entity_schema, relations, rules, source_identifiers})).
CANONICALISATION: UTF-8; sorted keys; stable identifiers; explicit null policy; versioned hashing procedure.
NOTE: Hash is computed by an implementation, not asserted as a precomputed value here.
15. UPDATE_MODEL
UPDATE_MODEL(input_delta):
validate_schema(input_delta)
attach_provenance(input_delta)
reconcile_entity_identity(input_delta)
preserve_previous_version()
recompute_affected_inferences()
recalculate_confidence_where_supported()
regenerate_FLOW_HASH()
publish_versioned_change_log()
ROLLBACK: Restore previous validated ontology state if consistency checks fail.
16. AI_CONSUMPTION
INPUT: cell records, ontology identifiers, evidence, time context and query.
OUTPUT: typed entities, relation triples, grounded explanations, uncertainty, citations and machine-readable derivations.
CONSUMPTION_RULES:
- Resolve instance versus class before answering.
- Preserve taxonomic and organism context.
- Distinguish observed facts from model-derived hypotheses.
- Carry temporal qualifiers through all claims.
- Reject unsupported universal generalisations.
- Return unknown where evidence is insufficient.
- Avoid invented measurements, citations or confidence values.
17. VALIDATION
TEST V1: Every relation endpoint satisfies its declared type.
TEST V2: Every cell has a stable identifier.
TEST V3: Every inferred claim records its supporting rules and evidence.
TEST V4: Every quantitative model states assumptions and units.
TEST V5: Division lineage is acyclic with respect to biological time.
TEST V6: Conflicting cell-type annotations remain traceable.
TEST V7: Recursive traversal terminates under finite depth.
TEST V8: FLOW_HASH changes when canonical ontology content changes.
18. INTEGRATION
PARENT: Biological Entities -> Cellular Entities.
LINKED_ONTOLOGIES: Cell Membrane; Cytoplasm; Nucleus; Organelle; Genome; Cell Cycle; Cell Signalling; Tissue; Organism; Metabolism.
ALIGNMENT_TARGETS: Cell Ontology (CL), Gene Ontology (GO), OBO Relations Ontology (RO), Uberon, NCBI Taxonomy, where mappings are verified.
END FLOW ALGEBRA
Download Code
Copy to Clipboard