-
Notifications
You must be signed in to change notification settings - Fork 149
LLM gets cognitive overload from overlapping tool names fff_grep and fff_multi_grep #311
Copy link
Copy link
Open
Description
This is GLM-4.7 justyfing why it did not succeeded on the tool use at the first attempt:
fff_grep:
"query": required, type: string
fff_multi_grep:
"patterns": required, type: array of strings
The tool schemas are clearly presented to me. My mistake was:
1. Mental confusion - I was thinking "I want to search for multiple things" so I defaulted to patterns
2. Tool mix-up - I conflated fff_grep (single query) with fff_multi_grep (array of patterns)
3. Not checking the schema - The description says "use ONE specific term" but I ignored it and assumed I could pass an array
The correct approach would have been:
- For multiple terms → use fff_multi_grep with {"patterns": ["term1", "term2"]}
- For single term → use fff_grep with {"query": "term"}
My proposal - one tool fff_grep with array for patterns:
{
"name": "fff_grep",
"description": "Searches for one or more specific terms or regex patterns. To search for a single term, pass an array with one item.",
"parameters": {
"type": "object",
"properties": {
"patterns": {
"type": "array",
"items": {
"type": "string"
},
"description": "A list of strings or regex patterns to search for. Example for single: ['term']. Example for multiple: ['term1', 'term2']."
}
},
"required": ["patterns"]
}
}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels