Every Agno run on the LlamaOpenAI and AIMLAPI models raised a TypeError, and the model layer returned that error as the assistant's answer.
Both providers override _format_message, and their overrides no longer matched OpenAIChat, which now passes compress_tool_results as a positional argument.
The Llama override now matches the base class and passes the flag through. The AIMLAPI override is gone, so AIMLAPI uses the base class directly. Compressed tool results now reach both models too.
from agno.agent import Agent
from agno.models.aimlapi import AIMLAPI
from agno.models.meta import LlamaOpenAI
Agent(model=LlamaOpenAI()).print_response("Summarize the benefits of open-source models.")
Agent(model=AIMLAPI()).print_response("Summarize the benefits of open-source models.")See the Meta and AI/ML API model guides in the documentation.
Frequently asked questions
Both providers override _format_message, and those overrides had drifted from OpenAIChat, which now passes compress_tool_results as a positional argument. Each call raised a TypeError, and the Agno model layer returned that error as the assistant's answer.
Yes. The LlamaOpenAI override now passes compress_tool_results through, and AIMLAPI uses the OpenAIChat base class directly, so compressed tool results reach both models.


