Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions lua/vectorcode/integrations/codecompanion/func_calling_tool.lua
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@ return check_cli_wrap(function(opts)
then
vim.list_extend(args, { "--project_root", action.options.project_root })
else
agent.chat:add_message(
{ role = "user", content = "INVALID PROJECT ROOT! USE THE LS COMMAND!" },
{ visible = false }
)
return {
status = "error",
data = "INVALID PROJECT ROOT! USE THE LS COMMAND!",
}
end
end

Expand Down Expand Up @@ -244,7 +244,7 @@ return check_cli_wrap(function(opts)
stderr = cc_common.flatten_table_to_string(stderr)
agent.chat:add_tool_output(
self,
string.format("**VectorCode Tool**: Failed with error:\n", stderr)
string.format("**VectorCode Tool**: Failed with error:\n```\n%s\n```", stderr)
)
end,
---@param agent CodeCompanion.Agent
Expand Down
10 changes: 5 additions & 5 deletions lua/vectorcode/integrations/codecompanion/legacy_tool.lua
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@ return check_cli_wrap(function(opts)
vim.list_extend(args, { "--project_root", action.options.project_root })
vim.list_extend(args, { "--absolute" })
else
agent.chat:add_message(
{ role = "user", content = "INVALID PROJECT ROOT! USE THE LS COMMAND!" },
{ visible = false }
)
return {
status = "error",
data = "INVALID PROJECT ROOT! USE THE LS COMMAND!",
}
end
end

Expand Down Expand Up @@ -281,7 +281,7 @@ Remember:
agent.chat:add_message({
role = "user",
content = string.format(
"VectorCode tool failed with the following error:\n",
"VectorCode tool failed with the following error:\n```\n%s\n```",
stderr
),
}, { visible = false })
Expand Down