Skip to content

Commit 697e05d

Browse files
authored
Merge pull request #581 from rumpl/remove-unused
Tool display name is no longer needed
2 parents 811af76 + 8db061a commit 697e05d

1 file changed

Lines changed: 0 additions & 17 deletions

File tree

pkg/agent/agent.go

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ package agent
33
import (
44
"context"
55
"fmt"
6-
"log/slog"
76
"math/rand"
87

98
"github.com/docker/cagent/pkg/model/provider"
@@ -116,22 +115,6 @@ func (a *Agent) Tools(ctx context.Context) ([]tools.Tool, error) {
116115
return agentTools, nil
117116
}
118117

119-
func (a *Agent) ToolDisplayName(ctx context.Context, toolName string) string {
120-
allTools, err := a.Tools(ctx)
121-
if err != nil {
122-
slog.Error("Failed to get tools for display name", "agent", a.Name(), "error", err)
123-
return toolName
124-
}
125-
126-
for _, tool := range allTools {
127-
if tool.Name == toolName {
128-
return tool.DisplayName()
129-
}
130-
}
131-
132-
return toolName
133-
}
134-
135118
func (a *Agent) ToolSets() []tools.ToolSet {
136119
var toolSets []tools.ToolSet
137120

0 commit comments

Comments
 (0)