Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
25708d31
Unverified
Commit
25708d31
authored
Jul 28, 2025
by
Michard Hugo
Committed by
GitHub
Jul 28, 2025
Browse files
[Bugfix] Mistral crashes on tool with no description (#21167)
Signed-off-by:
HugoMichard
<
hugo@harfanglab.fr
>
parent
0e18a5d0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
vllm/transformers_utils/tokenizers/mistral.py
vllm/transformers_utils/tokenizers/mistral.py
+4
-1
No files found.
vllm/transformers_utils/tokenizers/mistral.py
View file @
25708d31
...
...
@@ -183,7 +183,8 @@ def make_mistral_chat_completion_request(
message
[
"content"
]
=
content
# The Mistral client, in comparison to the OpenAI client, requires the
# "parameters" dict to be present, even if it's empty.
# "parameters" dict and the "description" string to be present
# even if they are empty.
if
tools
:
for
function
in
[
tool
[
"function"
]
for
tool
in
tools
...
...
@@ -191,6 +192,8 @@ def make_mistral_chat_completion_request(
]:
if
function
.
get
(
"parameters"
)
is
None
:
function
[
"parameters"
]
=
{}
if
function
.
get
(
"description"
)
is
None
:
function
[
"description"
]
=
""
from
mistral_common.protocol.instruct.request
import
ChatCompletionRequest
return
ChatCompletionRequest
(
messages
=
messages
,
...
...
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