Conversation
Owner
Author
|
Pushed to a previous version of tools-rs, fixed it in the last commits. @rmaze requesting approval. |
Signed-off-by: Marc <44448012+EggerMarc@users.noreply.github.com>
Signed-off-by: Marc <44448012+EggerMarc@users.noreply.github.com>
rmaze
approved these changes
Sep 21, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog
Added
FunctionResponseas the response struct of a successfultoolcall.This struct will hold
id: Option<CallId>,name: String,result: Valueas fields and implements serde serialization, as display, and PartialEq. The idea behind is to be able to further down the road add tracing to function calls for better management of calls, as well as improved control in serialization.Added
CallIdin bothFunctionResponse(as stated above) andFunctionCall.Attaching an id to a
toolcall is a common practice across LLM providers, as we're able to more easily build stack traces and logging. This is a requirement to later on build tracing support.Implemented
DisplayforFunctionResponse.Breaking changes
newinstead of building it out manually.newwill assign an id to theFunctionCall. If you do not wish to have an id to the call, manually set it toNone, as such.resulttoFunctionResponse.Previously, a
toolcall would simply result inserde::Value. Now, as stated above, you need to manually take the result field of theFunctionResponse.