咨询与建议

看过本文的还看了

相关文献

该作者的其他文献

文献详情 >SCOPE: Optimizing Key-Value Ca... 收藏
arXiv

SCOPE: Optimizing Key-Value Cache Compression in Long-context Generation

作     者:Wu, Jialong Wang, Zhenglin Zhang, Linhai Lai, Yilong He, Yulan Zhou, Deyu 

作者机构:School of Computer Science and Engineering Key Laboratory of Computer Network and Information Integration Ministry of Education Southeast University China Department of Informatics King’s College London United Kingdom The Alan Turing Institute United Kingdom 

出 版 物:《arXiv》 (arXiv)

年 卷 期:2024年

核心收录:

主  题:Decoding 

摘      要:Key-Value (KV) cache has become a bottleneck of LLMs for long-context generation. Despite the numerous efforts in this area, the optimization for the decoding phase is generally ignored. However, we believe such optimization is crucial, especially for long-output generation tasks based on the following two observations: (i) Excessive compression during the prefill phase which requires specific full context, impairs the comprehension of the reasoning task;(ii) Deviation of heavy hitters1 occurs in the reasoning tasks with long outputs. Therefore, SCOPE, a simple yet efficient framework that separately performs KV cache optimization during the prefill and decoding phases, is introduced. Specifically, the KV cache during the prefill phase is preserved to maintain the essential information, while a novel strategy based on sliding is proposed to select essential heavy hitters for the decoding phase. Memory usage and memory transfer are further optimized using adaptive and discontinuous strategies. Extensive experiments on LONGGENBENCH show the effectiveness and generalization of SCOPE and its compatibility as a plug-in to other prefill-only KV compression methods. 2 Copyright © 2024, The Authors. All rights reserved.

读者评论 与其他读者分享你的观点

用户名:未登录
我的评分