Shunyaya Symbolic Mathematical Hardware – Software Reference: I/O & Gotchas (9.10–9.11)

9.10 — I/O sketches and templates
CSV line (emit per sample).

time,kpi,m,a,band,knobs_hash,build_id,site_id,unit_id,note
YYYY-MM-DDThh:mm:ssZ,temp_loop,412.50,0.8123,A++,8c1e..d7,ssmh,plant-2,line-7,readonly

Manifest stamp (append once per day).

SSMH-STAMP day=YYYY-MM-DD knobs={eps_a:1e-6,eps_w:1e-12} conformance=9b2e..44

Rules. Never hide m; bands are advisory. Tie each row to the manifest via knobs_hash or an equivalent checksum. Keep a bounded and clamped: a := clamp(a, -1+eps_a, +1-eps_a).


9.11 — Common gotchas (and the fix)
Unclamped map. Forgot to clamp a before atanh. Fix: always a := clamp(a, -1+eps_a, +1-eps_a) first.
Batch vs stream mismatch. {U,W} not preserved. Fix: accumulate exactly and flush with a_out := tanh(U/max(W,eps_w)).
Leaking a into value math. Used a in magnitude path. Fix: phi((m,a)) = m always; keep the value lane classical.
Band flicker. Threshold chatter. Fix: widen hysteresis and/or increase rapidity precision so |delta_a| << band_step.
Ambiguous weights. Mixed w_i definitions. Fix: declare w_i := |m_i|^gamma (default gamma = 1) in the manifest and keep it constant for the pilot.
Hidden changes. Knob drift between runs. Fix: freeze knobs in a manifest and stamp daily; compare only like-for-like manifests.


Navigation
Back: Shunyaya Symbolic Mathematical Hardware – Software Reference: C, Rust & Unit Tests (9.7–9.9)
Next: Shunyaya Symbolic Mathematical Hardware – Interop: SSMS Ports, Stamp & Domain Patterns (10.1–10.3)


Directory of Pages
SSMH – Table of Contents