Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MetaGPT - Multi-agent framework #727

Open
1 task
irthomasthomas opened this issue Mar 16, 2024 · 1 comment
Open
1 task

MetaGPT - Multi-agent framework #727

irthomasthomas opened this issue Mar 16, 2024 · 1 comment
Labels
AI-Agents Autonomous AI agents using LLMs CLI-UX Command Line Interface user experience and best practices Code-Interpreter OpenAI Code-Interpreter programming-languages Topics related to programming languages and their features. software-engineering Best practice for software engineering

Comments

@irthomasthomas
Copy link
Owner

Quickstart | MetaGPT

Description:
Quickstart

Installation

pip install metagpt

Available installation methods can be found in the Installation section.

Configuration

Variations for setting up LLM API (OpenAI, Azure, Anthropic, etc.) and other components can be found in the Configuration section.

For formal usage of MetaGPT, using a config2.yaml. See Configuration.

Develop software with a one-line requirement

Note:
Below is a breakdown of the software startup example. If you install MetaGPT with the git clone approach, simply run

metagpt "write a cli blackjack game"

Now, let's get started! We will create a team of agents to write software based on one line of our instruction.

First, import off-the-shelf roles

import asyncio
from metagpt.roles import (
    Architect,
    Engineer,
    ProductManager,
    ProjectManager,
)
from metagpt.team import Team

Next, initiate the team, equip it with agents, set their budget, and provide our requirement of writing a small game

async def startup(idea: str):
    company = Team()
    company.hire(
        [
            ProductManager(),
            Architect(),
            ProjectManager(),
            Engineer(),
        ]
    )
    company.invest(investment=3.0)
    company.run_project(idea=idea)

    await company.run(n_round=5)

Finally, run it and get the code!

await startup(idea="write a cli blackjack game")

You may expect similar outputs below:

Usage

Usage: metagpt [OPTIONS] [IDEA]

Start a new project.

Arguments:

  • idea [IDEA] Your innovative idea, such as 'Create a 2048 game.' [default: None]

Options:

  • --investment FLOAT Dollar amount to invest in the AI company. [default: 3.0]
  • --n-round INTEGER Number of rounds for the simulation. [default: 5]
  • --code-review --no-code-review Whether to use code review. [default: code-review]
  • --run-tests --no-run-tests Whether to enable QA for adding & running tests. [default: no-run-tests]
  • --implement --no-implement Enable or disable code implementation. [default: implement]
  • --project-name TEXT Unique project name, such as 'game_2048'.
  • --inc --no-inc Incremental mode. Use it to coop with existing repo. [default: no-inc]
  • --project-path TEXT Specify the directory path of the old version project to fulfill the incremental requirements.
  • --reqa-file TEXT Specify the source file name for rewriting the quality assurance code.
  • --max-auto-summarize-code INTEGER The maximum number of times the 'SummarizeCode' action is automatically invoked, with -1 indicating unlimited. This parameter is used for debugging the workflow. [default: 0]
  • --recover-path TEXT recover the project from existing serialized storage [default: None]
  • --init-config --no-init-config Initialize the configuration file for MetaGPT. [default: no-init-config]
  • --help Show this message and exit.

Source

Suggested labels

@irthomasthomas irthomasthomas added AI-Agents Autonomous AI agents using LLMs CLI-UX Command Line Interface user experience and best practices Code-Interpreter OpenAI Code-Interpreter programming-languages Topics related to programming languages and their features. software-engineering Best practice for software engineering labels Mar 16, 2024
@irthomasthomas
Copy link
Owner Author

Related content

#383

Similarity score: 0.89

#499

Similarity score: 0.88

#682

Similarity score: 0.88

#707

Similarity score: 0.88

#498

Similarity score: 0.87

#660

Similarity score: 0.87

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AI-Agents Autonomous AI agents using LLMs CLI-UX Command Line Interface user experience and best practices Code-Interpreter OpenAI Code-Interpreter programming-languages Topics related to programming languages and their features. software-engineering Best practice for software engineering
Projects
None yet
Development

No branches or pull requests

1 participant