Behavioral Foundation Models for Quality Diversity

Nazim Bendib, Nicolas Perrin-Gilbert, Olivier Sigaud

TL;DR

This paper introduces BFM-QD, a framework that performs Quality-Diversity (QD) search within the compact latent space of a Behavioral Foundation Model (BFM) rather than the high-dimensional space of raw policy parameters. By leveraging pretrained behavioral manifolds, BFM-QD discovers diverse, high-performing repertoires of policies with unprecedented efficiency, particularly in sparse-reward and deceptive environments where traditional methods completely fail.

What Problem Does This Paper Address?

Quality-Diversity (QD) algorithms, like MAP-Elites, aim to find a large collection of solutions that are both high-performing and behaviorally diverse. However, they face a fundamental bottleneck: they typically search in the policy parameter space ($\Theta$). This space is massive (often tens of thousands of dimensions) and "unstructured"—randomly perturbing a neural network's weights almost never results in a coordinated, useful behavior.

While recent "Behavioral Foundation Models" (BFMs) can map a compact latent code $z$ to a policy $\pi_z$ capable of zero-shot task solving, they are usually used to extract just one "optimal" behavior. This paper addresses the underexploited potential of these models: can we use the structured, low-dimensional latent space of a BFM as a better "playground" for QD search?

Methods

The authors propose BFM-QD, which relocates the QD search from the parameter space to the BFM's latent space ($Z$).

  1. Latent Space Search: Instead of mutating network weights, the algorithm mutates latent codes $z \in \mathbb{R}^{50}$. These codes are then decoded by a frozen, pretrained BFM into full policies.
  2. Backward Inference (BI) Operator: The authors derive a novel, closed-form variation operator. BFMs (specifically those based on Successor Features) allow one to analytically infer the "optimal" latent code $z^*$ for a given reward function. The BI operator produces offspring by interpolating a parent $z$ toward this global $z^*$.
  3. Gradient-Free Improvement: Mathematically, the BI operator approximates a second-order Newton step on the policy improvement objective. Crucially, it achieves this without training a critic or performing backpropagation, making it highly sample-efficient and robust.
Figure 1: Overview of BFM-QD. A BFM is pretrained once on an offline dataset and then frozen. The loop is one QD generation: latent codes z are sampled from the archive, mutated into z′, and evaluated by rolling out πBFM(·|z′). Offspring update the archive.

Datasets

The framework was evaluated on 18 tasks across four continuous-control environments:

  • Locomotion: Walker2D_uni and HalfCheetah_uni (dense rewards, simple dynamics).
  • Navigation: AntMaze-medium (long-horizon, sparse, and deceptive rewards).
  • Manipulation: Cube-single (contact-rich manipulation with sparse rewards).

Pretraining data for the BFMs was collected using task-agnostic exploration methods like Random Network Distillation (RND).

Key Insights and Ideas

  • Behavioral Richness: Unlike the raw parameter space, the BFM latent space is "behaviorally rich" by construction. Even random latent vectors decode to coordinated, efficient behaviors. This provides a massive head start for QD search.
  • Meaningful Interpolation: In the latent space, linear interpolation between two solutions produces a behaviorally intermediate "offspring." In contrast, interpolating between neural network weights usually results in a broken, incoherent policy.
  • Decoupling Diversity from Precision: A fascinating finding is that QD performance saturates very early in the BFM's pretraining phase—well before the model is capable of high-accuracy zero-shot task solving. This suggests that for QD, the diversity of the latent manifold matters more than its precision.
  • Robustness to Deception: Because the BI operator doesn't rely on an online-trained critic, it doesn't get "tricked" by deceptive reward landscapes that typically cause policy-gradient-based QD methods to collapse.

Key Results

BFM-QD variants consistently outperformed all parameter-space baselines (including CMA-ME and DCRL-ME) across all metrics: coverage, QD-score, and maximum fitness.

  • Hard Tasks: On AntMaze and Cube-single, all parameter-space methods collapsed to near-zero performance. BFM-QD maintained strong behavioral coverage and high fitness.
  • Efficiency: BFM-QD operates in a 50-dimensional space, compared to the ~20,000 dimensions of standard MLP baselines, leading to significantly faster convergence.
  • BI vs. Gradients: The BI operator matched the performance of state-of-the-art policy gradient methods on easy tasks and far surpassed them on hard ones, all while being computationally cheaper.
Figure 2: Normalized QD-score, coverage, and normalized max fitness across all environments. BFM-QD variants consistently match or outperform all baselines, especially on harder tasks.

Limitations and Future Work

  • Hard Ceiling: The BFM is frozen during QD search. This means the discovered behaviors are limited to the "behavioral manifold" captured during offline pretraining. If a necessary behavior wasn't in the pretraining data, BFM-QD cannot find it.
  • Data Dependency: The quality of the search space is directly tied to the diversity of the offline dataset.
  • Future Directions: The authors suggest that fine-tuning the BFM online during the QD run could break the "hard ceiling" and allow the discovery of entirely novel behaviors. Additionally, extending this to environment-agnostic foundation models remains an open challenge.

Summary updated

BibTeX
@inproceedings{bendib2026behavioral,
  author = {Nazim Bendib and Nicolas Perrin-Gilbert and Olivier Sigaud},
  title = {{Behavioral Foundation Models for Quality Diversity}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=yFRrEkCBNX},
}
Figure