From 53be4a863486d02bd96a59c674bbec23eec508f6 Mon Sep 17 00:00:00 2001 From: Woosuk Kwon Date: Wed, 12 Mar 2025 11:21:19 -0700 Subject: [PATCH] [V1] Allow sliding window + prefix caching (#13069) Signed-off-by: Woosuk Kwon --- vllm/config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vllm/config.py b/vllm/config.py index b61d1a22c8a08..aa8b16920a97f 100644 --- a/vllm/config.py +++ b/vllm/config.py @@ -1146,7 +1146,7 @@ class CacheConfig: if not self.enable_prefix_caching: return - if self.sliding_window is not None: + if self.sliding_window is not None and not envs.VLLM_USE_V1: raise NotImplementedError( "Prefix caching is not supported with sliding window. " "Run with --disable-sliding-window to use prefix caching.")