Vision-Language Models are Zero-Shot Reward Models for Reinforcement Learning

Juan Rocamonde, Victoriano Montesinos, Elvis Nava, Ethan Perez, David Lindner

In the world of Reinforcement Learning (RL), the "reward function" is king. It’s the mathematical signal that tells an agent whether it’s doing a good job. However, designing these functions is a notorious headache: manual engineering is brittle and prone to "reward hacking," while learning from human feedback (RLHF) is prohibitively expensive and slow.

A new paper from researchers at FAR AI, Anthropic, and ETH Zurich, published at ICLR 2024, proposes a surprisingly simple alternative: just ask a pretrained Vision-Language Model (VLM) how well the agent is doing.

TL;DR

This paper demonstrates that pretrained VLMs like CLIP can serve as effective, zero-shot reward models for RL. By simply providing a text prompt (e.g., "a humanoid robot doing the splits"), researchers trained complex robotic behaviors in simulation without writing a single line of manual reward code or collecting human labels.

What Problem Does This Paper Address?

The "reward specification" problem is a major bottleneck in RL. If you want a robot to learn to "sit in a lotus position," how do you write a mathematical equation for that using only joint angles and velocities? Usually, you’d have to spend hours tuning weights or hire humans to rank thousands of videos of the robot trying to sit.

The authors tackle this by leveraging the "common sense" already embedded in large-scale models like CLIP. Since these models have seen millions of captioned images, they already "know" what a kneeling robot or a successful CartPole swing-up looks like. The challenge is turning that static knowledge into a dynamic reward signal that an RL algorithm can actually use to learn.

Methods: The VLM-RM Approach

The core approach, dubbed VLM-RM, uses the cosine similarity between a text prompt and the agent's current visual observation as the reward signal.

  1. Basic VLM-RM: The reward is simply the alignment between the image embedding (from the robot's camera) and the text embedding (the task description).
  2. Goal-Baseline Regularization: To make the signal cleaner, the authors introduced a "baseline" prompt (e.g., "a humanoid robot"). They then project the state embedding onto the vector connecting the baseline to the goal. This helps "cancel out" irrelevant visual information—like the color of the floor or the robot's general shape—focusing the reward strictly on the change required to reach the goal.
  3. Integration: They plugged these rewards into standard RL algorithms like Soft Actor-Critic (SAC) and Deep Q-Networks (DQN), treating the VLM as a "black box" reward generator.

Datasets and Environments

The researchers didn't train the VLMs; they used pretrained CLIP models (ranging from the small ResNet-50 to the massive ViT-bigG-14). They evaluated the method on:

  • Classic Control: CartPole and MountainCar (to validate against known ground-truth rewards).
  • MuJoCo Humanoid: A high-dimensional physics simulation where they tested complex poses: kneeling, standing with raised arms, doing the splits, and sitting in a lotus position.
Humanoid doing the splits
  • Modified Textures: They introduced more realistic textures to the standard MuJoCo environments to see if visual fidelity affected the VLM's performance.

Key Insights and Ideas

  • The Realism Requirement: VLMs are trained on real-world internet data. The authors found that "abstract" simulations (like a grey robot on a plain floor) confuse the models. By simply adding realistic textures (e.g., wood grain, sky backgrounds), the reward signal became significantly more accurate.
  • Scaling is Everything: There is a sharp "phase transition" in performance. Smaller CLIP models failed entirely on complex humanoid tasks, while the largest model (ViT-bigG-14) achieved 100% success. Reward quality appears to scale log-linearly with the number of parameters and training compute.
  • Zero-Shot Works: Unlike previous work that required fine-tuning VLMs on domain-specific data, this method works "out of the box." This suggests that as VLMs continue to improve, our ability to specify RL tasks will improve for free.

Key Results

  • Humanoid Mastery: Using only a single-sentence prompt and the largest CLIP model, the agent achieved a 100% success rate on 5 out of 8 complex tasks (Kneeling, Lotus position, Standing up, Arms raised, and Doing splits).
Humanoid in lotus position
  • Correlation: In classic control tasks, the VLM-generated rewards showed a high correlation with the actual ground-truth reward functions, proving they capture the underlying physics of the task.
  • Regularization Benefit: The "Goal-Baseline Regularization" was particularly helpful for smaller models, effectively acting as a "denoiser" for the reward signal.

Limitations and Future Work

Despite the success, the authors noted several "failure modes" tied to current VLM limitations:

  • Spatial Reasoning: CLIP struggles with fine-grained spatial relationships (e.g., "left arm vs. right arm") and subtle differences in body pose (e.g., "arms crossed" vs. "hands on hips").
  • Environment Distribution: If the simulation looks too "fake," the VLM fails. This limits the method to environments that can be rendered with some degree of photorealism.
  • Static vs. Dynamic: Currently, the model looks at individual frames. Future work could involve using Video-Language Models to specify tasks that require motion over time, like "doing a backflip" or "walking with a limp."

By turning natural language into a dense reward signal, this research moves us closer to a world where training a robot is as simple as describing what you want it to do.

Paper Citation: Rocamonde, J., Montesinos, V., Nava, E., Perez, E., & Lindner, D. (2024). Vision-Language Models are Zero-Shot Reward Models for Reinforcement Learning. ICLR 2024. Project Website

Summary updated

BibTeX
@inproceedings{rocamonde2024vision,
  author = {Juan Rocamonde and Victoriano Montesinos and Elvis Nava and Ethan Perez and David Lindner},
  title = {{Vision-Language Models are Zero-Shot Reward Models for Reinforcement Learning}},
  booktitle = {International Conference on Learning Representations},
  year = {2024},
  url = {https://openreview.net/forum?id=N0I2RtD8je},
}
Figure