-
Notifications
You must be signed in to change notification settings - Fork 70
feat(mcp): add mcp list-tools to list available tool calls #1213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: wb/parse-mcp-tool-json
Are you sure you want to change the base?
Conversation
|
This change is part of the following stack: Change managed by git-spice. |
b795d99 to
73b6673
Compare
a48bc5a to
f243dec
Compare
73b6673 to
4c6a6bd
Compare
27719e1 to
2414ed5
Compare
33e5f58 to
711d1bf
Compare
80a7854 to
d837a9c
Compare
e9da8bb to
ea3325b
Compare
d837a9c to
dff22dd
Compare
ea3325b to
89494c8
Compare
78d5bf9 to
0649d9b
Compare
| fmt.Printf(" • %s\n", name) | ||
| } | ||
| fmt.Println("\nUSAGE:") | ||
| fmt.Printf(" • Invoke a tool\n") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor: Why not just a normal ascii * instead of unicode stars? Ignore me if I am too much of an ASCII lover.
| Name: t.Name, | ||
| // normalize the raw mcp tool name to be without the mcp identifiers | ||
| rawName := t.Name | ||
| name, _ := strings.CutPrefix(rawName, "sg_") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
trimprefix?
| var r RawSchema | ||
| if err := json.Unmarshal(raw, &r); err != nil { | ||
| d.errors = append(d.errors, fmt.Errorf("failed to parse property %q: %w", name, err)) | ||
| d.errors = append(d.errors, errors.Newf("failed to parse property %q: %w", name, err)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
errors.Wrapf(err, ...
add subcommand to
mcpto list the various tools parsed from the mcp tool jsonPart of SRCH-2167
Test plan
executed locally