summaryrefslogtreecommitdiffhomepage
path: root/internal/llm/agent
diff options
context:
space:
mode:
authoradamdottv <[email protected]>2025-05-14 10:42:16 -0500
committeradamdottv <[email protected]>2025-05-14 10:42:16 -0500
commit4c998d4f4ff2d9570796a81a95eb84d34d0a6939 (patch)
tree99575441e437b14e62dca524d77d4d7a583032ba /internal/llm/agent
parentf7849c2d59d335c91d6ad079cabcda98c8b610f8 (diff)
downloadopencode-4c998d4f4ff2d9570796a81a95eb84d34d0a6939.tar.gz
opencode-4c998d4f4ff2d9570796a81a95eb84d34d0a6939.zip
chore: remove sourcegraph tool
Diffstat (limited to 'internal/llm/agent')
-rw-r--r--internal/llm/agent/tools.go10
1 files changed, 3 insertions, 7 deletions
diff --git a/internal/llm/agent/tools.go b/internal/llm/agent/tools.go
index be1f6ecbf..9551e32c5 100644
--- a/internal/llm/agent/tools.go
+++ b/internal/llm/agent/tools.go
@@ -19,11 +19,8 @@ func PrimaryAgentTools(
lspClients map[string]*lsp.Client,
) []tools.BaseTool {
ctx := context.Background()
- otherTools := GetMcpTools(ctx, permissions)
- // Always add the Diagnostics tool even if lspClients is empty
- // The tool will handle the case when no clients are available
- otherTools = append(otherTools, tools.NewDiagnosticsTool(lspClients))
+ mcpTools := GetMcpTools(ctx, permissions)
return append(
[]tools.BaseTool{
@@ -33,12 +30,12 @@ func PrimaryAgentTools(
tools.NewGlobTool(),
tools.NewGrepTool(),
tools.NewLsTool(),
- // tools.NewSourcegraphTool(),
tools.NewViewTool(lspClients),
tools.NewPatchTool(lspClients, permissions, history),
tools.NewWriteTool(lspClients, permissions, history),
+ tools.NewDiagnosticsTool(lspClients),
NewAgentTool(sessions, messages, lspClients),
- }, otherTools...,
+ }, mcpTools...,
)
}
@@ -47,7 +44,6 @@ func TaskAgentTools(lspClients map[string]*lsp.Client) []tools.BaseTool {
tools.NewGlobTool(),
tools.NewGrepTool(),
tools.NewLsTool(),
- tools.NewSourcegraphTool(),
tools.NewViewTool(lspClients),
}
}