BOL — Technical White Paper  |  DREL Solutions
BEGINNING OF LIFE SIMULATOR
Technical Design White Paper
Comprehensive System Specification & Scientific Reference

Abstract. This white paper presents the complete design specification for BOL (Beginning of Life), a computational platform that simulates the transition from prebiotic chemistry to self-replicating protocells. BOL implements a stochastic, spatially-resolved 3D chemistry engine with 27 abiotic reaction rules operating on 26 molecular species across four geologically plausible origin-of-life scenarios. The platform models amphiphilic self-assembly into vesicles with fitness-driven selection, template-directed RNA replication with error-prone fidelity, and energy coupling from thermal, redox, photochemical, and electrical sources. This document provides an exhaustive technical reference covering the scientific foundations, algorithmic implementations, data model, 50-endpoint REST API, security architecture, and deployment topology.

Version 1.0.0
March 2026
Classification: Public

Prepared by DREL Solutions

Contents

  1. Executive Summary
  2. Scientific Foundations
  3. System Architecture
  4. The 3D World Model
  5. Energy System
  6. Prebiotic Chemistry Engine
  7. Self-Assembly Engine
  8. Replication Engine
  9. Simulation Orchestrator
  10. Metrics & Complexity Scoring
  11. Configuration System
  12. Parameter Sweep Engine
  13. AI Analysis Laboratory
  14. Data Model
  15. Web Application
  16. Security Architecture
  17. Deployment & Operations
  18. Design Principles & Non-Functional Requirements
  19. Prompt-Driven Development
  20. Glossary
  21. References

1. Executive Summary

BOL (Beginning of Life) is a computational research platform that simulates the chemical and physical processes hypothesised to have driven the emergence of life on early Earth, approximately 3.8–4.1 billion years ago. The simulator operates as a self-contained Python application with a web-based dashboard, providing researchers and students with an interactive laboratory for exploring origin-of-life chemistry.

The platform models a three-dimensional hydrothermal environment where simple inorganic molecules (CO2, H2, NH3, H2S) undergo 27 abiotic reaction pathways to produce increasingly complex organic molecules—amino acids, nucleotides, sugars, and lipids. These building blocks spontaneously self-assemble into membrane-bound vesicles (protocells), within which RNA templates replicate with error-prone fidelity, driving Darwinian selection at the molecular level.

Key capabilities include:

The system is designed for portability (pure Python + NumPy), security (PBKDF2 authentication, CSP headers, rate limiting), and scientific transparency (all reactions grounded in published literature).

2. Scientific Foundations

2.1 The Origin-of-Life Problem

The origin of life remains one of the deepest unsolved problems in science. The transition from geochemistry to biochemistry required the emergence of three capabilities that define all known life: (1) metabolism—the ability to harvest energy and catalyse chemical reactions; (2) compartmentalisation—membrane boundaries that create distinct chemical environments; and (3) replication—the capacity to copy information with heritable variation.

BOL models all three pillars simultaneously in a unified simulation, allowing researchers to observe whether and how they emerge from simple starting conditions.

2.2 Four Leading Hypotheses

The simulator supports four prebiotic scenarios, each representing a major scientific hypothesis. No single hypothesis is privileged; users select the starting conditions and observe the outcomes.

HypothesisKey ProponentsCore MechanismEnvironment
RNA World Gilbert (1986), Joyce, Szostak RNA as both information carrier and catalyst (ribozymes) preceded DNA/protein life. Self-replicating RNA molecules drive early evolution. Shallow ponds with UV exposure; warm temperatures favour ribozyme activity.
Iron-Sulfur World Wächtershäuser (1988) Metabolism-first: exergonic FeS/pyrite reactions on mineral surfaces drive carbon fixation and organic synthesis before genetic molecules appear. Deep-sea volcanic vents with abundant iron sulfide and high mineral density.
Alkaline Hydrothermal Vent Russell (1994), Martin Natural proton gradients (pH 6–11) across iron-sulfide membranes in serpentinite-hosted vents provide free energy for carbon fixation. Off-axis alkaline vents with steep thermal and pH gradients; moderate mineral content.
Warm Little Pond Damer & Deamer (2015) Wet–dry cycling in terrestrial hot springs concentrates organics, promoting amphiphilic assembly and polymer synthesis during dehydration. Shallow surface pools with UV radiation; warm surface temperatures.

2.3 Computational Approach

BOL adopts a coarse-grained stochastic particle approach, intermediate between molecular dynamics (which tracks individual atoms) and systems-biology ODE models (which track concentrations). Each molecule is an object with aggregate physicochemical properties—type, mass, charge, hydrophobicity, sequence—moving through a continuous 3D volume. Reactions fire probabilistically based on proximity, thermodynamic feasibility, and local environmental conditions.

This design choice makes the simulation tractable (thousands of molecules in real time) while preserving spatial realism (concentration gradients, compartmentalisation, surface catalysis). Emergent behaviours—self-assembly, autocatalytic cycles, heritable selection—arise from the rules rather than being programmed explicitly.

3. System Architecture

3.1 Module Map

The application is organised into 11 Python modules plus a web layer. Module dependencies flow downward; no circular imports exist.

ModuleResponsibilityKey Classes / FunctionsDependencies
config.pyConfiguration managementConfig dataclass (~30 parameters)None
world.py3D environment & spatial hashingWorld — hash grid, gradient fieldsNumPy
energy.pyEnergy sources & couplingEnergySystem — 4 energy sourcesNumPy, World
chemistry.pyPrebiotic chemistry engineChemistryEngine, Molecule, 27 ReactionRulesNumPy, Config
assembly.pySelf-assembly engineAssemblyEngine, Vesicle, MicelleNumPy, World
replication.pyRNA replicationReplicationEngine — copy, mutate, recombineConfig
simulation.pyOrchestrator / main loopSimulation — step pipelineAll core modules
metrics.pyScoring & data exportMetrics — 24 per-step metrics + complexity scoreNumPy
sweep.pyBatch experimentationScenario, single-param, 2D grid sweepsSimulation, Config
visualization.pyDesktop 3D renderingVispy 0.16.1 GPU-rendered particle scatterVispy
ai.pyAnalysis laboratory27 analysis functions across 8 modulesAll core modules
web/server.pyWeb dashboard & REST APIFlask 3.x with 50 API endpointsFlask, all core

3.2 Simulation Step Pipeline

Each simulation tick executes a strict 7-phase pipeline. The ordering is critical: feedstock must be injected before chemistry can consume it; assembly must run after chemistry so that new products are available for encapsulation; replication runs last because it operates on assembled structures.

Phase 1: Feedstock Injection ─── spawn vent gases at bottom 15% of world │ Phase 2: Energy Update ──────── advance lightning state, recompute fields │ Phase 3: Brownian Diffusion ─── temperature-scaled random walks + periodic wrap │ Phase 4: Ocean Loss ─────────── molecules above 80% height may be removed │ Phase 5: Chemistry ──────────── sample encounters via spatial hash → fire reactions │ Phase 6: Self-Assembly ──────── micelle formation → promotion → growth → division │ Phase 7: Replication ────────── mineral-surface + vesicle-interior RNA copying │ └── Metrics Collection ──── 24 measurements + complexity score

3.3 Threading & Concurrency Model

The simulation runs in a background thread while the Flask web server handles HTTP requests on the main thread. Three threading locks protect shared state:

API endpoints acquire the simulation lock for read access, ensuring consistent snapshots are returned to the browser. The simulation thread acquires the lock at step boundaries to prevent mid-step reads.

3.4 Deployment Topology

Production Deployment
Browser
(PWA)
HTTPS
port 443
Nginx
Reverse Proxy
HTTP
port 5000
Flask + Sim
Gunicorn WSGI
CDN Assets: Chart.js • Three.js • Font Awesome 6
Infrastructure
GCP e2-small · Ubuntu 24.04 · systemd
SSL & Workers
Let’s Encrypt · Gunicorn: 3 workers · 120s timeout
Firewall
ufw — ports 22 (SSH), 80→443 (redirect), 443 (HTTPS)

4. The 3D World Model

The simulation world is a continuous three-dimensional volume (default 20×20×20 units) representing a cross-section of a hydrothermal vent environment. The vertical axis (Y) maps to depth: Y=0 is the vent floor (hot, alkaline, mineral-rich) and Y=20 is the ocean surface (cold, neutral, mineral-poor).

4.1 Spatial Hashing

Efficient neighbour lookups are critical for reaction sampling. BOL uses a uniform spatial hash grid with cell size equal to the reaction radius (default 3.0 units). Each molecule is assigned to a cell based on its position, and neighbour queries return all particles in the same cell plus the 26 surrounding cells (3×3×3 neighbourhood).

Performance. Spatial hashing provides O(1) neighbour lookups regardless of particle count, a critical advantage over brute-force O(n²) distance calculations. With cell_size = 3.0 and world_size = 20, the grid has approximately 6×6×6 = 216 cells.

The hash grid is rebuilt from scratch at the start of each chemistry step via World.clear() and World.insert(id, pos). This approach is simpler and more cache-friendly than incremental updates, given that all molecules move each tick.

4.2 Environmental Gradients

Three spatially varying fields are pre-computed on a coarse 10×10×10 grid and queried via trilinear index lookup:

FieldDistributionFormulaPhysical Basis
Temperature Linear gradient, top to bottom T(y) = T_max − (T_max − T_min) × (y / height) Hydrothermal vent floor at ~400 K; ocean surface at ~275 K
pH Linear gradient, top to bottom pH(y) = pH_max − (pH_max − pH_min) × (y / height) Alkaline vent fluid (pH 11) mixing with acidic ocean water (pH 6)
Mineral density Concentrated at bottom, zero above 2/3 height M(y) = max(0, 1.0 − frac_y × 1.5) Iron sulfide, pyrite, and clay minerals concentrated near vent chimney

4.3 Periodic Boundary Conditions

Horizontal boundaries (X, Z) use periodic wrapping: molecules exiting the right edge reappear on the left. This simulates an effectively infinite ocean floor without edge effects. Vertical boundaries (Y) are also periodic but are coupled with ocean loss at the top to simulate dilution into the open ocean.

pos_wrapped = pos mod world_size

5. Energy System

The EnergySystem module models four geologically plausible energy sources available on early Earth. Energy availability is spatially localised: thermal energy is strongest near the vent, UV penetrates only the top 25% of the water column, and lightning strikes are rare stochastic events. The total energy available at any position is queried during reaction evaluation to determine whether endergonic reactions can proceed.

5.1 Thermal Gradients

Thermal energy is derived from the temperature field. Higher temperatures near the vent floor provide continuous energy for mineral-surface catalysis.

E_thermal(pos) = max(0, (T(pos) − 300) / 150)

At a vent temperature of 400 K, thermal energy ≈ 0.67. At ambient ocean temperature (275 K), thermal energy is zero. This models the thermodynamic reality that vent-associated reactions benefit from elevated temperatures.

5.2 Redox Chemistry

Redox energy is proportional to local mineral density, modelling the electron transfer capacity of iron-sulfide (FeS) and pyrite (FeS2) surfaces near the vent.

E_redox(pos) = mineral_density(pos) × 0.5

Maximum redox energy of 0.5 occurs at the vent floor; it drops to zero above the mineral-bearing zone.

5.3 UV Radiation

Ultraviolet radiation follows Beer–Lambert attenuation from the ocean surface. UV provides energy for photochemical reactions (water photolysis, HCN polymerisation) but only penetrates the top fraction of the water column.

E_UV(pos) = 0.5 × exp(−depth_from_top / penetration_depth)

Where penetration_depth = world_height × uv_depth_frac (default 25%). UV energy is zero below 3× the penetration depth. This must be explicitly enabled in the scenario configuration (uv_radiation: true), as it is not present in deep-sea vent scenarios.

5.4 Lightning Discharge

Lightning strikes are modelled as rare stochastic events with spatial and temporal extent:

E_lightning(pos) = 0.8 × proximity × (remaining_steps / duration)

Lightning provides high-energy input for Miller–Urey type reactions (amino acid synthesis from CH4 + NH3) and HCN synthesis from N2 + CH4. The brief, intense energy bursts model the atmospheric electrical discharges hypothesised by Miller and Urey (1953) as a driver of prebiotic synthesis.

6. Prebiotic Chemistry Engine

The chemistry engine is the heart of BOL. It implements 27 abiotic reaction rules operating on 26 molecular species, with reaction probabilities governed by thermodynamics, local environment, and catalytic context. The engine uses encounter-based stochastic sampling rather than concentration-based kinetics, preserving spatial resolution.

6.1 Molecular Species Catalogue

BOL tracks 26 distinct molecule types, ranging from simple inorganic gases to complex biopolymers. Each type is defined by a template specifying mass, charge, hydrophobicity, and amphiphilicity.

TypeMassChargeHydrophobicityAmphiphilicCategory
water0.30.00.0Solvent
CO20.70.00.1C1 feedstock
CO0.50.00.1C1 intermediate
H20.030.00.0Reductant
NH30.30.00.0N source
HCN0.40.00.1N intermediate
H2S0.50.00.1S source
CH40.30.00.3C1 feedstock
N20.50.00.0Atmospheric
phosphate1.5−2.00.0Backbone group
iron_sulfide2.00.00.2Mineral catalyst
formaldehyde0.50.00.05C1 intermediate
glycolaldehyde1.00.00.05C2 sugar
pyruvate1.4−1.00.1Metabolic intermediate
acetyl_thioester1.60.00.3Activated intermediate
simple_sugar2.80.00.0Carbohydrate
ribose2.40.00.0Nucleotide backbone
amino_acid1.80.00.3Protein precursor
nucleobase1.80.00.2RNA precursor
nucleotide2.5−1.00.1RNA monomer
fatty_acid3.50.00.9YesMembrane amphiphile
glycerol1.50.00.0Lipid backbone
lipid4.00.00.8YesMembrane amphiphile
peptide5.00.00.3Protein polymer
rna_strand8.0−3.00.1Information polymer
Amphiphilic molecules (fatty_acid and lipid) have both hydrophilic and hydrophobic regions, enabling spontaneous self-assembly into bilayer membranes—the precursors to cell membranes.

6.2 The 27 Reaction Rules

Each reaction is defined by a ReactionRule specifying reactants, products, thermodynamic barrier (ΔG in kJ/mol), base rate, and environmental requirements. Reactions are grouped into seven categories reflecting the major synthetic pathways of prebiotic chemistry.

C1 Fixation & Small Molecules

#ReactionEquationΔGRateRequirements
1CO2 reductionCO2 + H2 → CO + H2O−200.25Mineral surface
2CO reductionCO + H2 → HCHO−120.20Mineral surface

Formose & Sugar Chemistry

#ReactionEquationΔGRateRequirements
3Formose step2 HCHO → glycolaldehyde−80.20
4Sugar synthesisglycolaldehyde + HCHO → simple sugar−100.18
5Ribose formation2 glycolaldehyde → ribose−60.12Mineral surface

Nitrogen & HCN Chemistry

#ReactionEquationΔGRateRequirements
6HCN synthesisNH3 + CO → HCN−150.22Energy source
7Nucleobase from HCN2 HCN → nucleobase−50.15
8Strecker amino acidHCN + HCHO → amino acid−180.20
9Amino acid from sugarNH3 + simple sugar → amino acid−150.15Energy source

Metabolic Intermediates

#ReactionEquationΔGRateRequirements
10Pyruvate synthesisCO2 + glycolaldehyde → pyruvate−100.15Mineral surface
11Thioester formationpyruvate + H2S → acetyl thioester−120.18Mineral surface

Macromolecule Assembly

#ReactionEquationΔGRateRequirements
12Nucleotide assemblynucleobase + ribose → nucleotide−60.20Mineral surface
13Peptide bond2 amino acids → peptide+100.20Energy + Mineral
14Peptide elongationpeptide + amino acid → peptide+80.25Energy + Mineral
15RNA polymerisation2 nucleotides → RNA strand+120.20Mineral + Energy
16RNA elongationRNA strand + nucleotide → RNA strand+100.25Mineral + Energy

Lipid & Membrane Chemistry

#ReactionEquationΔGRateRequirements
17Fatty acid synthesis2 acetyl thioester → fatty acid−80.18
18Lipid assemblyfatty acid + glycerol → lipid−50.22
19Glycerol from sugarsimple sugar + H2 → glycerol−100.18
20Lipid from sugars2 simple sugar → lipid−50.10

Photochemistry & Discharge Reactions

#ReactionEquationΔGRateRequirements
21UV water photolysis2 H2O → 2 H2+2370.10UV radiation
22UV HCN polymerisation2 HCN → nucleobase−50.25UV radiation
23UV formaldehydeCO2 + H2 → HCHO+50.20UV radiation
24Discharge amino acidCH4 + NH3 → amino acid−100.30Energy (lightning)
25Discharge HCNN2 + CH4 → 2 HCN+150.25Energy (lightning)
Endergonic reactions (positive ΔG) require energy coupling to proceed. The thermodynamic gating algorithm (Section 6.5) determines whether sufficient driving force is available from the four energy sources.

6.3 Reaction Algorithm

The chemistry step follows an encounter-based sampling approach rather than deterministic mass-action kinetics. This preserves spatial locality—only molecules that are physically near each other can react.

Encounter Sampling

  1. Build spatial hash — Insert all alive molecules into the grid.
  2. Compute encounter budgetmax_encounters = min(n_reactive × 5, 5000).
  3. For each encounter:
    1. Select a random alive, reactive molecule m1.
    2. Pick a random neighbouring cell from the 27-cell neighbourhood.
    3. Pick a random molecule m2 from that cell.
    4. Check the pre-computed _type_partners dictionary to see if any reaction exists for the pair (m1.type, m2.type).
    5. Verify distance ≤ reaction_radius.
    6. For 2-body reactions: attempt _evaluate_and_fire(rule, [m1, m2]).
    7. For 3-body reactions: search m2’s neighbours for a matching third reactant.

6.4 Rate Computation

When a candidate reaction pair is identified, the effective reaction rate is computed by multiplying the base rate with a series of environmental and catalytic modifiers:

rate = base_rate × f_temp × f_pH × f_mineral × f_catalyst × f_confinement × f_energy

Where each factor is computed as follows:

FactorFormulaRole
Temperature exp(−0.5 × ((T − T_opt) / T_width)²) Gaussian bell curve centred at optimal temperature (default 350 K, width 80 K)
pH exp(−0.5 × ((pH − pH_opt) / pH_width)²) Gaussian bell curve centred at optimal pH (default 7.0, width 4.0)
Mineral boost (1 + mineral_density × 2) × (1 + mineral_density × 3) Surface catalysis by iron-sulfide and clay minerals
Ribozyme catalyst 5.0× (if ribozyme motif detected in nearby RNA) Catalytic RNA accelerates enclosed reactions
Vesicle confinement 2.5× (if reactants share a vesicle) Concentration effect inside small compartments; also waives mineral requirement
UV boost Proportional to UV intensity at position Photochemical activation for UV-requiring reactions
Lightning boost 3.0× (if lightning is active at position) High-energy electrical discharge for Miller–Urey reactions

The final rate is hard-capped at 0.95 to prevent deterministic firing. A uniform random number is drawn; if random() < rate, the reaction fires: reactants are consumed (marked dead) and products are created at the reaction centre.

6.5 Thermodynamic Gating

Reactions with positive ΔG (endergonic) require energy coupling. The algorithm computes a driving force from the available energy sources and compares it against the thermodynamic difficulty:

driving_force = E_thermal × 0.4 + E_redox × 0.5 + E_UV × 0.6 + E_lightning × 0.8
difficulty = ΔG / 30.0
coupling = max(0, driving_force − difficulty × 0.3)

If coupling ≤ 0, the reaction is rejected regardless of other factors. The weighted coefficients reflect the relative thermodynamic potency of each energy source: lightning and UV provide the most concentrated energy, while thermal gradients provide the weakest per-event drive.

6.6 Polymer Sequence Construction

When polymerisation reactions fire, sequence strings are constructed:

RNA strands gain catalytic status when their sequence meets two criteria: (1) length ≥ catalytic_threshold (default 8) and (2) the sequence contains a ribozyme motif from the set {GUC, GAA, CCA, GCCA, GUCC, GAAC}. These motifs are loosely inspired by real ribozyme active sites (hammerhead, HDV, hairpin ribozymes).

7. Self-Assembly Engine

The AssemblyEngine models the spontaneous organisation of amphiphilic molecules into membrane-bound compartments. This process follows a lifecycle: free amphiphiles cluster into micelles, which grow and promote to vesicles (closed bilayer shells), which then undergo fitness-driven growth and division. Vesicles that lose too many lipids dissolve.

7.1 Micelle Formation

Free-floating amphiphilic molecules (fatty acids and lipids) that are not already part of any structure are clustered using a proximity-based algorithm:

  1. Identify all free amphiphiles (not in micelles or vesicles).
  2. For each amphiphile, find all other free amphiphiles within reaction_radius × 3 units.
  3. If the cluster size reaches the critical micelle concentration (default micelle_threshold = 8 lipids), form a new Micelle object.
  4. The micelle centre is the geometric mean of its member positions.
Biological basis. In real chemistry, amphiphiles spontaneously aggregate above their critical micelle concentration (CMC). BOL’s threshold-based model captures this phase transition without requiring explicit free-energy calculations.

7.2 Vesicle Promotion

Micelles that accumulate enough amphiphilic molecules are promoted to vesicles—closed bilayer shells that can encapsulate molecules:

7.3 Membrane Permeability

Vesicle membranes are selectively permeable, following a three-tier model:

CategoryMolecule TypesPermeation RateBehaviour
Freely permeable water, CO2, CO, H2, NH3, HCN, H2S, CH4, N2, HCHO 5.0% per step Small gases pass through bilayer freely
Semi-permeable amino acid, nucleotide, simple sugar, phosphate 0.8% per step Slow leakage of polar monomers
Impermeable peptide, RNA strand, lipid, fatty acid 0% Large molecules & polymers trapped inside

This permeability model ensures that polymers and information molecules are retained inside vesicles once synthesised, while small feedstock molecules can enter to fuel internal chemistry.

7.4 Fitness Scoring

Each vesicle receives a fitness score based on the functional molecules it contains. This score drives differential growth (fitter vesicles grow faster via osmotic influx and lipid accretion).

fitness = Σ(RNA contributions) + Σ(peptide contributions) + diversity_bonus
ComponentFormulaMaximum Contribution
RNA strand (non-catalytic)0.1 + length × 0.02~0.5 per strand
RNA strand (catalytic/ribozyme)0.1 + length × 0.02 + 0.3~0.8 per strand
Peptide0.05 + length × 0.01~0.2 per strand
Diversity bonus+0.15 (if both RNA and peptides present)0.15

Total fitness is capped at 2.0. Vesicles with catalytic RNA strands enjoy the strongest fitness advantage, reflecting the RNA World hypothesis that ribozymes were the primary drivers of early protocell fitness.

7.5 Osmotic Growth & Lipid Accretion

Fitter vesicles grow preferentially through two mechanisms:

Osmotic Growth

Small permeable molecules within a fitness-modulated attraction radius are absorbed into the vesicle. Higher fitness increases the effective absorption radius, modelling the biophysical reality that metabolically active protocells create local concentration gradients.

Lipid Accretion

Free-floating amphiphilic molecules within an attraction zone are recruited to the vesicle membrane:

attraction_radius = vesicle_radius + reaction_radius × 2 + fitness × 1.0
join_probability = min(0.5 + fitness × 0.25, 0.95)

This creates a positive feedback loop: fitter vesicles attract more lipids, growing larger, which provides more surface area for lipid accretion. This models the osmotic coupling between internal activity and membrane growth observed in synthetic protocell experiments (Szostak lab, 2004–2014).

7.6 Vesicle Division

Vesicles whose membrane lipid count exceeds division_size (default 50) undergo binary fission:

  1. Membrane lipids are randomly shuffled and split 50/50 into two daughters.
  2. Enclosed contents are randomly partitioned (each molecule has 50% chance to go to either daughter).
  3. Daughters are offset by a random vector × 2.0 units from the parent centre.
  4. Each daughter inherits generation = parent.generation + 1 and parent_id = parent.id.
  5. The parent vesicle is removed.

This division mechanism produces lineages (multi-generational chains) that can be tracked through the lineage viewer. Combined with differential fitness, this creates a minimal Darwinian selection system: fitter protocells grow faster, divide sooner, and propagate their contents to daughters.

7.7 Dissolution

Vesicles that lose membrane lipids below micelle_threshold / 2 (default 4) dissolve: all contents are released as free molecules and the vesicle is removed from the simulation. This models the thermodynamic instability of undersized bilayer structures.

8. Replication Engine

The ReplicationEngine models template-directed synthesis of RNA strands—the process by which information molecules make copies of themselves. Two distinct copying environments are modelled, reflecting different experimental and theoretical proposals.

8.1 Mineral-Surface Template Copying

Inspired by the Ferris (1996) and Orgel (2004) experiments on montmorillonite-catalysed RNA polymerisation, this mode operates on free-floating RNA strands near mineral-rich surfaces:

8.2 Vesicle-Interior Copying

RNA templates inside vesicles can replicate using encapsulated nucleotides. This mode is faster because the confined volume concentrates reactants:

8.3 Error Model

Template copying is error-prone, generating heritable variation that drives selection. Four types of errors are modelled, each with probability derived from the base error rate (default 0.02):

Error TypeProbabilityMechanism
Point mutation error_rate per base Complement base replaced by random alternative (A, U, G, or C)
Insertion error_rate × min(len/5, 2.0) Random base inserted at random position; longer strands more prone
Deletion error_rate × min(len/5, 2.0) Random base removed (if length > 2); longer strands more prone
Segment duplication error_rate × 0.5 A 2–3 base segment is duplicated in place (models slippage replication errors)
Evolutionary significance. Point mutations are the primary source of variation. Insertions and segment duplications allow sequences to grow, potentially acquiring new ribozyme motifs. Deletions provide a counterbalancing force that prevents unbounded sequence growth. Together, these error types create a rich mutational landscape for Darwinian evolution.

8.4 Recombination

When two RNA strands coexist inside the same vesicle, there is an 8% chance of single-point crossover during replication:

recombine(seq_a, seq_b) = seq_a[:crosspoint] + seq_b[crosspoint:]

The crossover point is chosen uniformly at random along the shorter sequence. Recombination allows beneficial motifs from different strands to combine, accelerating the exploration of functional sequence space—analogous to sexual recombination in modern organisms.

9. Simulation Orchestrator

The Simulation class in simulation.py coordinates all subsystems. It initialises the world, populates it with starting molecules according to the scenario configuration, and runs the step pipeline in a loop.

9.1 Feedstock Injection

At each step, new molecules representing vent gases are injected into the bottom 15% of the world, modelling continuous geochemical input from a hydrothermal vent:

Default FeedstockRate (molecules/step)
CO24
H25
H2S2
NH31

Rates are multiplied by the feedstock_rate configuration parameter (default 1.0). Fractional molecules are handled by probabilistic rounding: for rate 1.5, there is a 50% chance of spawning 1 or 2 molecules per step.

9.2 Brownian Diffusion

All molecules undergo temperature-dependent Brownian motion, fully vectorised for performance:

diffusion_coeff = scale × (T(pos) / 300) / mass
displacement = noise × diffusion_coeff (per axis)

Where noise is drawn from a standard normal distribution. Heavier molecules diffuse more slowly (inversely proportional to mass). Higher temperatures increase diffusion, naturally concentrating fast-moving light molecules near the hot vent while heavy polymers settle. All positions are wrapped periodically after displacement.

9.3 Ocean Loss

Molecules in the top 20% of the world height (above 80% of Y) have a per-step probability of ocean_loss_frac (default 5%) of being removed from the simulation. This models dilution of molecules into the open ocean—a sink that balances the feedstock source and prevents unbounded population growth.

9.4 Garbage Collection

Every 100 steps, dead molecules (consumed by reactions or ocean loss) are purged from the molecule list to free memory and maintain iteration performance. Python’s garbage collector handles the underlying memory reclamation.

10. Metrics & Complexity Scoring

10.1 Per-Step Metrics

The Metrics module records 24 measurements at every simulation step, providing a comprehensive time-series view of emergent dynamics:

CategoryMetricsDescription
Populationtotal_molecules, type_countsAlive molecule counts by type
Diversitydiversity_indexShannon entropy (bits) of type distribution
Assemblymicelle_count, vesicle_count, encapsulated_count, membrane_lipidsSelf-assembly state
Polymersrna_strand_count, max_rna_length, avg_rna_length, peptide_count, max_peptide_length, avg_peptide_lengthPolymer statistics
Catalysiscatalyst_countActive ribozyme catalysts
Energyenergy_budget, lightning_activeEnergy availability
Chemistryreactions_this_stepReaction throughput
Replicationreplication_fidelity, replication_eventsCopying accuracy and count
Selectionmax_fitness, avg_fitness, max_generation, divisions_observedVesicle fitness and lineage
Compositecomplexity_scoreOverall system organisation (0–100)

10.2 The Complexity Score

The complexity score is a weighted composite metric (0–100) that quantifies how far the simulation has progressed toward life-like organisation. It captures seven dimensions of emergent complexity:

ComponentWeightFormulaRationale
Chemical diversity15% min(shannon / 4, 1) × 15 A diverse chemical repertoire indicates active synthetic pathways
Polymer richness20% Blend of RNA count/length (60%) + peptide count/length (40%) Information polymers are prerequisites for genetic heredity
Catalytic activity15% min(catalysts / 3, 1) × 15 Ribozyme emergence signals the RNA World transition
Compartmentalisation15% (min(vesicles/5, 1)×0.5 + min(enclosed/50, 1)×0.5) × 15 Membrane boundaries enable selection at the protocell level
Selection dynamics15% (min(fitness/2, 1)×0.5 + min(generation/5, 1)×0.5) × 15 Multi-generational lineages with fitness differentials indicate Darwinian selection
Replication10% (min(events/10, 1)×0.5 + fidelity×0.5) × 10 Template copying with reasonable fidelity enables heredity
Information content10% min(max_polymer_length / 20, 1) × 10 Longer sequences carry more potential functional information

A score of 100 represents optimal simultaneous performance across all seven dimensions—a state rarely achieved, since it requires sustained polymer synthesis, vesicle populations with multi-generational fitness selection, active ribozyme catalysis, and high-fidelity replication all operating concurrently.

10.3 Export Formats

Simulation results can be exported in three formats:

11. Configuration System

11.1 Parameter Reference

The Config dataclass provides approximately 30 parameters with sensible defaults. All parameters can be overridden by scenario files, project settings, or CLI arguments.

CategoryParameterDefaultDescription
Worldworld_size[20, 20, 20]3D volume dimensions (units)
Environmenttemperature_min275 KOcean surface temperature
temperature_max400 KVent floor temperature
ph_min6.0Ocean pH (acidic)
ph_max11.0Vent pH (alkaline)
Energythermal_gradientTrueEnable thermal energy
uv_radiationFalseEnable UV photochemistry
lightningFalseEnable stochastic lightning
lightning_probability0.02Strike chance per step
Reactionsreaction_radius3.0Maximum encounter distance
base_rate_constant0.01Global rate multiplier
catalyst_multiplier100.0Ribozyme rate boost
Diffusiondiffusion_scale1.0Brownian motion intensity
Feedstockfeedstock_rate1.0Vent gas injection multiplier
feedstock_molecules{CO2:4, H2:5, ...}Gas types and counts per step
Lossocean_loss_frac0.05Surface dilution rate
Assemblymicelle_threshold8Minimum lipids for micelle
vesicle_threshold15Minimum lipids for vesicle
division_size50Lipid count triggering division
Replicationreplication_error_rate0.02Per-base mutation rate
min_polymer_length5Minimum length for copying
catalytic_threshold8Minimum length for ribozyme

11.2 Scenario Overlay

The configuration system uses a layered override architecture:

Layer 4: CLI Arguments highest priority
Layer 3: Project Configuration
Layer 2: Scenario JSON Overlay
Layer 1: Config Dataclass Defaults lowest priority

Each layer only specifies the parameters it needs to change; unspecified parameters inherit from the layer below. This design allows scenarios to define minimal overrides while inheriting robust defaults, and allows CLI arguments to override everything for ad-hoc experimentation.

11.3 The Four Preset Scenarios

Alkaline Hydrothermal Vent

Temperature: 275–400 K
pH: 6–11 (steep gradient)
Energy: Thermal + Redox
UV: Off | Lightning: Off
Mineral-rich environment with strong gradients.

Iron-Sulfur World

Temperature: 300–450 K
pH: 5–8 (moderate)
Energy: Thermal + Redox (enhanced)
UV: Off | Lightning: Off
Highest mineral density; metabolism-first focus.

RNA World

Temperature: 280–330 K
pH: 7–9 (mild)
Energy: Thermal + UV
UV: On | Lightning: Off
Moderate conditions favouring ribozyme stability.

Warm Little Pond

Temperature: 290–350 K
pH: 6–8 (near neutral)
Energy: Thermal + UV + Lightning
UV: On | Lightning: On
Surface environment with all energy sources.

12. Parameter Sweep Engine

The sweep.py module enables systematic exploration of the parameter space through three sweep modes:

ModeInputsOutputsPurpose
Scenario sweep All 4 scenarios × N seeds Bar chart + complexity time-series overlay Compare hypotheses under identical conditions
Single-parameter sweep One parameter across a value range 4-panel line plots (complexity, diversity, vesicles, fitness) Sensitivity analysis of individual parameters
2D grid sweep Cartesian product of 2 parameters Heatmap of complexity score Interaction effects between parameter pairs

Ten parameters are declared as sweepable: error_rate, reaction_radius, base_rate, catalyst_multiplier, diffusion_scale, feedstock_rate, ocean_loss_frac, division_size, vesicle_threshold, and temperature_max. Each sweep run produces per-run CSV files and a summary JSON for downstream analysis.

13. AI Analysis Laboratory

The AI Analysis Laboratory provides 27 deterministic analysis functions organised into 8 scientific modules. Each function operates on the current simulation state (molecules, reactions, vesicles, metrics history) and returns structured JSON results rendered by dedicated JavaScript visualisers.

13.1 Eight Modules, 27 Functions

Module#FunctionsFocus Area
Prebiotic Chemistry 4 pathway, yield, thermo, mineral Synthesis routes, reaction yields, thermodynamic coupling, mineral screening
Autocatalysis 3 raf, cycles, growth RAF set detection, catalytic cycle enumeration, network trajectory
Membrane Dynamics 3 cmc, stability, division Critical micelle concentration, vesicle stability, fission dynamics
Replication 4 template, error, ribozyme, heredity Template synthesis, mutation spectrum, ribozyme discovery, lineage tracking
Metabolism 3 coupling, tca, gradient Energy coupling pairs, proto-TCA detection, chemiosmotic gradients
Selection 3 landscape, group, transitions Fitness landscapes, group selection, major evolutionary transitions
Environment 3 sweep, compare, cycles Parameter sensitivity, scenario comparison, periodicity detection
Synthesis Report 4 full, bottleneck, hypothesis, report Full pathway analysis, bottleneck identification, hypothesis generation

13.2 Analysis Methodology

Pathway Analysis (prebiotic.pathway)

Uses breadth-first search backward from 9 target molecules (amino acid, nucleotide, ribose, etc.) through the reaction graph to find all synthesis paths from the food set (11 simple inorganic molecules). Results include the shortest path, intermediate molecules, and which reactions are on the critical path.

RAF Set Detection (autocatalysis.raf)

Implements the Reflexively Autocatalytic Food-generated set algorithm: starting from the food set, iteratively closes the set by identifying reactions whose products are catalysts for other reactions in the set. A non-empty RAF set indicates self-sustaining autocatalytic chemistry—a key milestone toward metabolism.

Fitness Landscape (selection.landscape)

Maps the genotype-to-fitness function by binning vesicles by their RNA sequence composition and correlating with fitness scores. Identifies local optima, fitness valleys, and evolutionary trajectories.

Major Transitions (selection.transitions)

Evaluates progress along the key evolutionary transitions framework (Szathmáry & Maynard Smith, 1995): replicating molecules → molecular populations → compartmentalised molecules → RNA-catalysed systems → protocells with heritable variation.

Deterministic analysis. All 27 functions are fully deterministic—they compute results from the current simulation state without any language model or probabilistic inference. The “AI” designation reflects the analytical intelligence of the algorithms, not the use of machine learning.

14. Data Model

BOL uses a file-based JSON storage strategy with no external database dependencies. This design eliminates database administration, simplifies deployment, and keeps the system fully self-contained.

EntityStorageKey PropertiesAccess Pattern
MoleculeIn-memoryid, type, pos[3], vel[3], mass, charge, hydrophobicity, sequence, vesicle_id, aliveCreated/destroyed every step by chemistry
VesicleIn-memoryid, center[3], radius, membrane_ids[], contents[], fitness, generation, parent_idCreated by promotion, removed by dissolution/division
MicelleIn-memoryid, center[3], lipid_ids[]Created by clustering, consumed by promotion
Reaction RuleConstantname, reactants, products, delta_g, base_rate, ph_opt, temp_opt, needs_mineralRead-only lookup each chemistry step
User Profileprofiles/*.jsonusername, password_hash, salt, display_name, bio, roleRead on login, write on register/update
Projectprojects/*.jsonid, name, owner, config, runs[]CRUD via API, locked access
Scenarioscenarios/*.jsonname, description, initial_molecules, environment, energy_sourcesRead-only at simulation start
Training Moduletraining/modules.jsonid, category, title, lessons[], quizzes[]Read-only curriculum
Bug Reportbugs/bugs.jsonid, title, severity, status, test_config, history[]CRUD via API, locked access

15. Web Application

15.1 Frontend Architecture

The web frontend uses a server-rendered architecture with Jinja2 templates and vanilla JavaScript for interactivity. This approach avoids framework dependencies while delivering a rich, responsive user experience.

ComponentTechnologyResponsibility
TemplatesJinja2 (30+ HTML files)Server-side rendering with master layout inheritance (base.html)
Dashboard JSapp.js (vanilla)Polling-based live updates, Chart.js integration, simulation controls
3D Viewerviewer.js (Three.js)WebGL particle visualisation with camera controls
AI Resultsai-results.js27 dedicated renderer functions for analysis outputs
Stylesstyles.cssSplunk-inspired dark theme with CSS custom properties, responsive breakpoints
PWAmanifest.json + service-worker.jsInstall-to-home-screen, offline caching of static assets

The design system features a dark background (#0a0a0a) with card surfaces (#1a1a2e) and accent colours—blue (#4cc9f0), pink (#f72585), gold (#fca311)—inspired by Splunk’s enterprise dashboard aesthetic. Mobile responsiveness is achieved through breakpoints at 768px and 480px, with a hamburger menu replacing the top navbar on small screens.

15.2 REST API Reference

The Flask server exposes approximately 50 REST API endpoints organised into 8 categories:

CategoryEndpointsAuth Required
Simulation ControlPOST /api/start, /api/stop, /api/pauseNo
Simulation DataGET /api/state, /api/history, /api/events, /api/reactions, /api/reaction_rules, /api/lineage, /api/energy, /api/network, /api/particles, /api/moleculesNo
AI AnalysisPOST /api/ai/<module>/<action>No
Scenarios & SweepGET /api/scenarios, POST /api/sweepNo
AuthenticationPOST /api/profile/register, /login, /logout, /update, /password, GET /api/profileVaries
ProjectsGET/POST /api/projects, GET/PUT/DELETE /api/projects/<id>, POST .../run, GET .../download, GET .../report, POST /api/projects/uploadYes
TrainingGET /api/training/modules, GET/POST .../progress, GET/POST .../notes/<id>, POST .../quiz/<id>Yes
Bug TrackerGET/POST /api/bugs, GET/PATCH/DELETE /api/bugs/<id>, POST .../test, POST .../test-all-openYes

15.3 Real-Time Update Strategy

The dashboard uses a polling-based approach for real-time updates, chosen for simplicity and compatibility over WebSockets:

EndpointIntervalDataConsumer
GET /api/state1 secondKPI cards, molecule counts, complexity, fitnessDashboard number cards
GET /api/history2 secondsTime-series arrays for chartingChart.js line/bar charts
GET /api/events3 secondsRecent event log entriesEvent feed sidebar

Chart.js instances update in-place using chart.data.datasets[n].data = newData with smooth animation transitions. This avoids chart recreation overhead and provides a fluid visual experience.

16. Security Architecture

BOL implements defence-in-depth security aligned with NIST SP 800-53 controls and CISA binding operational directives.

16.1 Authentication

ControlImplementationStandard
Password hashingPBKDF2-HMAC-SHA256, 260,000 iterations, 32-byte random saltNIST SP 800-132
Password policyMinimum 8 characters; must contain uppercase, lowercase, and digitNIST SP 800-63B
Timing-safe comparisonsecrets.compare_digest()Prevents timing side-channel attacks
Session managementFlask signed cookies; 8-hour lifetime; HttpOnly, SameSite=Lax, Secure (production)OWASP Session Management
Login rate limiting10 attempts per 5-minute window per IP; returns 429NIST SP 800-53 AC-7

16.2 Authorisation

16.3 Transport & Headers

HeaderValuePurpose
Strict-Transport-Securitymax-age=31536000; includeSubDomainsForce HTTPS for 1 year
Content-Security-Policyscript-src 'self' CDN...; frame-ancestors 'none'Prevent XSS and clickjacking
X-Content-Type-OptionsnosniffPrevent MIME type sniffing
X-Frame-OptionsSAMEORIGINPrevent framing by external sites
Referrer-Policystrict-origin-when-cross-originLimit referrer information leakage
Permissions-Policycamera=(), microphone=(), geolocation=(), payment=()Disable unused browser features

16.4 Input Validation

17. Deployment & Operations

BOL supports two deployment modes: local development and production deployment on a cloud server.

Production Deployment Pipeline

  1. Provision serversetup_server.sh creates a bol user, installs Python 3.12, Nginx, and certbot on Ubuntu 24.04 LTS.
  2. Deploy codedeploy_to_server.ps1 rsyncs the project to /opt/bol and creates a Python virtual environment with all dependencies.
  3. Configure servicesfinish_setup.sh creates a systemd unit file, Nginx virtual host configurations, and obtains SSL certificates.
  4. Harden headersfix_nginx_headers.sh applies CSP, HSTS, and X-Frame-Options headers to the Nginx configuration.

Operational Procedures

TaskCommand
Service statussystemctl status bol
Restart servicesystemctl restart bol
View logsjournalctl -u bol -f
SSL renewalcertbot renew (auto-configured)
Nginx config testnginx -t
BackupGit for code; periodic copy of profiles/, projects/, bugs/, .secret_key

Infrastructure

18. Design Principles & Non-Functional Requirements

Core Design Principles

  1. Coarse-Grained Particles — Molecules are objects with aggregate properties rather than individual atom simulations. This makes the simulation tractable at thousands of molecules while preserving meaningful chemistry.
  2. Stochastic Reactions — No reaction is deterministic. Probability-based firing creates realistic variation between runs and enables statistical analysis via sweeps.
  3. Spatial Realism — The continuous 3D volume with spatial hashing creates microenvironments where local conditions (temperature, pH, mineral density) drive different chemistries in different regions.
  4. Pluggable Scenarios — JSON configuration files allow new hypotheses to be explored without modifying source code.
  5. Observable Emergence — Self-assembly, replication, and selection are emergent phenomena, not hard-coded transitions. The simulation provides conditions; outcomes are observed.
  6. Real-Time Interactivity — Live dashboard updates enable scientists to observe and interact with running simulations.

Non-Functional Requirements

RequirementTargetImplementation
Performance<200ms per step (1,000 molecules)NumPy vectorised operations, spatial hashing
ScalabilityUp to 10,000 moleculesO(1) neighbour lookup, adaptive encounter budgets
PortabilityWindows, Linux, macOSPure Python + NumPy; browser-based UI
SecurityNIST SP 800-53, CISA BOD 18-01PBKDF2, CSP, HSTS, rate limiting
Availability99.5% uptime (production)systemd auto-restart, Gunicorn multi-worker

19. Prompt-Driven Development

19.1 Development Methodology

BOL was designed and constructed through a prompt-driven development process: a series of carefully sequenced natural-language design prompts, each specifying a major subsystem to build. The methodology mirrors an iterative engineering workflow where each prompt defines requirements, the implementation is executed, and validation is performed against all four origin-of-life scenarios before advancing to the next prompt.

This approach yielded several advantages:

19.2 The 24 Build Prompts

The application was constructed through 24 sequential prompts, beginning with project inception and culminating in a fully deployed web platform with PDF documentation, training curriculum, and algorithmic audit. The first 10 prompts were planned at inception; 14 additional prompts were added during development as the scope naturally expanded.

#PromptDateKey Deliverables
001 Project Inception & Scaffold 2026-03-09 Project structure, prompt log, progress log, existing software survey, 10-prompt build plan, Python package scaffold with config, world, simulation, and metrics modules.
002 Primordial Chemistry Engine 2026-03-09 27 molecule types, 21 reaction rules with pH/temperature Gaussian modifiers, cell-direct neighbour sampling for O(1) encounters, feedstock injection, ocean loss, mineral surface catalysis.
003 Energy Sources & Thermodynamics 2026-03-09 Four energy sources (thermal gradient, redox chemistry, UV Beer–Lambert, stochastic lightning). Multi-source Gibbs free energy coupling. 5 new energy-driven reactions (26 total), including UV photolysis and Miller–Urey synthesis.
004 Self-Assembly & Protocells 2026-03-09 Micelle formation via spatial clustering, vesicle promotion, lipid accretion, membrane permeability model (permeable vs impermeable types), initial encapsulation, vesicle confinement, dissolution. Compartment isolation in chemistry engine.
005 Polymers & Information Chemistry 2026-03-09 Amino acid sequences (20 AA codes), RNA sequences (AUGC), 6 ribozyme motifs, template-directed RNA replication with Watson–Crick pairing and error-prone copying. Mineral-surface concentration effects. First ribozyme catalyst emerged in validation.
006 Selection & Variation 2026-03-10 Vesicle fitness scoring, osmotic growth, division with content inheritance, semi-permeable monomers (Szostak model), confinement catalysis (2.5× rate), RNA recombination, segment duplication mutations. Third-generation vesicles observed.
007 3D Visualization 2026-03-09 Vispy 0.16.1 GPU renderer with CPK-coloured particle scatter, vent chimney mesh, thermal gradient planes, fitness-coded vesicle shells, HUD overlay, TurntableCamera, keyboard controls. ~460 lines of rendering code.
008–010 Metrics, Sweeps & Testing 2026-03-10 Metrics dashboard with Chart.js, parameter sweep engine, 4 scenario JSON presets, 56 unit tests (all passing), CLI arguments, performance optimisation (cell-direct sampling, dead molecule GC).
011 Web Dashboard 2026-03-10 Full Splunk-themed Flask web application with real-time KPI cards, 4 Chart.js time-series charts, simulation controls, event log, scenario picker, parameter sweep UI. Dark-theme CSS design system (~1,200 lines).
012 3D Microscope Viewer 2026-03-10 Three.js WebGL sprite-based particle renderer in the browser. Collapsible documentation panels. Real-time particle streaming from simulation API. Legend overlay, help panel, camera controls.
013 Icons & Branding 2026-03-10 Multi-resolution favicons (16–256px) and desktop icon generated with Pillow. DNA helix + vesicle motif.
014 Existing Software Reference 2026-03-10 Showcase page documenting 20 real-world origin-of-life tools in 5 categories with descriptions, capabilities, and BOL comparison points.
015 Molecule SVGs 2026-03-10 32 accurate ball-and-stick SVG molecule images. Viewer converted from Points to Sprites. Case normalisation, 7 missing types added, SVG artefacts removed.
016 Navigation, Security & Profiles 2026-03-10 Top navigation bar replacing sidebar, landing home page, security architecture (NIST SP 800-53 / CISA BOD 18-01 compliance), user profile system with credential protection, admin section (documentation, builds, user management).
017 White Paper & Design Documentation 2026-03-10 Comprehensive 21-section technical white paper (~135 KB). Cover page with abstract, full table of contents, professional print CSS, DREL Solutions branding. Served as standalone HTML.
018 AI Laboratory UX Overhaul 2026-03-11 Split AI Laboratory into 8 individual pages with dedicated templates. 30 per-action rich visual renderers (tables, meters, cards) in ai-results.js with shared CSS.
019 Project Management 2026-03-11–12 Full CRUD projects with user ownership, molecule grid picker, environment config, synchronous and background run modes. PDF report generation (stdlib). JSON download/import with owner reassignment. CLI --project flag.
020 Training Curriculum 2026-03-14 8-category origin-of-life training system with 32 interactive modules. TTS reader with chunk-based paragraph splitting, quizzes with grading, personal notes, progress tracking.
021 Bug Tracker & Quality Assurance 2026-03-14 Full lifecycle bug management with CRUD API, 5 severity levels, 6-state workflow (open → verified). Automated test runner (HTTP checks + shell commands). Stats dashboard with filtering.
022 Mobile PWA & Infrastructure 2026-03-14 Progressive Web App with manifest.json and service worker for offline caching. Hamburger menu for mobile navigation. Session persistence via secret key file. .gitignore for dev artefacts.
023 Algorithm Audit & Test Report 2026-03-14 Deep code audit of chemistry, energy, assembly, and replication modules. 4-scenario validation (1000 steps, seed 42). 6 issues identified, 1 code fix (vesicle −1 placeholder), 5 advisory. Formal test report page.
024 Whitepaper Sidebar TOC & PDF Generation 2026-03-14 Fixed left sidebar table of contents with scroll-spy highlighting and collapsible sub-sections. Professional PDF generation via xhtml2pdf with A4 layout, custom stylesheet, and page footers.
From inception to production-deployed platform in under one week. The prompt-driven approach enabled rapid, validated construction of a complex multi-module scientific application. Each prompt was validated against all four origin-of-life scenarios before the next was attempted.

19.3 Build Tracking & Release Management

BOL includes a dedicated Build History page (/builds) that provides a versioned release record of the platform. The build system serves as both documentation and an auditable record of every iteration.

Build Page Features

The build page is rendered as static content in the builds.html template, served via the /builds route. It is accessible to all authenticated users and provides a single-page view of the complete development history.

Release Metadata (v1.0.0)

AttributeValue
Release date2026-03-14
Build iterations24 (prompts)
Tests56 — all passing
PlatformPython 3.12
Dependencies6 third-party packages

19.4 Bug Tracker & Quality Assurance

BOL includes a built-in Bug Tracker (/bugs) that provides full lifecycle bug management without requiring external issue-tracking tools. The tracker was designed to keep quality assurance tightly coupled with the application itself.

Bug Lifecycle & Workflow

Each bug progresses through a defined state machine with six possible statuses:

  open  →  in_progress  →  fixed  →  verified
    ↓                          ↑          ↓
    ↓        reopened  ←———————+
    ↓
  wont_fix

Data Model

Bugs are stored as JSON in a file-based storage layer (bugs/bugs.json) with thread-safe access via a threading lock. Each bug record contains:

FieldTypeDescription
idIntegerAuto-incrementing unique identifier
titleString (max 500)Bug summary (required)
descriptionTextDetailed bug description
severityEnumlow, medium, high, critical
statusEnumopen, in_progress, fixed, verified, wont_fix, reopened
environmentEnumlocal, staging, production
steps_to_reproduceTextStep-by-step reproduction instructions
expected_behaviorTextWhat should happen
actual_behaviorTextWhat actually happens
fix_descriptionTextDescription of the fix applied
test_commandStringAutomated verification command (HTTP or shell)
fix_verifiedBooleanWhether the fix has been verified by test
tagsArrayCategorisation tags (e.g., “chemistry”, “ui”, “security”)
created / updatedISO 8601Timestamps for audit trail

REST API

The bug tracker exposes a full CRUD API with filtering and automated testing:

EndpointMethodDescription
/api/bugsGETList bugs with optional filters (status, severity, environment, search)
/api/bugsPOSTCreate new bug (authenticated)
/api/bugs/<id>GETRetrieve single bug
/api/bugs/<id>PATCHPartial update (authenticated)
/api/bugs/<id>DELETEDelete bug (authenticated)
/api/bugs/<id>/testPOSTRun automated test for a single bug
/api/bugs/test-all-openPOSTRun tests on all open/in-progress/fixed bugs

Automated Test Runner

The bug tracker includes a built-in automated test runner that can verify fixes without leaving the application. Each bug can specify a test_command in one of three formats:

  1. HTTP health checkGET https://url [expected_status]. Validates that the endpoint returns either the specified status code or any 2xx response.
  2. URL check — a plain URL is fetched and validated for a 2xx response.
  3. Shell command — arbitrary shell commands executed via subprocess.run(shell=False) with a 30-second timeout and output capped at 2,000 characters. Commands are parsed with shlex.split() to prevent shell injection (NIST SI-10).

When a bug in fixed status passes its automated test, the tracker automatically promotes it to verified. The “Test All” function runs tests on every open, in-progress, or fixed bug that has a test command defined, returning a summary of total, passed, and failed counts.

User Interface

The bug tracker UI provides:

SSRF mitigation. The automated test runner restricts URL schemes to http:// and https:// only, preventing server-side request forgery via file://, ftp://, or other dangerous schemes.

20. Glossary

TermDefinition
AmphiphileA molecule with both hydrophilic (water-loving) and hydrophobic (water-repelling) regions, enabling self-assembly into membranes. In BOL: fatty_acid and lipid.
Arrhenius equationTemperature dependence of reaction rates: k = A × exp(−Ea/RT). BOL uses Gaussian bell curves as a simplified analog.
Beer–Lambert lawExponential attenuation of light intensity with depth: I = I0 × exp(−depth/penetration). Used for UV energy modelling.
Brownian motionRandom molecular movement driven by thermal energy. Modelled as Gaussian noise scaled by temperature and inversely by mass.
CMCCritical Micelle Concentration — the amphiphile threshold above which spontaneous aggregation occurs. BOL uses micelle_threshold.
ΔG (Gibbs Free Energy)Thermodynamic potential for a reaction. Negative ΔG = spontaneous (exergonic). Positive ΔG = requires energy input (endergonic).
EndergonicA reaction requiring energy input (ΔG > 0). Must be coupled to an energy source (thermal, redox, UV, lightning) to proceed.
ExergonicA spontaneous reaction that releases energy (ΔG < 0). Can proceed without external energy coupling.
Fischer–TropschCatalytic reaction converting CO + H2 to organic molecules on metal surfaces. BOL reaction #2.
Formose reactionAutocatalytic synthesis of sugars from formaldehyde. BOL reactions #3–5.
Miller–UreyClassic experiment (1953) synthesising amino acids from simple gases via electrical discharge. BOL reaction #24.
ProtocellA vesicle encapsulating functional molecules—a minimal precursor to a living cell.
RAF SetReflexively Autocatalytic Food-generated set — a self-sustaining network of mutually catalysed reactions starting from a food set.
RibozymeAn RNA molecule with catalytic activity. In BOL: RNA strands ≥8 bases containing a recognition motif (GUC, GAA, CCA, GCCA, GUCC, GAAC).
Spatial hashingGrid-based indexing scheme dividing 3D space into cells for O(1) neighbour lookups.
Strecker synthesisChemical route from HCN + aldehyde to amino acids. BOL reaction #8.
ThioesterA reactive sulphur ester (R–CO–S–R′) that stores chemical energy analogous to ATP’s phosphoanhydride bond.
Watson–Crick pairingComplementary base pairing in RNA: A↔U, G↔C. Used by the replication engine for template copying.

21. References

  1. Gilbert, W. (1986). “The RNA World.” Nature, 319, 618.
  2. Wächtershäuser, G. (1988). “Before enzymes and templates: theory of surface metabolism.” Microbiol. Rev., 52(4), 452–484.
  3. Russell, M. J. & Hall, A. J. (1997). “The emergence of life from iron monosulphide bubbles at a submarine hydrothermal redox and pH front.” J. Geol. Soc., 154, 377–402.
  4. Miller, S. L. (1953). “A production of amino acids under possible primitive Earth conditions.” Science, 117(3046), 528–529.
  5. Ferris, J. P. et al. (1996). “Synthesis of long prebiotic oligomers on mineral surfaces.” Nature, 381, 59–61.
  6. Orgel, L. E. (2004). “Prebiotic chemistry and the origin of the RNA world.” Crit. Rev. Biochem. Mol. Biol., 39(2), 99–123.
  7. Damer, B. & Deamer, D. (2015). “Coupled phases and combinatorial selection in fluctuating hydrothermal pools.” Life, 5(1), 872–887.
  8. Szostak, J. W. et al. (2001). “Synthesizing life.” Nature, 409, 387–390.
  9. Szathmáry, E. & Maynard Smith, J. (1995). “The major evolutionary transitions.” Nature, 374, 227–232.
  10. Hordijk, W. & Steel, M. (2004). “Detecting autocatalytic, self-sustaining sets in chemical reaction systems.” J. Theor. Biol., 227(4), 451–461.
  11. Martin, W. & Russell, M. J. (2003). “On the origin of cells: a hypothesis for the evolutionary transitions from abiotic geochemistry to chemoautotrophic prokaryotes.” Phil. Trans. R. Soc. B, 358, 59–85.
  12. NIST Special Publication 800-53 Revision 5. “Security and Privacy Controls for Information Systems and Organizations.”
  13. NIST Special Publication 800-63B. “Digital Identity Guidelines: Authentication and Lifecycle Management.”
  14. CISA Binding Operational Directive 18-01. “Enhance Email and Web Security.”

BOL — Beginning of Life Simulator • Technical White Paper • Version 1.0.0 • March 2026

© 2026 DREL Solutions. All rights reserved.