From 0d2d7fd43911d81be4bab548d68687ad4b9fd250 Mon Sep 17 00:00:00 2001 From: Sambhav Dixit <94298612+sambhavnoobcoder@users.noreply.github.com> Date: Sun, 27 Oct 2024 18:38:27 +0530 Subject: [PATCH] add log methods to run - adding updated log methods to run --- swarms/structs/agent.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/swarms/structs/agent.py b/swarms/structs/agent.py index 1471ff3e..39bf238b 100644 --- a/swarms/structs/agent.py +++ b/swarms/structs/agent.py @@ -783,6 +783,8 @@ class Agent: or loop_count < self.max_loops ): loop_count += 1 + # Log step start + current_step_id = f"step_{loop_count}_{uuid.uuid4().hex}" self.loop_count_print(loop_count, self.max_loops) print("\n") @@ -836,6 +838,9 @@ class Agent: # Convert to a str if the response is not a str response = self.llm_output_parser(response) + + # Log step metadata + step_meta = self.log_step_metadata(loop_count, task_prompt, response) # Print if self.streaming_on is True: