This repo contains two things:
It is intended as a proof of concept.
GPTRPG is intended to be run locally. To run:
agent/env.json
file with your IFLYTEK API key.gptrpg
directory run npm install
to install dependencies for all projects.npm start
in the root directory. This will start the agent and the front-end. The front-end will be available at http://localhost:3000
.Code for the environment lives in the ui-admin
directory. It is a React project.
The environment was made with Tiled map editor. The files live in ui-admin/src/assets
.
The environment is rendered with Phaser and the Grid Engine Plugin
The environment consists of:
Code for the agent lives in the agent
directory.
The agent is a simple AI agent that uses the OpenAI API to make decisions. It communicates with the front-end via a websocket.
The agent is provided with a list of possible actions, the state of its surroundings, and its internal state (currently only sleepiness is measured).
上下左右移动窗口
把agent初始位置等参数做成可配置的参数
agent接收到控制指令后,不只是走一步,而是一直走
和大模型的互动改成触发式的
在界面上做一个显示窗,显示大模型的控制结果
优化稳定性,解决requestObj.sparkResult += data.payload.choices.text[0].content,TypeError: Cannot read properties of undefined (reading 'choices')的问题
创建两个角色,一个角色可以用上下左右控制,另一个角色是大模型自主控制
加一个check环节,检查大模型返回的值是否符合预期
加一个log文件,把每次试验的结果都用log记录下来。
改正上下左右控制agent报错的bug
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。