autogen icon indicating copy to clipboard operation
autogen copied to clipboard

[Roadmap] Persistence and state management

Open ekzhu opened this issue 1 year ago • 3 comments

We want to be able to persist the state of a multi-agent workflow and restart from a given state. This is required for large-scale deployment of AutoGen workflows. The key steps are:

  1. How to inject state (e.g., conversation history) into a multi-agent workflow so it starts from a given state. This functionality can also be used to implement in-context learning for individual agents, so they learn from a curated set of instructions and examples before participating in a workflow.
  2. How to export the state of a multi-agent workflow.

We start building (1) and (2) for individual class:

  • single-agent
  • two-agent chat
  • sequential chats
  • group chat,

and then move on to think about a composed workflow of multiple conversation patterns.

### Tasks
- [ ] GPTAssistantAgent add "thread_id" to its constructor to gain prior message histories. @jtrugman
- [ ] `initiate_chat` to add prior conversation histories for the two-agent chat.
- [ ] https://github.com/microsoft/autogen/issues/2359
- [ ] https://github.com/microsoft/autogen/issues/2671

ekzhu avatar Apr 11 '24 15:04 ekzhu

Hi! I have following use case: In multi-agen conversation with human, there is an Agent named "collector" which collects info about the user to json from conversation. That meta-information I want to use sometimes, and "coordinator" will decide when to call it to context.

Is this feature about state management? I want to implement it for my project, and may be it will be nice to PR this to main repo too?

For example: user_meta_info = { "Name": "Boris", "Chronic deseases": "astma, headache" }

NikolayTV avatar Apr 17 '24 10:04 NikolayTV

You are thinking about a usage case that is a natural language text to JSON conversion. You can certainly create a two-agent chats to collect human input and then in the initiate_chat use a summary_method=reflection_with_llm and summary_args={"summary_prompt": "extract the following information ... and returns a JSON"}. This is not directly really related to the state management.

ekzhu avatar Apr 17 '24 16:04 ekzhu

How could this support async chats?

randombet avatar Apr 23 '24 19:04 randombet

Partially completed due to resumable group chat. We can open new issue if necessary.

ekzhu avatar Aug 27 '24 01:08 ekzhu