SlowGuess/NeurIPS_2023_OCR huggingface dataset:
Haoxuan Li $^{1}$ , Kunhan Wu $^{2}$ , Chunyuan Zheng $^{3}$ , Yanghao Xiao $^{4}$ , Hao Wang $^{5}$ , Zhi Geng $^{6}$ , Fuli Feng $^{7}$ , Xiangnan He $^{7}$ , Peng Wu $^{6,*}$
$^{1}$ Peking University  $^{2}$ Carnegie Mellon University  $^{3}$ University of California, San Diego  $^{4}$ University of Chinese Academy of Sciences  $^{5}$ Zhejiang University
$^{6}$ Beijing Technology and Business University  $^{7}$ University of Science and Technology of China
In recommender systems, the collected data used for training is always subject to selection bias, which poses a great challenge for unbiased learning. Previous studies proposed various debiasing methods based on observed user and item features, but ignored the effect of hidden confounding. To address this problem, recent works suggest the use of sensitivity analysis for worst-case control of the unknown true propensity, but only valid when the true propensity is near to the nominal propensity within a finite bound. In this paper, we first perform theoretical analysis to reveal the possible failure of previous approaches, including propensity-based, multi-task learning, and bi-level optimization methods, in achieving unbiased learning when hidden confounding is present. Then, we propose a unified multi-task learning approach to remove hidden confounding, which uses a few unbiased ratings to calibrate the learned nominal propensities and nominal error imputations from biased data. We conduct extensive experiments on three publicly available benchmark datasets containing a fully exposed large-scale industrial dataset, validating the effectiveness of the proposed methods in removing hidden confounding.
Recommender systems (RS) play a key role in information retrieval by filtering out items that may be of interest to users [16, 24]. In general, the training process of recommendation uses historical user interaction data. However, a challenge in using interactions to make predictions is selection bias [3, 32, 40, 57], i.e., users always choose preferred items to interact [5, 51], resulting in a difference in the distribution between data with and without interactions [14, 45-49, 54, 56, 60], which poses a great challenge for unbiased evaluation and learning of the prediction models.
Many methods have been proposed to tackle the selection bias problem, such as the error imputation-based (EIB) [2], inverse propensity scoring (IPS) [33, 41, 42], and doubly robust (DR) methods [7, 11, 27-29, 52]. Based on these, recent works further incorporate multi-task learning to alleviate the data sparsity issue, such as entire space multi-task model (ESMM) [34], multi-task IPS and multi-task DR (Multi-IPS and Multi-DR) [59], and entire space counterfactual multi-task models (ESCM²) [44].
However, these studies only consider the selection bias induced by measured confounders, but ignore the presence of hidden (or unmeasured) confounders, which considerably influences the application of these advanced methods in real-world recommendation scenarios. Hidden confounders are ubiquitous and inevitable in RS due to information limitations (e.g., friend useful suggestions) or privacy restrictions (e.g., user salary) [8, 31, 35, 50]. In this paper, we perform theoretical analysis
*Corresponding author: pengwu@btbu.edu.cn.
for the existing propensity-based and multi-task learning methods, showing that all of them will lead to biased evaluation and learning in the presence of hidden confounding.
To remove hidden confounding, previous causal inference literature suggested the use of instrumental variables [12] or front door adjustment [36]. However, in real-world application scenarios, these approaches require strong assumptions that are difficult to verify in practice. On the other hand, a recent recommendation study proposed robust deconfounder (RD) to adopt sensitivity analysis using a min-max optimization for worst-case control of the unknown true propensity [8]. Nevertheless, they assume the true propensity is near to the nominal one within a bound, which is decided by the strength of the unmeasured confounder, posing another challenge in case these assumptions are violated.
In contrast, unbiased datasets are regarded as the gold standard for unbiased evaluations and can be collected from A/B tests or randomized controlled trials [10, 13, 21, 55]. This provides an alternative solution to remove hidden confounding [15, 20, 26, 58]. Nevertheless, training recommendation models directly on unbiased datasets can suffer from severe overfitting due to the limited sample size restricted by the collection cost of random exposure [4]. Despite few works leverage the unbiased data to combat selection bias [4, 53] by adopting the bi-level optimization, this paper shows that they still lead to biased learning, due to the biased hypothesis space of the prediction model.
To tackle the above problems, we propose a unified multi-task learning approach to remove hidden confounding by leveraging a few unbiased ratings. Interestingly, we show that the unbiased data can help calibrate the learned nominal propensities and nominal error imputations, which differs from RD using sensitivity analysis for nominal propensities only [8]. Specifically, the proposed multi-task learning builds residual networks for learned propensities and imputed errors from biased data, respectively. Next, a consistency loss of IPS (or DR) estimation on the biased dataset and empirical average prediction errors on the unbiased dataset are developed to help the training of the two residual networks, for calibrating the learned nominal propensities and nominal error imputations, respectively. The prediction model is then trained with the calibrated IPS (or calibrated DR) loss and unbiased data to achieve unbiased learning in the presence of hidden confounding.
- We theoretically reveal limitations of the existing multi-task learning and bi-level optimization methods for achieving the unbiasedness in the presence of hidden confounding.
- We provide a unified multi-task learning approach to remove hidden confounding by combining a few unbiased ratings, in which the learned nominal propensities and nominal error imputations can be calibrated by the residual networks with the proposed consistency loss.
- We conduct extensive experiments on three publicly available benchmark datasets, including a large-scale industrial dataset, to validate the effectiveness of the proposed methods.
We formulate the selection bias in RS using post-click conversion rate (pCVR) prediction task for illustration purpose, which can be naturally generalized to other recommendation tasks with explicit feedback, e.g., rating prediction. Suppose that the entire space has  $m$  users and  $n$  items, let  $\mathcal{D}$  be the set of all user-item pairs. Denote  $\mathbf{R} \in \{0,1\}^{m \times n}$  as the true post-click conversion label matrix of user-item pairs, where each entry  $r_{u,i}$  indicates whether a conversion occurs after user  $u$  clicks on item  $i$ . Let  $x_{u,i}$  be the feature of user-item pair  $(u,i)$ , and  $\hat{\mathbf{R}} \in \mathbb{R}^{m \times n}$  be the prediction matrix for pCVR, where  $\hat{r}_{u,i} = f(x_{u,i},\theta_{\mathrm{CVR}}) \in [0,1]$  is the predicted pCVR obtained by a model  $f$  with parameter  $\theta_{\mathrm{CVR}}$ . In RS, users always select the preferred items to click on, leading to a significant difference in the distribution between clicked and unclicked events thus causing selection bias.
If  $\mathbf{R}$  is fully observed, then a pCVR model  $f(x_{u,i};\theta_{\mathrm{CVR}})$  can be trained by minimizing the ideal loss
$$
\mathcal {L} _ {\mathrm {i d e a l}} (\theta_ {\mathrm {C V R}}) = \frac {1}{| \mathcal {D} |} \sum_ {(u, i) \in \mathcal {D}} \delta_ {u, i},
$$
where  $\delta_{u,i} \triangleq \delta(r_{u,i}, \hat{r}_{u,i})$  and  $\delta(\cdot, \cdot)$  is a pre-specified loss, e.g., the cross-entropy loss,  $\delta(r_{u,i}, \hat{r}_{u,i}) = -r_{u,i} \log \hat{r}_{u,i} - (1 - r_{u,i}) \log (1 - \hat{r}_{u,i})$ . However, the post-click conversion feedback of a user-item pair  $(u,i)$  can be observed only when user  $u$  clicks on item  $i$ , making the ideal loss not computable. Let  $o_{u,i}$  be the indicator of user  $u$  clicking on item  $i$ , and  $\mathcal{B} = \{(u,i) \mid (u,i) \in \mathcal{D}, o_{u,i} = 1\}$  be
the set of clicked events, where  $\mathcal{B}$  means that the clicked events is a biased sample of the entire space  $\mathcal{D}$ . In this paper, we further consider the presence of hidden confounding. Without loss of generality, we assume that all confounders consist of a measured part  $x_{u,i}$  and a hidden (unmeasured) part  $h_{u,i}$ , where the latter arises from issues such as information limitations (e.g., friend suggestions) and privacy restrictions (e.g., user salary), which cannot be observed explicitly and used for training.
3 Previous Methods Lead to Biased Learning under Hidden Confounding
The pCVR prediction task is closely related to click-through rate (CTR) and post-view click-through & conversion rate (CTCVR) prediction tasks, as the formula CTCVR = CTR * pCVR holds, where the CTR is  $p_{u,i} \triangleq \mathbb{P}(o_{u,i} = 1|x_{u,i})$ , also known as propensity score in the causal inference literature, represents the probability of a user  $u$  clicking on an item  $i$ . The CTCVR is  $\mathbb{P}(r_{u,i} = 1,o_{u,i} = 1|x_{u,i})$ , means the probability that item  $i$  is clicked and converted by user  $u$ .
Let  $\hat{p}_{u,i} \triangleq \hat{p}_{u,i}(x_{u,i},\theta_{\mathrm{CTR}})$  be CTR prediction model with parameter  $\theta_{\mathrm{CTR}}$ . The ESMM method [34] learns pCVR by joint-training CTR and CTCVR losses
$$
\mathcal {L} _ {\mathrm {C T R}} \left(\theta_ {\mathrm {C T R}}\right) = \frac {1}{| \mathcal {D} |} \sum_ {(u, i) \in \mathcal {D}} \delta \left(o _ {u, i}, \hat {p} _ {u, i}\right), \quad \mathcal {L} _ {\mathrm {C T C V R}} \left(\theta_ {\mathrm {C T R}}, \theta_ {\mathrm {C V R}}\right) = \frac {1}{| \mathcal {D} |} \sum_ {(u, i) \in \mathcal {D}} \delta \left(o _ {u, i} r _ {u, i}, \hat {p} _ {u, i} \hat {r} _ {u, i}\right).
$$
However, the ESMM loss  $\mathcal{L}_{\mathrm{CTR}}(\theta_{\mathrm{CTR}}) + \mathcal{L}_{\mathrm{CTCVR}}(\theta_{\mathrm{CTR}},\theta_{\mathrm{CVR}})$  is a biased estimator of the ideal loss [59]. To achieve unbiased learning, the MTL-IPS and MTL-DR methods [59] use the losses
$$
\mathcal {L} _ {\mathrm {I P S}} \left(\theta_ {\mathrm {C T R}}, \theta_ {\mathrm {C V R}}\right) = \frac {1}{| \mathcal {D} |} \sum_ {(u, i) \in \mathcal {D}} \frac {o _ {u , i} \delta_ {u , i}}{\hat {p} _ {u , i}}, \mathcal {L} _ {\mathrm {D R}} \left(\theta_ {\mathrm {C T R}}, \theta_ {\mathrm {C V R}}, \theta_ {\mathrm {I M P}}\right) = \frac {1}{| \mathcal {D} |} \sum_ {(u, i) \in \mathcal {D}} \left[ \hat {\delta} _ {u, i} + \frac {o _ {u , i} \left(\delta_ {u , i} - \hat {\delta} _ {u , i}\right)}{\hat {p} _ {u , i}} \right],
$$
where  $\hat{\delta}_{u,i} \triangleq \hat{\delta}_{u,i}(x_{u,i},\theta_{\mathrm{IMP}})$  is the imputation model that predicts  $\delta_{u,i}$  using  $x_{u,i}$ , i.e., it estimates  $g_{u,i} \triangleq \mathbb{E}[\delta_{u,i}|x_{u,i}]$ . Without hidden confounders,  $\mathcal{L}_{\mathrm{IPS}}$  is an unbiased estimator of the ideal loss when the learned propensities are accurate, i.e.,  $\hat{p}_{u,i} = p_{u,i}$  [41, 42], and  $\mathcal{L}_{\mathrm{DR}}$  is unbiased if either  $\hat{p}_{u,i} = p_{u,i}$  or  $\hat{\delta}_{u,i} = g_{u,i}$  [39, 52]. However, both IPS and DR are biased under hidden confounders.
Lemma 1 (Theorem 3.1 in [8]). In the presence of hidden confounders  $h_{u,i}$ , both  $\mathcal{L}_{IPS}$  and  $\mathcal{L}_{DR}$  are biased estimators of the ideal loss, even if  $\hat{p}_{u,i} = p_{u,i}$  and  $\hat{\delta}_{u,i} = g_{u,i}$ .
The above result also holds in the follow-up DR studies [23, 25, 43], and can be naturally extended to conclude that the MTL-IPS and MTL-DR [59] are biased under hidden confounding. Recently,  $\mathrm{ESCM}^2$ -IPS and  $\mathrm{ESCM}^2$ -DR showed state-of-the-art performance in pCVR prediction by incorporating the ESMM loss  $\mathcal{L}_{\mathrm{CTCVR}}$  as the global risk of CTCVR, and MTL-IPS and MTL-DR losses  $\mathcal{L}_{\mathrm{CVR}}^{\mathcal{B}}$  as counterfactual risk of pCVR [44]. Formally, the  $\mathrm{ESCM}^2$  loss is
$$
\mathcal {L} _ {\mathrm {E S C M} ^ {2}} = \mathcal {L} _ {\mathrm {C T R}} + \lambda_ {1} \mathcal {L} _ {\mathrm {I M P}} + \lambda_ {2} \mathcal {L} _ {\mathrm {C V R}} ^ {\mathcal {B}} + \lambda_ {3} \mathcal {L} _ {\mathrm {C T C V R}},
$$
where  $\lambda_{t}$  for  $t = 1,2,3$  are hyper-parameters,  $\mathcal{L}_{\mathrm{CVR}}^{\mathcal{B}}$  is either  $\mathcal{L}_{\mathrm{IPS}}$  or  $\mathcal{L}_{\mathrm{DR}}$ . The imputation loss is
$$
\mathcal {L} _ {\mathrm {I M P}} \left(\theta_ {\mathrm {C T R}}, \theta_ {\mathrm {C V R}}, \theta_ {\mathrm {I M P}}\right) = \frac {1}{| \mathcal {B} |} \sum_ {(u, i) \in \mathcal {B}} \frac {\left(\delta_ {u , i} - \hat {\delta} _ {u , i}\right) ^ {2}}{\hat {p} _ {u , i}}.
$$
However, since both  $\mathcal{L}_{\mathrm{CTCVR}}$  and  $\mathcal{L}_{\mathrm{CVR}}^B$  are biased under hidden confounding,  $\mathrm{ESCM}^2$  is also biased.
3.2 Debiasing with a Few Unbiased Ratings
Instead of only using the biased dataset  $\mathcal{B}$ , many methods are proposed to improve the debiasing performance by combining a small unbiased dataset  $\mathcal{U}$  and a large biased dataset  $\mathcal{B}$ , such as bilevel optimization approaches, including learning to debias (LTD) [53] and AutoDebias [4], causal embedding method (CausE) [1], knowledge distillation framework for counterfactual recommendation via uniform data (KDCRec) [30, 32], and causal balancing methods [26].
Specifically, learning to debias (LTD) [53] and AutoDebias [4] adopt bi-level optimization [17, 37] to learn a CTR model  $\hat{p}_{u,i}(x_{u,i},\theta_{\mathrm{CTR}})$  such that the pCVR prediction model  $\hat{r}_{u,i} = f(x_{u,i},\theta_{\mathrm{CVR}})$  performs well on the small unbiased dataset  $\mathcal{U}$ . Formally, the bi-level optimization in LTD is
$$
\theta_ {\mathrm {C T R}} ^ {*} = \arg \min  _ {\theta_ {\mathrm {C T R}}} \mathcal {L} _ {\mathrm {C V R}} ^ {\mathcal {U}} \left(\theta_ {\mathrm {C V R}} ^ {*} \left(\theta_ {\mathrm {C T R}}\right)\right),
$$
$$
\text {s . t .} \theta_ {\mathrm {C V R}} ^ {*} (\theta_ {\mathrm {C T R}}) = \arg \min  _ {\theta_ {\mathrm {C V R}}} \mathcal {L} _ {\mathrm {C V R}} ^ {\mathcal {B}} (\theta_ {\mathrm {C T R}}, \theta_ {\mathrm {C V R}}),
$$
where the upper loss is as an average of prediction errors on the unbiased dataset
$$
\mathcal {L} _ {\mathrm {C V R}} ^ {\mathcal {U}} \left(\theta_ {\mathrm {C V R}} ^ {*} \left(\theta_ {\mathrm {C T R}}\right)\right) = \frac {1}{| \mathcal {U} |} \sum_ {(u, i) \in \mathcal {U}} \delta \left(r _ {u, i}, \hat {r} _ {u, i} \left(\theta_ {\mathrm {C V R}} ^ {*} \left(\theta_ {\mathrm {C T R}}\right)\right)\right),
$$
and AutoDebias further develop a solution for universal debiasing. However, despite the use of unbiased ratings, we show that they still lead to biased estimates under hidden confounding.
Proposition 1. In the presence of hidden confounders, both LTD and AutoDebias are biased.
Proof. Let  $\mathcal{H}_{\mathrm{CTR}} = \{\hat{p}_{u,i}(x_{u,i},\theta_{\mathrm{CTR}}):\theta_{\mathrm{CTR}}\in \Theta_{\mathrm{CTR}}\}$  be the hypothesis space of propensity model. Then  $\theta_{\mathrm{CTR}}^*$  defined above is the parameter in  $\Theta_{\mathrm{CTR}}$  such that the pCVR prediction model performs optimally on  $\mathcal{U}$ . The bi-level optimization takes  $\mathcal{L}_{\mathrm{CVR}}^B$  to estimate the ideal loss using a selected propensity  $\hat{p}_{u,i}(x_{u,i},\theta_{\mathrm{CTR}}^*)\in \mathcal{H}_{\mathrm{CTR}}$ , however,  $\mathcal{L}_{\mathrm{CVR}}^B$  could be a biased estimator of the ideal loss for all  $\hat{p}_{u,i}\in \mathcal{H}_{\mathrm{CTR}}$  (due to  $\hat{p}_{u,i}$  could deviate from the true one by an arbitrary distance, as formally stated in Theorem 2), therefore both LTD and AutoDebias using bi-level optimization are biased.
Proposition 1 formally reveals the limitations of directly adopting bi-level optimization for addressing hidden confounding. Both LTD and AutoDebias essentially use unbiased data for model selection among all possible IPS or DR losses, but in fact, without correcting the IPS or DR estimators themselves for predicting the ideal loss, those IPS or DR-based methods will not be able to tackle unobserved confounding, because of the intrinsic biasedness of the estimators to the ideal loss.
An alternative class of methods that use unbiased data for tuning is the causal embedding method (CausE) [1] and KDCRec [30, 32]. Specifically, they both consider building a connection between a model trained with biased data and another model trained with unbiased data. CausE [1] designs an alignment term as the pairwise difference between the parameters of the two models, which is then included in the object function to be minimized. KDCRec [30, 32] proposes a general knowledge distillation framework for counterfactual recommendation via uniform data, including label-based, feature-based, sample-based, and model structure-based distillations. The above methods empirically shown impressive performance by distilling the shared information on both biased and unbiased data. However, theoretical guarantees under hidden confounding are lacking, and it would be interesting to investigate the conditions under which these methods can achieve unbiased learning.
3.3 Mitigating Hidden Confounding with Sensitivity Analysis
To tackle the problem of hidden confounding, robust deconfounder (RD) [8] proposes to adopt sensitivity analysis from the causal inference literature [6, 38] to minimize the worst-case prediction loss. Formally, the unknown true propensity  $\bar{p}_{u,i} \triangleq \mathbb{P}(o_{u,i} = 1|x_{u,i}, h_{u,i})$  is assumed to near the nominal propensity  $p_{u,i} = \mathbb{P}(o_{u,i} = 1|x_{u,i})$  within a bound that
$$
\frac {1}{\Gamma} \leq \frac {\left(1 - p _ {u , i}\right) \bar {p} _ {u , i}}{p _ {u , i} \left(1 - \bar {p} _ {u , i}\right)} \leq \Gamma \quad \Longrightarrow \quad 1 + \left(1 / p _ {u, i} - 1\right) / \Gamma \triangleq a _ {u, i} \leq w _ {u, i} \leq b _ {u, i} \triangleq 1 + \left(1 / p _ {u, i} - 1\right) \Gamma ,
$$
where hyper-parameter  $\Gamma$  corresponds to the strength of unmeasured confounding,  $w_{u,i} = 1 / \bar{p}_{u,i}$  is the inverse of the true propensity, and  $a_{u,i}$  and  $b_{u,i}$  are the lower and upper bounds of  $w_{u,i}$ , respectively. Let  $\mathcal{W} = [\hat{a}_{1,1},\hat{b}_{1,1}]\times \dots \times [\hat{a}_{m,n},\hat{b}_{m,n}]$  be the possible inverse propensities on all user-item pairs, where  $\hat{a}_{u,i}$  and  $\hat{b}_{u,i}$  are the estimates of  $a_{u,i}$  and  $b_{u,i}$ , respectively, then RD-IPS method trains the prediction model by minimizing the worst-case IPS loss
$$
\mathcal {L} _ {\mathrm {R D - I P S}} \left(\theta_ {\mathrm {C T R}}, \theta_ {\mathrm {C V R}}\right) = \max  _ {W \in \mathcal {W}} \frac {1}{| \mathcal {D} |} \sum_ {(u, i) \in \mathcal {D}} o _ {u, i} \delta_ {u, i} w _ {u, i},
$$
and the RD-DR method can be developed by a similar argument controlling the worst-case DR loss.
To summarize, the RD methods first obtains the bounds of true propensities around the nominal propensities, then minimize the upper bound of the IPS (or DR) loss to control the worst-case caused by unmeasured confounders. However, on the one hand, it is not clear how to set  $\Gamma$  correctly since both the true propensities and the strength of hidden confounding are unknown. On the other hand, the effectiveness of sensitivity analysis for controlling the hidden confounding requires that the true propensity is around the nominal propensity for all user-item pairs, but such (strong) assumptions cannot be verified from the data and raises another concern in case the assumptions are violated.
4 Debiasing Residual Networks under Hidden Confounding
4.1 Methodology Overview
Different from the previous methods that use sensitivity analysis to control the worst-case IPS or DR loss caused by hidden confounding, we propose a unified multi-task learning approach with residual networks as in Figure 1, with the motivation of using a small unbiased data to calibrate the learned propensities and imputed errors in IPS or DR loss for training the unbiased prediction model.
Following causal inference literature [18, 19], we define the true propensity and true imputation as  $\bar{p}_{u,i} \triangleq \mathbb{P}(o_{u,i} = 1|x_{u,i}, h_{u,i})$ ,  $\bar{g}_{u,i} \triangleq \mathbb{E}(\delta_{u,i}|x_{u,i}, h_{u,i})$ , both of them are functions of  $(x_{u,i}, h_{u,i})$  with  $\tilde{p}_{u,i}$  and  $\tilde{\delta}_{u,i}$  as their estimates. To distinguish, we call  $p_{u,i} = \mathbb{P}(o_{u,i} = 1|x_{u,i})$  and  $g_{u,i} = \mathbb{E}[\delta_{u,i}|x_{u,i}]$  the nominal propensity and nominal imputation, with  $\hat{p}_{u,i}$  and  $\hat{\delta}_{u,i}$  as their estimates.
Next, we show the necessity of calibrations on both  $\hat{p}_{u,i}$  and  $\hat{\delta}_{u,i}$  estimated from the raised data  $\mathcal{B}$ .
Theorem 2 (Necessity of Calibration). Suppose the partial derivative of  $\bar{p}_{u,i}$  and  $\bar{g}_{u,i}$  with respect to hidden confounders  $h_{u,i}$  are not always equal to 0, and  $\hat{p}_{u,i}$  and  $\hat{\delta}_{u,i}$  are consistent estimators of  $p_{u,i}$  and  $g_{u,i}$ , then there exists  $\eta > 0$ , such that
$$
\lim_{|\mathcal{D}|\to \infty}\mathbb{P}(|\hat{p}_{u,i} - \bar{p}_{u,i}| > \eta) > 0,\quad \lim_{|\mathcal{D}|\to \infty}\mathbb{P}(|\hat{\delta}_{u,i} - \bar{g}_{u,i}| > \eta) > 0.
$$
Proof. Given the partial derivative of  $\bar{p}_{u,i}$  with respect to hidden confounders  $h_{u,i}$  is not always equal to 0, that is,  $h_{u,i}$  has a non-zero effect on  $o_{u,i}$ , so we have  $\bar{p}_{u,i} \neq p_{u,i}$  according to their definitions. Thus, for some  $\epsilon > 0$ , there exist positive constants  $\delta_{\epsilon}, N_1(\epsilon) > 0$ , such that for all  $|\mathcal{D}| > N_1(\epsilon)$ ,
$$
\mathbb {P} \left(\left| \bar {p} _ {u, i} - p _ {u, i} \right| > \epsilon\right) > \delta_ {\epsilon} > 0.
$$
Since  $\hat{p}_{u,i}$  is a consistent estimator of  $p_{u,i}$ , there exists some  $N_2(\epsilon) > 0$ , such that for all  $|\mathcal{D}| > N_2(\epsilon)$
$$
\mathbb {P} (| \hat {p} _ {u, i} - p _ {u, i} | \geq \epsilon / 2) <   \frac {\delta_ {\epsilon}}{4}.
$$
Thus, if  $|\mathcal{D}| > \max \{N_1(\epsilon), N_2(\epsilon)\}$ , we have
$$
\begin{array}{l} \mathbb {P} \left(\left| \bar {p} _ {u, i} - p _ {u, i} \right| > \epsilon , \left| \hat {p} _ {u, i} - p _ {u, i} \right| <   \epsilon / 2\right) \\ = \mathbb {P} (| \bar {p} _ {u, i} - p _ {u, i} | > \epsilon) - \mathbb {P} (| \bar {p} _ {u, i} - p _ {u, i} | > \epsilon , | \hat {p} _ {u, i} - p _ {u, i} | \geq \frac {\epsilon}{2}) \\ > \delta_ {\epsilon} - \delta_ {\epsilon} / 4 = 3 \delta_ {\epsilon} / 4. \\ \end{array}
$$
Let  $\eta = \epsilon /2$  and note that  $\{| \bar{p}_{u,i} - p_{u,i}| > \epsilon ,|\hat{p}_{u,i} - p_{u,i}| <   \epsilon /2\} \subset \{| \hat{p}_{u,i} - \bar{p}_{u,i}| > \eta \}$  , we have
$$
\mathbb {P} \left(\left| \hat {p} _ {u, i} - \bar {p} _ {u, i} \right| > \eta\right) \geq \mathbb {P} \left(\left| \bar {p} _ {u, i} - p _ {u, i} \right| > \epsilon , \left| \hat {p} _ {u, i} - p _ {u, i} \right| <   \epsilon / 2\right) > 3 \delta_ {\epsilon} / 4 > 0,
$$
which leads to  $\lim_{|\mathcal{D}| \to \infty} \mathbb{P}(|\hat{p}_{u,i} - \bar{p}_{u,i}| > \eta) > 0$ . Similarly, it can be shown that  $\lim_{|\mathcal{D}| \to \infty} \mathbb{P}(|\hat{\delta}_{u,i} - \bar{g}_{u,i}| > \eta) > 0$ .
Theorem 2 shows that in the presence of hidden confounding, the estimated nominal propensities and nominal imputed errors deviate from the true one, even with the infinite sample size. To address this problem, as shown in Figure 1, we propose a novel consistency loss that utilizes unbiased data to calibrate the learned nominal propensities and imputed errors from the biased data.
(a) Res-IPS
Figure 1: Proposed debiasing residual networks for removing hidden confounding.
(b) Res-DR