I want to have a function that I can define as a tool for tool invocation. The parameter of the function is an object type, such as public String test(User user). How should I define this tool?

Comment From: AI-Agent-Java-Fun

Hi! Judging by the documentation and user experience, to use pojo as a method parameter, it is enough to comply with the conditions for serializing your object in json format, otherwise the model should handle itself when sending a request to execute the tool. If you want, you can add additional explanations inside the ToolParam annotation.