The duality of the free energy and relative entropy used to deduce deduce the stochastic game between an agent and the market

I am reading the article Pricing via utility maximization and entropy by Richard Rouge and Nicole El Karoui. They talk about the relative entropy of a probability measure $Q$ with respect to the probability measure $P$ defined by $h(Q \vert P) := E[dQ/dP \ln(dQ/dP)]$ if $Q \ll P$, $+\infty$ else. They also talk about the concept of free energy of a random variable $B$, and this is equal to $\ln E[\exp B]$. They claim that for a bounded random variable $B$, entropy and free energy are in relation by the following duality:

\begin{align} \ln E[\exp B] = \sup_{Q \ll P} [ E^{Q}[B] - h(Q \vert P) ] \end{align}

Does anyone know an article that shows the proof? or does anyone know how to deduce this equation?

The interesting feature is that with this formula we can deduce the stochastic game between an agent and the market.