  We consider (annealed) large deviation principles for component empirical
measures of several families of marked sparse random graphs, including (i)
uniform graphs on $n$ vertices with a fixed degree distribution; (ii) uniform
graphs on $n$ vertices with a fixed number of edges; (iii) Erd\H{o}s-R\'enyi
$G(n, c/n)$ random graphs. Assuming that edge and vertex marks are independent,
identically distributed, and take values in a finite state space, we show that
the large deviation rate function admits a concise representation as a sum of
relative entropies that quantify the cost of deviation of a probability measure
on marked rooted graphs from certain auxiliary independent and conditionally
independent versions. The proof exploits unimodularity, the consequent mass
transport principle, and random tree labelings to express certain combinatorial
quantities as expectations with respect to size-biased distributions, and to
identify unimodular extensions with suitable conditional laws. We also
illustrate how this representation can be used to establish Gibbs conditioning
principles that provide insight into the structure of marked random graphs
conditioned on a rare event. Additional motivation for this work arises from
the fact that such a representation is also useful for characterizing the
annealed pressure of statistical physics models with general spins, and large
deviations of evolving interacting particle systems on sparse random graphs.
