Repository navigation
[3rdparty] fix: LMCache's MP connector keeps vLLM's lookahead block hashes on, so an MTP prefix hit keeps its last block - #15
Merged
Conversation
…ashes on, so an MTP prefix hit keeps its last block With MTP, vLLM 0.34 keeps its lookahead block hashes on only when the KV connector class declares supports_lookahead_block_hashes(). LMCache's MP connector did not, so every replica with LMCache dropped the last matched block of each prefix-cache hit and moved its align-mode Mamba checkpoints back with it. LMCache patch 0006 makes the connector declare the support, and holds back the lookahead tokens of a lazy-offload store, which PEAR does not use.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
With MTP, vLLM 0.34 keeps its lookahead block hashes on only when the KV connector class declares
supports_lookahead_block_hashes(). LMCache's MP connector did not, so every replica with LMCache dropped the lastmatched block of each prefix-cache hit and moved its align-mode Mamba checkpoints back with it.
LMCache patch 0006 makes the connector declare the support, as LMCache's closed PR 6619 and vLLM main's own LMCache
connector do. It also holds back the lookahead tokens of a lazy-offload store, which PEAR does not use.
Validation:
the recipe as released (32 sessions per replica, H200 with vLLM limited to an H100's GPU memory, half the replicas
without LMCache): the replicas with LMCache run with lookahead hashes and hit 97.1% of their prompt tokens in vLLM's
own cache, as the replicas without LMCache do (97.1%); without the patch, in the same setup, they hit 94.3%.