arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2510.26692cs.CLcs.LG
收藏

Kimi Linear:一种富有表达力且高效的注意力架构

Kimi Linear: An Expressive, Efficient Attention Architecture

Kimi Team, Yu Zhang, Zongyu Lin, Xingcheng Yao, Jiaxi Hu, Fanqing Meng, Chengyin Liu, Xin Men, Songlin Yang, Zhiyuan Li, Wentao Li, Enzhe Lu, Weizhou Liu, Yanru… 展开作者

Kimi Team, Yu Zhang, Zongyu Lin, Xingcheng Yao, Jiaxi Hu, Fanqing Meng, Chengyin Liu, Xin Men, Songlin Yang, Zhiyuan Li, Wentao Li, Enzhe Lu, Weizhou Liu, Yanru Chen, Weixin Xu, Longhui Yu, Yejie Wang, Yu Fan, Longguang Zhong, Enming Yuan, Dehao Zhang, Yizhi Zhang, T. Y. Liu, Haiming Wang, Shengjun Fang, Weiran He, Shaowei Liu, Yiwei Li, Jianlin Su, Jiezhong Qiu, Bo Pang, Junjie Yan, Zhejun Jiang, Weixiao Huang, Bohong Yin, Jiacheng You, Chu Wei, Zhengtao Wang, Chao Hong, Yutian Chen, Guanduo Chen, Yucheng Wang, Huabin Zheng, Feng Wang, Yibo Liu, Mengnan Dong, Zheng Zhang, Siyuan Pan, Wenhao Wu, Yuhao Wu, Longyu Guan, Jiawen Tao, Guohong Fu, Xinran Xu, Yuzhi Wang, Guokun Lai, Yuxin Wu, Xinyu Zhou, Zhilin Yang, Yulun Du

AI总结:

提出混合线性注意力架构 Kimi Linear 及核心模块 KDA,通过细粒度门控和专用分块算法提升效率,在减少 75% KV 缓存并提升 6 倍解码吞吐量的同时,性能超越全注意力机制。

摘要:

我们介绍了 Kimi Linear,这是一种混合线性注意力架构,首次在各种场景(包括短上下文、长上下文和强化学习(RL)扩展机制)的公平比较中超越了全注意力机制。其核心是 Kimi Delta Attention (KDA),这是一种富有表达力的线性注意力模块,通过更细粒度的门控机制扩展了 Gated DeltaNet,从而更有效地利用有限的状态 RNN 内存。我们定制的分块算法通过 Diagonal-Plus-Low-Rank (DPLR) 转移矩阵的专用变体实现了高硬件效率,与通用 DPLR 公式相比大幅减少了计算量,同时与经典的 delta 规则保持更高的一致性。我们基于 KDA 和 Multi-Head Latent Attention (MLA) 的逐层混合,预训练了一个具有 3B 激活参数和 48B 总参数的 Kimi Linear 模型。实验表明,在相同的训练配方下,Kimi Linear 在所有评估任务中均以显著优势超越了全 MLA,同时将 KV 缓存使用量减少了高达 75%,并在 1M 上下文下实现了高达 6 倍的解码吞吐量。这些结果表明,Kimi Linear 可以作为全注意力架构的直接替代方案,具有卓越的性能和效率,包括输入和输出长度更长的任务。为了支持进一步研究,我们开源了 KDA 内核和 vLLM 实现,并发布了预训练和指令微调的模型检查点。

英文摘要:

We introduce Kimi Linear, a hybrid linear attention architecture that, for the first time, outperforms full attention under fair comparisons across various scenarios -- including short-context, long-context, and reinforcement learning (RL) scaling regimes. At its core lies Kimi Delta Attention (KDA), an expressive linear attention module that extends Gated DeltaNet with a finer-grained gating mechanism, enabling more effective use of limited finite-state RNN memory. Our bespoke chunkwise algorithm achieves high hardware efficiency through a specialized variant of the Diagonal-Plus-Low-Rank (DPLR) transition matrices, which substantially reduces computation compared to the general DPLR formulation while remaining more consistent with the classical delta rule. We pretrain a Kimi Linear model with 3B activated parameters and 48B total parameters, based on a layerwise hybrid of KDA and Multi-Head Latent Attention (MLA). Our experiments show that with an identical training recipe, Kimi Linear outperforms full MLA with a sizeable margin across all evaluated tasks, while reducing KV cache usage by up to 75% and achieving up to 6 times decoding throughput for a 1M context. These results demonstrate that Kimi Linear can be a drop-in replacement for full attention architectures with superior performance and efficiency, including tasks with longer input and output lengths. To support further research, we open-source the KDA kernel and vLLM implementations, and release the pre-trained and instruction-tuned model checkpoints.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑