Commit 90b38381 authored by IanShaw027's avatar IanShaw027
Browse files

fix: 移除 Gemini 不支持的 patternProperties 字段 #795

parent 19d3ecc7
...@@ -3235,7 +3235,7 @@ func cleanToolSchema(schema any) any { ...@@ -3235,7 +3235,7 @@ func cleanToolSchema(schema any) any {
for key, value := range v { for key, value := range v {
// 跳过不支持的字段 // 跳过不支持的字段
if key == "$schema" || key == "$id" || key == "$ref" || if key == "$schema" || key == "$id" || key == "$ref" ||
key == "additionalProperties" || key == "minLength" || key == "additionalProperties" || key == "patternProperties" || key == "minLength" ||
key == "maxLength" || key == "minItems" || key == "maxItems" { key == "maxLength" || key == "minItems" || key == "maxItems" {
continue continue
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment