Skip to content

Commit

Permalink
[HOTFIX] Fix the bug in ReAct Agent that the parameter max_retries
Browse files Browse the repository at this point in the history
…doesn't work (#464)

Co-authored-by: zengminchen <[email protected]>
  • Loading branch information
zzzmc and zengminchen authored Oct 24, 2024
1 parent 9cde8a6 commit eeee97a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/agentscope/agents/react_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ def reply(self, x: Optional[Union[Msg, Sequence[Msg]]] = None) -> Msg:
"""The reply method of the agent."""
self.memory.add(x)

for _ in range(10):
for _ in range(self.max_iters):
# Step 1: Reasoning: decide what function to call
function_call = self._reasoning()

Expand Down

0 comments on commit eeee97a

Please sign in to comment.