{"id":13644625,"url":"https://github.com/minedojo/voyager","last_synced_at":"2025-05-14T09:08:47.457Z","repository":{"id":169572106,"uuid":"645471238","full_name":"MineDojo/Voyager","owner":"MineDojo","description":"An Open-Ended Embodied Agent with Large Language Models","archived":false,"fork":false,"pushed_at":"2024-04-03T18:51:36.000Z","size":5270,"stargazers_count":6009,"open_issues_count":8,"forks_count":570,"subscribers_count":67,"default_branch":"main","last_synced_at":"2025-04-04T08:31:21.262Z","etag":null,"topics":["embodied-learning","large-language-models","minecraft","open-ended-learning"],"latest_commit_sha":null,"homepage":"https://voyager.minedojo.org/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MineDojo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-05-25T18:20:15.000Z","updated_at":"2025-04-03T19:42:33.000Z","dependencies_parsed_at":null,"dependency_job_id":"c309bab0-ac64-4c9a-989d-d985da3c8933","html_url":"https://github.com/MineDojo/Voyager","commit_stats":null,"previous_names":["minedojo/voyager"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MineDojo%2FVoyager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MineDojo%2FVoyager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MineDojo%2FVoyager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MineDojo%2FVoyager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MineDojo","download_url":"https://codeload.github.com/MineDojo/Voyager/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248420000,"owners_count":21100286,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["embodied-learning","large-language-models","minecraft","open-ended-learning"],"created_at":"2024-08-02T01:02:09.683Z","updated_at":"2025-04-11T14:38:11.436Z","avatar_url":"https://github.com/MineDojo.png","language":"JavaScript","funding_links":[],"categories":["NLP","Agent Categories"],"sub_categories":["\u003ca name=\"Unclassified\"\u003e\u003c/a\u003eUnclassified"],"readme":"# Voyager: An Open-Ended Embodied Agent with Large Language Models\n\u003cdiv align=\"center\"\u003e\n\n[[Website]](https://voyager.minedojo.org/)\n[[Arxiv]](https://arxiv.org/abs/2305.16291)\n[[PDF]](https://voyager.minedojo.org/assets/documents/voyager.pdf)\n[[Tweet]](https://twitter.com/DrJimFan/status/1662115266933972993?s=20)\n\n[![Python Version](https://img.shields.io/badge/Python-3.9-blue.svg)](https://github.com/MineDojo/Voyager)\n[![GitHub license](https://img.shields.io/github/license/MineDojo/Voyager)](https://github.com/MineDojo/Voyager/blob/main/LICENSE)\n______________________________________________________________________\n\n\nhttps://github.com/MineDojo/Voyager/assets/25460983/ce29f45b-43a5-4399-8fd8-5dd105fd64f2\n\n![](images/pull.png)\n\n\n\u003c/div\u003e\n\nWe introduce Voyager, the first LLM-powered embodied lifelong learning agent\nin Minecraft that continuously explores the world, acquires diverse skills, and\nmakes novel discoveries without human intervention. Voyager consists of three\nkey components: 1) an automatic curriculum that maximizes exploration, 2) an\never-growing skill library of executable code for storing and retrieving complex\nbehaviors, and 3) a new iterative prompting mechanism that incorporates environment\nfeedback, execution errors, and self-verification for program improvement.\nVoyager interacts with GPT-4 via blackbox queries, which bypasses the need for\nmodel parameter fine-tuning. The skills developed by Voyager are temporally\nextended, interpretable, and compositional, which compounds the agent’s abilities\nrapidly and alleviates catastrophic forgetting. Empirically, Voyager shows\nstrong in-context lifelong learning capability and exhibits exceptional proficiency\nin playing Minecraft. It obtains 3.3× more unique items, travels 2.3× longer\ndistances, and unlocks key tech tree milestones up to 15.3× faster than prior SOTA.\nVoyager is able to utilize the learned skill library in a new Minecraft world to\nsolve novel tasks from scratch, while other techniques struggle to generalize.\n\nIn this repo, we provide Voyager code. This codebase is under [MIT License](LICENSE).\n\n# Installation\nVoyager requires Python ≥ 3.9 and Node.js ≥ 16.13.0. We have tested on Ubuntu 20.04, Windows 11, and macOS. You need to follow the instructions below to install Voyager.\n\n## Python Install\n```\ngit clone https://github.com/MineDojo/Voyager\ncd Voyager\npip install -e .\n```\n\n## Node.js Install\nIn addition to the Python dependencies, you need to install the following Node.js packages:\n```\ncd voyager/env/mineflayer\nnpm install -g npx\nnpm install\ncd mineflayer-collectblock\nnpx tsc\ncd ..\nnpm install\n```\n\n## Minecraft Instance Install\n\nVoyager depends on Minecraft game. You need to install Minecraft game and set up a Minecraft instance.\n\nFollow the instructions in [Minecraft Login Tutorial](installation/minecraft_instance_install.md) to set up your Minecraft Instance.\n\n## Fabric Mods Install\n\nYou need to install fabric mods to support all the features in Voyager. Remember to use the correct Fabric version of all the mods. \n\nFollow the instructions in [Fabric Mods Install](installation/fabric_mods_install.md) to install the mods.\n\n# Getting Started\nVoyager uses OpenAI's GPT-4 as the language model. You need to have an OpenAI API key to use Voyager. You can get one from [here](https://platform.openai.com/account/api-keys).\n\nAfter the installation process, you can run Voyager by:\n```python\nfrom voyager import Voyager\n\n# You can also use mc_port instead of azure_login, but azure_login is highly recommended\nazure_login = {\n    \"client_id\": \"YOUR_CLIENT_ID\",\n    \"redirect_url\": \"https://127.0.0.1/auth-response\",\n    \"secret_value\": \"[OPTIONAL] YOUR_SECRET_VALUE\",\n    \"version\": \"fabric-loader-0.14.18-1.19\", # the version Voyager is tested on\n}\nopenai_api_key = \"YOUR_API_KEY\"\n\nvoyager = Voyager(\n    azure_login=azure_login,\n    openai_api_key=openai_api_key,\n)\n\n# start lifelong learning\nvoyager.learn()\n```\n\n* If you are running with `Azure Login` for the first time, it will ask you to follow the command line instruction to generate a config file.\n* For `Azure Login`, you also need to select the world and open the world to LAN by yourself. After you run `voyager.learn()` the game will pop up soon, you need to:\n  1. Select `Singleplayer` and press `Create New World`.\n  2. Set Game Mode to `Creative` and Difficulty to `Peaceful`.\n  3. After the world is created, press `Esc` key and press `Open to LAN`.\n  4. Select `Allow cheats: ON` and press `Start LAN World`. You will see the bot join the world soon. \n\n# Resume from a checkpoint during learning\n\nIf you stop the learning process and want to resume from a checkpoint later, you can instantiate Voyager by:\n```python\nfrom voyager import Voyager\n\nvoyager = Voyager(\n    azure_login=azure_login,\n    openai_api_key=openai_api_key,\n    ckpt_dir=\"YOUR_CKPT_DIR\",\n    resume=True,\n)\n```\n\n# Run Voyager for a specific task with a learned skill library\n\nIf you want to run Voyager for a specific task with a learned skill library, you should first pass the skill library directory to Voyager:\n```python\nfrom voyager import Voyager\n\n# First instantiate Voyager with skill_library_dir.\nvoyager = Voyager(\n    azure_login=azure_login,\n    openai_api_key=openai_api_key,\n    skill_library_dir=\"./skill_library/trial1\", # Load a learned skill library.\n    ckpt_dir=\"YOUR_CKPT_DIR\", # Feel free to use a new dir. Do not use the same dir as skill library because new events will still be recorded to ckpt_dir. \n    resume=False, # Do not resume from a skill library because this is not learning.\n)\n```\nThen, you can run task decomposition. Notice: Occasionally, the task decomposition may not be logical. If you notice the printed sub-goals are flawed, you can rerun the decomposition.\n```python\n# Run task decomposition\ntask = \"YOUR TASK\" # e.g. \"Craft a diamond pickaxe\"\nsub_goals = voyager.decompose_task(task=task)\n```\nFinally, you can run the sub-goals with the learned skill library:\n```python\nvoyager.inference(sub_goals=sub_goals)\n```\n\nFor all valid skill libraries, see [Learned Skill Libraries](skill_library/README.md).\n\n# FAQ\nIf you have any questions, please check our [FAQ](FAQ.md) first before opening an issue.\n\n# Paper and Citation\n\nIf you find our work useful, please consider citing us! \n\n```bibtex\n@article{wang2023voyager,\n  title   = {Voyager: An Open-Ended Embodied Agent with Large Language Models},\n  author  = {Guanzhi Wang and Yuqi Xie and Yunfan Jiang and Ajay Mandlekar and Chaowei Xiao and Yuke Zhu and Linxi Fan and Anima Anandkumar},\n  year    = {2023},\n  journal = {arXiv preprint arXiv: Arxiv-2305.16291}\n}\n```\n\nDisclaimer: This project is strictly for research purposes, and not an official product from NVIDIA.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fminedojo%2Fvoyager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fminedojo%2Fvoyager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fminedojo%2Fvoyager/lists"}