fix: Add minimax to tool call execution handler

This commit is contained in:
2026-03-06 23:51:17 -05:00
parent a47ea47839
commit bc606a8a8d

View File

@@ -578,6 +578,13 @@ async def _execute_tool_calls_concurrently(
call_id = cast(str, fc.get("id"))
try: args = json.loads(tool_args_str)
except: args = {}
elif provider == "minimax":
tool_info = fc.get("function", {})
name = cast(str, tool_info.get("name"))
tool_args_str = cast(str, tool_info.get("arguments", "{}"))
call_id = cast(str, fc.get("id"))
try: args = json.loads(tool_args_str)
except: args = {}
else:
continue
@@ -1775,10 +1782,9 @@ def _send_minimax(md_content: str, user_message: str, base_dir: str,
request_payload["temperature"] = 1.0
request_payload["max_tokens"] = min(_max_tokens, 8192)
# tools disabled for now - MiniMax tool format issue
# tools = _get_deepseek_tools()
# if tools:
# request_payload["tools"] = tools
tools = _get_deepseek_tools()
if tools:
request_payload["tools"] = tools
events.emit("request_start", payload={"provider": "minimax", "model": _model, "round": round_idx, "streaming": stream})