microsoft / autogen

A programming framework for agentic AI. Discord: https://aka.ms/autogen-dc. Roadmap: https://aka.ms/autogen-roadmap
https://microsoft.github.io/autogen/
Creative Commons Attribution 4.0 International
28.05k stars 4.09k forks source link

Reentrant human input #124

Open tkellogg opened 9 months ago

tkellogg commented 9 months ago

Hi,

I'm looking at the code for the first time, and I'm trying to understand how to involve a human. Looking at the conversable_agent, here's the default implementation:

def get_human_input(self, prompt: str) -> str:
        reply = input(prompt)
        return reply

What if the human is an HTTP response away? What if they're an SMTP relay away? Slack message?

Whenever the human is somewhere else on the network, it seems like I need to keep the autogen process alive. If they take 1 day to respond, that's not ideal, that's a long time to keep an idle process running. How are you planning on dealing with such a scenario?

ChristianWeyer commented 9 months ago

Yep, I had the same observation. For real-world usage, e.g., in a business applications scenario, we need some kind of a workflow engine in addition to the agent system.

tkellogg commented 9 months ago

If the architecture here doesn't support something like this, one way I would (will probably) approach it is to run autogen in some sort of lightweight VM, like firecracker, and when autogen signals that it's idle, pause the whole VM and save it for later reentrance.

afourney commented 9 months ago

I agree with the need to support reentrance or similar. In the two-agent scenario, we've worked around it in stateless environments (e.g., a http), by repopulating the histories, running without human intervention, and controlling the number of steps taken for each request.

sonichi commented 8 months ago

@victordibia @gagb for awareness I've seen many similar questions, and some doc or FAQ will be helpful.

ChristianWeyer commented 1 month ago

Is there a plan for this feature in the current roadmap @sonichi ?