---
title: Hybrid-Balance GFlowNet (HBG) Overview
url: https://www.emergentmind.com/topics/hybrid-balance-gflownet-hbg
type: topic
---

# Hybrid-Balance GFlowNet (HBG) Overview

Searching arXiv for the cited HBG-related papers to ground the article in current records.
arxiv_search.query{"search_query":"id:2301.12594 OR id:2209.12782 OR id:2510.04792 OR id:2602.01749","max_results":10}
arxiv_search.search{"query":"id:2301.12594 OR id:2209.12782 OR id:2510.04792 OR id:2602.01749","max_results":10}
arxiv.search{"query":"2301.12594 2209.12782 2510.04792 2602.01749","max_results":10}
Hybrid-Balance GFlowNet (HBG) denotes a class of Generative Flow Network formulations in which distinct balance mechanisms are combined, reweighted, or made explicit in order to preserve reward-proportional sampling while improving credit assignment, extending the state space, or controlling exploration and exploitation. In explicit nomenclature, HBG is a framework for vehicle routing that integrates Trajectory Balance (TB) and Detailed Balance (DB) in a single training and inference scheme [2510.04792]. In generalized continuous-state GFlowNet theory, the same expression naturally refers to TB or DB instantiated on hybrid discrete–continuous spaces with Radon–Nikodym derivatives and change-of-variables corrections [2301.12594]. Related literature also maps the idea of “hybrid balance” to $\lambda$-weighted mixtures of subtrajectory constraints and to $\alpha$-weighted forward/backward mixing, although those papers do not explicitly introduce the HBG name [2209.12782] [2602.01749]. Taken together, these works suggest that HBG is best understood not as a single universally fixed objective, but as a family of balance constructions that hybridize local and global consistency, discrete and continuous transitions, or forward and backward dynamics.

## 1. Scope, nomenclature, and canonical GFlowNet setting

A GFlowNet learns a forward policy $P_F$ over a constructive process so that terminal objects $x$ are sampled proportionally to a nonnegative reward $R(x)$. In the DAG formulation, a trajectory $\tau=(s_0,\ldots,s_T=x)$ satisfies
$$
P_F(\tau)=\prod_{t=0}^{T-1} P_F(s_{t+1}\mid s_t),
$$
and the target condition is
$$
R(x)=Z\sum_{\tau:s_T=x} P_F(\tau),
$$
with $Z=\sum_{x\in X}R(x)$ at optimum [2209.12782]. In the combinatorial optimization formulation used for vehicle routing problems, a state $s$ encodes a partial construction, an action appends the next node subject to feasibility, the backward policy $P_B$ reverses a forward step, the flow $F(s)$ is a scalar learned on each state, and the partition function $Z$ is the source flow at $s_0$ [2510.04792].

Within this general setting, the expression “Hybrid-Balance GFlowNet” has multiple technical uses. The vehicle-routing formulation introduces HBG as a training and inference framework that “uniquely integrates TB and DB in a principled and adaptive manner” and augments AGFN and GFACS [2510.04792]. The continuous-state theory describes HBG as the trajectory-balance objective specialized to hybrid spaces, where continuous corrections must be made explicit when a policy is parameterized through actions and deterministic transformations [2301.12594]. The SubTB($\lambda$) work states that it does not explicitly introduce or name HBG, but characterizes SubTB($\lambda$) as embodying a hybrid-balance principle because it blends local and trajectory-wide training signals through a $\lambda$-weighted mixture of subtrajectories [2209.12782]. The $\alpha$-GFN work likewise states that it does not use the term HBG explicitly, but presents a tunable hybridization of forward and backward components through
$$
P_\alpha=\alpha P_F+(1-\alpha)P_B,
$$
which is interpreted there as a hybrid-balance construction [2602.01749].

## 2. Balance laws from which HBG is constructed

The central ingredients of HBG are the standard GFlowNet balance objectives. For a complete trajectory $\tau=(s_0\to\cdots\to s_T=x)$, TB imposes
$$
\log Z + \sum_{t=0}^{T-1} \log P_F(s_{t+1}\!\mid s_t) - \sum_{t=0}^{T-1} \log P_B(s_t\!\mid s_{t+1}) = \log R(x),
$$
or equivalently
$$
\frac{Z\, \prod_{t=0}^{T-1} P_F(s_t \!\to s_{t+1})}{\prod_{t=0}^{T-1} P_B(s_{t+1} \!\to s_t)} = R(x).
$$
DB instead enforces local edge constraints,
$$
F(s)\, P_F(t|s) = F(t)\, P_B(s|t),
$$
with terminal condition $F(x)=R(x)$. FM imposes local conservation of edge flows,
$$
\sum_{u:(u\to s)\in A} F(u\to s) = \sum_{v:(s\to v)\in A} F(s\to v),
\qquad
\sum_{u:(u\to x)\in A} F(u\to x) = R(x),
$$
and uses the induced forward policy
$$
P_F(t|s)=\frac{F(s\to t)}{\sum_v F(s\to v)}.
$$
These objectives were originally contrasted as trajectory-wide, transition-wise, and state-local constraints [2209.12782].

In measurable-state GFlowNet theory, the same ideas are expressed with measures and kernels. A flow is a pair $F=(\mu,P_F)$ with $\mu\ll \nu$ and $P_F(s,\cdot)\ll \kappa(s,\cdot)$, while the backward kernel satisfies $P_B(s',\cdot)\ll \kappa^b(s',\cdot)$. The resulting Radon–Nikodym derivatives
$$
u(s)=\frac{d\mu}{d\nu}(s),\qquad
p_F(s,s')=\frac{dP_F(s,\cdot)}{d\kappa(s,\cdot)}(s'),\qquad
p_B(s',s)=\frac{dP_B(s',\cdot)}{d\kappa^b(s',\cdot)}(s)
$$
unify discrete probabilities and continuous densities [2301.12594]. In this generalized formulation, HBG is obtained by instantiating TB or DB in hybrid spaces and, when actions rather than state kernels are parameterized directly, by inserting the correct Radon–Nikodym or Jacobian terms.

A recurrent theme across these balance laws is the local–global tradeoff. DB and FM yield low-variance but biased training signals because credit is assigned locally, whereas TB yields low-bias global credit assignment but higher variance because it propagates reward over full trajectories [2209.12782]. HBG variants differ in where they intervene in this tradeoff: some make continuous corrections explicit, some interpolate across subtrajectory lengths, and some directly sum local and global losses.

## 3. HBG in hybrid discrete–continuous state spaces

The generalized continuous-state theory models a hybrid state space through a measurable pointed graph
$$
G = (\bar S, \tau, \Sigma, s_0, \perp, \kappa, \kappa^b, \nu)
$$
with distinguished source $s_0$ and sink $\perp$. A hybrid state space can be instantiated as
$$
\bar S = \{s_0\} \sqcup S \sqcup \{\perp\},
\qquad
S=S_d\times S_c,
$$
where $S_d$ is countable or finite and $S_c$ is a manifold or Euclidean subset; $\Sigma$ is the Borel $\sigma$-algebra induced by the disjoint union topology; and the reference measure is naturally chosen as counting measure on $S_d \otimes$ Lebesgue measure on $S_c$, plus Dirac masses at $s_0$ and $\perp$ [2301.12594].

The measure-theoretic FM condition is
$$
\int f(s')\,\mu(ds') = \iint f(s')\,\mu(ds)\,P_F(s,ds'),
$$
for bounded measurable $f$ with $f(s_0)=0$. In density form this becomes
$$
u(s') = \int u(s)\, p_F(s,s')\, \kappa^b(s',ds),
$$
$\nu$-almost surely on $S$. Terminal balance is expressed by reward matching,
$$
R(dx)=\mu(dx)P_F(x,\{\perp\}),
$$
or, in densities,
$$
r(x)=u(x)p_F(x,\perp),
$$
$\nu$-almost surely on $X$ [2301.12594]. The paper’s correctness theorem states that if FM and reward matching hold with respect to a positive finite $R\ll \nu$, then the terminating measure $P_{\mathrm{top}}$ is a probability measure and
$$
P_{\mathrm{top}}(B)=\frac{R(B)}{R(X)}
$$
for all measurable $B\subseteq X$.

The distinctive HBG issue arises when the forward policy is parameterized in an action space
$$
A(s)=A_d(s)\sqcup A_c(s)
$$
and then pushed forward to next states through a deterministic or stochastic mechanism $T(s,a)$. In that case the induced state-transition density must include the continuous correction
$$
p_F(s_t,s_{t+1})=\pi_A(a_t|s_t)\, C_t(s_t,a_t,s_{t+1}),
$$
where
$$
C_t(s_t,a_t,s_{t+1})
=
\frac{d\big((T_t)_{s_t\#}[Q_{A_t}(\cdot|s_t)]\big)}{d\kappa(s_t,\cdot)}(s_{t+1}).
$$
For diffeomorphic continuous maps with Lebesgue reference measure, this simplifies to
$$
C_t = |\det J_{T_t}(a_t)|^{-1},
$$
whereas for discrete branches $C_t=1$ on the corresponding atom of $\kappa(s_t,\cdot)$ [2301.12594].

The hybrid trajectory-balance equality for
$$
\tau=(s_0,a_0,s_1,\ldots,a_{T-1},s_T=x,s_{T+1}=\perp)
$$
is
$$
\log Z
+
\sum_{t=0}^{T-1}\big[\log \pi_A(a_t|s_t)+\log C_t\big]
-
\sum_{t=0}^{T-1}\log \pi_B(b_t|s_{t+1})
=
\log R(x),
$$
with loss
$$
L_{\mathrm{HBG}}(\tau)
=
\left(
\log Z
+
\sum_{t=0}^{T-1}\big[\log \pi_A(a_t|s_t)+\log C_t\big]
-
\sum_{t=0}^{T-1}\log \pi_B(b_t|s_{t+1})
-
\log R(x)
\right)^2.
$$
When one works directly in state space with $p_F(s,s')\equiv dP_F/d\kappa$, the correction $C_t$ is already included in $p_F$, and HBG reduces to the standard TB loss. The practical significance is narrow but important: HBG is useful precisely when the policy is modeled in action space and one must translate it to the state-space kernel correctly.

## 4. HBG as interpolation between local and trajectory-wide credit assignment

Subtrajectory Balance introduces a different kind of hybridization. For any contiguous subtrajectory
$$
\tau_{i:j}=(s_i\to s_{i+1}\to \cdots \to s_j),
$$
the paper shows that DB is equivalent to the subtrajectory constraint
$$
F(s_m)\prod_{i=m}^{n-1} P_F(s_{i+1}|s_i)
=
F(s_n)\prod_{i=m}^{n-1} P_B(s_i|s_{i+1}),
$$
with $F(x)=R(x)$ if $s_n$ is terminal. The associated loss is
$$
\mathcal{L}(\tau)=
\left(
\log
\frac{F(s_m)\prod_{i=m}^{n-1}P_F(s_{i+1}|s_i)}
{F(s_n)\prod_{i=m}^{n-1}P_B(s_i|s_{i+1})}
\right)^2.
$$
SubTB($\lambda$) then aggregates subtrajectory losses as
$$
\mathcal{L}_{\mathrm{SubTB}(\lambda)}(\tau)=
\frac{\sum_{0\le i<j\le n}\lambda^{\,j-i}\,\mathcal{L}(\tau_{i:j})}
{\sum_{0\le i<j\le n}\lambda^{\,j-i}},
$$
where $\lambda>0$ weighs by subtrajectory length [2209.12782].

The limiting cases recover the two standard extremes. As $\lambda\to 0^+$, only 1-step subtrajectories contribute, matching the average DB loss over edges. As $\lambda\to +\infty$, the longest subtrajectory dominates, recovering TB. At $\lambda=1$, all subtrajectories receive uniform weight. The gradient can be computed with one forward and one backward pass through the networks for $\log F$, $\log P_F$, and $\log P_B$; $O(n^2)$ linear operations combine logits across subtrajectories, while deep network evaluation remains $O(n)$.

The paper does not explicitly introduce or name HBG, but it states that SubTB($\lambda$) “embodies the hybrid-balance principle by blending local (edge/state) and trajectory-wide training signals through a $\lambda$-weighted mixture of subtrajectories” [2209.12782]. That interpretation is supported by the empirical bias–variance analysis: DB has the highest self-consistency and lowest variance, TB the lowest self-consistency and highest variance, and SubTB($\lambda$) lies in between. On hypergrid tasks, SubTB($\lambda=0.9$) converges faster and with less variability across seeds than TB, and in the very sparse setting with background reward $10^{-4}$, TB fails to discover all modes beyond $8\times 8$, whereas SubTB($\lambda$) still finds all and matches the target distribution well. On AMP, SubTB($\lambda$) attains reward $0.96\pm 0.02$ and diversity $42.23\pm 3.4$, compared with TB at $0.90\pm 0.03$ and $31.42\pm 2.9$; on GFP, SubTB($\lambda$) reaches reward $1.18\pm 0.10$ with diversity $204.44\pm 0.45$, while TB reaches $0.76\pm 0.19$ with diversity $204.31\pm 0.44$ [2209.12782]. These results place HBG, in this interpretive sense, within the broader program of balancing gradient bias and variance rather than merely combining two named losses.

## 5. Explicit HBG for vehicle routing problems

The 2025 vehicle-routing paper introduces Hybrid-Balance GFlowNet as a solver framework for CVRP and TSP. Its stated premise is that TB is well aligned with the global objective of minimizing total tour length but yields diffuse credit assignment in long-horizon VRPs, whereas DB produces strong local feedback but lacks a global perspective. HBG therefore combines the two in a single objective,
$$
\mathcal{L}_{\mathrm{HBG}}(\mathcal{T};\theta)
=
\sum_{\tau\in\mathcal{T}}
\big[
\mathcal{L}_{\mathrm{TB}}(\tau;\theta)+\mathcal{L}_{\mathrm{DB}}(\tau;\theta)
\big],
$$
and also studies a weighted variant
$$
\mathcal{L}_{\mathrm{HBG}}^{(\lambda)}(\mathcal{T};\theta)
=
\sum_{\tau\in\mathcal{T}}
\big[
\mathcal{L}_{\mathrm{TB}}(\tau;\theta)+\lambda\,\mathcal{L}_{\mathrm{DB}}(\tau;\theta)
\big].
$$
Empirically, a fixed $\lambda=1$ achieves a favorable balance across CVRP and TSP in AGFN and GFACS [2510.04792].

The TB component uses the solver-specific shaped reward $\widetilde{R}$:
$$
\mathcal{L}_{\mathrm{TB}}(\mathcal{T};\theta)
=
\frac{1}{h}\sum_{k=1}^{h}
\left(
\log \frac{Z(\theta)\,P_F(\tau_k;\theta)}
{\widetilde{R}(\tau_k)\,P_B(\tau_k)}
\right)^2.
$$
The DB component is defined stepwise:
$$
\mathcal{L}_{\mathrm{DB}}(s_t,s_{t+1};\theta)
=
\left(
\log
\frac{
P_f(s_{t+1}|s_t;\theta)\,F(s_t;\theta)\,\exp\big(\tilde{\mathcal{E}}(s_{t+1})\big)
}{
P_b(s_t|s_{t+1})\,F(s_{t+1};\theta)\,\exp\big(\tilde{\mathcal{E}}(s_t)\big)
}
\right)^2,
$$
with trajectory loss $\mathcal{L}_{\mathrm{DB}}(\tau;\theta)=\sum_{t=0}^{T-1}\mathcal{L}_{\mathrm{DB}}(s_t,s_{t+1};\theta)$. The local energy term is
$$
\tilde{\mathcal{E}}(s_t)=R(s_t)-\frac{1}{h}\sum_{k=1}^{h}R(s_t^{(k)}),
$$
where $R(s_t)$ is the local transition cost, namely the distance of the last edge in $s_t$.

The framework also specifies VRP-specific backward probabilities. At trajectory level, if $\tau$ contains a multi-route decomposition with multi-node sub-route count $a$ and single-node sub-route count $j$, then
$$
P_B(\tau)=\frac{1}{(a+j)!\cdot 2^a}.
$$
At the step level,
$$
P_b(s_t|s_{t+1})=
\begin{cases}
\frac{1}{2a+j}, & \text{if } s_{t+1}\text{ is the depot state;}\\[4pt]
1, & \text{otherwise.}
\end{cases}
$$
The learned flow head is
$$
F(s_t;\theta)=\frac{1}{t}\sum_{x_k\in s_t}\big(W_2\cdot \mathrm{ReLU}(W_1\cdot q_k+b_1)+b_2\big).
$$

A further distinctive feature is depot-centric inference for CVRP:
$$
x_{t+1}=
\begin{cases}
\text{sample }x\sim P_f(\cdot|s_t;\theta), & \text{if } x_t \text{ is depot;}\\
\arg\max_x P_f(x|s_t;\theta), & \text{if } x_t \text{ is a customer.}
\end{cases}
$$
Feasibility is enforced by masking unvisited customers whose demand exceeds the remaining capacity, and depot return is forced when no feasible unvisited customer remains. This asymmetry is motivated by the observation that only the depot has multiple valid predecessors in the backward dynamics.

The reported results are consistently favorable. On synthetic CVRP, AGFN improves from gap $11.48\%$ to $9.95\%$ at $n=200$, from $12.21\%$ to $10.44\%$ at $n=500$, and from $11.15\%$ to $9.34\%$ at $n=1000$ when HBG is added. GFACS improves from $23.11\%$ to $16.48\%$, from $23.83\%$ to $13.53\%$, and from $23.82\%$ to $10.61\%$ at the same sizes; with local search, the corresponding improvements are smaller but still present, for example $3.00\%$ to $2.75\%$ at $n=1000$. On TSP, AGFN improves from $19.71\%$ to $18.47\%$ at $n=1000$, and GFACS improves from $84.57\%$ to $75.93\%$. Runtime overhead is reported as negligible, with AGFN adding $0.01$–$0.04$s and GFACS remaining unchanged within measurement precision. Ablations show that DB-only is worse than TB and HBG, and that fixed $\lambda=1$ yields the most stable improvements across CVRP and TSP [2510.04792].

## 6. Markov-chain reinterpretation and $\alpha$-hybridization

A different formalization of HBG emerges from the Markov-chain perspective on GFlowNets. The $\alpha$-GFN paper shows that standard GFlowNet objectives correspond to reversibility of the equally mixed kernel
$$
P_{0.5}=\tfrac{1}{2}P_F+\tfrac{1}{2}P_B,
$$
and generalizes this to
$$
P_\alpha=\alpha P_F+(1-\alpha)P_B,\qquad \alpha\in(0,1).
$$
The one-step reversibility relation is
$$
\pi(s)\,P(s'|s)=\pi(s')\,P(s|s'),
$$
and the flows act as an unnormalized probability measure through
$$
Z_{\mathrm{state}}=\sum_{s\in S}F(s),\qquad
\pi(s)=\frac{F(s)}{Z_{\mathrm{state}}}.
$$
For a partial trajectory segment $\mathfrak{t}'=(s_k,\ldots,s_{k+m})$, the $\alpha$-SubTB target is
$$
\alpha^{m}F(s_k)\prod_{i=1}^{m}P_F(s_{k+i}|s_{k+i-1})
=
(1-\alpha)^{m}F(s_{k+m})\prod_{i=1}^{m}P_B(s_{k+i-1}|s_{k+i}),
$$
with analogous $\alpha$-DB, $\alpha$-TB, and forward-looking variants [2602.01749].

The paper states that these $\alpha$-objectives are equivalent to reversibility of the Markov chain with kernel $P_\alpha$, and that their convergence to unique flows is similar to vanilla objectives for all $\alpha\in(0,1)$. The conditions used include finite state space, a pointed DAG with source and sink, irreducibility and positive recurrence of the induced Markov chain, and positive rewards on terminal states so that $P_B(x|s_f)$ is well defined.

The practical role of $\alpha$ is to control exploration and exploitation. For $\alpha$-SubTB, the gradient-level characterization is
$$
\frac{\partial L_{\alpha\text{-SubTB}(\mathfrak{t}')}}{\partial P_F(\mathfrak{t}')}
=
\frac{\partial L_{\text{SubTB}(\mathfrak{t}')}}{\partial P_F(\mathfrak{t}')}
+
\frac{2m}{P_F(\mathfrak{t}')}\log\frac{\alpha}{1-\alpha}.
$$
For $\alpha>0.5$, the added term is positive and larger when $P_F(\mathfrak{t}')$ is small, pushing low-probability paths down faster and sharpening mass around high-reward trajectories; for $\alpha<0.5$, it is negative and promotes exploration. The paper recommends a two-stage schedule in which $\alpha$ is first held away from $0.5$ and then exponentially annealed back toward $0.5$:
$$
f(\alpha_0,n,N_1,N)=0.5+(\alpha_0-0.5)\exp\!\Big(-4\cdot\frac{n-N_1}{N-N_1}\Big).
$$

The paper explicitly notes that it does not use the term HBG, but in the supplied interpretation HBG corresponds to this $\alpha$-weighted hybridization of forward and backward components [2602.01749]. The empirical effect is substantial: across Set, Bit Sequence, and Molecule Generation, $\alpha$-GFN objectives are reported to outperform previous GFlowNet objectives, with up to a $10\times$ increase in the number of discovered modes. The conceptual significance is that hybrid balance can be framed not only as combining local and global constraints, but also as changing the reversible mixture that underlies those constraints.

## 7. Practical guidance, limitations, and recurrent misconceptions

A recurrent misconception is that HBG denotes a single standardized loss. The available literature does not support that claim. One paper explicitly names HBG for VRP and defines it as $\mathcal{L}_{\mathrm{TB}}+\mathcal{L}_{\mathrm{DB}}$ plus a depot-centric inference rule [2510.04792]. Another uses the term for hybrid discrete–continuous TB with explicit Radon–Nikodym corrections [2301.12594]. The SubTB($\lambda$) and $\alpha$-GFN papers both state that they do not explicitly use the HBG name, although they can be interpreted as hybrid-balance constructions [2209.12782] [2602.01749]. This suggests that HBG is an umbrella description for several non-identical balance hybridizations.

A second misconception is that hybridization merely means summing losses. In continuous or mixed spaces, the central issue may instead be measure-theoretic correctness. The continuous-state theory explicitly warns not to replace integrals over states by actions without Radon–Nikodym corrections, and emphasizes that support mismatch or ill-conditioned Jacobians can lead to biased or unstable training [2301.12594]. In this setting, HBG should be used when the forward policy is parameterized in an action space with deterministic hybrid maps to states; if the model works directly in state space through $P_F$ densities with respect to $\kappa$, then standard TB, DB, or FM already include the proper correction and are simpler to implement.

A third misconception is that stronger local balance is always sufficient. The VRP results contradict that view: DB-only is worse than TB and worse than the combined HBG objective, with gaps up to $22.72\%$ for AGFN and $54.36\%$ for GFACS at $n=200$ in the cited ablations [2510.04792]. Conversely, purely global TB can exhibit diffuse credit assignment on long-horizon problems, which is why SubTB($\lambda$) and the VRP HBG framework both introduce intermediate or additive local structure [2209.12782] [2510.04792].

The main practical limitations are likewise heterogeneous. In the generalized theory, correctness relies on finitely absorbing structure, accessibility, absolute continuity of kernels, and existence of the backward reference kernel $\kappa^b$; trajectory length and Jacobian conditioning directly affect memory and numerical stability [2301.12594]. In SubTB($\lambda$), the $O(n^2)$ enumeration of subtrajectories adds overhead in linear operations, and choosing $\lambda$ too close to the TB or DB extremes can reintroduce high variance or high bias; the paper reports that fixed $\lambda$ near $0.8$–$1.0$ is a strong default and that truncation to short subtrajectories can still work well [2209.12782]. In the VRP formulation, $\lambda=1$ is the most stable setting in the reported experiments, but benefits still depend on the underlying solver, and depot-centric inference is structurally most advantageous for depot problems such as CVRP rather than TSP [2510.04792]. In $\alpha$-GFNs, fixed extreme $\alpha$ can reduce reward fitting, so annealing back to $0.5$ is recommended unless a persistent exploration or exploitation bias is explicitly desired [2602.01749].

Within these constraints, the unifying principle remains stable across the literature: HBG refers to a GFlowNet construction in which balance is hybridized so that reward-proportional terminal sampling is preserved or approximated while the model gains a more useful training signal, a more general state space, or a more controllable exploration–exploitation profile.

Source: https://www.emergentmind.com/topics/hybrid-balance-gflownet-hbg