{
  "generated": "2026-11-07",
  "author": "technique-designer",
  "round": 2,
  "status": "PENDING",
  "md": "02_technique_proposals_r2.md",
  "focus": "AASD Acc +9 (54.05 -> >63) without tip-fuse post-processing",
  "closed_before": {
    "T1": "lag peak 0 ms AASD, -31 ms Carta (<2 SE); no gain",
    "T2_ESR": {"LODO_H": 0.7489, "LODO_Acc": 71.91, "AASD_Acc": 50.68, "Carta_Acc": 50.35},
    "T3_CFNull": {"LODO_H": 0.788, "LODO_Acc": 71.74, "AASD_Acc": 52.35, "Carta_Acc": 58.57},
    "VREx": {"AASD_Acc": 51, "Carta_Acc": 48}
  },
  "references": {
    "honest_LODO": {"H": 0.7981, "Acc": 73.3},
    "tip_AASD_Acc": 54.05,
    "tip_Carta_Acc": 60.6,
    "target": {"LODO_H": 0.85, "LODO_Acc": 78, "AASD_Acc": 63, "Carta_Acc": 60}
  },
  "key_findings": {
    "aasd_switch_stats": {"trial_s": 58, "dwell_median_s": 8.9, "dwell_mean_s": 9.7, "dwell_p10_s": 3.8, "dwell_p90_s": 16.4, "frac_segments_lt5s": 0.19},
    "carta_switch_stats": {"trial_s": 173, "dwell_median_s": 25.0, "dwell_p10_s": 13.0, "dwell_p90_s": 37.0},
    "oracle_delay_acc_pct": {
      "AASD": {"0": 100, "1": 91.5, "2": 83.1, "3": 75.1, "4": 67.6, "5": 61.1, "7": 51.8, "10": 45.4},
      "Carta": {"0": 100, "1": 96.5, "2": 93.1, "3": 89.6, "4": 86.1, "5": 82.7, "7": 75.7, "10": 65.4}
    },
    "sw2_evidence_acc_vs_time_since_switch": {
      "bins_s": ["0-1", "1-2", "2-3", "3-4", "4-5", "5-6", "6-8", "8-10", "10-15"],
      "AASD": [0.439, 0.459, 0.487, 0.505, 0.518, 0.534, 0.565, 0.590, 0.603],
      "Carta": [0.384, 0.414, 0.446, 0.464, 0.513, 0.545, 0.579, 0.625, 0.636]
    },
    "tw_pooling": "near-flat learned softmax; centroid 4.4-4.7 s before window end; mass in last 2 s = 0.25 (4 all5 seeds)",
    "latency_cut_oracle_acc_pct": {
      "AASD_raw": {"0": 53.8, "1": 54.9, "2": 55.7, "3": 55.9, "4": 55.8},
      "AASD_hmm": {"0": 53.0, "1": 54.1, "2": 55.1, "3": 55.7, "4": 55.9},
      "Carta_hmm": {"0": 59.2, "1": 60.2, "2": 61.2, "3": 61.8, "4": 62.3}
    },
    "required_quality_simulation": {
      "note": "linear evidence model on real AASD label sequences; best (W, p_stay) chosen with labels -> optimistic feasibility map, calibrated: 0.60 -> 54.8 vs observed 54.05",
      "steady10s_acc_to_best_AASD_Acc": {"0.60": 54.8, "0.65": 57.3, "0.70": 59.5, "0.75": 62.0, "0.80": 64.5, "0.85": 66.9},
      "best_readout_window_s": 2
    },
    "in_domain_reference_single_seed": {"acc1_range": [0.67, 0.72], "acc10_range": [0.69, 0.78]},
    "aasd_subject_steady_acc_range": [0.491, 0.678],
    "aasd_no_label_inversion": true,
    "aasd_envelopes": {"LR_corr": 0.0, "reverse_env_fidelity_r": 0.988, "presentation": "dichotic"},
    "within_trial_linear_oracle_bound": "adapt_within_trial.csv: oracle labels -> 0.59-0.62 acc after >=3 min, <= +0.009 H",
    "conclusion": "AASD>63 needs steady 10-s accuracy ~0.78 on AASD (DTU in-domain level, ~3x today's d') plus ~2-s read-out; latency alone <= +2; probability of reaching target this round < 10%; realistic combined +2..+5 Acc"
  },
  "shared_gate_D0": {
    "name": "label-free match-mismatch tracking diagnostic",
    "method": "frozen nets; m_s = f(E, s, s_past) for s in {A,B}, s_past = same stream shifted 8-30 s back; P(m_s>0) per dataset/subject; no attention labels",
    "decision": {
      "shift": "AASD M/M acc >= 0.05 below in-domain mean -> run R2-1, R2-2",
      "ceiling": "AASD M/M acc ~ in-domain -> run only R2-3 Step 0; report AASD target infeasible"
    },
    "effort": "~20 min GPU",
    "files": {"new": ["/root/disk_3tb/eeg-thao/mm_diag.py"], "outputs": ["/root/disk_3tb/eeg-thao/results/research/mm_diag.json", "/root/disk_3tb/eeg-thao/experiments/multi_agent_opt/runs/r2_d0_mmdiag_<date>/metrics.json"]}
  },
  "acceptance_rule": "all gates pass; paired by seed AASD Acc >= +1.0 and AASD H >= +0.005, Carta Acc >= -0.3, honest LODO H drop <= 0.01; AASD/Carta attention labels never select hyperparameters; selection on LODO (LODO-fast for R2-5); user decides keep/drop",
  "gates": [
    "column_swap |f(x)+f(-x)|<1e-5",
    "position_invariance prepend 60 s -> >=99% decision agreement after 60 s",
    "leakage_test <=0.969 s",
    "per-trial state reset at trial start and depends only on a bounded past buffer"
  ],
  "candidates": [
    {
      "rank": 1, "id": "R2-1", "name": "MM-TTA: label-free match-mismatch test-time training of a zero-init low-rank EEG spatial adapter on frozen SW2 nets",
      "lever": "d' (subject/recording spatial shift)", "track": "inference + per-trial causal updates",
      "hypothesis": "AASD plateau 0.60 is partly a spatial subject shift EA does not fix; attention label too weak to adapt on in 58 s, but match-mismatch on both streams is strong, label-free, swap-symmetric and matches the SparrKULee M/M init",
      "method": "E' = E(1+g) + (E U) V^T, V,g zero-init; every 2 s re-fit from zero on last 30 s buffer (windows ending <= t+FUT), K Adam steps; L = sum_{s in A,B} softplus(-f(E', s, s_past)) + lambda||UV^T||^2 + lambda_g||g||^2; attention logit uses previous block's adapter; reset per trial; one adapter per seed",
      "not_repeat_of": ["TRN-13 pseudo-label self-training", "DEC-10 emission/logit adaptation", "TRN-06 SSL pretrain", "PRE-02/PRE-16 EA", "EXT-02 SparrKULee pretrain", "r1-T5 distractor ranking (no updates)"],
      "hyperparams": {"r": [0, 2, 4], "K": [5, 10], "lr": [0.003, 0.01], "lambda": [0.01, 0.1], "buffer_s": 30, "first_update_s": 15, "every_s": 2},
      "gates": ["D0 shift", "LODO-held acc1 >= +0.5 pt in >=4/5 folds (seed 0 first)", "abort if M/M loss falls but attention acc1 drops"],
      "expected": {"AASD_Acc": "+0..+3", "Carta_Acc": "+0..+1.5", "LODO_H": "+0..+0.01"},
      "risk": "few updates per 58-s trial; adapter may raise both-stream tracking without raising attention contrast",
      "effort": "medium: 1 d code, ~2 GPU h",
      "implementable_now": true,
      "files": {"new": ["/root/disk_3tb/eeg-thao/mm_tta.py"], "reuses": ["/root/disk_3tb/eeg-thao/lagbank_sel.py (configure, load_nets, external_targets)", "R/direct_classifier.py (DirectNet, logits)"],
        "reads": ["R/models/all5_direct_clf_w10b3sw2P_s{0..3}.pt", "R/models/fold_direct_clf__eaP_n5_t60_w10b3_ptSPK[_s{1,2,3}]_aug-sw2_wts__{DS}.pt", "R/models/pretrain_spk_direct_clf_w10_b3_s{0..3}.pt"],
        "outputs": ["/root/disk_3tb/eeg-thao/results/research/mm_tta.json", "/root/disk_3tb/eeg-thao/experiments/multi_agent_opt/runs/r2_mmtta_<date>/"]}
    },
    {
      "rank": 2, "id": "R2-2", "name": "SAA: stimulus-anchored alignment (causal per-trial Procrustes of the label-free auditory-response spatial pattern onto the population pattern)",
      "lever": "d' (spatial shift of auditory subspace)", "track": "new prep; frozen screen then retrain",
      "hypothesis": "EA whitens total covariance dominated by non-auditory activity; the auditory pattern (cross-cov of EEG with mixture A+B, swap-invariant, label-free) rotates across subjects/caps; aligning it puts the auditory subspace where the classifier expects it",
      "method": "after eaP_n5_t60: exp-forgotten cross-cov EEG x (A+B) lags 0-375 ms (tau 30 s), shrink to population P0 (kappa), orthogonal Procrustes R_t, apply rotation from strictly earlier samples; screen at test time only with frozen nets, then prep saa_eaP + retrain 4 seeds x 6 ckpts",
      "not_repeat_of": ["PRE-02/PRE-16 EA grid", "PRE-17 cross-trial EA", "PTA-02 DSS/SSD->TRF", "ARC-09 channel FiLM/graph/SE", "PTA-01 CCA-spatial"],
      "hyperparams": {"tau_s": [20, 40], "kappa_s": [10, 30], "lags_ms": [0, 375], "alpha_geodesic": [0.5, 1.0]},
      "gates": ["label-free: cosine(P_subject, P0) rises on AASD and LODO-held", "LODO acc1 not lower in >1/5 folds", "AASD read once at the end", "skip if D0 = ceiling"],
      "expected": {"AASD_Acc": "+0..+2", "Carta_Acc": "+0..+1", "LODO_H": "+-0.005"},
      "risk": "pattern estimate noisy in 58 s; shrinkage may erase gain",
      "effort": "medium-high: screen 0.5 d CPU/GPU; retrain ~12 GPU h",
      "implementable_now": true,
      "files": {"new": ["/root/disk_3tb/eeg-thao/saa_align.py", "/root/disk_3tb/eeg-thao/build_saa_prep.py"], "outputs": ["/root/disk_3tb/eeg-thao/results/research/saa_screen.json", "cache/saa_eaP/*.npz (retrain stage)"]}
    },
    {
      "rank": 3, "id": "R2-3", "name": "PAD: presentation-aware dominance input (dichotic-consistent dom)",
      "lever": "d' (stimulus-view shift)", "track": "frozen diag then retrain",
      "hypothesis": "dom (normalised envelope dominance, glimpse/energetic-masking model) is meaningful for free-field/HRTF mixtures but not for dichotic presentation (AASD); KUL2016 has dichotic and HRTF trials -> testable in-domain",
      "method": "Step 0: KUL-held fold ckpts, acc1 by condition x {dom, dom:=0}; dom ablation on all folds + AASD/Carta. Step 1 (if pass): presentation dropout clf_p_dom_null=0.5 (dom:=0), optional physical presentation flag only if test metadata; retrain 4 seeds x 6 ckpts",
      "not_repeat_of": ["TRN-07 featdrop (condition-blind)", "PRE-23 glimpse features", "TRN-09 C5 montage aug"],
      "hyperparams": {"p_dom_null": [0.3, 0.5]},
      "gates": ["Step 0: dom ablation hurts HRTF but neutral/helps dichotic, or dichotic >=2 pt below HRTF", "LODO H drop <= 0.005"],
      "expected": {"AASD_Acc": "+0..+2", "Carta_Acc": "+-0.5", "LODO_H": "-0.005..+0"},
      "risk": "test-set presentation unknown; may help only the AASD proxy",
      "effort": "low diag (~30 min) / medium retrain (~8 GPU h)",
      "implementable_now": true,
      "files": {"new": ["/root/disk_3tb/eeg-thao/pad_diag.py"], "edits_workspace_copy": ["windows(): aug key clf_p_dom_null"], "outputs": ["/root/disk_3tb/eeg-thao/results/research/pad_diag.json"]}
    },
    {
      "rank": 4, "id": "R2-4", "name": "MC-mask TTA: test-time ensemble over in-distribution channel/cluster masks",
      "lever": "variance part of d'", "track": "inference-only",
      "method": "M fixed pseudo-random masks (same for all trials, no state) per seed matching training aug (p_chan 0.2, cluster 3-8); average logits",
      "not_repeat_of": ["ENS-01/02 seed averaging/stacking", "TRN-07 train-time aug"],
      "hyperparams": {"M": [8, 16, 32], "mask_rate": [0.1, 0.2]},
      "expected": {"AASD_Acc": "+0..+0.7", "Carta_Acc": "+0..+0.5", "LODO_H": "+0..+0.003"},
      "effort": "low", "implementable_now": true,
      "note": "run only as a stack on a passing d' candidate"
    },
    {
      "rank": 5, "id": "R2-5", "name": "SR-Pool + LODO-fast: training-free short re-pooling of per-position logits + fast-dwell LODO scoring track",
      "lever": "latency (multiplier)", "track": "inference-only",
      "method": "re-pool per-position logits h(B,W) with causal kernel over last T_p in {2,3,4} s; refit HMM emissions on LODO-fast schedules dwell ~ LogU(3,20) s (generic prior, not AASD-fitted)",
      "overlap_warning": "readout-family (BOARD discourages); partial overlap ARC-01, DEC-02; companion only, never standalone claim",
      "expected": {"AASD_Acc": "+0.5..+1.5 alone; x1.5-2 on top of a d' gain (sim: steady 0.80 -> 64.5 fast vs 60.0 10-s)"},
      "effort": "low", "implementable_now": true
    }
  ],
  "rejected": [
    {"idea": "label-free per-trial mixture decoder / forward-TRF LLR", "reason": "oracle-label within-trial linear decoder 0.59-0.62 after 3 min, +0.009 H; AASD trials 58 s; PTA-01 at chance on AASD"},
    {"idea": "alpha lateralisation / FBCSP", "reason": "test format 1-9 Hz; ARC-03/PTA-03 closed"},
    {"idea": "wav2vec/Whisper stimulus features", "reason": "no raw audio for training corpora"},
    {"idea": "key-press motor/LRP cues", "reason": "AASD-specific confound, not attention; absent in test; integrity"},
    {"idea": "more real-switch training data", "reason": "TRN-12; none on disk"},
    {"idea": "stimulus-conditioned switch hazard", "reason": "decision layer; unlearnable without real switches; latency bound ~+2"},
    {"idea": "AASD envelope re-extraction", "reason": "fidelity r 0.988; dichotic L/R corr 0.000"},
    {"idea": "raw vs processed AASD EEG / per-dataset prep", "reason": "selection on eval labels; no transfer"}
  ],
  "top3": ["R2-1", "R2-2", "R2-3"],
  "order": ["D0", "if shift: R2-1 (seed 0, LODO first) + R2-2 screen (CPU); if ceiling: R2-3 Step 0 and report infeasible", "stack R2-4, R2-5 on any passing d' candidate", "confirm seeds 1-3 before claim"]
}
