- 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 ht. The paper formalizes backward coherence as the recoverability of ht from its successor ht+1 through a learned backward projector gϕ, 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 ht 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 L1 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,…) and introducing backward coherence as the property that ht≈E[ht∣ht+1]. In this setting, the backward projector gϕ is trained to approximate E[ht∣ht+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 ht0 below 1), empirical summability of the backward drift, and bounded approximation error of ht1.
Main Theoretical Results
The core theoretical contributions include:
- Quasi-reverse-martingale convergence for general RNNs: Under operator contraction ht2 and summable quasi-martingale drift, the theory guarantees pathwise convergence of ht3 to a limit ht4 almost surely and in ht5 (see Theorem 1). The limiting behaviour directly relates to the process's forward and backward dynamics.
- Geometric convergence rates: When the drift decays geometrically, explicit finite-sample ht6 bounds are provided (Corollary 2), offering interpretable, contractively controlled convergence speeds, validated by empirical tracking-error experiments.
- Finite-sample statistical inference: The empirical quasi-martingale total ht7, based on the backward prediction residuals ht8, 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).
- Extensions to ht9-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.
- 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:
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: Simultaneous coverage vs calibration parameter for the increment-sum tube ht+12 (solid) and defect-tail proxy ht+13 (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:
- 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.
- 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+14 diagnostic responds in real time to NBER recession boundaries, marking regime changes.
Figure 3: On FRED-MD, RMRNN’s empirical quasi-martingale total ht+15 rises sharply during each NBER recession, demonstrating sensitivity of the diagnostic to real-world concept drift.
- 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: 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.