422 Client Error from Tool Call Argument Formatting

Hello,

I’m trying to run an Agent with only one tool that queries an exisiting vector DB. The agent is returning the proper input but it seems like they aren’t being formatted the proper way for the HuggingFace model I’m using (meta-llama/Llama-3.2-3B-Instruct)

I’m receiving the following error:

Unable to decode function arguments:                                                                                                                        
{'query': '<Correct query extracted from prompt>'}
Error: the JSON object must be str, bytes or bytearray, not dict  

Unexpected error invoking HuggingFace model: 422 Client Error: Unprocessable Entity for url: https://api-inference.huggingface.co/models/meta-llama/Llama-3.2-3B-Instruct/v1/chat/completions

Failed to deserialize the JSON body into the target type: messages[2].content: data did not match any variant of untagged enum MessageContent at line 1 column 1110

My agno installation is the most up-to-date. Any information on how to solve this issue?

Hi @cyd
Thanks for reaching out and for using Agno! I’ve looped in the right engineers to help with your question. We usually respond within 48 hours, but if this is urgent, just let us know, and we’ll do our best to prioritize it.
Appreciate your patience—we’ll get back to you soon! :smile:

Hi @cyd,

We’ve implemented a fix for this issue, and it should now be resolved. Could you please check and let us know if you encounter any further difficulties?

Thanks!