Phase-Delay Spectral Margin for Attractor RNNs
Implementation & benchmark of arXiv:2609.02047 — Phase-delays shape multistability and basin sizes in Kuramoto networks: analytical estimates from network structure
Source paper: Phase-delays shape multistability and basin sizes in Kuramoto networks: analytical estimates from network structure arXiv:2609.02047 ⓘ · analyzed Sep 3, 2026
AI-generated research hypothesis, automatically tested. Not peer-reviewed.
Idea description
Build a continuous-time or discretized recurrent network whose interaction graph has trainable magnitudes and phase delays, then regularize the spectrum of the phase-corrected interaction matrix around each desired latent phase-locked state. The cosine-weighted composite matrix determines whether perturbations contract or grow, providing a computable stability margin instead of relying only on empirical exploding-gradient detection.
Formulas
Mathematical statement
For a phase network with node phases \(\theta_i\), adjacency weights \(A_{ij}\ge 0\), coupling strength \(K>0\), natural frequencies \(\omega_i\), and edge delay \(\alpha_{ij}\), use \(\dot\theta_i=\omega_i+K\sum_j A_{ij}\sin(\theta_j-\theta_i-\alpha_{ij})\). A phase-locked state \(\theta_i^*(t)=\Omega t+\psi_i\) has perturbation Jacobian \(J=-K L_C\), where \(C_{ij}=A_{ij}\cos(\psi_j-\psi_i-\alpha_{ij})\) and \(L_C=\operatorname{diag}(C\mathbf 1)-C\). The composite spectrum determines local stability: every non-gauge eigenvalue of \(J\) must have negative real part, equivalently \(\operatorname{Re}\lambda_k(L_C)>0\). For a discrete Euler update with step size \(\eta\), the local map is \(\delta\theta_{t+1}=(I+\eta J)\delta\theta_t\), requiring \(|1-\eta K\lambda_k(L_C)|<1\) for every mode.
Implementation notes
1. Integration point: use a phase-valued recurrent cell or neural ODE with hidden state \(\theta\in\mathbb R^n\). Parameterize nonnegative edge magnitudes by \(A_{ij}=\operatorname{softplus}(a_{ij})\), and learn delays \(\alpha_{ij}\) modulo \(2\pi\). Add an input-dependent frequency term \(\omega_i=W_i x_t+b_i\). 2. Pseudocode: estimate a candidate locked state \(\psi\) by averaging the latent phase trajectory after teacher forcing; compute \(C_{ij}=A_{ij}\cos(\psi_j-\psi_i-\alpha_{ij})\); form \(L_C=\operatorname{diag}(C\mathbf 1)-C\); estimate eigenvalues using a dense eigensolver for small models or Arnoldi/power iterations for sparse models; add \(\mathcal L_{\mathrm{spec}}\) to the task loss; backpropagate through the eigensolver or use a detached spectral estimate for a slower control update. At inference, choose \(\eta\) below the largest value satisfying \(\max_k|1-\eta K\lambda_k|<1\). 3. Computed from the paper's mechanism: the cosine phase-delay composite matrix and its spectral stability test. Estimated empirically: the candidate locked state and basin volume. 4. First cheap experiment: train a 16-unit phase RNN on adding-machine sequences and compare a standard recurrent cell with the spectral-regularized cell at matched parameter count. Sweep \(\eta K\), record hidden-state norms, gradient norms, and recovery after perturbing a locked trajectory. The quantitative prediction is a sharp instability boundary at \(|1-\eta K\lambda_k|=1\); for an approximately real spectrum, measured divergence should begin within 20% of \(\eta_c=2/(K\lambda_{\max}(L_C))\). Increasing the minimum real eigenvalue by \(\gamma\) should increase the perturbation-decay rate approximately as \(K\min_{k\ne\mathrm{gauge}}\operatorname{Re}\lambda_k(L_C)\).
Verification
Stage 1 · Toy mechanism gate: Passed ✓
Stage 2 · Mechanism transferred to benchmark: Confirmed ✓
Stage 2 · Practical benchmark result: Inconclusive
Methodology: 8 paired seeds, permutation test (p<0.05) against a learning-rate-tuned baseline. How verification works
Stage 1 — Mechanism check agent confidence 8/10
Built a phase-delay RNN with trainable nonnegative edge magnitudes, bounded phase delays, differentiable composite-Laplacian spectral regularization, and Euler stability diagnostics. The toy check reproduced the predicted boundary: amplification was 0.60 at 0.8ηc, 1.00 at ηc, and 1.40 at 1.2ηc. In the matched mini-run, the idea improved the minimum real spectral margin from 0.341 to 3.295, reduced maximum Euler amplification from 0.959 to 0.606, and reduced 12-step perturbation gain from 0.334 to 0.120, but task MSE worsened from 0.000172 to 0.00561; thus the stability effect is real, but task-performance benefit was not demonstrated.
- Agent confidence
- 8/10
- Baseline
- task_mse=0.000172; min_real_eigenvalue=0.341; max_euler_amplification=0.959; 12_step_perturbation_gain=0.334
- Idea
- task_mse=0.00561; min_real_eigenvalue=3.295; max_euler_amplification=0.606; 12_step_perturbation_gain=0.120
Limitations: Only one small synthetic sequence task and one fixed random seed were tested; no adding-machine benchmark, multi-seed statistics, FLOP/speed comparison, long-horizon generalization, or larger attractor-RNN evaluation was performed. The perturbation test uses a short 12-step zero-input rollout, and the spectral penalty uses a dense eigensolver.
How to run: python3 experiment.py
Stage 2 — Benchmark vs. tuned baseline (arXiv:2609.02047)
No significant difference vs. the tuned baseline (+1.5%, p=0.8489, wins 3 / 8 paired seeds).
- Benchmark
- Dynamics forecasting
- Model
- rnn_small
- Paired seeds
- 8
- Baseline mean
- 0.0003
- Idea mean
- 0.0003
- Effect (Δ)
- 0 (+1.5%; negative = idea better)
- Wins
- 3 / 8 paired seeds
- p-value
- 0.8489 (permutation test, 20 000 shuffles)
- Smallest detectable effect
- ±31.1%
- Mechanism
- Confirmed ✓
- Practical effect
- Inconclusive
- Baseline tuning
- swept over 3 configs
Only the registered built-in dynamics track was tested. The intervention uses a dense 64-by-64 eigensolver and was evaluated for 15 epochs on 1000 training and 300 test examples; larger models, longer horizons, and broader generalization were not tested.
How to run: python3 bench_phase_margin.py
Verdict computed by deterministic test code from paired-seed statistics — not by the language model.
Stage 2 — Benchmark latest Failed ✗
Agent confidence: 9/10
The phase-delay spectral-margin GRU was evaluated against the matched standard rnn_small GRU on the registered dynamics track. The intervention produced a positive trained-model stability signal, but independent task MSE was slightly worse and the paired permutation test was not significant, so this is not a benchmark win.
- Baseline
- test MSE mean=0.000254957890319929, best lr=0.006
- Idea
- test MSE mean=0.00025879375971271656, best lr=0.006; delta_mean=+0.000003835869392787572; p=0.84895
Benchmark result
No significant difference vs. the tuned baseline (+1.5%, p=0.8489, wins 3 / 8 paired seeds).
- Benchmark
- Dynamics forecasting
- Model
- rnn_small
- Paired seeds
- 8
- Baseline mean
- 0.0003
- Idea mean
- 0.0003
- Effect (Δ)
- 0 (+1.5%; negative = idea better)
- Wins
- 3 / 8 paired seeds
- p-value
- 0.8489 (permutation test, 20 000 shuffles)
- Smallest detectable effect
- ±31.1%
- Mechanism
- Confirmed ✓
- Practical effect
- Inconclusive
- Baseline tuning
- swept over 3 configs
Only the registered built-in dynamics track was tested. The intervention uses a dense 64-by-64 eigensolver and was evaluated for 15 epochs on 1000 training and 300 test examples; larger models, longer horizons, and broader generalization were not tested.
How to run: python3 bench_phase_margin.py
Artifacts
- bench_phase_margin.py 6.2 KB View Raw
- bench_report.json 3.6 KB View Raw
- experiment.py 6.0 KB View Raw
- report.md 1.5 KB View
- report_bench_2026-09-03T115720.md 3.7 KB View
- results.json 1.6 KB View Raw