[Misc] Provide a DeepSeek ReasoningParser with thinking enabled by default#33221
Merged
DarkLight1337 merged 4 commits intovllm-project:mainfrom Jan 28, 2026
Merged
Conversation
…fault Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com>
…fault Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com>
Contributor
There was a problem hiding this comment.
Code Review
This pull request is a solid refactoring effort. It introduces a new DeepSeekV3ReasoningWithThinkingParser to consolidate logic for models that require 'thinking' to be enabled by default, such as glm45, holo2, and kimi_k2. This change effectively reduces code duplication by removing three redundant parser files. The implementation correctly maintains the intended behavior while improving the codebase's maintainability. The changes are well-executed and I don't see any issues.
Collaborator
Author
|
/cc @DarkLight1337 PTAL. |
DarkLight1337
approved these changes
Jan 28, 2026
This was referenced Jan 30, 2026
apd10
pushed a commit
to apd10/vllm
that referenced
this pull request
Jan 31, 2026
…fault (vllm-project#33221) Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com>
PiratePai
pushed a commit
to PiratePai/epd_shm
that referenced
this pull request
Feb 3, 2026
…fault (vllm-project#33221) Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com> Signed-off-by: PiratePai <416932041@qq.com> Signed-off-by: Pai <416932041@qq.com>
ItzDEXX
pushed a commit
to ItzDEXX/vllm
that referenced
this pull request
Feb 19, 2026
…fault (vllm-project#33221) Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com>
3 tasks
he-yufeng
added a commit
to he-yufeng/vllm
that referenced
this pull request
Mar 14, 2026
GLM4 MoE (vllm-project#37023): PR vllm-project#33221 replaced the dedicated Glm4MoeModelReasoningParser with the generic DeepSeekV3ReasoningWithThinkingParser, which delegates to R1. R1 treats tagless text as reasoning, but GLM4 injects <think> via the chat template, so tagless output means the model chose not to reason. Add Glm4MoeReasoningParser that returns (None, content) when </think> is absent, matching the expected semantics. SeedOSS (vllm-project#37022): The streaming path in BaseThinkingReasoningParser returns content for tagless text, but SeedOSS (like R1) may not emit the start token. Add the same R1-style streaming override so tagless streaming text is correctly classified as reasoning. Fixes vllm-project#37023, fixes vllm-project#37022 Signed-off-by: Yufeng He <40085740+he-yufeng@users.noreply.github.com>
2 tasks
he-yufeng
added a commit
to he-yufeng/vllm
that referenced
this pull request
Mar 15, 2026
GLM4 MoE (vllm-project#37023): PR vllm-project#33221 replaced the dedicated Glm4MoeModelReasoningParser with the generic DeepSeekV3ReasoningWithThinkingParser, which delegates to R1. R1 treats tagless text as reasoning, but GLM4 injects <think> via the chat template, so tagless output means the model chose not to reason. Add Glm4MoeReasoningParser that returns (None, content) when </think> is absent, matching the expected semantics. Empty reasoning (<think></think>) is normalized to None. SeedOSS (vllm-project#37022): The streaming path in BaseThinkingReasoningParser returns content for tagless text, but SeedOSS (like R1) may not emit the start token. Add the same R1-style streaming override so tagless streaming text is correctly classified as reasoning. Fixes vllm-project#37023, fixes vllm-project#37022 Signed-off-by: Yufeng He <40085740+he-yufeng@users.noreply.github.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.
Purpose
Provide a DeepSeek ReasoningParser with thinking enabled by default.
Avoid a large amount of duplicated code.
Test Plan
Test Result
Essential Elements of an Effective PR Description Checklist
supported_models.mdandexamplesfor a new model.