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

状态调优:基于状态的RWKV-7测试时扩展

State Tuning: State-based Test-Time Scaling on RWKV-7

Liu Xiao, Li Zhiyuan, Lin Yueyu

AI总结:

本文提出状态调优方法,通过观察者框架、核方法状态扩展和去相关反向传播仅调优RWKV-7的状态矩阵,在不改预训练权重的情况下实现测试时扩展,使小模型超越大模型。

摘要:

测试时扩展已成为机器学习中一个突出的研究方向,使模型能够在推理过程中增强其表达能力。Transformer以在效率与表达能力之间取得精妙平衡而著称,并已从利用不断扩展的键值(KV)缓存来显著提升性能的测试时扩展技术中获益。在本文中,我们针对基于RNN的RWKV-7模型,提出了一种新颖的基于状态的测试时扩展方法,我们称之为状态调优。通过利用RWKV-7的独特优势,我们的方法在不改变模型预训练权重的情况下,在目标任务上取得了最先进的性能。我们的方法围绕三项关键创新展开。第一,我们开发了一个观察者框架,使一个较小的模型能够复现并学习RWKV-7模型的状态动态。第二,我们采用核方法动态提升状态规模,增强模型捕捉复杂模式的能力。第三,我们整合了去相关反向传播(DBP)来优化提升后的状态矩阵,从而改善收敛性和表达能力。通过仅调优状态矩阵,我们证明了一个较小的模型在给定任务上可以超越较大的模型。该方法保留了原始RWKV-7架构的效率,同时利用测试时扩展的能力来提供更优的结果。我们的发现凸显了状态调优作为一种在资源受限环境中提升模型性能的有效策略的潜力。我们的代码位于https://github.com/TorchRWKV/flash-linear-attention。

英文摘要:

Test-time scaling has emerged as a prominent research direction in machine learning, enabling models to enhance their expressive capabilities during inference.Transformers, renowned for striking a delicate balance between efficiency and expressiveness, have benefited from test-time scaling techniques that leverage an expanding key-value (KV) cache to significantly improve performance.In this paper, we introduce a novel state-based approach to test-time scaling, which we term state tuning, tailored to the RNN-based RWKV-7 model.By exploiting the unique strengths of RWKV-7, our method achieves state-of-the-art performance on the target task without altering the model's pre-trained weights. Our approach centers on three key innovations. First, we develop an observer framework that allows a smaller model to replicate and learn the state dynamics of the RWKV-7 model. Second, we employ a kernel method to dynamically upscale the state size, enhancing the model's capacity to capture intricate patterns. Third, we integrate Decorrelated Backpropagation (DBP) to optimize the upscaled state matrix, thereby improving convergence and expressivity. By tuning only the state matrix, we demonstrate that a smaller model can outperform larger models on the given task. This method preserves the efficiency of the original RWKV-7 architecture while harnessing the power of test-time scaling to deliver superior results. Our findings underscore the potential of state tuning as an effective strategy for advancing model performance in resource-constrained settings. Our code is https://github.com/TorchRWKV/flash-linear-attention.

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

↑