Environment Descriptions for Usability and Generalisation in Reinforcement Learning

Dennis J. N. J. Soemers, Spyridon Samothrakis, Kurt Driessens, Mark H. M. Winands

TL;DR

This paper argues that Reinforcement Learning (RL) is currently bottlenecked by a "heavy engineering" requirement, where environments must be hard-coded in general-purpose languages. The authors propose a research shift toward using user-friendly description languages (DSLs) or natural language to define tasks, which would both democratize RL for non-experts and provide agents with the "rulebooks" they need to achieve true zero-shot generalization.

What Problem Does This Paper Address?

Currently, if you want to apply RL to a new problem, you generally need two things: deep expertise in RL and significant software engineering skills. Environments are typically "bespoke simulators" written in C++, Python, or hardware-accelerated frameworks like JAX/CUDA.

This creates two major hurdles:

  1. Usability Gap: Private individuals and small organizations without engineering teams are effectively locked out of using RL for their specific problems.
  2. The Generalization Wall: Because environments are black-box code, agents have no "understanding" of the task's logic. They only see numerical observations and rewards. This makes it incredibly difficult for an agent to generalize to a new, slightly different task because it cannot "read the rules" of the new environment.

Methods

This is a position paper that outlines a strategic research agenda rather than introducing a single new algorithm. The authors advocate for a workflow where:

  • Users describe problems in a Domain-Specific Language (DSL) (like Ludii for games) or Natural Language.
  • Compilers translate these descriptions into executable simulators.
  • Agents receive the description itself as context.

The paper contrasts the "customary setting" (where the agent is blind to the simulator's code) with a "proposed setting" where the environment description serves as an additional input to the agent, enabling it to reason about the rules of the game or task before taking its first action.

Datasets

While the paper does not introduce a new dataset, it reviews and categorizes existing benchmarks based on how they are defined:

  • Standard Suites: Arcade Learning Environment (Atari), ProcGen, and DeepMind Control Suite (all hard-coded).
  • DSL-based Benchmarks: PDDLGym (planning), Ludii (board games), MiniHack (grid-worlds), and the recently introduced Ludax (a JAX-based compiler for game descriptions).
  • Visual Analysis: The authors use a t-SNE visualization of 1,059 different board games described in the Ludii DSL to demonstrate how a single language can cover a vast, diverse problem space.

Key Insights and Ideas

  • Descriptions as Context: The core "aha moment" is that a task description (like a rulebook) is a form of context. If an agent is trained on a wide enough variety of descriptions, it can learn the semantics of the language, allowing it to perform zero-shot transfer to a brand-new task just by "reading" the description.
  • The Action Space Challenge: The authors point out a subtle technical conflict. Most Deep RL assumes a fixed, known action space. However, in succinct DSLs (like "place a piece on any empty square"), the total number of possible actions might change or be hard to calculate upfront, leading to "action aliasing" issues that current RL architectures aren't built to handle.
  • Democratization via "Prompting": Just as Large Language Models (LLMs) made AI accessible via prompting, the authors envision a future where RL is applied by "prompting" an agent with a description of a physical or virtual optimization problem.

Key Results

As a position paper, the "results" are the identification of critical research desiderata for the community:

  1. User-friendliness: Languages must be accessible to non-programmers.
  2. Completeness: Descriptions must be detailed enough to be compiled into a full simulator.
  3. Computational Efficiency: DSL-based simulators are often slower than hand-coded ones; we need better compilers (like Ludax) to bridge this gap.
  4. Procedural Generation: We should use DSLs to automatically generate thousands of "intermediate" tasks to fill the gaps in training data, helping agents learn the underlying logic of the description language.

Limitations and Future Work

  • The Reliability of LLMs: While natural language is the most user-friendly interface, LLMs currently struggle to generate perfectly executable code or DSL snippets without "hallucinating" rules.
  • Simulation Speed: There is an inherent trade-off between the abstraction of a DSL and the raw speed of hand-optimized C++ code.
  • Future Direction: The authors call for the development of "Foundation Models for RL" that are pre-trained on vast libraries of environment descriptions, enabling them to adapt to new human-described tasks instantly.

Summary updated

BibTeX
@inproceedings{soemers2025environment,
  author = {Dennis J. N. J. Soemers and Spyridon Samothrakis and Kurt Driessens and Mark H. M. Winands},
  title = {{Environment Descriptions for Usability and Generalisation in Reinforcement Learning}},
  booktitle = {ICAART},
  year = {2025},
  doi = {10.5220/0013247300003890},
}
Figure