The second term is 0, since we cannot proceed from W to X if W has not terminated. In the second term, we can expand the joint probability into its component conditional probabilities:

$$\propto\sum_{W}[\Pr\left(m\,s g|W_{t},d o n\,e(\,W,t\,+\,1\,),X_{t\,+\,1}\,,{\mathcal{E}}\,\right)$$ $$\cdot\,\Pr\left(X_{t\,+\,1}\,|\,W_{t},\,d o n\,e(\,W,t\,+\,1\,),{\mathcal{E}}\,\right)$$
$$\cdot\operatorname*{Pr}(W_{t},d o n\,e(W,t+1)|{\mathcal{E}}\,)]$$

We assume that the probability of sending a message and the distribution over plan transitions obey a Markov property, so that they are independent of the plan history before time t, given the current plan at time t. Thus, the first two conditional probabilities are independent of our previous history of observations. The third is exactly our previous belief that W is blocked:

$$\propto\sum_{W}[\Pr\left(m\,sg|W_{t},d o n\,e(W,t+1),X_{t+1}\right)\Pr\left(X_{t+1}|W_{t},d o n e(W,t+1)\right)$$ $$\cdot\,b_{t}(W,bloc\,k)]$$

The first two conditional probabilities are exactly our parameters, µ and π:

$$\propto\sum_{W}\mu_{w x}\pi_{w x}b_{t}(W,\,b l o c k)$$
$$\left(\,1\,\right)$$

Lines 4–5 of Algorithm 1 perform exactly the derived summation of Equation 1 (the normalization step is carried out on line 9 (see below). A similar procedure is followed when a message is observed indicating the termination of X (lines 6–8). In such a case, we know that the agent was executing X in the previous time step but that it has moved on to some successor. Thus, for each of X's potential successor plans Y, we set our belief in Y to be proportional to a transition probability, similar to that for the initiation message:

$$\operatorname*{Pr}\left(Y_{t+1}|m\,s g,{\mathcal{E}}\,\right)={\frac{\operatorname*{Pr}\left(m\right)}{\operatorname*{Pr}}}$$

Pr (m sg, Y t +1 | E )

## Pr(M Sg[E)

The denominator is again a normalization factor that we ignore. We can expand the numerator over possible states of X's execution:

$$\begin{array}{l}{{\propto\operatorname*{Pr}\left(m\,s g,Y_{t+1},X_{t},d o n e(X,t+1)|{\mathcal{E}}\right)}}\\ {{\quad+\operatorname*{Pr}\left(m s g,Y_{t+1},\neg X_{t},d o n e(X,t+1)|{\mathcal{E}}\right)}}\\ {{\quad+\operatorname*{Pr}\left(m s g,Y_{t+1},X_{t},\neg d o n\,e(X,t+1)|{\mathcal{E}}\right)}}\\ {{\quad+\operatorname*{Pr}\left(m s g,Y_{t+1},\neg X_{t},\neg d o n\,e(X,t+1)|{\mathcal{E}}\right)}}\end{array}$$
