Hegel is a gradient-free artificial consciousness simulation. It models Hegel's Phenomenology of Spirit as a progression of dynamical systems: from bare survival (metabolism) through self-discovery (prediction + intervention) to mutual recognition (two-agent interaction). There is no backpropagation, no loss function, no optimization. The organism either stays alive or dies. Learning happens through Hebbian rules as a side effect of survival.
The organism is a 25-dimensional ODE system: 5 metabolic variables + 20 CTRNN neuron activations, all solved together by an adaptive ODE integrator (Tsit5). The metabolism produces the chemistry of life, the brain reads sensory input from the chemistry and produces motor output, and the motor output modulates how the organism interacts with its environment.
| Variable | Name | Role | Death if |
|---|---|---|---|
| S | Substrate | Primary food source. Consumed by catalytic reactions, replenished from environment. Motor output modulates intake rate. | < 0.05 |
| T | Intermediate | Reaction product of S. Consumed by two different catalytic pathways (via C1 and C2). Key metabolic hub. | < 0.05 |
| U | Waste / Byproduct | End product recycled through cross-catalysis. Feeds back into catalyst C1 repair. Accumulation or depletion both dangerous. | < 0.05 |
| C1 | Catalyst 1 | Self-repairing enzyme. Catalyzes S+T reaction. Produced by C2+U cross-catalysis. If both catalysts fall, the system cannot self-repair. | < 0.005 |
| C2 | Catalyst 2 | Self-repairing enzyme. Catalyzes T+U reaction. Produced by C1+S cross-catalysis. Cross-repairs with C1 in a mutual dependency. | < 0.005 |
The viability margin measures how far the organism is from death. It's the minimum margin across all 5 concentrations relative to their death thresholds. A margin of 100% means perfectly safe. A margin of 0% means at the boundary. Negative means dead.
Death is permanent. Once any concentration drops below its threshold, the organism dies and cannot recover. This is a core design principle from viability theory (Aubin): the system must actively maintain itself within a viable region of state space. There is no resurrection.
The brain is a Continuous-Time Recurrent Neural Network (Beer, 1995) with 20 neurons. Each neuron follows:
tau_i * dy_i/dt = -y_i + sum_j(w_ij * sigma(y_j + theta_j)) + sensory_i
Sensory inputs come from the metabolic concentrations and environmental signals. Three motor output neurons (M1, M2, M3) control the organism's behavior: substrate intake rates and movement through the resource landscape.
There is no backpropagation. The CTRNN's weights evolve through four Hebbian rules:
Extracts principal components of input. dw = eta * y * (x - y * w). Converges to the first eigenvector of the input correlation matrix.
Creates selectivity through a sliding threshold. Neurons develop preferences for specific inputs. Below threshold = weakening (LTD), above = strengthening (LTP).
Lateral inhibition decorrelates neuron responses. Different neurons learn to respond to different features.
Can the organism stay alive? The metabolism must self-maintain under perturbations (random catalyst halvings, substrate depletions, noise bursts). Each run faces 12 random perturbations over 100,000 time units.
Does the brain actually control behavior, or is it just along for the ride? The CTRNN motor outputs must show meaningful variance, proving the neural network is actively modulating the organism's interaction with its environment.
Does learning help? Paired trials compare organisms with Hebbian learning ON vs OFF under identical conditions. If learning improves survival, the weights are capturing useful environmental structure.
Can the organism predict its environment? Prediction neurons output expected next sensory input. When prediction fails in ways correlated with the organism's own actions, a self-model emerges. This is Hegel's "determinate negation": world-model failure produces specific new structure.
Each organism faces 12 random perturbations during its 100,000-time-unit lifetime. These simulate environmental shocks:
Catalyst halving: C1 or C2 suddenly drops to 50%. The organism must repair through cross-catalysis.
Substrate depletion: S, T, or U drops sharply. The organism must compensate through motor behavior.
Noise bursts: Random perturbations across multiple variables simultaneously.
Perturbations are scheduled between t=1,000 and t=90,000, giving the organism time to stabilize before being tested.
This is not artificial general intelligence. It is not self-consciousness. It is a functional analog of Hegel's phenomenological progression, implemented as dynamical systems. The scientific question is whether gradient-free, viability-constrained self-maintenance can produce behaviors that structurally resemble consciousness stages. If it fails, documenting why it fails is equally valuable.