mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-04-28 06:51:16 +08:00
fix: add missing re.DOTALL flag to DeepSeek V3 tool call parser
This commit is contained in:
@@ -38,7 +38,8 @@ class DeepSeekV3ToolCallParser(ToolCallParser):
|
|||||||
|
|
||||||
# Regex captures: type, function_name, function_arguments
|
# Regex captures: type, function_name, function_arguments
|
||||||
PATTERN = re.compile(
|
PATTERN = re.compile(
|
||||||
r"<|tool▁call▁begin|>(?P<type>.*)<|tool▁sep|>(?P<function_name>.*)\n```json\n(?P<function_arguments>.*)\n```<|tool▁call▁end|>"
|
r"<|tool▁call▁begin|>(?P<type>.*)<|tool▁sep|>(?P<function_name>.*)\n```json\n(?P<function_arguments>.*)\n```<|tool▁call▁end|>",
|
||||||
|
re.DOTALL,
|
||||||
)
|
)
|
||||||
|
|
||||||
def parse(self, text: str) -> ParseResult:
|
def parse(self, text: str) -> ParseResult:
|
||||||
|
|||||||
Reference in New Issue
Block a user