  We study $BV$ functions in a Hilbert space $X$ endowed with a probability
measure $\nu$, assuming that $\nu$ is Fomin differentiable along suitable
directions. We establish basic characterizations, and we apply the general
theory to relevant examples, including invariant measures of some stochastic
PDEs.
