Soliciting clarity on notation in an elementary marginalisation identity In Boosting: Foundations and Algorithms by Freund and Schapire (2012), the authors describe the marginalisation identity in probability using the following notation:

Below, $\mathbb{P}_{P}(\cdot)$ and $\mathbb{E}_{P}(\cdot)$ denote probability and expectation over the random choice of $(x, y)$ from $P$, respectively.
The proof uses marginalization, the principle that if $X$ and $Y$ are random variables, then the probability of any event $a$ can be computed as the expected probability of the event when one of the variables is held fixed:
$$\mathbb{P}_{X, Y}(a) = \mathbb{E}_{X}[\mathbb{P}_{Y \, \vert \, X}(a | X)]$$

I'm rather confused by the use of the event $a$ here, and whether it refers to a realisation of $X$, or $Y$, or both $X$ and $Y$. What does the event $a$ refer to? Assuming that $a$ refers to a fixed value of $Y$ then shouldn't the left hand side read $\mathbb{P}_{Y}(a)$ rather than $\mathbb{P}_{X, Y}(a)$?
In the notation of density functions, shouldn't this really be
$$f_{Y}(a) = \int f_{Y \, \vert \, X}(a \vert x) f_{X}(x) \, dx$$
instead of
$$f_{X, Y}(a) = \int f_{Y \, \vert \, X}(a \vert x) f_{X}(x) \, dx?$$

The notation is strange, but I think I see what they're getting at.  Since they use subscripts for both random variables on the function on the left-hand-side, presumably they mean that $a$ can be any event involving both random variables (not just a value of $Y$), and they intend for the left-hand-side to be a probability statement taken with respect to the joint distribution of the random variables.  I would read their statement as an (unusual and clumsy) shorthand for the following:
$$\mathbb{P}(a) = \mathbb{P}((X,Y) \in \mathscr{A}) = \int f_{Y|X}(\mathscr{A}_x|x) \ f_X(x) \ dx,$$
where $a \equiv \{ (X,Y) \in \mathscr{A} \}$ is an event of interest and $\mathscr{A}_x \equiv \{ (X,Y) \in \mathscr{A} | X=x \}$ is the range of values of $Y$ that are compatible with that event when $X=x$.  I could be wrong (maybe they mean something else) but ---without further context--- that is how I would interpret it.
