KOSS: Kalman-Optimal Selective State Spaces for Long-Term Sequence Modeling

Lei Wang, Xin Tan, Mingwei Wang, Ying Zhang
12/18/2025
cs.LG

No official code found. Best implementation: wl822513/KOSS (1 star, last commit 2025-09-30).

Abstract

Recent selective state space models (SSMs), such as Mamba and Mamba-2, have demonstrated strong performance in sequence modeling owing to input-dependent selection mechanisms. However, these mechanisms lack theoretical grounding and cannot support context-aware selection from latent state dynamics. To address these limitations, we propose KOSS, a Kalman-optimal Selective State Space model that formulates selection as latent state uncertainty minimization. Derived from estimation theory, KOSS adopts a continuous-time latent update driven by a Kalman gain that dynamically modulates information propagation based on content and context, enabling a closed-loop, context-aware selectivity mechanism. To ensure stable computation and near-linear scalability, KOSS employs global spectral differentiation for frequency-domain derivative estimation, along with a segment-wise scan for hardware-efficient processing. On a selective copying task with distractors, KOSS achieves over 79\% accuracy while baselines drop below 20\%, demonstrating robust context-aware selection. Furthermore, across nine long-term forecasting benchmarks, KOSS reduces MSE by 2.92--36.23\% and consistently outperforms state-of-the-art models in both accuracy and stability. To assess real-world applicability, a case study on secondary surveillance radar (SSR) tracking confirms KOSS's robustness under irregular intervals and noisy conditions and demonstrates its effectiveness in real-world applications. Finally, supplementary experiments verify Kalman gain convergence and the frequency response of spectral differentiation, providing theoretical support for the proposed closed-loop design.

View on arXivView PDF

Code Implementations(1)

wl822513/KOSSCommunity76%

Kalman-Optimal Selective State Spaces for Long-Term Sequence Modeling

11PythonSep 30, 20251 years ago

Cite this paper

@article{wang2025koss,
  title  = {KOSS: Kalman-Optimal Selective State Spaces for Long-Term Sequence Modeling},
  author = {Lei Wang and Xin Tan and Mingwei Wang and Ying Zhang},
  year   = {2025},
  eprint = {2512.16723},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2512.16723v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2512.16723.svg)](https://codeofpaper.com/paper/2512.16723)

Discussion