jgrusewski
9b35fe9d45
plan(dqn): SP2 + SP3 implementation — fused NaN kernel + 5-mechanism Q-stability
Implementation plan for the approved combined design spec
(commit ed727b51c). Three phases:
Phase A — SP2 (5 tasks A1-A5 + Gate 1 smoke task A6):
- A1: Append dqn_nan_check_fused_f32_kernel to dqn_utility_kernels.cu
- A2: Add nan_check_buf_ptrs / nan_check_buf_lens device buffers (separate
ptr + len arrays per the design fork resolution; cleaner than packed)
- A3: populate_nan_check_meta + launch_nan_check_fused_f32 wrappers
- A4: Replace 8 individual check_nan_f32 calls with single fused launch
- A5: Audit doc Phase E + wire-up Invariant 7 entries
- A6: Gate 1 smoke — F0 ≥ 53.08 (must pass before Phase B)
Phase B — SP3 (8 tasks B1-B8 + Gate 2 smoke task B9):
- B1: Slot 36-47 diagnostic accessors (Adam m/v + weight slice + target_q + atoms)
- B2: Mech 1 — target_q clip after compute_denoise_target_q (single-point)
- B3: Mech 2 — C51 atom-position growth bounds in EMA-update kernel
- B4: Mech 3 — hard target sync (DQN main + IQN) at fold boundary
- B5: Mech 4 — comprehensive Adam EMA reset at fold transitions
- B6: Mech 5 — fused kernel extended to 24 slots with inline threshold-by-
slot-index logic (no per-step HtoD; q_abs_ref_eff passed as single arg)
- B7: Name table entries for slots 36-47 (both halt_nan + halt_grad_collapse)
- B8: Audit doc Phase F + wire-up Invariant 7 entries
- B9: Gate 2 smoke — full SP1 7-criterion validation
Phase C — Closure (2 tasks C1-C2):
- C1: project_sp2_sp3_resolved.md memory entry + SP1 closure update
- C2: Audit doc closure + wire-up final entry + push
Operating principles enforced throughout:
- ISV-driven bounds (Q_ABS_REF=16, ε on multiplier per SP1 pearl)
- No new ISV slots
- No DtoD/HtoD per step (inline-compute resolution for thresholds)
- Permanent diagnostic always-on (no debug flags)
- Per-task commits during dev; SP3 mechanisms ship together
- F0 paper-review documented per ISV bound
Plan covers ~1000 LOC across multiple commits, 2 L40S smokes (Gate 1 +
Gate 2), 4-7 days estimated. Self-review confirms full spec coverage.
2026-04-30 08:49:36 +02:00
..
2026-04-11 12:27:56 +02:00
2026-04-11 22:40:47 +02:00
2026-04-11 23:10:25 +02:00
2026-04-11 13:35:15 +02:00
2026-04-12 07:58:02 +02:00
2026-04-12 14:33:56 +02:00
2026-04-13 14:56:27 +02:00
2026-04-13 11:32:23 +02:00
2026-04-14 21:42:57 +02:00
2026-04-14 23:26:13 +02:00
2026-04-14 22:30:29 +02:00
2026-04-15 20:33:03 +02:00
2026-04-15 19:43:50 +02:00
2026-04-15 08:40:09 +02:00
2026-04-16 22:46:54 +02:00
2026-04-16 01:32:16 +02:00
2026-04-16 17:34:14 +02:00
2026-04-17 00:02:02 +02:00
2026-04-17 00:48:18 +02:00
2026-04-16 21:49:19 +02:00
2026-04-17 23:58:32 +02:00
2026-04-18 16:07:06 +02:00
2026-04-18 21:26:40 +02:00
2026-04-19 23:47:04 +02:00
2026-04-19 12:15:04 +02:00
2026-04-19 23:21:24 +02:00
2026-04-19 00:06:05 +02:00
2026-04-20 19:12:41 +02:00
2026-04-20 14:36:03 +02:00
2026-04-22 11:18:28 +02:00
2026-04-21 21:06:33 +02:00
2026-04-24 18:29:34 +02:00
2026-04-24 19:04:56 +02:00
2026-04-25 09:15:43 +02:00
2026-04-25 11:53:10 +02:00
2026-04-24 10:06:25 +02:00
2026-04-27 08:10:42 +02:00
2026-04-27 08:10:42 +02:00
2026-04-29 17:26:22 +02:00
2026-04-27 08:10:42 +02:00
2026-04-27 18:22:40 +02:00
2026-04-29 23:21:26 +02:00
2026-04-30 08:49:36 +02:00