mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-05-24 14:15:17 +02:00
update
This commit is contained in:
parent
257553d64d
commit
9435f115af
2 changed files with 3 additions and 4 deletions
|
|
@ -160,8 +160,7 @@ class SelfLearnAndReflect(Action):
|
|||
action = "h_swipe"
|
||||
else:
|
||||
# TODO Test for assignment, This error is eupiped with the next.
|
||||
logger.info(f"Warning: current action name:{self.act_name}")
|
||||
logger.info("Warning: act_name parse wrong!")
|
||||
logger.warning(f"Current action name parse failed, it's `{self.act_name}`")
|
||||
action = None
|
||||
context = reflect_template.format(
|
||||
action=action, ui_element=str(self.ui_area), task_desc=task_desc, last_act=last_act
|
||||
|
|
|
|||
|
|
@ -89,9 +89,9 @@ class AndroidAssistant(Role):
|
|||
"""ignore old memory to make it run multi rounds inside a role"""
|
||||
newest_msgs = self.rc.memory.get(k=1)
|
||||
newest_msg = newest_msgs[0] if newest_msgs else None
|
||||
if newest_msg and (RunState.SUCCESS.value not in newest_msg.content):
|
||||
if newest_msg and (RunState.FAIL.value in newest_msg.content):
|
||||
ignore_memory = False
|
||||
logger.error("Latest action_state is FINISH or FAIL, won't react in remainder rounds")
|
||||
logger.error("Latest action_state is FAIL, won't react in remainder rounds")
|
||||
return await super()._observe(ignore_memory)
|
||||
|
||||
async def _act(self) -> Message:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue