arXiv:2605.17757v2 cs.LG

OSCAR: 2비트 KV 캐시 양자화를 위한 오프라인 스펙트럼 공분산 인식 회전

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

Zhongzhu Zhou, Donglin Zhuang, Jisen Li, Ziyan Chen, Shuaiwen Leon Song, Ben Athiwaratkun, Xiaoxia Wu

제출 2026-11-13

한국어 초록

INT2 KV 캐시 양자화는 긴 문맥 LLM 서빙에 매력적이지만, 정확도와 실용성을 모두 확보하기는 여전히 어렵다. 하다마드 변환과 같은 데이터 비의존적 회전은 채널 이상치를 평탄화하지만, 후속 어텐션 쿼리가 캐시를 어떻게 조회하는지 무시하기 때문에 INT2에서는 여전히 성능이 급격히 저하된다. 본 논문은 어텐션을 인식하는 공분산 목표를 오프라인으로 추정하고 이를 이용해 레이어별 고정 회전과 클리핑 임계값을 도출하는 초저비트 KV 캐시 양자화 방법인 OSCAR를 제안한다. OSCAR는 양자화 기저를 어텐션이 사용하는 2차 모멘트 구조에 정렬함으로써 2비트 정밀도에서 어텐션 충실도를 보존한다. 고정 오차 대리 모델 하의 이론적 분석에 더하여, 페이지형 KV 캐시 레이아웃과 프리픽스 캐싱을 유지하는 융합 Triton 쓰기 및 디코드 커널을 갖춘 서빙 준비 완료 OSCAR 시스템을 구축하고, 이를 SGLang과 vLLM 같은 최신 서빙 엔진에 통합한다. 다섯 가지 과제에 걸쳐 최대 32K 토큰의 생성 트레이스를 갖는 추론 및 코딩 벤치마크에서 OSCAR를 평가한다. Qwen3-4B-Thinking-2507과 Qwen3-8B에서 OSCAR는 하다마드 단독 INT2가 붕괴하는 상황에서 BF16과의 정확도 격차를 각각 3.78점과 1.21점으로 좁히며, Qwen3-32B와 GLM-4.7(358B 파라미터)에서는 실행 간 변동 범위 내에서 BF16과 대등한 성능을 보인다. 최대 128K 토큰의 RULER-NIAH에서 OSCAR는 모든 문맥 길이에 걸쳐 QuaRot 방식의 INT2를 크게 능가한다. 시스템 측면에서 OSCAR는 KV 캐시 메모리를 거의 $8\times$ 압축하고, 동일한 메모리 예산 내에서 큰 배치 크기의 다중 요청 처리량을 최대 $7.8\times$ 높이며, KV 메모리 트래픽을 줄여 배치 크기 1의 디코딩을 BF16 대비 최대 $3.1\times$ 가속한다.

원문 초록

INT2 KV-cache quantization is attractive for long-context LLM serving, yet making it both accurate and practical remains challenging. Data-oblivious rotations such as Hadamard transforms flatten channel outliers, but still degrade sharply at INT2 because they ignore how downstream attention queries the cache. We propose OSCAR, an ultra-low-bit KV-cache quantization method that estimates attention-aware covariance targets offline and uses them to derive fixed per-layer rotations and clipping thresholds. By aligning the quantization basis with the second-moment structures consumed by attention, OSCAR preserves attention fidelity at 2-bit precision. Beyond theoretical analysis under a frozen-error surrogate, we build a serving-ready OSCAR system with fused Triton write and decode kernels that preserve paged KV-cache layouts and prefix caching, integrating into modern serving engines such as SGLang and vLLM. We evaluate OSCAR on reasoning and coding benchmarks with generation traces of up to 32K tokens across five tasks. On Qwen3-4B-Thinking-2507 and Qwen3-8B, OSCAR narrows the BF16 accuracy gap to 3.78 and 1.21 points, respectively, where Hadamard-only INT2 collapses, and matches BF16 within run-to-run variance on Qwen3-32B and GLM-4.7 (358B parameters). On RULER-NIAH up to 128K tokens, OSCAR substantially outperforms QuaRot-style INT2 across context lengths. System-wise, OSCAR compresses KV-cache memory by nearly $8\times$, boosts multi-request throughput by up to $7.8\times$ at large batch sizes within the same memory budget, and accelerates batch-size-1 decoding by up to $3.1\times$ over BF16 by cutting KV memory traffic.

제출 이력

확인된 버전만 표시합니다. 전체 제출 이력은 arXiv 원문에서 확인하세요.

  1. arXiv:2605.17757v2제출 시각 미확인

함께 살펴볼 논문

공통 태그를 근거로 연결했습니다. 실제 인용 관계나 논문의 우수성을 뜻하지 않습니다.

공통 태그로 연결된 공개 논문이 아직 없습니다.

토론

이 논문과 연결된 포럼 글이 아직 없습니다.