UNComp:行列エントロピーによるスパース性の解明が可能か?―不確実性考慮型圧縮設計

UNComp:行列エントロピーによるスパース性の解明が可能か?―不確実性考慮型圧縮設計

なぜ重要か: 企業や社会への影響が見込まれ、一般メディアにも波及する可能性があります。

ソースを読む(export.arxiv.org)

arXiv:2410.03090v2 発表種別:差し替え

要約: 長文脈推論における大規模言語モデル(LLM)の展開は、その膨大なメモリと計算需要のために依然として課題となっている。Key-Value (KV) キャッシュ圧縮などの手法はメモリ使用量の削減を目的としているが、隠れ状態とそれに対応するKVキャッシュ間の固有の構造的スパース性をしばしば無視している。本研究では、LLM内のスパース性の潜在的な指標としての不確実性の役割を探る。我々は、不確実性を考慮したフレームワークUNCompを提案する。これは、切り詰め行列エントロピーを利用して低情報量の領域を特定し、適応的圧縮に使用できるスパース性パターンを明らかにする。均一な圧縮を適用する従来の方法とは異なり、UNCompは、様々なモデルコンポーネントの重要性を反映する不確実性尺度によって導かれる、圧縮へのアプローチを動的に調整する。我々の分析によると、不確実性推定から導出されたスパース性パターンは、検索ヘッドや検索レイヤーなどの特別な長距離依存関係を明らかにするために利用できる。この視点は、圧縮の最適化方法に関する理解を深めるだけでなく、長文脈推論中のLLMの固有のスパース性に関する新たな知見も提供する。スパース性パターンを詳細に分析するために不確実性に焦点を当てることで、UNCompはKVキャッシュサイズを元の4.74%に削減し、プリフィル速度を6%向上させ、スループットを6.4倍向上させる。これは、強力なロスレス圧縮性能を提供するだけでなく、基礎となる理論ツールの有効性も検証するものである。コードはhttps://github.com/menik1126/UNCompで公開する。

原文(英語)を表示

Title (EN): UNComp: Can Matrix Entropy Uncover Sparsity? — A Compressor Design from an Uncertainty-Aware Perspective

arXiv:2410.03090v2 Announce Type: replace
Abstract: Deploying large language models (LLMs) for long-context inference remains challenging due to their substantial memory and computational demands. While techniques such as Key-Value (KV) cache compression are designed to reduce memory usage, they often neglect the structured sparsity inherent in the relationship between hidden states and their corresponding KV cache. In this work, we explore the role of uncertainty as a potential indicator of sparsity within LLMs. We propose UNComp, an uncertainty-aware framework that leverages truncated matrix entropy to identify areas of low information content, thereby revealing sparsity patterns that can be used for adaptive compression. Unlike traditional methods that apply uniform compression, UNComp dynamically adjusts its approach to compression, guided by uncertainty measures that reflect the importance of various model components. Our analysis shows that sparsity patterns, when derived from uncertainty estimates, can be exploited to reveal special long-range dependencies, such as retrieval heads and retrieval layers. This perspective not only enhances our understanding of how compression can be optimized but also provides new insights into the inherent sparsity of LLMs during long-context inference. By focusing on uncertainty to analyze the sparsity pattern in detail, UNComp reduces the KV cache size to 4.74% of the original, achieves a 6% prefill speedup, and improves throughput by 6.4x – not only delivering strong lossless compression performance, but also validating the effectiveness of the underlying theoretical tool. We release the code at https://github.com/menik1126/UNComp.

Published: 2025-09-24 19:00 UTC


コメントする