xLSTM 7B
NXAI · xLSTM · open weights
- Linear attention
- Pre-norm
Facts and where they come from
| Released | 2024-12 | config.jsonconfig.jsonHugging Face repository creation date (api.createdAt) |
|---|---|---|
| Licence | other | config.jsonconfig.jsonREADME metadata: license |
| Total parameters | 7B | labmodel cardmodel name xLSTM-7b |
| Active parameters | not disclosed | not disclosed |
| Context length | not disclosed | not disclosed |
| Norm placement | pre | codemodelling codetransformers 5.18.0 xlstm: norm_mlstm and norm_ffn before each block |
| Norm type | RMSNorm | codemodelling codetransformers 5.18.0 xlstm: norm_mlstm and norm_ffn before each block |
| QK-norm | no | config.jsonconfig.jsonadd_qk_norm |
| Positional encoding | none; all layers: the recurrence carries order | codemodelling codetransformers 5.18.0 xlstm: no positional encoding |
| Parallel attention and MLP | no | codemodelling codetransformers 5.18.0 xlstm: norm_mlstm and norm_ffn before each block |
Architecture, drawn from the data
mLSTM. Each column is one layer: its token mixer above, its feed-forward block below. Paler columns reuse another layer’s keys and values.
Modelled costs
From the cost model, batch size 1. Totals the lab states are in the table above; differences come from rounding, from what a lab counts, or from parts the model does not describe (listed on the about page).
| Parameters (modelled) | 6.87B |
|---|---|
| Active per token (modelled) | 6.87B |
| Without embeddings and output head | 6.45B total, 6.45B active |
| Published weights (Hugging Face count) | 6.87B |
| KV cache per token, BF16 (layers that grow with context) | 0 B |
| KV cache + state at 128K tokens, BF16 | 64.1 MiB |
| Decode FLOPs per token at 4K context | 13.5 GFLOP |
| Prefill FLOPs for a 4K prompt | 53.4 TFLOP |
KV cache against context
Every architecture field
| Field | Value | Source |
|---|---|---|
| d_model | 4,096 | config.jsonconfig.jsonembedding_dim |
| vocab | 50,304 | config.jsonconfig.jsonvocab_size |
| tied_embeddings | false | codemodelling codetransformers 5.18.0 xlstm: separate lm_head |
| mixers.mlstm.type | mlstm | codemodelling codemLSTM cell |
| mixers.mlstm.heads | 8 | config.jsonconfig.jsonnum_heads |
| mixers.mlstm.qk_dim | 2,048 | codemodelling codeqk_dim = round_up(embedding_dim * qk_dim_factor, mlstm_round_up_to_multiple_of) |
| mixers.mlstm.v_dim | 4,096 | codemodelling codev_dim = round_up(embedding_dim * v_dim_factor, mlstm_round_up_to_multiple_of) |
| ffns.dense.type | dense | codemodelling codeMLP |
| ffns.dense.d_ff | 10,944 | codemodelling coded_ff = round_up(embedding_dim * ffn_proj_factor, ffn_round_up_to_multiple_of) |
| ffns.dense.gated | true | codemodelling codeSwiGLU |
| layout | 32× mlstm/dense | config.jsonconfig.jsonnum_blocks |
Sources
- config.json @ 9dc507b
- model card
- arXiv 2503.13427
- modelling code · transformers 5.18.0 modelling code, or the model repository's own modelling file at the pinned revision
Listed in the LLM Architecture Gallery checklist as “xLSTM (7B)” (name only; see about).