ChatPaper.aiChatPaper

OSCAR: オフライン・スペクトル共分散を考慮した回転による2ビットKVキャッシュ量子化

OSCAR: Offline Spectral Covariance-Aware Rotation for 2-bit KV Cache Quantization

May 18, 2026
著者: Zhongzhu Zhou, Donglin Zhuang, Jisen Li, Ziyan Chen, Shuaiwen Leon Song, Ben Athiwaratkun, Xiaoxia Wu
cs.AI

要旨

INT2 KVキャッシュ量子化は、長文脈LLMサービングにおいて魅力的な手法であるが、高精度かつデプロイ可能な状態を両立することは依然として困難である。アダマール変換のような単純な回転は外れ値を低減するが、下流のアテンションと整合しないため、INT2では依然として性能が低下する。我々はOSCARを提案する。これは、オフラインで注意認識共分散構造を推定し、それらを用いて量子化のための固定回転とクリッピング閾値を導出する超低ビットKVキャッシュ量子化手法である。これにより、KV量子化をアテンションが実際に消費する共分散構造と整合させる。さらに重要な点として、我々は理論的正当性を提供するだけでなく、ページング方式KVキャッシュサービングや融合カーネルパイプラインと互換性を持つカスタムINT2アテンションカーネルを備えた、完全にデプロイ可能なOSCARシステムを開発し、SGLangやvLLMなどの現代的なLLMサービングフレームワークへのシームレスな統合を可能にした。 本手法を、最大32kトークンの推論トレースを持つ最近の推論モデルにおいて5つのタスクで評価した。Qwen3-4B-Thinking-2507およびQwen3-8Bにおいて、OSCARはBF16との精度差をそれぞれ3.78ポイントおよび1.42ポイントに削減した。一方、単純な回転によるINT2はほぼゼロにまで性能が低下した。さらにOSCARをQwen3-32BおよびGLM-4.7(358Bパラメータ)に拡張したところ、BF16と実質的に同等の性能を維持した。最大128Kの長文脈RULER-NIAHにおいても、OSCARは両方のQwen3モデルで頑健性を示したが、単純な回転によるINT2は性能が崩壊した。システム面では、OSCARはKVキャッシュメモリを約8倍削減し、同一メモリ予算下での大バッチサイズにおいてスループットを最大7倍向上させ、バッチサイズ1のデコード速度はメモリ帯域幅オーバーヘッドの低減によりBF16比で最大3倍高速化した。
English
INT2 KV-cache quantization is attractive for long-context LLM serving, but it remains difficult to make both accurate and deployable. Simple rotations such as Hadamard transforms reduce outliers, but still degrade at INT2 because they are not aligned with downstream attention. We propose OSCAR, an Ultra-low-bit KV Cache quantization method that estimates attention-aware covariance structures offline and uses them to derive fixed rotations and clipping thresholds for quantization. In this way, it aligns KV quantization with the covariance structures that attention actually consumes. More importantly, we not only provide theoretical justification but also develop a fully deployable OSCAR system with a custom INT2 attention kernel that remains compatible with paged KV-cache serving and fused kernel pipelines, enabling seamless integration into modern LLM serving frameworks such as SGLang and vLLM. We evaluate our methods on recent reasoning models with reasoning traces of up to 32k tokens across 5 tasks. On Qwen3-4B-Thinking-2507 and Qwen3-8B, OSCAR reduces the BF16 accuracy gap to 3.78 and 1.42 points, respectively, while naive rotation INT2 collapses to nearly zero. We further scale OSCAR to Qwen3-32B and GLM-4.7 (358B params), where it remains effectively on par with BF16. On long context - RULER-NIAH up to 128K, OSCAR remains robust on both Qwen3 models, while naive rotation INT2 collapses. System-wise, OSCAR reduces KV-cache memory by approximately 8x, improves throughput by up to 7x at large batch sizes under the same memory budget, and accelerates batch-size-1 decoding by up to 3x over BF16 due to reduced memory bandwidth overhead.