  In this paper we derive a Large Deviation Principle (LDP) for inhomogeneous
U/V-statistics of a general order. Using this, we derive a LDP for two types of
statistics: random multilinear forms, and number of monochromatic copies of a
subgraph. We show that the corresponding rate functions in these cases can be
expressed as a variational problem over a suitable space of functions. We use
the tools developed to study Gibbs measures with the corresponding
Hamiltonians, which include tensor generalizations of both Ising (with
non-compact base measure) and Potts models. For these Gibbs measures, we
establish scaling limits of log normalizing constants, and weak laws in terms
of weak* topology, which are of possible independent interest.
