tool-calls: r1: add missing <|tool▁calls▁end|> to grammar!
This commit is contained in:
parent
08271b5505
commit
df3474e2c2
1 changed files with 7 additions and 1 deletions
|
@ -552,9 +552,15 @@ static common_chat_params common_chat_params_init_deepseek_r1(const common_chat_
|
||||||
"<think>",
|
"<think>",
|
||||||
"</think>",
|
"</think>",
|
||||||
"<|tool▁sep|>",
|
"<|tool▁sep|>",
|
||||||
|
"<|tool▁calls▁end|",
|
||||||
|
"<|tool▁call▁begin|>",
|
||||||
"<|tool▁call▁end|>",
|
"<|tool▁call▁end|>",
|
||||||
};
|
};
|
||||||
builder.add_rule("root", "\"<|tool▁calls▁begin|>\" (" + string_join(tool_rules, " | ") + ")" + (inputs.parallel_tool_calls ? "*" : "") + " space");
|
builder.add_rule("root",
|
||||||
|
"\"<|tool▁calls▁begin|>\""
|
||||||
|
" (" +string_join(tool_rules, " | ") + ")" + (inputs.parallel_tool_calls ? "*" : "") +
|
||||||
|
"\"<|tool▁calls▁end|>\""
|
||||||
|
" space");
|
||||||
}, grammar_options);
|
}, grammar_options);
|
||||||
/*
|
/*
|
||||||
Note: we do not feed the thoughts back to the template for a few reasons:
|
Note: we do not feed the thoughts back to the template for a few reasons:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue