[Bugfix] Fix DeepseekV32 AssertionError: num_kv_heads == 1#33090
Merged
NickLucche merged 1 commit intovllm-project:mainfrom Jan 27, 2026
Merged
[Bugfix] Fix DeepseekV32 AssertionError: num_kv_heads == 1#33090NickLucche merged 1 commit intovllm-project:mainfrom
AssertionError: num_kv_heads == 1#33090NickLucche merged 1 commit intovllm-project:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request addresses a bug that caused an AssertionError: num_kv_heads == 1 with certain models, such as DeepseekV32. The root cause was a hardcoded num_kv_heads=4 used for probing the KV cache layout. The fix changes this value to 1, which is a more robust and general choice compatible with various attention architectures, including MQA. This change correctly resolves the reported assertion error without introducing any negative side effects. The implementation is sound.
Collaborator
Author
5 tasks
DarkLight1337
approved these changes
Jan 27, 2026
Collaborator
|
lgtm |
VedantMadane
pushed a commit
to VedantMadane/vllm
that referenced
this pull request
Jan 28, 2026
…oject#33090) Signed-off-by: NickLucche <nlucches@redhat.com> Signed-off-by: Vedant Madane <6527493+VedantMadane@users.noreply.github.com>
khluu
pushed a commit
that referenced
this pull request
Jan 28, 2026
Signed-off-by: NickLucche <nlucches@redhat.com> (cherry picked from commit 492a798)
apd10
pushed a commit
to apd10/vllm
that referenced
this pull request
Jan 31, 2026
…oject#33090) Signed-off-by: NickLucche <nlucches@redhat.com>
ItzDEXX
pushed a commit
to ItzDEXX/vllm
that referenced
this pull request
Feb 19, 2026
…oject#33090) Signed-off-by: NickLucche <nlucches@redhat.com>
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.
Fix #33086