Open b4codify opened 2 months ago
@b4codify . Thanks for the issue. This is indeed a bug in the a_generate_reply
method which runs all registered reply functions whether they are async or sync.
To fix this bug, we need to add a new flag to the register_reply
method to allow ignore sync reply functions in async chat, much like the existing flag ignore_async_in_sync_chat
:
And then in the constructor, set this flag to true when registering the a_check_termination_and_human_reply
function.
The team is currently focusing on the release of v0.4 preview. Would you like to submit a PR for this fix?
Thank you!
Describe the bug
Async
a_initiate_chat
agents conversation is interrupting more for human feedback whereas same codebase but for Syncinitiate_chat
workflow only asks once for human feedback. Moreover, in case Async flow, it doesn't execute the generated code after first human no feedback provided at console prompt, but it asks again for the feedback and when user provides no feedback again, only then generated code is executed. Refer the attached console log as well as video recording for your ref.This autogen framework's behavior of asking human feedback multiple times gets very chaotic when there are more agents involved and completely breaks the application logic specially around asking same feedback repeatedly by Async
a_initiate_chat()
agents' workflow.Here is the output for your ref. for both Sync and Async program: SYNC output:
ASYNC output
Steps to reproduce
Refer the Async & Sync code for your ref. SYNC Code
ASYNC Code
Model Used
No response
Expected Behavior
Sync
code block in case ofa_initiate_chat()
call.a_initiate_chat()
call.Screenshots and logs
Additional Information
No response