[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-mindcraft-bots--mindcraft":3,"tool-mindcraft-bots--mindcraft":64},[4,17,27,35,43,56],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":16},3808,"stable-diffusion-webui","AUTOMATIC1111\u002Fstable-diffusion-webui","stable-diffusion-webui 是一个基于 Gradio 构建的网页版操作界面，旨在让用户能够轻松地在本地运行和使用强大的 Stable Diffusion 图像生成模型。它解决了原始模型依赖命令行、操作门槛高且功能分散的痛点，将复杂的 AI 绘图流程整合进一个直观易用的图形化平台。\n\n无论是希望快速上手的普通创作者、需要精细控制画面细节的设计师，还是想要深入探索模型潜力的开发者与研究人员，都能从中获益。其核心亮点在于极高的功能丰富度：不仅支持文生图、图生图、局部重绘（Inpainting）和外绘（Outpainting）等基础模式，还独创了注意力机制调整、提示词矩阵、负向提示词以及“高清修复”等高级功能。此外，它内置了 GFPGAN 和 CodeFormer 等人脸修复工具，支持多种神经网络放大算法，并允许用户通过插件系统无限扩展能力。即使是显存有限的设备，stable-diffusion-webui 也提供了相应的优化选项，让高质量的 AI 艺术创作变得触手可及。",162132,3,"2026-04-05T11:01:52",[13,14,15],"开发框架","图像","Agent","ready",{"id":18,"name":19,"github_repo":20,"description_zh":21,"stars":22,"difficulty_score":23,"last_commit_at":24,"category_tags":25,"status":16},1381,"everything-claude-code","affaan-m\u002Feverything-claude-code","everything-claude-code 是一套专为 AI 编程助手（如 Claude Code、Codex、Cursor 等）打造的高性能优化系统。它不仅仅是一组配置文件，而是一个经过长期实战打磨的完整框架，旨在解决 AI 代理在实际开发中面临的效率低下、记忆丢失、安全隐患及缺乏持续学习能力等核心痛点。\n\n通过引入技能模块化、直觉增强、记忆持久化机制以及内置的安全扫描功能，everything-claude-code 能显著提升 AI 在复杂任务中的表现，帮助开发者构建更稳定、更智能的生产级 AI 代理。其独特的“研究优先”开发理念和针对 Token 消耗的优化策略，使得模型响应更快、成本更低，同时有效防御潜在的攻击向量。\n\n这套工具特别适合软件开发者、AI 研究人员以及希望深度定制 AI 工作流的技术团队使用。无论您是在构建大型代码库，还是需要 AI 协助进行安全审计与自动化测试，everything-claude-code 都能提供强大的底层支持。作为一个曾荣获 Anthropic 黑客大奖的开源项目，它融合了多语言支持与丰富的实战钩子（hooks），让 AI 真正成长为懂上",140436,2,"2026-04-05T23:32:43",[13,15,26],"语言模型",{"id":28,"name":29,"github_repo":30,"description_zh":31,"stars":32,"difficulty_score":23,"last_commit_at":33,"category_tags":34,"status":16},2271,"ComfyUI","Comfy-Org\u002FComfyUI","ComfyUI 是一款功能强大且高度模块化的视觉 AI 引擎，专为设计和执行复杂的 Stable Diffusion 图像生成流程而打造。它摒弃了传统的代码编写模式，采用直观的节点式流程图界面，让用户通过连接不同的功能模块即可构建个性化的生成管线。\n\n这一设计巧妙解决了高级 AI 绘图工作流配置复杂、灵活性不足的痛点。用户无需具备编程背景，也能自由组合模型、调整参数并实时预览效果，轻松实现从基础文生图到多步骤高清修复等各类复杂任务。ComfyUI 拥有极佳的兼容性，不仅支持 Windows、macOS 和 Linux 全平台，还广泛适配 NVIDIA、AMD、Intel 及苹果 Silicon 等多种硬件架构，并率先支持 SDXL、Flux、SD3 等前沿模型。\n\n无论是希望深入探索算法潜力的研究人员和开发者，还是追求极致创作自由度的设计师与资深 AI 绘画爱好者，ComfyUI 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",107662,"2026-04-03T11:11:01",[13,14,15],{"id":36,"name":37,"github_repo":38,"description_zh":39,"stars":40,"difficulty_score":23,"last_commit_at":41,"category_tags":42,"status":16},3704,"NextChat","ChatGPTNextWeb\u002FNextChat","NextChat 是一款轻量且极速的 AI 助手，旨在为用户提供流畅、跨平台的大模型交互体验。它完美解决了用户在多设备间切换时难以保持对话连续性，以及面对众多 AI 模型不知如何统一管理的痛点。无论是日常办公、学习辅助还是创意激发，NextChat 都能让用户随时随地通过网页、iOS、Android、Windows、MacOS 或 Linux 端无缝接入智能服务。\n\n这款工具非常适合普通用户、学生、职场人士以及需要私有化部署的企业团队使用。对于开发者而言，它也提供了便捷的自托管方案，支持一键部署到 Vercel 或 Zeabur 等平台。\n\nNextChat 的核心亮点在于其广泛的模型兼容性，原生支持 Claude、DeepSeek、GPT-4 及 Gemini Pro 等主流大模型，让用户在一个界面即可自由切换不同 AI 能力。此外，它还率先支持 MCP（Model Context Protocol）协议，增强了上下文处理能力。针对企业用户，NextChat 提供专业版解决方案，具备品牌定制、细粒度权限控制、内部知识库整合及安全审计等功能，满足公司对数据隐私和个性化管理的高标准要求。",87618,"2026-04-05T07:20:52",[13,26],{"id":44,"name":45,"github_repo":46,"description_zh":47,"stars":48,"difficulty_score":23,"last_commit_at":49,"category_tags":50,"status":16},2268,"ML-For-Beginners","microsoft\u002FML-For-Beginners","ML-For-Beginners 是由微软推出的一套系统化机器学习入门课程，旨在帮助零基础用户轻松掌握经典机器学习知识。这套课程将学习路径规划为 12 周，包含 26 节精炼课程和 52 道配套测验，内容涵盖从基础概念到实际应用的完整流程，有效解决了初学者面对庞大知识体系时无从下手、缺乏结构化指导的痛点。\n\n无论是希望转型的开发者、需要补充算法背景的研究人员，还是对人工智能充满好奇的普通爱好者，都能从中受益。课程不仅提供了清晰的理论讲解，还强调动手实践，让用户在循序渐进中建立扎实的技能基础。其独特的亮点在于强大的多语言支持，通过自动化机制提供了包括简体中文在内的 50 多种语言版本，极大地降低了全球不同背景用户的学习门槛。此外，项目采用开源协作模式，社区活跃且内容持续更新，确保学习者能获取前沿且准确的技术资讯。如果你正寻找一条清晰、友好且专业的机器学习入门之路，ML-For-Beginners 将是理想的起点。",84991,"2026-04-05T10:45:23",[14,51,52,53,15,54,26,13,55],"数据工具","视频","插件","其他","音频",{"id":57,"name":58,"github_repo":59,"description_zh":60,"stars":61,"difficulty_score":10,"last_commit_at":62,"category_tags":63,"status":16},3128,"ragflow","infiniflow\u002Fragflow","RAGFlow 是一款领先的开源检索增强生成（RAG）引擎，旨在为大语言模型构建更精准、可靠的上下文层。它巧妙地将前沿的 RAG 技术与智能体（Agent）能力相结合，不仅支持从各类文档中高效提取知识，还能让模型基于这些知识进行逻辑推理和任务执行。\n\n在大模型应用中，幻觉问题和知识滞后是常见痛点。RAGFlow 通过深度解析复杂文档结构（如表格、图表及混合排版），显著提升了信息检索的准确度，从而有效减少模型“胡编乱造”的现象，确保回答既有据可依又具备时效性。其内置的智能体机制更进一步，使系统不仅能回答问题，还能自主规划步骤解决复杂问题。\n\n这款工具特别适合开发者、企业技术团队以及 AI 研究人员使用。无论是希望快速搭建私有知识库问答系统，还是致力于探索大模型在垂直领域落地的创新者，都能从中受益。RAGFlow 提供了可视化的工作流编排界面和灵活的 API 接口，既降低了非算法背景用户的上手门槛，也满足了专业开发者对系统深度定制的需求。作为基于 Apache 2.0 协议开源的项目，它正成为连接通用大模型与行业专有知识之间的重要桥梁。",77062,"2026-04-04T04:44:48",[15,14,13,26,54],{"id":65,"github_repo":66,"name":67,"description_en":68,"description_zh":69,"ai_summary_zh":70,"readme_en":71,"readme_zh":72,"quickstart_zh":73,"use_case_zh":74,"hero_image_url":75,"owner_login":76,"owner_name":76,"owner_avatar_url":77,"owner_bio":78,"owner_company":78,"owner_location":78,"owner_email":78,"owner_twitter":78,"owner_website":78,"owner_url":79,"languages":80,"stars":101,"forks":102,"last_commit_at":103,"license":104,"difficulty_score":10,"env_os":105,"env_gpu":106,"env_ram":107,"env_deps":108,"category_tags":116,"github_topics":78,"view_count":23,"oss_zip_url":78,"oss_zip_packed_at":78,"status":16,"created_at":117,"updated_at":118,"faqs":119,"releases":154},3474,"mindcraft-bots\u002Fmindcraft","mindcraft","Minecraft AI with LLMs+Mineflayer","mindcraft 是一个让大语言模型（LLM）在《我的世界》（Minecraft）中“活”起来的开源项目。它结合了强大的 AI 模型与 Mineflayer 机器人框架，使 AI 能够像真实玩家一样进入游戏世界，理解自然语言指令、自主规划任务并执行复杂操作，甚至能在沙盒环境中编写和运行代码来解决问题。\n\n该项目主要解决了传统游戏机器人缺乏灵活性与智能决策能力的问题。用户不再需要编写繁琐的脚本，只需通过对话即可指挥 AI 助手进行建造、挖掘、合成或探索，极大地降低了自动化游戏的门槛，也为研究多模态智能体在虚拟环境中的行为提供了理想平台。\n\nmindcraft 特别适合开发者、AI 研究人员以及热爱技术探索的玩家使用。如果你希望实验不同的大模型（支持 OpenAI、Gemini、Claude、Ollama 等多种接口）在游戏场景中的表现，或者想观察 AI 如何通过学习掌握游戏机制，这是一个极佳的实践工具。其独特的技术亮点在于将代码生成能力融入游戏交互，允许 AI 动态编写策略代码，但出于安全考虑，该功能默认关闭，需用户手动配置并谨慎使用。无论是用于教育演示、算法验证，还是单纯体验与智能体","mindcraft 是一个让大语言模型（LLM）在《我的世界》（Minecraft）中“活”起来的开源项目。它结合了强大的 AI 模型与 Mineflayer 机器人框架，使 AI 能够像真实玩家一样进入游戏世界，理解自然语言指令、自主规划任务并执行复杂操作，甚至能在沙盒环境中编写和运行代码来解决问题。\n\n该项目主要解决了传统游戏机器人缺乏灵活性与智能决策能力的问题。用户不再需要编写繁琐的脚本，只需通过对话即可指挥 AI 助手进行建造、挖掘、合成或探索，极大地降低了自动化游戏的门槛，也为研究多模态智能体在虚拟环境中的行为提供了理想平台。\n\nmindcraft 特别适合开发者、AI 研究人员以及热爱技术探索的玩家使用。如果你希望实验不同的大模型（支持 OpenAI、Gemini、Claude、Ollama 等多种接口）在游戏场景中的表现，或者想观察 AI 如何通过学习掌握游戏机制，这是一个极佳的实践工具。其独特的技术亮点在于将代码生成能力融入游戏交互，允许 AI 动态编写策略代码，但出于安全考虑，该功能默认关闭，需用户手动配置并谨慎使用。无论是用于教育演示、算法验证，还是单纯体验与智能体共同游戏的乐趣，mindcraft 都提供了一个开放且可高度定制的实验场。","\u003Ch1 align=\"center\">🧠mindcraft⛏️\u003C\u002Fh1>\n\u003Ch1 align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Ftrendshift.io\u002Frepositories\u002F9163\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fmindcraft-bots_mindcraft_readme_4a68feb902da.png\" alt=\"kolbytn%2Fmindcraft | Trendshift\" style=\"width: 250px; height: 55px;\" width=\"250\" height=\"55\"\u002F>\u003C\u002Fa>\n\u003C\u002Fh1>\n\n\u003Cp align=\"center\">Crafting minds for Minecraft with LLMs and \u003Ca href=\"https:\u002F\u002Fprismarinejs.github.io\u002Fmineflayer\u002F#\u002F\">Mineflayer!\u003C\u002Fa>\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fblob\u002Fmain\u002FFAQ.md\">FAQ\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fdiscord.gg\u002Fmp73p35dzC\">Discord Support\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=gRotoL8P8D8\">Video Tutorial\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fkolbynottingham.com\u002Fmindcraft\u002F\">Blog Post\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fmindcraft-minecollab.github.io\u002Findex.html\">Paper Website\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fblob\u002Fmain\u002Fminecollab.md\">MineCollab\u003C\u002Fa>\n\u003C\u002Fp>\n\n> [!Caution]\nDo not connect this bot to public servers with coding enabled. This project allows an LLM to write\u002Fexecute code on your computer. The code is sandboxed, but still vulnerable to injection attacks. Code writing is disabled by default, you can enable it by setting `allow_insecure_coding` to `true` in `settings.js`. Ye be warned.\n\n# Getting Started\n## Requirements\n\n- [Minecraft Java Edition](https:\u002F\u002Fwww.minecraft.net\u002Fen-us\u002Fstore\u002Fminecraft-java-bedrock-edition-pc) (up to v1.21.11, recommend v1.21.6)\n- [Node.js Installed](https:\u002F\u002Fnodejs.org\u002F) (Node v18 or v20 LTS recommended. Node v24+ may cause issues with native dependencies)\n- At least one API key from a supported API provider. See [supported APIs](#model-customization). OpenAI is the default.\n\n> [!Important]\n> If installing node on windows, ensure you check `Automatically install the necessary tools`\n>\n> If you encounter `npm install` errors on macOS, see the [FAQ](FAQ.md#common-issues) for troubleshooting native module build issues\n\n## Install and Run\n\n1. Make sure you have the requirements above.\n\n2. Download the [latest release](https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Freleases\u002Flatest) and unzip it, or clone the repository.\n\n3. Rename `keys.example.json` to `keys.json` and fill in your API keys (you only need one). The desired model is set in `andy.json` or other profiles. For other models refer to the table below.\n\n4. In terminal\u002Fcommand prompt, run `npm install` from the installed directory\n\n5. Start a minecraft world and open it to LAN on localhost port `55916`\n\n6. Run `node main.js` from the installed directory\n\nIf you encounter issues, check the [FAQ](https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fblob\u002Fmain\u002FFAQ.md) or find support on [discord](https:\u002F\u002Fdiscord.gg\u002Fmp73p35dzC). We are currently not very responsive to github issues. To run tasks please refer to [Minecollab Instructions](minecollab.md#installation)\n\n\n# Configuration\n## Model Customization\n\nYou can configure project details in `settings.js`. [See file.](settings.js)\n\nYou can configure the agent's name, model, and prompts in their profile like `andy.json`. The model can be specified with the `model` field, with values like `model: \"gemini-2.5-pro\"`. You will need the correct API key for the API provider you choose. See all supported APIs below.\n\n\u003Cdetails>\n\u003Csummary>\u003Cstrong>⭐ VIEW SUPPORTED APIs ⭐\u003C\u002Fstrong>\u003C\u002Fsummary>\n\n| API Name | Config Variable| Docs |\n|------|------|------|\n| `openai` | `OPENAI_API_KEY` | [docs](https:\u002F\u002Fplatform.openai.com\u002Fdocs\u002Fmodels) |\n| `google` | `GEMINI_API_KEY` | [docs](https:\u002F\u002Fai.google.dev\u002Fgemini-api\u002Fdocs\u002Fmodels\u002Fgemini) |\n| `anthropic` | `ANTHROPIC_API_KEY` | [docs](https:\u002F\u002Fdocs.anthropic.com\u002Fclaude\u002Fdocs\u002Fmodels-overview) |\n| `xai` | `XAI_API_KEY` | [docs](https:\u002F\u002Fdocs.x.ai\u002Fdocs) |\n| `deepseek` | `DEEPSEEK_API_KEY` | [docs](https:\u002F\u002Fapi-docs.deepseek.com\u002F) |\n| `ollama` (local) | n\u002Fa | [docs](https:\u002F\u002Follama.com\u002Flibrary) |\n| `qwen` | `QWEN_API_KEY` | [Intl.](https:\u002F\u002Fwww.alibabacloud.com\u002Fhelp\u002Fen\u002Fmodel-studio\u002Fdeveloper-reference\u002Fuse-qwen-by-calling-api)\u002F[cn](https:\u002F\u002Fhelp.aliyun.com\u002Fzh\u002Fmodel-studio\u002Fgetting-started\u002Fmodels) |\n| `mistral` | `MISTRAL_API_KEY` | [docs](https:\u002F\u002Fdocs.mistral.ai\u002Fgetting-started\u002Fmodels\u002Fmodels_overview\u002F) |\n| `replicate` | `REPLICATE_API_KEY` | [docs](https:\u002F\u002Freplicate.com\u002Fcollections\u002Flanguage-models) |\n| `groq` (not grok) | `GROQCLOUD_API_KEY` | [docs](https:\u002F\u002Fconsole.groq.com\u002Fdocs\u002Fmodels) |\n| `huggingface` | `HUGGINGFACE_API_KEY` | [docs](https:\u002F\u002Fhuggingface.co\u002Fmodels) |\n| `novita` | `NOVITA_API_KEY` | [docs](https:\u002F\u002Fnovita.ai\u002Fmodel-api\u002Fproduct\u002Fllm-api?utm_source=github_mindcraft&utm_medium=github_readme&utm_campaign=link) |\n| `openrouter` | `OPENROUTER_API_KEY` | [docs](https:\u002F\u002Fopenrouter.ai\u002Fmodels) |\n| `glhf` | `GHLF_API_KEY` | [docs](https:\u002F\u002Fglhf.chat\u002Fuser-settings\u002Fapi) |\n| `hyperbolic` | `HYPERBOLIC_API_KEY` | [docs](https:\u002F\u002Fdocs.hyperbolic.xyz\u002Fdocs\u002Fgetting-started) |\n| `vllm` | n\u002Fa | n\u002Fa |\n| `cerebras` | `CEREBRAS_API_KEY` | [docs](https:\u002F\u002Finference-docs.cerebras.ai\u002Fintroduction) |\n| `mercury` | `MERCURY_API_KEY` | [docs](https:\u002F\u002Fwww.inceptionlabs.ai\u002F) |\n\n\u003C\u002Fdetails>\n\nFor more comprehensive model configuration and syntax, see [Model Specifications](#model-specifications).\n\nFor local models we support [ollama](https:\u002F\u002Follama.com\u002F) and we provide our own finetuned models for you to use. \nTo install our models, install ollama and run the following terminal command:\n```bash\nollama pull sweaterdog\u002Fandy-4:micro-q8_0 && ollama pull embeddinggemma\n```\n\n## Online Servers\nTo connect to online servers your bot will need an official Microsoft\u002FMinecraft account. You can use your own personal one, but will need another account if you want to connect too and play with it. To connect, change these lines in `settings.js`:\n```javascript\n\"host\": \"111.222.333.444\",\n\"port\": 55920,\n\"auth\": \"microsoft\",\n\n\u002F\u002F rest is same...\n```\n> [!Important]\n> The bot's name in the profile.json must exactly match the Minecraft profile name! Otherwise the bot will spam talk to itself.\n\nTo use different accounts, Mindcraft will connect with the account that the Minecraft launcher is currently using. You can switch accounts in the launcher, then run `node main.js`, then switch to your main account after the bot has connected.\n\n## Tasks\n\nTasks automatically start the bot with a prompt and a goal item to acquire or blueprint to construct. To run a simple task that involves collecting 4 oak_logs run \n\n`node main.js --task_path tasks\u002Fbasic\u002Fsingle_agent.json --task_id gather_oak_logs`\n\nHere is an example task json format: \n\n```\n{\n    \"gather_oak_logs\": {\n      \"goal\": \"Collect at least four logs\",\n      \"initial_inventory\": {\n        \"0\": {\n          \"wooden_axe\": 1\n        }\n      },\n      \"agent_count\": 1,\n      \"target\": \"oak_log\",\n      \"number_of_target\": 4,\n      \"type\": \"techtree\",\n      \"max_depth\": 1,\n      \"depth\": 0,\n      \"timeout\": 300,\n      \"blocked_actions\": {\n        \"0\": [],\n        \"1\": []\n      },\n      \"missing_items\": [],\n      \"requires_ctable\": false\n    }\n}\n```\n\nThe `initial_inventory` is what the bot will have at the start of the episode, `target` refers to the target item and `number_of_target` refers to the number of target items the agent needs to collect to successfully complete the task. \n\nIf you want more optimization and automatic launching of the minecraft world, you will need to follow the instructions in [Minecollab Instructions](minecollab.md#installation)\n\n## Docker Container\n\nIf you intend to `allow_insecure_coding`, it is a good idea to run the app in a docker container to reduce risks of running unknown code. This is strongly recommended before connecting to remote servers, although still does not guarantee complete safety.\n\n```bash\ndocker build -t mindcraft . && docker run --rm --add-host=host.docker.internal:host-gateway -p 8080:8080 -p 3000-3003:3000-3003 -e SETTINGS_JSON='{\"auto_open_ui\":false,\"profiles\":[\".\u002Fprofiles\u002Fgemini.json\"],\"host\":\"host.docker.internal\"}' --volume .\u002Fkeys.json:\u002Fapp\u002Fkeys.json --name mindcraft mindcraft\n```\nor simply\n```bash\ndocker-compose up --build\n```\n\nWhen running in docker, if you want the bot to join your local minecraft server, you have to use a special host address `host.docker.internal` to call your localhost from inside your docker container. Put this into your [settings.js](settings.js):\n\n```javascript\n\"host\": \"host.docker.internal\", \u002F\u002F instead of \"localhost\", to join your local minecraft from inside the docker container\n```\n\nTo connect to an unsupported minecraft version, you can try to use [viaproxy](services\u002Fviaproxy\u002FREADME.md)\n\n# Bot Profiles\n\nBot profiles are json files (such as `andy.json`) that define:\n\n1. Bot backend LLMs to use for talking, coding, and embedding.\n2. Prompts used to influence the bot's behavior.\n3. Examples help the bot perform tasks.\n\n## Model Specifications\n\nLLM models can be specified simply as `\"model\": \"gpt-4o\"`, or more specifically with `\"{api}\u002F{model}\"`, like `\"openrouter\u002Fgoogle\u002Fgemini-2.5-pro\"`. See all supported APIs [here](#model-customization).\n\nThe `model` field can be a string or an object. A model object must specify an `api`, and optionally a `model`, `url`, and additional `params`. You can also use different models\u002Fproviders for chatting, coding, vision, embedding, and voice synthesis. See the example below.\n\n```json\n\"model\": {\n  \"api\": \"openai\",\n  \"model\": \"gpt-4o\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\",\n  \"params\": {\n    \"max_tokens\": 1000,\n    \"temperature\": 1\n  }\n},\n\"code_model\": {\n  \"api\": \"openai\",\n  \"model\": \"gpt-4\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\"\n},\n\"vision_model\": {\n  \"api\": \"openai\",\n  \"model\": \"gpt-4o\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\"\n},\n\"embedding\": {\n  \"api\": \"openai\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\",\n  \"model\": \"text-embedding-ada-002\"\n},\n\"speak_model\": \"openai\u002Ftts-1\u002Fecho\"\n```\n\n`model` is used for chat, `code_model` is used for newAction coding, `vision_model` is used for image interpretation, `embedding` is used to embed text for example selection, and `speak_model` is used for voice synthesis. `model` will be used by default for all other models if not specified. Not all APIs support embeddings, vision, or voice synthesis.\n\nAll apis have default models and urls, so those fields are optional. The `params` field is optional and can be used to specify additional parameters for the model. It accepts any key-value pairs supported by the api. Is not supported for embedding models.\n\n## Embedding Models\n\nEmbedding models are used to embed and efficiently select relevant examples for conversation and coding.\n\nSupported Embedding APIs: `openai`, `google`, `replicate`, `huggingface`, `novita`\n\nIf you try to use an unsupported model, then it will default to a simple word-overlap method. Expect reduced performance. We recommend using supported embedding APIs.\n\n## Voice Synthesis Models\n\nVoice synthesis models are used to narrate bot responses and specified with `speak_model`. This field is parsed differently than other models and only supports strings formatted as `\"{api}\u002F{model}\u002F{voice}\"`, like `\"openai\u002Ftts-1\u002Fecho\"`. We only support `openai` and `google` for voice synthesis.\n\n## Specifying Profiles via Command Line\n\nBy default, the program will use the profiles specified in `settings.js`. You can specify one or more agent profiles using the `--profiles` argument: `node main.js --profiles .\u002Fprofiles\u002Fandy.json .\u002Fprofiles\u002Fjill.json`\n\n\n# Contributing\n\nWe welcome contributions to the project! We are generally less responsive to github issues, and more responsive to pull requests. Join the [discord](https:\u002F\u002Fdiscord.gg\u002Fmp73p35dzC) for more active support and direction.\n\nWhile AI generated code is allowed, please vet it carefully. Submitting tons of sloppy code and documentation actively harms development.\n\n## Patches\n\nSome of the node modules that we depend on have bugs in them. To add a patch, change your local node module file and run `npx patch-package [package-name]`\n\n## Development Team\nThanks to all who contributed to the project, especially the official development team: [@MaxRobinsonTheGreat](https:\u002F\u002Fgithub.com\u002FMaxRobinsonTheGreat), [@kolbytn](https:\u002F\u002Fgithub.com\u002Fkolbytn), [@icwhite](https:\u002F\u002Fgithub.com\u002Ficwhite), [@Sweaterdog](https:\u002F\u002Fgithub.com\u002FSweaterdog), [@Ninot1Quyi](https:\u002F\u002Fgithub.com\u002FNinot1Quyi), [@riqvip](https:\u002F\u002Fgithub.com\u002Friqvip), [@uukelele-scratch](https:\u002F\u002Fgithub.com\u002Fuukelele-scratch), [@mrelmida](https:\u002F\u002Fgithub.com\u002Fmrelmida)\n\n\n## Citation:\nThis work is published in the paper [Collaborating Action by Action: A Multi-agent LLM Framework for Embodied Reasoning](https:\u002F\u002Farxiv.org\u002Fabs\u002F2504.17950). Please use this citation if you use this project in your research:\n```\n@article{mindcraft2025,\n  title = {Collaborating Action by Action: A Multi-agent LLM Framework for Embodied Reasoning},\n  author = {White*, Isadora and Nottingham*, Kolby and Maniar, Ayush and Robinson, Max and Lillemark, Hansen and Maheshwari, Mehul and Qin, Lianhui and Ammanabrolu, Prithviraj},\n  journal = {arXiv preprint arXiv:2504.17950},\n  year = {2025},\n  url = {https:\u002F\u002Farxiv.org\u002Fabs\u002F2504.17950},\n}\n```\n\n## Contributors\n\nThanks to everyone who has submitted issues on and off Github, made suggestions, and generally helped make this a better project.\n\n![Contributors](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fmindcraft-bots_mindcraft_readme_e2a76e2e796c.png)\n","\u003Ch1 align=\"center\">🧠mindcraft⛏️\u003C\u002Fh1>\n\u003Ch1 align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Ftrendshift.io\u002Frepositories\u002F9163\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fmindcraft-bots_mindcraft_readme_4a68feb902da.png\" alt=\"kolbytn%2Fmindcraft | Trendshift\" style=\"width: 250px; height: 55px;\" width=\"250\" height=\"55\"\u002F>\u003C\u002Fa>\n\u003C\u002Fh1>\n\n\u003Cp align=\"center\">利用大语言模型和\u003Ca href=\"https:\u002F\u002Fprismarinejs.github.io\u002Fmineflayer\u002F#\u002F\">Mineflayer!\u003C\u002Fa>为Minecraft打造智能机器人。\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fblob\u002Fmain\u002FFAQ.md\">常见问题解答\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fdiscord.gg\u002Fmp73p35dzC\">Discord支持\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=gRotoL8P8D8\">视频教程\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fkolbynottingham.com\u002Fmindcraft\u002F\">博客文章\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fmindcraft-minecollab.github.io\u002Findex.html\">论文网站\u003C\u002Fa> | \n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fblob\u002Fmain\u002Fminecollab.md\">MineCollab\u003C\u002Fa>\n\u003C\u002Fp>\n\n> [!注意]\n请勿将此机器人连接到启用了代码执行功能的公共服务器。该项目允许大语言模型在您的计算机上编写和执行代码。虽然代码处于沙箱环境中，但仍可能受到注入攻击。默认情况下，代码编写功能已禁用；您可以通过在`settings.js`中将`allow_insecure_coding`设置为`true`来启用该功能。敬请留意。\n\n# 入门指南\n## 系统要求\n\n- [Minecraft Java版](https:\u002F\u002Fwww.minecraft.net\u002Fen-us\u002Fstore\u002Fminecraft-java-bedrock-edition-pc)（最高至v1.21.11，推荐v1.21.6）\n- [已安装Node.js](https:\u002F\u002Fnodejs.org\u002F)（建议使用Node v18或v20 LTS版本。Node v24及以上版本可能会导致原生依赖项出现问题）\n- 至少一个来自受支持API提供商的API密钥。请参阅[支持的API列表](#模型自定义)。默认使用OpenAI。\n\n> [!重要提示]\n> 如果在Windows上安装Node.js，请确保勾选“自动安装所需工具”选项。\n>\n> 如果在macOS上运行`npm install`时遇到错误，请参阅[常见问题解答](FAQ.md#common-issues)，以解决原生模块构建问题。\n\n## 安装与运行\n\n1. 确保已满足上述系统要求。\n\n2. 下载[最新发布版本](https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Freleases\u002Flatest)并解压，或直接克隆本仓库。\n\n3. 将`keys.example.json`重命名为`keys.json`，并填入您的API密钥（只需一个即可）。所需模型可在`andy.json`或其他配置文件中设置。如需使用其他模型，请参考下表。\n\n4. 在终端或命令提示符中，进入安装目录并运行`npm install`。\n\n5. 启动一个Minecraft世界，并将其开放为局域网游戏，监听本地回环地址端口`55916`。\n\n6. 在安装目录中运行`node main.js`。\n\n如遇问题，请查阅[常见问题解答](https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fblob\u002Fmain\u002FFAQ.md)或前往[Discord支持频道](https:\u002F\u002Fdiscord.gg\u002Fmp73p35dzC)寻求帮助。目前我们对GitHub上的问题响应较为有限。有关任务执行，请参阅[MineCollab使用说明](minecollab.md#installation)。\n\n# 配置\n## 模型自定义\n\n您可以在`settings.js`中配置项目相关参数。[查看文件。](settings.js)\n\n您还可以在各代理配置文件中（如`andy.json`）设置代理名称、使用的模型及提示词。模型可通过`model`字段指定，例如`model: \"gemini-2.5-pro\"`。请务必使用与所选API提供商匹配的正确API密钥。所有支持的API列表如下。\n\n\u003Cdetails>\n\u003Csummary>\u003Cstrong>⭐ 查看支持的API ⭐\u003C\u002Fstrong>\u003C\u002Fsummary>\n\n| API名称 | 配置变量 | 文档链接 |\n|------|------|------|\n| `openai` | `OPENAI_API_KEY` | [文档](https:\u002F\u002Fplatform.openai.com\u002Fdocs\u002Fmodels) |\n| `google` | `GEMINI_API_KEY` | [文档](https:\u002F\u002Fai.google.dev\u002Fgemini-api\u002Fdocs\u002Fmodels\u002Fgemini) |\n| `anthropic` | `ANTHROPIC_API_KEY` | [文档](https:\u002F\u002Fdocs.anthropic.com\u002Fclaude\u002Fdocs\u002Fmodels-overview) |\n| `xai` | `XAI_API_KEY` | [文档](https:\u002F\u002Fdocs.x.ai\u002Fdocs) |\n| `deepseek` | `DEEPSEEK_API_KEY` | [文档](https:\u002F\u002Fapi-docs.deepseek.com\u002F) |\n| `ollama`（本地） | 无 | [文档](https:\u002F\u002Follama.com\u002Flibrary) |\n| `qwen` | `QWEN_API_KEY` | [国际版](https:\u002F\u002Fwww.alibabacloud.com\u002Fhelp\u002Fen\u002Fmodel-studio\u002Fdeveloper-reference\u002Fuse-qwen-by-calling-api)\u002F[中文版](https:\u002F\u002Fhelp.aliyun.com\u002Fzh\u002Fmodel-studio\u002Fgetting-started\u002Fmodels) |\n| `mistral` | `MISTRAL_API_KEY` | [文档](https:\u002F\u002Fdocs.mistral.ai\u002Fgetting-started\u002Fmodels\u002Fmodels_overview\u002F) |\n| `replicate` | `REPLICATE_API_KEY` | [文档](https:\u002F\u002Freplicate.com\u002Fcollections\u002Flanguage-models) |\n| `groq`（非Grok） | `GROQCLOUD_API_KEY` | [文档](https:\u002F\u002Fconsole.groq.com\u002Fdocs\u002Fmodels) |\n| `huggingface` | `HUGGINGFACE_API_KEY` | [文档](https:\u002F\u002Fhuggingface.co\u002Fmodels) |\n| `novita` | `NOVITA_API_KEY` | [文档](https:\u002F\u002Fnovita.ai\u002Fmodel-api\u002Fproduct\u002Fllm-api?utm_source=github_mindcraft&utm_medium=github_readme&utm_campaign=link) |\n| `openrouter` | `OPENROUTER_API_KEY` | [文档](https:\u002F\u002Fopenrouter.ai\u002Fmodels) |\n| `glhf` | `GHLF_API_KEY` | [文档](https:\u002F\u002Fglhf.chat\u002Fuser-settings\u002Fapi) |\n| `hyperbolic` | `HYPERBOLIC_API_KEY` | [文档](https:\u002F\u002Fdocs.hyperbolic.xyz\u002Fdocs\u002Fgetting-started) |\n| `vllm` | 无 | 无 |\n| `cerebras` | `CEREBRAS_API_KEY` | [文档](https:\u002F\u002Finference-docs.cerebras.ai\u002Fintroduction) |\n| `mercury` | `MERCURY_API_KEY` | [文档](https:\u002F\u002Fwww.inceptionlabs.ai\u002F) |\n\n\u003C\u002Fdetails>\n\n如需更全面的模型配置及语法说明，请参阅[模型规格](#model-specifications)。\n\n对于本地模型，我们支持`ollama`平台，并提供经过微调的专属模型供您使用。要安装我们的模型，请先安装`ollama`，然后在终端中运行以下命令：\n```bash\nollama pull sweaterdog\u002Fandy-4:micro-q8_0 && ollama pull embeddinggemma\n```\n\n## 连接在线服务器\n若要连接到在线服务器，您的机器人需要一个官方的Microsoft\u002FMinecraft账号。您可以使用自己的个人账号，但如果您希望同时登录并游玩，则需要另一个账号。要进行连接，请修改`settings.js`中的以下几行：\n```javascript\n\"host\": \"111.222.333.444\",\n\"port\": 55920,\n\"auth\": \"microsoft\",\n\n\u002F\u002F 其余部分保持不变...\n```\n> [!重要提示]\n机器人在`profile.json`中的名称必须与Minecraft玩家名称完全一致！否则机器人会不断向自己发送消息。\n\n若需使用不同账号，Mindcraft将连接当前Minecraft启动器所使用的账号。您可以在启动器中切换账号，然后运行`node main.js`，待机器人成功连接后再切换回您的主账号。\n\n## 任务\n\n任务会自动启动机器人，并提供一个提示和一个需要获取的目标物品或建造蓝图。要运行一个简单的任务，例如收集4个橡木原木，可以执行以下命令：\n\n`node main.js --task_path tasks\u002Fbasic\u002Fsingle_agent.json --task_id gather_oak_logs`\n\n以下是一个示例任务的 JSON 格式：\n\n```\n{\n    \"gather_oak_logs\": {\n      \"goal\": \"收集至少四根原木\",\n      \"initial_inventory\": {\n        \"0\": {\n          \"wooden_axe\": 1\n        }\n      },\n      \"agent_count\": 1,\n      \"target\": \"oak_log\",\n      \"number_of_target\": 4,\n      \"type\": \"techtree\",\n      \"max_depth\": 1,\n      \"depth\": 0,\n      \"timeout\": 300,\n      \"blocked_actions\": {\n        \"0\": [],\n        \"1\": []\n      },\n      \"missing_items\": [],\n      \"requires_ctable\": false\n    }\n}\n```\n\n`initial_inventory` 是机器人在任务开始时拥有的初始物品清单，`target` 表示目标物品，而 `number_of_target` 则表示智能体需要收集的目标物品数量，以成功完成任务。\n\n如果你想进一步优化并自动启动 Minecraft 世界，你需要按照 [Minecollab 指南](minecollab.md#installation) 中的说明进行操作。\n\n## Docker 容器\n\n如果你打算启用 `allow_insecure_coding`，建议将应用程序运行在 Docker 容器中，以降低运行未知代码的风险。在连接到远程服务器之前，强烈建议这样做，尽管这并不能完全保证安全性。\n\n```bash\ndocker build -t mindcraft . && docker run --rm --add-host=host.docker.internal:host-gateway -p 8080:8080 -p 3000-3003:3000-3003 -e SETTINGS_JSON='{\"auto_open_ui\":false,\"profiles\":[\".\u002Fprofiles\u002Fgemini.json\"],\"host\":\"host.docker.internal\"}' --volume .\u002Fkeys.json:\u002Fapp\u002Fkeys.json --name mindcraft mindcraft\n```\n\n或者简单地使用：\n\n```bash\ndocker-compose up --build\n```\n\n在 Docker 中运行时，如果希望机器人加入你的本地 Minecraft 服务器，必须使用特殊的主机地址 `host.docker.internal`，以便从容器内部访问你的本地主机。请将以下内容添加到你的 [settings.js](settings.js) 文件中：\n\n```javascript\n\"host\": \"host.docker.internal\", \u002F\u002F 而不是 \"localhost\"，用于从 Docker 容器内连接到本地 Minecraft\n```\n\n若要连接到不受支持的 Minecraft 版本，可以尝试使用 [viaproxy](services\u002Fviaproxy\u002FREADME.md)。\n\n# 机器人配置文件\n\n机器人配置文件是 JSON 文件（如 `andy.json`），用于定义：\n\n1. 机器人后端使用的 LLM 模型，用于对话、编码和嵌入。\n2. 用于影响机器人行为的提示语。\n3. 帮助机器人完成任务的示例。\n\n## 模型规格\n\nLLM 模型可以简单地指定为 `\"model\": \"gpt-4o\"`，也可以更具体地写成 `\"{api}\u002F{model}\"` 的形式，例如 `\"openrouter\u002Fgoogle\u002Fgemini-2.5-pro\"`。所有支持的 API 可以在此处查看 [模型自定义](#model-customization)。\n\n`model` 字段可以是字符串或对象。如果使用对象格式，必须指定 `api`，还可以选择性地指定 `model`、`url` 和其他 `params`。你也可以为聊天、编码、视觉处理、嵌入和语音合成使用不同的模型或提供商。以下是一个示例：\n\n```json\n\"model\": {\n  \"api\": \"openai\",\n  \"model\": \"gpt-4o\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\",\n  \"params\": {\n    \"max_tokens\": 1000,\n    \"temperature\": 1\n  }\n},\n\"code_model\": {\n  \"api\": \"openai\",\n  \"model\": \"gpt-4\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\"\n},\n\"vision_model\": {\n  \"api\": \"openai\",\n  \"model\": \"gpt-4o\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\"\n},\n\"embedding\": {\n  \"api\": \"openai\",\n  \"url\": \"https:\u002F\u002Fapi.openai.com\u002Fv1\u002F\",\n  \"model\": \"text-embedding-ada-002\"\n},\n\"speak_model\": \"openai\u002Ftts-1\u002Fecho\"\n```\n\n`model` 用于聊天，`code_model` 用于新动作编码，`vision_model` 用于图像理解，`embedding` 用于嵌入文本以选择相关示例，而 `speak_model` 则用于语音合成。如果没有特别指定，`model` 将默认用于其他所有功能。并非所有 API 都支持嵌入、视觉处理或语音合成。\n\n所有 API 都有默认的模型和 URL，因此这些字段是可选的。`params` 字段也是可选的，可用于为模型指定额外的参数。它接受 API 支持的任何键值对，但不适用于嵌入模型。\n\n## 嵌入模型\n\n嵌入模型用于嵌入文本，并高效地选择与对话和编码相关的示例。\n\n支持的嵌入 API：`openai`、`google`、`replicate`、`huggingface`、`novita`\n\n如果你尝试使用不受支持的模型，系统将默认采用简单的词重叠方法，性能可能会有所下降。我们建议使用受支持的嵌入 API。\n\n## 语音合成模型\n\n语音合成模型用于朗读机器人的响应，并通过 `speak_model` 进行指定。此字段的解析方式与其他模型不同，仅支持格式为 `\"{api}\u002F{model}\u002F{voice}\"` 的字符串，例如 `\"openai\u002Ftts-1\u002Fecho\"`。目前我们仅支持 `openai` 和 `google` 作为语音合成提供商。\n\n## 通过命令行指定配置文件\n\n默认情况下，程序会使用 `settings.js` 中指定的配置文件。你可以使用 `--profiles` 参数指定一个或多个代理配置文件：`node main.js --profiles .\u002Fprofiles\u002Fandy.json .\u002Fprofiles\u002Fjill.json`。\n\n# 贡献\n\n我们欢迎对该项目的贡献！通常我们对 GitHub 上的问题响应较慢，但对拉取请求的响应更快。请加入 [Discord](https:\u002F\u002Fdiscord.gg\u002Fmp73p35dzC) 以获得更积极的支持和指导。\n\n虽然允许提交 AI 生成的代码，但请务必仔细审查。大量提交粗糙的代码和文档会严重阻碍开发进程。\n\n## 补丁\n\n我们依赖的一些 Node.js 模块存在 bug。要添加补丁，只需修改本地的 Node.js 模块文件，然后运行 `npx patch-package [package-name]`。\n\n## 开发团队\n感谢所有为项目做出贡献的人，尤其是官方开发团队：[@MaxRobinsonTheGreat](https:\u002F\u002Fgithub.com\u002FMaxRobinsonTheGreat)、[@kolbytn](https:\u002F\u002Fgithub.com\u002Fkolbytn)、[@icwhite](https:\u002F\u002Fgithub.com\u002Ficwhite)、[@Sweaterdog](https:\u002F\u002Fgithub.com\u002FSweaterdog)、[@Ninot1Quyi](https:\u002F\u002Fgithub.com\u002FNinot1Quyi)、[@riqvip](https:\u002F\u002Fgithub.com\u002Friqvip)、[@uukelele-scratch](https:\u002F\u002Fgithub.com\u002Fuukelele-scratch)、[@mrelmida](https:\u002F\u002Fgithub.com\u002Fmrelmida)。\n\n## 引用：\n本工作发表在论文《逐行动协作：用于具身推理的多智能体 LLM 框架》中（arXiv 预印本 arXiv:2504.17950）。如果你在研究中使用本项目，请引用以下文献：\n```\n@article{mindcraft2025,\n  title = {Collaborating Action by Action: A Multi-agent LLM Framework for Embodied Reasoning},\n  author = {White*, Isadora and Nottingham*, Kolby and Maniar, Ayush and Robinson, Max and Lillemark, Hansen and Maheshwari, Mehul and Qin, Lianhui and Ammanabrolu, Prithviraj},\n  journal = {arXiv preprint arXiv:2504.17950},\n  year = {2025},\n  url = {https:\u002F\u002Farxiv.org\u002Fabs\u002F2504.17950},\n}\n```\n\n## 贡献者\n\n感谢所有在 GitHub 上提交过问题、提出过建议，并总体上帮助使这个项目变得更好的人。\n\n![贡献者](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fmindcraft-bots_mindcraft_readme_e2a76e2e796c.png)","# MindCraft 快速上手指南\n\nMindCraft 是一个利用大语言模型（LLM）和 Mineflayer 库，让 AI 代理在 Minecraft 中自主思考、编码和行动的开源项目。\n\n## 环境准备\n\n在开始之前，请确保你的系统满足以下要求：\n\n*   **操作系统**：Windows, macOS 或 Linux。\n    *   *Windows 用户注意*：安装 Node.js 时务必勾选 `Automatically install the necessary tools` 选项。\n    *   *macOS 用户注意*：若遇到 `npm install` 报错，通常涉及原生模块编译问题，需确保已安装 Xcode Command Line Tools。\n*   **游戏版本**：Minecraft Java Edition（推荐 v1.21.6，支持范围最高至 v1.21.11）。\n*   **运行环境**：Node.js（推荐 LTS 版本 v18 或 v20。**注意**：Node v24+ 可能导致原生依赖兼容性问题）。\n*   **API 密钥**：至少需要一个支持的 LLM 提供商 API Key（默认支持 OpenAI，同时也支持 Google Gemini, Anthropic, Ollama 本地模型等）。\n\n## 安装步骤\n\n### 1. 获取源码\n下载最新发布的 [Release 包](https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Freleases\u002Flatest) 并解压，或者克隆仓库：\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft.git\ncd mindcraft\n```\n\n### 2. 配置 API 密钥\n将示例配置文件重命名并填入你的 API Key：\n```bash\ncp keys.example.json keys.json\n```\n编辑 `keys.json`，填入你拥有的任意一个服务商的 Key（例如 `OPENAI_API_KEY`）。\n\n> **安全警告**：默认情况下代码写入功能是关闭的。若需在 `settings.js` 中开启 `allow_insecure_coding: true`，请务必在沙箱环境（如 Docker）中运行，以防 LLM 生成的代码对主机造成风险。\n\n### 3. 安装依赖\n在项目根目录执行：\n```bash\nnpm install\n```\n\n### 4. 准备 Minecraft 世界\n1. 启动 Minecraft Java 版。\n2. 创建一个新世界并进入。\n3. 按 `Esc` 打开菜单，选择 **对局域网开放 (Open to LAN)**。\n4. 设置端口为 `55916`（如果该端口被占用，可修改 `settings.js` 中的端口配置），然后确认开放。\n\n## 基本使用\n\n### 启动 AI 代理\n确保 Minecraft 世界已在局域网开放，且在终端中位于项目目录下，运行：\n```bash\nnode main.js\n```\n此时，AI 代理将尝试连接到你开放的本地世界。你可以在游戏中看到它以玩家身份加入，并通过聊天框与其互动或观察其自动行为。\n\n### 运行特定任务\n你可以预设任务让 AI 自动完成（例如收集物品）。以下是一个收集 4 个橡木原木的示例命令：\n```bash\nnode main.js --task_path tasks\u002Fbasic\u002Fsingle_agent.json --task_id gather_oak_logs\n```\n\n### 自定义模型与代理\n*   **切换模型**：编辑 `profiles\u002Fandy.json`（或其他 profile 文件），修改 `model` 字段。例如使用 Gemini：\n    ```json\n    \"model\": \"gemini-2.5-pro\"\n    ```\n    确保已在 `keys.json` 中配置对应的 `GEMINI_API_KEY`。\n*   **使用本地模型 (Ollama)**：\n    首先拉取专用模型：\n    ```bash\n    ollama pull sweaterdog\u002Fandy-4:micro-q8_0 && ollama pull embeddinggemma\n    ```\n    然后在 profile 中将 api 设置为 `ollama`。\n\n### 进阶：多账号联机\n若要连接远程服务器或与自己的主账号一起玩，需在 `settings.js` 中修改配置：\n```javascript\n\"host\": \"你的服务器 IP\",\n\"port\": 服务器端口，\n\"auth\": \"microsoft\",\n```\n**注意**：Bot 在 profile 中设定的名字必须与登录的 Minecraft 账号名称完全一致，否则会导致逻辑冲突。启动时，MindCraft 会使用当前 Minecraft 启动器登录的账号身份。","一位独立游戏开发者希望在《我的世界》中快速验证复杂的红石机械逻辑或建筑算法，但受限于手动操作效率低下且缺乏即时编程辅助。\n\n### 没有 mindcraft 时\n- **试错成本极高**：开发者需反复进出游戏手动放置方块测试红石电路，一次逻辑验证往往耗时数小时。\n- **代码实现门槛高**：若想通过脚本自动化建造，必须精通 JavaScript 和 Mineflayer 库，学习曲线陡峭。\n- **缺乏动态交互**：预设脚本无法根据游戏内突发状况（如地形阻挡）实时调整策略，导致任务中途失败。\n- **创意落地缓慢**：脑海中复杂的建筑结构难以迅速转化为游戏内的实际坐标指令，灵感容易流失。\n\n### 使用 mindcraft 后\n- **自然语言驱动**：开发者直接用英语描述“建造一个自动分类物品的红石仓库”，mindcraft 即可理解意图并规划步骤。\n- **自主代码生成**：mindcraft 调用大模型实时编写并执行 JavaScript 代码，无需人工干预即可完成复杂逻辑部署。\n- **智能环境适应**：在建造过程中，mindcraft 能感知周围地形变化，自动规避障碍或调整材料用量，确保任务完成。\n- **即时迭代反馈**：若结果不理想，只需口头指出问题，mindcraft 立即修改代码并重试，将验证周期从小时级缩短至分钟级。\n\nmindcraft 将《我的世界》从单纯的手动沙盒升级为可由自然语言直接操控的智能实验场，极大释放了玩家的创造力与工程验证效率。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fmindcraft-bots_mindcraft_ffc7451e.png","mindcraft-bots","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Fmindcraft-bots_55d5a79a.png",null,"https:\u002F\u002Fgithub.com\u002Fmindcraft-bots",[81,85,89,93,97],{"name":82,"color":83,"percentage":84},"JavaScript","#f1e05a",71.1,{"name":86,"color":87,"percentage":88},"Python","#3572A5",22.7,{"name":90,"color":91,"percentage":92},"HTML","#e34c26",5.8,{"name":94,"color":95,"percentage":96},"Dockerfile","#384d54",0.3,{"name":98,"color":99,"percentage":100},"Shell","#89e051",0.2,5033,738,"2026-04-04T12:56:57","MIT","Windows, macOS, Linux","未说明 (主要依赖云端 LLM API，若使用本地 Ollama 模型则取决于具体模型需求)","未说明",{"notes":109,"python":110,"dependencies":111},"该项目基于 Node.js 而非 Python。需要安装 Minecraft Java 版 (推荐 v1.21.6)。默认使用云端大模型 API (如 OpenAI, Google 等)，需配置 API Key；若需本地运行模型，需安装 Ollama 并拉取指定模型。若启用代码执行功能，强烈建议在 Docker 容器中运行以确保安全。Windows 用户安装 Node.js 时需勾选自动安装必要工具选项。","不需要 (基于 Node.js)",[112,113,114,115],"Node.js v18\u002Fv20 LTS","npm","Mineflayer","Ollama (可选，用于本地模型)",[26,15],"2026-03-27T02:49:30.150509","2026-04-06T11:30:48.424025",[120,125,130,135,140,145,149],{"id":121,"question_zh":122,"answer_zh":123,"source_url":124},15930,"如何让 Ollama 本地模型（如 Llama3）正常工作？","本地小模型（如 Llama3 8b）通常表现不稳定，可能需要进行微调（finetuning）才能发挥最佳效果。如果希望充分利用新动作和代码生成能力，建议使用更大、更智能的模型。此外，可以在 settings.json 中将 \"allow_insecure_coding\" 设置为 true 以允许机器人编写代码，但需注意使用本地模型生成 Minecraft 代码的成功率可能较低。","https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fissues\u002F60",{"id":126,"question_zh":127,"answer_zh":128,"source_url":129},15931,"如何避免机器人猎杀动物？","可以通过禁用狩猎模式（hunting mode）来避免机器人杀死动物。在最新版本中，该模式默认已经是关闭状态。","https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fissues\u002F78",{"id":131,"question_zh":132,"answer_zh":133,"source_url":134},15932,"如何解决连接 oobabooga\u002Ftext-generation-webui 时的替换错误？","如果在 oobabooga 端遇到替换错误，可以尝试修改代码：将 `stop: stop_seq` 替换为以下两行：\nstop: stop_seq,\nuser_bio: 'Minecraft Player'\n注意：即使修复了该错误，功能可能仍受限于所使用的具体模型。","https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fissues\u002F29",{"id":136,"question_zh":137,"answer_zh":138,"source_url":139},15933,"遇到 OpenAI API 速率限制（429 Error）导致崩溃怎么办？","当出现 \"RateLimitError: 429 Rate limit reached\" 错误时，说明请求频率超过了限制（例如 text-embedding-ada-002 的限制）。解决方法包括：等待约 20 秒后重试，或者访问 OpenAI 账户账单页面添加支付方式以提高速率限制额度。","https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fissues\u002F31",{"id":141,"question_zh":142,"answer_zh":143,"source_url":144},15934,"如何在俄罗斯等地区使用被限制的 LLM 服务（如 Gemini）？","如果因地区限制无法直接连接 API（如 Gemini），仅使用浏览器 VPN 是不够的。你需要配置系统级的全局 VPN（system-wide VPN），而不仅仅是浏览器插件，才能让项目后端成功连接到服务。","https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fissues\u002F651",{"id":146,"question_zh":147,"answer_zh":148,"source_url":129},15935,"为什么每次发送消息后 Ollama 服务器都会重启且响应极慢？","这可能是因为每次用户发送消息时，系统创建了一个新的代理（agent）并重新加载初始数据，而不是复用现有的代理，导致服务器不断重启加载模型。此外，如果显存（VRAM）不足或检测到不支持的显卡（如某些 AMD iGPU），也会导致加载失败或回退到慢速模式。建议检查硬件兼容性日志，确认是否有 \"unsupported Radeon iGPU detected skipping\" 等警告。",{"id":150,"question_zh":151,"answer_zh":152,"source_url":153},15936,"如何正确设置 API 密钥以解决 'ERRNO -4077' 或找不到密钥的问题？","如果程序报错找不到 keys.json 中的 API 密钥，可以尝试通过设置环境变量来解决。例如在命令行中使用命令：set \"EXAMPLE_API=你的 apikey\"（Windows）或 export EXAMPLE_API=你的 apikey（Linux\u002FMac），将密钥设为环境变量后再启动程序。","https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fissues\u002F316",[155,160,165,170,175],{"id":156,"version":157,"summary_zh":158,"released_at":159},90684,"v0.1.4","Bug 修复、文档更新和稳定性提升。\n\n## 变更内容\n* @Lawtro37 添加了 \"goToSurface\" 技能\u002F动作\n* @Ninot1Quyi 改进了寻路功能\n* @htqkeku-eftc、@Wuodan 和 @uukelele 改进了 Docker 配置\n* @uukelele 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F646 中修复了自定义 OpenAI 端点问题\n* @icwhite 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F701 中修订了 minecollab.md 中的安装说明\n* @atiweb 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F704 中提升了 Paper\u002FSpigot 服务器的连接稳定性\n* 更新了默认模型\n* 进行了许多通用文档修复和稳定性改进\n\n## 新贡献者\n* @A-Macaw 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F615 中完成了首次贡献\n* @David-T-Campos 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F624 中完成了首次贡献\n* @htqkeku-eftc 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F630 中完成了首次贡献\n* @Akinara666 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F635 中完成了首次贡献\n* @Aotumuri 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F638 中完成了首次贡献\n* @aaelfe 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F650 中完成了首次贡献\n* @Lenni0451 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F639 中完成了首次贡献\n* @arjun-sa 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F675 中完成了首次贡献\n* @zswzhijing 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F668 中完成了首次贡献\n* @Wuodan 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F729 中完成了首次贡献\n* @yoava7 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F691 中完成了首次贡献\n* @gaogzs 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F732 中完成了首次贡献\n* @atiweb 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F704 中完成了首次贡献\n\n**完整变更日志**: https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fcompare\u002Fv0.1.3...v0.1.4","2026-03-20T16:23:35",{"id":161,"version":162,"summary_zh":163,"released_at":164},90685,"v0.1.3","## 变更内容\n* 村民交易功能的延续，由 @riqvip 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F603 中完成\n* 村民交易功能，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F606 中实现\n* 水桶修复，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F610 中完成\n* 更新 README.md 中的仓库链接，由 @riqvip 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F612 中完成\n* 随机性热修复，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F611 中进行\n* 新版本发布，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F614 中完成\n\n\n**完整变更日志**: https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fcompare\u002Fv0.1.2...v0.1.3","2025-09-20T22:04:25",{"id":166,"version":167,"summary_zh":168,"released_at":169},90686,"v0.1.2","## 变更内容\n* 动态设置 Minecraft 版本和主机端口，由 @Nimikita 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F321 中实现\n* 自动查找 Minecraft 版本和端口，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F595 中实现\n* 将所有机器人输出写入 mindserver，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F596 中实现\n* 远程输出功能，由 @Solenopsisbot 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F543 中实现\n* 为 OpenAI 和 Gemini 添加 TTS 功能，并更新 Gemini SDK，由 @uukelele-scratch 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F599 中实现\n* 控制面板全面重构，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F598 中实现\n* 支持 Minecraft 1.21.6，由 @riqvip 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F601 中实现\n* AI 文本转语音 | OpenAI 和 Google，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F600 中实现\n* 更新 README 中的 Ollama 模型引用，由 @Sweaterdog 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F602 中实现\n* GPT 更新，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F605 中实现\n* 启用工具使用功能，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F604 中实现\n* 新版本发布，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F608 中实现\n\n## 新贡献者\n* @Solenopsisbot 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F543 中完成了首次贡献\n\n**完整变更日志**: https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fcompare\u002Fv0.1.1...v0.1.2","2025-09-07T22:32:28",{"id":171,"version":172,"summary_zh":173,"released_at":174},90687,"v0.1.1","## 变更内容\n* Andy-4 相关内容，由 @Sweaterdog 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F593 中提交\n* andy-4，由 @MaxRobinsonTheGreat 在 https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fpull\u002F594 中提交\n\n\n**完整变更日志**: https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fcompare\u002Fv0.1.0...v0.1.1","2025-08-24T19:08:47",{"id":176,"version":177,"summary_zh":178,"released_at":179},90688,"v0.1.0","## Mindcraft 首次正式发布🎉\r\n这是 Mindcraft 的首次发布！这将有助于更稳定的安装，并建立清晰的版本控制系统。\n\n## 感谢所有贡献者 ❤️ \n@kolbytn @MaxRobinsonTheGreat @homberger @Radnos @Gigabyte0x1337 @Ninot1Quyi @Vineeth-0 @FateUnix29 @ereid7 @BF5258 @eltociear @1223nij @keneo @kevinji @kumavis @JurassikLizard @Shandelie @Lawtro37 @wlvrx @MohmmadQunibi @Nimikita @jasonhp @uukelele-scratch @hackdefendr @ShadowAlzazel @luoling8192 @Saintdoggie @pixelkat5 @Ayushmaniar @itsme6582 @Vinamra7 @ricktonoli @icwhite @dtesters @Sweaterdog @aeromechanic000 @rajammanabrolu @mrelmida @kevint-cerebras @Zgrill2 \n\n**完整更新日志**: https:\u002F\u002Fgithub.com\u002Fmindcraft-bots\u002Fmindcraft\u002Fcommits\u002Fv0.1.0","2025-08-24T00:12:05"]