PlayerEngine: Minecraft 的 AI 具身框架
PlayerEngine 是一个服务端框架,旨在从根本上改变 AI NPC 在 Minecraft 中的存在方式。由 Goodbird 开发,该项目突破了客户端模组的局限,提供了一套强大的工具包,让你的自定义生物拥有玩家的全部能力。
该项目诞生于超越聊天机器人 NPC 噱头、为 Player2 AI Game Jam 创造真正具身智能体的愿望。它不是为了让原版猪说话,而是赋予开发者创建能够挖矿、战斗、管理物品栏并与世界进行玩家级交互实体的能力。
故事:从客户端 hack 到真正的框架
PlayerEngine 的灵感来源于 ChatClef,这是 Player2 推出的一个创新模组,它将 AI 连接到玩家客户端。尽管具有开创性,但它有一个显著的局限性:要拥有 AI 同伴,必须运行多个 Minecraft 客户端实例。这既繁琐也不具备可扩展性。
PlayerEngine 通过将逻辑移至服务端,并将类人能力与 PlayerEntity 类本身解耦来解决这个问题。其结果是一个真正的框架,允许任何模组作者授予他们的自定义 LivingEntity 以玩家的“灵魂”。
核心概念:“玩家”作为一种接口
PlayerEngine 的核心在于将“成为玩家”不视为一种特定的实体类型,而是一组可以附加到任何生物上的能力。通过实现几个简单的接口,你的自定义生物将获得以下访问权限:
- 持久化的类玩家物品栏 (
LivingEntityInventory)。 - 与世界互动的能力,包括破坏方块和使用物品 (
LivingEntityInteractionManager)。 - 通过强大的 Automatone 引擎进行高级寻路和任务执行。
这使得 PlayerEngine 成为类似 Player2 API 提供的 AI “大脑”的最终“执行器”层。你的 LLM(大语言模型)可以决定 做什么,而 PlayerEngine 则赋予你的 NPC 去 做 的身体。
面向开发者的关键特性
- ? 赋能你的生物: 专为模组作者设计。轻松将你自己的自定义实体转化为类玩家智能体。不要只是给原版生物换皮——赋予你独特的创造物真正的自主权。
- ⛏️ 真实的世界交互: NPC 可以挖掘方块、使用工具和与物体互动。(注意:目前尚不支持复杂的建造)。
- ? 类玩家物品栏: 每个智能体都管理自己的持久化物品栏,支持复杂的资源收集、合成和工具管理。
- ? 无缝集成 Player2: PlayerEngine 是 Player2 API 完美的物理对应物。发送高级指令如
@get diamond 5,看着你的智能体执行一系列复杂任务以实现目标。 - ?️ 建立在坚实的基础之上:
- 导航: 由 Automatone 提供支持,它是传奇的 Baritone 寻路引擎的一个分支。
- 任务系统: 改编自 Player2 ChatClef 中健壮的任务和命令系统。
- 模块化: 使用 Cardinal Components 干净地附加能力,确保高兼容性和易于集成。
为什么 PlayerEngine “超越了 AI 噱头”
- 集成: 它是一个用于深度系统集成的框架。NPC 不再仅仅是任务发布者;它们是游戏经济、生态系统和涌现式叙事的积极参与者。
- 护栏: PlayerEngine 就是 护栏。它提供了一个基于确定性游戏逻辑的动作层,可靠地执行来自 LLM 的高级目标,并包含回退机制和对游戏世界的深入理解。
- 创造力: 它赋能 其他创作者。我们不仅仅展示一个酷炫的 NPC;我们是为整个社区提供构建自己智能同伴、对手和动态讲述者的工具。
- 稳定性: 站在巨人的肩膀上——Baritone 和 Cardinal Components,PlayerEngine 是一个稳定且高性能的基础,适用于雄心勃勃的 AI 项目。
致谢
本项目立足于许多人的工作和支持。
Player2
本框架是为 Player2 AI Game Jam 创建的,旨在与 Player2 API 无缝集成,实现他们对智能、交互式智能体的愿景。
我们是一群热衷于推进 AI 前沿技术的研究人员和工程师。我们的团队成员曾在全球一些领先的技术公司和研究机构工作,我们因共同构建能够以有意义的方式与世界互动的智能体的愿景而团结在一起。
基础与灵感
- Automatone / Baritone: PlayerEngine 的强大导航功能由 Automatone 提供,它是传奇的 Baritone 寻路引擎的一个分支。
- ChatClef: 健壮的任务和命令系统改编自 Player2 原始 ChatClef 模组,该模组证明了 AI 智能体在 Minecraft 中的潜力。
特别感谢
- Itsuka: 感谢他在 Player2 API 方面的宝贵指导、头脑风暴会议以及严谨的测试,这些帮助塑造了今天的 PlayerEngine。
作者
PlayerEngine 是由 Goodbird 开发的单人项目。
PlayerEngine: The AI Embodiment Framework for Minecraft
PlayerEngine is a server-side framework designed to fundamentally change how AI NPCs exist in Minecraft. Developed by Goodbird, this project moves beyond the limitations of client-side mods, offering a powerful toolkit to give your own custom mobs the full capabilities of a player.
This project was born from the desire to transcend the gimmick of chatbot NPCs and create truly embodied agents for the Player2 AI Game Jam. It's not about making vanilla pigs talk; it's about empowering developers to create entities that can mine, fight, manage an inventory, and interact with the world on a player's level.
The Story: From Client-Side Hacks to a True Framework
The inspiration for PlayerEngine came from ChatClef, an innovative mod by Player2 that connected an AI to the player's client. While groundbreaking, it had a significant limitation: to have AI companions, one had to run multiple instances of the Minecraft client. This was cumbersome and not scalable.
PlayerEngine solves this problem by moving the logic to the server and, most importantly, decoupling player-like abilities from the PlayerEntity class itself. The result is a true framework that allows any modder to grant their custom LivingEntity the soul of a player.
The Core Concept: The "Player" as an Interface
At its heart, PlayerEngine treats "being a player" not as a specific entity type, but as a set of capabilities that can be attached to any mob. By implementing a few simple interfaces, your custom mob gains access to:
- A persistent, player-like inventory (
LivingEntityInventory). - The ability to interact with the world, breaking blocks and using items (
LivingEntityInteractionManager). - Advanced pathfinding and task execution via the powerful Automatone engine.
This makes PlayerEngine the ultimate "actuator" layer for an AI "brain" like the one provided by the Player2 API. Your LLM can decide what to do, and PlayerEngine gives your NPC the body to do it.
Key Features for Developers
- ? Empower Your Mobs: Designed for modders. Easily transform your own custom entities into player-like agents. Don't just reskin a vanilla mob—give your unique creations true agency.
- ⛏️ True World Interaction: NPCs can mine blocks, use tools, and interact with objects. (Note: complex building is not yet supported).
- ? Player-Like Inventories: Each agent manages its own persistent inventory, allowing for complex resource gathering, crafting, and tool management.
- ? Seamless Player2 Integration: PlayerEngine is the perfect physical counterpart to the Player2 API. Send high-level commands like
@get diamond 5and watch your agent execute a complex chain of tasks to achieve the goal. - ?️ Built on a Solid Foundation:
- Navigation: Powered by Automatone, a fork of the legendary Baritone pathfinding engine.
- Task System: Adapts the robust task and command system from Player2's ChatClef.
- Modularity: Uses Cardinal Components to cleanly attach capabilities, ensuring high compatibility and easy integration.
Why PlayerEngine is "Beyond an AI Gimmick"
- Integration: It's a framework for deep systemic integration. NPCs are no longer just quest-givers; they are active participants in the game's economy, ecology, and emergent stories.
- Guardrails: PlayerEngine is the guardrail. It provides a deterministic, game-logic-based action layer that reliably executes the high-level goals from an LLM, complete with fallbacks and a robust understanding of the game world.
- Creativity: It empowers other creators. We're not just showing one cool NPC; we're giving the entire community a tool to build their own intelligent companions, adversaries, and dynamic storytellers.
- Stability: Built on the shoulders of giants—Baritone and Cardinal Components—PlayerEngine is a stable and performant foundation for ambitious AI projects.
Acknowledgements
This project stands on the work and support of many.
Player2
This framework was created for the Player2 AI Game Jam and is designed to integrate seamlessly with the Player2 API, realizing their vision for intelligent, interactive agents.
We are a team of researchers and engineers that are passionate about advancing the state of the art in AI. Our team members have worked at some of the world's leading tech companies and research institutions, and we are united by our shared vision of building intelligent agents that can interact with the world in a meaningful way.
Foundation & Inspiration
- Automatone / Baritone: The powerful navigation of PlayerEngine is provided by Automatone, a fork of the legendary Baritone pathfinding engine.
- ChatClef: The robust task and command system is adapted from the original ChatClef mod by Player2, which proved the potential of AI agents in Minecraft.
Special Thanks
- Itsuka: For his invaluable guidance with the Player2 API, brainstorming sessions, and rigorous testing that helped shape PlayerEngine into what it is today.
Author
PlayerEngine is a solo project developed by Goodbird.
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayerEngine
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayerEngine
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
下载 PlayerEngine
需要联机服务器吗?
稳定流畅、一键部署,几分钟即可和朋友联机开服
最低仅需 8 元/月 即可畅快联机
? PlayerEngine + Player2NPC v1.4.0
Minecraft 1.20.1 (Fabric 和 Forge) 以及 Minecraft 1.21.1 (Fabric 和 NeoForge)
✨ 更新内容
?️ 全新的 Player2NPC 菜单
按下 H 键打开新的 Player2NPC 中心。旧的字符列表界面已被一个有组织的菜单取代,用于管理你的同伴和模组。
- 查看你的同伴、当前任务、物品栏和最近的活动。
- 编辑同伴提示词并管理谁可以与其对话或控制它们。
- 配置行为、饥饿、战斗、旅行、预算、焦耳(Joules)、AI 记忆、配置文件和模型设置。
- 使用专用屏幕来调整模组的智能和自动化设置。
- 无需深入配置文件即可调整合成、熔炼、采矿、存储、燃料和航点设置。
? 农场系统重构
同伴现在可以从头到尾构建和管理真正的农场。
- 自动设置一个安全的、带灌溉的 9x9 农场,或者自己选择确切的位置。
- 清除障碍物、填补空隙、放置水源、翻耕土壤,并为种植做好准备。
- 种植所需的作物及数量,途中收集种子和其他所需物品。
- 仅收割成熟的作物,并在之后收集掉落物。
- 农场会被记住为航点,以便同伴以后能找到它们。
- 农场工作可以修复受损的地块并从临时中断中恢复,而不是丢失整个任务。
你可以使用直接命令 setup_farm、plant_farm 和 harvest_farm,或者用自然语言要求你的同伴。
?️ 合成、熔炼与升级
物品收集和合成功能经过重建,能够更可靠地处理较长的任务。
- 同伴可以遵循完整的配方链,收集缺失的材料并制作它们需要的中间部分。
- 合成支持更广泛的原版和模组配方。
- 优先使用附近的合成台,当需要且被允许时放置一个新的合成台。
- 熔炼和烹饪现在支持熔炉、高炉和烟熏炉。
- 同伴会选择并收集合适的燃料,等待真实的烹饪进度,并收集完成后的物品。
- 物品请求现在可以通过收集、合成和熔炼作为一个任务流程进行。
- 锻造台升级(包括下界合金升级)可以自动解决其所需的材料。
使用 smelt 进行熔炉工作,使用 smith 进行锻造台升级。在需要时,通过 get 请求物品也可以利用这些步骤。
? 长期记忆与更好的航点
同伴现在拥有跨会话和游戏周期的长期记忆。
- 情景记忆帮助 AI 回忆过去的互动、对话和事件,而不是将每次聊天都视为全新的开始。
- 事实记忆存储关于你、你的同伴和世界的有用信息,例如偏好、指令和你分享的重要细节。
- 当情况发生变化时,事实记忆可以被纠正,而情景记忆则提供了同伴所记得内容的背景和历史。
- 同伴还能记住农场位置,稍后进行检查,并注意已记忆的航点是否发生了更改。
- 更多的同伴状态,包括跟随行为、情绪、饥饿和对话数据,会在会话之间一致地保存。
记忆在更新和搜索基于嵌入的记忆时会消耗少量的焦耳(Joules)。你不需要很大的余额,但如果你希望同伴继续学习和回忆长期记忆,建议保留少量的焦耳。
? 修复问题
- 执行小动作时,活跃任务不再消失;支持的任务随后可以继续。
- 同伴更尊重玩家建造的结构,不太可能为了到达目标而破坏墙壁。
- 跟随和食物行为不再陷入重复的中断消息或令人困惑的循环中。
- 即使关闭了
mobGriping(生物破坏),同伴也会继续拾取掉落的物品。 - 维度之间的旅行不再导致同一同伴的副本遗留下来。
- 修复了一个同伴与生物碰撞时可能发生的罕见崩溃。
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
模组
一个用于收集生物掉落物的多区块模组。
模组
显示你正在注视的方块的信息。(适用于 Minecraft 1.16+ 的 Hwyla/Waila 分支)
模组
查看物品与配方
模组
使用 JavaScript 编辑配方、添加自定义物品、编写世界事件!
模组
适用于 MC 1.18+ 的 Effekseer 加载器
模组
那是什么?一个 Waila/Hwyla 的分支。
评论 0
登录后参与评分
还没有评论,来抢沙发吧