  We introduce efficient algorithms for approximate sampling from symmetric
Gibbs distributions on the sparse random (hyper)graph. The examples we consider
include (but are not restricted to) important distributions on spin systems and
spin-glasses such as the q state antiferromagnetic Potts model for $q\geq 2$,
including the colourings, the uniform distributions over the Not-All-Equal
solutions of random k-CNF formulas. Finally, we present an algorithm for
sampling from the spin-glass distribution called the k-spin model. To our
knowledge this is the first, rigorously analysed, efficient algorithm for
spin-glasses which operates in a non trivial range of the parameters.
  Our approach builds on the one that was introduced in [Efthymiou: SODA 2012].
For a symmetric Gibbs distribution $\mu$ on a random (hyper)graph whose
parameters are within an certain range, our algorithm has the following
properties: with probability $1-o(1)$ over the input instances, it generates a
configuration which is distributed within total variation distance
$n^{-\Omega(1)}$ from $\mu$. The time complexity is $O((n\log n)^2)$.
  The algorithm requires a range of the parameters which, for the graph case,
coincide with the tree-uniqueness region, parametrised w.r.t. the expected
degree d. For the hypergraph case, where uniqueness is less restrictive, we go
beyond uniqueness. Our approach utilises in a novel way the notion of
contiguity between Gibbs distributions and the so-called teacher-student model.
