LLMs for Generalizable Language-Conditioned Policy Learning under Minimal Data Requirements

Thomas Pouplin, Katarzyna Kobalczyk, Hao Sun, Mihaela van der Schaar

Abstract

Training autonomous agents to follow natural language instructions typically requires massive human-labeled datasets or extensive online trial-and-error. This paper presents TEDUO (Teaching the Environment Dynamics from Unlabeled Observations), a novel pipeline that enables the learning of generalizable, language-conditioned policies from unlabeled, sub-optimal offline data. By leveraging Large Language Models (LLMs) as both data enhancers and generalizers, TEDUO bridges the gap between raw environment dynamics and high-level linguistic reasoning.

Introduction

In the real world, data is often "low-fidelity"—recordings of agents performing tasks without explicit goal labels or success indicators. Traditional Reinforcement Learning (RL) struggles with such unlabeled data, while out-of-the-box LLMs lack the necessary grounding in specific environment physics to execute tasks reliably. TEDUO addresses this by using LLMs to automatically label and simplify environment data, which is then used to fine-tune a base LLM into a grounded, generalizable agent.

Methodology: The TEDUO Pipeline

The TEDUO framework consists of three distinct stages designed to transform messy, unlabeled observations into a robust policy.

The TEDUO pipeline: from unlabeled data to a generalizable language-conditioned policy.

1. LLMs as Data Enhancers

First, the system performs Hindsight Labeling. A prompted LLM examines state transitions to determine if they satisfy specific natural language goals. To scale this process, a smaller proxy neural network is trained to mimic the LLM's labeling logic.

Simultaneously, the system employs State Abstraction. The LLM strips away irrelevant environmental details (e.g., floor color) to generate a simplified textual representation focused solely on goal-relevant features. This drastically reduces the state space complexity for the subsequent RL phase.

LLM-based state abstraction: converting raw environment states into goal-relevant features.

2. Offline Policy Learning

Using the newly labeled and abstracted data, standard offline RL algorithms (such as Tabular Q-learning or DQN) are applied to identify optimal actions for a finite set of training goals. This step extracts the "ground truth" dynamics of the environment.

3. LLMs as Generalizers

Finally, the optimal trajectories discovered in the RL phase are used to fine-tune a base LLM (e.g., Llama-3-8B) via Supervised Fine-Tuning (SFT). This process "grounds" the LLM’s pre-existing linguistic knowledge in the environment's specific rules, allowing it to generalize to novel instructions and unseen states through compositional reasoning.

Experimental Evaluation

TEDUO was evaluated on two benchmarks: BabyAI, a complex grid-world requiring navigation and object manipulation, and Webshop, a simulated e-commerce environment requiring multi-step search and selection tasks.

Key Results

  • Superior Generalization: On BabyAI, TEDUO achieved a 65% success rate on training tasks, significantly outperforming a vanilla Llama-3-8B (17%). Crucially, on novel goals, TEDUO maintained a 45% success rate, while the standard RL baseline (BabyAI-IL-bot) fell to 16%.
  • Efficiency through Abstraction: LLM-driven state abstraction reduced the relevant feature space by 80%, enabling the RL component to converge much faster than on raw state inputs.
  • Zero-Shot Skill Transfer: In environments requiring the combination of previously separate skills (e.g., combining "picking up" and "opening" in a new context), TEDUO achieved a 60% success rate, whereas agents without LLM-based distillation failed entirely.

Discussion and Future Work

The core insight of TEDUO is that grounding is the missing link for LLM-based agents. Fine-tuning on a small amount of environment-specific data unlocks the LLM's latent ability to compose "atomic" skills into complex behaviors.

However, limitations remain. The current framework relies on textual environment representations, which may necessitate Vision-Language Models (VLMs) for high-dimensional visual tasks. Additionally, extending TEDUO from discrete actions to continuous control for robotics and automating the discovery of "plausible goals" from raw data are key areas for future research.

Summary updated

BibTeX
@inproceedings{pouplin2025llms,
  author = {Thomas Pouplin and Katarzyna Kobalczyk and Hao Sun and Mihaela van der Schaar},
  title = {{LLMs for Generalizable Language-Conditioned Policy Learning under Minimal Data Requirements}},
  booktitle = {International Conference on Machine Learning},
  year = {2025},
  url = {https://openreview.net/forum?id=5hyfZ2jYfI},
}
Figure