Find answers from the community

Updated 5 months ago

Tools

At a glance

The post indicates that the get_parameters_dict function is problematic. The comments suggest that the tool call arguments should be more descriptive, with a structured schema for parameters. Community members discuss issues with the current implementation, such as the limited character count in the main tool description and the lack of proper fine-tuning. They also explore alternative approaches like using fn_schema, but note that it doesn't accept a dictionary or JSON format. The discussion involves various related concepts and functions, but there is no explicitly marked answer.

get_parameters_dict is problemmatic
L
z
10 comments
What's wrong with it? Do open a PR if you spot an issue πŸ™
it's that tool call arguments are supposed to be pretty descriptive with like:
Plain Text
"parameters": {
                    "type": "object",
                    "properties": {
                        "name": {
                            "type": "string",
                            "description": "The name of the thing.",
                        },
"required": ["name"]
docstrings can provide it but the current llamaindex implementation just dumps it all in the main tool description
which is limited in how many characters it can hold, and isn't how gpt is fine-tuned
maybe I'll feel better about a PR after sleep
wait maybe I was just relying on that when I could set fn_schema
fn_schema doesn't take a dict or json. It wants, something...
yeah it's not doing the fun thing
so let's dump some tags here...
.schema()
deprecated
model_json_schema
to_tool_list()
parameters.items()
get_parameters_dict()
to_openai_tool()
ToolOutput

DefaultToolFnSchema
input
Add a reply
Sign up and join the conversation on Discord