How to correctly identify d-separation in directed graphical model (DGM)? Pardon me for the newbie question, I'm new in Bayesian network.
I'm reading Chapter 10, Directed Graphical Models (Bayes nets), of Kevin Murphy's textbook: Machine Learning, a Probabilistic Perspective.
Some discussion about using Bayes ball algorithm to test if d-separation holds between two nodes X, Y (or two sets of nodes X, Y) is not clear to me. 
For example, the first figure below indicates that node X and node Z are not d-separated.
However, the rule corresponding to the boundary case (second figure below) suggests that the path between nodes x and z is blocked.

So, my question is, if X in the first figure is observed, are Y and Z d-separated then (since the case will be reduced to the second figure)?
 A: The answer is NO. If $Y$ is not observed, $X$ and $Z$ are not d-separated. The ball can simply pass through $Y$ and reach to $Z$. 
Note that the second figure does not mean that the path between nodes $x$ and $z$ is blocked. It means that if $z$ is an unobserved leaf, the ball cannot pass through $z$, that is the ball cannot bounce back to $x$. It is defined to ensure that if none of the descendants of a v-structure is observed, the ball does not bounce back.
A: You can also try the Moralized Ancestral Graph.

Let X, Y, and Z be variables in a graph. We say X is d-separated from
Y given Z if X and Y are separated in the moralized ancestral graph.
This graph is constructed by first removing the descendants of X, Y,
Z. Then we convert the edges to undirected edges and add edges between
nodes which have a common child in the original graph, but no edge
between them.

Source: https://www.cs.cmu.edu/~epxing/Class/10708-17/notes-17/10708-scribe-lecture2.pdf
In your case,

We first remove the descendants of X, Y, Z and get:

Then we convert the edges to undirected edges and obtain:

Then we add edges between nodes which have a common child in the original graph, but no edges between them(v-structure) and get:

We see that Y and Z are connected, and hence they are not d-separated.
