Fix: Resolve issue #5814 by adjusting function call prompt order in messages#5882
Fix: Resolve issue #5814 by adjusting function call prompt order in messages#5882Frank-Jie wants to merge 2 commits intosgl-project:mainfrom
Conversation
…end of messages
CatherineSue
left a comment
There was a problem hiding this comment.
LGTM. Please correct me if I'm wrong: the order of messages have an effect in deepseekv3 function call results?
Can you add a system role under https://github.com/sgl-project/sglang/blob/main/test/srt/test_function_calling.py#L76 to make sure this doesn't affect other models' behavior?
|
Merged the system messages ( if provided by the user) instead of simply changing the position to make the structure more consistent with the typical message format. |
Thank you for your feedback.
|
|
@Frank-Jie thanks for the detailed info and thorough tests. I opened #5908 to add the chat template. I also attached a few test cases there. Can you take a look to see if it would cover the case you mentioned above? thanks |
Motivation
Modifications
The position of function call prompts in the messages has been modified to ensure correct function response.