From 3354dcff834ec1db93e90f46cd4f7ec285bb96c5 Mon Sep 17 00:00:00 2001 From: LeonOstrez Date: Wed, 22 Nov 2023 14:17:19 +0000 Subject: [PATCH] fix counting current_step_index --- pilot/helpers/Debugger.py | 2 +- pilot/helpers/agents/Developer.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pilot/helpers/Debugger.py b/pilot/helpers/Debugger.py index dbf7a6e883..83d8c33731 100644 --- a/pilot/helpers/Debugger.py +++ b/pilot/helpers/Debugger.py @@ -79,7 +79,7 @@ class Debugger: result['completed_steps'] = completed_steps result['current_step'] = steps[step_index] result['next_steps'] = steps[step_index + 1:] - result['current_step_index'] = step_index + len(completed_steps) + result['current_step_index'] = step_index # Remove the previous debug plan and build a new one convo.remove_last_x_messages(2) diff --git a/pilot/helpers/agents/Developer.py b/pilot/helpers/agents/Developer.py index d89b1ce84b..0880770c83 100644 --- a/pilot/helpers/agents/Developer.py +++ b/pilot/helpers/agents/Developer.py @@ -114,7 +114,7 @@ class Developer(Agent): result['completed_steps'] = completed_steps result['current_step'] = steps[step_index] result['next_steps'] = steps[step_index + 1:] - result['current_step_index'] = step_index + len(completed_steps) + result['current_step_index'] = step_index convo_dev_task.remove_last_x_messages(2) # todo before updating task first check if update is needed