fix(langchain): fix tests on standard content branch (#32590)

This commit is contained in:
ccurme
2025-08-18 10:49:01 -03:00
committed by GitHub
parent aca7c1fe6a
commit aeea0e3ff8
3 changed files with 8 additions and 1 deletions

View File

@@ -47,7 +47,12 @@ def parse_ai_message_to_tool_action(
try:
args = json.loads(function["arguments"] or "{}")
tool_calls.append(
ToolCall(name=function_name, args=args, id=tool_call["id"]),
ToolCall(
type="tool_call",
name=function_name,
args=args,
id=tool_call["id"],
),
)
except JSONDecodeError as e:
msg = (

View File

@@ -277,6 +277,7 @@ def test_configurable_with_default() -> None:
"model_kwargs": {},
"streaming": False,
"stream_usage": True,
"output_version": "v0",
},
"kwargs": {
"tools": [{"name": "foo", "description": "foo", "input_schema": {}}],

View File

@@ -277,6 +277,7 @@ def test_configurable_with_default() -> None:
"model_kwargs": {},
"streaming": False,
"stream_usage": True,
"output_version": "v0",
},
"kwargs": {
"tools": [{"name": "foo", "description": "foo", "input_schema": {}}],