AIO1: Pretrained End-to-End Neural Network for General Advanced Process Control
English | δΈζ
AIO1 is a single pretrained end-to-end neural network (~131M parameters) designed as a general multivariable Advanced Process Control (APC) controller. It controls arbitrary industrial plants through one dimensionless, plant-agnostic interface:
No commissioning step test: runs closed-loop immediately on unseen plants.
No formula, identifier, or MPC solver at runtime: no underlying PID loop, no recursive least squares, and no online optimization solver.
Plant-agnostic interface: receives only normalized public instrument readings (controlled variables, setpoints, bands, limits, priorities, measured disturbances, valve openings, rate limits, optional loop pairing and directions, and step interval). It infers plant dynamics, dead time, and operating drift directly from its own closed-loop history.
Code repository: M3rcyzzz/AIOGym2
Open-source process simulator & AIOGym Bench: M3rcyzzz/Hflash
Live research progress & replays: https://m3rcyzzz.club/aio/
ModelScope mirror: M3rcyzzz/AIO1
Status (2026-12-03)
Research checkpoint (Stage 15B, Hub round 50 β ~8.9M cumulative 384-step black-box RL environment steps across Stages 12B β 14 β 15 β 15B, simulation only, not validated on real industrial plants). On the upgraded 720-step AIOGym Bench (with persistent industrial drift on all mechanistic and external commercial suites), this release achieves 44.1 across the 7 main tracks (+4.8 over r82's 39.3, surpassing Static-model MPC at 43.8) and decisively beats Static-model MPC on every drift and real-plant arena (mech-industrial 85.9 vs. 48.0, shift-12x5 66.3 vs. 39.2, mech-heldout 23.0 vs. 1.7, external NeqSim 3.30 83.0 vs. 32.3, external DWSIM 10.3 45.0 vs. β38.6). This repository always keeps the latest verified checkpoint; each update replaces the previous release.
Architecture & Training Summary
- Runtime network (~131M parameters, single standalone model):
- Shared dimensionless encoders map every controlled variable, measured disturbance, and valve into 768-dim vectors so one set of weights adapts natively to plants of any size (trained across 12Γ5, 24Γ10, and 48Γ20).
- 12 spatio-temporal Transformer layers (width 768, 12 heads, RoPE, QK-Norm, KV caching), each combining causal temporal attention (128 steps), multi-lag cross-channel attention across 8 fixed delays (1 to 64 steps) for long dead times, simultaneous cross-channel interaction attention for multivariable coordination, and a 3,072-wide feed-forward network.
- Two persistent recurrent memories: a per-channel multi-timescale EMA (4β2,048 steps) for slow drift and levels, and an online linear-attention coupling memory (DeltaNet) updated in $O(1)$ per step that estimates live valve-to-sensor gains and in-flight moves in the delay pipe, protected by Cauchy outlier filtering against sudden unmeasured load shocks and a steady-state sign guardrail when valve direction is known.
- Direct action head with adaptive step-size scaling and
tanhrate-limit bounding.
- Black-box RL training on Hflash:
- Unified two-way scene split β Training (75% generated scenes across 9 procedural families covering long dead time, inverse response, strong nonlinearity, 4β12Γ band unmeasured step load shocks, hard limits, and faults + 25% mechanistic scenes across 18 ODE/DAE units, collected via closed-loop rollouts with parallel
(B, T)Transformer updates) vs. Evaluation (20 unseen mechanistic scenes + frozen multi-scale/drift/fault/blind-pairing tracks + external commercial simulators NeqSim & DWSIM). - Stage A (Online DAgger warm-up): 85% student / 15% teacher rollouts; only paired episodes (75%) imitate a training-only MPC teacher that uses ONLY public instruments (never peeking at hidden loads); blind episodes (25%) never copy the teacher.
- Stage B (384-step Black-Box RL: PPO β Counterfactual GRPO): drops both teacher imitation and Critic value networks, running 4 parallel rollouts per identical plant, event, and noise seed (Group Relative Policy Optimization) over 384-step horizons ($\gamma = 0.995$) with multi-scale 1/4/8-step block exploration (penetrating slow plant dead times), dim-scaled exploration noise, a moving EMA KL trust region, and matched 1D/2D Muon + AdamW step scales with DiLoCo multi-GPU synchronization.
- Unified two-way scene split β Training (75% generated scenes across 9 procedural families covering long dead time, inverse response, strong nonlinearity, 4β12Γ band unmeasured step load shocks, hard limits, and faults + 25% mechanistic scenes across 18 ODE/DAE units, collected via closed-loop rollouts with parallel
Verified Benchmark Results (2026-12-03, Simulation)
Official AIOGym Bench 0β100 scale: 0 = all valves frozen (Hold), 100 = strictly-causal privileged oracle MPC (audited with zero scores >100 across all 20 unseen mechanistic scenes; prior 360-step zero-drift scores are superseded). Every plant below is strictly excluded from training; all controllers run the exact same unseen plants, industrial drift schedules, events, and noise seeds.
1. Official AIOGym Bench Tracks (0β100 Scale, 720 steps)
| AIOGym Bench Track | Units | AIO1 (Stage 15B r50) | Static-model MPC |
|---|---|---|---|
mech-industrial (Eval Β· 6 attributed industrial scenes, drift) |
6 | 85.9 (100% safe; +37.9 vs. MPC) | 48.0 |
shift-12x5 (Eval Β· Permanent drift / grade change) |
32 | 66.3 (100% safe; +27.1 vs. MPC) | 39.2 |
synth-12x5 (Standard 12Γ5 MIMO) |
64 | 54.0 (100% safe; +7.6 vs. r82) | 69.8 |
synth-24x10 (Large 24Γ10 MIMO) |
32 | 27.4 (100% safe; +7.4 vs. r82) | 62.4 |
synth-48x20 (Plantwide 48Γ20 MIMO) |
16 | 26.9 (100% safe; r40 33.2, +14.7 vs. r82) | 39.4 |
fault-12x5 (Concurrent multi-faults) |
32 | 25.2 (100% safe; +1.1 vs. r82) | 46.1 |
mech-heldout (Eval Β· 14 MIT mechanistic scenes, strong drift) |
14 | 23.0 (78.6% safe; +21.3 vs. MPC) | 1.7 |
unpaired-12x5 (Blind pairing) |
64 | β11.6 (100% safe) | β |
- 7-track main mean: 44.1 (up from 39.3 at r82, +4.8; beats Static-model MPC 43.8).
2. All 20 Zero-Shot Mechanistic Industrial & Chemical Plants (720 steps, Industrial Drift)
- Audited causal
oracle MPC= 100.0 (zero >100 distortion): GasLib-24 95.7 (MPC 96.3), Badgwell 94.7 (MPC 77.8), DC Chiller 93.2 (MPC 73.1), Refrig 91.6 (MPC 99.6), WilliamsβOtto 90.1 (MPC 52.2), PEM Electrolyzer 88.5 (MPC 92.3), MMA 88.3 (MPC 89.5), BSM1 84.5 (MPC β34.8), TEP-9 79.9 (MPC β44.1), VAM 79.3 (MPC β41.9), TEP 74.0 (MPC 100.0), Crystallizer 63.3 (MPC 31.1), Methanol 56.7 (MPC 95.5), Boiler2 47.2 (MPC β100.0), Fed-batch bioreactor 17.5 (MPC β100.0), Headbox 0.2 (MPC β100.0), Debutanizer β7.6 (MPC β100.0), FCCU β100.0 (MPC 27.7), BenzeneβToluene β100.0 (MPC β100.0), Boiler β100.0 (MPC 96.6).
3. External Independent Commercial Dynamic Simulators (Same 0β100 AIOGym Bench Scale)
| Commercial Simulator (6 industrial-drift episodes each) | AIO1 (Stage 15B r50) | Static-model MPC | oracle MPC |
|---|---|---|---|
| NeqSim 3.30 (5Γ5 two-stage oil-gas separator, SRK EOS) | 83.0 (100% safe; +50.7 vs. MPC) | 32.3 (100% safe) | 100.0 |
| DWSIM 10.3 (5Γ3 pressurized catalytic CSTR, native .NET 10) | 45.0 (100% safe; +83.6 vs. MPC) | β38.6 (83.3% safe) | 100.0 |
Files
| File | Description |
|---|---|
model.safetensors |
Standalone inference weights (~131M parameters, safetensors format) |
config.json |
Minimal loader configuration |
modeling_aio.py, code/ |
Self-contained inference loader (load(), Controller, encode()) and slim runtime modules |
README.md, README_zh.md, LICENSE |
Bilingual model cards and MIT license |
Usage
# pip install torch numpy safetensors huggingface_hub
from huggingface_hub import snapshot_download
import sys
import numpy as np
path = snapshot_download("M3rcyzzz/AIO1")
sys.path.insert(0, path)
import modeling_aio as M
net = M.load(device="cpu") # or device="cuda" / "mps"
ctl = M.Controller(net) # keeps per-plant history & memory; call ctl.reset() for a new plant
packet = M.encode(
values=y, previous=y_prev, target=sp, last_target=sp_prev,
scale=cv_scale, lower=cv_low, upper=cv_high, tracking=is_tracked,
command=u, last_command=u_prev, u_low=u_min, u_high=u_max,
slew=du_max, pairing=pairing, dt=dt,
sign=paired_gain_sign, # +1 / -1 per MV, 0 if unknown; optional dv=, weight=
)
move = ctl.step(packet) # per-MV increment in [-1, 1] of slew limit (0 on unused slots)
u = np.clip(u + move[:len(u)] * du_max, u_min, u_max)
Limitations
- Simulation-only research checkpoint; never validated on a real industrial plant and not safety-certified.
- Clear headroom remains on standard/large synthetic MIMO (
synth-12x554.0 vs. Static-model MPC 69.8,24Γ1027.4,48Γ2026.9), concurrent faults (fault-12x525.2), blind pairing (unpaired-12x5β11.6), and 3/14 severe-drift held-out mechanistic units (boiler,btcol,fccu).
License
MIT (Copyright (c) 2026 Mercy Zhang), see LICENSE.
- Downloads last month
- 259