HEGEL

How It Works Back to Dashboard

What is Hegel?

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 core question: Can self-maintaining chemistry + local learning rules + survival pressure produce consciousness-like structures without any external optimization?

Architecture

Environment Resources input METABOLISM S + T + U C1 + C2 5 coupled ODEs sensory CTRNN BRAIN 20 neurons recurrent 20 coupled ODEs output MOTOR M1, M2, M3 movement + resource intake modulates intake rates HEBBIAN Oja + BCM weights VIABILITY BOUNDARY

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.

Metabolic Variables

VariableNameRoleDeath 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 catalysts C1 and C2 repair each other through cross-catalysis. This creates a self-maintaining loop: the system keeps itself alive through its own internal chemistry. If perturbations knock both catalysts too low, the repair loop collapses and the organism dies permanently.

Viability: Life and Death

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: CTRNN

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.

Hebbian Learning

There is no backpropagation. The CTRNN's weights evolve through four Hebbian rules:

Oja's Rule

Extracts principal components of input. dw = eta * y * (x - y * w). Converges to the first eigenvector of the input correlation matrix.

BCM Theory

Creates selectivity through a sliding threshold. Neurons develop preferences for specific inputs. Below threshold = weakening (LTD), above = strengthening (LTP).

Anti-Hebbian + Competitive

Lateral inhibition decorrelates neuron responses. Different neurons learn to respond to different features.

Learning ONLY happens while the organism is alive. Death stops all weight updates. This is the viability constraint on cognition: you can only learn if you survive.

The Four Layers

Layer 1: Metabolic Viability

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.

Advancement: 7 out of 10 recent runs surviving with average survival > 80,000 time units.
Layer 2: Sensorimotor Coupling

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.

Advancement: Average motor output variance > 0.01 across 5 recent runs.
Layer 3: Hebbian Adaptation

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.

Advancement: Learning-ON beats Learning-OFF in 2 out of 3 recent paired comparisons.
Layer 4: World Model

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.

Research frontier. No automatic advancement criteria yet.

Perturbations

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.

What This Is Not

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.