🤖 AI Summary
Existing RNN variants suffer from fragmented implementations across deep learning frameworks, lacking standardized interfaces and rigorous cross-framework evaluation—leading to poor reproducibility, redundant development, and inefficient experimentation.
Method: We introduce the first standardized, multi-framework RNN interface, implemented in open-source libraries: `torchrecurrent` (Python, for PyTorch), `RecurrentLayers.jl`, and `LuxRecurrentLayers.jl` (Julia, for JAX/Flux). These provide unified, semantically consistent implementations of diverse recurrent units—including LSTM, GRU, mGRU, and Delta-RNN—as well as higher-level architectures.
Contribution/Results: Our work establishes the first modular, extensible, and framework-agnostic RNN API, enabling flexible customization and seamless model migration across ecosystems. All libraries are MIT-licensed, actively maintained, and rigorously tested. By abstracting framework-specific complexities, they significantly lower implementation overhead and experimental barriers, thereby promoting structural standardization, reproducible research, and collaborative advancement in recurrent modeling.
📝 Abstract
Recurrent neural networks (RNNs) are a cornerstone of sequence modeling across various scientific and industrial applications. Owing to their versatility, numerous RNN variants have been proposed over the past decade, aiming to improve the modeling of long-term dependencies and to address challenges such as vanishing and exploding gradients. However, no central library is available to test these variations, and reimplementing diverse architectures can be time-consuming and error-prone, limiting reproducibility and exploration. Here, we introduce three open-source libraries in Julia and Python that centralize numerous recurrent cell implementations and higher-level recurrent architectures. torchrecurrent, RecurrentLayers.jl, and LuxRecurrentLayers.jl offer a consistent framework for constructing and extending RNN models, providing built-in mechanisms for customization and experimentation. All packages are available under the MIT license and actively maintained on GitHub.