mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-05-24 14:15:17 +02:00
update example for mgx
add intent detect action and mgx role
This commit is contained in:
parent
154e108fb0
commit
a9938472fc
4 changed files with 357 additions and 0 deletions
3
examples/mgx/__init__.py
Normal file
3
examples/mgx/__init__.py
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# @Author : stellahong (stellahong@fuzhi.ai)
|
||||
# @Desc :
|
||||
19
examples/mgx/run_mgx.py
Normal file
19
examples/mgx/run_mgx.py
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# @Author : stellahong (stellahong@fuzhi.ai)
|
||||
# @Desc :
|
||||
import asyncio
|
||||
|
||||
from metagpt.roles.di.mgx import MGX
|
||||
|
||||
requirement = (
|
||||
"design a game using Gym (an open source Python library), including a graphical interface and interactive gameplay"
|
||||
)
|
||||
|
||||
|
||||
async def main(requirement: str = ""):
|
||||
mgx = MGX(ususe_intent=True)
|
||||
await mgx.run(requirement)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(main(requirement))
|
||||
Loading…
Add table
Add a link
Reference in a new issue