From a0ab6af42ed7d148a68c947035995dd6fa77cfc4 Mon Sep 17 00:00:00 2001 From: Sambhav Dixit <94298612+sambhavnoobcoder@users.noreply.github.com> Date: Fri, 25 Oct 2024 03:37:01 +0530 Subject: [PATCH] style check --- swarms/structs/agent.py | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/swarms/structs/agent.py b/swarms/structs/agent.py index a089aee5..e6ca4405 100644 --- a/swarms/structs/agent.py +++ b/swarms/structs/agent.py @@ -803,14 +803,8 @@ class Agent: self.memory_query(task_prompt) # Generate response using LLM - response_args = ( - (task_prompt, *args) - if img is None - else (task_prompt, img, *args) - ) - response = self.call_llm( - *response_args, **kwargs - ) + response = self.llm(task_prompt, *args, **kwargs) + # Check if response is a dictionary and has 'choices' key if isinstance(response, dict) and 'choices' in response: