O(N) Linear Complexity Transformer - 125x faster than standard attention using cumulative sum trick. Pure PyTorch implementation.
-
Updated
Dec 29, 2025 - Python
O(N) Linear Complexity Transformer - 125x faster than standard attention using cumulative sum trick. Pure PyTorch implementation.
An experimental O(N) language model based on mathematical physics (Birman-Schwinger theory). A PyTorch implementation aiming to surpass Mamba in long-context stability and memory efficiency (O(N log N)) through Prime-Bump initialization and scattering theory routing.
Add a description, image, and links to the o-n-complexity topic page so that developers can more easily learn about it.
To associate your repository with the o-n-complexity topic, visit your repo's landing page and select "manage topics."