Papers
Topics
Authors
Recent
Search
2000 character limit reached

Backward Coherence and Hidden-State Stability in Recurrent Neural Networks: A Quasi-Reverse-Martingale Theory

Published 8 Jun 2026 in cs.LG, stat.AP, stat.CO, stat.ME, and stat.ML | (2606.08934v1)

Abstract: Recurrent neural networks maintain a hidden state $h_t$, but its probabilistic meaning is often unclear. We study hidden-state stability through \emph{backward coherence}: the extent to which $h_t$ can be reconstructed from $h_{t+1}$ by a learned backward projector $g_φ$. Under contraction and summable backward drift, the hidden-state sequence forms a quasi-reverse-martingale. This yields almost-sure convergence, rates under mixing, an interpretable limiting representation, finite pathwise stopping times, and a theoretical framework for time-uniform confidence sequences. Simulations support the theory. Backward-coherence regularisation reduces the empirical quasi-martingale total $\hat Q$ by $43$--$58%$, reaches stability $28$--$44%$ earlier than an unregularised RNN, and gives tracking-error recovery consistent with geometric bounds. Additional tests confirm echo-state forgetting rates bounded by $ρ$ and verify the increment-sum tube $R_t$ with $100%$ simultaneous coverage, although $R_t$ is conservative; in practice, the defect-tail proxy $\hat Q_t$ is the more useful monitor. The backward-coherence loss is also equivalent to minimising a Kullback--Leibler divergence in a Gaussian backward model, linking the method to variational inference. Extensions cover $φ$-mixing inputs, change-point tracking, and finite-sample concentration. Three real-data studies further validate the approach. On PhysioNet 2012 ICU data, the Reverse Martingale RNN (RMRNN) matches RNN mortality-prediction AUC while reaching stable representations 13 hours earlier. On FRED-MD, it reduces one-month-ahead forecast error by about fourfold under concept drift. On UCI Human Activity Recognition, it maintains lower post-transition tracking error with geometric decay. The guarantees apply under the stated assumptions; universality is not claimed.

Authors (1)

Summary

  • The paper establishes a quasi-reverse-martingale framework that guarantees RNN hidden-state convergence under contraction and drift conditions.
  • It provides geometric convergence bounds and finite-sample concentration results, validated by empirical tracking-error experiments.
  • Backward-coherence regularisation is introduced to enhance RNN stability, offering actionable stopping rules and observable diagnostics.

Backward Coherence and Hidden-State Stability in Recurrent Neural Networks: A Quasi-Reverse-Martingale Theory

Introduction and Motivation

This work addresses a fundamental open problem in RNN theory: the probabilistic characterisation and stability of the hidden state hth_t. The paper formalizes backward coherence as the recoverability of hth_t from its successor ht+1h_{t+1} through a learned backward projector gϕg_\phi, motivated by sequential prediction tasks where stable and interpretable hidden states are critical. The central contribution is the development of a quasi-reverse-martingale framework for hidden-state convergence, nearly eliminating reliance on untestable parametric or distributional assumptions. Key practical questions are addressed, including whether and when hth_t converges, under what conditions, and how its stabilisation can be effectively diagnosed or enforced in real-world RNNs.

Quasi-Reverse-Martingale Framework for RNNs

Reverse martingales underlie the probabilistic theory of conditional-mean convergence. Unlike the forward martingale, which conditions on an expanding filtration and typically requires uniform integrability for pathwise convergence, the reverse-martingale conditions adapt to decreasing filtrations, automatically enforcing L1L^1 convergence and yielding limits as conditional expectations with much weaker requirements.

The paper instantiates this probabilistic machinery for the sequence of RNN hidden states by leveraging the backward filtration Ftbwd=σ(ht,ht+1,)\mathcal{F}_t^{\mathrm{bwd}} = \sigma(h_t, h_{t+1}, \ldots) and introducing backward coherence as the property that htE[htht+1]h_t \approx E[h_t | h_{t+1}]. In this setting, the backward projector gϕg_\phi is trained to approximate E[htht+1]E[h_t | h_{t+1}], yielding a distribution-free, data-adaptive criterion for hidden-state stability.

The connection to reverse martingales is rigorous: for linear RNNs with decaying learning rate, the hidden state is an exact reverse martingale and almost-sure convergence to the mean follows from Doob's classical result. For nonlinear or gated RNNs, the quasi-reverse-martingale structure is established under explicit, verifiable criteria—primarily a contraction property (spectral norm of hth_t0 below 1), empirical summability of the backward drift, and bounded approximation error of hth_t1.

Main Theoretical Results

The core theoretical contributions include:

  1. Quasi-reverse-martingale convergence for general RNNs: Under operator contraction hth_t2 and summable quasi-martingale drift, the theory guarantees pathwise convergence of hth_t3 to a limit hth_t4 almost surely and in hth_t5 (see Theorem 1). The limiting behaviour directly relates to the process's forward and backward dynamics.
  2. Geometric convergence rates: When the drift decays geometrically, explicit finite-sample hth_t6 bounds are provided (Corollary 2), offering interpretable, contractively controlled convergence speeds, validated by empirical tracking-error experiments.
  3. Finite-sample statistical inference: The empirical quasi-martingale total hth_t7, based on the backward prediction residuals hth_t8, serves as a powerful observable diagnostic. New results characterize pathwise stopping times for stabilisation, provide robust pathwise (anytime-valid) confidence sets, and yield finite-sample concentration inequalities (Propositions 3–5).
  4. Extensions to hth_t9-mixing and non-stationary inputs: The theory encompasses dependent (mixing) and piecewise stationary processes—a critical generalization given the prevalence of concept drift and regime switching in practice. Explicit decompositions relate concept drift, recovery rates, and empirical stability diagnostics.
  5. Variational perspective: Minimizing the backward-coherence regularizer is shown to be equivalent to minimizing a KL divergence between the true conditional backward distribution and a learned Gaussian model, connecting the work to empirical Bayes and amortized inference paradigms.

Algorithmic and Practical Implications

Backward-coherence regularisation can be implemented as a lightweight loss-augmented term during RNN training. Its minimization constrains the model to produce hidden states compatible with a backward-consistent conditional mean, quantifiably reducing empirical trajectory instability, as measured by the observable drift and total residuals.

The framework provides statistical stopping rules—empirically, the time at which the per-step residual drops below a threshold can be interpreted as the point at which the model's representation is trustworthy for downstream predictions or actions.

Empirical Validation

Simulation Studies

Comprehensive synthetic experiments validate the theoretical predictions. Key findings include:

  • Backward-coherence regularisation reduces the empirical quasi-martingale total ht+1h_{t+1}0 by 43–58% compared to an unregularised baseline.
  • Regularised RNNs achieve the stability threshold (predefined tolerance in stepwise difference) 28–44% earlier across i.i.d., AR(1), and piecewise-stationary settings.
  • The empirical rate of hidden-state forgetting matches or beats the predicted geometric rate implied by the spectral norm, confirming sharpness. Figure 1

    Figure 1: Echo-state forgetting: normalized mean discrepancy decays at or faster than the predicted geometric rate ht+1h_{t+1}1, verifying the theoretical upper bound on contraction-induced forgetting.

Confidence Sequences and Monitoring

A critical diagnostic is the increment-sum tube, which, via the triangle inequality, always covers the final (infinite-horizon) hidden state with probability 1; however, it is highly conservative in practice (see Table 7 and Figure 2). A calibrated defect-tail proxy based on the sum of backward prediction residuals offers much tighter, interpretable pathwise confidence sequences with high empirical coverage. Figure 2

Figure 2: Simultaneous coverage vs calibration parameter for the increment-sum tube ht+1h_{t+1}2 (solid) and defect-tail proxy ht+1h_{t+1}3 (dashed); the direct tube is always valid, whereas the defect-tail proxy requires minimal calibration for 95% coverage.

Real-World Applications

Three canonical real data domains highlight the utility and generality of the framework:

  1. Clinical time series (PhysioNet ICU): Backward-coherence-regularized RNNs reach a stable latent representation 13 hours earlier than unregularised baselines in 48-hour ICU trajectories, without sacrificing predictive AUC.
  2. Macroeconomic forecasting (FRED-MD): The regularized model reduces one-month-ahead forecast error fourfold against the unregularized baseline under persistent regime drift. The empirical ht+1h_{t+1}4 diagnostic responds in real time to NBER recession boundaries, marking regime changes. Figure 3

    Figure 3: On FRED-MD, RMRNN’s empirical quasi-martingale total ht+1h_{t+1}5 rises sharply during each NBER recession, demonstrating sensitivity of the diagnostic to real-world concept drift.

  3. Human Activity Recognition (UCI HAR): Following discrete regime switches, the post-transition tracking error decays geometrically consistent with the predicted rate, and the RMRNN maintains lower tracking error relative to the baseline throughout the transition. Figure 4

    Figure 4: Post-transition mean tracking-error decays geometrically, as predicted, with RMRNN maintaining consistently lower error than the baseline baseline after discrete regime switching.

Theoretical and Practical Implications

The work provides the first comprehensive reverse martingale-based convergence theory for RNNs, directly linking architectural properties (contraction), process properties (input mixing and drift), and observable diagnostics (backward-coherence residuals) to provable stability guarantees and actionable practice. Backward-coherence regularisation, when paired with traditional contraction requirements and suitable projector learning schedules, offers quantifiable, interpretable stabilisation of RNN representations.

These results enable the construction of anytime-valid pathwise confidence sets, facilitate the use of practical finite-horizon diagnostics for hidden-state stability, and directly inform the deployment of RNNs in online, safety-critical, or non-stationary environments.

The theoretical machinery—Krickeberg decomposition, pathwise tubes, and identifying observable perturbation bounds for hidden-state limits—is modular and potentially extendable to broader classes of architectures, especially those with controlled recurrence or attention.

Future Directions

Several open technical directions are identified:

  • Formal derivation of backward Markov sufficiency for specific activations and gating structures.
  • Extension to growing-dimensional or hierarchical hidden dynamics.
  • Non-asymptotic finite-sample bounds for stabilization time and residuals.
  • Extension of the quasi-reverse-martingale theory to transformer architectures by defining analogous backward filtrations.

Conclusion

This work develops a comprehensive, nonparametric theory for hidden-state convergence and stability in RNNs based on quasi-reverse-martingale analysis. Strong observable convergence diagnostics and regularisation strategies are theoretically grounded, empirically validated, and readily applicable to a wide array of sequential learning problems. These results position backward coherence as a central diagnostic and control mechanism in practical time series modeling, with clear implications for both model design and deployment under drift and dynamical uncertainty.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Collections

Sign up for free to add this paper to one or more collections.

Tweets

Sign up for free to view the 1 tweet with 11 likes about this paper.