Home

Awesome

<h1 align="center"><img alt="Internet of Agents" src="https://github.com/OpenBMB/IoA/assets/32613237/04cbe3dc-84e1-4d70-ba5c-e8b07d3ee31d" style="width: 1em; height: 1em;"> Internet of Agents</h1> <p align="center"> <a href="https://discord.gg/E5XPtynFDh"> <img alt="Discord" src="https://img.shields.io/discord/1259737237763919963?logo=discord&style=flat&logoColor=white"/></a> <a href="https://github.com/astral-sh/ruff"> <img alt="Code Formater: Ruff" src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json"> </a> <a href="https://github.com/OpenBMB/IoA/LICENSE"> <img alt="License" src="https://img.shields.io/github/license/OpenBMB/IoA"> </a> <!-- <a href="https://openbmb.github.io/IoA/"><img src="https://img.shields.io/badge/Doc-En-white.svg" alt="EN doc"/></a> <a href="https://openbmb.github.io/IoA//doc_zh/index_zh.html"><img src="https://img.shields.io/badge/Doc-δΈ­ζ–‡-white.svg" alt="ZH doc"/></a> --> <br> <br>【<a href="https://openbmb.github.io/IoA/">Documentation</a> | <a href = "https://arxiv.org/abs/2407.07061 ">Paper</a>】<br> </p>

🌎 What is Internet of Agents?

Imagine if AI agents could collaborate like humans do on the internet. That's the idea behind Internet of Agents (IoA)! It's an open-source framework that aims to create a platform where diverse AI agents can team up to tackle complex tasks. For example, agents like AutoGPT and Open Interpreter can come together, share their unique skills, and work on problems that might be too tricky for a single agent to solve.

πŸš€ Key Features

For more details, please refer to our paper.

<p align="center" style="color:RGB(160, 160, 160)"> <img src="https://github.com/OpenBMB/IoA/assets/32613237/126082a8-432b-4039-8acd-49f4798a492c"> A peek at IoA's layered architecture </p> <p align="center" style="color:RGB(160, 160, 160)"> <img src="https://github.com/OpenBMB/IoA/assets/32613237/6d081cd8-a935-4e34-a24d-62eb65f8c6ec"> How IoA works </p>

πŸš€ Quick Start

Get IoA up and running in just a few steps:

1. πŸ“‹ Prerequisites

2. πŸ“₯ Clone the Repository

git clone git@github.com:OpenBMB/IoA.git
cd IoA

3. πŸ—οΈ Build Docker Images

Core Components

You can directly pull the pre-built docker images from docker hub

# Server
docker pull weize/ioa-server:latest

# Client
docker pull weize/ioa-client:latest

# Server Frontend
docker pull weize/ioa-server-frontend:latest

# Rename the images
docker tag weize/ioa-server:latest ioa-server:latest
docker tag weize/ioa-client:latest ioa-client:latest
docker tag weize/ioa-server-frontend:latest ioa-server-frontend:latest
<details> <summary>Or you can build from source</summary>
# Server
docker build -f dockerfiles/server.Dockerfile -t ioa-server:latest .

# Client
docker build -f dockerfiles/client.Dockerfile -t ioa-client:latest .

# Server Frontend
docker build -f dockerfiles/server_frontend.Dockerfile -t ioa-server-frontend:latest .
</details>

Agent Images (Build as needed)

# ReAct Agent
docker pull weize/react-agent:latest
docker tag weize/react-agent:latest react-agent:latest

# AutoGPT (we have fixed some bugs in AutoGPT's original docker image)
docker pull weize/autogpt:latest
docker tag weize/autogpt:latest autogpt:latest

# Open Interpreter
docker pull weize/open-interpreter:latest
docker tag weize/open-interpreter:latest open-interpreter:latest
<details> <summary>Or you can build from source</summary>
# ReAct Agent
docker build -f dockerfiles/tool_agents/react.Dockerfile -t react-agent:latest .

# AutoGPT (we have fixed some bugs in AutoGPT's original docker image)
docker build -f dockerfiles/tool_agents/autogpt.Dockerfile -t autogpt:latest .

# Open Interpreter
docker build -f dockerfiles/tool_agents/open_interpreter.Dockerfile -t open-interpreter:latest .
</details>

4. 🌐 Launch Milvus Service

docker network create agent_network
docker-compose -f dockerfiles/compose/milvus.yaml up

5. 🎬 Start IoA

cd dockerfiles/compose/
cp .env_template .env

In .env, fill in your OpenAI API key and other optional environment variables. Then for a quick demo with AutoGPT and Open Interpreter:

cd ../../
docker-compose -f dockerfiles/compose/open_instruction.yaml up

And you will set up your own small-scale Internet of Agents with AutoGPT and Open Interpreter!

6. πŸ§ͺ Test It Out

You can use the following script to test IoA on our Open Instruction dataset.

python scripts/open_instruction/test_open_instruction.py

Or simply send a post request like:

import requests

goal = "I want to know the annual revenue of Microsoft from 2014 to 2020. Please generate a figure in text format showing the trend of the annual revenue, and give me an analysis report."

response = requests.post(
    "http://127.0.0.1:5050/launch_goal",
    json={
        "goal": goal,
        "max_turns": 20,
        "team_member_names": ["AutoGPT", "Open Interpreter"],   # When it is left "None", the agent will decide whether to form a team autonomously
    },
)

print(response)
<details> <summary>πŸ€” Want to run IoA across different devices?</summary>

Check out our distributed setup guide. We're continuously improving our documentation, so your feedback is valuable!

</details>

🌟 Join the IoA Adventure!

We're just getting started with IoA, and we'd love your help to make it even better! Got ideas for cool ways to use IoA, like connecting PC agents with mobile agents? We're all ears!

Let's build the future of AI collaboration together! πŸš€