Fix Custom Tool File Upload: Resolve Multiple Files Recognition and Multipart Boundary Issues (#14014)
Co-authored-by: crazywoola <427733928@qq.com>
This commit is contained in:
@@ -186,6 +186,9 @@ class ApiBasedToolSchemaParser:
|
||||
return ToolParameter.ToolParameterType.BOOLEAN
|
||||
elif typ == "string":
|
||||
return ToolParameter.ToolParameterType.STRING
|
||||
elif typ == "array":
|
||||
items = parameter.get("items") or parameter.get("schema", {}).get("items")
|
||||
return ToolParameter.ToolParameterType.FILES if items and items.get("format") == "binary" else None
|
||||
else:
|
||||
return None
|
||||
|
||||
|
Reference in New Issue
Block a user