Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
change
sglang
Commits
9ba72530
Unverified
Commit
9ba72530
authored
Aug 21, 2025
by
gongwei-130
Committed by
GitHub
Aug 21, 2025
Browse files
accomendate reasoning_effort set in chat_template_kwargs (#9458)
parent
9c8e4f69
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
python/sglang/srt/entrypoints/openai/serving_chat.py
python/sglang/srt/entrypoints/openai/serving_chat.py
+8
-0
No files found.
python/sglang/srt/entrypoints/openai/serving_chat.py
View file @
9ba72530
...
@@ -87,6 +87,14 @@ class OpenAIServingChat(OpenAIServingBase):
...
@@ -87,6 +87,14 @@ class OpenAIServingChat(OpenAIServingBase):
self
,
self
,
request
:
ChatCompletionRequest
,
request
:
ChatCompletionRequest
,
)
->
tuple
[
GenerateReqInput
,
ChatCompletionRequest
]:
)
->
tuple
[
GenerateReqInput
,
ChatCompletionRequest
]:
reasoning_effort
=
(
request
.
chat_template_kwargs
.
pop
(
"reasoning_effort"
,
None
)
if
request
.
chat_template_kwargs
else
None
)
if
reasoning_effort
is
not
None
:
request
.
reasoning_effort
=
reasoning_effort
"""Convert OpenAI chat completion request to internal format"""
"""Convert OpenAI chat completion request to internal format"""
is_multimodal
=
self
.
tokenizer_manager
.
model_config
.
is_multimodal
is_multimodal
=
self
.
tokenizer_manager
.
model_config
.
is_multimodal
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment