mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-06-05 14:55:18 +02:00
feat: merge software tool
This commit is contained in:
commit
f4240ca483
8 changed files with 403 additions and 12 deletions
39
examples/di/software_company.py
Normal file
39
examples/di/software_company.py
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
#!/usr/bin/env python
|
||||
# -*- coding: utf-8 -*-
|
||||
import fire
|
||||
|
||||
from metagpt.roles.di.data_interpreter import DataInterpreter
|
||||
|
||||
|
||||
async def main():
|
||||
prompt = """
|
||||
This is a software requirement:
|
||||
```text
|
||||
write a snake game
|
||||
```
|
||||
---
|
||||
1. Writes a PRD based on software requirements.
|
||||
2. Writes a design to the project repository, based on the PRD of the project.
|
||||
3. Writes a project plan to the project repository, based on the design of the project.
|
||||
4. Writes codes to the project repository, based on the project plan of the project.
|
||||
5. Run QA test on the project repository.
|
||||
6. Stage and commit changes for the project repository using Git.
|
||||
Note: All required dependencies and environments have been fully installed and configured.
|
||||
"""
|
||||
di = DataInterpreter(
|
||||
tools=[
|
||||
"write_prd",
|
||||
"write_design",
|
||||
"write_project_plan",
|
||||
"write_codes",
|
||||
"run_qa_test",
|
||||
"fix_bug",
|
||||
"git_archive",
|
||||
]
|
||||
)
|
||||
|
||||
await di.run(prompt)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
fire.Fire(main)
|
||||
Loading…
Add table
Add a link
Reference in a new issue