Describe the problem/error/question
The AI Agent is unable to utilize multiple tools to complete the task requested by the user.
As shown in the screenshot, the workflow employs three tools:
- Get UDAS Admin Users
- Get UDAS request created by Users
- Construct the UDAS url
The user's query is: “What are the urls of the OPEN UDAS requests from current UDAS admin user?”. To address this, the AI Agent needs to call these three tools sequentially, using the output of one tool as the input for the next. However, it appears the AI Agent can only execute one tool at a time:
Interestingly, the input for the tool being called contains the correct reasoning:
{
"query": {
"request_ids": "[get_udas_request_created_by_user(email=get_current_udas_admin_user_info()['email'], status='OPEN')['request_ids']"]"
}
}
The sequence for calling the tools is correct, but the AI Agent seems to fail in calling multiple tools consecutively to fulfill the task. What is the recommended solution for this issue?
What is the error message (if any)?
Please share your workflow
Share the output returned by the last node
JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 2 (char 1)
Information on your n8n setup
- n8n version: 1.88.0
- Database (default: SQLite): Postgres
- n8n EXECUTIONS_PROCESS setting (default: own, main): main
- Running n8n via (Docker, npm, n8n cloud, desktop app): docker
- Operating system: Apple Silicon OS
Hello there!
If any part of the original text is in Portuguese, please translate it into your preferred language, as I need to understand your question to provide an accurate answer. I will then translate my response back and post it here.
Here's a suggested approach to help with your issue:
Create a separate workflow for testing purposes. Input your credentials and the necessary information.
I hope this is helpful.
If this suggestion resolves your issue, please mark my post as a solution (the blue box with a checkmark) to prevent this discussion from distracting others seeking the answer. Also, please click the heart icon.
Thank you!
Hi there, thanks for assisting with this! However, I'm not entirely grasping the suggestion. I don't have any problems with credentials since the model I'm using is a free version from ollama.
The problem I'm encountering is that to complete a task, the AI agent needs to invoke THREE tools I've defined, utilizing the output from one tool as the input to call another tool, generate the final result, and then return it to the users. But currently, it appears the AI Agent can only invoke ONE tool per execution.
Any additional suggestions would be greatly appreciated!
This thread was automatically closed 90 days following the last response. New replies are no longer permitted.