diff --git a/README.md b/README.md index 4e448d6cb..fecfbcef5 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,10 @@

πŸ€– AgentVerse πŸͺ

+

@@ -31,62 +33,50 @@ 【English | Chinese】

-**AgentVerse** offers a versatile framework that streamlines the process of creating custom multi-agent environments for large language models (LLMs). Designed to facilitate swift development and customization with minimal effort, our framework empowers researchers to concentrate on their research, rather than being bogged down by implementation details. - -⚠️⚠️⚠️ We're refactoring the code, and the goal is to provide a flexibility to construct simulation(without a predefined goal) and task-solving(with a specific goal) environments. Please note that this README is slightly outdated, we will update it soon. If you require a stable version that exclusively supports simulation environments, you can use [`release-0.1`](https://github.com/OpenBMB/AgentVerse/tree/release-0.1) branch. - ---- - -## ✨ Features +**AgentVerse** is designed to facilitate the deployment of mutiple LLM-based agents in various applications. AgentVerse primarily provides two frameworks: **task-solving** and **simulation**. -- πŸ₯³ **Efficient Environment Building:** Our framework provides a collection of essential building blocks for effortlessly creating a multi-agent environment. With only a few lines in a configuration file, you can easily construct basic environments such as a chat room for LLMs. This process entails defining the environment's settings and prompts for LLMs, enabling researchers like you to concentrate on experimentation and analysis. +- Task-solving: This framework assembles multiple agents as an automatic multi-agent system ([Multi-agent as system](https://arxiv.org/abs/2309.02427)) to collaboratively accomplish the corresponding tasks. +Applications: software development system, consulting system, etc. -- βš™οΈ **Customizable Components**: AgentVerse simplifies the multi-agent environment by dividing it into five functional modules and defining their respective interfaces. For complex environments that cannot be constructed directly using the basic modules offered in AgentVerse, you can customize one or more of the interfaces within these five functional modules to efficiently create your own multi-agent environment according to your requirements. - -- πŸ›  **Tools (Plugins) Utilization**: AgentVerse supports the multi-agent environments with tools. Currently, AgentVerse supports tools provided in [BMTools](https://github.com/OpenBMB/BMTools). +

+Screen Shot 2023-09-01 at 12 08 57 PM +

-## πŸ“° What's New -- [2023/10/5] πŸ’‘ We release the code of our paper [AgentVerse: Facilitating Multi-Agent Collaboration and Exploring Emergent Behaviors in Agents](https://arxiv.org/abs/2308.10848), and refactor our codebase to enable the creation of both simulation and task-solving environment! We have placed the code for Minecraft example in the paper at the [`minecraft`](https://github.com/OpenBMB/AgentVerse/tree/minecraft) branch. Our tool-using example will soon be updated to the `main` branch. Stay tuned! +- Simulation: This framework allows users to set up custom environments to observe behaviors among, or interact with, multiple agents. ⚠️⚠️⚠️ We're refactoring the code. If you require a stable version that exclusively supports simulation framework, you can use [`release-0.1`](https://github.com/OpenBMB/AgentVerse/tree/release-0.1) branch. Applications: game, social behavior research of LLM-based agents, etc. -- [2023/8/22] πŸ“ We're excited to share our work-in-progress paper [AgentVerse: Facilitating Multi-Agent Collaboration and Exploring Emergent Behaviors in Agents](https://arxiv.org/abs/2308.10848) related to this repository.

-Screen Shot 2023-09-01 at 12 08 57 PM +Screen Shot 2023-10-16 at 10 53 49 PM

-- [2023/6/5] πŸŽ‰ We are thrilled to present an array of [demos](#-simple-demo-video), including [NLP Classroom](#nlp-classroom), [Prisoner Dilemma](#prisoner-dilemma), [Software Design](#software-design), [Database Administrator](#database-administrator-dba), and a simple [H5 Pokemon Game](#pokemon) that enables the interaction with the characters in Pokemon! Try out these demos and have fun! -- [2023/5/1] πŸš€ [AgentVerse](https://github.com/OpenBMB/AgentVerse) is officially launched! -## 🌟 Join Us! -AgentVerse is on a mission to revolutionize the multi-agent environment for large language models, and we're eagerly looking for passionate collaborators to join us on this exciting journey. -### How Can You Contribute? -- **Code Development**: If you're an engineer, help us refine, optimize, and expand the current framework. We're always looking for talented developers to enhance our existing features and develop new modules. +--- -- **Documentation and Tutorials**: If you have a knack for writing, help us improve our documentation, create tutorials, or write blog posts to make AgentVerse more accessible to the broader community. -- **Application Exploration**: If you're intrigued by multi-agent applications and are eager to experiment using AgentVerse, we'd be thrilled to support your journey and see what you create! +# πŸ“° What's New +- [2023/10/5] Re-factor our codebase to enable the deployment of both simulation and task-solving framework! We have placed the code for Minecraft example in the paper at the [`minecraft`](https://github.com/OpenBMB/AgentVerse/tree/minecraft) branch. Our tool-using example will soon be updated to the `main` branch. Stay tuned! + +- [2023/8/22] We're excited to share our paper [AgentVerse: Facilitating Multi-Agent Collaboration and Exploring Emergent Behaviors in Agents](https://arxiv.org/abs/2308.10848) that illistrate the task-solving framework +in detail of AgentVerse. + +- [2023/6/5] We are thrilled to present an array of [demos](#-simple-demo-video), including [NLP Classroom](#nlp-classroom), [Prisoner Dilemma](#prisoner-dilemma), [Software Design](#software-design), [Database Administrator](#database-administrator-dba), and a simple [H5 Pokemon Game](#pokemon) that enables the interaction with the characters in Pokemon! Try out these demos and have fun! +- [2023/5/1] πŸš€ [AgentVerse](https://github.com/OpenBMB/AgentVerse) is officially launched! -- **Feedback and Suggestions**: Use AgentVerse and provide us with feedback. Your insights can lead to potential improvements and ensure that our framework remains top-notch. -Also, if you're passionate about advancing the frontiers of multi-agent environments and are eager to dive deeper into research, we invite you to join our team at THUNLP. To explore this exciting opportunity and embark on a collaborative journey with us, please reach out to [chenweize1998@gmail.com](chenweize1998@gmail.com) and [yushengsu.thu@gmail.com](yushengsu.thu@gmail.com) and express your interest. We're keen to welcome motivated individuals like you to our lab! -πŸ‘‰Also, check our Discord: https://discord.gg/cnutfCtC. -## πŸ—“ Coming Soon +# πŸ—“ Coming Soon - [x] Code release of our [paper](https://arxiv.org/abs/2308.10848) - [ ] Add documentation - [ ] Support more sophisticated memory for conversation history - [ ] Add support for local LLM + - - #### NLP Classroom In the NLP class, the professor and students engage in interactive communication. When students have a question, they raise their hands and patiently wait for the professor to call on them. Only after being called on by the professor, can students speak and ask their questions. @@ -157,7 +147,9 @@ Wait for the compilation to complete, and have fun! (WASD for moving around, and https://github.com/OpenBMB/AgentVerse/assets/11704492/4d07da68-f942-4205-b558-f155e95782e7 +--> + +# Contents +- [πŸ“° What's New](#-whats-new) +- [πŸ—“ Coming Soon](#-coming-soon) +- [Contents](#contents) +- [πŸš€ Getting Started](#-getting-started) + - [Installation](#installation) + - [Simulation CLI Example](#simulation-cli-example) + - [Simulation Local Website Demo](#simulation-local-website-demo) + - [Task-Solving CLI Example](#task-solving-cli-example) +- [πŸ”Ž Examples](#-examples) +- [🌟 Join Us!](#-join-us) + - [How Can You Contribute?](#how-can-you-contribute) +- [Social Media and Community](#social-media-and-community) +- [Star History](#star-history) +- [Citation](#citation) +- [Contact](#contact) -## πŸš€ Getting Started -### Installation + + +# πŸš€ Getting Started + +## Installation ```bash pip install -U agentverse @@ -233,16 +245,18 @@ pip install -r requirements.txt python setup.py develop ``` +## Simulation - +### Framework Required Modules +``` +- agentverse + - agents + - simulation_agent + - environments + - simulation_env +``` -### Simulation CLI Example +### CLI Example You can create a multi-agent environments provided by us. Using the classroom scenario as an example. In this scenario, there are nine agents, one playing the role of a professor and the other eight as students. @@ -252,7 +266,7 @@ python3 agentverse_command/main_simulation_cli.py --task simulation/nlp_classroo agentverse-simulation --task simulation/nlp_classroom_9players ``` -### Simulation Local Website Demo +### GUI Example (Local) We also provide a local website demo for this environment. You can launch it with @@ -263,7 +277,20 @@ agentverse-simulation-gui --task simulation/nlp_classroom_9players ``` After successfully launching the local server, you can visit [http://127.0.0.1:7860/](http://127.0.0.1:7860/) to view the classroom environment. -### Task-Solving CLI Example + +## Task-Solving + + +### Framework Required Modules +``` +- agentverse + - agents + - simulation_env + - environments + - tasksolving_env +``` + +### CLI Example To run the experiments with the task-solving environment proposed in our [paper](https://arxiv.org/abs/2308.10848), you can use the following command: @@ -277,6 +304,17 @@ agentverse-tasksolving --task tasksolving/humaneval/gpt-3.5 --dataset_path data/ You can take a look at `agentverse/tasks/tasksolving` for more experiments we have done in our paper. +# AgentVerse Showcases + +## Simulation Showcases +Refer to [simulation showcases](README_simulation_cases.md) + +## Task-Solving Showcases +Refer to [tasksolving showcases](README_tasksolving_cases.md) + + + + + + + + + + + + + +# 🌟 Join Us! +AgentVerse is on a mission to revolutionize the multi-agent environment for large language models, and we're eagerly looking for passionate collaborators to join us on this exciting journey. + +## Leaders +Leader +Leader + +## Contributors +Contributor +Contributor +Contributor +Contributor +Contributor +Contributor +Contributor +Contributor +Contributor +Contributor +Contributor +Contributor + + +## How Can You Contribute? +- **Code Development**: If you're an engineer, help us refine, optimize, and expand the current framework. We're always looking for talented developers to enhance our existing features and develop new modules. -## Star History +- **Documentation and Tutorials**: If you have a knack for writing, help us improve our documentation, create tutorials, or write blog posts to make AgentVerse more accessible to the broader community. + +- **Application Exploration**: If you're intrigued by multi-agent applications and are eager to experiment using AgentVerse, we'd be thrilled to support your journey and see what you create! + +- **Feedback and Suggestions**: Use AgentVerse and provide us with feedback. Your insights can lead to potential improvements and ensure that our framework remains top-notch. + +Also, if you're passionate about advancing the frontiers of multi-agent applications, become core AgentVerse team members, or are eager to dive deeper into agent research. Please reach out [AgentVerse Team](agentverse2@gmail.com), and CC to [chenweize1998@gmail.com](chenweize1998@gmail.com) and [yushengsu.thu@gmail.com](yushengsu.thu@gmail.com). We're keen to welcome motivated individuals like you to our team! + + +## Social Media and Community + +- Twitter: https://twitter.com/Agentverse71134 + +- Discord: https://discord.gg/cnutfCtC. + + +# Star History [![Star History Chart](https://api.star-history.com/svg?repos=OpenBMB/AgentVerse&type=Date)](https://star-history.com/#OpenBMB/AgentVerse&Date) @@ -413,9 +504,13 @@ If you find this repo helpful, feel free to cite us. } ``` -## Contact +# Contact + +AgentVerse Team: agentverse2@gmail.com + +Project leaders: -Weize Chen: chenweize1998@gmail.com +- Weize Chen: chenweize1998@gmail.com -[Yusheng Su](https://yushengsu-thu.github.io/): yushengsu.thu@gmail.com +- [Yusheng Su](https://yushengsu-thu.github.io/): yushengsu.thu@gmail.com diff --git a/README_simulation_cases.md b/README_simulation_cases.md new file mode 100644 index 000000000..3c7497556 --- /dev/null +++ b/README_simulation_cases.md @@ -0,0 +1,75 @@ + +## πŸ‘Ύ Simple Demo Video + +We demonstrate the following cases that are expertly crafted by AgentVerse. + + +#### NLP Classroom +In the NLP class, the professor and students engage in interactive communication. When students have a question, they raise their hands and patiently wait for the professor to call on them. Only after being called on by the professor, can students speak and ask their questions. + +Use the following command to launch the NLP Classroom example: +```bash +python agentverse_command/main_simulation_gui.py --task simulation/nlp_classroom_9players +``` + +https://github.com/OpenBMB/AgentVerse/assets/11704492/6ea07850-595e-4a28-a82e-f863011353c2 + + +#### Prisoner Dilemma +A prisoner's Dilemma is a thought experiment that challenges two completely rational agents to a dilemma: they can cooperate with their partner for mutual benefit or betray their partner ("defect") for individual reward. + +Use the following command to launch the Prisoner Dilemma example: +```bash +python agentverse_command/main_simulation_gui.py --task simulation/prisoner_dilemma +``` + +https://github.com/OpenBMB/AgentVerse/assets/11704492/017c46e5-c738-4fca-9352-b008e2d518bd + + +#### Software Design +In the Software Design example, a code writer, a code tester and a code reviewer collaborate on the code generation problem. Given a problem, the code writer first composes the code implementation. The code tester runs the unit tests and provides the feedback. The code viewer then generates a review. After collecting the test feedback and review, the code writer iteratively refines the code. + +Use the following command to launch the Software Design example: +```bash +python agentverse_command/main_simulation_gui.py --task simulation/sde_team/sde_team_2players +``` + +https://github.com/OpenBMB/AgentVerse/assets/11704492/5058066a-abee-490d-8659-b4e54661626a + + +#### [Database Administrator (DBA)](https://github.com/TsinghuaDatabaseGroup/DB-GPT) + +In the database diagnosis scenario, the Chief DBA monitors the system anomalies (e.g., slow queries, locks, crash down). If detected, the domain experts are alerted to analyze root causes, share insights, and suggest optimization solutions together. The Chief DBA then provides a summarized report to the user. + +```bash +python agentverse_command/main_simulation_gui.py --task simulation/db_diag +``` + +https://github.com/OpenBMB/AgentVerse/assets/11704492/c633419d-afbb-47d4-bb12-6bb512e7af3a + +#### [Text Evaluation (ChatEval)](https://github.com/chanchimin/ChatEval) +In the context of the text evaluation scenario, we recommend users explore the [ChatEval](https://github.com/chanchimin/ChatEval) repo. They've implemented a multi-agent referee team on AgentVerse to assess the quality of text generated by different models. When given two distinct pieces of text, roles within ChatEval can autonomously debate the nuances and disparities, drawing upon their assigned personas, and subsequently provide their judgments. Experiments indicate that their referee team, enriched with diverse roles specified in [config.yaml](#2-configuring-the-agents), aligns more closely with human evaluations. This demo is built upon the [Fastchat](https://github.com/lm-sys/FastChat) repo, and we'd like to express our appreciation for their foundational work. + + +https://github.com/OpenBMB/AgentVerse/assets/75533759/58f33468-f15b-4bac-ae01-8d0780019f85 + +#### Pokemon +**Currently available only in [`release-0.1`](https://github.com/OpenBMB/AgentVerse/tree/release-0.1)**. In the game, agents can walk around the game world, and interact with one another. As a player, you take on the role of an agent and can engage with others at any time. There are 6 characters in the PokΓ©mon environment who appeared in Pokemon Emerald: [May](https://bulbapedia.bulbagarden.net/wiki/May_(game)), [Professor Birch](https://bulbapedia.bulbagarden.net/wiki/Professor_Birch), [Steven Stone](https://bulbapedia.bulbagarden.net/wiki/Steven_Stone), [Maxie](https://bulbapedia.bulbagarden.net/wiki/Maxie), [Archie](https://bulbapedia.bulbagarden.net/wiki/Archie) and [Joseph](https://bulbapedia.bulbagarden.net/wiki/Mr._Stone). + +To launch the Pokemon game, first launch a local server with the following command: +```bash +uvicorn pokemon_server:app --reload --port 10002 +``` +Then open another terminal in the project's root path and run the following command: +```bash +cd ui +# If you do not have npm installed, you need to install it before running the following commands +# https://docs.npmjs.com/downloading-and-installing-node-js-and-npm +# We have tested on npm@9.6.4, node@20.0.0 +npm install +npm run watch +``` +Wait for the compilation to complete, and have fun! (WASD for moving around, and SPACE for launching a conversation.) + +https://github.com/OpenBMB/AgentVerse/assets/11704492/4d07da68-f942-4205-b558-f155e95782e7 + diff --git a/README_tasksolving_cases.md b/README_tasksolving_cases.md new file mode 100644 index 000000000..e69de29bb diff --git a/setup.py b/setup.py index 1632a1fe5..097c5765e 100644 --- a/setup.py +++ b/setup.py @@ -11,8 +11,8 @@ setuptools.setup( name="agentverse", version="0.1.8", - author="OpenBMB", - author_email="chenweize1998@gmail.com", + author="AgentVerse Team", + author_email="agentverse2@gmail.com", description="A versatile framework that streamlines the process of creating custom multi-agent environments for large language models (LLMs).", long_description=long_description, long_description_content_type="text/markdown",