[proofplan]
Fix a measurable point $x$ with positive treatment event $\{X=x\}$ and fix a measurable outcome set $A$. The consistency assumption gives equality of $Y$ and $Y_x$ outside a null subset of the conditioning event. Therefore the two outcome events $\{Y\in A\}$ and $\{Y_x\in A\}$ have the same intersection with $\{X=x\}$ up to a null set. The definition of [conditional probability](/page/Conditional%20Probability) given a positive-probability event then gives the desired equality after division by $\mathbb P(X=x)$.
[/proofplan]
[step:Reduce consistency to equality of the two conditioned outcome events]
Fix $x\in\mathcal X$ such that $\{x\}\in\mathcal E$ and $\mathbb P(X=x)>0$, and fix $A\in\mathcal G$. Define the conditioning event
\begin{align*}
B:=X^{-1}(\{x\})=\{\omega\in\Omega:X(\omega)=x\}.
\end{align*}
Since $X$ is $(\mathcal F,\mathcal E)$-measurable and $\{x\}\in\mathcal E$, one has $B\in\mathcal F$.
Define the observed-outcome event
\begin{align*}
E:=Y^{-1}(A)=\{\omega\in\Omega:Y(\omega)\in A\},
\end{align*}
and define the potential-outcome event
\begin{align*}
E_x:=Y_x^{-1}(A)=\{\omega\in\Omega:Y_x(\omega)\in A\}.
\end{align*}
Since $Y$ and $Y_x$ are $(\mathcal F,\mathcal G)$-measurable and $A\in\mathcal G$, both $E$ and $E_x$ belong to $\mathcal F$.
By consistency on $B$, there exists $N_x\in\mathcal F$ with $\mathbb P(N_x)=0$ such that $Y(\omega)=Y_x(\omega)$ for every $\omega\in B\setminus N_x$. Hence, for every $\omega\in B\setminus N_x$,
\begin{align*}
\omega\in E \iff \omega\in E_x.
\end{align*}
Therefore
\begin{align*}
(B\cap E)\triangle(B\cap E_x)\subset N_x.
\end{align*}
Since $N_x$ is null, the two events $B\cap E$ and $B\cap E_x$ have equal probability:
\begin{align*}
\mathbb P(B\cap E)=\mathbb P(B\cap E_x).
\end{align*}
[guided]
We first isolate the event on which we are conditioning. Define
\begin{align*}
B:=X^{-1}(\{x\})=\{\omega\in\Omega:X(\omega)=x\}.
\end{align*}
This is an event because the singleton $\{x\}$ is assumed to lie in $\mathcal E$ and $X:(\Omega,\mathcal F)\to(\mathcal X,\mathcal E)$ is measurable. The positivity assumption says $\mathbb P(B)>0$.
Next define the two outcome events whose conditional probabilities we want to compare:
\begin{align*}
E:=Y^{-1}(A)=\{\omega\in\Omega:Y(\omega)\in A\},
\end{align*}
and
\begin{align*}
E_x:=Y_x^{-1}(A)=\{\omega\in\Omega:Y_x(\omega)\in A\}.
\end{align*}
Both are elements of $\mathcal F$ because $A\in\mathcal G$ and both $Y$ and $Y_x$ are random variables from $(\Omega,\mathcal F)$ to $(\mathcal Y,\mathcal G)$.
The consistency assumption is used only on the conditioning event $B$. It gives an event $N_x\in\mathcal F$ with $\mathbb P(N_x)=0$ such that
\begin{align*}
Y(\omega)=Y_x(\omega)
\end{align*}
for every $\omega\in B\setminus N_x$. For such an $\omega$, membership in $A$ is the same for $Y(\omega)$ and $Y_x(\omega)$, so
\begin{align*}
\omega\in E \iff \omega\in E_x.
\end{align*}
Thus the only points where $B\cap E$ and $B\cap E_x$ can differ lie inside the null event $N_x$:
\begin{align*}
(B\cap E)\triangle(B\cap E_x)\subset N_x.
\end{align*}
Since a subset of a null event has probability zero, the two measurable events $B\cap E$ and $B\cap E_x$ have the same probability:
\begin{align*}
\mathbb P(B\cap E)=\mathbb P(B\cap E_x).
\end{align*}
[/guided]
[/step]
[step:Divide by the positive probability of the conditioning event]
By the definition of conditional probability given the positive-probability event $B$,
\begin{align*}
\mathbb P(Y\in A\mid X=x)=\frac{\mathbb P(B\cap E)}{\mathbb P(B)}.
\end{align*}
Similarly,
\begin{align*}
\mathbb P(Y_x\in A\mid X=x)=\frac{\mathbb P(B\cap E_x)}{\mathbb P(B)}.
\end{align*}
The denominator is positive by hypothesis, and the numerators are equal by the previous step. Therefore
\begin{align*}
\mathbb P(Y\in A\mid X=x)=\mathbb P(Y_x\in A\mid X=x).
\end{align*}
This proves the asserted equality for the fixed admissible $x$ and fixed $A\in\mathcal G$, and hence for all such $x$ and $A$.
[/step]