  Calculating thermodynamic potentials and observables efficiently and
accurately is key for the application of statistical mechanics simulations to
materials science. However, naive Monte Carlo approaches, on which such
calculations are often dependent, struggle to scale to complex materials in
many state-of-the-art disciplines such as the design of high entropy alloys or
multicomponent catalysts. To address this issue, we adapt sampling tools built
upon machine-learning based generative modeling to the materials space by
transforming them into the semi-grand canonical ensemble. Furthermore, we show
that the resulting models are transferable across wide-ranges of thermodynamic
conditions and can be implemented with any internal energy model U, allowing
integration into many existing materials workflows. We demonstrate the
applicability of this approach to the simulation of benchmark systems (AgPd,
CuAu) that exhibit diverse thermodynamic behavior in their phase diagrams.
Finally, we discuss remaining challenges in model development and promising
research directions for future improvements.
