diff --git a/swarms/structs/agent.py b/swarms/structs/agent.py index 5bb9e9b0..29d7037b 100644 --- a/swarms/structs/agent.py +++ b/swarms/structs/agent.py @@ -803,7 +803,14 @@ class Agent: self.memory_query(task_prompt) # Generate response using LLM - response = self.llm(task_prompt, *args, **kwargs) + response_args = ( + (task_prompt, *args) + if img is None + else (task_prompt, img, *args) + ) + response = self.call_llm( + *response_args, **kwargs + ) # Check and execute tools if self.tools is not None: