fix: the editing issue on claude (#1828)

This commit is contained in:
yetone
2025-04-08 11:26:49 +08:00
committed by GitHub
parent c0d3afe0a4
commit 8cca147b94

View File

@@ -345,7 +345,7 @@ function M:parse_curl_args(prompt_opts)
end
end
if prompt_opts.tools and Config.behaviour.enable_claude_text_editor_tool_mode then
if prompt_opts.tools and #prompt_opts.tools > 0 and Config.behaviour.enable_claude_text_editor_tool_mode then
if provider_conf.model:match("claude%-3%-7%-sonnet") then
table.insert(tools, {
type = "text_editor_20250124",