Skip to main content
QUICK REVIEW

[Paper Review] You Can't Count on Luck: Why Decision Transformers and RvS Fail in Stochastic Environments

Keiran Paster, Sheila A. McIlraith|arXiv (Cornell University)|May 31, 2022
Reinforcement Learning in RoboticsComputer Science8 citations
TL;DR

This paper identifies a critical failure mode of Decision Transformers and RvS (Reinforcement Learning via Supervised Learning) in stochastic environments, where high returns are achieved by luck rather than optimal behavior. The authors propose ESPER, which conditions on environment-stochasticity-independent representations—specifically, cluster-averaged returns—using adversarial learning to improve alignment between target and actual returns, achieving state-of-the-art performance on stochastic offline RL benchmarks.

ABSTRACT

Recently, methods such as Decision Transformer that reduce reinforcement learning to a prediction task and solve it via supervised learning (RvS) have become popular due to their simplicity, robustness to hyperparameters, and strong overall performance on offline RL tasks. However, simply conditioning a probabilistic model on a desired return and taking the predicted action can fail dramatically in stochastic environments since trajectories that result in a return may have only achieved that return due to luck. In this work, we describe the limitations of RvS approaches in stochastic environments and propose a solution. Rather than simply conditioning on the return of a single trajectory as is standard practice, our proposed method, ESPER, learns to cluster trajectories and conditions on average cluster returns, which are independent from environment stochasticity. Doing so allows ESPER to achieve strong alignment between target return and expected performance in real environments. We demonstrate this in several challenging stochastic offline-RL tasks including the challenging puzzle game 2048, and Connect Four playing against a stochastic opponent. In all tested domains, ESPER achieves significantly better alignment between the target return and achieved return than simply conditioning on returns. ESPER also achieves higher maximum performance than even the value-based baselines.

Motivation & Objective

  • To identify why RvS-style agents like Decision Transformers fail in stochastic environments despite strong performance in deterministic ones.
  • To address the core issue that conditioning on trajectory return conflates optimal behavior with luck in stochastic dynamics.
  • To develop a method that conditions on return estimates independent of environmental stochasticity to ensure reliable policy learning.
  • To validate the approach on new, challenging stochastic offline RL benchmarks where standard RvS fails.
  • To demonstrate that ESPER outperforms both RvS agents and strong value-based baselines like CQL in stochastic settings.

Proposed method

  • ESPER learns a representation of trajectories using adversarial training to disentangle action-dependent statistics from environment-induced stochasticity.
  • It clusters trajectories based on their action sequences and computes the average return for each cluster, using this as the conditioning signal instead of individual trajectory returns.
  • The method employs an adversarial loss to ensure that the learned trajectory representations are invariant to environmental stochasticity.
  • The model is trained to predict actions conditioned on the state and the cluster-averaged return, enabling robust decision-making in stochastic environments.
  • The approach is end-to-end differentiable and scalable, leveraging deep learning architectures without requiring explicit causal inference.
  • It uses a dynamics model to support the adversarial clustering, ensuring that the representations reflect agent-controlled behavior patterns.

Experimental results

Research questions

  • RQ1Why do Decision Transformers and RvS agents fail in stochastic environments despite strong performance in deterministic benchmarks?
  • RQ2Can we identify a conditioning signal for RvS that is independent of environmental stochasticity and thus more reliable for policy learning?
  • RQ3Does conditioning on cluster-averaged returns—estimated from action sequences—improve alignment between target and actual expected returns in stochastic environments?
  • RQ4Can a model conditioned on stochasticity-invariant representations outperform standard RvS and value-based methods in challenging stochastic offline RL tasks?
  • RQ5Is the proposed method robust across diverse stochastic environments, including partially observable and high-variance domains?

Key findings

  • ESPER achieves significantly better alignment between target return and expected performance than return-conditioned RvS agents in stochastic environments.
  • On the 2048 puzzle game and Connect Four against a stochastic opponent, ESPER attains near-maximum performance, outperforming even strong value-based baselines like CQL.
  • In the gambling environment, RvS agents fail catastrophically by favoring suboptimal actions due to luck, while ESPER correctly identifies the optimal action (a2) that guarantees a positive return.
  • The adversarial clustering in ESPER successfully learns representations invariant to environmental stochasticity, enabling reliable policy generalization.
  • Even with infinite data, return-conditioned RvS models fail in stochastic settings, proving that data scale alone cannot resolve the fundamental issue.
  • ESPER demonstrates that conditioning on environment-stochasticity-independent outcomes—such as average returns per action cluster—enables robust and optimal decision-making in real-world stochastic tasks.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.