Ai agent is not calling tool some time , if connected with memory

I have the same problem.

The Agent (LLM) ends its actions by simulating a tool call in the following format:

Calling My_Tool with input: {“query”:“my query”,“tool”:“my_tool”,“id”:“call_453138186985815f”}

This is especially common when forcing the Agent to call tools sequentially. It will call the first one correctly, but the second one will fail with the aforementioned error.

I think a similar problem was also observed in the following issue.