Skip to content

Commit 633455e

Browse files
committed
Make <|constrain|> optional
1 parent 4f16cea commit 633455e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

common/parsers/harmony.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ void harmony_msg_parser::commentary() {
6363

6464
void harmony_msg_parser::user_function() {
6565
static const common_regex tool_call_regex(
66-
"functions\\.([a-zA-Z_][a-zA-Z0-9_]*)\\s*(<\\|constrain\\|>([a-z]+))?<\\|message\\|>"
66+
"functions\\.([a-zA-Z_][a-zA-Z0-9_]*)\\s*(<\\|constrain\\|>)?([a-z]+)<\\|message\\|>"
6767
);
6868
if (auto res = builder.try_consume_regex(tool_call_regex)) {
6969
auto name = builder.str(res->groups[1]);

0 commit comments

Comments
 (0)