## 3 Methodology
### Pre Hoc Explainability Framework  
The Pre Hoc Explainability Framework uses a modified learning objective to incorporate explanations during the training process. In this framework, we first train a white-box explainer model \(g_{\phi}\) on the training data. Then, we use this explainer model to guide the learning of the black-box predictor model \(f_{\theta}\) by including a fidelity term in the loss function.  
The loss function for the pre hoc framework is formulated as follows:  
\[\mathcal{L}_{\text{Pre hoc}}=\mathcal{L}_{\text{BCE}}+\lambda_{1}D_{\text{JS} }+\lambda_{2}\mathcal{L}_{2}, \tag{13}\]  
where \(\mathcal{L}_{\text{BCE}}\) is the binary cross-entropy loss that ensures accurate predictions, \(\lambda_{1}\) is an explainability regularization coefficient that controls the trade-off between explainability and accuracy, and \(\lambda_{2}\) is the coefficient for standard \(\mathcal{L}_{2}\) regularization of model parameters \(\theta\) that aims to avoid overfitting and exploding gradients.  
The formulation of \(\mathcal{L}_{\text{Pre hoc}}\) combines three essential components: (1) binary cross-entropy loss ensures prediction accuracy on the original task, (2) Jensen-Shannon divergence \(D_{\text{JS}}\) enforces alignment between predictor and explainer outputs, weighted by \(\lambda_{1}\) to control the explainability-accuracy trade-off, and (3) L2 regularization with coefficient \(\lambda_{2}\) prevents overfitting. This multi-objective formulation is inspired by knowledge distillation [59] but adapted for explainability rather than compression.  
Expanding the loss function, we obtain the following:  
\[\begin{split}&\mathcal{L}_{\text{Pre hoc}}(\theta,\phi,X,y)= \underbrace{\frac{1}{N}\sum_{i=1}^{N}-y_{i}\log(\hat{y}_{\theta,i})-(1-y_{i}) \log(1-\hat{y}_{\theta,i})}_{\text{Predictor Accuracy}}\\ &+\underbrace{\lambda_{1}\frac{1}{2}(\sum_{i=1}^{N}\ln\left( \frac{\hat{y}_{\phi,i}}{\hat{y}_{\theta,i}}\right)\hat{y}_{\phi,i}+\sum_{i=1}^ {N}\ln\left(\frac{\hat{y}_{\theta,i}}{\hat{y}_{\phi,i}}\right)\hat{y}_{\theta,i})}_{\text{Fidelity}}+\underbrace{\lambda_{2}\sum_{j}\theta_{j}^{2}}_{\text{ L2 Regularization}},\end{split} \tag{14}\]  
Since the explanation is provided by the white-box model \(g_{\phi}\), which is inherently interpretable, the transparency is considered high when the explainer model outputs \(\hat{y}_{\phi}\) are similar to the regularized model \(f_{\theta}\) outputs \(\hat{y}_{\theta}\). This similarity is captured by \(D_{\text{JS}}\), which is the fidelity term in the objective function \(\mathcal{L}_{\text{Pre hoc}}\) (Equation (13)). While the objective function is to learn a model that will make accurate predictions, we give greater importance to model predictions that are similar to the white-box predictions and penalize those that are not similar.  
The optimization procedure for the pre hoc framework is as follows:  
1. Train the white-box explainer model \(g_{\phi}\) on the training data to minimize the binary cross-entropy loss.
2. Fix the parameters \(\phi\) of the explainer model.
3. Train the black-box predictor model \(f_{\theta}\) to minimize the combined loss function \(\mathcal{L}_{\text{Pre hoc}}\).