Abstract
Generative Flow Networks (GFlowNets) sample objects with probability proportional to a reward function, a task known as reward matching. While GFlowNets resemble reinforcement learning (RL), a direct theoretical link to standard RL has been missing. This paper establishes that GFlowNets are equivalent to policy evaluation of a uniform policy under a specific "rectification" of rewards. We introduce Rectified Policy Evaluation (RPE), an algorithm that achieves reward matching using standard RL building blocks, demonstrating competitive performance across several benchmarks.
Introduction: Bridging the Gap in Sequential Decision-Making
Sequential decision-making is typically divided into two paradigms: Reinforcement Learning (RL), which seeks to maximize cumulative reward, and Generative Flow Networks (GFlowNets), which aim to sample diverse solutions proportional to their rewards. GFlowNets are particularly valuable in scientific domains like drug discovery, where finding multiple high-quality candidates is more important than finding a single global optimum.
Despite their similarities, GFlowNets have often been viewed as a distinct "black box" compared to standard RL. While connections to Maximum Entropy (MaxEnt) RL exist, the link to the most fundamental RL operation—policy evaluation—remained unexplored. This paper demystifies GFlowNets by showing they are actually built on one of the most basic building blocks of RL: policy evaluation.
Methods: Rectified Random Policy Evaluation (RPE)
The core contribution is the discovery that GFlowNet "flow" functions ($F(s)$) are mathematically equivalent to the Value Function ($V(s)$) of a fixed, uniform random policy, provided the rewards are transformed correctly.
The Theoretical Connection
In a tree-structured MDP, the flow into a state is the sum of rewards of all reachable terminal states. The authors prove that by scaling rewards by a "branching ratio" ($g$-function), standard policy evaluation yields values that match GFlowNet flows.
The RPE Algorithm
The resulting algorithm, Rectified Random Policy Evaluation (RPE), simplifies GFlowNet training:
- Sampling: Trajectories are sampled using a fixed uniform random policy.
- Rectification: A scaling factor (the $g$-function) is calculated based on the environment's branching structure (e.g., the product of available actions in a tree).
- Evaluation: Standard policy evaluation is performed using these rectified rewards to estimate the value function.
Because RPE evaluates a fixed policy, it avoids the non-stationarity issues common in RL and GFlowNets, where the policy being evaluated changes during training.
Key Results and Benchmarks
The authors evaluated RPE on standard GFlowNet benchmarks, including DNA sequence generation (TF Bind), RNA sequence design, and molecule generation (QM9).
Performance and Diversity
RPE demonstrated exceptional accuracy and diversity compared to established GFlowNet baselines like Flow Matching (FM) and Trajectory Balance (TB). In RNA generation tasks, RPE achieved nearly 100% accuracy in matching the target distribution, whereas baselines ranged from 66% to 88%.
In the QM9 molecule generation task, RPE discovered high-reward modes more efficiently than traditional methods. The stability of evaluating a fixed policy allowed RPE to find more unique high-quality solutions (modes) than its counterparts.
Discussion and Limitations
The primary insight is that sophisticated reward-matching behavior can be achieved through the most basic RL operation. However, the current formulation of RPE relies on a path-invariance assumption: the branching ratio must be consistent regardless of the path taken to a state. While this holds for compositional tasks like building sequences or molecules, it may fail in environments with irregular boundaries.
Future research will focus on extending RPE to non-uniform policies and developing adaptive methods for environments where path-invariance is violated. This work opens a new bridge between RL and GFlowNets, suggesting that many "generative" tasks can be solved using the robust, well-understood tools of standard reinforcement learning.
Summary updated