paper-with-me

Papers

ThinK: Thinner Key Cache by Query-Driven Pruning

2024-07-30 · Yuhui Xu, Zhanming Jie, Hanze Dong, Lei Wang, Xudong Lu, Aojun Zhou, Amrita Saha, Caiming Xiong, Doyen Sahoo

Large Language Models (LLMs) have revolutionized the field of natural language processing, achieving unprecedented performance across a variety of applications. However, their increased computational and memory demands present significant challenges, especially when handling long sequences. This paper focuses on the long-context scenario, addressing the inefficiencies in KV cache memory consumption during inference. Unlike existing approaches that optimize the memory based on the sequence length, we identify substantial redundancy in the channel dimension of the KV cache, as indicated by an uneven magnitude distribution and a low-rank structure in the attention weights. In response, we propose ThinK, a novel query-dependent KV cache pruning method designed to minimize attention weight loss while selectively pruning the least significant channels. Our approach not only maintains or enhances model accuracy but also achieves a reduction in KV cache memory costs by over 20% compared with vanilla KV cache eviction and quantization methods. For instance, ThinK integrated with KIVI can achieve a 2.8x reduction in peak memory usage while maintaining nearly the same quality, enabling up to a 5x increase in batch size when using a single GPU. Extensive evaluations on the LLaMA and Mistral models across various long-sequence datasets verified the efficiency of ThinK, establishing a new baseline algorithm for efficient LLM deployment without compromising performance.

📄 PDF Abstract BibTeX arXiv:2407.21018

Code (0)

등록된 구현이 없습니다.

Tasks

GPUQuantization

Methods 이 논문이 사용한 방법론

Softmax The Softmax output function transforms a previous layer's output into a vector of probabilities. It is commonly used for multiclass classification. Given an input vector $x$…
Attention 설명 없음
LLaMA LLaMA is a collection of foundation language models ranging from 7B to 65B parameters. It is based on the transformer architecture with various improvements that were…
Pruning 설명 없음

Similar Papers 제목 키워드 기반

Towards thinner convolutional neural networks through Gradually Global Pruning

2017-03-29 · Zhengtao Wang, Ce Zhu, Zhiqiang Xia, Qi Guo 외

Deep network pruning is an effective method to reduce the storage and computation cost of deep neural networks when applying them to resource-limited devices. Among many pruning granularities, neuron level pruning will r…

Network Pruning

TaskPress: Query-Agnostic KV Cache Compression via Task-Guided Pruning

2026-08-04 · Wonpyo Park, Seung-won Hwang arxiv

Long-context inference with large language models is constrained by the linear growth of the key-value cache to sequence length. While pruning offers mitigation, prevailing methods determine query-specific token importan…

IntentKV: Cross-Turn Intent-Aware KV Cache Pruning for Agent Inference

2026-06-06 · Junjie Li, Jiong Lou, Jie Li arxiv

Multi-turn LLM agents fan short queries into long trajectories of tool calls, search results, and intermediate reasoning. Both KV memory and KV read bandwidth grow by orders of magnitude across a single trajectory, makin…

OBCache: Optimal Brain KV Cache Pruning for Efficient Long-Context LLM Inference

2025-10-09 · Yuzhe Gu, Xiyu Liang, Jiaojiao Zhao, Enmao Diao arxiv

Large language models (LLMs) with extended context windows enable powerful applications but impose significant memory overhead, as caching all key-value (KV) states scales linearly with sequence length and batch size. Ex…

Static Pruning Across Sparse Retrieval Regimes: What Transfers, What Breaks, and What Still Helps

2026-08-17 · Zirui Song, Yuye Zhu, Yang Yang arxiv

Static pruning is widely used to accelerate sparse neural retrieval, yet existing studies each validate their conclusions within a single custom pipeline, leaving it unclear which findings transfer to modern engines with…

Natural Questions