[Core] Preserve Marconi caching with selective hybrid cache retention (#47782)

Signed-off-by: Nick Hill <nickhill123@gmail.com>
This commit is contained in:
Nick Hill
2026-07-13 21:24:20 +01:00
committed by GitHub
parent 7dc447dda7
commit 8ac8375270
9 changed files with 501 additions and 235 deletions
@@ -235,6 +235,9 @@ class MooncakeStoreCoordinator:
manager_cls = KVCacheSpecRegistry.get_manager_class(spec)
assert manager_cls is not None
use_eagle = g_idx in self.eagle_group_ids
reachable_boundaries = (
() if num_prompt_tokens is None else (num_prompt_tokens - 1,)
)
mask = manager_cls.reachable_block_mask(
start_block=start_chunk,
end_block=end_chunk,
@@ -242,7 +245,7 @@ class MooncakeStoreCoordinator:
kv_cache_spec=spec,
use_eagle=use_eagle,
retention_interval=retention_interval,
num_prompt_tokens=num_prompt_tokens,
reachable_boundaries=reachable_boundaries,
)
if mask is not None:
assert len(mask) == end_chunk - start_chunk