RWKV-6 Finch 14B
RWKV · RWKV · open weights
- Linear attention
- Pre-norm
Facts and where they come from
| Released | 2024-07 | config.jsonconfig.jsonHugging Face repository creation date (api.createdAt) |
|---|---|---|
| Licence | apache-2.0 | config.jsonconfig.jsonREADME metadata: license |
| Total parameters | 14B | labmodel cardmodel name v6-Finch-14B |
| Active parameters | not disclosed | not disclosed |
| Context length | not disclosed | not disclosed |
| Norm placement | pre | codemodelling coderepo modeling_rwkv6.py: ln1 and ln2 before each mixing block |
| Norm type | LayerNorm | codemodelling coderepo modeling_rwkv6.py: ln1 and ln2 before each mixing block |
| QK-norm | no | codemodelling codeno q/k normalisation in the attention block |
| Positional encoding | none; all layers: the recurrence carries order | codemodelling codetransformers 5.18.0 rwkv6: no positional encoding |
| Parallel attention and MLP | no | codemodelling coderepo modeling_rwkv6.py: ln1 and ln2 before each mixing block |
Architecture, drawn from the data
RWKV. 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) | 13.8B |
|---|---|
| Active per token (modelled) | 13.8B |
| Without embeddings and output head | 13.3B total, 13.3B active |
| KV cache per token, BF16 (layers that grow with context) | 0 B |
| KV cache + state at 128K tokens, BF16 | 31.5 MiB |
| Decode FLOPs per token at 4K context | 27.2 GFLOP |
| Prefill FLOPs for a 4K prompt | 109 TFLOP |
KV cache against context
Every architecture field
| Field | Value | Source |
|---|---|---|
| d_model | 4,096 | config.jsonconfig.jsonhidden_size |
| vocab | 65,536 | config.jsonconfig.jsonvocab_size |
| tied_embeddings | false | codemodelling codeRWKV: separate head |
| mixers.rwkv.type | rwkv | codemodelling codeRWKV time mixing |
| mixers.rwkv.head_dim | 64 | config.jsonconfig.jsonhead_size |
| mixers.rwkv.mats | 5 | codemodelling codetime mixing: receptance, key, value, output, gate (RWKV-6) |
| ffns.dense.type | dense | codemodelling codechannel mixing |
| ffns.dense.d_ff | 14,336 | codemodelling codemodeling_rwkv6.py: intermediate_size = int(hidden_size * 3.5) // 32 * 32 |
| ffns.dense.gated | false | codemodelling codechannel mixing: key and value matrices |
| ffns.dense.receptance | true | codemodelling codechannel mixing also has a d x d receptance matrix |
| layout | 61× rwkv/dense | config.jsonconfig.jsonnum_hidden_layers |
Sources
- config.json @ ad7133e
- model card
- arXiv 2404.05892
- modelling code · transformers 5.18.0 modelling code, or the model repository's own modelling file at the pinned revision