Skip to content

Fix DSV4 DSpark sample-from-anchor initialization - #36419

Merged
hnyls2002 merged 2 commits into
sgl-project:mainfrom
weireweire:fix/dsv4-dspark-sample-from-anchor
Aug 26, 2026
Merged

hnyls2002 merged 2 commits into
sgl-project:mainfrom
weireweire:fix/dsv4-dspark-sample-from-anchor

Conversation

@weireweire

@weireweire weireweire commented Aug 26, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Initialize the standalone DeepSeek-V4 DSpark draft model sample-from-anchor setting from its checkpoint config.
  • Keep its required worker-facing interface consistent with generic DSpark draft models.

Motivation

The shared DSpark runner reads sample_from_anchor from every draft model. The generic DSpark mixin initializes it, but DeepseekV4ForCausalLMDSpark is a standalone implementation and omitted the attribute, causing startup to fail with AttributeError after #36186.

Validation

  • Python syntax compilation
  • Full pre-commit suite

CI States

Latest PR Test (Base): ⏳ Run #32932193005
Latest PR Test (Extra): ❌ Run #32932192777
Latest PR Test (AMD ROCm 7.2): ⏳ Run #32932192944

Root cause: the shared DSpark runner now requires every draft model to expose sample_from_anchor, but the standalone DeepSeek-V4 DSpark implementation did not inherit the generic DSpark mixin that initializes it. Startup therefore failed with AttributeError.\n\nFix: initialize sample_from_anchor directly from the DeepSeek-V4 draft checkpoint config using the shared DSpark config helper.\n\nValidation: Python syntax compilation, diff checks, and the full pre-commit suite passed.
@weireweire

Copy link
Copy Markdown
Contributor Author

@Fridge003 hi, could you have a look?

@weireweire

Copy link
Copy Markdown
Contributor Author

/tag-and-rerun-ci

@github-actions github-actions Bot added the run-ci CI: run the baseline test suite on this PR label Aug 26, 2026
@hnyls2002

Copy link
Copy Markdown
Collaborator

/rerun-test test_deepseek_v4_shared_expert_fusion.py test_runai_model_streamer_loader.py test_dspark_draft_path_default.py

@github-actions

github-actions Bot commented Aug 26, 2026 •

Copy link
Copy Markdown
Contributor

Results for /rerun-test test_deepseek_v4_shared_expert_fusion.py test_runai_model_streamer_loader.py test_dspark_draft_path_default.py:

🚀 ubuntu-latest (3 tests): ✅ View workflow run

cd test/ && python3 registered/unit/models/test_deepseek_v4_shared_expert_fusion.py
cd test/ && python3 registered/unit/model_loader/test_runai_model_streamer_loader.py
cd test/ && python3 registered/spec/dspark/test_dspark_draft_path_default.py

@hnyls2002
hnyls2002 merged commit db15976 into sgl-project:main Aug 26, 2026
100 of 155 checks passed
@weireweire
weireweire deleted the fix/dsv4-dspark-sample-from-anchor branch August 27, 2026 07:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

deepseek run-ci CI: run the baseline test suite on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants