# Mittag-Leffler Memory Diagnostic and Gating

- ID: 585
- Canonical URL: https://synthcore.org/idea/585/mittag-leffler-memory-diagnostic-and-gating
- API JSON: https://synthcore.org/api/idea/585.json
- API Markdown: https://synthcore.org/api/idea/585.md
- Verification status: mech_ok_no_baseline
- Source: [arXiv:2607.08588](https://arxiv.org/abs/2607.08588)
- Category: architecture
- Solves: accuracy, stability, sample-efficiency
- ML areas: ssm, rnn, optimizer, training-dynamics
- Math tags: dynamical-systems, statistics, stochastic-processes, pde, numerical-analysis
- Ratings: usefulness 7/10; difficulty 6/10; novelty 7/10

## Idea description

Measure how validation forecast error grows with prediction horizon and fit exponential and Mittag-Leffler models. When the Mittag-Leffler fit is decisively better, activate a fractional-memory SSM or long-memory residual branch and use its fitted effective order to set the branch's kernel decay and horizon-loss weights; otherwise retain a conventional recurrent or finite-memory branch.

## Mathematical statement

For a scalar observable or neural predictor, let $e(h)$ be the mean or median forecast error at horizon $h$, and let $E_\alpha(z)=\sum_{k=0}^{\infty}z^k/\Gamma(\alpha k+1)$ be the one-parameter Mittag-Leffler function. Compare $e_{\exp}(h)=A\exp(\lambda h)+C$ with $e_{\mathrm{ML}}(h)=A E_\alpha(\lambda h^\alpha)+C$, where $A>0$ is an amplitude, $\lambda$ is a growth or decay rate, $C\geq0$ is an error floor, and $0<\alpha\leq1$ is an effective shape/order parameter. For stable relaxation use $e_{\mathrm{ML}}(h)=A E_\alpha(-\lambda h^\alpha)+C$ with $\lambda>0$. Select the fractional branch only when cross-validated RMSE or an information criterion for the Mittag-Leffler fit is lower by a preset margin and bootstrap confidence intervals for the improvement exclude zero. The paper's kNN contraction analogue is $e_{kNN}(h)=\operatorname{median}_{i}\|\hat{x}_{i+h}-x_{i+h}\|$, estimated from nearest-neighbor forecasts; its role is to diagnose whether errors contract, remain bounded, or grow. The transferable mechanism is the shape of $e(h)$ and its local logarithmic slope $q(h)=d\log(e(h)-C)/d\log h$, not an assertion that $\alpha$ exactly equals the physical fractional derivative order.

## Key formulas

- $$E_\alpha(z)=\sum_{k=0}^{\infty}\frac{z^k}{\Gamma(\alpha k+1)},\qquad e_{\exp}(h)=A e^{\lambda h}+C,$$
- $$e_{\mathrm{ML}}(h)=A E_\alpha(\lambda h^\alpha)+C\quad\text{or, for stable decay,}\quad e_{\mathrm{ML}}(h)=A E_\alpha(-\lambda h^\alpha)+C,$$
- $$q(h)=\frac{d\log(e(h)-C)}{d\log h}=\frac{h\,e'(h)}{e(h)-C},$$
- $$\hat{\alpha},\hat{\lambda},\hat A,\hat C=\arg\min_{\alpha,\lambda,A,C}\sum_{h\in\mathcal H}\left[e_{\mathrm{val}}(h)-A E_\alpha(\lambda h^\alpha)-C\right]^2.$$

## Implementation notes

1. Exact integration point: train a two-branch sequence predictor. Branch B is a standard GRU or diagonal SSM; branch F is a fractional-memory SSM whose state input uses a truncated power-law convolution, $m_t=\sum_{j=0}^{L-1}w_j u_{t-j}$ with $w_j\propto(j+1)^{\alpha-1}$, followed by a learned linear state update. Start with both branches available, but stop gradients through the diagnostic gate during each diagnostic window. 2. Pseudocode: collect validation errors for horizons $\mathcal H=\{1,2,4,8,16,32,64\}$; compute $e(h)$ over identical examples; fit exponential and Mittag-Leffler curves by bounded nonlinear least squares with $0.1\leq\alpha\leq1.5$, $A\geq0$, unrestricted $\lambda$, and $C\in[0,\min_h e(h)]$; bootstrap examples to obtain $\Delta=\mathrm{RMSE}_{\exp}-\mathrm{RMSE}_{\mathrm{ML}}$; if $P(\Delta>0)>0.95$, set gate $g=1$ and use the fractional branch, otherwise set $g=0$ and use the conventional branch. For training, weight horizon $h$ by $w_h\propto1/[e_{\mathrm{ML}}(h)+\epsilon]$ for stable tasks or by $w_h\propto e_{\mathrm{ML}}(h)^{-1/2}$ for growing-error tasks, then normalize $\sum_h w_h=1$. 3. Computed versus estimated: evaluate $E_\alpha$ numerically using a special-function library or truncated series; estimate all curve parameters, the error floor, gate, and convolution scale from held-out errors. Refit every 1,000 to 10,000 updates to avoid noisy gating. 4. First cheap experiment: generate 10,000 sequences from a scalar Caputo relaxation process and a fractional chaotic benchmark at $\alpha\in\{0.5,0.8,1.0\}$, and train equal-size GRU, diagonal SSM, and gated two-branch models. Use a standard GRU as baseline and reserve 20% of trajectories for diagnostics. The falsifiable signature is that fractional data produce lower Mittag-Leffler fit error with bootstrap $P(\Delta>0)>0.95$, whereas integer-order data do not; the gated model should improve 64-step rollout RMSE by at least 10% only in the fractional regime. As the generating order approaches $\alpha=1$, the fitted effective order should approach one and the fractionality gate should switch off. A failure is no separation in fit quality or activation on integer-order data above 5% of trials.

## Verification

- Status: mech_ok_no_baseline
- Mechanism evidence: yes
- Mechanism confirmed: yes
- Practical verdict: no_effect
- Verdict: Built a Mittag-Leffler memory diagnostic MVP with numerical evaluation, bounded exponential/ML fitting, bootstrap-style gating, and saved results. The three mechanism checks matched predictions: short-time slope tracked alpha, half-life scaled as lambda^(-1/alpha), and long-time relaxation slope tracked -alpha; the gate activated for alpha=0.5/0.8 with 22.0%/24.8% relative fit gains and correctly rejected alpha=1.0 at a 2.9% gain. This demonstrates the diagnostic mechanism, but not an end-to-end neural SSM accuracy win.

### Mechanism check

- Verdict: Built a Mittag-Leffler memory diagnostic MVP with numerical evaluation, bounded exponential/ML fitting, bootstrap-style gating, and saved results. The three mechanism checks matched predictions: short-time slope tracked alpha, half-life scaled as lambda^(-1/alpha), and long-time relaxation slope tracked -alpha; the gate activated for alpha=0.5/0.8 with 22.0%/24.8% relative fit gains and correctly rejected alpha=1.0 at a 2.9% gain. This demonstrates the diagnostic mechanism, but not an end-to-end neural SSM accuracy win.
- Confidence: 8/10
- Limitations: No GRU/SSM branch was trained, no real trajectory dataset or 64-step neural rollout was evaluated, and the bootstrap used repeated synthetic noisy validation curves rather than independent held-out trajectories. The evaluator is specialized to stable negative-argument Mittag-Leffler relaxation and is not a general high-precision implementation for all complex or positive arguments.

### Practical benchmark

- Paired seeds: 8
- Baseline mean: 0
- Idea mean: 0
- p-value: 0.9929
- Paired wins: 2/8
- Benchmark verdict: no measurable effect

## Artifacts

- [bench_mittag_gate.py](https://synthcore.org/code/267/bench_mittag_gate.py)
- [bench_report.json](https://synthcore.org/code/267/bench_report.json)
- [ml_memory_experiment.py](https://synthcore.org/code/267/ml_memory_experiment.py)
- [report.md](https://synthcore.org/code/267/report.md)
- [report_bench_2026-08-30T235228.md](https://synthcore.org/code/267/report_bench_2026-08-30T235228.md)
- [results.json](https://synthcore.org/code/267/results.json)
- [Download all files as ZIP](https://synthcore.org/download/267)

## Disclaimer

AI-generated research hypothesis, automatically tested. Not peer-reviewed.
