Reinforcement Learning Friendly Vision-Language Model for Minecraft

Haobin Jiang, Junpeng Yue, Hao Luo, Ziluo Ding, Zongqing Lu

Abstract

Training Reinforcement Learning (RL) agents in open-ended environments like Minecraft is hindered by the complexity of manual reward engineering. While Vision-Language Models (VLMs) like CLIP have been proposed to generate rewards from text prompts, they are often limited by noisy internet-scale training data and a lack of sensitivity to task progress. We present CLIP4MC, a VLM specifically optimized to serve as an intrinsic reward function. By implementing a rigorous "Neat" data-cleaning pipeline and a "Random Swap" training objective based on entity size, CLIP4MC provides granular reward signals that guide agents toward task completion. Experimental results demonstrate significant performance gains, particularly in complex "Hunt" tasks where traditional VLMs fail.

Introduction

In the vast, open-ended world of Minecraft, designing reward functions for every possible task is an intractable problem. Recent research has turned to Vision-Language Models (VLMs) to provide intrinsic rewards by measuring the similarity between an agent's visual observations and a textual task description (e.g., "hunt a cow"). However, existing models like MineCLIP struggle with two primary issues: catastrophic misalignment in YouTube-sourced training data and "coarse" reward signals that do not distinguish between merely seeing an object and successfully interacting with it.

Figure 1: Comparison of irrelevant, mismatched, and matched video-text content found in raw YouTube datasets.

The "Neat" Dataset Pipeline

To address data quality, the researchers developed a four-stage pipeline to refine the MineDojo YouTube database:

  1. Transcript Cleaning: Utilizing OpenAI’s Whisper and FullStop for precise speech-to-text and punctuation.
  2. Keyword Filtering: Isolating clips relevant to specific Minecraft entities (stones, sheep, etc.).
  3. Video Partitioning: Applying Bellman k-segmentation to detect scene cuts and maintain semantic coherence.
  4. Correlation Filtering: Implementing global and local filters to ensure visual-textual alignment.

This process resulted in the CLIP4MC Dataset, a high-quality collection of 640,000 video-text pairs, which has been open-sourced to the research community as a superior alternative to noisier datasets.

RL-Friendly Architecture: The Random Swap Objective

A critical insight of this work is that standard contrastive learning provides a binary-like reward: the agent is rewarded for having the target in view, regardless of distance. To create a "reward gradient," CLIP4MC introduces the Random Swap objective.

The model estimates the bounding box size of target entities within the frame. If a target entity in a positive video clip is too small—indicating the agent is far from the goal—the model occasionally swaps it with a negative sample during training. This forces the model to assign lower similarity scores to distant targets, effectively rewarding the agent for approaching the objective.

Figure 2: CLIP4MC leverages entity size estimation to provide a continuous reward signal based on proximity to the target.

Key Results and Insights

CLIP4MC was evaluated against the official MineCLIP across various programmatic tasks. The results highlight the importance of granular rewards:

  • Superior Hunting Performance: In the "Hunt Chicken" task, CLIP4MC achieved a 26.1% success rate, while the official MineCLIP failed completely (0% success). Across all hunting tasks, CLIP4MC consistently outperformed baselines.
  • Reward Correlation: CLIP4MC’s rewards showed a 0.81 correlation with actual target proximity, a significant improvement over MineCLIP’s 0.62.
  • Data Efficiency: The model demonstrated that high-quality, cleaned data (640K pairs) can outperform models trained on much larger, noisier datasets.

Conclusion

CLIP4MC represents a significant step toward more capable RL agents in complex environments. By focusing on data quality and the spatial dynamics of task completion, the model provides the "RL-friendly" signals necessary for sophisticated interactions. Future work will explore scaling this approach to more abstract and creative tasks where progress is not solely defined by entity proximity.

Summary updated

BibTeX
@inproceedings{jiang2024reinforcement,
  author = {Haobin Jiang and Junpeng Yue and Hao Luo and Ziluo Ding and Zongqing Lu},
  title = {{Reinforcement Learning Friendly Vision-Language Model for Minecraft}},
  booktitle = {European Conference on Computer Vision},
  year = {2024},
  doi = {10.1007/978-3-031-73113-6\_1},
}
Figure