SGEMAS: Self-Growing Ephemeral Multi-Agent System
- SGEMAS is a bio-inspired architecture that uses autonomous agents and free energy minimization to perform unsupervised online anomaly detection.
- The system employs innovative birth–death population dynamics and a multi-scale instability index to achieve dynamic sparsity and computational efficiency.
- Experimental evaluations demonstrate that SGEMAS achieves high anomaly detection performance with low computational load, ideal for energy-constrained biomedical devices.
SGEMAS (Self-Growing Ephemeral Multi-Agent System) is a bio-inspired, energy-constrained architecture for unsupervised online anomaly detection that models intelligence as a dynamic thermodynamic process. The system leverages a population of autonomous agents whose structure is governed by free energy minimization and homeostatic constraints, achieving high computational sparsity and adaptability in streaming signal environments. SGEMAS introduces innovations in both model topology—via birth–death population dynamics—and objective function design, particularly the enforcement of entropic homeostasis and the integration of a multi-scale instability index. The architecture has demonstrated robust, label-free anomaly detection performance on physiological data streams under zero-shot, fully-online constraints (Hamdi, 8 Dec 2025).
1. System Architecture and Biological Motivation
SGEMAS is constructed as a sparse, time-varying ensemble of agents , each represented as a local "particle" in a reaction–diffusion medium. The collective activity of these agents forms the system's estimator for an incoming scalar signal . At each timestep , the system state is , where:
- : system's online estimate of ,
- : metabolic energy reservoir,
- : adaptive number of active agents,
- : deterministic operator defined by each agent.
Each agent possesses a binary alive-indicator 0, a fixed role 1 (Sensor, Regulator, Catalyst), and internal parameters 2. The agent contribution is 3, with 4 for Regulator agents. The self-organization of agent populations in response to signal-driven "surprise" supports the system's plasticity and sparsity.
2. Thermodynamic Objective and Free Energy Homeostasis
SGEMAS minimizes a Metabolic Lagrangian at each timestep,
5
where 6 quantifies momentary "surprise," 7 is adaptive precision (inverse local variance), 8 is the maintenance cost of agent population, and 9 balances accuracy and sparsity.
The free energy decomposition follows Active Inference principles:
0
with contributions from prediction error, model complexity, and entropy. The model maintains a point-mass posterior 1, and a Gaussian likelihood 2.
To preserve adaptability and prevent collapse to a degenerate state, SGEMAS enforces entropic homeostasis:
3
with a quadratic penalty
4
leading to an overall instantaneous objective
5
3. Structural Plasticity: Birth–Death Population Dynamics
SGEMAS agents undergo stochastic birth and death governed by the available metabolic energy 6:
- Recruitment (birth) rate:
7
with 8,
- Apoptosis (death) rate:
9
These rates induce discrete-time population updates,
0
with the population cost feeding back into the metabolic Lagrangian. This self-organizing mechanism enables dynamic sparsity and wake-on-demand agent activation, substantially reducing average computational load relative to fixed-topology methods.
4. Multi-Scale Instability Index and Energy Coupling
SGEMAS v3.3 incorporates a multi-scale instability index to enhance sensitivity to temporal signal variations:
1
The energy update is accordingly modified:
2
3 can equivalently be interpreted as a negative anomaly score regularizer. Empirically, integrating this index significantly increases anomaly detection performance, with an ablation study showing progressive gains through SGEMAS versions and a final v3.3 mean AUC of 4 in a challenging inter-patient, zero-shot regime.
5. Algorithmic Workflow
The following summarizes the SGEMAS v3.3 implementation:
1 All logic, including agent spawning, belief updating, and energy management, occurs online at each timestep in response to streaming data (Hamdi, 8 Dec 2025).
6. Experimental Evaluation and Computational Characteristics
Experiments utilize the MIT-BIH Arrhythmia Database (inter-patient DS2 split, 360 Hz, raw ECG), with rolling 10 s Z-score normalization and no segmentation at inference. The protocol is fully online, unsupervised, and zero-shot (no label or pre-training).
Quantitative Outcomes Table
| Model/Variant | AUC (DS2, mean ± std) | FLOPs per beat |
|---|---|---|
| SGEMAS v3.0 (baseline) | 0.502 ± 0.028 | ~10⁷ |
| SGEMAS v3.1 | ≈0.525 ± 0.030 | ~10⁷ |
| SGEMAS v3.2 | ≈0.548 ± 0.045 | ~10⁷ |
| SGEMAS v3.3 | 0.570 ± 0.070 | ~10⁷ |
| Isolation Forest | 0.49–0.52; beat 0.61 | ~10⁸ |
| Deep SVDD | 0.51–0.54 | Not stated |
| LSTM-AE | 0.53–0.56 | Not stated |
| Deep autoencoder | beat 0.55 | ~10¹⁰ |
On normalized beat input, SGEMAS attains an AUC of 0.791, outperforming both deep autoencoders (AUC 0.55) and Isolation Forest (AUC 0.61). Computational demands for SGEMAS are substantially reduced, with 5 FLOPs per beat versus 6–7 for comparator models. The wake-on-demand agent structure and enforced sparsity yield a marked reduction in resource consumption, a critical factor for embedded or wearable biomedical devices (Hamdi, 8 Dec 2025).
7. Implications, Extensions, and Future Directions
SGEMAS provides a physics-based homeostatic model that mediates structural "inertia", amplifying free-energy spikes during anomalies and guarding against over-adaptation to streaming data. The architecture's extreme sparsity and event-driven activation permit deployment in energy-constrained environments such as implantable or wearable health monitors.
The multi-scale instability index enables sensitivity to subtle waveform features in a label-free setting. Potential extensions include multi-lead ECG, continuous glucose monitoring, and EEG seizure detection, leveraging the shared free-energy objective and plasticity principle.
Future research priorities explicitly identified are: FLOPs-to-Joule energy translation, hyperparameter sensitivity analysis (notably for 8, 9, and 0), and benchmarking against variational/one-class deep models under matched online conditions (Hamdi, 8 Dec 2025).