CryptoMamba: Leveraging State Space Models for Accurate Bitcoin Price Prediction
Mohammad Shahab Sepehri, Asal Mehradfar, Mahdi Soltanolkotabi, Salman Avestimehr
TL;DR
CryptoMamba introduces a Mamba-based State Space Model designed for financial time-series forecasting, addressing Bitcoin price volatility and regime shifts. By stacking C-Blocks of CMBlocks with input-dependent dynamics and a Merge head, it captures long-range dependencies more efficiently than traditional RNNs or Transformers. In experiments against LSTM, Bi-LSTM, GRU, iTransformer, and S-Mamba, CryptoMamba achieves superior predictive accuracy and, when coupled with trading strategies, translates forecasts into robust real-world returns, notably with the volume-enhanced variant achieving RMSE $1598.1$, MAPE $2.034$, and MAE $1120.7$. The architecture is compact ($\approx 136k$ parameters) and computationally efficient (training $\approx 29$ minutes; inference $\approx 1.17$ ms/sample), supporting deployment in latency-sensitive environments and suggesting broad applicability to other assets and trading settings.
Abstract
Predicting Bitcoin price remains a challenging problem due to the high volatility and complex non-linear dynamics of cryptocurrency markets. Traditional time-series models, such as ARIMA and GARCH, and recurrent neural networks, like LSTMs, have been widely applied to this task but struggle to capture the regime shifts and long-range dependencies inherent in the data. In this work, we propose CryptoMamba, a novel Mamba-based State Space Model (SSM) architecture designed to effectively capture long-range dependencies in financial time-series data. Our experiments show that CryptoMamba not only provides more accurate predictions but also offers enhanced generalizability across different market conditions, surpassing the limitations of previous models. Coupled with trading algorithms for real-world scenarios, CryptoMamba demonstrates its practical utility by translating accurate forecasts into financial outcomes. Our findings signal a huge advantage for SSMs in stock and cryptocurrency price forecasting tasks.
