@@ -243,19 +243,7 @@ static void test_deepseek_v3_1_tool_calls() {
243243    assert_equals (variant, std::string (" " content );
244244    assert_equals (variant, std::string (" " reasoning_content );
245245
246-     //  variant: function + fenced JSON
247-     {
248-         const  std::string variant (" fenced" 
249-         const  std::string in = " <|tool▁calls▁begin|><|tool▁call▁begin|>function<|tool▁sep|>get_time\n ```json\n {\" city\" : \" Tokyo\" }\n ```<|tool▁call▁end|><|tool▁calls▁end|>" 
250-         auto  m = common_chat_parse (in, false , syntax);
251-         assert_equals<std::size_t >(variant, 1 , m.tool_calls .size ());
252-         assert_equals (variant, std::string (" get_time" tool_calls [0 ].name );
253-         assert_equals (variant, std::string (" {\" city\" :\" Tokyo\" }" tool_calls [0 ].arguments );
254-         assert_equals (variant, std::string (" " content );
255-         assert_equals (variant, std::string (" " reasoning_content );
256-     }
257- 
258-     //  variant: function + fenced JSON + thinking open
246+     //  variant: simple + thinking open
259247    {
260248        common_chat_syntax syntax = {
261249            /*  .format = */ 
@@ -264,8 +252,8 @@ static void test_deepseek_v3_1_tool_calls() {
264252            /*  .thinking_forced_open = */ true ,
265253            /*  .parse_tool_calls = */ true ,
266254        };
267-         const  std::string variant (" fenced_thinking " 
268-         const  std::string in = " REASONING</think><|tool▁calls▁begin|><|tool▁call▁begin|>function <|tool▁sep|>get_time \n ```json \n {\" city\" : \" Tokyo\" }\n ``` <|tool▁call▁end|><|tool▁calls▁end|>" 
255+         const  std::string variant (" simple_thinking " 
256+         const  std::string in = " REASONING</think><|tool▁calls▁begin|><|tool▁call▁begin|>get_time <|tool▁sep|>{\" city\" : \" Tokyo\" }<|tool▁call▁end|><|tool▁calls▁end|>" 
269257        auto  m = common_chat_parse (in, false , syntax);
270258        assert_equals<std::size_t >(variant, 1 , m.tool_calls .size ());
271259        assert_equals (variant, std::string (" get_time" tool_calls [0 ].name );
@@ -295,7 +283,7 @@ static void test_deepseek_v3_1_tool_calls() {
295283    }
296284
297285
298-     //  variant: thinking forced open + tool call in reasoning content + function + fenced JSON 
286+     //  variant: thinking forced open + tool call in reasoning content
299287    {
300288        common_chat_syntax syntax = {
301289            /*  .format = */ 
@@ -304,8 +292,8 @@ static void test_deepseek_v3_1_tool_calls() {
304292            /*  .thinking_forced_open = */ true ,
305293            /*  .parse_tool_calls = */ true ,
306294        };
307-         const  std::string variant (" thinking_forced_open_tool_call_in_reasoning_fenced_thinking " 
308-         const  std::string in = " REASONING<|tool▁calls▁begin|><|tool▁call▁begin|>get_time2<|tool▁sep|>{\" city\" : \" Tokyo2\" }<|tool▁call▁end|><|tool▁calls▁end|>REASONING</think><|tool▁calls▁begin|><|tool▁call▁begin|>function <|tool▁sep|>get_time \n ```json \n {\" city\" : \" Tokyo\" }\n ``` <|tool▁call▁end|><|tool▁calls▁end|>" 
295+         const  std::string variant (" thinking_forced_open_tool_call_in_reasoning " 
296+         const  std::string in = " REASONING<|tool▁calls▁begin|><|tool▁call▁begin|>get_time2<|tool▁sep|>{\" city\" : \" Tokyo2\" }<|tool▁call▁end|><|tool▁calls▁end|>REASONING</think><|tool▁calls▁begin|><|tool▁call▁begin|>get_time <|tool▁sep|>{\" city\" : \" Tokyo\" }<|tool▁call▁end|><|tool▁calls▁end|>" 
309297        auto  m = common_chat_parse (in, false , syntax);
310298        assert_equals<std::size_t >(variant, 1 , m.tool_calls .size ());
311299        assert_equals (variant, std::string (" get_time" tool_calls [0 ].name );
0 commit comments