docs/research/sota-2026-05-22/R20_2-threshold-handoff.md
Status: implementation of R20.1's catalogued refinement; mixed result reveals harmonic-rejection requirement · 2026-05-22
R20.1's naive precision-weighted Bayesian gave 84 BPM for HR when classical (105 BPM, 38% conf) disagreed with NV @ 1 m (72 BPM, 64% conf). The fix specified: when NV confidence > 60% AND amplitude > 3 pT, trust NV entirely.
| Distance | NV amp | NV rate | NV conf | Naive | Smart | Error (smart) | Regime |
|---|---|---|---|---|---|---|---|
| 0.5 m | 50.00 pT | 72.00 ✓ | 84% | 82.3 | 72.0 | +0.0 ✓ | nv_drives |
| 1.0 m | 6.25 pT | 144.00 ✗ harmonic | 67% | 129.9 | 144.0 | +72.0 ✗ | nv_drives |
| 1.5 m | 1.85 pT | 72.00 ✓ | 39% | 88.3 | 88.3 | +16.3 | weighted_fallback |
| 2.0 m | 0.78 pT | 77.00 | 36% | 91.5 | 91.5 | +19.5 | weighted_fallback |
| 3.0 m | 0.23 pT | 78.00 | 38% | 91.5 | 91.5 | +19.5 | weighted_fallback |
The threshold-based policy is correct in spirit (trust NV when good) but incorrect with simple FFT (which picks harmonics for narrow-band signals). Production needs:
R20.1's note already flagged "production needs Pan-Tompkins QRS detection". R20.2 confirms this is binding, not nice-to-have for the threshold hand-off to be safe.
This is a mixed result, honestly reported. The smart hand-off is right in principle; the FFT rate estimator beneath it is the weak link. Production fix is well-understood (Pan-Tompkins or autocorrelation), but the demo as written doesn't include it.
R20.2 is the 5-minute follow-up to R20.1. The catalogue-then-revisit pattern works: R20.1 flagged production gap; R20.2 attempted the fix; the attempt surfaced a deeper gap (harmonic rejection). Three layers of refinement in one quantum integration arc.
R20 (vision, tick 37) → Doc 17 (bridge, tick 38) → ADR-114 (spec, tick 39) → R20.1 (working demo, tick 40) → R20.2 (threshold refinement, this tick).
Five-step quantum integration arc. Production ADR-114 cog now has all known refinements catalogued before any Rust code is written.