Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions python/sglang/srt/function_call/base_format_detector.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,10 @@ def parse_streaming_increment(
try:
if current_text.startswith(self.bot_token):
start_idx = len(self.bot_token)
elif self.current_tool_id > 0 and current_text.startswith(
self.tool_call_separator + self.bot_token
):
start_idx = len(self.tool_call_separator + self.bot_token)
elif self.current_tool_id > 0 and current_text.startswith(
self.tool_call_separator
):
Expand Down
5 changes: 1 addition & 4 deletions test/srt/openai_server/function_call/test_tool_choice.py
Original file line number Diff line number Diff line change
Expand Up @@ -468,10 +468,7 @@ class TestToolChoiceQwen25(TestToolChoiceLlama32):

@classmethod
def setUpClass(cls):
cls.flaky_tests = {
"test_multi_tool_scenario_auto",
"test_multi_tool_scenario_required",
}
cls.flaky_tests = {}

cls.model = "Qwen/Qwen2.5-7B-Instruct"
cls.base_url = DEFAULT_URL_FOR_TEST
Expand Down
Loading