Skip to content

Enhancements over the base TinyRL core ​

Every mechanism in these tables exists because a specific industrial failure was observed and then proven prevented: nothing is speculative.

What nodes/core/ adds to the upstream TinyRL submodule (TinyRL/src: autograd, matrix, layers, OBGD optimizer, streaming updates) to make it a deployable industrial condition monitor. Each row names the mechanism, the industrial failure it prevents, and the test that proves it. The suite is tests/run_tests.sh; suite logs live in tests/logs/.

Evaluation state: all configurations green 2026-11-22 (ramps OFF host_tests_20261122_130728.log, ramps ON host_tests_20261122_130904.log, shipped default host_tests_20261122_131114.log); the suite stayed green through the 2026-11-24 contract changes (host_tests_20261124_174158.log, 6/6).

Ablation: each detection-chain row is removable at build time via the ABL_* switches in node_config.h (families listed in tests); the leave-one-out tour results are the paper's Table A-III.

A. Per-step detection chain (1 Hz, inside the monitor) ​

#EnhancementMechanismPreventsProof
A1Settle gate v2Per-feature motion EMAs floored at CAL units (SETTLE_CALM_N=8, node_config.h:76); no train/alarm/ask mid-move; settled-only feeding keeps an ask batch = ONE stateDecisions and training on mixed-distribution data during machine moves; the poisoned-centroid bug of 2026-11-15Suite stage 2 (SIMCHECK); the 2026-11-15 bench finding (RESEARCH.md)
A2Era-gated observation spaceDeployed cond-obs: obs = (rel - c_matched)/u_matched, nearest-condition frame for unknowns. z (legacy) and rel (paper A/B) arms kept behind build flagsA global observation frame that cannot see in-radius faultsEra ablation, stage 5/6/7 verdicts: z MISSES, rel MISSES, cond CATCHES the in-radius fault
A3Per-condition score bandsEach condition calibrates gate = mu+3sd of its own prediction error after 16 samples (PERCOND_MIN_N, node_config.h:278); the global fit theta only judges unknownsA state whose converged error sits above/below the global thetaStage 5: band maturity prints per condition; re-tour recognition with 0 asks
A4Positional evidence channelpos_acc_ charges (ragg/gate_r - 1) against the matched condition's own positional band; grace-INDEPENDENT; fires while the breach stands (tinyrl_monitor.cpp:1124, 2026-11-22f)Static geometry breaches masked by grace (the VFD phase_loss miss: rows sat 45x the band while acc read 0.00)Bench paper_tour run-20261122-123134: phase_loss owner 12/0 steps; in-radius catch
A5Leaky evidence accumulatorBoth evidence terms integrate scale-free (ACC_ALARM=5, cap 20, leak ACC_DECAY); quiet steps decay, never resetOne marginal breach firing; weak breaches never accumulatingStage 2 SIMCHECK alarm/label path; stage 4 tripwire
A6Sticky hold + tenure releaseRadius-edge drift stays matched to the last condition while within MATCH_Q; a hold cannot outlive STICKY_RELEASE_N=80 settled stepsSlow wander re-judging a known state against the fit theta; a grown radius carrying foreign rows foreverStage 6 tour across block switches; the 2026-11-21 hardware finding
A7Re-entry grace + band recalibrationREENTRY_GRACE_N=16 on regime entry; a matured band whose geometry is still its own recalibrates on re-entry (the net's floor moved after the regime-entry reset)Re-alarming a known state on re-entry; a stale band that can never re-formStage 6 churn + re-tour: 0 asks
A8Floor-excess re-anchor + floor-move yield2 sustained above-gate matched steps with quiet geometry re-anchor the score band (FLOOR_EXCESS_N=2); at the fire check the score arm yields while ragg < 3x gate_r (floor_move_case, tinyrl_monitor.cpp) - single-step rag excursions includedA machine's prediction-floor drift alarm-edging every visit to a known state (the 2026-11-22d churn race: 16 alarms/cycle)Ramped churn, 20 cycles 0 alarms 0 asks (suite 131114); 17 re-anchors landed in the tour
A9Positional-excursion re-anchorAn excursion breaching the band for POS_EX_MIN_N=2+ steps that then SUBSIDES for POS_EX_SUBSIDE_N=4 while matched re-anchors the positional band MATURE at the peakThe collect block's internal warm-up re-alarming its own rows every cycleStage 6: 5 positional re-anchors, each subsiding; suite 091038 log analysis
A10Identity adaptation guardCentroid/yardstick adaptation blocked while ragg > POS_ADAPT_BLOCK (3x) * gate_r; below 3x the honest wander still adaptsAn in-radius fault walking the matched condition's centroid onto itself (speed_2 became blind to window 2 of the same fault)Stage 7 contract (CATCHES); run-110857 analysis
A11Yardstick neighborhood growthQuiet-unmatched steps near a NORMAL condition within YARDSTICK_FAR=24 grow its UNITS only, never the centroid; not while alarmedBetween-visit instrument drift parking a known state outside its tight batch radius for minutesStage 6 re-tour recognition; the 2026-11-21 rig replay finding
A12Unknown-persist gateEvidence charges only from the 2nd consecutive settled unknown stepA single transition row (the 1-second ramp midpoint) charging the nearest band ~100x in one stepRamped suite (the run-120222 mid-tour FA class eliminated)
A13Z-era legacy latchThe 2026-11-19 positional Schmitt latch (in QUIET_Q 3, out MATCH_Q 4) kept for the ablation armLosing the documented baseline that the era ablation contrasts againstStage 5 (z-era TOURCHECK, synthetic fixture by design)

B. Learning, retention, and the ask loop ​

#EnhancementMechanismPreventsProof
B1Condition libraryFlash-resident JSONL per node: slug, kind (normal/fault), centroid c, yardstick u, score band, positional band (LIB_MAX=12); labels are fleet vocabulary, centroids per nodeRetention depending on weight plasticity; re-asking named statesStage 6 full-vocabulary assert; re-tour 0 asks
B2Ask loop (episode + pending store)Alarm opens an episode; settled samples feed it; at ASK_MIN_BATCH=15 a batch is stored (survives reboot) and the ask publishes; label/discard by idAsking before evidence; losing asked questions on rebootStage 6: asks mature at >= 15 (assert); pending store round-trip
B3One-shot labels, no re-asksA label names every open occurrence; recognition on revisit is 0-ask by construction; the sticky release bounds a hold's lifeRepeated asks for the same state (operator noise)Bench run-20261122-123134: re-tour asks 0, redundant 0
B4False-alarm feedbackonFeedbackNormal desensitizes, onFeedbackFault sharpens; pos_acc_ voided at the label (the answered ask closes its own case)Post-label alarm flapping from a stale reservoir (run-112814 flaps)Stage 2; run-112814 regression fixed in 22f
B5Mixed-batch protectionsA label rescaling the input frame drops optimizer traces; relabeled episodes never refine centroids; fault episodes never refineA label poisoning the predictor or dragging a centroid across statesFrame-switch [WHY] prints; the relabelled refine guard (episode.cpp)
B6Streaming plasticity disciplineBounded OBGD updates at the floor rate once a condition's band says converged; the Dohare correlates logged ([PLAST])Loss of plasticity / dead units over 100k stepsPlasticity audit: dead 0.00, mean abs w +128%, eff rank 4.51 -> 1.88 (100k bench, 2026-11-20)
B7Persistencemodel.bin + net.bin + conditions.jsonl + pending.jsonl on LittleFS; autosave <= 5 min (flash-wear budget); versioned blobsRelearning after every reboot; flash wearStage 3: save/reload round-trip asserted; stage 2 persistence
B8DeterminismFixed SEED=12345; assert-based suite; every number regenerates from tests/Undocumented seed dependenceSuite green on demand; the 2026-11-20 seed resolution

C. The industrial wrapper (schema, fixture, observability) ​

#EnhancementMechanismPreventsProof
C1UNS two-way schema5 MQTT topics (4 State/* up, Action/feedback down), UNS-pattern paths, publish on state/condition change only; labels flow down as Action/feedbackRaw telemetry flooding upstream; oracle-locked integrationsRQ2: 113 semantic msgs vs 4,800 raw vectors = 42x fewer (2,400-step tour)
C2Real-data fixtureThe MODBUS collect campaign (150 rows/condition, labeled-only loading) is the default world for suite + bench + figuresEvaluating only on synthetic dataREALMODE line, suite stage 6
C31-second ramp synthesisOne synthesized midpoint row per ordered block pair (linear in raw feature space, confirmed tail -> confirmed head); DEFAULT ON; TINYRL_RAMP_SYNTH=0 ablatesEvaluating on unphysical instant switches; unconfirmed operator rows entering the model (labeled-only loader)Suite green in all three fixture configurations
C4Explainability telemetry[WHY] names the evidence chain per decision (which term charged, which band judged, which grace applies); [RAW] carries score/gate/rag/gate_r/acc/posref; prints carry the node idUndiagnosable field behavior; two-node log ambiguityThe 2026-11-22f/g churn traces were read from these lines
C5Operator-facing tripwireQuiet-unmatched counter (qum=, report every 1000) watching the Settles-myopia blind regionA gated learner staying confidently blind to whole regionsStage 4 TRIPCHECK
C6Per-modality feature identityFeature order/units = model identity; the vib locked to 4 features (1,348 params both nodes); META ships true names/units to the benchFigure/axis mismatches; param creepStage 6 META; tools/feature_selection.py lock
C7MCU deployment disciplinePlatformIO envs per era; static footprints measured per env (17-18% RAM / 31-32% flash); 5 us/step host proxyShipping a regression that breaks the MCU budgetrun_mcu.sh builds; paper Table III footprints

What the base core provides (unchanged) ​

The Stream-X recipe (running-moment normalisation, LayerNorm + sparse init, bounded per-parameter updates), the OBGD optimizer, the sequential net, ESP32 kernel optimizations: used as-is from the submodule. The paper's claim is the wrapper, not a modification of the learner.