fix plan & task bugs, add task experience, update editor & browser, test issue fixing ability

This commit is contained in:
garylin2099 2024-05-13 15:11:43 +08:00
parent 91b11a2ab9
commit cb6484d01d
9 changed files with 102 additions and 29 deletions

View file

@ -514,6 +514,13 @@ class Plan(BaseModel):
if task_id in self.task_map:
task = self.task_map[task_id]
task.reset()
# reset all downstream tasks that are dependent on the reset task
for dep_task in self.tasks:
if task_id in dep_task.dependent_task_ids:
# FIXME: if LLM generates cyclic tasks, this will result in infinite recursion
self.reset_task(dep_task.task_id)
self._update_current_task()
def replace_task(self, new_task: Task):
"""