Assume $X_1, X_2, \ldots$ are i.i.d. random variables from $\Omega$ to $\mathbb{R}$. $Y$ is another random variable that is independent from the $X_i$. Does it hold that, almost surely
$$\frac{1}{N} \sum_{i=1}^N f(Y, X_i) \to \mathbb{E}[f(Y, X_1) | Y].$$ For a specific value $y$, we have that by the law of large numbers
$$\frac{1}{N} \sum_{i=1}^N f(y, X_i) \to \mathbb{E}_{X_1}[f(y, X_1)]$$
almost surely. But since there are uncountably many values $y$ that $Y$ can take, this is not enough. I can assume that $f$ is sufficiently nice.