Re: Official Review of Submission1828 by Reviewer 5MSL (1)
We thank the reviewer for the feedback.
> As pointed below, some of the explanations of the key ideas in the paper are not very clear. On page 4, below eq (5), the statement "true posterior distribution of action is biased towards the data collection policy" is not that straightforward from eq (5), could you add more explanations?
The Decision Transformer's approach to offline RL includes the training of an action distribution conditioned the return, thereby allowing for the sampling of an action at the time of inference by providing the projected return (return-to-go). Given that the return is the result of present and downstream actions, the distribution of action that a model tries to learn can be reframed as an action's posterior distribution, as is presented in equation (5). Note that equation (5) outlines the data distribution, which should be distinguished from the neural network model $p_{\psi}(a_{k,t} | R_{k,t}, o_{k,t}, H_{k,t})$. As noted in equation (5), the action's distribution is proportionate to the return's distribution, and this is subsequently weighted by the probability of action from the data collection policy. As it is the posterior distribution derived by the Bayes rule, we denote it as the “true” action posterior distribution.
To put this intuitively, if a model can accurately match equation (5), it will result in the action distribution being skewed towards the data collection policy. For instance, in a pre-recorded sequence, should an action be randomly selected with extremely low probability from the data collection policy, yet yield a high return, the subsequent action distribution in equation (5) would attribute a minute probability to the relevant action, given the high return. Despite the observation of a high return following the action, which would suggest a high probability of $p(R_{k,t}| a_{k,t}, o_{k,t}, H_{k,t})$, the resulting probability of action is weighted by the probability of action in the data collection policy, $\pi_k(a_{k,t}|o_{k,t})$, resulting in a small value. Therefore, even though (5) is the true posterior distribution of action, it is not the desirable action distribution for our model.
Ideally, the action distribution, as demonstrated in equation (6), should be proportional only to the return's distribution and would be unaffected by the data collection policy. With such a distribution, the undesired devaluation due to the data collection policy would be eliminated, thereby resolving the mentioned issue.
> Between eq.(7) and eq.(8), maybe the author could provide some details on the importance sampling trick they mentioned.
As explained in the previous answer, we would like to learn an action distribution in (6) instead of the action distribution in (5). However, since (5) is the true action distribution of data, the common maximum likelihood training objective will let the model match the action distribution in (5).
To let the model learn the action distribution in (6) instead, we first state the desirable training objective as if the data follow the distribution (6):
$$L_{\psi} = \sum_{k,t} \int \hat{p}(R_{k,t}, a_{k,t} |o_{k,t}, H_{k,t}) \log p_{\psi}(a_{k,t} | R_{k,t}, o_{k,t}, H_{k,t}) dR_{k,t} d a_{k,t}$$
Then, we apply the importance sampling trick to introduce the true action posterior in the equation:
$$L_{\psi} = \sum_{k,t} \int\hat{p}(R_{k,t} |o_{k,t}, H_{k,t}) \Big( \int p(a_{k,t} |R_{k,t}, o_{k,t}, H_{k,t}) \frac{\hat{p}(a_{k,t} |R_{k,t}, o_{k,t}, H_{k,t})}{p(a_{k,t} |R_{k,t}, o_{k,t}, H_{k,t})} \log p_{\psi}(a_{k,t} | R_{k,t}, o_{k,t}, H_{k,t}) d a_{k,t} \Big) dR_{k,t}$$
After some rearrangement of the equation, we get a much clearer formulation of the objective (the detailed steps can be found in appendix):
$$\sum_{k,t} \int p(R_{k,t}, a_{k,t} | o_{k,t}, H_{k,t}) \frac{\mathcal{U}(a_{k,t})}{\pi_k(a_{k,t}|o_{k,t})} \log p_{\psi}(a_{k,t} | R_{k,t}, o_{k,t}, H_{k,t}) d a_{k,t} dR_{k,t}$$
Note the probability distribution in front is now the joint distribution of return and action in the data distribution. We apply the Monte Carlo approximation to the integral by considering the recorded data are samples from the data distribution. We get the proposed training objective.
$$ \sum_{k,t} \frac{\mathcal{U}(a_{k,t})}{\pi_k(a_{k,t}|o_{k,t})} \log p_{\psi}(a_{k,t} | R_{k,t}, o_{k,t}, H_{k,t}), \quad R_{k,t}, a_{k,t} \sim p(R_{k,t}, a_{k,t} | o_{k,t}, H_{k,t}) $$