Crew based evaluation feedback loop #1700
Replies: 1 comment
-
I noticed that AIXP have a pattern to solve this issue of Loop detection and prevention across agent to agent communication, so if crewai can implement this within a crew would be great (especially a hierarchical crew with a manger). Message Tracking: Each message exchanged between AI agents includes a unique identifier and a counter. The counter increments with each subsequent communication involving the same message. If the counter reaches a predefined threshold, the communication is terminated to prevent a loop. This could be settings which are defined as part of the crew definition, and then the output is considered good enough to proceed to the next crew or finish up with the existing crew. |
Beta Was this translation helpful? Give feedback.
-
Whilst their is a pattern for feedback loops using flows across crews, if you want to have a hierarchical process with a manager to assign tasks, and you want a QA review process to provide feedback to the other agents within the crew - then I think it's better if the agents are all in the same crew especially if their work is highly co-related with each other.
Unfortunately, this could end up in an infinite loop, or they could keep iterating the idea a long time, especially if one agent thinks the goal is achieved but the reviewer uncovers more gaps - I guess you implement a stopping condition in the task definition and have the manager track how many iterations the team have gone through, however, I guess their is a risk these instructions get lost if the context is too long - I guess it would be good to support this concept properly OOTB and so it could be injected in the user prompt just like the tool information etc at the top - or some other way to track the number of iterations across multiple agents.
Beta Was this translation helpful? Give feedback.
All reactions