Skip to content

[BugFix] Select the DeepSeek Eagle relay by core API capability - #23977

Open
tgrhn wants to merge 4 commits into
vllm-project:mainfrom
tgrhn:fix/deepseek-eagle-relay-api-detection
Open

tgrhn wants to merge 4 commits into
vllm-project:mainfrom
tgrhn:fix/deepseek-eagle-relay-api-detection

Conversation

@tgrhn

@tgrhn tgrhn commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

What this PR does / why we need it?

On the pinned vLLM main commit, a Qwen3.6 MXFP8 TP2 launch failed while eagerly importing Ascend's worker patches. The DeepSeek patch selected the legacy relay using the version label 0.34.0 and tried to copy EagleModelMixin._aux_upstream_total_cached, which is absent on that core revision.

Detect the runner-managed relay using EagleModelMixin.aux_hidden_state_slot_keys and use the existing decoder subclass path when that API is available. Keep the existing mixin-member copy path for the release API. Align the DeepSeek PP relay test fixtures with the same distinction.

How was this patch tested?

  • Reproduced the import failure on a Qwen3.6-35B-A3B MXFP8 launcher with target graphs and each MTP draft execution mode. With the patch the launch advanced past worker patch import.

  • tests/ut/patch/worker/test_patch_deepseek_v2.py on the pinned core: 54 passed.

  • vLLM main: vllm-project/vllm@c410543

Signed-off-by: Tugrahan Karakadioglu <104067096+tgrhn@users.noreply.github.com>
Signed-off-by: Tugrahan Karakadioglu <104067096+tgrhn@users.noreply.github.com>
@github-actions

Copy link
Copy Markdown
Contributor

👋 Hi! Thank you for contributing to the vLLM Ascend project. The following points will speed up your PR merge:‌‌

  • A PR should do only one thing, smaller PRs enable faster reviews.
  • Every PR should include unit tests and end-to-end tests ‌to ensure it works and is not broken by other future PRs.
  • Write the commit message by fulfilling the PR description to help reviewer and future developers understand.

If CI fails, you can run linting and testing checks locally according Contributing and Testing.

🤖 How to trigger CI

CI runs automatically when the PR is opened or reopened. Pushing a new commit no longer re-runs the E2E CI (to save NPU runner resources), so use the comment commands below when needed. They are available to the PR author and users with triage permission or above:

  • /run — run the full PR CI gate on the latest commit.
  • /rerun — re-run the failed CI jobs (e.g. after a flaky failure).
  • /e2e — run selected E2E tests instead of the full gate.
  • /nightly / /presmoke / /weekly — run the corresponding large-scale tests (triage permission or above; blocked during the nightly maintenance window).
  • /cancel — cancel a running CI on this PR.

Note

Until the CI gate has run on a commit, the required ci-gate check stays pending and the PR cannot merge — remember to comment /run after pushing.


Tip

💡 Consider Linking a Related Issue or RFC

Your PR title contains the [BugFix] tag, indicating a bug fix or new feature.

Linking a related issue or RFC in the PR description is strongly encouraged — it gives reviewers helpful context and speeds up the review. You can use any of these keywords:

  • Fixes #<issue_number>
  • Closes #<issue_number>
  • Resolves #<issue_number>
  • Refs #<rfc_or_issue_number> (for RFCs)

🙏 Thanks for helping us keep the project well-organized!

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request replaces version-based checks (vllm_version_is("0.34.0")) with capability-based checks using hasattr(EagleModelMixin, "aux_hidden_state_slot_keys") in both the DeepSeek-V2 patch and its unit tests. This ensures the correct relay protocol is chosen even when the pinned main checkout and the release report the same vLLM version. Feedback on the PR notes that a release notes fragment is required for this user-facing change in accordance with the repository style guide.

if vllm_version_is("0.34.0"):
# Choose the relay protocol by capability because the pinned main checkout
# and the release can report the same vLLM version.
if not hasattr(EagleModelMixin, "aux_hidden_state_slot_keys"):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

According to the repository style guide, every user-facing pull request must include a release notes fragment under release_notes/fragments/<PR number>.yaml following the template in release_notes/TEMPLATE.yaml. Since this PR fixes a launch failure on Qwen3.6 MXFP8 TP2, it is user-facing and requires a release notes fragment describing the user-visible symptom.

References
  1. Every user-facing PR must add release_notes/fragments/<PR number>.yaml following release_notes/TEMPLATE.yaml. (link)

@github-actions

Copy link
Copy Markdown
Contributor

Last updated: 2026-12-01 01:08 UTC+8 for commit 946ab54.

ci-gate failed. Reason:

pre-commit failed (lint / markdownlint / mypy / gitleaks). Open the failed 'pre-commit' job above, fix the reported issues in your PR, and push again. No test label is needed for this failure.

See the workflow run for full logs. This comment is updated in place on each new failure and marked as passed once the gate passes (it is kept for history, not deleted).

Signed-off-by: Tugrahan Karakadioglu <104067096+tgrhn@users.noreply.github.com>
Signed-off-by: Tugrahan Karakadioglu <104067096+tgrhn@users.noreply.github.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant