From 16a5e92c06fc4f46aa22e31f1819f08f1bbcb565 Mon Sep 17 00:00:00 2001 From: AhJi26 <3094135677@qq.com> Date: Sun, 23 Feb 2025 18:41:44 +0800 Subject: [PATCH] rename llm-tool to search_keyword --- lua/avante/llm_tools.lua | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lua/avante/llm_tools.lua b/lua/avante/llm_tools.lua index a8ca520ce..4d915476d 100644 --- a/lua/avante/llm_tools.lua +++ b/lua/avante/llm_tools.lua @@ -281,7 +281,7 @@ function M.run_command(opts, on_log) if not Path:new(abs_path):exists() then return false, "Path not found: " .. abs_path end if on_log then on_log("command: " .. opts.command) end if - not M.confirm("Are you sure you want to run the command: `" .. opts.command .. "` in the directory: " .. abs_path) + not M.confirm("Are you sure you want to run the command: `" .. opts.command .. "` in the directory: " .. abs_path) then return false, "User canceled" end @@ -581,7 +581,8 @@ M._tools = { { name = "rag_search", enabled = function() return Config.rag_service.enabled and RagService.is_ready() end, - description = "Use Retrieval-Augmented Generation (RAG) to search for relevant information from an external knowledge base or documents. This tool retrieves relevant context from a large dataset and integrates it into the response generation process, improving accuracy and relevance. Use it when answering questions that require factual knowledge beyond what the model has been trained on.", + description = + "Use Retrieval-Augmented Generation (RAG) to search for relevant information from an external knowledge base or documents. This tool retrieves relevant context from a large dataset and integrates it into the response generation process, improving accuracy and relevance. Use it when answering questions that require factual knowledge beyond what the model has been trained on.", param = { type = "table", fields = { @@ -763,7 +764,7 @@ M._tools = { }, }, { - name = "search", + name = "search_keyword", description = "Search for a keyword in a directory", param = { type = "table",