Skip to content

Commit 14735f9

Browse files
committed
chore: remove ListTools
Signed-off-by: Donnie Adams <[email protected]>
1 parent b51e30e commit 14735f9

File tree

3 files changed

+0
-47
lines changed

3 files changed

+0
-47
lines changed

README.md

-26
Original file line numberDiff line numberDiff line change
@@ -47,32 +47,6 @@ As noted above, the Global Options are also available to specify here. These opt
4747

4848
## Functions
4949

50-
### listTools
51-
52-
Lists all the available built-in tools.
53-
54-
**Usage:**
55-
56-
```go
57-
package main
58-
59-
import (
60-
"context"
61-
62-
"github.com/gptscript-ai/go-gptscript"
63-
)
64-
65-
func listTools(ctx context.Context) (string, error) {
66-
g, err := gptscript.NewGPTScript(gptscript.GlobalOptions{})
67-
if err != nil {
68-
return "", err
69-
}
70-
defer g.Close()
71-
72-
return g.ListTools(ctx)
73-
}
74-
```
75-
7650
### listModels
7751

7852
Lists all the available models, returns a list.

gptscript.go

-10
Original file line numberDiff line numberDiff line change
@@ -268,16 +268,6 @@ func (g *GPTScript) Version(ctx context.Context) (string, error) {
268268
return out, nil
269269
}
270270

271-
// ListTools will list all the available tools.
272-
func (g *GPTScript) ListTools(ctx context.Context) (string, error) {
273-
out, err := g.runBasicCommand(ctx, "list-tools", nil)
274-
if err != nil {
275-
return "", err
276-
}
277-
278-
return out, nil
279-
}
280-
281271
type ListModelsOptions struct {
282272
Providers []string
283273
CredentialOverrides []string

gptscript_test.go

-11
Original file line numberDiff line numberDiff line change
@@ -66,17 +66,6 @@ func TestVersion(t *testing.T) {
6666
}
6767
}
6868

69-
func TestListTools(t *testing.T) {
70-
tools, err := g.ListTools(context.Background())
71-
if err != nil {
72-
t.Errorf("Error listing tools: %v", err)
73-
}
74-
75-
if len(tools) == 0 {
76-
t.Error("No tools found")
77-
}
78-
}
79-
8069
func TestListModels(t *testing.T) {
8170
models, err := g.ListModels(context.Background())
8271
if err != nil {

0 commit comments

Comments
 (0)