How NeuraGuard works
Educational overview of the computer-side pipeline. Everything is a research simulation on synthetic or mock intention streams — never real implant signals.
Architecture
How estimation works
Transparent heuristics on decoded intention streams — not clinical models, not implant firmware.
- Stream ingest — synthetic / CSV / mock WebSocket
- Feature extractor — sliding-window speed, variance, entropy, confidence
- State estimator — EMAs → load, focus, fatigue, agency
- Policy engine — thresholds → throttle / break / privacy block
- Action dispatcher — gated sample + UI status
load = 100 * clamp(0.35*norm(meanSpeed) + 0.25*norm(speedVar) + 0.20*norm(meanAccel) + 0.15*classEntropy + 0.05*meanClick)Higher speed variance, acceleration, and class entropy raise estimated load. Pure research proxy.
focus = 100 * clamp(0.45*(1 - classEntropy) + 0.35*meanConfidence + 0.20*(1 - privateRatio) - distractionPenalty)Stable dominant class + high confidence → higher focus. Private-thought spikes reduce focus score.
fatigue = EMA(prev, raw, α=0.02); raw = 100 * clamp(sessionProgress*0.4 + loadComponent*0.35 + lowConfidence*0.25 + injectBoost)Slow EMA so fatigue accumulates over minutes. Session length and sustained load contribute.
agency = 100 * clamp(0.5*meanConfidence + 0.3*(1 - anomalyNorm) + 0.2*(1 - privateRatio))Decoder confidence and low anomaly/private ratio proxy voluntary control.
raw = 100 * clamp(0.4*z(speed) + 0.3*z(entropy) + 0.3*z(confidence_drop)); anomaly = EMA(prev, raw, α≈0.18)Z-scores vs rolling window. EMA hysteresis reduces flapping on brief spikes. Not clinical.
match = 100 * (1 - clamp(0.5*|μ_speed - base| + 0.3*|μ_entropy - base| + 0.2*|μ_conf - base|))Toy continuous auth: compares current window stats to baseline (initial capture + optional drift). Not identity verification.
if anomalyEma < driftAnomalyMax for ≥ driftStableTicks: base ← EMA(base, features, α_drift≈0.008); else freeze baseTracks slow non-stationarity so long sessions don’t false-lock. Freezes during high anomaly / anomaly injection so sudden shifts still fire policies.
Neurabridge adapter (stub)
Soft integration shape for suite middleware. Map velocity_2d / class_label events into IntentionSample. See src/lib/adapter/neurabridge-stub.ts.
{ "type": "velocity_2d", "vx": 0.1, "vy": -0.2, "t": 1710000000000 }{ "type": "class_label", "label": "click", "confidence": 0.9, "t": 1710000000000 }{ "vx": 0.1, "vy": 0.2, "clickProb": 0.1, "intentClass": "pointer", "confidence": 0.8, "publication": "draft", "t": 1710000000000 }Safety framing
- Not a medical device (not SaMD).
- Not implant firmware or vendor SDK.
- Not affiliated with Neuralink or any implant company.
- All MVP data is synthetic or user-provided mock CSV/WS.