CacheWeave: 효율적인 위치 독립 KV 캐싱을 위한 재계산 학습
CacheWeave: Learning to Recompute for Efficient Position-Independent KV Caching
한국어 초록
위치 독립 캐싱은 청크 KV 캐시를 위치와 요청에 걸쳐 재사용한다. 그러나 독립 인코딩은 청크 간 상호작용을 누락하여 정확도를 저하시킬 수 있다. 본 연구에서 PIC 학습과 규칙 기반 재계산은 단독으로든 결합하든 전체 프리필 정확도를 일관되게 회복하지 못했다. PIC로 학습된 모델에 오라클 기반 재계산을 적용하면 동일한 예산에서 정확도가 향상되며, 이는 더 나은 선택 방법의 필요성을 시사한다. 본 논문은 전체 백본을 PIC에 맞게 적응시킨 뒤 동결하고, 적응된 모델의 오라클로 모델 고유의 블록 선택기를 학습하는 CacheWeave를 제안한다. 선택기는 백본 어텐션 점수를 추출하지 않고 간결한 캐시 청크 특징과 질문 은닉 상태를 사용한다. 선택기는 KV 블록에 정렬된 연속 토큰 블록을 선택하여 효율적인 재계산을 지원하고 쓰기 시 복사(copy-on-write) 증폭을 제한한다. 런타임인 CacheWeave-Serve는 비공개 및 공유 KV 캐시를 지원하고, 선택과 재계산을 GPU에서 수행하며, 하이브리드 어텐션 모델을 위해 슬라이딩 윈도 KV를 단계적으로 배치한다. 세 모델과 네 과제에 걸쳐 CacheWeave는 5% 재계산 예산에서 CacheBlend와 ProphetKV를 평균 각각 7.2%p, 3.5%p 앞서며, 전체 프리필 대비 평균 상대 정확도 손실은 1.6%이다. 32토큰 블록 사용 시 CacheWeave-Serve는 단일 요청 TTFT를 전체 프리필 대비 최대 16.1배, ProphetKV 대비 최대 1.7배 줄이고, 부하 상황의 SLO 굿풋을 최대 7.8배 높인다.
원문 초록
Position-independent caching reuses chunk KV caches across positions and requests. Independent encoding, however, omits cross-chunk interactions and can degrade accuracy. In our study, neither PIC training nor rule-based recomputation, alone or combined, consistently recovers full-prefill accuracy. Oracle-guided recomputation on PIC-trained models improves accuracy at the same budget, motivating better selection. We present CacheWeave, which adapts the full backbone to PIC, then freezes it and trains a model-native block selector on the adapted model's oracles. The selector uses compact cached chunk features and question hidden states without extracting backbone attention scores. It selects contiguous token blocks aligned with KV blocks to support efficient recomputation and limit copy-on-write amplification. Its runtime, CacheWeave-Serve, supports private and shared KV caches, keeps selection and recomputation on the GPU, and stages sliding-window KV for hybrid attention models. Across three models and four tasks, CacheWeave outperforms CacheBlend and ProphetKV by 7.2 and 3.5 percentage points on average at a 5% recomputation budget, with a mean relative accuracy loss of 1.6% to full prefill. With 32-token blocks, CacheWeave-Serve cuts single-request TTFT by up to 16.1x over full prefill and 1.7x over ProphetKV, and raises SLO goodput under load by up to 7.8x.
제출 이력
확인된 버전만 표시합니다. 전체 제출 이력은 arXiv 원문에서 확인하세요.
- arXiv:2611.01735v1제출 시각 미확인
함께 살펴볼 논문
공통 태그를 근거로 연결했습니다. 실제 인용 관계나 논문의 우수성을 뜻하지 않습니다.
공통 태그로 연결된 공개 논문이 아직 없습니다.
토론
이 논문과 연결된 포럼 글이 아직 없습니다.