feat: disable tools with config (#1459)
* chore: use missing generic for AvanteLLMToolFunc * feat: add disabled_tools config
This commit is contained in:
@@ -569,7 +569,9 @@ end
|
||||
function M.get_tools()
|
||||
return vim
|
||||
.iter(M._tools)
|
||||
:filter(function(tool)
|
||||
:filter(function(tool) ---@param tool AvanteLLMTool
|
||||
-- Always disable tools that are explicitly disabled
|
||||
if vim.tbl_contains(Config.disabled_tools, tool.name) then return false end
|
||||
if tool.enabled == nil then
|
||||
return true
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user