From 8cca147b94d9b2b7a4e955388a227e40930c5b9d Mon Sep 17 00:00:00 2001 From: yetone Date: Tue, 8 Apr 2025 11:26:49 +0800 Subject: [PATCH] fix: the editing issue on claude (#1828) --- lua/avante/providers/claude.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/avante/providers/claude.lua b/lua/avante/providers/claude.lua index deda9be..8957279 100644 --- a/lua/avante/providers/claude.lua +++ b/lua/avante/providers/claude.lua @@ -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",