MSA, or Memory Sparse Attention, is a research framework for scaling language-model memory to extremely long contexts. It replaces full attention over all tokens with sparse selection of compressed latent memory states. Document-wise rotary position encoding and top-k routing keep training and inference close to linear complexity. A tiered KV-cache design stores routing keys on GPU while larger content states can remain on CPU. Its Memory Parallel engine distributes scoring and transfers only selected memory back to the accelerator. Memory Interleave alternates retrieval, context expansion, and generation to improve multi-hop reasoning across distant segments. The project reports experiments extending from 16K to 100M tokens, including inference on two A800 GPUs.

Features

  • Memory Sparse Attention architecture
  • Document-wise rotary position encoding
  • Top-k latent memory routing
  • GPU and CPU tiered KV-cache compression
  • Memory Parallel distributed inference
  • Memory Interleave for multi-hop reasoning

Project Samples

Project Activity

See All Activity >

Follow MSA: Memory Sparse Attention

MSA: Memory Sparse Attention Web Site

Other Useful Business Software
Paessler: Easy to Use With Enterprise Power. Free Trial Icon
Paessler: Easy to Use With Enterprise Power. Free Trial

A low-code dashboard makes monitoring intuitive for any admin, while scripting and custom sensors give experts full control.

You shouldn't have to choose between a monitoring tool that's easy to use and one that's powerful enough for a complex environment. PRTG's low-code interface lets any admin build dashboards, set alerts and monitor devices without scripting, while custom sensors and full API access are there when your team needs deeper control. One platform, no compromise. Download a free 30-day trial now.
Get Free Download
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of MSA: Memory Sparse Attention!

Additional Project Details

Programming Language

Python

Related Categories

Python Frameworks, Python Artificial Intelligence Software

Registered

2026-09-18