From the E-step to optimization
The topic EM and Bayesian PCA split the log-likelihood into a lower bound and a gap, and its E-step closed the gap by setting . That step quietly assumed we can write the exact posterior over the latent variables. Often we cannot. A non-conjugate piece or a coupling between latent variables is enough to make the normalizing integral intractable. And once the parameters get priors too, they join the unknowns, and a posterior over everything at once is rarely available in closed form.
Variational inference keeps the decomposition and gives up exactness. Let now stand for all unknowns: latent variables and parameters alike. For any distribution ,
The left side does not depend on . So raising the ELBO lowers the KL to the posterior by exactly the same amount. We pick a variational family of distributions we can handle and solve
An integral we cannot take becomes an optimization we can run. If happens to contain the true posterior, the optimum is the posterior itself, and we are back at the exact E-step of EM.
All of this is useful only if can be evaluated while the posterior cannot. Read its definition once more with that question in mind; the check below asks exactly this.
If some parameters stay point estimates, we can alternate: a variational E-step over , then an M-step over . This is variational EM. Each step raises the ELBO, but unlike exact EM the log-likelihood itself is no longer guaranteed to grow.