diff --git a/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_content_list.json b/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e7862b56a0a233dc6b4aa146f11783d5713ee864
--- /dev/null
+++ b/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7360b642dcf78751e966400cd37c77d1c197a13db1d9ba7f6b5ff8486d5f625d
+size 46109
diff --git a/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_model.json b/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..3c0b703f67d69c014c941689e89f03012e2f6bca
--- /dev/null
+++ b/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3c6f54051a16899ec32b3c30f47f9ac6da3e26ae4f74b46661d7f972e16d01a1
+size 55790
diff --git a/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_origin.pdf b/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..cb8c3303e604af77cf1d8c72f2d6077952883a71
--- /dev/null
+++ b/debiasingmasksanewframeworkforshortcutmitigationinnlu/0cdf5ad0-de25-4a7b-836a-9a57555d069c_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3780f9cb99e745b7fce0a9ac09af23fcbdfdeddd28657e2e8ed49c588eaa910e
+size 204976
diff --git a/debiasingmasksanewframeworkforshortcutmitigationinnlu/full.md b/debiasingmasksanewframeworkforshortcutmitigationinnlu/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..fc471d21591355669b7e508fb82f5b5ba7cfee08
--- /dev/null
+++ b/debiasingmasksanewframeworkforshortcutmitigationinnlu/full.md
@@ -0,0 +1,191 @@
+# Debiasing Masks:
+
+# A New Framework for Shortcut Mitigation in NLU
+
+Johannes Mario Meissner†, Saku Sugawara‡, Akiko Aizawa†‡
+
+†The University of Tokyo, ‡National Institute of Informatics
+
+{meissner,saku,aizawa}@nii.ac.jp
+
+# Abstract
+
+Debiasing language models from unwanted behaviors in Natural Language Understanding tasks is a topic with rapidly increasing interest in the NLP community. Spurious statistical correlations in the data allow models to perform shortcuts and avoid uncovering more advanced and desirable linguistic features. A multitude of effective debiasing approaches has been proposed, but flexibility remains a major issue. For the most part, models must be retrained to find a new set of weights with debiased behavior. We propose a new debiasing method in which we identify debiased pruning masks that can be applied to a finetuned model. This enables the selective and conditional application of debiasing behaviors. We assume that bias is caused by a certain subset of weights in the network; our method is, in essence, a mask search to identify and remove biased weights. Our masks show equivalent or superior performance to the standard counterparts, while offering important benefits. Pruning masks can be stored with high efficiency in memory, and it becomes possible to switch among several debiasing behaviors (or revert back to the original biased model) at inference time. Finally, it opens the doors to further research on how biases are acquired by studying the generated masks. For example, we observed that the early layers and attention heads were pruned more aggressively, possibly hinting towards the location in which biases may be encoded.
+
+# 1 Introduction
+
+The issue of spurious correlations in natural language understanding datasets has been extensively studied in recent years (Gururangan et al., 2018; McCoy et al., 2019; Gardner et al., 2021). In the MNLI dataset (Williams et al., 2018), negation words such as "not" are unintended hints for the contradiction label (Gururangan et al., 2018), while a high word overlap between the premise and the hypothesis often correlates with entailment (McCoy et al., 2019).
+
+
+Figure 1: We find masks that remove bias from a finetuned model by using frozen-weight movement pruning.
+
+A common way to prevent the acquisition of biases (in this paper defined as unintended shortcut behaviors) is to adopt a debiasing loss function, such as product-of-experts (Hinton, 2002), to discourage learning shortcuts through the use of the annotated level of bias in each sample. Because manual bias annotation is difficult and expensive, the predictions of a biased model are used as bias annotations (Clark et al., 2019). Commonly, models must be retrained to achieve debiased behavior; this limits our ability to target different biases separately, as well as choose varied levels of debiasing strength (which impacts the in- vs. out-of-distribution trade-off).
+
+We propose a new debiasing framework that focuses on removing bias from an existing model, instead of the now-common approach of re-training from scratch. Our approach is depicted in Figure 1. We find a pruning mask that zeroes out the weights that cause biased outputs, producing the desired effect without altering the original model. This
+
+approach offers several clear advantages. First, pruning masks can be stored very efficiently, only occupying a fraction of the original model size. This enables creating multiple masks for varied debiasing behaviors. Secondly, masks can be effortlessly set or unset at inference time, as opposed to replacing the entire model. This allows for flexible application, as well as easy reversion to the original model when needed. Finally, re-framing the debiasing process as a mask search opens the doors towards future analysis directions, helping to more deeply understand how biases are learned, and how they can be eliminated.
+
+# 2 Related Work
+
+# 2.1 Shortcuts in NLU
+
+The study of shortcut solutions in machine learning (Geirhos et al., 2020; D'Amour et al., 2020) has gained attention in recent years, including in the field of Natural Language Understanding. In SQuAD (Rajpurkar et al., 2016), Jia and Liang (2017) show that distractor sentences can be inserted in such a way that the frequently used spurious features mislead the model's answer. In MNLI, Gardner et al. (2021) discuss the idea that all simple feature-label correlations should be regarded as spurious. Their results go in line with Gururan-gan et al. (2018), who show that models are able to achieve strong performance just by training on the hypothesis, a scenario where the desirable advanced features are not available. Instead, simple word correlations are used to make the prediction. Finally, other kinds of features such as lexical overlap have been pointed out as important shortcuts (McCoy et al., 2019).
+
+# 2.2 Debiasing
+
+A wide range of debiasing approaches have been proposed to alleviate shortcut behavior. For example, perturbations in the model's embedding space can encourage robustness to shortcuts (Liu et al., 2020), and training on adversarial data (Wang and Bansal, 2018) has important benefits for generalization capabilities too. Removing a certain subset in the training data (filtering) can help to avoid learning spurious correlations. Bras et al. (2020) devise an algorithm that selects samples to filter out, reducing the training time and robustness of the target model.
+
+We will focus our efforts on a family of approaches that rely on a debiasing loss function to
+
+discourage biased learning, instead of altering the original training data. A wide range of debiasing losses have been proposed to discourage shortcut learning. They all rely on having a measure of the level of bias for each training sample, which is commonly obtained via a biased model's predictions. Among the most common are product-of-experts and focal loss (Schuster et al., 2019). Other approaches introduce a higher level of complexity, such as confidence regularization (Utama et al., 2020a) requiring a teacher model, or learned-mixin (Clark et al., 2019) introducing an additional noise parameter.
+
+# 2.3 Pruning
+
+Pruning consists in masking out or completely removing weights in a neural network, such that they no longer contribute to the output. Common goals include reducing the model size or achieving an inference speed-up.
+
+Magnitude pruning is a basic pruning method that removes weights based on their absolute value. It has proven to be an effective method to reduce model size without compromising on performance. Gordon et al. (2020) apply this technique on transformer language models. Movement pruning, on the other hand, was proposed by Sanh et al. (2020), and involves training a score value alongside each weight. Scores are updated as part of the optimization process, and weights with an associated score below the threshold are masked out.
+
+Zhao et al. (2020) introduce an alternative to the usual finetuning process by finding a mask for the pretrained base model such that performance on the target task increases. The same base model can be used with several masks to perform multiple tasks. They show that this approach achieves similar performance to standard finetuning on the GLUE tasks (Wang et al., 2018).
+
+Our work is inspired by Zhao et al. (2020); but we focus on removing biases from an already finetuned model. We will refer to this method as a mask search. It benefits from the same advantages: masks can be easily applied and removed from a shared base model, while additionally offering storage improvements.
+
+# 3 Masked Debiasing
+
+Our proposed approach to debiasing takes a unique point of view in the debiasing field by assuming that biased behavior is encoded in specific weights
+
+
+Figure 2: Pruning rate for each module in one of our debiasing masks.
+
+of the network and can be removed without altering the remaining weights. Thus, we perform a mask search to identify and remove those weights, experiencing debiased behavior in the resulting model. Our approach comes together by combining a debiasing loss, a biased model, and a score-based pruning technique.
+
+Debiasing Loss Among the debiasing losses mentioned in Section 2.2, none appear to be clearly superior, each offering certain strengths and weaknesses, and striking a balance between in- and out-of-distribution performance. We err on the side of simplicity and run our experiments with the focal loss. We follow Clark et al. (2019) for the implementation.
+
+Bias Model To utilize a debiasing loss, we must obtain the predictions of a biased model on the training samples. We utilize weak learners, following the nomenclature introduced by Sanh et al. (2021); they do not require making any assumptions on the underlying biases. While our method works with any debiasing loss and bias level source, we choose this setting due to its flexibility and adaptability to new scenarios.
+
+To date, two major learners have been proposed: undertrained (Utama et al., 2020b) and underparameterized (Sanh et al., 2021) learners. We train and extract the predictions of both of them for comparison. Undertrained learners are trained by selecting a very small subset of the training data, but keeping the target model's architecture and hyperparameters. This effectively translates into a model that overfits on the selected data subset. Features uncovered by the model in this manner are deemed spurious, as it is assumed that more advanced features require exploring larger quantities of data. We
+
+used 2000 samples for MNLI, and 500 samples for the other datasets. Underparameterized learners, on the other hand, restrict the model complexity by reducing layer size and count. The expectation is that this underparameterization is restrictive and limits the ability to find complex features. We use BERT-Tiny (Turc et al., 2019), a BERT model with 2 layers and an inner size of 128.
+
+Frozen Movement Pruning Our approach is similar to Zhao et al. (2020); but we implement it by leveraging the framework provided by Sanh et al. (2020), with the addition of weight-freezing. We use unstructured pruning, which means that each individual weight is considered for exclusion. Further, we utilize a threshold approach: in each weight tensor we remove (mask out) those weights with an associated score that is lower than the threshold. A regularization term for the scores helps avoid all scores growing larger than the threshold. For further details, we refer the reader to Sanh et al. (2020). As the starting point, we load a model already finetuned on the target task.
+
+# 4 Experimental Setup
+
+We compare our approach against the standard approach of re-training the model with a debiasing loss. Our experiments are carried out with BERT-Base (Devlin et al., 2019).
+
+# 4.1 Tasks and Evaluation Scenarios
+
+We perform experiments on three tasks in NLU, and consider several biases and evaluation datasets.
+
+Natural Language Inference (NLI) This task consists in classifying whether the relationship between a pair of sentences (premise and hypothesis) is entailed, neutral or contradicted. We evaluate on two well-known biases: lexical overlap bias (McCoy et al., 2019) and negation words bias (Gururangan et al., 2018). We train on MNLI, and evaluate on HANS (McCoy et al., 2019) and our own negation-words subset. HANS can be used to evaluate the lexical overlap bias. Additionally, we create our own negation-words anti-bias set by selecting entailed samples from the MNLI validation set that contain negation words in the hypothesis.1
+
+
| MNLI | QQP | FEVER |
| Val. | HANS | Neg. | Val. | PAWS | PAWS (¬) | Val. | Symm. |
| Baseline | 84.38 | 61.97 | 78.47 | 92.07 | 44.28 | 23.37 | 85.67 | 64.08 |
| Masking w/o Debiasing | 83.15 | 64.16 | 77.87 | 90.91 | 37.61 | 16.38 | 84.71 | 63.26 |
| Undertrained SD | 81.02 | 67.06 | 74.82 | - | - | - | 86.54 | 65.06 |
| Underparam. SD | 83.03 | 67.75 | 72.36 | 88.79 | 43.50 | 27.16 | 85.70 | 65.79 |
| Undertrained MD (Ours) | 81.85 | 68.69 | 75.58 | - | - | - | 84.55 | 64.85 |
| Underparam. MD (Ours) | 82.24 | 67.86 | 73.95 | 89.61 | 44.34 | 28.56 | 84.96 | 63.37 |
| HypOnly MD (Ours) | 82.87 | 64.26 | 79.03 | - | - | - | - | - |
+
+Table 1: Our experimental results comparing a BERT-Base baseline against several debiasing methods, along with our own mask debiasing approach. SD stands for standard debiasing, while MD stands for masked debiasing. MNLI Neg. is our split of the MNLI development set containing at least one negation word in the hypothesis. PAWS $(\neg)$ indicates the subset of PAWS with a negative label (the anti-bias set for lexical overlap in QQP).
+
+Paraphrase Identification In this task the goal is to identify whether a pair of sentences are paraphrasing each other or not. We train on QQP (Quora Question Pairs) $^2$ , and evaluate on PAWS (Zhang et al., 2019), which tests the model's reliability on the lexical overlap bias.
+
+Fact Verification We train on FEVER (Thorne et al., 2018), and evaluate on FEVER Symmetric (Schuster et al., 2019). The task setup is similar to NLI; we classify a claim-evidence pair as either support, refutes or not-enough-information. FEVER Symmetric eliminates claim-only biases (clues in the claim that allow to guess the label), among which are negation words, in a similar fashion to MNLI.
+
+# 4.2 Hyperparameters and Reproducibility
+
+We aim for complete reproducibility by providing complete code and clear reproduction instructions in our repository. In most cases, we follow the configurations indicated by the respective original papers. Appendix B is additionally provided for a report of important hyperparameters.
+
+We run all of our experiments on five seeds. We not only seed the debiasing masks, but also the accompanying weak models and base models too.
+
+# 5 Results
+
+We compare our approach against our reproduction of the two weak model approaches, and compile our results in Table 1.
+
+$^{2}$ https://www.kaggle.com/c/
+quora-question-pairs
+ $^{3}$ https://github.com/mariomeissner/
+shortcut-pruning
+
+# 5.1 Masked Debiasing is Effective
+
+First, we observe that our debiasing masks are very effective, surpassing the performance of their standard debiasing counterparts in two out of the three evaluated tasks, while keeping a competitive indistribution performance. In the FEVER task, our masks provided a slight debiasing effect, but did not beat the standard debiasing baseline. We do not report undertrained debiasing results in the QQP setting due to their failure to converge to adequate results (in both standard and masked debiasing).
+
+To confirm that the combination of masking with a debiasing loss is necessary to achieve our results, we provide an ablation experiment (Masking w/o Debiasing) where the debiasing loss is replaced with the standard cross-entropy loss, while using the same pruning parameters. Results suggest that pruning alone is not able to achieve the same debiasing effect.
+
+# 5.2 Masks are Diverse
+
+As a means to showcase the capacity of debiasing masks to offer different debiasing behaviors, we refer to each method's capacity to mitigate the negation bias, evaluated by our negation-words subset.
+
+As the standard debiasing results reveal, both weak model approaches were unable to improve baseline performance on our subset. Therefore, we used the hypothesis-only bias model, as provided by Utama et al. (2020a). Negation words are strongly correlated with the hypothesis-only bias; accordingly, observe a performance improvement on our subset when leveraging this debiasing target.
+
+# 6 Mask Analysis
+
+Our pruning approach uses a score threshold, which allows for a dynamic pruning rate across modules. To gain a better understanding on our masks, we study the generated density distribution. Specifically, we study the rate at which weights were removed in different network regions. In each layer, we obtain the pruning rate of the attention layer's query, key, value, and output modules, as well as the two linear modules that follow. We plot the results in Figure 2.
+
+We make two general observations. First, pruning rates are relatively higher in the early layers. It is known that the last few layers are very task specific (Tenney et al., 2019), which likely implies that their modification more directly impacts performance. Thus, our masks may be targeting early layers as a means to remove biases without causing a noticeable performance decrease. Secondly, the attention modules are more heavily pruned than the linear layers, which could suggest that attention heads play an important role in bias encoding.
+
+# 7 Conclusion
+
+We conclude that debiasing masks are an effective approach to mitigating shortcuts. Alongside providing surprisingly well-performing debiased behaviors, masks allow to shift the way we think about debiasing: no longer should biased and unbiased models be treated as two separate models; rather, it becomes possible to "remove" biases by simply eliminating certain weights from the network.
+
+# Limitations
+
+An important limitation of this approach is that we found it necessary to follow Sanh et al. (2020) and run the movement pruning technique for 12 epochs, requiring longer training time. We hypothesize that in future work, it could become possible to drastically reduce training time for this approach.
+
+Further, in this short paper we explored three tasks in NLU with a fixed pruning configuration, but it would be beneficial to explore its applicability to other domains, combine it with other debiasing approaches, or explore more varied configurations, such as structured pruning methods for improved inference efficiency.
+
+# Acknowledgments
+
+The education period leading to this project has received funding from "la Caixa" Foundation (ID 100010434), under agreement LCF/BQ/AA19/11720042. This work was also supported by JST PRESTO Grant Number JPMJPR20C and JSPS KAKENHI Grant Number 21H03502.
+
+# References
+
+Ronan Le Bras, Swabha Swayamdipta, Chandra Bhagavatula, Rowan Zellers, Matthew Peters, Ashish Sabharwal, and Yejin Choi. 2020. Adversarial filters of dataset biases.
+Christopher Clark, Mark Yatskar, and Luke Zettlemoyer. 2019. Don't take the easy way out: Ensemble based methods for avoiding known dataset biases. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 4069-4082, Hong Kong, China. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Alexander D'Amour, Katherine Heller, Dan Moldovan, Ben Adlam, Babak Alipanahi, Alex Beutel, Christina Chen, Jonathan Deaton, Jacob Eisenstein, Matthew D Hoffman, et al. 2020. Underspecification presents challenges for credibility in modern machine learning. Journal of Machine Learning Research.
+Matt Gardner, William Merrill, Jesse Dodge, Matthew Peters, Alexis Ross, Sameer Singh, and Noah A. Smith. 2021. Competency problems: On finding and removing artifacts in language data. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1801-1813, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Robert Geirhos, Jorn-Henrik Jacobsen, Claudio Michaelis, Richard Zemel, Wieland Brendel, Matthias Bethge, and Felix A Wichmann. 2020. Shortcut learning in deep neural networks. Nature Machine Intelligence, 2(11):665-673.
+Mitchell Gordon, Kevin Duh, and Nicholas Andrews. 2020. Compressing BERT: Studying the effects of weight pruning on transfer learning. In Proceedings of the 5th Workshop on Representation Learning for
+
+NLP, pages 143-155, Online. Association for Computational Linguistics.
+Suchin Gururangan, Swabha Swayamdipta, Omer Levy, Roy Schwartz, Samuel Bowman, and Noah A. Smith. 2018. Annotation artifacts in natural language inference data. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 107-112, New Orleans, Louisiana. Association for Computational Linguistics.
+Geoffrey E Hinton. 2002. Training products of experts by minimizing contrastive divergence. Neural computation, 14(8):1771-1800.
+Robin Jia and Percy Liang. 2017. Adversarial examples for evaluating reading comprehension systems. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 2021-2031, Copenhagen, Denmark. Association for Computational Linguistics.
+Xiaodong Liu, Hao Cheng, Pengcheng He, Weizhu Chen, Yu Wang, Hoifung Poon, and Jianfeng Gao. 2020. Adversarial training for large neural language models. arXiv:2004.08994.
+Tom McCoy, Ellie Pavlick, and Tal Linzen. 2019. Right for the wrong reasons: Diagnosing syntactic heuristics in natural language inference. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3428-3448, Florence, Italy. Association for Computational Linguistics.
+Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. 2016. SQuAD: 100,000+ questions for machine comprehension of text. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2383-2392, Austin, Texas. Association for Computational Linguistics.
+Victor Sanh, Thomas Wolf, Yonatan Belinkov, and Alexander M Rush. 2021. Learning from others' mistakes: Avoiding dataset biases without modeling them. In International Conference on Learning Representations.
+Victor Sanh, Thomas Wolf, and Alexander M. Rush. 2020. Movement pruning: Adaptive sparsity by fin-tuning. NIPS'20, Red Hook, NY, USA. Curran Associates Inc.
+Tal Schuster, Darsh Shah, Yun Jie Serene Yeo, Daniel Roberto Filizzola Ortiz, Enrico Santus, and Regina Barzilay. 2019. Towards debiasing fact verification models. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3419-3425, Hong Kong, China. Association for Computational Linguistics.
+
+Ian Tenney, Dipanjan Das, and Ellie Pavlick. 2019. BERT rediscovers the classical NLP pipeline. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4593-4601, Florence, Italy. Association for Computational Linguistics.
+James Thorne, Andreas Vlachos, Christos Christodoulopoulos, and Arpit Mittal. 2018. FEVER: a large-scale dataset for fact extraction and VERIFICATION. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 809-819, New Orleans, Louisiana. Association for Computational Linguistics.
+Iulia Turc, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. Well-read students learn better: The impact of student initialization on knowledge distillation. CoRR, abs/1908.08962.
+Prasetya Utama, Nafise Sadat Moosavi, Victor Sanh, and Iryna Gurevych. 2021. Avoiding inference heuristics in few-shot prompt-based finetuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 9063-9074, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Prasetya Ajie Utama, Nafise Sadat Moosavi, and Iryna Gurevych. 2020a. Mind the trade-off: Debiasing NLU models without degrading the in-distribution performance. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8717-8729, Online. Association for Computational Linguistics.
+Prasetya Ajie Utama, Nafise Sadat Moosavi, and Iryna Gurevych. 2020b. Towards debiasing NLU models from unknown biases. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 7597-7610, Online. Association for Computational Linguistics.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. 2018. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In Proceedings of the 2018 EMNLP Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pages 353-355, Brussels, Belgium. Association for Computational Linguistics.
+Yicheng Wang and Mohit Bansal. 2018. Robust machine comprehension models via adversarial training. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 575-581, New Orleans, Louisiana. Association for Computational Linguistics.
+Adina Williams, Nikita Nangia, and Samuel Bowman. 2018. A broad-coverage challenge corpus for sen
+
+tence understanding through inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 1112-1122, New Orleans, Louisiana. Association for Computational Linguistics.
+
+Yuan Zhang, Jason Baldridge, and Luheng He. 2019. PAWS: Paraphrase adversaries from word scrambling. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 1298-1308, Minneapolis, Minnesota. Association for Computational Linguistics.
+
+Mengjie Zhao, Tao Lin, Fei Mi, Martin Jaggi, and Hinrich Schütze. 2020. Masking as an efficient alternative to finetuning for pretrained language models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2226-2241, Online. Association for Computational Linguistics.
+
+# A Negation Words
+
+Within the MNLI Validation Matched set, we select those entailed samples where at least one of the following words is present in the hypothesis: no, not, don't, none, nothing, never, aren't, isn't, weren't, neither, don't, didn't, doesn't, cannot, hasn't won't.
+
+# B Hyperparameters
+
+# B.1 Baseline and Debiased Models
+
+Our baseline models are trained with a batch size of 32, learning rate of 3e-5, weight decay of 0.1, and $20\%$ warmup steps.
+
+# B.2 Weak Learners
+
+Undertrained models are trained with the standard BERT architecture and 2000 samples (500 in the case of QQP and FEVER) of the dataset for 5 epochs. Utama et al. (2021) mention 3 in their paper, but train with 5 in their code repository. We confirm that 5 yields better results. For underparameterized models, we follow (Sanh et al., 2021) and use BERT-Tiny (Turc et al., 2019), a BERT model with 2 layers and an inner size of 128. This model is trained on the full training set for 3 epochs, and slightly adjusted hyperparameters.
+
+We use focal loss (sample reweighting) in all mask debiasing experiments, with the exception of the HypOnly MD model, which uses product-of-experts (in an attempt to follow Utama et al. (2020a) as closely as possible).
+
+# B.3 Masked Debiasing Models
+
+Our mask search is performed with a score learning rate of 0.1, batch size of 128, and 12 epochs of training.
\ No newline at end of file
diff --git a/debiasingmasksanewframeworkforshortcutmitigationinnlu/images.zip b/debiasingmasksanewframeworkforshortcutmitigationinnlu/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..a989783a45d13b5fae24e6938e053620105454dd
--- /dev/null
+++ b/debiasingmasksanewframeworkforshortcutmitigationinnlu/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:74c0e2b0ab592e9dad897552c04ab4ad360a2513f073ba9f8dbdec78b2ee4ec0
+size 151902
diff --git a/debiasingmasksanewframeworkforshortcutmitigationinnlu/layout.json b/debiasingmasksanewframeworkforshortcutmitigationinnlu/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..3a975a501eecb4ee903934df339eb54b4488bd24
--- /dev/null
+++ b/debiasingmasksanewframeworkforshortcutmitigationinnlu/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2d3740132b18e3213c1fe8ad16761b953b0d32c801587782c30d2b717f7860fd
+size 176636
diff --git a/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_content_list.json b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e9e8c7c8f2b507190ee4ecaf6bb129d683c148d8
--- /dev/null
+++ b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8aa2c6600cad14a9733a43d85396a66b3acb9e5f64f3f2e7af9ca88e3dcbae82
+size 140720
diff --git a/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_model.json b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..2a6790122aaaf707d2c1d77468eed16d2d813bd4
--- /dev/null
+++ b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:66bbaec68331f58a07699e661c29f0966dc557598a81a6775d87f725038d5c99
+size 167500
diff --git a/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_origin.pdf b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..acc49b10a1bc3c69ac0b5ab5013f617a5305b109
--- /dev/null
+++ b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/f12aefb5-3745-4794-91fc-30a082dc34ab_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e5568c7c6d66d8bae734fe40185a0c3c9a21016b4ee6a3e7bc001cd7c5216fb4
+size 864318
diff --git a/debiasingpretrainedtextencodersbypayingattentiontopayingattention/full.md b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..9d2bdcbfaf34c1c76f5bdc5155863d83971eb22c
--- /dev/null
+++ b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/full.md
@@ -0,0 +1,474 @@
+# Debiasing Pretrained Text Encoders by Paying Attention to Paying Attention
+
+Yacine Gaci $^{1}$ , Boualem Benatallah $^{2,3}$ , Fabio Casati $^{4}$ , Khalid Benabdeslem $^{1}$
+
+$^{1}$ LIRIS - University of Lyon 1, France $^{2}$ Dublin City University, Ireland
+
+3 UNSW, Sydney, Australia 4 ServiceNow, USA
+
+{yaccine.gaci, khalid.benabdeslem}@univ-lyon1.fr
+
+{boualem.benatallah, fabio.casati}@gmail.com
+
+# Abstract
+
+Natural Language Processing (NLP) models are found to exhibit discriminatory stereotypes across many social constructs, e.g. gender and race. In comparison to the progress made in reducing bias from static word embeddings, fairness in sentence-level text encoders received little consideration despite their wider applicability in contemporary NLP tasks. In this paper, we propose a debiasing method for pretrained text encoders that both reduces social stereotypes, and inflicts next to no semantic damage. Unlike previous studies that directly manipulate the embeddings, we suggest to dive deeper into the operation of these encoders, and pay more attention to the way they pay attention to different social groups. We find that stereotypes are also encoded in the attention layer. Then, we work on model debiasing by redistributing the attention scores of a text encoder such that it forgets any preference to historically advantaged groups, and attends to all social classes with the same intensity. Our experiments confirm that reducing bias from attention effectively mitigates it from the model's text representations.
+
+# 1 Introduction
+
+Natural Language Processing (NLP) is increasingly penetrating real-world processes such as recruitment (Hansen et al., 2015), legal systems (Dale, 2019), healthcare (Velupillai et al., 2018) and Web Search (Nalisnick et al., 2016). Part of this success is attributed to the underlying embedding layer which encodes sophisticated semantic representations of language (Camacho-Collados and Pilehvar, 2018). However, this wide adoption has called into question the fairness aspect of modern text encoders. Recent research exposed them for replicating discriminatory social biases which may cause unintended and undesired model behaviors with respect to social groups (Bolukbasi et al., 2016; Caliskan et al., 2017; May et al., 2019). As an
+
+example, a resume filtering system built on top of such biased encoders display overly improper preferences towards male applicants (Dastin, 2018).
+
+Methods to debias text encoders have recently been proposed, ranging from Counterfactual Data Augmentation (CDA) (Webster et al., 2020), projection on bias-free subspaces (Kaneko and Bollegala, 2021), contrastive learning (Cheng et al., 2020), adversarial attacks (Wang et al., 2021) or simply extending existing debiasing techniques from static word embeddings (Liang et al., 2020a; Bolukbasi et al., 2016; Manzini et al., 2019; Gaci et al., 2022a). However, these methods have shown mixed results, often failing to reduce the amount of bias to a satisfactory degree (Gonen and Goldberg, 2019; Blodgett et al., 2020; Meade et al., 2021). We argue that part of this shortcoming owes to the fact that current debiasing techniques, by operating exclusively on the model's embeddings, are not removing bias entirely. In this paper, we propose that some biases can also be encoded in the attention mechanism, and these stay relatively out of reach for methods that do not manipulate attention directly.
+
+To illustrate how biases are reflected in attention, we show some attention heads of BERT (Devlin et al., 2018) in Figure $1^{1}$ . Consider the following sentence "The doctor asked the nurse a question." Aiming to analyze how every word representation relates to different demographics, we add a dummy second input consisting of words representing distinct groups (e.g. he and she after the [SEP] token $^{2}$ ). Figure 1(a) illustrates that doctor pays much more attention to he than to she $^{3}$ , while Figure 1(b) reveals that nurse attends to she. This finding suggests that gender stereotypes are encoded in attention weights. Likewise, in Figure 1(c), math is more related to asian than to white or black,
+
+
+(a)
+
+
+(b)
+Figure 1: Attention patterns in modern text encoders suggest the existence of potential gender and racial biases. Figures (a), (b) and (c) correspond to the base version of BERT, while Figure (d) corresponds to BERT after applying the debiasing method proposed by Kaneko and Bollegala (2021)
+
+
+(c)
+
+
+(d)
+
+conforming to the famous racial stereotype casting asians as good mathematicians (Trytten et al., 2012; Shah, 2019). More intriguing is Figure 1(d), where we find that even after applying the bias reduction method proposed by Kaneko and Bollegala (2021), gender bias is still reflected in the attention of the supposedly debiased text encoder. We experimented with other debiasing methods and found similar results. These examples convey that biases can be hidden in the attention mechanism, and thus pose the risk of being recovered in representations and predictions.
+
+In this paper, we propose a novel bias measure based on attention weights in order to quantify the amount of bias encoded in attention heads. We show that modern text encoders display substantial amounts of bias in their attention components. Also, we quantitatively show that current debiasing methods do very little to mitigate social stereotypes, and merely conceal them in the attention layer. Then, we propose Attention-Debiasing (AttenD), an attention-based debiasing approach which works as follows: Given that attention weights conform with undesired biases (e.g., doctor attending to he, and nurse to she in Figure 1), we finetune the parameters of the text encoder of interest such that it learns to produce equal attention scores for every word in the input sentence with respect to social groups. Returning to the example of Figure 1, AttenD redistributes attention scores of doctor such that it attends to he and she with the same intensity, thus eliminating any preference toward one of the groups. However, alterations to the attention of doctor on the remaining words of the input sentence must be kept to a minimum in order not to corrupt the semantic understanding of the original text encoder. To do that, we distill the original attentions from an unaltered teacher text encoder
+
+(Hinton et al., 2015; Gou et al., 2021). In this setting, we encourage the debiased model to copy the original attention from its teacher to minimize semantic offset.
+
+We suggest that by equalizing attention weights, text encoders forget biased associations between groups and attributes. Thus, for a given input sentence, whether it mentions a man or a woman, a muslim or a christian, the model's attention on the mentioned group is the same, which leads to very close text representations, and hence identical predictions. In our experiments, we address gender, racial and religious biases, and show that AttenD not only reduces social stereotypes from the attention layer itself, but also from representations and predictions when applied to the tasks of textual inference and hate speech detection. We release our code and data on GitHub.
+
+# 2 Related Work
+
+# 2.1 Bias Quantification
+
+To date, there are three main approaches to detect stereotypes in text encoders: (1) representation-based: where vector relationships between different types of inputs are measured. For example, Caliskan et al. (2017) and May et al. (2019) compared the cosine similarity between representations of groups and attributes, and found that groups have unequal similarities. (2) likelihood-based: These approaches examine how often text encoders prefer stereotypes over anti-stereotypes. Preferences in this case are defined in terms of higher likelihoods as produced by language models using embeddings of the text encoders under study (Kurita et al., 2019; Nadeem et al., 2020; Nangia et al., 2020; Gaci et al., 2022b). (3) inference
+
+based: These methods employ text encoders in downstream NLP tasks (Blodgett et al., 2020) such as natural language inference (Dev et al., 2020), sentiment analysis (Díaz et al., 2018) or language generation (Sap et al., 2020; Sheng et al., 2020). Bias in such settings is declared as the difference in outcome when the models are tested with the same input sentence, differing only in social groups. In contrast, we propose a new metric that quantifies bias that is specifically encoded in the attention layer.
+
+# 2.2 Bias Reduction
+
+The NLP community has produced a wealth of methods to reduce bias from static word embeddings, spanning diverse techniques such as projections on bias-free dimensions (Bolukbasi et al., 2016; Manzini et al., 2019; Kaneko and Bollegala, 2019; Kumar et al., 2020; Ravfogel et al., 2020), adversarial attacks (Xie et al., 2017; Li et al., 2018; Elazar and Goldberg, 2018; Gaci et al., 2022a), or training from scratch with additional fairness constraints (Zhao et al., 2018). However, debiasing large-scale text encoders has started attracting the community's attention only recently. A lot of effort has focused on extending existing techniques to work for large text encoders. For instance, Liang et al. (2020a) contextualize words into sentences by sampling them from existing corpora before applying the methods of Bolukbasi et al. (2016). Kaneko and Bollegala (2021) minimizes the projection of sentence representations on a learned bias subspace, while Qian et al. (2019); Bordia and Bowman (2019); Liang et al. (2020b) add bias-reduction objectives to their loss functions. Another line of research uses CDA (Webster et al., 2020) to balance gender correlations in training data, while Lauscher et al. (2021) uses adapters to reduce the large training time that CDA incurs. Other debiasing techniques use contrastive learning (Cheng et al., 2020), zero-shot learning (Schick et al., 2021), dropout (Meade et al., 2022), or regularizing the entropy of attention (Attanasio et al., 2022). This last work differs from ours in that they discourage the model from basing its classification on identity terms while attending to a wider context. On the other hand, our goal is to reduce harmful associations to (dis)advantaged groups by calibrating the attention of the context on identity terms. Besides, our method is applied to text encoders as a general representation layer, while the method of
+
+Attanasio et al. (2022) is proposed for hate-speech classification models.
+
+# 2.3 Effect of Attention
+
+Attention plays a central role in modern NLP systems (Wiegreffe and Pinter, 2019). Several techniques have used attention to dissect and explain the inner functioning of text encoders (Vig, 2019b; Clark et al., 2019; Hoover et al., 2020; Tenney et al., 2020; Bastings and Filippova, 2020). However, recent studies argued that attention cannot be used as a reliable tool to explain the behavior of models (Jain and Wallace, 2019; Pruthi et al., 2020; Bastings and Filippova, 2020). In this work, we disagree with these anti-attention studies, and following the arguments of Wiegreffe and Pinter (2019), we emphasize that their limitations include:
+
+(1) the experimental setup was particularly limited to recurrent architectures (RNNs). We believe that one cannot generalize the findings to all kinds of models that use attention, especially transformer-based models like the ones we use in this paper, that mainly constitute of attention layers (Vaswani et al., 2017; Devlin et al., 2018). (2) Whether attention explains or not depends on the definition of explainability one is looking for (Lipton, 2018; Rudin, 2019). Although Jain and Wallace (2019) casts some doubt on the notion that attention grants one true and faithful interpretation, we believe they do not invalidate the fact that attention does show which features are most meaningful to models (Wiegreffe and Pinter, 2019). (3) Our own experiments confirm that by reducing bias in attention, we find that it is also reduced in embeddings and predictions. This hints that attention contributes in the decision-making of text encoders.
+
+# 3 Bias Quantification Using Attention
+
+Despite the applicability of our work on any text encoder that is built upon self-attention, we focus in this paper on models based on the encoder side of the transformer architecture, such as BERT (Devlin et al., 2018), RoBERTa (Liu et al., 2019), or ALBERT (Lan et al., 2019). This owes to the decoder side being usually used in auto-regression tasks, and less often to encode text.
+
+In this section, we present our metric to compute the amount of bias that is encoded in attention across an entire corpus $\mathbb{S}$ . First, we identify bias types of interest such as gender, race, religion. This is achieved by defining a set of tuples $\mathbb{G}$ for every
+
+| religion | gender |
| muslim, christian, jewish | he, she |
| quran, bible, torah | man, woman |
+
+Table 1: Examples of group tuples per bias
+
+bias type such that $\mathbb{G} = \{\mathcal{T}_1,\mathcal{T}_2,\dots,\mathcal{T}_k\}$ where each $\mathcal{T}_i$ describes social groups, or their attributes. Table 1 shows some possible values for $\mathcal{T}_i$ that we use in our study. Then, for every sentence $s$ in $\mathbb{S}$ , we randomly pick a tuple $\mathcal{T}_i$ from $\mathbb{G}$ and construct $s_g$ , an artificial sentence formed by words of $\mathcal{T}_i$ . For example, given Table 1, $s_g$ can be " muslim, christian, Jewish" or "man, woman". Finally, we use both $s$ and $s_g$ to make two-sentence inputs similar to the examples of Figure 1.
+
+After augmenting the corpus with artificial group-related sentences, we feed each augmented input to the text encoder under study, and collect the resulting self-attention weights. Each token in the augmented input distributes its attention on all other tokens according to their importance. Thus, every group in $s_g$ has its own attention allocation, i.e. the vector consisting of attention weights that tokens in $s$ give to the current group token. We declare bias in this case as the difference between attention allocations of groups. In other words, if the sentence distributes its attention on social groups differently (e.g. doctor in Figure 1 attends to he and not to she), then there is bias. Specifically, we measure Pearson correlation between attention allocations of social groups in a given attention head, aggregated over a corpus:
+
+$$
+\operatorname {B i a s} (\mathbb {S}, \mathbb {G}) = \frac {1}{| \mathbb {S} | | \mathbb {G} |} \sum_ {s \in \mathbb {S}} \sum_ {s _ {g} \in \mathbb {G}} \frac {1}{\left| \binom {\mathbb {G}} {2} \right|} \sum_ {i, j \in \binom {\mathbb {G}} {2}} \rho \left(A _ {s} ^ {g _ {i}}, A _ {s} ^ {g _ {j}}\right) \tag {1}
+$$
+
+where $\rho$ is Pearson correlation, $\binom{\mathbb{G}}{2}$ produces all possible pairs of social groups given a tuple, $A_{s}^{g_{i}}$ is the attention vector that sentence $s$ allocates to group $g_{i}$ . If this quantity is close to 0, we can say that attention exhibits bias since the average of correlations across sentences and groups is nearly 0. We use the News-commentary-v15 corpus as evaluation data and compute attention bias of BERT. We present the results for each attention head and for each bias type in Figure 2.
+
+We observe that BERT's attention heads encode different stereotypes with different intensities, conforming to the findings of Bhardwaj et al. (2021). Also, the lower layers of attention appear to encode more bias than the top layers since their heads are much darker. We believe this to be the consequence of lower layers being more aware of the input tokens, while top layers are fed transformations of the input as it flows through the attention stack.
+
+We also compute attention bias on BERT heads after applying different existing debiasing approaches, and present the results for gender bias in Figure 3. When we compare the heatmaps in Figure 3 to the heatmap of Figure 2(a), we notice that they are very similar, and attention bias is hardly removed. In some cases, it is even amplified (e.g. head 3 in layer 10 in Figure 3(a)). We stipulate that even though those debiasing methods show acceptable results with embedding-based bias evaluations, they appear to ignore the bias reflected in attention and thus can be recovered at prediction. In the next section, we present our own debiasing methods that aims to reduce bias from the top $k$ most biased attention heads.
+
+# 4 Debiasing Method
+
+The first step of AttenD is augmenting each sentence $s$ in the training corpus $\mathbb{S}$ with an artificial second input $s_g$ consisting of words related to groups of a given bias type, as explained in Section 3 and in the examples of Figure 1. Then, we finetune the encoder's parameters such that the top $k$ most biased heads produce equalized attention on groups, i.e. each token in $s$ pays the same amount of attention to tokens of $s_g$ , thus eliminating preferences and stereotypes. We minimize semantic loss by compelling the model to learn the original semantics from an unaltered teacher model by copying its internal attention.
+
+We schematize the operation of AttenD in Figure 4. $Gr_{1}, Gr_{2}$ and $Gr_{n}$ in the figure correspond to the tokens of $s_{g}$ . Both matrices represent one attention head of the text encoder before (left) and after (right) debiasing. The matrices should be read in rows. Each row depicts the attention weights of the corresponding token on all the other tokens of the input $(s + s_{g})^{7}$ . The matrices are conceptually split in four blocks: (1) attentions of $s$ on $s$ , (2) attentions of $s$ on $s_{g}$ , (3) attentions of $s_{g}$ on $s$ ,
+
+
+(a)
+
+
+(b)
+
+
+(c)
+
+
+(a)
+
+
+Figure 2: Attention bias in BERT base broken out by layer and head. (a) gender, (b) race, (c) religion
+(b)
+
+
+(c)
+
+
+Figure 3: Attention bias in BERT base broken out by layer and head after the application of several debiasing methods to reduce gender bias. These debiasing methods are (a) CDA (b) Sent-D (Liang et al., 2020a), (c) Kaneko Kaneko and Bollegala (2021)
+(a)
+Figure 4: Overview of an attention head before (a) and after (b) debiasing
+
+
+(b)
+
+and (4) attentions of $s_g$ on $s_g$ . Debiasing consists in making the columns of block 2 equal. In other words, each token in $s$ pays the same amount of attention to all the groups as indicated in the right side of Figure 4. We preserve the semantics of the original text encoder by keeping block 1 of Figure 4 unchanged. Both blocks 3 and 4 are irrelevant to the results, since they denote attentions of our artificially inserted second input $s_g$ . So, we do not impose any restrictions on them. In the following, we describe the important details of AttenD.
+
+# 4.1 Equalizing attentions on social groups
+
+The rationale behind attention equalization is to eliminate any inclination for the encoder to prefer any social group to the detriment of others. Equalizing attention vectors of block 2 (as defined in Figure 4) is equivalent to making them equal to a pivot vector. In our method, we consider the attention vector of $s$ on the first social group as the pivot (first column in block 2 of Figure 4), and minimize the mean square error between the pivot and the attention vectors of $s$ on the other groups, one at a time. Suppose $\mathbf{A}^{l,h,s,s_g} = Attn(s,s_g;l,h)$ is the attention matrix at layer $l$ , head $h$ of the encoder $E$ , computed from the input $s + s_g$ . The equalization loss is given by Equation 2.
+
+$$
+L _ {e q u} = \sum_ {s \in \mathbb {S}} \sum_ {l = 1} ^ {L} \sum_ {h = 1} ^ {H} \sum_ {i = 2} ^ {| | s _ {g} | |} | | \mathbf {A} _ {: \sigma , \sigma + 1} ^ {l, h, s, s _ {g}} - \mathbf {A} _ {: \sigma , \sigma + i} ^ {l, h, s, s _ {g}} | | _ {2} ^ {2} \tag {2}
+$$
+
+where $L$ is the number of layers of the text encoder, $H$ the number of heads, $\| s_g\|$ the number of social groups in $s_g$ and $\sigma$ is the position of the special token [SEP] that marks the end of $s$ and the beginning of $s_g$ . As can be seen, $\mathbf{A}_{: \sigma, \sigma + 1}^{l, h, s, s_g}$ is the
+
+pivot vector containing attention scores of $s$ on the first social group token (whose position is directly after [SEP], i.e., $\sigma + 1$ ). Equation 2 forces attention scores on subsequent social groups to be the same as on the first one, thus making them all equal. We also experiment with choosing the last group as pivot, or pick one at random. We find that these alternatives produce comparable results.
+
+# 4.2 Preserving semantic information
+
+We minimize semantic information loss in a knowledge distillation setting, where we recruit another model to be the teacher, and cast the text encoder that we want to debias as the student (Hinton et al., 2015; Gou et al., 2021). We initialize the student from the teacher. We do not apply our debiasing strategy on the teacher since it provides a reference to the original unaltered language representations. We compel the student to copy the teacher's attention for every input in the training corpus $\mathbb{S}$ .
+
+As in Section 4.1, let $\mathbf{A}^{l,h,s,s_g}$ be the attention of the student model at layer $l$ , head $h$ with $s$ and $s_g$ as input. Likewise, let $\mathbf{O}^{l,h,s,s_g}$ define the teacher's attention matrix. We formalize the preservation of semantic information as a regularizer where we minimize the squared $l_2$ distance between the student's and the teacher's attention scores.
+
+$$
+L _ {\text {d i s t i l}} = \sum_ {s \in \mathbb {S}} \sum_ {l = 1} ^ {L} \sum_ {h = 1} ^ {H} \left\| \mathbf {A} _ {: \sigma ,: \sigma} ^ {l, h, s, s _ {g}} - \mathbf {O} _ {: \sigma ,: \sigma} ^ {l, h, s, s _ {g}} \right\| _ {2} ^ {2} \tag {3}
+$$
+
+As can be seen from Equation 3, the student learns only to replicate block 1 (as in Figure 4) of the attention matrices. This is because block 1 contains attention scores of the original input sentence $s$ on itself, thus encoding an important aspect of semantics. We force the student not to reproduce the attention distribution on social groups (block 2) from the teacher since these are supposedly biased, and are left to the care of our debiasing objective. We do not use the MLM loss since the teacher model is already trained using that objective. We describe the overall training objective as a linear combination of the previously defined losses, with $\lambda$ as a hyperparameter to control the weight of debiasing over semantic preservation.
+
+$$
+L o s s = L _ {d i s t i l} + \lambda L _ {e q u} \tag {4}
+$$
+
+# 4.3 Negative Sampling
+
+While learning to equalize attention on social groups that constitute the second half of the input,
+
+the text encoder bears the risk of distributing its attention uniformly on any second half, no matter what it is. This is particularly alarming when the text encoder is subsequently employed in double-sentence tasks (Wang et al., 2018) such as semantic textual similarity or sentence entailment.
+
+To overcome the above obstacle, we introduce negative sampling. Instead of using words related to social groups in order to generate the artificial second input $s_g$ , we randomly sample words (negative examples) from the vocabulary. In this case, we do not equalize the attentions but compel the student to copy its teacher even for blocks 2, 3 and 4. We do this in order to prevent the text encoder from learning to assign the same attention weight to all tokens of the second input when these do not define social groups. We control the ratio of negative examples with a hyperparameter $\eta$ .
+
+# 5 Evaluation
+
+In this section, we first describe our experimental setup, then evaluate AttenD from two viewpoints: fairness and representativeness. Fairness is traditionally evaluated with two types of metrics: intrinsic metrics that measure bias in text representations regardless of their application, and extrinsic metrics that quantify bias in downstream tasks that text representations enable. We acknowledge that intrinsic metrics have recently been criticized (Goldfarb-Tarrant et al., 2020; Aribandi et al., 2021; Blodgett et al., 2021). However, we believe that a strong evaluation of bias should include both intrinsic, extrinsic and qualitative methods to draw a comprehensive evaluation. Since Aribandi et al. (2021) surmise that StereoSet and Crows-Pairs are more stable than other intrinsic measures of bias (e.g. WEAT (Caliskan et al., 2017) or SEAT (May et al., 2019)), we use them in this work. For extrinsic metrics, we evaluate our method on the tasks of textual inference and hate speech detection. Due to space limitations, we move the second one to Appendix A.3, in addition to other qualitative evaluations and ablation studies8.
+
+# 5.1 Debiasing setup
+
+To facilitate comparison, we follow existing literature (Nadeem et al., 2020; Nangia et al., 2020) in defining social groups for each type of bias, although the approach presented here is not restricted
+
+| Model | gender | race | religion | Overall |
| BERT | 84.52 | 79.65 | 82.57 | 82.25 |
| Sent-D | 86.45 | 79.27 | 82.98 | 82.90 |
| Kaneko | 82.71 | 75.34 | 78.13 | 78.73 |
| CDA | 82.50 | 73.92 | 78.39 | 78.61 |
| AttenD | 93.85 | 93.64 | 93.85 | 93.78 |
+
+Table 2: Attention bias on BERT before and after applying debiasing methods, the higher the better
+
+to that, and can be leveraged for both other kinds of biases and for a more inclusive definition of the groups. In the experiments, we show results of debiasing based on (binary) gender (male, female), race (white, black, asian, hispanic) and religion ( muslim, christian, jewish, buddhist). We leverage the definition words from previous work (Liang et al., 2020a). The full list can be found in Appendix A.2. We apply AttenD on BERT $^{9}$ (Devlin et al., 2018), and use the News-commentary-v15 corpus $^{10}$ as training data. It contains 223,153 sentences of which we use $80\%$ for training and $20\%$ for development. As for the top $k$ most biased heads, we find that debiasing all heads works best in practice for all text encoders under study. Thus, we set the top $k$ to the maximum number of heads for every model. Appendix A.1 contains details about hyperparameter search.
+
+# 5.2 Evaluations of Fairness
+
+# 5.2.1 Intrinsic Evaluation
+
+We start by quantifying the amount of attention bias described in Section 3 in BERT base before and after applying AttenD. For accurate comparisons against previous work, we decided to include the baselines whose final debiased models have been published in order to avoid errors of training and/or tuning hyperparameters. Thus, we compare AttenD against (1) Sent-D (Liang et al., 2020a) which extended the method of Hard-Debias (Bolukbasi et al., 2016) to work on transformer-based text encoders, (2) the debiasing procedure proposed by Kaneko and Bollegala (2021) that finetunes the text encoder to minimize the projection of its embeddings on a predefined bias subspace, and (3) CDA. We also conduct a simple ablation study by training without negative examples $(AttenD^{-})$ when necessary. We use the development set of
+
+the News-commentary-v15 corpus to compute bias scores, and report the results in Table 2.
+
+Although existing debiasing methods have been shown to reduce bias in embeddings (Liang et al., 2020a; Kaneko and Bollegala, 2021), we observe that they do very little to reduce it in attention. In fact, the method of Kaneko and Bollegala (2019) and CDA induce the model to encode more bias in the attention layer, which might make it to resurface in predictions if not addressed correctly.
+
+In the following, we demonstrate that AttenD is also capable of mitigating bias from text representations and likelihoods. To do that, we finetune text encoders of interest before and after applying debiasing methods on the language modeling task. Then, we use the publicly available subsets of two stereotype benchmarks: StereoSet (Nadeem et al., 2020) and Crows-Pairs (Nangia et al., 2020). Both provide likelihood-based diagnostics to measure how often stereotypes are considered likelier than anti-stereotypes, given the language model's likelihoods. An ideal unbiased text encoder should score $50\%$ in these benchmarks, i.e. it prefers neither stereotypes nor anti-stereotypes. Table 3 provides the evaluation results. StereoSet also provides a means to compute a language modeling (LM) score whose purpose is to check whether the encoder is still good at the task of language modeling, and that debiasing didn't hurt semantic performance.
+
+We observe that AttenD shows impressive debi- aising performance when evaluated with likelihood-based diagnostics. Improvements go up to $9.53\%$ with a slight decrease in the accuracy of language modeling $(-1.43\%)$ . We notice that our method yields the best results overall, and illustrates that reducing biases from attention directly helps with mitigating them from the model as a whole. Table 3 shows that using negative examples minimizes semantic information loss.
+
+# 5.2.2 Extrinsic Evaluation
+
+This approach of measuring bias builds on the intuition of Dev et al. (2020) stating that biased representations lead to invalid inferences, whose ratio quantifies bias. They construct a challenge benchmark for the natural language inference task where every hypothesis should be neutral to its premise. For example, suppose that the premise is The driver owns a van and the hypothesis is The man owns a van. The hypothesis neither entails nor contradicts the premise. If the predictions of a classifier deviate from neutrality, the underlying text encoder is
+
+| Model | Crows-Pairs | StereoSet | LM |
| gender | race | religion | Overall | gender | race | religion | Overall |
| BERT | 58.02 | 58.14 | 71.43 | 60.48 | 62.75 | 54.68 | 56.41 | 56.04 | 83.70 |
| Sent-D | 51.53 | 55.23 | 60.0 | 56.90 | 53.33 | 55.09 | 51.28 | 54.71 | 81.39 |
| Kaneko | 57.63 | 53.68 | 64.76 | 57.82 | 58.82 | 56.24 | 57.69 | 56.04 | 85.58 |
| CDA | 54.58 | 50.78 | 60.95 | 55.06 | 55.69 | 53.01 | 53.85 | 54.18 | 81.38 |
| AttenD- | 53.05 | 53.68 | 69.52 | 57.23 | 51.37 | 54.37 | 55.13 | 53.37 | 80.92 |
| AttenD | 51.53 | 50.78 | 61.90 | 54.58 | 54.51 | 52.29 | 56.41 | 53.18 | 82.27 |
+
+Table 3: Stereotype scores on BERT before and after applying debiasing methods. The closer to 50, the better. However, for the language modeling score (LM), the higher the better.
+
+| Model | Bias type | NN | FN | τ:0.5 | τ:0.7 |
| BERT | gender | 36.38 | 36.45 | 36.06 | 33.96 |
| race | 75.96 | 76.57 | 76.51 | 74.91 |
| religion | 43.47 | 43.55 | 43.45 | 41.77 |
| Sent-D | gender | 44.74 | 45.10 | 44.54 | 42.06 |
| race | 59.61 | 59.28 | 59.20 | 56.22 |
| religion | 29.64 | 29.08 | 29.02 | 27.24 |
| Kaneko | gender | 53.15 | 53.33 | 52.75 | 49.65 |
| race | 84.24 | 84.84 | 84.80 | 83.26 |
| religion | 69.27† | 69.80† | 69.72† | 67.66† |
| CDA | gender | 64.00 | 65.38 | 64.70 | 61.19 |
| race | 77.33 | 77.79 | 77.78 | 75.93 |
| religion | 49.00 | 49.03 | 48.97 | 46.78 |
| AttenD | gender | 65.91 | 67.10 | 66.69 | 63.59 |
| race | 92.26 | 92.77 | 92.74 | 91.79 |
| religion | 68.51 | 69.08 | 68.95 | 66.97 |
+
+assumed biased. Suppose that the set contains $M$ instances, and let the predictor's probabilities of the $i^{th}$ instance for entail, contradict and neutral be $e_i$ , $c_i$ and $n_i$ . Following Dev et al. (2020), we report three measures of inference-based bias: (1) Net Neutral (NN): $NN = \frac{1}{M} \sum_{i=1}^{M} n_i$ ; (2) Fraction Neutral (FN): $FN = \frac{1}{M} \sum_{i=1}^{M} \mathbf{1}_{n_i = \max(e_i, c_i, n_i)}$ ; (3) Threshold $\tau$ ( $\mathbf{T} : \tau$ ): $T : \tau = \frac{1}{M} \sum_{i=1}^{M} \mathbf{1}_{n_i > \tau}$ .
+
+In this experiment, we finetune text encoders on MNLI dataset for natural language inference (Wang et al., 2018). A bias-free model should score 1 (100%) in all three measures. We report our findings in Table 4. Our method outperforms the original model and the baselines. This result shows that AttenD succeeds in mitigating stereotypes in real world inference settings. We also debias hate speech detection models and report the results in Appendix A.3.
+
+Table 4: Inference-based bias measurements. Best scores are highlighted in bold, underlined, or marked with $\dagger$ for gender, race and religion $\dagger$ respectively
+
+| Models | Single sentence | Double sentence |
| sst2 | cola | stsb | mrpc | mnli (m/mm) | rte | wnli |
| BERT | 92.78 | 56.05 | 88.97 | 92.25 | 83.54 / 82.68 | 70.04 | 45.07 |
| Sent-D | 91.63 | 59.08 | 89.58 | 90.12 | 84.97 / 83.51 | 68.95 | 28.17 |
| Kaneko | 91.97 | 56.50 | 88.44 | 90.69 | 84.48 / 83.66 | 59.93 | 52.11 |
| CDA | 92.32 | 55.98 | 88.93 | 90.60 | 84.31 / 82.26 | 64.26 | 25.35 |
| AttenD | 92.32 | 56.25 | 81.12 | 80.44 | 84.59 / 83.96 | 58.12 | 39.44 |
| AttenD | 92.66 | 55.22 | 89.62 | 91.22 | 84.63 / 84.19 | 70.40 | 53.52 |
+
+Table 5: Performance of different models on GLUE tasks. The table shows accuracy scores for sst2, rte, wnli, and mnli for both matched and mismatched instances; $f1$ for mrpc; spearman correlation for stsb; and matthews correlation for cola
+
+# 5.3 Evaluations of Semantic Preservation
+
+We use GLUE benchmark (Wang et al., 2018) to verify whether the debiased text encoder still holds enough semantic information to be applicable in downstream NLP tasks. In essence, GLUE assesses the natural language understanding capabilities of NLP models. So, it constitutes a suitable stack to evaluate the semantic preservation of AttenD. In this experiment, we finetune our debiased models on seven different tasks from GLUE and show that per-task accuracy is preserved in Table 5. We also observe that not using negative examples (AttenD-) severely hurts semantics.
+
+# 6 Conclusion
+
+We proposed in this paper to pay closer attention to the attention mechanism of text encoders. Specifically, we find that social bias also resides in attention weights, in addition to in representations and embeddings. We characterize attention bias in text encoders by looking at which demographics are most relevant given a stereotypical scenario under different attention maps in various layers. Our bias quantification method is a weighted average of Pearson correlations between attention allocations for demographic group words. We also propose a novel debiasing method by modifying
+
+the self-attention weights so as to ensure equal attention activations across all group words for each token in each input sentence. At the same time, we use knowledge distillation from a teacher text encoder to preserve the useful semantics contained within. Finally, we utilize negative sampling with non-demographic word sets as the second sentence, where the teacher objective rather than attention equalization objective is applied, to prevent sentence-pair functionality in text encoders from being destroyed. We find that by mitigating biases from attention, the overall model bias is also reduced. We demonstrate this with various experiments that probe for bias internally, and when text encoders are used in downstream tasks, namely sentence inference and hate speech detection with limited costs to semantic usefulness.
+
+# 7 Limitations
+
+AttenD introduces many advantages. It is intuitive, simple in implementation, and inexpensive in terms of data resources. Also, the definitions of bias types and social groups in AttenD are extremely easy and flexible. However, we are aware of the following limitations: (1) There are more social divisions in the real world than the three dimensions we studied. Besides, bias types can be correlated in intricate ways, and it is not clear which or how many groups to include. For these reasons, we follow previous work and constrain our experiments to common use-cases. (2) We calibrate attention scores of every word in the input. However, some words are inherently charged with a strong inclination toward one group, e.g., *beard* to *male* or *pregnant* to *female*. Such words need not be debiased, which requires compiling expensive lists of related words for every social group and protecting them from attention equalization. We rely on knowledge distillation to retain as much useful semantic information as possible in order to assuage this concern. (3) We use discrete words for debiasing, and it is not obvious how to extend this to treat implicit bias (e.g. bias existing between *doctor* and *engineer* because they are both stereotyped to be rather occupations for men) or bias toward finer-grained groups, e.g. female muslims, or Buddhist Black Americans. (4) The template structure that we use for bias quantification and reduction does not necessarily capture all forms of social bias that are potentially concealed in the attention mechanism. Bias can also be internally
+
+encoded in attention weights in templates different from "sentence from a corpus [SEP] demographic 1 demographic 2 demographic $3''$ . For example, instead of declaring bias as a difference in attention of the original sentence on social groups, we do the reverse and focus on the attention of groups on the sentence. Or we can analyze the attention distribution of demographics on attributes such as occupations or polarity adjectives, by using templates such as "sentence describing a person in a demographic group [SEP] occupation 1 occupation 2 occupation $3''$ . We believe that calibrating the attention of demographics on occupation terms helps in reducing implicit bias, at least the one related to occupations. Also, different kinds of template structures should be used in order to capture the most complete notion of attention bias possible. These points constitute sound and promising future directions for our research. We plan to address them all in upcoming work.
+
+# 8 Ethical Considerations
+
+We propose a debiasing method based on equalizing and calibrating the attention of text encoders on mentions of social groups. Although the approach is, in itself, independent from the choice of such groups, or the selection of identity terms and definition words that characterize these groups, we focus in our experiments on bias types and groups commonly used in the debiasing literature; namely binary gender, race and religion. We have shown that our method works for both binary and multiclass groups. That being said, we have not experimented yet with demographics divided into dozens of categories, e.g. nationality, or the full scope of gender. We also did not include analysis for groups who are victims of under-criticized microaggressions such as old people, fat people or people suffering from physical/mental disabilities. We justify our experimental decisions with the following: (1) Current work in the literature focuses primarily on the three major demographic dimensions. So to facilitate comparison, we used that too. (2) Existing benchmarks to quantify the amount of bias in text encoders are often limited to binary gender, race and religion. So even though our approach enables the reduction of bias for minority groups, we have no reliable data and benchmarks to assess whether debiasing is indeed effective for such groups. We encourage researchers and data collectors in the field to produce more inclusive benchmarks in the
+
+future.
+
+We would like to remind all users that our models are not perfect, even after going through debiasing. Although our experiments show that bias is indeed reduced, it is not completely mitigated. Also, there is the possibility that finetuning on the Newscommentary-v15 corpus might introduce new biases encoded in the data. More generally, the bias detection experiments used in this paper and in all related work have positive predictive ability, which means that they can only detect the presence of bias, not the absence of it. So it is possible that bias is still hiding under different forms that current experimental lenses fail to detect. We believe that the community needs to include some aspect of human evaluation to faithfully assess the stereotypical propensities of text encoders. We project to do that in future work.
+
+# References
+
+Vamsi Aribandi, Yi Tay, and Donald Metzler. 2021. How reliable are model diagnostics? In *Findings of the Association for Computational Linguistics: ACL-IJCNLP* 2021, pages 1778-1785.
+Giuseppe Attanasio, Debora Nozza, Dirk Hovy, and Elena Baralis. 2022. Entropy-based attention regularization frees unintended bias mitigation from lists. In *Findings of the Association for Computational Linguistics: ACL* 2022, pages 1105-1119.
+Jasmijn Bastings and Katja Filippova. 2020. The elephant in the interpretability room: Why use attention as explanation when we have saliency methods? In Proceedings of the Third BlackboxNLP Workshop on Analyzing and Interpreting Neural Networks for NLP, pages 149-155.
+Rishabh Bhardwaj, Navonil Majumder, and Soujanya Poria. 2021. Investigating gender bias in bert. Cognitive Computation, pages 1-11.
+Su Lin Blodgett, Solon Barocas, Hal Daumé III, and Hanna Wallach. 2020. Language (technology) is power: A critical survey of "bias" in nlp. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5454-5476.
+Su Lin Blodgett, Gilsinia Lopez, Alexandra Olteanu, Robert Sim, and Hanna Wallach. 2021. Stereotyping norwegian salmon: an inventory of pitfalls in fairness benchmark datasets. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 1004-1015.
+Tolga Bolukbasi, Kai-Wei Chang, James Y Zou, Venkatesh Saligrama, and Adam T Kalai. 2016. Man
+
+is to computer programmer as woman is to homemaker? debiasing word embeddings. Advances in neural information processing systems, 29:4349-4357.
+Shikha Bordia and Samuel Bowman. 2019. Identifying and reducing gender bias in word-level language models. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Student Research Workshop, pages 7-15.
+Daniel Borkan, Lucas Dixon, Jeffrey Sorensen, Nithum Thain, and Lucy Vasserman. 2019. Nuanced metrics for measuring unintended bias with real data for text classification. In *Companion proceedings of the 2019 world wide web conference*, pages 491-500.
+Pete Burnap and Matthew L Williams. 2016. Us and them: identifying cyber hate on twitter across multiple protected characteristics. *EPJ Data science*, 5:1-15.
+Aylin Caliskan, Joanna J Bryson, and Arvind Narayanan. 2017. Semantics derived automatically from language corpora contain human-like biases. Science, 356(6334):183-186.
+Jose Camacho-Collados and Mohammad Taher Pilehvar. 2018. From word to sense embeddings: A survey on vector representations of meaning. Journal of Artificial Intelligence Research, 63:743-788.
+Pengyu Cheng, Weituo Hao, Siyang Yuan, Shijing Si, and Lawrence Carin. 2020. Fairfil: Contrastive neural debiasing method for pretrained text encoders. In International Conference on Learning Representations.
+Kevin Clark, Urvashi Khandelwal, Omer Levy, and Christopher D Manning. 2019. What does bert look at? an analysis of bert's attention. In Proceedings of the 2019 ACL Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pages 276-286.
+Robert Dale. 2019. Law and word order: Nlp in legal tech. Natural Language Engineering, 25(1):211-217.
+Jeffrey Dastin. 2018. Amazon scraps secret ai recruiting tool that showed bias against women. In *Ethics of Data and Analytics*, pages 296-299. Auerbach Publications.
+Sunipa Dev, Tao Li, Jeff M Phillips, and Vivek Srikumar. 2020. On measuring and mitigating biased inferences of word embeddings. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 7659-7666.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805.
+
+Mark Díaz, Isaac Johnson, Amanda Lazar, Anne Marie Piper, and Darren Gergle. 2018. Addressing age-related bias in sentiment analysis. In Proceedings of the 2018 chi conference on human factors in computing systems, pages 1-14.
+Lucas Dixon, John Li, Jeffrey Sorensen, Nithum Thain, and Lucy Vasserman. 2018. Measuring and mitigating unintended bias in text classification. In Proceedings of the 2018 AAAI/ACM Conference on AI, Ethics, and Society, pages 67-73.
+Yanai Elazar and Yoav Goldberg. 2018. Adversarial removal of demographic attributes from text data. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 11-21.
+Yacine Gaci, Boualem Benatallah, Fabio Casati, and Khalid Benabdeslem. 2022a. Iterative adversarial removal of gender bias in pretrained word embeddings. In Proceedings of the 37th ACM/SIGAPP Symposium On Applied Computing, pages 829-836.
+Yacine Gaci, Boualem Benatallah, Fabio Casati, and Khalid Benabdeslem. 2022b. Masked language models as stereotype detectors? In EDBT 2022.
+Seraphina Goldfarb-Tarrant, Rebecca Marchant, Ricardo Muñoz Sanchez, Mugdha Pandya, and Adam Lopez. 2020. Intrinsic bias metrics do not correlate with application bias. arXiv preprint arXiv:2012.15859.
+Hila Gonen and Yoav Goldberg. 2019. Lipstick on a pig: Debiasing methods cover up systematic gender biases in word embeddings but do not remove them. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 609-614.
+Jianping Gou, Baosheng Yu, Stephen J Maybank, and Dacheng Tao. 2021. Knowledge distillation: A survey. International Journal of Computer Vision, 129(6):1789-1819.
+C Hansen, M Tosik, G Goossen, C Li, L Bayeva, F Berbain, and M Rotaru. 2015. How to get the best word vectors for resume parsing. In SNN Adaptive Intelligence/Symposium: Machine Learning.
+Geoffrey Hinton, Oriol Vinyals, and Jeff Dean. 2015. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531.
+Benjamin Hoover, Hendrik Strobelt, and Sebastian Gehrmann. 2020. exbert: A visual analysis tool to explore learned representations in transformer models. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics: System Demonstrations, pages 187-196.
+Forrest Iandola, Albert Shaw, Ravi Krishna, and Kurt Keutzer. 2020. Squeezebert: What can computer vision teach nlp about efficient neural networks? In
+
+Proceedings of SustaiNLP: Workshop on Simple and Efficient Natural Language Processing, pages 124-135.
+Sarthak Jain and Byron C Wallace. 2019. Attention is not explanation. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 3543-3556.
+Masahiro Kaneko and Danushka Bollegala. 2019. Gender-preserving debiasing for pre-trained word embeddings. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 1641-1650.
+Masahiro Kaneko and Danushka Bollegala. 2021. Debiasing pre-trained contextualised embeddings. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 1256-1266.
+Diederik P Kingma and Jimmy Ba. 2014. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980.
+Vaibhav Kumar, Tenzin Singhay Bhotia, and Tanmoy Chakraborty. 2020. Nurse is closer to woman than surgeon? mitigating gender-biased proximities in word embeddings. Transactions of the Association for Computational Linguistics, 8:486-503.
+Keita Kurita, Nidhi Vyas, Ayush Pareek, Alan W Black, and Yulia Tsvetkov. 2019. Quantifying social biases in contextual word representations. In 1st ACL Workshop on Gender Bias for Natural Language Processing.
+Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma, and Radu Soricut. 2019. Albert: A lite bert for self-supervised learning of language representations. arXiv preprint arXiv:1909.11942.
+Anne Lauscher, Tobias Lüken, and Goran Glavaš. 2021. Sustainable modular debiasing of language models. arXiv preprint arXiv:2109.03646.
+Yitong Li, Timothy Baldwin, and Trevor Cohn. 2018. Towards robust and privacy-preserving text representations. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 25-30.
+Paul Pu Liang, Irene Mengze Li, Emily Zheng, Yao Chong Lim, Ruslan Salakhutdinov, and Louis Philippe Morency. 2020a. Towards debiasing sentence representations. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5502-5515.
+Sheng Liang, Philipp Dufter, and Hinrich Schütze. 2020b. Monolingual and multilingual reduction of gender bias in contextualized representations. In Proceedings of the 28th International Conference on Computational Linguistics, pages 5082-5093.
+
+Zachary C Lipton. 2018. The mythos of model interpretability: In machine learning, the concept of interpretability is both important and slippery. Queue, 16(3):31-57.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Thomas Manzini, Yao Chong Lim, Yulia Tsvetkov, and Alan W Black. 2019. Black is to criminal as Caucasian is to police: Detecting and removing multiclass bias in word embeddings. arXiv preprint arXiv:1904.04047.
+Binny Mathew, Punyajoy Saha, Seid Muhie Yimam, Chris Biemann, Pawan Goyal, and Animesh Mukherjee. 2021. Hatexplain: A benchmark dataset for explainable hate speech detection. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 14867-14875.
+Chandler May, Alex Wang, Shikha Bordia, Samuel R Bowman, and Rachel Rudinger. 2019. On measuring social biases in sentence encoders. In NAACL-HLT (1).
+Nicholas Meade, Elinor Poole-Dayan, and Siva Reddy. 2021. An empirical survey of the effectiveness of debiasing techniques for pre-trained language models. arXiv preprint arXiv:2110.08527.
+Nicholas Meade, Elinor Poole-Dayan, and Siva Reddy. 2022. An empirical survey of the effectiveness of debiasing techniques for pre-trained language models. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1878-1898.
+Moin Nadeem, Anna Bethke, and Siva Reddy. 2020. Stereoset: Measuring stereotypical bias in pretrained language models. arXiv preprint arXiv:2004.09456.
+Eric Nalisnick, Bhaskar Mitra, Nick Craswell, and Rich Caruana. 2016. Improving document ranking with dual word embeddings. In Proceedings of the 25th International Conference Companion on World Wide Web, pages 83-84.
+Nikita Nangia, Clara Vania, Rasika Bhalerao, and Samuel R Bowman. 2020. Crows-pairs: A challenge dataset for measuring social biases in masked language models.
+Ji Ho Park, Jamin Shin, and Pascale Fung. 2018. Reducing gender bias in abusive language detection. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2799-2804.
+Adam Paszke, Sam Gross, Soumith Chintala, Gregory Chanan, Edward Yang, Zachary DeVito, Zeming Lin, Alban Desmaison, Luca Antiga, and Adam Lerer. 2017. Automatic differentiation in pytorch.
+
+Danish Pruthi, Mansi Gupta, Bhuwan Dhingra, Graham Neubig, and Zachary C Lipton. 2020. Learning to deceive with attention-based explanations. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4782-4793.
+Yusu Qian, Urwa Muaz, Ben Zhang, and Jae Won Hyun. 2019. Reducing gender bias in word-level language models with a gender-equalizing loss function. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics: Student Research Workshop, pages 223-228.
+Shauli Ravfogel, Yanai Elazar, Hila Gonen, Michael Twiton, and Yoav Goldberg. 2020. Null it out: Guarding protected attributes by iterative nullspace projection. arXiv preprint arXiv:2004.07667.
+Manoel Horta Ribeiro, Pedro H Calais, Yuri A Santos, Virgílio AF Almeida, and Wagner Meira Jr. 2018. Characterizing and detecting hateful users on twitter. In Twelfth international AAAI conference on web and social media.
+Cynthia Rudin. 2019. Stop explaining black box machine learning models for high stakes decisions and use interpretable models instead. Nature Machine Intelligence, 1(5):206-215.
+Victor SANH, Lysandre DEBUT, Julien CHAUMOND, Thomas WOLF, and Hugging Face. Distilbert, a distilled version of bert: smaller, faster, cheaper and lighter.
+Maarten Sap, Saadia Gabriel, Lianhui Qin, Dan Jurafsky, Noah A Smith, and Yejin Choi. 2020. Social bias frames: Reasoning about social and power implications of language. In Association for Computational Linguistics.
+Timo Schick, Sahana Udupa, and Hinrich Schütze. 2021. Self-diagnosis and self-debiasing: A proposal for reducing corpus-based bias in nlp. Transactions of the Association for Computational Linguistics, 9:1408-1424.
+Niral Shah. 2019. "asians are good at math" is not a compliment: Stem success as a threat to personhood. Harvard Educational Review, 89(4):661-686.
+Emily Sheng, Kai-Wei Chang, Prem Natarajan, and Nanyun Peng. 2020. Towards controllable biases in language generation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, pages 3239-3254.
+Ian Tenney, James Wexler, Jasmijn Bastings, Tolga Bolukbasi, Andy Coenen, Sebastian Gehrmann, Ellen Jiang, Mahima Pushkarna, Carey Radebaugh, Emily Reif, et al. 2020. The language interpretability tool: Extensible, interactive visualizations and analysis for nlp models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 107-118.
+
+Deborah A Trytten, Anna Wong Lowe, and Susan E Walden. 2012. "asians are good at math. what an awful stereotype" the model minority stereotype's impact on asian american engineering students. Journal of Engineering Education, 101(3):439-468.
+
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in neural information processing systems, pages 5998-6008.
+
+Sumithra Velupillai, Hanna Suominen, Maria Liakata, Angus Roberts, Anoop D Shah, Katherine Morley, David Osborn, Joseph Hayes, Robert Stewart, Johnny Downs, et al. 2018. Using clinical natural language processing for health outcomes research: overview and actionable suggestions for future advances. Journal of biomedical informatics, 88:11-19.
+
+Jesse Vig. 2019a. Bertviz: A tool for visualizing multi-head self-attention in the bert model. In Proceedings of the 2019 ICLR Workshop on Debugging Machine Learning Models.
+
+Jesse Vig. 2019b. Visualizing attention in transformer-based language representation models. arXiv preprint arXiv:1904.02679.
+
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. 2018. Glue: A multi-task benchmark and analysis platform for natural language understanding. In Proceedings of the 2018 EMNLP Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pages 353-355.
+
+Liwen Wang, Yuanmeng Yan, Keqing He, Yanan Wu, and Weiran Xu. 2021. Dynamically disentangling social bias from task-oriented representations with adversarial attack. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 3740-3750.
+
+Kellie Webster, Xuezhi Wang, Ian Tenney, Alex Beutel, Emily Pittler, Ellie Pavlick, Jilin Chen, Ed Chi, and Slav Petrov. 2020. Measuring and reducing gendered correlations in pre-trained models. arXiv preprint arXiv:2010.06032.
+
+Sarah Wiegrefe and Yuval Pinter. 2019. Attention is not not explanation. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 11-20.
+
+Qizhe Xie, Zihang Dai, Yulun Du, Eduard Hovy, and Graham Neubig. 2017. Controllable invariance through adversarial feature learning. Advances in Neural Information Processing Systems, 30:585-596.
+
+Ziqi Zhang, David Robinson, and Jonathan Tepper. 2018. Detecting hate speech on twitter using a
+
+convolution-gru based deep neural network. In European semantic web conference, pages 745-760. Springer.
+
+Jieyu Zhao, Yichao Zhou, Zeyu Li, Wei Wang, and Kai-Wei Chang. 2018. Learning gender-neutral word embeddings. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 4847-4853.
+
+# A Appendix
+
+# A.1 Training Hyperparameters
+
+We used Adam optimizer (Kingma and Ba, 2014) with a learning rate of $5e^{-6}$ for 3 epochs. We keep the betas to their default values (0.9, 0.999) as in PyTorch implementation (Paszke et al., 2017). We set the loss coefficient $\lambda$ to 2.0 and the negative ratio $\eta$ to 0.8 meaning that in $80\%$ of the iterations, we use negative examples whose number we set to 5 in each negative iteration. For the number of heads $k$ having the top scores of attention bias, we experimented with different values for $k$ : {10, 20, 30, 50, 70, 100, all}. We found that debiasing all heads works best for all the text encoders that we experimented with. We only tuned the values of $\lambda$ , $\eta$ , $k$ , the learning rate, and the number of epochs. We conducted the hyperparameter search manually on the development set of the News-commentary-v15 corpus, and selected the hyperparameter configuration that maximized the attention-based bias metric. As for GLUE experiments, we follow the experimental setup of Devlin et al. (2018) and train each task for 3 epochs with a learning rate of $2e^{-5}$ on their respective training data. We ran all of our training and experiments on a NVIDIA Tesla V100 GPU.
+
+# A.2 Definition of bias types and social groups used in this paper
+
+While the approach is independent of the definition of social groups and categories (it could work for any kind of grouping, e.g., cuisine styles or sports), in the experiment we focus on groups commonly used in the debiasing literature: binary gender, religion and race. This is to facilitate comparison, but nothing in the approach prevents it from being used with broader and more inclusive groups. This being said, we have not experimented yet with debiasing where a dimension is divided in dozens of categories.
+
+We list the definition tuples that we used in Table 6. We show that AttenD does not incur strict rules for defining social groups, unlike previous
+
+work (Bolukbasi et al., 2016; Kaneko and Bollegala, 2019, 2021) that require the definition words to be organized in a predefined format (pairs of words or bag of words for every group), and provided in relatively large quantities. We can see from Table 6 that it is sufficient to define one tuple per bias type (e.g., race) if the tuples are hard to come by. Also, the tuples need not be of the same size (e.g., in religion there is a missing word for buddhist group since it is not clear which word to use in that tuple). This desired property owes to the fact that AttenD does not learn subspaces or directions for every bias type as previous works do (Bolukbasi et al., 2016; Kaneko and Bollegala, 2019; Kumar et al., 2020; Kaneko and Bollegala, 2021). In contrast, AttenD uses the tuples in order to equalize the attentions of the input sentence, and make the words therein attend to the groups with the same intensity. These example categories used in experiments are neither complete nor exhaustive, and in some experiments also include terms possibly considered inappropriate but that appear in the corpus and we may still want to debias from.
+
+# A.3 Extrinsic bias evaluation on the task of hate-speech detection
+
+Recent studies show that intrinsic metrics of bias do not necessarily correlate with bias measures on concrete real-world applications (Goldfarb-Tarrant et al., 2020). In the body of this paper, we already conducted intrinsic and extrinsic bias evaluations. In this experiment, we validate the efficacy of our debiasing method on a concrete real-world hate speech detection application where an input snippet of text is classified as either offensive (toxic, harmful, disrespectful, etc.) or not. We use hate speech detection because it is well studied in the literature (Burnap and Williams, 2016; Ribeiro et al., 2018; Zhang et al., 2018), and high-quality datasets which are tagged with social groups already exist (Borkan et al., 2019; Mathew et al., 2021).
+
+Admittedly, common social biases have also been shown to exist in hate speech detection models, for example in associating toxicity to frequently attacked groups (such as "muslim" or "gay") even if the text itself is not toxic (Dixon et al., 2018; Park et al., 2018). In this experiment, we adopt the bias definition of Borkan et al. (2019) which casts bias as a skewing in the hate speech detector scores based solely on the social groups mentioned in the text. In other words, we consider a model to
+
+exhibit unintended social stereotypes if the model's performance varies across groups. We use the bias measures proposed by Borkan et al. (2019) which are based on the Area Under the Receiver Operating Characteristic Curve (ROC-AUC, or AUC) metric. AUC measures the probability that a randomly chosen negative example (not offensive) receives a lower toxicity score than a randomly chosen positive example (offensive), meaning that a perfect model should always have an AUC score of 1.0. Stated differently, all negative examples have lower toxicity scores than positive examples. While AUC is used to measure the general performance of classifiers, Borkan et al. (2019) propose three extensions of AUC to measure bias. We summarize them in the following:
+
+Subgroup (Sub) AUC: where AUC is computed only on the group under consideration and not on all the examples of the test benchmark, i.e. only positive and negative examples of the target group are considered. This metric represents the model's performance on a given group. A higher value means that the model is good at distinguishing between toxic and non-toxic texts specific to the group.
+
+Background Positive Subgroup Negative (BPSN) AUC: where AUC is calculated on the negative examples of the target group, and the positive examples of the background (all other groups except the group under consideration). This metric computes whether the model discriminates against the target group with respect to the others. This value is reduced when non-toxic examples of the group have higher toxicity scores than actually toxic examples of the background.
+
+Background Negative Subgroup Positive (BNSP) AUC: where AUC is calculated on the positive examples of the target group, and the negative examples of the background. This metric computes whether the model favors the target group with respect to the others. This value is reduced when toxic examples of the group have lower toxicity scores than non-toxic examples of the background.
+
+In this experiment, we finetune the text encoder under study on hate speech detection task using the training set of HateXplain dataset (Mathew et al., 2021). We also use the test portion of HateXplain for the evaluation, which contains posts from Twitter11 and Gab12 annotated with their ground-truth
+
+| gender | religion |
| male | female | muslim | christian | jewish | buddhist |
| man | woman | muslim | christian | jewish | buddhist |
| boy | girl | muslims | christians | jews | buddhist |
| father | mother | islam | christianity | judaism | buddhism |
| brother | sister | mosque | church | synagogue | temple |
| grandfather | grandmother | quran | bible | torah | |
| son | daughter | imam | priest | rabbi | monk |
| gentleman | lady | mohammad | jesus | moses | buddha |
| he | she | | | | |
| his | her | | | | |
| himself | herself | | | | |
| race |
| white | black | asian | hispanic | | |
| white | black | asian | hispanic | | |
+
+Table 6: Full list of definition tuples for bias types and social groups used in this work
+
+toxicity scores and the social groups and communities they target. Fundamentally, the three metrics described above give bias scores per group. In order to combine the per group scores in one overall measure, we apply the Generalized Mean of Bias (GMB) introduced by the Google Conversation AI Team as part of their Kaggle competition $^{13}$ , and later used by Mathew et al. (2021) in their own evaluations. The formula of GMB is as the following:
+
+$$
+G M B (b) = \left(\frac {1}{| b |} \sum_ {g = 1} ^ {| b |} b _ {g} ^ {p}\right) ^ {1 / p} \tag {5}
+$$
+
+where $b$ is an array of AUC scores per group, and $b_{g}$ is the AUC score of group $g$ . We follow Mathew et al. (2021) and set $p$ to -5. We compute the GMB of all three metrics: Subgroup, BPSN and BNSP. As for Subgroup, we also add the standard deviation as it gives valuable information about how much the performance of the hate speech detection model varies across groups. We report our results in Table 7, in addition to classic performance measures.
+
+We observe that AttenD provides competitive results across the four bias metrics, and largely outperforms the baselines. Especially with GMB-BNSP, where bias scores of the original model are very low (i.e. it is throttled by social biases), we observe the best improvements overall, and by a large margin compared to existing debiasing methods. Also, the variance in model performance is
+
+lowest with AttenD, which confirms that the corresponding hate speech detection model has less stereotypes about different social groups. Finally, the general performance (Accuracy, F1 score and AUC) of the hate speech detection model after debiasing is not hurt.
+
+# A.4 Visualizing debiasing results
+
+In this experiment, we aim to visualize the effects of debiasing on attention weights. We only focus on binary gender bias for two reasons: First, it is easier to visualize binary variables on a 2D plane than multiclass variables (such as race, religion...). Second, gender is the most well studied bias type (Bolukbasi et al., 2016; Caliskan et al., 2017; May et al., 2019), so linguistic resources and vocabularies for gender exist and are well documented. We use the vocabulary words compiled by (Kaneko and Bollegala, 2019) and categorized into three non-overlapping subsets: (1) Male-definition $\Omega^M$ whose corresponding words are exclusively male-gendered such as father, king or uncle. (2) Female-definition $\Omega^F$ which is a set of inherently female words (mother, queen, aunt...). (3) Gender-stereotype $\Omega^S$ which is constituted of words that are not gendered by definition, but that carry a strong gender stereotype such as doctor being attributed to male or nurse to female.
+
+For every word $w \in \Omega^M \cup \Omega^F \cup \Omega^S$ , we extract sentences from the News-commentary-v15 corpus where $w$ is mentioned. We denote this set as $S^w$ . Then, for every sentence $s \in S^w$ , we append the dummy input "man, woman" as explained in Section 3 and the example of Figure 1. The augmented input $s'$ is then fed to the text encoder of
+
+| Models | Performance | Bias |
| Acc↑ | F1↑ | AUC↑ | STD-Sub↓ | GMB-Sub↑ | GMB-BPSN↑ | GMB-BNSP↑ |
| BERT | 0.783 | 0.823 | 0.870 | 0.119 | 0.698 | 0.800 | 0.379 |
| Sent-D | 0.791 | 0.825 | 0.870 | 0.121 | 0.689 | 0.725 | 0.583 |
| Kaneko | 0.797 | 0.833 | 0.872 | 0.112 | 0.705 | 0.789 | 0.512 |
| AttenD | 0.789 | 0.829 | 0.866 | 0.085 | 0.808 | 0.793 | 0.726 |
+
+interest (BERT base in this experiment), and we collect the attention scores of $w$ on the second-half tokens man and woman. Finally, for every word $w \in \Omega^M \cup \Omega^F \cup \Omega^S$ , we take the mean of its attention scores in $S^w$ . By the end of this procedure, we have for every word $w$ its attention score on the words man ( $a_m^w$ ) and woman ( $a_f^w$ ) as computed on the News-commentary-v15 corpus which includes overall 223,153 sentences. We take the difference $a_m^w - a_f^w$ which indicates the preference of the text encoder to consider $w$ as male (positive difference) or female (negative difference). The absence of gender bias is reflected in difference scores near zero.
+
+We plot the results in Figure 5 where the x-axis represents the differences $a_{m}^{w} - a_{f}^{w}$ , and the y-axis random values to separate the words vertically. Stereotype words (green dots) should have values near 0, which is not the case in Figure 5(b). This means that BERT has a strong preference for one of the genders, and is thus heavily biased. In contrast, our method brings the attention of stereotype words near 0, meaning that they prefer neither male nor female connotations. Moreover, the spread of stereotype words in Figure 5(d) is narrower than male- or female-oriented words, which is desired since these are inherently gendered and must pick a side. This result strengthens the claim that AttenD preserves semantic information, and is less severe in reducing bias from gendered words as it is on gender-neutral words. The difference in spread is less apparent in the original BERT model. We also note that debiasing the embeddings of BERT rather than the attention mechanism as in (Kaneko and Bollegala, 2021) (Figure 5(c)) is not enough since bias information is still lurking (and perhaps made worse for some words) in the attention component. Thus, we conclude that working on attention directly constitutes our best option for debiasing to date.
+
+Table 7: AUC-based bias measures on hate speech detection task
+
+| Models | Single sentence tasks | Double sentence tasks |
| sst2 | cola | stsb | mrpc | mnli (m/mm) | rte | wnli |
| BERT | 92.78 | 56.05 | 88.97 | 92.25 | 83.54 / 82.68 | 70.04 | 45.07 |
| AttenD | 92.66 | 55.22 | 89.62 | 91.22 | 84.63 / 84.19 | 70.40 | 53.52 |
| AttenD' | 92.32 | 56.25 | 89.12 | 80.44 | 84.59 / 83.96 | 58.12 | 39.44 |
+
+Table 8: Effect of negative examples on GLUE tasks. The table shows accuracy scores for sst2, rte, wnli, and mnli for both matched and mismatched instances; $f1$ for mrpc; spearman correlation for stsb; and matthews correlation for cola
+
+# A.5 Effect of negative examples on representativeness
+
+We remind that the introduction of negative examples to training serves in forcing the text encoder not to rely on a dangerous shortcut which is distributing its attention uniformly on all the tokens constituting the second half of the input, no matter what the input is. This is particularly important in double-sentence tasks where the text encoder is given two input sentences. In addition to Tables 3 and 5 which highlighted the effect of negative sampling on the final stereotype scores, the primary goal of using negative examples remains the preservation of the text encoder's representativeness. In Table 8, we report the performance of AttenD and AttenD with and without negative examples respectively on GLUE tasks. Unsurprisingly, the lack of negative examples does not damage the performance of single-sentence tasks since these ignore the second half of the input altogether. However, in double-sentence tasks where both halves are used for prediction, Table 8 shows that negative sampling plays a pivotal role in preserving the semantics of text encoders, and bypassing the side effects inflicted by attention equalization.
+
+# A.6 Word-Level vs Sentence-Level Debiasing
+
+As previously explained in the paper, AttenD calibrates the attention weighs of all tokens of the input sentence on group-related words. Since we used BERT-based models in our experiments, the
+
+
+(a)
+
+
+(b)
+
+
+(c)
+
+
+(d)
+Figure 5: Scatter plots of attention scores on male - female direction. (a) Original BERT, (b) BERT debiased by Sent-D (c) BERT debiased by (Kaneko and Bollegala, 2021), (d) BERT debiased by AttenD
+
+first token in the input is the special [CLS] token, which is considered by the NLP community as a vector representation for the entire input sentence. In the current version of AttenD, we also calibrate the attention weights of the special [CLS] token on groups, in addition to calibrating the other tokens of the sentence. One can see this notion as a combined word-level and sentence-level debiasing. In this experiment, we motivate this design choice by comparing it to word-level and sentence-level debiasing separately. For word-level, we exclude the [CLS] token from the attention equalization process, whereas in sentence-level we only calibrate the attention of [CLS]. We use all the bias evaluations run so far to understand the difference in performance. Tables 9, 10, 11, 12 and 13 report the results of StereoSet, Crows-Pairs, inference, hate speech and GLUE experiments respectively. We denote word-level debiasing by No [CLS], and sentence-level debiasing by Only [CLS] in the tables. The combination of both is referred to as AttenD, and is the variant that we promote in this paper. We observe that while the three settings are good at reducing bias from text encoders, AttenD is superior than word-level and sentence-level debiasing since it capitalizes on the benefits of both. It enjoys the fine granularity of reducing bias from every word, while it also mitigates biases that manifest at sentence-level.
+
+# A.7 Static vs Random ordering of group-related words
+
+In the preprocessing step of our method (as explained in Section 3), we use a preset ordering of group-related words of a given bias type to form the second input. For example, if we have the groups Muslim, Christian, Jew and Buddhist defining the religion bias type, AttenD constructs the second input using the same preset ordering of groups across all samples of the training data. Continuing the example above, AttenD appends the following artificial sentence " muslim, christian, jew, buddhist". In this experiment, we change the ordering of groups in a random way. Tables 9, 10, 11, 12 and 13 also report the bias scores of AttenD (static ordering) and AttenD with random ordering.
+
+Although the semantic performance of AttenD with random ordering is better, we notice that it suffers from a stronger presence of bias than in its static counterpart. In Table 12, AttenD with random ordering has an AUC score of 0 in one of the
+
+| Models | AttenD | No [CLS] | Only [CLS] | Random Order |
| Overall (lm/ss) | 83.34 | 53.04 | 80.37 | 53.71 | 81.70 | 55.51 | 82.91 | 54.75 |
| gender (lm/ss) | 78.24 | 53.73 | 76.86 | 52.94 | 75.88 | 54.51 | 79.02 | 55.69 |
| race (lm/ss) | 86.28 | 51.87 | 84.10 | 53.01 | 85.24 | 55.09 | 86.75 | 54.57 |
| religion (lm/ss) | 88.46 | 53.85 | 84.62 | 60.26 | 85.26 | 56.41 | 87.18 | 56.41 |
| profession (lm/ss) | 80.96 | 54.14 | 76.63 | 54.14 | 78.99 | 56.24 | 79.17 | 54.51 |
+
+Table 9: Language modeling (lm) and Stereotype scores (ss) on StereoSet of different variants of AttenD
+
+| Models | AttenD | No [CLS] | Only [CLS] | Random Order |
| Overall | 55.7 | 56.1 | 55.5 | 58.36 |
| gender | 57.36 | 50.76 | 50.0 | 53.82 |
| race | 51.15 | 54.84 | 53.1 | 57.75 |
| religion | 64.76 | 69.52 | 65.71 | 67.62 |
| age | 43.68 | 56.32 | 44.83 | 54.02 |
| sexual orientation | 58.33 | 71.43 | 63.1 | 64.29 |
| nationality | 57.86 | 53.46 | 65.41 | 62.28 |
| disability | 60.0 | 61.67 | 58.33 | 65.0 |
+
+Table 10: Bias measurements of different variants of AttenD on Crows-Pairs
+
+groups, which made the GMB extremely small. We suspect that the relatively poor fairness of random ordering owes to the fact that the model might be confused by different orderings throughout the iterations. A more serious analysis of the impact of group order on the overall performance (fairness and semantics) of AttenD motivates the direction of future work.
+
+# A.8 Effect of AttenD on other transformer-based text encoders
+
+We evaluate five widely used sentence-level text encoders: BERT (Devlin et al., 2018), ALBERT (Lan et al., 2019), RoBERTa (Liu et al., 2019), DistilBERT (SANH et al.) and SqueezeBERT (Iandola et al., 2020). For each model, we evaluate both its base and large variants (except for DistlBERT and SqueezeBERT since these are not available in HuggingFace's transformers library $^{14}$ ), original and debiased; which gives a total of sixteen evaluated models. We use Crows-Pairs dataset (Nangia et al., 2020) to quantify the intensity of undesired stereotypes encoded therein. As a reminder, ideal stereotype scores according to Crows-Pairs benchmark should be close to 50, i.e. models preferring neither stereotypes nor anti-stereotypes. Tables 14, 15, 16 and 17 show the bias results for BERT, ALBERT, RoBERTa and DistillBERT/SqueezeBERT respectively.
+
+All five models exhibit substantial levels of bias, and in each of the bias types with differing intensities (religion, sexual orientation and disability be
+
+| Model | Bias type | NN | FN | τ:0.5 | τ:0.7 |
| AttenD | gender | 01.31 | 00.43 | 00.35 | 00.21 |
| race | 93.31 | 93.94 | 93.90 | 93.04 |
| religion | 68.51† | 69.08† | 68.95† | 66.97† |
| No [CLS] | gender | 00.85 | 00.36 | 00.30 | 00.20 |
| race | 76.14 | 76.24 | 76.19 | 74.26 |
| religion | 40.80 | 40.04 | 39.98 | 37.78 |
| Only [CLS] | gender | 02.35 | 01.60 | 01.38 | 00.90 |
| race | 81.63 | 81.52 | 81.50 | 80.37 |
| religion | 44.40 | 44.01 | 43.95 | 42.76 |
| Random Order | gender | 01.54 | 00.51 | 00.39 | 00.23 |
| race | 54.71 | 54.92 | 54.89 | 52.49 |
| religion | 26.94 | 26.67 | 26.59 | 24.58 |
+
+Table 11: Inference-based bias measurements on different variants of AttenD. Best scores are highlighted with bold character, underlined, or marked with $\dagger$ for gender, race and religion $\dagger$ respectively
+
+ing the bias categories with the most severe stereotyping). Also, we find that the large variants are more biased than their base counterparts mainly because large models, with their larger capacity and greater number of parameters, can capture more intricate and more sophisticated aspects of training data, exposing them to learn more bias. This finding corresponds well to results of previous work (Nangia et al., 2020; Nadeem et al., 2020). The tables also show that AttenD is effective in mitigating bias from BERT, ALBERT, RoBERTa, DistilBERT and SqueezeBERT, and produces a reduction of up to $25\%$ . We note that AttenD succeeds in debiasing all models, with varying effectiveness across bias types. We also note that AttenD meets the best success with ALBERT as reductions are greater on this particular text encoder. We believe this is because ALBERT is composed of a single transformer layer (Lan et al., 2019) with substantially less parameters than BERT or RoBERTa; which makes debiasing easier since there is no interference between different attention layers. Finally, we see from the tables that AttenD sometimes contributes to adding a bit of bias. We observe that this phenomenon is rare, and happens especially with bias types we did not include in our design15. We assume that not explicitly compelling the text encoder to equalize attention heads corresponding to these overlooked bias types gave it green light to adjust these attentions in a way to facilitate solving the optimization problem; even if it entails adding bias. We plan to include all bias types present in
+
+Crows-Pairs dataset to our debiasing design as a future work.
+
+| Models | Performance | Bias |
| Acc↑ | F1↑ | AUC↑ | STD-Sub↓ | GMB-Sub↑ | GMB-BPSN↑ | GMB-BNSP↑ |
| AttenD | 0.789 | 0.829 | 0.866 | 0.085 | 0.808 | 0.793 | 0.726 |
| No [CLS] | 0.791 | 0.830 | 0.871 | 0.114 | 0.710 | 0.797 | 0.530 |
| Only [CLS] | 0.765 | 0.805 | 0.838 | 0.142 | 0.660 | 0.766 | 0.636 |
| Random Order | 0.784 | 0.822 | 0.861 | / | / | 0.764 | / |
+
+Table 12: AUC-based bias measures on hate speech detection task on different variants of AttenD
+
+| Models | Single sentence tasks | Double sentence tasks |
| sst2 | cola | stsb | mrpc | mnli (m/mm) | rte | wnli |
| AttenD | 92.66 | 55.22 | 89.62 | 91.22 | 84.63 / 84.19 | 70.40 | 53.52 |
| No [CLS] | 91.51 | 40.85 | 88.94 | 91.62 | 84.49 / 84.02 | 68.95 | 40.85 |
| Only [CLS] | 92.43 | 55.23 | 89.43 | 90.04 | 84.42 / 84.67 | 71.84 | 23.94 |
| Random Order | 93.23 | 59.07 | 88.85 | 91.94 | 83.75 / 84.86 | 71.84 | 30.99 |
+
+Table 13: GLUE performance of different variants of AttenD. The table shows accuracy scores for sst2, rte, wnli, and mnli for both matched and mismatched instances; $f1$ for mrpc; spearman correlation for stsb; and matthews correlation for cola
+
+| Models | BERT base | BERT large |
| Overall | 60.48 → 55.70 | -04.78 | 59.68 → 56.96 | -02.72 |
| race | 58.14 → 51.15 | -06.99 | 60.08 → 53.49 | -06.59 |
| gender | 58.02 → 57.36 | -00.66 | 55.34 → 53.05 | -02.29 |
| socioeconomic | 59.88 → 51.16 | -08.72 | 56.40 → 57.56 | +01.16 |
| nationality | 62.89 → 57.86 | -05.03 | 52.20 → 57.23 | +05.03 |
| religion | 71.43 → 64.76 | -06.67 | 68.57 → 66.67 | -01.90 |
| age | 55.17 → 43.68 | +01.15 | 55.17 → 54.02 | -01.15 |
| sexual orientation | 67.86 → 58.33 | -09.53 | 65.48 → 67.86 | +02.41 |
| physical appearance | 63.49 → 61.90 | -01.89 | 69.84 → 65.08 | -04.76 |
| disability | 61.67 → 60.00 | -01.67 | 76.67 → 65.00 | -11.67 |
+
+Table 14: Bias reduction in BERT base and large measured on Crows-Pairs dataset. Each cell is organized as follows: $\mathrm{o} \rightarrow \mathrm{d} + / -$ diff where $o$ is the stereotype score of the original model, $d$ is that of the debiased model using attention-based debiasing, and ${diff}$ is the difference in stereotype score. Negative values correspond to reduction in bias (desired) where positive values mean addition of bias (undesired).
+
+| Models | ALBERT base | ALBERT large |
| Overall | 56.76 → 51.99 | -04.77 | 60.48 → 53.58 | -06.90 |
| race | 51.36 → 48.84 | -00.20 | 59.11 → 50.97 | -08.14 |
| gender | 54.20 → 53.44 | -00.76 | 56.11 → 48.47 | -04.58 |
| socioeconomic | 60.47 → 61.05 | +00.58 | 54.07 → 50.00 | -01.16 |
| nationality | 51.57 → 57.86 | +06.29 | 62.26 → 60.38 | -04.07 |
| religion | 59.05 → 60.00 | +00.95 | 76.19 → 61.90 | -14.29 |
| age | 65.52 → 42.53 | -08.05 | 54.02 → 54.02 | -00.00 |
| sexual orientation | 75.00 → 38.10 | -13.10 | 71.43 → 63.10 | -08.33 |
| physical appearance | 46.03 → 41.27 | +04.76 | 58.73 → 57.14 | -01.59 |
| disability | 86.67 → 61.67 | -25.00 | 73.33 → 58.33 | -15.00 |
+
+Table 15: Bias reduction in ALBERT base and large measured on Crows-Pairs dataset. Each cell is organized as follows: $\mathrm{o} \rightarrow \mathrm{d} + / -$ diff where $o$ is the stereotype score of the original model, $d$ is that of the debiased model using attention-based debiasing,and ${diff}$ is the difference in stereotype score. Negative values correspond to reduction in bias (desired) where positive values mean addition of bias (undesired).
+
+| Models | RoBERTa base | RoBERTa large |
| Overall | 53.98 → 51.39 | -02.59 | 61.27 → 56.83 | -04.44 |
| race | 47.09 → 50.39 | -02.52 | 61.43 → 53.49 | -07.94 |
| gender | 54.96 → 45.80 | -00.76 | 51.91 → 51.91 | -00.00 |
| socioeconomic | 56.40 → 55.81 | -00.59 | 66.28 → 59.88 | -06.40 |
| nationality | 45.28 → 43.40 | +01.88 | 56.60 → 55.35 | -01.25 |
| religion | 56.19 → 60.00 | +03.81 | 59.05 → 62.86 | +03.81 |
| age | 64.37 → 56.32 | -08.05 | 71.26 → 62.07 | -09.19 |
| sexual orientation | 69.05 → 48.81 | -17.86 | 71.43 → 59.52 | -11.91 |
| physical appearance | 66.67 → 60.32 | -06.35 | 68.25 → 66.67 | -01.58 |
| disability | 71.67 → 65.00 | -06.67 | 66.67 → 70.00 | +03.33 |
+
+Table 16: Bias reduction in RoBERTa base and large measured on Crows-Pairs dataset. Each cell is organized as follows: $\mathrm{o} \rightarrow \mathrm{d} + / -$ diff where $o$ is the stereotype score of the original model, $d$ is that of the debiased model using attention-based debiasing, and ${diff}$ is the difference in stereotype score. Negative values correspond to reduction in bias (desired) where positive values mean addition of bias (undesired).
+
+| Models | DistilBERT | SqueezeBERT |
| Overall | 56.83 → 51.26 | -05.57 | 57.43 → 54.71 | -02.72 |
| race | 53.29 → 47.87 | -01.16 | 55.04 → 56.01 | +00.97 |
| gender | 54.58 → 46.56 | -01.14 | 52.67 → 48.47 | -01.14 |
| socioeconomic | 55.81 → 58.14 | +02.33 | 57.56 → 51.16 | -06.40 |
| nationality | 54.09 → 50.94 | -03.15 | 53.46 → 61.01 | +07.55 |
| religion | 70.48 → 57.14 | -13.34 | 74.29 → 60.95 | -13.34 |
| age | 59.77 → 48.28 | -08.05 | 55.17 → 48.28 | -03.45 |
| sexual orientation | 70.24 → 55.95 | -14.29 | 70.24 → 57.14 | -13.10 |
| physical appearance | 55.56 → 63.49 | +07.93 | 52.38 → 52.38 | -00.00 |
| disability | 61.67 → 56.67 | -05.00 | 70.00 → 61.67 | -08.33 |
+
+Table 17: Bias reduction in DistilBERT and SqueezeBERT measured on Crows-Pairs dataset. Each cell is organized as follows: $\mathrm{o} \rightarrow \mathrm{d} + / -$ diff where $o$ is the stereotype score of the original model, $d$ is that of the debiased model using attention-based debiasing, and ${diff}$ is the difference in stereotype score. Negative values correspond to reduction in bias (desired) where positive values mean addition of bias (undesired).
\ No newline at end of file
diff --git a/debiasingpretrainedtextencodersbypayingattentiontopayingattention/images.zip b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e587106b0bab98ff54f872e1e25e53e5e416aa53
--- /dev/null
+++ b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5885502e2c12a4c7c62a25df2dfe164820bf7b1cd948193f12ba3b5891735d86
+size 1040741
diff --git a/debiasingpretrainedtextencodersbypayingattentiontopayingattention/layout.json b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..e96a6de6ae256f65d685b3a7b7dcc53bafb76e04
--- /dev/null
+++ b/debiasingpretrainedtextencodersbypayingattentiontopayingattention/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e386c1cb0a17ce77852b4928811a54b9ff7c7d4c97e1f26d804fd4181892565c
+size 643317
diff --git a/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_content_list.json b/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..59da828944c34dfa71252e6eee0085666cc06517
--- /dev/null
+++ b/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cfefd3356da388b74226de04a7520ab4877744f18e93da6105565ac69295c4c1
+size 122904
diff --git a/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_model.json b/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..8c9d2f18fa5a879e1c32a4940dd327cdcf1dd20a
--- /dev/null
+++ b/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:abf5fc326c74f4bdd8a3ccf92e59ddb2ce858d2521b4935258e21977af87d89f
+size 137605
diff --git a/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_origin.pdf b/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4d6587c2c72c5c35dd6f92e45370006ef8173a92
--- /dev/null
+++ b/decodinganeuralretrieverslatentspaceforquerysuggestion/60f3a764-4e2b-45bc-a396-98a74aed5b7b_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:84c06839b69b314e655229c4d8c5d19be70c1da7b6c80c0035907b08d8cbd6dd
+size 714134
diff --git a/decodinganeuralretrieverslatentspaceforquerysuggestion/full.md b/decodinganeuralretrieverslatentspaceforquerysuggestion/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..acb41ac3f0cf9e6811c187da3bba283abf118518
--- /dev/null
+++ b/decodinganeuralretrieverslatentspaceforquerysuggestion/full.md
@@ -0,0 +1,499 @@
+# Decoding a Neural Retriever's Latent Space for Query Suggestion
+
+Leonard Adolphs†
+
+Michelle Chen Huebscher
+
+Christian Buck†
+
+Sertan Girgin‡
+
+Olivier Bachem‡
+
+Massimiliano Ciaramita
+
+Thomas Hofmann†
+
+$\dagger$ ETH Zürich
+
+ladolphs@inf.ethz.ch
+
+$\ddagger$ Google Research
+
+# Abstract
+
+Neural retrieval models have superseded classic bag-of-words methods such as BM25 as the retrieval framework of choice. However, neural systems lack the interpretability of bag-of-words models; it is not trivial to connect a query change to a change in the latent space that ultimately determines the retrieval results. To shed light on this embedding space, we learn a "query decoder" that, given a latent representation of a neural search engine, generates the corresponding query. We show that it is possible to decode a meaningful query from its latent representation and, when moving in the right direction in latent space, to decode a query that retrieves the relevant paragraph. In particular, the query decoder can be useful to understand "what should have been asked" to retrieve a particular paragraph from the collection. We employ the query decoder to generate a large synthetic dataset of query reformulations for MSMarco, leading to improved retrieval performance. On this data, we train a pseudo-relevance feedback (PRF) T5 model for the application of query suggestion that outperforms both query reformulation and PRF information retrieval baselines.
+
+# 1 Introduction
+
+Neural encoder models (Karpukhin et al., 2020; Ni et al., 2021; Izacard et al., 2021) have improved document retrieval in various settings. They have become an essential building block for applications in open-domain question answering (Karpukhin et al., 2020; Lewis et al., 2020b; Izacard and Grave, 2021), open-domain conversational agents (Shuster et al., 2021; Adolphs et al., 2021), and, recently, language modeling (Shuster et al., 2022). Neural encoders embed documents and queries in a shared (or joint) latent space, so that paragraphs can be ranked and retrieved based on their vector similarity with a given query. This constitutes a conceptually powerful approach to discovering semantic
+
+similarities between queries and documents that is often found to be more nuanced than simple term frequency statistics typical of classic sparse representations. However, such encoders may come with shortcomings in practice. First, they are prone to domain overfitting, failing to consistently outperform bag-of-words approaches on out-of-domain queries (Thakur et al., 2021). Second, they are notoriously hard to interpret as similarity is no longer controlled by word overlap, but rather by semantic similarities that lack explainability. Third, they may be non-robust as small changes in the query can lead to inexplicably different retrieval results.
+
+In bag-of-words models, it can be straightforward to modify a query to retrieve a given document: e.g., following insights from relevance feedback (Rocchio, 1971), by increasing the weight of terms contained in the target document (Adolphs et al., 2022; Huebscher et al., 2022). This approach is not trivially applicable to neural retrieval models as it is unclear how an added term might change the latent code of a query.
+
+In this paper, we look into the missing link connecting latent codes back to actual queries. We thus propose to train a "query decoder", which maps embeddings in the shared query-document space to query strings, inverting the fixed encoder of the neural retriever (cf. Figure 1a). As we will show, such a decoder lets us find queries that are optimized to retrieve a given target document. It deciphers what information is in the latent code of a document and how to phrase a query to retrieve it.
+
+We use this model to explore the latent space of a state-of-the-art neural retrieval model, GTR (Ni et al., 2021). In particular, we leverage the structure of the latent space by traversing from the embedding of a specific query to its human-labeled gold paragraph and use our query decoder to generate reformulation examples from intermediate points along the path as shown in Figure 1b. We find that using this approach, we can generate a large
+
+
+Figure 1: We train a query decoder (QD) model that inverts the shared encoder of a neural retrieval model (a). Then, we leverage the structure of the latent space of a neural retrieval model by traversing from query to gold paragraph embeddings and using our query decoder to generate a dataset of successful query reformulations (b). Finally, we train a pseudo-relevance feedback query suggestion model on this dataset that predicts promising rewrites, given a query and its search results (c).
+
+
+(b)
+
+
+
+dataset of query reformulations on MSMarco-train (Nguyen et al., 2016) that improve retrieval performance without needing additional human labeling. We use this dataset to train a pseudo-relevance feedback (PRF) query suggestion model. Here, we fine-tune a T5-large model (Raffel et al., 2020) that uses the original query, together with its top-5 GTR search results, as the input context to predict a query suggestions as depicted in Figure 1c. We show that our model provides fluent, diverse query suggestions with better retrieval performance than various baselines, including a T5 model trained on question editing (Chu et al., 2020), and a PRF query expansion model (Pal et al., 2013).
+
+We make the resources to reproduce the results publicly available1.
+
+# 2 Related Work
+
+Neural Retriever Classic retrieval systems such as BM25 (Robertson and Zaragoza, 2009) use term frequency statistics to determine the relevancy of a document for a given query. Recently, neural retrieval models have become more popular and started to outperform classic systems on multiple search tasks. Karpukhin et al. (2020) use a dual-encoder setup based on BERT-base (Devlin et al., 2019), called DPR, to encode query and documents separately and use maximum inner product search (Shrivastava and Li, 2014) to find a match. They use this model to improve recall and answer quality for multiple open-domain question-answer datasets, including OpenQA-NQ (Lee et al., 2019). Ni et al. (2021) show that scaling up the dual encoder architecture improves the retrieval performance. They train a shared dual encoder model, based on T5
+
+(Raffel et al., 2020), in a multi-stage manner, including fine-tuning on MSMarco (Nguyen et al., 2016), and evaluate on the range of retrieval tasks of the BEIR benchmark (Thakur et al., 2021). Izacard et al. (2021) show that one can train an unsupervised dense retriever and be competitive against strong baselines on the BEIR benchmark.
+
+Xiong et al. (2021) propose approximate nearest neighbor negative contrastive learning (ANCE) to learn a dense retrieval system. On top of this dense retriever, Li et al. (2022) consider a pseudorelevance feedback method. Other than our approach, this method does not provide the user with rephrased queries.
+
+Applications of Neural Retrievers Neural retrieval models have been at the core of recent improvements among a range of different NLP tasks. Lewis et al. (2020b) augment a language generation model, BART (Lewis et al., 2020a), with a DPR neural retriever and evaluate on multiple knowledge-intensive NLP tasks; most notably, they improve over previous models on multiple open-domain QA benchmarks using an abstractive method.
+
+Izacard and Grave (2021) propose the Fusion-in-Decoder method to aggregate a large set of documents from the neural retriever and provide them to the model during answer generation. Their focus is on open-domain QA where they significantly outperform previous models when considering a large set of documents during decoding.
+
+Shuster et al. (2021) use neural retrieval models to improve conversational agents in knowledge-grounded dialogue. They show that the issue of hallucination - i.e., generating factual incorrect knowledge statements - can be significantly re
+
+duced when using a neural-retriever-in-the-loop architecture. Separating the retrieval-augmented knowledge generation and the conversational response generation can further improve the issue of hallucination in knowledge-grounded dialogue and helps fuse modular QA and dialogue models (Adolphs et al., 2021). Recently, retrieval query generation approaches have been proposed to improve open-domain dialogue (Komeili et al., 2021) and language modeling (Shuster et al., 2022).
+
+Query Generation Query optimization is a longstanding problem in IR (Lau and Horvitz, 1999; Teevan et al., 2004). Recent work has investigated query refinement with reinforcement learning for Open Domain and Conversational Question Answering (Nogueira and Cho, 2017; Buck et al., 2018; Wu et al., 2021).
+
+The methods presented in this paper are a natural complement to the work of Adolphs et al. (2022), who propose a heuristic approach to generate multistep query refinements, used to train sequential query generation models for the task of learning to search. Their method is also inspired by relevance feedback, but they seek to reach the gold document purely in language space, by brute force exploration. For this purpose, they use specialized search operators to condition the retrieval results as desired. Huebscher et al. (2022) show that, when paired with a hybrid sparse/dense retrieval environment, the search agents trained on this kind of synthetic data combine effective corpus exploration, competitive performance and interpretability.
+
+Web-GPT (Nakano et al., 2021) presents an end-to-end search modeling approach based on human demonstrations, in a similar spirit our work could be seen as way of involving humans-in-loop by proposing better queries.
+
+Fixed-vector decoders Probabilistic decoders mapping from a fixed size vector space to natural language have also been explored in auto-encoder settings. A key challenge in this line of work lies in obtaining decoders that are robust, i.e., they generate natural text for a variety of input vectors. Bowman et al. (2016) proposed using a RNN-based language model in combination with variational autoencoders (VAE) (Kingma and Welling, 2013) which add Gaussian space to the decoder input. Zhao et al. (2018) proposed the use of Adversarial Autoencoder (AAE) (Makhzani et al., 2015) to which Shen et al. (2020) added data denoising
+
+
+Table 1: Decoding metrics of the Query Decoder (QD) based on the GTR-base neural retrieval model. The F1 score is the F1 word overlap between the original query, of MSMarco or NQ, and the output of the query decoder model when provided with the GTR encoding of the query. The cosine similarity is measured between the re-encoding of the generated query and the encoding of the original query. The figure above depicts the metrics visually with a toy example for clarity.
+
+by randomly dropping words in the input and the reconstructing the full output.
+
+Recently, RNN-based decoders have been replaced by Transformer-based language models (Vaswani et al., 2017), for example by Montero et al. (2021), Park and Lee (2021) and Li et al. (2020).
+
+# 3 Query Decoder
+
+Training We train a T5 (Raffel et al., 2020), decoder-only model, to (re-)generate a query from its embedding obtained in a neural retrieval model. As training data, we use a subset of 3 million queries of the PAQ dataset (Lewis et al., 2021). We use the GTR-base (Ni et al., 2021), shared-encoder model, to generate the embeddings and use the queries as the targets. The objective of the query decoder learning is to invert the mapping of the fixed GTR encoder model, as visually depicted in Figure 1a. More training details of the query decoder are provided in Appendix A.2.1.
+
+Query Reconstruction Evaluation We consider the round-trip consistency as a first step in evaluating the query decoder's effectiveness. A query $q$ is encoded via GTR and then decoded by our decoder to generate $q'$ . We use queries from MS-Marco, and NQ test sets of the BEIR benchmark (Thakur et al., 2021). As a first metric, we compute
+
+the F1 score between the original $q$ and its reconstruction $q'$ . Since word-overlap is imperfect in measuring query drift, we further re-encode $q'$ and compare its latent code with the code for $q$ via their cosine similarity. The results of these evaluations are reported in Table 1, where we also provide an illustrative example of the proposed approach. For both datasets, MSMarco and NQ, the metrics of F1 and cosine similarity are generally high, indicating that the GTR code carries information that allows for close approximate query reconstruction.
+
+
+
+| Data | Top1 | Top3 | Top5 |
| MSMarco | 0.551 | 0.737 | 0.796 |
| NQ | 0.721 | 0.863 | 0.897 |
+
+Paragraph to Query Evaluation Many interesting use cases rely on the ability to generate queries from passages of text (Du et al., 2017; Kumar et al., 2018). As GTR embeds document paragraphs and queries into the same space, the query decoder can also be used to invert the retrieval process. We thus evaluate the decoder quality by starting from a document paragraph, decoding a query from its embedding and then running the GTR search engine on that query to check if this query retrieves the desired paragraph as a top-ranked result. We test this in an experiment with human-labeled gold paragraphs from MSMarco and NQ, using top-k as the success metric. The results reported in Table 2 are very encouraging in that the desired paragraph is indeed found very often among the topmost GTR search results. Two example paragraph decodings from MSMarco are shown in Table 3; for both decodings, the gold paragraph is retrieved at the top position.
+
+Latent Space Traversal Decoding We have shown that query decoding can reconstruct queries and that it can find retrieval queries for target passages. We now turn to a more concrete practical
+
+Table 2: Share of gold paragraphs for which we can decode a query that retrieves the given paragraph within its top-k GTR search results. The figure above depicts the metric evaluation visually for clarity.
+
+| Original Query
+nebl coin price [Rank: 2]
+Decoding from Gold Paragraph
+what is the current price of neblio today belo [Rank: 1]
+Gold Paragraph
+Neblio Price Chart US Dollar (NEBL/USD) Neblio price for today is $16.3125. It has a current circulating supply of 12.8 Million coins and a total volume exchanged of $9,701,465 |
| Original Query
+when is champaign il midterm elections [Rank: 3]
+Decoding from Gold Paragraph
+when is the general election in illinois 2018 [Rank: 1]
+Gold Paragraph
+Illinois elections, 2018. A general election will be held in the U.S. state of Illinois on November 6, 2018. All of Illinois’ executive officers will be up for election as well as all of Illinois’ eighteen seats in the United States House of Representatives. |
+
+Table 3: Examples of query decodings from the gold paragraph. The rank indicates the retrieval position of the gold paragraph using the corresponding query.
+
+application, namely to automatically generate a data set of query reformulations, from which strategies for interactive retrieval can be learned. In this context, reformulated queries should remain semantically similar to the original query and not overfit to the target passage. They should be somewhat 'in between' the query and the gold passage, as any passage is likely to contain answers to multiple, different questions. This can be operationalized by decoding queries from points along the line connecting the embeddings of the query and its target passage as depicted in Figure 1b.
+
+To validate this idea, we apply it to the MSMarco and NQ retrieval dataset where each query is paired with a human-labeled gold paragraph. In particular, we move in $k$ equidistant increments from the original query embedding $\mathbf{q}$ to the gold paragraph embedding $\mathbf{d}$ , i.e.
+
+$$
+\mathbf {q} _ {\kappa} = \mathbf {q} + \frac {\kappa}{k} (\mathbf {d} - \mathbf {q}) \quad \kappa = 0, \dots , k \tag {1}
+$$
+
+and generate a reformulation at each step.2 As a sanity check, Figure 3 shows the average retrieval performance of the decoded queries when moving from the original query embedding to the gold paragraph embedding for MSMarco and NQ. For both datasets, the normalized discounted cumulative gain (nDCG) (Jarvelin and Kekäläinen, 2002)
+
+
+Figure 2: Visualization of the latent-space traversal from query to gold paragraph, using 2D t-SNE. The blue point denotes the embedding of the original query "where is quincy located". The green squares are the embeddings of the retrieved paragraphs for this query. The closest one about "Quincy Washington" is shown in the green text bar. The orange crosses denote the embeddings of the reformulations of the query decoder when moving to the gold paragraph depicted as the red plus. The orange and red text bars show the final reformulation and the gold paragraph text, respectively. The number above the query and reformulations show the nDCG score. As the gold paragraph is describing the climate of Quincy in addition to its location, a reformulation about the "average rainfall in quincy illinois" retrieves the desired paragraph.
+
+improves steadily and plateaus, then slightly dips, only when getting close to the gold paragraph embedding. We hypothesize that two effects are at work here that explain this dip: (i) the closer one moves towards the gold passage embedding, the more the query decoder operates out-of-distribution as it is trained on query embeddings. The joint latent space is sparse and likely characterized by distinct regions for queries and passage embeddings, which have different properties (e.g., length or surface structure). (ii) A passage might answer several questions. When decoding from an embedding close to the paragraph, these might start being conflated.
+
+Examples We provide a visual example of the latent traversal approach in Figure 2 where we project the latent space to 2 dimensions using t-SNE (Hinton and Roweis, 2002). The plot shows that for the ambiguous query "where is quincy located" (blue dot), the gold paragraph about the climate of Quincy, Illinois (red plus), is far away from the top-10 retrieved documents (green squares). Traversing the latent space from the query towards the gold paragraph leads to improved reformulations
+
+
+Figure 3: The normalized discounted cumulative gain (nDCG) of the reformulations from the query decoder when moving the input code from the embedding of the query to the embedding of the gold paragraph. Decoding closer to the gold paragraph embedding leads to queries with improved average retrieval performance. The initial decodings nDCG scores are slightly lower than from the original query due to the reconstruction loss of the query decoder.
+
+(orange crosses), as is evident from the shrinking distance to the gold paragraph and by the improved nDCG score.
+
+Semantically, the reformulations move to questions about the climate of Quincy, as this is the main topic of the gold paragraph. The full sequence of reformulations is shown in Table 15. Another example is shown in Table 4; similarly, we see that the decoded queries move semantically from the general question of average annual return on the stock market to the more specific question of return at the S&P stock exchange. Many more examples are provided in Appendix A.5.
+
+# 4 Query Suggestion Model
+
+Dataset Generation We generate a dataset of query reformulations using the latent space traversal decoding as described in the previous section. In particular, for the 532,761 queries of the MSMarco-train dataset, we leverage GTR's learned latent space structure and move towards the embedding of their gold paragraph. At $k = 20$ intermediate steps on this path, we use our query decoder to generate reformulations.
+
+For more than $80\%$ of the queries, we find at least one optimal reformulation that retrieves the gold paragraph at the top position. In Figure 4, we show histograms of nDCG and the inner product to the gold paragraph for the original query versus the best-found reformulation. The metrics show that the latent space traversal helps us discover good
+
+# Original Query
+
+average yearly return on stock market [0.00]
+
+# Decodings during Traversal
+
+what is the average annual return on stock market [0.00]
+
+average return on a stock market year [0.00]
+
+what is the average annual return on stock market [0.00]
+
+what is the average return on stock in a year [0.00]
+
+what is the average return in a stock market [0.00]
+
+what is the average annual return in stock (s&p) [0.36]
+
+what is the average return on the stock market (s&p) [0.36]
+
+what is the average return on the s&p stock exchange at a time [1.00]
+
+what is the average return in s&p stock at a time [0.36]
+
+what is the average annual return of the s&p stock exchange (best) [1.00]
+
+# Gold Paragraph
+
+The S&P 500 gauges the performance of the stocks of the 500 largest, most stable companies in the Stock Exchange. It is often considered the most accurate measure of the stock market as a whole. The current average annual return from 1926, the year of the S&Ps inception, through 2011 is $11.69\%$ . That's a long look back, and most people aren't interested in what happened in the market 80 years ago.
+
+Table 4: Example of a successful traversal on an MS-Marco query. The nDCG@10 score of each query is provided in the brackets. Here, we traverse the latent space in $k = 10$ equidistant steps from the embedding of the original query "average yearly return on stock market", which results in an nDCG retrieval score of 0, to the embedding of the gold paragraph. The queries decoded from a latent code close to the gold paragraph, focus on the returns of the S&P (as the gold paragraph) and lead to improved retrieval results.
+
+query reformulations that lead to massively improved retrieval performance and are closer to the corresponding gold paragraphs in latent space.
+
+We filter the dataset to only contain "successful" reformulations to train the reformulation model. Here, we require a reformulation to have an nDCG of 1 (i.e., retrieve the gold paragraph at the top position), to improve the nDCG compared to the original query, and its embedding to have a larger inner product with the gold paragraph than the original query. Using this approach, we generate a dataset of 863,307 successful query rewrites. As the example in Table 4 and Appendix A.5 show, the decoded queries do not always have human-like fluency and for some sequences intent shift occurs when decoding closer to the paragraph. This is one reason we're moving in increments from the original query to the gold paragraph instead of directly
+
+
+
+
+(a)
+(b)
+Figure 4: The histogram of nDCG (a) and inner product with the gold paragraph embedding of the original query vs. the best reformulation found with the latent-space traversal approach on MSMarco-train.
+
+decoding it.
+
+Interestingly, however, we find that this noise of the dataset is unspecific enough that it gets smoothed out during model training as described in the following paragraph. More details about this dataset are provided in Sec. A.3.
+
+Model Training We use the reformulation dataset to train two query suggestion model variants. First, we train a model on the plain reformulation examples, from original query to "successful" rewrite. As a second, more powerful approach, we train a model with pseudo-relevance feedback (PRF); here, we provide GTR's top-5 search results for the original query as additional context to the model. Both models are fine-tuned from the T5-large (Raffel et al., 2020) pre-training checkpoint. Consequently, we name the models in the following way:
+
+- qsT5-plain: A T5 query suggestion model trained on the plain generated reformulation
+
+examples (no pseudo-relevance feedback) of MSMarco-train, mapping from query to query reformulation.
+
+- qsT5: A T5 query suggestion model trained on the generated reformulation examples of MSMarco-train, where the input is augmented with the content of GTR's top-5 retrieved search results for the original query, mapping from query and search results to query reformulation.
+
+The details and hyperparameters of the model training are provided in Appendix A.2.2.
+
+Baseline Models To measure the effectiveness of our query suggestion model, we benchmark it against multiple baselines. The baselines are meant to cover various angles of competitive approaches to query suggestion, namely training on human-generated question-edit histories, a classic RM3 pseudo-relevance feedback query expansion method, and a latent space sampling approach utilizing our query decoder. In the following, we introduce the three baselines in detail.
+
+- MQR: We train a T5-large model on the "multidomain question rewriting" (MQR) (Chu et al., 2020) dataset. This dataset consists of 427,719 human-contributed Stack Exchange question-edit histories, mapping from ill-formed to well-formed. While this is a relatively large training dataset, our synthetic generations dataset is roughly double in size with 863,307 rewrites, yet without any human edits. This baseline captures the effect of turning a query to a well-formed question to improve retrieval performance. It does not use PRF but maps from query to reformulation, as our qsT5-plain model. Training details of this model are provided in Section A.2.3 in the Appendix.
+
+- RM3: We employ RM3 (Jaleel et al., 2004) as a strong pseudo-relevance feedback baseline. In particular, we use a query expansion approach that uses the formula described in Eq. 20 of Pal et al. (2013) with $\mu = 2500$ to determine the most relevant terms of the top-5 retrieved documents. Then, each suggestion of the model consists of the original query together with one of the determined relevant terms.
+- Sampling+QD: To check how much of the retrieval performance gain is due to an ensembling effect in latent space, we compare against a random sampling baseline that includes our query
+
+# Original Query
+
+who created spiritual gangster
+
+# MQR
+
+Who created the Spiritual Gangster?
+
+Who created the "spiritual gangster" storyline?
+
+Who created the "spiritual gangster"?
+
+# RM3
+
+who created spiritual gangster spiritual
+
+who created spiritual gangster modern
+
+who created spiritual gangster inspired
+
+# Sampling+QD
+
+who created gangster a spiritual & egantious
+
+who created spiritual gangster -gangster
+
+who created spiritual gangster
+
+# qsT5
+
+who is the founder of spiritual gangsters
+
+who created the spiritual gangster ( spiritual yogi )
+
+what is the spiritual gangster movement
+
+# qst5-plain
+
+who are the founders of the gangster spirit band
+
+how many gangsters were formed in white supreme
+
+who was the members of the gangster supremes
+
+# Gold Paragraph
+
+About Spiritual Gangster. Spiritual Gangster represents a new generation of yogis seeking balance between the ancient practice of yoga and the modern world. Founded by Vanessa Lee and Ian Lopatin, this newly borne brand calls for high vibration living and radiating love shore-to-shore, person-to-person, heart-to-heart.
+
+Table 5: Examples of the top query suggestions for the different models for the query "who created spiritual gangster". The final row shows the human-labeled gold paragraph.
+
+decoder (QD). In particular, we sample a point uniformly at random from an epsilon-ball around the embedding of the original query and use the query decoder to decode that point to a query. This baseline does not use PRF.
+
+Evaluation We evaluate the query suggestion models on the MSMarco and NQ test sets. For each example, we generate up to 10 suggestions using nucleus sampling (Holtzman et al., 2020). Our ultimate goal is to provide users with at least one reformulation that better captures their search intent. As we assume the gold paragraph captures the information need of the user, we evaluate if, within a small set of reformulations, there is a query that would lead them closer to that paragraph; i.e., we measure the maximum nDCG@10 of the top-k reformulations and the original query. We provide the results in Figure 5.
+
+
+(a)
+
+
+(b)
+Figure 5: Retrieval metrics of the query suggestion models on the MSMarco (a) and NQ (b) test sets. The dashed line shows the nDCG@10 score of the original query. The bars represent the nDCG@10 of the best 1, 3, 5, and 10 reformulations (including the original query), respectively, of different models. The error bars show the 95 percent confidence interval when doing bootstrap sampling from up to 10 generations of the models. The RM3 and qsT5 models are using pseudo-relevance feedback, i.e., information about the top-retrieved paragraphs.
+
+We see that our qsT5 model significantly outperforms all baselines on both datasets. Notably, it substantially improves upon the RM3 pseudorelevance feedback baseline; this indicates that our full reformulation approach is more powerful for neural retrievers than a well-established query expansion technique.
+
+The large gap between qsT5 and qsT5-plain validates the importance and usefulness of conditioning on the initial search results.
+
+Successfully rewriting the query to a well-formed variant benefits this task as indicated by the improved nDCG performance of the non-PRF baseline of the T5 model trained on MQR (blue) over the original query (dashed line). The qsT5-plain model outperforms the MQR model when considering multiple reformulations on MSMarco, indicating that in some cases our model learns successful rewriting beyond improving fluency.
+
+The qsT5-plain is mostly on par with sampling randomly around the embedding of the original query and using our query decoder to generate a reformulation; hence, we can speculate that the main benefit of this non-PRF model comes from an ensembling effect of generating suitable reformulations around the neighborhood of the original query. Again, this reinforces the benefit of pseudo-relevance feedback for the application of query suggestion.
+
+Additional plots showing the inner product metric for this experiment and a table summarizing the numbers are provided in Appendix A.1.
+
+Diversity & Fluency To quantitatively highlight the characteristics of the evaluated query suggestion models, we report Self-BLEU (Zhu et al., 2018) and perplexity of a language model as proxies for diversity and fluency, respectively, in Table 6. Self-BLEU is measured between 10 suggestions for a given query and averaged across the dataset, where a low Self-BLEU indicates large diversity between suggestions. For the perplexity evaluation, we employ the T5-base language model trained on C4 (Raffel et al., 2020) and measure the average per-token perplexity of all suggestions for a given dataset; here, we associate lower perplexity with higher fluency of the suggestions.
+
+Table 6 shows that the MQR baseline generates the most fluent queries, but with low diversity compared to our reformulation approaches. The RM3 query expansions score worst in diversity as they always use the original query as a base. Our qsT5 model scores second best in diversity, with a good comparative perplexity, only surpassed by the qsT5 variant without PRF, due to the fact that this model does not focus on the "narrowed-down" topics of the retrieved results. Notably, the perplexity is higher for the NQ dataset than for MSMarco due to the nature of queries in NQ being closer to well-formed questions as opposed to 'search engine queries'.
+
+Examples In Table 5, we cherry-pick a representative example of query suggestions for the different models. This example showcases typical be
+
+| Model | MSMarco | NQ |
| S-BLEU | PPL | S-BLEU | PPL |
| Original Query | - | 1622.2 | - | 217.9 |
| MQR | 46.1 | 59.6 | 61.4 | 56.8 |
| RM3 | 74.8 | 1562.6 | 88.0 | 309.5 |
| Sampling+QD | 23.7 | 726.0 | 26.6 | 687.5 |
| qST5 | 17.8 | 247.8 | 18.4 | 223.2 |
| qST5-plain | 9.2 | 196.6 | 7.6 | 249.8 |
+
+Table 6: Self-BLEU (Zhu et al., 2018) and Perplexity (PPL) for the query suggestions of the different models on MSMarco and NQ. Self-BLEU is measured between 10 suggestions of a model for a given query and then averaged across the dataset to provide information about the diversity of the suggestions. Perplexity is measured per token based on a T5 language model to provide a relative comparison of fluency of the query suggestions.
+
+haviors of the models. The MQR model is trained on turning ill-formed into well-formed questions. Hence, it usually produces grammatical but low diversity reformulations, especially when the original query is already close to a well-formed question. The relatively high Self-BLEU score amongst its reformulations for a given query, reported in Table 6, supports the argument of limited diversity.
+
+The RM3 model appends the most relevant terms to the original query and therefore has the lowest overall diversity (i.e., highest Self-BLEU). The Sampling+QD model can result in non-grammatical or even nonsensical queries depending on the sampled point in latent space. While the qsT5 model can utilize the top-retrieved search results to form reformulations that are in accordance with the topic of the query (e.g., "yogi" in the example of Table 5), the qsT5-plain needs to rely on its internal world knowledge stored in its parameters. It thus cannot connect "gangster" with "yogi" here.
+
+# 5 Conclusion
+
+Dual encoders have reset the standard in IR. However, language-based inverted index architectures still hold their ground, especially in out-of-domain evaluations (Thakur et al., 2021). To help further our understanding of the connections, and potential, between the two, we propose a method that relies on a query decoder to map back to language space the latent codes generated by the encoder.
+
+The interplay between latent and language representations, in combination with a simple goal-directed mechanism for traversing the shared query-document space, allows us to generate a large synthetic dataset of query reformulations on which we
+
+train a pseudo-relevance feedback query suggestion model that characteristically tries to predict the location of the target document.
+
+Our contribution is twofold: (i) we develop a generic way to generate training data for directional query refinement by traversing the latent space between queries and relevant documents, and (ii) we build a powerful reformulation model that we evaluate on a novel benchmark inspired by the query suggestion task. Suggestions are typically well-formed, diverse and more likely to lead to the right document than competing methods.
+
+# 6 Limitations
+
+A proper user study would provide a valuable complement to the current evaluation and contribute to a fuller picture. However, this presents significant challenges that are beyond the scope of the current work. For instance, is not trivial to adequately design a meaningful task for human raters conducive to good agreement, e.g., it may be inevitable to second-guess the original query intent in the presence of unexpected interpretations brought to the surface by the suggestions. For the time being, we feel the automatic evaluation proposed here will be more valuable, as it makes direct comparison and reproducibility straightforward.
+
+Secondly, it seems sensible to further evaluate the query suggestions in an end-to-end IR task. Preliminary experiments in this direction using MS Marco proved somewhat inconclusive, while they introduce significant complexity. The data annotations are sparse (one passage per query, by and large) and it is often the case that multiple relevant passages exist for the same query.3 This makes reranking a crucial but faulty component, opening up a somewhat orthogonal front. The ideal evaluation would rely on a deeper manual analysis for a limited query set, e.g., TREC-style (e.g., cf. Craswell et al. (2020)).
+
+We leave both for future work.
+
+# Acknowledgements
+
+We would like to thank Léonard Hussenot for his insightful feedback and the support with the Diversity & Fluency experiments. Furthermore, we thank Wojciech Gajewski, Sascha Rothe, and Lierni Sestorain Saralegui for helpful discussions and feedback throughout the course of the project.
+
+# References
+
+Martín Abadi, Ashish Agarwal, Paul Barham, Eugene Brevdo, Zhifeng Chen, Craig Citro, Greg S. Corrado, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Ian Goodfellow, Andrew Harp, Geoffrey Irving, Michael Isard, Yangqing Jia, Rafal Jozefowicz, Lukasz Kaiser, Manjunath Kudlur, Josh Levenberg, Dandelion Mane, Rajat Monga, Sherry Moore, Derek Murray, Chris Olah, Mike Schuster, Jonathon Shlens, Benoit Steiner, Ilya Sutskever, Kunal Talwar, Paul Tucker, Vincent Vanhoucke, Vijay Vasudevan, Fernanda Viégas, Oriol Vinyals, Pete Warden, Martin Wattenberg, Martin Wicke, Yuan Yu, and Xiaojiang Zheng. 2015. TensorFlow: Large-scale machine learning on heterogeneous systems. Software available from tensorflow.org.
+
+Leonard Adolphs, Benjamin Borschinger, Christian Buck, Michelle Chen Huebscher, Massimiliano Ciaramita, Lasse Espeholt, Thomas Hofmann, Yannic Kilcher, Sascha Rothe, Pier Giuseppe Sessa, and Lierni Sestorain. 2022. Boosting search engines with interactive agents. Transactions on Machine Learning Research.
+
+Leonard Adolphs, Kurt Shuster, Jack Urbanek, Arthur Szlam, and Jason Weston. 2021. Reason first, then respond: Modular generation for knowledge-infused dialogue. CoRR, abs/2111.05204.
+
+Samuel R. Bowman, Luke Vilnis, Oriol Vinyals, Andrew Dai, Rafal Jozefowicz, and Samy Bengio. 2016. Generating sentences from a continuous space. In Proceedings of The 20th SIGNLL Conference on Computational Natural Language Learning, pages 10-21, Berlin, Germany. Association for Computational Linguistics.
+
+Christian Buck, Jannis Bulian, Massimiliano Ciaramita, Wojciech Gajewski, Andrea Gesmundo, Neil Houlsby, and Wei Wang. 2018. Ask the right questions: Active question reformulation with reinforcement learning. In International Conference on Learning Representations.
+
+Zewei Chu, Mingda Chen, Jing Chen, Miaosen Wang, Kevin Gimpel, Manaal Faruqui, and Xiance Si. 2020. How to ask better questions? a large-scale multi-domain dataset for rewriting ill-formed questions. Proceedings of the AAAI Conference on Artificial Intelligence, 34(05):7586-7593.
+
+Nick Craswell, Bhaskar Mitra, Emine Yilmaz, and Daniel Campos. 2020. Overview of the TREC 2020 deep learning track.
+
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+
+Xinya Du, Junru Shao, and Claire Cardie. 2017. Learning to ask: Neural question generation for reading comprehension.
+
+Geoffrey E Hinton and Sam Roweis. 2002. Stochastic neighbor embedding. In Advances in Neural Information Processing Systems, volume 15. MIT Press.
+
+Ari Holtzman, Jan Buys, Li Du, Maxwell Forbes, and Yejin Choi. 2020. The curious case of neural text degeneration. In International Conference on Learning Representations.
+
+Michelle Chen Huebscher, Christian Buck, Massimiliano Ciaramita, and Sascha Rothe. 2022. Zero-shot retrieval with search agents and hybrid environments.
+
+Gautier Izacard, Mathilde Caron, Lucas Hosseini, Sebastian Riedel, Piotr Bojanowski, Armand Joulin, and Edouard Grave. 2021. Towards unsupervised dense information retrieval with contrastive learning. CoRR, abs/2112.09118.
+
+Gautier Izacard and Edouard Grave. 2021. Leveraging passage retrieval with generative models for open domain question answering. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 874-880, Online. Association for Computational Linguistics.
+
+Nasreen Jaleel, James Allan, W. Croft, Fernando Diaz, Leah Larkey, Xiaoyan Li, Mark Smucker, and Courtney Wade. 2004. Umass at trec 2004: Novelty and hard.
+
+Kalervo Järvelin and Jaana Kekäläinen. 2002. Cumulated Gain-Based Evaluation of IR Techniques. ACM Trans. Inf. Syst., 20(4):422-446.
+
+Vladimir Karpukhin, Barlas Oguz, Sewon Min, Patrick Lewis, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6769-6781, Online. Association for Computational Linguistics.
+
+Diederik P Kingma and Max Welling. 2013. Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114.
+
+Mojtaba Komeili, Kurt Shuster, and Jason Weston. 2021. Internet-augmented dialogue generation. CoRR, abs/2107.07566.
+
+Vishwajeet Kumar, Kireeti Boorla, Yogesh Meena, Ganesh Ramakrishnan, and Yuan-Fang Li. 2018. Automating reading comprehension by generating question and answer pairs. CoRR, abs/1803.03664.
+
+Tessa Lau and Eric Horvitz. 1999. Patterns of Search: Analyzing and Modeling Web Query Refined. In Proceedings of the 7th International on User Modeling.
+
+Kenton Lee, Ming-Wei Chang, and Kristina Toutanova. 2019. Latent retrieval for weakly supervised open domain question answering. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6086–6096, Florence, Italy. Association for Computational Linguistics.
+
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020a. BART: Denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880, Online. Association for Computational Linguistics.
+
+Patrick Lewis, Ethan Perez, Aleksandra Piktus, Fabio Petroni, Vladimir Karpukhin, Naman Goyal, Heinrich Kuttler, Mike Lewis, Wen-tau Yih, Tim Rocktäschel, Sebastian Riedel, and Douwe Kiela. 2020b. Retrievalaugmented generation for knowledge-intensive nlp tasks. In Advances in Neural Information Processing Systems, volume 33, pages 9459-9474. Curran Associates, Inc.
+
+Patrick Lewis, Yuxiang Wu, Linqing Liu, Pasquale Minervini, Heinrich Kuttler, Aleksandra Piktus, Pontus Stenetorp, and Sebastian Riedel. 2021. PAQ: 65 million probably-asked questions and what you can do with them. Transactions of the Association for Computational Linguistics, 9:1098-1115.
+
+Chunyuan Li, Xiang Gao, Yuan Li, Baolin Peng, Xiujun Li, Yizhe Zhang, and Jianfeng Gao. 2020. Optimus: Organizing sentences via pre-trained modeling of a latent space. arXiv preprint arXiv:2004.04092.
+
+Hang Li, Shengyao Zhuang, Ahmed Mourad, Xueguang Ma, Jimmy Lin, and Guido Zuccon. 2022. Improving query representations for dense retrieval with pseudo relevance feedback: A reproducibility study. In Advances in Information Retrieval, pages 599-612, Cham. Springer International Publishing.
+
+Alireza Makhzani, Jonathon Shlens, Navdeep Jaitly, Ian Goodfellow, and Brendan Frey. 2015. Adversarial autoencoders. arXiv preprint arXiv:1511.05644.
+
+Ivan Montero, Nikolaos Pappas, and Noah A. Smith. 2021. Sentence bottleneck autoencoders from transformer language models. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1822-1831, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+
+Reiichiro Nakano, Jacob Hilton, Suchir Balaji, Jeff Wu, Long Ouyang, Christina Kim, Christopher Hesse, Shantanu Jain, Vineet Kosaraju, William Saunders, Xu Jiang, Karl Cobbe, Tyna Eloundou, Gretchen Krueger, Kevin Button, Matthew Knight, Benjamin Chess, and John Schulman. 2021. WebGPT: Browser-assisted question-answering with human feedback. CoRR, abs/2112.09332.
+
+Tri Nguyen, Mir Rosenberg, Xia Song, Jianfeng Gao, Saurabh Tiwary, Rangan Majumder, and Li Deng. 2016. MS MARCO: A Human Generated MAchine Reading COprehension Dataset.
+
+Jianmo Ni, Chen Qu, Jing Lu, Zhuyun Dai, Gustavo Hernández Abrego, Ji Ma, Vincent Y. Zhao,
+
+Yi Luan, Keith B. Hall, Ming-Wei Chang, and Yinfei Yang. 2021. Large dual encoders are generalizable retrievers. CoRR, abs/2112.07899.
+
+Rodrigo Nogueira and Kyunghyun Cho. 2017. Task-oriented query reformulation with reinforcement learning. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 574-583, Copenhagen, Denmark. Association for Computational Linguistics.
+
+Dipasree Pal, Mandar Mitra, and Kalyankumar Datta. 2013. Query expansion using term distribution and term association.
+
+Seongmin Park and Jihwa Lee. 2021. Finetuning pretrained transformers into variational autoencoders. arXiv preprint arXiv:2108.02446.
+
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140):1-67.
+
+Stephen Robertson and Hugo Zaragoza. 2009. The probabilistic relevance framework: Bm25 and beyond. Foundations and Trends in Information Retrieval, 3(4):333-389.
+
+J. J. Rocchio. 1971. Relevance feedback in information retrieval. In G. Salton, editor, The Smart retrieval system - experiments in automatic document processing, pages 313-323. Englewood Cliffs, NJ: Prentice-Hall.
+
+Tianxiao Shen, Jonas Mueller, Dr.Regina Barzilay, and Tommi Jaakkola. 2020. Educating text autoencoders: Latent representation guidance via denoising. In Proceedings of the 37th International Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research, pages 8719-8729. PMLR.
+
+Anshumali Shrivastava and Ping Li. 2014. Asymmetric lsh (alsh) for sublinear time maximum inner product search (mips). In Advances in Neural Information Processing Systems, volume 27. Curran Associates, Inc.
+
+Kurt Shuster, Mojtaba Komeili, Leonard Adolphs, Stephen Roller, Arthur Szlam, and Jason Weston. 2022. Language models that seek for knowledge: Modular search & generation for dialogue and prompt completion.
+
+Kurt Shuster, Spencer Poff, Moya Chen, Douwe Kiela, and Jason Weston. 2021. Retrieval augmentation reduces hallucination in conversation. In *Findings of the Association for Computational Linguistics: EMNLP* 2021, pages 3784-3803, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+
+Jaime Teevan, Christine Alvarado, Mark S. Ackerman, and David R. Karger. 2004. The Perfect Search Engine is Not Enough: A Study of Orienteering Behavior in Directed Search. In Proceedings of the SIGCHI Conference on Human Factors in Computing Systems.
+
+Nandan Thakur, Nils Reimers, Andreas Rückle, Abhishek Srivastava, and Iryna Gurevych. 2021. BEIR: A heterogenous benchmark for zero-shot evaluation of information retrieval models. CoRR, abs/2104.08663.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. Advances in neural information processing systems, 30.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierrick Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+Zeqiu Wu, Yi Luan, Hannah Rashkin, David Reitter, Hannaneh Hajishirzi, Mari Ostendorf, and Gaurav Singh Tomar. 2021. CONQRR: Conversational query rewriting for retrieval with reinforcement learning. arxiv.org:2112.08558.
+Lee Xiong, Chenyan Xiong, Ye Li, Kwok-Fung Tang, Jialin Liu, Paul N. Bennett, Junaid Ahmed, and Arnold Overwijk. 2021. Approximate nearest neighbor negative contrastive learning for dense text retrieval. In International Conference on Learning Representations.
+Junbo Zhao, Yoon Kim, Kelly Zhang, Alexander Rush, and Yann LeCun. 2018. Adversarily regularized autoencoders. In International conference on machine learning, pages 5902-5911. PMLR.
+Yaoming Zhu, Sidi Lu, Lei Zheng, Jiaxian Guo, Weinan Zhang, Jun Wang, and Yong Yu. 2018. Texygen: A benchmarking platform for text generation models. In SIGIR, pages 1097-1100.
+
+# A Appendix
+
+# A.1 Additional Results of the Query Suggestion Model
+
+| Model | MSMarco | NQ |
| 1 | 3 | 5 | 10 | 1 | 3 | 5 | 10 |
| Original Query | .420 | - | - | - | .495 | - | - | - |
| MQR | .439 .001 | .454 .005 | .464 .005 | .477 .004 | .531 .001 | .548 .008 | .557 .009 | .571 .005 |
| Sampling+QD | .440 .001 | .469 .005 | .484 .007 | .506 .013 | .522 .001 | .548 .005 | .561 .006 | .580 .005 |
| RM3 | .445 .003 | .472 .016 | .495 .009 | .522 .011 | .526 .003 | .552 .012 | .571 .006 | .589 .012 |
| qsT5 | .455 .002 | .496 .010 | .519 .010 | .554 .011 | .541 .003 | .582 .011 | .615 .008 | .637 .009 |
| qsT5-plain | .440 .005 | .470 .007 | .488 .005 | .508 .008 | .520 .006 | .543 .006 | .553 .010 | .577 .013 |
+
+Table 7: Retrieval metric nDCG@10 of the query suggestion models on the MSMarco and NQ test sets. The numbers represent the nDCG@10 of the best 1, 3, 5, and 10 reformulations (including the original query), respectively, of different models. The small number indicates the standard deviation when doing bootstrap sampling from up to 10 generations of the models.
+
+
+(a)
+
+
+(b)
+Figure 6: Inner product of the best reformulation with the gold paragraph for the various query suggestion models on the MSMarco (a) and NQ (b) test sets. The dashed line shows the inner product of the original query with the gold paragraph. The bars represent the inner product with the gold paragraph of the best 1, 3, 5, and 10 reformulations (including the original query), respectively, of different models. The error bars show the 95 percent confidence interval when sampling repeatedly from up to 10 generations of the models. The RM3 and qST5 models are using pseudo-relevance feedback, i.e., information about the top-retrieved paragraphs, while the rest is only mapping from query to query.
+
+# A.2 Training and Model Details
+
+# A.2.1 Query Decoder Model
+
+We initialize the query decoder from the Tensorflow (Abadi et al., 2015) T5-base (Raffel et al., 2020) checkpoint for conditional language generation of the Huggingface transformers library (Wolf et al., 2020). We train and use only the decoder of the 220M parameter model with 12 layers, 12 heads, and a hidden state dimension of 768. We train the model on a random sample of 3M queries from the PAQ dataset (Lewis et al., 2021) with the hyperparameters provided in Table 8 for 130 hours on 16 Cloud TPU v3. Given the size of the model and the associated cost of training, we do not do an exhaustive grid search over the parameters but only sweep over four different values for the learning rate (1e-4, 3e-4, 5e-4, 1e-3). We determine the best model according to sequence classification accuracy on a held-out dev set.
+
+| Parameter | Value |
| Number Decoder Layers | 12 |
| Number Heads | 12 |
| Head Dimension | 64 |
| Embedding Dimension | 768 |
| MLP Dimension | 2048 |
| Batch Size | 64 |
| Dropout Rate | 0.0 |
| Base Learning Rate | 0.0005 |
| Warm-up Steps | 100 |
| Optimizer | AdamW |
| Weight Decay Rate | 0.01 |
| Finetuning steps on PAQ | 5M |
+
+# A.2.2 qsT5 Query Suggestion Model
+
+We initialize our qsT5 and qsT5-plain models from the T5-large checkpoint and train them with the parameters provided in Table 9 for $\sim 24$ hours on 16 Cloud TPU v3 each. We prefix the query with the keyword "Query: " and each passage, for the qsT5 model, with the keyword "Paragraph: ". For this model we rely on standard hyperparameters and, given the cost of training, do not further grid search for better values.
+
+Table 8: Training Parameters for the T5-base Query Decoder model
+
+| Parameter | Value |
| Number Encoder Layers | 24 |
| Number Decoder Layers | 24 |
| Number Heads | 16 |
| Head Dimension | 64 |
| Embedding Dimension | 1024 |
| MLP Dimension | 2816 |
| Batch Size | 128 |
| Dropout Rate | 0.1 |
| Base Learning Rate | 0.001 |
| Warm-up Steps | 1000 |
| Optimizer | AdaFactor |
| Input Token Length | 1024 |
| Output Token Length | 32 |
| Finetuning steps (qsT5) | 40k |
| Finetuning steps (qsT5-plain) | 31k |
+
+Table 9: Training Parameters for the T5-large qsT5 and qsT5-plain Query Suggestion Models
+
+# A.2.3 MQR Query Suggestion Model
+
+As with our qsT5 models, we initialize the MQR query reformulation model from the T5-large checkpoint. We train the model with the parameters provided in Table 10 for $\sim 3\mathrm{h}$ on 16 Cloud TPU v3, and choose the best checkpoint according to sequence accuracy on the dev set. Training quickly overfits after about
+
+2k step ( $\sim 16\mathrm{min}$ ). We increased the batch size to 2048 and found the adding dropout didn't help but did no further hyperparameter tuning.
+
+| Parameter | Value |
| Number Encoder Layers | 24 |
| Number Decoder Layers | 24 |
| Number Heads | 16 |
| Head Dimension | 64 |
| Embedding Dimension | 1024 |
| MLP Dimension | 2816 |
| Batch Size | 2048 |
| Dropout Rate | 0.0 |
| Fixed Learning Rate | 0.001 |
| Optimizer | AdaFactor |
| Input Token Length | 32 |
| Output Token Length | 32 |
| Finetuning steps | 1800 |
+
+# A.3 Dataset Details
+
+We experiment with a few different thresholds on what constitutes a successful reformulation for our generated dataset. We achieve the best results in terms of sequence classification accuracy of a held-out dev set of reformulations for the dataset described in the main body of the paper. Our final dataset of successful reformulations of MSMarco-train queries contains 863,207 successful query rewrites that are split among a training, development, and test set as reported in Table 11.
+
+Table 10: Training Parameters for the T5-large MQR Query Reformulation Model
+
+| Split | Number of Examples |
| Train | 768,372 |
| Dev | 86,478 |
| Test | 8,457 |
| Total | 863,307 |
+
+Table 11: Successful Reformulation Dataset Details
+
+| Type | Query | nDCG@10 |
| Original Query | shopko kennewick address | 0.63 |
| MQR | Is the address for the Shopko in Kennewick correct? | 1.00 |
| What is this shopko in Kennewick, NY address? | 1.00 |
| Is there a Shopko in Kennewick with the following address? | 1.00 |
| RM3 | shopko kennewick address 867 | 0.50 |
| shopko kennewick address store | 1.00 |
| shopko kennewick address 5500 | 0.50 |
| Sampling+QD | who is the localization of koieko shopphan | 0.00 |
| shopk kennewickko address in shopington | 0.63 |
| shopko kennewick is located in which address | 0.63 |
| qsT5 | what is the address of shopko located in kennewick washington | 1.00 |
| what is the location of shopko in kennewick washington | 1.00 |
| where is shopko store in kennewick washington | 1.00 |
| qsT5-plain | what time is open shopko at 867 kennewick | 1.00 |
| what is the main store at shopko kabetown | 0.00 |
| when does store for shopko located in north kansas | 0.00 |
| Gold Paragraph | Information about possible store closing and store hours for: Shopko in Kennewick, Washington, 99336 Address: 867 North Columbia Center Blvd | Phone: (509) 736-0884 | Type: Store, Department Store, Retail More information: |
+
+Table 12: Examples of the top query suggestions for the MSMarco query "shopko kennewick address". The final row shows the human-labeled gold paragraph and the nDCG@10 retrieval score is provided for each query. In this example, we see that the qsT5 model can leverage the PRF to successfully generate queries that focus on Kennewick in Washington. For the non-PRF models, this is not possible.
+
+| Type | Query | nDCG@10 |
| Original Query | definition of a surge | 0.50 |
| MQR | What is the definition of a surge? | 0.43 |
| What is the definition of a surge? | 0.43 |
| What is a surge? | 0.63 |
| RM3 | definition of a surge surge | 0.33 |
| definition of a surge sudden | 0.43 |
| definition of a surge increase | 0.30 |
| Sampling+QD | what is the definition of a surge | 0.50 |
| a surge to a begin in the surge definition | 0.43 |
| what is the definition of a surge | 0.50 |
| qsT5 | what is the definition of a surge in the sea | 0.50 |
| what is the meaning of surge in a wave | 0.63 |
| what is the definition of a surge in a sound | 1.00 |
| qsT5-plain | what is the swiveling of a rolling motion | 0.00 |
| what is the meaning of a surge in the emotional side of a big wave | 0.43 |
| the surge of a wave or ayurvedic chorus | 0.00 |
| Gold Paragraph | surge. 1. a strong, wavelike forward movement, rush, or sweep: the surge of the crowd. 2. a sudden, strong rush or burst: a surge of energy. 3. a strong, swelling, wavelike volume or body of something. 4. the rolling swell of the sea. 5. a swelling wave; billow. 6. the swelling and rolling sea. 7. a sudden rush or burst of electric current or voltage. b. a violent oscillatory disturbance. |
+
+Table 13: Examples of the top query suggestions for the MSMarco query "definition of a surge". The final row shows the human-labeled gold paragraph and the nDCG@10 retrieval score is provided for each query. Here, we see that the qsT5 model provides more useful additions to the query than the simple rephrasing of the MQR model. It adds topical terms like "sea", "wave", or "sound" with which it is possible to obtain improved retrieval performance.
+
+| Type | Query | nDCG@10 |
| Original Query | what aircraft can you fly with a ppl | 0.29 |
| MQR | What aircraft can you fly with a passenger? | 0.00 |
| What aircraft can you fly with passengers? | 0.00 |
| Which aircraft can you fly with a passenger? | 0.00 |
| RM3 | what aircraft can you fly with a ppl pilot | 0.36 |
| what aircraft can you fly with a ppl license | 0.32 |
| what aircraft can you fly with a ppl private | 0.43 |
| Sampling+QD | what aircraft can you fly with a ppl | 0.29 |
| what ships did you fly a learn park and can server ( pplalo | 0.00 |
| a able a flying wings able islands with a pistol pl | 0.00 |
| qsT5 | what kind of airplane can you fly with a ppl | 0.00 |
| what type of aircraft are you able to fly a private pilot | 1.00 |
| what does a personal pilot ( a ppl ) mean | 0.00 |
| qsT5-plain | what are the types of aircraft that can be used for private pilots | 1.00 |
| what kind of licenses are required to have a private pilot | 0.32 |
| how many pilots are required to take a commercial flight | 0.00 |
| Gold Paragraph | The types of aircraft one may fly depends on what they are certified for, e.g. Airplane Single Engine land. See Categories and Classes for a list. Usually, a newly minted private pilot is certified to fly all planes in the generic category single engine piston, often abbreviated SEP. This includes the Cessna 172, PA-28, Diamond DA40, Robin DR400 and similar planes. More complex types, like those with retractable undercarriage or variable pitch props, require additional training and licensing. |
+
+Table 14: Examples of the top query suggestions for the MSMarco query "what aircraft can you fly with a ppl". The final row shows the human-labeled gold paragraph and the nDCG@10 retrieval score is provided for each query. In this example only the two qsT5 models are able to add the term "private pilot" to the query that leads to good retrieval performance. Notably, the RM3 PRF baseline ranks these two terms separately as important and adds them to their suggestions.
+
+# A.5 Additional Traversal Examples
+
+
+Figure 7: Visualization of the latent-space traversal from query to gold paragraph, using 2D t-SNE. The blue point denotes the embedding of the original query "what is the third law". The green squares are the embeddings of the retrieved paragraphs for this query. The closest one about the "Third Law of Motion" is shown in the green text bar. The orange "x's" denote the embeddings of the reformulations of the query decoder when moving to the gold paragraph depicted as the red plus. The orange and red text bars show the final reformulation and the gold paragraph text, respectively.
+
+| Type | Query | nDCG@10 |
| Original Query | where is Quincy located | 0.00 |
| Reformulations | where is Quincy located in miami | 0.00 |
| where is Quincy located in a state | 0.00 |
| where is the city of Quincy located | 0.00 |
| where is the state of Quincy located | 0.00 |
| where is the city of Quincy located in illinois | 0.39 |
| where is the climate of Quincy located in illinois | 1.00 |
| where does the water come from in quincy illinois | 1.00 |
| what is the average rainfall in quincy illinois | 1.00 |
| Gold Paragraph | Location/Climate. The western most city in Illinois, Quincy is located along the eastern bank of the Mississippi River atop 90 foot limestone bluffs which overlook a wide expanse of the river and a natural harbor. Residents enjoy a moderate, four season climate where the sun shines nearly 68% of the time. This area of Illinois receives an average of 36.86 inches of rainfall a year, and an average of 24 inches of snowfall. The average winter temperature is 28 degrees and the average summer temperature is 79 degrees. |
+
+Table 15: Example of a traversal on an MSMarco query. Here, we traverse the latent space in equidistant steps from the embedding of the original query "where is quincy located", which results in an nDCG@10 retrieval score of 0, to the embedding of the gold paragraph. The queries decoded from a latent code close to the gold paragraph are concerned with the climate of Quincy, Illinois, which is the focus of the gold paragraph.
+
+| Type | Query | nDCG@10 |
| Original Query | weather year round in new york city | 0.00 |
| Reformulations | what is the weather year in new york city | 0.33 |
| what is the weather in new york city each year | 0.00 |
| what is the weather in new york city | 0.00 |
| what is the hottest season in new york city | 0.39 |
| when is the coldest month in new york | 0.30 |
| when is the hottest month in new york | 1.00 |
| Gold Paragraph | New York: Annual Weather Averages. July is the hottest month in New York with an average temperature of 25°C (76°F) and the coldest is January at 2°C (35°F) with the most daily sunshine hours at 11 in July. The wettest month is May with an average of 114mm of rain. |
+
+Table 16: Example of a traversal on an MSMarco query. Here, we traverse the latent space in equidistant steps from the embedding of the original query "weather year round in new york city", which results in an nDCG@10 retrieval score of 0, to the embedding of the gold paragraph. The queries decoded from a latent code close to the gold paragraph are more specific, asking about the hottest and coldest month in New York.
+
+| Type | Query | nDCG@10 |
| Original Query | what year declaration of independence | 0.00 |
| Reformulations | when was the declaration of independence year | 0.00 |
| when was the declaration of independence year | 0.00 |
| what year is the declaration of independence | 0.00 |
| when was the declaration of independence | 0.00 |
| what is the declaration of independence in the year | 0.33 |
| what is the declaration of independence in most of the person | 0.00 |
| what is the declaration of independence in most of them | 0.00 |
| when was the declaration of independence ( most important ) | 1.00 |
| when was the declaration of independence ( dst ) on the most important document | 1.00 |
| when was the declaration of independence ( most important ) | 1.00 |
| Gold Paragraph | The Declaration of Independence is, of course, one of the country's most important documents, adopted at the Second Continental Congress on July 4, 1776. The text and purpose of the Declaration would likely be recognizable to those who have applied for U.S. citizenship, since questions about the document appear on the naturalization test. |
+
+Table 17: Example of a traversal on an MSMarco query. Here, we traverse the latent space in equidistant steps from the embedding of the original query "what year declaration of independence", which results in an nDCG@10 retrieval score of 0, to the embedding of the gold paragraph. The queries decoded from a latent code close to the gold paragraph, include the keyword "important" that seems to be helpful in retrieving this particular gold paragraph.
+
+| Type | Query | nDCG@10 |
| Original Query | how many us dollars are currently in circulation | 0.00 |
| Reformulations | how many dollars are currently in circulation | 0.00 |
| how many dollars are in circulation in us | 0.00 |
| how many dollars are in circulation in the us | 0.00 |
| how many dollars are in circulation in the us | 0.00 |
| how many dollars are in circulation in the us | 0.00 |
| what are the dollars that are in circulation us | 0.00 |
| what are the sets of dollars in the us | 0.00 |
| what are the denominations of dollars around us | 0.50 |
| what are the denominations of $ 100 were there | 1.00 |
| what are the denominations of $ more than that were used in the us | 1.00 |
| Gold Paragraph | Large denominations of United States currency. Large denominations of United States currency greater than $100 were circulated by the United States Treasury until 1969. Since then, the U.S. dollar has only been issued in seven denominations: $1, $2, $5, $10, $20, $50, and $100. |
+
+Table 18: Example of a traversal on an MSMarco query. Here, we traverse the latent space in equidistant steps from the embedding of the original query "how many us dollars are currently in circulation", which results in an nDCG@10 retrieval score of 0, to the embedding of the gold paragraph. The decoded queries drift away from the original questions of dollars in circulation to the denominations of dollar bills. The reason of this drift becomes obvious by looking at the gold paragraph that explains the denominations of the US Dollar but not the money currently in circulation. This is one of many examples where the labeled gold paragraph is not correct and hence the decoded queries drift away from the original query.
+
+| Type | Query | nDCG@10 |
| Original Query | are Tesla electric cars | 0.00 |
| Reformulations | are Tesla electric cars no are they electric car | 0.00 |
| is Tesla electric cars a car or they are electric | 0.00 |
| tesla electric cars are they or electric car | 0.00 |
| tesla electric cars are they being or electric | 0.00 |
| tesla cars are electric to be or electric cars | 0.00 |
| tesla electric cars are off of what kind of cars | 0.00 |
| tesla electric cars are a bolton on which time | 0.00 |
| tesla electric cars a mile off what speed are they | 0.00 |
| 737 el taton speedway was flying away on how many cars | 1.00 |
| 737 bolts on a ta speedway how many miles off airport | 1.00 |
| Gold Paragraph | A Qantas Boeing 737 aircraft and a Tesla electric car race on the nearly 2 mile runway at Avalon Airport. The Tesla was hard to catch off the start. Both travelled neck and neck as the 737 reached take-off speed of 161 mph and the Tesla hit 155 mph. USA TODAY. |
+
+Table 19: Example of a traversal on an MSMarco query. Here, we traverse the latent space in equidistant steps from the embedding of the original query "are Tesla electric cars", which results in an nDCG@10 retrieval score of 0, to the embedding of the gold paragraph. In this example the final decoded query perfectly solves the retrieval problem (nDCG of 1) even though being semantically very strange. These queries are an interesting example as their embedding is close to the embedding of the gold paragraph, even though they have little non-stopword overlap with the gold paragraph (in the second to last query, only "737" overlaps exactly).
\ No newline at end of file
diff --git a/decodinganeuralretrieverslatentspaceforquerysuggestion/images.zip b/decodinganeuralretrieverslatentspaceforquerysuggestion/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..097ded0b7519f92b2c6189561ec069d515ab34c8
--- /dev/null
+++ b/decodinganeuralretrieverslatentspaceforquerysuggestion/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:eccd2ec961c04d0db2c2241dc44723bd110aff83c8326689a2a1406b6e2daefb
+size 1469787
diff --git a/decodinganeuralretrieverslatentspaceforquerysuggestion/layout.json b/decodinganeuralretrieverslatentspaceforquerysuggestion/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2546ce48bc7caefed5e2e78104681a43f275a27f
--- /dev/null
+++ b/decodinganeuralretrieverslatentspaceforquerysuggestion/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:30c0b7c901b3b4db2cef34db2f71ab48e1b492f8f36a7b6ca3d0fe5b9af319fc
+size 439560
diff --git a/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_content_list.json b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e97cf49fb557c7d99062b034277a822924589229
--- /dev/null
+++ b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9eefadc7d88ea52bc3a2c78480a2e93c0dafa3c0ac712c69d5abaa212f2edd44
+size 111295
diff --git a/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_model.json b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..2ed3b485c4e3c37ff669d54d47e8fea82455dc33
--- /dev/null
+++ b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f16762f8161033dd305587cfc6898937f9519335b41dcdabecb5e672e2f237ff
+size 132489
diff --git a/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_origin.pdf b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..1802850f4d2b4d678220ef35c4fb6d7d9af8c9f5
--- /dev/null
+++ b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/b1a5f9bf-ce66-4ad3-a038-fc1f5fe3d891_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0ed651017aa7a2f8002c8aab107f9e525b1987aa640a20de9c2df28a4bc073b6
+size 1183544
diff --git a/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/full.md b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..922758c842ca64824d3a766f6c41ecafd2eb43be
--- /dev/null
+++ b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/full.md
@@ -0,0 +1,417 @@
+# Deconfounding Legal Judgment Prediction for European Court of Human Rights Cases Towards Better Alignment with Experts
+
+Santosh T.Y.S.S $^{1*}$ and Shanshan Xu $^{1*}$ and Oana Ichim $^{2}$ and Matthias Grabmair $^{1}$
+
+1School of Computation, Information, and Technology; Technical University of Munich, Germany
+
+$^{2}$ Graduate Institute of International and Development Studies, Geneva, Switzerland
+
+{santosh./(tokala, shanshan.xu, matthiasgrabmair}@tum.de
+
+oana.ichim@graduateinstitute.ch
+
+# Abstract
+
+This work demonstrates that Legal Judgement Prediction systems without expert-informed adjustments can be vulnerable to shallow, distracting surface signals that arise from corpus construction, case distribution, and confounding factors. To mitigate this, we use domain expertise to strategically identify statistically predictive but legally irrelevant information. We adopt adversarial training to prevent the system from relying on it. We evaluate our deconfounded models by employing interpretability techniques and comparing to expert annotations. Quantitative experiments and qualitative analysis show that our deconfounded model consistently aligns better with expert rationales than baselines trained for prediction only. We further contribute a set of reference expert annotations to the validation and testing partitions of an existing benchmark dataset of European Court of Human Rights cases.
+
+# 1 Introduction
+
+The task of Legal Judgment Prediction (LJP) has recently gained increasing attention in the legal and mainstream NLP communities (Aletras et al., 2016; Zhong et al., 2018; Medvedeva et al., 2020; Liu et al., 2019; Sert et al., 2021). Legal cases are resolved through the exchange of arguments in front of a decision body by lawyers who represent litigating parties. This typically involves evidential reasoning, the determination of relevant rules from sources of law (e.g., codes, regulations, precedent), their application to the case, and the balancing of legal and societal values. In the NLP context, LJP takes the form of classifying the outcome of a case from some textual representation of its specific facts, effectively skipping legal reasoning. This forms a counterpoint to knowledge-focused approaches to outcome prediction (e.g., Brüninghaus and Ashley, 2005; Branting, 2013; Grabmair,
+
+
+Figure 1: Our deconfounding experiment architecture
+
+2017) that connect to a lawyer's understanding of the domain but also require substantial knowledge engineering.
+
+This carries particular risk in the legal domain, where systems may rely on data elements that are statistically predictive but legally irrelevant, or even forbidden as decision criteria (e.g., the race of an accused person). This can lead to undesirable consequences, ranging from suboptimal litigation strategy decisions, flawed inference about factors predictive for the outcome, to disparate impact of decisions across groups that are to be treated equally. If legal decisions are to be informed by predictive systems processing textual case descriptions, then such systems must strive to be as closely aligned with legally relevant and permissible parts of the input as possible.
+
+In this work, we focus on LJP for the European Court of Human Rights (ECtHR), which adjudicates complaints by individuals against states about alleged violations of their rights as enshrined in the European Convention of Human Rights. We trained deep neural models on four tasks across two existing, related datasets (Chalkidis et al., 2019, 2022a) around predicting such violations alleged by the claimant and decided by the court. We find that the models substantially base their predictions on aspects of the text that correlate with the outcome
+
+but either have no legal bearing or are forbidden nationality-related information that stem from the distribution of cases arising at the court.
+
+To improve the alignment of model focus with legal expert understanding, we apply a series of deconfounding measures, including a vocabulary-based method which identifies predictive tokens using a simple model. The third author, who is an ECtHR expert, then identifies distractors among them. The distracting signal can subsequently be removed from the encodings via adversarial training. This procedure is an effective way of engaging with domain experts and obtaining information about what the model should be steered away from by means of deconfounding, rather than trying to attract the model towards relevant elements via expensive data collection for supervised training. For simplicity, throughout this paper, we use 'deconfounding' in an inclusive sense as the mitigation of distracting effects of (a) confounders in the statistical sense that influence both the dependent and independent variables, (b) reverse causation relationships, and (c) other attributes that spuriously correlate with the target variable. See Fig. 1 for an overview of our experiment design.
+
+We evaluate our trained and deconfounded models with regard to an alignment of its explanation rationales with (1) a dataset of expert passage relevance assessments we collected and will make available to community as a supplement to Chalkidis et al. (2019), and (2) on expert relevance assessments published as part of Chalkidis et al. (2021). Our results show that our deconfounding steps succeed in improving the model focus alignment with expert-identified, relevant patterns on both sets of reference annotations.
+
+In sum, we make the following contributions:
+
+- We introduce an expert-informed deconfounding method which identifies distracting effects from confounders and spurious correlations using a simple model, and mitigates them through adversarial training, thus helping to improve the alignment of the model focus with legal expert rationales.
+- We empirically evaluate this method on four tasks in legal judgment prediction on ECtHR data and show that our model consistently aligns better with expert rationales than a baseline trained for the prediction target only.
+- We release a set of gold rationales annotated
+
+by an ECtHR expert as a supplement to an existing dataset to facilitate future work on deriving more useful insight from trained predictive systems in the legal domain.\*
+
+# 2 Related Work
+
+LJP as an NLP task has been tackled using n-gram representations (e.g., Aletras et al., 2016; Medvedeva et al., 2020), word embeddings and domain models (Branting et al., 2021), and deep neural networks (e.g., Chalkidis et al., 2019; Ma et al., 2021; Xu et al., 2020). Special attention must be given to the origin of the text from which the prediction is to be made. Medvedeva et al. (2021, 2022) recharacterize LJP on texts produced before the outcome is known as 'forecasting' and observes that most current works 'classify' judgments based on the data compiled after the outcome has been determined. They also find that forecasting is a harder task. This result is consistent with our finding of confounding effects from text production by the ECtHR, resulting in a prediction from fact descriptions that were influenced by the decision.
+
+Moverover, the relationship between the information LJP models rely on and legal expert analysis of texts remains underexplored. Bhambhoria et al. (2021) find that transformer-based models exploit spurious correlations and that simple models, such as XGBoost, can achieve similar performance. Chalkidis et al. (2021) extract model rationales for alleged violation prediction and observes limited overlap with expert markup. Similarly, a small study in Branting et al. (2021) finds that users do not perceive case prediction-derived highlighting as useful in making predictions themselves. Our work contributes to this state of the art by using adversarial deconfounding to improve the overlap between what systems predict from with what legal experts consider relevant.
+
+Deconfounding A growing number of works have raised awareness that deep neural models may exploit spurious statistical patterns and take erroneous shortcuts (McCoy et al., 2019; Bender and Koller, 2020; Geirhos et al., 2020). A common method of mitigating this is adversarial learning. Pryzant et al. 2018 use a gradient reversal layer (Ganin et al., 2016) to deconfound lexicons in text classification. Other domains that adopt adversarial training to
+
+eliminate confounders include bioinformatics (Dincer et al., 2020) and political science (Roberts et al., 2020). Many existing works on identifying shortcuts focus on situations where these patterns are known in advance and may require potentially expensive data collection. In fairness-focused legal NLP, Chalkidis et al. (2022b) observe and remedy group disparities in LJP performance on the ECtHR informed by metadata attributes (respondent state, applicant gender, applicant age). We extend this to explainability in LJP by involving a legal expert in a procedure that allows an efficient, incremental identification of distracting information, as well as its removal via adversarial training.
+
+Interpretability We employ interpretability techniques to evaluate model alignment with expert rationales. Danilevsky et al. (2020) reviews and categorizes the main current interpretability methods. Though initial works (Ghaeini et al., 2018; Lee et al., 2017) used attention scores as explanation for model decisions, Bastings and Filippova (2020); Serrano and Smith (2019) point out that saliency methods, such as gradient based methods (Sundararajan et al., 2017; Li et al., 2016), propagation based methods (Bach et al., 2015), occlusion based methods (Zeiler and Fergus, 2014), and surrogate model based methods (Ribeiro et al., 2016) are better suited for explainability analysis. However, the reliability and informativeness of these methods remains an open research problem. Our model uses the currently most commonly used Integrated Gradients (IG) (Sundararajan et al., 2017), which computes the gradient of the model's output with respect to its input features.
+
+# 3 ECtHR Tasks & Datasets
+
+The ECtHR has been the subject of substantial prior work in LJP. We use two datasets for model training and evaluation: First, for binary violation we use the dataset by Chalkidis et al. (2019) of approx. 11k case fact statements, where the target is to predict whether the court has found at least one convention article to be violated. To evaluate alignment, we annotate 50 (25 each) expert rationales for cases from both the development and test partitions (See App. C for the annotation process). Second, for article-specific violation, we use the LexGLUE dataset by Chalkidis et al. (2022a), which consists of 11k case fact statements along with information about which convention articles have been alleged to be violated, and which the court has found to
+
+be violated. For alignment, we merge this data with the 50 test set rationales from Chalkidis et al. (2021). While both datasets stem from the ECtHR's public database, they differ in case facts and outcome distribution as we explain in Sec. 3.1. The input texts consist of each case's FACTS section extracted from ECtHR judgments. This section is drafted by court staff over the course of the case proceedings. While it does not contain the outcome explicitly, it is not finalized before the final decision has been determined, potentially creating confounding effects.
+
+We conduct experiments on four LJP tasks:
+
+Task J - Binary Violation For our task J, the model is given a fact statement and is asked to predict whether or not any article of the convention has been violated. We train our models on Chalkidis et al. (2019) and evaluate alignment on the set of expert rationales we collected.
+
+Task B - Article Allegation We train and evaluate on LexGLUE's $ECtHR$ $B$ ,* where the fact description is the basis to predict the set of convention articles that the claimant alleges to have been violated. It can be conceptualized as topic classification in that the system needs to identify suitable candidate articles (e.g., the right to respect for private and family life) from fact statements (e.g., about government surveillance). We test alignment on the expert rationales by Chalkidis et al. (2021).
+
+Task A - Article Violation We also experiment with LexGLUE's ECtHR $A$ , which is to predict which of the convention's articles has been deemed violated by the court from a case's fact description. Task A is a more difficult version of task B, where both an identification of suitable articles and a prediction of their violation must be performed. For alignment, we again use the expert rationales by Chalkidis et al. (2021), which are technically intended for task ECtHR $B$ , but which we consider to also be suitable for an evaluation of task A.*
+
+Task A|B - Article Violation given Allegation We further disentangle the LexGLUE tasks and pose ECtHR A|B. Given the facts of a case and the allegedly violated articles, the model should predict which (if any) specific articles have been violated.
+
+This task reflects the legal process, as the court is aware of allegations made by the applicants when deciding. Providing information about the allegations shifts the nature of the task from topic classification to article-specific violation/non-violation prediction, thus refocusing the model and ideally leading to violation-specific explanations.
+
+# 3.1 Data Distribution & Preprocessing
+
+In order to facilitate model alignment, we worked with our ECtHR expert to identify shallow prediction signals in the fact statements that are unrelated to the legal merits of the complaint.
+
+# 3.1.1 Length and Respondent State
+
+For the task J dataset of Chalkidis et al. 2019, we find that the distribution of fact description length (number of sentences) and the distribution of respondent states are different between the two classes (see Appendix A). We hence account for the identity of the respondent state and the length of the fact descriptions via our deconfounding procedure for both datasets.
+
+# 3.1.2 Accounting for Inadmissible Cases
+
+We also observe in the task J dataset that the magnitudes of the running paragraph numbers differ between the classes, and that the single word "represented" strongly correlates with the positive class. This phenomenon arises because 2.6k of the 7k training cases are 'inadmissible' cases labeled as 'non-violation'. Legally, inadmissible cases are not necessarily 'non-violation' as inadmissibility relates to complaints not fulfilling the court's formal or procedural criteria.* In such cases, the court does not examine the merits of the application. The more interesting non-violation cases are such that are admissible, but in which no violation of the convention has been found. The single negative class contains instances of both inadmissible and admissible-but-no-violation-found cases. As explained above, the input texts of Chalkidis et al. 2019 are extracted from the FACTS section of full ECtHR decisions. In inadmissible cases, the applicant's background information can typically be found at the beginning of that section. We found that almost all inadmissible case facts start with
+
+the same formulaic sentence stating the applicant's name, nationality, and legal representation. This specific sentence is absent from the texts of admissible cases (violation and non-violation), where that information is part of a separate PROCEDURE section not included in the dataset. Moreover, due to the PROCEDURE section preceding the FACTS section in admissible cases, the running paragraph numbers appearing in FACTS sections of inadmissible cases are smaller than those of the admissible cases. If not remedied, these phenomena provide a considerable predictive signal for the label and distract the system from legally relevant information. In our experiments, we hence remove paragraph numbers from the input via preprocessing and account for distractor vocabulary via our deconfounding procedure described in Sec. 4. Still, the nature of task J remains unchanged and requires the system to classify the outcomes of a collection of both admissible and inadmissible cases.
+
+# 3.1.3 Article-Specific Violation
+
+By contrast, the more recent LexGLUE dataset only contains admissible cases and corresponding information about which articles the claimant has alleged to have been violated (for task B) along with those that the court has found to have been violated, if any (task A). The collection covers 10 different convention articles that make up the largest share of ECtHR jurisprudence. Each article has been alleged in a partition of the cases, and has been found to be violated in a subset of these.* For a given article in task B, all cases in which it has been alleged can be considered positive instances while the remaining cases are negatives. We consider task B as akin to topic classification, where the rights enshrined in the convention articles (e.g., Art. 6: right to a fair trial; Art. 1 Protocol 1: protection of property, etc.) may correlate with certain case fact language (e.g., related to law enforcement or appropriation, respectively). Task A incorporates this step and adds violation prediction per article, which is more difficult in principle. However, we observe that a few articles account for a large portion of the data and the conditional probability of a positive violation label in task A given its allegation labels from task B can be very high (see App. B). This makes an analysis of what trained models focus
+
+on more difficult, since they may learn to identify these dominant articles with high conditional violation probability, and be distracted from focusing on information that specifically signals violations of those articles. To remedy this, we propose task AlB that provides models an easy access to the label information of B, facilitating their focus only on determining whether the court finds a violation of given articles. This task is realistic since the allegations by the claimant are known to the court at the time that it decides whether the respondent state has violated the convention in the case.
+
+# 4 Expert-Informed Deconfounding
+
+We apply an expert-informed deconfounding method designed to mitigate the distracting effects of confounding elements and spurious correlations. As Pryzant et al. (2018) observe, accounting for confounders is common practice throughout many data analysis tasks to capture the intended signal and facilitate explainable models. In LJP, we understand confounding elements as such that influence both the observed legal outcome (convention violations found by the court as coded in the dataset) and the input text from which this outcome is to be predicted (here: ECtHR fact statements). Already covered examples are the different distribution of information across sections for admissible and in-admissible cases and the length of the fact descriptions (inadmissible cases tend to require less factual information to be dismissed). An example of a spurious correlation is the identity of the respondent state (certain article violations will be claimed more often against a small number of governments, leading to a correlation). They each should have no bearing on the probability of an outcome in a given case as a judge will not decide against a violation because the facts are short, or because the case is against a particular government.
+
+Confounding effects and spurious information in LJP may not be known ahead of time, especially if the legal decision is not made on the basis of an immutable a priori document, but rather on the basis of text that is technically a part of the eventual judgment. Our expert-informed method is intended to mitigate such situations where spurious correlations are introduced in the text production but may
+
+not be known in advance as explicit confounders.
+
+Our method consists of two steps: (i) Identification of distracting attributes for deconfounding through a combination of simple model training and minimal expert markup, and (ii) mitigation of these effects through adversarial training.
+
+# 4.1 Step 1: Identification of Distracting Attributes and Tokens
+
+We first identify input attributes and categorize them as either distracting or genuinely legally relevant in an expert consultation. 'Distracting' attributes are highly correlated with the task label but not relevant in a human expert prediction. Attributes can be either (i) explicit in the text (such as vocabulary tokens) or (ii) implicit (e.g., country, text length, etc.). Implicit attributes can be derived from available metadata or a corpus analysis.
+
+For textual attributes, we apply depth-limited decision trees on an n-gram representation of the fact statement to predict the case outcome. We extract all tokens that appear in the trees and iterate, successively removing tokens identified as predictive. Compared to extracting tokens from a single larger tree, this process is better suited to remove high-entropy-reducing tokens one typically finds near the root of trees. The list of removed tokens is then presented to a legal expert, who categorizes them into spurious and legally genuine (see Appendix Sec. F for the list of spurious vocabulary identified by the expert and the rationale behind the choices). This requires substantially less effort from the expert compared to other methods, such as data annotation or manual creation of counterfactuals. To prevent trees from picking up very sparse tokens, we filter the extracted terms using local mutual information (LMI) (Schuster et al., 2019), a re-weighted version of pointwise mutual information (PMI) (Church and Hanks, 1990). We calculate LMI for each pair of token and label as illustrated in Appendix Sec. G.
+
+# 4.2 Step 2: Mitigation of Distracting Attributes
+
+We assume a neural NLP model $M$ consisting of a feature extractor $F$ and classifier $C$ with parameters $\theta_{f}$ and $\theta_{c}$ , respectively. For each confounder $k$ , we apply a discriminator $D_{k}$ with parameters $\theta_{d_{K}}$ to the feature extractors. We use adversarial training to maximize the feature extractor's ability to capture information for the main classification target while minimizing its ability to predict the
+
+value of distractor attributes. This encourages the model to generate distractor-invariant feature representation for the classifier. We use the following adversarial training objective:
+
+$$
+\sum_ {k} \arg \min _ {\theta_ {d _ {k}}} L \left(D _ {k} (F (x)), y _ {k}\right) \tag {1}
+$$
+
+$$
+\arg \min _ {\theta_ {f}, \theta_ {c}} [ L (C (F (x)), y _ {c}) - \sum_ {k} \lambda_ {k} L (D _ {k} (F (X)), y _ {k}) ] \tag {2}
+$$
+
+where $L$ represents the loss, $\lambda$ is a hyperparameter, $x$ is the input, $y_{c}$ is the label, and $y_{k}$ is the distracting attribute $k$ . The above optimization is performed using a gradient reversal layer (GRL) (Ganin and Lempitsky, 2015) to jointly optimize all the components instead of alternately updating the components as in GANs (Goodfellow et al., 2014). The GRL is inserted between the feature extractor and discriminators. It acts as the identity during the forward pass but, during the backward pass, scales the gradients flowing through by $-\lambda$ , making the feature extractor receive the opposite gradients from the discriminator. This changes the overall objective function to:
+
+$$
+\arg \min _ {\theta_ {f}, \theta_ {c}, \theta_ {D}} [ L (C (F (x)), y _ {c}) + \sum_ {k} \lambda_ {k} L (D _ {k} (G R L ((F (X))), y _ {k}) ] \tag {3}
+$$
+
+We hypothesize that learning distractor-invariant feature representations through adversarial learning will help the model to focus on parts of the input that experts consider relevant.
+
+# 5 Experiments & Discussion
+
+In this section we describe our experiments in using our proposed deconfounding methodology to improve the alignment of model focus on the input with expert rationales on our set of LJP tasks.
+
+# 5.1 Models
+
+Baseline: We use the BERT variant of Hierarchical Attention Networks (Yang et al., 2016) as a baseline model. To segment our very long input texts we resort to a greedy sentence packing strategy in which we pack as many sentences as possible into one packet until it reaches the predefined maximum length (512 tokens constrained BERT). When a sentence exceeds this maximum, we split it into parts to fit into multiple packets. We encode each packet with LegalBERT (Chalkidis et al., 2020) to obtain the token level representations. Following Yang et al., 2016, we use a token attention layer
+
+aggregating the representation of the tokens and form a sentence (packet) vector. We pass these sentence vectors through a GRU encoder to obtain contextual representations. These are aggregated at the document level using a sentence attention layer. This model constitutes the feature extractor component $F$ in our architecture. The obtained document representation is passed through dense layers for the final target prediction, constituting our classifier component $C$ .
+
+paraRem: Same as the baseline model but trained on data from which the paragraph number artifacts have been removed (see Sec. 3.1).
+
+gradCou: paraRem model extended with a multiclass discriminator with a cross-entropy loss predicting the identity of the respondent government, and a corresponding deconfounding GRL.
+
+gradLen: paraRem model extended with a length discriminator predicting the length (number of sentences) of the document via a set of bins and a cross-entropy loss, and a corresponding GRL to predict the bin value.
+
+gradVocab: paraRem model extended with a vocabulary discriminator to predict the presence of identified spurious tokens, and associated GRL. As there can be multiple spurious tokens in a document, we employ binary entropy loss per token as it is a multi-label classification.
+
+We refer to the above three deconfounded models collectively as singleGrad models.
+
+gradAll: paraRem model extended with all country, length, and vocabulary discriminators in parallel, and associated GRLs.
+
+Please refer to Appendix Sec. H for details on model configuration and training.
+
+# 5.2 Quantitative Evaluation & Discussion
+
+# 5.2.1 Expert Alignment Evaluation
+
+Our main objective is to evaluate the alignment of the model's focus on the input text with legal expert rationales (i.e., selected subsets of relevant segments of the input). Following Chalkidis et al. 2021, we measure the model's ability to identify the correct rationales at the paragraph level, which is the natural granularity of ECtHR fact sections. To extract the importance score for each paragraph, we rely on an interpretability technique which quantifies the impact of a particular input token towards the final prediction of the model.
+
+We use integrated gradients (Sundararajan et al., 2017) to obtain a token-level focus score and ag-
+
+ | J | B | A | A|B |
| Model | valid | test | test | test | test |
| Random | 38.67(4.52) | 28.22(3.16) | 36.65(2.91) | 36.65(2.91) | 36.65(2.91) |
| baseline | 39.04(4.31) | 29.73(3.28) | 39.07(2.94) | 40.10(3.02) | 41.36(3.02) |
| paraRem | 41.81(3.59) | 31.53(3.43) | 41.47(3.06) | 41.93(2.88) | 41.86(2.86) |
| gradCou | 42.29(3.54) | 33.37(3.75) | 42.36(3.09) | 43.56(2.78) | 43.16(2.85) |
| gradLen | 42.21(3.55) | 33.58(2.98) | 43.55(2.92) | 43.12(3.31) | 43.75(3.14) |
| gradVocab | 42.96(3.57) | 33.77(3.41) | 43.34(3.02) | 44.48(3.36) | 44.39(2.86) |
| gradAll | 44.42(3.40) | 34.48(3.74) | 44.84(3.13) | 45.95(3.09) | 44.91(3.18) |
| p-value | 0.164 | 0.013 | 0.031 | 0.008 | 0.071 |
+
+Table 1: Expert alignment performance expressed in precision@Oracle scores; value in brackets indicates standard error of the computed score; p values compare gradAll versus paraRem and were computed using a paired t-test.
+
+aggregate paragraph-level scores as the squared L2-norm of token scores in the paragraph divided by the square root of its number of tokens to account for length variation. We compute precision@k conditioned on some fixed $k$ between the top-k paragraphs based on paragraph scores and golden paragraph rationales. The number of relevant paragraphs in gold rationales varies considerably, so a predefined $k$ is inadequate. Thus, we compute precision@Oracle following Chalkidis et al., 2021, where Oracle is the number of relevant paragraphs in the gold rationales.
+
+For tasks J, A, and A|B, the negative label (i.e., non-violation) is of similar interest as the positive label. In task B, however, the negative label merely indicates that a specific article has not been alleged, which is legally largely uninteresting. Hence, we reduce negative IG scores of tokens (indicating a negative contribution to the prediction) to zero.
+
+# 5.2.2 Prediction Performance Evaluation
+
+We also report the models' performance on the main four LJP tasks. For Task J, we report the macro F1-score for binary violation prediction. For Task A and B, following (Chalkidis et al., 2022a), we report micro-F1 ( $\mu$ -F1) and macro-F1 (m-F1) scores. For Task A|B, we also report micro-F1 and macro-F1 scores. In computing the above metrics for tasks A and A|B, we consider the cases in which a particular article has been deemed violated as pos
+
+itive instances and the rest of the instances as negatives. We also introduce hard-macro-F1 (hm-F1) for both Task A and AlB, in which F1 is computed for each article using only those instances as negatives where an article has been alleged as violated but not found so by the court.
+
+# 5.2.3 Quantitative Evaluation Results
+
+Table 1 and Table 2 show the performance of different models on expert alignment and outcome prediction, respectively.
+
+paraRem vs. baseline: We observe that paraRem outperforms the baseline model in expert alignment across all tasks with a minimal drop in prediction performance. Task J stands out in that removing distracting signals via paragraph number removal even leads to a marginal improvement. Notably, we separately confirm the vulnerability of the baseline model by applying it to the test set with paragraph numbers removed and evaluate it on a test set without paragraph numbers, resulting in macro-F1 of 51.16 (i.e., a nearly 30 points drop).
+
+gradCou, gradLen, gradVocab vs. paraRem: In all tasks, we observe that all singleGrad models improve in expert alignment performance over paraRem by a small but consistent margin. This demonstrates the ability of our deconfounding component to help the model better identify legally relevant parts of the input. Notably, gradVocab shows the most improvement in alignment over paraRem in all tasks except Task B (alleged article prediction), where gradLen performs best. During development on task B, we observed that the decision-tree based removal of predictive words led to only a marginal falloff in tree model accuracy, even after multiple iterations, since there was simply a lot of topical words (e.g., for police misconduct, legal proceedings, etc.) to take over as some of them were removed. This in part reflects the different nature of the tasks and shows a limitation of our tree-training-based method for identifying spurious tokens. Similar to paraRem, the gradLen model (in case of Task A, B, and AlB) also shows improvement in prediction performance compared to the baseline model. This suggests that deconfounding can potentially prevent the model getting stuck in distractor-related local optima.
+
+Alignment: All singleGrad models outperform the baseline with regard to expert alignment. We observe that gradAll achieves the highest score, which establishes some degree of complementarity among the three singleGrad models and the distracting
+
+signals they remedy. A paired t-test (gradAll vs. paraRem) reveals p-values above typical significance levels for the validation partition of task J, along with a considerable divergence in the general score level for the two tasks. We conjecture that this is the result of our small rationale sample size (50 from each partition) and differences in distribution between the task J data partitions, which have been split along the timeline rather than random. We also see a higher p-value for task AlB, which is intuitive since it is the most difficult. Its dataset lacks easily identifiable inadmissible cases (as in task J) and it has access to B's labels as concurrent, non-textual input. To gain some more insight into AlB, we report on a qualitative error analysis of the model rationales below.
+
+# 5.3 Qualitative Evaluation & Discussion
+
+Expert Scores: We sample 40 cases from task AI B validation and test sets (see App. Sec. D). We provide the expert with randomized visualizations of IG scores at the token level derived from our paraRem and gradAll models. Following (Jayaram and Allaway, 2021), the expert was asked to rate these on a five-point Likert scale (range -2 to 2) on two metrics: (i) Sufficiency: Is a sufficiently large set of tokens focused on to arrive at the prediction?; and (ii) Irrelevance: How many irrelevant tokens does the model focus on? We phrased the scale such that, for both parameters, a higher rating signals a better alignment between the model focus and the expert's assessment. Table 3 presents averages of the raw scale scores. We observe that the deconfounded gradAll model scores higher (See App. I for an example pair of IG visualizations).
+
+Manual IG Inspection: For the paraRem model, we notice that high scoring IG tokens are sparse, whereas in gradAll, focus is densely distributed. There, contiguous spans of tokens tend to receive higher scores. This phenomenon is likely due to paraRem being drawn to single word distractors. Deconfounding helps the gradAll model to spread its focus across larger segments of the text. Our ECtHR expert further observed that gradAll highlighted words that, in conjunction, were indicative of the outcome, even if those were a considerable distance apart. At the same time, however, it seemed that two words hinting at opposite outcomes in a single sentence forced the system to focus only on one of the two, leaving the other one unhighlighted. We conjecture that these long- and
+
+short-distance phenomena are a result of the hierarchical model architecture necessitated by the long documents and leave their further exploration for future work.
+
+An inspection of high scored tokens in paraRem reveals that many of them are highly discriminative in our decision tree models, showing that complex neural models can easily fall for distractors at the expense of missing equally predictive but semantically more complex signals. This reinforces our paradigm to identify discriminative tokens using a simpler model and subject them to expert scrutiny. In particular, we found that the word "represented" forms a natural decoy and, when injected into a violation-outcome fact statement, flips the predicted label of trained deep neural models. This led us to believe those models rely more on individual words than one might expect, and motivated us to explore how this can be exploited with information derived from simple models. Figure 2 shows that the performance of decision trees with unigram features (at iteration 1 without removed tokens) can even come close to BERT models.
+
+In paraRem, we further observe that tokens at the start of sentences receive higher IG scores. We believe this to be the model counting sentences, which justifies deconfounding for length. For gradAll, we observe that sentence beginnings still receive focus, but less strongly so. This may be due to BERT recognizing sentence boundaries.
+
+Further alignment improvement: The overall low precision@Oracle scores show that considerable differences in alignment with human experts remain. We conjecture that the model is shifting its focus, at least in part, to other spurious attributes which our current setup could not reveal. This calls for further investigation to design effective methods to identify such patterns. However, we expect them to be increasingly subtle and difficult to recognize, potentially even for legal experts. An intuitive upper bound for the system would be the annotation agreement of multiple experts, which to the best of our knowledge remains unexplored in the current state of the art.
+
+Expert Pattern Identification: Our results naturally raise the question of how distractors can be identified in ECtHR fact texts by experts. Generally, the patterns we focused on affect the relationship between the argumentation in the judgment and the supportive facts given. There is copious literature on the court's inconsistent approach to
+
+ | Task J | Task B | Task A | Task A|B |
| Model | m-F1 | μ F1 | m-F1 | μ F1 | m-F1 | hm-F1 | μ F1 | m-F1 | hm-F1 |
| baseline | 81.23 | 78.08 | 68.42 | 69.28 | 58.80 | 55.30 | 77.42 | 68.23 | 58.95 |
| paraRem | 82.67 | 77.82 | 66.90 | 68.94 | 58.35 | 55.62 | 77.20 | 67.32 | 58.80 |
| gradCou | 81.22 | 76.31 | 66.58 | 67.47 | 56.40 | 54.04 | 76.83 | 66.85 | 58.14 |
| gradLen | 81.99 | 78.06 | 67.19 | 69.18 | 58.88 | 56.10 | 79.07 | 69.79 | 61.24 |
| gradVocab | 82.00 | 77.68 | 66.40 | 69.06 | 58.47 | 55.71 | 78.87 | 69.49 | 60.64 |
| gradAll | 81.53 | 77.46 | 66.75 | 68.32 | 58.06 | 53.74 | 78.71 | 69.26 | 60.58 |
+
+Table 2: Prediction Performance
+
+| Metric | paraRem | gradAll |
| Sufficiency (↑) | 0.150 | 0.550 |
| Irrelevance (↑) | 0.475 | 0.625 |
+
+Table 3: Qualitative evaluation scores
+
+legal decision-making (e.g., Madsen et al. 2018) and it is known to switch between judicial policies depending on case circumstances (Helfer and Voeten, 2020). We hence paid attention to specific markers in the fact section and correlated them to existing precedents and argumentation patterns. A few examples: The court may decide to make use of positive obligations and decide against the state (violation) by highlighting failures of national authorities, or may decide to use those same positive obligations under 'the responsible authorities' doctrine, highlighting the efforts of national authorities to bring domestic legislation in line with the convention, thus deciding that there has been no violation. There are also fact patterns and practices specific to particular state parties to the convention (e.g., prison overcrowding, procedural issues in child abduction cases). The court may also sometimes highlight specific facts of a case with the view to 'document' its resemblance to, or divergence from, an existing precedent. A detailed, legally informed case study on predictive patterns is beyond the scope of this work.
+
+# 5.4 Recommendations for LJP Research
+
+In order to produce value for legal practice, we believe that LJP/LJF as an NLP task should strive for a productive combination of expert knowledge with data-derived insight. Based on our results, we formulate the following recommendations: First, as has already been observed in the field, any prediction/classification should happen from suitable source text that does not encode information about the outcome but contains as complete factual information as possible, or at least control for this
+
+influence. Second, straightforward predictors (e.g., input length and shallow unigram models) should be used to identify distractors and confounders. Third, claimed performance levels in predicting case outcomes should be contextualized by information about the distribution of the legal issues and respective conditional outcome probabilities in the corpus, as well as against baseline classifiers capable of exploiting known distractors. Fourth, more granular outcome variable information (e.g., case declared inadmissible vs. case dismissed on the merits, decomposition into outcomes of individual issues) will allow the development of more nuanced prediction/classification systems. Taken together, if such models can be explained and integrated into a decision support system for suitable tasks in legal practice, experts will be more likely to perceive them as adding value.
+
+# 6 Conclusion
+
+Our results show that our deconfounded LJP models are consistently better aligned with expert rationales than a baseline optimized for the target label only, and in many cases can even achieve better prediction performance. However, the improvement is small and the paragraphs focused on by all our models are still quite different from what an expert has annotated as relevant, as indicated by generally low precision@Oracle scores $(< 50\%)$ . Still, our quantitative results show that expert-informed deconfounding LJP works in principle and can potentially go a long way to train more robust and trustworthy neural LJP models, as well as derive more useful legal insight from them.
+
+# Limitations
+
+We present a case study in deconfounding legal judgment prediction on the ECtHR, and all results are to be understood as relative to the ECtHR, its jurisprudence, the used datasets, and the formal tasks. The distracting attributes we identify include
+
+confounding effects of the court's document production, where the decision may be known before the decision text (including the fact section) is finalized. A replication of this study in other LJP settings is of course warranted before general applicability can be claimed. Our analysis of task B has further revealed that redundant vocabulary distribution can challenge the system's ability to point out individual 'smoking gun' distracting tokens. This aspect is particularly complex in light of differing legal systems and their respective cultures and patterns of drafting texts that may form the basis of predictive or, more generally, assistive systems. Morphologically rich languages, where distracting signal may be spread across multiple tokens, may make this challenge more difficult and require stem- or lemma-based processing as part of the method.
+
+Our deconfounding method is work-intensive and assumes the identifiability of distracting information in text and metadata by an expert. Legal expert agreement about what parts of decisions are relevant remains underexplored, and the division of genuine versus spurious language may also vary in between multiple experts. While we are convinced that further research on effective deconfounding of legal NLP systems is needed if these systems are to become robust and trustworthy, the time-intensive nature of collaboratively developing and qualitatively evaluating such models with legal experts poses a considerable resource challenge.
+
+A technical difficulty in working with legal documents is their length, and the use of packet-based hierarchical models constrains the maximum distance across which tokens can directly attend to one another. The impact of this limitation on model performance in various types of tasks is the subject of ongoing exploratory work (e.g., Dai et al. 2022).
+
+# Ethics Statement
+
+The research presented here works exclusively with publicly available datasets of ECtHR decisions, which are based on HUDOC*, the public database of the Court. While these decisions are not anonymized and contain the real names of individuals involved, our work does not engage with the data in a way that we consider harmful beyond this availability.
+
+Our models are designed to be used with pretrained language models and hence inherit any bi
+
+ases they may contain. This entails an obligation to screen incorporated models and to test any developed system with regard to its performance across groups of cases (e.g. Chalkidis et al. 2022b), and to remedy any disparities before deploying it as a prediction and inference tool. Our experiments are targeted at controlling for legally irrelevant distractors in the input, which is in line with this responsibility.
+
+The task of legal judgment prediction raises ethical concerns, both general as well as specific to the European Court of Human Rights. (Fikfak, 2021) emphasizes focal issues with regard to the court considering the use predictive technology to tackle its caseload, including system bias and the challenges of designing the interaction between judges and predictive systems. The latter is of course especially sensitive given experiences made with recidivism risk prediction (Collins 2018) and possible disparate effects of how judges interact with scores (Albright 2019). Our research group is committed to research on LJP as a means to derive insight from legal decision data towards increasing accountability, fairness, and transparency in the use of technology in legal systems. The premise of this work is that the behavior of legal outcome prediction systems is to be scrutinized with great care. This paper does not advocate for the practical use of such systems, but rather empirically explores difficulties that arise in their development and recommends a closer connection between technical research and legal expertise (see Sec. 5.4).
+
+All models of this project were developed and trained on Google Colab. Our models adapted pretrained language models and we did not engage in any training of such large models from scratch. We did not track computation hours.
+
+# Acknowledgments
+
+We are grateful to Jaromir Savelka for the ability to use the Gloss annotation tool and for providing feedback on the draft. We also thank the anonymous reviewers for valuable comments.
+
+# References
+
+Alex Albright. 2019. If you give a judge a risk score: evidence from kentucky bail decisions. Harvard John M. Olin Fellow's Discussion Paper, 85:16.
+Nikolaos Aletras, Dimitrios Tsarapatsanis, Daniel Preoticiuc-Pietro, and Vasileios Lampos. 2016. Predicting judicial decisions of the european court of
+
+human rights: A natural language processing perspective. PeerJ Computer Science, 2:e93.
+Sebastian Bach, Alexander Binder, Gregoire Montavon, Frederick Klauschen, Klaus-Robert Müller, and Wojciech Samek. 2015. On pixel-wise explanations for non-linear classifier decisions by layer-wise relevance propagation. *PloS one*, 10(7):e0130140.
+Jasmijn Bastings and Katja Filippova. 2020. The elephant in the interpretability room: Why use attention as explanation when we have saliency methods? In Proceedings of the Third BlackboxNLP Workshop on Analyzing and Interpreting Neural Networks for NLP, pages 149-155.
+Emily M. Bender and Alexander Koller. 2020. Climbing towards NLU: On meaning, form, and understanding in the age of data. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5185-5198, Online. Association for Computational Linguistics.
+Rohan Bhambhoria, Samuel Dahan, and Xiaodan Zhu. 2021. Investigating the state-of-the-art performance and explainability of legal judgment prediction. In Canadian Conference on AI.
+L Karl Branting. 2013. Reasoning with rules and precedents: a computational model of legal analysis. Springer Science & Business Media.
+L Karl Branting, Craig Pfeifer, Bradford Brown, Lisa Ferro, John Aberdeen, Brandy Weiss, Mark Pfaff, and Bill Liao. 2021. Scalable and explainable legal prediction. Artificial Intelligence and Law, 29(2):213-238.
+Stefanie Brüninghaus and Kevin D Ashley. 2005. Generating legal arguments and predictions from case texts. In Proceedings of the 10th international conference on Artificial intelligence and law, pages 65-74.
+Ilias Chalkidis, Ion Androutsopoulos, and Nikolaos Aletras. 2019. Neural legal judgment prediction in English. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4317-4323, Florence, Italy. Association for Computational Linguistics.
+Ilias Chalkidis, Manos Fergadiotis, Prodromos Malakasiotis, Nikolaos Aletras, and Ion Androutsopoulos. 2020. Legal-bert: The muppets straight out of law school. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 2898-2904.
+Ilias Chalkidis, Manos Fergadiotis, Dimitrios Tsarapat-sanis, Nikolaos Aletras, Ion Androutsopoulos, and Prodromos Malakasiotis. 2021. Paragraph-level rationale extraction through regularization: A case study on european court of human rights cases. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 226-241.
+
+Ilias Chalkidis, Abhik Jana, Dirk Hartung, Michael Bommarito, Ion Androutsopoulos, Daniel Katz, and Nikolaos Aletras. 2022a. LexGLUE: A benchmark dataset for legal language understanding in English. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 4310-4330, Dublin, Ireland. Association for Computational Linguistics.
+Ilias Chalkidis, Tommaso Pasini, Sheng Zhang, Letizia Tomada, Sebastian Schwemer, and Anders Søgaard. 2022b. FairLex: A multilingual benchmark for evaluating fairness in legal text processing. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 4389-4406, Dublin, Ireland. Association for Computational Linguistics.
+Kenneth Church and Patrick Hanks. 1990. Word association norms, mutual information, and lexicography. Computational linguistics, 16(1):22-29.
+Erin Collins. 2018. Punishing risk. *Geo. LJ*, 107:57.
+Xiang Dai, Ilias Chalkidis, Sune Darkner, and Desmond Elliott. 2022. Revisiting transformer-based models for long document classification. arXiv preprint arXiv:2204.06683.
+Marina Danilevsky, Kun Qian, Ranit Aharonov, Yannis Katsis, Ban Kawas, and Prithviraj Sen. 2020. A survey of the state of explainable AI for natural language processing. In Proceedings of the 1st Conference of the Asia-Pacific Chapter of the Association for Computational Linguistics and the 10th International Joint Conference on Natural Language Processing, pages 447-459, Suzhou, China. Association for Computational Linguistics.
+Ayse B Dincer, Joseph D Janizek, and Su-In Lee. 2020. Adversarial deconfounding autoencoder for learning robust gene expression embeddings. Bioinformatics, 36(Supplement_2):i573-i582.
+Veronika Fikfak. 2021. What future for human rights? decision-making by algorithm. Decision-making by algorithm (September 3, 2021). Strasbourg Observers, 19.
+Yaroslav Ganin and Victor Lempitsky. 2015. Unsupervised domain adaptation by backpropagation. In International conference on machine learning, pages 1180-1189. PMLR.
+Yaroslav Ganin, Evgeniya Ustinova, Hana Ajakan, Pascal Germain, Hugo Larochelle, François Lavi-olette, Mario Marchand, and Victor Lempitsky. 2016. Domain-adversarial training of neural networks. The journal of machine learning research, 17(1):2096-2030.
+Robert Geirhos, Jorn-Henrik Jacobsen, Claudio Michaelis, Richard Zemel, Wieland Brendel, Matthias Bethge, and Felix A Wichmann. 2020. Shortcut learning in deep neural networks. Nature Machine Intelligence, 2(11):665-673.
+
+Reza Ghaeini, Xiaoli Fern, and Prasad Tadepalli. 2018. Interpreting recurrent and attention-based neural models: a case study on natural language inference. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 4952-4957.
+Ian Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. 2014. Generative adversarial nets. Advances in neural information processing systems, 27.
+Matthias Grabmair. 2017. Predicting trade secret case outcomes using argument schemes and learned quantitative value effect tradeoffs. In Proceedings of the 16th edition of the International Conference on Artificial Intelligence and Law, pages 89-98.
+Laurence R Helfer and Erik Voeten. 2020. Walking back human rights in europe? European Journal of International Law, 31(3):797-827.
+Sahil Jayaram and Emily Allaway. 2021. Human rationales as attribution priors for explainable stance detection. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 5540-5554.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
+Jaesong Lee, Joong-Hwi Shin, and Jun-Seok Kim. 2017. Interactive visualization and manipulation of attention-based neural machine translation. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 121-126.
+Jiwei Li, Xinlei Chen, Eduard Hovy, and Dan Jurafsky. 2016. Visualizing and understanding neural models in nlp. In Proceedings of the 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 681-691.
+Zhiyuan Liu, Cunchao Tu, and Maosong Sun. 2019. Legal cause prediction with inner descriptions and outer hierarchies. In *China National Conference on Chinese Computational Linguistics*, pages 573-586. Springer.
+Luyao Ma, Yating Zhang, Tianyi Wang, Xiaozhong Liu, Wei Ye, Changlong Sun, and Shikun Zhang. 2021. Legal judgment prediction with multi-stage case representation learning in the real court setting. In Proceedings of the 44th International ACM SIGIR Conference on Research and Development in Information Retrieval, pages 993-1002.
+Mikael Rask Madsen, Pola Cebulak, and Micha Wiebusch. 2018. Backlash against international
+
+courts: explaining the forms and patterns of resistance to international courts. International Journal of Law in Context, 14(2):197-220.
+Tom McCoy, Ellie Pavlick, and Tal Linzen. 2019. Right for the wrong reasons: Diagnosing syntactic heuristics in natural language inference. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3428-3448, Florence, Italy. Association for Computational Linguistics.
+Masha Medvedeva, Ahmet Üstün, Xiao Xu, Michel Vols, and Martijn Wieling. 2021. Automatic judgement forecasting for pending applications of the European court of human rights. In *ASAIL/LegalAIIA@ICAIL*.
+Masha Medvedeva, Michel Vols, and Martijn Wieling. 2020. Using machine learning to predict decisions of the european court of human rights. Artificial Intelligence and Law, 28(2):237-266.
+Masha Medvedeva, Martijn Wieling, and Michel Vols. 2022. Rethinking the field of automatic prediction of court decisions. Artificial Intelligence and Law, pages 1-18.
+Reid Pryzant, Kelly Shen, Dan Jurafsky, and Stefan Wagner. 2018. Deconfounded lexicon induction for interpretable social science. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 1615-1625, New Orleans, Louisiana. Association for Computational Linguistics.
+Marco Tulio Ribeiro, Sameer Singh, and Carlos Guestrin. 2016. "why should i trust you?" explaining the predictions of any classifier. In Proceedings of the 22nd ACM SIGKDD international conference on knowledge discovery and data mining, pages 1135-1144.
+Margaret E Roberts, Brandon M Stewart, and Richard A Nielsen. 2020. Adjusting for confounding with text matching. American Journal of Political Science, 64(4):887-903.
+Tal Schuster, Darsh Shah, Yun Jie Serene Yeo, Daniel Roberto Filizzola Ortiz, Enrico Santus, and Regina Barzilay. 2019. Towards debiasing fact verification models. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3419-3425.
+Sofia Serrano and Noah A Smith. 2019. Is attention interpretable? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 2931-2951.
+Mehmet Fatih Sert, Engin Yildirim, and İrfan Haşlak. 2021. Using artificial intelligence to predict decisions of the turkish constitutional court. *Social Science Computer Review*, page 08944393211010398.
+
+Nitish Srivastava, Geoffrey Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. 2014. Dropout: a simple way to prevent neural networks from overfitting. The journal of machine learning research, 15(1):1929-1958.
+
+Mukund Sundararajan, Ankur Taly, and Qiqi Yan. 2017. Axiomatic attribution for deep networks. In International conference on machine learning, pages 3319-3328. PMLR.
+
+Nuo Xu, Pinghui Wang, Long Chen, Li Pan, Xiaoyan Wang, and Junzhou Zhao. 2020. Distinguish confusing law articles for legal judgment prediction. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 3086-3095, Online. Association for Computational Linguistics.
+
+Zichao Yang, Diyi Yang, Chris Dyer, Xiaodong He, Alex Smola, and Eduard Hovy. 2016. Hierarchical attention networks for document classification. In Proceedings of the 2016 conference of the North American chapter of the association for computational linguistics: human language technologies, pages 1480-1489.
+
+Matthew D Zeiler and Rob Fergus. 2014. Visualizing and understanding convolutional networks. In European conference on computer vision, pages 818-833. Springer.
+
+Haoxi Zhong, Zhipeng Guo, Cunchao Tu, Chaojun Xiao, Zhiyuan Liu, and Maosong Sun. 2018. Legal judgment prediction via topological learning. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 3540-3549, Brussels, Belgium. Association for Computational Linguistics.
+
+# A Dataset Statistics
+
+Table 5 demonstrates the artefacts from corpus construction and admissibility-related confounding information in the training set of Task J. Figure 3 and 4 display the distribution of text length and the respondent state in the Task J train set. Figure 5 and 6 show the statistics of text length and respondent state in the Task B train set.
+
+# B LexGlue Dataset Characteristics
+
+Table 4 describes the conditional probability of a violation finding by the court given the allegation of a particular article as well as the probability of a violation finding regarding a particular article even though it was not alleged.
+
+# C Rational annotation Process for Task J
+
+We sampled 50 cases (25 each) from the validation and test split. In each split, we sample two cases for each of the ten violated articles, one containing the token 'represented' and one without, along with five inadmissible cases. While the article information is available in the task J dataset, we do not use it as it was introduced as a binary violation classification task.
+
+The rationale annotation process was done using the GLOSS annotation tool. The third author of this paper, who is an ECtHR expert, read the case fact statements and highlighted paragraphs which she considered indicative of an eventual finding of a violation for any convention article by the court. Despite our sampling involving randomness, the expert was already familiar with a considerable portion of the decisions. Given this, we abstained from producing a human expert outcome prediction baseline.
+
+# D Case Sampling for Qualitative Evaluation
+
+For the qualitative evaluation of Task A|B, we sample 40 cases (20 each) from validation and test split. In each split, we sample two cases for each of the ten allegedly violated articles, one with a finding of a convention violation and with a non-violation finding.
+
+# E Decision Tree Performance
+
+Figure 2 shows the performance of our decision tree model across iterations for different tasks. After each iteration, we remove the informative to
+
+kens from previous iterations. In case of task J, we notice a steep fall after iteration 5. Tasks A and B exhibit less dramatic falloff of macro-averaged F1, owing to the different nature of the tasks as article-specific violations. Performance on Task A|B even shows small increases, albeit with a low absolute score. The large standard deviations bands computed across all articles show considerable variation.
+
+# F Spurious Vocabulary identified by Expert
+
+Following is the spurious vocabulary we obtained with respect to each task.
+
+- Task J: represented, national, mr, summarised, practising, lawyer, agent, paragraph
+- Task B: hearing, born, adjourned, detained, noted, hearing, alleged, investigation, place, question, members
+- Task A: stated, could, also, one, arrested, detained, hearing, investigation, hearing, within, due, second, hearing, certain
+- Task AI B: february, published, november, march, religious, investigation, first, service, letter, carried, would, one, submitted, head, march, damage, group, provided, seen
+
+The words were chosen as relevant or irrelevant by using the daily vocabulary of a human rights lawyer working at the ECtHR as a reference. A word was considered legally relevant if, taken individually, it could be introduced into legal reasoning. For instance, the word "religious" was spurious because taken individually it says nothing about the content of a norm. One may talk about religious freedom, but the legally relevant word there is freedom. Article 9 mentions religion, but restrictions related to religion may also be present under Article 8, 3, 2, 5, etc. Under the same Article 9 for instance, the court decides whether there has been a violation depending on criteria such as tolerance, pluralism, etc. It is those criteria that are relevant whereas "religion" is not by itself relevant as a part of the legal reasoning.
+
+# G LMI Calculation
+
+We calculate LMI for each pair of token $t$ and label $y$ as follows:
+
+$$
+L M I (\mathrm {t}, \mathrm {y}) = p (\mathrm {t}, \mathrm {y}) \times P M I (\mathrm {t}, \mathrm {y}) \tag {4}
+$$
+
+$$
+p (t, y) = \frac {\operatorname {c o u n t} (t , y)}{| D |} \tag {5}
+$$
+
+$$
+P M I (\mathbf {t}, \mathbf {y}) = \log \frac {p (\mathbf {t} \mid \mathbf {y})}{p (\mathbf {t})} \tag {6}
+$$
+
+where $\text{count}(t, y)$ denotes the co-occurrence of $t$ and label $y$ , and $|D|$ is the number of unique words in the training set.
+
+In the case of binary classification (task J) and one-vs-one multi-label classification (task A|B), we calculate the LMI score for a token as the absolute difference between LMI scores for both positive and negative labels, as both the labels represent a particular class. In one-vs-rest (tasks A, B), we simply take the difference between LMI scores for both positive and negative labels (rather than absolute difference) as the negative label does not specifically represent a particular class. Finally, we calculate the z-score statistic of the effective LMI score for each token to identify significant tokens.
+
+# H Model configuration & Training
+
+Spurious token identification: We train a series of decision trees of depth 3 to assemble lists of predictive tokens for expert filtering. The feature vector consists of whitespace-tokenized unigrams reduced by the LMI filtering explained above. For task J, this means training trees that predict the binary violation label. For task A and B we employ a one-vs-rest classification to produce one decision tree series per article. For task AlB we provided the task B labels (allegedly violated articles) in one-vs-one fashion per article, with positive instances being facts where that particular article was deemed violated, and negatives where that particular article was merely alleged but not deemed violated.
+
+LJP models: Our models compute BERT-based word embeddings of size 768. Our word level attention context vector size is 300. The sentence level GRU encoder dimension is 200, thus giving a bidirectional embedding of size 400, and a sentence level attention vector dimension of 200. The final dense classifier for all tasks has 100 hidden units. The output dimension is 1 for task J and 10 for the other tasks (i.e. one per convention article). For task AlB, we concatenate a multi-hot 10-element feature vector containing the task B labels to the output of the feature extractor before it is passed to the classifier. All discriminators (country, length, and vocabulary) are built as analogous classifiers with a hidden dimension of 100 and output layer
+
+dimensions as required by each of them. We use mini batches size of 8 in case of Task J and 16 for all other tasks. The model is optimized end-to-end using Adam (Kingma and Ba, 2015). The dropout rate (Srivastava et al., 2014) in all layers is 0.1. We determine the best learning rate using a grid search on the development set and use early stopping based on the development set F1 score.
+
+# I Visualization of IG score
+
+Figure 7 exhibits screenshot excerpts of a sample case text provided to the legal expert for qualitative evaluation. The yellow background highlight was not in the original visualization and has been supplied here as a reference. We add it here as an example of focus patterns shifting incurred by our deconfounding method.
+
+
+
+
+
+
+Figure 2: Macro-F1-Performance of Decision Trees across different iterations with removal of informative feature nodes in successive iterations. For Task A,B, AlB, standard deviation bars represent variability in F1-score across the 10 articles.
+
+
+
+| Article | % of cases alleged | % of cases alleged and violated | % of cases alleged but not violated | conditional probability of violation given allegation | % of cases not alleged but violated |
| 10 | 4.9 | 3.1 | 1.8 | 63.27 | 0.13 |
| 11 | 1.8 | 1.2 | 0.6 | 66.67 | 0.02 |
| 14 | 4.93 | 1.51 | 3.42 | 30.63 | 0.06 |
| 2 | 6.92 | 5.48 | 1.44 | 79.13 | 0.13 |
| 3 | 19.33 | 14.5 | 4.83 | 75.0 | 0.49 |
| 5 | 18.03 | 14.68 | 3.36 | 81.39 | 0.52 |
| 6 | 60.41 | 51.64 | 8.77 | 85.49 | 0.62 |
| 8 | 11.73 | 7.66 | 4.08 | 65.25 | 0.23 |
| 9 | 0.9 | 0.44 | 0.46 | 49.38 | 0.01 |
| P1-1 | 17.31 | 15.02 | 2.29 | 86.78 | 0.77 |
+
+Table 4: Statistics of LexGlue Train Dataset (Total of 9000 Cases) (Chalkidis et al., 2022a)
+
+ | violation | non-violation |
| number of cases | 3551 | 3549 |
| avg. number of sentences per case | 55 | 35 |
| number of inadmissible cases | 0 | 2608 |
| avg. first paragraph number appeared in the text | 6.1 | 1.8 |
| percentage of cases containing the word ‘represented’ | 0.17 | 0.68 |
+
+Table 5: Statistics of violation (label 1) and non-violation (label 0) cases in the training set of Task J. Some inadmissible cases are so short that no paragraph numbers appear. In such situations we count the paragraph number as 0.
+
+
+Figure 3: Text length distribution in the training set of Task J
+
+
+Figure 4: Country distribution in the training set of Task J
+
+
+Figure 5: Text length distribution for each violated article in the training set of Task B
+
+
+Figure 6: Country distribution in training set of Task B. For the display effect, only countries accounting for more than $1\%$ of the total cases are displayed.
+
+(a) gradAll
+(b) paraRem
+Figure 7: Example visualizations of different IG scores derived from the (a) gradAll and (b) paraRem model, respectively. The gradAll model focuses contiguously and densely on the expert-annotated indicative sentence 'A defendant to committal proceedings ... proving guilt lay on the person seeking committal' (yellow background highlighted); while the paraRem model fails to focus the latter half the indicative sentence.
+
+committal proceedings , which had applied to the proceedings before the county court ( see paragraph41 below ) , such proceedings concerned a [UNK] criminal charge [UNK] for the purpose of article 6 of the convention and the defendant therefore benefit ##ed from the right to legal assistance set out inarticle 6 § 3 (c ) . a defendant to committal proceedings was not obliged to give evidence and enjoyed a right against self [UNK] incrimination and ,referring to article 6 § 2 , the burden of proving guilt lay on the person seeking committal him the applicant [UNK] s case , cose #s ] observed that thesematters had not been drawn to the attention of the judge . he continued : [UNK] 11 . un ##ut ##or #ed and un ##assi #ste #d as the judge was , matterswent wrong from the beginning . the judge noted , at the outset , that mr hammer ##to #n was acting in person . he made no comment about it whatever .
\ No newline at end of file
diff --git a/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/images.zip b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..b33e45b1878e6360bba28196ed8feae4d9fdaa21
--- /dev/null
+++ b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:25cda20fdb1b7aa4c49481d31031f002791e934611a44db7d820c1af99356343
+size 573727
diff --git a/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/layout.json b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d90575680b923980a68ca0c7569e6d571488b701
--- /dev/null
+++ b/deconfoundinglegaljudgmentpredictionforeuropeancourtofhumanrightscasestowardsbetteralignmentwithexperts/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0d9d666436c1ed38b1c6da042f482f2a1dd091c2445c79405fa2bff346b73ed9
+size 429978
diff --git a/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_content_list.json b/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..a89c05f8cf25cbd8c806d2ffe9da78a811a696bd
--- /dev/null
+++ b/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:02f65c0e4bd1f0ebde37358154951c4ae22491d4d73eb45b08cbed799fa4d4d4
+size 114577
diff --git a/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_model.json b/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..7837733767b8027df1eb3ebb3dcb14a4e28ec692
--- /dev/null
+++ b/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:45d179595d8195ea693a49059df0d57183586ef850f39120a3efb124399ba1b1
+size 139863
diff --git a/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_origin.pdf b/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..6f1a814a47c2f803a858fa2ea146fc504b98e3af
--- /dev/null
+++ b/detectinglabelerrorsbyusingpretrainedlanguagemodels/6a586241-5a85-4d3a-9a9f-6eb4fc2015c3_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4a0700744d3307a24901dcf13e9a965ca5c38caec1ac7fc44a1a56f15058cfa2
+size 758874
diff --git a/detectinglabelerrorsbyusingpretrainedlanguagemodels/full.md b/detectinglabelerrorsbyusingpretrainedlanguagemodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..6a60d17d69c0b690d2fcff964f8cb66f8ccb73f9
--- /dev/null
+++ b/detectinglabelerrorsbyusingpretrainedlanguagemodels/full.md
@@ -0,0 +1,452 @@
+# Detecting Label Errors by using Pre-Trained Language Models
+
+Derek Chong*
+Stanford University
+derekch@stanford.edu
+
+Jenny Hong*
+Stanford University
+jennyhong@cs.stanford.edu
+
+Christopher D. Manning
+Stanford University
+manning@cs.stanford.edu
+
+# Abstract
+
+We show that large pre-trained language models are inherently highly capable of identifying label errors in natural language datasets: simply examining out-of-sample data points in descending order of finetuned task loss significantly outperforms more complex error-detection mechanisms proposed in previous work. To this end, we contribute a novel method for introducing realistic, human-originated label noise into existing crowdsourced datasets such as SNLI and TweetNLP. We show that this noise has similar properties to real, hand-verified label errors, and is harder to detect than existing synthetic noise, creating challenges for model robustness. We argue that human-originated noise is a better standard for evaluation than synthetic noise. Finally, we use crowdsourced verification to evaluate the detection of real errors on IMDB, Amazon Reviews, and Recon, and confirm that pre-trained models perform at a $9 - 36\%$ higher absolute Area Under the Precision-Recall Curve than existing models.
+
+# 1 Introduction
+
+Improving model performance in the presence of label errors comprises an area of active research (Song et al., 2022). However, existing methods focus on label errors in training data. Although seldom acknowledged, evaluation label errors are at least as pernicious as training label errors: pervasive errors in commonly used NLP benchmarks have been found to destabilize model performance (Malik and Bhardwaj, 2011; Northcutt et al., 2021b). Such findings suggest that improving training methods does not preclude the need for improving the underlying data. We propose a simple method for using large, pre-trained language models
+
+
+Figure 1: Precision-recall curves for label error detection: Large language models detect label errors with high precision, and far more effectively than a baseline word vector-based neural classifier. Overlaying a state-of-the-art model-agnostic error detection method, Confident Learning, results in little to no improvement (TweetNLP-5; §7).
+
+(LLMs) to directly identify label errors for the purposes of correcting or removing them.
+
+The majority of work in identifying label errors, and in data-centric artificial intelligence (DCAI) more broadly, focuses on image and healthcare data (DCAI Workshop, 2021). However, the success of the foundation model (FM) paradigm in applying pre-trained language models to a variety of NLP tasks (Bommasani et al., 2021; Reiss et al., 2020) suggests that FMs may be a powerful tool for detecting and correcting label errors in language datasets. Pre-training has been shown to imbue models with properties such as resistance to label errors, class imbalance (Karthik et al., 2021), out-of-distribution detection (Hendrycks et al., 2018), and confidence calibration (Desai and Durrett, 2020), while conferring ro
+
+| Dataset | Text | Label | Sentiment |
| IMDB | It is really unfortunate that a movie so well produced turns out to be such a disappointment. I thought this was full of (silly) cliches. It had all sorts of differences that it tried to tie together (not a bad thing in itself) but the result is at best awkward, but in fact ridiculous–too many clashes that wouldn’t really happen. Then the end of the movie–the last 10 minutes–ruined all the rest. At first I thought Xavier was OK but with retrospect I think he was pretty bad. And that’s all really too bad, because technically it was really good, and the soundtrack was great too. So the form was good, but the content pretty horrible. | Positive | Negative |
| IMDB | The ending made my heart jump up into my throat. I proceeded to leave the movie theater a little jittery. After all, it was nearly midnight. The movie was better than I expected. I don’t know why it didn’t last very long in the theaters or make as much money as anticipated. Definitely would recommend. | Negative | Positive |
| Amazon | The new design only has a thin layer of cellulose sponge material. It will not last as long. Already showing signs of wearing out. The picture does not represent the item received. | Neutral | Negative |
+
+Table 1: Organic label errors from sentiment datasets IMDB and Amazon, shown with the original dataset label. Each example was hypothesized by our model to be erroneous, and later verified by crowd workers.
+
+bustness, generalization, and natural language understanding capabilities (Wang et al., 2018; Petroni et al., 2019). Our primary contribution is to show that simply verifying items in order of their out-of-sample loss on a foundation model improves precision by an absolute $15 - 28\%$ and Area Under the Precision-Recall Curve (AUPR) by an absolute $9 - 36\%$ .
+
+Many methods for label error detection rely on artificially introduced label errors as ground truth for evaluating their methods. Northcutt et al. (2021a) develop a state-of-the-art model for identifying label errors, Confident Learning (CL), and use the better approach of crowdsourced human evaluations to determine the ground truth of label errors. We model our experiments on real data after their verification protocol, replicating this on real errors in IMDB (Maas et al., 2011), Amazon Reviews (McAuley et al., 2015), and Recon (Hong et al., 2021), with adaptations to mitigate annotator fraud (Kennedy et al., 2020).
+
+In the process of assessing our results, we contribute a novel technique and protocol for introducing realistic, human-originated label noise into existing crowdsourced datasets, and apply it to two such datasets, TweetNLP (Gimpel et al., 2010) and SNLI (Bowman et al., 2015). We demonstrate that our technique better approximates organic (real, naturally occurring) label errors than existing methods. We provide evidence that this realism is essential to properly assessing model performance: even
+
+models that are robust to standard synthetic.
+noising approaches show limited robustness to
+human-originated noise.1
+
+# 2 Related Work
+
+Learning with Noisy Labels (LNL) focuses on the model-training stage. Noise-robust approaches examine model enhancements such as the design of loss functions (Joulin et al., 2016; Amid et al., 2019; Liu and Guo, 2020; Ma et al., 2020), regularization (Azadi et al., 2015; Zhou and Chen, 2021), reweighting (Bar et al., 2021; Kumar and Amid, 2021), hard negative mining and contrastive learning (Zhang and Stratos, 2021). Noise-cleansing approaches aim to segregate clean data from noisy data in training, e.g. bagging and boosting (Wheway, 2000; Sluban et al., 2014), $k$ -nearest neighbors (Delany et al., 2012), outlier detection (Gamberger et al., 2000; Thongkam et al., 2008), bootstrapping (Reed et al., 2014), and neural networks supervised directly on detecting an error, when such data exist (Jiang et al., 2018).
+
+LNL methods have in most cases been evaluated using artificially-generated label noise. A typical evaluation of an LNL method uses a standard benchmark dataset, and programmatically corrupts training labels via one of three main noisings schemes (Frenay and Verleysen, 2014; Algan and Ulusoy, 2020). Uni
+
+form noise is most commonly used but unrealistic; deep neural networks have been found to perform well even when noised labels outnumber original labels at a ratio of 100 to 1 (Rolnick et al., 2017). Class-dependent noise randomly permutes labels based on a confusion matrix. However, research on annotator disagreement suggests that label errors tend to result from feature-based, not class-based ambiguity (Hendrycks et al., 2018). Training models to generate realistic feature-based or instance-dependent noise has recently emerged as an area of active research (Chen et al., 2021b; Xu et al., 2021; Dawson and Polikar, 2021). However, Algan and Ulusoy (2020) report that feature-dependent noise may bias benchmark performance toward similar models to the ones used to generate this noise.
+
+The noising schemes above each fail in some way to simulate organic, naturally occurring label errors, which are estimated to occur in common benchmarks at $1 - 5\%$ of labels (Redman, 1998; Muller and Markert, 2019; Northcutt et al., 2021b; Kreutzer et al., 2022) or even as much as $20\%$ (Hovy et al., 2014; Abedjan et al., 2016). For organic errors, CL (Northcutt et al., 2021a) predicts errors in IMDB, Amazon Reviews, and other datasets by estimating a joint distribution between noisy and uncorrupted labels; Reiss et al. (2020) pioneers using BERT for error detection on ConLL-2003 via a classifier trained over a frozen BERT embeddings layer.
+
+# 3 Methods
+
+Motivation. Empirical evidence on image data suggests that models exhibit high loss on label errors in training data relative to the underlying features (Huang et al., 2019; Kim et al., 2021; Hong et al., 2021; Chen et al., 2021a). Hendrycks and Gimpel (2017) show that predicted probabilities of (non pre-trained) neural networks can identify out-of-distribution examples. We consider the framing that label errors are one type of out-of-distribution data. Indeed, CL (Northcutt et al., 2021a) uses normalized predicted probabilities, also from non pre-trained models, to directly identify label errors. Foundation models are highly performant; we hypothesize that a low likelihood label is likely to be an error.
+
+
+Figure 2: Loss exhibits a strong log-linear relationship with error detection precision at a fixed threshold, across a broad range of models and hyperparameters ( $r^2$ : 0.94; TweetNLP-5, §7).
+
+Foundation models. The success of Reiss et al. (2020)'s approach in using frozen BERT embeddings motivates directly applying the foundation model paradigm: we use a large language model that was first pre-trained on a task-agnostic dataset, then fine-tune the model for a given task.
+
+We address classification tasks: given a model's score $f_{i,c}$ for each item $i$ and class $c$ , its predicted probability is the softmax-normalized score $p(c \mid x_i)$ . Because each item belongs to exactly one class, the contribution of item $i$ to the loss is the negative log probability of the score for the assigned class $y_i$ :
+
+$$
+L _ {i} = \sum_ {i} - \log p \left(y _ {i} \mid x _ {i}\right).
+$$
+
+We fine-tune such a model for the training split of each data set. To identify label errors on a validation or test set, we hypothesize items from the dataset as a label error in order of the item's loss on that out-of-distribution set.
+
+We propose two main methods. Foundation Model Loss (FML) uses a single foundation model, fine-tuned on the corresponding task (e.g., sentiment classification, POS tagging), to hypothesize items in order of the model-predicted loss. We augment FML using task-adaptive pre-training (TAPT; Gururan-gan et al., 2020), which is further pre-training on in-domain data, using only text on the pretraining objective without using any labels for fine-tuning on the cross-entropy objective.
+
+Foundation Model Ensembling (FME) combines multiple foundation models on the same
+
+
+Figure 3: Assessing model robustness against a range of noising methods on TweetNLP, with methods ordered by hypothesized realism. Solid orange lines report task performance on noisy test data, reflecting observations in practice; dashed blue lines report task performance on underlying clean test data, reflecting models' actual performance. Models may be robust to uniform and class-dependent noise, where the true performance remains high even with increasing levels of noise. However, they are not necessarily robust to human-originated noise, where the true test performance decreases with increasing noise.
+
+task. We hypothesize that ensembling may be disproportionately effective at detecting label errors, as training noise induces models to learn random spurious correlations (Watson et al., 2022). Rather than using a validation set to choose the single model with the lowest loss on the task, FME uses the top three models trained in a hyperparameter sweep, and differing in both hyperparameters and random initialization, as fully described in Appendix D. FME creates a synthetic probability distribution over the task outputs by averaging the probabilities predicted using each individual model. FME then hypothesizes items in order of loss over the synthetic distribution.
+
+# 4 Generating Realistic Label Noise
+
+To better evaluate label noise detection performance, we prepare a set of benchmark datasets populated with controllable, highly realistic, human-originated label noise.
+
+Sources of human error. We observe that datasets often undergo multiple annotation passes: crowdsourced labels typically aggregate several annotators' inputs (Hovy et al., 2014; Wei et al., 2022), and subsets of data may receive more extensive validation (Bowman et al., 2015), gold labels by trained experts (Plank et al., 2014), or correction passes (Reiss et al., 2020). We hypothesize that differences between such annotations may be usefully repurposed as a source of realistic, human-originated label noise, as disagreements between annotators is known to reflect systematic ambiguity and human error (Plank et al., 2014; Zhang et al.,
+
+2017), and differs from the type of noise studied using existing synthetic methods.
+
+We construct three noising methods which may be applied in many of the above scenarios. For any dataset which includes two levels of label quality, the dissenting label method replaces final labels with disagreeing labels at random, simulating imperfect quality control. Datasets which provide individual annotator identifiers may apply the dissenting worker approach: select one annotator at random, apply all of their labels which disagree with final labels, and repeat until reaching the target noise rate. This simulates gaps in annotator training, which introduce systematic idiosyncrasies. Finally the crowd majority method applies to any dataset in which individual annotations can be aggregated to produce a label other than the final label: the former label simulates challenging, systematic errors in the latter.
+
+Noising and robustness. We assess the effect of these noising methods using TweetNLP (Gimpel et al., 2010), a corpus of 26,435 tokens from 1,827 American English tweets collected from Twitter used to train part-of-speech (POS) tagging. TweetNLP includes gold labels annotated by 17 experts, but later received a separate crowdsourced assessment, aggregated by majority vote (Hovy et al., 2014). We noise TweetNLP to eight levels from 0-20% separately for each method, fine-tune DeBERTA-v3-base (He et al., 2021) on each noising, and evaluate models on both noisy and clean test sets. Results from noisy test sets represent model performance as measurable in
+
+
+Figure 4: Distributions of losses of label errors on TweetNLP at $5\%$ noising. Uniform and class-based noise produce high and distinctive losses; human-originated noise is widely distributed, and has greater overlap with the distribution of clean data points; §6.
+
+practice; real datasets contend with noise in evaluation data. Clean test set results represent true model performance. Fig. 3 reports the results of this evaluation.
+
+For uniform and class-dependent noise, true performance remains high even for high noise levels (per Rolnick et al., 2017). But crucially, this robustness does not extend to human-originated noise: human label errors are correlated to input text, and so contain systematic erroneous features, which models may learn in training. On more challenging nois-ing methods, although measured performance appears to increase, true performance actually linearly decreases with noise. Fig. 4 explores this further via the distributions of model losses for each nois-ing method: loss induced by human-originated noise overlaps significantly with clean items, whereas loss from uniform and class-based nois-ing is distinctively higher.
+
+Noise detection benchmarks. We standardize a set of benchmarks from existing datasets for use in our main experiments. TweetNLP-5 and SNLI-5 aim to simulate typical data noise conditions: we apply dissenting worker and dissenting label noising to a $5\%$ level (see Appendix A for details). SNLI is a corpus of 570,152 sentence pairs, in which the task is to label each pair with entailment, contradiction, or semantic independence; we use the $10\%$ subset which includes five crowdsourced annotations per item, as collected by
+
+Bowman et al. (2015) during data validation.
+
+We construct TweetNLP-M to investigate robustness to systematic error introduced by the crowdsourcing process. We apply crowd majority noising, comparing noisy majority-vote aggregated labels by Hovy et al. (2014) to clean expert labels, which serve as a measure of true performance. Accordingly, we retain all disagreements, or $20.46\%$ of the dataset. We also report results on Recon, a legal classification dataset of 1,279 documents in which Hong et al. (2021) found label errors to destabilize model evaluation; as above, we compare non-expert and expert annotator labels.
+
+# 5 Validation on Real Label Errors
+
+In addition to human-originated noise datasets, we evaluate error detection performance on organic errors in two benchmark datasets, following Northcutt et al. (2021a)'s protocol.
+
+Datasets. The IMDB Large Movie Review Dataset is a collection of movie reviews for binary sentiment classification (Maas et al., 2011), and is split into train and test sets of 25,000 items each. Amazon Reviews is a collection of reviews and 5-point star ratings from Amazon customers (McAuley et al., 2015). We used the version released by Northcutt et al. (2021a), which includes the following modifications: It uses 1-star, 3-star, 5-star reviews with net positive helpful upvotes as a ternary sentiment task, resulting in a dataset of 9,996,437 reviews. For tractability we use a train split of a random sample of 2.5 million items, and a test split of 25,000 items.
+
+Baseline protocol. Workers are presented with review text and asked to determine whether overall sentiment is positive, negative, neutral, or off-topic. Each review is independently presented to five workers. An example is considered a "Non-Error" if at least three workers agree the original label is correct. Otherwise, we consider the label to be correctly identified as an error. We further categorize label errors as "Correctable" if at least three workers agree on the same replacement label, or "Non-Agreement" if no majority exists.
+
+New adaptations. While conducting initial experiments, we found that the Northcutt et al.
+
+| IMDB
+Old Protocol | New Protocol |
| C | NA | NE | Total |
| Correctable | 105 | 44 | 24 | 173 |
| Non-Agreement | 75 | 252 | 225 | 552 |
| Non-Error | 3 | 62 | 520 | 585 |
| Total | 183 | 358 | 769 | 1310 |
+
+| Amazon | New Protocol |
| Old Protocol | C | NA | NE | Total |
| Correctable | 142 | 43 | 117 | 302 |
| Non-Agreement | 140 | 79 | 211 | 430 |
| Non-Error | 75 | 31 | 162 | 268 |
| Total | 357 | 153 | 490 | 1000 |
+
+Table 2: Re-evaluation of baselines: The number of Correctable, Non-Agreement, and Non-Error assessments produced by the CL Mechanical Turk evaluation protocol and the new protocol, on the same set of items. The new protocol substantially reduces annotator non-agreement; §5.
+
+(2021a) MTurk protocol resulted in a significant amount of annotator fraud. Some workers spent unreasonably short amounts of time on the text, and frequently disagreed with both expert and peer annotators, reflecting increasingly common issues in crowdsourced annotations (Kennedy et al., 2020). Appendix C describes four extra conditions we added to improve the Northcutt et al. (2021a) protocol.
+
+In order to establish an accurate baseline, we re-evaluate the label errors hypothesized by CL (Northcutt et al., 2021a). On the new protocol, Fleiss' $\kappa$ inter-annotator agreement increases from 0.131 to 0.464 for IMDB, and 0.014 to 0.556 for Amazon, and Table 2 shows that Non-Agreement decreases by $35\%$ in IMDB and $65\%$ in Amazon. This suggests a substantial decrease in low-quality annotations.
+
+# 6 Experiments
+
+Label noise realism. Section 4 defined the human-originated noising protocol used to generate TweetNLP-5, TweetNLP-M, and SNLI-5. Section 5 specified a protocol for identifying organic label errors present in IMDB and Amazon. We assess the realism of synthetic noise methods by comparing loss distributions against models trained with organic noise (for real label errors, we refer to items verified as Correctable via MTurk). We quantify the de
+
+
+Figure 5: Distributions of losses of hypothesized label errors that MTurk workers verified for IMDB. As with Fig. 4, uniform and class-based methods do not approximate real, worker-identified errors, and losses of real label errors have greater overlap with the distribution of clean data; §6.
+
+greet to which noising induces erroneous learning by measuring the Wasserstein distances between noisy and clean loss distributions.
+
+Overall LLM performance. We assess broad error detection capabilities by evaluating 13 commonly-used LLMs on TweetNLP-5. We measure performance against loss, model size, and GLUE score (a proxy for general model capability; Wang et al., 2018). Appendix D provides implementation details. This experiment's results inform model selection: we use DeBERTA-v3-base for all further experiments.
+
+Main experiment. Using our realistic nois-. ing benchmarks, and the MTurk baselines and verification protocol, we can now assess the performance of each label error detection method. We evaluate Foundation Model Loss (FML) and Foundation Model Ensembling (FME).
+
+As a baseline, we evaluate Confident Learning (CL; Northcutt et al., 2021a). CL is not a standalone method; it augments existing models. Given an underlying model's predicted scores for each class and the true proportion of each class, CL forms a reweighting matrix, called the confident joint. To form a label error prediction score, CL reweights the model's scores by the confident joint. CL hypothesizes items in order of this resulting score.
+
+CL uses FastText (Joulin et al., 2017) for IMDB and Amazon, but includes no implemen
+
+ | Area Under Precision-Recall Curve | Precision, Recall @ Error%3 | Recall @ 2 · Error% |
| I | Am. | R | T-5 | T-M | S-5 | I | Am. | R | T-5 | T-M | S-5 | R | T-5 | T-M | S-5 |
| H&G | - | - | - | 0.30 | 0.41 | 0.20 | - | - | - | 0.31 | 0.44 | 0.22 | - | 0.54 | 0.63 | 0.34 |
| CL | 0.24 | 0.31 | 0.25 | 0.30 | 0.41 | 0.17 | 0.41 | 0.51 | 0.31 | 0.36 | 0.44 | 0.18 | 0.46 | 0.47 | 0.63 | 0.32 |
| FML | 0.58 | 0.39 | 0.37 | 0.66 | 0.48 | 0.54 | 0.68 | 0.64 | 0.46 | 0.65 | 0.47 | 0.45 | 0.62 | 0.88 | 0.64 | 0.66 |
| FME | 0.60 | 0.40 | 0.38 | 0.68 | 0.48 | 0.61 | 0.69 | 0.66 | 0.38 | 0.66 | 0.48 | 0.46 | 0.69 | 0.88 | 0.65 | 0.68 |
| FME+CL | 0.20 | 0.17 | 0.37 | 0.68 | 0.48 | 0.62 | - | - | 0.38 | 0.69 | 0.48 | 0.47 | 0.69 | 0.89 | 0.66 | 0.68 |
+
+Table 3: Main experiment: Evaluating label error detection methods using datasets containing highly-realistic label errors (IMDB, Amazon Reviews, Recon, TweetNLP-5, TweetNLP-M, SNLI-5). Foundation model-based methods significantly outperform baselines on every dataset, as shown by an overall performance metric (AUPR). In practice, estimating the number of dataset errors and checking this many items quickly catches up to $69\%$ of errors, at the same accuracy $(\mathrm{P,R@Err\%})$ . For improved coverage, checking twice this number of items catches up to $89\%$ of errors $(\mathrm{R@2-Err\%})$ .
+
+tations for POS tagging or NLI. As a result, for TweetNLP and SNLI, we apply CL to the H&G baseline (Hendrycks and Gimpel, 2017), a two-layer neural classifier over word vectors pre-trained on a corpus of 56 million tweets (Owoputi et al., 2013). For all datasets, we also assess applying CL to foundation models $(\mathbf{FME} + \mathbf{CL})$
+
+For each dataset, we run 25 hyperparameter sweeps which each fine-tune a model for the given task (e.g., POS tagging) using noisy data, and select the model with the best validation set task performance. We report label error detection performance (not task performance). Area Under the Precision-Recall Curve (AUPR) provides an overall performance score (Saito and Rehmsmeier, 2015; Hendrycks and Gimpel, 2017). We also report metrics representing performance on competing data cleaning priorities: efficiency requires high precision on a small number of items, whereas coverage requires high recall on a larger number of items. Appendix E.1 describes the Truncated AUPR used for IMDB and Amazon, which are too costly to fully crowd verify.
+
+End-to-end noising. We finally isolate the effects of noise and label error correction for validation and test splits. For each dataset, we prepare three versions of the validation and test splits, respectively: a clean version assumed to contain zero errors, a noisy version, with label
+
+noise deliberately introduced, and a corrected version generated from noisy splits using our main error detection method (ranking errors with FME and correcting the top $\mathrm{Err\%}$ data points). We train 40 hyperparameter sweeps, with performance cross-evaluated on all prepared data splits.
+
+We report three different metrics. We report each model's accuracy on the clean test split as the true accuracy. Following the norms of Fig. 3, we report the measurable accuracy as the accuracy of the model selected using performance on the noisy or corrected validation split on the corresponding test split. Finally, we report the rank of the model as the rank of the model's performance on clean test data. The best performing model among all sweeps has rank 1, and the worst has rank 40. This metric emphasizes that different validation sets select different models.
+
+We perform this exercise using IMDB and Amazon noised to $5\%$ (I-5, A-5), and TweetNLP-5 and TweetNLP-M.
+
+# 7 Results
+
+Label noise realism. Human-originated noise appears to closely approximate real label noise. Figs. 4 and 5 show that the losses of both real and human-originated label errors are lower and more widely-distributed than existing noising methods. Their Wasserstein distances to the distribution of clean data are significantly lower than existing noising methods, suggesting comparable erroneous learning (Appendix B).
+
+Overall LLM performance. We discover a strong log-linear relationship between error
+
+
+Figure 6: Precision-recall curves for label error detection on Amazon by method. FML+CL and FME+CL produce fewer items and do not extend to a recall past 0.21. Applying CL to FM changes little compared to using FM alone.
+
+detection performance and loss, which holds across many model families and configurations $(r^2$ : 0.94, Fig. 2). We also find relationships between error detection performance and general model capability, in terms of GLUE score $(r^2$ : 0.79) and model size (Fig. 10). Fig. 7 illustrates key findings using models' receiver operating characteristic (ROC) curves. Ensembling confers significantly more gains in error detection performance higher than gains on underlying task performance, across a broad range of models and hyperparameters; Appendix E.3 explores ensembling in greater detail.
+
+Main experiment. Table 3 shows that Foundation Model Ensembling significantly improves AUPR from the CL and H&G baselines on all datasets, with an absolute difference of 0.36 on IMDB, 0.09 on Amazon, and a difference of 0.07-0.44 on synthetic data.
+
+Fig. 1 shows that applying CL to FME has minimal effect on performance at every level of recall; most numbers are identical across the FME and $\mathrm{FME + CL}$ rows of Table 3. In fact, CL does not necessarily improve upon the H&G baseline across datasets, with CL performance sometimes dipping below H&G by 0.01-0.03.
+
+While loss naturally ranks all data points, CL only hypothesizes a fixed number of potential errors: Appendix E.2 shows the raw counts of items at fixed thresholds, per the original CL study. At the CL threshold, we outperform CL by an absolute $15 - 28\%$ . At the $\mathrm{CL + FME}$ threshold, predicted items are almost exactly
+
+
+Figure 7: ROC curves for error detection performance on TweetNLP-5: LLM loss is highly effective for detecting label errors, and performance is highly correlated with general language understanding (GLUE, $r^2$ : 0.79).
+
+the same, with Jaccard similarities of 0.59-0.99. By contrast, ensembling improves performance over FML by a greater amount on almost every measure, and introduces no such constraint.
+
+End-to-end noising. Cleaning validation data selects better models. Noise in validation splits reduces performance by encouraging the selection of models with lower true performance. Noise in test splits significantly reduces measureable (noisy test) performance, as expressed by the difference between measureable and true performance. In general, correcting label errors improves task performance: even when the reported task performance worsens, the reported performance is closer to the true performance of the model, measured using clean training and validation data.
+
+# 8 Discussion
+
+Rapid data "health check". Sorting evaluation data by each item's loss is an easy way to quickly highlight label errors. Using this simple technique with a foundation model appears to generally identify over half of all label errors through human re-evaluation of a single-digit percentage of all data (Table 3). We expect this technique to work across deep learning domains, due to its simplicity and the extensive use of training loss in LNL research (Song et al., 2022). Given estimates for typical rates of label errors and the gain observed in the end-to-end experiment, our technique may enable a $1 - 2\%$ increase in reportable test accuracy
+
+| Eval. | Test Perf. | I-5 | A-5 | T-5 | T-M |
| Noisy | Measurable | 90.1 | 88.3 | 89.3 | 89.3 |
| True | 94.2 | 91.0 | 92.8 | 82.0 |
| Rank | 10 | 1 | 3 | 10 |
| Corr. | Measurable | 95.1 | 90.7 | 92.9 | 88.5 |
| True | 95.1 | 90.8 | 93.0 | 82.0 |
| Rank | 4 | 5 | 2 | 8 |
| Clean | True | 95.8 | 91.0 | 93.8 | 82.1 |
+
+Table 4: End-to-end effects of label noise on task performance, as evaluated on noisy, corrected, and clean validation and test data splits. True accuracy is measured on clean test sets, and measurable accuracy on noisy or corrected test sets. Rank is a relative measure of true accuracy; lower numerical ranks have higher accuracy. Corrections which improve or reduce performance metrics are highlighted in green or red, respectively. Metrics are evaluated on models trained on noisy data.
+
+across many datasets, in addition to the gains from improving model selection.
+
+Pre-training and robustness. We demonstrate that despite established findings on artificial noising (Hendrycks et al., 2018), pretraining confers limited robustness to realistic human noise. The majority of label errors are systematic in nature (Snow et al., 2008; Plank et al., 2014; Samuel et al., 2022), and crowdsourced labels form, to an extent, a different distribution from reality, as approximated by expert labels (Hendrycks et al., 2020). When trained on crowdsourced or other data containing systematic errors, FMs quickly drift towards this incorrect distribution.
+
+Applying AI to data-centric AI. Data-centric AI aims to improve AI through labeling, curating, and augmenting the underlying data. We find that AI itself can be applied towards improving data quality, as part of a human-in-the-loop (HITL) iteration, which contributes an additional positive feedback loop between data quality and AI performance.
+
+New challenges in LNL. Standard noisings methods are unrealistic and no longer challenging for state-of-the-art language models (Algan and Ulusoy, 2020); recent LNL analyses study conditions where up to $80\%$ of labels are noised (Song et al., 2022). Our findings reinforce the need to reassess LNL methods in the context of more realistic noise (Zhu et al., 2022).
+
+Our human-originated noising method produces realistic label errors, and can be applied to any crowdsourced dataset which includes raw annotation data. As such datasets emerge across deep learning domains (Wei et al., 2022), we hope this method may inspire challenging and realistic new LNL performance benchmarks. Our method also enables detailed exploration of the properties of human noise, which may support work on open LNL problems such as improving feature-based noising techniques, and estimating dataset noise (Bäuerle et al., 2022; Northcutt et al., 2021b).
+
+End-to-end noising. The study of model performance on noise in validation and test data is essential: noise in other splits can affect reported model performance as much as noise in training data. Clean and noisy performance on evaluation data provide useful insight into models' overall performance.
+
+# 9 Conclusions and Future Work
+
+Pre-trained models effectively identify label errors on real NLP datasets, definitively outperforming existing methods on the same benchmarks by an absolute $9 - 36\%$ in AUPR.
+
+Human-originated noising techniques may present a solution to the clear limitations of current LNL noising schemes: they are highly realistic and yet controllable for experimental purposes. We invite further exploration of this family of label noising techniques. We believe human-originated noising enables future advancements across multiple areas of LNL, supporting new tasks and metrics in areas such as the cost of human reannotation, estimation of dataset error, and mitigation of bias.
+
+Finally, we advocate for LNL to move towards an end-to-end approach of evaluating with label noise, which takes into account noise within validation and test splits, and more accurately models the conditions of data in practice.
+
+# Limitations
+
+Partial metrics. Determining the true recall of a label error detection method on a real datasets is generally infeasible due to its high cost; this requires a complete re-evaluation so as to identify every label error within the dataset. While some datasets exist in which this has been undertaken, such as Hovy et al.
+
+(2014) for TweetNLP, for most datasets containing organic label errors, we can only assess precision directly.
+
+To mitigate this, we can estimate recall by estimating total dataset error counts using sampling techniques. As a result of this limitation, we prefer AUPR over AUROC (Area Under the Receiving Operating Curve) as our overall assessment metric: estimates of AUPR are scaled by a fixed ratio, and therefore comparable between models on the same dataset, whereas AUROC is nonlinear with respect to the estimate.
+
+Requires multiple annotations per label. Human-originated noising methods are only applicable to datasets which include at least two human annotations per label. While it is becoming increasingly common to release individual-level annotator data, this is not an ubiquitous practice.
+
+Cleaning benchmark data. In our analysis of model performance gains derived from applying our methods to cleaning evaluation data, we find that cleaning validation splits enables the selection of models with better test performance. Such a method may be useful in a large number of applications.
+
+However, we caution against using this method to clean data intended for use in comparing performance across model families and variants: the cleaning process may bias any such benchmarks toward the models most similar to the model used to clean the data. While our method improves the performance of a given model on a task, and correcting label errors always improves the validity of test data, these improvements is unlikely to improve the performance of all models by the same amount.
+
+This limitation is shared with other existing model-based scoring methods such as BERTScore (Zhang* et al., 2020).
+
+# Acknowledgements
+
+We would like to thank Google.org for credits for use of the Google Cloud Platform. We are also grateful to our anonymous reviewers, members of the Stanford NLP Group, and Bryan H. Chong for their constructive feedback, as well as the many researchers who made data publicly available to enable our present work.
+
+# References
+
+Ziawasch Abedjan, Xu Chu, Dong Deng, Raul Castro Fernandez, Ihab F Ilyas, Mourad Ouzzani, Paolo Papotti, Michael Stonebraker, and Nan Tang. 2016. Detecting data errors: Where are we and what needs to be done? Proceedings of the VLDB Endowment, 9(12):993-1004.
+Jon Agley, Yunyu Xiao, Rachael Nolan, and Lilian Golzarri-Arroyo. 2021. Quality control questions on Amazon's Mechanical Turk (MTurk): A randomized trial of impact on the USAUDIT, PHQ-9, and GAD-7. Behavior research methods, pages 1-13.
+Görkem Algan and Ilkay Ulusoy. 2020. Label noise types and their effects on deep learning. arXiv:2003.10471.
+Ehsan Amid, Manfred KK Warmuth, Rohan Anil, and Tomer Koren. 2019. Robust bi-tempered logistic loss based on Bregman divergences. Advances in Neural Information Processing Systems, 32.
+Samaneh Azadi, Jiashi Feng, Stefanie Jegelka, and Trevor Darrell. 2015. Auxiliary image regularization for deep CNNs with noisy labels. arXiv preprint arXiv:1511.07069.
+Noga Bar, Tomer Koren, and Raja Giryes. 2021. Multiplicative reweighting for robust neural network optimization. arXiv preprint arXiv:2102.12192.
+Alex Bäuerle, Ángel Alexander Cabrera, Fred Hohman, Megan Maher, David Koski, Xavier Suau, Titus Barik, and Dominik Moritz. 2022. Symphony: Composing interactive interfaces for machine learning. In CHI Conference on Human Factors in Computing Systems, pages 1-14.
+Rishi Bommasani, Drew A Hudson, Ehsan Adeli, Russ Altman, Simran Arora, Sydney von Arx, Michael S Bernstein, Jeannette Bohg, Antoine Bosselut, Emma Brunskill, et al. 2021. On the opportunities and risks of foundation models. arXiv preprint arXiv:2108.07258.
+Samuel R. Bowman, Gabor Angeli, Christopher Potts, and Christopher D. Manning. 2015. A large annotated corpus for learning natural language inference. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 632-642, Lisbon, Portugal. Association for Computational Linguistics.
+Jiefeng Chen, Frederick Liu, Besim Avci, Xi Wu, Yingyu Liang, and Somesh Jha. 2021a. Detecting errors and estimating accuracy on unlabeled data with self-training ensembles. Advances in Neural Information Processing Systems, 34.
+Pengfei Chen, Junjie Ye, Guangyong Chen, Jingwei Zhao, and Pheng-Ann Heng. 2021b. Beyond
+
+class-conditional assumption: A primary attempt to combat instance-dependent label noise. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 11442-11450.
+Glenn Dawson and Robi Polikar. 2021. Rethinking noisy label models: Labeler-dependent noise with adversarial awareness. arXiv preprint arXiv:2105.14083.
+DCAI Workshop. 2021. NeurIPS data-centric AI workshop. NeurIPS 2021 Data-Centric AI Workshop.
+Sarah Jane Delany, Nicola Segata, and Brian Mac Namee. 2012. Profiling instances in noise reduction. Knowledge-Based Systems, 31:28-40.
+Sean A Dennis, Brian M Goodson, and Christopher A Pearson. 2020. Online worker fraud and evolving threats to the integrity of MTurk data: A discussion of virtual private servers and the limitations of IP-based screening procedures. *Behavioral Research in Accounting*, 32(1):119-134.
+Shrey Desai and Greg Durrett. 2020. Calibration of pre-trained transformers. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 295-302, Online. Association for Computational Linguistics.
+Benoit Frenay and Michel Verleysen. 2014. Classification in the presence of label noise: A survey. IEEE Transactions on Neural Networks and Learning Systems, 25(5):845-869.
+Dragan Gamberger, Nada Lavrac, and Saso Dzeroski. 2000. Noise detection and elimination in data preprocessing: experiments in medical domains. Applied artificial intelligence, 14(2):205-223.
+Kevin Gimpel, Nathan Schneider, Brendan O'Connor, Dipanjan Das, Daniel Mills, Jacob Eisenstein, Michael Heilman, Dani Yogatama, Jeffrey Flanigan, and Noah A Smith. 2010. Part-of-speech tagging for Twitter: Annotation, features, and experiments. Technical report, Carnegie-Mellon Univ Pittsburgh Pa School of Computer Science.
+Suchin Gururangan, Ana Marasovic, Swabha Swayamdipta, Kyle Lo, Iz Beltagy, Doug Downey, and Noah A. Smith. 2020. Don't stop pretraining: Adapt language models to domains and tasks. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8342-8360, Online. Association for Computational Linguistics.
+Pengcheng He, Jianfeng Gao, and Weizhu Chen. 2021. DeBERTaV3: Improving DeBERTa using Electra-style pre-training with gradient-disentangled embedding sharing. arXiv:2111.09543.
+
+Dan Hendrycks and Kevin Gimpel. 2017. A baseline for detecting misclassified and out-of-distribution examples in neural networks. Proceedings of International Conference on Learning Representations.
+Dan Hendrycks, Xiaoyuan Liu, Eric Wallace, Adam Dziedzic, Rishabh Krishnan, and Dawn Song. 2020. Pretrained transformers improve out-of-distribution robustness. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 2744-2751, Online. Association for Computational Linguistics.
+Dan Hendrycks, Mantas Mazeika, Duncan Wilson, and Kevin Gimpel. 2018. Using trusted data to train deep networks on labels corrupted by severe noise. Advances in neural information processing systems, 31.
+Jenny Hong, Derek Chong, and Christopher Manning. 2021. Learning from limited labels for long legal dialogue. In Proceedings of the Natural Legal Language Processing Workshop 2021, pages 190-204, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Dirk Hovy, Barbara Plank, and Anders Søgaard. 2014. Experiments with crowdsourced reannotation of a POS tagging data set. In Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 377-382, Baltimore, Maryland. Association for Computational Linguistics.
+Jinchi Huang, Lie Qu, Rongfei Jia, and Binqiang Zhao. 2019. O2u-net: A simple noisy label detection approach for deep neural networks. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 3326-3334.
+Lu Jiang, Zhengyuan Zhou, Thomas Leung, Li-Jia Li, and Li Fei-Fei. 2018. Mentornet: Learning data-driven curriculum for very deep neural networks on corrupted labels. In International Conference on Machine Learning, pages 2304-2313. PMLR.
+Yiding Jiang, Vaishnavh Nagarajan, Christina Baek, and J Zico Kolter. 2022. Assessing generalization of SGD via disagreement. In International Conference on Machine Learning.
+Armand Joulin, Edouard Grave, Piotr Bojanowski, and Tomas Mikolov. 2017. Bag of tricks for efficient text classification. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers, pages 427-431. Association for Computational Linguistics.
+Armand Joulin, Laurens van der Maaten, Allan Jabri, and Nicolas Vasilache. 2016. Learning visual features from large weakly supervised data. In European Conference on Computer Vision, pages 67-84. Springer.
+
+Shyamgopal Karthik, Jérôme Revaud, and Boris Chidlovskii. 2021. Learning from long-tailed data with noisy labels. arXiv:2108.11096.
+Ryan Kennedy, Scott Clifford, Tyler Burleigh, Philip D Waggoner, Ryan Jewell, and Nicholas JG Winter. 2020. The shape of and solutions to the MTurk quality crisis. Political Science Research and Methods, 8(4):614-629.
+Taehyeon Kim, Jongwoo Ko, JinHwan Choi, SeYoung Yun, et al. 2021. FINE samples for learning with noisy labels. Advances in Neural Information Processing Systems, 34.
+Julia Kreutzer, Isaac Caswell, Lisa Wang, Ahsan Wahab, Daan van Esch, Nasanbayar Ulzii-Orshikh, Allahsera Tapo, Nishant Subramani, Artem Sokolov, Claytone Sikasote, et al. 2022. Quality at a glance: An audit of web-crawled multilingual datasets. Transactions of the Association for Computational Linguistics, 10:50-72.
+Abhishek Kumar and Ehsan Amid. 2021. Constrained instance and class reweighting for robust learning under label noise. arXiv.
+Yang Liu and Hongyi Guo. 2020. Peer loss functions: Learning from noisy labels without knowing noise rates. In International Conference on Machine Learning, pages 6226-6236. PMLR.
+Xingjun Ma, Hanxun Huang, Yisen Wang, Simone Romano, Sarah Erfani, and James Bailey. 2020. Normalized loss functions for deep learning with noisy labels. In International Conference on Machine Learning, pages 6543-6553. PMLR.
+Andrew L. Maas, Raymond E. Daly, Peter T. Pham, Dan Huang, Andrew Y. Ng, and Christopher Potts. 2011. Learning word vectors for sentiment analysis. In Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies, pages 142-150, Portland, Oregon, USA. Association for Computational Linguistics.
+Hassan H Malik and Vikas S Bhardwaj. 2011. Automatic training data cleaning for text classification. In 2011 IEEE 11th international conference on data mining workshops, pages 442-449. IEEE.
+Julian McAuley, Christopher Targett, Qinfeng Shi, and Anton van den Hengel. 2015. Image-based recommendations on styles and substitutes. In SIGIR 2015, page 43-52, New York, NY, USA. Association for Computing Machinery.
+Alexandra M Mellis and Warren K Bickel. 2020. Mechanical Turk data collection in addiction research: Utility, concerns and best practices. Addiction, 115(10):1960-1968.
+
+Aaron Moss and Leib Litman. 2018. After the bot scare: Understanding what's been happening with data collection on MTurk and how to stop it. *CloudResearch*.
+Nicolas M. Müller and Karla Markert. 2019. Identifying mislabeled instances in classification datasets. In 2019 International Joint Conference on Neural Networks (IJCNN), pages 1-8. IEEE.
+Curtis Northcutt, Lu Jiang, and Isaac Chuang. 2021a. Confident learning: Estimating uncertainty in dataset labels. Journal of Artificial Intelligence Research, 70:1373-1411.
+Curtis G Northcutt, Anish Athalye, and Jonas Mueller. 2021b. Pervasive label errors in test sets destabilize machine learning benchmarks. arXiv:2103.14749.
+Olutobi Owoputi, Brendan O'Connor, Chris Dyer, Kevin Gimpel, Nathan Schneider, and Noah A. Smith. 2013. Improved part-of-speech tagging for online conversational text with word clusters. In Proceedings of the 2013 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 380-390, Atlanta, Georgia. Association for Computational Linguistics.
+Fabio Petroni, Tim Rocttäschel, Sebastian Riedel, Patrick Lewis, Anton Bakhtin, Yuxiang Wu, and Alexander Miller. 2019. Language models as knowledge bases? In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 2463-2473, Hong Kong, China. Association for Computational Linguistics.
+Barbara Plank, Dirk Hovy, and Anders Søgaard. 2014. Linguistically debatable or just plain wrong? In Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 507-511.
+Thomas C Redman. 1998. The impact of poor data quality on the typical enterprise. Communications of the ACM, 41(2):79-82.
+Scott Reed, Honglak Lee, Dragomir Anguelov, Christian Szegedy, Dumitru Erhan, and Andrew Rabinovich. 2014. Training deep neural networks on noisy labels with bootstrapping. arXiv preprint arXiv:1412.6596.
+Frederick Reiss, Hong Xu, Bryan Cutler, Karthik Muthuraman, and Zachary Eichenberger. 2020. Identifying incorrect labels in the CoNLL-2003 corpus. In Proceedings of the 24th conference on computational natural language learning, pages 215-226.
+
+David Rolnick, Andreas Veit, Serge Belongie, and Nir Shavit. 2017. Deep learning is robust to massive label noise. arXiv:1705.10694.
+Takaya Saito and Marc Rehmsmeier. 2015. The precision-recall plot is more informative than the ROC plot when evaluating binary classifiers on imbalanced datasets. *PloS one*, 10(3):e0118432.
+Jim Samuel, Gavin Rozzi, and Ratnakar Palle. 2022. The dark side of sentiment analysis: An exploratory review using lexicons, dictionaries, and a statistical monkey and chimp. Dictionaries, and a Statistical Monkey and Chimp. (January 6, 2022).
+Antonios Saravanos, Stavros Zervoudakis, Dongnanzi Zheng, Neil Stott, Bohdan Hawryluk, and Donatella Delfino. 2021. The hidden cost of using Amazon Mechanical Turk for research. In International Conference on Human-Computer Interaction, pages 147-164. Springer.
+Borut Sluban, Dragan Gamberger, and Nada Lavrač. 2014. Ensemble-based noise detection: noise ranking and visual performance evaluation. Data mining and knowledge discovery, 28(2):265-303.
+Rion Snow, Brendan O'Connor, Daniel Jurafsky, and Andrew Ng. 2008. Cheap and fast - but is it good? evaluating non-expert annotations for natural language tasks. In Proceedings of the 2008 Conference on Empirical Methods in Natural Language Processing, pages 254-263, Honolulu, Hawaii. Association for Computational Linguistics.
+Hwanjun Song, Minseok Kim, Dongmin Park, Yooju Shin, and Jae-Gil Lee. 2022. Learning from noisy labels with deep neural networks: A survey. IEEE Transactions on Neural Networks and Learning Systems.
+Jaree Thongkam, Guandong Xu, Yanchun Zhang, and Fuchun Huang. 2008. Support vector machine for outlier detection in breast cancer survivability prediction. In Asia-Pacific Web Conference, pages 99-109. Springer.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. 2018. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In Proceedings of the 2018 EMNLP Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pages 353-355, Brussels, Belgium. Association for Computational Linguistics.
+Matthew Watson, Bashar Awwad Shiekh Hasan, and Noura Al Moubayed. 2022. Agree to disagree: When deep learning models with identical architectures produce distinct explanations. In Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision, pages 875-884.
+
+Jiaheng Wei, Zhaowei Zhu, Hao Cheng, Tongliang Liu, Gang Niu, and Yang Liu. 2022. Learning with noisy labels revisited: A study using real-world human annotations. In International Conference on Learning Representations.
+Virginia Wheway. 2000. Using boosting to detect noisy data. In Pacific Rim International Conference on Artificial Intelligence, pages 123-130. Springer.
+Liang Xu, Jiacheng Liu, Xiang Pan, Xiaojing Lu, and Xiaofeng Hou. 2021. DataCLUE: A benchmark suite for data-centric NLP. arXiv:2111.08647.
+Jing Zhang, Victor S Sheng, Qianmu Li, Jian Wu, and Xindong Wu. 2017. Consensus algorithms for biased labeling in crowdsourcing. Information Sciences, 382:254-273.
+Tianyi Zhang*, Varsha Kishore*, Felix Wu*, Kilian Q. Weinberger, and Yoav Artzi. 2020. BERTScore: Evaluating text generation with BERT. In International Conference on Learning Representations.
+Wenzheng Zhang and Karl Stratos. 2021. Understanding hard negatives in noise contrastive estimation. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 1090-1101, Online. Association for Computational Linguistics.
+Wenxuan Zhou and Muhao Chen. 2021. Learning from noisy labels for entity-centric information extraction. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 5381-5392, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Dawei Zhu, Michael A Hedderich, Fangzhou Zhai, David Ifeoluwa Adelani, and Dietrich Klakow. 2022. Is BERT robust to label noise? A study on learning with noisy labels in text classification. arXiv:2204.09371.
+
+# A Noising Benchmarks
+
+This section specifies how noising protocols were applied to create each fixed crowdsourced dataset. Crowd labels for each dataset are available to download from the respective GitHub projects.
+
+# A.1 TweetNLP-5
+
+TweetNLP-5(%) is a fixed noisng of TweetNLP to a $5\%$ noise level in each split. Of the label errors, $80\%$ (i.e. $4\%$ of each split) are assigned using the dissenting worker method. The remaining $20\%$ (i.e. $1\%$ of each split) are assigned
+
+using the dissenting label method. Fig. 4 shows that both methods provide similar distributions of label errors. Although the dissenting worker method more realistically captures individual worker idiosyncrasies, the dissenting label method is actually slightly lower loss during training (i.e. harder for a model to distinguish from correct labels).
+
+# A.2 TweetNLP-M
+
+TweetNLP-M(ajority) directly uses the majority class labels collected by Hovy et al. (2014) on the Crowdflower platform, which have a $79.54\%$ agreement with the high-quality expert gold labels collected by Gimpel et al. (2010). Per the Hovy et al. (2014) protocol, in the rare case of ties, the tie is broken in favor of the label that matches the gold label, if applicable. Otherwise, a label is selected at random. The "-M" suffix distinguishes the Hovy et al. (2014) labels from the gold labels.
+
+# A.3 SNLI-5
+
+The Stanford Natural Language Inference dataset (SNLI) annotations do not include a worker identifier, meaning each item is attached to five crowdsourced labels, but there is no indication of which labels came from the same annotator across the dataset. As a result, we cannot apply the dissenting worker noisng method.
+
+SNLI-5 has exactly $5\%$ of its data noised in each split. Of the label errors, $80\%$ (i.e. $4\%$ of each split) are assigned using a method that represents systematic errors, to simulate of dissenting worker method: We use the minority label when there is a 3-2 split between the five labels. The remaining $20\%$ (i.e. $1\%$ of each split) are assigned using the dissenting label method, as in TweetNLP-5.
+
+# B Loss Distributions
+
+Section 4 examines dataset noisings primarily in terms of loss distributions on noised labels. To provide additional context, Fig. 8 provides an equivalent view for SNLI, and Fig. 9 shows combined distributions of both clean and noisy data points on TweetNLP.
+
+Table 5 reports the Wasserstein distances (or earth mover's distances) measured between the loss distributions of noisy and clean data points for models trained on TweetNLP and IMDB, as
+
+
+Figure 8: Distributions of losses of label errors on SNLI at $5\%$ noising, which demonstrates similar performance characteristics to TweetNLP, as shown in Fig. 4.
+
+
+Figure 9: Combined distributions of losses of both noisy and clean data points, for TweetNLP with $5\%$ noising.
+
+described in Section 7. Human-originated label noise more closely resembles both clean data points and real label noise as its hypothesized realism increases.
+
+# C Mechanical Turk Protocol
+
+# C.1 Change Specifications
+
+We use Amazon Mechanical Turk to validate real label errors from IMDB (Maas et al., 2011) and Amazon Reviews (McAuley et al., 2015). We begin with the Northcutt et al. (2021a) protocol, and add four additional conditions, so as to mitigate annotator fraud.
+
+First, we pre-qualify workers by requiring them to correctly answer a qualification test of four unambiguous questions (Hovy et al., 2014; Agley et al., 2021).
+
+Second, after the initial qualification, we con
+
+| Noising Method | TweetNLP | IMDB |
| Uniform Noise | 5.62 | 5.04 |
| Class-Based Noise | 5.23 | 4.91 |
| Dissenting Label | 4.02 | - |
| Dissenting Worker | 3.44 | - |
| Crowd Majority | 2.33 | - |
| Real Label Errors | - | 2.67 |
+
+Table 5: Wasserstein distances between loss distributions of noisy and clean data points: Human-originated noising exhibits comparable levels of erroneous learning to organic label errors.
+
+ | IMDB | Amazon |
| Original Protocol | 0.1314 | 0.0141 |
| New Protocol | 0.4643 | 0.5561 |
+
+Table 6: A comparison of inter-annotator agreement between the original and new MTurk protocol results using Fleiss' $\kappa$ . A score of 1.0 represents perfect agreement between workers, and 0.0 represents guessing at random. Annotations from the original protocol are substantially closer to random chance.
+
+tinue to monitor worker quality by introducing sentinel questions with known answers into the workers' regular tasks. We periodically remove workers who fail the tasks.
+
+Third, we set filter criteria to limit workers to the following Anglosphere countries: United States, Canada, United Kingdom, Ireland, Australia, and New Zealand (Moss and Litman, 2018), to improve the chances of finding annotators with sufficient cultural context to correctly interpret review text. Our filter criteria include the standard recommendations of requiring a $\geq 99\%$ positive task approval rate with $\geq 500$ tasks approved.
+
+Finally, we set a baseline target rate of US$10 per hour, calculated using word counts and average reading speed (primarily for ethical reasons; the effect of compensation and annotation quality is an area of active research; Saravanos et al., 2021).
+
+The new protocol's labels are produced using a final set of approximately 70 workers. Workers averaged at least 12 seconds on each task;
+
+half the time needed to read prompts at an average reading speed. The average time spent by a worker in the Northcutt et al. (2021a) protocol was 5 seconds. $^6$
+
+# C.2 Protocol Validation
+
+We hypothesize that the Non-Agreements in the original protocol represent not only ambiguous data points, but also noise in the original protocol resulting from low quality work. Tables 2 and 6 show that the new protocol improves the level of agreement between workers. As such, we confirm that the increased agreement between workers in the new protocol results from higher quality labels.
+
+Following the Northcutt et al. (2021a) protocol for expert review, we additionally select a total of 50 items from each of IMDB and Amazon for expert review. The experts are blinded to both the original labels and MTurk results and asked to label each item from scratch. They then reconciled results and came to a consensus for each item. The results are compared at the aggregate level of "Correctable," "Non-Agreement," and "Non-Error," as opposed to the individual sentiment level (Positive, Negative, Neutral, or Off-Topic). The expert agreement with one another was $79\%$ , so in $21\%$ of the items, the expert label was considered to be Non-Agreement and matched the MTurk workers only if the workers also produced Non-Agreement. Table 7 provides the result of this assessment.
+
+For the original protocol, $52\%$ of the items agreed with expert annotators, $31\%$ of the items were incorrectly labeled as Non-Agreement, $12\%$ of the items were incorrectly labeled as Correctables, and $5\%$ of the items were incorrectly labeled as Non-Errors. $8\%$ of items were disagreements between experts and crowd workers where neither side had a Non-Agreement. In other words, $8\%$ of all items were disagreements between Correctable and Non-Error.
+
+For the new protocol, $72\%$ of the items agreed with expert annotators, $4\%$ of the items were incorrectly labeled as Non-Agreement, $7\%$ of the items were incorrectly labeled as Correctable, and $17\%$ were incorrectly labeled as
+
+ | IMDB | Amazon | Total |
| Original Correct | 33 | 19 | 52 |
| New Correct | 41 | 31 | 72 |
| Both Correct | 28 | 14 | 42 |
+
+Table 7: A comparison of original and new MTurk protocol results against 100 expert-labeled data points.
+
+Non-Errors. $5\%$ of items were disagreements between experts and crowd workers where neither side had a Non-Agreement.
+
+# D Overall LLM Performance Experiments
+
+Due to the high costs associated with expert and crowdsourced validation, we use TweetNLP-5 as a development dataset for model selection.
+
+We selected the following models for exploration: XLNet (base, large), RoBERTa (base, large), BERT (small, base, large), DeBERTa (V3: xsmall, small, base, large, and V2: xlarge, xxlarge), GPT (assorted). We performed 25 hyperparameter sweeps with each model, selecting the top three runs for further analysis. In order to avoid model family-level bias in the choice of hyperparameters, we set a broad shared range for three hyperparameters: learning rate varying from $10^{-6}$ to $10^{-3}$ , the number of epochs from 2 to 8, and the batch size between 8, 16, 64, and 128. Training time and the final hyperparameters varied based on the model.
+
+We ultimately selected DeBERTA-v3-base as a compromise between performance and training speed. We used Google Cloud Platform for training infrastructure. Experiments were run using NVIDIA A100 GPUs, and runtime per training run was approximately 20 minutes for IMDB, Recon, and SNLI, 3 minutes for TweetNLP, and 4 hours for Amazon, when configured with a 2.5 million data point training split.
+
+# E Main Experiment
+
+# E.1 Metrics
+
+We calculate the Area Under the Precision-Recall Curve (AUPR) using the trapezoidal rule, given individual measurements of precision and recall at every possible threshold.
+
+
+Figure 10: Label noise detection performance by model size and family, evaluated on TweetNLP-5. GPT-based models exhibit similar scaling trends, despite intrinsic disadvantages on classification tasks (due to pure autoregressive pre-training).
+
+We report the Truncated AUPR on IMDB and Amazon. Because IMDB and Amazon are too expensive to fully crowd verify, we cannot calculate precision and recall at the 25,000th item for each method, for each dataset, as it would require every data point to be relabeled on MTurk. Instead, we use the CL framework of predicting a fixed number of items. For example, for IMDB, CL hypothesizes 1,310 out of the 25,000 items to be label errors. We can calculate the precision and recall for every threshold, up to the number hypothesized by Confident Learning. We can calculate the precision and recall of the 1st, 2nd, 3rd, ..., and 1,310th items.
+
+We know the exact recall for all synthetic datasets. For IMDB and Amazon, we use the estimate that $5\%$ of the data is erroneous, which is consistent with common understanding of the prevalence of label errors (Redman, 1998; Müller and Markert, 2019; Northcutt et al., 2021b; Kreutzer et al., 2022).
+
+All results reported on synthetic datasets reflect the average of individual scores from the three top-performing models from 25 hyperparameter sweeps. However, for cost-efficiency, results which require crowdsourced evaluation (such as IMDB and Amazon) are based on one run selected at random from a top three.
+
+# E.2 Confident Learning
+
+Northcutt et al. (2021b) reports results using raw counts, not the accuracy, precision, recall,
+
+| Dataset | Num. Errors Hypothesized | Correctable | Non-Agreement | Non-Error |
| CL | FML | FME | CL | FML | FME | CL | FML | FME |
| IMDB | 1310 | 183 | 323 | 328 | 358 | 573 | 581 | 769 | 414 | 401 |
| Amazon | 1000 | 357 | 508 | 517 | 148 | 131 | 143 | 495 | 361 | 340 |
| TweetNLP-M | 250 | 121 | 158 | 165 | - | - | - | 129 | 92 | 85 |
+
+Table 8: The number of each type of error accurately identified for each dataset by each noise detection method, keeping the number of errors hypothesized fixed for ease of comparison. (TweetNLP is expert reviewed and by construction does not have any Non-Agreement types.)
+
+| Dataset | Num. Errors Hypothesized | Correctable | Non-Agreement | Non-Error | Jaccard Similarity |
| FME | FME+CL | FME | FME+CL | FME | FME+CL |
| IMDB | 316 | 168 | 168 | 108 | 108 | 40 | 40 | 0.99 |
| Amazon | 381 | 226 | 204 | 65 | 56 | 90 | 121 | 0.60 |
| TweetNLP-M | 129 | 93 | 98 | - | - | 36 | 31 | 0.59 |
+
+Table 9: Examining the performance of overlaying Confident Learning on FME, comparing the number of errors hypothesized by $\mathrm{FME + CL}$ . We also report the Jaccard similarity between the two models.
+
+or any other metric. For ease of comparability, Table 8 reports the number of correctable, non-agreement, and non-error items identified by each method on each dataset. CL hypothesizes a fixed number of items, which is reported in the last column, and we assess a matching number of items from each method.
+
+When hypothesizing a fixed number of items, the foundation model approaches far outperform CL baselines. On IMDB, FME correctly identifies 909 label errors, a $28\%$ absolute improvement in accuracy. On Amazon, the FME approach correctly identifies 660 label errors, compared to the 505 identified by CL, a $15.5\%$ absolute improvement.
+
+Applying CL to FME results in a different model that hypothesizes a different number of items (fewer, in all cases). Table 9 shows the raw counts of correctable, non-agreement, and non-error items when each of our models hypothesizes items at this reduced threshold.
+
+Overlaying CL on foundation model loss appears to have little marginal utility. Table 9 also shows a high Jaccard similarity across all datasets, suggesting that applying CL on top of an FM changes little about the items hypothesized. On many datasets, FME and $\mathrm{FME + CL}$ perform almost identically in the number of items correctly hypothesized, slightly harming performance on Amazon Reviews, and slightly improving it on TweetNLP-5 (Table 10). FME+CL decreases the total number of hypothesized items compared to FME
+
+because of the threshold set by CL. We compare the FME and $\mathrm{FME + CL}$ approaches at the reduced number of hypothesized items in order to assess the impact of CL in the presence of pre-training.
+
+Not only is aggregate performance nearly identical, we see in Figs. 1 and 6 that FME and $\mathrm{FME + CL}$ perform similarly for the entire range of items hypothesized along the Precision-Recall curve. The primary difference is that FME can continue hypothesizing items even past $\mathrm{FME + CL}$ 's threshold.
+
+# E.3 Ensembling
+
+Results from Tables 3 and 10 show that assembling (FME) improves error detection performance over using a single model (FML) in almost every scenario tested, at a rate several times higher than gains to underlying task performance.
+
+We also observe a phenomenon of disproportionately high variance in model error detection performance: Table 10 quantifies the standard deviation of the former at three times the standard deviation of performance on the underlying task, and Fig. 2 shows this to be the case even when comparing models with a fixed loss. This finding persisted even when holding all hyperparameters and data constant, with only the random seed being changed.
+
+We hypothesize that label noise in training data induces models to learn spurious correlations, which cause models to make errors in a
+
+| Method | Task Accuracy | FM Error Detection Performance | Effects of CL Overlay |
| Noisy | Clean | Precision | Recall | F1 | Precision | Recall | F1 |
| Averaged | 0.88 ± 0.03 | 0.91 ± 0.03 | 0.50 ± 0.11 | 0.65 ± 0.03 | 0.56 ± 0.08 | 0.51 ± 0.11 | 0.67 ± 0.03 | 0.57 ± 0.07 |
| Ensembled | 0.89 ± 0.02 | 0.92 ± 0.03 | 0.56 ± 0.12 | 0.62 ± 0.03 | 0.58 ± 0.08 | 0.58 ± 0.11 | 0.65 ± 0.03 | 0.61 ± 0.07 |
| Difference | +1.14% | +1.24% | +12.52% | -4.31% | +4.66% | +13.89% | -2.98% | +6.03% |
+
+Table 10: Ensembling confers gains in error detection performance disproportionate to gains in underlying task performance, across a broad range of models and hyperparameters (on TweetNLP-5, results from top three models per sweep, as measured at the fixed threshold set by CL).
+
+structured manner (Watson et al., 2022; Jiang et al., 2022); this results in greater levels of model disagreement, with minimal impact on top-line performance. Ensembling may be disproportionately effective because it serves an added function of reducing variance caused by these low-quality features.
+
+# E.4 TAPT
+
+We perform Task-Assisted Pretraining (TAPT; Gururangan et al., 2020) using the original hyperparameters everywhere except for the optimizer, in which we use AdamW instead of Adam for DeBERTa. We run TAPT on the all splits of the corresponding data for all datasets except Amazon Reviews, where because of its size, we use TAPT on only 50,000 data points, or $0.5\%$ of the full dataset. After running TAPT, we then run 25 fine-tune sweeps.
\ No newline at end of file
diff --git a/detectinglabelerrorsbyusingpretrainedlanguagemodels/images.zip b/detectinglabelerrorsbyusingpretrainedlanguagemodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..65f31916e99e31817d5e55c358c0adc89178f182
--- /dev/null
+++ b/detectinglabelerrorsbyusingpretrainedlanguagemodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2f8006f72ff694ca190640c4d9e5b5e0c0dfeaf743a52e90a6b17583cacb7dbc
+size 725740
diff --git a/detectinglabelerrorsbyusingpretrainedlanguagemodels/layout.json b/detectinglabelerrorsbyusingpretrainedlanguagemodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..791d3885ea26b8aa108f0a696610889c466634c9
--- /dev/null
+++ b/detectinglabelerrorsbyusingpretrainedlanguagemodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ef563e06a0ef920ac4b509521481664ad933fc61faa27b40ff30155b4da766ba
+size 505330
diff --git a/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_content_list.json b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..2b7c5df52270ddf4c0626db09094e6b947270f17
--- /dev/null
+++ b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:98af5a774b9737ff911ae145aa72b18431b396a9d01b0d01d8755a9528de7311
+size 82443
diff --git a/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_model.json b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..434993b9b38a8d9ea5fc566fc22b95009cf9f5ca
--- /dev/null
+++ b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:853cea04b4e2a754066f4540da3325e93dd807c75274e0d4d155477ec879e281
+size 101317
diff --git a/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_origin.pdf b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..522e3d53a012dedaf8c2f82b190fec7b067697ef
--- /dev/null
+++ b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/8f34bcb5-3355-4574-97b3-f2b25a8107cd_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3aca1eb64c2d38eddf2882d317b452f79bad8b84358f1f038044c4426604609f
+size 555658
diff --git a/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/full.md b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..319d564c371ee02042b313cf0fa810ad004fe622
--- /dev/null
+++ b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/full.md
@@ -0,0 +1,346 @@
+# Dial2vec: Self-Guided Contrastive Learning of Unsupervised Dialogue Embeddings
+
+Che Liu, Rui Wang, Junfeng Jiang, Yongbin Li*, Fei Huang
+DAMO Academy, Alibaba Group
+
+{liuche.lc,wr224079,jiangunjfeng.jjf,shuide.lyb,f.huang}@alibaba-inc.com
+
+# Abstract
+
+In this paper, we introduce the task of learning unsupervised dialogue embeddings. Trivial approaches such as combining pre-trained word or sentence embeddings and encoding through pre-trained language models (PLMs) have been shown to be feasible for this task. However, these approaches typically ignore the conversational interactions between interlocutors, resulting in poor performance. To address this issue, we proposed a self-guided contrastive learning approach named dial2vec. Dial2vec considers a dialogue as an information exchange process. It captures the conversational interaction patterns between interlocutors and leverages them to guide the learning of the embeddings corresponding to each interlocutor. The dialogue embedding is obtained by an aggregation of the embeddings from all interlocutors. To verify our approach, we establish a comprehensive benchmark consisting of six widely-used dialogue datasets. We consider three evaluation tasks: domain categorization, semantic relatedness, and dialogue retrieval. Dial2vec achieves on average 8.7, 9.0, and 13.8 points absolute improvements in terms of purity, Spearman's correlation, and mean average precision (MAP) over the strongest baseline on the three tasks respectively. Further analysis shows that dial2vec obtains informative and discriminative embeddings for both interlocutors under the guidance of the conversational interactions and achieves the best performance when aggregating them through the interlocutor-level pooling strategy. All codes and data are publicly available at https://github.com/AlibabaResearch/DAMOConvAI/tree/main/dial2vec.
+
+# 1 Introduction
+
+Dialogue embedding, as a critical prerequisite of semantically understanding a dialogue, has been
+
+a central issue in dialogue-related research such as dialogue clustering (Shi et al., 2018; Lv et al., 2021), conversational sentiment analysis (Wang et al., 2020; Lv et al., 2021), context-dependent text-to-SQL (Hui et al., 2021; Wang et al., 2022), and dialogue summarization (Liu et al., 2019b; Liu and Chen, 2021). Trivial unsupervised approaches generally encode dialogues by combining their pretrained word or sentence embeddings (Pennington et al., 2014; Reimers and Gurevych, 2019) or using PLMs (Wu et al., 2020a; Bao et al., 2020; He et al., 2022a,b,c). However, such methods are not specifically designed for dialogues and thus fail to adequately capture the key conversational information. In this paper, we formally introduce the task of learning unsupervised dialogue embeddings, which aims to learn dialogue embeddings that can well reflect conversational semantics without any additional manual annotations.
+
+Previous studies have extensively demonstrated the importance of encoding token-level interactions for learning semantic textual embeddings. However, for dialogue embedding, encoding interlocutor-level interactions is also essential but is overlooked in trivial approaches. Figure 1 shows
+
+
+Figure 1: A dialogue from the SGD dataset.
+
+an example. We highlight the significant interaction patterns between the interlocutors with red
+
+color. As we can see, although these patterns only appear in three utterances, they highly represent the key conversational semantics (e.g., topics) and are more important than the other parts (e.g., greetings and chit-chats). We hold that capturing and leveraging them is one of the keys to learning high-quality unsupervised dialogue embeddings.
+
+In this work, we propose dial2vec, a self-guided contrastive learning approach to solve the proposed task. Dial2vec considers a dialogue as an information exchange process between the two interlocutors and learns embeddings for both interlocutors with the help of each other. Specifically, dial2vec firstly encodes a dialogue through a PLM and assigns each interlocutor a self-representation by masking the non-corresponding positions in the encoding outputs. Then it calculates a matching matrix via the token-level dot-product operation between the two self-representations, obtaining a cross-representation for each interlocutor. Finally, the two cross-representations are leveraged as guidance to help the two self-representations gradually learn the interlocutor-level interaction-aware information and eliminate the interaction-free information during the training procedure.
+
+To verify our model, we build a comprehensive benchmark comprising a total of 98,879 dialogues by introducing six widely-used dialogue datasets, including BiTOD (Lin et al., 2021), Doc2dial (Feng et al., 2020), MetalWOZ (Lee et al., 2019), MultiWOZ (Eric et al., 2019), Self-dialogue (Fainberg et al., 2018), and SGD (Rastogi et al., 2020). Each dataset consists of thousands of dialogues, where each dialogue is provided with a domain label (e.g., hotel booking and movie). We leverage these labels and design three evaluation tasks: domain categorization, semantic relatedness, and dialogue retrieval. We categorize them into intrinsic and extrinsic tasks according to their different focus.
+
+Experimental results on this benchmark show that dial2vec outperforms the baselines by a substantial margin. Compared with the strongest baseline, dial2vec achieves on average 8.7, 9.0, and 13.8 points absolute improvements in terms of purity, Spearman's correlation, and mean average precision (MAP) on the three tasks respectively. We also conduct experiments with the single interlocutor's embeddings, their aggregation strategies, and the overall dialogue embedding distributions to study how dial2vec achieves such advanced performance. The results demonstrate that dial2vec
+
+learns both informative and discriminative embeddings for the two interlocutors and achieves the best performance when combining them through the proposed interlocutor-level pooling aggregation strategy.
+
+# 2 Related Work
+
+# 2.1 Text Embedding
+
+Text embedding aims to encode a piece of text into a distributed vector that could represent its semantics. Early works (Bengio et al., 2003; Mikolov et al., 2013; Pennington et al., 2014) learn unsupervised word embeddings by making use of word-level co-occurrence information in the skip-gram or CBOW tasks. Recently, Devlin et al. (2018); Liu et al. (2019a); Yang et al. (2019); Raffel et al. (2020) pre-train deep transformer (Vaswani et al., 2017) with a series of pretext tasks, setting a new state-of-the-art across the GLUE benchmark (Wang et al., 2018) as well as exhibiting a strong potential in producing general text embeddings. Along this line, Gao et al. (2021); Yan et al. (2021); Liu et al. (2021); Chuang et al. (2022); Nishikawa et al. (2022); Zhou et al. (2022); Klein and Nabi (2022) fine-tune the PLMs with contrastive learning objectives, achieving remarkable improvements in learning unsupervised sentence embeddings. Luo et al. (2021) introduce a data augmentation-based contrastive learning approach in learning document embeddings, achieving superior performance over word2vec-based approaches (Le and Mikolov, 2014; Chen, 2017).
+
+For dialogue embedding, the above approaches are generally unsatisfactory, as they typically obtain dialogue embeddings by averaging the pretrained word or sentence embeddings, ignoring the interlocutor-level conversational interactions. Although conversational-PLMs pre-trained with dialogue data can solve this problem to some extent (Wu et al., 2020a; Bao et al., 2020; Roller et al., 2021), they mainly focus on learning end-to-end models which are not sufficient for our task. As a comparison, we study how to produce high-quality dialogue embeddings by fully exploiting the conversational information.
+
+# 2.2 Contrastive Learning
+
+Contrastive learning is an emerging self-supervised learning method which can improve the representation capability of PLMs in both pre-training and fine-tuning stages. Wu et al. (2020b); Meng et al.
+
+
+Figure 2: Architecture of dial2vec. Firstly, it encodes a dialogue through a PLM and assigns each interlocutor a self-representation through a masking layer (highlighted with yellow). Hollow circles in each self-representation represent zero embeddings. Then two matching matrices are calculated through the dot-product multiplication, based on which two cross-representations are generated. Each cross-representation and its corresponding self-representation are complementary in the token sequence dimension. Finally, the cosine distance between them will be minimized or maximized according to whether the training sample is positive or negative.
+
+(2021); Giorgi et al. (2020) introduce the token-level and sentence-level contrastive learning tasks by correcting corrupted texts to encourage PLMs to learn noise-invariant representations. Zhang et al. (2022) propose phrase-guided and tree-guided contrastive learning objectives to inject syntactic knowledge into PLMs. Kim et al. (2021) propose a self-guided learning objective through which a PLM fine-tunes itself under the guidance of its different layers. Inspired by these works, we propose to leverage the interlocutor-level conversational interactions to guide the learning of dialogue embeddings in an unsupervised learning manner.
+
+# 3 Proposed Approach
+
+In this section, we take a two-party dialogue as an example to describe how dial2vec works. It is worth mentioning that dial2vec can be extended to the multi-party version through the OVR (one vs. the rest) scheme with no modification of the architecture.
+
+# 3.1 Training Samples Generation
+
+We first describe how we construct the positive and the negative training samples, which plays a key role in the self-guided contrastive learning approach. Suppose that we have a dialogue dataset $\mathcal{D} = \{S_k\}_{k=1}^K$ , where $S_k = \{u_1^{p_1}, u_2^{p_2}, u_3^{p_3}, u_4^{p_4}, \ldots, u_{t-1}^{p_1}, u_t^{p_2}\}$ is the $k$ -th dialogue session with $t$ utterances. $p_1$ and $p_2$ represent two interlocutors. We treat each utterance in a dialogue as a turn, regardless of which interlocutor it corresponds to. For the convenience of narration, $k$ in $S_k$ is omitted in the following sections.
+
+We treat $S$ (i.e., the original dialogue) as a positive sample. To construct a negative sample $S'$ , we first randomly select an interlocutor in $S$ , say $p_1$ , and keep all the turns of it. Then we fill the other turns of $S$ with the utterances of $p_2$ randomly sampled from all dialogue sessions. For each positive sample, we repeat this operation multiple times to generate the desired number of negative samples.
+
+# 3.2 Model Architecture
+
+Figure 2 shows the architecture of dial2vec, which consists of two parts: encoding and contrastive learning. After training, dial2vec aggregates the embeddings from both interlocutors to obtain the final dialogue embedding, which is further used for downstream tasks.
+
+# 3.2.1 Encoding
+
+Following Bao et al. (2020), we use four types of embeddings as input to dial2vec: token embedding, relative positional embedding, turn embedding, and role embedding. To encode the dialogue, we first concatenate all the utterances and then tokenize them through WordPiece (Wu et al., 2016) to obtain a long token sequence. The tokens along with their corresponding position, turn, and role indices are respectively mapped into four embedding spaces and summed to form the final input embedding.
+
+# 3.2.2 Contrastive Learning
+
+Suppose that the output embeddings from the encoder are $\{\mathbf{h}_1,\mathbf{h}_2,\mathbf{h}_3,\dots ,\mathbf{h}_n\}$ , where $\mathbf{h}_i\in \mathbb{R}^d$ is the output embedding corresponding to the $i$ -th input token and $n$ is the length of the input sequence,
+
+we stack the output embeddings as a matrix denoted as $\mathbf{E} \in \mathbb{R}^{n \times d}$ .
+
+To obtain the self-representations, we first generate two binary mask vectors $\mathbf{m}^{p_1}$ and $\mathbf{m}^{p_2}$ for two interlocutors respectively. Let $m_i^{p_1}$ be the $i$ -th element in $\mathbf{m}^{p_1}$ , then $m_i^{p_1}$ is set to 1 only when $\mathbf{h}_i$ is derived from the input token of $p_1$ , otherwise it is 0. Similar operation is applied to generate $\mathbf{m}^{p_2}$ . Then, the self-representations are obtained by:
+
+$$
+\begin{array}{l} \hat {\mathbf {E}} ^ {p _ {1}} = \mathbf {E} \odot (\mathbf {m} ^ {p _ {1}}) ^ {T}, \\ \hat {\mathbf {E}} ^ {p _ {2}} = \dots \end{array} \tag {1}
+$$
+
+$$
+\hat {\mathbf {E}} ^ {p _ {2}} = \mathbf {E} \odot (\mathbf {m} ^ {p _ {2}}) ^ {T},
+$$
+
+where $\odot$ denote the broadcast element-wise multiplication.
+
+To extract the interaction information, we perform the token-level dot-product multiplication between $\hat{\mathbf{E}}^{p_1}$ and $\hat{\mathbf{E}}^{p_2}$ and compute a correlation score matrix for each interlocutor, which is formulated by:
+
+$$
+\mathbf {C} ^ {p _ {1}} = \hat {\mathbf {E}} ^ {p _ {2}} \left(\hat {\mathbf {E}} ^ {p _ {1}}\right) ^ {T}, \tag {2}
+$$
+
+$$
+\mathbf {C} ^ {p _ {2}} = \hat {\mathbf {E}} ^ {p _ {1}} \left(\hat {\mathbf {E}} ^ {p _ {2}}\right) ^ {T},
+$$
+
+where $\mathbf{C}^{p_1}$ and $\mathbf{C}^{p_2}$ are both $n\times n$ square matrices and they are transposed to each other. Then we generate the cross-representations by:
+
+$$
+\tilde {\mathbf {E}} ^ {p _ {1}} = \mathbf {C} ^ {p _ {1}} \hat {\mathbf {E}} ^ {p _ {1}}, \tag {3}
+$$
+
+$$
+\mathbf {\tilde {E}} ^ {p _ {2}} = \mathbf {C} ^ {p _ {2}} \mathbf {\hat {E}} ^ {p _ {2}}.
+$$
+
+Note that $\tilde{\mathbf{E}}$ can be regarded as a refined representation of $\hat{\mathbf{E}}$ , which highlights the conversational interaction information in the trivial encoding results. The fact that $\tilde{\mathbf{E}}$ and $\hat{\mathbf{E}}$ share the same semantic space allows us to directly optimize their cosine distance without any additional transformations. In this circumstance, $\tilde{\mathbf{E}}$ acts as guidance for leading $\hat{\mathbf{E}}$ to be an interaction-aware self-representation, and this is why we call dial2vec works in a self-guided manner.
+
+We further introduce $w$ as a restriction hyperparameter to mask the long-range semantic correlations among the utterances of $p_1$ and $p_2$ . Specifically, let $\mathbf{C}[i,j]$ denotes the element in the $i$ -th row and the $j$ -th column of $\mathbf{C}$ in Eq. (2). $T(i)$ represents a function which returns the turn index for the $i$ -th output embedding in $\mathbf{E}$ . Then $\forall i,j \in 1,2,\ldots,n$ , $\mathbf{C}[i,j]$ is masked with zero where $abs(T(i) - T(j)) > w$ , otherwise remains unchanged. Here we omit the superscript $p_1$ and $p_2$ in $\mathbf{C}$ since they are processed in the same way.
+
+# 3.2.3 Aggregation
+
+To obtain the dialogue embedding $\mathbf{e}$ , we compare two aggregation strategies. In the first strategy, we directly perform average pooling across all entire output embeddings $\mathbf{E}$ (here we do not distinguish between $p_1$ and $p_2$ ). We further propose the interlocutor-level pooling strategy, formulated as:
+
+$$
+\mathbf {e} = \sum_ {r = 1} ^ {R} \frac {\sum_ {i = 1} ^ {n} m _ {i} ^ {p _ {r}} \mathbf {h} _ {i}}{\sum_ {i = 1} ^ {n} m _ {i} ^ {p _ {r}}}, \tag {4}
+$$
+
+where $m_{i}^{p_{r}}$ is the $i$ -th value in $\mathbf{m}^{p_r}$ and $R$ is the number of interlocutors. We compare the results of the two strategies in Section 5.3.2.
+
+# 3.2.4 Learning Objective
+
+We adopt the NT-Xent loss proposed in (Oord et al., 2018) to train our model. Let $N$ be the number of all training samples associated with $S$ , which actually equals one positive sample plus the number of its corresponding negative samples. The loss $l$ is defined as:
+
+$$
+l = - \sum_ {r = 1} ^ {R} \log \frac {e ^ {\operatorname {s i m} \left(\hat {\mathbf {E}} ^ {p r} , \tilde {\mathbf {E}} ^ {p r}\right) / \tau}}{\sum_ {j = 1} ^ {N} e ^ {\operatorname {s i m} \left(\tilde {\mathbf {E}} _ {j} ^ {p r} , \tilde {\mathbf {E}} _ {j} ^ {p r}\right) / \tau}}, \tag {5}
+$$
+
+where $\tau$ is the hyper-parameter of temperature. $\mathrm{sim}(\cdot ,\cdot)$ is defined as an average pooling operation followed by the cosine distance calculation. For all $K$ dialogues in the dataset $D$ the loss $\mathcal{L}$ is given by:
+
+$$
+\mathcal {L} = \frac {1}{K} \sum_ {i = 1} ^ {K} l _ {i}. \tag {6}
+$$
+
+# 4 Experiments Setup
+
+# 4.1 Evaluation Tasks
+
+We introduce three evaluation tasks: domain categorization, semantic relatedness, and dialogue retrieval. We categorize them into intrinsic and extrinsic tasks. The intrinsic tasks, including domain categorization and semantic relatedness, focus on assessing the overall distribution of the learned dialogue embeddings. The extrinsic task (i.e., dialogue retrieval) is more concerned with the performance of embeddings in dense retrieval scenarios.
+
+Domain Categorization. Given a dataset of dialogues, the task is to assign each dialogue the corresponding domain label. Following Schnabel et al. (2015), we conduct this experiment as an unsupervised clustering task. All the dialogue embeddings
+
+| Datasets | Train | Dev | Test | #Domain |
| #Sample | #Turn | #Word | #Sample | #Turn | #Word | #Sample | #Turn | #Word |
| BiTOD | 2952 | 19 | 217 | 70 | 11 | 109 | 106 | 10 | 106 | 6 |
| Doc2dial | 3474 | 11 | 187 | 661 | 12 | 182 | 661 | 12 | 182 | 4 |
| MetalWOZ | 30307 | 11 | 83 | 3788 | 11 | 82 | 3789 | 11 | 82 | 47 |
| MultiWOZ | 8437 | 13 | 177 | 1077 | 9 | 110 | 1084 | 9 | 110 | 7 |
| Self-dialogue | 19331 | 15 | 151 | 2416 | 15 | 151 | 2417 | 15 | 152 | 28 |
| SGD | 16142 | 20 | 199 | 836 | 14 | 140 | 1331 | 12 | 124 | 45 |
+
+Table 1: Statistics of the six dialogue datasets used in our experiments. #Turn and #Word represent the average number of turns and words per dialogue. #Domain represents the total number of domains in the dataset.
+
+are clustered into $n$ categories with KMeans++ Algorithm (Arthur and Vassilvitskii, 2006), where $n$ is the number of domains in the dataset. We adopt the purity metric in this task.
+
+Semantic Relatedness. We pair each dialogue with a dialogue randomly selected from the same dataset and evaluate their semantic relatedness score based on their cosine similarity. The ground-truth label assigned to each dialogue pair is a binary value and is decided by whether the two dialogues share the identical domain. Following Baroni et al. (2014), we calculate Spearman's correlation between the sorted semantic relatedness scores and their corresponding ground-truth labels. This task is more stable than the domain categorization task since it gets rid of the high variance of clustering algorithms when the embedding distribution changes.
+
+Dialogue Retrieval. Given a dialogue as a query, this task requires a model to rank all the candidates based on the cosine similarities. We use mean average precision (MAP) as the evaluation measure.
+
+# 4.2 Datasets
+
+We collect six widely-used dialogue datasets as below. We choose these datasets because they hold clear domain labels. Other datasets either provide non-semantic labels (e.g., logical labels that are less relevant to conversational semantics) (Li et al., 2017) or provide the domain labels automatically annotated by algorithms (Chen et al., 2021), thus are not suitable in our experiments. We split each dataset into training, validation, and testing sets and filter out dialogues with multiple domains in validation and test sets to fit our evaluation tasks. All domain labels are invisible to the model during the training procedure. Table 1 shows their statistics.
+
+BiTOD (Lin et al., 2021) is a bilingual multi-domain dataset proposed for end-to-end task
+
+oriented dialogue modeling. It provides thousands of dialogues and a large and realistic bilingual knowledge base. We use the dialogues and conduct experiments under the monolingual setting.
+
+Doc2dial (Feng et al., 2020) includes goal-oriented dialogues that are grounded in the associated documents. We take the document topics as the domain labels of the dialogues.
+
+MetalWOZ (Lee et al., 2019) is proposed for DSTC8, aiming at helping models more accurately predict user responses in new domains.
+
+MultiWOZ (Eric et al., 2019) is a multi-domain dialogue dataset that poses significant challenges to task-oriented dialogue modeling due to its complexity. We use the 2.1 version in our experiments.
+
+Self-dialogue (Fainberg et al., 2018) consists of large-scale self-dialogues with a broad set of topics. Modeling these dialogues is relatively difficult since they have more turns and topics.
+
+SGD (Rastogi et al., 2020) is another larger-scale multi-domain dialogue dataset. We take the service field as the domain label of the dialogues.
+
+# 4.3 Comparison Methods
+
+The baseline approaches compared to our model are categorized into four groups as follows.
+
+Non-DL Approaches. We treat a dialogue as a document and apply Latent Dirichlet Allocation (LDA) (Blei et al., 2003) to assign each dialogue a topic. LDA is only used in the domain categorization task, since it cannot give a similarity score between two dialogues.
+
+**Embedding-based Approaches.** We consider a dialogue as a sequence of words or sentences, and we obtain dialogue embeddings by combining their pre-trained embeddings. We adopt GloVe (Pennington et al., 2014) to obtain pre-trained word embeddings, SimCSE (Gao et al., 2021) to obtain pre-trained universal sentence embeddings, and DialogueCSE (Liu et al., 2021) to obtain pre-trained dialogue-based sentence embeddings. Also, we
+
+| Model | Domain Categorization | Semantic Relatedness |
| bit | doc | met | mul | sel | sgd | Average | bit | doc | met | mul | sel | sgd | Average |
| LDA | 44.7 | 35.2 | 19.3 | 45.9 | 24.7 | 20.2 | 31.7 | - | - | - | - | - | - | - |
| GloVe | 64.3 | 54.7 | 40.5 | 79.0 | 35.0 | 51.6 | 54.2 | 34.3 | 25.9 | 15.8 | 38.9 | 15.7 | 27.6 | 26.4 |
| Doc2Vec | 82.7 | 70.9 | 43.9 | 86.1 | 40.9 | 63.6 | 64.7 | 43.4 | 24.8 | 14.6 | 30.6 | 10.7 | 26.9 | 25.2 |
| SimCSE | 79.3 | 64.7 | 45.1 | 85.5 | 46.8 | 66.7 | 64.7 | 39.5 | 33.2 | 14.9 | 38.1 | 18.3 | 26.9 | 28.5 |
| DialogueCSE | 85.8 | 68.4 | 77.5 | 94.9 | 53.2 | 72.1 | 75.3 | 42.4 | 44.5 | 23.9 | 65.2 | 27.6 | 31.7 | 39.2 |
| BERT | 49.1 | 54.0 | 31.6 | 61.3 | 44.4 | 31.3 | 45.3 | 24.3 | 22.4 | 11.6 | 30.5 | 16.7 | 17.9 | 20.6 |
| RoBERTa | 63.2 | 40.4 | 46.4 | 62.8 | 44.9 | 40.8 | 49.8 | 30.2 | 14.8 | 15.4 | 28.5 | 17.5 | 16.7 | 20.5 |
| T5 | 78.7 | 55.2 | 67.6 | 89.5 | 43.8 | 69.5 | 67.4 | 38.6 | 28.6 | 20.8 | 42.5 | 20.0 | 29.7 | 30.0 |
| TOD-BERT | 75.6 | 63.1 | 82.9 | 94.3 | 50.0 | 50.3 | 69.4 | 47.0 | 32.6 | 24.3 | 48.9 | 24.6 | 24.8 | 33.7 |
| Blender | 80.9 | 56.4 | 62.3 | 82.4 | 45.4 | 73.1 | 66.8 | 37.0 | 28.1 | 19.9 | 44.4 | 18.3 | 31.1 | 29.8 |
| PLATO | 74.1 | 79.0 | 73.9 | 82.5 | 62.5 | 71.0 | 73.8 | 46.6 | 38.7 | 22.7 | 45.3 | 35.1 | 32.4 | 36.8 |
| Dial2Vec | 90.6 | 90.2 | 77.2 | 96.7 | 63.1 | 86.2 | 84.0 | 68.8 | 50.7 | 24.5 | 71.0 | 37.2 | 36.9 | 48.2 |
+
+Table 2: Evaluation results of the intrinsic tasks on the six dialogue datasets, including BiTOD (bit), Doc2dial (doc), MetalWOZ (met), MultiWOZ (mul), Self-dialogue (sel) and SGD (sgd). The metrics are purity and Spearman's correlation for the two tasks respectively. All results reported are averaged across 10 independent runs to reduce the variance. Boldface and underline highlight the best and the second-best scores.
+
+consider a dialogue as a document and embed it with Doc2Vec (Le and Mikolov, 2014).
+
+PLMs. We consider three representative pretrained language models, including BERT (Devlin et al., 2018), RoBERTa (Liu et al., 2019a), and T5 (Raffel et al., 2020).
+
+Conversational-PLMs. We adopt TOD-BERT (Wu et al., 2020a), Blender (Roller et al., 2021), and PLATO (Bao et al., 2020) as baselines in this group. TOD-BERT (Wu et al., 2020a) is pre-trained with nine dialogue datasets, including MultiWOZ and MetalWOZ. We adopt it as a strong baseline to compare against our model, especially on the MultiWOZ and MetalWOZ datasets. Blender (Roller et al., 2021) and PLATO (Bao et al., 2020) are pre-trained with large-scale open domain dialogue data including Twitter and Reddit (Cho et al., 2014; Zhou et al., 2018; Galley et al., 2019). We also include them as strong baselines for comparison.
+
+For all PLMs and Conversational-PLMs, we use the average of the output embeddings from the top layer as the dialogue embedding. We do not experiment with the [CLS] token embedding since it may be relatively weak in representing long conversational texts.
+
+# 4.4 Implement Details
+
+Our model is implemented in PyTorch (Paszke et al., 2019). We initialize our encoder with PLATO's pre-trained parameters. During finetuning, we freeze the bottom 6 layers of the encoder to avoid the catastrophic forgetting problem. The maximum sequence length is limited to 512 but is
+
+sufficient for most dialogues in our experiments. The temperature $\tau$ and the window size $w$ are set to 0.2 and 10 respectively, since such configuration performs best across all datasets. We optimize the model parameters with Adam optimizer (Kingma and Ba, 2015), using a learning rate of 1e-5 and a batch size of 5 per GPU. All models are trained with 4 NVIDIA Tesla V100 GPUs.
+
+# 5 Experimental Results
+
+# 5.1 Intrinsic Task
+
+Table 2 shows the experimental results of the intrinsic tasks. For each task, dial2vec achieves on average 8.7 and 9.0 absolute improvements in terms of purity and Spearman's correlation against the strongest baseline DialogueCSE. We attribute the strong performance to the introduction of the interlocutor-level conversational interaction information in learning dialogue embeddings.
+
+Conversational-PLMs show overwhelming superiority over PLMs, indicating that pre-training with conversational data plays a key role in producing better dialogue embeddings. The phenomenon that TOD-BERT achieves very competitive results against dial2vec on MultiWOZ and MetalWOZ also confirms this fact. Even so, dial2vec easily bridges or reverses the gaps between PLATO and TOD-BERT on both datasets, demonstrating its superiority in exploiting conversational information.
+
+PLATO generally performs better than TODBERT and Blender. We hypothesize that the turn and role embeddings also play a crucial role in our task. To verify this, we employ BERT as the en
+
+coder and train dial2vec(BERT) $^1$ under the same setting as dial2vec(PLATO). However, the results on the three tasks degrade rapidly after reaching the best performances. We believe that under such a setting, the inputs provide insufficient information for the model to maintain turn-aware and role-aware semantic information in the encoding outputs, making the training not robust.
+
+The embedding-based methods suffer from poor performance since they ignore the weights when combining word and sentence embeddings. Among them, SimCSE releases the inherent representation capability of PLMs by introducing the twice-dropout operation in fine-tuning, achieving better results than GloVe and Doc2Vec. But since such an operation is generic and orthogonal to our work, we do not incorporate it into our model. Particularly, DialogueCSE yields superior results compared with other embedding-based methods and even shows competitive performances against our model. This is reasonable since it is the only baseline in this group that leverages conversational interactions to learn sentence embeddings. However, its performance is still unsatisfactory since it performs sentence-level instead of interlocutor-level interactions and fails to model the entire dialogue.
+
+# 5.2 Extrinsic Task
+
+Table 3 shows dial2vec's performances on the dialogue retrieval task. Compared to the experiment results on the intrinsic tasks, dial2vec achieves more significant improvements on all datasets. We attribute it to dial2vec's capability of understanding fine-grained conversational semantics. Since dial2vec is forced to distinguish the positive samples composed of the exact matching question-answers from the negative ones, the semantic information it learned is more fine-grained than tasks trained with only domain labels. Such characteristic makes it adept at ranking semantically similar candidates, resulting in better performance on the MAP metric.
+
+# 5.3 Analysis
+
+To further investigate the property of our model, we adopt PLATO as the baseline to conduct experiments with the single interlocutor's embeddings, the aggregation strategies, and the embedding distributions. We report the average results across all datasets.
+
+| Model | Dialogue Retrieval |
| bit | doc | met | mul | sel | sgd | AVG |
| GloVe | 63.8 | 49.1 | 29.4 | 65.9 | 24.1 | 52.6 | 47.5 |
| Doc2Vec | 67.7 | 43.7 | 15.1 | 50.9 | 16.3 | 43.1 | 39.5 |
| SimCSE | 62.5 | 52.5 | 23.8 | 62.1 | 27.0 | 44.8 | 45.5 |
| DialogueCSE | 72.9 | 58.2 | 66.7 | 82.9 | 34.5 | 62.5 | 62.9 |
| BERT | 52.4 | 44.8 | 17.0 | 56.4 | 25.8 | 26.0 | 37.1 |
| RoBERTa | 62.2 | 40.6 | 30.4 | 57.4 | 25.5 | 35.0 | 41.9 |
| T5 | 67.3 | 49.9 | 43.9 | 69.7 | 27.8 | 53.8 | 52.1 |
| TOD-BERT | 73.2 | 53.0 | 65.7 | 84.2 | 33.0 | 45.3 | 59.1 |
| Blender | 69.1 | 50.1 | 44.6 | 70.1 | 25.4 | 63.0 | 53.7 |
| PLATO | 71.6 | 59.7 | 54.5 | 68.7 | 45.9 | 63.2 | 60.6 |
| Dial2Vec | 94.4 | 69.4 | 68.0 | 96.4 | 49.4 | 82.8 | 76.7 |
+
+# 5.3.1 Single Interlocutor's Embeddings
+
+Intuitively, each interlocutor holds their own unilateral information of the dialogue. However, such interaction-free information usually contains noises or overlaps with that from other interlocutors. Table 4 shows the experiment results of PLATO and dial2vec. We find that the PLATO's embeddings for individual interlocutors usually perform close to or even better than the aggregated results. As a comparison, dial2vec yields significantly better embeddings for both interlocutors, and achieves further improvements when aggregating them. We conclude that under the guidance of the conversational interactions, dial2vec eliminates the interlocutor-level interaction-free information and highlights the interaction-aware information, thus achieving better performances.
+
+Table 3: Evaluation results of the dialogue retrieval task. We use the mean average precision (MAP) as the evaluation metric. Boldface and underline highlight the best and the second-best scores.
+
+| Model | Interlocutor | Purity | Spearman | MAP |
| PLATO | p1 | 71.78 | 36.23 | 59.38 |
| p2 | 75.29 | 36.67 | 60.73 |
| p1 + p1 | 73.83 | 36.80 | 60.60 |
| diff | -1.46 | 0.13 | -0.13 |
| Dial2Vec | p1 | 83.27 | 47.82 | 75.72 |
| p2 | 82.21 | 46.74 | 74.56 |
| p1 + p1 | 83.97 | 48.19 | 76.73 |
| diff | 0.70 | 0.37 | 1.01 |
+
+Table 4: Performances of dialogue embeddings for each interlocutor. $p1$ represents that we use the embeddings from the interlocutor who starts the conversation, and $p2$ represents the opposite. $p1 + p2$ represents the aggregated results. diff shows improvements of the aggregated results over the best single interlocutor's results. Boldface represents the best scores among the models.
+
+# 5.3.2 Aggregation Strategies
+
+As described in Section 3.2.3, we experiment with two aggregation strategies: average pooling and interlocutor-level pooling. For average pooling, we average all the output embeddings as the final dialogue embedding, while for interlocutor-level pooling, we sum the average pooling results of the output embeddings corresponding to each interlocutor.
+
+| Model | Purity | Spearman | MAP |
| Dial2Vecavg | 83.69 | 47.93 | 76.39 |
| Dial2Vecint | 83.97 | 48.19 | 76.73 |
| diff | +0.28 | +0.26 | +0.34 |
+
+Table 5: Comparison between the average-pooling (denoted as avg) and interlocutor-level pooling (denoted as int) strategies. Boldface highlights the best scores.
+
+Table 5 shows the results for the two strategies on all datasets. The interlocutor-level pooling strategy performs consistently better than the average pooling strategy. We hold that the interlocutor-level pooling strategy acts as a normalization operation that balances the weight of semantic information from different interlocutors.
+
+# 5.3.3 Alignment and Uniformity Analysis
+
+Inspired by Wang and Isola (2020), we employ the alignment and uniformity metrics to study the variation of dialogue embedding distribution during training. Given a set of data pairs and their corresponding labels, the alignment metric is calculated as the expected value of Euclidean distances of each positive data pair, formulated as:
+
+$$
+\ell_ {\text {a l i g n m e n t}} \triangleq \underset {x, x ^ {+} \sim p _ {p o s}} {\mathbb {E}} \| f (x) - f \left(x ^ {+}\right) \| ^ {2}. \tag {7}
+$$
+
+The alignment metric is suitable for tasks such as Gao et al. (2021) since the positive pairs are encoded from a unique text. However, in our scenario, positive pairs generated from two different dialogues are only expected to have closer distances than negative pairs. Thus, we revise the Eq. (7) to be:
+
+$$
+\begin{array}{l} \ell_ {a d j \_ a l i g n m e n t} \triangleq \underset {x, x ^ {+} \sim p _ {p o s}} {\mathbb {E}} \| f (x) - f (x ^ {+}) \| ^ {2}, \\ - \underset {x, x ^ {-} \sim p _ {n e g}} {\mathbb {E}} \| f (x) - f \left(x ^ {-}\right) \| ^ {2}. \tag {8} \\ \end{array}
+$$
+
+We name $\ell_{adj\_alignment}$ as the adjusted alignment metric.
+
+The uniformity metric is defined to measure how close the embeddings are to the uniform distribution:
+
+$$
+\ell_ {\text {u n i f o r m i t y}} \triangleq \log \underset {x, y \stackrel {i. i. d} {\sim} p _ {\text {d a t a}}} {\mathbb {E}} e ^ {- 2 \| f (x) - f (y) \| ^ {2}}, \tag {9}
+$$
+
+where $p_{data}$ denotes the data distribution.
+
+Figure 3 shows how the adjusted alignment and uniformity vary with the training iterations. 'Start' marks the results at the very beginning of training, which also stands for the vanilla PLATO's performances. As we can see, the two metrics decrease rapidly in the first few iterations. We believe dial2vec learns discriminative embeddings by pushing the embeddings for the two interlocutors in the negative samples away from each other in this stage. Since the dialogue embeddings are spread out over the unit hypersphere, both metrics decrease. As the training proceeds, the model learns the fine-grained informative dialogue embeddings from the positive samples. This makes the dialogues with similar semantics close to each other, causing the uniformity to increase again. The two metrics finally converge to the values much better than the start points, showing that dial2vec learns both informative and discriminative embeddings.
+
+
+Figure 3: The scatter plot of $\ell_{\text{adj\_alignment}} - \ell_{\text{uniformity}}$ on the six testing sets. We plot the two metrics after every evaluation. For both metrics, lower values represent better distributions.
+
+# 6 Conclusion
+
+In this paper, we formally introduce the task of learning unsupervised dialogue embeddings and propose dial2vec to solve this task. We introduce a self-guided mechanism that leverages the conversational interactions to guide the learning of the embeddings for both interlocutors and propose the interlocutor-level strategy to aggregate them. We further release a benchmark consisting of six
+
+widely-used dialogue datasets and three tasks designed based on the domain labels. Our model achieves superior performances on all datasets across the three tasks, and further analysis shows that the dialogue embeddings learned by our model are more informative and discriminative than the baselines. We believe there is still much room for improvement to generate satisfactory dialogue embedding.
+
+# 7 Limitations
+
+Our work has two limitations. First, although dial2vec is designed to be able to scale to multi-party conversations, we did not conduct such experiments due to the lack of a suitable multi-party evaluation dataset. As annotating for a multi-party dialogue dataset is indeed complicated, we leave it to future work. Besides, dial2vec still performs unsatisfactorily when employing BERT-like encoders. Although they also achieve very competitive results, we believe that a robust training procedure is more important since we do not know when to stop training under the unsupervised setting in practice. Dial2vec should be further improved to better adapt to the multiple formats of input embeddings.
+
+# References
+
+David Arthur and Sergei Vassilvitskii. 2006. k-means++: The advantages of careful seeding. Technical report, Stanford.
+Siqi Bao, Huang He, Fan Wang, Hua Wu, and Haifeng Wang. 2020. Plato: Pre-trained dialogue generation model with discrete latent variable. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 85-96.
+Marco Baroni, Georgiana Dinu, and German Kruszewski. 2014. Don't count, predict! a systematic comparison of context-counting vs. context-predicting semantic vectors. In Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 238-247.
+Yoshua Bengio, Réjean Ducharme, Pascal Vincent, and Christian Janvin. 2003. A neural probabilistic language model. The journal of machine learning research, 3:1137-1155.
+David M Blei, Andrew Y Ng, and Michael I Jordan. 2003. Latent dirichlet allocation. the Journal of machine Learning research, 3:993-1022.
+Minmin Chen. 2017. Efficient vector representation for documents through corruption. arXiv preprint arXiv:1707.02377.
+
+Yulong Chen, Yang Liu, and Yue Zhang. 2021. Dialogsum challenge: Summarizing real-life scenario dialogues. In Proceedings of the 14th International Conference on Natural Language Generation, pages 308-313.
+Kyunghyun Cho, Bart Van Merrienboer, Caglar Gulcehre, Dzmitry Bahdanau, Fethi Bougares, Holger Schwenk, and Yoshua Bengio. 2014. Learning phrase representations using rnN encoder-decoder for statistical machine translation. arXiv preprint arXiv:1406.1078.
+Yung-Sung Chuang, Rumen Dangovski, Hongyin Luo, Yang Zhang, Shiyu Chang, Marin Soljačić, Shang-Wen Li, Wen-tau Yih, Yoon Kim, and James Glass. 2022. Diffcse: Difference-based contrastive learning for sentence embeddings. arXiv preprint arXiv:2204.10298.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805.
+Mihail Eric, Rahul Goel, Shachi Paul, Adarsh Kumar, Abhishek Sethi, Peter Ku, Anuj Kumar Goyal, Sanchit Agarwal, Shuyang Gao, and Dilek Hakkani-Tur. 2019. Multiwoz 2.1: A consolidated multi-domain dialogue dataset with state corrections and state tracking baselines. arXiv preprint arXiv:1907.01669.
+Joachim Fainberg, Ben Krause, Mihai Dobre, Marco Damonte, Emmanuel Kahembwe, Daniel Duma, Bonnie Webber, and Federico Fancellu. 2018. Talking to myself: self-dialogues as data for conversational agents. arXiv preprint arXiv:1809.06641.
+Song Feng, Hui Wan, Chulaka Gunasekara, Siva Patel, Sachindra Joshi, and Luis Lastras. 2020. doc2dial: A goal-oriented document-grounded dialogue dataset. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 8118-8128.
+Michel Galley, Chris Brockett, Xiang Gao, Jianfeng Gao, and Bill Dolan. 2019. Grounded response generation task at dstc7. In AAAI Dialog System Technology Challenges Workshop.
+Tianyu Gao, Xingcheng Yao, and Danqi Chen. 2021. Simcse: Simple contrastive learning of sentence embeddings. arXiv preprint arXiv:2104.08821.
+John M Giorgi, Osvald Nitski, Gary D Bader, and Bo Wang. 2020. Declutr: Deep contrastive learning for unsupervised textual representations. arXiv preprint arXiv:2006.03659.
+Wanwei He, Yinpei Dai, Binyuan Hui, Min Yang, Zheng Cao, Jianbo Dong, Fei Huang, Luo Si, and Yongbin Li. 2022a. Space-2: Tree-structured semi-supervised contrastive pre-training for task-oriented dialog understanding. arXiv preprint arXiv:2209.06638.
+
+Wanwei He, Yinpei Dai, Min Yang, Jian Sun, Fei Huang, Luo Si, and Yongbin Li. 2022b. Unified dialog model pre-training for task-oriented dialog understanding and generation. In Proceedings of the 45th International ACM SIGIR Conference on Research and Development in Information Retrieval, pages 187-200.
+Wanwei He, Yinpei Dai, Yinhe Zheng, Yuchuan Wu, Zheng Cao, Dermot Liu, Peng Jiang, Min Yang, Fei Huang, Luo Si, et al. 2022c. Galaxy: A generative pre-trained model for task-oriented dialog with semi-supervised learning and explicit policy injection. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 36, pages 10749-10757.
+Binyuan Hui, Ruiying Geng, Qiyu Ren, Binhua Li, Yongbin Li, Jian Sun, Fei Huang, Luo Si, Pengfei Zhu, and Xiaodan Zhu. 2021. Dynamic hybrid relation exploration network for cross-domain context-dependent semantic parsing. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 13116-13124.
+Taeuk Kim, Kang Min Yoo, and Sang-goo Lee. 2021. Self-guided contrastive learning for bert sentence representations. arXiv preprint arXiv:2106.07345.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In ICLR (Poster).
+Tassilo Klein and Moin Nabi. 2022. Scd: Self-contrastive decorrelation of sentence embeddings. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 394–400.
+Quoc Le and Tomas Mikolov. 2014. Distributed representations of sentences and documents. In International conference on machine learning, pages 1188-1196. PMLR.
+Sungjin Lee, Hannes Schulz, Adam Atkinson, Jianfeng Gao, Kaheer Suleman, Layla El Asri, Mahmoud Adada, Minlie Huang, Shikhar Sharma, Wendy Tay, and Xiujun Li. 2019. Multi-domain task-completion dialog challenge. In Dialog System Technology Challenges 8.
+Yanran Li, Hui Su, Xiaoyu Shen, Wenjie Li, Ziqiang Cao, and Shuzi Niu. 2017. Dailydialog: A manually labelled multi-turn dialogue dataset. arXiv preprint arXiv:1710.03957.
+Zhaojiang Lin, Andrea Madotto, Genta Indra Winata, Peng Xu, Feijun Jiang, Yuxiang Hu, Chen Shi, and Pascale Fung. 2021. Bitod: A bilingual multidomain dataset for task-oriented dialogue modeling. In Thirty-fifth Conference on Neural Information Processing Systems Datasets and Benchmarks Track (Round 1).
+Che Liu, Rui Wang, Jinghua Liu, Jian Sun, Fei Huang, and Luo Si. 2021. Dialoguecse: Dialogue-based contrastive learning of sentence embeddings. arXiv preprint arXiv:2109.12599.
+
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019a. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Zhengyuan Liu and Nancy Chen. 2021. Controllable neural dialogue summarization with personal named entity planning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 92-106.
+Zhengyuan Liu, Angela Ng, Sheldon Lee, Ai Ti Aw, and Nancy F Chen. 2019b. Topic-aware pointer-generator networks for summarizing spoken conversations. In 2019 IEEE Automatic Speech Recognition and Understanding Workshop (ASRU), pages 814-821. IEEE.
+Dongsheng Luo, Wei Cheng, Jingchao Ni, Wenchao Yu, Xuchao Zhang, Bo Zong, Yanchi Liu, Zhengzhang Chen, Dongjin Song, Haifeng Chen, et al. 2021. Unsupervised document embedding via contrastive augmentation. arXiv preprint arXiv:2103.14542.
+Chenxu Lv, Hengtong Lu, Shuyu Lei, Huixing Jiang, Wei Wu, Caixia Yuan, and Xiaojie Wang. 2021. Task-oriented clustering for dialogues. In *Findings of the Association for Computational Linguistics: EMNLP* 2021, pages 4338-4347.
+Yu Meng, Chenyan Xiong, Payal Bajaj, Saurabh Tiwary, Paul Bennett, Jiawei Han, and Xia Song. 2021. Coco-lm: Correcting and contrasting text sequences for language model pretraining. arXiv preprint arXiv:2102.08473.
+Tomas Mikolov, Kai Chen, Greg Corrado, and Jeffrey Dean. 2013. Efficient estimation of word representations in vector space. arXiv preprint arXiv:1301.3781.
+Sosuke Nishikawa, Ryokan Ri, Ikuya Yamada, Yoshi-masa Tsuruoka, and Isao Echizen. 2022. Ease: Entity-aware contrastive learning of sentence embedding. arXiv preprint arXiv:2205.04260.
+Aaron van den Oord, Yazhe Li, and Oriol Vinyals. 2018. Representation learning with contrastive predictive coding. arXiv preprint arXiv:1807.03748.
+Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. 2019. Pytorch: An imperative style, high-performance deep learning library. Advances in neural information processing systems, 32.
+Jeffrey Pennington, Richard Socher, and Christopher D Manning. 2014. Glove: Global vectors for word representation. In Proceedings of the 2014 conference on empirical methods in natural language processing (EMNLP), pages 1532-1543.
+
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21:1-67.
+Abhinav Rastogi, Xiaoxue Zang, Srinivas Sunkara, Raghav Gupta, and Pranav Khaitan. 2020. Towards scalable multi-domain conversational agents: The schema-guided dialogue dataset. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 8689-8696.
+Nils Reimers and Iryna Gurevych. 2019. Sentence-bert: Sentence embeddings using siamese bert-networks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3982-3992.
+Stephen Roller, Emily Dinan, Naman Goyal, Da Ju, Mary Williamson, Yinhan Liu, Jing Xu, Myle Ott, Eric Michael Smith, Y-Lan Boureau, et al. 2021. Recipes for building an open-domain chatbot. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 300-325.
+Tobias Schnabel, Igor Labutov, David Mimno, and Thorsten Joachims. 2015. Evaluation methods for unsupervised word embeddings. In Proceedings of the 2015 conference on empirical methods in natural language processing, pages 298-307.
+Chen Shi, Qi Chen, Lei Sha, Sujian Li, Xu Sun, Houfeng Wang, and Lintao Zhang. 2018. Autodialabel: Labeling dialogue data with unsupervised learning. In Proceedings of the 2018 conference on empirical methods in natural language processing, pages 684-689.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in neural information processing systems, pages 5998-6008.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R Bowman. 2018. Glue: A multi-task benchmark and analysis platform for natural language understanding. arXiv preprint arXiv:1804.07461.
+Jiancheng Wang, Jingjing Wang, Changlong Sun, Shoushan Li, Xiaozhong Liu, Luo Si, Min Zhang, and Guodong Zhou. 2020. Sentiment classification in customer service dialogue with topic-aware multitask learning. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 9177-9184.
+Lihan Wang, Bowen Qin, Binyuan Hui, Bowen Li, Min Yang, Bailin Wang, Binhua Li, Jian Sun, Fei Huang,
+
+Luo Si, et al. 2022. Proton: Probing schema linking information from pre-trained language models for text-to-sql parsing. In Proceedings of the 28th ACM SIGKDD Conference on Knowledge Discovery and Data Mining, pages 1889-1898.
+Tongzhou Wang and Phillip Isola. 2020. Understanding contrastive representation learning through alignment and uniformity on the hypersphere. In International Conference on Machine Learning, pages 9929-9939. PMLR.
+Chien-Sheng Wu, Steven CH Hoi, Richard Socher, and Caiming Xiong. 2020a. Tod-bert: Pre-trained natural language understanding for task-oriented dialogue. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 917-929.
+Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, et al. 2016. Google's neural machine translation system: Bridging the gap between human and machine translation. arXiv preprint arXiv:1609.08144.
+Zhuofeng Wu, Sinong Wang, Jiatao Gu, Madian Khabsa, Fei Sun, and Hao Ma. 2020b. Clear: Contrastive learning for sentence representation. arXiv preprint arXiv:2012.15466.
+Yuanmeng Yan, Rumei Li, Sirui Wang, Fuzheng Zhang, Wei Wu, and Weiran Xu. 2021. Consent: A contrastive framework for self-supervised sentence representation transfer. arXiv preprint arXiv:2105.11741.
+Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Russ R Salakhutdinov, and Quoc V Le. 2019. Xlnet: Generalized autoregressive pretraining for language understanding. Advances in neural information processing systems, 32.
+Shuai Zhang, Wang Lijie, Xinyan Xiao, and Hua Wu. 2022. Syntax-guided contrastive learning for pretrained language model. In Findings of the Association for Computational Linguistics: ACL 2022, pages 2430-2440, Dublin, Ireland. Association for Computational Linguistics.
+Hao Zhou, Tom Young, Minlie Huang, Haizhou Zhao, Jingfang Xu, and Xiaoyan Zhu. 2018. Commonsense knowledge aware conversation generation with graph attention. In *IJCAI*, pages 4623-4629.
+Kun Zhou, Beichen Zhang, Wayne Xin Zhao, and Ji-Rong Wen. 2022. Debiased contrastive learning of unsupervised sentence representations. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 6120-6130.
\ No newline at end of file
diff --git a/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/images.zip b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..f0c9a71efbc9eaa226fbe7adcd705ca9b36ea2a7
--- /dev/null
+++ b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:96f082f4a1c66679de7139869b33ce2c878dec8854a8b8b5f8ce4b5df61f363c
+size 485424
diff --git a/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/layout.json b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..b6cb9c670cf247ef3ef796cc9684817795186142
--- /dev/null
+++ b/dial2vecselfguidedcontrastivelearningofunsuperviseddialogueembeddings/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:da458b2ceb2ef24f269c2ab0bc013345733330ea225c3bbf82603f2b25a43112
+size 384116
diff --git a/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_content_list.json b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..c19fd88042e8c53c8f6f4315990be8c80599206d
--- /dev/null
+++ b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7a225b9793ca7aba4df5ad3ae2e8cf24338e9d6c7b05d42b6a6802fa4ce7ab7d
+size 87876
diff --git a/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_model.json b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0b7424dbdf817cd9a1fa523bfdde40b4603f8e55
--- /dev/null
+++ b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:680207e2c75ac8204a6636bfdc47a7068418ffd60f6ffd89484810ded14decb6
+size 105199
diff --git a/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_origin.pdf b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..f4d05d1896662c876fb58b3e86693f7595ca3f54
--- /dev/null
+++ b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/9d769241-d32a-497e-b955-7e3ec652b4d9_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:94559edaedc4c52c1b4c0ac84dc550c65cc79b5f9d26c5f8fefb4872c3226b8c
+size 1299954
diff --git a/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/full.md b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..4cfb09ef83940894b16695284bc8c395eeabcc65
--- /dev/null
+++ b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/full.md
@@ -0,0 +1,331 @@
+# DialogConv: A Lightweight Fully Convolutional Network for Multi-view Response Selection
+
+Yongkang Liu1, Shi Feng1, Wei Gao2, Daling Wang1 and Yifei Zhang1
+
+1 Northeastern University, China
+
+2 Singapore Management University, Singapore
+
+misonsky@163.com, fengshi@cse.neu.edu.cn
+
+weigao@smu.edu.sg, {wangdaling,zhangyifei}@cse.neu.edu.cn
+
+# Abstract
+
+Current end-to-end retrieval-based dialogue systems are mainly based on Recurrent Neural Networks or Transformers with attention mechanisms. Although promising results have been achieved, these models often suffer from slow inference or huge number of parameters. In this paper, we propose a novel lightweight fully convolutional architecture, called DialogConv, for response selection. DialogConv is exclusively built on top of convolution to extract matching features of context and response. Dialogues are modeled in 3D views, where DialogConv performs convolution operations on embedding view, word view and utterance view to capture richer semantic information from multiple contextual views. On the four benchmark datasets, compared with state-of-the-art baselines, DialogConv is on average about $8.5 \times$ smaller in size, and $79.39 \times$ and $10.64 \times$ faster on CPU and GPU devices, respectively. At the same time, DialogConv achieves the competitive effectiveness of response selection.
+
+# 1 Introduction
+
+An important challenge in building intelligent dialogue systems is the response selection problem, which aims to select an appropriate response from a set of candidates given a dialogue context. Such retrieval-based dialogue systems have attracted great attention from academia and industry due to the advantages of informative and fluent responses produced (Tao et al., 2021).
+
+The existing retrieval-based dialogue systems can be divided into three patterns according to the way of input handling (Zhang and Zhao, 2021): (i) Separate Pattern (Wu et al., 2017; Zhang et al., 2018; Zhou et al., 2018; Gu et al., 2019); (ii) Concatenated Pattern (Tan et al., 2015; Zhou et al., 2016); (iii) PrLM (Pretrained Language Model) Pattern (Cui et al., 2020; Gu et al., 2020; Liu et al., 2021). Separate Pattern (i.e., Figure 1 (a)) encodes utterances individually, while Concatenated Pat
+
+
+Figure 1: Flat modeling. (a) is separate pattern, (b) is concatenated pattern and (c) is PrLM pattern. Grey bars in (c) are embedded representations of special symbols.
+
+tern (i.e., Figure 1 (b)) concatenates all utterances into a continuous word sequence. Methods based on these two patterns usually have Recurrent Neural Networks (RNNs) (Hochreiter and Schmidhuber, 1997; Cho et al., 2014) and attention mechanism (Bahdanau et al., 2015) as the backbone. Although promising results have been achieved, these methods are generally slow in training and inference due to their recurrent nature.
+
+The PrLM Pattern (i.e., Figure 1 (c)) uses special symbols to connect all utterances into a continuous sequence, similar to Concatenated Pattern. While PrLM Pattern has obtained state-of-the-art performance in response selection (Cui et al., 2020; Gu et al., 2020; Liu et al., 2021), this method having Transformer (Vaswani et al., 2017) as the de facto standard architecture suffers from a large number of parameters and heavy computational cost. Very large models not only lead to increased training costs, but also prevent researchers from iterating quickly. At the same time, slow inference hinders development and deployment of dialogue systems in real-world scenarios.
+
+Furthermore, these three patterns treat dialogue contexts as flat structures (Li et al., 2021). Methods based on such flat structures usually capture the sequential features of text by considering each word as a unit. However, previous work (Lu et al., 2019) revealed that given a multi-turn dialogue (e.g., Figure 2 (a)), the context of the dialogue can exhibit a composition of 3D stereo structures as
+
+
+Figure 2: Stereo view modeling. (a) An example of multi-turn dialogue; (b) Features from different views; (c) A schematic diagram of stereo view; (d) Convolution on different views ((1) is convolution in embedding view; (2) is convolution in word view; and (3) is convolution in utterance view)
+
+we view utterances in each dimension (shown as Figure 2 (b) and (c))). As shown in Figure 2 (b), the embedding view can represent features of each individual word, the word view can represent the features from the whole conversation and a single utterance, and the utterance view can capture the dependencies between different localities composed of adjacent utterances. Existing methods (Gu et al., 2019; Zhou et al., 2016; Gu et al., 2020) only extract features based on the flat structures, but cannot simultaneously capture complex features from such stereoscopic views.
+
+In this paper, we propose a lightweight fully convolutional network model, called DialogConv, without any RNN and attention module for multiview response selection. Different from previous studies (Zhou et al., 2016; Gu et al., 2019, 2020; Li et al., 2021) which model the dialogue in a flat view, DialogConv models the dialogue context and response together in the 3D space of the stereo views, i.e., embedding view, word view, and utterance view (as shown in Figure 2 (d)). In the embedding view, the word-level features will be refined through convolution operations on the plane formed by the word sequence dimension and the utterance dimension. In the word view, the global conversation features will be captured by concatenating all words into a continuous sequence, and the features of each utterance will be refined by performing convolution on each utterance. In the utterance view, the dependency features between different local contexts will be distilled by performing convolution across different utterances. In general, DialogConv can simultaneously extract features with different granularities from the stereo structure.
+
+DialogConv is completely based on CNN, which uses much fewer parameters and computing resources. DialogueConv has an average number
+
+of parameters of 12.4 million, which is on average about $8.5 \times$ smaller than other models. The inference speed of DialogConv can be on average about $79.39 \times$ faster on CPU device and $10.64 \times$ faster on GPU device than existing models. Moreover, DialogConv achieves competitive results on four benchmarks and performs even better when pretrained with contrastive learning. In summary, we make the following contributions:
+
+- We propose an efficient convolutional response selection model, DialogConv, which, to our best knowledge, is the first response selection model built entirely on multiple convolutional layers without any RNN or attention module.
+- We model dialogue from stereo views, where 2D and 1D convolution operations are performed on embedding, word and utterance views, and thus DialogConv can capture features from stereo views simultaneously.
+- Extensive experiments on four benchmark datasets show that DialogConv with fewer parameters can achieve competitive performance with faster speed and less computing resources. The code is available o Github².
+
+# 2 Related Work
+
+# 2.1 Retrieval-based Dialogue System
+
+Most existing retrieval-based dialogue systems (Wu et al., 2017; Gu et al., 2019; Liu et al., 2021) focus on matching between dialogue context and response. These methods attempt to mine deep semantic features through sequence modeling, e.g., using attention-based pairwise matching mechanisms to capture interaction features between dialogue context and candidate response. However, previous research (Sankar et al., 2019; Li et al., 2021) shows that these methods fail to fully exploit the conversation history information. In addition, methods based on recurrent neural network suffer
+
+from slow inference speed due to the nature of recurrent structures. Although Transformer-based methods (Vaswani et al., 2017) get rid of the weakness of recurrent structure, they are usually plagued by a large number of parameters (Wu et al., 2019), making the training and inference of Transformer-based models require a lot of computational cost. In this paper, we propose a multi-view approach to model dialogue context based on a fully convolutional structure and a lightweight model that is smaller and faster than most existing methods.
+
+# 2.2 Convolutional Neural Networks (CNN)
+
+For the past few years, CNNs have been the go-to model in computer vision. The main reason is that CNN enjoys the advantage of parameter sharing and is better at modeling local structures. A large number of excellent architectures based on CNN have been proposed (Krizhevsky et al., 2012; He et al., 2016; Dai et al., 2021). For text processing, convolutional structures are good at capturing local dependencies of text and are faster than RNNs (Hochreiter and Schmidhuber, 1997). Therefore, some studies (Wu et al., 2016; Lu et al., 2019; Yuan et al., 2019) employ convolutional structures to aggregate the matching features between dialogue contexts and responses. However, these works usually require combining attention mechanisms or the skeleton structure of RNN with CNNs. Furthermore, these studies treat dialogue context as a flat structure. In this paper, we propose a novel fully convolutional architecture to extract matching features from stereo views, which can simultaneously extract the features with different granularities from different views.
+
+# 3 Methodology
+
+# 3.1 Problem Formulation
+
+In this paper, an instance in the dialogue dataset can be represented as $(C,y)$ , where $C = (u_1,u_2,\ldots ,u_{t - 1},r)$ represents the set of dialogue contexts $(\pmb {u}_1,\pmb {u}_2,\dots ,\pmb{u}_{t - 1})$ and the response $\pmb{r}$ , $\pmb{u_i}$ is the $i$ -th utterance, and $y\in \{0,1\}$ is the class label of $C$ . As the core of retrieval-based dialogue system, the purpose of response selection is to build a discriminator $g(C)$ on $(C,y)$ to measure the matching between the dialogue context and response.
+
+# 3.2 Fully Convolutional Matching
+
+We propose a fully convolutional encoder for multi-view response selection. Multiple views include embedding view, word view, and utterance view. In the embedding view, the convolution operations are performed on the plane formed by the word sequence dimension and the utterance dimension, and word-level features can be extracted through nonlinear transformations between different embeddings. In the word view, global dialogue context features will be captured by convolution of a contiguous sequence connecting all words, and features of each utterance will be obtained by performing convolution on each utterance. In the utterance view, DialogConv is responsible for capturing the dependency features between different local contexts composed of adjacent utterances. Figure 3 shows an overview of our proposed DialogConv, which consists of six layers: (i) embedding layer; (ii) local matching layer; (iii) context matching layer; (iv) discourse matching layer; (v) aggregation layer; (vi) prediction Layer.
+
+Symbol Definition: The embedding layer uses a pretrained word embedding model to map each word in $C$ to a vector space. We stack $C$ chronologically into a 3D tensor $G \in \mathbb{R}^{t \times \ell \times d}$ , where $d$ represents the dimension of word embedding, $\ell$ represents the length of the utterance and $t$ is the number of utterances including the response. $G$ is the input to DialogConv. We use $\mathrm{Conv2D}_{k \times s}^v$ and $\mathrm{Conv1D}_w^v$ to denote the convolution operations, where $\mathrm{Conv2D}_{k \times s}^v$ denotes a two-dimensional convolution with a convolution kernel size of $k \times s$ , $\mathrm{Conv1D}_w^v$ represents a one-dimensional convolution with a convolution kernel size of $w$ , and $v$ represents a specific view. We will describe the details of the remaining layers in the following subsections.
+
+# 3.2.1 Local Matching Layer
+
+The local matching layer is responsible for extracting features of each utterance. The local matching stage contains features from the embedding and word views. Firstly, we employ $1 \times 1$ convolutions in the embedding view and the word view, respectively. The process can be formally described as:
+
+$$
+G _ {1} = \operatorname {C o n v 2 D} _ {1 \times 1} ^ {\text {e m b e d d i n g}} (\sigma (G)) \tag {1}
+$$
+
+$$
+G _ {2} = \operatorname {C o n v 2 D} _ {1 \times 1} ^ {\text {w o r d}} \left(G _ {1}\right) + G \tag {2}
+$$
+
+where $\sigma (\cdot)$ stands for GELUs activation function (Hendrycks and Gimpel, 2016). The $1\times 1$
+
+
+Figure 3: Overview of our DialogConv. The conv@ $i$ symbol represents the $i$ -th convolution operation.
+
+convolution pays attention to the information of the current element itself and does not consider the influence of local context. The features of individual words will be extracted from the embedding and word views by $1 \times 1$ convolution. Multi-scale convolution (Szegedy et al., 2015; Gao et al., 2019) has been shown to be effective in extracting local features. Therefore, we use a $k_{1} \times s_{1}$ convolution in the word view and a $1 \times 1$ convolution in the embedding view to capture the matching features of each utterance. The formal description is given as follows:
+
+$$
+\boldsymbol {G} _ {3} = \operatorname {C o n v 2 D} _ {k _ {1} \times s _ {1}} ^ {\text {w o r d}} \left(\sigma \left(\boldsymbol {G} _ {2}\right)\right) \tag {3}
+$$
+
+$$
+\boldsymbol {G} _ {4} = \operatorname {C o n v 2 D} _ {1 \times 1} ^ {\text {e m b e d d i n g}} \left(\boldsymbol {G} _ {3}\right) + \boldsymbol {G} _ {2} \tag {4}
+$$
+
+Note that we focus on the features of a single utterance in the local matching layer.
+
+# 3.2.2 Context Matching Layer
+
+The context matching layer is responsible for extracting matching features of the global dialogue context. Firstly, we flatten $G_{4}$ into a two-dimensional tensor $G_{5} \in \mathbb{R}^{(t \times \ell) \times d}$ . This is equivalent to concatenating all utterances in chronological order into one continuous sequence of words. Then, we use convolution across words sequence with kernel size of $w_{1}$ in the embedding view, and kernel size of $w_{2}$ in the word view. Details are as follows:
+
+$$
+\boldsymbol {G} _ {6} = \operatorname {C o n v 1 D} _ {w _ {1}} ^ {\text {e m b e d d i n g}} \left(\sigma \left(\boldsymbol {G} _ {5}\right)\right) \tag {5}
+$$
+
+$$
+G _ {7} = f _ {\text {r e s h a p e}} \left(\operatorname {C o n v 1 D} _ {w _ {2}} ^ {\text {w o r d}} \left(G _ {6}\right)\right) + G _ {5} (6)
+$$
+
+where $f_{\text{reshape}}$ is a function that reshapes the output of the convolution to the same shape as $G_5$ and $G_7 \in \mathbb{R}^{t \times \ell \times d}$ . The features of the global dialogue context can be aggregated by a nonlinear transformation between different words concatenating all utterances. The features of the global context are basis for extracting the dependency features between different local contexts.
+
+# 3.2.3 Discourse Matching Layer
+
+The discourse matching layer is responsible for capturing the dependencies between different local contexts composed of adjacent utterances. Modeling dependency features is beneficial for capturing changes in implicit topics, intentions, etc. in the dialogue context, which is important for choosing the correct response. We employ orthogonal convolution to extract dynamic dialogue flow features across utterances to capture discourse-level changes. The specific process is formulated as follows:
+
+$$
+G _ {8} = \operatorname {C o n v 2 D} _ {1 \times s _ {2}} ^ {\text {u t t e r a n c e}} (\sigma (G _ {7})) \tag {7}
+$$
+
+$$
+\boldsymbol {G} _ {9} = \operatorname {C o n v 2 D} _ {s _ {2} \times 1} ^ {\text {u t t e r a n c e}} \left(\boldsymbol {G} _ {8}\right) \tag {8}
+$$
+
+$$
+\boldsymbol {G} _ {1 0} = \operatorname {C o n v 2 D} _ {1 \times 1} ^ {\text {u t t e r a n c e}} \left(\boldsymbol {G} _ {9}\right) + \boldsymbol {G} _ {7} \tag {9}
+$$
+
+where the $1 \times s_2$ convolution and $s_2 \times 1$ convolution are called orthogonal convolutions because the direction of their convolution kernels is vertical. The $1 \times s_2$ convolution is responsible for forming semantic flow based on the context-level features of a single utterance, and the $s_2 \times 1$ convolution extracts discourse structural features according to the depth of dialogue. Finally, we integrate features of utterances through the $1 \times 1$ convolution.
+
+# 3.2.4 Aggregation Layer
+
+The aggregation layer is responsible for obtaining high-level semantic information by integrating the matching features from previous layers. First, we use max-pooling to obtain the sentence representation $G_{11} \in \mathbb{R}^{t \times d}$ . Then, we employ two layers of convolution to extract matching features along the embedding dimension in the embedding view and the depth of dialogue in the utterance view, respectively. The formulation is as follows:
+
+$$
+\boldsymbol {G} _ {1 2} = \operatorname {C o n v 1 D} _ {w _ {3}} ^ {\text {e m b e d d i n g}} (\boldsymbol {G} _ {1 1}) \tag {10}
+$$
+
+$$
+\boldsymbol {G} _ {1 3} = \operatorname {C o n v l D} _ {w _ {4}} ^ {\text {u t t e r a n c e}} \left(\boldsymbol {G} _ {1 2}\right) + \boldsymbol {G} _ {1 1} \tag {11}
+$$
+
+where $w_{3}$ and $w_{4}$ are the convolution kernel sizes. We again use a max-pooling operation based on $G_{13}$ to obtain the final context representation $O$ .
+
+# 3.3 Self-supervised Pre-training
+
+As a lightweight neural structure, the performance of DialogConv can be further improved by a pretraining strategy using a small corpus. While the masked language model pretraining (Devlin et al., 2019; Lan et al., 2020) usually requires large-scale corpora, self-supervised contrastive learning can generally learn representations with a relatively small-scale corpus. Therefore, we employ contrastive learning to learn effective representations by pulling semantically close neighbors together and pushing apart non-neighbors (Hadsell et al., 2006). Given a set of paired examples $D = (x_{i}, x_{i}^{+})$ , where $x_{i}$ is the dialogue context $c$ and $x_{i}^{+}$ is the correct response. We adopt the previous contrastive learning framework (Liu and Liu, 2021) and employ a cross-entropy objective, where the negatives $x_{i}^{-}$ include responses with $y = 0$ and in-batch negatives (Chen et al., 2017). The training objective is:
+
+$$
+L = \log \frac {e ^ {\sin \left(x _ {i} , x _ {i} ^ {+}\right) / \tau}}{\sum_ {j = 1} ^ {| x _ {i} ^ {-} |} e ^ {\sin \left(x _ {i} , x _ {i j} ^ {-}\right) / \tau} + e ^ {\sin \left(x _ {i} , x _ {i} ^ {+}\right) / \tau}} \tag {12}
+$$
+
+where $\tau$ is a temperature hyperparameter, $x_{ij}^{-}$ represents the $j$ -th negative example of $x_{i}, x_{i}^{+}$ represents the positive example of $x_{i}$ , and $sim(\cdot, \cdot)$ is the cosine similarity.
+
+# 4 Experiments and Results
+
+The baselines are described in the Appendix A.1.
+
+# 4.1 Datasets
+
+We conduct extensive experiments on four public datasets: (i) Ubuntu Dialogue (Ubuntu) (Lowe et al., 2015); (ii) Multi-Turn Dialogue Reasoning (MuTual) (Cui et al., 2020); (iii) Douban Conversation Corpus (Douban) (Wu et al., 2016); (iv) E-commerce Dialogue Corpus (ECD) (Zhang et al., 2018). Ubuntu consists of 1 million context-response pairs for training, 0.5 million pairs for validation, and 0.5 million pairs for testing. The ratio of the positive and the negative is 1:1 for training, and 1:9 for validation and testing. Douban consists of 1 million context-response pairs for training, 50k pairs for validation, and 10k pairs for testing. Response candidates are retrieved from Sina Weibo
+
+and labeled by human judges. ECD contains 1 million context-response pairs for training, 10k pairs for validation, and 10k pairs for testing and consists of five different types of conversations (e.g., commodity consultation, logistics express, recommendation, negotiation and chitchat) based on over 20 commodities. MuTual is the first human-labeled reasoning-based dataset for multi-turn dialogue, which contains 7,088 context-response pairs for training, 886 pairs for validation, and 886 pairs for testing. The ratio of the positive and the negative is 1:3 in the training, validation and test sets.
+
+# 4.2 Evaluation Metrics
+
+We follow previous research (Zhang and Zhao, 2021) using evaluation metric $\mathrm{Rn}@\mathrm{k}$ to measure model performance on the datasets Ubuntu, Douban and ECD, which calculates the proportion of truly positive responses among the top- $k$ responses selected from a list of $n$ available candidates for a context. In addition, the traditional metrics MAP (Mean Average Precision) (Baeza-Yates and Ribeiro-Neto, 1999) and MRR (Mean Reciprocal Rank) (Voorhees et al., 1999) are employed on Douban. We use recall at position 1 of 4 candidates $(\mathbb{R}@\mathbb{1})$ , recall at position 2 of 4 candidates $(\mathbb{R}@\mathbb{2})$ and MRR on MuTual dataset, following previous study (Liu et al., 2021). The Ubuntu, Douban and ECD test sets provide ten candidate responses, while the MuTual provides four candidate responses, leading them to adopt different evaluation metrics.
+
+# 4.3 Implementation Details
+
+Model Details: We implement DialogConv using Tensorflow 2 and train DialogConv on a server with an Intel(R) Core(TM) i7-10700 CPU 2.90HZ and a single GeForce RTX 2070 SUPER GPU (8G). In experiments, we consider up to 10 turns and 50 words for the Ubuntu, Douban and ECD datasets, and up to 8 turns and 50 words for the MuTual dataset. The dimension of word embeddings is set to 200. We set the convolution filter sizes $k_{1} = 1$ , $w_{1} = 1$ , $w_{2} = 5$ , $w_{3} = 3$ , $w_{4} = 1$ , $s_{1} = 3$ and $s_{2} = 3$ . Layers 1, 2, 3, 4, 8, 9 and 10 use 2D convolutions, and layers 6, 7, 12 and 13 use 1D convolutions. We set the stride of all convolutional layers to [1, 1] or 1. The filter size of convolution layers 1, 2, 4, 5, 9 and 11 is set to [1, 1]. The filter sizes of the convolution layers 3, 6, 7, 8 and 10 are set to [1, 3], 5, [1, 3], [3, 1] and 3, respectively.
+
+Self-supervised Pre-training: We conduct
+
+ | Ubuntu (English) | Douban (Chinese) |
| Method | R10@1 | R10@2 | R10@5 | MAP | MRR | P@1 | R10@1 | R10@2 | R10@5 |
| MV-LSTM | 0.653 | 0.804 | 0.946 | 0.498 | 0.538 | 0.348 | 0.202 | 0.351 | 0.710 |
| MH-LSTM | 0.653 | 0.799 | 0.944 | 0.500 | 0.537 | 0.345 | 0.202 | 0.348 | 0.720 |
| DUA | 0.757 | 0.868 | 0.962 | 0.551 | 0.599 | 0.421 | 0.243 | 0.421 | 0.780 |
| DAM | 0.767 | 0.874 | 0.969 | 0.550 | 0.601 | 0.427 | 0.254 | 0.410 | 0.757 |
| MRFN | 0.786 | 0.886 | 0.976 | 0.571 | 0.617 | 0.448 | 0.276 | 0.435 | 0.783 |
| IMN | 0.794 | 0.889 | 0.974 | 0.570 | 0.615 | 0.433 | 0.262 | 0.452 | 0.789 |
| IoI | 0.796 | 0.894 | 0.974 | 0.573 | 0.621 | 0.444 | 0.269 | 0.451 | 0.786 |
| MSN | 0.800 | 0.899 | 0.978 | 0.587 | 0.632 | 0.470 | 0.295 | 0.452 | 0.788 |
| BERT-2-128 | 0.647 | 0.767 | 0.911 | - | - | - | - | - | - |
| BERT-4-256 | 0.706 | 0.809 | 0.932 | - | - | - | - | - | - |
| BERT-4-512 | 0.757 | 0.869 | 0.966 | - | - | - | - | - | - |
| BERT-8-512 | 0.788 | 0.888 | 0.978 | - | - | - | - | - | - |
| BERT-12-768 | 0.808 | 0.897 | 0.975 | 0.591 | 0.633 | 0.454 | 0.280 | 0.470 | 0.828 |
| DBERT-6-768 | 0.783 | 0.879 | 0.968 | 0.542 | 0.592 | 0.418 | 0.249 | 0.407 | 0.765 |
| TBERT-4-312 | 0.638 | 0.766 | 0.922 | 0.532 | 0.567 | 0.378 | 0.235 | 0.397 | 0.742 |
| TBERT-6-768 | 0.729 | 0.835 | 0.954 | 0.559 | 0.597 | 0.413 | 0.257 | 0.417 | 0.796 |
| DialogConv | 0.788 | 0.883 | 0.979 | 0.571 | 0.624 | 0.432 | 0.272 | 0.453 | 0.785 |
| DialogConv* | 0.801 | 0.904 | 0.976 | 0.572 | 0.634 | 0.457 | 0.282 | 0.452 | 0.825 |
+
+Table 1: Results on Ubuntu and Douban datasets. The first, second and third groups of models belong to the Concatenated Pattern, Separate Pattern and PrLM-based Pattern, respectively. DialogConv* represents the performance when pretraining with contrastive learning. **Bold** indicates the best result, and **underline** indicates the second best result. $X$ represents the number of layers and $Y$ represents the hidden size of the model in BERT- $X-Y$ , DBERT- $X-Y$ and TBERT- $X-Y$ . TBERT stands for TinyBERT, and DBERT stands for DistilBERT. The ‘-’ indicates no corresponding BERT version is available.
+
+ | ECD (Chinese) | MuTual (English) |
| Method | R10@1 | R10@2 | R10@5 | R@1 | R@2 | MRR |
| MV-LSTM | 0.412 | 0.591 | 0.857 | - | - | - |
| QANET | 0.455 | 0.662 | 0.920 | 0.247 | 0.517 | 0.522 |
| BIDAF | 0.491 | 0.708 | 0.933 | 0.357 | 0.589 | 0.589 |
| MH-LSTM | 0.410 | 0.590 | 0.858 | - | - | - |
| DL2R | 0.399 | 0.571 | 0.842 | - | - | - |
| DUA | 0.501 | 0.700 | 0.921 | 0.437 | 0.698 | 0.658 |
| DAM | 0.526 | 0.727 | 0.933 | 0.458 | 0.718 | 0.673 |
| IMN | 0.621 | 0.797 | 0.964 | 0.404 | 0.622 | 0.638 |
| IoI | 0.563 | 0.768 | 0.950 | 0.421 | 0.686 | 0.647 |
| MSN | 0.606 | 0.770 | 0.937 | 0.420 | 0.677 | 0.646 |
| BERT-2-128 | - | - | - | 0.520 | 0.765 | 0.715 |
| BERT-4-256 | - | - | - | 0.558 | 0.800 | 0.742 |
| BERT-4-512 | - | - | - | 0.607 | 0.837 | 0.772 |
| BERT-8-512 | - | - | - | 0.619 | 0.816 | 0.774 |
| BERT-12-768 | 0.610 | 0.814 | 0.973 | 0.648 | 0.847 | 0.795 |
| DBERT-6-768 | 0.517 | 0.695 | 0.885 | 0.602 | 0.836 | 0.769 |
| TBERT-4-312 | 0.449 | 0.583 | 0.854 | 0.534 | 0.778 | 0.724 |
| TBERT-6-768 | 0.587 | 0.794 | 0.953 | 0.615 | 0.833 | 0.785 |
| DialogConv | 0.827 | 0.889 | 0.962 | 0.602 | 0.834 | 0.769 |
| DialogConv* | 0.844 | 0.891 | 0.963 | 0.622 | 0.854 | 0.782 |
+
+Table 2: Results on ECD and MuTual datasets. The '-' indicates no corresponding BERT version is available.
+
+small-scale pretraining on the training set of downstream tasks through contrastive learning, such as Ubuntu and Douban. Negative instances include not only negative examples provided by the dataset, but also candidate responses from other instances in the same batch. We use the Stochastic Gradient Descent (SGD) optimizer (Bottou, 2012) in the
+
+self-supervised pretraining phase. We set the batch size to 128, the learning rates to 0.001, and the temperature $\tau$ to 0.007.
+
+Fine-tuning: During the fine-tuning phase, we train DialogConv and other models using the Adam optimizer (Kingma and Ba, 2015). The learning rates are initialized to $1e-3$ , $5e-4$ , $1e-4$ , $5e-5$ and $1e-5$ via a multi-step strategy. The batch size is set to 32 for the MuTual dataset and 64 for the other datasets. The values of the above hyperparameters are all fixed using the validation set.
+
+# 4.4 Results of Effectiveness
+
+Tables 1 and 2 report the test results of DialogConv and all compared models on the four datasets. While DialogConv does not achieve the best performance, the model attains near-optimal results in most cases. Furthermore, we calculate the confidence level $(p < 0.05)$ of DialogConv compared to BERT $_{base}$ (i.e., BERT-12-768), which shows that the results of DialogConv are credible.
+
+As shown in Table 1, DialogConv outperforms most classic models such as DUA and DAM, and achieves comparable performance to MRFN on the Ubuntu dataset. DialogConv also outperforms other lightweight variants of BERT such as DBETR-6-768 (i.e., DistilBERT-6-768) and
+
+| Model | Inference Time (CPU/GPU) | Parameters (M) |
| Ubuntu (m) | Douban (s) | ECD (s) | MuTual (s) | Ubuntu | Douban | ECD | MuTual |
| DAM | 177/45 | 227/68 | 227/66 | 91/38 | 95 | 67 | 13 | 8 |
| DUA | 143/49 | 176/64 | 175/64 | 64/26 | 96 | 70 | 16 | 15 |
| IOI | 347/39 | 421/49 | 429/47 | 157/22 | 96 | 69 | 15 | 10 |
| MSN | 105/13 | 128/17 | 126/14 | 45/7 | 89 | 62 | 11 | 13 |
| BERT-2-128 | 54/14 | - | - | 24/9 | 4 | - | - | 4 |
| BERT-4-256 | 352/37 | - | - | 81/12 | 11 | - | - | 11 |
| BERT-4-512 | 1372/53 | - | - | 339/24 | 29 | - | - | 29 |
| BERT-8-512 | 3174/82 | - | - | 667/42 | 41 | - | - | 41 |
| BERT-12-768 | 8991/219 | 4922/240 | 4681/239 | 1694/98 | 110 | 102 | 102 | 110 |
| DBERT-6-768 | 1339/83 | 1591/92 | 1612/87 | 595/33 | 67 | 54 | 54 | 67 |
| TBERT-4-312 | 376/34 | 450/35 | 445/30 | 165/13 | 14 | 11 | 11 | 14 |
| DialogConv | 13/5 | 18/7 | 16/7 | 7/3 | 23 | 13 | 9 | 4 |
+
+Table 3: Comparison of model inference time and the scale of parameters. "m" ("s") stands for minutes (seconds). The number of parameters of Chinese and English BERT is different because their vocabularies differ. The '-' indicates no corresponding BERT version is available.
+
+TBERT-6-768 (i.e., TinyBETR-6-768). When pretrained with contrastive learning, DialogConv performs close to BERT-12-768 and even outperforms BERT-12-768 on R10@2. On the Douban dataset, the performance of DialogConv is $2.3\%$ lower than the best result on R10@1. However, the performance of pretrained DialogConv can achieve nearoptimal results.
+
+In Table 2, compared to BERT-12-768, DialogConv has a huge advantage of $21.7\%$ on R10@1 and $7.5\%$ higher on R10@2, is much better than other variants of BERT. We will discuss this phenomenon in Section 4.7. DialogConv outperforms some classic retrieval-based dialogue models such as DAM and MSN, and is close to some lightweight BERT variants such as DBERT-6-768 and BERT-4-512. Compared to BERT-12-768, DialogConv is $2.6\%$ lower on R10@1 on the MuTual. We believe that the lower performance of DialogConv on MuTual is caused by a limitation of DialogConv itself, which we will discuss in detail in Section 4.7.
+
+# 4.5 Model Efficiency
+
+To measure the complexity of our base model, we analyze the actual inference time of the model on CPU and GPU, as well as the number of parameters, as shown in Table 3. DialogConv a huge speed advantage over other models, no matter on CPU or GPU. For example, on the Ubuntu dataset, DialogConv $4.19 \times$ to $115.67 \times$ faster on CPU and $2.39 \times$ to $11.64 \times$ faster on GPU, and the average inference speed is $115.67 \times$ faster on CPU and $11.64 \times$ faster on GPU than other models. On all four bench
+
+mark datasets, the inference speed of DialogConv is on average $79.39 \times$ faster on CPU and $10.64 \times$ faster on GPU compared to other models. Overall, the gain of inference speed ranges from $1.97 \times$ to $40.61 \times$ on GPU and from $3.47 \times$ to $697.00 \times$ on CPU. The CPU and GPU devices are described in the Implementation Details 4.3 subsection above.
+
+The average number of parameters of DialogConv on the four benchmark datasets is 12.4 million, which is $2.8 \times$ larger than BERT-2-128, $1.1 \times$ than BERT-4-256, and comparable to TBERT-4-312. However, DialogConv has clear advantages in performance and inference time over these models. Compared to TBERT-6-768 and DBERT-7-768, the average number of parameters of DialogConv is $4.9 \times$ and $5.1 \times$ smaller, respectively. Compared with BERT-12-768, the average number of parameters of DialogConv on four datasets is $8.5 \times$ smaller. As compared to the classic models DUA, DAM, IOI and MSN, DialogConv needs approximately $3.5 \times$ less parameters. Overall, DialogConv achieves promising results in both performance and inference time, but relies on generally less parameters. The main reason is that convolutional structure enjoys the advantage of shared parameters, which make DialogConv have fewer parameters compared to other models based on RNN or attention mechanism.
+
+# 4.6 Ablation Study
+
+Table 4 reports the result of module ablation. 1) -LocM removes the local matching layer; 2) -ConM removes the context matching layer; 3) -DisM removes the discourse matching layer; 4) -Agg replaces the aggregation layer with max-pooling.
+
+ | MuTual (English) | ECD (Chinese) |
| Setting | R@1 | R@2 | MRR | R10@1 | R10@2 | R10@5 |
| DialogConv | 0.614 | 0.825 | 0.778 | 0.833 | 0.901 | 0.988 |
| -LocM | 0.580 | 0.786 | 0.754 | 0.813 | 0.881 | 0.958 |
| -ConM | 0.577 | 0.801 | 0.759 | 0.806 | 0.823 | 0.919 |
| -DisM | 0.578 | 0.785 | 0.753 | 0.810 | 0.845 | 0.910 |
| -Agg | 0.573 | 0.783 | 0.750 | 0.804 | 0.824 | 0.870 |
+
+Table 4: Ablation results on validation set.
+
+We can observe that each submodule plays a vital role in DialogConv. Specifically, the local matching layer captures the features of each utterance by mixing the features from the embedding and word views. The context matching layer updates the matching features based on the entire dialogue context and response. The discourse matching layer extracts the dependencies between different local contexts composed of adjacent utterances. Comparatively, it seems that the local matching layer has a little less impact on the model performance than the other layers. We conjecture that the layer can only extract local features to some extent since convolution is better at capturing local features.
+
+# 4.7 Result Analysis and Discussion
+
+BERT-12-768 is a representative BERT base version among other BERT variants. Therefore, we use it as the basic comparison model. In Table 2, DialogConv has an absolute advantage of $21.7\%$ on R10@1 and $7.5\%$ on R10@2 compared with BERT-12-768 on ECD. We believe that there are three main reasons for this phenomenon. First, DialogConv focuses on matching, which can extract matching features from stereoscopic views. We visualize the convolution results of each layer of dialogConv as a heatmap (Figure 4 in Appendix A.2). According to the heatmap, DialogConv can capture key matching features between dialogue context and response. The local matching layer mainly focuses on the features between words. This is because we use $1 \times 1$ convolution in the conv@1 and conv@2 layers while matching features appear between several overlapping words in the two layers. When we use larger convolution kernels, DialogConv starts to focus on matching features between phrases. A similar phenomenon can be observed in the context matching layer. We can see that after the local and global features are extracted by the discourse matching layer, some important features are clearly captured. Second, for ECD, the average overlap of keywords between response
+
+and context reaches about $40\%$ , which is beneficial for DialogConv to extract matching features from multi-view stereos. Third, ECD is a dataset in the domain of e-commerce. The domain-specific performance of BERT-12-768 may be mediocre because the pre-training corpora of BERT-12-768 is domain-agnostic.
+
+In Table 2, DialogConv achieves relatively insufficient performance on MuTual. We believe the main reason is that Mutual is a human-labeled reasoning dataset for multi-turn dialogues. However, DialogConv focuses on matching between dialogue context and response, and lacks reasoning ability. Therefore, DialogConv cannot make a correct predictions on reasoning-oriented examples in MuTual. Figure 5 (in Appendix A.2) demonstrates the convolutional heatmap visualization of DialogConv on MuTual. According to the heatmap, DialogConv erroneously focuses on the features of "and", "their" and "in" in the dialogue context, and dose not consider "5" and "7" as key features.
+
+DialogConv can effectively exploit the dependencies between different local contexts composed of adjacent utterances. To reveal its capabilities in this regard, we perturb the dialogue structure by randomly perturbing the dialogue context and report the results in Table 6 and Table 7 (in Appendix). We can see that the performance of DialogConv degrades to varying degrees on the four benchmark datasets. Specifically, the performance drops by $12.9\%$ R10@1 on Ubuntu, $12\%$ R10@1 on Douban, $17.7\%$ R10@1 on ECD, and $7.4\%$ R@1 on MuTual. We speculate that the dialogue structure contains the dependencies between different local contexts, which is important for multi-turn response selection. When perturbing the dialog stecture, the dependencies between local contexts will be severely broken, resulting in performance degradation of DialogConv.
+
+# 5 Conclusion
+
+In this paper, we propose DialogConv, a multi-view lightweight architecture based exclusively on CNN. DialogConv conducts convolutions on embedding, word, and utterance views to capture matching features. Experiment results show that DialogConv has fewer parameters, is faster, and requires less computing resources to achieve competitive results on four benchmark datasets. DialogConv provides a valuable reference for the dialogue system being deployed in real-world scenarios.
+
+# 6 Limitations
+
+Although our work can achieve competitive results with less computing resources, we acknowledge some limitations of our study. Firstly, DialogConv focuses on matching, resulting in insufficient reasoning ability. Therefore, DialogConv has a lot of room for improvement in the performance of dialogue reasoning (on the MuTual dataset). Secondly, we did not explore the performance of deep DialogConv. Our study mainly focuses on designing a lightweight model, ignoring the potential heavy-duty DialogConv under the blessing of large-scale training corpora. We will explore the performance potential of deep DialogConv in future work.
+
+# 7 Acknowledgement
+
+We would like to thank the reviewers for their constructive comments. The project is supported by the National Natural Science Foundation of China (61872074, 62172086, 62106039, 62272092).
+
+# References
+
+Ricardo A. Baeza-Yates and Berthier Ribeiro-Neto. 1999. Modern Information Retrieval.
+Dzmitry Bahdanau, Kyung Hyun Cho, and Yoshua Bengio. 2015. Neural machine translation by jointly learning to align and translate. In 3rd International Conference on Learning Representations, ICLR 2015.
+Léon Bottou. 2012. Stochastic gradient descent tricks. In Neural networks: Tricks of the trade, pages 421-436. Springer.
+Ting Chen, Yizhou Sun, Yue Shi, and Liangjie Hong. 2017. On sampling strategies for neural network-based collaborative filtering. In Proceedings of the 23rd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, pages 767-776.
+Kyunghyun Cho, Bart van Merrienboer, Caglar Gülcehre, Dzmitry Bahdanau, Fethi Bougares, Holger Schwenk, and Yoshua Bengio. 2014. Learning phrase representations using rn encoder-decoder for statistical machine translation. In EMNLP.
+Leyang Cui, Yu Wu, Shujie Liu, Yue Zhang, and Ming Zhou. 2020. Mutual: A dataset for multi-turn dialogue reasoning. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 1406-1416.
+Zihang Dai, Hanxiao Liu, Quoc Le, and Mingxing Tan. 2021. Coatnet: Marrying convolution and attention for all data sizes. Advances in Neural Information Processing Systems, 34.
+
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. Bert: Pre-training of deep bidirectional transformers for language understanding. In *NAACL-HLT* 2019: Annual Conference of the North American Chapter of the Association for Computational Linguistics, pages 4171–4186.
+Shanghua Gao, Ming-Ming Cheng, Kai Zhao, Xin-Yu Zhang, Ming-Hsuan Yang, and Philip HS Torr. 2019. Res2net: A new multi-scale backbone architecture. IEEE transactions on pattern analysis and machine intelligence.
+Jia-Chen Gu, Tianda Li, Quan Liu, Zhen-Hua Ling, Zhiming Su, Si Wei, and Xiaodan Zhu. 2020. Speaker-aware bert for multi-turn response selection in retrieval-based chatbots. In Proceedings of the 29th ACM International Conference on Information & Knowledge Management, pages 2041-2044.
+Jia-Chen Gu, Zhen-Hua Ling, and Quan Liu. 2019. Interactive matching network for multi-turn response selection in retrieval-based chatbots. In Proceedings of the 28th ACM International Conference on Information and Knowledge Management, pages 2321-2324.
+R. Hadsell, S. Chopra, and Y. LeCun. 2006. Dimensionality reduction by learning an invariant mapping. In 2006 IEEE Computer Society Conference on Computer Vision and Pattern Recognition (CVPR'06), volume 2, pages 1735-1742.
+Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. 2016. Deep residual learning for image recognition. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 770-778.
+Dan Hendrycks and Kevin Gimpel. 2016. Gaussian error linear units (gelus). arXiv preprint arXiv:1606.08415.
+Sepp Hochreiter and Jürgen Schmidhuber. 1997. Long short-term memory. *Neural computation*, 9(8):1735-1780.
+Xiaoqi Jiao, Yichun Yin, Lifeng Shang, Xin Jiang, Xiao Chen, Linlin Li, Fang Wang, and Qun Liu. 2020. Tinybert: Distilling bert for natural language understanding. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 4163-4174.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In International Conference on Learning Representations (Poster).
+Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. 2012. Imagenet classification with deep convolutional neural networks. Advances in neural information processing systems, 25:1097-1105.
+Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma, and Radu Soricut. 2020. Albert: A lite bert for self-supervised learning of language representations. In ICLR 2020: Eighth
+
+International Conference on Learning Representations.
+Zekang Li, Jinchao Zhang, Zhengcong Fei, Yang Feng, and Jie Zhou. 2021. Conversations are not flat: Modeling the dynamic information flow across dialogue utterances. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 128-138.
+Yixin Liu and Pengfei Liu. 2021. Simcls: A simple framework for contrastive learning of abstractive summarization. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 1065-1072.
+Yongkang Liu, Shi Feng, Daling Wang, Kaisong Song, Feiliang Ren, and Yifei Zhang. 2021. A graph reasoning network for multi-turn response selection via customized pre-training. Proceedings of the AAAI Conference on Artificial Intelligence, 35(15):13433-13442.
+Ryan Lowe, Nissan Pow, Iulian Vlad Serban, and Joelle Pineau. 2015. The ubuntu dialogue corpus: A large dataset for research in unstructured multi-turn dialogue systems. In Proceedings of the 16th Annual Meeting of the Special Interest Group on Discourse and Dialogue, pages 285-294.
+Junyu Lu, Chenbin Zhang, Zeying Xie, Guang Ling, Tom Chao Zhou, and Zenglin Xu. 2019. Constructing interpretive spatio-temporal features for multi-turn responses selection. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 44-50.
+Victor Sanh, Lysandre Debut, Julien Chaumont, and Thomas Wolf. 2019. Distilbert, a distilled version of bert: smaller, faster, cheaper and lighter. arXiv preprint arXiv:1910.01108.
+Chinnadhurai Sankar, Sandeep Subramanian, Christopher Pal, Sarath Chandar, and Yoshua Bengio. 2019. Do neural dialog systems use the conversation history effectively? an empirical study. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 32-37.
+Minjoon Seo, Aniruddha Kembhavi, Ali Farhadi, and Hannaneh Hajishirzi. 2017. Bidirectional attention flow for machine comprehension. In *ICLR 2017: International Conference on Learning Representations* 2017.
+Christian Szegedy, Wei Liu, Yangqing Jia, Pierre Sermanet, Scott Reed, Dragomir Anguelov, Dumitru Erhan, Vincent Vanhoucke, and Andrew Rabinovich. 2015. Going deeper with convolutions. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 1-9.
+
+Ming Tan, Cicero dos Santos, Bing Xiang, and Bowen Zhou. 2015. Lstm-based deep learning models for non-factoid answer selection. arXiv preprint arXiv:1511.04108.
+Chongyang Tao, Jiazhan Feng, Rui Yan, Wei Wu, and Daxin Jiang. 2021. A survey on response selection for retrieval-based dialogues. IJCAI.
+Chongyang Tao, wei wu, Can Xu, Wenpeng Hu, Dongyan Zhao, and Rui Yan. 2019. One time of interaction may not be enough: Go deep with an interaction-over-interaction network for response selection in dialogues. In ACL 2019: The 57th Annual Meeting of the Association for Computational Linguistics, pages 1-11.
+Chongyang Tao, Wei Wu, Can Xu, Wenpeng Hu, Dongyan Zhao, and Rui Yan. 2019. Multi-representation fusion network for multi-turn response selection in retrieval-based chatbots. In Proceedings of the twelfth ACM international conference on web search and data mining, pages 267-275.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. Advances in neural information processing systems, 30.
+Ellen M Voorhees et al. 1999. The trec-8 question answering track report. In Trec, volume 99, pages 77-82.
+Shengxian Wan, Yanyan Lan, Jiafeng Guo, Jun Xu, Liang Pang, and Xueqi Cheng. 2016. A deep architecture for semantic matching with multiple positional sentence representations. In Proceedings of the AAAI Conference on Artificial Intelligence, 1.
+Shuohang Wang and Jing Jiang. 2016. Machine comprehension using match-lstm and answer pointer. arXiv preprint arXiv:1608.07905.
+Yu Wu, Wei Wu, Chen Xing, Ming Zhou, and Zhoujun Li. 2016. Sequential matching network: A new architecture for multi-turn response selection in retrieval-based chatbots. arXiv preprint arXiv:1612.01627.
+Yu Wu, Wei Wu, Chen Xing, Ming Zhou, and Zhoujun Li. 2017. Sequential matching network: A new architecture for multi-turn response selection in retrieval-based chatbots. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 496-505.
+Zhanghao Wu, Zhijian Liu, Ji Lin, Yujun Lin, and Song Han. 2019. Lite transformer with long-short range attention. In International Conference on Learning Representations.
+Rui Yan, Yiping Song, and Hua Wu. 2016. Learning to respond with deep neural networks for retrieval-based human-computer conversation system. In Proceedings of the 39th International ACM SIGIR conference on Research and Development in Information Retrieval, pages 55-64.
+
+Adams Wei Yu, David Dohan, Minh-Thang Luong, Rui Zhao, Kai Chen, Mohammad Norouzi, and Quoc V. Le. 2018. Qanet: Combining local convolution with global self-attention for reading comprehension. In International Conference on Learning Representations.
+Chunyuan Yuan, Wei Zhou, Mingming Li, Shangwen Lv, Fuqing Zhu, Jizhong Han, and Songlin Hu. 2019. Multi-hop selector network for multi-turn response selection in retrieval-based chatbots. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 111-120.
+Zhuosheng Zhang, Jiangtong Li, Pengfei Zhu, Hai Zhao, and Gongshen Liu. 2018. Modeling multi-turn conversation with deep utterance aggregation. In Proceedings of the 27th International Conference on Computational Linguistics, pages 3740-3752.
+Zhuosheng Zhang and Hai Zhao. 2021. Advances in multi-turn dialogue comprehension: A survey. arXiv preprint arXiv:2103.03125.
+Xiangyang Zhou, Daxiang Dong, Hua Wu, Shiqi Zhao, Dianhai Yu, Hao Tian, Xuan Liu, and Rui Yan. 2016. Multi-view response selection for human-computer conversation. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 372-381.
+Xiangyang Zhou, Lu Li, Daxiang Dong, Yi Liu, Ying Chen, Wayne Xin Zhao, Dianhai Yu, and Hua Wu. 2018. Multi-turn response selection for chatbots with deep attention matching network. In ACL 2018: 56th Annual Meeting of the Association for Computational Linguistics, volume 1, pages 1118-1127.
+Xiangyang Zhou, Lu Li, Daxiang Dong, Yi Liu, Ying Chen, Wayne Xin Zhao, Dianhai Yu, and Hua Wu. 2018. Multi-turn response selection for chatbots with deep attention matching network. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1118-1127.
+
+# A Appendix
+
+# A.1 Baselines
+
+MV-LSTM (Wan et al., 2016) is a semantic matching method based on LSTM. QANET (Yu et al., 2018) is a machine reading comprehension method based on CNN. MH-LSTM (Wang and Jiang, 2016) is an extractive machine reading comprehension model based on LSTM. BIDAF (Seo et al., 2017) is a machine reading comprehension model based on bi-directional attention flow. Multi-View (Zhou et al., 2016) is a multi-turn dialogue retrieval-based method based on token view and
+
+utterance view. DL2R (Yan et al., 2016) is a multi-turn retrieval-based dialogue model based on sentence pair matching. DUA (Zhang et al., 2018) is a hierarchical interaction model based on attention mechanism. DAM (Zhou et al., 2018) is a deep interaction method based on attention. IMN (Gu et al., 2019) is a retrieval-based dialogue model with bi-directional matching. MRFN (Tao et al., 2019) is a retrieval-based dialogue model with multiple types of representations. IoI (Tao et al., 2019) is a retrieval-based dialogue model based on multiple interactions. MSN (Yuan et al., 2019) is a retrieval-based dialogue model with multi-hop selector mechanism.
+
+BERT (Devlin et al., 2019) is an autoencoding language model based on transformer. Here we employ multiple BERT versions including BERT-2-128 (two layers with hidden size 128), BERT-4-256 (four layers with hidden size 256), BERT-4-512, BERT-8-512 and BERT-12-768. TinyBERT (Jiao et al., 2020) is compressed BERT through a two-stage distillation technique. TinyBERT includes the officially releases TinyBERT-3-312 (short for TBERT-3-312) and TinyBERT-6-768 (short for TBERT-6-768) in Chinese and English. DistilBERT (Sanh et al., 2019) is a distilled version of BERT. DistilBERT includes the officially releases DistilBERT-6-768 (short for DBERT-6-768) in Chinese and English. Notationwise, we use $X$ to represent the number of layers and $Y$ represent the hidden size in BERT- $X-Y$ , DBERT- $X-Y$ and TBERT- $X-Y$ .
+
+# A.2 Heatmap Visualization
+
+Figure 4 and Figure 5 demonstrate example convolutional heatmap visualizations for each layer of DialogConv from datasets Mutual and ECD, respectively. Table 5 demonstrates the comparison between Chinese and English of an example of Ecomm. We obtain the heatmaps in Figure 5 and 4 through visualizing the similarity matrix between response and dialogue context. The larger the value of the similarity matrix, the brighter the corresponding visualization result, and the more important the corresponding word is. According to Figure 4, DialogConv can capture the key features in dialogue context and response such as "not" (不是或非), "quality" (质量), "problem" (问题). We can conclude that DialogConv makes decision based on the matching features between dialogue context and responses. According to Figure 5, DialogConv mis
+
+ | Chinese | English |
| context | 我提前问你了吧 | I asked you in advance. |
| 这不是质量问题哦 | It's not a quality problem. |
| 我要小的又不能用而且这么多包 | I want small and unusable, and so many bags. |
| response | 非质量问题退回的 | For non-quality problems returned |
| 运费亲自理 | the freight will be handled by yourself |
+
+Table 5: An example of a Chinese-English aligned of ECD dataset.
+
+
+Figure 4: An example of visualization heatmap from ECD. The conv@i represents the i-th convolution operation in Figure 3. The horizontal axis represents the dialogue history, and the vertical axis represents the response. The English translation refers to Table 5.
+
+takenly considers "their", "them", "see", and "i" as important features and ignores the key features "5" and "7" in the dialogue context.
+
+
+Figure 5: An example of visualization heatmap from Mutual. The conv@i represents the i-th convolution operation in Figure 3. The horizontal axis represents the dialogue history, and the vertical axis represents the response.
+
+ | Ubuntu (English) | Douban (Chinese) |
| Types | R10@1 | R10@2 | R10@5 | MAP | MRR | P@1 | R10@1 | R10@2 | R10@5 |
| Norm | 0.788 | 0.883 | 0.979 | 0.571 | 0.624 | 0.432 | 0.272 | 0.453 | 0.785 |
| Rand | 0.659 | 0.781 | 0.948 | 0.422 | 0.458 | 0.267 | 0.152 | 0.270 | 0.630 |
+
+Table 6: Performance of DialogConv with normal/perturbed dialogue structure on Ubuntu and Douban. Norm represents the normal dialogue structure. Rand represents the perturbing dialogue structure by shuffling the dialogue context randomly.
+
+ | ECD (Chinese) | MuTual (English) |
| Types | R10@1 | R10@2 | R10@5 | R@1 | R@2 | MRR |
| Norm | 0.827 | 0.889 | 0.962 | 0.602 | 0.834 | 0.769 |
| Rand | 0.650 | 0.780 | 0.946 | 0.528 | 0.761 | 0.686 |
+
+Table 7: Performance of DialogConv with normal/perturbed dialogue structure on ECD and MuTual. Norm represents the normal dialogue structure. Rand represents the perturbing dialogue structure by shuffling the dialogue context randomly.
\ No newline at end of file
diff --git a/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/images.zip b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..ff2729caeb17e78939020775ddd54161dc9b656c
--- /dev/null
+++ b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:87ac729d81e34498ca8a82b06097a9399532c2a1b03e0169dc60749e4ac6ac2f
+size 764865
diff --git a/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/layout.json b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..aa41e3a4ceeefccc385d2787b7c357116e998b09
--- /dev/null
+++ b/dialogconvalightweightfullyconvolutionalnetworkformultiviewresponseselection/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:57ea3523a498e9c5567d59beea04c8e0eda956f169b4ca4c46234ed8933f01f4
+size 425678
diff --git a/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_content_list.json b/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..2e3b8df4b3c461896ea6ad24dbb95b0ef1de88a1
--- /dev/null
+++ b/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:07b302cefc77088711ddc57648d33224323518758fb75a0dd9e0c5e8111e5264
+size 122777
diff --git a/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_model.json b/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..eedb1772111457f7f813ebe215f7d1f54017bc55
--- /dev/null
+++ b/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9c61589383b544a31c7dd1c19ba99504b9dfb602e6774e9436b82aca05a1057e
+size 151858
diff --git a/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_origin.pdf b/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c004358f60a45b79ee7bff563fb2dccc95f4cede
--- /dev/null
+++ b/dictionaryassistedsupervisedcontrastivelearning/9f0f0466-a979-45df-aae4-a528f89ede32_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:41cf636e11ba53bdee126029e14109bf03677edd223abf06491533ae993e4a73
+size 923304
diff --git a/dictionaryassistedsupervisedcontrastivelearning/full.md b/dictionaryassistedsupervisedcontrastivelearning/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f23b00a1ea17d163351fe7a1701d021d5c335f19
--- /dev/null
+++ b/dictionaryassistedsupervisedcontrastivelearning/full.md
@@ -0,0 +1,487 @@
+# Dictionary-Assisted Supervised Contrastive Learning
+
+Patrick Y. Wu $^{1}$ , Richard Bonneau $^{1,2,4,5}$ , Joshua A. Tucker $^{1,2,3}$ , and Jonathan Nagler $^{1,2,3}$
+
+1 Center for Social Media and Politics, New York University
+
+$^{2}$ Center for Data Science, New York University
+
+$^{3}$ Department of Politics, New York University
+
+$^{4}$ Department of Biology, New York University
+
+ourant Institute of Mathematical Sciences, New York University
+
+{pyw230,onneau,joshua.tucker,jonathan.nagler}@nyu.edu
+
+# Abstract
+
+Text analysis in the social sciences often involves using specialized dictionaries to reason with abstract concepts, such as perceptions about the economy or abuse on social media. These dictionaries allow researchers to impart domain knowledge and note subtle usages of words relating to a concept(s) of interest. We introduce the dictionary-assisted supervised contrastive learning (DASCL) objective, allowing researchers to leverage specialized dictionaries when fine-tuning pretrained language models. The text is first keyword simplified: a common, fixed token replaces any word in the corpus that appears in the dictionary(ies) relevant to the concept of interest. During fine-tuning, a supervised contrastive objective draws closer the embeddings of the original and keyword-simplified texts of the same class while pushing further apart the embeddings of different classes. The keyword-simplified texts of the same class are more textually similar than their original text counterparts, which additionally draws the embeddings of the same class closer together. Combining DASCL and cross-entropy improves classification performance metrics in few-shot learning settings and social science applications compared to using cross-entropy alone and alternative contrastive and data augmentation methods.1
+
+# 1 Introduction
+
+We propose a supervised contrastive learning approach that allows researchers to incorporate dictionaries of words related to a concept of interest when fine-tuning pretrained language models. It is conceptually simple, requires low computational resources, and is usable with most pretrained language models.
+
+Dictionaries contain words that hint at the sentiment, stance, or perception of a document (see, e.g., Fei et al., 2012). Social science experts often
+
+craft these dictionaries, making them useful when the underlying concept of interest is abstract (see, e.g., Brady et al., 2017; Young and Soroka, 2012). Dictionaries are also useful when specific words that are pivotal to determining the classification of a document may not exist in the training data. This is a particularly salient issue with small corpora, which is often the case in the social sciences.
+
+However, recent supervised machine learning approaches do not use these dictionaries. We propose a contrastive learning approach, dictionary-assisted supervised contrastive learning (DASCL), that allows researchers to leverage these expert-crafted dictionaries when fine-tuning pretrained language models. We replace all the words in the corpus that belong to a specific lexicon with a fixed, common token. When using an appropriate dictionary, keyword simplification increases the textual similarity of documents in the same class. We then use a supervised contrastive objective to draw together text embeddings of the same class and push further apart the text embeddings of different classes (Khosla et al., 2020; Gunel et al., 2021). Figure 1 visualizes the intuition of our proposed method.
+
+The contributions of this project are as follows.
+
+- We propose keyword simplification, detailed in Section 3.1, to make documents of the same class more textually similar.
+- We outline a supervised contrastive loss function, described in Section 3.2, that learns patterns within and across the original and keyword-simplified texts.
+- We find classification performance improvements in few-shot learning settings and social science applications compared to two strong baselines: (1) ROBERTA (Liu et al., 2019) / BERT (Devlin et al., 2019) fine-tuned with cross-entropy loss, and (2) the supervised contrastive learning approach detailed in Gunel et al. (2021), the most closely related approach to DASCL. To be clear, although BERT and
+
+
+Figure 1: The blue dots are embeddings of the original reviews and the white dots are the embeddings of the keyword-simplified reviews from the SST-2 dataset (Wang et al., 2018). Both reviews are positive, although they do not overlap in any positive words used. The reviews are more textually similar after keyword simplification. Using $\mathrm{BERT}_{\mathrm{BASE - UNC A S E D}}$ out-of-the-box, the cosine similarity between the original reviews is .654 and the cosine similarity between the keyword-simplified reviews is .842. Although there are some issues with using cosine similarity with BERT embeddings (see, e.g., Ethayarajh, 2019; Zhou et al., 2022), we use it as a rough heuristic here.
+
+ROBERTA are not state-of-the-art pretrained language models, DASCL can augment the loss functions of state-of-the-art pretrained language models.
+
+# 2 Related Work
+
+Use of Pretrained Language Models in the Social Sciences. Transformers-based pretrained language models have become the de facto approach when classifying text data (see, e.g., Devlin et al., 2019; Liu et al., 2019; Raffel et al., 2020), and are seeing wider adoption in the social sciences. Terechshenko et al. (2021) show that RoBERTa and XLNet (Yang et al., 2019) outperform bag-of-words approaches for political science text classification tasks. Ballard et al. (2022) use BERTweet (Nguyen et al., 2020) to classify tweets expressing polarizing rhetoric. Lai et al. (2022) use BERT to classify the political ideologies of YouTube videos using text video metadata. DASCL can be used with most pretrained language models, so it can potentially improve results across a range of social science research.
+
+Usage of Dictionaries. Dictionaries play an important role in understanding the meaning behind text in the social sciences. Brady et al. (2017) use a moral and emotional dictionary to predict whether tweets using these types of terms increase their dif
+
+fusion within and between ideological groups. Simchon et al. (2022) create a dictionary of politically polarized language and analyze how trolls use this language on social media. Hopkins et al. (2017) use dictionaries of positive and negative economic terms to understand perceptions of the economy in newspaper articles. Although dictionary-based classification has fallen out of favor, dictionaries still contain valuable information about usages of specific or subtle language.
+
+Text Data Augmentation. Text data augmentation techniques include backtranslation (Sennrich et al., 2016) and rule-based data augmentations such as random synonym replacements, random insertions, random swaps, and random deletions (Wei and Zou, 2019; Karimi et al., 2021). Shorten et al. (2021) survey text data augmentation techniques. Longpre et al. (2020) find that task-agnostic data augmentations typically do not improve the classification performance of pretrained language models. We choose dictionaries for keyword simplification based on the concept of interest underlying the classification task and use the keyword-simplified text with a contrastive loss function.
+
+Contrastive Learning. Most works on contrastive learning have focused on self-supervised contrastive learning. In computer vision, images and their augmentations are treated as positives and other images as negatives. Recent contrastive learning approaches match or outperform their supervised pretrained image model counterparts, often using a small fraction of available annotated data (see, e.g., Chen et al., 2020a; He et al., 2020; Chen et al., 2020b; Grill et al., 2020). Self-supervised contrastive learning has also been used in natural language processing, matching or outperforming pretrained language models on benchmark tasks (see, e.g., Fang et al., 2020; Klein and Nabi, 2020).
+
+Our approach is most closely related to works on supervised contrastive learning. Wen et al. (2016) propose a loss function called center loss that minimizes the intraclass distances of the convolutional neural network features. Khosla et al. (2020) develop a supervised loss function that generalizes NT-Xent (Chen et al., 2020a) to an arbitrary number of positives. Our work is closest to that of Gunel et al. (2021), who also use a version of NT-Xent extended to an arbitrary number of positives with pretrained language models. Their supervised contrastive loss function is detailed in Section A.1.
+
+
+Figure 2: Overview of the proposed method. Although ROBERTA is shown, any pretrained language model will work with this approach. The two RoBERTa networks share the same weights. The dimension of the projection layer is arbitrary.
+
+# 3 Method
+
+The approach consists of keyword simplification and the contrastive objective function. Figure 2 shows an overview of the proposed framework.
+
+# 3.1 Keyword Simplification
+
+The first step of the DASCL framework is keyword simplification. We select a set of $M$ dictionaries $\mathcal{D}$ . For each dictionary $d_{i} \in \mathcal{D}$ , $i \in \{1, \dots, M\}$ , we assign a token $t_{i}$ . Then, we iterate through the corpus and replace any word $w_{j}$ in dictionary $d_{i}$ with the token $t_{i}$ . We repeat these steps for each dictionary. For example, if we have a dictionary of positive words, then applying keyword simplification to
+
+a wonderfully warm human drama that remains vividly in memory long after viewing
+
+would yield
+
+a human drama that remains in memory long after viewing
+
+There are many off-the-shelf dictionaries that can be used during keyword simplification. Table 4 in Section A.2 contains a sample of dictionaries reflecting various potential concepts of interest.
+
+# 3.2 Dictionary-Assisted Supervised
+
+# Contrastive Learning (DASCL) Objective
+
+The dictionary-assisted supervised contrastive learning loss function resembles the loss functions from Khosla et al. (2020) and Gunel et al. (2021). Consistent with Khosla et al. (2020), we project the final hidden layer of the pretrained language model to an embedding of a lower dimension before using the contrastive loss function.
+
+Let $\Psi(x_i), i \in \{1, \dots, N\}$ , be the $L_2$ -normalized projection of the output of the pretrained language encoder for the original text and $\Psi(x_{i+N})$ be the corresponding $L_2$ -normalized projection of the output for the keyword-simplified text. $\tau > 0$ is the temperature parameter that controls the separation of the classes, and $\lambda \in [0,1]$ is the parameter that balances the cross-entropy and the DASCL loss functions. We choose $\lambda$ and directly optimize $\tau$ during training. In our experiments, we use the classifier token as the output of the pretrained language encoder. Equation 1 is the DASCL loss, Equation 2 is the multiclass cross-entropy loss, and Equation 3 is the overall loss that is optimized when finetuning the pretrained language model. The original text and the keyword-simplified text are used with the DASCL loss (Eq. 1); only the original text is used with the cross-entropy loss. The keyword-simplified text is not used during inference.
+
+$$
+\mathcal {L} _ {\mathrm {D A S C L}} = - \frac {1}{2 N} \sum_ {i = 1} ^ {2 N} \frac {1}{2 N _ {y _ {i}} - 1} \times
+$$
+
+$$
+\sum_ {j = 1} ^ {2 N} \mathbb {1} _ {i \neq j, y _ {i} = y _ {j}} \log \left[ \frac {\exp \left(\Psi \left(x _ {i}\right) \cdot \Psi \left(x _ {j}\right) / \tau\right)}{\sum_ {k = 1} ^ {2 N} \mathbb {1} _ {i \neq k} \exp \left(\Psi \left(x _ {i}\right) \cdot \Psi \left(x _ {k}\right) / \tau\right)} \right] \tag {1}
+$$
+
+$$
+\mathcal {L} _ {\mathrm {C E}} = - \frac {1}{N} \sum_ {i = 1} ^ {N} \sum_ {c = 0} ^ {C} y _ {i, c} \cdot \log \hat {y} _ {i, c} \tag {2}
+$$
+
+$$
+\mathcal {L} = (1 - \lambda) \mathcal {L} _ {C E} + \lambda \mathcal {L} _ {D A S C L} \tag {3}
+$$
+
+# 4 Experiments
+
+# 4.1 Few-Shot Learning with SST-2
+
+SST-2, a GLUE benchmark dataset (Wang et al., 2018), consists of sentences from movie reviews and binary labels of sentiment (positive or negative). Similar to Gunel et al. (2021), we experiment with SST-2 with three training set sizes: $N = 20$ , 100, and 1,000. Accuracy is this benchmark's primary metric of interest; we also report average precision. We use ROBERTABASE as the pretrained language model. For keyword simplification, we use the opinion lexicon (Hu and Liu, 2004), which contains dictionaries of positive and negative words. Section A.3.3 further describes these dictionaries.
+
+We compare DASCL to two other baselines: ROBERTABASE using the cross-entropy (CE) loss function and the combination of the cross-entropy and supervised contrastive learning (SCL) loss functions used in Gunel et al. (2021). We also experiment with augmenting the corpus with the
+
+| Loss | N | Accuracy | Avg. Precision |
| CE | 20 | .675 ± .066 | .791 ± .056 |
| CE w/ DA | 20 | .650 ± .051 | .748 ± .050 |
| CE+SCL | 20 | .709 ± .077 | .826 ± .068 |
| CE+DASCL | 20 | .777 ± .024 | .871 ± .014 |
| CE+DASCL w/ DA | 20 | .697 ± .075 | .796 ± .064 |
| CE | 100 | .822 ± .019 | .897 ± .023 |
| CE w/ DA | 100 | .831 ± .032 | .904 ± .031 |
| CE+SCL | 100 | .833 ± .042 | .883 ± .043 |
| CE+DASCL | 100 | .858 ± .017 | .935 ± .012 |
| CE+DASCL w/ DA | 100 | .828 ± .020 | .908 ± .012 |
| CE | 1000 | .903 ± .006 | .962 ± .007 |
| CE w/ DA | 1000 | .899 ± .005 | .956 ± .006 |
| CE+SCL | 1000 | .905 ± .005 | .960 ± .011 |
| CE+DASCL | 1000 | .906 ± .006 | .959 ± .009 |
| CE+DASCL w/ DA | 1000 | .904 ± .004 | .960 ± .011 |
+
+Table 1: Accuracy and average precision over the SST-2 test set in few-shot learning settings. Results are averages over 10 random seeds with standard deviations reported. DA refers to data augmentation, where the keyword-simplified text augments the training corpus.
+
+keyword-simplified text (referred to as "data augmentation," or "DA," in results tables). In other words, when data augmentation is used, both the original text and the keyword-simplified text are used with the cross-entropy loss.
+
+We use the original validation set from the GLUE benchmark as the test set, and we sample our own validation set from the training set of equal size to this test set. Further details about the data and hyperparameter configurations can be found in Section A.3. Table 1 shows the results across the three training set configurations.
+
+DASCL improves results the most when there are only a few observations in the training set. When $N = 20$ , using DASCL yields a 10.2 point improvement in accuracy over using the cross-entropy loss function ( $p < .001$ ) and a 6.8 point improvement in accuracy over using the SCL loss function ( $p = .023$ ). Figure 3 in Section A.3.8 visualizes the learned embeddings using each of these loss functions using t-SNE plots. When the training set's size increases, the benefits of using DASCL decrease. DASCL only has a slightly higher accuracy when using 1,000 labeled observations, and the difference between DASCL and cross-entropy alone is insignificant ( $p = .354$ ).
+
+# 4.2 New York Times Articles about the Economy
+
+Barbera et al. (2021) classify the tone of New York Times articles about the American economy as positive or negative. 3,119 of the 8,462 labeled articles (3,852 unique articles) in the training set are la
+
+| Loss | N | Accuracy | Avg. Precision |
| L2 Logit | 100 | .614 | .479 |
| CE | 100 | .673 ± .027 | .593 ± .048 |
| CE w/ DA | 100 | .663 ± .030 | .576 ± .058 |
| CE+SCL | 100 | .614 ± .000 | .394 ± .043 |
| CE+DASCL | 100 | .705 ± .013 | .645 ± .016 |
| CE+DASCL w/ DA | 100 | .711 ± .013 | .644 ± .027 |
| L2 Logit | 1000 | .624 | .482 |
| CE | 1000 | .716 ± .012 | .662 ± .030 |
| CE w/ DA | 1000 | .710 ± .011 | .656 ± .024 |
| CE+SCL | 1000 | .722 ± .009 | .670 ± .022 |
| CE+DASCL | 1000 | .732 ± .011 | .671 ± .025 |
| CE+DASCL w/ DA | 1000 | .733 ± .008 | .681 ± .021 |
| L2 Logit | Full | .681 | .624 |
| CE | Full | .753 ± .012 | .713 ± .015 |
| CE w/ DA | Full | .752 ± .011 | .708 ± .017 |
| CE+SCL | Full | .756 ± .011 | .723 ± .009 |
| CE+DASCL | Full | .759 ± .006 | .741 ± .010 |
| CE+DASCL w/ DA | Full | .760 ± .008 | .739 ± .014 |
+
+Table 2: Accuracy and average precision over the economic media test set (Barberá et al., 2021) when using 100, 1000, and all labeled examples from the training set for fine-tuning. Except for logistic regression, results are averages over 10 random seeds with standard deviations reported.
+
+beled positive; 162 of the 420 articles in the test set are labeled positive. Accuracy is the primary metric of interest; we also report average precision. In addition to using the full training set, we also experiment with training sets of sizes 100 and 1,000. We use the positive and negative dictionaries from Lexicoder (Young and Soroka, 2012) and dictionaries of positive and negative economic terms (Hopkins et al., 2017). Barbera et al. (2021) use logistic regression with $L_{2}$ regularization. We use ROBERTABASE as the pretrained language model. Section A.4 contains more details about the data, hyperparameters, and other evaluation metrics. Table 2 shows the results across the three training set configurations.
+
+When $N = 100$ , DASCL outperforms cross-entropy only, cross-entropy with data augmentation, and SCL on accuracy ( $p < .005$ for all) and average precision ( $p < .01$ for all). When $N = 1000$ , DASCL outperforms cross-entropy only, cross-entropy with data augmentation, and SCL on accuracy ( $p < .05$ for all) and average precision (but not statistically significantly). DASCL performs statistically equivalent to DASCL with data augmentation across all metrics when $N = 100$ and 1000.
+
+When using the full training set, ROBERTaBASE is a general improvement over logistic regression. Although the DASCL losses have slightly higher accuracy than the other RoBERTa-based models, the differences are not statistically significant. Us-
+
+ing DASCL yields a 2.8 point improvement in average precision over cross-entropy $(p < .001)$ and a 1.8 improvement in average precision over SCL $(p < .001)$ . Figure 4 in Section A.4.9 visualizes the learned embeddings using each of these loss functions using t-SNE plots.
+
+# 4.3 Abusive Speech on Social Media
+
+The OffensEval dataset (Zampieri et al., 2020) contains 14,100 tweets annotated for offensive language. A tweet is considered offensive if "it contains any form of non-acceptable language (pro-fanity) or a targeted offense." Caselli et al. (2020) used this same dataset and more narrowly identified tweets containing "hurtful language that a speaker uses to insult or offend another individual or group of individuals based on their personal qualities, appearance, social status, opinions, statements, or actions." We focus on this dataset, AbusEval, because of its greater conceptual difficulty. 2,749 of the 13,240 tweets in the training set are labeled abusive, and 178 of the 860 tweets in the test set are labeled abusive. Caselli et al. (2021) pretrain a BERTBASE-UNCASED model, HateBERT, using the Reddit Abusive Language English dataset. Macro F1 and F1 over the positive class are the primary metrics of interest; we also report average precision. In addition to using the full training set, we also experiment with training sets of sizes 100 and 1,000. Section A.5 contains more details about the data and hyperparameters.
+
+We combine DASCL with BERTBASE-UNCASED and HateBERT. Alorainy et al. (2019) detect cyberhate speech using threats-based othering language, focusing on the use of "us" and "them" pronouns. Following their strategy, we look at the conjunction of sentiment using Lexicoder and two dictionaries of "us" and "them" pronouns, which may suggest abusive speech. Table 3 compares the performance of BERTBASE-UNCASED and HateBERT with cross-entropy against BERTBASE-UNCASED and HateBERT with cross-entropy and DASCL.
+
+When $N = 100$ , BERT with DASCL outperforms BERT on macro F1 ( $p = .008$ ), F1 over the positive class ( $p = .011$ ), and average precision ( $p = .003$ ); when $N = 1000$ , BERT with DASCL outperforms BERT on macro F1 ( $p = .021$ ), F1 over the positive class ( $p = .028$ ), and average precision ( $p = .007$ ). HateBERT with DASCL performs statistically on par with HateBERT across all metrics for $N = 100$ and $N = 1000$ . BERT with DASCL performs sta
+
+| Model | N | Macro F1 | F1, Pos | Avg. Precision |
| BERT | 100 | .293±.083 | .334±.025 | .233±.040 |
| HateBERT | 100 | .513±.120 | .346±.049 | .303±.059 |
| BERT w/ DASCL | 100 | .427±.112 | .362±.017 | .284±.022 |
| HateBERT w/ DASCL | 100 | .449±.110 | .345±.033 | .281±.045 |
| BERT | 1000 | .710±.018 | .523±.034 | .608±.024 |
| HateBERT | 1000 | .711±.028 | .512±.053 | .626±.017 |
| BERT w/ DASCL | 1000 | .729±.014 | .559±.032 | .637±.016 |
| HateBERT w/ DASCL | 1000 | .704±.010 | .501±.020 | .626±.016 |
| BERT | Full | .767±.008 | .636±.012 | .703±.006 |
| HateBERT | Full | .768±.005 | .630±.009 | .695±.005 |
| BERT w/ DASCL | Full | .779±.010 | .653±.014 | .716±.005 |
| HateBERT w/ DASCL | Full | .766±.007 | .623±.011 | .695±.006 |
+
+Table 3: Macro F1, F1, and average precision over the AbusEval test set (Caselli et al., 2020) when using 100, 1000, and all labeled examples from the training set for fine-tuning. Results are averages over 10 random seeds with standard deviations reported.
+
+tistically equivalent to HateBERT when $N = 100$ and $N = 1000$ on all metrics, except on F1 over the positive class when $N = 1000$ $(p = .030)$ .
+
+When using the full training set, BERT with DASCL improves upon the macro F1, F1 over the positive class, and average precision compared with both BERT (macro F1: $p = .010$ ; F1: $p = .010$ ; AP: $p < .001$ ) and HateBERT (macro F1: $p = .007$ ; F1: $p < .001$ ; AP: $p < .001$ ). Figure 5 in Section A.5.8 visualizes the learned embeddings using BERT and BERT with DASCL using t-SNE plots.
+
+# 5 Conclusion
+
+We propose a supervised contrastive learning approach that allows researchers to leverage specialized dictionaries when fine-tuning pretrained language models. We show that using DASCL with cross-entropy improves classification performance on SST-2 in few-shot learning settings, on classifying perceptions about the economy expressed in New York Times articles, and on identifying tweets containing abusive language when compared to using cross-entropy alone or alternative contrastive and data augmentation methods. In the future, we aim to extend our approach to other supervised contrastive learning frameworks, such as using this method to upweight difficult texts (Suresh and Ong, 2021). We also plan to expand this approach to semi-supervised and self-supervised settings to better understand core concepts expressed in text.
+
+# Limitations
+
+We aim to address limitations to the supervised contrastive learning approach described in this paper in future works. We first note that there are no experiments in this paper involving multiclass or multilabel classification; all experiments involve only binary classification. Multiclass or multilabel classification may present further challenges when categories are more nuanced. We expect improvements in classification performance when applied to multiclass or multilabel classification settings, but we have not confirmed this.
+
+Second, we have not experimented with the dimensionality of the projection layer or the batch sizes. At the moment, the projection layer is arbitrarily set to 256 dimensions, and we use batch sizes from previous works. Future work aims to study how changing the dimensionality of this projection layer and the batch size affects classification outcomes.
+
+Third, we have used the DASCL objective with ROBERTA and BERT, but have not used it with the latest state-of-the-art pretrained language models. We focused on these particular pretrained language models because they are commonly used in the social sciences and because of computational constraints.
+
+Fourth, we have not examined how the quality or size of the dictionary may affect classification outcomes. A poorly constructed dictionary may lead to less improvement in classification performance metrics or may even hurt performance. Dictionaries with too many words or too few words may also not lead to improvements in classification performance metrics. Future work aims to study how the quality and size of dictionaries affect the DASCL approach.
+
+Fifth, we have not explored how this method can be used to potentially reduce bias in text classification. For example, we can replace gendered pronouns with a token (such as ""), potentially reducing gender bias in analytical contexts such as occupation.
+
+Lastly, we have not explored how keyword simplification may be useful in a self-supervised or semi-supervised contrastive learning setting. This may be particularly helpful for social scientists who are often interested in exploring core concepts or perspectives in text rather than classifying text into specific classes.
+
+# Ethics Statement
+
+Our paper describes a supervised contrastive learning approach that allows researchers to leverage specialized dictionaries when fine-tuning pretrained language models. While we did not identify any systematic biases in the particular set of dictionaries we used, any dictionary may encode certain biases and/or exclude certain groups. This can be particularly problematic when working with issues such as detecting hate speech and abusive language. For example, in the context of abusive language, if words that attack a particular group are (purposely or unintentionally) excluded from the dictionaries, those words would not be replaced. This may under-detect abusive text that attacks this specific group.
+
+This paper does not create any new datasets. The OffensEval/AbusEval dataset contains sensitive and harmful language. Although we did not annotate or re-associate any tweets, we are cognizant that particular types of abusive language against certain groups or identities may not have been properly annotated as abusive, or certain types of abusive language may have been excluded from the corpus entirely.
+
+# Acknowledgements
+
+We gratefully acknowledge that the Center for Social Media and Politics at New York University is supported by funding from the John S. and James L. Knight Foundation, the Charles Koch Foundation, Craig Newmark Philanthropies, the William and Flora Hewlett Foundation, the Siegel Family Endowment, and the Bill and Melinda Gates Foundation. This work was supported in part through the NYU IT High Performance Computing resources, services, and staff expertise. We thank the members of the Center for Social Media and Politics for their helpful comments when workshopping this paper. We would also like to thank the anonymous reviewers for their valuable feedback in improving this paper.
+
+# References
+
+Quinn Albaugh, Julie Sevenans, Stuart Soroka, and Peter John Loewen. 2013. The automated coding of policy agendas: A dictionary-based approach. Retrieved from https://www.almendron.com/tribuna/wp-content/uploads/2017/05/CAP2013v2.pdf.
+Wafa Alorainy, Pete Burnap, Han Liu, and Matthew L.
+
+Williams. 2019. "The enemy among us": Detecting cyber hate speech with threats-based othering language embeddings. ACM Trans. Web, 13(3).
+American Defamation League. 2022. Hate on display hate symbols database. Retrieved from https:// www.adl.org/resources/hate-symbols/search. Accessed: 2022-08-28.
+Muhammad Zubair Asghar, Shakeel Ahmad, Maria Qasim, Syeda Rabail Zahra, and Fazal Masud Kundi. 2016. SentiHealth: creating health-related sentiment lexicon using hybrid approach. SpringerPlus, 5(1).
+Stefano Baccianella, Andrea Esuli, and Fabrizio Sebastiani. 2010. SentiWordNet 3.0: An enhanced lexical resource for sentiment analysis and opinion mining. In Proceedings of the Seventh International Conference on Language Resources and Evaluation (LREC'10), Valletta, Malta. European Language Resources Association (ELRA).
+Andrew O. Ballard, Ryan DeTamble, Spencer Dorsey, Michael Heseltine, and Marcus Johnson. 2022. Dynamics of polarizing rhetoric in congressional tweets. *Legislative Studies Quarterly*.
+Pablo Barbera, Amber E. Boydstun, Suzanne Linn, Ryan McMahon, and Jonathan Nagler. 2021. Automated text classification of news articles: A practical guide. Political Analysis, 29(1):19-42.
+Elisa Bassignana, Valerio Basile, and Viviana Patti. 2018. Hurtlex: A multilingual lexicon of words to hurt. In Proceedings of the Fifth Italian Conference on Computational Linguistics (CLiC-It 2018).
+Margaret M. Bradley and Peter J. Lang. 1999. Affective Norms for English Words (ANEW): Instruction manual and affective ratings. Technical Report C-1, The Center for Research in Psychophysiology, University of Florida. Retrieved from https://pdodds.w3.uvm.edu/teaching/courses/2009-08UVM-300/docs/others/everything/bradley1999a.pdf.
+William J. Brady, Julian A. Wills, John T. Jost, Joshua A. Tucker, and Jay J. Van Bavel. 2017. Emotion shapes the diffusion of moralized content in social networks. Proceedings of the National Academy of Sciences, 114(28):7313-7318.
+Marc Brysbaert, Amy Beth Warriner, and Victor Kuperman. 2013. Concreteness ratings for 40 thousand generally known english word lemmas. Behavior Research Methods, 46(3):904-911.
+Tommaso Caselli, Valerio Basile, Jelena Mitrovic, and Michael Granitzer. 2021. HateBERT: Retraining BERT for abusive language detection in English. In Proceedings of the 5th Workshop on Online Abuse and Harms (WOAH 2021), pages 17-25, Online. Association for Computational Linguistics.
+Tommaso Caselli, Valerio Basile, Jelena Mitrovic, Inga Kartoziya, and Michael Granitzer. 2020. I feel offended, don't be abusive! implicit/explicit messages
+
+in offensive and abusive language. In Proceedings of the Twelfth Language Resources and Evaluation Conference, pages 6193-6202, Marseille, France. European Language Resources Association.
+Eshwar Chandrasekharan, Umashanthi Pavalanathan, Anirudh Srinivasan, Adam Glynn, Jacob Eisenstein, and Eric Gilbert. 2017. You can't stay here: The efficacy of reddit's 2015 ban examined through hate speech. Proc. ACM Hum.-Comput. Interact., 1(CSCW).
+Jeffrey T. Chang, Hinrich Schütze, and Russ B. Altman. 2002. Creating an Online Dictionary of Abbreviations from MEDLINE. Journal of the American Medical Informatics Association, 9(6):612-620.
+Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. 2020a. A simple framework for contrastive learning of visual representations. In Proceedings of the 37th International Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research, pages 1597-1607. PMLR.
+Xinlei Chen, Haoqi Fan, Ross Girshick, and Kaiming He. 2020b. Improved baselines with momentum contrastive learning.
+Yoonjung Choi and Janyce Wiebe. 2014. EffectWordNet: Sense-level lexicon acquisition for opinion inference. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 1181-1191, Doha, Qatar. Association for Computational Linguistics.
+Thomas Davidson, Dana Warmsley, Michael Macy, and Ingmar Weber. 2017. Automated hate speech detection and the problem of offensive language. Proceedings of the International AAAI Conference on Web and Social Media, 11(1):512-515.
+Jesse Davis and Mark Goadrich. 2006. The relationship between precision-recall and roc curves. In Proceedings of the 23rd International Conference on Machine Learning, ICML '06, page 233-240, New York, NY, USA. Association for Computing Machinery.
+Matías Dell' Amerlina Ríos and Agustín Gravano. 2013. Spanish DAL: A Spanish dictionary of affect in language. In Proceedings of the 4th Workshop on Computational Approaches to Subjectivity, Sentiment and Social Media Analysis, pages 21-28, Atlanta, Georgia. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+
+Kawin Ethayarajh. 2019. How contextual are contextualized word representations? Comparing the geometry of BERT, ELMo, and GPT-2 embeddings. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 55–65, Hong Kong, China. Association for Computational Linguistics.
+Hongchao Fang, Sicheng Wang, Meng Zhou, Jiayuan Ding, and Pengtao Xie. 2020. CERT: Contrastive self-supervised learning for language understanding.
+Ethan Fast, Binbin Chen, and Michael S. Bernstein. 2016. Empath: Understanding topic signals in largescale text. In Proceedings of the 2016 CHI Conference on Human Factors in Computing Systems, CHI '16, page 4647-4657, New York, NY, USA. Association for Computing Machinery.
+Geli Fei, Bing Liu, Meichun Hsu, Malu Castellanos, and Riddhiman Ghosh. 2012. A dictionary-based approach to identifying aspects implied by adjectives for opinion mining. In Proceedings of COLING 2012: Posters, pages 309-318, Mumbai, India. The COLING 2012 Organizing Committee.
+Sarah Fioroni, Ariel Hasell, Stuart Soroka, and Brian Weeks. 2022. Constructing a dictionary for the automated identification of discrete emotions in news content.
+Konstantina Georgelou, Antje Hildebrandt, and Katerina Paramana. 2017. The PSi manifesto lexicon: An online discursive platform. Global Performance Studies, 1(1).
+Jean-Bastien Grill, Florian Strub, Florent Altché, Corentin Tallec, Pierre Richemond, Elena Buchatskaya, Carl Doersch, Bernardo Avila Pires, Zhaohan Guo, Mohammad Gheshlaghi Azar, Bilal Piot, Koray Kavukcuoglu, Remi Munos, and Michal Valko. 2020. Bootstrap your own latent - a new approach to self-supervised learning. In Advances in Neural Information Processing Systems, volume 33, pages 21271-21284. Curran Associates, Inc.
+Belize Gunel, Jingfei Du, Alexis Conneau, and Veselin Stoyanov. 2021. Supervised contrastive learning for pre-trained language model fine-tuning. In International Conference on Learning Representations.
+Hatebase. 2022. Hatebase is a collaborative, regionalized repository of multilingual hate speech. Retrieved from https://hatebase.org/. Accessed: 2022-08-28.
+Kaiming He, Haoqi Fan, Yuxin Wu, Saining Xie, and Ross Girshick. 2020. Momentum contrast for unsupervised visual representation learning. In 2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 9726-9735.
+
+Daniel J. Hopkins, Eunji Kim, and Soojong Kim. 2017. Does newspaper coverage influence or reflect public perceptions of the economy? Research & Politics, 4(4):1-7.
+Minqing Hu and Bing Liu. 2004. Mining and summarizing customer reviews. In Proceedings of the Tenth ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, KDD '04, page 168-177, New York, NY, USA. Association for Computing Machinery.
+C. Hutto and Eric Gilbert. 2014. VADER: A parsimonious rule-based model for sentiment analysis of social media text. Proceedings of the International AAAI Conference on Web and Social Media, 8(1):216-225.
+Akbar Karimi, Leonardo Rossi, and Andrea Prati. 2021. AEDA: An easier data augmentation technique for text classification. In *Findings of the Association for Computational Linguistics: EMNLP* 2021, pages 2748-2754, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Prannay Khosla, Piotr Teterwak, Chen Wang, Aaron Sarna, Yonglong Tian, Phillip Isola, Aaron Maschinot, Ce Liu, and Dilip Krishnan. 2020. Supervised contrastive learning. In Advances in Neural Information Processing Systems, volume 33, pages 18661-18673. Curran Associates, Inc.
+Svetlana Kiritchenko, Saif Mohammad, and Mohammad Salameh. 2016. SemEval-2016 task 7: Determining sentiment intensity of English and Arabic phrases. In Proceedings of the 10th International Workshop on Semantic Evaluation (SemEval-2016), pages 42-51, San Diego, California. Association for Computational Linguistics.
+Svetlana Kiritchenko and Saif M. Mohammad. 2016a. Capturing reliable fine-grained sentiment associations by crowdsourcing and best-worst scaling. In Proceedings of the 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 811-817, San Diego, California. Association for Computational Linguistics.
+Svetlana Kiritchenko and Saif M. Mohammad. 2016b. Sentiment composition of words with opposing polarities. In Proceedings of the 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 1102-1108, San Diego, California. Association for Computational Linguistics.
+Svetlana Kiritchenko, Xiaodan Zhu, Colin Cherry, and Saif Mohammad. 2014. NRC-Canada-2014: Detecting aspects and sentiment in customer reviews. In Proceedings of the 8th International Workshop on Semantic Evaluation (SemEval 2014), pages 437-442, Dublin, Ireland. Association for Computational Linguistics.
+
+Tassilo Klein and Moin Nabi. 2020. Contrastive self-supervised learning for commonsense reasoning. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7517-7523, Online. Association for Computational Linguistics.
+Angela Lai, Megan A. Brown, James Bisbee, Richard Bonneau, Joshua A. Tucker, and Jonathan Nagler. 2022. Estimating the ideology of political youtube videos.
+Quentin Lhoest, Albert Villanova del Moral, Yacine Jernite, Abhishek Thakur, Patrick von Platen, Suraj Patil, Julien Chaumont, Mariama Drame, Julien Plu, Lewis Tunstall, Joe Davison, Mario Šaško, Gunjan Chhablani, Bhavitvya Malik, Simon Brandeis, Teven Le Scao, Victor Sanh, Canwen Xu, Nicolas Patry, Angelina McMillan-Major, Philipp Schmid, Sylvain Gugger, Clément Delangue, Theo Matussière, Lysandre Debut, Stas Bekman, Pierrick Cistac, Thibault Goehringer, Victor Mustar, François Lagunas, Alexander Rush, and Thomas Wolf. 2021. Datasets: A community library for natural language processing. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 175-184, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. RoBERTa: A robustly optimized BERT pretraining approach.
+Shayne Longpre, Yu Wang, and Chris DuBois. 2020. How effective is task-agnostic data augmentation for pretrained transformers? In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 4401–4411, Online. Association for Computational Linguistics.
+Tim Loughran and Bill McDonald. 2011. When is a liability not a liability? textual analysis, dictionaries, and 10-ks. The Journal of Finance, 66(1):35-65.
+Xuan Lu and Qiaozhu Mei. 2022. Covid-core twitter dataset. Retrieved from https://midas.umich.edu/twitter-decahose-data/. Accessed: 2022-08-28.
+Pekka Malo, Ankur Sinha, Pekka Korhonen, Jyrki Wallenius, and Pyry Takala. 2014. Good debt or bad debt: Detecting semantic orientations in economic texts. Journal of the Association for Information Science and Technology, 65(4):782-796.
+C. Martindale. 1975. The Romantic Progression: The Psychology of Literary History. A Halsted Press Book. Hemisphere Publishing Corporation.
+George A. Miller. 1995. Wordnet: A lexical database for english. Commun. ACM, 38(11):39-41.
+
+Saif Mohammad. 2011. Even the abstract have color: Consensus in word-colour associations. In Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies, pages 368-373, Portland, Oregon, USA. Association for Computational Linguistics.
+Saif Mohammad. 2018a. Obtaining reliable human ratings of valence, arousal, and dominance for 20,000 English words. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 174-184, Melbourne, Australia. Association for Computational Linguistics.
+Saif Mohammad. 2018b. Word affect intensities. In Proceedings of the Eleventh International Conference on Language Resources and Evaluation (LREC 2018), Miyazaki, Japan. European Language Resources Association (ELRA).
+Saif M. Mohammad and Svetlana Kiritchenko. 2015. Using hashtags to capture fine emotion categories from tweets. Computational Intelligence, 31(2):301-326.
+Saif M. Mohammad and Peter D. Turney. 2013. Crowdsourcing a word-emotion association lexicon. Computational Intelligence, 29(3):436-465.
+Antonio Moreno-Ortiz, Javier Fernandez-Cruz, and Chantal Pérez Chantal Hernández. 2020. Design and evaluation of SentiEcon: a fine-grained economic/financial sentiment lexicon from a corpus of business news. In Proceedings of the Twelfth Language Resources and Evaluation Conference, pages 5065–5072, Marseille, France. European Language Resources Association.
+Dat Quoc Nguyen, Thanh Vu, and Anh Tuan Nguyen. 2020. BERTweet: A pre-trained language model for English tweets. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 9-14, Online. Association for Computational Linguistics.
+Nuno Oliveira, Paulo Cortez, and Nelson Areal. 2016. Stock market sentiment lexicon acquisition using microblogging data and statistical measures. Decision Support Systems, 85:62-73.
+PeaceTech Lab. 2022. Our hate speech lexicons. Retrieved from https://www.peacetechlab.org/ hate-speech-lexicons. Accessed: 2022-08-28.
+Kathryn Pearson and Logan Dancey. 2011. Speaking for the underrepresented in the house of representatives: Voicing women's interests in a partisan era. Politics & Gender, 7(4):493-519.
+Kevin Quealy. 2021. The complete list of trump's twitter insults (2015-2021). Retrieved from https://www.nytimes.com/interactive/2021/01/19/upshot/trump-complete-insult-list.html. Accessed: 2022-08-28.
+
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140):1-67.
+Sara Rosenthal, Preslav Nakov, Svetlana Kiritchenko, Saif Mohammad, Alan Ritter, and Veselin Stoyanov. 2015. SemEval-2015 task 10: Sentiment analysis in Twitter. In Proceedings of the 9th International Workshop on Semantic Evaluation (SemEval 2015), pages 451-463, Denver, Colorado. Association for Computational Linguistics.
+Rico Sennrich, Barry Haddow, and Alexandra Birch. 2016. Neural machine translation of rare words with subword units. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1715-1725, Berlin, Germany. Association for Computational Linguistics.
+Kashish Ara Shakil, Kakh Kashan Tabassum, Fawziah S. Alqahtani, and Mudasir Ahmad Wani. 2021. Analyzing user digital emotions from a holy versus non-pilgrimage city in saudi arabia on twitter platform. Applied Sciences, 11(15).
+Connor Shorten, Taghi M. Khoshgoftaar, and Borko Furht. 2021. Text data augmentation for deep learning. Journal of Big Data, 8.
+Alexandra A. Siegel, Evgenii Nikitin, Pablo Barberá, Joanna Sterling, Bethany Pullen, Richard Bonneau, Jonathan Nagler, and Joshua A. Tucker. 2021. Trumping hate on twitter? online hate speech in the 2016 u.s. election campaign and its aftermath. Quarterly Journal of Political Science, 16(1):71-104.
+Almog Simchon, William J Brady, and Jay J Van Bavel. 2022. Troll and divide: the language of online polarization. *PNAS Nexus*, 1(1). Pgac019.
+Swapna Somasundaran, Josef Ruppenhofer, and Janyce Wiebe. 2007. Detecting arguing and sentiment in meetings. In Proceedings of the 8th SIGdial Workshop on Discourse and Dialogue, pages 26-34, Antwerp, Belgium. Association for Computational Linguistics.
+Jacopo Staiano and Marco Guerini. 2014. Depeche mood: a lexicon for emotion analysis from crowd annotated news. In Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 427-433, Baltimore, Maryland. Association for Computational Linguistics.
+Varsha Suresh and Desmond Ong. 2021. Not all negatives are equal: Label-aware contrastive loss for fine-grained text classification. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 4381-4394, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+
+Zhanna Terechshenko, Fridolin Linder, Vishakh Padmakumar, Michael Liu, Jonathan Nagler, Joshua A. Tucker, and Richard Bonneau. 2021. A comparison of methods in political science text classification: Transfer learning language models for politics.
+Paul Thompson, John McNaught, Simonetta Montemagni, Nicoletta Calzolari, Riccardo del Gratta, Vivian Lee, Simone Marchi, Monica Monachini, Piotr Pezik, Valeria Quochi, CJ Rupp, Yutaka Sasaki, Giulia Venturi, Dietrich Rebholz-Schuhmann, and Sophia Ananiadou. 2011. The BioLexicon: a largescale terminological resource for biomedical text mining. BMC Bioinformatics, 12(1).
+Laurens van der Maaten and Geoffrey Hinton. 2008. Visualizing data using t-sne. Journal of Machine Learning Research, 9(86):2579-2605.
+Isabelle van der Vegt, Maximilian Mozes, Bennett Kleinberg, and Paul Gill. 2021. The grievance dictionary: Understanding threatening language use. Behavior Research Methods.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. 2018. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In Proceedings of the 2018 EMNLP Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pages 353-355, Brussels, Belgium. Association for Computational Linguistics.
+Mudasir Ahmad Wani, Nancy Agarwal, Suraiya Jabin, and Syed Zeeshan Hussain. 2018. User emotion analysis in conflicting versus non-conflicting regions using online social networks. Telematics and Informatics, 35(8):2326-2336.
+Michael Weaver. 2019. "Judge Lynch" in the court of public opinion: Publicity and the de-legitimation of lynching. American Political Science Review, 113(2):293-310.
+Jason Wei and Kai Zou. 2019. EDA: Easy data augmentation techniques for boosting performance on text classification tasks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 6382-6388, Hong Kong, China. Association for Computational Linguistics.
+Yandong Wen, Kaipeng Zhang, Zhifeng Li, and Yu Qiao. 2016. A discriminative feature learning approach for deep face recognition. In Computer Vision – ECCV 2016, pages 499–515, Cham. Springer International Publishing.
+Cynthia Whissell. 2009. Using the revised dictionary of affect in language to quantify the emotional undertones of samples of natural language. Psychological Reports, 105(2):509-521. PMID: 19928612.
+
+Cynthia M. Whissell. 1989. Chapter 5 - the dictionary of affect in language. In Robert Plutchik and Henry Kellerman, editors, The Measurement of Emotions, pages 113-131. Academic Press.
+
+Tobias Widmann and Maximilian Wich. 2022. Creating and comparing dictionary, word embedding, and transformer-based models to measure discrete emotions in german political text. Political Analysis, page 1-16.
+
+Janyce Wiebe and Rada Mihalcea. 2006. Word sense and subjectivity. In Proceedings of the 21st International Conference on Computational Linguistics and 44th Annual Meeting of the Association for Computational Linguistics, pages 1065-1072, Sydney, Australia. Association for Computational Linguistics.
+
+Theresa Wilson, Janyce Wiebe, and Paul Hoffmann. 2005. Recognizing contextual polarity in phrase-level sentiment analysis. In Proceedings of Human Language Technology Conference and Conference on Empirical Methods in Natural Language Processing, pages 347-354, Vancouver, British Columbia, Canada. Association for Computational Linguistics.
+
+Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Russ R Salakhutdinov, and Quoc V Le. 2019. Xlnet: Generalized autoregressive pretraining for language understanding. In Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc.
+
+Lori Young and Stuart Soroka. 2012. Affective news: The automated coding of sentiment in political texts. Political Communication, 29(2):205-231.
+
+Marcos Zampieri, Preslav Nakov, Sara Rosenthal, Pepa Atanasova, Georgi Karadzhov, Hamdy Mubarak, Leon Derczynski, Zeses Pitenis, and Căgni Čoltekin. 2020. SemEval-2020 task 12: Multilingual offensive language identification in social media (OffensEval 2020). In Proceedings of the Fourteenth Workshop on Semantic Evaluation, pages 1425-1447, Barcelona (online). International Committee for Computational Linguistics.
+
+Kaitlyn Zhou, Kawin Ethayarajh, Dallas Card, and Dan Jurafsky. 2022. Problems with cosine as a measure of embedding similarity for high frequency words. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 401-423, Dublin, Ireland. Association for Computational Linguistics.
+
+# A Appendix
+
+# A.1 Gunel et al. (2021)'s Supervised Contrastive Learning Objective
+
+Equation 4 is the supervised contrastive learning objective from Gunel et al. (2021). The dictionary-assisted supervised contrastive learning objective in Equation 1 is similar to Equation 4 except Equation
+
+1 is extended to include the keyword-simplified text.
+
+$$
+\begin{array}{l} \mathcal {L} _ {S C L} = \sum_ {i = 1} ^ {N} - \frac {1}{N _ {y _ {i}} - 1} \times \\ \sum_ {j = 1} ^ {N} \mathbb {1} _ {i \neq j} \mathbb {1} _ {y _ {i} = y _ {j}} \log \left[ \frac {\exp \left(\Phi \left(x _ {i}\right) \cdot \Phi \left(x _ {j}\right) / \tau\right)}{\sum_ {k = 1} ^ {N} \mathbb {1} _ {i \neq k} \exp \left(\Phi \left(x _ {i}\right) \cdot \Phi \left(x _ {k}\right) / \tau\right)} \right] \tag {4} \\ \end{array}
+$$
+
+# A.2 Examples of Dictionaries and Lexicons
+
+Table 4 contains a sample of dictionaries across various use cases and academic fields that can be potentially used with DASCL. There is no particular order to the dictionaries, with similar dictionaries clustered together. We did not include any non-open source dictionaries.
+
+# A.3 Additional Information for the Few-Shot Learning Experiments with SST-2
+
+# A.3.1 Data Description: Few-Shot Training Sets, Validation Set, and Test Set
+
+The SST-2 dataset was downloaded using Hugging Face's Datasets library (Lhoest et al., 2021). The test set from SST-2 does not contain any labels, so we use the validation set from SST-2 as our test set. We create our own validation set by randomly sampling a dataset equivalent in size to the original validation set. Our validation set and few-shot learning sets were sampled with no consideration to the label distributions of the original training or validation sets.
+
+When $N = 20$ , there are 11 positive examples and 9 negative examples. When $N = 100$ , there are 60 positive examples and 40 negative examples. When $N = 1000$ , there are 558 positive examples and 442 negative examples. Our validation set has 486 positive examples and 386 negative examples. Lastly, our test set has 444 positive examples and 428 negative examples.
+
+# A.3.2 Text Preprocessing Steps
+
+The only text preprocessing step taken is that nonASCII characters are removed from the dataset. The text is tokenized using a byte-level BPE tokenizer (Liu et al., 2019).
+
+# A.3.3 Dictionaries Used During Keyword Simplification
+
+We used the opinion lexicon from Hu and Liu (2004). This lexicon consists of two dictionaries: one with all positive unigrams and one with all negative unigrams. There are 2,006 positive words
+
+| Dictionary Name | Type of Words or Phrases | Source |
| Opinion Lexicon | Positive/negative sentiment | Hu and Liu (2004) |
| Lexicoder Sentiment Dictionary | Positive/negative sentiment | Young and Soroka (2012) |
| SentiWordNet | Sentiment | Baccianella et al. (2010) |
| ANEW | Emotions | Bradley and Lang (1999) |
| EmoLex | Emotions | Mohammad and Turney (2013) |
| DepecheMood | Emotions | Staiano and Guerini (2014) |
| Moodbook | Emotions | Wani et al. (2018) |
| Moral & Emotion Dictionaries | Moralization and Emotions | Brady et al. (2017) |
| Emotion Intensity Lexicon | Emotion intensity | Mohammad (2018b) |
| VAD Lexicon | Valence, arousal, and dominance of words | Mohammad (2018a) |
| SCL-NMA | Negators, modals, degree adverbs | Kiritchenko and Mohammad (2016a) |
| SCL-OPP | Sentiment of mixed polarity phrases | Kiritchenko and Mohammad (2016b) |
| Dictionary of Affect in Language | Affect of English words | Whissell (1989, 2009) |
| Spanish DAL | Affect of Spanish words | Dell' Amerlina Ríos and Gravano (2013) |
| Subjectivity Lexicon | Subjectivity clues | Wilson et al. (2005) |
| Subjectivity Sense Annotations | Subjectivity disambiguation | Wiebe and Mihalcea (2006) |
| Arguing Lexicon | Patterns representing arguing | Somasundaran et al. (2007) |
| +/- Effect Lexicon | Positive/negative effects on entities | Choi and Wiebe (2014) |
| AEELex | Arabic and English emotion | Shakil et al. (2021) |
| Discrete Emotions Dictionary | Emotions in news content | Fioroni et al. (2022) |
| Yelp/Amazon Reviews Dictionaries | Sentiments in reviews | Kiritchenko et al. (2014) |
| VADER | Sentiments on social media | Hutto and Gilbert (2014) |
| English Twitter Sentiment Lexicon | Sentiments on social media | Rosenthal et al. (2015) |
| Arabic Twitter Sentiment Lexicon | Sentiments on social media | Kiritchenko et al. (2016) |
| Hashtag Emotion Lexicon | Emotions associated with Twitter hashtags | Mohammad and Kiritchenko (2015) |
| Political Polarization Dictionary | Political polarizing language | Simchon et al. (2022) |
| ed8 | Affective language in German political text | Widmann and Wich (2022) |
| Policy Agendas Dictionary | Keywords by policy area | Albaugh et al. (2013) |
| "Women" Terms | Terms related to the category "women" | Pearson and Dancey (2011) |
| Trump's Twitter Insults | Insults used by President Trump | Quealy (2021) |
| Hate Speech Lexicon | Hate speech | Davidson et al. (2017) |
| PeaceTech Lab's Hate Speech Lexicons | Hate speech | PeaceTech Lab (2022) |
| Hatebase | Hate speech | Hatebase (2022) |
| Hurtlex | Hate speech | Bassignana et al. (2018) |
| Hate on Display Hate Symbols | Hate speech and symbols | American Defamation League (2022) |
| Hate speech on Twitter | Hate speech on Twitter | Siegel et al. (2021) |
| Reddit hate lexicon | Hate speech on Reddit | Chandrasekharan et al. (2017) |
| Pro/Anti-Lynching | Pro/anti-lynching terms | Weaver (2019) |
| Grievance Dictionary | Terms related to grievance | van der Vegt et al. (2021) |
| Economic Sentiment Terms | Economic sentiment in newspapers | Hopkins et al. (2017) |
| Loughran-McDonald Dictionary | Financial sentiment | Loughran and McDonald (2011) |
| SentiEcon | Financial and economic sentiment | Moreno-Ortiz et al. (2020) |
| Financial Phrase Bank | Phrases expressing financial sentiment | Malo et al. (2014) |
| Stock Market Sentiment Lexicon | Stock market sentiment | Oliveira et al. (2016) |
| BioLexicon | Linguistic information of biomedical terms | Thompson et al. (2011) |
| SentiHealth | Health-related sentiment | Asghar et al. (2016) |
| MEDLINE Abbreviations | Abbreviations from medical abstracts | Chang et al. (2002) |
| COVID-CORE Keywords | COVID-19 keywords on Twitter | Lu and Mei (2022) |
| PSi Lexicon | Performance studies keywords | Georgelou et al. (2017) |
| Concreteness Ratings | Concreteness of words and phrases | Brysbaert et al. (2013) |
| Word-Colour Association Lexicon | Word-color associations | Mohammad (2011) |
| Regressive Imagery Dictionary | Primordial vs. conceptual thinking | Martindale (1975) |
| Empath | Various lexical categories | Fast et al. (2016) |
| WordNet | Various lexical categories | Miller (1995) |
+
+Table 4: A sample of dictionaries that can potentially be used with DASCL. There is no particular order to the dictionaries, with similar dictionaries clustered together. We did not include any non-open source dictionaries.
+
+and 4,783 negative words. We replaced the positive words with the token “”. We replaced the negative words with the token “”.
+
+# A.3.4 Number of Parameters and Runtime
+
+This experiment uses the ROBERTABASE pretrained language model, which contains 125 million parameters (Liu et al., 2019). When using DASCL, we also had an additional temperature parameter, $\tau$ , that was directly optimized. With the hyperparameters described in Section A.3.5 and using an NVIDIA V100 GPU, it took approximately 2.1 seconds to train over 40 batches using cross-entropy (CE) alone, 2.2 seconds to train over 40 batches using CE+SCL, and 3.3 seconds to train over 40 batches using CE+DASCL.
+
+# A.3.5 Hyperparameter Selection and Configuration Details
+
+We take our hyperparameter configuration directly from Gunel et al. (2021). For each configuration, we set the learning rate to $1 \times 10^{-5}$ and used a batch size of 16. When using the SCL objective, in line with Gunel et al. (2021), we set $\lambda = 0.9$ and $\tau = 0.3$ . When using the DASCL objective, we also set $\lambda = 0.9$ and initialized $\tau = 0.3$ . We trained for 100 epochs for all few-shot learning settings.
+
+# A.3.6 Model Evaluation Details
+
+The model from the epoch with the highest accuracy over our own validation set was chosen as the final model for each random seed. We report accuracy, which is the main metric of interest with this benchmark, and average precision. Average precision is used to summarily quantify the precision-recall tradeoff, and is viewed as the area under the precision-recall curve (Davis and Goadrich, 2006). Average precision is defined as
+
+$$
+A P = \sum_ {n} \left(R _ {n} - R _ {n - 1}\right) P _ {n}
+$$
+
+where $P_{n}$ and $R_{n}$ are the precision and recall at the nth threshold.
+
+# A.3.7 Results over the Validation Set
+
+Table 5 reports the accuracy and the average precision over the validation set for the SST-2 few-shot setting experiments. The validation set was used for model selection, so the reported results over the validation set are from the model with the highest accuracy achieved on the validation set across the 100 epochs.
+
+| Loss | N | Accuracy | Avg. Precision |
| CE | 20 | .680 ± .043 | .768 ± .062 |
| CE w/ DA | 20 | .668 ± .025 | .729 ± .034 |
| CE+SCL | 20 | .707 ± .049 | .797 ± .060 |
| CE+DASCL | 20 | .743 ± .016 | .839 ± .023 |
| CE+DASCL w/ DA | 20 | .700 ± .048 | .765 ± .061 |
| CE | 100 | .832 ± .015 | .905 ± .021 |
| CE w/ DA | 100 | .849 ± .023 | .915 ± .027 |
| CE+SCL | 100 | .848 ± .020 | .905 ± .029 |
| CE+DASCL | 100 | .872 ± .010 | .942 ± .010 |
| CE+DASCL w/ DA | 100 | .842 ± .020 | .927 ± .010 |
| CE | 1000 | .900 ± .005 | .958 ± .010 |
| CE w/ DA | 1000 | .905 ± .006 | .959 ± .005 |
| CE+SCL | 1000 | .904 ± .038 | .958 ± .016 |
| CE+DASCL | 1000 | .907 ± .004 | .961 ± .011 |
| CE+DASCL w/ DA | 1000 | .908 ± .005 | .965 ± .008 |
+
+Table 5: Accuracy and average precision over the SST-2 validation set in few-shot learning settings. Results are averages over 10 random seeds with standard deviations reported.
+
+# A.3.8 t-SNE Plots of the Learned Classifier Token Embeddings for the Test Set, N = 20
+
+We use t-SNE (van der Maaten and Hinton, 2008) plots to visualize the learned classifier token embeddings, “ $\langle \mathrm{s} \rangle$ ”, over the SST-2 test set when using the cross-entropy objective alone, using the cross-entropy objective with the supervised contrastive learning (SCL) objective (Gunel et al., 2021), and using the cross-entropy objective with the dictionary-assisted supervised contrastive learning (DASCL) objective. These plots are in Figure 3. We see that DASCL draws embeddings of the same class closer and pushes embeddings of different classes farther apart compared to using cross-entropy alone or using cross-entropy with SCL.
+
+# A.4 Additional Information for the New York Times Articles about the Economy Experiments
+
+# A.4.1 Data Description: Few-Shot Training Set, Validation Set, and Test Set
+
+The data for the New York Times articles was downloaded from https://dataverse.harvard.edu/dataset.xhtml?persistentId $\equiv$ doi:
+
+10.7910/DVN/MXKRDE. The test set was created using the replication files included at the link. In the original code, there was an error with overlapping training and test sets. We removed the duplicated observations from the training set. Because a single article could be annotated multiple times by different annotators, our validation set was created
+
+
+(a) CE
+
+
+(b) $\mathrm{CE + SCL}$
+
+
+(c) $\mathrm{CE + DASCL}$
+Figure 3: t-SNE plots of the classifier token embeddings on the SST-2 test set fine-tuned using a training set size of 20. The loss configuration is noted below each plot. Blue are negative examples and red are positive examples.
+
+using $15\%$ of the unique number of articles in the training data. 452 of the 1,317 labeled articles in the validation set are labeled positive. For our few-shot training sets, when $N = 100$ , there were 41 positive examples. When $N = 1000$ , there were 363 positive examples. Our validation set and few-shot learning sets were sampled with no consideration to the label distributions of the original training or validation sets.
+
+# A.4.2 Text Preprocessing Steps
+
+The only preprocessing was removing HTML tags that occasionally appeared in the text. The text is tokenized using a byte-level BPE tokenizer.
+
+# A.4.3 Dictionaries Used During Keyword Simplification
+
+We used two sets of dictionaries during keyword simplification. We first used Lexicoder, downloaded from http://www.snsoroka.com/data-lexicoder/. It is a dictionary specifically designed to study sentiment in news coverage (Young and Soroka, 2012). The dictionary is split into four separate sub-dictionaries: positive words, negative words, "negative" positive words (e.g., "not great"), and "negative" negative words (e.g., "not bad"). There are 1,709 positive words, 2,858 negative words, 1,721 negative positive words, and 2,860 negative negative words. We replaced positive words and negative negative words with the token "". We replaced the negative economic words with the token "".
+
+# A.4.4 Number of Parameters and Runtime
+
+This experiment uses the ROBERTABASE pretrained language model, which contains 125 million parameters (Liu et al., 2019). When using DASCL, we also had an additional temperature parameter, $\tau$ , that was directly optimized. With the
+
+hyperparameters described in Section A.4.5 and using an NVIDIA V100 GPU, it took approximately 5.7 seconds to train over 40 batches using cross-entropy (CE) alone, 5.7 seconds to train over 40 batches using $\mathrm{CE + SCL}$ , and 10.7 seconds to train over 40 batches using $\mathrm{CE + DASCL}$ .
+
+# A.4.5 Hyperparameter Selection and Configuration Details
+
+We selected hyperparameters using the validation set. We searched over the learning rate and the temperature initialization; we used $\lambda = 0.9$ for all loss configurations involving contrastive learning. We used a batch size of 8 because of resource constraints. We fine-tuned ROBERTABASE for 5 epochs.
+
+For the learning rate, we searched over $\{5 \times 10^{-6}, 1 \times 10^{-5}, 2 \times 10^{-5}\}$ ; for the temperature, $\tau$ , initialization, we searched over $\{0.07, 0.3\}$ . We fine-tuned the model and selected the model from the epoch with the highest accuracy. We repeated this with three random seeds, and selected the hyperparameter configuration with the highest average accuracy. We used accuracy as the criterion because Barbera et al. (2021) used accuracy as the primary metric of interest. The final learning rate across all loss configurations was $5 \times 10^{-6}$ . The final $\tau$ initialization for both SCL and DASCL loss configurations was 0.07. We used these same hyperparameters when we limited the training set to 100 and 1,000 labeled examples.
+
+# A.4.6 Model Evaluation Details
+
+During fine-tuning, the model from the epoch with the highest accuracy over the validation set was chosen as the final model for each random seed. We report accuracy, which is the main metric of interest with this dataset, and average precision. For a definition of average precision, see Section A.3.6.
+
+The results in Table 2 for logistic regression using the full training set differ slightly from their paper because of an error in overlapping training and test sets in the original splits.
+
+# A.4.7 Additional Classification Metrics: Precision and Recall
+
+Table 6 contains additional classification metrics—precision and recall—for the test set when using 100, 1,000, and all labeled examples from the training set for fine-tuning.
+
+| Loss | N | Precision | Recall |
| L2 Logit | 100 | .000 | .000 |
| CE | 100 | .646 ± .079 | .359 ± .126 |
| CE+DA | 100 | .656 ± .096 | .312 ± .170 |
| SCL | 100 | .000 ± .000 | .000 ± .000 |
| DASCL | 100 | .653 ± .044 | .519 ± .055 |
| DASCL+DA | 100 | .690 ± .051 | .475 ± .093 |
| L2 Logit | 1000 | .542 | .160 |
| CE | 1000 | .670 ± .028 | .526 ± .074 |
| CE+DA | 1000 | .658 ± .029 | .527 ± .089 |
| SCL | 1000 | .674 ± .017 | .543 ± .046 |
| DASCL | 1000 | .684 ± .032 | .575 ± .069 |
| DASCL+DA | 1000 | .682 ± .036 | .592 ± .062 |
| L2 Logit | Full | .689 | .315 |
| CE | Full | .690 ± .036 | .663 ± .055 |
| CE+DA | Full | .696 ± .033 | .643 ± .056 |
| SCL | Full | .700 ± .036 | .652 ± .053 |
| DASCL | Full | .709 ± .021 | .640 ± .041 |
| DASCL+DA | Full | .718 ± .031 | .628 ± .060 |
+
+Table 6: Precision and recall over the economic media test set (Barberá et al., 2021) when using 100, 1000, and all labeled examples from the training set for fine-tuning. Except for the logistic regression model, results are averages over 10 random seeds with standard deviations reported.
+
+# A.4.8 Results over the Validation Set
+
+Table 7 reports the accuracy, precision, recall, and average precision over the validation set for the economic media data. The validation set was used for model selection, so the reported results over the validation set are from the model with the highest accuracy achieved on the validation set across the 5 epochs.
+
+# A.4.9 t-SNE Plots of the Learned Classifier Token Embeddings for the Test Set
+
+We use t-SNE plots to visualize the learned classifier token embeddings, “”, over the New York Times articles about the economy test set when using the cross-entropy objective alone, using the cross-entropy objective with the supervised contrastive learning (SCL) objective (Gunel et al., 2021), and using the cross-entropy objective with the dictionary-assisted supervised contrastive learning (DASCL) objective. These plots are in Figure 4. We see that DASCL pushes embeddings of different classes farther apart compared to using cross-entropy alone or using cross-entropy with SCL.
+
+# A.5 Additional Information for the AbusEval Experiments
+
+# A.5.1 Data Description: Few-Shot Training Set, Validation Set, and Test Set
+
+The data was downloaded from https://github. com/tommasoc80/AbuseEval. Because there was no validation set, we created our own validation set by sampling $15\%$ of the training set. 399 of the 1,986 tweets in the validation set are labeled abusive. For our few-shot training sets, when $N = 100$ , 17 tweets are labeled abusive. When $N = 1000$ , 210 tweets are labeled abusive. Our validation set and few-shot learning sets were sampled with no consideration to the label distributions of the original training or validation sets.
+
+# A.5.2 Text Preprocessing Steps
+
+We preprocessed the text of the tweets in the following manner: we removed all HTML tags, removed all URLs (even the anonymized URLs), removed the anonymized @ tags, removed the retweet ("RT") tags, and removed all "&" tags. The text is tokenized using the WordPiece tokenizer (Devlin et al., 2019).
+
+# A.5.3 Dictionaries Used During Keyword Simplification
+
+We used two sets of dictionaries during keyword simplification. For the first dictionary, we used Lexicoder. For a description of the Lexicoder dictionary, see Section A.4.3. We used the same token-replacements as described in Section A.4.3.
+
+The second dictionary used was a dictionary of "us" and "them" pronouns. These pronouns are intended to capture directed or indirected abuse. The "us" pronouns are "we're", "we'll", "we'd", "we've", "we", "me", "us", "ours", and "let's". The "them" pronouns are "you're", "you've", "you'll", "you'd", "yours", "your", "you", "theirs", "their", "they're", "they", "them", "people", "men", "women", "man", "woman", "mob", "y'all", and "rest." This dictionary is loosely based on suggested words found in Alorainy et al. (2019).
+
+# A.5.4 Number of Parameters and Runtime
+
+This experiment uses the BERTBASE-UNCASED pretrained language model, which contains 110 million parameters (Liu et al., 2019). When using DASCL, we also had an additional temperature parameter, $\tau$ , that was directly optimized. With the hyperparameters described in Section A.5.5 and using an NVIDIA V100 GPU, it took approximately
+
+| Loss | Accuracy | Precision | Recall | Avg. Precision |
| CE | .723 ± .004 | .644 ± .022 | .438 ± .054 | .605 ± .007 |
| CE w/ DA | .726 ± .004 | .662 ± .035 | .423 ± .059 | .607 ± .007 |
| CE+SCL | .727 ± .003 | .659 ± .037 | .438 ± .065 | .611 ± .006 |
| CE+DASCL | .724 ± .006 | .655 ± .020 | .416 ± .037 | .610 ± .007 |
| CE+DASCL w/ DA | .724 ± .004 | .662 ± .031 | .406 ± .051 | .609 ± .006 |
+
+Table 7: Accuracy, precision, recall, and average precision over the validation set for economic media (Barberá et al., 2021). Results are averages over 10 random seeds with standard deviations reported.
+
+
+
+
+
+
+(a) CE
+(b) $\mathrm{CE} + \mathrm{SCL}$
+(c) $\mathrm{CE + DASCL}$
+Figure 4: t-SNE plots of the classifier token embeddings on the New York Times articles about the economy test set fine-tuned using the full training set. The loss configuration is noted below each plot. Blue are negative examples and red are positive examples.
+
+2.6 seconds to train over 40 batches using cross-entropy (CE) alone and 4.9 seconds to train over 40 batches using CE+DASCL.
+
+# A.5.5 Hyperparameter Selection and Configuration Details
+
+We selected hyperparameters using the validation set. We searched over the learning rate and the temperature initialization; again, we used $\lambda = 0.9$ for all loss configurations involving contrastive learning. In line with Caselli et al. (2021), we used a batch size of 32. We fine-tuned BERTBASE-UNCASED and HateBERT for 5 epochs.
+
+For the learning rate, we searched over $\{1 \times 10^{-6}, 2 \times 10^{-6}, 3 \times 10^{-6}, 4 \times 10^{-6}, 5 \times 10^{-6}, 1 \times 10^{-5}, 2 \times 10^{-5}\}$ ; for the temperature, $\tau$ , initialization, we searched over $\{0.07, 0.3\}$ . We fine-tuned the model and selected the model from the epoch with the highest F1 over the positive class. We repeated this with three random seeds, and selected the hyperparameter configuration with the highest average F1 over the positive class. We used the F1 score over the positive class as the criterion because it is one of the metrics of interest in Caselli et al. (2021). The final learning rate across all loss configurations was $2 \times 10^{-6}$ . The final $\tau$ initialization for both SCL and DASCL loss configurations was 0.3. We note that our hyperparameter search yielded a different set of hyperparameters from Caselli et al. (2021). We used these same hyperparameters when we limited the training set to 100 and 1,000 labeled examples.
+
+# A.5.6 Model Evaluation Details
+
+During fine-tuning, the model from the epoch with the highest F1 over the validation set was chosen as the final model for each random seed. We report macro F1 and F1, the main metrics of interest with this dataset, and average precision. For a definition of average precision, see Section A.3.6.
+
+# A.5.7 Results over the Validation Set
+
+Table 8 reports the macro F1, F1, and average precision over the validation set for AbusEval. The validation set was used for model selection, so the reported results over the validation set are from the model with the highest F1 achieved on the validation set across the 5 epochs.
+
+# A.5.8 t-SNE Plots of the Learned Classifier Token Embeddings for the Test Set
+
+We use t-SNE plots to visualize the learned classifier token embeddings, “”, over the AbusEval
+
+| Model | Macro F1 | F1, Pos | Avg. Precision |
| BERT | .756 ± .006 | .632 ± .008 | .681 ± .014 |
| HateBERT | .754 ± .009 | .635 ± .008 | .708 ± .005 |
| BERT+
+DASCL | .759 ± .007 | .639 ± .007 | .683 ± .012 |
| HateBERT+
+DASCL | .755 ± .005 | .635 ± .005 | .706 ± .006 |
+
+Table 8: The macro F1, F1, and average precision over the AbusEval validation set (Caselli et al., 2020). Results are averages over 10 random seeds with standard deviations reported.
+
+test set when using BERT and when using BERT with DASCL. These plots are in Figure 5. We see that using DASCL with BERT pushes embeddings of different classes farther apart compared to using BERT alone.
+
+
+(a) BERT
+
+
+(b) BERT with DASCL
+Figure 5: t-SNE plots of the classifier token embeddings on the AbusEval test set fine-tuned using the full training set. The model is noted below each plot. Blue are examples of non-abusive tweets and red are examples of abusive tweets.
\ No newline at end of file
diff --git a/dictionaryassistedsupervisedcontrastivelearning/images.zip b/dictionaryassistedsupervisedcontrastivelearning/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..ffd6a55debebbde24548d60f2279ef28ca76c91a
--- /dev/null
+++ b/dictionaryassistedsupervisedcontrastivelearning/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f10bd5a815eabe142ce814a6f94a19ef7294a5f58528489d510c4eedd7157000
+size 1263217
diff --git a/dictionaryassistedsupervisedcontrastivelearning/layout.json b/dictionaryassistedsupervisedcontrastivelearning/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..994db42312f9c2e9d0e6f9fe3dfbd8b22dd47078
--- /dev/null
+++ b/dictionaryassistedsupervisedcontrastivelearning/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4bd6c46ae677ab4298e59319d0cf73c4d32a0e82b8e8dfdf191ec152dd7aabf0
+size 552572
diff --git a/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_content_list.json b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..7b1d53830b43d19fe0b4579744edfc53549f596f
--- /dev/null
+++ b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4d5a4b864963c1003ea7fba224dd3a3113af528b802a06ca1b455ecf6acd129c
+size 106708
diff --git a/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_model.json b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..ed22d3b0244e0eab52b8584d5398d059184597c2
--- /dev/null
+++ b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c3ec678072654fa56193a39fac2060d2abc44ceb5613048cc1ec17971bda6e6c
+size 126579
diff --git a/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_origin.pdf b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c54a6dda6108a9b1f3cc73829a942abd8a20dbac
--- /dev/null
+++ b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/0b9de31a-e330-433b-b996-a1ca7bf3d3fc_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d7d3c0e6e4a0e2e1b63a2500c111004d1dfefcfa4e793124ff72e0d4b624f4bb
+size 654544
diff --git a/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/full.md b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..89cb97aadb7e323663b3dfe2728859d28958c762
--- /dev/null
+++ b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/full.md
@@ -0,0 +1,420 @@
+# Differentiable Data Augmentation for Contrastive Sentence Representation Learning
+
+Tianduo Wang and Wei Lu
+
+StatNLP Research Group
+
+Singapore University of Technology and Design
+
+{tianduo_wang,luwei}@sutd.edu.sg
+
+# Abstract
+
+Fine-tuning a pre-trained language model via the contrastive learning framework with a large amount of unlabeled sentences or labeled sentence pairs is a common way to obtain high-quality sentence representations. Although the contrastive learning framework has shown its superiority on sentence representation learning over previous methods, the potential of such a framework is under-explored so far due to the simple method it used to construct positive pairs. Motivated by this, we propose a method that makes hard positives from the original training examples. A pivotal ingredient of our approach is the use of prefix that is attached to a pre-trained language model, which allows for differentiable data augmentation during contrastive learning. Our method can be summarized in two steps: supervised prefix-tuning followed by joint contrastive fine-tuning with unlabeled or labeled examples. Our experiments confirm the effectiveness of our data augmentation approach. The proposed method yields significant improvements over existing methods under both semi-supervised and supervised settings. Our experiments under a low labeled data setting also show that our method is more label-efficient than the state-of-the-art contrastive learning methods.
+
+# 1 Introduction
+
+Learning universal and effective sentence representations is an enduring problem in natural language processing (NLP). The objective of learning sentence representations is similar to that of learning word embeddings (Mikolov et al., 2013; Pennington et al., 2014), i.e., we expect the embeddings of sentences with similar semantics to be close to each other, while the embeddings of sentences with different meanings to be sufficiently far away from each other. Recently, we have witnessed the success of pre-trained language models in various NLP
+
+
+Figure 1: Our two-stage tuning strategy.
+
+tasks. However, the quality of the sentence representations directly obtained from non fine-tuned language models remains unsatisfactory (Reimers and Gurevych, 2019; Li et al., 2020).
+
+One approach to addressing this problem is to fine-tune a pre-trained language model via the contrastive learning objective on labeled or unlabeled sentences. Several recent research efforts (Yan et al., 2021; Gao et al., 2021b; Jiang et al., 2022) have shown that a contrastive learning based finetuning stage can produce state-of-the-art results on the sentence embedding learning task.
+
+Some previous contrastive learning works on other modalities, e.g., image (Chen et al., 2020a,b), have shown that an effective data augmentation (DA) method is crucial for the success of contrastive learning. However, due to the discrete nature of language, applying commonly-used sentence augmentation strategies, e.g., word deletion and replacement, over the input sentences for contrastive learning leads to suboptimal results (Gao et al., 2021b). Instead, Gao et al. (2021b) propose to perform data augmentation via dropout, showing that this extremely simple approach can yield better sentence representations than previous DA methods that are based on discrete transformations.
+
+Although this dropout-based DA method outperforms its discrete counterparts, the potential of the contrastive learning framework is under-explored due to its simple treatment of the positive pair construction process. Previous works have shown that contrastive learning benefits from strong data augmentations that can produce hard positives with
+
+meaningful differences. Specifically, Chen et al. (2020a) demonstrate that contrastive learning requires stronger data augmentation than traditional supervised learning. Tian et al. (2020) further show that, for contrastive learning, a good pair of positive instances should only share task-relevant information while discarding irrelevant information as much as possible.
+
+Motivated by this idea, we propose DiffAug, a differentiable data augmentation method for contrastive sentence representation learning. This method prepends two separate prefix modules (Li and Liang, 2021) to a common pre-trained language model. The goal is to obtain hard positive pairs with the help of these two prefix modules for contrastive learning, where supervised signals can be used to guide the tuning process of such prefix modules. Such a design essentially requires us to fine-tune both language model and newly-added prefix. However, how to effectively train them jointly to best serve our sentence representation learning purpose is a non-trivial research question.
+
+Our observations show that, though tempting, it can be undesirable to fine-tune language model and prefix jointly from the beginning of the training process. Rather, we propose an effective two-stage tuning strategy, prefix-tuning followed by joint tuning, as illustrated in Figure 1. Specifically, we argue that it is crucial to perform prefix-tuning first, until a module-compatible state is achieved, before we move to the second stage to perform joint tuning for both modules. Our main contributions can be summarized as follows:
+
+- We propose a novel and effective data augmentation method for contrastive sentence representation learning with the help of prefix modules. We further design a mechanism that allows this module to be carefully optimized with labeled data first, allowing hard positives with meaningful differences to be constructed, which can benefit contrastive learning.
+- Our experiments show that the proposed method achieves the new state-of-the-art results on both semi-supervised and supervised settings. We also investigate the situation when labeled data is scarce. The results demonstrate that our method is more label-efficient than previous contrastive learning methods, showing the robustness of our proposed approach.
+- Our work successfully combines the traditional fine-tuning and prefix-tuning paradigms.
+
+Through extensive analysis we identify the crucial elements required to ensure the success of our proposed approach.
+
+# 2 Background
+
+Our method is based on the state-of-the-art contrastive learning framework proposed by Gao et al. (2021b). We first introduce this framework. Next, we discuss the mechanism of prefix-tuning (Li and Liang, 2021).
+
+# 2.1 The contrastive learning framework
+
+Contrastive learning aims to learn meaningful representations from data by pulling together instances with similar semantic meanings and pushing apart dissimilar ones (Hadsell et al., 2006). The contrastive learning framework that we apply in this work is proposed by Gao et al. (2021b). There are three main components in this framework:
+
+- A data augmentation module $g(\cdot ;\theta)$ that generates positive pairs from a batch of training data with parameters denoted as $\theta$ . Previous contrastive learning works on other modalities (Chen et al., 2020a; Tian et al., 2020) have shown that the meaningful differences between positive pairs will allow the potential of contrastive learning to be better explored. Our work mainly improves this module.
+- A neural network based encoder $f(\cdot ; \phi)$ that maps input data to a representation space with parameters denoted as $\phi$ . For natural language, $f(\cdot ; \phi)$ could be any neural network architecture that is suitable for encoding sentences. For our approach, we follow previous works (Gao et al., 2021b; Jiang et al., 2022), and employ pre-trained language models as $f(\cdot ; \phi)$ , e.g. BERT (Devlin et al., 2019) and RoBERTa (Liu et al., 2019).
+- A contrastive loss function can be defined over a batch of data with size $N$ as follows:
+
+$$
+\mathcal {L} _ {\mathrm {c l}} = - \frac {1}{N} \sum_ {i = 1} ^ {N} \log \frac {\exp \left(\frac {\cos \left(h _ {i , 1} , h _ {i , 2}\right)}{\tau}\right)}{\sum_ {j = 1} ^ {N} \exp \left(\frac {\cos \left(h _ {i , 1} , h _ {j , 2}\right)}{\tau}\right)} \tag {1}
+$$
+
+where $h_{i,1} = f(g(x_i;\theta_1);\phi)$ and $h_{i,2} = f(g(x_i;\theta_2);\phi)$ are the representations of the
+
+augmented instances from the same data $x_{i}$ , $\tau$ is the temperature hyperparameter, and $\cos(\cdot, \cdot)$ is the cosine similarity function. Note that we have two parameters $\theta_{1}$ and $\theta_{2}$ , as we involve two separate data augmentation operations here.
+
+# 2.2 The mechanism of prefix-tuning
+
+Transformer (Vaswani et al., 2017) has become the most crucial component for many pre-trained language models. In this section, we discuss the self-attention module in Transformer and illustrate how prefix-tuning (Li and Liang, 2021) works. The original self-attention layer first maps the input $X \in \mathbb{R}^{L \times d}$ into three matrices, i.e., query $Q \in \mathbb{R}^{L \times d}$ , key $K \in \mathbb{R}^{L \times d}$ , and value $V \in \mathbb{R}^{L \times d}$ where $L$ and $d$ are the input length and hidden dimension respectively. The self-attention function is defined as:
+
+$$
+H = \operatorname {A t t e n t i o n} (Q, K, V) = \operatorname {s o f t m a x} \left(\frac {Q K ^ {T}}{\sqrt {d}}\right) V \tag {2}
+$$
+
+where $H\in \mathbb{R}^{L\times d}$ is the output of the self-attention layer. Prefix-tuning (Li and Liang, 2021) affects the output of the original language model by preponding tunable matrices as key-value pairs. Specifically, in each self-attention layer, two matrices $P_{k}$ , $P_{v}\in \mathbb{R}^{l\times d}$ will be concatenated to the original $K$ and $V$ respectively, where $l$ is the prefix length. Therefore, in prefix-tuning, the self-attention function will become the following:
+
+$$
+\begin{array}{l} H _ {p} = \operatorname {A t t e n t i o n} (Q, [ P _ {k}; K ], [ P _ {v}; V ]) \\ = \operatorname {s o f t m a x} \left(\frac {Q \left[ P _ {k} ; K \right] ^ {T}}{\sqrt {d}}\right) \left[ P _ {v}; V \right] \tag {3} \\ \end{array}
+$$
+
+where $[\cdot ;\cdot ]$ represents the concatenation on the first dimension. Since our method applies prefix for data augmentation, we use $\theta$ to denote the set of tunable matrices $\{(P_k^i,P_v^i)|i = 1,\dots,M\}$ , where $M$ is the number of self-attention layers in the pretrained language model.
+
+# 3 Method
+
+In this section, we describe the proposed data augmentation method, and our two-stage tuning strategy. We then discuss reasons why our proposed approach works.
+
+# 3.1 Differentiable data augmentation
+
+The InfoMin principle (Tian et al., 2020) states that a good pair of positive instances for contrastive learning should be as different as possible while retaining enough useful information relevant to the downstream tasks. Following this principle, we improve the current state-of-the-art contrastive learning framework (Gao et al., 2021b) via prefix (Li and Liang, 2021). We hope the added prefix modules can generate positive pairs with meaningful differences. To formulate this idea, we replace $h_i = f(g(x_i; \theta); \phi)$ with $h_i = f(x_i; \theta, \phi)$ , since the prepended prefix modules can be regarded as a part of the language model.
+
+We initialize the prefix modules randomly following Li and Liang (2021). This step allows the two initial representations returned from the two networks (with two different prefix modules) to be reasonably different. The next question is how to inject task-relevant information into the prefix. Previous works (Conneau et al., 2017; Reimers and Gurevych, 2019) have shown that training encoders with natural language inference (NLI) datasets (Bowman et al., 2015; Williams et al., 2018) via cross entropy loss can enhance the quality of generated sentence embeddings. It motivates us to use this objective to train our prefix modules. Since $\theta$ is initialized randomly, and $\phi$ is obtained from pre-training, we believe directly tuning $\theta$ and $\phi$ together from the beginning may not lead to the optimal results. Instead, we propose a two-stage tuning strategy: during the first stage, we only tune the prefix via cross entropy loss over the NLI dataset with the language model fixed, while in the second stage, we tune $\theta$ and $\phi$ jointly via the contrastive learning framework.
+
+Stage 1: prefix-tuning. There are two main objectives for stage-1 tuning. First, we hope the two prefix modules to have meaningful differences such that they are capable of capturing the relation between NLI sentence pairs. Second, we expect the added prefix modules to be compatible with the original language model, so that they can be trained jointly in stage 2. To fulfill these two objectives, we optimize:
+
+$$
+\min _ {\theta_ {1}, \theta_ {2}} \mathcal {L} _ {\mathrm {c e}} \left(f \left(X _ {p}; \theta_ {1}, \phi\right), f \left(X _ {h}; \theta_ {2}, \phi\right), Y\right) \tag {4}
+$$
+
+where $X_{p}$ and $X_{h}$ represent premise and hypothesis sentences from the NLI dataset respectively, and $Y$ consists of binary labels indicating the relation between sentence pairs formed from $X_{p}$ and
+
+
+(a) Stage 1: prefix-tuning
+
+
+(b) Stage 2: joint tuning
+Figure 2: The proposed DiffAug method has two training stages: (a) use cross entropy loss to make prefix modules capable of capturing the relationship between sentence pairs with the language model fixed; (b) use the contrastive learning objective to optimize both language model and prefix modules.
+
+$X_{h}$ . Here $\theta_{1}$ and $\theta_{2}$ represent the parameters of two prepended prefix modules respectively. The feature vector we use for the cross entropy loss is the concatenation of two sentence representations $u$ and $v$ , as well as their element-wise absolute differences $|u - v|$ following (Reimers and Gurevych, 2019). Stage-1 tuning is illustrated in Figure 2a.
+
+Stage 2: joint tuning. After obtaining a pair of well-trained prefix modules from stage 1, we do contrastive learning in stage-2 tuning. The following objective is optimized:
+
+$$
+\min _ {\theta_ {1}, \theta_ {2}, \phi} \mathcal {L} _ {\mathrm {c l}} \left(f (X; \theta_ {1}, \phi), f (X; \theta_ {2}, \phi)\right) \tag {5}
+$$
+
+Our stage-2 tuning is illustrated in Figure 2b. Previous works (Yan et al., 2021; Li et al., 2020) have shown that adding cross entropy loss on NLI data as an auxiliary loss during unsupervised fine-tuning can enhance the quality of the learned sentence embeddings. We add this auxiliary loss during stage 2 under our semi-supervised setting, and find it further improves the performance. More details about the auxiliary loss are in Appendix E.
+
+# 3.2 Why two-stage tuning works?
+
+In this section, we explain why the proposed two-stage tuning strategy works. From experimental results, we find the performance of contrastive learning is sensitive to the number of training steps in stage 1, and there is an optimal value for this hyperparameter. This phenomenon is consistent for both BERT and RoBERTa. To better understand this phenomenon, we introduce a new concept here: module-compatible state. When we say two modules are in the module-compatible state, we mean these two modules can be tuned together while obtaining satisfactory results after training. Given a set of training hyperparameters (e.g., learning rate
+
+and batch size) and a stage-2 training objective, the extent of module compatibility is closely related to the number of stage-1 training steps. We find there are two countering metrics that determine the optimal stage-1 steps: representation divergence $(\delta)$ and weight convergence $(\kappa)$ .
+
+Representation divergence means the difference of embeddings that are generated from a positive pair. Since the motivation of this work is to design a stronger data augmentation strategy than dropout (Gao et al., 2021b), a larger representation divergence is desired. To measure this metric quantitatively, we use the expected distance between representations generated from positive pairs:
+
+$$
+\delta \triangleq \underset {(x, x ^ {+}) \sim p _ {\text {p o s}}} {\mathbb {E}} | | f (x; \theta_ {1}, \phi) - f (x ^ {+}; \theta_ {2}, \phi) | | _ {2} \tag {6}
+$$
+
+We plot in Figure 3a the trend of $\delta$ as stage 1 proceeds. As a reference, we also plot the representation divergence when dropout is used for data augmentation (Gao et al., 2021b). We can observe that $\delta$ quickly reaches the highest value at around 1,500 steps, and then its value slowly goes down. We performed multiple runs with different random seeds, and found the figures all suggest that the optimal number of steps would be around 1,500. However, though we hope the representations of two positives could be as different as possible due to the InfoMin Principle (Tian et al., 2020), we also found that in practice sometimes it would be beneficial to prolong the first stage with slightly more than 1,500 steps. For example, the optimal number of stage-1 training steps for our semi-supervised model is 2,000. To explain this discrepancy, we now turn to look at the second metric, weight convergence.
+
+The prefix modules are initialized randomly, therefore it is unsurprising to find that the parameters of prefix modules are significantly different from those of the pre-trained language model. Specifically, both prefix and language model's key and value matrices have zero means, but those matrices of language model have a much larger variance than those of prefix. We quantify this difference by measuring the weight convergence $\kappa$ - the $l_{2,1}$ -norm difference between the key-value matrices of prefix and those of language model. The weight convergence between $m$ -th layer's key
+
+
+(a) Representation divergence.
+
+
+(b) Weight convergence.
+Figure 3: The visualization of the relationship between two metrics and stage-1 training steps from the $\mathrm{BERT}_{\mathrm{base}}$ with batch size 128 and learning rate 0.001.
+
+matrix of language model $K^m\in \mathbb{R}^{L\times d}$ and that of prefix $P_{k}^{m}\in \mathbb{R}^{l\times d}$ can be defined as follows:
+
+$$
+\kappa_ {k} ^ {m} \triangleq \frac {1}{L} \| K ^ {m} \| _ {2, 1} - \frac {1}{l} \| P _ {k} ^ {m} \| _ {2, 1} \tag {7}
+$$
+
+where $||\cdot ||_{2,1}$ represents the $l_{2,1}$ -norm. The weight convergence between the value matrices $\kappa_v^m$ is defined similarly. In practice, the overall $\kappa$ is defined as the averaged score over the weight convergence for both key and value matrices on all $M$ self-attention layers:
+
+$$
+\kappa \triangleq \frac {1}{2 M} \sum_ {m = 1} ^ {M} \kappa_ {k} ^ {m} + \kappa_ {v} ^ {m} \tag {8}
+$$
+
+From Figure 3b, we find the difference is monotonically decreasing, which indicates that the distribution gap reduces as stage-1 tuning continues. Previous work (Glorot and Bengio, 2010) has identified that such a parameter distribution gap can block the gradient descent based training, and we show how such distribution gap will affect the selfattention layer in details in Appendix B. Overall, the lower the $\kappa$ , the easier it is for the model to perform stage-2 tuning. This explains why it could be worthwhile to start stage-2 tuning slightly after we have reached the peak for representation divergence – though we have missed the peak, the prolonged stage-1 tuning that leads to an even lower $\kappa$ can potentially make the stage-2 tuning easier.
+
+From the above analysis, we can see the module-compatible state is determined by both $\delta$ and $\kappa$ . A larger $\delta$ will better explore the potential of the contrastive learning framework, while a smaller $\kappa$ will make the stage-2 tuning more stable. An overall good performance is obtained when a module-compatible state is reached. More details about the optimal stage-1 step are in Appendix E.
+
+# 4 Experiments
+
+Following previous works, we mainly conduct experiments on Semantic Textual Similarity (STS) tasks. The results demonstrate the capability of our method on producing high-quality universal sentence representations.
+
+# 4.1 Experimental setup
+
+We conduct experiments with both $\mathrm{BERT}_{\mathrm{base}}$ and $\mathrm{RoBERTa}_{\mathrm{base}}$ , but only present $\mathrm{BERT}_{\mathrm{base}}$ results in this section. The results of $\mathrm{RoBERTa}_{\mathrm{base}}$ can be found in Appendix D. We consider three different settings: unsupervised, semi-supervised, and supervised settings. The unsupervised category contains both contrastive learning based and non-contrastive learning based methods that are trained with unlabeled examples. The semi-supervised setting allows the usage of both labeled and unlabeled data, but labeled data is only used for cross entropy loss. Our supervised setting only considers the supervised contrastive learning methods where the label information from NLI dataset is used for constructing positive and hard negative instances.
+
+Datasets Following previous works, we use two training datasets for the abovementioned settings: one is the unlabeled Wikipedia dataset (Wiki1M) (Gao et al., 2021b) which contains $10^{6}$ sentences sampled from Wikipedia; the other is the labeled NLI dataset combining SNLI (Bowman et al., 2015) and MNLI (Williams et al., 2018). It comprises 275,600 sentence triplets with the format (anchor, entailment, contradiction).
+
+We evaluate our method on seven standard STS datasets: STS tasks 2012-2016 (Agirre et al., 2012, 2013, 2014, 2015, 2016), STS-Benchmark (Cer et al., 2017), and SICK-Relateness (Marelli et al., 2014). The sentence pairs in each dataset are scored from 0 to 5 to indicate the semantic similarity. Following previous works (Gao et al., 2021b; Jiang et al., 2022), we report the Spearman's rank correlation coefficients between the cosine similarity of the learned sentence representations and the golden similarity scores on each dataset.
+
+Baselines We first consider two common methods for obtaining sentence embeddings from BERT: using [CLS] vector and mean pooling. BERT-flow (Li et al., 2020) is an unsupervised post-processing method that transforms the original BERT sentence embedding distribution to a smooth and isotropic Gaussian distribution. Con-
+
+| Method | STS12 | STS13 | STS14 | STS15 | STS16 | STS-B | SICK-R | Avg. |
| Unsupervised methods |
| BERT( [CLS]) | 20.16 | 30.01 | 20.09 | 36.88 | 38.08 | 16.50 | 42.63 | 29.19 |
| BERT( Mean Pooling) | 38.78 | 57.98 | 57.98 | 63.15 | 61.06 | 46.35 | 58.40 | 54.81 |
| BERT-flow | 58.40 | 67.10 | 60.85 | 75.16 | 71.22 | 68.66 | 64.47 | 66.55 |
| ConBERT | 66.07 | 77.40 | 70.32 | 80.91 | 77.29 | 75.78 | 66.91 | 73.53 |
| SimCSE | 68.40 | 82.41 | 74.38 | 80.91 | 78.56 | 76.85 | 72.23 | 76.25 |
| PromptBERT | 71.56 | 84.58 | 76.98 | 84.47 | 80.60 | 81.60 | 69.87 | 78.54 |
| DiffCSE | 72.28 | 84.43 | 76.47 | 83.90 | 80.54 | 80.59 | 71.23 | 78.49 |
| Semi-supervised methods |
| SBERT | 70.97 | 76.53 | 73.19 | 79.09 | 74.30 | 77.03 | 72.91 | 74.89 |
| SBERT-flow | 69.78 | 77.27 | 74.35 | 82.01 | 77.46 | 79.12 | 76.21 | 76.60 |
| ConBERTjoint | 72.60 | 82.40 | 77.64 | 82.82 | 78.37 | 80.03 | 78.20 | 78.87 |
| DiffAug (ours) | 75.28±.0 | 85.20±.2 | 78.57±.0 | 85.20±.2 | 81.01±.3 | 82.42±.3 | 73.24±.5 | 80.13±.1 |
| w/ aux loss | 73.46±.5 | 85.61±.2 | 78.93±.3 | 85.82±.1 | 80.74±.2 | 82.70±.2 | 77.00±.5 | 80.61±.2 |
| Supervised contrastive learning methods |
| SimCSE | 75.30 | 84.67 | 80.19 | 85.40 | 80.82 | 84.25 | 80.39 | 81.57 |
| PromptBERT | 75.48 | 85.59 | 80.57 | 85.99 | 81.08 | 84.56 | 80.52 | 81.97 |
| DiffAug (ours) | 76.92±.7 | 85.17±.2 | 80.81±.4 | 86.91±.5 | 82.52±.1 | 84.32±.5 | 80.27±.2 | 82.42±.0 |
+
+Table 1: Sentence embedding performance on the seven standard STS tasks (Spearman's correlation). The highest results under semi-supervised and supervised settings are highlighted. $\diamond$ : results are from (Reimers and Gurevych, 2019); $\diamond$ : results are re-evaluated by (Gao et al., 2021b); $\clubsuit$ : results are re-evaluated by us using the released code. More details about the re-evaluation are in Appendix C. Other baseline results are from their original papers. All our results in this table are averaged over three different runs (with standard deviation).
+
+SERT (Yan et al., 2021) is an unsupervised contrastive learning method with several data augmentation techniques for sentences. Its unsupervised results can be further improved by incorporating NLI supervision. SimCSE (Gao et al., 2021b) is a contrastive learning framework that uses dropout for data augmentation. Its supervised approach regards the entailment sentence pairs from the NLI dataset as positives, and the contradiction pairs as hard negatives. PromptBERT (Jiang et al., 2022) improves SimCSE by applying effective hard prompts on input sentences. DiffCSE (Chuang et al., 2022) combines the contrastive learning objective with a difference prediction objective which is inspired by equivariant contrastive learning (Dangovski et al., 2021). SBERT (Reimers and Gurevych, 2019) uses BERT with a siamese structure to generate sentence embeddings after learning on NLI data with cross entropy loss. This method can be combined with the post-processing methods, e.g., BERT-flow (Li et al., 2020), to produce better results under the semi-supervised setting.
+
+# 4.2 Main results
+
+We compare our model with previous sentence embedding methods on the standard seven STS
+
+datasets in Table 1. Since our method requires a supervised prefix-tuning stage before the contrastive learning, we only report our results under the semi-supervised and supervised settings. For semi-supervised setting, we also report the results of our method with the auxiliary loss that is mentioned in Section 3.1. From Table 1, we make the following observations:
+
+- The quality of sentence embeddings directly obtained from $\mathrm{BERT}_{\mathrm{base}}$ (both [CLS] vector and mean pooling) without further fine-tuning is poor. This phenomenon and the reasons behind it have been studied extensively (Reimers and Gurevych, 2019; Li et al., 2020; Su et al., 2021).
+- In general, supervised and semi-supervised models are better than unsupervised models, which indicates that the label information in NLI data is beneficial to learning good sentence embeddings.
+- Our method outperforms baselines in both semi-supervised and supervised settings on average. Since our method strictly follows the contrastive learning framework proposed by Gao et al. (2021b) except for the data augmentation module, our improved results confirm that the proposed data augmentation method is effective for contrastive learning.
+
+# 4.3 Training with less labeled data
+
+In this section, we show our method is more label-efficient than the state-of-the-art contrastive learning methods with $\mathrm{BERT}_{\mathrm{base}}$ . The results are presented in Table 2. We find not all the previous contrastive learning methods discuss the semi-supervised setting. However, Yan et al. (2021) proposes several ways of adding supervised signal into their unsupervised contrastive learning, and these methods are also applicable to other unsupervised approaches. Therefore, we re-evaluate previous methods under the semi-supervised setting following (Yan et al., 2021), and produce stronger baselines. The details about the re-implementation can be found in Appendix C. We report the results of our semi-supervised method with auxiliary loss in stage 2. For previous supervised contrastive learning methods that do not discuss the low labeled data condition, we re-evaluate their methods with less labeled data.
+
+To construct the low labeled data settings, we sub-sample $1\%$ ( $\sim 2,756$ ) or $10\%$ ( $\sim 27,560$ ) labeled examples from the full NLI dataset. For each size, we sample 5 sub-datasets and take the average over 3 different runs. Thus, we report the averaged results over 15 models under each low-data setting. Table 2 shows our approach significantly outperforms baselines under all settings. We also notice that the performance gap increases as the number of labeled examples decreases.
+
+We suspect that the advantages of our proposed method in low labeled data situations come from the prefix-tuning in stage 1. Since the baseline methods all fine-tune the whole parameters of the language model, it is easy to overfit when the labeled data is scarce. However, for our method, the amount of added prefix parameters is much smaller (only $0.3\%$ of the parameters in $\mathrm{BERT}_{\mathrm{base}}$ ). Therefore, the overfitting problem can be alleviated.
+
+# 4.4 Ablation study
+
+In this section, we compare several variants of our proposed prefix-based method, and investigate the impact of different parameter-efficient methods for data augmentation and prefix length. More ablation studies (auxiliary loss and stage-1 training steps) are provided in Appendix E. All results are based on the STS-B development set.
+
+Variants of applying prefix. In this work, we propose to use prefix-tuning (Li and Liang, 2021) for data augmentation. Now we investigate the
+
+| Method | Fraction of labeled data |
| 0% | 1% | 10% | 100% |
| Semi-supervised setting |
| SimCSEjoint | 76.25 | 76.45±.6 | 77.46±.6 | 77.73±.6 |
| PromptBERTjoint | 78.54 | 79.26±.3 | 79.65±.3 | 79.81±.1 |
| DiffAug (ours) | - | 80.42±.1 | 80.58±.1 | 80.61±.2 |
| Supervised setting |
| SimCSE | - | 75.26±.4 | 79.04±.2 | 81.58±.1 |
| PromptBERT | - | 78.33±.2 | 80.01±.1 | 81.88±.1 |
| DiffAug (ours) | - | 80.18±.6 | 81.73±.2 | 82.42±.0 |
+
+Table 2: Averaged sentence representation performance on the standard seven STS tasks with different sizes of labeled data. $\hat{\mathbf{\sigma}}$ and $\spadesuit$ are the results of unsupervised SimCSE and PromptBERT respectively. We report these two results from their original papers. All other baseline results are re-evaluated by us.
+
+performance of several variants of the proposed method. The results are presented in Table 3. The amount of added parameters relative to that in $\mathrm{BERT}_{\mathrm{base}}$ is also reported. We select two unsupervised data augmentation methods, i.e., synonym replacement and dropout, as baselines since they are simple yet effective for sentence representation learning.
+
+Our method trains two different prefix modules in stage 1 and jointly tunes both prefixes and language model in stage 2. Here we first consider two variants of applying prefixes: using two identical prefixes (same) and fixing the prefixes during stage 2 (fix). The performance gap between the first variant and our method confirms that contrastive learning performs better when the positives are meaningfully different. The performance drop caused by the second variant validates the necessity of tuning prefix and language model together in stage 2.
+
+To investigate the importance of fine-tuning language model with prefix in stage 2, we consider another prefix variant, i.e., prefix-tuning, which means that only prefix modules will be tuned for both stage 1 and stage 2. The performance gap between our proposed method and the "prefix-tuning" method indicates that optimizing the language model is necessary for obtaining good results on sentence representation learning tasks.
+
+Different parameter-efficient methods as data augmentation module. We also consider other parameter-efficient (PE) methods for data augmentation. Previous work (He et al., 2021) has unified
+
+| Method | # added params (rel. BERTbase) | STS-B dev. |
| Unsupervised methods |
| Synonym replacement♥ | 0 | 77.4 |
| Dropout♥ | 0 | 82.5 |
| Prefix variants (l = 8) |
| Prefix (same) | 0.3% | 85.7 |
| Prefix (fix) | 0.3% | 85.4 |
| Prefix (different, ours) | 0.3% | 86.2 |
| Prefix-tuning (different) | 0.3% | 84.8 |
| Other parameter-efficient methods |
| Adapter (different, r = 4) | 0.3% | 85.6 |
| Adapter (different, r = 64) | 4.8% | 85.1 |
| LoRA (different, r = 4) | 0.3% | 85.4 |
| LoRA (different, r = 64) | 4.8% | 86.1 |
+
+Table 3: Comparison between different methods for data augmentation under the semi-supervised setting. $l$ and $r$ are the prefix length and bottleneck dimension respectively. $\stackrel{\circ}{\vdots}$ : results are from Gao et al. (2021b).
+
+current PE methods under one framework. Hence, it is theoretically possible to transfer the success of our method with prefix-tuning to other PE methods. In this section, we additionally tried two most common and effective methods, i.e., Adapter (Houlsby et al., 2019) and LoRA (Hu et al., 2021) with different bottleneck dimensions. The description of these two methods can be found in Appendix F.
+
+As shown in Table 3, with a small amount of additional parameters (0.3%), data augmentation with distinct prefix modules obtains the highest score on the STS-B development set. Such a phenomena of prefix's effectiveness with small budget of additional parameters has also been observed by both He et al. (2021) and Li and Liang (2021) on textual generation tasks. We believe this is because prefix directly modifies each attention head on the multi-head attention layers, which makes it more expressive than other methods when parameter budget is limited.
+
+We then study whether this conclusion changes if more tunable parameters are added. Table 3 shows that the performance of Adapter drops after having more tunable parameters $(0.3\% \rightarrow 4.8\%)$ , but LoRA performs better (STS-B dev. score improves by 0.7 points) when the bottleneck dimension increases from 4 to 64, though it is still slightly lower than our proposed prefix-based method.
+
+From the above results, we conclude that applying prefixes for data augmentation is the most effective and space-efficient method for sentence representation learning tasks.
+
+
+Figure 4: The relationship between prefix length and STS-B development set performance under the semi-supervised setting using $\mathrm{BERT}_{\mathrm{base}}$
+
+Prefix length. Prefix length is a critical hyperparameter in our experiments. The longer the prefix, the more tunable parameters, therefore the more expressive the data augmentation module is. However, it does not mean a longer prefix will definitely lead to a better performance. According to the InfoMin principle (Tian et al., 2020), a longer prefix may bring unnecessary noise, thus hurting the performance of contrastive learning. Figure 4 shows that the optimal prefix length for $\mathrm{BERT}_{\mathrm{base}}$ under the semi-supervised setting is around 8.
+
+# 5 Related work
+
+Learning sentence embeddings as a fundamental NLP problem has been extensively studied. Many works (Reimers and Gurevych, 2019; Li et al., 2020; Yan et al., 2021; Gao et al., 2021b; Jiang et al., 2022) achieve good results based on pretrained language models. Among these works, contrastive learning methods achieve the state-of-the-art results. In this work, we improve the data augmentation module of the contrastive learning framework by a prompting method.
+
+Contrastive sentence representation learning. Contrastive learning aims to learn effective representations by pulling together semantically close neighbors and pushing apart non-neighbors. A crucial problem in contrastive learning is how to generate positive instances. The commonly-used data augmentation methods in NLP include word deletion, reordering, and substitution (Xie et al., 2020; Yan et al., 2021). However, data augmentation in NLP is inherently difficult because of the discrete nature of language. (Gao et al., 2021b) shows that data augmentation via dropout is consistently better than previous discrete transformations.
+
+Prompting. Prompting means querying a pretrained language model by adding natural language tokens into the input sentences (Brown et al., 2020). This method alleviates the discrepancy between a language model's pre-training stage and fine-tuning stage, and is shown to be useful when the labeled data for downstream tasks is scarce (Gao et al., 2021a). Although adding natural language tokens (i.e., hard prompt) is effective for certain tasks, it takes efforts to design good prompts. Motivated by this problem, soft prompt methods (Qin and Eisner, 2021; Zhong et al., 2021) are proposed. Unlike hard prompt, soft prompt tokens can be fine-tuned continuously. Therefore, it is more expressive. Some recent works further improve the soft prompt method by adding deep prompt modules on language models (Houlsby et al., 2019; Li and Liang, 2021; Liu et al., 2022), and they are called parameter-efficient methods. With more tunable parameters, the parameter-efficient methods can handle complex natural language tasks, e.g., language understanding (Houlsby et al., 2019), text generation (Li and Liang, 2021), and structured prediction (Liu et al., 2022). Such methods usually assume the language model is fixed during fine-tuning, and only the newly-added prompting modules can be tuned.
+
+# 6 Conclusion
+
+In this paper, we propose a differentiable data augmentation method for contrastive sentence representation learning. Unlike previous discrete transformations for sentences (e.g., token shuffling and synonyms replacement) and continuous methods (e.g., dropout (Gao et al., 2021b)), the proposed method learns how to do data augmentation implicitly based on supervised signals from the natural language inference (NLI) tasks. In this way, our method produces hard positives with meaningful differences for contrastive learning. We demonstrate the effectiveness of our method on several semantic textual similarity tasks, and our method achieves new state-of-the-art performance in both semi-supervised and supervised settings on average. We also conduct experiments where only limited labeled data is available. The results demonstrate the proposed method is robust when its labeled data is scarce.
+
+To the best of our knowledge, our method is the first work that provides a successful solution for combining the conventional pre-trained language
+
+model fine-tuning with parameter-efficient methods via a two-stage tuning process. The approach of combining the two yields better results than using any of them alone on the sentence representation learning tasks. One potential future research direction is to generalize this method to other NLP research areas, e.g., domain adaptation and low-resource tasks.
+
+# Limitations
+
+Since our method incorporates a learnable module for data augmentation, it requires additional training time and GPU memory compared with previous contrastive learning methods. The demand for more computation resources is a clear limitation of our work. We compare the training overheads with two previous contrastive learning methods in Table 4. We have mentioned in the previous section that our stage-1 tuning is necessary, and it is not a trivial task to reach a module-compatible state. Therefore, reducing computation resources during training for our method is difficult. However, given the improvements that are brought by our methods on sentence embedding learning tasks, the additional computation cost is worthy.
+
+| Method | Training time | GPU memory usage |
| SimCSE | 36 min. | 10 GB |
| PromptBERT | 48 min. | 13 GB |
| DiffAug (ours) | 65 min. | 15 GB |
+
+Table 4: Comparison of training time and GPU memory usage of our method and previous contrastive learning methods. We use same batch size (128) and same number of epochs (3) on NLI dataset with BERTbase for all three methods for a fair comparison. All results in this table are obtained from a single Nvidia Quadro RTX8000 GPU.
+
+# Acknowledgements
+
+We would like to thank the anonymous reviewers and (senior) area chairs for their insightful comments and help with this work. We would also like to thank members of StatNLP research group for helpful discussions. This research is supported by the National Research Foundation, Singapore under its AI Singapore Programme (AISG Award No: AISGRP-2019-012). Any opinions, findings and conclusions or recommendations expressed in this material are those of the authors and do not reflect the views of National Research Foundation, Singapore and AI Singapore.
+
+# References
+
+Eneko Agirre, Carmen Banea, Claire Cardie, Daniel Cer, Mona Diab, Aitor Gonzalez-Agirre, Weiwei Guo, Inigo Lopez-Gazpio, Montse Maritxalar, Rada Mihalcea, German Rigau, Larritz Uria, and Janyce Wiebe. 2015. SemEval-2015 task 2: Semantic textual similarity, English, Spanish and pilot on interpretability. In Proceedings of SemEval.
+Eneko Agirre, Carmen Banea, Claire Cardie, Daniel Cer, Mona Diab, Aitor Gonzalez-Agirre, Weiwei Guo, Rada Mihalcea, German Rigau, and Janyce Wiebe. 2014. SemEval-2014 task 10: Multilingual semantic textual similarity. In Proceedings of SemEval.
+Eneko Agirre, Carmen Banea, Daniel Cer, Mona Diab, Aitor Gonzalez-Agirre, Rada Mihalcea, German Rigau, and Janyce Wiebe. 2016. SemEval-2016 task 1: Semantic textual similarity, monolingual and crosslingual evaluation. In Proceedings of SemEval.
+Eneko Agirre, Daniel Cer, Mona Diab, and Aitor Gonzalez-Agirre. 2012. SemEval-2012 task 6: A pilot on semantic textual similarity. In Proceedings of *SEM.
+Eneko Agirre, Daniel Cer, Mona Diab, Aitor Gonzalez-Agirre, and Weiwei Guo. 2013. *SEM 2013 shared task: Semantic textual similarity. In Proceedings of *SEM.*
+Samuel R. Bowman, Gabor Angeli, Christopher Potts, and Christopher D. Manning. 2015. A large annotated corpus for learning natural language inference. In Proceedings of EMNLP.
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Proceedings of NeurIPS.
+Daniel Cer, Mona Diab, Eneko Agirre, Inigo Lopez-Gazpio, and Lucia Specia. 2017. SemEval-2017 task 1: Semantic textual similarity multilingual and crosslingual focused evaluation. In Proceedings of SemEval.
+Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. 2020a. A simple framework for contrastive learning of visual representations. In Proceedings of ICML.
+Ting Chen, Simon Kornblith, Kevin Swersky, Mohammad Norouzi, and Geoffrey Hinton. 2020b. Big self-supervised models are strong semi-supervised learners. In Proceedings of NeurIPS.
+
+Yung-Sung Chuang, Rumen Dangovski, Hongyin Luo, Yang Zhang, Shiyu Chang, Marin Soljacic, Shang-Wen Li, Scott Yih, Yoon Kim, and James Glass. 2022. DiffCSE: Difference-based contrastive learning for sentence embeddings. In Proceedings of ACL.
+Alexis Conneau, Douwe Kiela, Holger Schwenk, Loic Barrault, and Antoine Bordes. 2017. Supervised learning of universal sentence representations from natural language inference data. In Proceedings of EMNLP.
+Rumen Dangovski, Li Jing, Charlotte Loh, Seungwook Han, Akash Srivastava, Brian Cheung, Pulkit Agrawal, and Marin Soljačić. 2021. Equivariant contrastive learning. arXiv preprint arXiv:2111.00899.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of NAACL.
+Tianyu Gao, Adam Fisch, and Danqi Chen. 2021a. Making pre-trained language models better few-shot learners. In Proceedings of ACL-IJCNLP.
+Tianyu Gao, Xingcheng Yao, and Danqi Chen. 2021b. Simcse: Simple contrastive learning of sentence embeddings. In Proceedings of EMNLP.
+Xavier Glorot and Yoshua Bengio. 2010. Understanding the difficulty of training deep feedforward neural networks. In Proceedings of AISTATS.
+Raia Hadsell, Sumit Chopra, and Yann LeCun. 2006. Dimensionality reduction by learning an invariant mapping. In Proceedings of CVPR.
+Junxian He, Chunting Zhou, Xuezhe Ma, Taylor Berg-Kirkpatrick, and Graham Neubig. 2021. Towards a unified view of parameter-efficient transfer learning. In Proceedings of ICLR.
+Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. 2015. Delving deep into rectifiers: Surpassing human-level performance on imagenet classification. In Proceedings of ICCV.
+Neil Houlsby, Andrei Giurgiu, Stanislaw Jastrzebski, Bruna Morrone, Quentin De Laroussilhe, Andrea Gesmundo, Mona Attariyan, and Sylvain Gelly. 2019. Parameter-efficient transfer learning for nlp. In Proceedings of ICML.
+Edward J Hu, Phillip Wallis, Zeyuan Allen-Zhu, Yanzhi Li, Shean Wang, Lu Wang, Weizhu Chen, et al. 2021. Lora: Low-rank adaptation of large language models. In Proceedings of ICLR.
+Ting Jiang, Shaohan Huang, Zihan Zhang, Deqing Wang, Fuzhen Zhuang, Furu Wei, Haizhen Huang, Liangjie Zhang, and Qi Zhang. 2022. Promptbert: Improving bert sentence embeddings with prompts. arXiv preprint arXiv:2201.04337.
+
+Bohan Li, Hao Zhou, Junxian He, Mingxuan Wang, Yiming Yang, and Lei Li. 2020. On the sentence embeddings from pre-trained language models. In Proceedings of EMNLP.
+Xiang Lisa Li and Percy Liang. 2021. Prefix-tuning: Optimizing continuous prompts for generation. In Proceedings of ACL-IJCNLP.
+Xiao Liu, Kaixuan Ji, Yicheng Fu, Weng Tam, Zhengxiao Du, Zhilin Yang, and Jie Tang. 2022. P-tuning: Prompt tuning can be comparable to fine-tuning across scales and tasks. In Proceedings of ACL.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Marco Marelli, Stefano Menini, Marco Baroni, Luisa Bentivogli, Raffaella Bernardi, and Roberto Zamparelli. 2014. A SICK cure for the evaluation of compositional distributional semantic models. In Proceedings of LREC.
+Tomas Mikolov, Ilya Sutskever, Kai Chen, Greg S Corrado, and Jeff Dean. 2013. Distributed representations of words and phrases and their compositionality. In Proceedings of NeurIPS.
+Jeffrey Pennington, Richard Socher, and Christopher D. Manning. 2014. Glove: Global vectors for word representation. In Proceedings of EMNLP.
+Guanghui Qin and Jason Eisner. 2021. Learning how to ask: Querying lms with mixtures of soft prompts. In Proceedings of NAACL.
+Nils Reimers and Iryna Gurevych. 2019. Sentence-bert: Sentence embeddings using siamese bert-networks. In Proceedings of EMNLP-IJCNLP.
+Jianlin Su, Jiarun Cao, Weijie Liu, and Yangyiwen Ou. 2021. Whitening sentence representations for better semantics and faster retrieval. arXiv preprint arXiv:2103.15316.
+Chaofan Tao, Lu Hou, Wei Zhang, Lifeng Shang, Xin Jiang, Qun Liu, Ping Luo, and Ngai Wong. 2022. Compression of generative pre-trained language models via quantization. In Proceedings of ACL.
+Yonglong Tian, Chen Sun, Ben Poole, Dilip Krishnan, Cordelia Schmid, and Phillip Isola. 2020. What makes for good views for contrastive learning? In Proceedings of NeurIPS.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Proceedings of NeurIPS.
+Adina Williams, Nikita Nangia, and Samuel Bowman. 2018. A broad-coverage challenge corpus for sentence understanding through inference. In Proceedings of NAACL.
+
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of EMNLP.
+Qizhe Xie, Zihang Dai, Eduard Hovy, Thang Luong, and Quoc Le. 2020. Unsupervised data augmentation for consistency training. In Proceedings of NeurIPS.
+Yuanmeng Yan, Rumei Li, Sirui Wang, Fuzheng Zhang, Wei Wu, and Weiran Xu. 2021. Consent: A contrastive framework for self-supervised sentence representation transfer. In Proceedings of ACL.
+Zexuan Zhong, Dan Friedman, and Danqi Chen. 2021. Factual probing is [MASK]: Learning vs. learning to recall. In Proceedings of NAACL.
+
+# A Implementation details
+
+We implement our method based on Hugging Face's Transformer (Wolf et al., 2020) and PyTorch libraries. The backbone of our code is from (Gao et al., 2021b) with some prompt implementation details from (Jiang et al., 2022). For both semi-supervised and supervised settings, we evaluate the model on the STS-B development set every 50 training steps, and only save the checkpoints with the best performance on development set for the final evaluation on test set.
+
+For all our settings, we apply hard prompts on the input sentences and obtain the sentence representations from the hidden embeddings of [MASK] tokens. The hard prompt templates we use in our method are from (Jiang et al., 2022). We also apply the template denoising for contrastive learning since this technique brings significant improvements from only adding hard prompts according to (Jiang et al., 2022).
+
+The core component of our method is the use of two different prefix modules for data augmentation. During training, we use them to construct hard positive pairs with meaningful differences for contrastive learning. During inference, we prepend both prefix modules to the language model to obtain the sentence representations. In practice, we follow Li and Liang (2021) and reparametrize the key and value matrices $P_{k}$ , $P_{v}$ in the prefix by a smaller matrix $P'$ composed with a large multi-layer perceptron to make the training stable. Our training hyperparameters under different settings for $\mathrm{BERT}_{\mathrm{base}}$ are in Table 5.
+
+ | | Semi-supervised | Supervised |
| | w/o aux | w/ aux | w/o aux |
| Stage 1 | learning rate | 1e-3 | 1e-3 | 1e-3 |
| batch size | 128 | 128 | 128 |
| training steps | 2000 | 1500 | 1250 |
| Stage 2 | learning rate | 1e-5 | 1e-5 | 5e-5 |
| batch size | 256 | 256 | 128 |
| epochs | 1 | 1 | 3 |
+
+Table 5: Hyperparameters for each setting.
+
+# B Analysis of weight convergence
+
+In the previous section, we mentioned that the module-compatible state in our case is closely related to the stage-1 training steps, and the optimal number of training steps is determined by two countering metrics, i.e., representation divergence and weight convergence. Previous works (Chen et al., 2020a; Tian et al., 2020) have demonstrated the importance of representation divergence in contrastive learning. In this section, we show the necessity of weight convergence in our stage-2 training. Our method is based on the prefix-tuning (Li and Liang, 2021) that affects the original language model by adding new key-value pairs on each self-attention layer. The added key and value matrices influence the self-attention computation differently. Specifically, key matrix $(K)$ is used for attention matrix calculation, i.e., $A = \mathrm{softmax}\left(\frac{Q^T K}{\sqrt{d}}\right)$ while value matrix $(V)$ is used for weighted averaged output generation, i.e., $H = AV$ , we analyze the impact of weight convergence on key and value separately.
+
+# B.1 The impact of weight convergence on attention matrix calculation
+
+The computation of attention matrix includes a softmax operation $S(\cdot):\mathbb{R}^N\to \mathbb{R}^N$ that can be defined as:
+
+$$
+S (\mathbf {a}): \left(\begin{array}{c}a _ {1}\\\vdots\\a _ {N}\end{array}\right)\rightarrow \left(\begin{array}{c}s _ {1}\\\vdots\\s _ {N}\end{array}\right) \tag {9}
+$$
+
+where $s_i = \frac{\exp(a_i)}{\sum_{j=1}^N \exp(a_j)}$ , and $N$ is the length of input and output vectors. Therefore, the derivative of the softmax function $S(\cdot)$ , i.e., the Jacobian matrix, can be derived as:
+
+$$
+J _ {\text {s o f t m a x}} = \left( \begin{array}{c c c c} \frac {\partial s _ {1}}{\partial a _ {1}} & \frac {\partial s _ {1}}{\partial a _ {2}} & \dots & \frac {\partial s _ {1}}{\partial a _ {N}} \\ \frac {\partial s _ {2}}{\partial a _ {1}} & \frac {\partial s _ {2}}{\partial a _ {2}} & \dots & \frac {\partial s _ {2}}{\partial a _ {N}} \\ \vdots & \vdots & \ddots & \vdots \\ \frac {\partial s _ {N}}{\partial a _ {1}} & \frac {\partial s _ {N}}{\partial a _ {2}} & \dots & \frac {\partial s _ {N}}{\partial a _ {N}} \end{array} \right) \tag {10}
+$$
+
+where
+
+$$
+\frac {\partial s _ {i}}{\partial a _ {j}} = \left\{ \begin{array}{c} s _ {i} \cdot (1 - s _ {j}), \text {i f} i = j \\ - s _ {i} \cdot s _ {j}, \text {i f} i \neq j \end{array} \right. \tag {11}
+$$
+
+From the above derivation, either a too large or a too small $s_i$ will make the derivative approach zero. Notice that in Section 3.2, we mentioned the averaged norm of the key vectors from randomly initialized prefix module is much smaller than those in the original language model. Therefore, if we tune both prefix and language model jointly without stage-1 training, the gradient back propagation of the self-attention layer will be blocked due to the vanishing gradients.
+
+# B.2 The impact of weight convergence on weighted averaged output generation
+
+In the self-attention layer of the Transformer, the embeddings of each token are generated via the weighted average of the value vectors. Previous works (Glorot and Bengio, 2010; He et al., 2015) have shown the importance of keeping the same the variance of input of each layer in a deep neural network during forward propagation. Specifically, if we write the input matrix of layer $i$ as $Z^i$ , to ensure the information flow, we hope
+
+$$
+\forall (i, i ^ {\prime}), \operatorname {V a r} \left[ Z ^ {i} \right] = \operatorname {V a r} \left[ Z ^ {i ^ {\prime}} \right] \tag {12}
+$$
+
+For the Transformer's $i$ -th self-attention layer, we use $X^i$ , $H^i \in \mathbb{R}^{L \times d}$ to represent the input and output respectively, where $L$ is the input length, and $d$ is the hidden dimension. The importance of weight convergence in attention matrix has been discussed in the last section. Now, for simplicity, we write the attention function as $H^i = A^i[P_v^i; V^i]$ , where $A^i \in \mathbb{R}^{L \times (L + l)}$ is the attention matrix after softmax, $P_v^i \in \mathbb{R}^{l \times d}$ is the added value matrix from the prefix module, and $V^i \in \mathbb{R}^{L \times d7}$ is the value matrix of the original language model.
+
+We have shown in Section 3.2 the norm of $P_{v}^{i}$ is significantly less than that of $V^{i}$ at the beginning. Therefore, if the training steps of stage 1 is not long enough, the difference between the variance of $P_{v}^{i}$ and $V^{i}$ could be so large that makes the condition in the Equation 12 invalid, which will cause the stage-2 joint training unstable.
+
+| Method | STS12 | STS13 | STS14 | STS15 | STS16 | STS-B | SICK-R | Avg. |
| ConBERTjoint | 72.60±.4 | 82.40±.8 | 77.64±.5 | 82.82±.1 | 78.37±.1 | 80.03±.4 | 78.20±.1 | 78.87±.3 |
| ConBERTsup-unsup | 70.11±.2 | 82.07±.5 | 74.97±.4 | 83.21±.2 | 76.91±.3 | 78.89±.3 | 76.92±.5 | 77.58±.3 |
| ConBERTsup-joint | 71.96±.3 | 82.70±.4 | 75.85±1.1 | 82.70±.5 | 77.16±.8 | 80.78±.7 | 75.12±.4 | 78.04±.5 |
| SimCSEjoint | 70.73±1.8 | 83.22±.3 | 75.75±.5 | 82.93±.6 | 77.90±1.0 | 78.69±.3 | 74.86±.5 | 77.73±.6 |
| SimCSEsup-unsup | 69.02±2.4 | 82.21±1.3 | 74.51±.9 | 82.27±.6 | 77.20±.6 | 78.55±1.3 | 74.06±1.8 | 76.83±1.3 |
| SimCSEsup-joint | 70.80±1.2 | 81.27±.2 | 74.68±.5 | 81.83±1.0 | 77.58±1.2 | 78.55±1.5 | 73.58±1.1 | 76.90±.8 |
| PromptBERTjoint | 71.71±.3 | 84.99±.1 | 77.25±.2 | 85.01±.1 | 80.66±.1 | 81.86±.1 | 75.50±.3 | 79.81±.1 |
| PromptBERTsup-unsup | 71.23±.2 | 85.16±.1 | 77.88±.2 | 85.15±.2 | 81.23±.2 | 82.06±.6 | 75.22±.8 | 78.15±.2 |
| PromptBERTsup-joint | 71.34±.7 | 81.61±1.0 | 76.23±.6 | 82.92±.5 | 78.45±.7 | 79.76±1.0 | 74.63±.7 | 77.85±.7 |
+
+# C Baseline methods
+
+In this section, we describe how we re-evaluate the baseline models when their original published results are not directly comparable with our methods. For unsupervised ConSERT (Yan et al., 2021), we re-evaluate it on Wiki1M dataset.
+
+For methods that do not implement with semi-supervised setting, we find that simply adding an auxiliary cross entropy loss with proper weight can boost the performance from unsupervised results. To make a comprehensive evaluation, we try the following three methods of adding supervised signals from NLI data inspired by (Yan et al., 2021):
+
+- Joint training (joint). We combine the contrastive learning objective with the cross entropy loss, which can be written as
+
+$$
+\mathcal {L} _ {\text {j o i n t}} = \mathcal {L} _ {\mathrm {c l}} + \alpha \cdot \mathcal {L} _ {\mathrm {c e}} \tag {13}
+$$
+
+where the contrastive loss is computed with unlabeled Wiki1M data while the cross entropy loss is computed with labeled NLI data. For this setting, we try different values of $\alpha$ for each method and select the best one to compare with our method.
+
+- Supervised training then unsupervised contrastive training (sup-unsup). We split the whole training process into 2 stages: first train the model with cross entropy loss on NLI data, then train the model with contrastive loss on Wiki1M data.
+- Supervised training then joint training (supjoint). The training process is still split into 2 stages: first, the model is trained with cross entropy loss on NLI data; next, the model is trained with the joint loss $\mathcal{L}_{\mathrm{joint}}$ .
+
+The results of each setting are shown in Table 6. We select the setting with the best performance
+
+Table 6: Semi-supervised baselines re-implemented by us over three different settings.
+
+| Method | Fraction of labeled data |
| 0% | 1% | 10% | 100% |
| Semi-supervised setting |
| SimCSEjoint | 76.57♥ | 77.32±.8 | 77.66±.5 | 77.85±.5 |
| PromptRoBERTa joint | 79.15♠ | 79.89±.5 | 80.12±.5 | 80.45±.5 |
| DiffAug (ours) | - | 80.56±.3 | 80.71±.3 | 80.93±.3 |
| Supervised setting |
| SimCSE | - | 76.83±.6 | 80.18±.2 | 82.43±.2 |
| PromptRoBERTa | - | 79.15±.4 | 81.22±.3 | 82.50±.2 |
| DiffAug (ours) | - | 79.50±.7 | 81.89±.2 | 82.76±.2 |
+
+Table 7: Averaged sentence representation performance on STS tasks with different fractions of labeled data using RoBERTabase. $\diamond$ and $\spadesuit$ are the results of unsupervised SimCSE and PromptBERT respectively. We report these two results from their original papers, and re-evaluate other baseline results.
+
+(i.e., joint training setting) and use it to compare with our method in Table 2.
+
+# D RoBERTa results
+
+We compare our approach on RoBERTa $_{\text{base}}$ with the state-of-the-art contrastive learning methods (Gao et al., 2021b; Jiang et al., 2022) under different fractions of labeled data in Table 7. We use a similar approach to evaluate our method and baselines on RoBERTa $_{\text{base}}$ that we described in Section 4.3. The results show that the proposed method also outperforms the baselines on RoBERTa $_{\text{base}}$ .
+
+# E Ablation studies
+
+Auxiliary objective in stage 2. We now investigate the impact of cross entropy auxiliary objective in stage-2 training. When the auxiliary loss is added, the overall objective for stage 2 has a form of $\mathcal{L} = \mathcal{L}_{cl} + \alpha \cdot \mathcal{L}_{ce}$ , where $\alpha$ is a scalar that balances two losses. Table 8 shows the impact of auxiliary loss in stage 2. We find that for
+
+| Add aux loss | α | STS-B dev. |
| False | - | 86.2 |
| True | 1 × 10-4 | 86.0 |
| 1 × 10-3 | 86.3 |
| 1 × 10-2 | 84.8 |
| 1 × 10-1 | 83.3 |
+
+Table 8: Ablation studies of the impact of auxiliary objective during stage 2 for semi-supervised settings.
+
+semi-supervised setting, adding auxiliary loss with $\alpha = 1\times 10^{-3}$ works the best. We suspect NLI data contains valuable information that benefits sentence representation learning. However, for our semi-supervised method, such information gained from stage 1 can be gradually forgotten in stage 2 if no auxiliary loss is added. Hence, combining contrastive loss with an auxiliary cross entropy loss in stage 2 will benefit the overall training process.
+
+Training steps of stage 1. Another hyperparameter we find crucial for the overall performance is the training steps of stage 1. The importance of this hyperparameter has been elaborated in Section 3.2. Here we conduct further analysis using $\mathrm{BERT}_{\mathrm{base}}$ under the semi-supervised setting by visualizing the relationship between stage-1 training steps and cross entropy loss on the training data. We observe that a lower stage-1 cross entropy loss does not always lead to a better overall performance. From Figure 5, we can see that the model reaches the highest development score when the number of training steps is around 2,000, but the training loss can still be further reduced.
+
+As we mentioned in Section 3.1, one of the important roles that stage-1 training performs is to make sure the prefix modules are compatible with the language model during the contrastive learning in stage 2. Therefore, for our method, the compatibility between prefix and language model is more important than prefix's capability on capturing sentence relationships.
+
+# F Overview of the existing parameter-efficient methods
+
+In this section, we introduce two existing parameter-efficient methods that are mentioned in Section 4.4, i.e., Adapter (Houlsby et al., 2019) and LoRA (Hu et al., 2021).
+
+Adapter. This method proposes to insert modules with small amount of trainable parameters on
+
+
+Figure 5: Number of stage-1 training steps V.S. STS-B development performance V.S. cross entropy loss on the training data.
+
+each layer of the Transformer-based pre-trained language model. Specifically, each module has three main components: a down-projection linear layer with parameters $W_{\mathrm{down}} \in \mathbb{R}^{d \times r}$ , a up-projection linear layer with parameters $W_{\mathrm{up}} \in \mathbb{R}^{r \times d}$ , and a non-linear activation function $f(\cdot)$ , where $d$ and $r$ are the hidden states and bottleneck dimensions respectively. The adpater module modifies the hidden state $h$ in the following way:
+
+$$
+\boldsymbol {h} \leftarrow \boldsymbol {h} + f \left(\boldsymbol {h} W _ {\text {d o w n}}\right) W _ {\text {u p}} \tag {14}
+$$
+
+In the original implementation (Houlsby et al., 2019), the adapter modules are inserted in two places on each transformer layer, i.e., one is after the self-attention layer and the other is after the feed-forward network layer.
+
+LoRA. Similar to Adapter, LoRA also adds small modules, called trainable rank decomposition matrices, on each layer of the pre-trained language model. Each LoRA module is composed of two tunable weight matrices $W_{\mathrm{down}} \in \mathbb{R}^{d \times r}$ and $W_{\mathrm{up}} \in \mathbb{R}^{r \times d}$ . Unlike Adapter, LoRA module does not contain any non-linear activation functions, and the added weight matrices are parallel to the original weight matrices. Hence, it works in the following way:
+
+$$
+\boldsymbol {h} \leftarrow \boldsymbol {h} + s \cdot \boldsymbol {x} W _ {\text {d o w n}} W _ {\text {u p}} \tag {15}
+$$
+
+where $s \geq 1$ is a scaling factor and $x$ represents the input. Another difference between LoRA and Adapter is that LoRA modules are only applied on the query and value projection matrices $Q$ and $V$ in the self-attention sub-layers, while the Adapter modules are attached on both the self-attention and feed-forward network sub-layers.
\ No newline at end of file
diff --git a/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/images.zip b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..7e59303c6b7a3e2b4cc72c3443781c671e3f0c30
--- /dev/null
+++ b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a6ff5e5253c619d84dc2d22ed5486cd1df59c1918ccfc344d696f42ac9017b50
+size 587567
diff --git a/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/layout.json b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..07fdba25c197922b659b8ce330910342e40d2017
--- /dev/null
+++ b/differentiabledataaugmentationforcontrastivesentencerepresentationlearning/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a2e90e8035fb302fa04af34ee49e49e422aeb34e34754b93d23d383db2fb1d53
+size 513184
diff --git a/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_content_list.json b/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..6d4969f9ba161f7e5fe3d2e6a6e9fcada5dd5e03
--- /dev/null
+++ b/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0b57e5c2bf9c7961b791133393cec66da4c778908de2dafd5f8c561dd9568e8c
+size 93950
diff --git a/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_model.json b/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..a95236186bb0f9079bafd80b42ce02fd8169d4be
--- /dev/null
+++ b/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a5325889296b347fa5e0a32e8c71c9de4ab85c81fea007071d2cff0ed09d7729
+size 117572
diff --git a/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_origin.pdf b/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..228f2313af0c46eb0ec32e34c9d64156be89a5ea
--- /dev/null
+++ b/differentiallyprivatelanguagemodelsforsecuredatasharing/cb607e1e-ba3b-47f6-9ac8-bb1c87425047_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b9fca9987c42adb5cf51468da0b84afb491aa9ce2e2afd7c1d2d20375421fd28
+size 527544
diff --git a/differentiallyprivatelanguagemodelsforsecuredatasharing/full.md b/differentiallyprivatelanguagemodelsforsecuredatasharing/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..50ae89c3f5e34804e3020b3bb54e582c7daea37b
--- /dev/null
+++ b/differentiallyprivatelanguagemodelsforsecuredatasharing/full.md
@@ -0,0 +1,367 @@
+# Differentially Private Language Models for Secure Data Sharing
+
+Justus Mattern
+
+RWTH Aachen
+
+justus.mattern@rwh-aachen.de
+
+Zhijing Jin
+
+MPI & ETH Zürich
+
+zjin@tue.mpg.de
+
+Benjamin Weggenmann
+
+SAP Security Research
+
+benjamin.weggenmann@sap.com
+
+Bernhard Scholkopf *
+
+MPI for Intelligent Systems
+
+bs@tue.mpg.de
+
+Mrinmaya Sachan *
+
+ETH Zürich
+
+msachan@ethz.ch
+
+# Abstract
+
+To protect the privacy of individuals whose data is being shared, it is of high importance to develop methods allowing researchers and companies to release textual data while providing formal privacy guarantees to its originators. In the field of NLP, substantial efforts have been directed at building mechanisms following the framework of local differential privacy, thereby anonymizing individual text samples before releasing them. In practice, these approaches are often dissatisfying in terms of the quality of their output language due to the strong noise required for local differential privacy. In this paper, we approach the problem at hand using global differential privacy, particularly by training a generative language model in a differentially private manner and consequently sampling data from it. Using natural language prompts and a new prompt-mismatch loss, we are able to create highly accurate and fluent textual datasets taking on specific desired attributes such as sentiment or topic and resembling statistical properties of the training data. We perform thorough experiments indicating that our synthetic datasets do not leak information from our original data and are of high language quality and highly suitable for training models for further analysis on real-world data. Notably, we also demonstrate that training classifiers on private synthetic data outperforms directly training classifiers on real data with DP-SGD. $^{1}$
+
+# 1 Introduction
+
+Rapid advancements in the field of deep learning and natural language processing (NLP) have enabled companies, public institutions and researchers to extract information and gain knowledge from large-scale data generated by individuals. In many cases, it is desirable to share such data
+
+
+Figure 1: Main idea of our paper: To share potentially sensitive datasets with third parties, we train a language model (LM) on the sensitive data in a differentially private manner and consequently prompt the LM to generate synthetic samples with privacy guarantees.
+
+with third parties, for example when analyses are performed by external consultants or in order to provide high quality benchmarks for the research community. This, however, entails a variety of risks related to privacy that cannot merely be solved by pseudonymization: A variety of deanonymization attacks enable the re-identification of individuals from tabular data such as movie ratings (Narayanan and Shmatikov, 2008), geolocation data (Lee et al., 2017) and notably also text (Koppel et al., 2009; Shrestha et al., 2017; Fabien et al., 2020). It is therefore highly desirable to develop anonymization mechanisms enabling secure data sharing, ideally with mathematical privacy guarantees as granted by differential privacy (DP) (Dwork and Roth, 2014).
+
+Existing approaches anonymize every text sample individually by obtaining differentially private vector representations (Weggenmann and Kerschbaum, 2018; Fernandes et al., 2019) or using sequence-to-sequence approaches that rewrite a
+
+given sample to eliminate user-revealing information (Shetty et al., 2018; Feyisetan et al., 2019a, 2020a; Weggenmann et al., 2022), thereby following local differential privacy. As pointed out by Mattern et al. (2022), local DP requires a very high degree of noise which often leads to incoherent language and only little semantic overlap. The strict requirements of local DP are, however, not necessary if we assume that an entity aiming to share data already has access to the full collection of user-written texts and only wants to release an anonymized version of it.
+
+In this paper, inspired by recent advances demonstrating the feasibility of training large language models (LLMs) in a differentially private manner (Li et al., 2021), we propose a globally differentially private data release mechanism relying on the generation of a "twin" dataset of the original, sensitive user data from large language models. As depicted in Figure 1, we train GPT-2 (Radford et al., 2019) to generate texts of our original dataset based on prompts inferred from the sample's individual attributes such as sentiment or topic. For fine-tuning, we use a differentially private optimization algorithm in order to protect the content of our training data. Subsequently, we sample from the trained model to generate a large number of synthetic, anonymous texts, resulting in a verifiably private "twin" dataset. We carefully evaluate our proposed method using popular NLP datasets such as IMDb movie reviews or Amazon product reviews. Here, we find that even after learning with strong privacy guarantees such as $\epsilon = 3$ or $\epsilon = 8$ from only a very limited amount of training samples such as 25 or 50, our generated data is of high quality and the classifiers trained on it achieve accuracies only $\sim 3\%$ lower than those trained on the full original dataset containing thousands of samples. Notably, we also find that transformer based classification models trained on private data outperform models trained on real data with differentially private optimization. Finally, we show that the differentially private fine-tuning procedure effectively minimizes the risk of data leakage from language models that was previously discovered by Carlini et al. (2021).
+
+# 2 Background
+
+# 2.1 Differential Privacy
+
+Differential privacy (DP) is a formal notion of privacy that is currently considered the state-of-the-art
+
+for quantifying and limiting information disclosure about individuals. It has been introduced by Dwork et al. (2006a) under the name $\epsilon$ -indistinguishability with the goal of giving semantic privacy by quantifying the risk of an individual that results from participation in data collection.
+
+In the original, central model of DP, we consider adjacent datasets that differ by at most one record (i.e., one individual's data). A differentially private query on both databases should yield matching results with similar probabilities, i.e., answers that are probabilistically indistinguishable. This is achieved via random mechanisms that return noisy query results, thus masking the impact of each individual.
+
+Definition 1. Let $\epsilon >0$ be a privacy parameter, and $0\leq \delta \leq 1$ . A randomized mechanism $\mathcal{M}$ on $\mathcal{X}$ fulfills $(\epsilon ,\delta)$ -DP if for any pair of adjacent inputs $\pmb {x},\pmb{x}^{\prime}\in \mathcal{X}$ , and all sets of possible outputs $Z\subset \operatorname {supp}\mathcal{M}$
+
+$$
+\Pr \left[ \mathcal {M} (\boldsymbol {x}) \in Z \right] \leq e ^ {\epsilon} \cdot \Pr \left[ \mathcal {M} \left(\boldsymbol {x} ^ {\prime}\right) \in Z \right] + \delta . \tag {1}
+$$
+
+In the local model (Duchi et al., 2013), noise is added locally at the data source, before the data is collected and stored in a central database. A basic example is randomized response (Warner, 1965), where each survey participant either provides a truthful or a random answer depending on the flip of an (unbiased) coin. The local model makes the strong assumption that any two inputs are considered adjacent, which often makes it difficult to achieve a satisfying privacy-utility trade-off.
+
+# 2.2 Differentially Private Optimization
+
+An important application of DP is privacy-preserving machine learning to protect the privacy of the training data. Typically, neural networks are trained by optimizing a loss function using stochastic gradient descent (SGD) or a derived method such as Adam (Kingma and Ba, 2015), which iteratively compute gradients of the loss function over batches of samples from the training dataset. As shown by Song et al. (2013a); Bassily et al. (2014a); Abadi et al. (2016a), it is possible to implement a differentially private version of SGD (DP-SGD) by clipping the gradients and applying the Gaussian mechanism (Dwork and Roth, 2014): The latter works by applying noise from an isotropic Gaussian distribution $\mathcal{N}(\mathbf{0},\sigma^2\mathbf{I})$ , where the standard deviation $\sigma$ is derived based on the desired privacy parameters $\epsilon$ and $\delta$ .
+
+To achieve good privacy-utility trade-offs, it is important to accurately track the total privacy budget spent throughout the entire training. In the context of DP, repeated executions of the same (here: Gaussian) mechanism is referred to as composition. Basic (Dwork et al., 2006b) and various more refined, advanced composition theorems (Dwork et al., 2010; Dwork and Rothblum, 2016; Bun and Steinke, 2016) have been stated in the literature that aim at providing tight bounds for the overall privacy budget. However, these advances still resulted in relatively loose bounds and thus large overall privacy budgets over the course of highly iterative algorithms such as DP-SGD. Tight worst-case bounds for composition were derived by Kairouz et al. (2015), however, it was shown to be computationally infeasible to compute them in general (Murtagh and Vadhan, 2016).
+
+For this reason, specific efforts have been made to find tighter bounds and accurate approximations for the overall privacy loss: A first example that provides substantial reduced upper bounds is the moments accountant (Abadi et al., 2016a), which is closely related to Rényi DP (Mironov, 2017), a generalization of DP based on Rényi divergence. Gaussian and $f$ -DP (Dong et al., 2019) provide an approximation of the total budget using the central limit theorem (CLT). Finally, Gopi et al. (2021); Koskela et al. (2020), inspired by Sommer et al. (2019), are able to compute the exact budget numerically up to arbitrary precision by aggregating the privacy loss random variable with fast Fourier transform.
+
+# 3 Approach
+
+We consider the following scenario to motivate our approach: an entity wants to implement NLP pipelines to gain insights from internal data, e.g., emails from customers. To seek advice and get support for modeling the data and building pipelines, the entity aims to share an excerpt of the internal data with a third party such as a consultant or a group of researchers. In order to do this without compromising the privacy of its customers, the aim is to synthesize a verifiably private "toy" dataset that reflects the properties of the original data without leaking private information. On such a toy dataset, a third party could research how to best solve the task at hand and train a model to perform inference on the actual internal data, without being able to access sensitive information about cus
+
+tomers. Formally, we aim to achieve the following goal: We consider a dataset consisting of a training set $\mathcal{D}_{\mathrm{train}}$ and test set $\mathcal{D}_{\mathrm{test}}$ . Given $\mathcal{D}_{\mathrm{train}}$ or a subset of it, we want to train a generative model to synthesize a dataset $\widetilde{\mathcal{D}}_{\mathrm{train}}$ that does not leak information from the original $\mathcal{D}_{\mathrm{train}}$ . Furthermore, the synthesized dataset should share statistical properties with the original one so that a classification model trained on $\widetilde{\mathcal{D}}_{\mathrm{train}}$ performs as well as if it was trained on $\mathcal{D}_{\mathrm{train}}$ when making predictions about $\mathcal{D}_{\mathrm{test}}$ .
+
+To achieve this, we use the pretrained autoregressive transformer model (Vaswani et al., 2017) GPT-2 (Radford et al., 2019) and use natural language prompts to enable the conditional generation of text based on desired textual attributes such as its sentiment, domain or genre provided in the prompt. Furthermore, we introduce a new training objective that penalizes the generation of samples fitting another label to reduce the risk of faulty labeled samples in our synthetic dataset. Finally, we fine-tune our model using a differentially private optimizer to provide privacy guarantees for our training data and to prevent information leakage from our model when subsequently sampling our synthetic dataset.
+
+# 3.1 Conditional text generation with natural language prompts
+
+As we want to control specific textual attributes of our synthetic data, we need to train our model in a manner that allows us to generate different types of texts corresponding to the desired attributes or labels present in our dataset. We consider a text sample to correspond to a set of $M$ attributes of interest, namely $A := \{a_1, a_2, \dots, a_M\}$ , where each attribute $a_j$ can take on a set of categorical values $C_j$ . In the case of product reviews, $a_1$ could be the sentiment of a review that can take on the values $a_1 \in C_1 = \{\text{Positive}, \text{Negative}\}$ and $a_2$ can be the product category, so that $a_2 \in C_2 = \{\text{Books}, \text{Electronics}, \text{DVD}, \text{Kitchen}\}$ . Our goal is to learn a model $p(x | a_1, \dots, a_M)$ in order to controllably synthesize text samples according to our desired attributes.
+
+A straightforward approach to realize this would be to train a single generative model for all possible attribute value combinations. This approach is, however, highly memory-intensive, as it requires us to store the weights of a large number of models that grows exponentially with the number of categorical attributes. Following recent work
+
+
+Figure 2: Our template-based approach for generating task instructions. A template consists of placeholders for verbalizations of different attribute values.
+
+(Schick and Schütze, 2021a), we therefore train a single language model to conditionally generate texts based on task instructions. Beyond reducing our memory needs, this approach allows us to leverage our model's pretraining knowledge and to perform text generation with only very little training samples (Schick and Schütze, 2021a). Our instructions $\pmb{i}(a_1, \dots, a_M)$ are formed using a template with placeholders that are filled out with verbalizations $v(a_j)$ taking on different forms for different values of every attribute $a_j$ . An example of such an instruction template is visualized in Figure 2.
+
+During the training stage, we use a differentially private optimizer to fine-tune our language model to generate each text sample within the original dataset based on the prompt corresponding to its individual attributes. Subsequently, we can synthesize a new dataset by controllably sampling text based on our desired attributes passed in the prompt. To generate a private "twin" dataset, one might use the same distribution of textual attributes as in the original dataset. Alternatively, the instruction-based approach allows us to control and change such ratios, for instance if we desire to debias our original data.
+
+# 3.2 Reducing faulty labels with prompt-mismatch objective
+
+The standard training objective for autoregressive language modeling is to minimize the negative log-likelihood (NLL) of every token given its previous tokens. We incorporate the natural language instructions (Radford et al., 2019; Brown et al., 2020) into this training objective. For every text sequence $\pmb{x}$ and its corresponding attribute values $a\coloneqq (a_{1},\dots,a_{M})$ , we construct the concatenated sequence $\pmb {i}(a)\oplus \pmb{x}$ which prepends a corresponding task instruction to each text sample. Let $L$ denote the length of this concatenated sequence and let $w_{l}$
+
+be the sequence's $l$ -th token. Our NLL loss is now
+
+$$
+\operatorname {N L L} (\boldsymbol {i} (a) \oplus \boldsymbol {x}) = - \sum_ {w _ {l} \in \boldsymbol {i} (a) \oplus \boldsymbol {x}} \log p \left(w _ {l} \mid w _ {< l}\right). \tag {2}
+$$
+
+This objective encourages the model to generate correct samples for a given instruction. However, it does not minimize the likelihood of generating wrong samples corresponding to another prompt and therefore attribute. This is specifically unfavorable for our goal of generating synthetic training datasets as every generated text having an error of this kind corresponds to a wrongly labeled training sample. To address this, we extend the training objective with a term penalizing the generation of a given sample for a wrong prompt. Specifically, let $I_{\mathrm{wrong}}$ denote the set of all prompts not matching the given attribute values $a_1, \dots, a_M$ , specifically
+
+$$
+I _ {\text {w r o n g}} := \left\{\boldsymbol {i} \left(\bar {a} _ {1}, \dots , \bar {a} _ {M}\right) \mid \bar {a} _ {j} \in C _ {j} \backslash \left\{a _ {j} \right\} \right\}. \tag {3}
+$$
+
+We now define the overall training loss we are aiming to minimize as
+
+$$
+\begin{array}{l} \mathcal {L} _ {\mathrm {o v r}} = \operatorname {N L L} (\boldsymbol {i} (a) \oplus \boldsymbol {x}) \\ - \frac {\lambda}{\left| I _ {\text {w r o n g}} \right|} \sum_ {i _ {\mathrm {w}} \in I _ {\text {w r o n g}}} \operatorname {N L L} \left(\boldsymbol {i} _ {\mathrm {w}} \oplus x\right), \tag {4} \\ \end{array}
+$$
+
+where $\lambda$ is the hyperparameter to balance the two losses. Note that in practice, when the number of possible labels is high, this computation might be inefficient and the objective too complex for the model to realize. In this case, one might randomly sample a few class labels for the wrong prompt in every training batch or penalize the generation for class labels that are the most similar to the correct one.
+
+# 4 Evaluation
+
+We conduct extensive evaluation measuring the utility and privacy of our generated data as well as the quality of its language. In this section, we describe the datasets we use as well as our evaluation metrics, implementation details and results.
+
+# 4.1 Datasets
+
+We use two publicly available datasets that are widely used for evaluating the performance of text classification models:
+
+Table 1: Accuracy of classification models trained on synthetic data.
+
+| # Train Samples | IMDb | Amazon |
| Sentiment | Sentiment | Product Category |
| 25 | 50 | 5000 | 25 | 50 | 3000 | 25 | 50 | 3000 |
| BERT: |
| ε = 3 | 82.8% | 88.3% | 89.1% | 85.2% | 87.2% | 88.5% | 98.6% | 98.7% | 98.9% |
| ε = 8 | 86.0% | 87.6% | 89.1% | 87.4% | 85.9% | 89.2% | 98.5% | 98.9% | 98.9% |
| ε = ∞ | 86.5% | 87.6% | 89.2% | 89.2% | 88.5% | 89.2% | 98.7% | 98.8% | 99.0% |
| TF-IDF: |
| ε = 3 | 71.7% | 78.3% | 81.0% | 69.5% | 75.4% | 79.1% | 96.8% | 97.0% | 98.0% |
| ε = 8 | 76.4% | 79.2% | 82.6% | 74.9% | 74.5% | 78.3% | 96.8% | 98.2% | 98.2% |
| ε = ∞ | 80.2% | 79.0% | 82.5% | 75.2% | 77.9% | 79.7% | 97.6% | 97.9% | 98.1% |
+
+# 4.1.1 IMDb Movie Reviews
+
+The IMDb movie review dataset consists of movie reviews written by various authors. We use the two binary sentiment labels as attributes to condition our model on and use a random subset of 5,000 reviews for training and evaluation each.
+
+# 4.1.2 Amazon Multi Domain Reviews
+
+The Amazon multi domain review dataset was introduced by Blitzer et al. (2007) and consists of two thousand product reviews from each of the four product categories books, DVDs, electronics and kitchen appliances. Both binarized sentiment labels and the product categories books and electronics serve as attributes we consider. Our resulting training data consists of 3,000 training samples and 1,000 test samples.
+
+# 4.2 Implementation Details
+
+We implement and train our language models using the PyTorch (Paszke et al., 2019) and Hugging Face Transformers (Wolf et al., 2020) libraries and the 1.5B parameter implementation of GPT-2 (Radford et al., 2019). To fine-tune the language models, we employ the "privacy engine" of the private-transformers package by Li et al. (2021). In line with their experiments, we also use DP-Adam (Dong et al., 2019; Bu et al., 2020), a differentially private version of the Adam (Kingma and Ba, 2015) optimizer. The privacy engine allows us to specify desired target privacy parameters $\epsilon$ and $\delta$ , from which the standard deviation parameter $\sigma$ for the Gaussian mechanism is derived using either Renyi DP (Mironov, 2017), the CLT (Dong et al., 2019), or the FFT accountant (Gopi et al., 2021). Following Li et al. (2021), we set $\delta = \frac{1}{2*|D_{train}|}$ and vary the parameter $\epsilon$
+
+Table 2: Accuracy of classification models trained on real data.
+
+ | IMDb | Amazon |
| Sentiment | Sentiment | Product |
| BERT: |
| ε = 3 | 83.6% | 79.5% | 95.2% |
| ε = 8 | 86.7% | 83.4% | 96.6% |
| ε = ∞ | 90.9% | 91.2% | 98.9% |
| TF-IDF: |
| ε = ∞ | 85.5% | 75.8% | 98.6% |
+
+in our experiments. To obtain reliable results for training our generative models on small subsets of the training samples, we sample three random subsets for every size and report averaged results from these three experimental runs. We trained GPT-2 over five epochs when using a differentially private optimizer and merely two epochs when using a non-private optimizer, as the latter tended to overfit quickly on the small training set. To further mitigate this, a smaller learning rate turned out to be more effective for non-private optimization: While we used a learning rate of 8e-6 with DP-Adam, we obtained the best results for non-private optimization with a learning rate of 5e-7. Lastly, we chose the hyperparameter $\lambda := 0.2$ . We generated our synthetic datasets using the original distribution of sentiment and product category attributes, which was $50 / 50$ in all cases. To sample from GPT-2, we use nucleus sampling (Holtzman et al., 2020) with $p = 0.8$ across all experiments. Our results were not obtained through an extensive hyperparameter search but educated guesses over a couple of iterations to avoid large computational effort. All experiments were performed using a NVIDIA Tesla A100 GPU. With this setup, a training epoch over 1,000 text samples took approximately five minutes.
+
+# 4.3 Experimental Results
+
+As stated previously, we aim to synthesize datasets that (1) reflect properties of the original data and can be used to train classifiers that perform similar to those trained on the original data, (2) are private and do not leak information from the original data and (3) are diverse and of high language quality. Accordingly, we perform experiments with metrics maesuring these attributes and report our results in the following:
+
+# 4.3.1 Data Utility
+
+To measure the utility of our datasets, we train classification models for each attribute on both our original data and the generated data and compare their performances when evaluating them on our real test data. Ideally, our anonymized twin datasets should lead to classifiers that are as accurate as those trained on our original data. To account for various settings including those with computational constraints, we train a shallow support vector machine classifier based on Tfidf encodings as well as a deep BERT (Devlin et al., 2019) based classifier with 110M parameters. Furthermore, as an interesting baseline, we evaluate the performance of BERT trained on real data with differentially private optimization using the code from Li et al. (2021). The classification accuracies for models trained on synthetic data are shown in Table 1 and classification accuracies for models trained on real data are shown in 2. In the following, we summarize our key findings:
+
+Synthetic data is almost on par with real data: The performance of classification models trained on generated data only drops minimally compared to those trained on real data. Across all three classification tasks, for both datasets with privacy budgets of $\epsilon = 3$ and $\epsilon = 8$ , the accuracy of BERT and Tf-IDf based models is never less than $3\%$ of the accuracy obtained for real data when given access to all training samples (5,000 and 3,000 for IMDb and Amazon, respectively).
+
+Classifiers trained on synthetic data outperform private classifiers trained on real data: Notably, when comparing the results of transformer based classifiers trained on our synthetic data (Table 1) to those trained on real data with differentially private optimization (Table 2), we find that the former substantially outperforms the latter
+
+across all tasks for both $\epsilon = 3$ and $\epsilon = 8$ . This raises the question whether the intermediate step of private data generation should always be performed rather than training classifiers with DP-SGD.
+
+Private data generation shows high utility in few-shot settings: Lastly, even when given only as little as 25 or 50 samples, GPT-2 can generate datasets that lead to high-performing classifiers, which can most likely be attributed to the utilization of pretraining knowledge through our prompting techniques. Therefore, beyond the anonymization of existing datasets, our method can be used to enlarge existing small datasets in a private manner.
+
+# 4.3.2 Data Privacy
+
+To the best of our knowledge, methods aiming to measuring the privacy of textual data are an active area of research (Carlini et al., 2021; Brown et al., 2022) and there is no standardized and agreed upon way to do so. In our experiments, we follow Carlini et al. (2021) by counting the number of instances in which our synthetic dataset contains samples that are extremely close to a sample from the training data and can therefore be considered a duplicate: For every sample $\pmb{x}_i$ from our training data used for the language model and every $\pmb{x}_j \in \widetilde{D}_{\mathrm{train}}$ , we measure the set of trigrams $\mathbf{g}_3(\pmb{x}_i)$ , $\mathbf{g}_3(\pmb{x}_j)$ . We consider the two samples as duplicates if
+
+$$
+| \mathrm {g} _ {3} (\boldsymbol {x} _ {i}) \cup \mathrm {g} _ {3} (\boldsymbol {x} _ {j}) | \geq 2 * \min (| \mathrm {g} _ {3} (\boldsymbol {x} _ {i}) |, | \mathrm {g} _ {3} (\boldsymbol {x} _ {j}) |)
+$$
+
+As we hypothesize that duplicates are relatively rare, we double the generated data compared to our utility experiments and search for them within 10,000 and 6,000 samples generated for the IMDb and Amazon dataset, respectively. Our results are depicted in Table 3 and demonstrate the significant reduction of data leakage from privately trained models.
+
+| # Samples | IMDb | Amazon |
| 25 | 50 | 5000 | 25 | 50 | 3000 |
| ε = 3 | 1 | 0 | 1 | 0 | 0 | 0 |
| ε = 8 | 0 | 6 | 2 | 4 | 1 | 0 |
| ε = ∞ | 8 | 23 | 13 | 16 | 30 | 9 |
+
+Table 3: Number of duplicates from the training data generated by language models
+
+# 4.3.3 Language Quality
+
+As a metric measuring the quality of our generated samples, we use the Mauve $^4$ (Pillutla et al.,
+
+2021) score to compute the similarity of the distributions of $\mathcal{D}_{\mathrm{train}}$ and the generated data $\widetilde{\mathcal{D}}_{\mathrm{train}}$ from every trained model. As can be seen in Table 4, higher $\epsilon$ values tend to increase the quality measured by Mauve, but overall seem not to be highly significant. As a reference, the Mauve score computed when comparing $\mathcal{D}_{\mathrm{train}}$ and $\mathcal{D}_{\mathrm{test}}$ are 0.95 for IMDb and 0.94 for Amazon. Based on manual inspection, the quality of generated texts seems to be very high. Mismatches between prompts and generated texts (e.g. a negative review generated for a positive prompt) as well as incoherent generations do occur, but very rarely. Excerpts of the generated data can be seen in Table 5, failure cases can be found in Table 6 and 7 in the appendix.
+
+| # Samples | IMDb | Amazon |
| 25 | 50 | 5000 | 25 | 50 | 3000 |
| ε = 3 | 0.81 | 0.83 | 0.81 | 0.82 | 0.81 | 0.83 |
| ε = 8 | 0.82 | 0.81 | 0.81 | 0.82 | 0.81 | 0.82 |
| ε = ∞ | 0.81 | 0.85 | 0.84 | 0.84 | 0.85 | 0.82 |
+
+Table 4: Mauve scores measuring the similarity of generated data and $\mathcal{D}_{train}$ .
+
+# 5 Related Work
+
+# 5.1 Text Anonymization
+
+Substantial efforts have been made to enable the privacy-preserving processing of textual data through both private textual vector representations and by transforming text into readable anonymous formats. Approaches from the former category either aim at obtaining term frequency vectors using differentially private mechanisms (Weggenmann and Kerschbaum, 2018; Fernandes et al., 2019) or by using deep learning methods with adversarial training objectives (Coavoux et al., 2018). In the work by Qu et al. (2021), various local DP mechanisms are explored to obtain private BERT representations.
+
+Methods aiming at rewriting texts in a privacy-preserving manner range from rule-based approaches using human-engineered text perturbations (Mahmood et al., 2019; Bevendorff et al., 2019) as well as word replacements through the perturbation of individual word embeddings using differential privacy (Feyisetan et al., 2019b, 2020b) to deep learning based approaches leveraging sequence-to-sequence models. These sequence-to-sequence models can either incorporate adversarial objectives penalizing the generation of author-revealing information (Shetty et al., 2018; Xu et al.,
+
+2019) or integrate differential privacy in the text sampling process (Bo et al., 2021; Weggenmann et al., 2022; Mattern et al., 2022).
+
+Notably, various papers proposing the integration of differentially private mechanisms in deep learning architectures (Krishna et al., 2021; Beigi et al., 2019a,b; Alnasser et al., 2021) have been shown to actually violate differential privacy (Habernal, 2021, 2022). While these works still represent important contributions due to their good empirical results, it should be noted that the design of NLP systems with DP guarantees is a task that is prone to errors and should be approached carefully.
+
+# 5.2 Differentially Private Language Model Training
+
+As generative language models have been shown to leak training data (Carlini et al., 2021) and the embeddings of discriminative models have been shown to contain sensitive information about a text's originator (Song and Raghunathan, 2020), differentially private optimizers such as DP-SGD (Song et al., 2013b; Bassily et al., 2014b) and DP-Adam (Abadi et al., 2016b; Kingma and Ba, 2014) have been applied to a variety of NLP tasks. Large-scale pretraining of BERT using DP-SGD has shown to reap comparable masked language modeling performance to non-private BERT (Anil et al., 2021). For the tasks of text classification and named entity recognition, good performance has been obtained with BERT and DP-SGD, but only with large privacy budgets of $\epsilon = 100$ or higher. Recently, it has been demonstrated that with the correct choice of hyperparameters and fine-tuning objectives aligned with the pretraining procedure, both generative and discriminative language models can achieve high performance in various tasks even with stricter privacy bounds (Li et al., 2021; Yu et al., 2022). An active area of research is concerned with the empirical evaluation of a language model's privacy (Brown et al., 2022) using methods such as membership inference attacks (Hayes et al., 2019).
+
+# 5.3 Synthetic Data Generation:
+
+Synthetic data generation with privacy guarantees using methods such as DP-GAN (Xie et al., 2018), PATE-GAN (Jordon et al., 2018) or various related approaches has successfully been applied for structured tabular or visual data (Torkzadehmahani et al., 2019; Neunhoeffer et al., 2020; Chen et al., 2020). Beyond these methods, DPRP (Differen
+
+Table 5: Exemplary generated samples from models trained with only 25 text samples. The texts were selected by picking a random sample from $\mathcal{D}_{test}$ and finding the most similar one according to Sentence-BERT (Reimers and Gurevych, 2019) within the generated data.
+
+| Amazon (Category=Electronics, Sentiment=Positive) |
| Original | I'm not any expert in the computer world. But this product it is very easy to install. The range is very strong. I'm very happy with this product!!! |
| ε = 3 | I really like this. It works great. The speed is a bit slow. But, after I learned that this is how a good keyboard feels. I can't say enough good things about this keyboard. |
| ε = 8 | This is a good piece of equipment. It is small, has a high quality and a reasonable price. I used it to test the sound from my computer monitor. I am happy with the sound. |
| ε = ∞ | I got this game to play on my PSP as a little side project. I'm quite happy with it. The graphics are pretty good and the story line is pretty entertaining, as well. |
| Amazon (Category=Books, Sentiment=Negative) |
| Original | Good Lord, people must be busier than I thought. If you haven't been allowed to even think about your future after retirement, then maybe you will get something out of this book. For the rest of us, this is drivel |
| ε = 3 | I have been looking for an awesome, fun, easy to read book, like a classic from when I was a kid. I am very disappointed. It is not a fun read. It really is a bore. I have read the sequel, and am also disappointed. This is not one of those things that you read to pass the time. Not a good choice for a first book. |
| ε = 8 | I would've done better with another book I read. The plot is interesting but the characters are bland and the setting is really only a backdrop to the action and plot. It's a shame as I enjoyed the book, but this isn't a good read. |
| ε = ∞ | This book was boring, boring, and boring. I have been thinking about getting a new copy of this book ever since I read it, but this one didn't work for me at all. Not a bad idea, just not my cup of tea. |
+
+tially Private Data Release via Random Projections) (Gondara and Wang, 2020) has been proposed as a model free alternative for releasing small private datasets that does not require training a generative model. For the domain of text, synthetic data generation techniques have predominantly been developed and evaluated without considering privacy guarantees (Anaby-Tavor et al., 2020; Schick and Schütze, 2021b). Merely the work presented by Bommasani et al. (2019) is similar to our paper, but does not provide any quantitative results about the experiments.
+
+# 6 Conclusion
+
+In this paper, we explored the generation of synthetic datasets from differentially private language models as a solution for publicly sharing textual data while protecting the privacy of users whose data is being shared. Our experiments show that synthetic data from differentially private language models is of high quality and is very well suited as training data for further tasks while significantly reducing the risk of leaking the original data. Our approach can be applied in a variety of use cases
+
+working with sensitive data. An interesting challenge for future work is the anonymization of multimodal datasets consisting of tabular, visual and text data.
+
+# Limitations
+
+Privacy Guarantee While differential privacy provides a statistical privacy guarantee, one can not be certain that a differentially private language model does not leak any sensitive information. As seen in our experiments, the differentially private models did leak some of their training data, even if significantly less than the non-private ones. This can be a concern when dealing with training data containing names, telephone numbers or even passwords.
+
+Synthetic Data Quality As shown in Table 6 and 7, our models did in rare cases produce incoherent language or text samples that did not fit the desired control attributes. This can limit the quality of the generated data.
+
+Limits of Controllable Generation The controllability of multiple fine-grained textual attributes in text generation remains a difficult challenge Lyu et al. (2021). We therefore need to assume that our approach will become less accurate the higher the amount of textual attributes we want to consider.
+
+# Ethical Considerations
+
+Data privacy is a highly important issue for the responsible deployment of machine learning solutions. With our work, we directly contribute to this field of research.
+
+As our method relies on large pretrained language models, it should be noted that users deploying these technologies need to be aware of their undesirable, human-like biases (Sheng et al., 2019; Abid et al., 2021). Methods for reducing these harmful associations are actively being developed by the research community (Liang et al., 2021; Schick et al., 2021).
+
+# Acknowledgments
+
+This material is based in part upon works supported by the German Federal Ministry of Education and Research (BMBF): Tübingen AI Center, FKZ: 01IS18039B; by the German Federal Ministry for Economic Affairs and Climate Action (BMWK) in the project Trade-EVs II, FKZ: 01MV20006A; by the Machine Learning Cluster of Excellence, EXC number 2064/1 - Project number 390727645; by the John Templeton Foundation (grant #61156); by a Responsible AI grant by the Haslerstiftung; and an ETH Grant (ETH-19 21-1). Zhijing Jin is supported by PhD fellowships from the Future of Life Institute and Open Philanthropy, as well as the travel support from ELISE (GA no 951847) for the ELLIS program. We also thank OpenAI Researcher Access Program for granting our team credits to their API.
+
+# References
+
+Martin Abadi, Andy Chu, Ian Goodfellow, H. Brendan McMahan, Ilya Mironov, Kunal Talwar, and Li Zhang. 2016a. Deep learning with differential privacy. In Proceedings of the 2016 ACM SIGSAC Conference on Computer and Communications Security, CCS '16, page 308-318, New York, NY, USA. Association for Computing Machinery.
+Martin Abadi, Andy Chu, Ian Goodfellow, H. Brendan McMahan, Ilya Mironov, Kunal Talwar, and Li Zhang. 2016b. Deep learning with differential
+
+privacy. In Proceedings of the 2016 ACM SIGSAC Conference on Computer and Communications Security, CCS '16, page 308-318, New York, NY, USA. Association for Computing Machinery.
+Abubakar Abid, Maheen Farooqi, and James Zou. 2021. Persistent anti-muslim bias in large language models. In Proceedings of the 2021 AAAI/ACM Conference on AI, Ethics, and Society, pages 298-306.
+Walaa Alnasser, Ghazaleh Beigi, and Huan Liu. 2021. Privacy preserving text representation learning using bert. In Social, Cultural, and Behavioral Modeling, pages 91-100, Cham. Springer International Publishing.
+Ateret Anaby-Tavor, Boaz Carmeli, Esther Goldbraich, Amir Kantor, George Kour, Segev Shlomov, Naama Tepper, and Naama Zwerdling. 2020. Do not have enough data? deep learning to the rescue! Proceedings of the AAAI Conference on Artificial Intelligence, 34(05):7383-7390.
+Rohan Anil, Badih Ghazi, Vineet Gupta, Ravi Kumar, and Pasin Manurangsi. 2021. Large-scale differentially private bert.
+Raef Bassily, Adam Smith, and Abhradeep Thakurta. 2014a. Private empirical risk minimization: Efficient algorithms and tight error bounds. In 2014 IEEE 55th Annual Symposium on Foundations of Computer Science, pages 464-473. IEEE.
+Raef Bassily, Adam Smith, and Abhradeep Thakurta. 2014b. Private empirical risk minimization: Efficient algorithms and tight error bounds. In 2014 IEEE 55th Annual Symposium on Foundations of Computer Science, pages 464-473.
+Ghazaleh Beigi, Kai Shu, Ruocheng Guo, Suhang Wang, and Huan Liu. 2019a. I am not what i write: Privacy preserving text representation learning.
+Ghazaleh Beigi, Kai Shu, Ruocheng Guo, Suhang Wang, and Huan Liu. 2019b. Privacy preserving text representation learning. In Proceedings of the 30th ACM Conference on Hypertext and Social Media, HT '19, page 275-276, New York, NY, USA. Association for Computing Machinery.
+Janek Bevendorff, Martin Potthast, Matthias Hagen, and Benno Stein. 2019. Heuristic authorship obfuscation. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 1098-1108, Florence, Italy. Association for Computational Linguistics.
+John Blitzer, Mark Dredze, and Fernando Pereira. 2007. Biographies, Bollywood, boom-boxes and blenders: Domain adaptation for sentiment classification. In Proceedings of the 45th Annual Meeting of the Association of Computational Linguistics, pages 440-447, Prague, Czech Republic. Association for Computational Linguistics.
+
+Haohan Bo, Steven H. H. Ding, Benjamin C. M. Fung, and Farkhund Iqbal. 2021. ER-AE: Differentially private text generation for authorship anonymization. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 3997-4007, Online. Association for Computational Linguistics.
+Rishi Bommasani, Steven Wu, and Xanda Schofield. 2019. Towards private synthetic text generation. In NeurIPS 2019 Machine Learning with Guarantees Workshop.
+Hannah Brown, Katherine Lee, Fatemehsadat Mireshghallah, Reza Shokri, and Florian Tramér. 2022. What does it mean for a language model to preserve privacy?
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Advances in Neural Information Processing Systems, volume 33, pages 1877-1901. Curran Associates, Inc.
+Zhiqi Bu, Jinshuo Dong, Qi Long, and Weijie J Su. 2020. Deep learning with gaussian differential privacy. Harvard data science review, 2020(23).
+Mark Bun and Thomas Steinke. 2016. Concentrated differential privacy: Simplifications, extensions, and lower bounds. In Theory of Cryptography Conference, pages 635-658. Springer.
+Nicholas Carlini, Florian Tramér, Eric Wallace, Matthew Jagielski, Ariel Herbert-Voss, Katherine Lee, Adam Roberts, Tom Brown, Dawn Song, Ülfar Erlingsson, Alina Oprea, and Colin Raffel. 2021. Extracting training data from large language models. In 30th USENIX Security Symposium (USENIX Security 21), pages 2633-2650. USENIX Association.
+Dingfan Chen, Tribhuvanesh Orekondy, and Mario Fritz. 2020. Gs-wgan: A gradient-sanitized approach for learning differentially private generators. In Proceedings of the 34th International Conference on Neural Information Processing Systems, NIPS'20, Red Hook, NY, USA. Curran Associates Inc.
+Maximin Coavoux, Shashi Narayan, and Shay B. Cohen. 2018. Privacy-preserving neural representations of text. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 1-10, Brussels, Belgium. Association for Computational Linguistics.
+
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Jinshuo Dong, Aaron Roth, and Weijie J Su. 2019. Gaussian differential privacy. arXiv preprint arXiv:1905.02383.
+J. C. Duchi, M. I. Jordan, and M. J. Wainwright. 2013. Local privacy and statistical minimax rates. In 2013 IEEE 54th Annual Symposium on Foundations of Computer Science, pages 429-438.
+C. Dwork, F. McSherry, K. Nissim, and A. Smith. 2006a. Calibrating noise to sensitivity in private data analysis. In Theory of Cryptography Conference, pages 265-284. Springer.
+Cynthia Dwork, Krishnaram Kenthapadi, Frank McSherry, Ilya Mironov, and Moni Naor. 2006b. Our data, ourselves: Privacy via distributed noise generation. In Annual international conference on the theory and applications of cryptographic techniques, pages 486-503. Springer.
+Cynthia Dwork and Aaron Roth. 2014. The Algorithmic Foundations of Differential Privacy, volume 9. Now Publishers Inc., Hanover, MA, USA.
+Cynthia Dwork and Guy N Rothblum. 2016. Concentrated differential privacy. arXiv preprint arXiv:1603.01887.
+Cynthia Dwork, Guy N Rothblum, and Salil Vadhan. 2010. Boosting and differential privacy. In 2010 IEEE 51st Annual Symposium on Foundations of Computer Science, pages 51-60. IEEE.
+Mael Fabien, Esau Villatoro-Tello, Petr Moticek, and Shantipriya Parida. 2020. BertAA: BERT fine-tuning for authorship attribution. In Proceedings of the 17th International Conference on Natural Language Processing (ICON), pages 127-137, Indian Institute of Technology Patna, Patna, India. NLP Association of India (NLPAI).
+Natasha Fernandes, Mark Dras, and Annabelle McIver. 2019. Generalised differential privacy for text document processing. In International Conference on Principles of Security and Trust, pages 123-148. Springer.
+Oluwaseyi Feyisetan, Borja Balle, Thomas Drake, and Tom Diethe. 2020a. Privacy- and Utility-Preserving Textual Analysis via Calibrated Multivariate Perturbations, page 178–186. Association for Computing Machinery, New York, NY, USA.
+
+Oluwaseyi Feyisetan, Borja Balle, Thomas Drake, and Tom Diethe. 2020b. Privacy-and utility-preserving textual analysis via calibrated multivariate perturbations. In Proceedings of the 13th International Conference on Web Search and Data Mining, pages 178-186.
+Oluwaseyi Feyisetan, Tom Diethe, and Thomas Drake. 2019a. Leveraging hierarchical representations for preserving privacy and utility in text. In 2019 IEEE International Conference on Data Mining (ICDM), pages 210-219.
+Oluwaseyi Feyisetan, Tom Diethe, and Thomas Drake. 2019b. Leveraging hierarchical representations for preserving privacy and utility in text. In 2019 IEEE International Conference on Data Mining (ICDM), pages 210-219. IEEE.
+Lovedeep Gondara and Ke Wang. 2020. Differentially private small dataset release using random projections. In Proceedings of the 36th Conference on Uncertainty in Artificial Intelligence (UAI), volume 124 of Proceedings of Machine Learning Research, pages 639-648. PMLR.
+Sivakanth Gopi, Yin Tat Lee, and Lukas Wutschitz. 2021. Numerical composition of differential privacy. In Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual, pages 11631-11642.
+Ivan Habernal. 2021. When differential privacy meets nlp: The devil is in the detail. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1522-1528.
+Ivan Habernal. 2022. How reparametrization trick broke differentially-private text representation learning.
+Jamie Hayes, Luca Melis, George Danezis, and Emiliano De Cristofaro. 2019. Logan: Membership inference attacks against generative models. In Proceedings on Privacy Enhancing Technologies (PoPETs), volume 2019, pages 133-152. De Gruyter.
+Ari Holtzman, Jan Buys, Li Du, Maxwell Forbes, and Yejin Choi. 2020. The curious case of neural text degeneration. In International Conference on Learning Representations.
+James Jordon, Jinsung Yoon, and Mihaela Van Der Schaar. 2018. Pate-gan: Generating synthetic data with differential privacy guarantees. In International conference on learning representations.
+Peter Kairouz, Sewoong Oh, and Pramod Viswanath. 2015. The composition theorem for differential privacy. In Proceedings of the 32nd International Conference on Machine Learning, volume 37 of Proceedings of Machine Learning Research, pages 1376-1385, Lille, France. PMLR.
+Diederik P. Kingma and Jimmy Ba. 2014. Adam: A method for stochastic optimization.
+
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
+Moshe Koppel, Jonathan Schler, and Shlomo Argamon. 2009. Computational methods in authorship attribution. Journal of the American Society for information Science and Technology, 60(1):9-26.
+Antti Koskela, Joonas Jälkö, and Antti Honkela. 2020. Computing tight differential privacy guarantees using FFT. In The 23rd International Conference on Artificial Intelligence and Statistics, AISTATS 2020, 26-28 August 2020, Online [Palermo, Sicily, Italy], volume 108 of Proceedings of Machine Learning Research, pages 2560-2569. PMLR.
+Satyapriya Krishna, Rahul Gupta, and Christophe Dupuy. 2021. ADePT: Auto-encoder based differentially private text transformation. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 2435–2439, Online. Association for Computational Linguistics.
+Wei-Han Lee, Changchang Liu, Shouling Ji, Prateek Mittal, and Ruby B. Lee. 2017. Blind de-onymization attacks using social networks. In Proceedings of the 2017 on Workshop on Privacy in the Electronic Society, WPES '17, page 1-4, New York, NY, USA. Association for Computing Machinery.
+Xuechen Li, Florian Tramér, Percy Liang, and Tatsunori Hashimoto. 2021. Large language models can be strong differentially private learners.
+Paul Pu Liang, Chiyu Wu, Louis-Philippe Morency, and Ruslan Salakhutdinov. 2021. Towards understanding and mitigating social biases in language models. In International Conference on Machine Learning, pages 6565–6576. PMLR.
+Yiwei Lyu, Paul Pu Liang, Hai Pham, Eduard Hovy, Barnabás Póczos, Ruslan Salakhutdinov, and Louis-Philippe Morency. 2021. StylePTB: A compositional benchmark for fine-grained controllable text style transfer. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2116-2138, Online. Association for Computational Linguistics.
+Asad Mahmood, Faizan Ahmad, Zubair Shafiq, Padmini Srinivasan, and Fareed Zaffar. 2019. A girl has no name: Automated authorship obfuscation using mutant-x. Proceedings on Privacy Enhancing Technologies, 2019(4):54-71.
+Justus Mattern, Benjamin Weggenmann, and Florian Kerschbaum. 2022. The limits of word level differential privacy.
+Ilya Mironov. 2017. Rényi differential privacy. In 2017 IEEE 30th Computer Security Foundations Symposium (CSF), pages 263-275.
+
+Jack Murtagh and Salil Vadhan. 2016. The complexity of computing the optimal composition of differential privacy. In Theory of Cryptography Conference, pages 157-175. Springer.
+Arvind Narayanan and Vitaly Shmatikov. 2008. Robust de-anonymization of large sparse datasets. In 2008 IEEE Symposium on Security and Privacy (sp 2008), pages 111-125.
+Marcel Neunhoeffer, Steven Wu, and Cynthia Dwork. 2020. Private post-gan boosting. In International Conference on Learning Representations.
+Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, Alban Desmaison, Andreas Kopf, Edward Yang, Zachary DeVito, Martin Raison, Alykhan Tejani, Sasank Chilamkurthy, Benoit Steiner, Lu Fang, Junjie Bai, and Soumith Chintala. 2019. Pytorch: An imperative style, high-performance deep learning library. In Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc.
+Krishna Pillutla, Swabha Swayamdipta, Rowan Zellers, John Thickstun, Sean Welleck, Yejin Choi, and Zaid Harchaoui. 2021. Mauve: Measuring the gap between neural text and human text using divergence frontiers. Advances in Neural Information Processing Systems, 34.
+Chen Qu, Weize Kong, Liu Yang, Mingyang Zhang, Michael Bendersky, and Marc Najork. 2021. Natural Language Understanding with Privacy-Preserving BERT, page 1488-1497. Association for Computing Machinery, New York, NY, USA.
+Alec Radford, Jeff Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. 2019. Language models are unsupervised multitask learners.
+Nils Reimers and Iryna Gurevych. 2019. SentenceBERT: Sentence embeddings using Siamese BERTnetworks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3982-3992, Hong Kong, China. Association for Computational Linguistics.
+Timo Schick and Hinrich Schütze. 2021a. Few-shot text generation with natural language instructions. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 390-402, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Timo Schick and Hinrich Schütze. 2021b. Generating datasets with pretrained language models. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 6943-6951.
+
+Timo Schick, Sahana Udupa, and Hinrich Schütze. 2021. Self-Diagnosis and Self-Debiasing: A Proposal for Reducing Corpus-Based Bias in NLP. Transactions of the Association for Computational Linguistics, 9:1408-1424.
+Emily Sheng, Kai-Wei Chang, Premkumar Natarajan, and Nanyun Peng. 2019. The woman worked as a babysitter: On biases in language generation. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3407-3412, Hong Kong, China. Association for Computational Linguistics.
+Rakshith Shetty, Bernt Schiele, and Mario Fritz. 2018. A4NT: Author attribute anonymity by adversarial training of neural machine translation. In 27th USENIX Security Symposium (USENIX Security 18), pages 1633-1650, Baltimore, MD. USENIX Association.
+Prasha Shrestha, Sebastian Sierra, Fabio González, Manuel Montes, Paolo Rosso, and Thamar Solorio. 2017. Convolutional neural networks for authorship attribution of short texts. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers, pages 669-674, Valencia, Spain. Association for Computational Linguistics.
+David M Sommer, Sebastian Meiser, and Esfandiar Mohammadi. 2019. Privacy loss classes: The central limit theorem in differential privacy. Proceedings on privacy enhancing technologies, 2019(2):245-269.
+Congzheng Song and Ananth Raghunathan. 2020. Information Leakage in Embedding Models, page 377-390. Association for Computing Machinery, New York, NY, USA.
+Shuang Song, Kamalika Chaudhuri, and Anand D Sarwate. 2013a. Stochastic gradient descent with differentially private updates. In 2013 IEEE Global Conference on Signal and Information Processing, pages 245-248. IEEE.
+Shuang Song, Kamalika Chaudhuri, and Anand D. Sarwate. 2013b. Stochastic gradient descent with differentially private updates. In 2013 IEEE Global Conference on Signal and Information Processing, pages 245-248.
+Reihaneh Torkzadehmahani, Peter Kairouz, and Benedict Paten. 2019. Dp-cgan: Differentially private synthetic data and label generation. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) Workshops.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc.
+
+Stanley L Warner. 1965. Randomized response: A survey technique for eliminating evasive answer bias. Journal of the American Statistical Association, 60(309):63-69.
+
+Benjamin Weggenmann and Florian Kerschbaum. 2018. SynTF: Synthetic and differentially private term frequency vectors for privacy-preserving text mining. In The 41st International ACM SIGIR Conference on Research & Development in Information Retrieval, SIGIR '18, page 305-314, New York, NY, USA. Association for Computing Machinery.
+
+Benjamin Weggenmann, Valentin Rubblack, Michael Andrejczuk, Justus Mattern, and Florian Kerschbaum. 2022. DP-VAE: Human-readable text anonymization for online reviews with differentially private variational autoencoders. In Proceedings of the ACM Web Conference 2022, WWW '22, page 721-731, New York, NY, USA. Association for Computing Machinery.
+
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumond, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+
+Liyang Xie, Kaixiang Lin, Shu Wang, Fei Wang, and Jiayu Zhou. 2018. Differentially private generative adversarial network.
+
+Qiongkai Xu, Lizhen Qu, Chenchen Xu, and Ran Cui. 2019. Privacy-aware text rewriting. In Proceedings of the 12th International Conference on Natural Language Generation, pages 247-257, Tokyo, Japan. Association for Computational Linguistics.
+
+Da Yu, Saurabh Naik, Arturs Backurs, Sivakanth Gopi, Huseyin A Inan, Gautam Kamath, Janardhan Kulkarni, Yin Tat Lee, Andre Manoel, Lukas Wutschitz, Sergey Yekhanin, and Huishuai Zhang. 2022. Differentially private fine-tuning of language models. In International Conference on Learning Representations.
+
+# A Failure Cases
+
+We demonstrate manually selected failure cases in Tables 6 and 7. Generated texts from Table 6 do not reflect the attributes passed in the prompt accurately and would therefore correspond to wrongly labeled samples in our dataset. Table 7 features generated texts that contain logical or language errors.
+
+Table 6: Failure cases in which the generated text does not fit the desired attributes. Model mistakes are marked in red.
+
+| # Train Samples | ε | Desired Attributes | Text |
| 25 | 3 | Category=Books Sentiment = Negative | I have read and enjoyed many of your books, but I can’t recommend this one highly enough. I am not a big fan of vampires. They don’t interest me at all This book, however, did. It was a fun, entertaining read. I loved the characters. I really didn’t care if I was going to be able to go back in time to help save the future, or if I would be in for the long haul. There was a lot of tension throughout the book. I was glad I was able to finish it. I’m glad that I was not as upset with it as many others were. I gave this book a solid 5 stars. |
| 50 | 3 | Category=Books Sentiment = Negative | I was looking for a book on how to be a good leader and found it by chance. It seems that no matter how bad you have been, how bad things have gotten, or how terrible a person you are, a leader can still turn it around. |
| 50 | 3 | Category=Books Sentiment = Positive | I am not a huge fan of the Star Wars films but I really enjoyed this one. It is the first time I’ve ever seen the Star Trek movies and I enjoyed them as well. The plot is a bit different then you’d expect from a Star Trek story but I enjoyed it all the same. |
| 50 | 8 | Category=Electronics Sentiment = Negative | I have a brand new LG Electronics Vivid 5, and so far I’m very happy. The screen has a nice clear picture and has great picture quality, the speakers are good, the microphone is not great, the battery is adequate, and it’s nice and light. This is the first of the Vivid series I have bought, and I’m glad I got one. |
+
+Table 7: Failure cases in which the generated text is incoherent or does not make sense. Model mistakes are marked in red.
+
+| # Train Samples | ε | Desired Attributes | Text |
| 50 | ∞ | Category=Electronics
+Sentiment = Negative | The device itself, while very good, is bad. It seems like the software doesn’t
+like to write out its own ID (it should) so the app doesn’t work. I’ve seen
+other users say the same thing and have had no problems. I haven’t bought another
+bluetooth device, but I’m pretty sure it has something to do with it. |
| 25 | 8 | Category=Books
+Sentiment = Positive | I really enjoyed this book. I didn’t get the full explanation as I am only
+a beginner but for beginners with the basic knowledge of a math and physics
+the theory is very sound. 2.0 stars. |
| 4,000 | ∞ | Category=Books
+Sentiment = Negative | This book is a compilation of some of my personal thoughts and ideas.
+The author’s goal was to make me believe in witchcraft, but he
+completely failed. |
| 50 | 8 | Category=Electronics
+Sentiment = Positive | This is the best little portable guitar i’ve bought since the little portable
+juke box on a bike. The high quality quality quality of this product is great .
+I do wish i had bought a sooner the old jukebox but once you
+get it together its really nice to have. |
\ No newline at end of file
diff --git a/differentiallyprivatelanguagemodelsforsecuredatasharing/images.zip b/differentiallyprivatelanguagemodelsforsecuredatasharing/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..8aec62ad0d16813ab8556dd57e844ef9623d22b3
--- /dev/null
+++ b/differentiallyprivatelanguagemodelsforsecuredatasharing/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:49d89ae2e806ed4626d1600cd3af714e0a330bea0e831f6720e9046d82e93e89
+size 620787
diff --git a/differentiallyprivatelanguagemodelsforsecuredatasharing/layout.json b/differentiallyprivatelanguagemodelsforsecuredatasharing/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..19accc40c6a2ceea5d1e8e993ecbf2d44bb5b586
--- /dev/null
+++ b/differentiallyprivatelanguagemodelsforsecuredatasharing/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:79d4c05386c74730045cdc1fbc84a10d0fd0ecd47152ac0d7fde259f8801779a
+size 417844
diff --git a/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_content_list.json b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..910615d22d59bf4796d1822805d998095deb5367
--- /dev/null
+++ b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:933e40abb74bbbd90664ef6efe5ef520e87af1590accd6eeb08063769b2a30d8
+size 132253
diff --git a/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_model.json b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..6e3d3287db1ac8ca7865e2116dc4dd6007518ce6
--- /dev/null
+++ b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:28270f0bcb86d763f099ac7f04986cbc6cfbedc78d55fffb0e6b55947f072c1b
+size 158334
diff --git a/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_origin.pdf b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..ed7c899e205ba5a988d2d4e9e186db4a2b6ecb08
--- /dev/null
+++ b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/4ad14922-54e4-4d80-9a67-bb7e19316021_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1919db94db93ce0ce4984d55b8481b720d7b51d2fbc2c8ab4af4e388e7548dcb
+size 521819
diff --git a/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/full.md b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..0e123c530caf36efe48d236ad33d74016eee2251
--- /dev/null
+++ b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/full.md
@@ -0,0 +1,626 @@
+# Digging Errors in NMT: Evaluating and Understanding Model Errors from Partial Hypothesis Space
+
+Jianhao Yan*
+
+WeChat AI, Tencent, China
+
+elliotttyan37@gmail.com
+
+Fandong Meng
+
+WeChat AI, Tencent, China
+
+fandongmeng@tencent.com
+
+# Abstract
+
+Solid evaluation of neural machine translation (NMT) is key to its understanding and improvement. Current evaluation of an NMT system is usually built upon a heuristic decoding algorithm (e.g., beam search) and an evaluation metric assessing similarity between the translation and golden reference. However, this system-level evaluation framework is limited by evaluating only one best hypothesis and search errors brought by heuristic decoding algorithms. To better understand NMT models, we propose a novel evaluation protocol, which defines model errors with model's ranking capability over hypothesis space. To tackle the problem of exponentially large space, we propose two approximation methods, top region evaluation along with an exact top- $k$ -decoding algorithm, which finds top-ranked hypotheses in the whole hypothesis space, and Monte Carlo sampling evaluation, which simulates hypothesis space from a broader perspective. To quantify errors, we define our NMT model errors by measuring distance between the hypothesis array ranked by the model and the ideally ranked hypothesis array. After confirming the strong correlation with human judgment, we apply our evaluation to various NMT benchmarks and model architectures. We show that the state-of-the-art Transformer models face serious ranking issues and only perform at the random chance level in the top region. We further analyze model errors on architectures with different depths and widths, as well as different data-augmentation techniques, showing how these factors affect model errors. Finally, we connect model errors with the search algorithms and provide interesting findings of beam search inductive bias and correlation with Minimum Bayes Risk (MBR) decoding. $^{1}$
+
+Chenming Wu*
+
+Tencent, China
+
+wcm1994@gmail.com
+
+Jie Zhou
+
+WeChat AI, Tencent, China
+
+withtomzhou@tencent.com
+
+# 1 Introduction
+
+Sequence-to-sequence models (Sutskever et al., 2014; Vaswani et al., 2017) have shown promising results in neural machine translation (NMT), where methods typically frame a conditional probability distribution from a source sentence to a target sentence. One key to the booming of neural machine translation is the sound evaluation, which shows the trajectory to a better model design and architecture. The commonly used evaluation protocol of an NMT system comprises two main components: a search algorithm and an evaluation metric. The algorithm is responsible for decoding a translated sentence, and the metric computes the discrepancy between the generated translation and the reference.
+
+The above evaluation protocol is preferred as it is consistent with what we serve in production NMT. It has an underlying assumption that the gap between an NMT model and the ideal model can be depicted by the gap between decoded translations and references. However, this assumption does not always hold. Recent literature (Stahlberg and Byrne, 2019; Meister et al., 2020) points out that search errors brought by heuristic decoding methods would hide huge flaws of NMT models (model errors). The empty string is commonly scored with the highest probability among the model's probabilities over all hypotheses. Thus, disentanglement between search algorithms and NMT models is necessary for evaluating NMT systems.
+
+Previous approaches disentangle search errors and model errors. However, they only take the mode $^2$ of the hypothesis space, i.e., all hypothesis accompanied with their probabilities, to evaluate model errors, which is not comprehensive. We ask two research questions:
+
+- Q1: How to define a more comprehensive eval
+
+uation over the hypothesis space?
+
+- Q2: With such evaluation, how do different architecture/data augmentation/search methods affect model errors?
+
+To answer these questions, we introduce a new paradigm to evaluate model errors in hypothesis space. The decoding and evaluation of model errors need to fit the requirements of the new paradigm. For the decoding algorithm, it should be both exact (not affected by search errors) and able to access more representative part of hypothesis space. For the evaluation, it is essential to identify how good or bad these parts are quantitatively. Particularly, to deal with prohibitively large search space, we introduce two approximations: the top region evaluation, alongside with an exact top- $k$ decoding algorithm that not only avoids search errors but can access the top-ranked region of the whole hypothesis space, and the Monte Carlo sampling based evaluation. In addition, we provide formal definitions of evaluation in hypothesis space. We use hypothesis ranking (HR) as a proxy for measuring the distance between the model's hypothesis space and ideal hypothesis space.
+
+After confirming the strong correlation between our evaluation and human judgment, extensive experiments are conducted over three machine translation benchmarks with small, medium, and large sizes. We apply our proposed evaluation as a useful tool to analyze models and search algorithms. We identify that the state-of-the-art Transformer models have weak hypothesis ranking abilities only about the random chance level in the top region. We further analyze model errors on models with different depths and widths, as well as applied with different data-augmentation techniques, showing how these affect model errors. In addition, we connect our model errors with search algorithms. Specifically, with our top-region evaluation, we provide quantitative results on beam search's lucky biases. With sampling-based evaluation, we show it correlates well with the promising minimum risk decoding.3
+
+Our contributions can be summarized as follows.
+
+- We propose an NMT model error evaluation over hypothesis space, with two approximated solutions addressing the prohibitively large hypothesis space and corresponding hypothesis-ranking (HR) metrics.
+
+- We conduct in-depth analysis over various NMT techniques and find that the state-of-the-art Transformer models face severe hypothesis-ranking problems with abilities at the random chance level in top region.
+- We show that our evaluation is effective in analyzing the beam search's lucky biases and correlates well with the MBR decoding.
+
+# 2 Definitions
+
+We first introduce definitions of system level, hypothesis mode and hypothesis space evaluations.
+
+# 2.1 NMT Model and Hypothesis Space
+
+Give an NMT model $M$ , a source sentence $x$ and a reference sentence $\hat{y}$ . Most of the NMT models are auto-regressive models, which define a conditional distribution for a hypothesis $y_{i}$ as:
+
+$$
+\begin{array}{l} P (y _ {i} | x) = \prod_ {t \in (1, T)} P (y _ {i} ^ {t} | x; y _ {i} ^ {1: t - 1}), \\ = M \left(x, y _ {i}\right), \tag {1} \\ \end{array}
+$$
+
+where $t$ represents the time step on target side and $T$ is the total length of $y_{i}$ .
+
+The hypothesis space of $M$ is defined as the set of all hypotheses given by $M$ along with their probabilities,
+
+$$
+\mathcal {Y} = \left\{\left(y _ {i}, P \left(y _ {i} \mid x\right)\right), \forall P \left(y _ {i} \mid x\right) > 0 \right\}, \tag {2}
+$$
+
+and we refer to $\mathcal{V}$ as $M$ 's hypothesis space. 4
+
+# 2.2 System level Evaluation
+
+Given a decoding algorithm $F$ and an evaluation metric such as BLEURT or COMET (Sellam et al., 2020;Rei et al., 2020), the system-level evaluation of an NMT system usually proceeds by first decoding a hypothesis $y^\prime$ from the hypothesis space:
+
+$$
+y ^ {\prime} = F (\mathcal {Y}), \tag {3}
+$$
+
+where $F$ usually selects one or a few translation(s) with the highest step-by-step conditional probabilities from hypothesis space according to the autoregressive modeling. Next, system-level evaluation measures the similarity between $y^\prime$ and reference $\hat{y}$
+
+$$
+S _ {\text {s y s t e m}} = \operatorname {S c o r e} (\hat {y}, y ^ {\prime}). \tag {4}
+$$
+
+# 2.3 Hypothesis Mode Evaluation
+
+It is recognized in previous literature (Niehues et al., 2017; Stahlberg et al., 2018; Stahlberg and Byrne, 2019; Meister et al., 2020) that evaluating an NMT model and the decoding method as a whole system hinders the understanding of NMT model errors. Therefore, Stahlberg and Byrne (2019) propose an exact decoding method that finds the top-1 hypothesis $y_{m}$ over hypothesis distribution (mode) to evaluate model errors:
+
+$$
+y _ {m} = \operatorname {a r g m a x} _ {y \in \mathcal {Y}} (P (\mathcal {Y})), S _ {\mathrm {m e}} = \operatorname {S c o r e} (\hat {y}, y _ {m}). \tag {5}
+$$
+
+They find empty strings usually appear to be the modes of distributions and use the empty rate of modes to quantify the model errors. We call this paradigm the mode-level evaluation in the following sections.
+
+# 2.4 Hypothesis Space Evaluation
+
+Selecting only one hypothesis in the whole hypothesis space loses much information of the hypothesis distribution and makes the evaluation biased. Suppose we have two models A and B. Both of them have the mode hypotheses of empty string " P \left(y _ {j} | x\right) \text {i f} Q \left(y _ {i}\right) > Q \left(y _ {j}\right) \\ \forall y _ {i}, y _ {j} \in \mathcal {Y}, \tag {7} \\ \end{array}
+$$
+
+where $Q(y_{i})$ is the translation quality function (e.g., COMET), and short for $Q(\hat{y}, y_{i})$ .
+
+Hence, by extending such ability from pairwise to all hypotheses of a source sentence $x$ , we define a
+
+proxy for ideal hypothesis space using the perfectly ordered hypothesis array of which the indices are sorted by translation quality. Formally, we define a perfect hypothesis-level ranking (HR) array $\mathcal{V}_{\mathrm{HR}}$ over the hypothesis space $\mathcal{V}$ with,
+
+$$
+\mathcal {Y} _ {\mathrm {H R}} = \left[ y _ {I _ {\mathrm {H R}} ^ {0}}, y _ {I _ {\mathrm {H R}} ^ {1}}, \dots , y I _ {\mathrm {H R}} ^ {n} \right]; \tag {8}
+$$
+
+$$
+I _ {\mathrm {H R}} = \operatorname {a r g s o r t} ([ Q (y _ {1}), \dots , Q (y _ {n}) ]). \tag {9}
+$$
+
+Analogously, we define $\mathcal{V}_{\mathrm{M}}$ as the array sorted by model probabilities,
+
+$$
+\mathcal {Y} _ {\mathrm {M}} = \left[ y _ {I _ {\mathrm {M}} ^ {0}}, y _ {I _ {\mathrm {M}} ^ {1}}, \dots , y _ {I _ {\mathrm {M}} ^ {n}} \right]; \tag {10}
+$$
+
+$$
+I _ {\mathrm {M}} = \operatorname {a r g s o r t} ([ P (y _ {1} | x), \dots , P (y _ {n} | x) ]). \tag {11}
+$$
+
+Next, we can now define the model errors over hypothesis space with the distance between these two sorted arrays,
+
+$$
+S _ {\text {d i s t}} = \mathrm {D} \left(\mathcal {Y} _ {\mathrm {H R}}, \mathcal {Y} _ {\mathrm {M}}\right), \tag {12}
+$$
+
+where $D$ is a certain distance function.
+
+# 3 Our Proposed Evaluation
+
+Two key designs of the evaluation over hypothesis space are the choice of distance functions and tackling the intractably large space. In this section, we first discuss our distance functions. Then, we propose two methods to simulate the hypothesis space, with the topmost and sampled hypotheses respectively.
+
+# 3.1 Model Errors
+
+We propose two distance functions to describe ranking distance $D$ in this section. First, we propose an extended version of nDCG (Järvelin and Kekäläinen, 2002), which we coin $\mathbf{k}$ -approximated Ranked Gains (kRG):
+
+$$
+\operatorname {k R G} \left(\boldsymbol {\mathcal {Y}} _ {\mathrm {H R}}, \boldsymbol {\mathcal {Y}} _ {\mathrm {M}}\right) = \frac {\operatorname {D C G} _ {k} \left(\boldsymbol {\mathcal {Y}} _ {\mathrm {M}}\right)}{\operatorname {D C G} _ {k} \left(\boldsymbol {\mathcal {Y}} _ {\mathrm {H R}}\right)}, \tag {13}
+$$
+
+$$
+\operatorname {D C G} _ {k} (\boldsymbol {\mathcal {Y}}) = \sum_ {y _ {j} \in \boldsymbol {\mathcal {Y}}} \frac {f (y _ {j})}{\log_ {2} (j + 1)}, \tag {14}
+$$
+
+$$
+f \left(y _ {j}\right) = k - \operatorname {R a n k} \left(y _ {j}, \mathcal {Y} _ {\mathrm {H R}}\right), \tag {15}
+$$
+
+where $f(y_{j})$ denotes the relevance score of a certain ranked hypothesis and $k$ is the length for approximated $\mathcal{V}_{\mathrm{HR}}$ and $\mathcal{V}_{\mathrm{M}}$ . kRG directly measures the ranking of a model's hypotheses array, where 0 means a completely wrong ranking and 1 means a perfect ranking.
+
+Next, in concern of translation quality of selected hypotheses, we further propose $\mathbf{k}$ -approximated
+
+Quality-based Ranked Gains (kQRG):
+
+$$
+\operatorname {k Q R G} \left(\mathcal {Y} _ {\mathrm {H R}}, \mathcal {Y} _ {\mathrm {M}}\right) = \frac {\operatorname {D C G} _ {q k} \left(\mathcal {Y} _ {\mathrm {M}}\right)}{\operatorname {D C G} _ {q k} \left(\mathcal {Y} _ {\mathrm {H R}}\right)}, \tag {16}
+$$
+
+$$
+\operatorname {D C G} _ {q k} (\boldsymbol {\mathcal {Y}}) = \sum_ {y _ {j} \in \boldsymbol {\mathcal {Y}}} \frac {\mathrm {Q} (y _ {j})}{\log_ {2} (j + 1)}, \tag {17}
+$$
+
+where we replace relevance score with translation quality $Q \in [0,1]$ and normalize over $\mathcal{V}_{\mathrm{HR}}$ . We approximate $\mathrm{DCG}_{qk}(\mathcal{V}_{\mathrm{HR}})$ with its upper-bound:
+
+$$
+\begin{array}{l} \mathrm {D C G} _ {q k} \left(\mathcal {Y} _ {\mathrm {H R}}\right) = \sum_ {y _ {j} \in \mathcal {Y} _ {\mathrm {H R}}} \frac {\mathrm {Q} \left(y _ {j}\right)}{\log_ {2} (j + 1)} (18) \\ < = \sum_ {j \in [ 0: k ]} \frac {1 . 0}{\log_ {2} (j + 1)}. (19) \\ \end{array}
+$$
+
+kQRG consider both how the hypotheses are ranked and whether these hypotheses have good translation qualities. Unlike kRG, the bound and interpretation of kQRG depends on the choice of translation quality functions, which we will discuss later.
+
+# 3.2 Simulating Hypothesis Space
+
+As discussed above, it is intractable to obtain the HR array $\mathcal{V}_{\mathrm{HR}}$ and model ranked array $\mathcal{V}_{\mathrm{M}}$ . Our evaluation has to rely on approximations. Here, we present two methods to approximate the hypothesis space, namely the top hypothesis region and Monte Carlo sampling.
+
+# 3.2.1 Top Hypothesis Region
+
+While always being hindered by search errors, MAP decoding, the de facto standard search algorithm in NMT applications, seeks the topmost hypotheses from the whole space. Thus, one reasonable approximation is to focus more on hypotheses with the highest probabilities, which are regarded, by the model, with great importance and are the globally optimal solutions for MAP decoding. Formally, we define a top region model array:
+
+$$
+\tilde {\mathcal {Y}} _ {\mathrm {M}} = \mathcal {Y} _ {\mathrm {M}} [ 0: k ]; \tilde {I} _ {\mathrm {M}} = I _ {\mathrm {M}} [ 0: k ], \tag {20}
+$$
+
+where $k$ denotes how many top-ranked hypotheses we consider.
+
+Exact Top- $k$ Decoding To find the topmost hypotheses, we extend the exact decoding algorithm (Stahlberg and Byrne, 2019) and propose a top- $k$ DFS-based exact decoding algorithm (Algorithm 1). Our decoding method is guaranteed to find the exact top- $k$ hypotheses from the model's hypothesis space. Particularly, we traverse the search space of an NMT model in a depth-first manner. We enumerate all tokens in the vocabulary at each search
+
+ALGORITHM 1: DFS-based Top-k Exact Search.
+Input :x: Source sentence, y: Translation prefix (default: [], p: log $P(y|x)$ (default 0.0), k: Top-k hypotheses to output, V: Vocabulary. , Output: List $l$ contains top-k hypotheses with log-probabilities. global minHeap global $\gamma \gets -\inf$ Function dfsTopK $(x,y,p)$ .. if $y[|y| - 1] = < / s>$ then push(minHeap, $(p,y))$ if len(minHeap) $>k$ then pop(minHeap) end if len(minHeap) $= k$ then $\gamma \leftarrow$ minHeap[0][0] end end for $v\in V$ do $p^{\prime}\gets p + \log P(v|x,y)$ if $p^{\prime}\geq \gamma$ then dfsTopK $(x,[y;v],p^{\prime})$ end end return minHeap
+return dfsTopK $(x,[]0.0)$
+
+step and concatenate them with the current history as the next possible translation prefixes. During the search process, we keep track of the current top- $k$ hypotheses that we find. Specifically, a minimum heap is used to maintain current top- $k$ hypotheses during the search procedure. The hypothesis with the lowest score in the minimum heap dynamically update our lower bound during searching: Once we find a newly finished hypothesis (i.e., ended with $$ ), we push the hypothesis into the heap and make adjustments to retain the heap size equals $k$ . Then, we update the lower bound and truncate decoding paths. Finally, the hypotheses stayed in the minimum heap are returned. We use beam search result as the initial bound of the search space and sort the vocabulary before enumeration for a faster update of lower bounds. The implementation tricks and computational cost analysis can be found in Appendix D.
+
+# 3.2.2 Hypothesis Region Sampling
+
+Besides the view of topmost region over the hypothesis space, we also provide a broad view for hypothesis space. We use Monte Carlo sampling to simulate the whole space as follows. Note that we slightly abuse the notation with $k$ as the number of
+
+samples.
+
+$$
+y _ {i} \sim P (y | x), i \in [ 0, k ] \tag {21}
+$$
+
+$$
+\tilde {\mathcal {Y}} _ {\mathrm {M}} = \left[ y _ {\tilde {I} _ {\mathrm {M}} ^ {0}}, y _ {\tilde {I} _ {\mathrm {M}} ^ {1}}, \dots , y _ {\tilde {I} _ {\mathrm {M}} ^ {k}} \right], \tag {22}
+$$
+
+$$
+\tilde {I} _ {\mathrm {M}} = \operatorname {a r g s o r t} ([ Q (y _ {1}), \dots , Q (y _ {k}) ]). \tag {23}
+$$
+
+In both cases, there will be $k$ items in the array.
+
+Then, we reorder hypotheses appeared in $\tilde{\mathcal{V}}_{\mathrm{M}}$ to form a local HR array $\tilde{\mathcal{V}}_{\mathrm{HR}}$ ,
+
+$$
+\tilde {\mathcal {Y}} _ {\mathrm {H R}} = \left[ y _ {\tilde {I} _ {\mathrm {H R}} ^ {0}}, y _ {\tilde {I} _ {\mathrm {H R}} ^ {1}}, \dots , y _ {\tilde {I} _ {\mathrm {H R}} ^ {k}} \right], \tag {24}
+$$
+
+$$
+\tilde {I} _ {\mathrm {H R}} = \operatorname {a r g s o r t} ([ Q (y _ {\tilde {I} _ {\mathrm {M}} ^ {0}}), \dots , Q (y _ {\tilde {I} _ {\mathrm {M}} ^ {k}}) ]). \tag {25}
+$$
+
+# 4 Validation of Our Protocol
+
+This section validates the proposed protocol from the perspectives of translation quality, ranking capability and human evaluation.
+
+Translation Quality. There are a number of sentence-level metrics proposed in neural machine translation. For example, there are string-based metrics like BLEU and ChRf (Papineni et al., 2002; Popovic, 2015) and neural model-based metrics like BLEURT and COMET (Sellam et al., 2020; Rei et al., 2020). Recent studies and our human evaluation described later show that COMET scores are superior to other metrics in the correlations with human evaluation. (Kocmi et al., 2021; Mathur et al., 2020; Freitag et al., 2021b). Thus, we use COMET for main results of this paper.
+
+Ranking Capability. The ranking capability of our protocol is evaluated by the nDCG metric, which is a widely used metric in many different areas that need to quantitatively measure the ranking efficacies (Liu et al., 2018; Agarwal et al., 2020). The reliability of nDCG is well supported by previous literature. As a result, the validations of translation quality and ranking capability enable our protocol to be a solid evaluation protocol.
+
+Human Evaluation. Moreover, we provide the human evaluation in this section to strengthen the validation of our protocol. We follow (Kocmi et al., 2021) to design the human evaluation. Specifically, we randomly select our NMT systems trained by the NIST Zh-En dataset into three evaluation groups. Each of which consists of comparison among three different systems, where we sample 50 sentences from NIST Zh-En test sets and provide top-5 exact decoding results $(\tilde{Y_M})$ . As a result, each group has 750 sentences, and we conduct the human evaluation on a total of 9 systems.
+
+We ask three professional Chinese-English translators to answer a question: how far are the array
+
+of translations from the perfect ranked outputs? (kQRG) The annotators are required to give a score between 1 to 5. However, the scores are sometimes hard to give directly. Therefore, we ask human annotators to first have a sentence-level assessment of all translated sentences on a scale of [0, 100], following the source-based Direct Assessment method (DA, Graham et al. (2017)). We do not provide the reference to avoid the reference bias (Kocmi et al., 2021). Then, annotators provide their ranking and total quality scores based on their scoring results of a system's top- $k$ (e.g., [40, 75, 40, 80]). We compute Pearson's/Spearman's Correlations between human scores and the corresponding kQRG on the top-5 translations. The results are 0.8554/0.8506 respectively $^5$ , which demonstrate a strong correlation between our proposed protocol and human judgments. We also conduct experiments comparing the correlation using different translation quality metrics other than COMET in the Appendix A, including Sentence-BLEU, BLEURT (Sellam et al., 2020), ChrF (Popovic, 2015), COMET-QE (Rei et al., 2020), and COMET correlates well with human results. We believe the above results validate our proposed protocol.
+
+# 5 Experiments and Findings
+
+In this section, we use our proposed evaluation protocol to evaluate two crucial factors of NMT systems - model architecture and search algorithm.
+
+Setup. All experiments are conducted over three commonly used NMT benchmarks, NIST Chinese-English, WMT'14 English-German, and WMT'14 English-French with small, medium, and large sizes. The statistics of datasets, pre-processing and training details can be found in Appendix B.
+
+Evaluation Details. We use COMET (Rei et al., 2020) as our translation quality function among all experiments. We also provide results with ChrF (Popović, 2015) in the Appendix, as suggested in Kocmi et al. (2021). By default, we use top-10 hypotheses for top region and 200 random samples for Monte Carlo sampling in all experiments.
+
+Interpretation. We report kRG and kQRG results in our experiments. The kRG measures the 'local' ranking ability of the top region of hypothesis space, directly representing whether the model correctly puts high-quality hypotheses over bad quality ones. The results range from 0 to $100\%$ , where 0
+
+| Method | System | Mode | Top | Sample |
| BLEU | # Emp | kQRG | kQRG |
| Transformer | 27.22 | 64.70 | -60.39 | -106.75 |
| w/o LS | 26.76 | 34.85 | -17.75 | -25.07 |
| w/ para BT | 27.36 | 27.26 | -13.04 | -19.52 |
| w/ para FT | 28.06 | 0.93 | 43.27 | 10.43 |
| w/ 12-layer Enc | 27.75 | 58.11 | -50.57 | -104.94 |
| w/ 18-layer Enc | 28.03 | 53.58 | -43.88 | -97.46 |
| w/ Dim 768 | 28.00 | 50.18 | -43.33 | -101.23 |
| w/ Dim 1024 | 28.49 | 44.72 | -34.56 | -84.93 |
+
+Table 1: Model errors of different models in WMT'14 En-De task. 'para BT' and 'para FT' denote backtranslation and forward-translation over parallel golden data, and LS denotes label smoothing.
+
+denotes a completely wrong ranking, and $100\%$ denotes a perfect ranking. Alternatively, kQRG measures two aspects: 'local' ranking ability and hypothesis selection - the quality of hypotheses that we can get from top-region or sampling. Using COMET trained with normalized z-scores, the kQRG values are not bounded by [0, 1] and may have negative values. A z-score above 0 means that the translation is better than average, and below 0 is the opposite. Thus, recall our definitions, we have two anchors to interpret kQRG values, where 0 means average translation qualities and 1 means perfect rankings with COMET values of 1, which is not the highest but a strong score.
+
+# 5.1 Findings on NMT Techniques
+
+Table 1 demonstrates the results for different Transformer-based models in WMT'14 En-De. Results across different languages and other translation metrics can be found in Appendix C and are consistent with our main results. We make following observations:
+
+1. Failure of mode evaluation. Let us take a look at the empty rates, the evaluation for model errors proposed in previous literature. We find that removing label smoothing, adding pseudo-parallel data will drastically decrease the number of empty rates, even close to 0 ("para $FT$ ), indicating an almost perfect model with tiny model errors. However, it is not the case. Our kRG and kQRG results indicate that the model still has much to improve. These demonstrate that mode-level evaluation collapses when evaluating certain models and the superiority of our evaluation.
+
+
+
+
+
+
+Figure 1: Ranking ability with respect to increasing number of $k$ . Left: Top Region; Right: Sampling.
+
+
+Figure 2: kQRG for Wide/Deep models. T-/S- denote Top Region/Sampling. Left: Model Dimension; Right: Decoder Depth.
+
+2. The State-of-the-art Transformer models face serious ranking problem in top region. In Figure 1, we plot the kRG results for top region and sampling. To further investigate the results, we also plot a random kRG. Recall definitions in Equation (13). The list of relevance scores $f(y_{j})$ is a certain permutation of $[0,1,\dots ,k - 1]$ . The random results are averaged from 100k samples of permutations.
+
+For top region model errors shown on the left, the model's kRG values are close to the random line when increasing $k$ . Such behavior indicates severe ranking errors, and the model performs only at the random chance level in the top region. In contrast, by studying the sampled results on the right, the model outperforms the random line with a considerable gap. The model's opposite behaviors from the top region and sampling approximation are surprising. We conjecture that the NMT model can distinguish good/bad hypotheses coarsely but fail at the top region and fine-grained levels.
+
+The above findings provide another explanation on why MBR decoding (Eikema and Aziz, 2020; Freitag et al., 2021a) achieved better performance recently, as the model can better rank the sampling outputs. Rank-sensitive training (Chiang, 2012) might be a possible solution for the ranking errors.
+
+3. Widening models are more effective in reducing model errors. Recently, many interests have been drawn for using deeper models (Wang et al., 2019; Li et al., 2020) instead of wider models (Yan et al., 2020) to increase model capacity. Here we study the model errors of wider and deeper models.
+
+Our results are shown in Figure 2. With the
+
+| Method | Top Region | Beam Search |
| kRG | kQRG | kRG | kQRG |
| 6-layer | 81.37 | -74.72 | 80.82-0.55 | 19.46+94.19 |
| 9-layer | 81.38 | -74.66 | 81.16-0.22 | 20.47+95.13 |
| 12-layer | 80.62 | -66.02 | 80.84+0.22 | 22.02+88.04 |
| 15-layer | 80.94 | -66.60 | 80.90-0.04 | 22.34+88.94 |
| 18-layer | 81.42 | -73.54 | 80.69-0.74 | 22.31+95.85 |
| D384 | 82.05 | -86.18 | 80.59-1.46 | 16.46+102.63 |
| D512 | 81.37 | -74.72 | 80.82-0.55 | 19.46+94.19 |
| D640 | 80.82 | -67.44 | 81.16+0.34 | 21.63+89.06 |
| D768 | 80.91 | -58.92 | 81.11+0.19 | 22.28+81.21 |
| D896 | 80.20 | -56.01 | 80.14-0.06 | 22.01+78.01 |
| D1024 | 80.57 | -54.26 | 81.26+0.69 | 23.26+77.52 |
+
+increases in model dimensions, model errors with top region and sampling have both been improved. In contrast, a deeper decoder shows smaller model errors in the top region, but larger model errors in sampling (whole hypothesis space), which is counter-intuitive as we would expect that a larger model capacity means smaller model errors. As we do not observe a clear trend in increasing encoder depth, we put these results in the Appendix in case readers are interested.
+
+4. Model confidence may be crucial to reducing model errors. Results show that $w/$ para $FT$ , $w/$ para $BT$ and $w/o$ $LS$ all show impressive improvements in kQRG in both of our evaluations. Nonetheless, their BLEU scores with beam search are only comparable/worse than other methods like deep/wide models. In this case, system-level evaluation fails to capture decent improvements over the model's hypothesis space. As forward-translation training and disabling label-smoothing are expected to enhance the model confidence, we conjecture that model errors are highly related to model confidence and leave the exploration as future work.
+
+# 5.2 Connection to Search Algorithms
+
+# 5.2.1 Quantify Beam Search Lucky Biases
+
+As pointed out in recent work (Meister et al., 2020), beam search seems to bring a lucky bias that covers some of the model errors. This section utilizes our
+
+Table 2: Hypothesis space evaluation over top-10 outputs versus beam top-10 outputs when increasing dimensions / enc layers.
+
+| Method | Pearson | Cost |
| MBR | 1.000 | N2 |
| Beam Search | -0.143 | N |
| Sampling | 0.975 | N |
| Ours | 0.977 | N |
+
+Table 3: Correlation studies for MBR decoding.
+
+proposed metric to understand the bias brought by beam search, since our top-region evaluation finds the best solution for MAP decoding with no search errors.
+
+Concretely, we use kRG and kQRG to evaluate the errors from both exact top- $k$ and beam search top- $k$ outputs and compare the scores to check the effect of beam search bias. In this way, the gap between two errors represents the lucky bias brought by beam search quantitatively. Experiments are conducted in NIST Zh-En, and results are shown in Table 2. We have several interesting findings.
+
+Firstly, beam search leads to a decent improvement (from $+77\%$ to $+102\%$ ) in kQRG, which quantitatively proves the existence of beam search's lucky bias in recent work.
+
+Then, beam search generally does not affect ranking abilities. As shown, the gaps of kRG between the beam and exact outputs are generally small and fluctuate around 0. We do not observe a clear trend of beam search bias in ranking abilities.
+
+Furthermore, we analyze deeper and wider models and observe different behaviors. There is a clear trend in decreasing the gap between the beam and the exact when increasing the model's width. Conversely, the lucky biases of beam search retain when increasing the model's depth, showing deeper models are more compatible with beam search biases than wider ones. Such behaviors concur with the studies, showing that deeper models perform more efficiently and effectively with beam search than wider models (Wang et al., 2019; Li et al., 2020). We show that the observed superiority of deep models may stem from their compatibility with beam search's inductive bias.
+
+# 5.2.2 Correlations with MBR Decoding
+
+MBR decoding emerges as a promising and powerful decoding algorithm instead of beam search (Eikema and Aziz, 2020; Freitag et al., 2021a), which makes use of sampled hypothesis space and is relevant to our proposed evaluation. Here, it is necessary to study the correlation between our proposed sampling evaluation and MBR decoding.
+
+Concretely, we perform experiments over our ten systems with WMT'14 En-De, and we test the Spearsman/Kendall correlation between MBR decoding translation qualities and our sampled kQRG scores. For MBR, we use 100 samples per source sentences and BLEURT (Sellam et al., 2020) as our utility function, following Freitag et al. (2021a). One salient advantage of our proposed evaluation instead of directly MBR over test sets is the computational cost. For instance, with 100 samples, our evaluation uses 100 BLEURT calls per sentence, while the naive MBR needs 10k BLEURT calls due to its usage of quadratic computations.
+
+We also report the correlation for the other two evaluations, namely beam search and sampling. As shown in Table 3, our method performs the best among the three evaluations, and it indicates a potential application for our sampling-based kQRG.
+
+# 6 Related Work
+
+Decoding Methods. Most decoding methods in NMT aims to find the hypothesis with the highest conditional probability, i.e., maximum-a-posteriori (MAP) decoding. Among all MAP decoding methods, beam search is most widely applied in the modern NMT systems for evaluation. Naive beam search has several known drawbacks, such as favoring short translations and its monotonic constraint. Hence, many regularization/rescoring methods (Bahdanau et al., 2014; Wu et al., 2016; He et al., 2016; Yang et al., 2018; Murray and Chiang, 2018) or beam search variants (Freitag and Al-Onaizan, 2017; Shu and Nakayama, 2018) are proposed to improve the performance. Other than beam search, one promising MAP decoding for evaluation is the DFS-based exact search (Stahlberg and Byrne, 2019), which finds the mode of model distributions. Despite its high computational cost, it reveals important information about the learned hypothesis space. We follow this approach and present a top- $k$ exact search method, which can access the top-region of hypothesis space.
+
+In addition, there are some non-MAP decoding algorithms. A typical one is the stochastic sampling-based decoding methods (Ackley et al., 1985; Holtzman et al., 2019), which randomly choose candidates from each step's output distribution. Further, Eikema and Aziz (2020) introduces a Minimum Bayesian Risk decoding method based on sampling. Leblond et al. (2021) propose a metric-driven search approach via Monte-Carlo
+
+Tree Search (MCTS). The sampling-based methods are promising and may incorporate with our evaluation in future directions.
+
+Error Evaluation. Evaluation of NMT errors focuses on studying the gap between machine-translated results and human-translated references. Statistical matching metrics (Papineni et al., 2002; Banerjee and Lavie, 2005; Koehn et al., 2007; Denkowski and Lavie, 2014; Guo and Hu, 2019) and pretrained metrics (Sellam et al., 2020; Rei et al., 2020) are two dominant directions in evaluating errors. These metrics prove that linguistic similarity between references and machine translations correlates the human evaluation well. However, to the best of our knowledge, these statistical metrics evaluate one best hypothesis decoded from heuristic decoding algorithm (i.e., system-level evaluation), which incorporate huge search errors and bias understanding of NMT models.
+
+Recent efforts (Niehues et al., 2017; Stahlberg et al., 2018; Stahlberg and Byrne, 2019; Meister et al., 2020; Eikema and Aziz, 2020) are devoted to analyzing model errors without search errors and provide meaningful conclusions. Nonetheless, these approaches still evaluate over one hypothesis in hypothesis space except with the one with highest probability. This is incomprehensive due to neglecting errors inside the whole hypothesis space. In contrast, we dig into model errors over top regions and provide a more comprehensive evaluation. In addition, we provide various interesting findings over model errors with regards to NMT techniques and search algorithms.
+
+# 7 Conclusion
+
+This paper presents a novel evaluation protocol for model errors in the perspective of rankings over the hypothesis space. Specifically, our evaluation encompasses two approximated evaluations, top region and Monte Carlo Sampling, and two metrics, kRG and kQRG, measuring the hypothesis ranking ability of hypothesis space. Our evaluations correlate well with human judgments and provide interesting findings over NMT techniques and search algorithms. We believe these findings shed light on future development in the NMT field.
+
+For future directions, we think the evaluation of NMT models should disentangle with search algorithms, and assess models more comprehensively from the perspective of hypothesis space. Furthermore, the effectiveness of different NMT
+
+techniques should also be re-evaluated from such a perspective. We expect multi-angle evaluations over the NMT models. Errors we revealed, like the ranking errors, need to be fixed and may have connections with the well-known beam search curse problem, which is also a promising direction worth exploring.
+
+# References
+
+David H Ackley, Geoffrey E Hinton, and Terrence J Sejnowski. 1985. A learning algorithm for boltzmann machines. Cognitive science, 9(1):147-169.
+Shubham Agarwal, Trung Bui, Joon-Young Lee, Ioannis Konstas, and Verena Rieser. 2020. History for visual dialog: Do we really need it? In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8182-8197, Online. Association for Computational Linguistics.
+Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. 2014. Neural machine translation by jointly learning to align and translate. arXiv preprint arXiv:1409.0473.
+Satanjeev Banerjee and Alon Lavie. 2005. Meteor: An automatic metric for mt evaluation with improved correlation with human judgments. In Proceedings of the acl workshop on intrinsic and extrinsic evaluation measures for machine translation and/or summarization, pages 65-72.
+David Chiang. 2012. Hope and fear for discriminative training of statistical translation models. Journal of Machine Learning Research, 13(4).
+Michael Denkowski and Alon Lavie. 2014. Meteor universal: Language specific translation evaluation for any target language. In Proceedings of the ninth workshop on statistical machine translation, pages 376-380.
+Chris Dyer, Victor Chahuneau, and Noah A Smith. 2013. A simple, fast, and effective reparameterization of ibm model 2. In Proceedings of the 2013 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 644-648.
+Bryan Eikema and Wilker Aziz. 2020. Is map decoding all you need? the inadequacy of the mode in neural machine translation. In Proceedings of the 28th International Conference on Computational Linguistics, pages 4506-4520.
+Markus Freitag and Yaser Al-Onaizan. 2017. Beam search strategies for neural machine translation. In Proceedings of the First Workshop on Neural Machine Translation, pages 56-60.
+Markus Freitag, David Grangier, Qijun Tan, and Bowen Liang. 2021a. Minimum bayes risk decoding with
+
+neural metrics of translation quality. arXiv preprint arXiv:2111.09388.
+Markus Freitag, Ricardo Rei, Nitika Mathur, Chi-kiu Lo, Craig Stewart, George Foster, Alon Lavie, and Ondrej Bojar. 2021b. Results of the wmt21 metrics shared task: Evaluating metrics with expert-based human evaluations on ted and news domain. In Proceedings of the Sixth Conference on Machine Translation, pages 733-774.
+Jonas Gehring, Michael Auli, David Grangier, Denis Yarats, and Yann N Dauphin. 2017. Convolutional sequence to sequence learning. In International Conference on Machine Learning, pages 1243-1252. PMLR.
+Yvette Graham, Timothy Baldwin, Alistair Moffat, and Justin Zobel. 2017. Can machine translation systems be evaluated by the crowd alone. *Natural Language Engineering*, 23(1):3-30.
+Yinuo Guo and Junfeng Hu. 2019. Meteor++ 2.0: Adopt syntactic level paraphrase knowledge into machine translation evaluation. In Proceedings of the Fourth Conference on Machine Translation (Volume 2: Shared Task Papers, Day 1), pages 501-506.
+Wei He, Zhongjun He, Hua Wu, and Haifeng Wang. 2016. Improved neural machine translation with smt features. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 30.
+Michael D Hendy and David Penny. 1982. Branch and bound algorithms to determine minimal evolutionary trees. Mathematical Biosciences, 59(2):277-290.
+Ari Holtzman, Jan Buys, Li Du, Maxwell Forbes, and Yejin Choi. 2019. The curious case of neural text degeneration. In International Conference on Learning Representations.
+Kalervo Järvelin and Jaana Kekäläinen. 2002. Cumulated gain-based evaluation of ir techniques. ACM Transactions on Information Systems (TOIS), 20(4):422-446.
+Tom Kocmi, Christian Federmann, Roman Grundkiewicz, Marcin Junczys-Dowmunt, Hitokazu Matsushita, and Arul Menezes. 2021. To ship or not to ship: An extensive evaluation of automatic metrics for machine translation. arXiv preprint arXiv:2107.10821.
+Philipp Koehn, Hieu Hoang, Alexandra Birch, Chris Callison-Burch, Marcello Federico, Nicola Bertoldi, Brooke Cowan, Wade Shen, Christine Moran, Richard Zens, et al. 2007. Moses: Open source toolkit for statistical machine translation. In Proceedings of the 45th annual meeting of the association for computational linguistics companion volume proceedings of the demo and poster sessions, pages 177-180.
+
+Rémi Leblond, Jean-Baptiste Alayrac, Laurent Sifre, Miruna Pislar, Jean-Baptiste Lespiau, Ioannis Antonoglou, Karen Simonyan, and Oriol Vinyals. 2021. Machine translation decoding beyond beam search. arXiv preprint arXiv:2104.05336.
+Bei Li, Ziyang Wang, Hui Liu, Yufan Jiang, Quan Du, Tong Xiao, Huizhen Wang, and Jingbo Zhu. 2020. Shallow-to-deep training for neural machine translation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 995-1005.
+Zhenghao Liu, Chenyan Xiong, Maosong Sun, and Zhiyuan Liu. 2018. Entity-duet neural ranking: Understanding the role of knowledge graph semantics in neural information retrieval. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2395-2405, Melbourne, Australia. Association for Computational Linguistics.
+Minh-Thang Luong, Hieu Pham, and Christopher D Manning. 2015. Effective approaches to attention-based neural machine translation. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 1412-1421.
+Alan Mackworth. 2013. Lecture notes in introduction to artificial intelligence.
+Nitika Mathur, Johnny Wei, Markus Freitag, Qingsong Ma, and Ondrej Bojar. 2020. Results of the wmt20 metrics shared task. In Proceedings of the Fifth Conference on Machine Translation, pages 688-725.
+Clara Meister, Ryan Cotterell, and Tim Vieira. 2020. If beam search is the answer, what was the question? In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2173-2185, Online.
+Kenton Murray and David Chiang. 2018. Correcting length bias in neural machine translation. arXiv preprint arXiv:1808.10006.
+Jan Niehues, Eunah Cho, Thanh-Le Ha, and Alex Waibel. 2017. Analyzing neural MT search and model performance. In Proceedings of the First Workshop on Neural Machine Translation, pages 11-17, Vancouver.
+Myle Ott, Michael Auli, David Grangier, and Marc'Aurelio Ranzato. 2018. Analyzing uncertainty in neural machine translation. In Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research, pages 3956-3965. PMLR.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th annual meeting of the Association for Computational Linguistics, pages 311-318.
+
+Maja Popovic. 2015. chrf: character n-gram f-score for automatic mt evaluation. In Proceedings of the Tenth Workshop on Statistical Machine Translation, pages 392-395.
+Ricardo Rei, Craig Stewart, Ana C Farinha, and Alon Lavie. 2020. Comet: A neural framework for mt evaluation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2685-2702.
+Thibault Sellam, Dipanjan Das, and Ankur Parikh. 2020. Bleurt: Learning robust metrics for text generation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7881-7892.
+Rico Sennrich, Barry Haddow, and Alexandra Birch. 2016. Neural machine translation of rare words with subword units. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1715-1725, Berlin, Germany.
+Raphael Shu and Hideki Nakayama. 2018. Improving beam search by removing monotonic constraint for neural machine translation. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 339-344.
+Felix Stahlberg and Bill Byrne. 2019. On NMT search errors and model errors: Cat got your tongue? In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3356-3362, Hong Kong, China.
+Felix Stahlberg, Danielle Saunders, Gonzalo Iglesias, and Bill Byrne. 2018. Why not be versatile? applications of the SGNMT decoder for machine translation. In Proceedings of the 13th Conference of the Association for Machine Translation in the Americas (Volume 1: Research Track), pages 208-216, Boston, MA. Association for Machine Translation in the Americas.
+Ilya Sutskever, Oriol Vinyals, and Quoc V Le. 2014. Sequence to sequence learning with neural networks. Advances in neural information processing systems, 27:3104-3112.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems, pages 5998-6008.
+Qiang Wang, Bei Li, Tong Xiao, Jingbo Zhu, Changliang Li, Derek F Wong, and Lidia S Chao. 2019. Learning deep transformer models for machine translation. arXiv preprint arXiv:1906.01787.
+Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, et al.
+
+2016. Google's neural machine translation system: Bridging the gap between human and machine translation. arXiv preprint arXiv:1609.08144.
+Jianhao Yan, Fandong Meng, and Jie Zhou. 2020. Multiunit transformers for neural machine translation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 1047-1059.
+Yilin Yang, Liang Huang, and Mingbo Ma. 2018. Breaking the beam search curse: A study of (re-) scoring methods and stopping criteria for neural machine translation. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 3054-3059.
+
+# Appendix
+
+# Table of Contents
+
+A Correlation with Human Judgements 12
+B Experimental Details 12
+
+B.1 Detailed Descriptions of Datasets 12
+B.2 Training Details 12
+
+C Additional Experimental Results on Model Errors 13
+
+C.1 Various NMT Benchmarks 13
+C.2 Various Translation Quality Functions 13
+C.3 Various Model Architectures 14
+C.4 Analysis on Original Sources 14
+C.5 Clean and Up-to-date Datasets 14
+C.6 Increasing encoder depth 15
+
+D Implementation Details of Exact Top- k 15
+
+D.1 Worst-case Analysis for Exact Search Algorithm 16
+D.2 Empirical Computational Cost. 16
+D.3 Choice of Different $k$ Values 16
+
+E Case Study 17
+F Limitations 18
+
+# A Correlation with Human Judgements
+
+This section provides the correlation results for different choices of translation quality metrics. We choose four reference-based metrics: sentenceBLEU, ChrF, BLEURT, and COMET, and a reference-free QE metric: COMET-QE. We test both the sentence and system score correlations between kQRG and human judgments. The results are shown in Table 4.
+
+Among all translation quality metrics, sentenceBLEU performs the worst, and COMET shows the strongest correlation in both sentence and system levels. This justifies our choice of COMET for the main results. We also find that $\mathrm{ChrF}$ has good correlations with human evaluation. Therefore, we provide results for $\mathrm{ChrF}$ in the following sections. In addition, our evaluation can be incorporated with QE metrics and becomes a reference-free evaluation protocol. However, COMET-QE lags behind
+
+other reference-based translation quality metrics in terms of correlation.
+
+# B Experimental Details
+
+# B.1 Detailed Descriptions of Datasets
+
+For our WMT'14 En-De/En-Fr tasks, we use 4.5M / 35.7M preprocessed data, which is tokenized and split using byte pair encoded (BPE) (Sennrich et al., 2016) with 32K/40K merge operations and a shared vocabulary for source and target sides. For En-De, we use newstest2013 as the validation set and newstest2014 as the test set. For En-Fr, we use the combination of newstest2012 and newstest2013 as our validation set and newstest2014 as the test set.
+
+For the NIST Zh-En task, we use 1.25M sentences extracted from LDC corpora7. To validate the performance of our model, we use the NIST 2006 (MT06) test set with 1664 sentences as our validation set. Then, the NIST 2002 (MT02), 2004 (MT04), 2005 (MT05), 2008 (MT08) test sets are used as our test sets, which contain 878, 1788, 1082, and 1357 sentences, respectively. All reported results are averaged over different test sets.
+
+The statistics of all three datasets can be found in Table 5.
+
+# B.2 Training Details
+
+Our models are trained using the fairseq toolkit8. We train each of our Transformer models for 100k/300k/300k steps for three datasets and validate every 5000 steps. The default label smoothing is 0.1. The dropout rates for different Transformer models range from 0.1 to 0.4. The batch sizes are 8k/64k/64k tokens for three datasets. All our Transformer models are pre-norm models. Other hyperparameter settings are the same as in (Vaswani et al., 2017). For evaluation, we report case-sensitive tokenized BLEU scores using multi-bleu.perl9 for both WMT'14 En-De and En-Fr, and case-insensitive tokenized BLEU scores for NIST Chinese-English. We select the best checkpoint on the validation set and report its performance on the test set. All reported results are averaged over all sentences in the test set. For results with beam
+
+| Translation Quality | Sentence | System |
| Pearson | Spearman | Pearson | Spearman |
| Sentence-BLEU | 0.67 | 0.80 | 0.59 | 0.55 |
| ChrF | 0.85 | 0.86 | 0.75 | 0.72 |
| BLEURT | 0.86 | 0.85 | 0.71 | 0.61 |
| COMET | 0.86 | 0.85 | 0.78 | 0.82 |
| COMET-QE | 0.66 | 0.66 | 0.71 | 0.53 |
+
+Table 4: Pearson and Spearman's correlation scores with human judgements across different translation quality functions. Bold and underline represent the 1st and 2nd performing results, respectively.
+
+| Name | Train | Dev | Test | BPE |
| NIST Zh-En | 1.2M | 1664 | 5105 | 40K/30K |
| WMT'14 En-De | 4.5M | 3000 | 3003 | 32K |
| WMT'14 En-Fr | 35.7M | 6003 | 3003 | 40K |
+
+search, the beam size is 5, and the length penalty is 0.6.
+
+# C Additional Experimental Results on Model Errors
+
+# C.1 Various NMT Benchmarks
+
+This section presents COMET results on the WMT'14 English-French and NIST Chinese-English tasks. The results are shown in Table 6, 7. It is encouraging that the results are all consistent and corroborate our findings in the main text. As these three datasets have small, medium, and large sizes, we prove that our proposed protocol generalizes well across different languages and sized datasets.
+
+Furthermore, by comparing results among these experiments, we find that model errors for different tasks vary vastly. The reason might be either the intrinsic difficulties of tasks or other properties of the dataset like sizes or cleanliness, etc. We revisit the dataset properties in Section C.5.
+
+# C.2 Various Translation Quality Functions
+
+This section provides model errors with an additional reference-based translation quality metric - ChrF, which performs second to COMET in our correlation studies.
+
+In Table 8, we present our results using ChrF with the English-German task. An advantage of
+
+Table 5: Statistics of Datasets
+
+| Method | System | Mode | Top | Sample |
| BLEU | # Emp | kQRG | kQRG |
| Transformer | 42.47 | 41.14 | -74.72 | -60.73 |
| w/o LS | 42.44 | 14.59 | -31.78 | -11.54 |
| w/ para FT | 42.17 | 17.52 | -23.42 | -52.83 |
| w/ 12-layer Enc | 43.38 | 36.24 | -66.02 | -59.63 |
| w/ 18-layer Enc | 43.81 | 43.11 | -73.54 | -58.85 |
| w/ Dim 768 | 42.88 | 40.76 | -58.92 | -57.17 |
| w/ Dim 1024 | 43.43 | 34.03 | -54.26 | -52.74 |
+
+Table 6: COMET model errors of different models in NIST Chinese-English task. kQRG values are not normalized.
+
+| Method | System | Mode | Top | Sample |
| BLEU | # Emp | kQRG | kQRG |
| Transformer | 40.78 | 46.75 | -22.69 | -96.48 |
| w/o LS | 40.70 | 19.51 | 28.37 | 5.69 |
| w/ para FT | 40.95 | 27.26 | 49.67 | -82.75 |
| w/ 12-layer Enc | 41.28 | 44.99 | -18.96 | -95.62 |
| w/ 18-layer Enc | 41.74 | 53.58 | -16.91 | -94.56 |
| w/ Dim 768 | 41.73 | 46.12 | -17.71 | -93.17 |
| w/ Dim 1024 | 42.35 | 40.42 | -11.04 | -87.07 |
+
+Table 7: COMET model errors of different models in WMT'14 En-Fr task. kQRG values are not normalized.
+
+using ChrF is its bound between 0 and 1, which makes our kQRG easier to interpret. We observe that all of our findings in Section 5.1 still hold. This proves our proposed protocol performs consistently across different choices of translation metrics.
+
+| Method | System | Mode | Top | Sample |
| BLEU | # Emp | kQRG | kQRG |
| Transformer | 27.22 | 64.70 | 31.67 | 34.58 |
| w/o LS | 26.76 | 34.85 | 41.64 | 42.41 |
| w/ para BT | 27.36 | 27.26 | 42.89 | 43.31 |
| w/ para FT | 28.06 | 0.93 | 55.55 | 49.72 |
| w/ 12-layer Enc | 27.75 | 58.11 | 33.86 | 35.11 |
| w/ 18-layer Enc | 28.03 | 53.58 | 35.33 | 36.48 |
| w/ Dim 768 | 28.00 | 50.18 | 35.60 | 35.67 |
| w/ Dim 1024 | 28.49 | 44.72 | 37.75 | 37.99 |
+
+Table 8: ChrF model errors of different models in WMT'14 English-German.
+
+| Method | BLEU | kRG | kQRG |
| Transformer | 27.22 | 80.21 | -60.39 |
| RNNSearch | 23.07 | 83.63 | -106.26 |
| ConvS2S | 26.51 | 81.76 | -77.40 |
+
+# C.3 Various Model Architectures
+
+In previous sections, we discuss the model errors of Transformer models. In this section, we extend the experiments to different NMT architectures, i.e., ConvSeq2Seq (Gehring et al., 2017) and RNNSearch (Luong et al., 2015). We use the WMT'14 English-German and present our model error (COMET) results in Table 9.
+
+Interestingly, we find that RNNSearch performs the best in terms of kRG, indicating the strongest ranking capability. ConvSeq2Seq has a 63.08 score in kRG and is second to RNNSearch. Both of them perform better than the Transformer model in terms of ranking capability and are better than random ranking (58.72 in Section 5.1). Then, the Transformer model outperforms ConvSeq2Seq and RNNSearch in terms of model error and BLEU score, showing a stronger hypothesis selection. On the one side, these results demonstrate that future model design needs to revisit RNN models' advantages and incorporate them with current Transformer architectures. On the other side, the RNN model with the best ranking ability only scores 66.16 of [0, 100] in kRG, indicating large potentials in reducing model errors by improving their ranking abilities.
+
+Table 9: Top region model errors with different model architectures in WMT'14 English-French.
+
+| Method | Source En | Source De |
| kRG | kQRG | kRG | kQRG |
| Transformer base | 80.84 | -84.46 | 79.58 | -36.24 |
| w/ para ft | 81.87 | 35.98 | 82.42 | 50.61 |
| w/ para bt | 79.47 | -33.76 | 80.46 | 7.50 |
| Transformer Big | 80.63 | -59.59 | 80.59 | -9.46 |
+
+Table 10: Top region model errors on English-original and German- original part of newestest2014 En-De test-set.
+
+# C.4 Analysis on Original Sources
+
+One interesting result in our main experiments is that the paraFT model performs much better than the paraBT model. One possible reason is that paraFT model overfits the original sides of the test sets. Therefore, we compare model errors on the English-original part and German-original part of newstest2014 to verify this assumption, which contains 1,500 and 1,503 sentences, respectively.
+
+Table 10 shows the results. Comparing "Source En" with "Source De", we find that the ranking capabilities (kRG) are not much affected by the original sides. However, models perform substantially better in kQRG of source German side than that of the source English side, as translated English sentences are easier to translate than original English sentences. The gap between paraFT and paraBT varies to some extent across different origins, but with both sides, paraFT still strongly outperforms paraBT. Thus we conclude that original side is not the main reason.
+
+# C.5 Clean and Up-to-date Datasets
+
+There is a concern that the ranking issues are from the WMT'14 datasets, which are outdated and noisy (Ott et al., 2018). In this section, we study properties of the datasets and provide two additional ablation experiments to support our method. We introduce two datasets: (1) WMT'14 En-De dataset filtered by language detection and the fast align, (2) the WMT'20 En-De dataset, to which we perform the same filters. These two datasets contain 3.86M and 37.2M paired sentences, respectively. For language detection, we use the pretrained fasttext tool $^{10}$ and filter out the sample if either side of a paired sentence is identified as other languages. For the fast align (Dyer et al.,
+
+| Dataset | kRG | kQRG |
| WMT'14 En-De (4.5M) | 80.21 | -60.39 |
| w/ LD | 80.24 | -50.88 |
| w/ LD + FA | 80.32 | -45.41 |
| WMT'20 En-De (37M) | 80.19 | -21.84 |
| w/ Sample 4.5M | 79.88 | -21.02 |
| w/ Sample 10M | 80.09 | -23.42 |
| w/ Sample 20M | 80.39 | -29.95 |
+
+Table 11: Top region model errors over filtered WMT'14 En-De and WMT'20 En-De tasks. The model we use is the Transformer-base model. LD denotes filtering with language detection. FA denotes filtering with fast align.
+
+2013) filtering, we compute both the source-target and target-source alignment scores and filter out sentences with an average score less than $-6$ .
+
+The results are shown in Table 11. We have four key observations. Firstly, by comparing original WMT'14 En-De results with datasets after language detection (LD) and fast align filtering (FA), we find fine-grained cleaning techniques help reduce model errors. The kQRG values improve significantly, from $-60.39\%$ to $-45.41\%$ . Secondly, training with an up-to-date dataset dramatically improves the model in terms of reducing errors. As the WMT'20 En-De training set (37.2M) is much larger than the WMT'14 En-De (4.5M), we also conduct experiments with different sampled sizes of the WMT'20 dataset from 4.5M to 20M. We find that even with the same training set size (4.5M), the model trained with the WMT'20 dataset outperforms its WMT'14 counterpart $(-21.02\%$ versus $-29.95\%)$ . Thirdly, we attempt to increase the size of training corpus with WMT20 En-De. Surprisingly, we observe that top region model errors go slightly up. Fourthly, all our models with clean or updated datasets still do not show stronger ranking abilities than random rankings.
+
+All above findings reveal two points: (1) The ranking errors we identified in the main text still exist even with cleaner or up-to-date datasets. The main cause for these ranking problems is not the training set. (2) Using a clean, up-to-date dataset reduces model errors. It helps the model move better hypotheses into the top-region of hypothesis space, thus achieving better kQRG scores. The results for kQRG values are strongly dependent on the datasets.
+
+
+Figure 3: kQRG for deep encoder models.
+
+# C.6 Increasing encoder depth
+
+As discussed in Section 5.1, we plot the model errors for deep encoders in Figure 3. We do not observe a clear trend for smaller or larger model errors when increasing encoder depth.
+
+# D Implementation Details of Exact Top-k
+
+Here we explain the implementation details of our exact top- $k$ algorithm. The detailed algorithm is shown in Algorithm 2. Our implementation is built upon uid-decoding $^{11}$ and sgnmt $^{12}$ projects, and is compatible with the models trained with fairseq. The original implementation of exact top-1 decoding heavily relies on CPU operations. In contrast, our top- $k$ version moves a number of computations to GPU, and improves several implementation details as follows.
+
+- Optimizing the iterating process. As defined the 13-th line of our Algorithm 2, we need to iterate through all words in the vocabulary. However, the order of iterations significantly influences the speed because of the lower bounds. Empirically, we find that iterating the vocabulary greedily substantially reduces the run time.
+- Batching the hypotheses for each time step. As stated at the 14-th line of Algorithm 2, we iterate one word and perform one forward model inference at a time. However, the GPU utilization of this scheme is extremely low. Thus, we use batch technique and batch b different words for one model forward pass, which efficiently increases the GPU utilization.
+
+- Good lower bounds facilitate the search process. We observe that better lower bounds vastly reduce the search time. In our implementation, we use the top $n$ -best list output from the beam search with larger beam sizes than $n$ as our lower bounds.
+
+As a result, the speed is improved significantly.
+
+# D.1 Worst-case Analysis for Exact Search Algorithm
+
+This section analyzes the worst-case behaviors of exact search algorithms. First, let us discuss a simple case when the exact search does not use lower bounds. Given a target sentence set $Y_{l} = \{y|\mathrm{len}(y) = l\}$ where all hypotheses in that set have the same length $l$ , it is obvious that the search operations needed for exact top-1 and exact top- $k$ algorithms are the same, i.e., $N_{l} = |Y_{l}| = |V|^{l}$ . Thus, the total search operations for all lengths $l \in [1,l_{\max}]$ can be computed by $N = \sum_{l \in [1,l_{\max}]} N_{l}$ .
+
+Next, we consider the case with lower bounds. Since lower bounds help trim the search space, the worst case happens when the search algorithm finds the hypotheses in a reversed order. In that case, lower bounds could not trim any search space and have to iterate all hypotheses. Hence, the numbers of search operations needed for both top-1 and top- $k$ algorithms are identical, i.e., $N = \sum_{l\in [1,l_{\max}]}N_l$ operations. On the other hand, both the top-1 and our top- $k$ algorithms are similar to Branch&Bound algorithm (Hendy and Penny, 1982), which cannot lower the time complexity in the worst case, and its time complexity is the same as the one of depth-first-search (DFS) algorithm (Mackworth, 2013). However, it is practically useful because it is proved to be able to improve the search speed significantly.
+
+# D.2 Empirical Computational Cost
+
+This section provides several empirical results to show how different decoding methods perform in terms of computational time. We randomly sample 100 sentences in WMT'14 En-De newstest2014 and report the corresponding run time as well as the number of expansion operations. The expansion operation, i.e., model's forward pass, is the most time-consuming operation in the exact search algorithm and is linear to the number of computation flops. We report the computational costs for three
+
+ALGORITHM 2: DFS-based Top-k Exact Search.
+Input :x: Source sentence, y: Translation prefix (default: [], p: log $P(y|x)$ (default 0.0), k: Top-k hypotheses to output
+Output: List $l$ contains top-k hypotheses with log-probabilities.
+global minHeap
+global $\gamma \gets -\inf$
+Function dfsTopK(x, y, p):
+if $y[|y| - 1] = < / s>$ then
+push(minHeap, (p, y))
+if len(minHeap) > k then
+| pop(minHeap)
+end
+if len(minHeap) = k then
+| $\gamma \gets \min \text{Heap}[0][0]$
+end
+end
+for $v \in V$ do
+ $p' \gets p + \log P(v|x, y)$
+if $p' \geq \gamma$ then
+| dfsTopK(x, [y; v], p')
+end
+end
+return minHeap
+return dfsTopK(x, [], 0.0)
+
+different algorithms, including Beam Search, Exact Top-1 and Exact Top-5. Each reported number is the average over four runs with different samples as inputs.
+
+The results are shown in Table 12. First, we can see that Beam Search is about ten to twenty times faster than exact search algorithms. This is consistent with results in previous literature. Second, compared with previous Exact Search implementation, our implementation of top-5 search has almost the same time cost as top-1, which demonstrates the effectiveness and efficiency of our proposed approach.
+
+By taking the number of expansions into account, we notice two more interesting facts - On the one hand, the number of expansions is not linear to $k$ . Our top- $k$ algorithm explores only about five times the search space compared with top-1 algorithm. On the other hand, our algorithm is significantly more efficient than the original implementation, with four times faster in terms of the number of expansions and only about two times in terms of the computational cost. In our own experiments, we use 8 NVIDIA V100 GPUs for decoding, and it takes about a day to decode exact top-10 on a standard WMT testset.
+
+# D.3 Choice of Different $k$ Values
+
+We first report computational costs with different values of $k$ , shown in Table 13. The computational
+
+| Method | Time Cost (seconds) | Num Expansions |
| Beam Search | 453.0 | - |
| Stahlberg and Byrne (2019) | 8,064.0 | 2,769.6 |
| Exact Top-5 w/ BS lower bounds | 8,914.4 | 6,029.4 |
+
+Table 12: Time cost and number of expansions for exact search algorithms with 4 sampled runs on 100 test sentences.
+
+
+
+
+Figure 4: kRG and kQRG for Transformer base, paraft and big models, with top- $k$ varies in \{10, 20, 30, 50, 75, 100\}
+
+time and the number of expansions grow as $k$ increases. When we enlarge the number of $k$ from 5 to 10, the time costs grow by about 1.9 times (15,916.2/8,914.4), which denotes an almost linear time cost with regard to $k$ . Compared to (Stahlberg and Byrne, 2019), our algorithms are more efficient – Our top-5 algorithm operates two times of expansions and performs comparably with their algorithms in terms of computational time.
+
+Then, regarding the performance with different top- $k$ , we plot models' kRG and kQRG with their top [10, 100] outputs. In Figure 4, when we increase $k$ , kRG values of Transformer-Base ('base') and Transformer-Big ('big') stay close to the random permutation results, while the model trained with forward translation ('paraft') achieves a considerable gap over the random. The gap remains
+
+stable with larger values of $k$ . The kQRG values of all three models show good discrimination. We do not observe a trend of changing relative orders.
+
+These results prove one important and favorable characteristic of our evaluation: Both of our metrics are not sensitive to the choice of $k$ , which validates the usage with a lower value of $k$ to evaluate the model's distribution.
+
+In the main content of our paper, we mainly use top-10 results for our evaluation method for the trade-off between efficiency and effectiveness.
+
+# E Case Study
+
+This section provides a case study for English-German translation outputs for our Exact Top- $k$ decoding algorithm. Table 14 shows the generated hypotheses, their corresponding log probabilities, and BLEU scores.
+
+There are several problems of models' generated outputs based on the example: First, the ranking problem we argue in the main content apparently exists, which is demonstrated in our provided example. For instance, the model gives the highest score to an empty hypothesis (only $<\mathrm{EOS}>$ ), which ranks the model's mode hypothesis the worst in the hypothesis space. Second, the model ranks some sub-optimal hypotheses in the top-10 rankings, like 2-nd, 4-th, 7-th, 10-th. However, the best hypothesis is ranked only at the 10-th position. It can also prove the existence of the ranking problem. Third, the model favors shorter hypotheses. The hypotheses at rank positions 1-st, 6-th, and 9-th are much shorter than the others. The short hypotheses have roughly similar scores compared with the longer ones. Furthermore, most of the hypotheses share a similar prefix, which is similar to the reference, demonstrating that the model can find proper translations with incorrect log probabilities. Those problems indicate the existence of an under-confidence problem, which is in line with our findings in Section 5.1.
+
+| Method | Time Cost (seconds) | Num Expansions |
| Stahlberg and Byrne (2019) | 8,064.0 | 2,769.6 |
| Exact Top-5 w/ BS lower bounds | 8,914.4 | 6,029.4 |
| Exact Top-10 w/ BS lower bounds | 15,916.2 | 10,865.9 |
| Exact Top-20 w/ BS lower bounds | 28,313.9 | 19,155.8 |
+
+Table 13: Computational time and expansions for exact search algorithms when $k$ increases.
+
+# F Limitations
+
+We summarize our proposed method has two limitations. First, each of our approximations has its own limitations. Speaking of top region, the proposed exact search algorithm is computational extensive and local, meaning that it may be limited by its representativeness of the hypothesis space. As for Monte Carlo sampling, the evaluation is fast and more global but captures only coarse-grained model errors. Even so, our two approximations can complement each other's limitations. Second, our proposed metrics are dependent with the value of $k$ and choice of translation function. Specifically, for kRG, when we increase $k$ (Figure 1), the random result also increases. For kQRG, we use COMET in our main content and report ChrF results in Appendix. These two results have very different scale and upper/ lower bounds. This may lead to difficulty in interpretation.
+
+| Rank | LogProb | BLEU | hypothesis |
| Ref | - | 100.00 | Zwei Anlagen so nah beieinander: Absicht oder Schildbürgerstreich? <EOS> |
| 1 | -9.04 | 00.00 | <EOS> |
| 2 | -10.13 | 20.45 | Zwei Leuchten so nah beieinander: absichtlich oder einfach nur ein dummer Fehler? <EOS> |
| 3 | -10.40 | 07.47 | Zwei Leuchten so nahe beieinander: absichtlich oder einfach nur ein dummer Fehler? <EOS> |
| 4 | -10.56 | 22.24 | Zwei Leuchten so nah beieinander: absichtlich oder nur ein dummer Fehler? <EOS> |
| 5 | -10.92 | 08.13 | Zwei Leuchten so nahe beieinander: absichtlich oder nur ein dummer Fehler? <EOS> |
| 6 | -10.94 | 05.89 | Zwei Leuchten so nahe beieinander? <EOS> |
| 7 | -11.10 | 22.24 | Zwei Leuchten so nah beieinander: absichtlich oder einfach ein dummer Fehler? <EOS> |
| 8 | -11.15 | 37.60 | Zwei Leuchten so nah beieinander: Absicht oder einfach nur ein dummer Fehler? <EOS> |
| 9 | -11.21 | 17.63 | Zwei Leuchten so nah beieinander? <EOS> |
| 10 | -11.39 | 40.90 | Zwei Leuchten so nah beieinander: Absicht oder nur ein dummer Fehler? <EOS> |
+
+Table 14: The generated translations with top-10 decoding. The source sentence is "Two sets of lights so close to one another: intentional or just a silly error?"
\ No newline at end of file
diff --git a/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/images.zip b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..5c789feb2ece876e257fd3195d0cb551382490ce
--- /dev/null
+++ b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:08c2f8a87c4c5cdcb972781efc2464f8287cbcc4b5e652b5370a2c5d26e9b41a
+size 875798
diff --git a/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/layout.json b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..73c3a6bcb8665ae891e0a8257d8aeb79123ce6f3
--- /dev/null
+++ b/diggingerrorsinnmtevaluatingandunderstandingmodelerrorsfrompartialhypothesisspace/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7b509eaf37b9e74065f3d36923fdcea80b5f4dd85afcc81ab68d4642792cfb4d
+size 641110
diff --git a/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_content_list.json b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..0b3c1893af5c51ffa618d718f27203fffb779d47
--- /dev/null
+++ b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:305644ca45dc61640ef3f829de8a586accf118ff92271d7df5bd58a03869d37d
+size 50777
diff --git a/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_model.json b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..77118be4852c8a93bfcadc744f9081705aa804b8
--- /dev/null
+++ b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:19c4bff577154bd4853b659ef16badb1c0262ba548f80110de59fc77f7a2bf81
+size 62102
diff --git a/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_origin.pdf b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..96159f459a18b418b8390ecd774f49021997ea1f
--- /dev/null
+++ b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/9b4313b2-8434-4d45-b485-bdf02c4462cc_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0117ebe047cbc4dc70eba1a861e9d7f612ad99836bcc991ddc94bde0ba5201de
+size 641608
diff --git a/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/full.md b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..e2bc03b5f21e6496087ec4c763eb67392f447219
--- /dev/null
+++ b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/full.md
@@ -0,0 +1,233 @@
+# Dimension Reduction for Efficient Dense Retrieval via Conditional Autoencoder
+
+Zhenghao Liu $^{1}$ , Han Zhang $^{1}$ , Chenyan Xiong $^{2}$ , Zhiyuan Liu $^{3}$ , Yu Gu $^{1}$ , and Xiaohua Li $^{1}$
+
+$^{1}$ Department of Computer Science and Technology, Northeastern University, China
+
+$^{2}$ Microsoft Research, United States
+
+$^{3}$ Department of Computer Science and Technology, Institute for AI, Tsinghua University, China
+
+Beijing National Research Center for Information Science and Technology, China
+
+{liuzhenghao,guyu,lixiaohua}@mail.neu.edu.cn
+
+zhanghan@stumail.neu.edu.cn; chenyan.xiong@microsoft.com
+
+liuzy@tsinghua.edu.cn
+
+# Abstract
+
+Dense retrievers encode queries and documents and map them in an embedding space using pre-trained language models. These embeddings need to be high-dimensional to fit training signals and guarantee the retrieval effectiveness of dense retrievers. However, these high-dimensional embeddings lead to larger index storage and higher retrieval latency. To reduce the embedding dimensions of dense retrieval, this paper proposes a Conditional Autoencoder (ConAE) to compress the high-dimensional embeddings to maintain the same embedding distribution and better recover the ranking features. Our experiments show that ConAE is effective in compressing embeddings by achieving comparable ranking performance with its teacher model and making the retrieval system more efficient. Our further analyses show that ConAE can alleviate the redundancy of the embeddings of dense retrieval with only one linear layer. All codes of this work are available at https://github.com/NEUIR/ConAE.
+
+# 1 Introduction
+
+As the first stage of numerous multi-stage IR and NLP tasks (Nogueira et al., 2019; Chen et al., 2017; Thorne et al., 2018), dense retrievers (Xiong et al., 2021a) have shown lots of advances in conducting semantic searching and avoiding the vocabulary mismatch problem (Robertson and Zaragoza, 2009). Dense retrievers usually encode queries and documents as high-dimensional embeddings, which are necessary to guarantee retrieval effectiveness during training (Ma et al., 2021; Reimers and Gurevych, 2021). Nevertheless, high dimensional embeddings usually exhaust the memory to store the index and lead to longer retrieval latency (Indyk and Motwani, 1998; Meiser, 1993).
+
+The research of building efficient dense retrieval systems has been stimulated recently (Min et al.,
+
+2021). To reduce the dimensions of document embeddings, existing work reserves the principle dimensions or compresses query and document embeddings for building more efficient retrievers (Yang and Seo, 2021; Ma et al., 2021).
+
+There are two challenges in compressing embeddings of dense retrievers: The compressed embeddings should share a similar distribution with the original embeddings, making the low-dimensional embedding space uniform and the document embeddings distinguishable; All the compressed embeddings should have the ability to maintain the maximal information for matching related queries and documents during retrieval, which helps better align the related query-document pairs.
+
+This paper proposes a Conditional Autoencoder (ConAE), which aims to build efficient dense retrieval systems by reducing the embedding dimensions of queries and documents. ConAE first encodes high-dimensional embeddings into a low-dimensional embedding space and then generates embeddings that can be aligned to related queries or documents in the original embedding space. In addition, ConAE designs a conditional loss to regulate the low-dimensional embedding space to mimic the embedding distribution of high-dimensional embeddings. Our experiments show that ConAE is effective to compress the high-dimensional embeddings and avoid redundant ranking features by achieving comparable retrieval performance with vanilla dense retrievers and better visualizing the embedding space with t-SNE.
+
+# 2 Related Work
+
+Dense retrievers use a bi-encoder architecture to encode queries and documents and map them in an embedding space for retrieval (Karpukhin et al., 2020; Xiong et al., 2021b,a; Lewis et al., 2020; Zhan et al., 2021; Li et al., 2021; Yu et al., 2021).
+
+To learn an effective embedding space, dense retrievers are forced to maintain high-dimensional embeddings to fit training signals.
+
+The most direct way to reduce the dimension of embeddings is that retaining parts of the dimensions of high-dimensional embeddings (Yang and Seo, 2021; Ma et al., 2021). Some work uses the first 128 dimensions to encode both queries and documents (Yang and Seo, 2021) or utilizes PCA to retain the primary dimensions to recover most information from the raw embeddings (Ma et al., 2021). Other work (Ma et al., 2021) proposes a supervised method, which uses neural networks to compress the high-dimensional embeddings as lower-dimensional ones. These supervised models provide a better dimension reduction way than unsupervised models by avoiding missing too much information. To optimize the encoders, some work (Ma et al., 2021) continuously trains dense retrievers with the contrastive training strategies (Karpukhin et al., 2020; Xiong et al., 2021a).
+
+# 3 Methodology
+
+This section introduces our Conditional Autoencoder (ConAE). We first introduce the preliminaries of dense retrieval (Sec. 3.1), and then describe the architecture of ConAE (Sec. 3.2).
+
+# 3.1 Preliminary of Dense Retrieval
+
+Given a query $q$ and a document collection $D = \{d_1, \ldots, d_j, \ldots, d_n\}$ , dense retrievers (Xiong et al., 2021b,a; Karpukhin et al., 2020) employ pretrained language models (Devlin et al., 2019; Liu et al., 2019) to encode $q$ and $d$ as $K$ -dimensional embeddings, $h_q$ and $h_d$ .
+
+Then we can calculate the retrieval score $f(q, d)$ of $q$ and $d$ with dot product $f(h_q, h_d) = h_q \cdot h_d$ . Then we contrastively train query and document encoders by maximizing the retrieval probability $P(d^{+} | q, \{d^{+}\} \cup D^{-})$ of the relevant document $d^{+}$ (Xiong et al., 2021b,a):
+
+$$
+P \left(d ^ {+} \mid q, \left\{d ^ {+} \right\} \cup D ^ {-}\right) = \frac {e ^ {f \left(h _ {q} , h _ {d +}\right)}}{e ^ {f \left(h _ {q} , h _ {d +}\right)} + \sum_ {d ^ {-} \in D ^ {-}} e ^ {f \left(h _ {q} , h _ {d -}\right)}}, \tag {1}
+$$
+
+where $d^{-}$ is the document sampled from the irrelevant document set $D^{-}$ (Karpukhin et al., 2020; Xiong et al., 2021a).
+
+# 3.2 Dimension Compression with ConAE
+
+In this subsection, we introduce ConAE to compress the $K$ -dimensional embeddings $h_q$ and $h_d$ of
+
+both queries and documents to the $L$ -dimensional embeddings $h_q^e$ and $h_d^e$
+
+Encoder. We first get the initial representations $h_q$ and $h_d$ for query $q$ and document $d$ from existing dense retrievers, such as ANCE (Xiong et al., 2021a). Then these $K$ -dimensional embeddings can be compressed to low dimensional ones with two different linear layers, $\mathrm{Linear}_q$ and $\mathrm{Linear}_d$ :
+
+$$
+h _ {q} ^ {e} = \operatorname {L i n e a r} _ {q} \left(h _ {q}\right); h _ {d} ^ {e} = \operatorname {L i n e a r} _ {d} \left(h _ {d}\right). \tag {2}
+$$
+
+$h_q^e$ and $h_d^e$ are $L$ -dimensional embeddings. The dimension $L$ can be 256, 128 or 64, which is much lower than the dimension $K$ of $h_q$ and $h_d$ .
+
+Then we use KL divergence to regulate encoded embeddings to mimic the initial embedding distributions of queries and documents:
+
+$$
+L _ {K L} = \sum_ {q} \sum_ {d \in D _ {\mathrm {t o p}}} P (d | q, D _ {\mathrm {t o p}}) \cdot \log \frac {P (d | q , D _ {\mathrm {t o p}})}{P _ {e} (d | q , D _ {\mathrm {t o p}})}, \tag {3}
+$$
+
+where $P_{e}(d|q,D_{\mathrm{top}})$ is calculated with E.q.1, using the encoded embeddings $h_q^e$ and $h_d^e$ . $D_{\mathrm{top}}$ consists of the top-ranked documents, which are searched by the teacher retriever-ANCE.
+
+Decoder. The decoder module maps the encoded embeddings $h_q^e$ and $h_d^e$ into the original embedding space by aligning the compressed embeddings $h_q^e$ and $h_d^e$ with $h_q$ and $h_d$ . It aims at optimizing encoder modules to maximally maintain ranking features from the initial representations $h_q$ and $h_d$ of query and document.
+
+Firstly, we use one linear layer to project $h_q^e$ and $h_d^e$ to $K$ -dimensional embeddings, $\hat{h}_q$ and $\hat{h}_d$ :
+
+$$
+\hat {h} _ {q} = \operatorname {L i n e a r} \left(h _ {q} ^ {e}\right); \hat {h} _ {d} = \operatorname {L i n e a r} \left(h _ {d} ^ {e}\right). \tag {4}
+$$
+
+Then we respectively train the decoded embeddings $\hat{h}_q$ and $\hat{h}_d$ to align with $h_q$ and $h_d$ in the original embedding space using two max margin losses $L_{q}$ and $L_{d}$ . The max margin loss is widely used in previous neural IR research to optimize the ranking scores (Xiong et al., 2017; Dai et al., 2018).
+
+The first loss $L_{q}$ is used to optimize the decoded query representation $\hat{h}_q$ :
+
+$$
+L _ {q} = \sum_ {q} 1 + \tanh f \left(\hat {h} _ {q}, h _ {d ^ {-}}\right) - \tanh f \left(\hat {h} _ {q}, h _ {d ^ {+}}\right), \tag {5}
+$$
+
+and we can also optimize the decoded document representation $\hat{h}_d$ with the second loss function $L_{d}$
+
+$$
+L _ {d} = \sum_ {q} 1 + \tanh f \left(h _ {q}, \hat {h} _ {d ^ {-}}\right) - \tanh f \left(h _ {q}, \hat {h} _ {d ^ {+}}\right). \tag {6}
+$$
+
+| Dataset | #Doc | Train | #Queries Dev | Test |
| MS MARCO | 8,841,823 | 452,939 | 50,000 | 6,980 |
| NQ | 21,015,323 | 79,168 | 8,757 | 3,610 |
| TREC DL | 8,841,823 | - | - | 43 |
| TREC-COVID | 171,332 | - | - | 50 |
+
+Table 1: Data Statistics.
+
+Training Loss. Finally, we train our conditional autoencoder model with the following loss $L$ :
+
+$$
+L = L _ {K L} + \lambda L _ {q} + \lambda L _ {d}, \tag {7}
+$$
+
+where $\lambda$ is a hyper-parameter to weight the autoencoder losses.
+
+# 4 Experimental Methodology
+
+This section describes the datasets, evaluation metrics, baselines and implementation details of our experiments.
+
+Dataset. Four datasets are used to evaluate the retrieval effectiveness of different dimension reduction models, including MS MARCO (Passage Ranking) (Nguyen et al., 2016), NQ (Kwiatkowski et al., 2019), TREC DL (Craswell et al., 2020) and TREC-COVID (Roberts et al., 2020). In our experiments, we randomly sample 50,000 queries from the raw training set of MS MARCO as the development set and use MS MARCO (Dev) as the testing set. The dimension reduction models that are trained on MS MARCO are also evaluated on two benchmarks, TREC DL and TREC-COVID, aiming to evaluate their generalization ability. All data statistics are shown in Table 1.
+
+Evaluation Metrics. NDCG@10 is used as the evaluation metric on three benchmarks, MS MARCO, TREC DL and TREC-COVID. MS MARCO also uses MRR@10 as the primary evaluation metric (Nguyen et al., 2016). For the NQ dataset, the hit accuracy on Top20 and Top100 is used as the evaluation metric, which is the same as previous work (Karpukhin et al., 2020).
+
+Baselines. In our experiments, we compare ConAE with two baselines from previous work (Ma et al., 2021), Principle Component Analysis (PCA) and CE. PCA reduces the embedding dimension by retaining the principle dimensions that can keep most of the variance within the original representation. CE model uses two linear layers $W_{q}$ and $W_{d}$ without biases to transform dense representations of queries and documents into lower embeddings (Ma et al., 2021). We also start from CE models and continuously train the whole model to
+
+implement our ANCE models to generate query and document embeddings of different dimensions.
+
+Implementation Details. The rest describes our implementation details. All embedding dimension reduction models base on one of the best dense retrievers ANCE (Xiong et al., 2021a) and build document index with exact matching (flat index), which is implemented by FAISS (Johnson et al., 2019). During training ConAE, we set the hyperparameter $\lambda$ as 0.1 and search Top100 documents using vanilla ANCE to construct the $D_{\mathrm{top}}$ collection for each query. For our CE and ANCE models, we sample 7 negative documents for each query to contrastively train these models and sample 1 negative document to train ConAE. In our experiments, we set the batch size to 2 and accumulate step to 8 for ANCE. The batch size and accumulate step are 128 and 1 for other models. All models are implemented with PyTorch and tuned with Adam optimizer. The learning rates of ANCE and other models are set to $2e - 6$ and 0.001, respectively.
+
+# 5 Evaluation Result
+
+Four experiments are conducted in this section to study the effectiveness of ConAE in reducing embedding dimensions for dense retrieval.
+
+# 5.1 Overall Performance
+
+The performance of different dimension reduction models is shown in Table 2. PCA, CE and ConAE are based on ANCE (Teacher), which freezes the teacher model and only optimizes the dimension projection layers. ANCE starts from CE and continuously tunes all parameters in the model.
+
+Compared with PCA and CE (Ma et al., 2021), ConAE achieves the best performance on almost of datasets, which shows its effectiveness in compressing dense retrieval embeddings. ConAE can achieve comparable performance with ANCE (Teacher) using 128-dimensional embeddings to build the document index on MS MARCO, which reduces the retrieval latency (from $17.152\mathrm{ms}$ to $3.942\mathrm{ms}$ per query) and saves the index storage (from 26.0G to 4.3G) significantly. It demonstrates that ConAE is effective to alleviate the redundancy of the embeddings learned by dense retrievers.
+
+Among all baselines, PCA shows significantly worse ranking performance on MS MARCO, indicating that embedding dimensions of dense retrievers are usually nonorthogonal. ConAE-128 achieves more than $11\%$ improvements than
+
+| Method | MS MARCO | NQ | TREC DL | TREC-COVID |
| Latency(ms) | MRR@10 | NDCG@10 | Rec@1000 | Top20 | Top100 | NDCG@10 | NDCG@10 |
| Teacher-768 | 17.152 | 0.3302 | 0.3877 | 0.9584 | 0.8224 | 0.8787 | 0.6489 | 0.6529 |
| ANCE-256 | 6.159 | 0.3145 | 0.3709 | 0.9545 | 0.8188 | 0.8765 | 0.6455 | 0.5722 |
| PCA-256 | 6.296 | 0.2440 | 0.2940 | 0.9257 | 0.8042 | 0.8715 | 0.5118 | 0.2601 |
| CE-256 | 7.344 | 0.2959 | 0.3472 | 0.9333 | 0.8066 | 0.8726 | 0.5916 | 0.4110 |
| ConAE-256 | 7.158 | 0.3294 | 0.3864 | 0.9560 | 0.8053 | 0.8723 | 0.6438 | 0.6405 |
| ANCE-128 | 3.419 | 0.3092 | 0.3667 | 0.9527 | 0.8069 | 0.8709 | 0.6514 | 0.5612 |
| PCA-128 | 3.525 | 0.2348 | 0.2838 | 0.9170 | 0.7875 | 0.8620 | 0.4795 | 0.2523 |
| CE-128 | 4.530 | 0.2917 | 0.3438 | 0.9345 | 0.7934 | 0.8668 | 0.6170 | 0.4692 |
| ConAE-128 | 3.942 | 0.3245 | 0.3816 | 0.9523 | 0.8064 | 0.8687 | 0.6380 | 0.6381 |
| ANCE-64 | 3.041 | 0.2773 | 0.3295 | 0.9217 | 0.7687 | 0.8474 | 0.6003 | 0.4731 |
| PCA-64 | 2.627 | 0.1855 | 0.2259 | 0.8540 | 0.6698 | 0.7928 | 0.3788 | 0.2174 |
| CE-64 | 3.046 | 0.2551 | 0.3036 | 0.9042 | 0.7404 | 0.8341 | 0.5561 | 0.3968 |
| ConAE-64 | 3.087 | 0.2862 | 0.3376 | 0.9222 | 0.7604 | 0.8460 | 0.5877 | 0.5006 |
+
+
+(a) Teacher (t-SNE).
+
+
+Figure 1: Embedding Visualization of Different Dense Retrievers. Figure 1(a), 1(b) and 1(c) are plotted with t-SNE with 768, 128 and 64 dimensional embeddings. In Figure 1(d), we directly use ConAE w/o Decoder to visualize the document embedding space of ANCE. The “ $\bullet$ ” in “dark orange” color denotes the golden document that ranked 2nd by ConAE-64 and 1st by other models. For other documents, darker blue ones are more relevant to the query.
+
+
+(b) ConAE-128 (t-SNE).
+(c) ConAE-64 (t-SNE).
+
+
+(d) Teacher (ConAE).
+
+Table 2: Performance of Different Dimension Reduction Models. We start from ANCE (Teacher), reduce the embedding dimension and evaluate their retrieval effectiveness. The document indices are built with flat index and the sizes of MS MARCO indices are 26.0G, 8.5G, 4.3G and 2.2G for 768, 256, 128 and 64 dimensional embeddings.
+
+| Method | MS MARCO MRR@10 | TREC-COVID NDCG@10 | TREC DL NDCG@10 |
| ConAE-256 | 0.3294 | 0.6405 | 0.6438 |
| w/o Decoder | 0.3271 | 0.6546 | 0.6377 |
| w/o KL | 0.3276 | 0.6218 | 0.6491 |
| ConAE-128 | 0.3245 | 0.6381 | 0.6380 |
| w/o Decoder | 0.3203 | 0.6525 | 0.6266 |
| w/o KL | 0.3234 | 0.6365 | 0.6367 |
| ConAE-64 | 0.2862 | 0.5006 | 0.5877 |
| w/o Decoder | 0.2846 | 0.4703 | 0.5951 |
| w/o KL | 0.2822 | 0.4658 | 0.5759 |
+
+Table 3: Retrieval Performance of Different Ablation Models. ConAE w/o Decoder and ConAE w/o KL use $L_{KL}$ and $L_{q} + L_{d}$ to train the distillation models.
+
+CE and performs much better on TREC-COVID, demonstrating its ranking effectiveness and generalization ability. ANCE can further improve the retrieval performance of CE by continuously training the query and document encoders, which adapts the teacher model to the low-dimensional version.
+
+# 5.2 Ablation Study
+
+This subsection conducts ablation studies in Table 3 to investigate the effectiveness of different modules in our ConAE model.
+
+The different modules in ConAE play different roles. Compared with ConAE w/o Decoder, ConAE w/o KL usually shows better retrieval effectiveness on the two benchmarks MS MARCO and TREC DL, which ask the model to retrieve candidates from the same data source. It demonstrates that our autoencoder architecture can reserve more ranking features to fit the training supervision of MS MARCO. On the other hand, ConAE w/o Decoder shows stronger generalization ability by outperforming ConAE w/o KL on TREC-COVID, which belongs to a different domain. The source of the generalization ability of ConAE w/o Decoder may come from finer-grained training signals from our teacher model. The annotated training signals usually face the hole rate problem (Xiong et al., 2020) and using neural IR models to denoise the training signals has shown strong effectiveness in training neural IR models (Qu et al., 2021).
+
+ConAE combines both KL and autoencoder architectures to fully use training signals and regulate the distribution of compressed embedding, which usually achieves better retrieval performance.
+
+# 5.3 Embedding Visualization with ConAE
+
+We randomly sample one case from MS MARCO and visualize the embedding space of query and retrieved documents in Figure 1.
+
+We first employ t-SNE (van der Maaten and Hinton, 2008) to visualize the embedding spaces of ANCE (Teacher) and ConAE. As shown in Figure 1(b), ConAE-128 conducts a more meaningful visualization results: the related query-document pair is closer and the other documents are distributed around the golden document according to their relevance to the query. The visualization of ANCE (Teacher) is slightly distorted and different from our expectations, which is mainly due to its redundancy. The redundant features usually mislead t-SNE to overfit these ranking features, thus reducing the embedding dimension of dense retrievers to 128 provides a possible way to alleviate redundant features and better visualize the embedding space of dense retrievers using t-SNE. Besides, ConAE-64 shows decreased retrieval performance than ConAE-128 (Sec. 5.1). As shown in Figure 1(c), it mainly derives from that ConAE-64 loses some ranking features with the limited embedding dimensions.
+
+The other way to visualize the embedding space is using ConAE w/o Decoder to project the embedding to a 2-dimensional coordinate. It uses KL divergence to optimize the 2-dimensional embeddings to mimic the relevance score distribution of teacher models. As shown in Figure 1(d), the distributions of documents are distinguishable, which provides an intuitive way to analyze the ranking-oriented document distribution. In addition, the query is usually far away from the documents. The main reason lies that the relevance scores are calculated by dot product and the embedding norms are meaningful to distinguish the relevant documents.
+
+# 5.4 Retrieval Performance with HNSW
+
+Besides exact searching, we also show retrieval results of different dimension reduction methods in Table 4, which are implemented by the approximate nearest neighbor (ANN) search, Hierarchical Navigable Small World (HNSW). Using HNSW, the retrieval efficiency can be further improved, especially for high-dimensional embeddings. ConAE keeps its advanced retrieval performance again with less than 1ms retrieval latency.
+
+| Dim. | Method | Latency (ms) | MS MARCO |
| MRR@10 | NDCG@10 |
| 768 | ANCE | 2.056 | 0.3295 | 0.3869 |
| 256 | PCA | 1.016 | 0.2427 | 0.2924 |
| CE | 1.646 | 0.2948 | 0.3461 |
| ConAE | 1.478 | 0.3257 | 0.3818 |
| 128 | PCA | 0.702 | 0.2340 | 0.2829 |
| CE | 1.047 | 0.2906 | 0.3424 |
| ConAE | 0.978 | 0.3209 | 0.3770 |
| 64 | PCA | 0.616 | 0.1844 | 0.2246 |
| CE | 0.860 | 0.2545 | 0.3030 |
| ConAE | 0.983 | 0.2837 | 0.3344 |
+
+Table 4: ANN Retrieval Effectiveness of Different Models. The ANN index is built with HNSW.
+
+# 6 Conclusion
+
+This paper presents ConAE, which reduces the embedding dimension of dense retrievers. Our experiments show that ConAE can achieve comparable retrieval performance with the teacher model, significantly reduce the index storage and accelerate the searching process. Our further analyses show that the high-dimensional embeddings of dense retrievers are usually redundant and ConAE helps to alleviate such redundancy and visualize the embedding space more intuitively and effectively.
+
+# Limitations
+
+In this paper, we mainly focus on compressing the embeddings of dense retrievers in an additional stage between query/document encoding and index building. As a result, we fix query and document embeddings of dense retrievers and project high-dimensional embeddings to low-dimensional ones using only one linear layer. Thus, the effectiveness of ConAE is limited by the number of learnable parameters. Even though ConAE shows comparable performance with ANCE (Teacher), joint modeling the query/document encoder, dimension reduction module and index building still show strong potential to achieve better retrieval performance.
+
+# Acknowledgments
+
+This work is mainly supported by Beijing Academy of Artificial Intelligence (BAAI) as well as supported in part by the Natural Science Foundation of China under Grant No. 62206042 and No. 62006129, the Fundamental Research Funds for the Central Universities under Grant No. N2216013, China Postdoctoral Science Foundation under Grant No. 2022M710022 and National Science and Technology Major Project (J2019-IV-0002-0069).
+
+# References
+
+Danqi Chen, Adam Fisch, Jason Weston, and Antoine Bordes. 2017. Reading Wikipedia to answer open-domain questions. In Proceedings of ACL, pages 1870-1879.
+Nick Craswell, Bhaskar Mitra, Emine Yilmaz, and Daniel Campos. 2020. Overview of the trec 2020 deep learning track.
+Zhuyun Dai, Chenyan Xiong, Jamie Callan, and Zhiyuan Liu. 2018. Convolutional neural networks for soft-matching n-grams in ad-hoc search. In Proceedings of WSDM, pages 126-134.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: pre-training of deep bidirectional transformers for language understanding. In Proceedings of NAACL-HLT, pages 4171-4186.
+Piotr Indyk and Rajeev Motwani. 1998. Approximate nearest neighbors: towards removing the curse of dimensionality. In Proceedings of the thirtieth annual ACM symposium on Theory of computing, pages 604-613.
+Jeff Johnson, Matthijs Douze, and Hervé Jégou. 2019. Billion-scale similarity search with gpus. IEEE Transactions on Big Data.
+Vladimir Karpukhin, Barlas Oğuz, Sewon Min, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. In Proceedings of EMNLP, pages 6769-6781.
+Tom Kwiatkowski, Jennimaria Palomaki, Olivia Redfield, Michael Collins, Ankur Parikh, Chris Alberti, Danielle Epstein, Illia Polosukhin, Jacob Devlin, Kenton Lee, et al. 2019. Natural questions: A benchmark for question answering research. Transactions of the Association for Computational Linguistics, 7:452-466.
+Mike Lewis, Marjan Ghazvininejad, Gargi Ghosh, Armen Aghajanyan, Sida Wang, and Luke Zettlemoyer. 2020. Pre-training via paraphrasing. In Proceedings of NeurIPS.
+Yizhi Li, Zhenghao Liu, Chenyan Xiong, and Zhiyuan Liu. 2021. More robust dense retrieval with contrastive dual learning. In Proceedings of the 2021 ACM SIGIR International Conference on Theory of Information Retrieval, pages 287-296.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized BERT pretraining approach.
+Xueguang Ma, Minghan Li, Kai Sun, Ji Xin, and Jimmy Lin. 2021. Simple and effective unsupervised redundancy elimination to compress dense vectors for
+
+passage retrieval. In Proceedings of EMNLP, pages 2854-2859.
+Stefan Meiser. 1993. Point location in arrangements of hyperplanes. Information and Computation, 106(2):286-303.
+Sewon Min, Jordan Boyd-Graber, Chris Alberti, Danqi Chen, Eunsol Choi, Michael Collins, Kelvin Guu, Hannaneh Hajishirzi, Kenton Lee, Jennimaria Palomaki, et al. 2021. Neurips 2020 efficientqa competition: Systems, analyses and lessons learned. In Proceedings of the NeurIPS 2020 Competition and Demonstration Track, pages 86-111.
+Tri Nguyen, Mir Rosenberg, Xia Song, Jianfeng Gao, Saurabh Tiwary, Rangan Majumder, and Li Deng. 2016. MS MARCO: A human generated machine reading comprehension dataset. In Proceedings of the Workshop on Cognitive Computation: Integrating neural and symbolic approaches 2016 co-located with the 30th Annual Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain, December 9, 2016, volume 1773.
+Rodrigo Nogueira, Wei Yang, Jimmy Lin, and Kyunghyun Cho. 2019. Document expansion by query prediction.
+Yingqi Qu, Yuchen Ding, Jing Liu, Kai Liu, Ruiyang Ren, Wayne Xin Zhao, Daxiang Dong, Hua Wu, and Haifeng Wang. 2021. Rocketqa: An optimized training approach to dense passage retrieval for open-domain question answering. In Proceedings of NAACL-HLT, pages 5835-5847.
+Nils Reimers and Iryna Gurevych. 2021. The curse of dense low-dimensional information retrieval for large index sizes. In Proceedings of ACL, pages 605-611.
+Kirk Roberts, Tasmeer Alam, Steven Bedrick, Dina Demner-Fushman, Kyle Lo, Ian Soboroff, Ellen Voorhees, Lucy Lu Wang, and William R Hersh. 2020. Trec-covid: rationale and structure of an information retrieval shared task for covid-19. Journal of the American Medical Informatics Association, 27(9):1431-1436.
+Stephen Robertson and Hugo Zaragoza. 2009. The probabilistic relevance framework: BM25 and beyond. Now Publishers Inc.
+James Thorne, Andreas Vlachos, Oana Cocarascu, Christos Christodoulopoulos, and Arpit Mittal. 2018. The fact extraction and VERIFICATION (FEVER) shared task. In Proceedings of the First Workshop on Fact Extraction and VERIFICATION (FEVER), pages 1-9.
+Laurens van der Maaten and Geoffrey Hinton. 2008. Visualizing data using t-sne. Journal of Machine Learning Research, 9:2579-2605.
+Chenyan Xiong, Zhuyun Dai, Jamie Callan, Zhiyuan Liu, and Russell Power. 2017. End-to-end neural ad-hoc ranking with kernel pooling. In Proceedings of SIGIR, pages 55-64.
+
+Chenyan Xiong, Zhenghao Liu, Si Sun, Zhuyun Dai, Kaitao Zhang, Shi Yu, Zhiyuan Liu, Hoifung Poon, Jianfeng Gao, and Paul Bennett. 2020. Cmt in treccovid round 2: mitigating the generalization gaps from web to special domain search.
+Lee Xiong, Chenyan Xiong, Ye Li, Kwok-Fung Tang, Jialin Liu, Paul N. Bennett, Junaid Ahmed, and Arnold Overwijk. 2021a. Approximate nearest neighbor negative contrastive learning for dense text retrieval. In Proceedings of ICLR.
+Wenhan Xiong, Xiang Lorraine Li, Srinivasan Iyer, Jingfei Du, Patrick S. H. Lewis, William Yang Wang, Yashar Mehdad, Wen-tau Yih, Sebastian Riedel, Douwe Kiela, and Barlas Oguz. 2021b. Answering complex open-domain questions with multi-hop dense retrieval. In Proceedings of ICLR.
+Sohee Yang and Minjoon Seo. 2021. Designing a minimal retrieve-and-read system for open-domain question answering. In Proceedings of NAACL-HLT, pages 5856-5865.
+Shi Yu, Zhenghao Liu, Chenyan Xiong, Tao Feng, and Zhiyuan Liu. 2021. Few-shot conversational dense retrieval. In Proceedings of SIGIR.
+Jingtao Zhan, Jiaxin Mao, Yiqun Liu, Min Zhang, and Shaoping Ma. 2021. Optimizing dense retrieval model training with hard negatives. In Proceedings of SIGIR.
\ No newline at end of file
diff --git a/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/images.zip b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..bfcf8b91bd6aac4fbc3c8c5dba21d2a0031d626e
--- /dev/null
+++ b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:135b95a523caf72cfcecfb9a471af566808c233565ec41030c46179a5bf779ad
+size 266198
diff --git a/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/layout.json b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..bf765e3172cf8efff1867f55d36bafe4649cddb4
--- /dev/null
+++ b/dimensionreductionforefficientdenseretrievalviaconditionalautoencoder/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:80359043a80f0ce0eb77ec8f950160c2974ee972fbfaa77a62d09c5ddcd6c2e7
+size 271327
diff --git a/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_content_list.json b/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..205ede8274c13eeae127e7a6e3fc0c15583bb5ca
--- /dev/null
+++ b/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:43179aeb3e73aec528764c5e9d92366244fabdcc254c3883ae0b7b1bceb3eb0e
+size 73457
diff --git a/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_model.json b/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..2904be71520d836b0162d18c2bcb2d20402e986c
--- /dev/null
+++ b/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:74a4d8d8896f4f0d458d2cf350df86ebbaede1689547180cbe66895ee6b2e713
+size 90130
diff --git a/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_origin.pdf b/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..beb9bf733cf3208ee599abe0dee2907a8c1cd2fb
--- /dev/null
+++ b/directionsfornlppracticesappliedtoonlinehatespeechdetection/afc07e98-9288-4152-aa7c-3f211eb50e7a_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2039444a764bbfae17af448240b1c74a3407d5fde84a0728fa0e679b0a6f8c4e
+size 243425
diff --git a/directionsfornlppracticesappliedtoonlinehatespeechdetection/full.md b/directionsfornlppracticesappliedtoonlinehatespeechdetection/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..764f4b0c960911b7a56ce4d656be9986a3681417
--- /dev/null
+++ b/directionsfornlppracticesappliedtoonlinehatespeechdetection/full.md
@@ -0,0 +1,245 @@
+# Directions for NLP Practices Applied to Online Hate Speech Detection
+
+Paula Fortuna,
+Mónica Domínguez
+NLP Group
+Pompeu Fabra University
+Barcelona, Spain
+first.last@upf.edu
+
+Leo Wanner
+ICREA and
+Pompeu Fabra University
+Barcelona, Spain
+leo.wanner@upf.edu
+
+Zeerak Talat Simon Fraser University Burnaby, Vancouver zeerak_talat@sfu.ca
+
+# Abstract
+
+Addressing hate speech in online spaces has been conceptualized as a classification task that uses Natural Language Processing (NLP) techniques. Through this conceptualization, the hate speech detection task has relied on common conventions and practices from NLP. For instance, inter-annotator agreement is conceptualized as a way to measure dataset quality and certain metrics and benchmarks are used to assure model generalization. However, hate speech is a deeply complex and situated concept that eludes such static and disembodied practices. In this position paper, we critically reflect on these methodologies for hate speech detection, we argue that many conventions in NLP are poorly suited for the problem and encourage researchers to develop methods that are more appropriate for the task.
+
+# 1 Introduction
+
+Online hate speech is the cause for growing concern, due to its social impacts (Soral et al., 2018). In response, automatic detection of hate speech has become a popular research area in Natural Language Processing (NLP), with a substantial number of papers at leading conferences, targeted workshops and shared tasks dedicated to it. Simultaneously, content moderation infrastructures that rely on machine learning technologies have been proposed to address the propagation of online harms.
+
+The increase in research interest to hate speech detection has spurred on a growth and variety in annotated resources for the task created within the academy and industry. However, at the same time, critical work on hate speech detection has found that there are significant challenges related to the published research outcome with respect to the construction of data (Vidgen and Derczynski, 2021; Fortuna et al., 2020), model generalizability (Nozza, 2021; Fortuna et al., 2021), and socially biased effects of models (Talat et al., 2018; Davidson
+
+et al., 2019). These challenges indicate that despite a techno-optimist attitude from the NLP community to the task (Talat et al., 2021), the acceleration in research on the topic has impeded a maturation of the basic conventions, principles and practices which this research is based on. Hence, it seems timely to assess whether the NLP conventions and practices that have been followed so far are indeed appropriate for the classification of hate speech.
+
+In contrast to prior work, which has sought to address specific shortcomings of machine learning algorithms for hate speech detection (e.g., Dixon et al., 2018), our work presents a comprehensive analysis of the inadequacies of some of NLP's methodological conventions for algorithmic hate speech detection. That is, in this position paper we reflect on contemporary methodological challenges that arise from applying common NLP methodologies to hate speech detection.
+
+More specifically, we a) reflect on frequently used conventions for classification of text and explore their inadequacies with reference to hate speech detection; and b) discuss the future of current methodologies for this task. On the basis of our analysis, we conclude that current models are incapable of detecting hate speech without harms to marginalized communities. We therefore call for the scientific community to adapt NLP methodologies such that future developments center the impacts that used methodologies may have on marginalized communities. We believe that by critically reflecting on the potential real-world impacts of the methodologies for hate speech detection on marginalized communities, the scientific community can come to identify methodologies that result in more just futures.
+
+# 2 Reflections On Hate Speech Detection
+
+Hate speech detection is commonly conceptualized as a supervised classification task, with the goal to determine whether content is hateful or not (Yin
+
+and Zubiaga, 2021). This setting requires that we i) define the problem; ii) collect, sample, and annotate data to obtain labels;1 and iii) apply optimization technologies (i.e. machine learning algorithms) to the labeled data. Finally, the resulting methods and models are evaluated using specific metrics and techniques. In this section, we review these stages through the lens of hate speech detection.
+
+# 2.1 Definitional Challenges of Hate Speech
+
+Defining hate speech is to control the discourse surrounding the phenomena; determine which groups are minoritized, and therefore should be protected; and which patterns of speech should be sanctioned (Gelber, 2021). Coining a definition of hate speech is therefore a political task, in particular due to the implication that each of the many available possible definitions carry (Thylstrup and Talat, 2020). While definitions are subject to the cultural norms of the geography in which they are created (Talat et al., 2022), universalist assumptions surrounding established definitions of hate speech in NLP fail to account for the diversity required for the task. Such universalist assumptions allow for hate speech detection infrastructures as “a third layer of interpretation” between the sender and recipient of a message (Thylstrup and Talat, 2020).
+
+Moreover, hate speech is often categorized under the umbrella terms such as "abusive language", "offensive language", or "toxicity" (Poletto et al., 2021; Jigsaw, 2019), resulting in a concept drift, where hate speech cedes prominence to the more generic concepts, such as generally offensive language. As a result, models are prone to learn patterns that emphasize the more frequently occurring categories (e.g. 'insult') and under-perform on hate speech (Fortuna et al., 2020).
+
+Furthermore, most NLP research exclusively considers textual material, assuming that it provides adequate information. However, hate speech is deeply tied to oppression and it is therefore necessary to understand the speaker and listener's subjectivities to situate the text and adjudicate whether it constitutes hate speech. More often than not, this information is unavailable from the text.
+
+# 2.2 On Challenges of Hate Speech Annotation
+
+A common convention in labeling a dataset is to use an odd number of annotations for each text sample. The reliability of the labels in a dataset is often measured by computing the Inter-Annotator Agreement (IAA). In this section, we discuss biases in annotations and the paradoxical search for ground truth within disagreement.
+
+# 2.2.1 Annotation Bias
+
+Socially biased systems are a growing concern within NLP (Blodgett et al., 2020; Talat et al., 2022). Social biases are particularly apparent in hate speech datasets (and models) as biases are a reflection of wider social tension. Data source selection and sampling strategies can also be contributors to the social biases found in datasets and models. For instance, data samples often skew towards particular perpetrators or keywords (e.g., slurs), resulting in datasets that favor explicit abuse and hate speech (e.g. Davidson et al., 2017; Basile et al., 2019; Founta et al., 2018). Collected data samples are then annotated through the lens of the selected definitions of hate speech, and the IAA is computed. Once satisfactory levels of agreement have been obtained, the "ground-truth" for each text is selected (Pustejovsky and Stubbs, 2012), often by selecting the label chosen by the majority of annotators. Thus, labels embed the subjectivities of the annotators. For instance, if three annotators agree that "cats are better than dogs", the agreement reflects the annotators' subjective preferences, in spite of complete agreement (i.e. $IAA = 1.0$ ), rather than the inherent value of cats or dogs.
+
+The annotation challenge is further aggravated by the absence of widely agreed-upon annotation criteria (Vidgen et al., 2019a), resulting in unclear categories. For instance, the term "abusive" has been described in terms of the speakers' intent to injure (Pitsilis et al., 2018) and in terms of the assumed impact on the reader (Wulczyn et al., 2017). Further, as annotators most often cannot communicate with the authors or the targeted subjects, annotators must make assumptions with respect to the intention of the authors of a text and its impact on readers - as, e.g., in the case of the above reclaimed slurs (Sap et al., 2019).
+
+The selection of annotators is another source of social biases (Talat et al., 2021). Annotators are often recruited from crowd-working platforms, with little regard to their subject matter expertise or so
+
+cial and cultural background. However, annotators' subjectivities, expertise (Waseem, 2016), attitudes and beliefs (Sap et al., 2021), and their diversity and variability (Hovy and Prabhumoye, 2021) have been shown to influence annotation results in spite of training and exposure to annotation guidelines.
+
+# 2.2.2 On Ground Truth and Agreement
+
+The goal for annotation efforts in NLP is to assign a gold label to data (e.g., a document or an entity therein) (Zeinert et al., 2021). The search for a single label in the face of disagreement is based on the assumption that there exists a single correct label which can be approximated using agreement aggregation methods. IAA is used as a proxy for the quality, i.e., correctness, of obtained labels. In the context of hate speech, IAA is often very low (Vigna et al., 2017; Olteanu et al., 2018; Poletto et al., 2019). However, researchers often rely on a single label as ground truth, disregarding the absence of agreement, variability, and subjectivity of the obtained ground truth (Paullada et al., 2021). The result is that, paradoxically, researchers construct ground truth for inherently subjective questions on the basis of disagreement.
+
+# 2.3 Model Learning and Evaluation
+
+Once a dataset has been labeled, models can be trained and evaluated. To assess model performance and generalizability, the trained models are evaluated on held-out test sets (Chollet and Allaire, 2018; Pustejovsky and Stubbs, 2012). This paradigm of evaluation assumes that training data and data encountered when a model is deployed are independent and identically distributed (I.I.D.) (Arlot and Celisse, 2010). For hate speech, the I.I.D. assumption means that the annotation of a text is independent of earlier annotations of other texts, and that the data sampled from outside of the dataset will follow the same class distribution that is evident in the labeled dataset. Below, we detail the limitations that can arise from the assumptions made in for model evaluation and the risks from drawing conclusions from them.
+
+# 2.3.1 On Model Understanding
+
+Although contemporary machine learning models often show an impressive performance when applied to different NLP tasks, they have been criticized for failing to grasp pragmatics due to their reliance on the distributional hypothesis (Bender and Koller, 2020). This is particularly concerning
+
+for addressing hate speech as it operates at the linguistic level of pragmatics. It is therefore important to understand how machine learning models make judgments on whether texts are hateful. Deeper assessments of hate speech models suggest that they have a very superficial understanding of language (see appendix A). In fact, prior work has argued that the reported performances for hate speech detection are in part influenced by spurious correlations (e.g. Rahman et al., 2021; Wiegand et al., 2019), and overlapping data in the train and test sets (Arango et al., 2019). This work has shown that correcting of these issues results in a decrease of performance. If models are over-fitting to spurious correlations and are incapable of language understanding, the question arises whether we can rely on current classifiers for robustly detecting hate speech.
+
+# 2.3.2 On Interpreting Model Performance
+
+Recent work on quantitative benchmarks has questioned the ability of contemporary methods to measure generalization in machine learning (Raji et al., 2021; Paullada et al., 2021), and for hate speech (Röttger et al., 2021). Researchers have found that well-performing systems for hate speech detection are susceptible to minor adversarial modifications of the input text that significantly alter the meaning (Gröndahl et al., 2018). That is, solely relying on quantitative benchmark results can produce an incomplete picture of the performance of evaluated models, leading researchers to over-estimate the performances of systems that are brittle in nature.
+
+# 2.3.3 On Model Generalization
+
+One reason models may be vulnerable to adversarial attacks is that they over-fit to tokens and token interaction patterns instead of learning to generalize the concept of hate speech (Oliva et al., 2020; Sarkar and KhudaBukhsh, 2021; Oak, 2019; Fortuna et al., 2021). Although this issue has been identified by prior work, we reconsider it in light of the limitations we have discussed thus far.
+
+We identified the following three factors that make the I.I.D. assumption unlikely to hold, resulting in models that are unlikely to generalize: 1) Given the variety of concepts and definitions in hate speech, it is very hard to assure that the different samples express the same flavor of the phenomena; 2) due to the fact that hate speech only occurs very rarely in random samples (Vidgen et al., 2019b), sampling strategies tend to over-emphasize domains where hate speech is more likely to occur,
+
+making it unlikely that two independent enterprises in dataset creation will result in complementary datasets; and 3) the speed at which linguistic shift happens in online social media (Hogan and Quan-Haase, 2010) makes it unclear if time-bounded data collections from social media can be I.I.D. This also raises an open question for the development of machine learning models for hate speech detection: How can we identify when it becomes necessary to train new models to keep abreast with the changes that have occurred in language use since the training data was sampled?
+
+# 3 Discussion: On the Present and Future for Hate Speech Detection
+
+In the preceding sections, we have highlighted a number of challenges and ethical concerns that arise from the current conceptualization of hate speech detection. We argue that these limitations render current models unable to detect hate speech without significant risk to minorities. Specifically, classifiers that are unable to accurately classify content directed towards marginalized communities risk increasing the costs for said communities to participate in online spaces, due to the increased risks of being subject to hate speech whilst also remaining unprotected by hate speech detection systems (Oliva et al., 2020). Thus, contemporary systems for hate speech detection risk reproducing normative values and attitudes towards acceptable language use while further entrenching marginalization in online spaces (Thylstrup and Talat, 2020).
+
+Overcoming the identified challenges will require shifting our research practices. In this section, we propose new directions for hate speech detection. However, we do not expect that implementing any individual solution in isolation will result in ready to use classifiers. We therefore emphasize the need for research to continuously reassess the risks that arise from methodological innovations for hate speech detection.
+
+Accounting for Plurality of Hate Speech While contemporary methods for annotating hate speech imply the assumption that there is a universal definition of hate speech, and that models derived from labeled data are applicable across all contexts, we argue instead for a pluralist approach to annotation. By taking a pluralist approach, e.g. through situating models within subjective contexts, researchers are afforded the ability to view hate speech as contextual to the subjectivities of the target of hate.
+
+For instance, by narrowing down definitions of hate, clearly providing the geographical and cultural contexts, and specifying the values and goals for the model, researchers can clearly articulate within which contexts models and data are valid and which particular groups models seek to protect. Such model framing can help address the issues surrounding universality and can provide space for researchers to consider how their choices have political implications for what speech is sanctioned.
+
+Accounting for Context Supervised machine learning models for hate speech primarily operate on text, and a single label for each document during training. However, whether a text amounts to hate speech is highly context dependent (Talat et al., 2018). For instance, whether a word is used as a slur or as a reclaimed term depends on the identity of the speaker, the phrasal and social contexts in which it is uttered. The primary means of approximating conversational context in prior work has been through the use of conversation threads and user metadata (see appendix B.1). Such conversational contexts only account for a small number of contexts that are invoked during the utterance and annotation. Annotators, for example, may hold prior knowledge on the histories, social hierarchies, conflicts, or stereotypes concerning the groups addressed in a document. Hate speech detection research would therefore benefit from considering methods to explicitly incorporate such information into the modeling pipeline.
+
+Representative Sampling Procedures Given the sampling methods used to ensure an adequate distribution of hate speech for labeling, models are often trained on data distributions that significantly vary from real-world occurrences of hate speech. To address this concern, future data collection efforts should seek to minimize such distributional differences whilst taking into account wider notions of conversational contexts.3
+
+Representative Annotation Processes The common NLP practices of having a small number of annotations for each document (often just three annotations per document) that are used to compute IAA and perform label aggregation erases different opinions on the label of a document. In this way, the use of aggregation methods for label voting exerts direct control over subjective positions on the
+
+labels, and thereby the discourses that the model will come to replicate. However, the interpretation of what constitutes hate is a highly subjective question and is subject to the workers' individual subjectivities (Waseem, 2016). While subjectivities are inherent, we propose that researchers use scales (DeVellis and Thorpe, 2021) to measure different dimensions of hate speech. Scales have previously been used in the social sciences for asking subjective questions, and could provide new possibilities for hate speech research. In particular, the use of scales can allow for framing models in terms of the values that they embody. $^4$
+
+Evaluation of Hate Speech Models In the last few years, research on hate speech detection has shown increases in performance across a number of metrics. However, as we have argued, despite quantitative improvements such performance increases do not reveal a full picture of model performances. In fact, contemporary models only display a superficial understanding of hate speech (see appendix A for an analysis of Vidgen et al. (2021)). It is therefore necessary for research on hate speech to consider new evaluation paradigms and metrics. Such initiatives must center models' abilities to generalize beyond identifying frequently occurring tokens. For instance, an emphasis on evaluating models for over-fitting to particular tokens (see appendix B.4) can provide a greater understanding of model generalizability. Another promising direction is the creation of test suites that target potential areas of concern for models for detecting hate (e.g. Röttger et al., 2021). Another avenue for improved evaluation is to directly leverage training data to create hard-to-pass tests for machine learning models. While such evaluation practices are a step in the right direction, they do not address the question of context. It is therefore necessary to develop evaluation practices that seek to evaluate models in the contexts that models are developed for, with the aid of methods capable to identify if new data is still I.I.D. to the data used for training.
+
+Handling Classification Errors For many NLP tasks classification errors do not have immediate harms. For hate speech detection, classification
+
+errors can result in significant immediate harms to people. False negatives can result in hateful speech being passed as acceptable which can allow harmful content to remain unsanctioned (Oliva et al., 2020). While false positives can result in offensive speech being sanctioned. Given content moderation's commitment to dominant social norms (Thylstrup and Talat, 2020), classification errors often disproportionately affect marginalized communities, i.e. white supremacist content remains unsanctioned while content from marginalized communities is removed (Davidson et al., 2019; Oliva et al., 2020). In light of these concerns, it is prudent for the NLP community and legislators to reflect on the ramifications of classification errors. For instance, we encourage both communities to reflect on whether it is appropriate to deploy models that will produce racialized and gendered classification errors, which entity is to be held to account for such errors, and how victims of automated classification errors should be compensated.[5]
+
+# 4 Conclusion
+
+In this paper, we have argued that current NLP practices for hate speech detection are unlikely to address the core concerns of hate speech detection, i.e. identify hate with minimal errors and protect marginalized communities. We therefore call for the NLP community to rethink its methodologies such that future developments reduce risk for marginalized communities.
+
+One avenue for future work is to follow the principles of design justice (Costanza-Chock, 2018), which emphasizes community inclusion and ownership of (technological) solutions. Following the principles of design justice, researchers would decenter their own expertise in favor of the lived expertise of affected communities. We strongly believe that future steps must center a multidisciplinary approach in close communication with affected groups. By taking steps to document and address the limitations of contemporary methods for hate speech, researchers can identify new avenues for improving hate speech detection models. Moreover, researchers can take steps towards ensuring that content moderation technologies provide safer online spaces for marginalized communities by mitigating the prevalence of online hate speech.
+
+# Limitations
+
+This study is intended as a theoretical consideration of the issues that arise in hate speech detection. The study analyzes the current limits of using machine learning infrastructures for the identification and moderation of hate speech. One limitation of the work is the theoretical frame of our work. While our frame allows for more deeply understanding the issues of contemporary methods for hate speech detection, deeper considerations of sociological and anthropological methods can afford significant improvements in our understanding of NLP technologies, such as hate speech detection, as socio-technical systems and their social impacts. A further limitation of our work is its focus on research rather than application, and therefore does not discuss how classification models are used in real-world content moderation applications. This is left to future work.
+
+# Acknowledgements
+
+We thank the reviewers for their insightful comments. The first author is supported by the research grant SFRH/BD/143623/2019, provided by the Portuguese national funding agency for science, research and technology, Fundação para a Ciência e a Tecnologia (FCT), within the scope of Operational Program Human Capital (POCH), supported by the European Social Fund and by national funds from MCTES.
+
+# References
+
+Sohail Akhtar, Valerio Basile, and Viviana Patti. 2021. Whose opinions matter? perspective-aware models to identify opinions of hate speech victims in abusive language detection. CoRR, abs/2106.15896.
+Aymé Arango, Jorge Pérez, and Barbara Poblete. 2019. Hate speech detection is not as easy as you may think: A closer look at model validation. In Proceedings of the 42nd International ACM SIGIR Conference on Research and Development in Information Retrieval, SIGIR 2019, Paris, France, July 21-25, 2019, pages 45-54. ACM.
+Sylvain Arlot and Alain Celisse. 2010. A survey of cross-validation procedures for model selection. Statistics Surveys, 4(none):40 - 79.
+Giuseppe Attanasio, Debora Nozza, Dirk Hovy, and Elena Baralis. 2022. Entropy-based attention regularization frees unintended bias mitigation from lists. CoRR, abs/2203.09192.
+
+Valerio Basile, Cristina Bosco, Elisabetta Fersini, Debora Nozza, Viviana Patti, Francisco Manuel Rangel Pardo, Paolo Rosso, and Manuela Sanguinetti. 2019. SemEval-2019 task 5: Multilingual detection of hate speech against immigrants and women in Twitter. In Proceedings of the 13th International Workshop on Semantic Evaluation, pages 54-63, Minneapolis, Minnesota, USA. Association for Computational Linguistics.
+Emily M. Bender and Alexander Koller. 2020. Climbing towards NLU: On Meaning, Form, and Understanding in the Age of Data. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5185-5198, Online. Association for Computational Linguistics.
+Su Lin Blodgett, Solon Barocas, Hal Daumé III, and Hanna Wallach. 2020. Language (Technology) is Power: A Critical Survey of "Bias" in NLP. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5454-5476, Online. Association for Computational Linguistics.
+François Chollet and J.J. Allaire. 2018. Deep learning with R. Manning Publications, New York.
+Sasha Costanza-Chock. 2018. Design Justice, A.I., and Escape from the Matrix of Domination. Journal of Design and Science.
+Aida Mostafazadeh Davani, Mark Diaz, and Vinodkumar Prabhakaran. 2021. Dealing with Disagreements: Looking Beyond the Majority Vote in Subjective Annotations. arXiv:2110.05719 [cs]. ArXiv: 2110.05719.
+Thomas Davidson, Debasmita Bhattacharya, and Ingmar Weber. 2019. Racial bias in hate speech and abusive language detection datasets. In Proceedings of the Third Workshop on Abusive Language Online, pages 25-35, Florence, Italy. Association for Computational Linguistics.
+Thomas Davidson, Dana Warmsley, Michael W. Macy, and Ingmar Weber. 2017. Automated hate speech detection and the problem of offensive language. In Proceedings of the Eleventh International Conference on Web and Social Media, ICWSM 2017, Montreal, Quebec, Canada, May 15-18, 2017, pages 512-515. AAAI Press.
+Robert F DeVellis and Carolyn T Thorpe. 2021. *Scale development: Theory and applications*. Sage publications.
+Lucas Dixon, John Li, Jeffrey Sorensen, Nithum Thain, and Lucy Vasserman. 2018. Measuring and Mitigating Unintended Bias in Text Classification. In Proceedings of the 2018 AAAI/ACM Conference on AI, Ethics, and Society, pages 67-73, New Orleans LA USA. ACM.
+
+Paula Fortuna, Juan Soler Company, and Leo Wanner. 2020. Toxic, hateful, offensive or abusive? what are we really classifying? an empirical analysis of hate speech datasets. In Proceedings of The 12th Language Resources and Evaluation Conference, LREC 2020, Marseille, France, May 11-16, 2020, pages 6786-6794. European Language Resources Association.
+Paula Fortuna, Juan Soler Company, and Leo Wanner. 2021. How well do hate speech, toxicity, abusive and offensive language classification models generalize across datasets? Inf. Process. Manag., 58(3):102524.
+Antigoni-Maria Founta, Constantinos Djouvas, Despoina Chatzakou, Ilias Leontiadis, Jeremy Blackburn, Gianluca Stringhini, Athena Vakali, Michael Sirivianos, and Nicolas Kourtellis. 2018. Large scale crowdsourcing and characterization of twitter abusive behavior. In Proceedings of the Twelfth International Conference on Web and Social Media, ICWSM 2018, Stanford, California, USA, June 25-28, 2018, pages 491-500. AAAI Press.
+Lei Gao and Ruihong Huang. 2017. Detecting online hate speech using context aware models. In Proceedings of the International Conference on Advances in Natural Language Processing, RANLP 2017, Varna, Bulgaria, September 2 - 8, 2017, pages 260-266. INCOMA Ltd.
+Katharine Gelber. 2021. Differentiating hate speech: a systemic discrimination approach. Critical Review of International Social and Political Philosophy, 24(4):393-414.
+Tommi Gröndahl, Luca Pajola, Mika Juuti, Mauro Conti, and N. Asokan. 2018. All you need is "love": Evading hate speech detection. In Proceedings of the 11th ACM Workshop on Artificial Intelligence and Security, AISec '18, page 2-12, New York, NY, USA. Association for Computing Machinery.
+Bernie Hogan and Anabel Quan-Haase. 2010. Persistence and change in social media. Bulletin of Science, Technology & Society, 30(5):309-315.
+Eduard H. Hovy and Shrimai Prabhumoye. 2021. Five sources of bias in natural language processing. Lang. Linguistics Compass, 15(8).
+Jigsaw. 2019. Perspective api. Available in https://github.com/conversationali/perspectiveapi, accessed last time in November 2019.
+Brendan Kennedy, Xisen Jin, Aida Mostafazadeh Davani, Morteza Dehghani, and Xiang Ren. 2020. Contextualizing hate speech classifiers with post-hoc explanation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5435-5442, Online. Association for Computational Linguistics.
+
+Deepak Kumar, Patrick Gage Kelley, Sunny Consolvo, Joshua Mason, Elie Bursztein, Zakir Durmeric, Kurt Thomas, and Michael Bailey. 2021. Designing toxic content classification for a diversity of perspectives. In Seventeenth Symposium on Usable Privacy and Security, SOUPS 2021, August 8-10, 2021, pages 299-318. USENIX Association.
+Elisa Leonardelli, Stefano Menini, Alessio Palmero Aprosio, Marco Guerini, and Sara Tonelli. 2021. Agreeing to disagree: Annotating offensive language datasets with annotators' disagreement. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, EMNLP 2021, Virtual Event / Punta Cana, Dominican Republic, 7-11 November, 2021, pages 10528-10539. Association for Computational Linguistics.
+Frederick Liu and Besim Avci. 2019. Incorporating Priors with Feature Attribution on Text Classification. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6274-6283, Florence, Italy. Association for Computational Linguistics.
+Edoardo Mosca, Maximilian Wich, and Georg Groh. 2021. Understanding and interpreting the impact of user context in hate speech detection. In Proceedings of the Ninth International Workshop on Natural Language Processing for Social Media, pages 91-102, Online. Association for Computational Linguistics.
+Debora Nozza. 2021. Exposing the limits of zero-shot cross-lingual hate speech detection. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 907–914, Online. Association for Computational Linguistics.
+Rajvardhan Oak. 2019. Poster: Adversarial examples for hate speech classifiers. In Proceedings of the 2019 ACM SIGSAC Conference on Computer and Communications Security, CCS 2019, London, UK, November 11-15, 2019, pages 2621-2623. ACM.
+Thiago Dias Oliva, Dennys Marcelo Antonialli, and Alessandra Gomes. 2020. Fighting hate speech, silencing drag queens? artificial intelligence in content moderation and risks to lgbtq voices online. Sexuality & Culture, pages 1-33.
+Alexandra Olteanu, Carlos Castillo, Jeremy Boy, and Kush R. Varshney. 2018. The effect of extremist violence on hateful speech online. In Proceedings of the Twelfth International Conference on Web and Social Media, ICWSM 2018, Stanford, California, USA, June 25-28, 2018, pages 221-230. AAAI Press.
+Nedjma Ousidhoum, Yangqiu Song, and Dit-Yan Yeung. 2020. Comparative evaluation of label-agnostic selection bias in multilingual hate speech datasets. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2532–2542, Online. Association for Computational Linguistics.
+
+Amandalynne Paullada, Inioluwa Deborah Raji, Emily M. Bender, Emily Denton, and Alex Hanna. 2021. Data and its (dis)contents: A survey of dataset development and use in machine learning research. Patterns, 2(11):100336.
+Georgios K. Pitsilis, Heri Ramampiaro, and Helge Langseth. 2018. Detecting offensive language in tweets using deep learning. CoRR, abs/1801.04433.
+Fabio Poletto, Valerio Basile, Cristina Bosco, Viviana Patti, and Marco Stranisci. 2019. Annotating hate speech: Three schemes at comparison. In Proceedings of the Sixth Italian Conference on Computational Linguistics, Bari, Italy, November 13-15, 2019, volume 2481 of CEUR Workshop Proceedings. CEUR-WS.org.
+Fabio Poletto, Valerio Basile, Manuela Sanguinetti, Cristina Bosco, and Viviana Patti. 2021. Resources and benchmark corpora for hate speech detection: a systematic review. Lang. Resour. Evaluation, 55(2):477-523.
+James Pustejovsky and Amber Stubbs. 2012. Natural Language Annotation for Machine Learning: A guide to corpus-building for applications. "O'Reilly Media, Inc."
+Md. Mustafizur Rahman, Dinesh Balakrishnan, Dhiraj Murthy, Mucahid Kutlu, and Matthew Lease. 2021. An information retrieval approach to building datasets for hate speech detection. CoRR, abs/2106.09775.
+Inioluwa Deborah Raji, Emily M. Bender, Amandalynne Paullada, Emily Denton, and Alex Hanna. 2021. AI and the Everything in the Whole Wide World Benchmark. arXiv:2111.15366 [cs]. ArXiv:2111.15366.
+Paul Röttger, Bertie Vidgen, Dong Nguyen, Zeerak Waseem, Helen Margetts, and Janet Pierrehumbert. 2021. HateCheck: Functional tests for hate speech detection models. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 41-58, Online. Association for Computational Linguistics.
+Maarten Sap, Dallas Card, Saadia Gabriel, Yejin Choi, and Noah A. Smith. 2019. The risk of racial bias in hate speech detection. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 1668-1678, Florence, Italy. Association for Computational Linguistics.
+Maarten Sap, Swabha Swayamdipta, Laura Vianna, Xuhui Zhou, Yejin Choi, and Noah A. Smith. 2021. Annotators with attitudes: How annotator beliefs and identities bias toxic language detection. CoRR, abs/2111.07997.
+
+Rupak Sarkar and Ashiqur R. KhudaBukhsh. 2021. Are chess discussions racist? an adversarial hate speech data set (student abstract). In Thirty-Fifth AAAI Conference on Artificial Intelligence, AAAI 2021, Thirty-Third Conference on Innovative Applications of Artificial Intelligence, IAAI 2021, The Eleventh Symposium on Educational Advances in Artificial Intelligence, EAAI 2021, Virtual Event, February 2-9, 2021, pages 15881-15882. AAAI Press.
+Wiktor Soral, Michal Bilewicz, and Mikołaj Winiewski. 2018. Exposure to hate speech increases prejudice through desensitization. Aggressive behavior, 44(2):136-146.
+Zeerak Talat, Smarika Lulz, Joachim Bingel, and Isabelle Augenstein. 2021. Disembodied Machine Learning: On the Illusion of Objectivity in NLP. ArXiv: 2101.11974.
+Zeerak Talat, Aurélie Néveol, Stella Biderman, Miruna Clinciu, Manan Dey, Shayne Longpre, Sasha Luccioni, Maraim Masoud, Margaret Mitchell, Dragomir Radev, Shanya Sharma, Arjun Subramonian, Jaesung Tae, Samson Tan, Deepak Tunuguntla, and Oskar Van Der Wal. 2022. You reap what you sow: On the challenges of bias evaluation under multilingual settings. In Proceedings of BigScience episode #5 - workshop on challenges & perspectives in creating large language models, pages 26-41, virtual+Dublin. Association for Computational Linguistics.
+Zeerak Talat, James Thorne, and Joachim Bingel. 2018. Bridging the gaps: Multi task learning for domain transfer of hate speech detection. In Online Harassment, pages 29-55. Springer.
+Nanna Thylstrup and Zeerak Talat. 2020. Detecting 'Dirt' and 'Toxicity': Rethinking Content Moderation as Pollution Behaviour. SSRN Electronic Journal.
+Alexandra N Uma, Tommaso Fornaciari, Dirk Hovy, Silviu Paun, Barbara Plank, and Massimo Poesio. 2021. Learning from disagreement: A survey. Journal of Artificial Intelligence Research, 72:1385-1470.
+Bertie Vidgen and Leon Derczynski. 2021. Directions in abusive language training data, a systematic review: Garbage in, garbage out. PLOS ONE, 15(12):1-32.
+Bertie Vidgen, Alex Harris, Dong Nguyen, Rebekah Tromble, Scott Hale, and Helen Margetts. 2019a. Challenges and frontiers in abusive content detection. In Proceedings of the Third Workshop on Abusive Language Online, pages 80-93, Florence, Italy. Association for Computational Linguistics.
+Bertie Vidgen, Helen Margetts, and Alex Harris. 2019b. How much online abuse is there? A systematic review of evidence for the UK. The Alan Turing Institute, London. Backup Publisher: The Alan Turing Institute.
+
+Bertie Vidgen, Tristan Thrush, Zeerak Waseem, and Douwe Kiela. 2021. Learning from the worst: Dynamically generated datasets to improve online hate detection. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 1667-1682, Online. Association for Computational Linguistics.
+
+Fabio Del Vigna, Andrea Cimino, Felice Dell'Orletta, Marinella Petrocchi, and Maurizio Tesconi. 2017. Hate me, hate me not: Hate speech detection on facebook. In Proceedings of the First Italian Conference on Cybersecurity (ITASEC17), Venice, Italy, January 17-20, 2017, volume 1816 of CEUR Workshop Proceedings, pages 86-95. CEUR-WS.org.
+
+Zeerak Waseem. 2016. Are you a racist or am I seeing things? annotator influence on hate speech detection on Twitter. In Proceedings of the First Workshop on NLP and Computational Social Science, pages 138-142, Austin, Texas. Association for Computational Linguistics.
+
+Michael Wiegand, Josef Ruppenhofer, and Thomas Kleinbauer. 2019. Detection of Abusive Language: the Problem of Biased Datasets. In Proceedings of the 2019 Conference of the North, pages 602-608, Minneapolis, Minnesota. Association for Computational Linguistics.
+
+Ellery Wulczyn, Nithum Thain, and Lucas Dixon. 2017. Ex machina: Personal attacks seen at scale. In Proceedings of the 26th International Conference on World Wide Web, WWW 2017, Perth, Australia, April 3-7, 2017, pages 1391-1399. ACM.
+
+Wenjie Yin and Arkaitz Zubiaga. 2021. Towards generalisable hate speech detection: a review on obstacles and solutions. PeerJ Comput. Sci., 7:e598.
+
+Philine Zeinert, Nanna Inie, and Leon Derczynski. 2021. Annotating online misogyny. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 3181-3197, Online. Association for Computational Linguistics.
+
+Brian Hu Zhang, Blake Lemoine, and Margaret Mitchell. 2018. Mitigating unwanted biases with adversarial learning. In Proceedings of the 2018 AAAI/ACM Conference on AI, Ethics, and Society, AIES '18, page 335-340, New York, NY, USA. Association for Computing Machinery.
+
+# A Hate Speech Dynabench Model Classification Results
+
+In this section, we provide examples of sentences classified by a state of the art model for hate speech detection (i.e. the Dynabench classifier proposed by Vidgen et al. (2021)) to illustrate challenges for
+
+state of the art models. This analysis is neither quantitative nor exhaustive, however it seeks to illustrate core issues for technical systems for the classification of hate speech. Quantitative analysis of mis-classifications have a set of concerns (see Section 2.3.2 for more detail). We submitted adversarial cases to the model interface6, and find that model fails to predict correctly for simple adversarial examples (see table 1).
+
+We craft our adversarial examples on the basis of western notions of sexism, starting with a simple example that we expect the model to correctly classify: "Women's place is in the kitchen". We then introduce minor variations to this sentence in order to gauge the model's understanding of sexism (see table 1 for a full list of our examples). For instance, we replace the word "women" with "men", "oven", and "gender". For these three cases, all examples except for "oven" are predicted as hate speech. While the model correctly identifies that an oven does in fact belong in a kitchen, it's gender-invariance for predicting hate speech reveals that the model has not learned the relationship between sexism and gender roles. That is, the model has not learned the social factors which are crucial to delineating hate speech from inoffensive speech.
+
+When we keep the word "women" static and change the remaining sentence to something inoffensive, we see that the model performs better which indicates a correct distinction between minority terms and hate speech. We continue with new examples and introduce replacements to the word "kitchen". When replaced by "school", the model incorrectly predicts that it is hateful. This further evidences the model's inability to distinguish prescriptions of actions from hate. More concerning is the model's inability to correctly relate the implication of femicide, when evaluated on the text "Women's place is in the cemetery." While this further provides further evidence that the model does not learn a latent understanding of power dynamics, it also illustrates that the model may not provide adequate protections against violent speech towards women.
+
+In our second set of examples (examples 2.1-2.3), we examine how the model responds more broadly to conversations around power dynamics. We see here that the explicit mentioning of gender and race prompts incorrect predictions from
+
+the model, i.e., that the mere mention of comparative privilege is labeled as hateful. Should this model be deployed, it would actively limit conversations around race, gender, and power dynamics more broadly. Such conversations are frequently had by communities that are marginalized, in efforts to identify, discuss, and seek to remedy their own marginalization. That is, the model would censor conversations that are necessary to have, in order for society to progress beyond contemporary forms of marginalization, thereby actively limiting movements for social progress.
+
+In our final three examples, we see that the model makes incorrect predictions for all three cases. In the latter two cases, we see further evidence that the model does not link notions of sexism and fascism with their expressed goals of marginalization.
+
+# B Improvements for Hate Speech Detection
+
+We acknowledge that the NLP community is working towards identifying shortcomings of the current research practices, e.g., by studying how to learn from disagreements (Davani et al., 2021) or different perspectives during annotation (Leonardelli et al., 2021; Akhtar et al., 2021; Kumar et al., 2021). Here, we provide a brief summary of these efforts, which can also serve as a source of ideas for future approaches to the problem.
+
+# B.1 Improving Hate Speech Modeling
+
+To counteract the lack of contextual information, the latest developments have added information to single text samples, including the conversation threads (Gao and Huang, 2017), network data and user information (e.g. Mosca et al., 2021). Adding conversational context, is a positive step forward as it adds contextual information which can help to frame the message being predicted. However the inclusion of more context may not be sufficient for addressing the participation of models in processes of marginalization. As have argued in this paper, we believe that considering methods from design, which aim to center and give definitional power to affected populations in the design and development processes, can be a productive path forward.
+
+# B.2 Handling Search with Keywords
+
+Some prior work has sought to evaluate the quality of keyword-based data collection. For instance, (Ousidhoum et al., 2020) rely on topic modeling to
+
+evaluate text in datasets to assess the quality of keywords. By applying LDA, the authors extract topics from the dataset and compare them to the keywords used to populate the dataset. The average stability of the keywords and topics is then measured by comparing the average similarity between the keywords and topics predicted by the topic model. Moreover, Ousidhoum et al. (2020) seek to identify the best matchin terms between the keywords and the words produced for each topic. By performing and developing such analyses, researchers may be able to evaluate the degree to which the collected data reflects the data that they intended to collect, thereby improving the quality of datasets.
+
+# B.3 Improving Conventions for the Annotation and Quality of a Dataset
+
+Recent work has sought alternatives to IAA and gold standards for general applications of machine learning (Uma et al., 2021). For hate speech, a number of studies have found novel methods to address these issues (Leonardelli et al., 2021; Akhtar et al., 2021; Kumar et al., 2021). One potential solution to such issues, is the notion of perspective-aware models and datasets (Akhtar et al., 2021). In this framing, different subjectivities of people lead to different models that embody such subjectivities. To this effect, Akhtar et al. (2021) train different classifiers on the basis of how data was annotated by different groups, including groups that have traditionally been marginalized and excluded. By doing so, Akhtar et al. (2021) provide further legitimacy to their model, as these do not seek to represent a universal position on hate speech, but rather seek to situate models within the lived realities of people. While we believe that this approach constitutes an improvement on predominant practices in NLP, this approach also has several risks. First, the approach requires considering and discussing which perspectives are warranted for the purposes of developing resources and models for hate speech detection. For instance, while it could be interesting to understand how white supremacists would view notions of hate speech, training models on their annotations is unlikely to yield systems that attain the goal of protecting marginalized communities. Rather, taking their perspective is likely to engage actively in marginalization of traditionally excluded and marginalized communities. Second, this approach raises ethical concerns surrounding the exposure of hate speech to marginalized com
+
+| ID | Text | HS Dynabench | % |
| 1.1 | Women's place is in the kitchen. | hateful | 99.88 |
| 1.2 | Men's place is in the kitchen. | hateful | 98.32 |
| 1.3 | Oven's place is in the kitchen. | not-hateful | 99.68 |
| 1.4 | Gender's place is in the kitchen. | hateful | 98.32 |
| 1.5 | Women are human beings. | not-hateful | 99.97 |
| 1.6 | Women's place is in school. | hateful | 99.60 |
| 1.7 | Women's place is in the cemetery. | not-hateful | 99.96 |
| 1.8 | Women went to the kitchen. | hateful | 99.86 |
| 1.9 | If a woman wants she can stay in her kitchen. | hateful | 98.06 |
| 1.10 | Women's places are anywhere they wish to be. | hateful | 99.67 |
| 1.11 | Women like to do many things, close or far from the kitchen. | hateful | 97.78 |
| 1.12 | Women kitchen. | hateful | 92.95 |
| 1.13 | Kitchen women. | not-hateful | 76.75 |
| 2.1 | White girls have more privilege than black girls. | hateful | 99.69 |
| 2.2 | White men are more privileged than white women. | hateful | 95.86 |
| 2.3 | White men have more privilege than white men. | hateful | 98.66 |
| 2.4 | Aliens should be hated. | hateful | 99.97 |
| 2.5 | I am scared of English white men. | hateful | 98.05 |
| 2.6 | I am a proud sexist. | not-hateful | 99.90 |
| 2.7 | I am a proud nazi. | not-hateful | 99.72 |
+
+Table 1: Hate speech automatic classification by Dynabench (the 'ID' column corresponds to a text identifier, the 'Text' column to the sentence inserted in the model, the 'HS Dynabench' to the classification 'hateful' vs. 'not-hateful', and the $\%$ column captures the probability of the example to belong to the resulting class in percentage)
+
+munities, who are already at a greater risk of being targets of hate speech.
+
+# B.4 Evaluating Model Over-fitting
+
+Prior work has addressed the question of models over-fitting to tokens and spurious correlations in data (e.g. Liu and Avci, 2019; Kennedy et al., 2020). One such effort is produced by Kennedy et al. (2020), who aim to address the issue of model overfitting to identity terms. They address the problem by using an algorithm that allows for analyses of lists of identity terms with other tokens that occur in the document. Through their analyses, Kennedy et al. (2020) identify the token and identity term patterns that correlate with the hateful class. Other research has attempted to address the challenge of word-lists. For instance, Zhang et al. (2018) use adversarial training, while Attanasio et al. (2022) use an entropy-based attention regularization that works without any additional information.
\ No newline at end of file
diff --git a/directionsfornlppracticesappliedtoonlinehatespeechdetection/images.zip b/directionsfornlppracticesappliedtoonlinehatespeechdetection/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..8423cadba5b7aec6dec1ce14ec89a9eb57c98e74
--- /dev/null
+++ b/directionsfornlppracticesappliedtoonlinehatespeechdetection/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:43a22739ef74d576d414ca48b8c689d612887c6f699ef24dd576b7088c653da8
+size 150552
diff --git a/directionsfornlppracticesappliedtoonlinehatespeechdetection/layout.json b/directionsfornlppracticesappliedtoonlinehatespeechdetection/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..a3f155cdc4bd93b4e461199acd217cf7cf0cff44
--- /dev/null
+++ b/directionsfornlppracticesappliedtoonlinehatespeechdetection/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fce14037a54ebe1553bdd1305d020f4cc56ac3f0029e8d755e19d5ab3eb698c8
+size 255889
diff --git a/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_content_list.json b/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..5c7478ee6915343d3540245a49a7a27863057cd2
--- /dev/null
+++ b/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2a5716f3cb9fc8fdc1c5dcae490313d47ca2a7160667d815b7c653b1e892ae6e
+size 112469
diff --git a/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_model.json b/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..b2ec010414f4ca21c70e4678b5a5992f6a78cd8d
--- /dev/null
+++ b/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3f407668a61ffd279e2ce69af8533b7e7c806c57488e1de7abd4ce07b84cefe5
+size 144276
diff --git a/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_origin.pdf b/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..434f324290b54a8cfbe31fdd725b37c5b5b2ef38
--- /dev/null
+++ b/discosensecommonsensereasoningwithdiscourseconnectives/a69e9cc6-2e87-47e1-8e36-ace8b55895a3_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f7b6033c727552136b479ad0f9fdd255be27f4f5dd9d177e2b2839f17fe01c12
+size 363886
diff --git a/discosensecommonsensereasoningwithdiscourseconnectives/full.md b/discosensecommonsensereasoningwithdiscourseconnectives/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..d99a0373bb3f31c11390bf28c5d0488919db49ed
--- /dev/null
+++ b/discosensecommonsensereasoningwithdiscourseconnectives/full.md
@@ -0,0 +1,449 @@
+# DISCOSENSE: Commonsense Reasoning with Discourse Connectives
+
+Prajjwal Bhargava and Vincent Ng
+
+Human Language Technology Research Institute
+
+University of Texas at Dallas
+
+Richardson, TX 75083-0688
+
+prajjwalin@protonmail.com, vince@HLT.utdallas.edu
+
+# Abstract
+
+We present DISCOSENSE, a benchmark for commonsense reasoning via understanding a wide variety of discourse connectives. We generate compelling distractors in DISCOSENSE using Conditional Adversarial Filtering, an extension of Adversarial Filtering that employs conditional generation. We show that state-of-the-art pre-trained language models struggle to perform well on DISCOSENSE, which makes this dataset ideal for evaluating next-generation commonsense reasoning systems.
+
+# 1 Introduction
+
+Much of the recent work in commonsense reasoning has focused on evaluating a pre-trained language model's (LM) ability to predict the most plausible ending/option given a context. Even after devising bias reduction techniques (Zellers et al., 2019b; Bras et al., 2020) to mitigate the effects of annotation artifacts and make the task difficult, state-of-the-art LMs have managed to achieve or even surpass human performance on numerous commonsense downstream tasks (Zellers et al., 2019b; Sakaguchi et al., 2020; Bhagavatula et al., 2020). Nevertheless, these LMs are still very far from being able to perform commonsense reasoning as well as humans. Hence, the fact that they have begun to ace existing benchmarks implies that time is ripe to design a new challenging benchmark that can reliably target their limitations.
+
+Motivated by this observation, we present DISCOSENSE, a benchmark for performing commonsense reasoning through understanding a wide variety of discourse connectives. Figure 1 shows an example taken from DISCOSENSE. As can be seen, an example is composed of a context (e.g., "Our waitress was very nice, but she kept on forgetting my stuff.") and a discourse connective (e.g., "For example"), and the goal is to choose the most plausible ending out of four options. If we ignore the discourse connective, then all four options may
+
+Our waitress was very nice, but she kept on forgetting my stuff. For example
+
+a) When I ordered the garlic shrimp, she remembered to add my requested garlic butter.
+b) She took forever to bring me my beer and fries.
+c) When I told her I wanted to use the free breakfast that was available she was not pleased.
+d) For some customers, this is fine.
+
+Figure 1: Example on commonsense reasoning with discourse connectives. The correct (i.e., most plausible) option is boldfaced.
+
+seem plausible because we do not know what the writer's intent is. Once we consider both the context and the discourse connective, then it is clear that only option b) is plausible. The reason is that "For example" signals an EXEMPLIFICATION relation between its arguments, and what follows the discourse connective is expected to be an example of the waitress keeping on forgetting the writer's stuff. Using commonsense knowledge, we know that (1) "my beer and fries" is an example of "my stuff", and (2) her taking forever to bring the writer stuff implies she kept on forgetting his/her stuff.
+
+What if we replace "For example" with "However" in the example? Since "However" signals a CONTRAST relation, options a) and d) both seem viable. Specifically, option a) describes a situation in which she did not forget the writer's stuff. While option d), unlike option a), does not describe any example that signals a contrast, one may infer a contrast between option d) and the context: being forgetful is fine for some customers. Nevertheless, option a) is arguably more plausible than option d) and should be chosen. The reason is that for d) to be sensible, one needs to assume that her forgetting the writer's stuff implies that she is in general forgetful. Without this assumption, it may be strange for other customers to have an opinion on her forgetting the writer's stuff. In general, the most plausible option is the option that makes the smallest number of assumptions, and/or is the most
+
+coherent given the context and the discourse connective. Considering the commonsense knowledge and the reasoning involved, it should not be difficult to see that this task is challenging.
+
+Our contributions are four-fold. First, we create DISCOSENSE, a new dataset aimed at testing LMs' commonsense reasoning capabilities through discourse connectives. Second, we employ a controlled text generation based adversarial filtering approach to generate compelling negatives. Third, we establish baseline results on DISCOSENSE with numerous state-of-the-art discriminator models and show that they struggle to perform well on DISCOSENSE, which makes our dataset an ideal benchmark for next-generation commonsense reasoning systems. Finally, we show the efficacy of using DISCOSENSE as a transfer learning resource through sequential fine-tuning of LMs on DISCOSENSE followed by HELLASWAG and achieve near state-of-the-art results on the HELLASWAG test set. To stimulate work on this task, we make our code and data publicly available.
+
+# 2 Related Work
+
+In this section, we discuss related work, focusing our discussion on the differences between DIS-COSENSE and existing commonsense reasoning benchmarks. In addition, we present an overview of Adversarial Filtering, which will facilitate the introduction of the Conditional Adversarial Filtering mechanism we propose in Section 3.
+
+Commonsense reasoning benchmarks. SWAG (Zellers et al., 2018) and HELLASWAG (Zellers et al., 2019b) are arguably the most prominent commonsense reasoning benchmarks. In SWAG, given a partial description along with four candidate endings, the task is to predict the most plausible ending. The synthetic options (a.k.a. distractors) are generated through a process called Adversarial Filtering (AF) (see below). HELLASWAG is an extension of SWAG that seeks to eliminate artifacts in the generated endings. Unlike SWAG and HELLASWAG, DISCOSENSE requires that the discourse connective be taken into account in the reasoning process, thus increasing the number of inference steps and potentially the task complexity. In addition, while the examples in SWAG and HELLASWAG come primarily from ActivityNet (a benchmark focused on dense captioning of temporal events),
+
+DISCOSENSE features a more diverse set of examples coming from varied domains that may only be solved with rich background knowledge.
+
+There are benchmarks that aim to test different kinds of commonsense reasoning abilities, although none of them focuses on reasoning over discourse connectives. SocialIQA (Sap et al., 2019), for instance, focuses on social and emotional commonsense reasoning. ABDUCTIVE NLI (Bhagavatula et al., 2020) focuses on abductive reasoning. WINOGRANDE (Sakaguchi et al., 2020) contains Winograd schema-inspired problems, which are essentially hard pronoun resolution problems requiring world knowledge. PIQA (Bisk et al., 2020) examines physical commonsense reasoning. MCTACO (Zhou et al., 2019) and TIMEDIAL (Qin et al., 2021) focus on temporal reasoning in comprehension and dialogue formats.
+
+More closely related to DISCOSENSE are commonsense reasoning benchmarks that involve reasoning with a particular kind of relations. COPA (Choice of Plausible Alternatives) (Roemmele et al., 2011) focuses exclusively on reasoning with CAUSAL relations and involves choosing the more plausible ending out of two (rather than four) options. P-MCQA (Qasemi et al., 2021) focuses exclusively on reasoning with PRECONDITION relations: given a commonsense fact, select the precondition that makes the fact possible (enabling) or impossible (disabling) out of four options. $\delta$ -NLI (Rudinger et al., 2020), which aims to evaluate defensible inference, focuses exclusively on reasoning with the STRENGTHEN/WEAKEN relations: given a premise-claim pair where the premise supports the claim, generate a sentence that either strengthens or weakens the support. WINOVENTI (Do and Pavlick, 2021), which is composed of Winograd-style schemas, focuses exclusively on reasoning with ENTAILMENT relations: given two sentences with an entailment relation, such as "Pete says the pear is delicious. The pear is ..., the goal is to fill in the blank with one of two choices (e.g., "edible", "inedible"). There are two key differences between these datasets and DISCOSENSE. First, rather than focusing on a particular type of relation, DISCOSENSE encompasses 37 discourse connectives signaling different discourse relation types. Second, DISCOSENSE involves reasoning with discourse connectives, which is more complicated than reasoning with discourse relations. Specifically, as some connectives are sense-ambiguous
+
+| Dataset | Model | Human |
| SWAG (Zellers et al., 2018) | 91.71 | 88 |
| αNLI (Bhagavatula et al., 2020) | 91.18 | 92.9 |
| Hellaswag (Zellers et al., 2019b) | 93.85 | 95.6 |
| CosmosQA (Huang et al., 2019) | 91.79 | 94 |
| PIQA (Bisk et al., 2020) | 90.13 | 94.9 |
| SocialIQa (Sap et al., 2019) | 83.15 | 88.1 |
| MC-TACO (Zhou et al., 2019) | 80.87 | 75.8 |
| WinoGrande (Sakaguchi et al., 2020) | 86.64 | 94 |
| ProtoQA (Boratko et al., 2020) | 54.15 | 74.03 |
| VCR (Zellers et al., 2019a) | 63.15 | 85 |
+
+Table 1: Status of how competitive current commonsense reasoning benchmarks are for state-of-the-art pretrained language models.
+
+(e.g., the connective "since" may serve as a temporal or causal connective (Pitler and Nenkova, 2009)), a LM will likely need to (implicitly) perform sense disambiguation in order to perform well on DISCOSENSE.
+
+There are datasets and knowledge bases where the semantic/discourse/commonsense relations are explicitly annotated and which can provide data sources from which commonsense reasoning benchmarks can be derived. Examples include (1) the Penn Discourse TreeBank (Prasad et al., 2008), where two sentences or text segments are annotated with their discourse relation type, if any; (2) COREQUISITE (Qasemi et al., 2021), which is used to provide the commonsense facts and the human-generated preconditions in the P-MCQA dataset mentioned above; (3) SNLI (Bowman et al., 2015), where each premise-hypothesis pair is annotated as ENTAILMENT, CONTRADICTION, or NEUTRAL; (4) ATOMIC $_{20}$ (Hwang et al., 2021), which is a commonsense knowledge graph where the nodes correspond to propositions and the edges correspond to social/physical commonsense relations; and (5) SOCIAL-CHEM-101 (Forbes et al., 2020), which is a collection of statements about commonsense social judgments made given everyday situations.
+
+One of the motivations behind the creation of DISCOSENSE is that state-of-the-art LMs have managed to achieve or even surpass human performance on various commonsense reasoning benchmarks. Table 1 shows the best accuracies achieved by existing LMs on 10 widely used commonsense reasoning benchmarks and the corresponding human performance levels. As can be seen, existing LMs have managed to achieve an accuracy of more than $80\%$ on eight of these benchmarks.
+
+
+Figure 2: Components of Adversarial Filtering.
+
+Adversarial filtering (AF). Originally proposed by Zellers et al. (2018), AF aims to create examples that would be difficult for models to solve, specifically by replacing the easy options in correctly-solved examples with difficult ones. As shown in Figure 2, AF has three components: data (i.e., examples with multiple options, one of which is correct), a discriminator LM (a classifier that is used to solve each example) and a generator LM (a model that generates new options for an example). In each AF iteration, the discriminator LM is trained on the training set and used to solve each example in the test set. If a test example is incorrectly solved (i.e., the discriminator LM chooses the wrong option), the example is deemed sufficiently difficult and no change is made to it. On the other hand, if a test example is correctly solved, then AF seeks to increase its difficulty by replacing the easiest option (i.e., the generated option that the discriminator LM classifies with the highest confidence) with a new option generated by the generator LM. Training a new discriminator LM in each AF iteration ensures that the dataset is not just adversarial for one LM but a class of LMs, as training different instances of the same type of LMs results in models that have differently learned linguistic representations. This process is repeated on all correctly classified examples in the test set until the performance on the test set converges.
+
+# 3 DISCOSENSE
+
+# 3.1 Task Description
+
+DISCOSENSE aims to measure the commonsense inference abilities of computational models through the use of discourse connectives. The correct endings can be obtained after understanding the purpose of the given discourse connectives. Given a context $c = (s, d)$ , which is composed of a contextual sentence $s$ and a discourse connective $d$ as well as a set of four options $O = \{o_1, o_2, o_3, o_4\}$ , the task is to predict the most plausible ending $o_i \in O$ .
+
+| Data Source | DISCOSENSE Train | DISCOSENSE Test |
| DISCOVERY Train | Bottom 7% | - |
| DISCOVERY Validation | - | 100% |
| DISCOFUSE train | Top ~54k w/ DC | - |
+
+# 3.2 Dataset Creation
+
+To assemble DISCOSENSE, we focus on source datasets that contain two sentences connected through a discourse connective. Specifically, we use two peer reviewed academic datasets, DISCOVERY (Sileo et al., 2019) and DISCOFUSE (Geva et al., 2019). In DISCOVERY, each sentence is composed of two sentences connected via a discourse connective for the purpose of learning joint sentence representations with discourse connectives. DISCOFUSE, on the other hand, is assembled for the task of sentence fusion (i.e., joining several independent sentences into a single coherent sentence). We only consider those examples where a discourse connective is needed for sentence fusion, and include in DISCOSENSE the fused sentences in the Wikipedia $^2$ split of DISCOFUSE. Since these datasets contain sentences from Common Crawl $^3$ and Wikipedia articles, DISCOSENSE is diverse in the topics it covers. Importantly, since by construction the discourse connective is crucial in solving the underlying tasks (i.e., sentence representation learning and sentence fusion), the crucial role played by the discourse connectives in these sentences makes them suitable for our use case. Details of how the DISCOVERY and DISCOFUSE sentences are used to create DISCOSENSE are shown in Tables 2 and 3.
+
+# 3.3 Generating Options
+
+Next, we describe how we generate challenging options for DISCOSENSE using an improved version of AF that we call Conditional Adversarial Filtering (CAF). CAF follows the AF procedure in Figure 2, only differing from AF in terms of (1) the generator LM (Section 3.3.1), (2) the discriminator LM (Section 3.3.2), and (3) how the generator LMs are used to generate options (Section 3.3.3).
+
+Table 2: Data sources for DISCOSENSE and its composition before human verification. DC refers to those samples in DISCOFUSE that are concerned with the discourse connective phenomenon.
+
+| Data | Generator LM |
| DISCOVERY Train | last 93% |
| DISCOVERY Test | 100% |
+
+Table 3: Data used to train the generator LMs in Conditional Adversarial Filtering.
+
+# 3.3.1 Conditional Generator LM
+
+Pre-training does not explicitly teach how important a particular token or text span is in contributing to the semantics of a sentence. Hence, to be able to generate sentences that are coherent with not only the context but also the discourse connective, we propose to use Controllable Text Generation, which aims to provide a more granular control over how generation happens to match a particular attribute. In the context of Transformer-based LMs, there are two lines of research on controllable text generation. One examines how to steer generation by fine-tuning an extra set of parameters while keeping the base (unconditionally trained) model fixed (Dathathri et al., 2020; Qin et al., 2020; Zhang et al., 2020; Krause et al., 2020), while the other involves conditionally training a generative model on a control variable to generate text w.r.t. a prompt prefix. We adopt the latter approach, extending CTRL (Keskar et al., 2019) to explicitly steer generation w.r.t. discourse relations by using discourse connectives as control codes, as described below.
+
+Training. The input to CTRL is as follows:
+
+$$
+\underline {{\text {i n p u t}}} \colon [ d ] + [ \text {c o n t e x t} ] - \underline {{\text {l a b e l}}} \colon [ \text {e n d i n g} ]
+$$
+
+where $d$ is a discourse connective. Specifically, each input context for CTRL is prepended with a connective, and the training task for CTRL is to learn the conditional distribution $p(e|d,$ context) over possible endings $e$ . The predicted ending is then compared with the human generated ending to compute loss. Since the original CTRL model is pre-trained with control codes suitable for open-ended text generation, we fine-tune CTRL on the portion of DISCOVERY shown in Table 3 using all the 174 connectives present in the selected splits. Comparing Tables 2 and 3, we can see that the data the generator LM is fine-tuned on is not part of DISCOSENSE. Doing so ensures that the endings generated by the generator LM are different from the ground truth (i.e., the human written endings).
+
+Decoding. We use Nucleus sampling (Holtzman et al., 2020) for generating options for the training set with the value of $p$ set to 0.7, which means the
+
+weights of the tail of the probability distribution are ignored (i.e., tokens with a cumulative probability mass of less than 0.3 are left out). Additionally, we use a length penalty of 0.8 to restrict the length of the generations to match the average length of the ground truth to avoid the induction of length bias.
+
+Efficacy of conditional generation. Recall that we propose the use of conditional generation, specifically the use of discourse connectives as control codes, in our generator LM because of our hypothesis that the resulting LM would generate options that are more compliant with the purpose of the discourse connective. To test this hypothesis, we compare the text generation capability of CTRL with that of GPT2-xL, a model that is trained unconditionally and has nearly the same number of parameters (1.6B) as CTRL, under the same evaluation setting. Specifically, both LMs are fine-tuned on the same data (see Table 3) using the same machine (a 2x Quadro RTX 8000 with a batch size of 24). The only difference between them lies in the format of the training examples: in CTRL the discourse connective is used as the control code and therefore precedes the context, whereas in GPT2-xL, the discourse connective follows the context.
+
+The two LMs are then independently applied to generate exactly one option for each example in the DISCOVERY validation set. CTRL achieves a much lower perplexity than GPT2-XL (2.39 vs. 2.53), which suggests that conditional training improves the quality of the generated sentences.
+
+# 3.3.2 Discriminator LM
+
+We use ROBERTA-LARGE (Liu et al., 2019) as the discriminator LM, which takes the context, the discourse connective, and the four endings as input and predicts the most plausible ending. This LM is trained on the randomly shuffled training split of DISCOSENSE and applied to the DISCOSENSE test set to get the confidence scores associated with its predictions.
+
+# 3.3.3 Generating Options
+
+Next, we describe how we generate options for the examples in DISCOSENSE. Recall that each example contains one of 174 discourse connectives. Rather than generating options for examples that contain any of these 174 connectives, we select 37 discourse connectives and generate options only for examples that contain one of them. The connectives that are discarded are primarily those that impose few constraints on the endings to be gen
+
+| although | in other words | particularly |
| as a result | in particular | rather |
| by contrast | in short | similarly |
| because of this | in sum | specifically |
| because of that | interestingly | subsequently |
| but | instead | thereafter |
| consequently | likewise | thereby |
| conversely | nevertheless | therefore |
| for example | nonetheless | though |
| for instance | on the contrary | thus |
| hence | on the other hand | yet |
| however | otherwise | |
| in contrast | overall | |
+
+Table 4: Discourse connectives present in DISCOSENSE.
+
+erated given the context according to preliminary experiments. For instance, the connective "and" is discarded because numerous endings are equally plausible. Similarly for connectives that signal a temporal relation (e.g., "before", "after"): they also tend to allow numerous equally plausible endings, as can be seen in examples such as "John went to eat lunch after [ending]". The 37 connectives that we end up choosing are shown in Table 4. These connectives are less likely to yield options that look equally plausible to human annotators and which are indicative of different kinds of discourse relations, such as EXEMPLIFICATION (e.g., "for instance"), CONCESSION (e.g., "although"), COMPARISON (e.g., "in contrast"), and CAUSAL (e.g., "as a result"). 94k examples in DISCOSENSE contain one of the 37 connectives.
+
+To generate the options for these 94k sentences, we begin by training 20 generator LMs on a randomly shuffled order of the generators' training data (see Table 3) and then inserting them into a circular queue. Although the underlying data is the same, random shuffling ensures that the learned representations of these 20 models are different. Since each example needs to have 3 synthetic options, we use the first 3 generator LMs from the circular queue to generate the initial options for each example. After that, we begin CAF. In each CAF iteration, we (1) train the discriminator LM (see Section 3.3.2) on the DISCOSENSE training set for 4 epochs and use it to filter out the options deemed as easiest by the discriminator LM; and (2) use the next generator LM in the circular queue to generate the options for the examples whose easiest option is removed by the discriminator LM. In other words, a different discriminator LM is used in each CAF iteration, and a generator LM in the
+
+| DiscoSense |
| train | 9299 |
| # Context Answer tuples | test | 3757 |
| total | 13056 |
| Statistics | Train / Test |
| Average | context | 22.08 / 22.51 |
| answers (all) | 18.62 / 18.92 |
| # | answers (correct) | 16.94 / 18.18 |
| tokens | answers (incorrect) | 18.51 / 18.5 |
| Unique | context | 32577 / 16858 |
| answers (all) | 43992 / 27406 |
| # | answers (correct) | 26836 / 15078 |
| tokens | answers (incorrect) | 41158 / 25900 |
+
+Table 5: Data statistics for DISCOSENSE.
+
+circular queue is used once every 20 CAF iterations. CAF is run separately for the DISCOSENSE training and test sets. After running CAF for approximately 150 iterations, the average accuracy of a discriminator LM decreased from $86 - 90\%$ to $34\%$ on the DISCOSENSE test set.
+
+# 3.3.4 Other Implementation Details
+
+For the models we use in CAF, we obtain the pre-trained weights and the implementations from Hugging Face Transformers (Wolf et al., 2019). These models are trained using the AdamW optimizer (Loshchilov and Hutter, 2019) with a learning rate of $2e^{-5}$ . The training of each generator LM is performed on a 2x Quadro RTX 8000 with a batch size of 24 and typically lasts for 3 days. The training of a discriminator LM is performed on a RTX 3090 with a batch size of 16 and typically lasts for 5-6 hours.
+
+# 3.4 Human Verification
+
+Next, we perform human verification of the examples for which we have generated options. The verification proceeds in two steps. In Step 1, we ask three human verifiers to independently identify the correct option for each example, removing an example if at least one person fails to identify the correct option. We repeat this process until the number of examples that survive this verification reaches 13,056.4 In Step 2, we ask three human verifiers not involved in Step 1 to independently identify the correct option for each of the 13,056 examples verified in Step 1. We compute for each verifier the accuracy of choosing the correct option and use the average accuracy as the human perfor
+
+
+Figure 3: Distribution of examples over discourse connectives in DISCOSENSE.
+
+mance on DISCOSENSE. Appendix A contains the details on how the human verifiers are recruited and the annotation instructions we present to them.
+
+# 3.5 Dataset Statistics
+
+Statistics on DISCOSENSE are shown in Table 5, in which we report the average number of tokens in (1) the context, (2) the ground truth and (3) the generated endings. The number of unique tokens provides a rough characterization of the richness of the vocabulary. In addition, we report the distribution of the examples over the discourse connectives in DISCOSENSE in Figure 3.
+
+# 4 Evaluation
+
+# 4.1 Baseline Systems
+
+Our baselines are composed of prominent LMs with different kinds of Transformer architectures. First, we consider models that are pre-trained in a BERT-like fashion and share architectural similarities, including the base and large variants of BERT (Devlin et al., 2019) and ROBERTA (Liu et al., 2019), as well as ALBERT-XXLARGE-V2 (Lan et al., 2020). As an extension, we select LONG-FORMER BASE, which is pre-trained in the same manner as ROBERTA but has a sparse attention matrix. From the autoregressive/decoder based networks, we experiment with XLNET LARGE (Yang et al., 2019), which maximizes the learning of bidirectional contexts and GPT2-XL. For
+
+| Model | Accuracy / std |
| Random Guess | 25.0 |
| BERT-BASE (110M) | 32.86 / 0.45 |
| BERT-LARGE (336M) | 34.25 / 1.04 |
| ROBERTA-BASE (125M) | 34.11 / 0.45 |
| ROBERTA-LARGE (355M) | 34 / 0.2 |
| ALBERT-XXLARGE-V2 (223M) | 50.91 / 1.44 |
| LONGFORMER BASE (435M) | 35.29 / 0.77 |
| XLNET LARGE (340M) | 36.71 / 0.77 |
| FUNNEL-TRANSFORMER-XL (468M) | 35.22 / 1.94 |
| ELECTRA-LARGE | 65.87 / 2.26 |
| Human Performance | 95.40 / 0.20 |
+
+Table 6: Accuracies (best results obtained among 8 epochs when averaged over 5 runs with random seeds) of the LMs on the DISCOSENSE test set.
+
+models trained with a different pre-training objective, we experiment with ELECTRA-LARGE (Clark et al., 2020) and FUNNEL-TRANSFORMER-XL (Dai et al., 2020), the latter of which is pre-trained in a similar manner as ELECTRA-LARGE.
+
+We obtain the implementations of these LMs from Hugging Face Transformers. We fine-tune them on the DISCOSENSE training set using a 4-way cross-entropy loss in the same way as the discriminator LMs in CAF are trained (see Section 3.3.4) and evaluate them on the test set.
+
+# 4.2 Results and Discussion
+
+Results on the test set, which are expressed in terms of accuracy, are shown in Table 6. A few points deserve mention.
+
+First, all baselines perform better than random guess (row 1). This implies that while CAF is used to remove easy options, there may still be artifacts in the data that could be exploited by the LMs.
+
+Second, models sharing a similar pre-training objective as that of BERT, such as ROBERTA and LONGFORMER, are among the worst baselines. A similar trend is observed with XLNET. Although ALBERT has the Masked Token Prediction task in its pre-training objective, its architectural differences (i.e., larger hidden states and parameter sharing) and its Sentence Order Prediction objective seem to help it learn inter-sentence coherency properties better than its BERT counterparts.
+
+Third, pre-training appears to play a predominant role in our task. While the BERT family of models are trained with the masked-LM objective, the pre-training objective of ELECTRA (the best baseline) is designed to determine if a token in a human-written sentence has been replaced by a generator. We speculate that ELECTRA's superior
+
+
+Figure 4: Error rate of ELECTRA on each discourse connective in the DISCOSENSE test set.
+
+performance can be attributed to the fact that its pretrained knowledge of discriminating between synthetic and human generated tokens transfers well to the task of discriminating between synthetically generated sentences and human written sentences in DISCOSENSE. Nevertheless, the fact that it only achieves an accuracy of $65.87\%$ is indicative of the challenges DISCOSENSE has for existing LMs. Note that this accuracy is much lower than those achieved by LMs on many commonsense reasoning benchmarks (see Table 1). These results suggest that DISCOSENSE is a challenging benchmark for state-of-the-art LMs.
+
+Finally, we report human performance in the last row of Table 6. Details of how these numbers are obtained are discussed in Section 3.4. As can be seen, the accuracy achieved by the best baseline, ELECTRA, lags behind that of humans by nearly $30\%$ points.
+
+# 4.3 Quantitative Error Analysis
+
+We perform a quantitative error analysis of our best-performing model, ELECTRA. Specifically, we compute for each discourse connective the percentage of examples in the DISCOSENSE test set that are misclassified by ELECTRA, with the goal of gaining a better understanding of the discourse connectives that are perceived as easy as well as those that are perceived as difficult as far as commonsense reasoning is concerned.
+
+Results are shown in Figure 4. As we can see,
+
+the misclassification rates are highest for those discourse connectives that express contrast (e.g., "otherwise", "however", "but", "although"). A plausible explanation for this result is that it is often hard to anticipate what a human would have in mind if they are trying to indicate the opposite of what they mean to say. On the other hand, the model finds it easy to predict sentences where the discourse connective signals compliance and exemplification (e.g., "similarly", "likewise", "hence", "because of that", "for example").
+
+# 4.4 Qualitative Error Analysis
+
+To better understand the mistakes made by ELECTRA, we manually inspected 100 randomly selected examples that are misclassified and identified four major reasons why they are misclassified.
+
+1. Less plausible endings. This category contributes to $21\%$ of the errors where the model chooses a less plausible ending. Choosing a less plausible option could be associated with a partial understanding of the context or unwarranted assumptions. In Example 1 of Figure 5, the model makes the assumption that whatever is applicable to grass is also applicable to trees. However, the option it ends up picking is non-factual in nature because of the phrase "7000 years ago".
+2. Abstract associations. $14\%$ of the errors are made due to the formation of abstract associations between concepts. The model seems to rely on certain spans of context for classification rather than understand the semantics in its entirety. In Example 2 of Figure 5, the model seems to wrongly associate "energy dense nutrients" with "obesity" and fails to understand that the context is discussing the correlation between nutrient deficit diet and people belonging to lower income groups.
+3. Complex Context Understanding. $23\%$ of the examples are misclassified due to the fact that a deeper than usual reasoning is needed to understand the context. In Example 3 of Figure 5, we see that the context is about something weighing on a mind, indicating that the author may be faced with a pressing situation. The connective "but" indicates that while the situation being dealt with is problematic or stressful, the author would still pursue it, making option c) the most plausible. Here, the model fails to understand what it means to have something weighing on mind and what that can
+
+1) Although the grasses were only a moment old, they appeared as if they were months old. Likewise
+
+a) Similar phenomena occurred with the ancient trees around the earth 7,000 years ago.
+b) The dinosaurs were not billions of years old.
+c) Several seeds were found encased within stems that are several months old, but they seemed quite fresh and alive.
+d) The trees, although only a day old when they sprouted forth, were nevertheless like trees years old as they were fully grown.
+
+2) Low income people are less likely to consume a healthy diet than wealthier people, and energy dense nutrients poor diets are preferentially consumed by persons of lower socioeconomic status. Consequently
+
+a) Nutrients associated with these diets may be potentially contributing to obesity and diabetes.
+b) Metabolic syndrome is primarily related to obesity.
+c) Their health is at greater risk from diet related illness.
+d) A great number of persons suffering from obesity related diseases receive inadequate nutritional care.
+
+3) It weighs on a mind, all this but
+
+a) You have to live it if you want to know whats on it.
+b) All that means in practice.
+c) It does make me want to back up and ask even bigger questions.
+d) In a kind of perverse way, I don't really feel sad.
+
+Figure 5: Examples misclassified by ELECTRA (mis-classified options in pink; ground truths in green).
+
+make a person do, in this case, "ask bigger questions".
+
+4. Lack of understanding of the discourse connective. In many cases it is difficult to pinpoint the reason why an example is misclassified. Hence, if a misclassified example is not covered by any of the first three categories, we attribute the mistake to a lack of understanding of the discourse connective. This category contributes to $42\%$ of the errors.
+
+# 4.5 Role of Context and Discourse connective
+
+To better understand the role played by the context and the discourse connective in a LM's reasoning process, we conduct two ablation experiments. In the first experiment, we remove the discourse connective, so only the context and the endings are available to the LMs. In the second experiment, we strip the context and the discourse connective, exposing only the endings to the LMs.
+
+Results of these experiments are shown in the $\mathrm{C + E}$ column and the E column of Table 7 respectively. For comparison purposes, the results obtained by not removing anything are shown in the
+
+| Model | C+D+E | C+E | E |
| BERT-BASE | 32.86 / 0.5 | 33.95 / 0.8 | 32.27 / 1.3 |
| BERT-LARGE | 34.25 / 1.0 | 33.30 / 0.6 | 30.29 / 0.9 |
| ROBERTA-BASE | 34.11 / 0.5 | 32.73 / 0.4 | 32.49 / 0.7 |
| ROBERTA-LARGE | 34.99 / 0.2 | 34.94 / 0.9 | 32.70 / 0.7 |
| ALBERT-XXL | 50.91 / 1.4 | 50.87 / 1.2 | 38.04 / 0.4 |
| LONGFORMER | 35.29 / 0.8 | 36.82 / 0.8 | 33.18 / 1.0 |
| XLNET LARGE | 36.71 / 0.8 | 36.68 / 1.1 | 31.87 / 0.4 |
| FUNNEL-XL | 35.22 / 1.9 | 34.62 / 4.9 | 30.76 / 4.2 |
| ELECTRA-LARGE | 65.87 / 2.3 | 56.75 / 0.8 | 43.33 / 2.2 |
+
+$\mathrm{C + D + E}$ column. As can be seen, when the discourse connective is removed, performance drops for all baselines except for BERT-BASE and LONG-FORMER, and when both the discourse connective and the context are removed, performance drops for all baselines. In the case of the best baseline, ELECTRA, performance drops abruptly as information is withdrawn (C+E: $17.91\%$ and E: $44.27\%$ ), thus highlighting its reliance on both pieces of information for its competitive performance. Overall, these results suggest that reasoning over both the context and the connective is necessary for this task. It is worth mentioning, though, that even when both the context and the connective are removed, all the LMs still manage to achieve an accuracy of more than $30\%$ . Additional experiments are needed to determine the reason why they perform considerably better than random guess when only the endings are given. This will most likely involve an examination of whether there are systematic differences between the human-generated sentences and their automatically generated counterparts.
+
+# 4.6 DISCOSENSE for Transfer Learning
+
+Next, we look at DISCOSENSE from the perspective of a transfer learning source. Specifically, to understand whether fine-tuning a LM on DISCOSENSE can improve its performance on a related dataset, HELLASWAG, we perform sequential fine-tuning, where we fine-tune each baseline LM on the DISCOSENSE training set followed by the HELLASWAG training set (both for 4 epochs). Note that discourse connectives are removed from the input because HELLASWAG does not have them.
+
+Results on the validation split of HELLASWAG
+
+Table 7: Accuracies (best results among 8 epochs when averaged over 5 runs with random seeds) on the DISCOSENSE test set with specific pieces of information from the input removed. D, C, and E refer to the discourse connective, the context and the endings respectively. The numbers following $\prime \prime$ are the standard deviations.
+
+| Model | HS | DS→HS |
| BERT-BASE-UNCASED | 38.47 | 40.38 |
| BERT-LARGE-UNCASED | 44.36 | 42.54 |
| ROBERTA-BASE | 58.21 | 57.00 |
| ROBERTA-LARGE | 81.50 | 82.34 |
| ALBERT-XXLARGE-V2 | 80.97 | 81.47 |
| XLNET-LARGE | 76.47 | 76.56 |
| ELECTRA-LARGE | 86.90 | 91.50 |
| FUNNEL-TRANSFORMER-XL | 86.88 | 87.50 |
+
+Table 8: Results of sequential fine-tuning on the validation split of HELLASWAG.
+
+are shown in Table 8. Specifically, the HS column shows the results of the baselines on HELLASWAG and the DS $\rightarrow$ HS shows the results of the baselines after sequential fine-tuning. As we can see, sequential fine-tuning yields performance improvements with almost all LMs. Notably, the improvement is more pronounced for ELECTRA (4.3%) than for ALBERT and the BERT-based models. One plausible reason is that ELECTRA does not struggle as much in understanding DISCOSENSE as the BERT-based models do, and as a result, it shows a bigger improvement, possibly benefitting from the diverse contextual nature of DISCOSENSE.
+
+Finally, we evaluate the sequentially fine-tuned ELECTRA-LARGE model on the HELLASWAG test split. The model achieves an accuracy of $90.76\%$ , considerably outperforming its vanilla fine-tuning counterpart $(85.75\%)$ and only underperforming models that have 4x (e.g., He et al. (2021), Lourie et al. (2021)) and 32x more parameters (e.g., Lourie et al. (2021)) and are trained on 23x more data.
+
+# 5 Conclusion
+
+Motivated in part by the fact that existing pretrained language models have surpassed human performance on numerous commonsense reasoning datasets, we introduced DISCOSENSE, a challenging benchmark that concerns commonsense reasoning with discourse connectives to determine the most plausible ending of a sentence. This task was made difficult by the synthesis of high quality complex examples, which was made possible through coupling highly competitive conditionally trained models for language generation with Adversarial Filtering. The best performing model on DISCOSENSE only achieved an accuracy of $65\%$ , significantly lagging behind humans. This makes DISCOSENSE an ideal benchmark for next-generation commonsense reasoning systems.
+
+# Ethical Considerations
+
+Following the guidelines in Mitchell et al. (2019), Bender and Friedman (2018), and Gebru et al. (2021), we believe that we have provided all the necessary information in our description of DISCOSENSE. In this section, we focus on ethical considerations.
+
+Bias mitigation. While it may not be possible to eliminate all of the biases that exist in a dataset, we have certainly taken steps to mitigate biases in DISCOSENSE. Adversarial Filtering has been shown to be an effective de-biasing approach to remove annotation artifacts, and we have taken a step further to improve this approach through conditional text generation. In addition, to our knowledge, our work has used more capable generators and discriminators (adversarial filter) to synthesize text in comparison to other works (Zellers et al., 2018, 2019b; Bras et al., 2020).
+
+Human annotator information. All annotators/verifiers were hired during Summer 2021 as student workers (20-25 hours/week) with full consent. All of them were undergraduate and graduate students aged around 20-24. The group comprised both male and female students with members belonging to different ethnicity, namely Asian, Caucasian, and Hispanic. All annotators were native English speakers. Additional details on the selection of annotators can be found in Appendix A.1. The annotators were compensated with a hourly rate of 10 US dollars.
+
+Steps taken to protect annotators from harmful content. All annotators were provided with a thorough instructional training session in which they were instructed on how to annotate the data, how to go about the whole task, and what kind of examples to skip. Before we shared the data, we performed filtering of examples based on sensitive/offensive keywords. After the filtering process, we provided the annotators with a document that contains instructions on how to annotate and how to go about the whole task (see Appendix A.2). They were asked to follow their own pace (the amount of time they can spend per example). They were asked to attempt examples that were specifically related to commonsense reasoning tasks. Since the aforementioned keyword-based approach for filtering harmful content may not be able to identify all harmful/offensive documents, the annotators were provided with an opportunity to skip examples that they would consider offensive, sensitive orchal
+
+lenging enough to confuse them.
+
+Is this dataset consistent with the terms of use and the intellectual property and privacy right of people? The most important term of use for this dataset is that it shall primarily be used for NLP research. The source text of this dataset was obtained from DISCOVERY and DISCOFUSE, both of which have been there for a long time. These datasets have been obtained from Commoncrawl and Wikipedia data, which is public information. Therefore these data sources do not contain any information that is non-public. We agree with the authors of DISCOVERY and DISCOFUSE that these data sources do not seem to mis-represent any community nor can be used to identify a certain set of individual known outside public information. Through conditional text generation, which has been used to synthesize commonsense knowledge text with discourse connectives, we present text that is mostly suitable for commonsense reasoning tasks, making this work consistent with the terms of use. We believe that our work does not have use cases that would usually be considered out-of-bounds for NLP research.
+
+Is there anything about the composition of the dataset or the way it was collected and preprocessed/cleaned/labeled that might impact future uses? We have highlighted all the necessary information required by the user of this dataset to use it for their own use case. Each example has gone through multiple rounds of screening. We do not expect to see any risk being posed by the user of this dataset nor any financial harm associated with its use.
+
+Will the dataset be distributed to third parties outside of the entity (e.g., company, institution, organization) on behalf of which the dataset was created? We will open-source all the models and data produced from this work immediately after publication. We plan to release it on a GitHub repository with the MIT license and also make it available on Hugging Face Datasets.
+
+If others want to extend/augment/build on/contribute to the dataset, is there a mechanism for them to do so? We have provided all the essential information needed by a user to extend this work. They will have access to the data and the models which they can use for experimentation. We will continue to monitor the GitHub repository to resolve issues.
+
+# Limitations
+
+Next, we discuss some limitations of our work.
+
+Limitations of (Conditional) Adversarial Filtering. Recall that we seek to create a challenging commonsense reasoning benchmark by automatically removing annotation artifacts7 and replacing easy options in examples via the design and use of Conditional Adversarial Filtering (CAF). Although CAF is an improved version of Adversarial Filtering (AF), which has been frequently used in the last few years in the construction of commonsense reasoning benchmarks, it is not without its limitations. Specifically, how well CAF can identify annotation artifacts and easy options and subsequently remove artifacts and replace easy options with difficult ones depends on how good the discriminator and the generators are. As discussed before, while the discriminator and generators we use in the creation of DISCOSENSE are stronger than those used in the creation of virtually all other commonsense reasoning benchmarks (e.g., SWAG and HELLASWAG), these discriminator and generators are still not perfect. In particular, the fact that the best-performing baseline, ELECTRA, achieves an accuracy that is substantially higher than random guess (i.e., $67\%$ vs. $25\%$ ) is an indication that the discriminator and generators fail to remove all annotation artifacts and/or replace easy options with sufficiently difficult ones for state-of-the-art pretrained language models. As pre-trained language models continue to improve, we do expect that the family of AF approaches will become more effective. Nevertheless, moving forward, researchers should think about whether there are alternative, non-AF-based approaches for creating challenging commonsense reasoning benchmarks that do not suffer from the limitations of AF-based approaches.
+
+Coverage of discourse connectives. While we have taken measures to ensure that DISCOSENSE has a good coverage of discourse connectives, there are still many connectives that are not present in DISCOSENSE due to the ambiguity they give rise to. For example, having "and" does not make it clear what the next sentence should talk about given a context, meaning that it is likely for these connectives to have many endings that are equally plausible. Given budgetary constraints, we do not want to
+
+waste our human verification effort on identifying and filtering the potentially large number of examples that contain equally plausible endings as a result of these ambiguous discourse connectives. So, we have avoided their inclusion in DISCOSENSE thus far. However, to fairly evaluate how good a model is in reasoning with discourse connectives, we should augment DISCOSENSE with ambiguous discourse connectives in the future.
+
+Types of reasoning. Although there is a high coverage in the types of commonsense reasoning DISCOSENSE aims to study (e.g., physical world reasoning, social commonsense reasoning, numerical reasoning, linguistic reasoning, temporal reasoning, abductive reasoning), there are other kinds of reasoning studied within the NLP literature that this benchmark does not aim to evaluate upon, such as multi-hop reasoning and symbolic reasoning. It is still not clear how adversarial approaches can be applied to make these kinds of reasoning difficult. We leave this component to a future work.
+
+# Acknowledgments
+
+We thank the three anonymous reviewers for their insightful comments on an earlier draft of the paper. This work was supported in part by NSF Grant IIS-1528037. Any opinions, findings, conclusions or recommendations expressed in this paper are those of the authors and do not necessarily reflect the views or official policies, either expressed or implied, of the NSF.
+
+# References
+
+Emily M. Bender and Batya Friedman. 2018. Data statements for natural language processing: Toward mitigating system bias and enabling better science. Transactions of the Association for Computational Linguistics, 6:587-604.
+Chandra Bhagavatula, Ronan Le Bras, Chaitanya Malaviya, Keisuke Sakaguchi, Ari Holtzman, Hannah Rashkin, Doug Downey, Wen tau Yih, and Yejin Choi. 2020. Abductive commonsense reasoning. In The 8th International Conference on Learning Representations, Addis Ababa, Ethiopia.
+Yonatan Bisk, Rowan Zellers, Ronan Le Bras, Jianfeng Gao, and Yejin Choi. 2020. PIQA: Reasoning about physical commonsense in natural language. In Proceedings of the 34th AAAI Conference on Artificial Intelligence, pages 7432-7439, New York City, NY. AAAI Press.
+Michael Boratko, Xiang Li, Tim O'Gorman, Rajarshi Das, Dan Le, and Andrew McCallum. 2020. Pro
+
+toQA: A question answering dataset for prototypical common-sense reasoning. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 1122-1136, Online. Association for Computational Linguistics.
+Samuel R. Bowman, Gabor Angeli, Christopher Potts, and Christopher D. Manning. 2015. A large annotated corpus for learning natural language inference. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 632-642, Lisbon, Portugal. Association for Computational Linguistics.
+Ronan Le Bras, Swabha Swayamdipta, Chandra Bhagavatula, Rowan Zellers, Matthew E. Peters, Ashish Sabharwal, and Yejin Choi. 2020. Adversarial filters of dataset biases. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event, volume 119 of Proceedings of Machine Learning Research, pages 1078-1088. PMLR.
+Kevin Clark, Minh-Thang Luong, Quoc V. Le, and Christopher D. Manning. 2020. ELECTRA: Pretraining text encoders as discriminators rather than generators. In The 8th International Conference on Learning Representations, Addis Ababa, Ethiopia.
+K. Bretonnel Cohen, Karen Fort, Gilles Adda, Sophia Zhou, and Dimeji Farri. 2016. Ethical issues in corpus linguistics and annotation: Pay per hit does not affect effective hourly rate for linguistic resource development on Amazon Mechanical Turk. In Proceedings of LREC Workshop on ETHics In Corpus Collection, Annotation Application (ETHI-CA2 2016), pages 8-12.
+Zihang Dai, Guokun Lai, Yiming Yang, and Quoc Le. 2020. Funnel-transformer: Filtering out sequential redundancy for efficient language processing. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, pages 4271-4282, Online. Curran Associates, Inc.
+Sumanth Dathathri, Andrea Madotto, Janice Lan, Jane Hung, Eric Frank, Piero Molino, Jason Yosinski, and Rosanne Liu. 2020. Plug and play language models: A simple approach to controlled text generation. In The 8th International Conference on Learning Representations, Addis Ababa, Ethiopia.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Nam Do and Ellie Pavlick. 2021. Are rotten apples edible? challenging commonsense inference ability with
+
+exceeds. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 2061-2073, Online. Association for Computational Linguistics.
+Maxwell Forbes, Jena D. Hwang, Vered Shwartz, Maarten Sap, and Yejin Choi. 2020. Social chemistry 101: Learning to reason about social and moral norms. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 653-670, Online. Association for Computational Linguistics.
+Karen Fort, Gilles Adda, and K. Bretonnel Cohen. 2011. Last words: Amazon Mechanical Turk: Gold mine or coal mine? Computational Linguistics, 37(2):413-420.
+Timnit Gebru, Jamie Morgenstern, Briana Vecchione, Jennifer Wortman Vaughan, Hanna Wallach, Hal Daume III, and Kate Crawford. 2021. Datasheets for datasets. Communications of the ACM, 64(12):86-92.
+Mor Geva, Eric Malmi, Idan Szpektor, and Jonathan Berant. 2019. DiscoFuse: A large-scale dataset for discourse-based sentence fusion. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 3443-3455, Minneapolis, Minnesota. Association for Computational Linguistics.
+Pengcheng He, Xiaodong Liu, Jianfeng Gao, and Weizhu Chen. 2021. DeBERTa: Decoding-enhanced bert with disentangled attention. Computing Research Repository, arXiv:2006.03654.
+Ari Holtzman, Jan Buys, Li Du, Maxwell Forbes, and Yejin Choi. 2020. The curious case of neural text degeneration. In *The 8th International Conference on Learning Representations*, Addis Ababa, Ethiopia.
+Lifu Huang, Ronan Le Bras, Chandra Bhagavatula, and Yejin Choi. 2019. Cosmos QA: Machine reading comprehension with contextual commonsense reasoning. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 2391-2401, Hong Kong, China. Association for Computational Linguistics.
+Jena D. Hwang, Chandra Bhagavatula, Ronan Le Bras, Jeff Da, Keisuke Sakaguchi, Antoine Bosselut, and Yejin Choi. 2021. COMET-ATOMIC 2020: On symbolic and neural commonsense knowledge graphs. In Proceedings of the 34th AAAI Conference on Artificial Intelligence, pages 6384–6392, Online. AAAI Press.
+Nitish Shirish Keskar, Bryan McCann, Lav Varshney, Caiming Xiong, and Richard Socher. 2019. CTRL: A conditional transformer language model for controllable generation. Computing Research Repository, arXiv:1909.05858.
+
+Ben Krause, Akhilesh Deepak Gotmare, Bryan McCann, Nitish Shirish Keskar, Shafiq Joty, Richard Socher, and Nazneen Fatema Rajani. 2020. GeDi: Generative discriminator guided sequence generation. Computing Research Repository, arXiv:2009.06367, abs/2009.06367.
+Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma, and Radu Soricut. 2020. Albert: A lite bert for self-supervised learning of language representations. In The 8th International Conference on Learning Representations, Addis Ababa, Ethiopia.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. RoBERTa: A robustly optimized BERT pretraining approach. Computing Research Repository, arXiv:1907.11692.
+Ilya Loshchilov and Frank Hutter. 2019. Decoupled weight decay regularization. In The 7th International Conference on Learning Representations, New Orleans, Louisiana.
+Nicholas Lourie, Ronan Le Bras, Chandra Bhagavatula, and Yejin Choi. 2021. UNICORN on RAINBOW: A universal commonsense reasoning model on a new multitask benchmark. In Proceedings of the 35th AAAI Conference on Artificial Intelligence, Online. AAAI Press.
+Margaret Mitchell, Simone Wu, Andrew Zaldivar, Parker Barnes, Lucy Vasserman, Ben Hutchinson, Elena Spitzer, Inioluwa Deborah Raji, and Timnit Gebru. 2019. Model cards for model reporting. In Proceedings of the Conference on Fairness, Accountability, and Transparency (FAT*19), pages 220-229, New York, NY. Association for Computing Machinery.
+Emily Pitler and Ani Nenkova. 2009. Using syntax to disambiguate explicit discourse connectives in text. In Proceedings of the ACL-IJCNLP 2009 Conference Short Papers, pages 13-16, Suntec, Singapore. Association for Computational Linguistics.
+Rashmi Prasad, Nikhil Dinesh, Alan Lee, Eleni Milt-sakaki, Livio Robaldo, Aravind Joshi, and Bonnie Webber. 2008. The Penn Discourse TreeBank 2.0. In Proceedings of the Sixth International Conference on Language Resources and Evaluation (LREC'08), Marrakech, Morocco. European Language Resources Association (ELRA).
+Ehsan Qasemi, Filip Ilievski, Muhao Chen, and Pedro A. Szekely. 2021. CoreQuisite: Circumstantial preconditions of common sense knowledge. Computing Research Repository, arXiv:2104.08712.
+Lianhui Qin, Aditya Gupta, Shyam Upadhyay, Luheng He, Yejin Choi, and Manaal Faruqui. 2021. TIME-DIAL: Temporal commonsense reasoning in dialog. In Proceedings of the 59th Annual Meeting of the
+
+Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 7066-7076, Online. Association for Computational Linguistics.
+Lianhui Qin, Vered Shwartz, Peter West, Chandra Bhagavatula, Jena D. Hwang, Ronan Le Bras, Antoine Bosselut, and Yejin Choi. 2020. Back to the future: Unsupervised backprop-based decoding for counterfactual and abductive commonsense reasoning. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 794-805, Online. Association for Computational Linguistics.
+Melissa Roemmele, Cosmin Adrian Bejan, and Andrew Gordon. 2011. Choice of Plausible Alternatives: An evaluation of commonsense causal reasoning. In Proceedings of the AAAI Spring Symposium on Logical Formalizations of Commonsense Reasoning. AAAI Press.
+Rachel Rudinger, Vered Shwartz, Jena D. Hwang, Chandra Bhagavatula, Maxwell Forbes, Ronan Le Bras, Noah A. Smith, and Yejin Choi. 2020. Thinking like a skeptic: Defeasible inference in natural language. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 4661-4675, Online. Association for Computational Linguistics.
+Keisuke Sakaguchi, Ronan Le Bras, Chandra Bhagavatula, and Yejin Choi. 2020. Winogrande: An adversarial winograd schema challenge at scale. In Proceedings of the 34th AAAI Conference on Artificial Intelligence, pages 8732-8740, New York City, NY. AAAI Press.
+Maarten Sap, Hannah Rashkin, Derek Chen, Ronan Le Bras, and Yejin Choi. 2019. Social IQa: Commonsense reasoning about social interactions. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 4463-4473, Hong Kong, China. Association for Computational Linguistics.
+Damien Sileo, Tim Van De Cruys, Camille Pradel, and Philippe Muller. 2019. Mining discourse markers for unsupervised sentence representation learning. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 3477-3486, Minneapolis, Minnesota. Association for Computational Linguistics.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame,
+
+Quentin Lhoest, and Alexander M. Rush. 2019. HuggingFace's Transformers: State-of-the-art natural language processing. Computing Research Repository, arXiv:1910.03771.
+
+Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Russ R. Salakhutdinov, and Quoc V. Le. 2019. Xlnet: Generalized autoregressive pretraining for language understanding. In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, Vancouver, Canada. Curran Associates, Inc.
+
+Rowan Zellers, Yonatan Bisk, Ali Farhadi, and Yejin Choi. 2019a. From recognition to cognition: Visual commonsense reasoning. In Proceedings of the 2019 IEEE Conference on Computer Vision and Pattern Recognition (CVPR 2019), pages 6720-6731, Long Beach, CA.
+
+Rowan Zellers, Yonatan Bisk, Roy Schwartz, and Yejin Choi. 2018. SWAG: A large-scale adversarial dataset for grounded commonsense inference. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 93-104, Brussels, Belgium. Association for Computational Linguistics.
+
+Rowan Zellers, Ari Holtzman, Yonatan Bisk, Ali Farhadi, and Yejin Choi. 2019b. HellaSwag: Can a machine really finish your sentence? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4791-4800, Florence, Italy. Association for Computational Linguistics.
+
+Jeffrey O. Zhang, Alexander Sax, Amir Zamir, Leonidas Guibas, and Jitendra Malik. 2020. Side-tuning: A baseline for network adaptation via additive side networks. In Proceedings of the 16th European Conference on Computer Vision (ECCV 2020), pages 698-714, Glasgow, UK.
+
+Ben Zhou, Daniel Khashabi, Qiang Ning, and Dan Roth. 2019. "going on a vacation" takes longer than "going for a walk": A study of temporal commonsense understanding. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3363-3369, Hong Kong, China. Association for Computational Linguistics.
+
+# A Crowdsourcing Details
+
+We performed crowdsourcing to determine if humans are able to identify the ground truth in each example present in the training and test sets of DISCOSENSE.
+
+# A.1 Selection of Annotators
+
+We selected undergraduate and graduate student workers primarily on the basis of relevant background knowledge and their current skill set. Since
+
+the dataset features intricate English sentences, we shortlisted students who are native English speakers. We presented all shortlisted student workers with a one-hour training session followed by an evaluation test and ranked them based on their performance on the test. We then hired the top-performing students as our annotators and asked them to answer each example in DISCOSENSE. We closely monitored the progress and the performance of each annotator and provided timely feedback through virtual meetings on how his/her way of performing annotation can be improved by understanding the difficulties encountered by him/her and rectifying any problems if they have been doing the annotation in an incorrect manner. All of the annotators were made aware of how the annotated data would be used and its implications. The student workers who did not perform the annotation work in a satisfactory manner were replaced by the next best performing student on the waitlist. All student workers were paid $10/hr (Fort et al., 2011; Cohen et al., 2016).
+
+# A.2 Instructions Provided to Annotators
+
+Below are the instructions we presented to the annotators during our one-hour tutorial. Each of them received a copy of these instructions plus numerous examples (one of them is shown below) at the end of the tutorial and was given an opportunity to ask clarification questions about the instructions and the annotation process in general after a closer examination of these instructions and examples.
+
+Motivation. Academic research is an exploration activity to solve problems that have not been completely solved before. By this nature, each academic research work must sit at the frontier of the field and present novelties that have not been addressed by prior works. Machine Learning (specifically Deep Learning) has seen advancements in numerous domains such as personal assistants, machine translation, etc. What you may have seen is a particular Machine Learning algorithm being deployed in finished end products, but what we do not observe are the research challenges that were overcome behind the scenes to get there. What you will be involved in is one of the research tasks that is far from being solved. You will be contributing towards a meaningful task that has the potential to make scientific advancements. We are dealing with Commonsense Reasoning with regard to
+
+Natural Language Processing. Specifically, we are addressing the problem of how machines can learn to reason in the manner humans do with textual data. This task often requires humans to make use of the information they have acquired about our world (e.g., how the physical world works), and reason about what they read and how it complies with what they already know. The reasoning works on multiple levels: firstly we understand the information we read, make sure we understood it properly, and then reason through various means about it to ensure that it makes sense with what we know. The following quote sums it up nicely.
+
+The brain is an abduction machine, continuously trying to prove abductively that the observables in its environment constitute a coherent situation.
+
+— Jerry Hobbs, ACL 2013 Lifetime Achievement Award winner
+
+Current Deep Learning models are very good at picking unintended signals to arrive at the correct answer, but this is not what we intend them to do. For instance, if "not" is present within a sentence, then the model might be biased towards predicting negation even though that might not be the case. We require them to pick the right answer through a reasoning process that is as close to the human reasoning process as possible. To address this task, we need to build a dataset that aims at providing "correct" signals to our models, and hopefully the models can learn to reason reasonably well once they are trained on this dataset.
+
+High level description of the task. The task description is straightforward.
+
+Given a context and a discourse connective, predict which ending is the best to the best of your knowledge/capability.
+
+While reading the contexts, you should understand what the discourse connective is supposed to convey. A discourse connective is a word/phrase used to connect two sentences and reveal their relationship. Consider the following examples.
+
+1. I am feeling hungry, as a result, I cooked lunch.
+2. Although I liked reading the book, there were
+
+I love that he's able to use wired as a venue for launching future bestsellers though
+
+a) I think the wired article is a bit too long.
+b) I don't think its a bad thing for him to do so.
+c) I do agree with some of the other reviews that wired is not a very well written book.
+
+d) Honestly, I might have preferred the podcast of his presentation on the topic.
+
+Figure 6: Example taken from the DISCOSENSE training set. The correct answer is boldfaced.
+
+# some major flaws.
+
+In these examples, the green-colored text is the context and the discourse connective is boldfaced. Notice how the text in orange is framed in accordance with the discourse connective. For instance, if "as a result" is present, then the ending will most likely be about the consequence of what is described in the context; in contrast, if "although" is the discourse connective, then the ending needs to take a contrasting standpoint. Hence, the discourse connective decides what the ending needs to talk about. We have provided a list of the discourse connectives you can expect in the "Role of discourse connectives" section. You are required to be completely familiar with the role each connective is supposed to play.
+
+Figure 6 shows an example you might expect in the dataset. Any ending that violates what we know about how the physical world works or challenges our notions about anything in particular needs to be discarded. You have to choose the most plausible ending, which is the ending that is the most feasible amongst four endings. In cases where two or more endings seem equally feasible, the following criteria should be used.
+
+- Any ending that seems to be indisputably correct can be regarded as the best.
+- The best ending will not be inconsistent with the context and the discourse connective.
+- If all three options seem incorrect and implausible and the remaining option makes the most sense relatively, then it should be chosen since the correct ending is the best ending by default.
+- Two endings can make sense, but the ending that is likely to be more sensible is what you should consider as the best. For example:
+
+- Context: A man is singing into a microphone.
+- Ending 1: A man performs a song.
+- Ending 2: A man is performing on stage.
+
+Ending 2 is not incorrect but ending 1 makes more logical sense to us as humans. In such cases, mark what seems more logical to you.
+
+Role of discourse connectives. Please make sure that you understand the role of each connective.
+
+although: in spite of the fact that; even though
+- as a result: because of something
+because of this: for the reason that
+because of that: for the reason that
+- but: used for joining two ideas or statements when the second one is different from the first one
+- by contrast: used to express difference with something
+- consequently: as a result
+- conversely: introducing a statement or idea which reverses one that has just been made or referred to
+- for example: used to introduce something
+- for instance: as an example
+- hence: as a consequence; for this reason
+- however: used to introduce a statement that contrasts with or seems to contradict something that has been said previously
+- in contrast: used to express difference with something
+- in other words: to put it another way
+- in particular: especially; specifically
+- in short: to sum up; briefly
+- in sum: to sum up; in summary
+- instead: as an alternative or substitute
+- interestingly: in a way that arouses curiosity or interest
+
+- likewise: in the same way
+- nevertheless: in spite of that; notwithstanding; all the same
+- nonetheless: in spite of that; nevertheless
+- on the contrary: conversely; used to intensify a denial of what has just been implied or stated by suggesting that the opposite is the case
+- on the other hand: used to introduce a contrasting point of view, fact, or situation
+- otherwise: in circumstances different from those present or considered; or else
+- overall: taking everything into account
+particularly:especially
+- rather: used to indicate one's preference in a particular matter; preferably
+- similarly: in a similar way
+- specifically: in a way that is exact and clear; precisely
+- subsequently: after a particular thing has happened; afterward
+thereafter: after that time
+- thereby: by that means; as a result of that
+- therefore: for that reason; consequently
+- though: despite the fact that; although
+- thus: as a result or consequence of this; therefore
+- yet: so far; up until the present or a specified or implied time; by now or then
\ No newline at end of file
diff --git a/discosensecommonsensereasoningwithdiscourseconnectives/images.zip b/discosensecommonsensereasoningwithdiscourseconnectives/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..7dca0fbd80b0142b82fd02fb89e2a9df38962f10
--- /dev/null
+++ b/discosensecommonsensereasoningwithdiscourseconnectives/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:51f8f9a36621328e4cf4787154b69b1be349025a33c9f3c4b55621ee064ded2f
+size 368889
diff --git a/discosensecommonsensereasoningwithdiscourseconnectives/layout.json b/discosensecommonsensereasoningwithdiscourseconnectives/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..bd2922d6e292418236cbf00a902e9028f7b33241
--- /dev/null
+++ b/discosensecommonsensereasoningwithdiscourseconnectives/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ea80f5272e6e12ee7f2d4592edff30971cc1c96a7648a1a2ef1d00ff338254db
+size 486101
diff --git a/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_content_list.json b/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..3c7f60cee525b23276de47c0fa6508cc8b74155d
--- /dev/null
+++ b/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:06b087c149bfe6922c78440e72a948bdf2ff75fc553d5d77c55f860e3718d960
+size 149344
diff --git a/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_model.json b/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..1de8506ff8a6605e7d5bf270c40de84ad12e42e5
--- /dev/null
+++ b/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b4ff7ab26dafe488b99cb8125b537ff1bf59e28573540ed4e131c1b3f8811225
+size 174814
diff --git a/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_origin.pdf b/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..44c81cabec9b451935eb2555f9ecfd11027276b3
--- /dev/null
+++ b/discourseawaresoftpromptingfortextgeneration/c60ee428-a7bc-4d8d-84c2-5c5ec06e1623_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:353b2e3d1958cd71809c6ce074f8cfd6833ae66edc6500612a558e1d7bedf1bf
+size 4053834
diff --git a/discourseawaresoftpromptingfortextgeneration/full.md b/discourseawaresoftpromptingfortextgeneration/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..6e77343d781446e60d83cfbf930676104b20010d
--- /dev/null
+++ b/discourseawaresoftpromptingfortextgeneration/full.md
@@ -0,0 +1,558 @@
+# Discourse-Aware Soft Prompting for Text Generation
+
+Marjan Ghazvininejad
+
+Vladimir Karpukhin
+
+Vera Gor
+
+Asli Celikyilmaz
+
+Meta AI
+
+# Abstract
+
+Current efficient fine-tuning methods (e.g., adapters (Houlsby et al., 2019), prefix-tuning (Li and Liang, 2021), etc.) have optimized conditional text generation via training a small set of extra parameters of the neural language model, while freezing the rest for efficiency. While showing strong performance on some generation tasks, they don't generalize across all generation tasks. We show that soft-prompt based conditional text generation can be improved with simple and efficient methods that simulate modeling the discourse structure of human written text. We investigate two design choices: First, we apply hierarchical blocking on the prefix parameters to simulate a higher-level discourse structure of human written text. Second, we apply attention sparsity on the prefix parameters at different layers of the network and learn sparse transformations on the softmax-function. We show that structured design of prefix parameters yields more coherent, faithful and relevant generations than the baseline prefix-tuning on all generation tasks.
+
+# 1 Introduction
+
+Recent advances in pre-trained language models (PLMs) (Lewis et al., 2020; Raffel et al., 2020; Radford et al., 2019) have made great impact on text generation research, especially when they are fine-tuned on downstream tasks such as summarization, data-to-text generation, long-question answering, etc. Consequent research have shown that PLMs' impact can further be improved when trained with more parameters, on more data and with more compute (GPT-3 (Brown et al., 2020), Megatron (Smith et al., 2022)). On the flip side, storing larger LMs or fully fine-tuning them (updating all the parameters) on downstream tasks usually causes resource or over-fitting issues.
+
+To mitigate fine-tuning issues, recent work have proposed prompt-based learning (Liu et al., 2021a), which focus on learning textual prompts to steer
+
+PLMs' continuation towards desired output while keeping the model parameters frozen. While providing strong control of the PLMs, such prompt engineering could be time consuming requiring manual crafting. There is a growing research direction under prompt learning towards lightweight finetuning (Houlsby et al., 2019; Lester et al., 2021), which update only a small number of existing or extra parameters while keeping most of the original pre-trained parameters frozen. Among them is prefix-tuning (Li and Liang, 2021), which prepends tunable continuous task-specific prompt vectors called prefixes to the input and only trains these continuous prompts during fine-tuning. Although prefix-tuning can yield comparable results to full fine-tuning on some generation tasks, it did not generalize to tasks like abstractive summarization.
+
+In this work, we focus on prefix-tuning and investigate ways to improve its generalization on text generation tasks. We start asking the following questions that motivates our design choices: (1) Do different parts of the transformer network process the prefix parameters more efficiently?; (2) Do prefix parameters capture high-level discourse structure of the input text?; (3) Can constraining prefix attention distribution to be structurally sparse enable better transfer of the task features?
+
+To address (1), we conduct empirical analysis on prefix-tuned BART (Lewis et al., 2020), by varying the size of the prefix parameters at the encoder and decoder networks on text generation tasks. We find that the prefix parameters at higher layers impact the performance the most, while sparse prefixes can be sufficient at the lower layers (§ 6.1).
+
+Motivated by this finding and to address (2), we investigate discourse-aware soft prompting via hierarchical blocking of prefix parameters. Previous text generation work (e.g., abstractive summarization) has shown that abstraction can be better modeled with hierarchically structured architectures (Liu and Lapata, 2019; Fabbri et al., 2019;
+
+Xiao et al., 2021). To simulate a hierarchical discourse structure while only tuning additional prefix parameters, we first split the input and output text into segments and then assign sets of prefix parameters to each segment at different layers. With this structure, a set of prefixes can only be reached by their designated input or output segments during self-attention. We argue that for conditional generation tasks with hierarchically structured blocking of prefixes, we can simulate the structure of human writing styles: in input text each paragraph is a distinct section of related sentences and in output text (e.g., summary) each output sentence outlines salient concepts. Thus, a set of prefixes designated to each input and output segment at different layers can learn levels of abstractions from each section. We show performance improvements over baseline prefix tuning, yielding comparable results to full fine-tuning in several generation tasks in § 6.2.
+
+Inspired by these findings, we address (3) by applying a suite of known sparse attention alternatives to standard full-attention matrix during prefix-tuning. Our goal is to analyze whether sparse prefix-tuned models can encode important features better than dense prefix-tuned models. Prior work have shown that sparsity in self-attention not only improves training efficiency, but also focusing on salient features while pushing down unrelated features and relations can impact the model performance. This improves language modeling (Sukhbaatar et al., 2021; Wang et al., 2020), language understanding (Shi et al., 2021; Cui et al., 2019) and text generation (Zaheer et al., 2020; Li et al., 2021; Liu et al., 2021b; Manakul and Gales, 2021). Motivated by previous work we apply sparsity into the self-attention by substituting the softmax function with a sparse alternative under encoder prefix-tuning (without introducing any additional model parameters). With spectral analysis we show that sparse prefix parameters can identify important features compared to dense prefix parameters. Our quantitative analysis yield performance improvements on automatic metrics over best prefix-tuning models, while human judges generally prefer our sparse prefix model generations on factuality and coherence criteria ( $\S$ 6.3 and $\S$ 6.4).
+
+Efficient tuning of PLMs offers a promising new direction for many NLP tasks including text generation, which we study in this work. Our results suggest that prompt design with hierarchical structure and sparsity in prefix parameters: (i)
+
+generate more coherent and faithful text than baseline prefix-tuning across several summarization and data-to-text generation tasks, (ii) trail the performance of fine-tuning on most summarization tasks with a small margin, while at par with fine-tuning on data-to-text generation tasks, (iii) improve all the baselines in low-resource settings.
+
+# 2 Related Work
+
+Prompt Tuning. Recent years have observed several efficient methods for prompt-based tuning of large-scale PLMs (Liu et al., 2021a). These range from prompt engineering (Petroni et al., 2019; Cui et al., 2021), to more advanced approaches such as prompt ensembling (Mao et al., 2021), composition (Han et al., 2021; Liu et al., 2022; He et al., 2022), or prompt-aware training methods (Lester et al., 2021; Gu et al., 2021). Li and Liang (2021) propose prefix-tuning and show strong results on some text generation tasks, leaving room for further generalization. Here, we build directly upon the prefix-tuning from Li and Liang (2021), showing where it falls short and providing several discourse-aware prompt design approaches. We find with human evaluations ( $\S$ 6.5) on relevance criteria that the prefix-tuning struggles with encoding of salient concepts that constraint generation models require. This setting bears similarities to discourse modeling, which we discuss below.
+
+Discourse Modeling. Several previous work make architectural design choices to teach models about the overall document discourse structure (Marcu, 1997; Barzilay and Lee, 2004; Barzilay and Lapata, 2008; Li and Hovy, 2014) to improve the summarization task. Recent work investigates different model architectures of discourse structure via: structured attention (Cohan et al., 2018), graph based methods (Dong et al., 2021), or hierarchical encoders (Pasunuru et al., 2021; Cao and Wang, 2022). We simulate the discourse structure of text via hierarchical prefixes and propose discourse-aware prompt-design for efficient PLM tuning.
+
+Sparse Language Models. Most work on sparsity in transformers aim at improving the time and space bottleneck of dense transformers (Tay et al., 2021). Work on text generation imbue sparsity to improve coherence, fluency, $n$ -gram diversity and reduce repetition. These work range from: sparse methods on posterior vocabulary distributions at inference time (Fan et al., 2018; Holtzman et al., 2020), sparse attention mechanisms (Cui
+
+
+Figure 1: Encoder self-attention matrices $A$ from layers 1, 6 and 12 of prefix-tuned models showing query attention scores (on $y$ -axis) over all prefix+inputs keys (on $x$ -axis). Top row are matrices of models on E2E dataset where the first 10 features on $x$ -axis are prefix features, and bottom row are on CNN/DM dataset where first 100 features are prefix parameters.
+
+et al., 2019; Liu et al., 2021b; Shi et al., 2021; Sukhbaatar et al., 2021), modified softmax Martins et al. (2020), or loss functions (Welleck et al., 2020) to improve LM coherence and generalization. Similarly, we inject sparsity on the attention matrix of prefix+input features to improve the knowledge transferred to downstream text generation tasks and generating more relevant and coherent text ( $\S 6$ ).
+
+# 3 Prefix-Tuning
+
+Following the intuition of the text-based prompt tuning methods (Liu et al., 2021a), prefix-tuning (Li and Liang, 2021) introduces task-specific prompt parameters with the goal of triggering the desired response of the LM without updating any of the original LM parameters. At each layer, it prepends tunable prefix parameters (also called soft-prompts) as additional keys and values to the multi-head self-attention. Prefix-tuning defines $h_i^{(l)}$ as the activation at the $i$ -th token ( $i = 1 \cdots T$ ) of the $l$ -th layer in a $L$ -layer transformer:
+
+$$
+h _ {i} ^ {(l)} = \left\{ \begin{array}{l l} P _ {\theta} [ i,: ], & \text {i f} i \in P _ {\mathrm {i d x}} \\ L M _ {\phi} \left(z _ {i}, h _ {< i}\right) & \text {o t h e r w i s e} \end{array} \right. \tag {1}
+$$
+
+$[,]$ indicates concatenation, $P_{\mathrm{idx}}$ is the sequence of prefix indices, where the activations of the first $\left|P_{\mathrm{idx}}\right|$ positions are directly calculated by $P_{\theta}$ and $z_{i}$ is the $i$ -th token in the input sequence. During training only the parameters corresponding to the prefix keys and values are updated and the same objective function as finetuning is used1.
+
+# 4 Discourse Aware Prefix-Tuning
+
+Visualizing the prompt impact. To motivate the discourse-aware prompt design, we investigate the
+
+impact of prefix-parameters on transformer models during prefix-tuning. We first analyze the attention behaviour similar to (Sun and Lu, 2020). We prefix-tune two BART-LARGE models, one on data-to-text generation task with E2E dataset (Dušek et al., 2019), and another on summarization with CNN/DM (Hermann et al., 2015). For E2E we use 10-prefixes (the first 10 keys are from prefix parameters) and 100-prefixes for CNN/DM $^2$ (similar to Li and Liang (2021)). In Figure 1, we plot the encoder self-attention distributions $A$ for different layers averaging over all head vectors. The $x$ -axis represents the keys while $y$ -axis denotes the queries. For attention matrices of all the layers, see Appendix A.4 Figure 7. The attention scores show stronger relations with the prefix Keys in the E2E model compared to CNN/DM, where the prefixes exhibit weaker relations compared to the input keys. We attribute this to a few issues which we investigate in this work:
+
+Modeling hierarchical structure. Firstly, during prefix-tuning, the model should not only focus on learning the task specific semantics, but also the models should learn the corresponding discourse structure of the downstream task datasets. To model the intrinsic structure of the input text, biasing transformer models with a type of hierarchy has been shown to improve the generation performance. For example, previous work (Cohan et al., 2018; Liu and Lapata, 2019; Cao and Wang, 2022) learns the discourse structure of human written text (e.g., the beginning, body, conclusion paragraphs, topic shifts, etc.) with hierarchically structured transformers to capture the salient aspects in the input text necessary for improved performance in summarization. With probing experiments Jawahar et al. (2019) show that BERT (Devlin et al., 2019) captures surface features and phrase-level information in the lower layers, syntactic features in the middle and semantic features and long-distance dependencies at the higher layers. Motivated by these, we apply variations of hierarchical blocking on prefix parameters at different layers of the network and investigate their impact on text generation with qualitative and quantitative experiments.
+
+Introducing sparsity. Secondly, the weaker prefix attention in longer inputs (Figure 1-CNN/DM attention matrices) may imply that the attention neglects important connections, and potentially dis
+
+turbed by many unrelated words. This issue can be attributed to the softmax function at attention score calculation (Laha et al., 2018; Cui et al., 2019). Softmax produces attention distribution with dense dependencies between words, and fails to assign near/exactly zero probability to less meaningful relations. Thus, the model neglects to put more attention to important connections while also being easily disturbed by many unrelated words (Cui et al., 2019). This issue is more pronounced in tasks like abstractive summarization, since only a handful of salient input aspects is needed to compose a coherent summary. Sparse attention mechanisms (Liu et al., 2021b; Shi et al., 2021) can remedy this issue by learning to put more emphasis on the important features.
+
+Below we describe ways to apply a suite of blocking schemes and sparsity in prefix-tuning models as sketched in Figure 2. Each block represents attention matrix $\mathbf{A} \in \mathbb{R}^{T \times (P + T)}$ , while each row vector $a_{t} \in \mathbb{R}^{(P + T)}$ , $t = 1 \dots T$ , are the attention weights of $P$ -prefix and $T$ -input-key features.
+
+# 4.1 Prefix Blocking
+
+As shown in Figure 2-(b) and (e), the two variations of prefix-blocking we apply here are a type of structural bias we imbue the models to simulate high-level discourse structure of documents:
+
+Uniform Blocking (UniBlock): We first split the sequence of input tokens into segments. We allocate different sets of prefix parameters to each segment and apply blocking on the rest of the prefix parameters. In baseline prefix-tuning, a query of a token can bind with all the prefix and input key and value parameters, while in the uniform blocked prefix-tuning, the query of a token in the input or output segment can bind with all input key and values but only with the designated prefix key and value vectors. For example, if 100 prefix parameters are used and we split the input tokens into 2 segments, the first 50 prefix keys and values can only be bound with the query vectors of input tokens from the first input segment and so on. We only apply blocking to the prefix parameters and let all inputs tokens attend to each other, see Figure 2-(b). In uniform blocking, we use the same blocking schema at each layer.
+
+Hierarchical Blocking (HierBlock): To bias the prefix parameters with a form of hierarchy, we use the uniform prefix-blocking on the lower layers of the transformer, while we let all tokens attend to all
+
+
+Figure 2: Sketches of attention matrices $A$ used in prefix-tuning models representing different prefix design patterns. $p$ -keys and $i$ -keys denote $P$ prefix and $T$ input keys. Sparsity of attention scores are indicated by color gradations. White cells in any row represent blocked parameters for the query.
+
+prefixes at the top layers as shown in Figure 2-(e). The attention matrix of the top layers is same as the standard prefix-tuning of (Li and Liang, 2021) where no blocking on prefixes is applied.
+
+# 4.2 Sparse Attention Prefix-Tuning
+
+To train a prefix-tuning model that learns to highlight important input content, we apply five sparse attention design options on the encoder.
+
+(1) Truncated Sparse Attention (TruncSA): Dai et al. (2021) used sparse cross-attention using truncation to improve salient feature extraction which showed improvements in downstream tasks performance. To simulate encoding with salient features, we apply top- $p$ truncation on both the prefix and input keys as follows: we first add all the row elements $a_{ti} \in [0,1]$ of the attention matrix, namely the attention scores contributing from all the queries, then normalize across all key-features, which yields new key-feature row vectors $\tilde{a}_t \in \mathbb{R}^{(P + T)}$ , $\tilde{a}_t \in \tilde{A}$ :
+
+$$
+\bar {a} _ {t} = \sum_ {i} ^ {T} a _ {t i} \quad \tilde {a} _ {t} = \bar {a} _ {t} / \left(\sum_ {t} ^ {(P + T)} \bar {a} _ {t}\right) \tag {2}
+$$
+
+Using top- $p$ truncation (Dai et al., 2021) we truncate the feature key scores and use the top- $p$ portion of the probability mass in each key attention score. We create a binary mask for each key feature via $\text{mask}(\tilde{\mathbf{A}}) = \text{top-} p(\tilde{\mathbf{A}},\tau)$ by assigning 1.0 to the keys that the top- $p$ sampling has selected, 0 otherwise and threshold parameter $\tau$ controls sparsity. Lastly, we broadcast point-wise multiplication between the sparse mask and the attention matrix $\mathbf{A}$ to obtain the top- $p$ sparse attention matrix $\tilde{\mathbf{A}} = \text{mask}(\tilde{\mathbf{A}}) \odot \mathbf{A}$ , as sketched in Figure 2-(c).
+
+The top- $p$ truncation is similar to using dropout on the features of the network while controlling the dropout rate with a user-defined threshold to compensate for overfitting and performance. Al
+
+though top- $p$ sparse attention provides automatic control over attention sparsity, truncation completely masks some features. Next, we show how to dynamically learn to apply soft-sparsity via sampling from a distribution.
+
+(2) Soft Sparse Attention (SoftSA): Influencing the attention distribution with a stochastic mask to attend to salient tokens can potentially help build higher quality sparse attention for text modeling. Several work investigate novel approaches to learn the sparsity in attention matrix (Li et al., 2021; Roy et al., 2021; Shi et al., 2021) using a sampling method to formulate the right amount of sparsity. They associate the attention scores $a_{ti}$ with each cell $(t,i)$ in A and define a sampling distribution to learn the attention mask during training as sketched in Figure 2-(d). Similarly, we apply relaxed Bernoulli distribution as a sampler to construct our stochastic mask. Since sampling from Bernoulli distribution is not differentiable, we use the Gumbel Softmax reparameterization trick (Jang et al., 2016) with gumbel-softmax:
+
+$$
+\tilde {a} _ {t} = \operatorname {S o f t m a x} _ {n \in 1 \dots (P + T)} \left(a _ {t n}, g, \tau\right) \tag {3}
+$$
+
+where $g = -\log (-\log (u))$ is an independent Gumbel noise generated from the uniform distribution $u \sim U(0,1)$ and $\tau$ is a temperature. As $\tau$ approaches zero, the gumbel output approaches to a discrete distribution in $\{0,1\}$ , becomes identical to those from the Bernoulli distribution. For details on Gumbel-softmax, see Appendix A.1.
+
+(3) & (4) Hierarchical Sparse Attention: To simulate an intrinsic discourse structure of the input text, similar to the hierarchical blocking in § 4.1, we apply sparsity on the parameters only at the lower layers. We train hierarchical models with the dense attention at the higher layers, and apply $(c)$ truncated (HTruncSA) or $(d)$ soft sparse attention (HSoftSA) at the lower layers (see Figure 2-(f)).
+
+(5) Hierarchical Blocking with Sparse Attention (HierBlock+SoftSA): The hierarchical blocking models we used in § 4.1 puts restrictions on the prefix parameters that input tokens can bind with at different layers of the network. To analyze the impact of ensemble of prefix blocking and sparsity, we apply sparsity on the hierarchically blocked prefix-tuning models. We apply soft sparsity (SoftSA) on the lower layers of the network attention matrices of HierBlock models and keep the higher layer attention matrices dense.
+
+| Dataset | Domain | #Data |
| Summarization | | Train/Val/Test |
| XSum (2018) | News | 204K/11K/11K |
| CNN/DM (2015) | News | 287K/13K/11K |
| Wikipow (2018) | DIY | 157K/5.6K/5.6k |
| SAMSum (2019) | Dialog | 15.7K/<1K/<1K |
| Pubmed (2018) | Clinical | 203K/6K/6K |
| Structure to Text (S2T) |
| E2E (2017; 2019) | Reviews | 33K/4K/4.7K |
| DART (2021) | Reviews | 63K/7K/12.5K |
+
+Table 1: Datasets used in the experiments.
+
+# 5 Experiment Setup
+
+Methods. We build all fine-prefix-tuning models on the multi-layered encoder-decoder Transformer architecture using BART-LARGE (Lewis et al., 2020), though our methods can be applied to any transformer architecture with key-value attention. We compare our discourse aware prefix-tuning approaches to full parameter fine-tuning and baseline prefix-tuning (Li and Liang, 2021). Finetuning updates all the LM parameters, while all prefix-tuning models freeze LM parameters and only update the prefix parameters. Baseline prefix-tuning models update prefix parameters at each layer of the transformers using dense attention while our proposed models use variations of sparse and blocked attention at different layers of the network. We choose the best models on validation dataset. For setup details see Appendix A.1.
+
+Datasets. We conduct experiments across six datasets on two tasks: abstractive summarization and data-to-text (S2T) generation. We present a summary of the datasets in Table 1 and provide more details about the datasets in Appendix A.2.
+
+Metrics. For all the tasks and datasets we use the $n$ -gram match metrics: ROUGE-1/2/L (Lin, 2004) for summarization. We use BLEU (Papineni et al., 2002), NIST (Belz and Reiter, 2006), METEOR (Lavie and Agarwal, 2007), ROUGE-L, TER (Snover et al., 2006), Movers (Zhao et al., 2019) and BERTScore (Zhang* et al., 2020) for S2T tasks and report human evaluations analysis.
+
+# 6 Experiment Results
+
+# 6.1 Are all prefix-parameters useful?
+
+Finding: Prefix-tuning models encode diverse but task specific features at each layer differently, while the top-layer prefixes encode abstract features.
+
+Analysis: Earlier work (Jiang et al., 2021; Elazar et al., 2021; Yates et al., 2021) suggests that some layers of the transformers are better than others at producing representations that are useful for a
+
+| Method | XSum
+R1/R2/R-L | CNN/DM
+R1/R2/R-L | PubMed
+R1/R2/R-L | Wikipow
+R1/R2/R-L | SAMSum
+R1/R2/R-L |
| Fineune (FT) |
| FT [*] | 45.14/22.27/37.25 | 44.16/21.28/40.90 | 45.09/19.56/27.42 | 42.86/19.71/34.80 | 49.30/25.60/47.70 |
| FT (repr.). | 45.47/22.40/37.42 | 44.30/21.14/41.22 | 44.96/19.00/27.74 | 43.26/19.38/34.89 | 53.02/28.30/48.73 |
| PrefixTune (PT) |
| PT [*] | 43.80/20.93/36.05 | - | - | - | - |
| PT (repr.) | 43.43/20.37/35.47 | 42.50/19.52/39.08 | 42.38/16.31/24.57 | 39.26/15.58/28.27 | 52.12/26.52/48.05 |
| UniBlock | 43.49/20.58/35.80 | 42.43/19.38/39.15 | 42.81/16.83/24.87 | 39.34/15.55/28.75 | 52.42/27.70/48.12 |
| HierBlock | 43.91/20.83/36.38 | 43.33/20.27/40.12 | 43.16/16.96/25.73 | 40.03/15.90/30.15 | 52.68/27.88/48.56 |
+
+given task. To investigate if similar patterns show up in prefix-tuned models, we take XSum dataset and train models with prefix parameters only at the top layers, the bottom layers, and at a single layer.
+
+Table 2: Summarization: Prefix blocking experiment results comparing against finetuning and prefix-tuning. Top block are best reported scores from corresponding papers [*]: $\spadesuit$ (Lewis et al., 2020), $\spadesuit$ (Li and Liang, 2021), $\star$ (Chen and Yang, 2020), $\spadesuit$ (Zhang et al., 2020). (repr.) denotes our replication of finetuned and prefetchuned BART models. Bottom block are our prefetchuned models: Uniform (UniBlock) and Hierarchical (HierBlock) prefix blocking represent models which use prefix-blocking at different layers ( $\S$ 4.1). All models use BART-large. The best finetune (top block) models are bolded, best prefetchune models (bottom block) are further underlined. All hyper-parameters are summarized in Appendix Table 8.
+
+| Layers | Rouge-1/2/L |
| Top (8-12) | 42.3/18.1/33.4 |
| Low (1-7) | 35.7/13.1/26.9 |
| All (1-12) | 42.6/19.3/34.2 |
+
+Table 3: Validation Rouge scores of prefix-tuned models on XSum using only top/low layers.
+
+
+Figure 3: Validation Rouge-L on single-layer prefix-tuning with XSum.
+
+We show layer-specific prefix-tuned models' validation performance results in Table 3. The 'Top' layers model is tuned with only the top-layer prefix parameters (i.e., top 4 layers have additional prefix parameters), the 'Low' layers model uses only the lower-layer prefix-parameters (i.e., bottom 7 layers have additional prefix parameters) and 'All' layers prefix parameters is same as baseline prefix-tuning. On inspection, we see a moderate/huge performance gap between the models trained with top/upper layers, while we obtain the best performance when we tune all-layer prefix parameters. We see similar patterns on the SAMSum dialog summarization and E2E structure to text generation tasks (in Appendix A.5). We also build models when prefix parameters are used at a single layer of the network. On single layers in Figure 3, all layers contribute to the performance, the top layer prefixes perform best suggesting they might be encoding summary related abstract information.
+
+# 6.2 Are hierarchical prompts effective?
+
+Finding: Hierarchical design of prefix parameters can yield more robust information transfer in text generation improving baseline prefix-tuning.
+
+Analysis: To simulate learning the discourse related representations we bias prefix parameters
+
+with a structure of input documents (as discussed in §4) and experiment with two hierarchical structures: uniform (UniBlock) and hierarchical (HierBlock) from § 4.1. In Table 2 we report the performance of our models in comparison to fine-tuning and baseline prefix-tuning on abstractive summarization tasks. Our results indicate that prefix-blocking models improve over the baseline prefix-tuning on all summarization tasks by up to +1.1 ROUGE-L score overall. Especially for Wikihow, which are considered long document summarization task, we observe up to +2 ROUGE-L score improvement. We further observe that hierarchical blocking on prefixes also helps for data-to-text tasks, though the performance impact of structural bias is more prominent in summarization tasks. We show detailed results of data-to-text tasks and provide samples of generated outputs in Appendix A.6.
+
+# 6.3 Does sparse attention help prefix-tuning?
+
+Finding: With hierarchically structured sparsity training, prefix tuning show more sparse patterns at the lower layers. Sparse prefix parameters at lower layers, and dense at higher layers enable more efficient tuning of the prefix-parameters.
+
+Spectrum Analysis (Statistical Proof): To investigate if our sparse models do in fact learn sparse representations, we conduct spectrum analysis on the encoder attention matrix $\mathbf{A}$ zooming in on the prefix parameters3. To analyze the variation of attention scores we calculate the principal components of the attention scores of prefix parameters4 and plot in Figure 4. We observe that the spectrum distribution of prefixes in lower layers is more skewed than in higher layers, meaning that, in lower layers, more
+
+
+Figure 4: Spectrum analysis of the self-attention matrix comparing the baseline Dense and our Sparse Prefix-Tuned (PT) transformer model zooming in on prefix parameters of size 100. The Y-axis is the normalized cumulative singular value of the self-attention matrix $\mathbf{A}$ , and the X-axis denotes the index of largest eigenvalue. The results are based on BART-Large on XSum dataset. The left plots the averages of all $\mathbf{A}$ on the lower layers, while right plots averages over higher layers.
+
+| Method | XSum | CNN | PubMed | Wikipow | SAMSum |
| Finetune |
| Dense | 37.42 | 41.22 | 27.42 | 34.89 | 48.73 |
| (1) TruncSA | 37.02 | 39.96 | 26.37 | 35.58 | 48.12 |
| (2) SoftSA | 37.23 | 39.67 | 26.26 | 32.53 | 48.45 |
| Prefix-tune |
| Dense | 35.47 | 39.08 | 24.57 | 28.27 | 48.05 |
| (1) TruncSA | 35.39 | 39.52 | 25.61 | 28.94 | 47.88 |
| (2) SoftSA | 35.94 | 39.24 | 25.72 | 28.94 | 47.35 |
| (3) HTruncSA | 36.42 | 40.00 | 25.28 | 30.02 | 48.00 |
| (4) HSoftSA | 36.13 | 39.83 | 24.90 | 30.01 | 48.33 |
+
+information is concentrated in the largest singular values and the rank of $\mathbf{A}$ is lower. In summary, with sparse attention at the lower layers and dense attention at the top layers, the prefix-tuned models enables encoding important features necessary for the factual and consistent summarization. Details on spectrum analysis are provided in Appendix A.7. Next, we empirically support this statistical proof.
+
+Sparsity Analysis: We investigate the impact of sparsity on the performance of the prefix-tuning models. For a fair comparison, we also apply attention sparsity on the finetuned models. We build prefix-tuning models with (1) Truncated Sparse Attention (TruncSA), (2) Soft Sparse Attention (SoftSA), (3) Hierarchical TruncSA (HTruncSA), with top- $p$ sparsity at the lower layers, and dense attention at the top layers, (4) Hierarchical Soft Sparse Attention (HSoftSA), with soft sparse attention at the lower layers but dense at top layers.
+
+We show the ROUGE-L results in Table 4. We observe that when sparsity is used on the prefix-parameters, the prefix-tuned models outperform baseline all-dense prefix-tuning models on all
+
+Table 4: Sparse Attention experiment ROUGE-L results on Finetuning, and Prefix-tuning using dense and soft sparse attention designs in §4.2. The best finetuned models (top-block) are bolded, the best prefixtune models (bottom-block) are further underlined. Full results are included in Appendix 12.
+
+| Dataset | HierBlock | HierBlock+SoftSA |
| Summarization | R1/R2/R-L | R1/R2/R-L |
| XSum | 43.91/20.83/36.38 | 44.00/20.93/36.59 |
| CNN/DM | 43.33/20.27/40.12 | 43.33/20.31/40.10 |
| PubMed | 43.16/16.83/24.87 | 42.96/16.64/25.00 |
| Wikipow | 39.34/15.55/28.75 | 39.30/15.42/28.67 |
| SAMSum | 52.58/27.58/48.42 | 52.83/27.94/48.72 |
| Data-to-Text | | |
| E2E | BLEU/R-L/CiDER | BLEU/R-L/CiDER |
| 67.2/69.1/2.35 | 68.0/69.6/3.38 |
| DART | BLEU/MET/TER↓ | BLEU/MET/TER↓ |
| 46.6/0.39/0.45 | 46.0/0.39/0.46 |
+
+Table 5: What happens when we apply sparsity to hierarchically blocked prompt design? Results comparing dense and sparse prefix-tuning with structurally biased prefix design (via hierarchical blocking) on various text generation tasks. The best results across two models are bolded.
+
+datasets. The performance improvements are more pronounced on long document summarization tasks such as Wikihow, reaching close to 2.0 ROUGE-L improvements. Comparing all layers sparse models of (1) and (2) to hierarchically biased sparsity models of (3) and (4), we observe improvements with the hierarchically structured sparse prefix-tuning models. More details on quantitative analysis are provided in Appendix A.7 and Table 12.
+
+# 6.4 Does sparsity on hierarchically blocked prefixes further improve performance?
+
+Finding: The most performance gains are obtained when sparsity constraints are applied on the hierarchically blocked prefixes (Table 5).
+
+Analysis: Recall from the earlier discussions in §6.2 that, if applying blocking on the lower layered prefixes, while letting all tokens attend to all prefixes at the top layers (HierBlock models) can improve performance. On separate set of ablations in §6.3, we also observe that if we apply sparsity at different layers of the network, the sparse parameters influence the performance compared to the dense prefix tuned parameters at all layers. We now apply sparsity on the hierarchically blocked prefix-models, combining the best hierarchically blocked models with the sparse attention.
+
+In Table 5 we show results of our hierarchical prefix blocking (HierBlock) model against hierarchical prefix blocking model with soft sparse attention (HierBlock+SoftSA) from §4.2. To build the HierBlock+SoftSA models, we apply soft sparsity at the lower layers with blocked prefix parameters, while the top layers use dense prefixes with all tokens attending to all prefixes. In Table 5 we repeat the results of the last row from Table 2 for easy comparison. We observe performance improvements on summarization tasks where the output summaries are shorter, (e.g., XSum SAMSum) and
+
+
+Table 6: Human evaluation results on Faithfulness (top) and Overall (bottom) ratings. PT: Prefixtune, HSoftSA: Hierarchical Soft Attention, HB: HierBlock, HB+SoftSA: HierBlock with Soft Sparse Attention. Bold win %s indicate significance $(p < .05)$ .
+
+ | Better Narrative Structure |
| HB+SoftSA wins | 64.9% |
| PT wins | 24.3% |
| Same | 10.8% |
+
+Table 7: Human evaluation results on narrative structure. PT: Prefixtune, HB+SoftSA: HierBlock with Soft Sparse Attention. $(p < .05)$ .
+
+less on the longer summaries (e.g., Pubmed, Wikihow). On the data-to-text generation tasks the sparsity on hierarchical blocking only improves on E2E, though both HierBlock and HierBlock+SoftSA perform better than baseline prefix-tuning models (see App. Table 13). More details are provided in Appendix A.8. Our analysis suggests that discourse aware design can improve prefix-tuning when the output generations are short (<100 tokens).
+
+# 6.5 Do human evals. support our claims?
+
+Finding: Humans generally prefer generated text from hierarchically blocked prefix-tuned models over all other models, find overall quality of generations indistinguishable from fine-tuning.
+
+Analysis: To evaluate the generated text from our proposed methods against baseline models, we ask human annotators to rate generations on five criteria: faithfulness (consistent with the context), relevance (captures key-points), grammaticality, coherence (form a cohesive whole), and overall quality (informative). Table 6 shows the results of the study on faithfulness, and overall metrics. The columns show the percentage of wins of the model against its opponent on a given row. Our HierBlock (HB) and Hierarchical Soft Sparse Attention (HSoftSA) models beat prefix-tuning and HierBlock signifi
+
+cantly $(p < .05)$ beats most of our sparse models on all axes including factuality. On relevance metrics, all our models perform better than prefix-tuning and even improving fintuning. More details about the evaluation setup as well as results on all the criteria comparing against fine-tuning and prefix-tuning can be found in Appendix A.10. In Table 14 we provide comparisons with fine-tuning and observe that HierBlock models perform as good as finetuning on all criteria.
+
+To determine which model generates an output that contains better narrative structure, we also use expert annotators to conduct a human evaluation study. We conducted head-to-head analysis and asked annotators to compare the summaries generated from our best model HierBlock+SoftSA against PrefixTuning. The generated text was evaluated for narrative structure, where most important facts are linked to causal, argumentative, and other discourse relations (Table 7). According to the results, HierBlock+SoftSA generates summaries with a better narrative structure.
+
+# 6.6 Which structural features are harder to transfer in low-resource settings?
+
+Finding: In low-resource settings, hierarchically designed sparse prefix parameters can efficiently transfer knowledge and represent the semantics and structure of input text yielding more accurate output generations.
+
+Analysis: We simulate a low-resource setting by randomly sampling $k\%$ ( $k = 5,10,25,50$ ) from the training dataset of two summarization tasks: XSum on news, and Wikihow on DIY domains (see train data sizes in Table 1). We use the same hyperparameter settings as our previous models detailed in § 5. We compare our approach to finetuning and prefix-tuning under low-resource settings.
+
+In Figure 5 on the right, we plot ROUGE-L averaging scores of models trained on XSUM and Wikihow. Our structured prefix-tuned models, Hi-erBlock (blue) and its sparse extension which uses sparse features, Hi-erBlock+SA (red) outper
+
+
+Figure 5: Average ROUGE-L scores on low-resource settings.
+
+forms fine-tuned (green) and prefix-tuned models (olive), while using the same number of parameters in low resources settings (when $< 50\%$ training sam
+
+plies are used). Although HierBlock models show consistent performance, on low-resource settings HierBlock-SA performance is more stable. (See Appendix A.11 for more details.)
+
+# 7 Conclusion
+
+We have described simple but effective prompt design options for prefix-tuning of text generation tasks. We enrich prefix parameters with structural biases by way of: prefix-blocking at different layers of the network, sparsity on prefix-parameters and an ensemble of both biases. We show with quantitative and human evaluations on metrics such as coherence and faithfulness that discourse aware prefix improves prefix-tuning across all text generation tasks even at low data settings.
+
+# 8 Limitations
+
+We note a few limitations of our work: (1) our experiments are limited by available datasets, and only evaluated on limited closed domain text generation tasks; (2) we focused on efficient prefix-tuning, while ensemble of different efficient tuning models can boost performance even further; (3) we conduct experiments with $\sim 300\mathrm{M}$ parameter models extending previous work, but it will be valuable for future work to scale to larger models which may exhibit more faithful and consistent generations.
+
+# 9 Ethics Statement
+
+In this work we apply several changes to the state-of-the-art encoder-decoder modeling architecture and build several models to benchmark our new architecture with baseline architectures on several open source text generation datasets.
+
+Intended use. Our architecture is designed to build models of abstractive document summarization and table summarization. Potentially our architecture could be used to train models for summarizing any type of datasets (e.g., any documents, textual conversational dialogues, blog posts, reports, meetings, legal forms, etc.) to further improve the productivity and efficiency of the users in their daily activities without needing to read/listen to long documents/conversations/meetings.
+
+Failure mode. Even though our models yield factually consistent summaries, as judged by us and raters, they can still generate factually inconsistent summaries or sometimes hallucinate information that the source document does not include. This
+
+might be due to the bias or noise in the training data. Model builders wanting to use our architecture to build models on their datasets should build models with consideration of intellectual properties and privacy rights.
+
+Misuse Potential. We note the models to be built with our architecture should be used with careful consideration especially if used to build summarization models. The generated summaries produced by our models are not controlled and use generative approaches, therefore, they could generate unreliable text. Researchers working on abstractive summarization should focus on generating factually correct, ethical and reliable text. If our models are trained on news datasets, a careful consideration should be made on factuality of the generated text and measures have been taken to prevent model hallucinations.
+
+# References
+
+Regina Barzilay and Mirella Lapata. 2008. Modeling local coherence: An entity-based approach. Computational Linguistics, 34(1).
+Regina Barzilay and Lillian Lee. 2004. Catching the drift: Probabilistic content models, with applications to generation and summarization. In Proceedings of the 2004 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies.
+Anja Belz and Ehud Reiter. 2006. Comparing automatic and human evaluation of NLG systems. In 11th Conference of the European Chapter of the Association for Computational Linguistics, pages 313-320, Trento, Italy. Association for Computational Linguistics.
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Advances in Neural Information Processing Systems, volume 33, pages 1877-1901. Curran Associates, Inc.
+Shuyang Cao and Lu Wang. 2022. HIBRIDS: Attention with hierarchical biases for structure-aware long document summarization. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 786-807,
+
+Dublin, Ireland. Association for Computational Linguistics.
+Jiaao Chen and Diyi Yang. 2020. Multi-view sequence-to-sequence models with conversational structure for abstractive dialogue summarization. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4106-4118, Online. Association for Computational Linguistics.
+Arman Cohan, Franck Dernoncourt, Doo Soon Kim, Trung Bui, Seokhwan Kim, Walter Chang, and Nazli Goharian. 2018. A discourse-aware attention model for abstractive summarization of long documents. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 615-621, New Orleans, Louisiana. Association for Computational Linguistics.
+Baiyun Cui, Yingming Li, Ming Chen, and Zhongfei Zhang. 2019. Fine-tune BERT with sparse self-attention mechanism. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3548–3553, Hong Kong, China. Association for Computational Linguistics.
+Leyang Cui, Yu Wu, Jian Liu, Sen Yang, and Yue Zhang. 2021. Template-based named entity recognition using BART. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 1835-1845, Online. Association for Computational Linguistics.
+Wenliang Dai, Samuel Cahyawijaya, Zihan Liu, and Pascale Fung. 2021. Multimodal end-to-end sparse model for emotion recognition. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 5305-5316, Online. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies.
+Yue Dong, Andrei Mircea, and Jackie Chi Kit Cheung. 2021. Discourse-aware unsupervised summarization for long scientific documents. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 1089-1102, Online. Association for Computational Linguistics.
+Ondřej Dušek, David M. Howcroft, and Verena Rieser. 2019. Semantic noise matters for neural natural language generation. In Proceedings of the 12th International Conference on Natural Language Generation,
+
+pages 421-426, Tokyo, Japan. Association for Computational Linguistics.
+Yanai Elazar, Shauli Ravfogel, Alon Jacovi, and Yoav Goldberg. 2021. Amnesic probing: Behavioral explanation with amnesic counterfactuals. Transactions of the Association for Computational Linguistics, 9:160-175.
+Alexander Fabbri, Irene Li, Tianwei She, Suyi Li, and Dragomir Radev. 2019. Multi-news: A large-scale multi-document summarization dataset and abstractive hierarchical model. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 1074-1084, Florence, Italy. Association for Computational Linguistics.
+Angela Fan, Mike Lewis, and Yann Dauphin. 2018. Hierarchical neural story generation. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 889-898, Melbourne, Australia. Association for Computational Linguistics.
+Bogdan Gliwa, Iwona Mochol, Maciej Biesek, and Aleksander Wawer. 2019. SAMSum corpus: A human-annotated dialogue dataset for abstractive summarization. In Proceedings of the 2nd Workshop on New Frontiers in Summarization, pages 70–79, Hong Kong, China. Association for Computational Linguistics.
+Xiaodong Gu, Kang Min Yoo, and Sang-Woo Lee. 2021. Response generation with context-aware prompt learning. ArXiv.
+Xu Han, Weilin Zhao, Ning Ding, Zhiyuan Liu, and Maosong Sun. 2021. PTR: prompt tuning with rules for text classification. ArXiv, abs/2105.11259.
+Pan He, Yuxi Chen, Yan Wang, and Yanru Zhang. 2022. Protum: A new method for prompt tuning based on "[mask)". volume abs/2201.12109.
+Karl Moritz Hermann, Tomas Kocisky, Edward Grefenstette, Lasse Espeholt, Will Kay, Mustafa Suleyman, and Phil Blunsom. 2015. Teaching machines to read and comprehend. In Advances in Neural Information Processing Systems, volume 28. Curran Associates, Inc.
+Ari Holtzman, Jan Buys, Li Du, Maxwell Forbes, and Yejin Choi. 2020. The curious case of neural text degeneration. In International Conference on Learning Representations.
+Neil Houlsby, Andrei Giurgiu, Stanislaw Jastrzebski, Bruna Morrone, Quentin de Laroussilhe, Andrea Gesmundo, Mona Attariyan, and Sylvain Gelly. 2019. Parameter-efficient transfer learning for NLP. In International Conference of Machine Learning.
+Eric Jang, Shixiang Gu, and Ben Poole. 2016. Categorical reparameterization with gumbel-softmax. In International Conference on Learning Representations.
+
+Ganesh Jawahar, Benoit Sagot, and Djamé Seddah. 2019. What does BERT learn about the structure of language? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, Florence, Italy. Association for Computational Linguistics.
+Yichen Jiang, Asli Celikyilmaz, Paul Smolensky, Paul Soulos, Sudha Rao, Hamid Palangi, Roland Fernandez, Caitlin Smith, Mohit Bansal, and Jianfeng Gao. 2021. Enriching transformers with structured tensor-product representations for abstractive summarization. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Online. Association for Computational Linguistics.
+Mahnaz Koupae and William Yang Wang. 2018. Wiki-how: A large scale text summarization dataset.
+Wojciech Kryscinski, Nitish Shirish Keskar, Bryan McCann, Caiming Xiong, and Richard Socher. 2019. Neural text summarization: A critical evaluation. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 540-551, Hong Kong, China. Association for Computational Linguistics.
+Anirban Laha, Saneem A. Chemmengath, Priyanka Agrawal, Mitesh M. Khapra, Karthik Sankaranarayanan, and Harish G. Ramaswamy. 2018. On controllable sparse alternatives to softmax. In Proceedings of the 32nd International Conference on Neural Information Processing Systems, NIPS'18, page 6423-6433, Red Hook, NY, USA. Curran Associates Inc.
+Alon Lavie and Abhaya Agarwal. 2007. Meteor: An automatic metric for mt evaluation with high levels of correlation with human judgments. In Proceedings of the Second Workshop on Statistical Machine Translation, StatMT '07, page 228-231, USA. Association for Computational Linguistics.
+Brian Lester, Rami Al-Rfou, and Noah Constant. 2021. The power of scale for parameter-efficient prompt tuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 3045-3059, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: Denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880, Online. Association for Computational Linguistics.
+
+Haoran Li, Arash Einolghozati, Srinivasan Iyer, Bhargavi Paranjape, Yashar Mehdad, Sonal Gupta, and Marjan Ghazvininejad. 2021. EASE: Extractive-abstractive summarization end-to-end using the information bottleneck principle. In Proceedings of the Third Workshop on New Frontiers in Summarization, pages 85-95, Online and in Dominican Republic. Association for Computational Linguistics.
+Jiwei Li and Eduard H Hovy. 2014. A model of coherence based on distributed sentence representation. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing.
+Xiang Lisa Li and Percy Liang. 2021. Prefix-tuning: Optimizing continuous prompts for generation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4582-4597, Online. Association for Computational Linguistics.
+Chin-Yew Lin. 2004. ROUGE: A package for automatic evaluation of summaries. In Text Summarization Branches Out, pages 74-81, Barcelona, Spain. Association for Computational Linguistics.
+Pengfei Liu, Weizhe Yuan, Jinlan Fu, Zhengbao Jiang, Hiroaki Hayashi, and Graham Neubig. 2021a. Pretrain, prompt, and predict: A systematic survey of prompting methods in natural language processing. CoRR, abs/2107.13586.
+Xiao Liu, Kaixuan Ji, Yicheng Fu, Weng Tam, Zhengxiao Du, Zhilin Yang, and Jie Tang. 2022. P-tuning: Prompt tuning can be comparable to fine-tuning across scales and tasks. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 61-68, Dublin, Ireland. Association for Computational Linguistics.
+Yang Liu and Mirella Lapata. 2019. Hierarchical transformers for multi-document summarization. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 5070-5081, Florence, Italy. Association for Computational Linguistics.
+Ye Liu, Jianguo Zhang, Yao Wan, Congying Xia, Lifang He, and Philip Yu. 2021b. HETFORMER: Heterogeneous transformer with sparse attention for long-text extractive summarization. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 146-154, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Potsawee Manakul and Mark Gales. 2021. Long-span summarization via local attention and content selection. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers),
+
+pages 6026-6041, Online. Association for Computational Linguistics.
+Yuning Mao, Lambert Mathias, Rui Hou, Amjad Alma-hairi, Hao Ma, Jiawei Han, Wen tau Yih, and Madian Khabsa. 2021. Unipelt: A unified framework for parameter-efficient language model tuning. ArXiv, abs/2110.07577.
+Daniel Marcu. 1997. From discourse structures to text summaries. In Intelligent Scalable Text Summarization.
+Pedro Henrique Martins, Zita Marinho, and André F. T. Martins. 2020. Sparse text generation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4252-4273, Online. Association for Computational Linguistics.
+Linyong Nan, Dragomir Radev, Rui Zhang, Amrit Rau, Abhinand Sivaprasad, Chiachun Hsieh, Xiangru Tang, Aadit Vyas, Neha Verma, Pranav Krishna, Yangxiaokang Liu, Nadia Irwanto, Jessica Pan, Faiaz Rahman, Ahmad Zaidi, Murori Mutuma, Yasin Tarabar, Ankit Gupta, Tao Yu, Yi Chern Tan, Xi Victoria Lin, Caiming Xiong, Richard Socher, and Nazneen Fatema Rajani. 2021. Dart: Open-domain structured data record to text generation. arXiv preprint arXiv:2007.02871.
+Shashi Narayan, Shay B. Cohen, and Mirella Lapata. 2018. Don't give me the details, just the summary! topic-aware convolutional neural networks for extreme summarization. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 1797-1807, Brussels, Belgium. Association for Computational Linguistics.
+Jekaterina Novikova, Ondrej Dušek, and Verena Rieser. 2017. The E2E dataset: New challenges for end-to-end generation. In Proceedings of the 18th Annual Meeting of the Special Interest Group on Discourse and Dialogue, Saarbrücken, Germany. ArXiv:1706.09254.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. 2002. Bleu: A method for automatic evaluation of machine translation. In Proceedings of the 40th Annual Meeting on Association for Computational Linguistics, ACL '02, page 311-318, USA. Association for Computational Linguistics.
+Ramakanth Pasunuru, Asli Celikyilmaz, Michel Galley, Chenyan Xiong, Yizhe Zhang, Mohit Bansal, and Jianfeng Gao. 2021. Data augmentation for abstractive query-focused multi-document summarization. In AAAI.
+Fabio Petroni, Tim Rocttäschel, Sebastian Riedel, Patrick Lewis, Anton Bakhtin, Yuxiang Wu, and Alexander Miller. 2019. Language models as knowledge bases? In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference
+
+on Natural Language Processing (EMNLP-IJCNLP), pages 2463-2473, Hong Kong, China. Association for Computational Linguistics.
+PurdueOWL. 2019. Journalism and journalistic writing: The inverted pyramid structure.
+Alec Radford, Jeff Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. 2019. Language models are unsupervised multitask learners.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140):1-67.
+Aurko Roy, Mohammad Saffar, Ashish Vaswani, and David Grangier. 2021. Efficient Content-Based Sparse Attention with Routing Transformers. Transactions of the Association for Computational Linguistics, 9:53-68.
+Abigail See, Peter J. Liu, and Christopher D. Manning. 2017. Get to the point: Summarization with pointer-generator networks. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1073-1083, Vancouver, Canada. Association for Computational Linguistics.
+Han Shi, Jiahui Gao, Xiaozhe Ren, Hang Xu, Xiaodan Liang, Zhenguo Li, and James Tin-Yau Kwok. 2021. Sparsebert: Rethinking the importance analysis in self-attention. In Proceedings of the 38th International Conference on Machine Learning, volume 139 of Proceedings of Machine Learning Research, pages 9547-9557. PMLR.
+Shaden Smith, Mostofa Patwary, Brandon Norick, Patrick LeGresley, Samyam Rajbhandari, Jared Casper, Zhun Liu, Shrimai Prabhumoye, George Zerveas, Vijay Korthikanti, Elton Zheng, Rewon Child, Reza Yazdani Aminabadi, Julie Bernauer, Xia Song, Mohammad Shoeybi, Yuxiong He, Michael Houston, Saurabh Tiwary, and Bryan Catanzaro. 2022. Using deepspeed and megatron to train megatron-turing NLG 530b, A large-scale generative language model. volume abs/2201.11990.
+Matthew Snover, Bonnie Dorr, Rich Schwartz, Linnea Micciulla, and John Makhoul. 2006. A study of translation edit rate with targeted human annotation. In Proceedings of the 7th Conference of the Association for Machine Translation in the Americas: Technical Papers, pages 223-231, Cambridge, Massachusetts, USA. Association for Machine Translation in the Americas.
+Sainbayar Sukhbaatar, Da Ju, Spencer Poff, Stephen Roller, Arthur Szlam, Jason Weston, and Angela Fan. 2021. Not all memories are created equal: Learning to forget by expiring. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event.
+
+Xiaobing Sun and Wei Lu. 2020. Understanding attention for text classification. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 3418-3428, Online. Association for Computational Linguistics.
+Yi Tay, Mostafa Dehghani, Samira Abnar, Yikang Shen, Dara Bahri, Philip Pham, Jinfeng Rao, Liu Yang, Sebastian Ruder, and Donald Metzler. 2021. Long range arena: A benchmark for efficient transformers. In International Conference on Learning Representations.
+Sinong Wang, Belinda Z. Li, Madian Khabsa, Han Fang, and Hao Ma. 2020. Linformer: Self-attention with linear complexity. CoRR, abs/2006.04768.
+Sean Welleck, Ilia Kulikov, Stephen Roller, Emily Dinan, Kyunghyun Cho, and Jason Weston. 2020. Neural text generation with unlikelihood training. In International Conference on Learning Representations.
+Wen Xiao, Iz Beltagy, Giuseppe Carenini, and Arman Cohan. 2021. Primer: Pyramid-based masked sentence pre-training for multi-document summarization.
+Andrew Yates, Rodrigo Nogueira, and Jimmy Lin. 2021. Pretrained transformers for text ranking: Bert and beyond. In Proceedings of the 14th ACM International Conference on Web Search and Data Mining, WSDM '21, page 1154-1156, New York, NY, USA. Association for Computing Machinery.
+Manzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie, Chris Alberti, Santiago Otanon, Philip Pham, Anirudh Ravula, Qifan Wang, Li Yang, et al. 2020. Big bird: Transformers for longer sequences. volume 33.
+Jingqing Zhang, Yao Zhao, Mohammad Saleh, and Peter J. Liu. 2020. Pegasus: Pre-training with extracted gap-sentences for abstractive summarization. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event, volume 119 of Proceedings of Machine Learning Research, pages 11328-11339. PMLR.
+Tianyi Zhang*, Varsha Kishore*, Felix Wu*, Kilian Q. Weinberger, and Yoav Artzi. 2020. *Bertscore: Evaluating text generation with bert.* In International Conference on Learning Representations.
+Wei Zhao, Maxime Peyrard, Fei Liu, Yang Gao, Christian M. Meyer, and Steffen Eger. 2019. MoverScore: Text generation evaluating with contextualized embeddings and earth mover distance. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 563-578, Hong Kong, China. Association for Computational Linguistics.
+
+# A Appendix
+
+# Context: How to straighten a curly wig?
+
+It is the best method for both straightening and curling a wig. It is also the best method for synthetic wigs that may be more delicate to heated styling tools.
+
+Allow the hair to fall straight down without resting on anything. Tripods work brilliantly if you fit a mannequin head on them.
+
+Boil about 1.5L for a long wig and 1L or less for a short wig. The heat of the water will soften the plastic fibers and will pull them down. Use a wide soft-bristled brush. For extremely curly wigs, it will take more than one treatment and a lot of time. It does no damage to the wig and can be done while the wig is still wet. This is a permanent style; you will need to re-curl the wig if you don't want it straight anymore. You're basically remolding plastic into a new shape, so will need to mold it back if you want the curls again.
+
+# Output Summaries:
+
+Human : consider trying the hot water method. place the wig on a stand. boil a pot full of water. pour it carefully over the wig, making sure that it completely covers it. avoid combing or brushing a wig when it is wet. wait until it is dry. repeat the method if necessary.
+
+Finetune: use this method for very curly wigs. place the wig on a flat surface. boil water in a large pot. remove the pot from the heat and allow the water to cool. brush the wig with a wide-bristled brush. repeat the process until the entire wig is straight. curl the wig if you don't want it straight anymore.
+
+Prefixtune: understand the benefits of this method. lay the wig flat on a flat surface. boil a small amount of water. brush the wig with a soft-bristled brush. repeat the process if necessary. re-curl the wig if desired. finished.
+
+HSoftSA: use this method if you want to straighten the wig. place the wig on a mannequin head. boil a pot of water. brush the wig with a soft-bristled brush. repeat as needed. re-curl the wig if necessary.
+
+HierBlock: heat the water in a large pot over medium heat. put the wig in the pot and allow it to sit for a few minutes. remove the wig from the pot. brush the wig with a soft-bristled brush. repeat the process with the other wig.
+
+HierBlock+SoftSA: wash the wig with warm water. put the wig on a mannequin head. rinse the wig. brush the hair with a soft-bristled brush. repeat the process until the hair is completely straight. re-curl the wig if you want.
+
+Figure 6: Model Generated Output Text on Wikihow Dataset. The red colored text indicates factual errors, repetitions, and incoherent text.
+
+# A.1 Hyperparameters (Cont. from § 5)
+
+We fit our BART-LARGE models to their respective datasets with the hyperparameters shown in Table 8. Encoder/decoder block sizes indicate the size of the segments we split the input/output tokens. For instance, if the encoder block size is 2, we split the input tokens into two segments. Each segment has designated set of prefixes which can vary at each layer. In hierarchical blocking models
+
+| Parameter | Xsum | CNN/DM | PubMed | Wikihow | SAMSum | E2E | DART |
| learning rate | 5e-05 | 5e-05 | 5e-05 | 5e-05 | 5e-05 | 5e-05 | 5e-05 |
| # epochs | 30 | 30 | 30 | 30 | 20 | 10 | 10 |
| batch size | 8 | 8 | 8 | 8 | 16 | 16 | 16 |
| prefix-length | 100 | 50-100 | 100-200 | 100-200 | 10-20 | 5-10 | 5-10 |
| beamsize | 5 | 5 | 5 | 5 | 5 | 5 | 5 |
| Hierarchical Blocking |
| encoder block size | 1,2,3 | 1,2,3 | 1,2,3 | 1,2,3 | 1,2,3 | 1,2,3 | 1,2,3 |
| decoder block size | 1,2 | 1,2 | 1,2 | 1,2 | 1,2 | 1,2 | 1,2 |
| Sparse Attention |
| top-p | 95.% | 95.% | 95.% | 95.% | 95.% | 95.% | 95.% |
| τ(top-p) | 1.0,0.1 | 1.0,0.1 | 1.0,0.1 | 1.0,0.1 | 1.0,0.1 | 1.0,0.1 | 1.0,0.1 |
| τ(soft attn.) | 1.0,0.1,0.01 | 1.0,0.1,0.01 | 1.0,0.1,0.01 | 1.0,0.1,0.01 | 1.0,0.1,0.01 | 1.0,0.1,0.01 | 1.0,0.1,0.01 |
+
+Table 8: Hyperparameters of different prefix-tuned models.
+
+| Corpus | Version | License | Citation | Link |
| XSum | v1 | MIT | Narayan et al. (2018) | https://github.com/EdinburghNLP/XSum |
| CNN/DM | v1 | MIT | Hermann et al. (2015) | https://github.com/abisee/cnn-dailymail |
| PubMed | v1 | Creative Commons | Cohan et al. (2018) | https://github.com/armancohan/long-summarization |
| WikiHow | v1 | CC-BY-NC-SA | Koupae and Wang (2018) | https://github.com/mahnazkoupae/wikiHow-Dataset |
| SAMSum | v1 | CC BY-NC-ND 4.0 | Gliwa et al. (2019) | https://github.com/giancolu/Samsung-dataset |
| E2E | v1 | CC4.0-BY-SA | Dušek et al. (2019) | https://github.com/tuetschek/e2e-cleaning |
| DART | v1 | MIT | Nan et al. (2021) | https://github.com/Yale-LILY/dart |
+
+Table 9: Additional documentation of scientific artifacts used in our paper.
+
+(HierBlock) we segment the lower layers, so the prefixes are blocked for different segments, while at the top layers no segmentation or blocking is applied. We use at most two segments in the output text since the text generations tasks we investigate in this work contain much shorter output tokens compared to the input tokens.
+
+Gumbel Softmax Reparameterization Trick: Sampling introduces discrete valued parameters which are not differential at training time. Thus, we resort to the GumbelSoftmax trick (Jang et al., 2016), which provides a tool for sampling from a continuous approximation of a discrete distribution. The Gumbel-Softmax trick considers a discrete variable with class probabilities $\pi_1,\dots ,\pi_k$ and draws samples $g_{1},\dots,g_{k}$ from a Gumbel distribution, Gumbel(0,1), as follows:
+
+$$
+y = \frac {\exp \left(\left(\log \left(\pi_ {i}\right) + g _ {i}\right) / \tau\right)}{\sum_ {j = 1} ^ {k} \exp \left(\left(\log \pi_ {j} + g _ {j}\right) / \tau\right)} \tag {4}
+$$
+
+for $i = 1,\dots ,k$ . The Gumbel(0,1) distribution can be sampled using inverse transform sampling by drawing $u\sim \mathrm{Uniform}(0,1)$ and computing $g = -\log (-\log (u))$ . Plugging in the samples $g_{i}$ and the class probabilities $\pi_{i}$ in Eq.4, we generate a $k$ -dimensional sample vector $y\in \triangle^{k - 1}$ , that is the continuous approximation of the one-hot-encoded representation of the discrete variable $d$ . In fact, as $\tau$ approaches 0, samples from the Gumbel-Softmax distribution become one-hot, making it discrete.
+
+For more details please refer to (Jang et al., 2016).
+
+# A.2 Dataset Details (Cont. from §5)
+
+All datasets are in English language. The summarization datasets range from extreme abstractive summarization with XSum (Narayan et al., 2018) to summarize documents into one summary sentence, conversational summarization using SAM-Sum dataset (Gliwa et al., 2019), long clinical document summarization with PubMed (Cohan et al., 2018) $^{5}$ and DIY domain with Wikihow (Koupaee and Wang, 2018), and commonly used CNN/DM (Hermann et al., 2015; See et al., 2017) news article summarization dataset with an "Inverted Pyramid" (PurdueOWL, 2019) document structure (Kryscinski et al., 2019). We also investigate S2T datasets on customer reviewers including E2E (Novikova et al., 2017; Dušek et al., 2019) and DART (Nan et al., 2021) with each input being a semantic RDF triple set derived from data records in tables and sentence descriptions that cover all facts in the triple set.
+
+XSum (Narayan et al., 2018) is a collection of 227k BBC News articles ranging from 2010 to 2017. The dataset covers a wide range of subjects. The single-sentence summaries are written by pro
+
+fessionals.
+
+CNN/DailyMail (Hermann et al., 2015) dataset contains 93k news articles extracted from CNN News, and around 220k articles extracted from the Daily Mail newspapers. The summaries are human written bullet point text which are provided in the same source documents. In our experiments we use the non-anonymized version, which is commonly used in summarization research papers.
+
+PubMed (Cohan et al., 2018) is a long document dataset of 215K scientific publications from PubMed. The task is to generate the abstract from the paper body.
+
+WikiHow (Koupaee and Wang, 2018) is a large-scale dataset of 200K instructions from the online WikiHow.com website. Each instance consists of multiple instruction-step paragraphs and an accompanying summary sentence of each paragraph. The task is to generate the concatenated summary-sentences from the paragraphs.
+
+SAMSUM (Gliwa et al., 2019) is a multi-turn dialog corpus of 16K chat dialogues and manually annotated summaries. The task is to generate an abstractive summary of the dialog with coherent discourse structure of the original dialog.
+
+E2E (Dušek et al., 2019) is a structured data to natural language summary dataset that provides information about restaurants. The structured inputs consists of different attributes (slots) such as name, type of food or area and their values. It contains 50K instances of diverse descriptions of the structured input introducing challenges, such as open vocabulary, complex syntactic structures and diverse discourse phenomena.
+
+DART (Nan et al., 2021) is a text generation dataset for open-domain structured data-record to text generation. It consists of 82K examples from variety of domains. The inputs are in semantic RDF triple set form which are derived from data records in tables and tree ontology of the schema. The output generations are human annotated with sentence descriptions that cover all facts in the triple set.
+
+Licence details In our experiments, we use several datasets (as detailed above) from public resources. Table 9 summarizes the licences. All data are solely used for research purposes.
+
+# A.3 Compute Infrastructure and Run time
+
+Each experiment runs on a single machine with 8 GPUs. Depending on the training dataset size, summarization models require from 5.5 hours to 18 hours to train. The data-to-text datasets are much smaller which takes less than 4 hours. All finetuned models follow the BART-large transformer architecture with a total of 12 layers, 1024 hidden dimensions, and 406M parameters. The prefix-models increase the parameters size of fine-tune models by $0.1\%$ up to $2\%$ depending on the number of prefix parameters. See hyperparameters details in Appendix A.1.
+
+# A.4 Visualization of Prefix Parameters (Cont. from $\S 4$
+
+To analyze the attention behaviour (similar to (Sun and Lu, 2020)) we plot the attention matrix of the prefix-tuned models focusing on the prefix parameters. We use a prefix-tuned BART-LARGE (12-layer stacked transformer) on two tasks: data-to-text generation on E2E (Dušek et al., 2019) and summarization on CNN/DM (Hermann et al., 2015). In Figure 7, we plot the encoder self-attention distributions $A$ for different layers averaging over head vectors. The $x$ -axis represent the keys, while $y$ -axis denote the queries.
+
+# A.5 Are All Prefix Parameters Useful? (Cont. from § 6.1)
+
+We investigate the influence of prefix parameters on different layers of the network. For this experiments we trained BART-LARGE and add prefix parameters only at the top layers, lower layers and all layers (this is same as baseline prefix-tuning models). On XSum dataset, we observed a large performance gap between the models trained with top/ lower layers, while we obtain the best performance when we tune all-layer prefix parameters (in Table 3 in the main text). Here, we investigate if similar performance gains are observed on dialog summarization (SAMSum) and data to text generation (E2E) tasks.
+
+We show the performance scores of our experiments on validation datasets in Table 11. We observe similar results as the analysis on XSum dataset. Top layers prefix parameters learn salient features related to the task, though using prefixes at all layers yields better performance.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+Figure 7: Encoder self-attention matrices $A$ of prefix-tuned models indicating the query attention scores over all keys (prefix+inputs) on the y-axis. The scores are averaged over all heads. The left block is for E2E dataset where the first 10 features represent prefix features, while CNN/DM dataset on the right with first 100 features represent the prefixes.
+
+
+
+
+
+
+
+
+
+
+
+| Method | E2E | DART |
| #Parm. | BLEU | NIST | MET | R-L | CIDEr | BLEU | MET | TER ↓ | Mover | BERT |
| GPT-2-Large |
| Finetune (*) | 774M | 68.5 | 8.78 | 46.0 | 69.9 | 2.45 | 47.0 | 0.39 | 0.46 | 0.51 | 0.94 |
| Prefixtune (*) | 774M+%0.1 | 70.3 | 8.85 | 46.2 | 71.7 | 2.47 | 46.7 | 0.39 | 0.45 | 0.51 | 0.94 |
| BART-Large |
| Finetune | 406M | 67.8 | 8.76 | 45.1 | 69.5 | 2.38 | 46.1 | 0.38 | 0.46 | 0.53 | 0.95 |
| Prefixtune | 406M+%0.1 | 67.3 | 8.66 | 44.8 | 68.6 | 2.34 | 45.9 | 0.39 | 0.45 | 0.53 | 0.95 |
| Uniblock | 406M+%0.1 | 66.1 | 8.60 | 45.0 | 68.3 | 2.36 | 46.5 | 0.39 | 0.46 | 0.53 | 0.95 |
| HierBlock | 406M+%0.1 | 67.2 | 8.70 | 45.1 | 69.1 | 2.35 | 46.6 | 0.39 | 0.45 | 0.54 | 0.95 |
+
+Table 10: Data-to-Text: Prefix-Blocking Models compared against Finetune and Prefixtune models. (*) Top block are best reported numbers in (Li and Liang, 2021) using GPT-2 LARGE model, twice the size of BART-LARGE. Bottom block are our experiment results. Best results on GPT-2 and BART-LARGE models are bolded separately and second best BART-LARGE models are further underlined. For all the prefix-tuned BART models, the prefix-length is 5 for E2E and 10 for DART dataset. All hyper-parameters are summarized in Appendix Table 8.
+
+| Method | SAMSum | E2E |
| R1/R2/RL | BLEU/RL |
| Top (8-12) | 49.55/23.72/42.16 | 64.3/65.7 |
| Low (1-7) | 43.16/19.08/38.14 | 62.4/62.6 |
| All (1-12) | 50.16/25.03/43.16 | 65.4/66.5 |
+
+Table 11: Results of prefix-tuned models on validation datasets of SAMSum (from the summarization task) and E2E (from the structure to text task) using only the top/low layers.
+
+# A.6 Investigation of Hierarchical Prompt Design (Cont. from § 6.2)
+
+We investigate if blocking prefixes helps for data-to-text tasks. Table 10 shows the results. Similar to summarization experiments in § 6.2, we observe improvements with hierarchical blocking on E2E dataset, though the improvement is minimal in DART dataset. We include previous best model results reported in (Li and Liang, 2021). Their results are from GPT-2 LARGE, which is twice the size of BART-LARGE models, so our results are slightly lower. We replicated the fine-tuning and prefixtun
+
+ing results for fair comparison (top two rows of the bottom block in Table 10. We also provide the model sizes in terms of number of parameters. We conclude from these results that the prefix models tuned with structurally biased additional set of parameters can yield more robust information transfer reaching as good as finetuning models. In Figure 6 we show the output summaries generated by some of our best discourse aware prefix-tuned models in comparison to baseline fine-tuned and prefix-tuned models.
+
+# A.7 Investigation of the Impact of Sparsity (Cont. from § 6.3)
+
+Spectrum Analysis: We conduct spectrum analysis of the encoder attention matrix $\mathbf{A}$ zooming in on the prefix parameters to investigate if our sparse models do in fact learn sparse representations. A similar spectrum analysis has been used to prove the sparsity of the attention matrix in Linformer (Wang et al., 2020), a sparse transformer. Our goal
+
+| Method | XsumR1/R2/R-L | CNN/DMR1/R2/R-L | PubMedR1/R2/R-L | WikipowR1/R2/R-L | SAMSumR1/R2/R-L |
| Finetune |
| Dense (reproduce) | 45.47/22.40/37.42 | 44.30/21.14/41.22 | 45.09/19.56/27.42 | 43.26/19.38/34.89 | 53.02/28.30/48.73 |
| (1) TruncSA | 45.17/21.98/37.02 | 43.02/20.03/39.96 | 41.08/17.02/26.37 | 44.85/20.00/35.58 | 52.45/27.56/48.12 |
| (2) SoftSA | 45.34/22.02/37.23 | 42.97/20.44/39.67 | 40.15/16.30/26.26 | 41.56/17.80/32.53 | 52.47/27.88/48.45 |
| Prefix-tune |
| Dense (reproduce) | 43.43/20.37/35.47 | 42.50/19.52/39.08 | 42.38/16.31/24.57 | 39.26/15.58/28.27 | 52.12/26.52/48.05 |
| (1) TruncSA | 43.56/20.62/35.96 | 42.80/19.81/39.52 | 42.50/16.85/25.61 | 39.43/15.69/28.94 | 52.09/27.49/47.88 |
| (2) SoftSA | 43.80/20.82/35.94 | 42.25/19.50/39.24 | 42.90/16.95/25.72 | 39.31/15.61/28.94 | 51.72/25.51/47.35 |
| (3) HTruncSA | 44.17/21.11/36.42 | 43.17/20.17/40.00 | 43.30/17.00/25.28 | 40.00/16.11/30.02 | 52.12/26.94/48.00 |
| (4) HSoftSA | 44.05/20.84/36.13 | 43.10/20.06/39.83 | 42.30/16.20/24.90 | 39.83/16.10/30.01 | 52.37/27.57/48.33 |
+
+Table 12: Summarization: Sparse Attention experiment results on Finetuning, and Prefix-tuning with Truncated (TruncSA) and Bernoulli Sampling soft attention (SoftSA) and Hierarchical Truncated (HTruncSA) and Soft Attention (HSoftSA) for Prefix-Tuning. All models are based on BART-LARGE. Best finetune results (top block) across models are bolded while the best prefix-tune models (bottom block) are further underlined. All hyper-parameters are summarized in Appendix Table 8.
+
+| Method | E2E | DART |
| #Parm. | BLEU | NIST | MET | R-L | CIDEr | BLEU | MET | TER ↓ | Mover | BERT |
| Finetune (repr.) | 406M | 67.8 | 8.76 | 45.1 | 69.5 | 2.38 | 46.1 | 0.38 | 0.46 | 0.53 | 0.95 |
| Prefixtune (repr.) | 406M+%0.1 | 67.3 | 8.66 | 44.8 | 68.6 | 2.34 | 45.9 | 0.39 | 0.45 | 0.53 | 0.95 |
| HSoftSA | 406M+%0.1 | 66.2 | 8.57 | 45.0 | 68.7 | 2.33 | 46.2 | 0.39 | 0.45 | 0.53 | 0.95 |
| HierBlock+SoftSA | 406M+%0.1 | 68.0 | 8.76 | 45.3 | 69.6 | 2.38 | 46.0 | 0.39 | 0.46 | 0.53 | 0.95 |
+
+Table 13: Data-to-Text: Hierarchical Sparse Attention Models compared against Finetune and Prefixtune models (repr=reproduced). All models use BART-Large as backbone and best models are bolded and second best are further underlined. For all the prefix-tuned models, the prefix-length is 5 for E2E and 10 for DART dataset. All hyper-parameters are summarized in Appendix Table 8.
+
+is to analyze the principal components of the subspace that captures the variation of the attention scores in prefix parameters. The eigenvalues capture the variation of the attention scores distribution along different principal components. The higher the elbow in the spectrum graph, the less parameters are used and the model learns to represent the inputs with only the salient terms ignoring superfluous details.
+
+For our spectrum analysis, we compare the baseline prefix-tuning, which encodes a dense attention matrix everywhere in the network (Dense PT) against one of our sparse prefix-tuned models with truncated attention matrix (Sparse PT), as we explained in § 4.2-(a), using top- $p$ sampling. Both models are a 12-layer stacked transformer (BART-LARGE) trained on XSum extreme summarization task. We apply singular value decomposition into $\mathbf{A}$ across different layers and different heads of the model, and plot the normalized cumulative singular value averaged over 1000 sentences. We compare the models' sparsity patterns at the top and at the lower layers separately as shown in Figure 4. The two figures exhibit a long-tail spectrum distribution across layers and heads. This implies that most of the information of matrix $\mathbf{A}$ can be recovered from the first few largest singular values. We observe that the spectrum distribution in lower layers
+
+is more skewed than in higher layers, meaning that, in lower layers, more information is concentrated in the largest singular values and the rank of $\mathbf{A}$ is lower. With sparse attention at the lower layers and dense attention at the top layers, the prefix-tuned models can encode salient features controlling the generation.
+
+Sparsity Analysis: In Table 12 we show the ROUGE-1, ROUGE-2 and ROUGE-L scores of fine-tuned and prefix-tuned summarization models comparing dense and sparse attention impact. We observe that when sparsity is used on the prefix-parameters, the prefix-tuned models outperform dense counterparts. The performance improvements are more pronounced on shorter generation tasks such as XSUM but we still see improvements reaching up to 2.0 ROUGE-L score improvements on longer documents such as Wikihow. Similar performance patterns are observed in Table 13 on data-to-text generation tasks using E2E and DART.
+
+# A.8 Investigation of the Impact of Sparsity on Hierarchically Linked Prefixes (Cont. from § 6.4)
+
+In Table 12 we showed ROUGE-L results of our hierarchical prefix blocking (HierBlock) model against hierarchical prefix blocking model with soft sparse attention (HierBlock+SoftSA). We observe
+
+| Criteria | Prefixtune wins | HierBlock wins | same | Prefixtune wins | HSoftSA wins | same | Prefixtune wins | HierBlock+SoftSA wins | same |
| factuality | 36 | 36 | 78 | 25 | 45 | 80 | 39 | 38 | 73 |
| relevance | 31 | 29 | 90 | 20 | 39 | 91 | 27 | 33 | 90 |
| grammaticality | 26 | 28 | 96 | 24 | 24 | 102 | 28 | 20 | 102 |
| coherence | 32 | 32 | 86 | 28 | 37 | 85 | 32 | 29 | 89 |
| overall | 40 | 38 | 72 | 30 | 49 | 71 | 41 | 38 | 71 |
| Criteria | HierBlock wins | HSoftSA wins | same | HierBlock wins | HierBlock+SoftSA wins | same | HSoftSA wins | HierBlock+SoftSA wins | same |
| factuality | 28 | 42 | 80 | 28 | 42 | 80 | 35 | 41 | 74 |
| relevance | 25 | 34 | 91 | 23 | 35 | 92 | 31 | 32 | 87 |
| grammaticality | 18 | 35 | 97 | 26 | 23 | 101 | 26 | 19 | 105 |
| coherence | 18 | 44 | 88 | 34 | 30 | 86 | 35 | 27 | 88 |
| overall | 28 | 48 | 74 | 32 | 44 | 74 | 38 | 38 | 74 |
| Criteria | Finetune wins | HierBlock wins | same | Finetune wins | HierBlock+SoftSA wins | same | | | |
| factuality | 48 | 39 | 63 | 44 | 42 | 64 | | | |
| relevance | 37 | 40 | 73 | 31 | 47 | 72 | | | |
| grammaticality | 38 | 24 | 88 | 43 | 17 | 90 | | | |
| coherence | 45 | 32 | 73 | 46 | 30 | 74 | | | |
| overall | 45 | 49 | 56 | 39 | 49 | 62 | | | |
+
+Table 14: Head-to-Head comparison of human evaluations on random subset of Wikihow dataset.
+
+improvements on performance on most summarization tasks including news summarization (XSum and CNN/DM), dialog summarization (SAMSum). We find that HierBlock+SoftSA models show much larger improvements on XSUM and Wikihow summarization, from +0.5 to close to 2 ROUGE-L scores. On the structure to text generation tasks the sparsity on hierarchical blocking helps on some datasets (with E2E), though both HierBlock and HierBlock+SoftSA perform better than the baseline prefix-tuning models (see Table 13).
+
+# A.9 Automatic Evaluations (Cont. from § 5)
+
+For model evaluations we use ROUGE-1/2/L using Python rouge-score 0.0.4 version licensed under the Apache 2.0 License. We use the default ROUGE script rouge.py from the GEM evaluation shared task. All other metrics are adopted from their linked corresponding papers. We use the official evaluation script for BLEU (Papineni et al., 2002), METEOR (Lavie and Agarwal, 2007), NIST (Belz and Reiter, 2006) TER (Snover et al., 2006), MoverScore (Zhao et al., 2019), BERTScore (Zhang* et al., 2020).
+
+# A.10 Human Evaluations (Cont. from § 6.5)
+
+We perform human evaluations to establish that our model's ROUGE improvements are correlated with human judgments. We compare the generations from four models: baseline prefix-tune (PT), Hierarchically blocked PT (HierBlock/HB), Hierarchical Soft Sparse Attention PT (HSoftSA) and the ensemble of the blocked sparse model (HierBlock+SoftSA). We use the following as eval
+
+uation criteria for generated summaries, which we include in the instructions for the annotators.
+
+Faithfulness: Are the details in the summary fully consistent with the details in the source document? The summary must not change any details from the source document. The summary also must not hallucinate any information that is not in the source document.
+
+Relevance: Does the summary capture the key points of the text? Are only the important aspects contained in the summary? Is there any extra/irrelevant information?
+
+Grammaticality: Considers the grammatical quality of each individual sentence in the summary. For each sentence, does it sound natural and grammatically correct?
+
+Coherence: Does the summary form a cohesive, coherent whole? Is it well-written, well-structured and well-organized? Is it easy to follow? It should not be a heap of related information, but should build from sentence to sentence to a coherent body of information about a topic.
+
+Overall Quality: Given the input context, is the summary satisfactory? Does the summary provide good quality information to the user? Is it helpful, informative and detailed enough given the information that's contained in the text? Which summary of the two do you prefer best overall?
+
+Annotator Details: Human annotation was conducted by 9 professional raters (7 linguist raters, 1
+
+linguist subject-matter-expert and 1 linguist) employed by an outsourcing company handling content moderation. All raters are monolingual native speakers of English; 6 have a minimum of high school degree or equivalent and 3 have a bachelor's degree. Raters received compensation starting at \(18 per hour (which is close to 2.5 minimum wage in the state where the raters are located) and were also provided with Premium Differential as part of their contracts. Each rater conducted between 44 and 175 pairwise evaluations. Data collection protocol was reviewed by expert reviewers and received expedited approval as the data presented to the raters did not contain any sensitive or integrity-violating content. Participant consent was obtained as part of the non-disclosure agreement signed by each rater employee upon hire. All raters have also signed a sensitive content agreement that outlined the types of content they may encounter as part of their employment, associated potential risks and information and wellness resources provided by the outsourcing company to its employees.
+
+Human Evaluation Procedure: We randomly select 50 samples from the Wikihow test set and ask 9 trained judges to evaluate them on the 5 criteria defined above. We perform head-to-head evaluation (more common in DUC style evaluations), where judges are shown the original document, the ground truth summary and two model summaries in random order. The judges are then asked to compare two model summaries based on each of the five criteria. In each case, a judge either has the option to choose a model summary that ranks higher on a given criterion (i.e., respond by identifying the winning summary), or assert that both summaries are similar given the criterion and rate the comparison as "same". The evaluation of each pair of summaries across all 5 criteria takes on average between 5 and 10 minutes to complete. The raters were shown the data to be rated in a spread sheet, where each line contained multiple columns in sequence: document, human written summary, model-A generated summary, model-B generation summary, and five additional columns indicating faithfulness, relevance, grammaticality, coherence, overall quality. The headers of the columns were clearly stated. The rates enter a/b/same in each corresponding cell when comparing summaries head-to-head based on each criteria.
+
+
+
+
+
+
+(a) Average Rouge-1
+(b) Average Rouge-2
+(c) Average Rouge-L
+Figure 8: Quantitative analysis on low-resource settings. The charts show average of ROUGE-1, ROUGE-2, ROUGE-L scores from models trained on two summarization tasks: XSUM and Wikihow. Our structurally biased parameter tuned HierBlock (blue) and HierBlock+SA (red) consistently outperforms the baseline Finetuned (green) and Prefix-tuned models (olive) when $<50\%$ training data is used.
+
+Human Evaluation Results: In Table 14 we show head-to-head evaluation scores on all five metrics showing wins from each model as well as when both are selected as equal. Each sub-table compare a different model. Our Hierarchical Blocking (HierBlock) and Hierarchical Soft Sparse Attention (HSoftSA) models beat prefix-tuning and HierBlock significantly $(p < .05)$ beats most of our sparse models on all axes including factuality. In
+
+On a small data annotation, we also compare two of our best models HierBlock and HierBlock+SoftSA againts best finetuning model generations, which are shown in the same Table 14. We observe that in most cases both of our models are preferred as good as finetuning on all criteria, except on overall, the HierBlock summaries are ranked much higher than fine-tuning models.
+
+# A.11 Low-data settings (Cont. from § 6.6)
+
+In Figure 8, we plot the ROUGE-1, ROUGE-2 and ROUGE-L scores averaging scores from two summarization tasks (XSUM and Wikihow). Our structured prefix parameter tuned models, HierBlock (blue) and its sparse extension which uses sparse features, HierBlock+SA (red) outperforms Prefix-tuned models (olive), while using the same number of parameters in low resources settings (when
+
+<50% training samples are used). Both models outperform Finetuned models (green) on ROUGE-1 and ROUGE-2 metrics (Figure 8-(a)&(b)). While the HierBlock models show consistent performance, we conclude that on low-resource settings HierBlock-SA performance is more stable.
\ No newline at end of file
diff --git a/discourseawaresoftpromptingfortextgeneration/images.zip b/discourseawaresoftpromptingfortextgeneration/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..3ff05b0d672bf16e3e03f86adb4af3561061ff78
--- /dev/null
+++ b/discourseawaresoftpromptingfortextgeneration/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6c44e07ef8c377be8deda49e61f24cafdf56df051f685f361f213751d1fe548c
+size 949161
diff --git a/discourseawaresoftpromptingfortextgeneration/layout.json b/discourseawaresoftpromptingfortextgeneration/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..fa10ef39de4f69fd226ba40fadb307690dcce31a
--- /dev/null
+++ b/discourseawaresoftpromptingfortextgeneration/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1ec42a22f66a4079a858b5cb71a942e4c4c75669d15fe0a27fcd0acc9055404a
+size 634181
diff --git a/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_content_list.json b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..9c16e20186e08c3247a3fc1808f3bd2ef03423b5
--- /dev/null
+++ b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e1411da2aecd89003cd1e367d1b012cff11409f76171a21d0076262c59d286b0
+size 99271
diff --git a/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_model.json b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..cffa4a29155d9688a8ec12951da025a558f1376c
--- /dev/null
+++ b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:66b7ff5cc5985e2efd004a060d1dfab92a8d31857b10d2946f143e4d64d72c7a
+size 119006
diff --git a/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_origin.pdf b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..9eb2aca6c41c293f9c26c46e04bfc3b4568e78a1
--- /dev/null
+++ b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/9211249e-cf13-4a7c-826f-e94880ddee7c_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:438fb054797d7cd237a04be762e8af8090751c06aa9786becd93fd04bf48e2d8
+size 668481
diff --git a/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/full.md b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..ab76653bf95a7d12abaced74a1affd6a25b2eafe
--- /dev/null
+++ b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/full.md
@@ -0,0 +1,425 @@
+# Discourse Comprehension: A Question Answering Framework to Represent Sentence Connections
+
+Wei-Jen Ko $^{1}$ Cutter Dalton $^{2}$ Mark Simmons $^{3}$ Eliza Fisher $^{4}$ Greg Durrett $^{1}$ Junyi Jessy Li $^{4}$
+
+1 Computer Science, 4 Linguistics, The University of Texas at Austin
+
+$^{2}$ Linguistics, University of Colorado Boulder
+$^{3}$ Linguistics, University of California San Diego
+
+wjko@utexas.edu, cutter.dalton@colorado.edu, mjsimmons@ucsd.edu, eliza.fisher@utexas.edu,
+
+gdurrett@cs.utexas.edu, jessy@utexas.edu
+
+# Abstract
+
+While there has been substantial progress in text comprehension through simple factoid question answering, more holistic comprehension of a discourse still presents a major challenge (Dunietz et al., 2020). Someone critically reflecting on a text as they read it will pose curiosity-driven, often open-ended questions, which reflect deep understanding of the content and require complex reasoning to answer (Ko et al., 2020; Westera et al., 2020). A key challenge in building and evaluating models for this type of discourse comprehension is the lack of annotated data, especially since collecting answers to such questions requires high cognitive load for annotators. This paper presents a novel paradigm that enables scalable data collection targeting the comprehension of news documents, viewing these questions through the lens of discourse. The resulting corpus, DCQA (Discourse Comprehension by Question Answering), captures both discourse and semantic links between sentences in the form of free-form, open-ended questions. On an evaluation set that we annotated on questions from Ko et al. (2020), we show that DCQA provides valuable supervision for answering open-ended questions. We additionally design pretraining methods utilizing existing question-answering resources, and use synthetic data to accommodate unanswerable questions.
+
+# 1 Introduction
+
+Research in question answering has pushed machine comprehension to new heights, especially in answering factoid questions (e.g., SQuAD (Rajpurkar et al., 2018) and Natural Questions (Kwiatkowski et al., 2019)) and even questions that require multiple steps of reasoning (Yang et al., 2018). Yet while existing systems are effective at sifting through a long document to find a fact, they fail to achieve what we consider *discourse comprehension*. Deep comprehension of
+
+[S1] A night of largely peaceful protests ended early Monday in a bloody clash between Muslim Brotherhood supporters and Egyptian soldiers.
+
+# Q1 What happened before the clash?
+
+... [S10] Hours earlier, Egypt's new interim leadership had narrowed in on a compromise candidate to serve as the next prime minister.
+[S11] ...Egyptian media reported that the new frontrunner is Ziad Bahaa El-Din, a founding member of the Egyptian Social Democratic Party.
+
+# Q2 What is El-Din's history?
+
+# Q3 How does El-Din compare to his competitors?
+
+[S12] El-Din is an attorney and former parliament member who previously served as an economic adviser, financial regulator and head of Egypt's General Authority for Investment under the government of deposed President Hosni Mubarak.
+[S13] El-Din is seen as a less divisive choice than secular opposition leader Mohamed ElBaradei, whose nomination was abruptly blocked a day earlier.
+
+
+
+
+
+
+Figure 1: Discourse comprehension involves making high level inferences across sentences, often in the form of open-ended questions. This is an example from our dataset DCQA.
+
+a discourse requires establishing temporal and semantic relationships across abstract concepts in various parts of a document (Hobbs, 1985), going beyond understanding the individual pieces of knowledge conveyed or the details of events (Wegner et al., 1984). The gap between existing QA frameworks and discourse comprehension has been highlighted in recent work. Dunietz et al. (2020) emphasized the lack of narrative understanding capability in existing machine reading comprehension systems and benchmark datasets. Recent research (Ko et al., 2020; Westera et al., 2020) demonstrated that human reading comprehension is marked by the spontaneous generation of open-ended questions anchored in one part of an article; some of these questions are later answered in the article itself, forming a connection in the discourse (Figure 1). Ko et al. (2020) showed that compared to existing QA datasets, these questions are products of higher-level (semantic and discourse) processing (e.g., "how" and "why" questions) whose answers are typically complex linguistic units like whole sentences. Such reader-generated questions are far out of reach from the capabilities of systems trained
+
+
+Figure 2: DCQA framework. During data collection, an annotator writes down what question a particular sentence answers and which previous sentence it arose from (i.e., its anchor point). During QA, an annotator or an automatic system sees that question attached to the prior sentence, and has to find the answer in the remainder of the document.
+
+on current QA datasets.
+
+This view of discourse comprehension falls within the linguistic framework of Questions Under Discussion (QUD) (Velleman and Beaver, 2016; De Kuthy et al., 2018), where discourse progresses by continuously evoking implicit or explicit questions and answering them. The open-endedness of these questions is triggered by readers' psychological mechanisms including corrections of knowledge deficits and active monitoring of the common ground (Graesser et al., 1992). These fundamental differences in how questions are constructed from existing, mostly factoid QA datasets lead to difficulty spotting answers with keyword or paraphrastic overlaps. Additionally, the questions are contextualized, as they rely on an established common ground and the anchor point.
+
+Collecting question-answer pairs that target discourse comprehension entails a high cognitive load for human annotators. Consequently, existing resources designed to train models to answer such questions are scarce. Westera et al. (2020) introduced TED-Q, a smaller dataset covering 6 TED talks, including 1102 answered questions. Ko et al. (2020)'s INQUISITIVE dataset consists of more (19k) questions evoked under the QUD paradigm, yet they did not annotate answers.
+
+We present DCQA (Discourse Comprehension by Question Answering), a dataset of 22,394 English question-answer pairs distributed across 606 English news articles (Figure 2). We view DCQA as a key resource to train QA systems to answer discourse-driven, contextual, and open-ended questions as those in INQUISITIVE. On its own, DCQA is a discourse framework that represents connections (or relationships) between sentences via freeform questions and their answers.
+
+DCQA uses a novel crowdsourcing paradigm inspired by QUD recovery (De Kuthy et al., 2018; Riester, 2019): instead of collecting the answer labels given the question, we start from an answer sentence and collect the question. Specifically, for each sentence in an article, annotators ask a question that reflects how the main purpose of the sentence connects to an anchor sentence in prior context, such that the sentence is the answer to the question. This paradigm is scalable while maintaining a diverse range of open-ended question types, a varied distribution of distance between question anchor and answers, and the ability to capture interesting linguistic phenomena. We further demonstrate that annotating answers given the questions is much more subjective and challenging.
+
+We present two experiments using DCQA. We first evaluate a model's ability to extract the correct sentence to answer questions in DCQA. Our Longformer (Beltagy et al., 2020) baseline achieves $67\%$ accuracy, doing well in light of human performance of $72.2\%$ . However, the model struggles much more than humans do when the answer sentence is further away from the question anchor point.
+
+Our main experiment evaluates whether DCQA can be used to train systems to answer questions such as those in INQUISITIVE, where the questions are asked without seeing any upcoming context that may contain answers. To enable evaluation over INQUISITIVE, we collect a human-annotated test set. We find that existing datasets, including SQuAD, QuAC, ELI5, and TED-Q, yield poor accuracy (1.4% to 25%) on extracting answer sentences for the answerable questions in INQUISITIVE. In contrast, training on DCQA leads to a performance of 40.8%. We further design ways to enable pretraining using SQuAD and ELI5, which leads to
+
+significant performance improvements. Finally, we present a pipeline system for question-answering that handles unanswerable questions utilizing synthetic data. $^{1}$
+
+# 2 Background and related work
+
+Discourse and question answering. Discourse theories profile the relationships between linguistic units in a document that make it coherent and meaningful; these relations could be temporal, causal, elaborative, etc. (Mann and Thompson, 1988; Lascarides and Asher, 2008; Prasad et al., 2008). Most of these theories define fixed relation taxonomies, which have been viewed as templatic question (Prasad and Joshi, 2008; Pyatkin et al., 2020). In contrast, QUD makes use of free-form questions to represent discursive relationships (Riester, 2019); each utterance in a text builds on the reader's common ground and can evoke questions; each utterance is also an answer to an implicit (or explicit, if present) question.
+
+INQUISITIVE (Ko et al., 2020) is a collection of such curiosity-driven, QUD-style questions generated by readers as they read through a document (i.e., asking questions on-the-fly without seeing any upcoming context); specifically, 19K questions for the first 5 sentences across 1500 news documents from three sources: Newsela (Xu et al., 2015), WSJ articles from the Penn Treebank (Marcus et al., 1993), and Associated Press (Harman and Liberman, 1993). Each question is attached to a span in the current sentence the reader is reading, e.g.,
+
+... It's an obvious source of excitement for Doyle, who is 27 years old and has severe autism.
+
+Q: Why is this important?
+
+One major motivation of DCQA is to train models to answer these questions. Thus as opposed to creating a "challenge dataset", we are mainly exploring more scalable ways for data collection.
+
+TED-Q (Westera et al., 2020) is also a QUD dataset annotating questions and answers simultaneously over 6 TED talk transcripts. In contrast, we propose a data collection paradigm that works from the answers back to the context for lower cognitive load and higher scalability. Also, all answers from TED-Q are within 5 sentences after the question anchor, which is not the case in our dataset.
+
+Open-ended question answering. While there are many datasets for question answering, most
+
+of them are factoid in nature (Rajpurkar et al., 2018; Kwiatkowski et al., 2019). Ko et al. (2020) found that the question types are so different that pre-training on factoid questions hurts the performance of generating open-ended questions. Fan et al. (2019) collected human-written answers for their open-ended "ELI5" questions, but the questions and answers are not grounded in a document context. QuAC (Choi et al., 2018) introduces information-seeking question-answer pairs given context in dialogue; in contrast DCQA aims to represent discursive and semantic links that cover the full document. Also QuAC questions are conditioned on previous dialogue turns, which is not the case in DCQA. Soleimani et al. (2021) collected paragraphs with a subheading that is a question from news articles, so the whole paragraph can be seen as the answer to the question. However, more than $86\%$ of the time in INQUISITIVE (Section 6.1), and $99\%$ for TED-Q, the answers to naturally generated open-ended questions consist of one sentence in the text. By more precisely locating the answers, DCQA also establishes finer-grained connections within a document.
+
+# 3 The DCQA dataset
+
+We present DCQA using a new data collection paradigm that describes how sentences in an article relate to prior context; specifically, what question is the current sentence answering given its prior context, inspired by literature in QUD discovery (De Kuthy et al., 2018; Riester, 2019).
+
+We annotate news documents due to their rich linguistic structure that mixes narratives, different lines of events, and perspectives from parties involved (Van Dijk, 2013; Choubey et al., 2020).
+
+# 3.1 Annotation paradigm
+
+We design a crowdsourcing task, illustrated in Figure 2. At a high level, data collection consists of two simultaneous tasks: question generation given an answer sentence, and question linking that places the question in a precise anchor point in the document. Annotators start from the beginning of the article. For each new sentence, they write a question that reflects the main purpose of the new sentence and indicates how the new sentence elaborates on prior context. The new sentence is thus the answer to the question. Because the question should arise from one of the previous sentences in the article, the annotator also chooses which earlier
+
+
+Figure 3: Snippet of an annotated article: each sentence after the first is annotated with a question linked to an earlier sentence where it arises from (which we call the question's anchor sentence). Black arrows represent question generation; orange arrows represent question linking.
+
+sentence most naturally evokes the question (which we refer to as the question's "anchor" sentence).
+
+We instructed annotators to ask open-ended questions that require some explanation as an answer, instead of questions that could be answered simply by a place/person/time or yes/no. They are also told that when writing the question, they should assume that the question could be asked and understood by people only reading the earlier sentences, following the QUD framework and Ko et al. (2020); Westera et al. (2020). This means avoiding reference to any information first introduced in the new sentence and avoiding copying phrases only used in the new sentence. Reusing phrases from or referencing previous sentences is allowed.
+
+An example of the first 6 sentences of a fully-annotated article is shown in Figure 3, where we can see each sentence after the first is annotated with a question. For instance, sentence 4 mainly describes the trip of U.N. ambulances arriving, and it provides more detail on how the sick and wounded Muslims described in sentence 1 arrive.
+
+We illustrate the Question Answering task in the right pane of Figure 2. Given the anchor sentence and the question, the task is to extract a sentence in the upcoming context that would answer this question. Because the questions are contextual, they typically need to be associated with the anchor to be comprehensible (we illustrate the importance of identifying the anchor through model analysis in Section 5). Additionally, since we seek to answer questions that are generated during the natural progress of discourse, the questions presuppose the common ground established by the reader, which consists of all context up to the an
+
+chor sentence. (Because of this question generation paradigm, in DCQA, as well as INQUISITIVE and TED-Q, all answers to the questions are after the anchor sentence.) Thus the QA task is that given the context, anchor, and question, find the sentence that contains the answer. For example, S1 in Figure 3 evokes QA and QC, and the task is to find the answer sentences 2 and 4, respectively:
+
+[Context+Anchor]: In sign of hope for civilians trapped by war, scores of sick and wounded Muslims arrived in the Bosnian capital early today after being evacuated from a besieged eastern town.
+
+[QA]: What is the situation of the civilians trapped by war?
+
+[Answer to QA]: sentence 2.
+
+[QC]: How did scores of sick and wounded Muslims arrive?
+
+[Answer to QC]: sentence 4.
+
+# 3.2 Annotators and corpus
+
+The data we aim to collect consists of free-form, mostly open-ended questions. The nature of the data is inherently subjective, and the free text annotation poses challenges for automatic evaluation of quality. Therefore, we take measures to both recruit good annotators and ensure annotation quality.
+
+Our annotation team consists of three expert annotators, as well as a small number of qualified and trained crowd workers. We first piloted the task among the expert annotators, who were undergraduate linguistics researchers familiar with linguistics literature on discourse coherence. The crowdsourcing task was then collectively developed to be accessible to crowdworkers and to provide a list of constraints for the questions; we show in Appendix C.2 the key instructions.
+
+We use Amazon Mechanical Turk as our crowd
+
+| Similarity | 1 | 2 | 3 | 4 | 5 |
| Percentage | 26.1 | 14.6 | 17.6 | 16.9 | 24.9 |
| Same anchor | 35.8 | 23.7 | 34.8 | 43.1 | 69.8 |
+
+sourcing platform. To ensure quality, we designed a qualification task consisting of one article. We manually inspected the quality of the responses of each candidate, and only workers who asked satisfactory questions were invited to continue with the task. Throughout the process, we also monitored the responses of the workers and reminded them about specific guidelines when necessary. The workers are paid around $10/hr. No demographic information was collected.
+
+Corpus We annotate a subset of the articles used in the INQUISITIVE dataset (Ko et al., 2020) (c.f. Section 2). In contrast to INQUISITIVE which only contains curiosity-driven questions about the first five sentences for each article, we annotate up to the first 20 sentences. DCQA consists of 22,394 questions distributed across 606 articles, 51 of which are annotated by experts. Each article is annotated by 2 annotators.
+
+# 4 Analyzing DCQA
+
+This section presents a series of analytical questions we pose in order to understand DCQA questions, answers, and potential challenges.
+
+Are questions similar given the same answer sentence? We first quantify the level of subjectivity in our question-answering paradigm via two angles: (1) Given the same answer sentence, how similar are the questions asked by different annotators? (2) When questions are similar, do annotators agree on which sentence is the anchor?
+
+Since the questions are free-text in form, we use human judgments to assess their similarity. We asked our expert annotators to rate the similarity of a sample of 261 pairs of questions asked with the same answer sentence, on a scale of 1-5. Table 1 (row "percentage") shows that the questions different people ask may differ: while $41.8\%$ of the questions are highly similar with ratings of 4-5, $40.7\%$ of the questions are semantically different with ratings 1-2.
+
+Table 1: Human rating of question similarity for questions with the same answer sentence (top row), and fraction of questions with the same anchor sentence in each bucket (bottom row).
+
+| Distance | 1 | 2-4 | ≥5 |
| DCQA | 48.8 | 24.2 | 27.0 |
| TED-Q | 58.2 | 41.8 | 0.0 |
| INQUISITIVE | 18.1 | 27.8 | 54.1 |
+
+Table 2: The distribution of the distance (in terms of sentence ID differences) between the answer and anchor sentences.
+
+Table 1 (row "same anchor") shows how often annotators agree on the anchor sentence. When people ask the same questions (similarity 5), the percentage of agreement on the anchor sentence is high. Similar questions can have different anchors but answered in the same sentence; Appendix A.1 shows an example. Distinct questions can also share the same anchor sentence, as shown in Figure 1, questions 2 and 3.
+
+How well can humans do the QA task? Our annotation paradigm produces open-ended questions given the answer sentence, while ultimately the question-answering task seeks to find the answer given the question. Thus we explore to what extent humans can, given a question, find the original answer sentence where the question was generated. We asked an expert annotator to answer questions in a randomly sampled subset of 1175 questions from the validation and test sets, without informing them of the "gold" answer labels. If the annotator thinks there are multiple answers, he could annotate multiple sentences. After the answers are annotated, the gold answer is shown and the annotator adjudicates the two versions of answers.
+
+The agreement between the annotator and the gold labels is $72.2\%$ . In cases where the annotator selected multiple answer sentences, we report the expected agreement when randomly choosing one of them. For $69.5\%$ of the questions, the annotator exactly chose the gold answer; for $5.3\%$ , the annotator selected multiple answers including the gold. On $2.3\%$ of the data, the annotator thinks the gold answer cannot be used to answer the question without a stretch, thus should be regarded as noise. For the rest, the annotator thinks that both answers are reasonable as there are multiple possible answers, although they did not originally choose the gold. In these cases, the annotator tended to choose an earlier sentence than the gold. An example for multiple answer sentences is in Appendix A.1.
+
+How far away are answer sentences from question anchors? Table 2 shows the distances be
+
+tween the question anchor and the answer sentence, by difference of sentence IDs. While for a large proportion of questions, the answer sentence could be found just a few sentences after the question anchor sentence, there are also some questions with answers that are far away later in the article.
+
+Compared to TED-Q, DCQA contains fewer questions that are answered by the immediate next sentence. DCQA also has answers $\geq 5$ sentences away from the question, which TED-Q does not have. This means that fewer questions in DCQA can be trivially found in the immediate next sentence. Additionally, this also shows that the sentence connections captured by DCQA naturally result in a different structure from QADiscourse (Py- atkin et al., 2020) that expresses discourse relations across adjacent sentences in templatic questions.
+
+We also show the figures for INQUISITIVE over a subset that we annotate for answers (Section 6.1). Most of the INQUISITIVE answers are far away from where the question was asked; this is in stark contrast with TED-Q, highlighting the distributional differences between TED talks and news.
+
+Linguistic characteristics of DCQA. An interesting effect of the question generation process is that annotators often find semantic links between two parts of the article that are not pragmatically or discursively connected. For example:
+
+[Context]: This small Dallas suburb's got trouble. Trouble with a capital T and that rhymes with P and that stands for pool. More than 30 years ago, Prof. Harold Hill, the con man in Meredith Willson's 'The Music Man,' warned the citizens of River City, Iowa, against the game.
+[Sentence 6]: Now kindred spirits on Addison's town council have barred the town's fanciest hotel, the Grand Kempinski, from installing three free pool tables in its new lounge.
+[Question]: Just how fancy is the Grand Kempinski? [Sentence 13]: At the lounge [of the Grand Kempinski], manager Elizabeth Dyer won't admit patrons in jeans, T-shirts or tennis shoes.
+
+This question arises from the adjective fanciest used in Sentence 6. The discursive intent of Sentence 6 is to describe the events that make the game of pool relevant to the Dallas suburb mentioned; the assertion that the Grand Kempinski hotel is the "town's fanciest" is not discursively salient at this point, though it is relevant later in the article, as indicated by Sentence 13. This shows that a conscious reader was able to connect two pragmatically unrelated sentences by their semantic content. Such links have been deemed important in discourse literature, e.g., the Discourse Graphbank (Wolf and
+
+ | Train | Val. | Test |
| # questions | 20942 | 718 | 734 |
| # docs | 555 | 22 | 30 |
+
+Table 3: Train/test/validation splits of DCQA.
+
+Gibson, 2005) and the Entity Relation between two adjacent sentences in the Penn Discourse Treebank (Prasad et al., 2008).
+
+Finally, we present an analysis about the type of the questions asked in Appendix A.2, using the schema in Cao and Wang (2021). DCQA has a good coverage of the key question types in existing high-level question answering datasets (TEDQ and INQUISITIVE); the most frequent question types are concept, cause, procedural, and example.
+
+# 5 Question answering on DCQA
+
+As each of the questions already has a designated answer sentence during data collection, DCQA can be used to learn models for this type of QA, or as a testbed for existing models.
+
+Model Because our task involves reasoning over long documents, we choose Longformer (Beltagy et al., 2020) as our model. Longformer is a transformer model with an attention pattern that combines a local windowed attention and global attention on pre-selected, task-dependent tokens only. This makes the computation time scale linearly with the sequence length instead of quadratic (as in conventional transformers), allowing faster computation on longer sequences, as well as better performance on QA tasks with long contexts.
+
+Our model operates similarly to the BERT QA model for SQuAD (Devlin et al., 2019). For the model input, we concatenate the question, the anchor sentence, and the article, separated by delimiters. Note that by passing in the full article, the model has access to all context prior to the anchor. Since the goal of our model is to predict a sentence instead of the answer span, we add two tokens in front of each sentence in the article, the start of sentence token [sos] and the sentence ID. The model is trained to predict the span of the two added tokens in front of the answer sentence.
+
+Settings We use our expert annotated question-answer pairs for the validation and test sets, and crowd annotation for the training set. Table 3 shows the distribution of articles and questions across training, testing and validation sets.
+
+| Type | Model | Human |
| 1 | 85.4 | 81.8 |
| 2-4 | 46.3 | 69.3 |
| ≥5 | 51.0 | 57.1 |
+
+Because we will later experiment on INQUISITIVE (Section 6), we exclude articles overlapping with the INQUISITIVE test set (10 articles containing 376 questions) during training.
+
+We use HuggingFace (Wolf et al., 2020) for our implementation. We use the Adam (Kingma and Ba, 2015) optimizer with $(\beta_{1},\beta_{2}) = (0.9,0.999)$ and a learning rate of 5e-5.
+
+Results The fine-tuned Longformer model achieves $67.2\%$ accuracy. Note that a baseline that predicts the immediate next sentence after the anchor would achieve an accuracy of $40\%$ . We also experimented training with TED-Q, which achieved an inferior result of $39.5\%$ .
+
+We observe the overall performance is about $5\%$ lower than a human's $(72.2\%, \text{Section 4})$ . However, the model is doing substantially worse on answers that do not immediately follow the anchor (Table 4; human performance is reported on the 1,175 annotated examples in Section 4). We observe that human performance for answers further away from the anchor is also lower, reflecting that establishing longer-distance discursive connections is also more subjective for humans. Table 9 in Appendix B.1 stratifies model performance per question type.
+
+# How important are the context and anchor?
+
+To evaluate the influence of the context and anchor sentences, we experiment on 3 ablation settings. The results are shown in Table 5.
+
+(1) No prior context: We remove all the sentences prior to the anchor sentence from model inputs (while keeping the anchor itself). This setting resulted in an accuracy of $66.4\%$ , which is slightly worse yet on par with the context present, showing that the model does not use much information from the sentences before the anchor.
+
+(2) Unspecified anchor: For the Longformer model, we do not concatenate the anchor sentence with the question, while keeping the full article intact (which includes the prior context and the anchor). We observed an accuracy of $43.5\%$ , which is a substantial $23.7\%$ drop from the version with
+
+Table 4: Model and human accuracy for answer sentence extraction, statified by distance between question anchor and answer.
+
+ | accuracy |
| Original model | 67.2 |
| No prior context | 66.4 |
| Unspecified anchor | 43.5 |
| No context and no anchor | 42.6 |
+
+Table 5: Results for ablating context and source sentence
+
+the anchor sentence present. This shows that the model is struggling to locate the anchor if it is not given as supervision.
+
+(3) No prior context and no anchor: In this setting, in addition to applying both modification from above: no prior context in the input article and the anchor sentence is not concatenated with the question for the model, the anchor is also removed from the input article. This yields an accuracy of $42.6\%$ , slightly worse but on par with (2).
+
+We can see from (2) and (3) that specifying which sentence the question arises from is very important for the model performance, while the presupposed common ground does not play such a significant role.
+
+As a small experiment to assess whether humans can find the anchor points, we asked one of our expert annotators to try answering a set of 90 questions under those ablation settings. We found that for (1) and (2), the human performed almost the same as providing all the information, while (3) is $35\%$ worse. This shows that human are better at finding the anchor from the article while it is not specified, provided that the full article is present. Additionally, the questions are contextual, and requires the anchor to comprehend.
+
+# 6 Question answering on external datasets
+
+We first describe our collection of the Inquisitive test set (Section 6.1). Then we explore only answerable questions (Section 6.2), and design pretraining methods to allow the use of other QA datasets. Finally, we present a pipeline system that also handles question answerability (Section 6.3), by predicting whether a question is answerable using synthesized data from DCQA.
+
+# 6.1 INQUISITIVE answer collection
+
+To construct the evaluation set, for a subset of INQUISITIVE questions in their test set, two of our expert annotators independently chose the sentence that contains the answer. Then they met to adjudicate a final version of the answers.
+
+This newly annotated data consists of answers to 719 INQUISITIVE questions from 60 articles. Before adjudication, the annotators agree on whether there is an answer $78.8\%$ of the time. Out of those questions at least one annotator had answers, $42.7\%$ have total agreement, and another $7.3\%$ have partial agreement. This shows that answering the INQUISITIVE questions is challenging, even for trained linguistics senior students.
+
+After adjudication, 424 of the questions have answers. 57 of the questions have multiple valid answers (for 30 cases, related information spreads across multiple sentences; for 27 cases, the questions can be answered from multiple angles).
+
+During testing, we judge the model as correct if it predicts any one of the answers.
+
+# 6.2 Answering answerable questions
+
+We use Longformer as discussed in Section 5 as our base model. Additionally, we explore the utility of other existing QA datasets via pre-training: (1) we synthetically augment SQuAD 2.0 (Rajpurkar et al., 2018) for better compatibility of data format between DCQA and INQUISITIVE; (2) we utilize ELI5 (Fan et al., 2019) to provide more supervision for answering open-ended questions. We also explore using TED-Q for training. We also experiment on training with QuAC (Choi et al., 2018) for comparison, since a portion QuAC questions are open-ended questions, though its domain and the dependency of the questions on previous dialog turns make the format different from ours. We do not use previous dialog turns in our experiments.
+
+SQuAD pretraining While DCQA and INQUIISITIVE contain mainly high-level questions, their format is different: INQUIISITIVE questions are asked about a sub-sentential span in the document, and the questions are more dependent on the span.
+
+To pre-train the model to bridge this formatting gap, we create a synthetic dataset from SQuAD that simulates the input format with an annotated question span utilizing coreference substitution. Preprocessing details are described in Appendix C.1.
+
+ELI5 pretraining We also sought existing data for additional supervision to answer open-ended questions. The most related dataset we found is ELI5 (Fan et al., 2019) for long-form question answering. While the questions in the dataset comes with a human-written answer, they do not have context to form a question answering text. Preprocessing details are described in Appendix C.2.
+
+ | DCQA | INQUISITIVE |
| SQuAD | 34.7 | 9.9 |
| ELI5 | 1.3 | 1.4 |
| QuAC | 35.9 | 17.2 |
| TED-Q | 39.5 | 25.0 |
| +SQuAD+ELI5 | 46.0 | 38.2 |
| DCQA | 67.2 | 40.8 |
| +SQuAD | 66.7 | 41.3 |
| +ELI5 | 64.0 | 42.9 |
| +SQuAD+ELI5 | 66.0 | 45.5 |
| +TED-Q | 64.0 | 40.6 |
+
+Table 6: Question answering results. Systems trained on DCQA (includes pre-training) can get the strongest performance on INQUISITIVE.
+
+Settings When using either SQuAD or ELI5 pretraining, we pretrain for 6 epochs. When using both types of pretraining, we directly mix the data together, and pretrain for 3 epochs. The parameters are tuned on discourse questions validation set. All other settings are the same as in Section 5.
+
+Results Table 6 shows for both DCQA and all INQUISITIVE questions with an answer, the accuracy values of answer sentence extraction. Training only on TED-Q, synthesized SQuAD, QuAC, and ELI5 examples produces poor results, showing that existing datasets cannot be directly used to train model to answer the open-ended questions meant to facilitate discourse comprehension.
+
+When tested on INQUISITIVE, training on DCQA achieves the best performance across all settings, showing its ability to provide supervision for open-ended question answering. Although pretraining did not help for answering DCQA questions, for INQUISITIVE, both types of pretraining are helpful individually, and using them together yields the best result. We conducted a binomial significance test between DCQA and $\mathrm{S + E + DCQA}$ and found that the improvement is statistically significant. Additionally, pre-training also improved performance when used with TED-Q (rows 3 vs. 4). This shows that our design to adapt the two datasets is successful. TED-Q used on top of the other two pre-training did not improve performance.
+
+# 6.3 Handling question answerability
+
+We experiment on the full open-ended question answering task: given context and question, answer
+
+| System | DCQA | S+E+DCQA | S+E+TED |
| F1 | 0.260 | 0.358 | 0.242 |
+
+Table 7: Pipeline system question answering results
+
+the question only if there is an answer to be found in the article.
+
+While DCQA does not come with unanswerable questions, we generate them by truncating parts of the articles that contain answers. Specifically, we truncate each article in the training set of DCQA to the first 12 sentences, and label questions with answers after sentence 12 as unanswered. Using this data, we train a model to predict whether a question is answerable given the text, following the setup of models in Sections 5 and 6.2. We then combine this model with models in Section 6.2 into a pipeline: first predict whether an answer exists, then provide the answer. For the full task, we split the collected INQUISITIVE answers into a validation (223 examples) and test (496 examples) sets. We adjust the threshold of predicting on the validation set of discourse questions.
+
+Results show that the model could predict if there is an answer correctly $84\%$ of the time on the synthetic discourse questions test set, but only $67\%$ of the time when tested on INQUISITIVE. In both datasets, about $59\%$ of the questions are answered. This shows that although our way of generating synthetic data is useful, answerability prediction is challenging.
+
+We report the result of the pipeline system in Table 7, applying first our answerability model, then the corresponding question answering model. We use F1 score of correctly predicted questions following Rajpurkar et al. (2018). If the model predicts no answer, we treat it as not making a prediction when calculating the F1 score.
+
+While DCQA and pre-training is useful, the numbers clearly show that a full open-ended question answering system, that includes answerability prediction, is an extremely challenging task. Answerability prediction presents a bottleneck here, and we leave for future work to design better strategies and models.
+
+# 7 Conclusion
+
+We present DCQA that connects pieces in a document via open-ended questions and full-sentence
+
+answers. DCQA is collected via a new paradigm that regards the main purpose of a new sentence as an answer to a free-form question evoked earlier in the context. Consequently, this paradigm yields both discourse and semantic links across all sentences in a document. DCQA is introduced with the goal of providing a more scalable data collection paradigm, also as initial resource, for answering open-ended questions for discourse comprehension. Our experiments showed that DCQA provides valuable supervision for such tasks.
+
+# Limitations
+
+DCQA collects questions in a reactive manner: the answer is first observed before the question is generated. This is, by design, different from methods where questions are elicited as a person reads (i.e., without seeing upcoming context, as in INQUISITIVE and TED-Q). Seeing the answer before asking the question inevitably results in a slight distributional shift from datasets such as INQUISITIVE, as seen in Table 8 (Appendix A.2). Qualitatively, we observe that the questions tend to be a bit more specific than INQUISITIVE, and answers are more easily associated with a particular sentence.
+
+Another notable difference is that DCQA does not address unanswerable questions. While we designed synthetic data augmentation methods to train models to handle such questions, this is challenging, as discussed in Section 6.3. We hope future work could find better solutions.
+
+Multi-sentence answers exist much more frequently in high-level question answering than factoid QA; in DCQA, it happens if questions elicited from different answer sentences share an anchor sentence (Appendix A.1). We leave multi-sentence answers for future work.
+
+Finally, although DCQA is designed as a general paradigm for data collection, the dataset presented in this paper is collected on English news articles. Thus the distribution of questions and answers may change by genre and/or language, which should be explored in future work.
+
+# Acknowledgments
+
+We are grateful for the feedback provided by anonymous reviewers. This work was partially supported by NSF grants IIS-2145479, IIS-2145280, and IIS-1850153. We acknowledge the Texas Advanced Computing Center at UT Austin for many of the results within this paper.
+
+# References
+
+Iz Beltagy, Matthew E. Peters, and Arman Cohan. 2020. Longformer: The long-document transformer. arXiv:2004.05150.
+Shuyang Cao and Lu Wang. 2021. Controllable open-ended question generation with a new question type ontology. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 6424-6439.
+Eunsol Choi, He He, Mohit Iyyer, Mark Yatskar, Wen tau Yih, Yejin Choi, Percy Liang, and Luke Zettle-moyer. 2018. QuAC: Question answering in context. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2174-2184.
+Prafulla Kumar Choubey, Aaron Lee, Ruihong Huang, and Lu Wang. 2020. Discourse as a function of event: Profiling discourse structure in news articles around the main event. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5374-5386.
+Kordula De Kuthy, Nils Reiter, and Arndt Riester. 2018. Qud-based annotation of discourse structure and information structure: Tool and evaluation. In Proceedings of the Eleventh International Conference on Language Resources and Evaluation (LREC 2018).
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. Bert: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186.
+Jesse Dunietz, Greg Burnham, Akash Bharadwaj, Owen Rambow, Jennifer Chu-Carroll, and Dave Ferrucci. 2020. To test machine comprehension, start by defining comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7839-7859.
+Angela Fan, Yacine Jernite, Ethan Perez, David Grangier, Jason Weston, and Michael Auli. 2019. ELI5: Long form question answering. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3558-3567.
+Matt Gardner, Joel Grus, Mark Neumann, Oyvind Tafjord, Pradeep Dasigi, Nelson F Liu, Matthew Peters, Michael Schmitz, and Luke Zettlemoyer. 2018. Allennlp: A deep semantic natural language processing platform. In Proceedings of Workshop for NLP Open Source Software (NLP-OSS), pages 1-6.
+Arthur C Graesser, Natalie Person, and John Huber. 1992. Mechanisms that generate questions. *Questions and information systems*, 2:167-187.
+Donna Harman and Mark Liberman. 1993. TIPSTER Complete LDC93T3A. Linguistic Data Consortium.
+Jerry R Hobbs. 1985. On the coherence and structure of discourse.
+
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In Proceedings of the 3rd International Conference for Learning Representations.
+Wei-Jen Ko, Te-yuan Chen, Yiyan Huang, Greg Durrett, and Junyi Jessy Li. 2020. Inquisitive question generation for high level text comprehension. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6544-6555.
+Tom Kwiatkowski, Jennimaria Palomaki, Olivia Redfield, Michael Collins, Ankur Parikh, Chris Alberti, Danielle Epstein, Illia Polosukhin, Matthew Kelcey, Jacob Devlin, Kenton Lee, Kristina N. Toutanova, Llion Jones, Ming-Wei Chang, Andrew Dai, Jakob Uszkoreit, Quoc Le, and Slav Petrov. 2019. Natural questions: a benchmark for question answering research. Transactions of the Association for Computational Linguistics, 7:453-466.
+Alex Lascarides and Nicholas Asher. 2008. Segmented discourse representation theory: Dynamic semantics with discourse structure. In Computing meaning, pages 87-124. Springer.
+William C Mann and Sandra A Thompson. 1988. Rhetorical structure theory: Toward a functional theory of text organization. Text-interdisciplinary Journal for the Study of Discourse, 8(3):243-281.
+Mitch Marcus, Beatrice Santorini, and Mary Ann Marcinkiewicz. 1993. Building a large annotated corpus of English: The Penn Treebank. Computational Linguistics, 19(2):313-330.
+Fabio Petroni, Aleksandra Piktus, Angela Fan, Patrick Lewis, Majid Yazdani, Nicola De Cao, James Thorne, Yacine Jernite, Vassilis Plachouras, Tim Rocktäschel, and Sebastian Riedel. 2021. KILT: a benchmark for knowledge intensive language tasks. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2523-2544.
+Rashmi Prasad, Nikhil Dinesh, Alan Lee, Eleni Miltsakaki, Livio Robaldo, Aravind K Joshi, and Bonnie L Webber. 2008. The Penn Discourse TreeBank 2.0. In Language Resources and Evaluation Conference.
+Rashmi Prasad and Aravind Joshi. 2008. A discourse-based approach to generating why-questions from texts. In Proceedings of the Workshop on the Question Generation Shared Task and Evaluation Challenge, pages 1-3. Citeseer.
+Valentina Pyatkin, Ayal Klein, Reut Tsarfaty, and Ido Dagan. 2020. Qadiscourse-discourse relations as qa pairs: Representation, crowdsourcing and baselines. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2804-2819.
+Pranav Rajpurkar, Robin Jia, and Percy Liang. 2018. Know what you don't know: Unanswerable questions for SQuAD. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 784-789.
+
+Nils Reimers and Iryna Gurevych. 2019. SentenceBERT: Sentence embeddings using siamese bert-networks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3982-3992.
+Arndt Riester. 2019. Constructing qud trees. In *Questions in discourse*, pages 164–193. Brill.
+Amir Soleimani, Christof Monz, and Marcel Worring. 2021. Nlquad: A non-factoid long question answering data set. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 1245-1255.
+Teun A Van Dijk. 2013. News as discourse.
+Leah Velleman and David Beaver. 2016. Question-based models of information structure. In *The Oxford handbook* of information structure.
+Martha L Wegner, Robert H Brookshire, and LE Nicholas. 1984. Comprehension of main ideas and details in coherent and noncoherent discourse by aphasic and nonaphasic listeners. *Brain and language*, 21(1):37-51.
+Matthijs Westera, Laia Mayol, and Hannah Rohde. 2020. TED-Q: Ted talks and the questions they evoke. In Proceedings of the Twelfth International Conference on Language Resources and Evaluation (LREC'2020).
+Florian Wolf and Edward Gibson. 2005. Representing discourse coherence: A corpus-based study. Computational linguistics, 31(2):249-287.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45.
+Wei Xu, Chris Callison-Burch, and Courtney Naples. 2015. Problems in current text simplification research: New data can help. Transactions of the Association for Computational Linguistics, 3:283-297.
+Zhilin Yang, Peng Qi, Saizheng Zhang, Yoshua Bengio, William W. Cohen, Ruslan Salakhutdinov, and Christopher D. Manning. 2018. HOTPOTQA: A Dataset for Diverse, Explainable Multi-hop Question Answering. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2369-2380.
+
+# A Additional analysis of DCQA
+
+# A.1 Additional examples
+
+An example showing similar questions with different anchors but the same answer sentence:
+
+[Sentence 11] Now, those animals, once just visitors, have established resident populations – and they are spreading. [Q1] How far have the Wolverines spread?
+[Sentence 12] "We have growing evidence of them using larger and larger areas over time," Aubry said. [Q2] How far have the Wolverines gone in their repopulation?
+[Sentence 13] So far, scientists have confirmed resident wolverine populations from the North Cascades to as far south as this bait lure south of Highway 2 west of Leavenworth. Answers both Q1 and Q2.
+In the example below, the expert annotator found multiple answer sentences for the question whose gold answer was Sentence 12.
+[Sentence 1]: Amid skepticism that Russia's war in Chechnya can be ended across a negotiating table, peace talks were set to resume Wednesday in neighboring Ingushetia. [Question]: What has been the fallout of the war?
+[Sentence 12 (original and expert answer)]: The Russian offensive has turned Grozny into a wasteland littered with rotting bodies, twisted metal and debris.
+[Sentence 13 (expert answer)]: Hardly a building is untouched.
+[Sentence 14 (expert answer)]: The war has also cost Russia dearly – in lives, prestige and rubles.
+
+# A.2 What questions are asked?
+
+We further examine what types of questions are asked. We fine-tune a classifier based on pretrained BERT (Devlin et al., 2019) using the data and classification scheme from Cao and Wang (2021).4 Table 8 shows the distribution of the types of question. We also show distributions of other open-ended question datasets for comparison.
+
+In all datasets, concept questions are the most frequent; those questions ask about the definition or background knowledge. Compared to other datasets, ours contain many more causal questions (e.g., why did Joyce Benes stop feeding the horses?), reflecting that annotators frequently make causal inferences across events. In contrast we see fewer procedural and example questions. Our dataset also tend to contain few judgmental questions, i.e., question about opinions, which may be a reflection of news articles trying to stay objective.
+
+# B Additional model analysis
+
+# B.1 Model accuracy by question type
+
+Table 9 shows the accuracy stratified by different types of questions as classified using the model from Cao and Wang (2021). The QA model performs well on extent and consequence questions, followed by concept, verification, and disjunct
+
+ | INQ. | Ours | TED-Q |
| verification | 4.0 | 7.9 | 15.5 |
| disjunctive | 0.1 | 1.0 | 1.3 |
| concept | 31.3 | 32.5 | 23.3 |
| extent | 7.7 | 5.7 | 4.9 |
| example | 13.7 | 6.9 | 15.0 |
| comparison | 0.6 | 0.5 | 0.8 |
| cause | 14.1 | 31.8 | 13.8 |
| consequence | 4.2 | 0.6 | 1.5 |
| procedural | 14.3 | 10.8 | 14.7 |
| judgmental | 9.9 | 2.4 | 9.2 |
+
+questions, while performing relatively worse on comparison or cause questions.
+
+Table 8: Question types in each dataset, classified using the model from Cao and Wang (2021). Our dataset has good coverage of the key question types in the other two datasets.
+
+| Type | Accuracy |
| concept | 66.8 |
| verification | 67.8 |
| procedural | 58.4 |
| comparison | 50.0 |
| cause | 55.7 |
| judgmental | 62.6 |
| extent | 71.3 |
| example | 64.3 |
| disjunct | 66.7 |
| consequence | 69.0 |
+
+Table 9: Model performance statified by question type, trained and tested on DCQA.
+
+# C Pretraining details
+
+# C.1 SQuAD pretraining
+
+At a high level, certain phrases in the SQuAD questions may be referred to by pronouns or demonstratives in their corresponding article, and we can replace such phrases in the questions by these more context-dependent forms, and sample an element in the chain that precedes the answer as the highlighted span. Specifically, we: (1) combine 5 consecutive paragraphs from SQuAD articles to create longer text and extract coreference chains; (2) for each question whose answer span is in the combined text, we look for exact matches between ngrams in the question and expressions in coreference chains; (3) if there is a match, substitute the question phrase with a random reference in the matched chain, or the demonstrative "this"; When choosing the random reference we also consider whether the it is in possessive form. (4) designate a
+
+random chain element preceding the answer as the highlighted span.
+
+For example, for the SQuAD question "Of what group in the periodic table is oxygen a member?", we found "oxygen" in the corresponding article referred to as "it", "the element", etc. Thus we change the question to "Of what group in the periodic table is it a member?", and generate the following highlight using one of the sentences before the answer: "At standard temperature and pressure, two atoms of the element bind to form dioxygen."
+
+This method synthesizes questions with noun spans only, which is the most frequent span category in INQUISITIVE; we did not handle verbs or adjectives this way because of their variability.
+
+We synthesized 45437 questions, including 42021 questions with an answer. We use special tokens to denote the start and end of the synthesized span.
+
+# C.2 ELI5 pretraining
+
+We retrieve the sentence in the supporting documents with the highest BM25 score as the approximate answer sentence. Following Petroni et al. (2021), we use the whole English Wikipedia as the supporting corpus instead of the original supporting documents. We combine sentences before and after the answer sentence with the answer itself to form the "article" as the input to the question answering model. The number of context sentences are randomly chosen so that the length of the synthesized article is comparable to INQUISITIVE articles and the answers are evenly distributed among different positions in the synthesized article.
+
+To prevent low quality answers, we have an additional filtering step that keeps only the examples whose cosine similarity between the sentence embeddings (embedded using distilled SRoBERTa (Reimers and Gurevych, 2019)) of the retrieved answer and the gold answer is larger than 0.55. This resulted in 55740 examples.
+
+# C.3 Additional experimental details
+
+We run our experiments on NVIDIA Tesla V100 SXM2 GPUs. We use 2 GPUs when training the model and it takes about 10 hours for the QA model. The longformer-base-4096 we use has roughly 148M parameters. Our hyperparameters are tuned on the validation set; we mainly tune the learning rate and the number of epochs. Our reported results are from a single run.
+
+# Instructions:
+
+With this task, we ask you to slowly read through an article, and think of each sentence as an answer to a question that arose from the context you've already read. What would these questions be?
+
+Your involvement could help us understand the structure of articles, and also help advance the ability of computers to understand the articles. By doing this task, you are teaching the computers to answer high-level questions about articles.
+
+Thank you for helping out with our research!
+
+# What to do:
+
+We will look at sentences in an article one by one. For each new sentence, we ask you to construct a question, which indicates how the new sentence elaborates on earlier sentences. The new sentence should be the answer to the question. In other words, think of each sentence as an answer to a question that arose from the context you've already read. Please type the question in the box "Write a question about the article up to here, and this new sentence is the answer"
+
+You will also be asked to specify which earlier sentence the question is mainly about. Please type the sentence ID in the box "Which sentence does the question arise from?"
+
+The earlier sentences in the article will be shown in the left column once you hover on the answering area.
+
+Before you start, please read the following guidelines carefully.
+
+# Guidelines:
+
+1. When there are many possible questions, please ask the question that reflects the main purpose of the new sentence. 2. Please try to ask open-ended questions that require some explanation as an answer when possible (such as questions starting with Why), instead of questions that could be answered simply by a place/person/time or yes/no.
+
+3. When writing the question, please assume that the question could be asked and understood by people only reading the earlier sentences,
+
+which means that you should avoid using information first introduced in the new sentence, and avoid copying the phrases only used in the new sentence. It is allowed to reuse the phrases in previous sentences.
+
+4. When a question could arise from many sentences individually, choose the earliest sentence
+
+Figure 4: Key instructions of our crowdsourcing task for question collection.
+
+# D Instructions for question collection
+
+Instructions for DCQA's crowdsourcing interface is shown in Figure 4.
+
+# E Copyright information related to
+
+# DCQA
+
+DCQA's annotated data is a subset of the articles used in the INQUISITIVE dataset (Ko et al., 2020). This data is sourced from three existing datasets: Newsela (Xu et al., 2015), WSJ articles from the Penn Treebank (Marcus et al., 1993), and Associated Press (Harman and Liberman, 1993). The Newsela dataset can be requested free of charge for researchers at https://newsela.com/data, and the authors have obtained permission to perform research on this data. The Penn Treebank is one of the most widely used resource in NLP, and is available via the LDC at https://catalog.ldc.upenn.edu/LDC99T42. The Associated Press data is also available from the LDC at https://catalog.ldc.upenn.edu/LDC93T3A.
\ No newline at end of file
diff --git a/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/images.zip b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..420d1b04b0c4863cf3eba053a0a99fe2c14032a9
--- /dev/null
+++ b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9ca44f6331b2fcb123605f4714a7b611f396b78fe781595cb80b4c25c0b09e1f
+size 308315
diff --git a/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/layout.json b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..665fe7d4cd96d1292cc444dab779dd423f957edd
--- /dev/null
+++ b/discoursecomprehensionaquestionansweringframeworktorepresentsentenceconnections/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7bbb2bd27ca25bc20b187d608262ef6c9151823b35b9cb83261734db2d74e046
+size 409386
diff --git a/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_content_list.json b/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..1d435d3293ef8d20ae771c7ae209064745bae17e
--- /dev/null
+++ b/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fc1b9c339b70c03b24b30593ca4eff5914bd84e8e73ebe51d175cc941efd939b
+size 106441
diff --git a/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_model.json b/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0748c567bcb4d45a1c7c4fbc863cdae639c7dd5d
--- /dev/null
+++ b/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8ce88b66ae0c325f24b8b054c4d5333d1cd7ceb57a2270d44a30922805b11c60
+size 132070
diff --git a/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_origin.pdf b/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c6fee08465ec75b5b13db4ff895ecbfdbf6f66b1
--- /dev/null
+++ b/discoursecontextpredictabilityeffectsinhindiwordorder/c55f693f-936f-4568-b5f2-b19e37173aa5_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c8ecc4524c1cda798319bae3d6041f77496324c3aeed7197ece611cf237566d0
+size 546383
diff --git a/discoursecontextpredictabilityeffectsinhindiwordorder/full.md b/discoursecontextpredictabilityeffectsinhindiwordorder/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c7e63a80614eb722e2eff5d2423e704152b080cb
--- /dev/null
+++ b/discoursecontextpredictabilityeffectsinhindiwordorder/full.md
@@ -0,0 +1,419 @@
+# Discourse Context Predictability Effects in Hindi Word Order
+
+Sidharth Ranjan
+
+IIT Delhi
+
+sidharth.ranjan03@gmail.com
+
+Sumeet Agarwal
+
+IIT Delhi
+
+sumeet@iitd.ac.in
+
+Marten van Schijndel
+
+Cornell University
+
+mv443@cornell.edu
+
+Rajakrishnan Rajkumar
+
+IISER Bhopal
+
+rajak@iserb.ac.in
+
+# Abstract
+
+We test the hypothesis that discourse predictability influences Hindi syntactic choice. While prior work has shown that a number of factors (e.g., information status, dependency length, and syntactic surprisal) influence Hindi word order preferences, the role of discourse predictability is underexplored in the literature. Inspired by prior work on syntactic priming, we investigate how the words and syntactic structures in a sentence influence the word order of the following sentences. Specifically, we extract sentences from the Hindi-Urdu Treebank corpus (HUTB), permute the preverbal constituents of those sentences, and build a classifier to predict which sentences actually occurred in the corpus against artificially generated distractors. The classifier uses a number of discourse-based features and cognitive features to make its predictions, including dependency length, surprisal, and information status. We find that information status and LSTM-based discourse predictability influence word order choices, especially for non-canonical object-fronted orders. We conclude by situating our results within the broader syntactic priming literature.
+
+# 1 Introduction
+
+Grammars of natural languages have evolved over time to factor in cognitive pressures related to production (Hawkins, 1994, 2000) and comprehension (Hawkins, 2004, 2014), learnability (Christiansen and Chater, 2008) and communicative efficiency (Jaeger and Tily, 2011; Gibson et al., 2019). In this work, we test the hypothesis that maximization of discourse predictability (quantified using lexical repetition surprisal and adaptive LSTM surprisal) is a significant predictor of Hindi syntactic choice, when controlling for information status, dependency length, and surprisal measures estimated
+
+from $n$ -gram, LSTM and incremental constituency parsing models.
+
+Our hypothesis is inspired by a solid body of evidence from studies based on dependency treebanks of typologically diverse languages which show that grammars of languages tend to order words by minimizing dependency length (Liu, 2008; Futrell et al., 2015) and maximizing their trigram predictability (Gildea and Jaeger, 2015). Parallel to this line of work on sentence-level word order, another strand of work has focused on discourse-level estimates of entropy starting from the Constant Entropy Rate hypothesis (CER; Genzel and Charniak, 2002). To overcome the major difficulty of estimating sentence probabilities conditioned on the previous discourse context, Qian and Jaeger (2012) approximated discourse-level entropy using lexical cues from the previous context. In contrast, we leverage modern computational psycholinguistic neural techniques to obtain word and sentence-level estimates of inter-sentential discourse predictability and study the impact of these measures on Hindi word order choices. We conclude that discourse-level priming influences Hindi word order decisions and interpret our findings in the light of the factors outlined by Reitter et al. (2011).
+
+Hindi (Indo-Aryan language; Indo-European language family) has a rich case-marking system and flexible word order, though it mainly follows SOV word order (Kachru, 2006) as exemplified below.
+
+(1) a. amar ujala-ko yah sukravar-ko daak-se
+Amar Ujala-ACC it friday-on post-INST
+prapt hua
+receive be.PST.SG
+Amar Ujala received it by post on Friday.
+
+b. yah amar ujala-ko sukravar-ko daak-se prapt hua
+c. sukravar-ko yah amar ujala-ko daak-se prapt hua
+
+To test ordering preferences, we generated meaning-equivalent grammatical variants (Examples 1b and 1c above) of reference sentences (Example 1a) from the Hindi-Urdu Treebank corpus of written text (HUTB; Bhatt et al., 2009) by permuting their preverbal constituent ordering. Subsequently, we used a logistic regression model to distinguish the original reference sentences from the plausible variants based on a set of cognitive predictors. We test whether fine-tuning a neural language model on preceding sentences improves predictions of preverbal Hindi constituent order in later sentences over other cognitive control measures. The motivation for our fine-tuning method is that, during reading, encountering a syntactic structure eases the comprehension of subsequent sentences with similar syntactic structures as attested in a wide variety of languages (Arai et al., 2007; Tooley and Traxler, 2010) including Hindi (Husain and Yadav, 2020). Our cognitive control factors are motivated by recent works which show that Hindi optimizes processing efficiency by minimizing lexical and syntactic surprisal (Ranjan et al., 2019) and dependency length (Ranjan et al., 2022a) at the sentence level.
+
+Our results indicate that discourse predictability is maximized by reference sentences compared with alternative orderings, indicating that discourse predictability influences Hindi word-order preferences. This finding corroborates previous findings of adaptation/priming in comprehension (Fine et al., 2013; Fine and Jaeger, 2016) and production (Gries, 2005; Bock, 1986). Generally, this effect is influenced by lexical priming, but we also find that certain object-fronted constructions prime subsequent object-fronting, providing evidence for self-priming of larger syntactic configurations. With the introduction of neural model surprisal scores, dependency length minimization effects reported to influence Hindi word order choices in previous work (Ranjan et al., 2022a) disappear except in the case of direct object fronting, which we interpret as evidence for the Information Locality Hypothesis (Futrell et al., 2020). Finally, we discuss the implications of our findings for syntactic priming in both comprehension and production.
+
+Our main contribution is that we show the impact of discourse predictability on word order choices using modern computational methods and
+
+naturally occurring data (as opposed to carefully controlled stimuli in behavioural experiments). Cross-linguistic evidence is imperative to validate theories of language processing (Jaeger and Nor-cliffe, 2009), and in this work we extend existing theories of how humans prioritize word order decisions to Hindi.
+
+# 2 Background
+
+# 2.1 Surprisal Theory
+
+Surprisal Theory (Hale, 2001; Levy, 2008) posits that comprehenders construct probabilistic interpretations of sentences based on previously encountered structures. Mathematically, the surprisal of the $k^{th}$ word, $w_{k}$ , is defined as the negative log probability of $w_{k}$ given the preceding context:
+
+$$
+S _ {k} = - \log P \left(w _ {k} \mid w _ {1 \dots k - 1}\right) = \log \frac {P \left(w _ {1} \dots w _ {k - 1}\right)}{P \left(w _ {1} \dots w _ {k}\right)} \tag {1}
+$$
+
+These probabilities can be computed either over word sequences or syntactic configurations and reflect the information load (or predictability) of $w_{k}$ . High surprisal is correlated with longer reading times (Levy, 2008; Demberg and Keller, 2008; Staub, 2015) as well as longer spontaneous spoken word durations (Demberg et al., 2012; Dammalapati et al., 2021). Lexical predictability estimated using $n$ -gram language models is one of the strongest determinants of word-order preferences in both English (Rajkumar et al., 2016) and Hindi (Ranjan et al., 2022a, 2019; Jain et al., 2018).
+
+# 2.2 Dependency Locality Theory
+
+Dependency locality theory (Gibson, 2000) has been shown to be effective at predicting the comprehension difficulty of a sequence, with shorter dependencies generally being easier to process than longer ones (Temperley, 2007; Futrell et al., 2015; Liu et al., 2017, cf. Demberg and Keller, 2008).
+
+# 3 Data and Models
+
+Our dataset comprises 1996 reference sentences containing well-defined subject and object constituents from the HUTB1 corpus of dependency trees (Bhatt et al., 2009). The HUTB corpus, which belongs to the newswire domain and contains written text in a natural discourse context,
+
+is a human-annotated, multi-representational, and multi-layered treebank. The dependency trees here assumes Panini's grammatical model where each sentence is represented as a series of modifier-modified elements (Bharati et al., 2002; Sangal et al., 1995). Each tree in the HUTB corpus denotes words in the sentence with nodes such that head words (modified) are linked to the dependent words (modifier) via labelled links denoting the grammatical relationship between word pairs.
+
+For each reference sentence in the HUTB corpus, we created artificial variants by permuting the preverbal constituents whose heads were linked to the root node in the dependency tree. Inspired by grammar rules proposed in the NLG literature (Rajkumar and White, 2014), ungrammatical variants were automatically filtered out by detecting dependency relation sequences not attested in the original HUTB corpus. After filtering, we had 72833 variant sentences for our classification task. Figure 1 in Appendix A displays the dependency tree for Example sentence 1a and explains our variant generation procedure in more detail.
+
+To determine whether the original word order (i.e. the reference sentence) is preferred to the permuted word orders (i.e. the variant sentences), we conducted a targeted human evaluation via forced-choice rating task and collected sentence judgments from 12 Hindi native speakers for 167 randomly selected reference-variant pairs in our data set. Participants were first shown the preceding sentence, and then they were asked to select the best continuation between either the reference or the variant. We found that $89.92\%$ of the reference sentences which originally appeared in the HUTB corpus were also preferred by native speakers compared to the artificially generated grammatical variants expressing similar meaning (Further details are provided in Appendix G). Therefore, in our analyses we treat the HUTB reference sentences as human-preferred gold orderings compared with other possible automatically-generated constituent orderings.
+
+# 3.1 Models
+
+We set up a binary classification task to separate the original HUTB reference sentences from the variants using the cognitive metrics described in Section 2. To alleviate the data imbalance between
+
+the two classes (1996 references vs 72833 variants), we transformed our data set using the approach described in Joachims (2002). This technique converts a binary classification problem into a pairwise ranking task by training the classifier on the difference of the feature vectors of each reference and its corresponding variants (see Equations 2 and 3). Equation 2 displays the objective of a standard binary classifier, where the classifier must learn a feature weight $(w)$ such that the dot product of $w$ with the reference feature vector $(\phi (\text{reference}))$ is greater than the dot product of $w$ with the variant feature vector $(\phi (\text{variant}))$ . This objective can be rewritten as equation 3 such that the dot product of $w$ with the difference of the feature vectors is greater than zero.
+
+$$
+w \cdot \phi (\text {r e f e r e n c e}) > w \cdot \phi (\text {v a r i a n t}) \tag {2}
+$$
+
+$$
+w \cdot (\phi (r e f e r e n c e) - \phi (v a r i a n t)) > 0 \tag {3}
+$$
+
+Every variant sentence in our dataset was paired with its corresponding reference sentence with order balanced across these pairings (e.g., Example 1 would yield (1a,1b) and (1c,1a)). Thereafter, their feature vectors were subtracted (e.g., 1a-1b and 1c-1a), and binary labels were assigned to each transformed data point. Reference-Variant pairs were coded as "1" and Variant-Reference pairs were coded as "0". The alternate pair ordering thus re-balanced our previously severely imbalanced classification task. Table 5 in Appendix D illustrates the original and transformed values of the independent variables.
+
+For each reference sentence, our objective was to model the possible syntactic choices entertained by the speaker. In each instance, the author chose to generate the reference order over the variant, implicitly demonstrating an order preference. If the cognitive factors in our study influenced that decision, a logistic regression model should be able to use those factors to predict which syntactic choice was ultimately chosen by the author. Using the transformed features dataset labelled with 1 (denoting a preference for the reference order) and 0 (denoting a preference for the variant order), we trained a logistic regression model to predict each reference sentence (see Equation 4). We report our classification results using 10-fold cross-validation. The regression results are reported on the entire transformed test data for the respective
+
+experiments. All experiments were done with the Generalized Linear Model (GLM) package in $R$ .
+
+$$
+c h o i c e \sim \left\{ \begin{array}{l l} & \delta \text {d e p e n d e n c y l e n g t h +} \\ & \delta \text {t r i g r a m s u r p +} \delta \text {p c f g s u r p +} \\ & \delta \text {I S s c o r e +} \delta \text {l e x i c a l r e p e t i t i o n s u r p +} \\ & \delta \text {l s t m s u r p +} \delta \text {a d a p t i v e l s t m s u r p} \end{array} \right. \tag {4}
+$$
+
+Here choice is encoded by the binary dependent variable as discussed above (1: reference preference and 0: variant preference). To obtain sentence-level surprisal measures, we summed word-level surprisal of all the words in each sentence. The values for independent variables were calculated as follows.
+
+1. Dependency length: We computed a sentence-level dependency length measure by summing the head-dependent distances (measured as the number of intervening words) in the HUTB reference and variant dependency trees.
+2. Trigram surprisal: For each word in a sentence, we estimated its local predictability using a 3-gram language model (LM) trained on the written section of the EMILLE Hindi Corpus (Baker et al., 2002), which consists of 1 million mixed genre sentences, using the SRILM toolkit (Stolcke, 2002) with Good-Turing discounting.
+3. PCFG surprisal: The syntactic predictability of each word in a sentence was estimated using the Berkeley latent-variable PCFG parser $^2$ (Petrov et al., 2006). 12000 phrase structure trees were created to train the parser by converting Bhatt et al.'s HUTB dependency trees into constituency trees using the approach described in Yadav et al. (2017). Sentence level log-likelihood of each test sentence was estimated by training a PCFG LM on four folds of the phrase structure trees and then testing on a fifth held-out fold.
+4. Information status (IS) score: We automatically annotated whether each sentence exhibited given-new ordering. The subject and object constituents in a sentence were assigned a Given tag if its head was a pronoun or any
+
+content word within it was mentioned in the preceding sentence. All other phrases were tagged as New. For each sentence, IS score was computed as follows: a) Given-New order $= +1$ b) New-Given order $= -1$ c) Given-Given and New-New $= 0$ . For an illustration of givenness coding, see Example 3 in Appendix A and the description in Appendix B.
+
+5. Lexical repetition surprisal: For each word in a sentence, we accounted for lexical priming by interpolating a 3-gram language model with a unigram cache LM based on the history of words ( $H = 100$ ) containing only the preceding sentence. We used the original implementation provided in the SRILM toolkit with a default interpolation weight parameter ( $\mu = 0.05$ ; see Equations 5 and 6) based on the approach described by Kuhn and De Mori (1990). The idea is to keep a count of recently occurring words in the sentence history and then boost their probability within the trigram language model. Words that have occurred recently in the text are likely to re-occur3 in subsequent sentences (Kuhn and De Mori, 1990; Clarkson and Robinson, 1997).
+
+$$
+\begin{array}{l} P \left(w _ {k} \mid w _ {1}, w _ {2}, \dots . w _ {k - 1}\right) = \mu P _ {\text {c a c h e}} \left(w _ {k} \mid w _ {1}, w _ {2}, \dots . w _ {k - 1}\right) \\ + (1 - \mu) P _ {t r i g r a m} \left(w _ {k} \mid w _ {k - 2}, w _ {k - 1}\right) \tag {5} \\ \end{array}
+$$
+
+$$
+P _ {\text {c a c h e}} \left(w _ {k} \mid w _ {k - H}, w _ {k - H + 1},.. w _ {k - 1}\right) = \frac {w _ {k} \text {c o u n t s} _ {\text {(c a c h e)}}}{H} \tag {6}
+$$
+
+6. LSTM surprisal: We estimated the predictability for each word according to the entire sentence prefix using a long short-term memory language model (LSTM; Hochreiter and Schmidhuber, 1997) trained on the 1 million written sentences from the EMILLE Hindi corpus (Baker et al., 2002). We used the LSTM implementation provided in the Neural Complexity toolkit (van Schijndel and Linzen, 2018) with default hyper-parameter settings to estimate surprisal using the neural context within each sentence. The exact parameters are as follows: 2 LSTM layers with 200 hidden units each, 200-dimensional word embeddings, 20 units each of learning rate,
+
+| Learning Rate | 0 | 0.002 | 0.02 | 0.2 | 2 | 20 | 200 |
| Perplexity | 103.29 | 98.79 | 87.78 | 66.64 | 56.86 | 117.91 | ~ 10^9 |
+
+and training epoch with early stopping. Rest other parameters were set to default setting. $^4$
+
+7. Discourse LSTM surprisal: We estimated the discourse predictability of each word in the sentence using the ADAPT function of the neural complexity toolkit. van Schijndel and Linzen (2018) proposed a simple way to continuously adapt a neural LM to each successive test sentence, and found that adaptive surprisal predicts human reading times significantly better than non-adaptive surprisal. Their method takes a pre-trained LSTM LM, and, after generating surprisals for a test sentence, the parameters of the LM get updated based on the cross-entropy loss for that sentence. After that, the revised LM weights are used to predict the next test sentence. This continuous fine-tuning approach effectively modulates a sentence-level LSTM through discourse priming. In our work, for each test sentence, we used our base LSTM LM and adapted it to the immediately preceding context sentence and then used it to generate (discourse-sensitive) surprisal values for the desired sentence. We used an adaptive learning rate of 2 as it minimized the perplexity of the validation data set (see Table 1).
+
+# 4 Experiments and Results
+
+We tested the hypothesis that discourse predictability (estimated from adaptive LSTM and lexical repetition surprisal) influences constituent ordering in Hindi over other baseline cognitive controls, including dependency length, information status and trigram and non-adaptive surprisal. The adaptive LSTM surprisal had a high correlation with all other surprisal features and a low correlation with
+
+Table 1: Learning rate influence on adaptive LSTM validation perplexity ( $N = 13274$ sentences; the initial non-adaptive model uses a learning rate of 0)
+
+| Predictor | β̂ | σ̂ | t |
| intercept | 1.50 | 0.001 | 1496.47 |
| trigram surprisal | -0.08 | 0.005 | -14.53 |
| dependency length | 0.02 | 0.001 | 15.55 |
| pcfg surprisal | -0.07 | 0.002 | -39.46 |
| IS score | 0.01 | 0.001 | 11.32 |
| lex-rept surprisal | -0.03 | 0.005 | -5.31 |
| lstm surprisal | -0.14 | 0.016 | -9.26 |
| adaptive lstm surprisal | -0.13 | 0.016 | -8.18 |
+
+Table 2: Regression model on full data set $\left( {N = {72833}}\right.$ ; all significant predictors denoted by $\left| \mathrm{t}\right| > 2$ )
+
+dependency length and information status score (see Figure 2 in Appendix C). We report the results of regression and prediction experiments on the full data set as well as on subsets of the data consisting of two types of non-canonical constructions.
+
+# 4.1 Regression Analysis
+
+Our regression results over the entire data set (Table 2) show that all of our measures are significant predictors for the task of classifying reference and variant sentences. The negative regression coefficients for our surprisal metrics (including adaptive LSTM surprisal) indicate that surprisal is consistently lower in the reference sentences compared with the competing variants. And adding adaptive discourse LSTM surprisal into a model containing all other predictors significantly improved the fit of our regression model ( $\chi^2 = 66.81$ ; $p < 0.001$ ). Thus these results support our core hypothesis that word order choices seem to maximize discourse predictability compared with possible alternative productions. The positive regression coefficient for information status (IS) score indicates that reference sentences adhere to given-new ordering. Similarly, adding IS score into a model containing all other predictors significantly improved the fit of our regression model ( $\chi^2 = 127.94$ ; $p < 0.001$ ). However, the positive regression coefficient of dependency length suggests that reference sentences exhibit longer dependency lengths compared to their variant counterparts, violating locality considerations. Thus dependency length might be in conflict with (and/or overridden by) other factors like discourse priming or information locality (see Section 6 for more discussion of this idea).
+
+We also examined the contribution of each predictor on two non-canonical syntactic configura
+
+tions, direct object (DO) fronted and indirect object (IO) fronted constructions, which have been studied extensively in the sentence comprehension literature. Prior work has shown that salient objects tend to occur early in the sentence, thus leading to fronting (Wierzba and Fanselow, 2020; Kaiser and Trueswell, 2004). In the specific context of Hindi, Vasisithth (2004) examined the role of locality effects in processing these non-canonical word orders in salient as well as non-salient contexts. He showed that the increased distance to the verb in DO-fronted sentences leads to high self-paced reading times at the inner-most verb as compared to its canonical counterpart in both salient and non-salient conditions. However, in IO-fronted constructions, he found that salient contexts alleviated the processing difficulty which was caused by increased distance. Based on these findings, we predict that adaptive surprisal should be more effective in IO-fronted than DO-fronted constructions.
+
+To test this hypothesis, we isolated reference sentences where the direct object precedes the subject (for a DO-fronted test set) and reference sentences where the indirect object precedes the subject (for an IO-fronted test set) along with their context sentences. We compared both sets to paired variants that exhibited canonical order (i.e. where the subject preceded both objects). Tables 3a and 3b present regression results for DO- and IO-fronted constructions respectively. These subsets constitute a very small fraction of our dataset due to the infrequency of these constructions in Hindi. The regression coefficient for adaptive LSTM surprisal was significantly negative for both subsets, indicating that the non-canonical structures are more common in the context of similarly non-canonical structures. This pattern is more robust for IO-fronted reference sentences ( $\chi^2 = 90.90$ ; p < 0.001) than for DO-fronted reference sentences ( $\chi^2 = 4.03$ ; p = 0.04), validating our proposed prediction about these constructions. Coming to the efficacy of IS scores over these two non-canonical constructions, givenness is effective in case of DO-fronted reference sentences only ( $\chi^2 = 49.06$ ; p < 0.001). Furthermore, in contrast to the IO-fronted subset, the regression coefficient for dependency length in DO-fronted items is significantly negative suggesting that locality considerations are limited to
+
+constructions involving a high dependency length difference between reference and variants, $^{6}$ a similar finding to that reported in Ranjan et al. (2022a) on the same task.
+
+# 4.2 Prediction Accuracy
+
+While the previous section explored how predictors contribute to Hindi ordering preferences across all of the data in aggregate, in this section we frame our model as a classification task on held-out data to determine how many sentences are affected by each predictor. This enables us to examine the relative performance of different predictors in identifying Hindi reference sentences amidst artificially generated grammatical variants and to conduct more detailed error analysis of our results. We used 10-fold cross-validation to evaluate model classification accuracy, i.e. the percentage of data points where a model correctly predicted the refer- erent sentence over a paired variant, for different subsets of predictors (see Table 4).
+
+Non-adaptive LSTM surprisal (94.01% accuracy) and adaptive LSTM surprisal (94.06%) yielded the best classification accuracies when no other predictors were included. Over a baseline model comprised of every other feature except lexical repetition surprisal (see base2 in Table 4), adaptive LSTM surprisal induced a small but significant increase of $0.03\%$ in accuracy $(p = 0.04$ using McNemar's two-tailed test). When we included lexical repetition surprisal in the baseline model (see base1 in Table 4), adaptive LSTM surprisal ceased to be a significant predictor. This suggests that, in the general case, the maximization of discourse predictability is driven by localized lexical priming captured by our trigram cache model. Apart from the content words, adaptive LSTM surprisal accounts for the re-occurrence of function words (e.g., case markers) which have been shown to modulate syntactic priming and drive parsing processes (Husain and Yadav, 2020).
+
+To study prediction accuracy on non-canonical constructions, we restricted our analyses to IO- and DO-fronted items in the test partition (still training the classifier on the full training partition for each fold). In contrast to the DO-fronted subset, adaptive surprisal was a significant predictor
+
+| Predictor | β | σ | t |
| intercept | 1.49 | 0.008 | 171.18 |
| trigram surfp | -0.28 | 0.049 | -5.84 |
| dep length | -0.05 | 0.008 | -6.22 |
| pcfg surp | 0.001 | 0.014 | 0.12 |
| IS score | 0.04 | 0.006 | 7.04 |
| lex repetition surp | 0.07 | 0.044 | 1.67 |
| lstm surp | 0.03 | 0.114 | 0.23 |
| adaptive lstm surp | -0.23 | 0.113 | -2.00 |
+
+(a) Direct objects (DO; 1663 points) fronted cases
+
+| Predictor | β | σ | t |
| intercept | 1.51 | 0.008 | 188.49 |
| trigram surp | -0.18 | 0.039 | -4.54 |
| dep length | 0.02 | 0.012 | 1.77 |
| pcfg surp | -0.13 | 0.015 | -8.34 |
| IS score | -0.01 | 0.005 | -1.87 |
| lex repetition surp | 0.03 | 0.036 | 0.92 |
| lstm surp | 1.21 | 0.154 | 7.87 |
| adaptive lstm surp | -1.50 | 0.155 | -9.67 |
+
+(b) Indirect objects (IO; 1353 points) fronted cases
+
+Table 3: Discourse adaptation regression model on DO/IO fronted cases (all significant predictors denoted by $\left| t\right| > 2$ )
+
+| Predictors | Full Accuracy % | DO | IO | | Predictors | Full Accuracy % | DO | IO |
| a = IS score | 51.84 | 53.88 | 50.92 | Collective: with repetition effects |
| b = dep length | 62.31*** | 68.49*** | 58.91*** | base1 = a+b+c+d+e+f | 95.05 | 80.99 | 89.06 |
| c = pcfg surp | 86.86*** | 65.90 | 78.86*** | base1 + g | 95.06 | 81.06 | 89.65* |
| d = lex repetition surp | 90.07*** | 77.33*** | 85.07*** | Collective: without repetition effects |
| e = 3-gram surp | 91.18*** | 78.95* | 87.29** | base2 = a+b+c+e+f | 95.06 | 81.24 | 89.65 |
| f = lstm surp | 94.01*** | 79.55 | 87.28 | base2 + g | 95.09* | 81.42 | 89.80 |
| g = adaptive lstm surp | 94.06 | 79.97 | 88.32*** | | | | |
+
+Table 4: Prediction performances (Full data set (72833 points), Direct objects (DO; 1663 points) and indirect object (IO; 1353 points) fronted cases; each row refers to a distinct model; *** McNemar's two-tailed significance compared to model on previous row)
+
+of IO-fronted syntactic choice, even in the presence of lexical repetition surprisal, as is evident from the significant increase of $0.6\%$ in accuracy $(p = 0.02$ using McNemar's two-tailed test; see the rightmost IO column in Table 4). This result indicates that discourse predictability is effective in predicting IO-fronting in sentences that follow other IO-fronted sentences, suggesting the presence of syntactic priming effects. We consider adaptive LSTM LM surprisal (i.e., updating LM weights on successive sentences at test time) as an indicative of syntactic priming in this work but not the vanilla LSTM LM surprisal. We present a more nuanced discussion on this theme in Section 6.
+
+Both our regression and classification results demonstrate that discourse adaptation is more effective in IO-fronted than DO-fronted constructions, mirroring the findings in Hindi sentence comprehension, where Vasishth (2004) showed that discourse context could compensate for the processing difficulty induced by indirect object fronting. The findings of our computational modelling reported in Table 4 are further validated by the agreement accuracy of our human evaluation study described in
+
+Section 3. Participants were more prone to prefer IO-fronted construction (80%) compared to DO-fronted construction (65%) as shown in Table 9 of Appendix G.
+
+# 4.3 Qualitative Analysis: Success of Adaptive LSTM Surprisal
+
+Further linguistic analyses in IO-fronted constructions revealed that LSTM adaptation also captured the priming of given-given items, potentially modeling the preferred ordering of multiple given items, a case not captured by IS score or lexical repetition surprisal. Reference sentence 1a is correctly predicted by the model containing adaptive LSTM surprisal and all other features (i.e., $\text{base1} + g$ in Table 4) but a model without adaptive LSTM surprisal (i.e., base1) predicts the variant Example 1b. Appendix E Table 6 presents the exact scores of different predictors for the referent-variant pairs (1a and 1b). All predictors but LSTM and adaptive LSTM surprisal assign high score for the reference sentence with respect to its paired variant. Adaptive LSTM surprisal assigns a low per-word surprisal for the phrase amar ujala when it comes at
+
+the first position in the reference sentence (1a) with respect to when it comes at the second position in the variant (1b), potentially modeling givenness as this word occurred in the previous sentence (Example 2 in Appendix E) as well. See Figure 3 in Appendix E for the information profile of the reference-variant pairs.
+
+# 4.4 What causes priming?
+
+In the priming literature, there is debate as to whether priming is driven by residual neural activation (short-lived effects) or by humans learning and updating their language expectations (long-lived effects). Bock and Griffin (2000) showed that syntactic priming in humans persisted even when prime and target sentences were separated by 10 intervening sentences, supporting the implicit learning (long-lived) hypothesis of syntactic priming. In order to test this effect on constituent ordering choice, we repeated our adaptation experiment by adapting to additional context sentences from the preceding discourse. Adaptive LSTM surprisal and lexical repetition surprisal were estimated by adapting the base LSTM LM and trigram LM, respectively, to five preceding context sentences, rather than the single context sentence we used for our other analyses. We found that for non-canonical IO/DO-fronted constructions, additional context sentences do not improve the adaptive LSTM LM's word order predictions, suggesting that priming may be driven by short-term residual activation (see Table 8 in the Appendix F).
+
+# 5 Variance Inflation Factor
+
+In this section, we evaluate our regression models for multicollinearity in terms of variance inflation factor (VIF) score. As Figure 2 in Appendix C denotes, the adaptive LSTM surprisal measure has a high correlation with all other surprisal predictors, which raises some suspicion that estimates of effects of the variables in our regression model might be unreliable. Table 10 in Appendix H presents the VIF scores for different regression models containing different set of predictors on full dataset, DO- and IO-fronted subsets. The outcomes indicate that all the surprisal predictors except PCFG surprisal in our original regression models have very high VIF scores (see Table 10a in Appendix H). Nevertheless, removing the more correlated mea
+
+sures, such as trigram surprisal and base LSTM surprisal does not alter any of our old results (see Table 11 for new regression results and Table 10b for corresponding VIF scores in Appendix H). All the surprisal measures including adaptive LSTM and lexical repetitions surprisal have negative regression coefficients suggesting that Hindi tends to optimize for discourse predictability.
+
+# 6 Discussion
+
+Our main findings suggest that in written Hindi, people choose word orders that maximize discourse predictability. The actual psychological mechanisms are conceivably lexical and structural priming. Our results indicate that lexical priming is most influential in canonical sentence contexts, but syntactic priming does influence ordering preferences in non-canonical contexts. Below, we discuss the implications of our findings in terms of the 4 factors affecting syntactic priming discussed in detail by Reitter et al. (2011): inverse frequency interaction, decay, lexical boost, and cumulativity. The IO-fronted construction is very rare (0.76% of our data) compared to DO-fronted non-canonical sentences (1% of our data) in the HUTB corpus of 13274 sentences. We find strong priming effects in IO-fronted constructions but weak priming in the case of DO-fronted constructions, providing evidence for an inverse frequency interaction (Scheepers, 2003; Jaeger and Snider, 2007).
+
+Our finding that priming is not aided by long-term contexts indicates a decay effect in priming, which supports the residual activation (short-lived) hypothesis of priming in comprehension (Pickering and Branigan, 1998). Nevertheless, there has been evidence for implicit learning effects in comprehension as well (Luka and Barsalou, 2005; Wells et al., 2009). More recently, Ranjan et al. (2022b) using a similar setup as our current work argued for the existence of both the accounts viz., residual activation and implicit learning, and demonstrated the role of dual mechanism priming effects (Tooley and Traxler, 2010) in Hindi word order.
+
+Previous work suggests that lexical overlap between prime and target sentences enhances syntactic priming (Pickering and Branigan, 1998; Gries, 2005). The repeated lexical items become cues during sentence planning and bias the speaker to produce similar structures that those repeated lex
+
+ical items tend to occur in. Overall, we find that lexical repetition influences Hindi syntactic choice; however, syntactic priming is observed over and above lexical repetition in non-canonical constructions. It's interesting to note that comparable results have also been reported for English dialogue corpora (Healey et al., 2014; Green and Sun, 2021). We plan to conduct a systematic investigation on Hindi spoken data as a part of future work.
+
+Finally, with regards to the cumulativity of priming, Jaeger and Snider (2007) showed in their corpus study of production of passives and that insertion/omission that the effect of priming increases with the number of primes preceding it. Our work does not investigate this specifically, and more controlled experiments would be required.
+
+The success of LSTM-based surprisal estimates over and above dependency length can also be interpreted in light of Futrell's (2019) point about the limitation of Surprisal Theory with respect to word order. Futrell modified Surprisal Theory by positing that the per-word processing difficulty is proportional to its surprisal given a lossy memory representation of the preceding context. Moreover, Futrell et al. (2020) proposed the Information Locality Hypothesis (ILH) which states that all pairs of words with high mutual information (not merely syntactically related words) tend to be located close to one another. The long window offered by LSTM surprisal thus models relationships between words at varying distances (over and above conventional trigram models). The success of these surprisal estimates for the task of reference sentence prediction provides some preliminary evidence for ILH in the case of word order.
+
+Future work needs to tease apart priming effects of both vanilla LSTM and adaptive LSTM surprisal in the light of recent works. In this work, sentences are treated as independent while estimating their surprisal using vanilla LSTM LM, so there is no way vanilla LSTM can exhibit syntactic priming given the independent sentences. However, Misra et al. (2020) demonstrated that BERT exhibits "priming effect". The BERT LM was able to predict a word with greater probability when the context included a related word than an unrelated word. However, the effect decreased as the amount of information provided by the context increases. In other words, the related prime under high context
+
+tual constraint started acting as distractor—actively demoting the target word in the probability distribution; thus exhibiting "mispriming effect" (Kassner and Schütze, 2020). This could be due to stylistic avoidance of repeated structures/words in the adjacent sentences. Future work also needs to investigate whether word-order preferences can be jointly optimized using multiple factors (Gildea and Jaeger, 2015). In particular, the relationship between the drive to minimize surprisal (as found in this work) and the tendency to make information profiles uniform (Jaeger, 2010) needs to be explored more thoroughly in the light of recent findings (Meister et al., 2021).
+
+Overall, our results demonstrate that Hindi word order preferences are influenced by discourse predictability maximization considerations. The actual mechanisms of discourse effects are plausibly lexical and syntactic priming.
+
+# 7 Limitations
+
+The 'levels' problem discussed in Levy (2018) which posits 2 levels of linguistic optimisation is germane while evaluating our work. Our results are restricted to the level of syntactic choices made by individual speakers or users of a given language over a lifetime (and not at the level of entire grammars and evolutionary timescales). Our experiments conducted on written text need to be performed on spoken data in order to make claims about priming in language production.
+
+# Acknowledgements
+
+We thank the first author's dissertation committee members, Drs. Musam and Samar Husain, as well as the Cornell C.Psyd members for their insightful comments and suggestions on this work. We thank Rupesh Pandey's logistical assistance in gathering the human judgment data for this work. We are also grateful for the thorough feedback provided by the anonymous reviewers of EMNLP 2022, ACL ARR 2021, and COMCO 2021. Finally, the last two authors also thank extramural funding from the Department of Science and Technology of India through the Cognitive Science Research Initiative (project no. DST/CSRI/2018/263).
+
+# References
+
+Manabu Arai, Roger PG Van Gompel, and Christoph Scheepers. 2007. Priming ditransitive structures in comprehension. Cognitive psychology, 54(3):218-250.
+Paul Baker, Andrew Hardie, Tony McEnery, Hamish Cunningham, and Robert Gaizauskas. 2002. Emille: a 67-million word corpus of indic languages: data collection, mark-up and harmonization. In Proceedings of LREC 2002, pages 819-827. Lancaster University.
+Akshar Bharati, Rajeev Sangal, Vineet Chaitanya, Amba Kulkarni, Dipti Misra Sharma, and KV Ramakrishnamacharyulu. 2002. Anncorra: building tree-banks in indian languages. In COLING-02: The 3rd Workshop on Asian Language Resources and International Standardization.
+Rajesh Bhatt, Bhuvana Narasimhan, Martha Palmer, Owen Rambow, Dipti Misra Sharma, and Fei Xia. 2009. A multi-representational and multi-layered treebank for Hindi/urdu. In Proceedings of the Third Linguistic Annotation Workshop, ACL-IJCNLP '09, pages 186-189, Stroudsburg, PA, USA. Association for Computational Linguistics.
+Bock and Z. Griffin. 2000. The persistence of structural priming: Transient activation or implicit learning. Journal of Experimental Psychology, 2(120):177-192.
+J.Kathryn Bock. 1986. Syntactic persistence in language production. Cognitive Psychology, 18(3):355-387.
+Morten H. Christiansen and Nick Chater. 2008. Language as shaped by the brain. Behavioral and Brain Sciences, 31(5):489-509.
+P.R. Clarkson and A. J. Robinson. 1997. Language model adaptation using mixtures and an exponentially decaying cache. In In Proceedings of ICASSP-97, pages 799-802.
+Samvit Dammalapati, Rajakrishnan Rajkumar, and Sumeet Agarwal. 2021. Effects of Duration, Locality, and Surprisal in Speech Disfluency Prediction in English Spontaneous Speech. In Proceedings of the Society for Computation in Linguistics, volume 4, page 10.
+Vera Demberg and Frank Keller. 2008. Data from eyetracking corpora as evidence for theories of syntactic processing complexity. Cognition, 109(2):193-210.
+Vera Demberg, Asad B. Sayeed, Philip J. Gorinski, and Nikolaos Engonopoulos. 2012. Syntactic surprisal affects spoken word duration in conversational contexts. In Proceedings of the 2012 Joint Conference
+
+on Empirical Methods in Natural Language Processing and Computational Natural Language Learning, EMNLP-CoNLL '12, pages 356-367, Stroudsburg, PA, USA. Association for Computational Linguistics.
+Alex B Fine and T Florian Jaeger. 2016. The role of verb repetition in cumulative structural priming in comprehension. Journal of Experimental Psychology: Learning, Memory, and Cognition, 42(9):1362.
+Alex B Fine, T Florian Jaeger, Thomas A Farmer, and Ting Qian. 2013. Rapid expectation adaptation during syntactic comprehension. *PloS one*, 8(10):e77661.
+Richard Futrell. 2019. Information-theoretic locality properties of natural language. In Proceedings of the First Workshop on Quantitative Syntax (Quasy, SyntaxFest 2019), pages 2-15, Paris, France. Association for Computational Linguistics.
+Richard Futrell, Edward Gibson, and Roger P. Levy. 2020. Lossy-context surprisal: An information-theoretic model of memory effects in sentence processing. Cognitive Science, 44(3):e12814.
+Richard Futrell, Kyle Mahowald, and Edward Gibson. 2015. Large-scale evidence of dependency length minimization in 37 languages. Proceedings of the National Academy of Sciences, 112(33):10336-10341.
+Dmitriy Genzel and Eugene Charniak. 2002. Entropy rate constancy in text. In Proceedings of the 40th Annual Meeting on Association for Computational Linguistics, ACL '02, pages 199-206, Stroudsburg, PA, USA. Association for Computational Linguistics.
+Edward Gibson. 2000. Dependency locality theory: A distance-based theory of linguistic complexity. In Alec Marantz, Yasushi Miyashita, and Wayne O'Neil, editors, Image, Language, brain: Papers from the First Mind Articulation Project Symposium. MIT Press, Cambridge, MA.
+Edward Gibson, Richard Futrell, Steven T. Piandadosi, Isabelle Dautriche, Kyle Mahowald, Leon Bergen, and Roger Levy. 2019. How efficiency shapes human language. Trends in Cognitive Sciences, 23(5):389-407.
+Daniel Gildea and T. Florian Jaeger. 2015. Human languages order information efficiently. CoRR, abs/1510.02823.
+Clarence Green and He Sun. 2021. Global estimates of syntactic alignment in adult and child utterances during interaction: Nlp estimates based on multiple corpora. Language Sciences, 85:101353.
+
+Stefan Th. Gries. 2005. Syntactic priming: A corpus-based approach. Journal of Psycholinguistic Research, 34(4):365-399.
+John Hale. 2001. A probabilistic Earley parser as a psycholinguistic model. In Proceedings of the second meeting of the North American Chapter of the Association for Computational Linguistics on Language technologies, NAACL '01, pages 1-8, Pittsburgh, Pennsylvania. Association for Computational Linguistics.
+John A. Hawkins. 1994. A Performance Theory of Order and Constituency. Cambridge University Press, New York.
+John A. Hawkins. 2000. The relative order of prepositional phrases in english: Going beyond manner-place-time. Language Variation and Change, 11(03):231-266.
+John A. Hawkins. 2004. Efficiency and Complexity in Grammars. Oxford University Press.
+John A. Hawkins. 2014. *Cross-Linguistic Variation and Efficiency*. Oxford University Press.
+Patrick GT Healey, Matthew Purver, and Christine Howes. 2014. Divergence in dialogue. *PloS one*, 9(6):e98598.
+Sepp Hochreiter and Jürgen Schmidhuber. 1997. Long short-term memory. Neural computation, 9(8):1735-1780.
+Samar Husain and Himanshu Yadav. 2020. Target complexity modulates syntactic priming during comprehension. Frontiers in Psychology, 11:454.
+T. Florian Jaeger. 2010. Redundancy and reduction: Speakers manage information density. Cognitive Psychology, 61(1):23-62.
+T. Florian Jaeger and Elizabeth Norcliffe. 2009. The cross-linguistic study of sentence production: State of the art and a call for action. Language and Linguistic Compass, 3(4):866-887.
+T. Florian Jaeger and Neal Snider. 2007. Implicit learning and syntactic persistence: Surprisal and cumulativity. University of Rochester Working Papers in the Language Sciences, 3:26-44.
+T. Florian Jaeger and Harold Tily. 2011. Language processing complexity and communicative efficiency. WIRE: Cognitive Science, 2(3):323-335.
+Ayush Jain, Vishal Singh, Sidharth Ranjan, Rajakrishnan Rajkumar, and Sumeet Agarwal. 2018. Uniform Information Density Effects on Syntactic Choice in Hindi. In Proceedings of the Workshop on Linguistic Complexity and Natural Language Processing, pages 38-48, Santa Fe, New-Mexico. Association for Computational Linguistics.
+
+Thorsten Joachims. 2002. Optimizing search engines using clickthrough data. In Proceedings of the Eighth ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, KDD '02, pages 133-142, New York, NY, USA. ACM.
+Y. Kachru. 2006. Hindi. London Oriental and African language library. John Benjamins Publishing Company.
+Elsi Kaiser and John C Trueswell. 2004. The role of discourse context in the processing of a flexible word-order language. Cognition, 94(2):113-147.
+Nora Kassner and Hinrich Schütze. 2020. Negated and misprimed probes for pretrained language models: Birds can talk, but cannot fly. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7811-7818, Online. Association for Computational Linguistics.
+Roland Kuhn and Renato De Mori. 1990. A cache-based natural language model for speech recognition. IEEE transactions on pattern analysis and machine intelligence, 12(6):570-583.
+Roger Levy. 2008. Expectation-based syntactic comprehension. Cognition, 106(3):1126 - 1177.
+Roger P Levy. 2018. Communicative efficiency, uniform information density, and the rational speech act theory.
+Haitao Liu. 2008. Dependency distance as a metric of language comprehension difficulty. Journal of Cognitive Science, 9(2):159-191.
+Haitao Liu, Chunshan Xu, and Junying Liang. 2017. Dependency distance: A new perspective on syntactic patterns in natural languages. *Physics of Life Reviews*, 21:171 - 193.
+Barbara J Luka and Lawrence W Barsalou. 2005. Structural facilitation: Mere exposure effects for grammatical acceptability as evidence for syntactic priming in comprehension. Journal of Memory and Language, 52(3):436-459.
+Clara Meister, Tiago Pimentel, Patrick Haller, Lena Jäger, Ryan Cotterell, and Roger Levy. 2021. Revisiting the Uniform Information Density hypothesis. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 963-980, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Kanishka Misra, Allyson Ettinger, and Julia Rayz. 2020. Exploring bert's sensitivity to lexical cues using tests from semantic priming. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 4625-4635.
+
+Slav Petrov, Leon Barrett, Romain Thibaux, and Dan Klein. 2006. Learning accurate, compact, and interpretable tree annotation. In Proceedings of the 21st International Conference on Computational Linguistics and the 44th Annual Meeting of the Association for Computational Linguistics, ACL-44, pages 433-440, Stroudsburg, PA, USA. Association for Computational Linguistics.
+Martin J. Pickering and Holly P. Branigan. 1998. The Representation of Verbs: Evidence from Syntactic Priming in Language Production. Journal of Memory and Language, 39(4):633-651.
+Ting Qian and T. Florian Jaeger. 2012. Cue effectiveness in communicatively efficient discourse production. Cognitive Science, 36(7):1312-1336.
+Rajakrishnan Rajkumar, Marten van Schijndel, Michael White, and William Schuler. 2016. Investigating locality effects and surprisal in written english syntactic choice phenomena. Cognition, 155:204-232.
+Rajakrishnan Rajkumar and Michael White. 2014. Better surface realization through psycholinguistics. Language and Linguistics Compass, 8(10):428-448. ISSN: 1749-818X.
+Sidharth Ranjan, Sumeet Agarwal, and Rajakrishnan Rajkumar. 2019. Surprisal and Interference Effects of Case Markers in Hindi Word Order. In Proceedings of the Workshop on Cognitive Modeling and Computational Linguistics, pages 30-42, Minneapolis, Minnesota. Association for Computational Linguistics.
+Sidharth Ranjan, Rajakrishnan Rajkumar, and Sumeet Agarwal. 2022a. Locality and expectation effects in Hindi preverbal constituent ordering. Cognition, 223:104959.
+Sidharth Ranjan, Marten van Schijndel, Sumeet Agarwal, and Rajakrishnan Rajkumar. 2022b. Dual mechanism priming effects in Hindi word order. arXiv preprint arXiv:2210.13938.
+David Reitter, Frank Keller, and Johanna D. Moore. 2011. A computational cognitive model of syntactic priming. Cognitive Science, 35(4):587-637.
+Rajeev Sangal, Vineet Chaitanya, and Akshar Bharati. 1995. Natural language processing: a Paninian perspective. PHI Learning Pvt. Ltd.
+C Scheepers. 2003. Syntactic priming of relative clause attachments: persistence of structural configuration in sentence production. Cognition, 89:179-205.
+Adrian Staub. 2015. The effect of lexical predictability on eye movements in reading: Critical review and theoretical interpretation. *Language and Linguistics Compass*, 9(8):311-327.
+
+Andreas Stolcke. 2002. SRILM — An extensible language modeling toolkit. In Proc. ICSLP-02.
+David Temperley. 2007. Minimization of dependency length in written English. Cognition, 105(2):300-333.
+Kristen M Tooley and Matthew J Traxler. 2010. Syntactic priming effects in comprehension: A critical review. Language and Linguistics Compass, 4(10):925-937.
+Marten van Schijndel and Tal Linzen. 2018. A neural model of adaptation in reading. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 4704-4710.
+S. Vasishth. 2004. Discourse context and word order preferences in Hindi. Yearbook of South Asian Languages, pages 113-127.
+Justine B Wells, Morten H Christiansen, David S Race, Daniel J Acheson, and Maryellen C MacDonald. 2009. Experience and sentence processing: Statistical learning and relative clause comprehension. Cognitive psychology, 58(2):250-271.
+Marta Wierzba and Gisbert Fanselow. 2020. Factors influencing the acceptability of object fronting in german. The Journal of Comparative Germanic Linguistics, 23(1):77-124.
+Himanshu Yadav, Ashwini Vaidya, and Samar Husain. 2017. Keeping it simple: Generating phrase structure trees from a Hindi dependency treebank. In TLT.
+
+# Appendix
+
+# A Variant Generation
+
+# (2) Context sentence
+
+amar ujala-ki bhumika nispaksh rehti
+Amar Ujala-GEN role unbiased remain
+hai
+be.PRS.SG
+
+Amar Ujala's role remains unbiased.
+
+(3) a. amar ujala-ko yah sukravar-ko
+Amar Ujala-ACC it friday-on
+daak-se prapt hua
+post-INST receive be.PST.SG
+[Given-Given = 0] (Reference)
+
+Amar Ujala received it by post on Friday.
+
+b. yah amar ujala-ko sukravar-ko daak-se prapt hua [Given-Given = 0] (Variant 1)
+c. sukravar-ko yah amar ujala-ko daak-se prapt hua [New-Given = -1] (Variant 2)
+
+This work uses sentences from the Hindi-Urdu Treebank (HUTB) corpus of dependency trees (Bhatt et al., 2009) containing well-defined subject and object constituents. Figure 1 displays the dependency tree (and a glossary of relation labels) for reference sentence 3a. The grammatical variants were created using an algorithm that took as input the dependency tree corresponding to each HUTB reference sentence. The reordering algorithm permuted the preverbal7 dependents of the root verb and linearized the resulting tree to obtain variant sentences. For example, corresponding to the reference sentence 3a and its root verb "hai" (see figure 1a), the preverbal constituents with parents as "ujala", "yah", "suravar", "daak", and "prapt" were permuted to
+
+generate the artificial variants (3b and 3c). The ungrammatical variants were automatically filtered out using dependency relation sequences (denoting grammar rules) attested in the gold standard corpus of HUTB trees. In the dependency tree 1a, "k4-k1", "k7t-k1", "k3-k7t", and "pof-k3" are dependency relation sequences. In cases where the total number of variants exceeded 100 (a random cutoff), we chose 99 non-reference variants randomly along with the reference sentence.
+
+# B Information Status Annotation
+
+The subject and object constituents in a sentence were assigned a Given tag if any content word within them was mentioned in the preceding sentence or if the head of the phrase was a pronoun. All other phrases were tagged as New. The sentence example 3 illustrates the proposed annotation scheme.
+
+- Example 3a follows Given-Given ordering — The object “Amar Ujala” in the sentence is mentioned in the preceding context sentence 2, it would be annotated as Given. In contrast, the subject “yah” is a pronoun so it would also be tagged as Given following the annotation scheme.
+- Example 3c follows New-Given ordering — The object "sukravar" in the sentence should be tagged as New as it is not mentioned in the preceding context sentence 2. In contrast, the subsequent pronoun "yah", which acts as the subject of the sentence, should be tagged as Given following the annotation scheme.
+
+# C Correlation Plot
+
+The Pearson's correlation coefficients between different predictors are displayed in Figure 2. The adaptive LSTM surprisal has a high correlation with all other surprisal features and a low correlation with dependency length and information status score.
+
+# D Joachims Transformation
+
+This technique converts a binary classification problem into a pair-wise ranking task involving the
+
+
+Figure 1: Example HUTB dependency tree and relation labels
+
+| Label | Dependency relation |
| Invariant syntactic relations |
| k1 | subject/agent |
| k2 | object/patient |
| k3 | instrument |
| k4 | object/recipient |
| k7t | location in time |
| Complex predicate relation |
| pof | parts of conjunct verb |
| pof_cn | parts of compound noun |
| Local word group (lwg) |
| lwg_psp | postposition |
| lwg_vaux | auxiliary verb |
| Symbols |
| rsym | symbol relation |
| (b) Dependency relations |
+
+
+Figure 2: Pearson's coefficient of correlation between different pairs of predictors
+
+feature vectors of a reference sentence and each of its variants. Table 5 displays the Joachims's transformation. The delta $(\delta)$ refers to the difference between the feature vectors of the reference sentence and its paired variant. The overall goal is to model two-alternative choices for each reference sentence such that the speaker generates the reference sentence after rejecting a potential grammatical variant. Moreover, the reference sentence that appeared originally in the corpus must have been present due to its properties (viz., dependency length, discourse context, accessibility, or surprisal), and variant sentences are less likely to be produced due to the same reasons.
+
+# E Information Profile for IO-fronted Example
+
+The LSTM LM, when adapted to the previous sentence (2) in the discourse, assigns a lower surprisal score to the given item when it occurs in the first position ("amar ujala" in sentence 3a) than when it appears in the second position ("amar ujala" in sentence 3b) in the subsequent sentence.
+
+# F Contextual Adaptation on One Vs. Multiple Sentences for DO/IO Constructions
+
+We investigated if adapting the LSTM LM to the preceding five contextual sentences instead of one contextual sentence will help predict word-ordering patterns better for IO/DO constructions. Table 7 showcases perplexity dip on test sentences during 1 vs. 5 contextual sentence adaptation. Table 8 highlights the classification accuracy of different models containing a combination of features. Our results indicate that adding Prev5-adaptive LSTM surprisal in the machine learning model above and beyond every other feature, including Prev1-adaptive surprisal (i.e., Baseline) does not significantly boost prediction accuracy for both IO- and DO-fronted subset. A similar finding was observed when Prev5-lexical-repetition surprisal (Prev5-Lex-Rept LM: base trigram LM interpolated with unigram cache LM containing 5 preceding sentences history) was included in the classifier model above and beyond every other feature (i.e., Baseline) including Prev1-lexical-repetition surprisal (Prev1-Lex-Rept LM: base trigram LM interpolated with unigram cache LM containing only 1
+
+preceding sentence history).
+
+# G Human Evaluation
+
+To determine whether the permuted word order (variant) is dispreferred to the original word order (reference), we conducted a targeted human evaluation via a forced-choice task and collected sentence judgments from 12 Hindi native speakers for 167 randomly selected reference-variant pairs in our data set. Participants were first shown the preceding sentence and then asked to judge the subsequent most likely sentence as the best choice between the reference-variant pair. Each sentence was assigned a human label of "1" if more than $50\%$ participants voted it as best choice else human label of "0". The stimuli belonged to two different constructions, viz., the reference sentence (Ref) has canonical ordering whereas, the variant (Var) has non-canonical ordering (DO-fronted or IO-fronted) and vice versa.
+
+Table 9 presents the results. On the entire dataset containing 167 reference-variant pairs, $89.92\%$ (agreement accuracy) of the reference sentences originally appearing in the HUTB corpus were also preferred by native speakers compared to the artificially generated grammatical variants expressing similar meanings. Moreover, as initially hypothesized, the Hindi participants were more prone to prefer IO-fronted construction $(80\%)$ compared to DO-fronted construction $(65\%)$ as captured by the agreement accuracy validating the findings reported in Table 4. Overall, the full model containing all the features, including adaptive LSTM surprisal, predicted human preferences $(76.65\%)$ much better than corpus choice labels $(74.85\%)$ .
+
+# H Variance Inflation Factor Analysis
+
+Table 10a displays the VIF scores for each predictor in the different regression models. The VIF scores for the regression models without the correlated features, such as trigram surprisal and vanilla LSTM surprisal, are documented in Table 10b. And Table 11 reports the results of the regression experiment when the model did not contain these highly correlated features.
+
+| Condition | Label | Dependency length | n-gram surprisal | pcfg surprisal |
| Reference | 1 | 18 | 24.69 | 61.13 |
| Variant1 | 0 | 20 | 23.80 | 60.67 |
| Variant2 | 0 | 18 | 23.02 | 60.02 |
+
+(a) Original feature values
+
+| Condition | Label | δ Dependency length | δ n-gram surprisal | δ pcfg surprisal |
| Variant1 -Reference | 0 | 2 | -0.89 | -0.46 |
| Reference -Variant2 | 1 | 0 | 1.67 | 1.11 |
+
+(b) Transformed feature values
+Table 5: Joachims transformation
+
+| Type | 3g surp | Deplen | PCFG surp | IS score | LSTM surp | Adaptive LSTM surp | Lex rept surp |
| Example 3a | Reference | 24.69 | 18 | 61.13 | 0 | 91.80 | 89.52 | 23.80 |
| Example 3b | Variant | 23.80 | 20 | 60.67 | 0 | 93.78 | 93.17 | 22.19 |
+
+
+Figure 3: Information profile for the reference-variant pair 3a and 3b
+
+Table 6: Predictor scores for reference-variant pairs (3a, 3b)
+
+| Non-canonical HUTB Sentences | Frequency Count (%) | Baseline Perplexity | Adapted Perplexity (Prev1) | Perplexity Dip (Prev1) | Adapted Perplexity (Prev5) | Perplexity Dip (Prev5) |
| DO | 133 (1%) | 183.92 | 103.40 | -80.52 | 77.33 | -106.59 |
| IO | 101 (0.76%) | 138.78 | 88.26 | -50.52 | 68.45 | -70.33 |
+
+Table 7: Effect of adaptation on discourse sentences (Prev1: Preceding one sentence in discourse, Prev5: Preceding five sentences in discourse)
+
+| Type | Baseline | + Prev5 Adaptive LSTM Surp | + Prev5 Lex-Rept Surp |
| DO | 81.06 | 81.12 | 80.94 |
| IO | 89.65 | 89.73 | 89.51 |
+
+Table 8: Prediction performance (Direct objects (DO: 1663 points), Indirect Objects (IO: 1353 points)); Baseline denotes $base1 + g$ shown in Table 4; bold denotes McNemar's two-tailed significance compared to a baseline model in the same row
+
+| Construction Type (item count) | Agreement (%) human:corpus | Model (%) corpus labels | Model (%) human labels |
| Ref: Canonical | Var: DO-fronted (20) | 95 | 90 | 85 |
| Ref: DO-fronted | Var: Canonical (20) | 65 | 25 | 50 |
| Ref: Canonical | Var: IO-fronted (20) | 100 | 85 | 85 |
| Ref: IO-fronted | Var: Canonical (20) | 80 | 65 | 65 |
| Ref: Non-canonical | Var: Canonical (80) | 85.00 | 66.25 | 71.25 |
| Ref: Canonical | Var: Canonical (87) | 94.25 | 82.76 | 81.61 |
| Total (167) | 89.92 | 74.85 | 76.65 |
+
+Table 9: Targeted human evaluation — Agreement human/curus: Percentages of times human judgment matches with corpus reference choice; Model corpus: Percentages of corpus choice correctly predicted by the classifier containing all the predictors (base1 + g as per Table 4); Model human: Percentages of human label correctly predicted by the classifier containing all the predictors (base1 + g as per Table 4)
+
+| Predictors | Full (72833) | DO (1663) | IO (1353) |
| trigram surp | 27.61 | 18.87 | 18.87 |
| dependency length | 1.18 | 1.46 | 1.46 |
| pcfg surp | 3.08 | 1.86 | 1.86 |
| IS score | 1.01 | 1.03 | 1.03 |
| lex-rept surp | 24 | 16.47 | 16.47 |
| lstm surp | 241.62 | 109.04 | 109.04 |
| adaptive lstm surp | 244.37 | 106.97 | 106.97 |
| PERFORMANCE | | | |
| Residual standard err | 0.271 | 0.294 | 0.354 |
| Multiple R-squared | 0.707 | 0.657 | 0.502 |
| Adjusted R-squared | 0.707 | 0.655 | 0.500 |
+
+(a) All predictors
+
+| Predictors | Full (72833) | DO (1663) | IO (1353) |
| dependency len | 1.18 | 1.42 | 1.18 |
| pcfg surp | 2.95 | 1.73 | 2.08 |
| IS score | 1.01 | 1.01 | 1.06 |
| lex-rept surp | 4.99 | 4.45 | 4.26 |
| adaptive lstm surp | 5.77 | 4.39 | 4.29 |
| PERFORMANCE | | | |
| Residual std. err | 0.271 | 0.357 | 0.304 |
| Multiple R-sqrd | 0.706 | 0.492 | 0.633 |
| Adjusted R-sqrd | 0.706 | 0.490 | 0.631 |
+
+(b) Predictors except trigram and lstm surprisal measures
+Table 10: Variance inflation factor analysis on different regression models containing: (a) all predictors b) all predictors but correlated features; Each column denotes individual models on a given dataset with a different set of predictors; VIF larger than 5 or 10 indicates that the model has problems estimating the coefficient of variables
+
+| Predictor | β̂ | σ̂ | t |
| Intercept | 1.5 | 0.001 | 1493.53 |
| dependency len | 0.02 | 0.0011 | 15.84 |
| pcfg surp | -0.08 | 0.0017 | -43.49 |
| IS score | 0.01 | 0.001 | 11.92 |
| lex-rept surp | -0.09 | 0.0022 | -39.97 |
| adaptive lstm surp | -0.28 | 0.0024 | -116.06 |
+
+Table 11: Regression model on full data set after removing the correlated features ( $N = 72833$ ; all significant predictors denoted by $|\mathbf{t}| > 2$ )
\ No newline at end of file
diff --git a/discoursecontextpredictabilityeffectsinhindiwordorder/images.zip b/discoursecontextpredictabilityeffectsinhindiwordorder/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..d9f1f8679bc47e4d3720f50d3a520f936fa03005
--- /dev/null
+++ b/discoursecontextpredictabilityeffectsinhindiwordorder/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2558413520b42f6e7c6fb63ca3bd0ed58b7de05f688269c8a0520ba629c7fa56
+size 631194
diff --git a/discoursecontextpredictabilityeffectsinhindiwordorder/layout.json b/discoursecontextpredictabilityeffectsinhindiwordorder/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..0e917f016895bd4120341f20ae84920d182f7679
--- /dev/null
+++ b/discoursecontextpredictabilityeffectsinhindiwordorder/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:162d6506ba7b0b9e9572d436b42a99520842649a52ac330e8ce291cffc44c6fb
+size 455562
diff --git a/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_content_list.json b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e10c1c4b5cdf2809e7b8ec48cec9004b77bf14a0
--- /dev/null
+++ b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e2c787f8967c5ec06db12d35b07d5948e045f18d5bd29dde6d76375194c2f8e0
+size 128283
diff --git a/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_model.json b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..d8d9e178d64a53a3c3288bc1ba90c70bbd5c296a
--- /dev/null
+++ b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2d51eeeb6fda89407b62fc02120da28a6a1ba0dd7eb7d28f28b587c3e7c26829
+size 155654
diff --git a/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_origin.pdf b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c10bf5879aa761ebd6a571a15dd61c50766acfb6
--- /dev/null
+++ b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/2283f536-9b35-493d-b929-a6fafebdd4dd_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1af598b6ca0f1bf96cb0773c09ed8dea9689d75cc2e0c82e0a4ecb7292b9928c
+size 1797321
diff --git a/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/full.md b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..6468253c8b73dd6240cda9252158d0283d1183ba
--- /dev/null
+++ b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/full.md
@@ -0,0 +1,450 @@
+# Discovering Differences in the Representation of People using Contextualized Semantic Axes
+
+Li Lucy, Divya Tadimeti, and David Bamman
+
+University of California, Berkeley
+
+{lucy3_li, dtadimeti, dbamman}@berkeley.edu
+
+# Abstract
+
+A common paradigm for identifying semantic differences across social and temporal contexts is the use of static word embeddings and their distances. In particular, past work has compared embeddings against "semantic axes" that represent two opposing concepts. We extend this paradigm to BERT embeddings, and construct contextualized axes that mitigate the pitfall where antonyms have neighboring representations. We validate and demonstrate these axes on two people-centric datasets: occupations from Wikipedia, and multi-platform discussions in extremist, men's communities over fourteen years. In both studies, contextualized semantic axes can characterize differences among instances of the same word type. In the latter study, we show that references to women and the contexts around them have become more detestable over time.
+
+# 1 Introduction
+
+Warning: This paper contains content that may be offensive or upsetting.
+
+Quantifying and describing the nature of language differences is key to measuring the impact of social and cultural factors on text. Past work has compared English embeddings for people to adjectives or concepts (Garg et al., 2018; Mendelsohn et al., 2020; Charlesworth et al., 2022), or projected embeddings against axes representing contrasting attributes (Turney and Littman, 2003; An et al., 2018; Kozlowski et al., 2019; Field and Tsvetkov, 2019; Mathew et al., 2020; Kwak et al., 2021; Lucy and Bamman, 2021b; Fraser et al., 2021; Grand et al., 2022). Static representations for the same word can also be juxtaposed across corpora that reflect different time periods (Gonen et al., 2020; Hamilton et al., 2016). This paradigm of using embedding distances to uncover socially meaningful patterns has also transferred over to studies that measure biases in contextualized embeddings, such as Wolfe and Caliskan (2021)'s finding that BERT
+
+
+Figure 1: An axis is constructed using embeddings of adjectives in selected contexts. These contexts are predictive of synonyms, but not antonyms, of the target adjective during masked language modeling. Token-level embeddings for people are then projected onto this axis.
+
+embeddings of less frequent minority names are closer to words related to unpleasantness.
+
+The use of "semantic axes" is enticing in that it offers an interpretable measurement of word differences beyond a single similarity value (Turney and Littman, 2003; An et al., 2018; Kozlowski et al., 2019; Kwak et al., 2021). Words are projected onto axes where the poles represent anonymous concepts (such as beautiful-ugly), and the projected embedding's location along the axis indicates how similar it is to either concept. Semantic axes constructed using static, type-based embeddings have been used to analyze socially meaningful differences, such as words' associations with class (Kozlowski et al., 2019), or gender stereotypes in narratives (Huang et al., 2021; Lucy and Bamman, 2021b).
+
+Our work investigates the extension and application of semantic axes to contextualized embeddings. We present a novel approach for constructing semantic axes with English BERT embeddings (Figure 1). These axes are built to encourage self-consistency, where anonymous poles are less conflated with each other. They are able to capture semantic differences across word types as well as variation in a single word across contexts. Their ability to differentiate contexts makes them suitable
+
+for studying how a word changes across domains or across individual sentences. These axes are also more self-consistent and coherent than ones created using GloVe and other baseline approaches.
+
+We demonstrate the use of contextualized axes on two datasets: occupations from Wikipedia, and people discussed in misogynistic online communities. We use the former as a case where terms appear in definitional contexts, and characteristics of people are well-known. In the latter longitudinal, cross-platform case study, we examine lexical choices made by communities whose attitudes towards women tend to be salient and extreme. We chose this set of online communities as a substantive use case of our method, in light of recent attention in web science on analyzing online extremism and hate at scale (e.g. Ribeiro et al., 2021b,a; Aliapoulios et al., 2021). There, we analyze language change and variation along axes through a sociolinguistic lens, emphasizing that speakers use language that reflects their social identities and beliefs (CH-Wang and Jurgens, 2021; Huffaker and Calvert, 2017; Card et al., 2016; Lakoff and Ferguson, 2006).
+
+Our code, vocabularies, and other resources can be found in our Github repo: https://github.com/lucy3/context_semanticAxes.
+
+# 2 Constructing semantic axes
+
+Static embeddings. Several formulae for calculating the similarity of a target word to two sets of pole words have been proposed in prior work on static semantic axes. These differ in whether they take the difference between a target word's similarities to each pole (Turney and Littman, 2003), calculate a target word's similarity to the difference between pole averages (An et al., 2018; Kwak et al., 2021), or calculate a target word's similarity to the average of several word pair differences that represent the same anonymous relationship (Kozlowski et al., 2019). We build on the approach of An et al. (2018) and Kwak et al. (2021), because it does not require us to curate multiple paired antonyms for each axis, and it draws out the difference between two concepts before a target word is compared to them, rather than after. We define an axis $V$ containing anonymous sets of adjective vectors, $S_{l} = \{l_{1}, l_{2}, l_{3}, \dots, l_{n}\}$ and $S_{r} = \{r_{1}, r_{2}, r_{3}, \dots, r_{m}\}$ , as the following:
+
+$$
+V = \frac {1}{n} \sum_ {i = 1} ^ {n} l _ {i} - \frac {1}{m} \sum_ {j = 1} ^ {m} r _ {j}.
+$$
+
+Relying on single-word poles for axes can be unstable to the choice of each word (An et al., 2018; Antoniak and Mimno, 2021). An et al. (2018) creates a pole's set of words using the nearest neighbors of a seed word, which may risk conflating unintended meanings or anonymous neighbors (Mrkšić et al., 2016; Sedoc et al., 2017). For example, one axis uses the opposite seed words green and experienced, but green's nearest neighbors include red rather than inexperienced. Instead of using this nearest neighbors approach, we construct poles using WordNet antonym relations. Each end of an axis aggregates synonymous and similar lemmas in WordNet synsets, which are expanded using the similar to relation (Miller, 1992).
+
+Our type-based embedding baseline, GLOVE, uses 300-dimensional GloVe vectors pretrained on Wikipedia and Gigaword (Pennington et al., 2014). We only keep poles where both sides have at least three adjectives that appear in the GloVe vocabulary, and we also exclude acronyms, which are often more ambiguous in meaning. We start with 723 axes, where poles have on average 9.63 adjectives each.
+
+Contextualized embeddings. Static embeddings, however, present a number of limitations. Such embeddings cannot easily handle polysemy or homonymy (Wiedemann et al., 2019), and even when they are trained on different social or temporal contexts, they require additional steps to be aligned (Gonen et al., 2020). Context-specific embeddings also need enough training examples of target words to create usable representations. These limitations prevent the analysis of token-based semantic variation, such as measuring how one mention of a word is more or less beautiful than another. Our main contribution of contextualized axes uses the same WordNet-based formulation as our GloVe baseline. Rather than each word in $S_{l}$ or $S_{r}$ being represented by a single GloVe embedding, we obtain BERT embeddings over multiple occurrences of each adjective. We use BERT-base, as this model is small enough for efficient application on large datasets and is popular in previous work on semantic change and differences (e.g. Hu et al., 2019; Lucy and Bamman, 2021a; Giulianelli et al., 2020; Zhou et al., 2022; Coll Ardanuy et al., 2020; Martinc et al., 2020). It is also used in tutorials for researchers outside of NLP, which means it has high potential use in computational social science and cultural analytics (Mimno et al., 2022).
+
+For contextualized axes, we obtain a potential pool of contexts for adjectives sampled over all of Wikipedia from December 21, 2021, preprocessed using Attardi (2015)'s text extractor. This sample contains up to 1000 sentences, or contexts, that contain each adjective, and we avoid contexts that are too short (over 10 tokens) or too long (over 150 tokens).1
+
+We experiment with two methods of obtaining contextualized BERT embeddings for each adjective: a random "default" (BERT-DEFAULT) and one where contexts are picked based on word probabilities (BERT-PROB). For BERT-DEFAULT, we take a random sample of 100 contextualized embeddings across the adjectives in each pole. Since words can be nearest neighbors with their antonyms in semantic space (Mrkšić et al., 2016; Sedoc et al., 2017), our main approach, BERT-PROB, aggregates word embeddings over contexts that highlight contrasting meanings of axes' poles.
+
+To select contexts, we mask out the target adjective in each of its 1000 sentences, and have BERT-base predict the probabilities of synonyms and antonyms for that masked token. We remove contexts where the average probability of antonyms is greater than that of synonyms, sort by average synonym probability, and take the top 100 contexts. One limitation of our approach is that predictions are restricted to adjectives that can be represented by one wordpiece token. If none of the words on a pole of an axis appear in BERT's vocabulary, we backoff to BERT-DEFAULT to represent that axis.
+
+For each axis type, we also have versions where words' embeddings are $z$ -scored, which has been shown to improve BERT's alignment with humans' word similarity judgements (Timkey and van Schijndel, 2021). For $z$ -scoring, we calculate mean and standard deviation BERT embeddings from a sample of around 370k whole words from Wikipedia. As recommended by Bommasani et al. (2020), we use mean pooling over wordpieces to produce word representations when necessary, and we extend this approach to create bigram representations as well. These embeddings are a concatenation of the last four layers of BERT, as these tend to capture more context-specific information (Ethayarajh, 2019).
+
+| Method | Average C | # of consistent axes |
| GLOVE | 0.101 (0.006) | 503 |
| BERT-DEFAULT | 0.084 (0.006) | 393 |
| BERT-DEFAULTz | 0.111 (0.007) | 468 |
| BERT-PROB | 0.101 (0.006) | 436 |
| BERT-PROBz | 0.133 (0.007) | 512 |
+
+Table 1: A table of $\mathcal{C}$ , averaged across poles, with $95\%$ confidence intervals (CI) in parentheses. The $z$ symbol represents $z$ -scored approaches.
+
+# 3 Internal validation
+
+We internally validate our axes for self-consistency. For each axis, we remove one adjective's embeddings from either side, and compute its cosine similarity to the axis constructed from the remaining adjectives. For BERT approaches, we average the adjective's multiple embeddings to produce only one before computing its similarity to the axis. In a "consistent" axis, a left-out adjective should be closer to the pole it belongs to. That is, if it belongs to $S_{l}$ , its similarity to the axis should be positive. We average these leave-one-out similarities for each pole, negating the score when the adjective belongs to $S_{r}$ , to produce a consistency metric, $\mathcal{C}$ . Table 1 shows $\mathcal{C}$ for different axis-building methods. An axis is "consistent" if both of its poles have $\mathcal{C} \geq 0$ .
+
+GLOVE's most inconsistent axis poles often involve directions, such as east $\leftrightarrow$ west, left-handed $\leftrightarrow$ right-handed, and right $\leftrightarrow$ left. These concepts may be difficult to learn from text without grounding. We find that the various BERT approaches' most inconsistent axes include direction-related ones as well, but they also struggle to separate concepts such as lower-class $\leftrightarrow$ upper-class.
+
+The best method for producing consistent axes is $z$ -scored BERT-PROB, with a significant difference in $\mathcal{C}$ from $z$ -scored BERT-DEFAULT and GLOVE (Mann-Whitney U-test, $p < 0.001$ ). It also produces the highest number of consistent axes. GLOVE presents itself as a formidable baseline, and BERT-DEFAULT struggles in comparison to it.
+
+# 4 External validation
+
+Previous work on static semantic axes validates them using sentiment lexicons, exploratory anal
+
+| Category | Occupation Experiment | Person Experiment |
| Writing | creative, fanciful, fictive | formal, logical, discursive | + folksy, unceremonious, casual | + ignoble, common, plebeian |
| Entertainment | transcribed, taped, recorded | structural, constructive, creative | + trademarked, branded, copyrighted | + emotional, soupy, slushy |
| Art | unostentatious, aesthetic, artistic | creative, fanciful, fictive | + activist, active, hands-on | + practiced, proficient, adept |
| Health | unhealthy, pathologic, asthmatic | rehabilitative, structural, constructive | + confirmable, empirical, experiential | + teotatal, dry, drug-free |
| Agriculture | drifting, mobile, unsettled | rustic, agrarian, bucolic | + boneless, deboned, boned | - rehabilitative, structural, constructive |
| Government | amenable, answerable, responsible | policy-making, political, governmental | + respectful, deferential, honorific | + amenable, answerable, responsible |
| Sports | spry, gymnastic, sporty | zealous, ardent, enthusiastic | - amenable, answerable, responsible | - subject, subservient, dependent |
| Engineering | formal, logical, discursive | rehabilitative, structural, constructive | + coeducational, integrated, mixed | + advanced, high, graduate |
| Science | humanistic, humane, human-centered | zealous, ardent, enthusiastic | + humanistic, humane, human-centered | + stoic, unemotional, chilly |
| Math & statistics | enumerable, estimable, calculable | formal, logical, discursive | + enumerable, estimable, calculable | - amenable, answerable, responsible |
| Social Sciences | humanistic, humane, human-centered | relational, relative, comparative | + significant, portentious, probative | + humanistic, humane, human-centered |
+
+yses, and human-reported associations (An et al., 2018; Kwak et al., 2021; Kozlowski et al., 2019). We perform external validation of self-consistent axes on a dataset where people appear in a variety of well-defined and known contexts: occupations from Wikipedia. We conduct two main experiments. In the first, we test whether contextualized axes can detect differences across occupation terms, and in the second, we investigate whether they can detect differences across contexts.
+
+# 4.1 Data
+
+We collect eleven categories of unigram and bigram occupations from Wikipedia lists: Writing, Entertainment, Art, Health, Agriculture, Government, Sports, Engineering, Science, Math & Statistics, and Social sciences (Appendix A). The number of occupations per category ranges from 3 in Math & Statistics to 48 in Entertainment, with an average of 27.2. We use the MediaWiki API to find Wikipedia pages for occupations in each list if they exist and follow redirects when necessary (e.g. Blogger redirects to Blog). For each occupation's singular form, we extract sentences in its page that contains it. In total, we have 3,015 sentences for 300 occupations.
+
+# 4.2 Term-level experiment (occupations)
+
+Each occupation is represented by a pre-trained GloVe embedding or a BERT embedding averaged over all occurrences on its page. If an axis uses $z$ -scored adjective embeddings, we also $z$ -score the occupation embeddings compared to it. We assign poles to occupations based on which side of the axis they are closer to via cosine similarity. Top poles are highly related to their target occupation category, as seen by the examples for $z$ -scored BERT-PROB in Table 2.
+
+One limitation for interpretability is that word
+
+Table 2: The top two $z$ -scored BERT-PROB axis poles, ordered from left to right, for each occupation category and experiment. Each pole is represented by three example adjectives drawn from the set used to construct that pole. Since the person experiment compares each occupation category to all others, + or - indicates the direction of the shift in axis similarity. For example, sports occupations are still closer to responsible than irresponsible, just less so (-) than other occupations.
+
+| Method | Occupation Experiment | Person Experiment |
| GLOVE | 3.485 (± 0.491) | - |
| BERT-DEFAULT | 3.576 (± 0.429) | 2.697 (± 0.361) |
| BERT-DEFAULTz | 2.636 (± 0.459) | 2.485 (± 0.367) |
| BERT-PROB | 3.333 (± 0.473) | 2.667 (± 0.363) |
| BERT-PROBz | 1.970 (± 0.297) | 2.152 (± 0.404) |
+
+Table 3: Average rank of each axis-building method for each experiment, across human evaluators and occupation categories. $95\%$ CI in parentheses.
+
+embeddings' proximity can reflect any type of semantic association, not just that a person actually has the attributes of an adjective. For example, adjectives related to unhealthy are highly associated with Health occupations, which can be explained by doctors working in environments where unhealthiness is prominent. Therefore, embedding distances only provide a foggy window into the nature of words, and this ambiguity should be considered when interpreting word similarities and their implications. This limitation applies to both static embeddings and their contextualized counterparts.
+
+We conduct human evaluation on this task of using semantic axes to differentiate and characterize occupations. Three student annotators examined the top three poles retrieved by each axis-building approach and ranked these outputs based on semantic relatedness to occupation categories (Appendix B). These annotators had fair agreement, with an average Kendall's $W$ of 0.629 across categories and experiments. Though GLOVE is a competitive baseline, $z$ -scored BERT-PROB is the highest-ranked approach overall (Table 3). This suggests that more self-consistent axes also produce measurements that better reflect human judgements of occupations' general meaning.
+
+# 4.3 Context-level experiment (person)
+
+The identity of a word, and prior associations learned from BERT's training data, have the potential to overpower its in-context use (Field and Tsvetkov, 2019). Thus, we may want to discount word associations originally learned by BERT when we examine the use of a target word in a narrower context. Prior work has shown that words with higher frequency in BERT's training data tend to encode more context-specific information in their embeddings (Ethayarajh, 2019; Zhou et al., 2021; Wolfe and Caliskan, 2021). To investigate whether contextualized axes can measure context changes for people, we replace all occupation bigrams and unigrams with person, a very common word. This also makes contexts across different words comparable to each other, a property which we will leverage later in Section 5.4.
+
+Each person embedding is averaged over one occupation's contexts. The identity of person tends to overpower its similarity to axes across contexts, in that the top-ranked poles are similar across occupation categories. So, in contrast to the previous occupation experiment, additional steps are needed to draw out meaningful differences in how person is used in one group of contexts from its typical use. To do this, we estimate the average cosine similarity to axes of $n$ person embeddings in occupational contexts using 1000 bootstrapped samples, where $n$ is the number of terms in an occupation category. We take the axes with the highest statistically significant ( $p < 0.001$ , one-sample $t$ -test) difference in cosine similarity.
+
+We assume that occupations' Wikipedia pages mention them within definitional contexts, so top-ranked poles should reflect the original occupation replaced by person. These top poles are less intuitive than those outputted by the earlier term-level experiment (Table 2). Still, in some cases, such as for Government and Math & Statistics occupations, we uncover relative differences that distinguish one category from others. We only show three adjectives in the top two poles in Table 2 due to space considerations, but moving further down the list for $z$ -scored BERT-PROB uncovers additional meaningful poles. For example, the pole spry, gymnastic, sporty is the third most prominent shift and highest similarity increase (+) in the person experiment for Sports occupations. In addition, human evaluators preferred BERT-PROB over other approaches (Table 3, Appendix B).
+
+# 5 Measuring change and variation
+
+Now that we have contextualized semantic axes that can measure differences across words and contexts, we apply them onto a domain that can showcase salient and socially meaningful variation. NLP research on harmful language often employs methods that focus on the target group, such as measuring their association with other words (Zannettou et al., 2020; Garg et al., 2018; Tahmasbi et al., 2021; Field and Tsvetkov, 2019), or with biases in models (Wolfe and Caliskan, 2021; Ghosh et al., 2021). We illustrate the application of self-consistent $z$ -scored BERT-PROB axes onto the manosphere, which is a collection of communities with mostly male users who hold alternative beliefs around relationships and gender. We use the same axes we presented earlier, which were created using Wikipedia data, because Wikipedia provides more normative coverage of a variety of adjectives than topic-specific communities. This way, we examine how entities in the manosphere orient themselves against typical adjectival uses and meanings.
+
+The manosphere has been linked to acts of violence in the physical world (Hoffman et al., 2020), and most members believe that men are systemically disadvantaged in society (Van Valkenburgh, 2021; Marwick and Caplan, 2018; Lin, 2017; Ging, 2019). These communities focus on heterosexual relationships and masculinity, and feature a dynamic linguistic landscape. Much prior work on the manosphere has been qualitative, such as ethnographies (Lin, 2017; Lumsden, 2019; Van Valkenburgh, 2021). There have been a few quantitative analyses of their language, usually focusing on phrase and word frequencies in a few communities (Farrell et al., 2019; Gothard et al., 2021; LaViolette and Hogan, 2019; Jaki et al., 2019). As an example involving word vectors, Farrell et al. (2020) uses static embeddings identify the meanings of incels' neologisms by inspecting words' nearest neighbors.
+
+Our case study extends beyond prior work with its methodology and scale. We use contextualized semantic axes to tackle one question: how have references to women and contexts around them changed over fourteen years?
+
+# 5.1 Data
+
+We use a taxonomy of subreddits and external forums described by Ribeiro et al. (2021a), who show that the manosphere began with ideologies such as
+
+pick-up artists (PUA) and Men's Rights Activists (MRA), and evolved into more extreme ones such as The Red Pill (TRP), incels (short for involuntary celibate) and Men Who Go Their Own Way (MGTOW), with users moving from older to newer ideologies. We call this dataset EXTREME_REL, because it contains extreme views of relationships.
+
+We use Reddit posts and comments from March 2008 to December 2019 from subreddits listed in Ribeiro et al. (2021a)'s study, downloaded from Pushshift (Baumgartner et al., 2020). We slightly modify their taxonomy by separating out incel subreddits where the intended userbase are women (femcels), and also include a newer set of subreddits focused on "Female Dating Strategy" (FDS), a women-led community analogous to TRP (Holden, 2020; Clark-Flory, 2021). Therefore, we have 60 subreddits in seven ideological categories: Incels, MGTOW, PUA, MRA, TRP, FDS, and Femcels4 (Appendix C). This Reddit subset of EXTREME_REL contains over 1.3 billion tokens.
+
+We also include seven external forums provided by Ribeiro et al. (2021a). These public forums include A Voice for Men (AVFM), Master Pick-up Artist (MPUA) Forum, The Attraction, incels.co, MGTOW Forum, RooshV, and Red Pill Talk. This forum subset of EXTREME_REL contains over 800 million tokens spanning November 2005 to June 2019, and we remove duplicates and quoted text from posts.
+
+Some experiments use a subset of Reddit that shares a similar topical focus as EXTREME_REL, but may have more mainstream views of women and relationships. We use a list6 of common "Relationship" subreddits: r/relationships, r/dating, r/relationship_advice, r/dating_advice, and r/breakups. We call this dataset GENERAL_REL, and it contains 1.2 billion tokens from September 2009 to December 2019. For Reddit data, we do not use posts and comments written by usernames who have bot-like behavior, which we define as repeating any 10-gram more than 100 times.
+
+# 5.2 Vocabulary
+
+We use a mix of NER, online glossaries, and manual inspection to curate a unique vocabulary of people (details in Appendix D). This vocabulary has 2,434 unigrams and 4,179 bigrams, tokenized using BERT's tokenizer without splitting words into wordpieces (Devlin et al., 2019; Wolf et al., 2020). These terms appear at least 500 times in EXTREME_REL.
+
+Since gender is central to the manosphere, we infer these labels based on terms' social gender in a dataset. For example, accuser is not semantically gendered like girl and woman, but its social gender, estimated using pronouns, is more feminine in EXTREME_REL than GENERAL_REL. We use two stages of gender inference to account for pronoun sparsity and noise. First, we use a list of semantically gendered nouns, and second, we use feminine and masculine pronouns linked to terms via coreference resolution (details in Appendix E). We label each vocabulary term based on its fraction of co-occurring feminine pronouns in EXTREME_REL and GENERAL_REL, separately. We are able to label $72.5\%$ of the vocabulary in EXTREME_REL and $67.0\%$ of it in GENERAL_REL.
+
+# 5.3 Term-level change
+
+Contextualized semantic axes can reveal how word and phrase types change over time. Here, our analyses focus on 1,482 feminine (gender-leaning $>0.75$ ) terms in EXTREME_REL. To capture broad snapshots of words' use, we randomly sample up to 500 sentence-level occurrences of each term in each platform and ideology (e.g. a specific forum or Reddit category) in each year. Overall $z$ -scored BERT embeddings for each vocab word are averages over this stratified sample of its contexts.
+
+The history of the manosphere is characterized by waves of different ideological communities (Ribeiro et al., 2021a). To reflect this characterization through language, we segment our vocabulary based on when terms peak in popularity. We cluster normalized frequency time series for each term using $K$ -Spectral Centroid clustering (KSC) (Yang and Leskovec, 2011). We use their default parameters, including $K = 6$ . In contrast to their original approach, our symmetric distance measure
+
+
+Figure 2: Top five most frequent feminine (gender leaning $>0.75$ ) vocabulary terms in each time series cluster, with their gender-leaning score. In each cluster's figure, cluster centers $\mu$ are thick lines, with time series of all vocab terms in light gray. Cluster centers are scaled down to half the maximum height of words' timelines. All time series start on Nov 2005 and end on Dec 2019.
+
+| Axis | Variance |
| womanly ↔ unwomanly | 0.0207 |
| androgynous ↔ male, female | 0.0105 |
| lovable ↔ detestable | 0.0104 |
| reputable ↔ disreputable | 0.0085 |
| wholesome ↔ sickening | 0.0084 |
| clean ↔ dirty | 0.0078 |
+
+Table 4: The axes with the largest variance among feminine-leaning terms in EXTREME_REL. An extended version of this table with more high-variance axes and examples of top words at each pole is in Appendix F.
+
+$\hat{d}$ is invariant to scaling by $\alpha$ but not to the translation of the time series, so that peaks earlier in time are not clustered with those later in time:
+
+$$
+\hat {d} (x, y) = \frac {| | x - \alpha y | |}{| | x | |},
+$$
+
+where $\alpha = x^{T}y / ||y||^{2}$
+
+"Waves" of term types for people correspond to ideological change. Figure 2 shows examples of feminine terms, but the top masculine terms are often labels of ideological groups, such as mgtow and incels, which we use to estimate which clusters align with ideological up and downturns.8 Cluster A and cluster D tend to have terms that have widespread use.
+
+We examine the shifts of high variance, substantive axes across temporal clusters. High variance axes include those related to gender, appearance, and desirability (Table 4). For example, the lovable versus detestable pole contrasts beautiful girls with degenerate whores. As another example, the axis for clean versus dirty contrasts loyal wife with harlots. Prior studies using toxicity detection and lexicon-based approaches found that hate
+
+
+Figure 3: Average axis scores among temporal clusters of feminine word types introduced in Figure 2. Cluster averages include $95\%$ CI, vertical dotted lines mark axis midpoints, and clusters are split based on overall frequency percentile. Cluster C, E, and F align with later, more hateful ideologies.
+
+and misogyny rose with the arrival of later MG-TOW and incel communities (Farrell et al., 2019; Ribeiro et al., 2021a). Similarly, we find that lexical choices for women are more detestable and dirty in later waves associated with MG-TOW and incels (Figure 3). Often, low and high frequency words share similar patterns in each wave.
+
+# 5.4 Context-level change
+
+Contextualized semantic axes can reveal how the contexts around people have changed over time. Women in online communities can be referenced in a variety of ways (Figure 2). To compare overall changes around women between mainstream and extremist communities, we examine the contexts around feminine (gender-leaning $>0.75$ ) words. We use instances of 287 unigram types, since bigrams can include modifiers that would be considered "context". As discussed earlier, word identities impact measurements of contextual changes across them (Section 4.3). We replace each target word with person or people depending on whether it is singular or plural, estimated through the Python INFLECT package. We choose
+
+
+Figure 4: Contexts around singular (person) or plural (people) feminine words over time in EXTREME_REL and GENERAL_REL along three axes. Time series include $95\%$ CI, and dotted lines mark the peak of major ideological communities (gray labels). These vertical lines are months that have the highest normalized frequencies of words used to refer to their members: puas, mras, trpers, mgtows, and incels.
+
+
+
+
+
+replacements to respect singular/plural forms to ensure ecological validity and not perturb BERT's sensitivity to grammaticality (Yin et al., 2020). We use reservoir sampling to obtain up to 1000 occurrences of person- or people-replaced feminine words in each month on EXTREME_REL and GENERAL_REL.
+
+In comparison to GENERAL_REL, EXTREME_REL has more detestable, sickening, and dirty contexts for women (Figure 4). Both GENERAL_REL and EXTREME_REL discuss relationship issues, but contextualized axes reveal how contrasting and changing attitudes toward women can influence context. Negative associations especially peak during the height of the incels' movement around late 2017 to mid 2019. These persist despite Reddit's ban of r/incels in November 2017 and the quarantine of r/braincels and r/theredpill in September 2018. Thus, the widespread efficacy of community-level moderation is worthy of closer study (e.g. Copland, 2020; Ribeiro et al., 2021b). An advantage of computing scores at the token-level rather than at the type-level is interpretability. That is, one can see which contexts land at the extreme ends of axes (as illustrated in Table 5).
+
+Contextualized semantic axes can also illuminate differences among lexical variables, or different linguistic forms that share the same referential meaning (Nguyen et al., 2021; Labov, 1972). As prominent examples, men-led communities use the lexical innovations femoids and foids, which are shortenings of female humanoids, as dehumanizing words for all women (Chang, 2020; Prazmo, 2020). Two women-led communities, Femcels and
+
+| Example | Score |
| ... use this against us men ... those evil people! | 0.244 |
| ... these people pollute our public ... | 0.240 |
| ... parasite worthless whore people. | 0.234 |
| ... I have two little people and they are absolutely amazing ... | -0.156 |
| people who are this young and attractive ... | -0.144 |
| ... my ideal relationship and people like this ... | -0.137 |
+
+Table 5: Examples of people, when replacing words for women, in different contexts along the lovable $\leftrightarrow$ detestable axis in EXTREME_REL. These examples have the maximum or minimum score in their month, and were included in the sample used in Figure 4.
+
+FDS, use moids as an analogous way to refer to men. Prior work studying three manosphere subreddits showed that the lemmas woman and girl are constructed negatively as immoral, deceptive, incapable and insignificant (Krendel, 2020). We hypothesize that the contexts of community-specific variants should have even more dehumanizing connotations along similar dimensions. In this experiment, we replace all terms (men, moids, foids, femoids, and women) with people.
+
+We sample up to 100 occurrences of each variant in each platform and ideology per year, limiting time ranges to when domain-specific variants are widely used by their home community. We examine the use of variants for men by Femcels and FDS in 2018-2019, and the use of variants for women by all other communities in EXTREME_REL in 2017-2019. Unlike in the person experiment for occupations, we have substantial pools of occurrences to compare. Thus, to find axes that distinguish one
+
+
+Figure 5: Average axis scores, of words used by men-led communities to refer to women (squares), and words used by women-led communities to refer to men (circles). Community-specific variants have lighter colors, and bars indicate $95\%$ CI.
+
+variant from another, we use axis scores as features in random forest classifiers (Pedregosa et al., 2011), and perform binary classification of word identity: women versus foids or femoids, and men versus moids (Appendix G). We rank axes based on their feature importance, and select three highly ranked and relevant axes to show in Figure 5. Shifts along these axes confirm our hypothesis that community-specific variants are more dehumanized than their widely-used counterparts.
+
+# 6 Conclusion
+
+In this work, we examine the capability of contextualized embeddings for discovering differences among words and contexts. Our method uses predicted word probabilities to pinpoint which contexts to include when aggregating BERT embeddings to construct axes. This approach creates more self-consistent axes that better fit different occupation categories, in comparison to baselines. We further demonstrate the use of these axes in a longitudinal, cross-platform case study. Overall, contextualized embeddings offer more flexibility and granularity compared to static ones for the analysis of content across time and communities. That is, rather than train static word embeddings for various subsets of data, we can characterize change and variation at the token-level.
+
+Though we focus on analyzing associations between adjectives and people, our approach can generalize to other types of entities as well. Measuring and comparing the contexts of other entity types should include many of the same considerations we did, such as reducing the conflation of antonyms, controlling for word identity by replacing target words with a shared hypernym, and experimenting with $z$ -scoring. Future work includes understanding why some opposing concepts are conflated in large language models, and how a word embed
+
+ding's identity influences its encoding of contexts.
+
+# 7 Limitations
+
+Aside from computing power requirements (Appendix H), we outline a few additional limitations of our methodology and its application not discussed in the main text.
+
+Domain shift. The use of pretrained BERT on a niche set of communities makes our approaches susceptible to domain shift, such as rare words having less robust embeddings (Zhou et al., 2022, 2021), or target words carrying over learned associations from a broader corpus that are less applicable in a narrower one. Domain shift is difficult to avoid without retraining or further pretraining BERT, which is resource-intensive, may risk catastrophic forgetting, and inaccessible to some disciplines in computational social science (Gururangan et al., 2020; Ramponi and Plank, 2020; Goodfellow et al., 2014). Also, training a large language model on text with toxic and misogynistic origins introduces additional risk of dual use (Kurenkov, 2022). We suggest some potential workarounds that lessen the severity of domain shift, such as replacing target words with common ones for context-focused analyses.
+
+WordNet. WordNet is a popular lexical resource for NLP, but its senses for words can be overly fine-grained (Pilehvar and Camacho-Collados, 2019) and not suitable for all domains. We use WordNet version 3.0, which is included in NLTK, and this version was last updated in 2006. Since English is constantly changing, some synonym and antonym relations may be outdated.
+
+Errors. Our method for drawing out differences in words is better than common baselines yet still imperfect, and some of the opposing concepts in embedding space that BERT struggles to separate may be important for an application domain. Therefore, domain expertise is needed to recognize spurious patterns from real ones and fill these gaps.
+
+In the main text we mention that embeddings offer a "foggy window" into how two concepts may be associated or related, and the exact type of relation is not always clear. For example, if contexts for women are closer to unpleasant, does it mean that the text discusses unpleasant events that affect women, or that the writers believe that women are unpleasant, or both? Some of this uncertainty could be resolved qualitatively by inspecting
+
+sentences at poles' extremes. We compare embeddings for people to axes, but it is also possible to include relation-based approaches such as dependency parsing and compare words that share specific relations with people to axes (e.g. Lucy and Bamman, 2021b). One trade-off of doing this is that informative verbs and adjectives connected to mentions of target groups can be sparse. Our method is able to find that mathematician replaced with person is highly similar to calculable in a variety of sentence structures, such as this one modified off Wikipedia: A person is someone who uses an extensive knowledge of mathematics in their work, typically to solve mathematical problems.
+
+# 8 Ethical considerations
+
+User privacy. Online data opens many doors for research, but its use raises concerns around user privacy. For our use case, we believe that the benefits of our work outweigh privacy-related harms. Consent is infeasible to obtain for large datasets (Buchanan, 2017), and in the manosphere, it is unlikely that users would give consent, especially if the researchers using their data believe that their ideologies are harmful and wrong. Obtaining consent would pose risks to the safety of the researcher (Conway, 2021; Doerfler et al., 2021).
+
+All online discussions included in our work were public when downloaded by their original curators, mainly Baumgartner et al. (2020) and Ribeiro et al. (2021a). Some forums and online glossaries were relocated, shutdown, banned, or made private later on. A user's "right to be forgotten" confronts researchers who have interests in documenting and studying the histories of communities. We truncate the examples shown in our paper rather than use them in full verbatim (Bruckman, 2002).
+
+Communities may expect their posts to stay within their in-group, but the content in our work was posted on public platforms. This publicity and increased visibility plays a key role in how this content impacts others, such as those who view this information and propagate it elsewhere, or those who are direct targets of hate. Common targets such as women and people of color carry a bigger burden when participating in online spaces (Hoffmann and Jonas, 2017), and our broader research agenda aims to mitigate this issue.
+
+Social biases in models and resources. We use WordNet to group similar adjectives into semantic axes, but we observe some socially harmful asso
+
+ciations in this resource. For example, gross and fat are listed as similar lemmas. As another example, WordNet conflates gender and sexuality when androgynous and bisexual are also listed as similar lemmas. The BERT language model, like all large, pretrained models, is also susceptible to social biases in its training data (Bender et al., 2021).
+
+Gender inference. In this paper's main case study, we perform gender inference for word and phrase types. This step was necessary to study how women are portrayed over time, which is a key question due to the centrality of misogyny in these communities. However, perfect prediction of each word's perceived gender in our dataset using pronouns is impossible (Cao and Daume III, 2021). Not all mentions of people co-occur with pronouns, pronouns do not equate gender, and coreference resolution systems can produce errors. So, we approximate the social gender of terms by aggregating coreference patterns over all instances of that term. Since it is difficult to separate noisy errors from meaningful word-level pronoun variation at scale, we had to use a score threshold to pinpoint what words were feminine-leaning enough to be included in our analyses.
+
+Restricting pronouns to the traditional binary of feminine and masculine is limiting, since individuals use other pronouns as well. They/them pronouns are predominantly used to reference plural terms in this dataset, and the coreference model we use does not handle neopronouns. The manosphere and the typical framing under which it is studied is heavily cisheteronormative. We use a frequency cutoff to determine our vocabulary (Appendix D), so references to transgender and nonbinary people may be filtered out. Vocabulary terms retained for transgender people are outdated or typically offensive terms such as transsexuals and transgenderers, and no vocab term includes non-binary, nb, or nonbinary.
+
+# 9 Acknowledgements
+
+We thank Manoel Horta Ribeiro for sharing his dataset and materials for our case study, and Sam Robertson, Alexis Lopez, and Harold Cha for evaluating model outputs. In addition, we are grateful for feedback provided by Nicholas Tomlin, Kaitlyn Zhou, and our anonymous reviewers. This research was supported by funding from the National Science Foundation (DGE-1752814, IIS-1813470, and IIS-1942591).
+
+# References
+
+Max Aliapoulios, Kejsi Take, Prashanth Ramakrishna, Daniel Borkan, Beth Goldberg, Jeffrey Sorensen, Anna Turner, Rachel Greenstadt, Tobias Lauinger, and Damon McCoy. 2021. A large-scale characterization of online incitements to harassment across platforms. In Proceedings of the 21st ACM Internet Measurement Conference, IMC '21, page 621-638, New York, NY, USA. Association for Computing Machinery.
+Jisun An, Haewoon Kwak, and Yong-Yeol Ahn. 2018. SemAxis: A lightweight framework to characterize domain-specific word semantics beyond sentiment. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2450-2461, Melbourne, Australia. Association for Computational Linguistics.
+Maria Antoniak and David Mimno. 2021. Bad seeds: Evaluating lexical methods for bias measurement. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 1889-1904, Online. Association for Computational Linguistics.
+Giuseppe Attardi. 2015. Wikiextractor. https://github.com/attardi/wikiextractor.
+Jason Baumgartner, Savvas Zannettou, Brian Keegan, Megan Squire, and Jeremy Blackburn. 2020. The pushshift reddit dataset. In Proceedings of the international AAAI conference on web and social media, volume 14, pages 830-839.
+Emily M. Bender, Timnit Gebru, Angelina McMillan-Major, and Shmargaret Shmitchell. 2021. On the dangers of stochastic parrots: Can language models be too big? In Proceedings of the 2021 ACM Conference on Fairness, Accountability, and Transparency, FAccT '21, page 610-623, New York, NY, USA. Association for Computing Machinery.
+Dale Beran. 2018. Who are the incels of 4chan and why are they so angry? https://psmag.com/news/who-are-the-incels-of-4chan-and-why-are-the-y-so-angy.
+Rishi Bommasani, Kelly Davis, and Claire Cardie. 2020. Interpreting Pretrained Contextualized Representations via Reductions to Static Embeddings. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4758-4781, Online. Association for Computational Linguistics.
+Amy Bruckman. 2002. Studying the amateur artist: A perspective on disguising data collected inhuman subjects research on the internet. Ethics and Inf. Technol., 4(3):217-231.
+
+Elizabeth Buchanan. 2017. Considering the ethics of big data research: A case of Twitter and ISIS/ISIL. PLOS ONE, 12(12):1-6.
+Yang Trista Cao and Hal Daumé III. 2021. Toward gender-inclusive coreference resolution: An analysis of gender and bias throughout the machine learning lifecycle*. Computational Linguistics, 47(3):615-661.
+Dallas Card, Justin Gross, Amber Boydstun, and Noah A. Smith. 2016. Analyzing framing through the casts of characters in the news. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 1410-1420, Austin, Texas. Association for Computational Linguistics.
+Sky CH-Wang and David Jurgens. 2021. Using sociolinguistic variables to reveal changing attitudes towards sexuality and gender. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 9918-9938, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Winnie Chang. 2020. The monstrous-feminine in the incel imagination: investigating the representation of women as "femoids" on /r/braincels. *Feminist Media Studies*, 0(0):1-17.
+Tessa E. S. Charlesworth, Aylin Caliskan, and Mahzarin R. Banaji. 2022. Historical representations of social groups across 200 years of word embeddings from google books. Proceedings of the National Academy of Sciences, 119(28):e2121798119.
+Kevin Clark and Christopher D. Manning. 2016. Deep reinforcement learning for mention-ranking coreference models. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2256-2262, Austin, Texas. Association for Computational Linguistics.
+Tracy Clark-Flory. 2021. Reddit's Female Dating Strategy, advice for 'queens'. https://jezebel.com/ inside-female-dating-strategy-the-subred dit-that-teach-1847558145.
+Mariona Coll Ardanuy, Federico Nanni, Kaspar Beelen, Kasra Hosseini, Ruth Ahnert, Jon Lawrence, Katherine McDonough, Giorgia Tolfo, Daniel CS Wilson, and Barbara McGillivray. 2020. Living machines: A study of atypical animacy. In Proceedings of the 28th International Conference on Computational Linguistics, pages 4534-4545, Barcelona, Spain (Online). International Committee on Computational Linguistics.
+Maura Conway. 2021. Online extremism and terrorism research ethics: Researcher safety, informed consent, and the need for tailored guidelines. *Terrorism and Political Violence*, 33(2):367-380.
+Simon Copland. 2020. Reddit quarantined: Can changing platform affordances reduce hateful material online? Internet Policy Review: Journal on Internet Regulation, 9(4):1-26.
+
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Periwinkle Doerfler, Andrea Forte, Emiliano De Cristofaro, Gianluca Stringhini, Jeremy Blackburn, and Damon McCoy. 2021. "I'm a professor, which isn't usually a dangerous job": Internet-facilitated harassment and its impact on researchers. Proc. ACM Hum. Comput. Interact., 5(CSCW2).
+Kawin Ethayarajh. 2019. How contextual are contextualized word representations? Comparing the geometry of BERT, ELMo, and GPT-2 embeddings. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 55–65, Hong Kong, China. Association for Computational Linguistics.
+Tracie Farrell, Oscar Araque, Miriam Fernandez, and Harith Alani. 2020. On the use of jargon and word embeddings to explore subculture within the Reddit's cosmosphere. In 12th ACM Conference on Web Science, WebSci '20, page 221-230, New York, NY, USA. Association for Computing Machinery.
+Tracie Farrell, Miriam Fernandez, Jakub Novotny, and Harith Alani. 2019. Exploring misogyny across the manosphere in reddit. In Proceedings of the 10th ACM Conference on Web Science, pages 87-96.
+Anjalie Field and Yulia Tsvetkov. 2019. Entity-centric contextual affective analysis. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 2550-2560, Florence, Italy. Association for Computational Linguistics.
+Kathleen C. Fraser, Isar Nejadgholi, and Svetlana Kiritchenko. 2021. Understanding and countering stereotypes: A computational approach to the stereotype content model. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 600-616, Online. Association for Computational Linguistics.
+Nikhil Garg, Londa Schiebinger, Dan Jurafsky, and James Zou. 2018. Word embeddings quantify 100 years of gender and ethnic stereotypes. Proceedings of the National Academy of Sciences, 115(16):E3635-E3644.
+Sayan Ghosh, Dylan Baker, David Jurgens, and Vinodkumar Prabhakaran. 2021. Detecting cross-geographic biases in toxicity modeling on social media. In Proceedings of the Seventh Workshop on
+
+Noisy User-generated Text (W-NUT 2021), pages 313-328, Online. Association for Computational Linguistics.
+Debbie Ging. 2019. Alphas, betas, and incels: Theorizing the masculinities of the manosphere. *Men and Masculinities*, 22(4):638-657.
+Mario Giulianielli, Marco Del Tredici, and Raquel Fernandez. 2020. Analysing lexical semantic change with contextualised word representations. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 3960-3973, Online. Association for Computational Linguistics.
+Hila Gonen, Ganesh Jawahar, Djamé Seddah, and Yoav Goldberg. 2020. Simple, interpretable and stable method for detecting words with usage change across corpora. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 538-555, Online. Association for Computational Linguistics.
+Ian J. Goodfellow, Mehdi Mirza, Da Xiao, Aaron Courville, and Yoshua Bengio. 2014. An empirical investigation of catastrophic forgetting in gradient-based neural networks. In *In Proceedings of International Conference on Learning Representations (ICLR)*.
+Kelly Gothard, David Rushing Dewhurst, Joshua A. Minot, Jane Lydia Adams, Christopher M. 5-Danforth, and Peter Sheridan Dodds. 2021. The incel lexicon: Deciphering the emergent cryptolect of a global misogynistic community. Available online at https://arxiv.org/abs/2105.12006.
+Gabriel Grand, Idan Asher Blank, Francisco Pereira, and Evelina Fedorenko. 2022. Semantic projection recovers rich human knowledge of multiple object features from word embeddings. Nature Human Behaviour, pages 1-13.
+Suchin Gururangan, Ana Marasovic, Swabha Swayamdipta, Kyle Lo, Iz Beltagy, Doug Downey, and Noah A. Smith. 2020. Don't stop pretraining: Adapt language models to domains and tasks. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8342-8360, Online. Association for Computational Linguistics.
+William L. Hamilton, Jure Leskovec, and Dan Jurafsky. 2016. Cultural shift or linguistic drift? comparing two computational measures of semantic change. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2116-2121, Austin, Texas. Association for Computational Linguistics.
+Bruce Hoffman, Jacob Ware, and Ezra Shapiro. 2020. Assessing the threat of incel violence. Studies in Conflict & Terrorism, 43(7):565-587.
+
+Anna Lauren Hoffmann and Anne Jonas. 2017. Recasting Justice for Internet and Online Industry Research Ethics, Internet Research Ethics for the Social Age: New Cases and Challenges, pages 3-18. Peter Lang.
+Madeleine Holden. 2020. Reddit Female Dating Strategy: 'like Red Pill for women'. https://melmagazine.com/en-us/story/female-dating-strategy-reddit.
+Alexander Miserlis Hoyle, Lawrence Wolf-Sonkin, Hanna Wallach, Isabelle Augenstein, and Ryan Cotterell. 2019. Unsupervised discovery of gendered language through latent-variable modeling. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 1706-1716, Florence, Italy. Association for Computational Linguistics.
+Renfen Hu, Shen Li, and Shichen Liang. 2019. Diachronic sense modeling with deep contextualized word embeddings: An ecological view. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3899-3908, Florence, Italy. Association for Computational Linguistics.
+Tenghao Huang, Faeze Brahman, Vered Shwartz, and Snigdha Chaturvedi. 2021. Uncovering implicit gender bias in narratives through commonsense inference. In *Findings of the Association for Computational Linguistics: EMNLP* 2021, pages 3866-3873, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+David A. Huffaker and Sandra L. Calvert. 2017. Gender, Identity, and Language Use in Teenage Blogs. Journal of Computer-Mediated Communication, 10(2). JCMC10211.
+Sylvia Jaki, Tom De Smedt, Maja Gwoźdź, Rudresh Panchal, Alexander Rossa, and Guy De Pauw. 2019. Online hatred of women in the incels.me forum: Linguistic analysis and automatic detection. Journal of Language Aggression and Conflict, 7(2):240-268.
+Austin C Kozlowski, Matt Taddy, and James A Evans. 2019. The geometry of culture: Analyzing the meanings of class through word embeddings. American Sociological Review, 84(5):905-949.
+Alexandra Krendel. 2020. The men and women, guys and girls of the 'manosphere': A corpus-assisted discourse approach. Discourse & Society, 31(6):607-630.
+Andrey Kurenkov. 2022. Lessons from the GPT-4chan controversy. The Gradient.
+Haewoon Kwak, Jisun An, Elise Jing, and Yong-Yeol Ahn. 2021. Frameaxis: characterizing microframe bias and intensity with word embedding. PeerJ Computer Science, 7:e644.
+William Labov. 1972. Sociolinguistic patterns. 4. University of Pennsylvania press.
+
+George Lakoff and Sam Ferguson. 2006. The framing of immigration. *Rockridge Institute*.
+Jack LaViolette and Bernie Hogan. 2019. Using platform signals for distinguishing discourses: The case of men's rights and men's liberation on reddit. Proceedings of the International AAAI Conference on Web and Social Media, 13(01):323-334.
+Jie Liang Lin. 2017. Antifeminism Online: MGTOW (Men Going Their Own Way), pages 77-96. transcript Verlag.
+Li Lucy and David Bamman. 2021a. Characterizing English variation across social media communities with BERT. Transactions of the Association for Computational Linguistics, 9:538-556.
+Li Lucy and David Bamman. 2021b. Gender and representation bias in GPT-3 generated stories. In Proceedings of the Third Workshop on Narrative Understanding, pages 48-55, Virtual. Association for Computational Linguistics.
+Karen Lumsden. 2019. "I Want to Kill You in Front of Your Children" Is Not a Threat. It's an Expression of a Desire': Discourses of Online Abuse, Trolling and Violence on r/MensRights, pages 91-115. Springer International Publishing, Cham.
+Matej Martinc, Petra Kralj Novak, and Senja Pollak. 2020. Leveraging contextual embeddings for detecting diachronic semantic shift. In Proceedings of the 12th Language Resources and Evaluation Conference, pages 4811-4819, Marseille, France. European Language Resources Association.
+Alice E. Marwick and Robyn Caplan. 2018. Drinking male tears: language, the manosphere, and networked harassment. *Feminist Media Studies*, 18(4):543-559.
+Binny Mathew, Sandipan Sikdar, Florian Lemmerich, and Markus Strohmaier. 2020. The POLAR framework: Polar opposites enable interpretability of pretrained word embeddings. In Proceedings of The Web Conference 2020, WWW '20, page 1548-1558, New York, NY, USA. Association for Computing Machinery.
+Julia Mendelsohn, Yulia Tsvetkov, and Dan Jurafsky. 2020. A framework for the computational linguistic analysis of dehumanization. Frontiers in Artificial Intelligence, 3.
+George A. Miller. 1992. WordNet: A lexical database for English. In Speech and Natural Language: Proceedings of a Workshop Held at Harriman, New York, February 23-26, 1992.
+David Mimno, Melanie Walsh, and Maria Antoniak. 2022. BERT for humanists. http://www.bertforkumanists.org/.
+Nikola Mrkšić, Diarmuid Žéaghdha, Blaise Thomson, Milica Gašić, Lina M. Rojas-Barahona, Pei-Hao Su, David Vandyke, Tsung-Hsien Wen, and Steve Young.
+
+2016. Counter-fitting word vectors to linguistic constraints. In Proceedings of the 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 142-148, San Diego, California. Association for Computational Linguistics.
+Dong Nguyen, Laura Rosseel, and Jack Grieve. 2021. On learning and representing social meaning in NLP: a sociolinguistic perspective. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 603-612, Online. Association for Computational Linguistics.
+F. Pedregosa, G. Varoquaux, A. Gramfort, V. Michel, B. Thirion, O. Grisel, M. Blondel, P. Prettenhofer, R. Weiss, V. Dubourg, J. Vanderplas, A. Passos, D. Cournapeau, M. Brucher, M. Perrot, and E. Duchesnay. 2011. Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12:2825-2830.
+Jeffrey Pennington, Richard Socher, and Christopher Manning. 2014. GloVe: Global vectors for word representation. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 1532-1543, Doha, Qatar. Association for Computational Linguistics.
+Mohammad Taher Pilehvar and Jose Camacho-Collados. 2019. WiC: the word-in-context dataset for evaluating context-sensitive meaning representations. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 1267-1273, Minneapolis, Minnesota. Association for Computational Linguistics.
+Ewelina Praźmo. 2020. Foids are worse than animals. A cognitive linguistics analysis of dehumanizing metaphors in online discourse. *Topics in Linguistics*, 21:16-27.
+Alan Ramponi and Barbara Plank. 2020. Neural unsupervised domain adaptation in NLP—A survey. In Proceedings of the 28th International Conference on Computational Linguistics, pages 6838-6855, Barcelona, Spain (Online). International Committee on Computational Linguistics.
+Manoel Horta Ribeiro, Jeremy Blackburn, Barry Bradlyn, Emiliano De Cristofaro, Gianluca Stringhini, Summer Long, Stephanie Greenberg, and Savvas Zannettou. 2021a. The evolution of the manosphere across the web. In Proceedings of the International AAAI Conference on Web and Social Media, volume 15, pages 196-207.
+Manoel Horta Ribeiro, Shagun Jhaver, Savvas Zannettou, Jeremy Blackburn, Gianluca Stringhini, Emiliano De Cristofaro, and Robert West. 2021b. Do platform migrations compromise content moderation? evidence from r/The_Donald and r/Incels. Proc. ACM Hum.-Comput. Interact., 5(CSCW2).
+
+João Sedoc, Jean Gallier, Dean Foster, and Lyle Ungar. 2017. Semantic word clusters using signed spectral clustering. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 939-949, Vancouver, Canada. Association for Computational Linguistics.
+Nikhil Sonnad and Tim Squirrel. 2019. The alt-right is creating its own dialect. Here's the dictionary. https://qz.com/1092037/the-alt-right-is-creating-its-own-dialect-heres-a-complete-guide/.
+Tim Squirrell. 2018. A definitive guide to Incels part two: the a-z incel dictionary. https://www.timsequirrell.com/blog/2018/5/30/a-definitive-guide-to-incels-part-two-the-blackpill-and-d-vocabulary.
+Fatemeh Tahmasbi, Leonard Schild, Chen Ling, Jeremy Blackburn, Gianluca Stringhini, Yang Zhang, and Savvas Zannettou. 2021. "Go Eat a Bat, Chang!": On the emergence of sinophobic behavior on web communities in the face of COVID-19. In Proceedings of the Web Conference 2021, WWW '21, page 1122-1133, New York, NY, USA. Association for Computing Machinery.
+William Timkey and Marten van Schijndel. 2021. All bark and no bite: Rogue dimensions in transformer language models obscure representational quality. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 4527-4546, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Peter D Turney and Michael L Littman. 2003. Measuring praise and criticism: Inference of semantic orientation from association. ACM Transactions on Information Systems (TOIS), 21(4):315-346.
+Shawn P Van Valkenburgh. 2021. Digesting the red pill: Masculinity and neoliberalism in the cosmos. Men and Masculinities, 24(1):84-103.
+Gregor Wiedemann, Steffen Remus, Avi Chawla, and Chris Biemann. 2019. Does BERT make any sense? interpretable word sense disambiguation with contextualized embeddings. In Proceedings of the 15th Conference on Natural Language Processing (KONVENS 2019): Long Papers, pages 161-170, Erlangen, Germany. German Society for Computational Linguistics & Language Technology.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumond, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+
+Robert Wolfe and Aylin Caliskan. 2021. Low frequency names exhibit bias and overfitting in contextualizing language models. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 518-532, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+
+Jaewon Yang and Jure Leskovec. 2011. Patterns of temporal variation in online media. In Proceedings of the Fourth ACM International Conference on Web Search and Data Mining, WSDM '11, page 177-186, New York, NY, USA. Association for Computing Machinery.
+
+Fan Yin, Quanyu Long, Tao Meng, and Kai-Wei Chang. 2020. On the robustness of language encoders against grammatical errors. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 3386-3403, Online. Association for Computational Linguistics.
+
+Savvas Zannettou, Joel Finkelstein, Barry Bradlyn, and Jeremy Blackburn. 2020. A quantitative approach to understanding online antisemitism. In Proceedings of the International AAAI Conference on Web and Social Media, volume 14, pages 786-797.
+
+Kaitlyn Zhou, Kawin Ethayarajh, and Dan Jurafsky. 2021. Frequency-based distortions in contextualized word embeddings. arXiv preprint arXiv:2104.08465.
+
+Kaitlyn Zhou, Kawin Ethayarajh, and Dan Jurafsky. 2022. Richer countries and richer representations. In Findings of the Association for Computational Linguistics: ACL 2022, pages 2074-2085, Dublin, Ireland. Association for Computational Linguistics.
+
+# A Wikipedia page titles
+
+Table 6 lists the categories of occupations, the titles of Wikipedia pages that list them, and the number of terms in each category. These lists were retrieved in February 2022.
+
+# B Human evaluation for occupations
+
+We recruited three student volunteers with familiarity with NLP coursework and tasks to rank the top poles provided by each axis-building method for our occupation and person experiments. We used Qualtrics to design and launch the survey. Since we were not asking about personal opinions but rather evaluating models, we were determined exempt from IRB review by the appropriate office at our institution. Each question pertains to a specific occupation category, and within each experiment, question order and answer option order are randomly shuffled. Each model option is presented with its top three poles, in order of most to less
+
+| Occupation type | Wikipedia category lists | # of terms |
| Writing | “List of writing occupations” | 27 |
| Entertainment | “List of theatre personnel”, “List of film and television occupations” | 48 |
| Art | “List of artistic occupations” | 32 |
| Health | “List of healthcare occupations” | 47 |
| Agriculture | “Category:Agricultural occupations”, and plant and husbandry subcategory | 29 |
| Government | “Category:Government occupations” | 47 |
| Sports | “Lists of sportspeople” | 24 |
| Engineering | “List of scientific occupations” | 7 |
| Physical, natural, and earth sciences (“Science”) | “List of scientific occupations” | 30 |
| Math & statistics | “List of scientific occupations” | 3 |
| Social sciences | “List of scientific occupations” | 6 |
+
+Table 6: Wikipedia page titles for pages containing lists of occupations.
+
+Hi! Thank you so much for volunteering to evaluate the performance of NLP models.
+
+Please read these instructions carefully.
+
+In this task, you will judge how much lists of adjectives from WordNet outputted by models are semantically related to occupational differences described in Wikipedia. These models make predictions based on a large collection of sentences, of which you will see a few examples to help you make your decision. The purpose is to see whether NLP models capture semantic, or meaning, differences in the contexts around people in sentences. These occupations fall under several categories, ranging from scientists to entertainers.
+
+You are deciding which models' outputs are typically more related to occupations, which may not reflect your personal opinions about occupations.
+
+There are two sets of questions, and 11 questions in each set.
+
+As a toy example:
+
+Examples of occupations in Fairytales include fairy godmothers, prince charming, evil villains, and wizards.
+
+You are given the sets of adjectives below. Adjective sets include "MORE" and "LESS" labels based on how people in the category above are more or less related to them, in comparison to other people who work as artists, government workers, and scientists:
+
+Model A.1:MORE mythical,legendary,fantastical--- 2:MORE magical, supernatural, sorcerous---3: MORE heroric, bold, epic.
+Model B.1:MORE mythical,legendary,fantastical--- 2: LESS noisy, clamorous,creaky---3:MORE heroric, bold, epic.
+Model C.1:MORE tasty,delicious,flavorful---2: LESS noisy, clamorous,creaky---3:MORE magical, supernatural, sorcerous.
+
+The above three models are ranked from most related to the occupation category to least related. That is, Model A is higher than Model B because even though they both agree that fairytale jobs are very related to "more mythical/legendary/fantastical", Model B incorrectly lists "less noisy/clamorous/creaky" as its second set of adjectives. Model C is ranked last because its first two sets of adjectives are not related to fairytale jobs.
+
+Try to be consistent in your rankings. That is, in the example above, you should not rank Model C after A and before B because A and B agree on the first set and overall share two valid adjective sets. Model C is more of an outlier, with only one valid third adjective set.
+
+Figure 6: Instructions and a toy example shown to human evaluators.
+
+relevant. Figure 6 shows screenshots of instructions. In the toy example, the options are labeled with "Model A", "Model B", "Model C", to allow explanation clarity, but in the actual task questions, options are not labeled with model letters to avoid biasing the evaluators towards a specific model. Some annotators expressed that the task was difficult, and for some occupations, different approaches output similar axes, just in different order.
+
+# C Reddit communities
+
+We used a list of subreddits9 for the manosphere provided by (Ribeiro et al., 2021a) in their detailed,
+
+data-driven sketch of the manosphere.
+
+Five of the subreddits included in Ribeiro et al. (2021a)'s taxonomy of the Reddit手掌 sphere (r/malecels, r/lonelynonviolentmen, r/1ncels, r/incelbrotherhood, r/incelspurgatory) were not on Pushshift's dump of Reddit. We curated the list of communities for our new ideological category, Female Dating Strategy (FDS), using a now removed list of FDS's "sister communities" on the subreddit r/FemaleDatingStrategy's sidebar: r/PinkpillFeminism, r/AskFDS, r/FDSSuperFans, r/PornFreeRelationships, and r/FemaleLevelUpStrategy. The Femcels set of subreddits include: r/Trufemcels, r/TheGlowUp, and r/AskTruFemcels. Though the main user base of the手掌 are men, there are also small populations of women in other ideologies as well, such as r/redpillwomen. We mainly portion out FDS and Femcels due to their role in Section 5.4's lexical variant experiment as communities who use moids.
+
+In total we have 12 subreddits in TRP, 11 in MRA, 7 in PUA, 22 in Incels, 3 in MGTOW, 4 in Femcels, and 6 in FDS. The complete list of subreddits and their categories is also in our Github repo.
+
+# D Vocabulary creation
+
+First, we extract nominal and proper persons using NER, keeping ones that are popular (occur at least 500 times in EXTREME_REL), and unambiguous, where at least $20\%$ of its instances in these datasets are tagged as a person. Gathering a substantial number of labels from our domain to train an indomain NER system from scratch is outside the scope of our work, so we experimented with three models trained on other labeled datasets: ACE, contemporary literature, and a combination of both. We evaluated these models on a small set of posts and comments labeled by one author, after retrieving 25 examples per forum or Reddit ideological category using reservoir sampling. The annotator only labeled spans for nominal and named PERSON entities. Table 7 shows the performance of each model on EXTREME_REL. Based on these evaluation results, we chose to use the model trained on contemporary literature.
+
+We extract bigrams and unigrams from detected spans, excluding determiners and possessives whose heads are the root of the span. Named entities that refer to types of people rather than
+
+| Training data | Precision | Recall | F1 |
| ACE | 0.657 | 0.641 | 0.649 |
| Literature | 0.798 | 0.711 | 0.752 |
| Combined | 0.715 | 0.744 | 0.729 |
+
+Table 7: Model performance on a human-annotated sample of Reddit and forum data. The F1 score we used to determine our choice of model is highlighted in bold.
+
+specific individuals were estimated through their co-occurrence with the determiner $a$ , e.g. a Chad.
+
+Then, one author consulted community glossaries and examined in-context use of words to manually correct the list of automatically extracted terms. We include additional popular and unambiguous words not tagged sufficiently often enough by NER, but defined as people in prior work and online resources.
+
+Table 8 lists the sources and glossaries for vocabulary words and the ideologies they include. Some of these sources, such as the Shedding of the Ego, are created by insiders in the community, while some, such as academic papers and news articles, are by outsiders. For each of these glossaries and lists of terms, we manually separated them into two categories: 269 people (singular and plural forms) and 1776 non-people. Two of these sites, Shedding of the Ego and Pualingo, no longer exists, but were publicly available until at least late 2020. We include 93 terms for people that were initially filtered out in our NER pipeline in our final vocabulary, excluding ambiguous ones that also occur often as non-human entities, such as tool (a fool who is taken advantage of) and jaw (short for just another wannabe).
+
+The resulting vocabulary contains niche language, where $20.7\%$ of unigrams are not found in WordNet, and $85.1\%$ of those missing are also not in the Internet resource Urban Dictionary. $^{10}$ The full list is also available in our Github repo.
+
+# E Gender inference
+
+This section includes additional details around our gender inference process.
+
+Our list of semantically gendered terms, or words gendered by definition, expands upon the one used by Hoyle et al. (2019): man, men, boy, boys, father, fathers, son, sons, brother, bothers, husband, husbands, uncle, uncles, nephew,
+
+| Source | Medium | Community |
| Jaki et al. (2019) | academic paper | Incels |
| Ging (2019) | academic paper | Manosphere |
| Farrell et al. (2019) | academic paper | Manosphere |
| Lin (2017) | academic paper | MGTOW |
| Squirrell (2018) | blog | Incels |
| Sonnad and Squirrell (2019) | news | Red Pill |
| Beran (2018) | magazine | Incels |
| Pualingo | website | PUA |
| Rational Wiki | website | Manosphere |
| Shedding of the Ego | blog | MGTOW, PUA |
+
+Table 8: Sources for non-NER detected terminology we include in our study. Shedding of the Ego can be viewed in the Internet Archive. On the other hand, Pualingo was taken down and removed from the Internet archive during the preparation of this paper. In some cases, the focus community is the entire manosphere, while in others, it is a subset.
+
+nephews, emperor, emperors, king, kings, prince, princes, duke, dukes, lord, lords, knight, knights, waiter, waiters, actor, actors, god, gods, policeman, policemen, postman, postmen, hero, heros, wizard, wizards, steward, stewards, woman, women, girl, girls, mother, mothers, daughter, daughters, sister, sisters, wife, wives, aunt, aunts, niece, nieces, empress, empresses, queen, queens, princess, princesses, duchess, duchesses, lady, ladies, dame, dames, waitress, waitresses, actress, actresses, goddess, goddesses, policeman, policewomen, postwoman, postwomen, heroine, heroines, witch, witches, stewardess, stewardesses.
+
+We include the following additional semantically gendered terms: male, males, dude, dudes, guy, guys, boyfriend, boyfriends, bf, female, females, chick, chicks, girlfriend, girlfriends, gf, gal, gals, bro, transmen, transwomen, she, he.
+
+We check if any of the above words appear in a unigram or bigram vocabulary term. Around $29.9\%$ of our vocabulary in EXTREME_REL is gendered through this word list approach.
+
+To infer gender for the remaining words using pronouns, we ran coreference resolution on EXTREME_REL, and extracted all pronouns that are clustered in coreference chains with terms in our vocabulary (Clark and Manning, 2016). We label the masculine to feminine leaning of vocab terms by calculating the proportion of feminine pronouns (she, her, hers, herself) over the sum of feminine and masculine pronouns (he, him, his, himself). We only consider a word to have a usable gender signal if it appears in at least 10 coreference clusters with feminine or masculine pronouns. Since plural
+
+words do not usually appear with $\text{he/she}$ pronouns, we have plural words take on the gender leaning of their singular forms. We pair plural and singular forms using the Python INFLECT package. $^{11}$ We also transfer unigrams' gender to bigrams, after examining the modifiers (the first token) in bigram terms to check that they are not differently and semantically gendered. Around $20.9\%$ of our vocabulary in EXTREME_REL is gendered through pronouns alone, an additional $12.6\%$ is gendered through plural to singular mapping, and an additional $9.1\%$ is gendered through bigram to unigram mapping.
+
+# F High variance axes
+
+Table 9 shows the top vocabulary terms that correspond to the poles of high variance axes.
+
+# G Classification of lexical variants
+
+Our main goal here is to tease out which axes differentiate the contexts of lexical variants, rather than find the best model that performs well on a classification task. Therefore, we choose to use a random forest classifier for its interpretability: it outputs weights that indicate what features were most important across its decisions. We use scikit-learn's implementation, and perform randomized search with 5-fold cross validation and weighted F1 scoring to select model parameters (Table 10). Table 11 shows the most important axis features of these models. In general, the set of most important features did not change much with parameter choices and roughly aligns with axes that showcase the largest mean differences between each pair of variants. That is, the three axes we show in the main text in Figure 5 are also among the top ten ordered by mean difference for men vs. moids and women vs. femoids.
+
+# H Runtime and infrastructure
+
+We only use BERT-base for inference, but the overall runtime cost is high due to the size of our corpora: English Wikipedia and social media discussions. We use one Titan XP GPU with 8 CPU cores for most of the paper, and occasionally expanded to multiple machines with 1080ti and K80 GPUs in parallel when handling social media data. We use BERT for two main purposes: predicting word probabilities to select contexts for constructing axes, and obtaining word embeddings. On one
+
+Feminine
+
+| Axis | Variance | Examples |
| womanly ↔ unwomanly | 0.0207 | female gender, feminine women, feminine woman ↔ hambeast, tomboys, tomboy |
| androgynous ↔ male, female | 0.0105 | manipulative bitch, nympho, moodlewhore ↔ white females, female, females |
| lovable ↔ detestable | 0.0101 | little princess, sweet girl, beautiful girl ↔ stupid cunts, degenerate whores, accusers |
| reputable ↔ disreputable | 0.0085 | great wife, great woman, great women ↔ slut, dirty slut, Sluts |
| wholesome ↔ sickening | 0.0084 | homemakers, healthy woman, healthy women ↔ evil bitch, dirty slut, degenerate whores |
| clean ↔ dirty | 0.0078 | loyal wife, healthy woman, perfect woman ↔ club Sluts, hambeasts, harlots |
| conventional ↔ unconventional | 0.0076 | most women, average female, female counterparts ↔ debbie downer, sissy, fuckbuddy |
| beautiful ↔ ugly | 0.0075 | great girl, beautiful wife, gorgeous girl ↔ fat pig, female rapist, degenerate whores |
| proud ↔ humble | 0.0070 | harlots, manipulative bitch, harlot ↔ zero women, few women, most females |
| competent ↔ incompetent | 0.0069 | female lawyer, good pussy, female judge ↔ harlots, degenerate whores, unattractive woman |
| old ↔ young | 0.0069 | old hags, old hag, old ex ↔ young teen, toddler, toddlers |
+
+Table 9: An extended version of Table 4. The axes with the largest variance among feminine-leaning terms in EXTREME_REL. Examples shown are the top three for each pole.
+
+| Parameter | Choices |
| n_estimators | 50*, 100, 150†‡, 200 |
| criterion | entropy†‡, gini* |
| max_depth | None, 10*, 50, 70†, 100‡ |
| max_features | auto†, sqrt†* |
| min_samples_split | 2†, 5†*, 10, 20 |
| min_samples_leaf | 1‡, 2†*, 4 |
+
+Titan XP GPU, the former takes $\sim 1$ hour for one million sentences containing one masked target word each, and the latter takes $\sim 2.5$ hours for one million sentences, including wordpiece aggregation.
+
+Table 10: Parameter choices for random forest classification. Symbols mark selected parameters for each task, where $\dagger$ refers to men vs. moids, $\ddagger$ refers to women vs. femoids, and $*$ refer to women vs. foids. These models had weighted F1 scores of 0.670, 0.759, and 0.781, respectively.
+
+| Axis | Importance |
| men vs. moids |
| violent ↔ nonviolent | 0.0078 |
| useful ↔ useless | 0.0064 |
| possible ↔ impossible | 0.0064 |
| wholesome ↔ sickening | 0.0063 |
| meaningful ↔ meaningless | 0.0055 |
| women vs. femoids |
| lost (e.g. doomed) ↔ saved | 0.0081 |
| dignified ↔ pathetic | 0.0073 |
| good ↔ evil | 0.0071 |
| meaningful ↔ meaningless | 0.0070 |
| high ↔ low | 0.0063 |
| women vs. foids |
| empirical ↔ theoretical | 0.0112 |
| good ↔ evil | 0.0101 |
| blond ↔ brunet | 0.0095 |
| meaningful ↔ meaningless | 0.0090 |
| shapely ↔ unshapely | 0.0084 |
+
+Table 11: Feature importances in random forest classifiers that predict the identity of a target word, where features are words' axes scores. Bolded axes are featured in the main text in Figure 5.
\ No newline at end of file
diff --git a/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/images.zip b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..0278c0d0fc94025ebc955356c2b433c71dfdd181
--- /dev/null
+++ b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6c560f163d81db5289610b524cb95c995406a3841d0a59335e87a75f1eefa982
+size 596752
diff --git a/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/layout.json b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..5d53105598f022d2c219f5f4d557d4547475b859
--- /dev/null
+++ b/discoveringdifferencesintherepresentationofpeopleusingcontextualizedsemanticaxes/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ea96867564737910588c684b9fbf9ee74f0127d47c4c9eced79c1782ea960bf1
+size 527745
diff --git a/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_content_list.json b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..74c3593606380a2b1a1479224047a727e406a0b4
--- /dev/null
+++ b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:361422ca18add6b7b663a03459a84cd68fc6fcd06a3f7a2a8aba275e684d658c
+size 112598
diff --git a/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_model.json b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..de0379f3378916f2e9a8d2e3c299576b89ae40bb
--- /dev/null
+++ b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2325bd2a79e57b93aff6005aa9d720f379923d0ec50484aa3cd1b5091fcb2159
+size 135327
diff --git a/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_origin.pdf b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..a2cda4282d865267f454fc3816607de2e9b0d306
--- /dev/null
+++ b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/a4bd247c-3325-4527-8069-1ca9c0d8e116_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:67894be2e92668aa327bb68abc02e2346d3ad9aaac253a110f792ec26f8162ca
+size 2420735
diff --git a/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/full.md b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..59bf57d7b263a5b7659142f6d982085ea8b8e15f
--- /dev/null
+++ b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/full.md
@@ -0,0 +1,412 @@
+# Discovering Language-neutral Sub-networks in Multilingual Language Models
+
+Negar Foroutan Mohammadreza Banaei Rémi Lebret
+
+Antoine Bosselut Karl Aberer
+
+{firstname_lastname}@epfl.ch
+
+EPFL
+
+# Abstract
+
+Multilingual pre-trained language models transfer remarkably well on cross-lingual downstream tasks. However, the extent to which they learn language-neutral representations (i.e., shared representations that encode similar phenomena across languages), and the effect of such representations on cross-lingual transfer performance, remain open questions.
+
+In this work, we conceptualize language neutrality of multilingual models as a function of the overlap between language-encoding subnetworks of these models. We employ the lottery ticket hypothesis to discover sub-networks that are individually optimized for various languages and tasks. Our evaluation across three distinct tasks and eleven typologically-diverse languages demonstrates that sub-networks for different languages are topologically similar (i.e., language-neutral), making them effective initializations for cross-lingual transfer with limited performance degradation.
+
+# 1 Introduction
+
+Multilingual language models (MultiLMs) such as mBERT (Devlin et al., 2019), XLM (Conneau and Lample, 2019), and XLM-R (Conneau et al., 2020a) are pre-trained jointly on raw data from multiple languages. Later, when they are fine-tuned for a task using perhaps a single high-resource language dataset, they demonstrate promising zero-shot cross-lingual performance, generalizing to the same task in different languages despite not having been fine-tuned for those languages.
+
+The facilitator of this cross-lingual transfer ability is often hypothesized to be a learned language neutrality in these models (i.e., similar linguistic phenomena across languages are represented similarly by the model). However, the source of this ability remains an open question. Certain studies
+
+
+(a) Step 1: Discover sub-networks in multilingual language models that encode particular languages
+
+
+(b) Step 2: Transfer sub-networks to new languages to evaluate their language neutrality degree
+
+Figure 1: Overview of our approach. We discover sub-networks in the original multilingual language model that are good foundations for learning various tasks and languages (a). Then, we investigate to what extent these sub-networks are similar by transferring them across other task-language pairs (b). In this example, the blue and red lines show sub-networks found for French and Urdu, respectively, and purple connections are shared in both sub-networks. Dashed lines show the weights that are removed in the pruning phase.
+
+have investigated mBERT (a prominent MultiLM) for universal language-neutral components that would facilitate cross-lingual transfer (Libovický et al., 2019; Pires et al., 2019; Libovický et al., 2020). Meanwhile, other studies claim mBERT is not language-neutral as it partitions its multilingual semantic space into separate language-specific subspaces (Singh et al., 2019; Choenni and Shutova, 2020; Wu and Dredze, 2019). However, most of these prior works analyze the language neutrality
+
+of MultiLMs by probing their output contextual representations.
+
+In this paper, language-neutrality is instead conceptualized in terms of the parameters of MultiLMs. We hypothesize that a multilingual model with language-neutral representations would have learned different languages using the same subset of parameters in its network structure. Subnetworks in MultiLMs that overlap across languages, and transfer well when re-trained on other languages from the pre-training corpus, would indicate that the model is comprised of language-neutral representations that jointly encode multiple languages. To demonstrate this effect, we extract sub-networks from MultiLMs by pruning them for individual languages and task pairs using iterative magnitude pruning (Frankle and Carbin, 2019) (Figure 1a). Then, we evaluate the cross-lingual transfer of sub-networks by re-initializing to the unpruned parameters of the original MultiLM, and re-training on task data for different languages (Figure 1b).
+
+Our results on three tasks, namely masked language modeling, named entity recognition (Pan et al., 2017), and natural language inference (Conneau et al., 2018), show high absolute parameter overlap among sub-networks discovered for different languages and effective cross-lingual transfer between languages on the same task (even outperforming the original multilingual model for certain low-resource languages). However, cross-lingual sub-network transfer deteriorates as we increase the sparsity level of the sub-networks, suggesting that language-neutral components of the MultiLMs are pruned in favor of retaining necessary language-and task-specific components for the language-task pair used to discover the sub-network.
+
+# 2 Background & Motivation
+
+Multilingual Language Models. Multilingual language models (MultiLMs) such as mBERT (Devlin et al., 2019), XLM (Conneau and Lample, 2019), and XLM-R (Conneau et al., 2020a) have achieved state of the art results in cross-lingual understanding tasks by jointly pre-training Transformer models (Vaswani et al., 2017) on many languages. Specifically, mBERT has shown effective cross-lingual transfer for many tasks, including named entity recognition (Pires et al., 2019; Wu and Dredze, 2019), cross-lingual natural language inference (Conneau et al., 2018; Hu et al., 2020),
+
+and question answering (Lewis et al., 2020).
+
+Due to these impressive cross-lingual transfer results, many recent works investigate the source of this capacity. One line of study investigates the effect of different pre-training settings (e.g., shared vocabulary, shared parameters, joint multilingual pre-training, etc.) on cross-lingual transfer (K et al., 2020; Artetxe et al., 2020; Conneau et al., 2020b). Other works explore how learned multilingual representations are partitioned into language-specific subspaces (Singh et al., 2019; Wu and Dredze, 2019; Choenni and Shutova, 2020). In contrast to these works, our study explores the existence of language-neutral parameters in MultiLMs. Using iterative magnitude pruning, we extract pruned sub-networks from multilingual LMs for various tasks and languages, and investigate to what extent these sub-networks are similar by transferring them across languages.
+
+Analysis of Multilingual Representations. Prior work has demonstrated the lack of language neutrality in mBERT by comparing the similarity of mBERT's encodings for semantically-similar sentences across multiple languages (Singh et al., 2019), concluding that mBERT partitions the representation space among languages rather than using a shared, interlingual space. In opposition, other efforts show that mBERT learns language-neutral representation space that facilitates cross-lingual transfer (Pires et al., 2019; Libovický et al., 2019; Libovický et al., 2020). These findings have led to attempts to disentangle the language-specific and language-neutral components of mBERT to improve its performance (Libovický et al., 2019; Libovický et al., 2020; Wang et al., 2020; Gonen et al., 2020; Zhao et al., 2021; Lin et al., 2021). The language-neutral component itself can be viewed as the stacking of two sub-networks: a multilingual encoder followed by a task-specific language-agnostic predictor (Müller et al., 2021).
+
+In this work, we discover language-neutral components in the parameters of MultiLMs by pruning them for different language-task pairs. By transferring sub-networks across languages, we investigate to what extent these sub-networks are language-neutral.
+
+Lottery Ticket Hypothesis. The lottery ticket hypothesis (LTH) shows that dense, randomly
+
+initialized neural networks contain small, sparse sub-networks (i.e., winning tickets) capable of being trained in isolation to reach the accuracy of the original network (Frankle and Carbin, 2019). This phenomenon has been observed in multiple applications, including computer vision (Morcos et al., 2019; Frankle et al., 2020) and natural language processing (Gale et al., 2019; Yu et al., 2020).
+
+In particular, the lottery ticket hypothesis has previously been applied to the BERT model (Devlin et al., 2019) using the GLUE benchmark (Wang et al., 2019; Prasanna et al., 2020; Chen et al., 2020). Importantly, Chen et al. (2020) show that sub-networks found using the masked language modeling task can transfer to other tasks. In the context of multilingual language models, (Ansell et al., 2022) propose a sparse LTH-based finetuning method to benefit from both modular and expressive fine-tuning approaches. In this work, we specifically use the lottery ticket hypothesis to examine the possibility of transferring winning tickets across languages, thereby disentangling whether language-neutral and language-specific components of mBERT emerge in winning tickets of different languages.
+
+# 3 Methodology
+
+In this section, we define sub-networks (i.e., winning tickets in the LTH) and identify our approach to discovering them through a pruning algorithm derived from the lottery ticket hypothesis.
+
+Sub-networks. For any network $f(x; \theta)$ with initial parameters $\theta$ , we define a sub-network for $f$ as $f(x; m \odot \theta)$ where $m \in \{0, 1\}^{|\theta|}$ is a binary mask on its parameters and $\odot$ is the element-wise product. The mask $m$ sets many of the parameters of the original network to zero, which prunes edges in the computation graph and yields a sub-network of the original network.
+
+Winning ticket. When training network $f(x; \theta)$ on a task, $f$ reaches maximum evaluation performance $a$ at iteration $i$ . Similarly, when training subnetwork $f(x; m \odot \theta)$ on the same task, $f$ reaches maximum evaluation performance $a'$ at iteration $i'$ . A sub-network $f(x; m \odot \theta)$ is a winning ticket $f^{*}(x; m \odot \theta)$ if it achieves similar or better performance than the original network: $a - a' \leq \epsilon$ when $i' \leq i$ (we set $\epsilon$ to be one standard deviation of performance of the original mBERT model).
+
+Algorithm 1 Iterative magnitude pruning to reach sparsity level $s$ .
+
+Start with mBERT pre-trained weights $\theta_0$
+
+$$
+\text {S e t} p \leftarrow 1 0 \text {a n d} n \leftarrow \frac {s}{p}
+$$
+
+for $r\gets 0$ to $n - 1$ do
+
+$$
+\text {T r a i n} \theta_ {i}
+$$
+
+Prune $p\%$ of the parameters in $\theta_0$
+
+$$
+\text {R e s t} \theta_ {0}
+$$
+
+end for
+
+Return the resulted pruned network
+
+Identifying winning tickets. As shown in Algorithm 1, we use unstructured magnitude iterative pruning (Han et al., 2015) to discover winning tickets. In this approach, an original model is repeatedly trained on a task over multiple rounds $r$ , and a subset of its parameters is pruned in each round until a desired sparsity level $s$ is reached (Frankle and Carbin, 2019; Chen et al., 2020). More specifically, in each round $r$ of training, the model is trained to its peak performance on the task. Then we prune $p\%$ of the original parameters with the lowest magnitudes. After pruning the subset of the weights in a round $r$ , the remaining weights are reset to their original pre-trained initialization, and the model is re-trained on the same dataset again. We set the iterative pruning rate $p = 10$ in all experiments (e.g., five rounds to reach $s = 50\%$ sparsity). To evaluate whether a sub-network is a winning ticket for a task, we check the network's task-specific performance once it has reached the desired sparsity level $s$ . Figure 1 shows an overview of our approach.
+
+# 4 Experimental Setup
+
+# 4.1 Model
+
+In our experiments, we use the cased version of multilingual BERT (mBERT; Devlin et al., 2019). This model is a 12-layer transformer with around 110M parameters. It is pre-trained using the masked language modeling and next sentence prediction training objectives on the Wikipedia dumps for 104 languages. A shared Wordpiece (Wu et al., 2016) vocabulary of size $110\mathrm{k}$ is initialized for these 104 languages.
+
+# 4.2 Tasks & Datasets
+
+We perform our experiments on three different NLP tasks. We have chosen typologically diverse languages covering different language families: Germanic, Romance, Indo-Aryan, and Semitic, and
+
+
+(a) MLM
+
+
+(b) NER
+Figure 2: Performance of pruned sub-networks for each task-language pair at different sparsity levels
+
+
+(c) XNLI
+
+including both high- and low-resource languages from the NLP perspective. These languages are including English (en), French (fr), German (de), Chinese (zh), Russian (ru), Spanish (es), Farsi (fa), Urdu (ur), Arabic (ar), Hindi (hi), and Swahili (sw).
+
+Masked Language Modeling (MLM). For this task, we use 512-token sequences from Wikipedia in each language as the training data.
+
+Named Entity Recognition (NER). We use WikiAnn (Pan et al., 2017), a multilingual named entity recognition and linking dataset built on Wikipedia articles for 282 languages4. Swahili (sw) is not included in this dataset, and Hindi (hi) has a small data size, so these two languages are excluded from the NER experiments.
+
+Natural Language Inference (NLI). We use the cross-lingual natural language inference (XNLI) dataset (Conneau et al., 2018). This dataset includes a subset of examples from MNLI (Williams et al., 2018) translated into 14 languages5. Farsi is not included in this dataset.
+
+# 4.3 Training Details
+
+We tune hyperparameters and select evaluation metrics for each task based on prior work (Chen et al., 2020)6. All results are reported on the development sets of these datasets and are the average of three runs using different random seeds. We use the same number of training and evaluation examples for all languages of a task. Table 7 in the appendix reports pre-training and fine-tuning details. Computational details are reported in Appendix H.
+
+# 5 Experimental Results
+
+In this section, we report our evaluations to study the presence of language-neutral sub-networks in multilingual language models. First, we validate the lottery ticket hypothesis for the mBERT model for various languages and tasks. Then, we compare the winning tickets for different languages by analyzing their parameter overlap and cross-lingual performance. Finally, to further assess the similarity of the winning tickets in a zero-shot setting, we evaluate their performance in a sentence retrieval task.
+
+Existence of Winning Tickets. To discover winning tickets for each task-language pair, we run Algorithm 1 to identify sub-networks at various sparsity levels. Then, we train the pruned sub-networks on the same task and language to identify whether it qualifies as a winning ticket, $f^{*}(x,m\odot \theta)$ .
+
+In Figure 2, we report the performance of pruned sub-networks for each task-language pair at different sparsity levels between 0 and $90\%$ . Winning tickets are found for each language and task at multiple sparsity levels, though as these sub-networks get sparser, they no longer satisfy the winning ticket criterion (performance must be within 1 standard deviation of the full mBERT performance). However, they still often perform within $10\%$ of their winning ticket performance. Interestingly, we find that the performance drop at higher sparsity levels is greater for the MLM and NER tasks than for XNLI, highlighting the importance of evaluating on tasks that induce diverse behavior in sparse models.
+
+Absolute Sub-network Overlap. Given that we can discover suitable winning tickets for every language and task, we now assess the similarity of the discovered sub-networks by comparing their parameter overlap. Sub-network pairs (or larger groups) with higher overlap will be more likely to
+
+
+
+
+(a) MLM
+
+
+(b) NER
+Figure 3: Sparsity pattern overlap between pruned sub-networks across different layers at $50\%$ sparsity level.
+
+
+(c) XNLI
+
+correspond to language-neutral representations in the original mBERT model. To measure parameter overlap between discovered sub-networks for different task-language pairs, we compute the Jaccard similarity between masks $(m_i, m_j)$ from two sub-networks $\left(\frac{m_i \cap m_j}{m_i \cup m_j}\right)$ . In Figure 3, we report the parameter overlap across mBERT's layers for different language pairs across each of the tasks. These results are for sub-networks at $50\%$ sparsity, so we note that the expected Jaccard similarity of two randomly sampled $s = 50\%$ sparse sub-networks would be $33\%$ .
+
+We find that the NER task generally discovers sub-networks with much more overlap across languages, followed by XNLI and MLM. Both NER and XNLI exhibit increasingly overlapping sub-networks at higher layers, while sub-networks discovered for the MLM task increase in overlap up until the middle layers and then drop again. This phenomenon is perhaps partly explained by the upper layers being more task-focused (Merchant et al., 2020). For the MLM task, the model must predict language-specific tokens as the task. While we do not prune the task heads as part of our algorithm, the upper layers of mBERT may still need to be specialized to particular languages to predict their unique vocabularies7.
+
+As a comparison, we establish an upper bound on the expected overlap between languages, by computing the overlap of sub-networks for the same language (pruned using different random seeds). The average overlap of sub-networks across multiple runs is 98.66, 92.23, and 92.23 for the NER, XNLI, and MLM tasks, respectively. In all three tasks, the overlaps across runs are much higher than the mask overlap across languages.
+
+Cross-lingual Transfer of Winning Tickets. We now evaluate the transfer of winning tickets across languages for a given task. Using the discovered sub-networks for each task-language pair (set at a sparsity level of $50\%$ to maintain consistency across languages), we train these sub-networks on the other task-language pairs for the same task and compare their performance against the original subnetwork trained on identical data (i.e., $a(s, t)$ vs $a(t, t)^8$ where $s$ stands for the source language and $t$ stands for the target language). If a transferred sub-network's performance on the target language is within one standard deviation of the target language sub-network's performance, we identify it as a successful transfer, indicating that this winning ticket is more language-neutral than language-specific, as its original parameters are adaptable for different languages.
+
+Figure 4a shows the transfer performance (i.e., the performance drop or gain of the sub-network when trained on the target language compared to when trained on the source language) of MLM winning tickets. For this task, none of the winning tickets for source languages are winning tickets for other languages, meaning that the sub-networks do not achieve similar perplexity as to the target sub-networks when transferred to the target tasks. However, the perplexity increase is relatively limited (within 0.2-0.5 points) compared to a $50\%$ sub-network pruned randomly (rand), suggesting that these language-specific sub-networks do contain shared multi-lingual components.
+
+A similar transfer pattern emerges for the NER task in Figure 4b. None of the transferred subnetworks match the performance of the source lan
+
+
+(a) MLM
+
+
+(b) NER
+
+
+(c) XNLI
+Figure 4: The performance difference of transferring winning tickets across languages (50% sparsity). Each row indicates the source language and each column indicates a target language. Each cell shows the difference in performance between the transferred sub-network and the sub-network discovered from training directly on the target language. We also report the performance drop of a random sub-network (rand) compared to the language sub-network. Blue and red colors indicate performance losses and gains respectively.
+
+guage sub-network. However, the performance remains high, with most target languages maintaining $98\%$ of the target sub-network performance when trained on the source sub-networks (compared to when trained on a random sub-network). Chinese (zh) and Urdu (ur) experience the worst performance drop when we use sub-networks trained for other languages to transfer for these two languages. One explanation could be that Chinese NER is more challenging than other languages due to the lack of capitalization information and the challenge of word segmentation in Chinese. Consequently, Chinese may require more language-specific information that may be pruned from the sub-networks of other languages. The relatively low transfer performance for Urdu may be more empirical. Urdu's sub-network at $50\%$ sparsity has a high performance, outperforming mBERT by 1.2 points, making it a strong baseline.
+
+The results for the XNLI task (depicted in Figure 4c) exhibit a different pattern. For XNLI, the sub-networks found for a language often perform well for other languages, hinting at significant language-neutral components in these subnetworks. At times, these transferred sub-networks even exceed the performance of the source language sub-networks. For example, the French and English winning tickets are also winning tickets for all other languages we examined. The Spanish, Russian, and German sub-networks also transfer well to most other languages. However, the transfer performance of Urdu10 and Swahili sub-networks are worse than other languages, possibly because these two languages were under-represented during mBERT's pre-training, and so contributed less to the model's final parameters compared to other languages11. We also note that Arabic's winning ticket outperforms mBERT by $\sim 1.5$ points for Swahili and Urdu. As both Urdu and Swahili have been historically influenced by Arabic (Spear, 2000; Versteegh, 2014), they may benefit from Arabic being a high resource language in the pre-training corpus.
+
+
+Figure 5: The performance difference of transferring winning tickets across languages (50% sparsity) for the XNLI task on the mT5 model.
+
+Interestingly, the parameter overlaps of all the language pairs do not always predict their crosslingual transfer performance. For MLM, the lower relative degree of sub-network overlap between languages does align with the observed performance drop when transferring winning tickets between languages (Figure 4a). Similarly, an increased overlap is observed among XNLI sub-networks, corresponding to improved transfer performance between languages. When looking at the NER sub-networks, however, which have the highest pairwise overlap, we do not observe successful transfer results (Figure 4b). We conjecture that transfer for NER may require specialized knowledge about the entities likely to be discussed in a particular language (e.g., Chinese Wikipedia articles in the NER dataset may contain more information about Chinese public and historical figures). Consequently, even if a high overlap is observed, the non-overlapping parameters in these sub-networks are crucial for successful task performance $^{12}$ .
+
+To investigate to what extent these observations generalize to other models, we repeat the same experiments for the mT5 model (Xue et al., 2021). This model is a multilingual text-to-text transformer with 12 layers and 580 million parameters and is trained on a multilingual variant of the C4 dataset (mC4; Raffel et al., 2020) covering 101 languages. We formulate the XNLI task into a text-to-text format similar to the mT5 paper by generating the label text from the concatenation of the premise and hypothesis. Figure 5 shows the
+
+
+
+
+Figure 6: Average cross-transfer performance drop for sub-networks with sparsity levels $50\%$ and $80\%$ . For each source language and task, the relative average is computed across the other languages and the same task.
+
+cross-lingual transfer performance for the XNLI task at $50\%$ sparsity level. $^{14}$ For most cases, the transfer performance drop is relatively small, and, as with mBERT, similar languages such as English, Spanish, French, and German transfer well to most of the other languages, suggesting that language-neutral parameters are a common phenomenon in different MultiLMs.
+
+Impact of Sub-network Density. To investigate the effect of sparsity on the retainment of language-neutral components, we compare the cross-lingual transferability of mBERT sub-networks at $50\%$ and $80\%$ sparsity levels. Figure 6 shows the average of relative transfer performance drop per language for the NER and XNLI tasks. Each bar represents an average performance drop after retraining (and evaluating) the sub-network for the source language on all the target languages, individually. As we increase the sparsity level of a sub-network, its cross-lingual transferability degrades considerably (i.e., the relative performance drop increases), indi
+
+cating that there were language-neutral parameters at $50\%$ sparsity level facilitating the cross-lingual transfer that were pruned in the $80\%$ sparse subnetwork. As we decrease the model's capacity by pruning more parameters, the model relies more on language- and task-specific parameters than those that may facilitate the cross-lingual transfer.
+
+Parallel Sentence Retrieval. To further assess the language neutrality of mBERT, we compare the behavior of different sub-networks in a zero-shot setting where they are used as feature extractors. We evaluate each sub-network's sentence retrieval accuracy (Pires et al., 2019) on the English-to-French translation test set from the WMT14 dataset (3003 sentence pairs). This task aims to find sentence pairs from two corpora in two different languages, where the two sentences of each pair are corresponding translations of one another. In these experiments, we use the parallel retrieval implementation from LASER with the margin-based scoring function from (Artetxe and Schwenk, 2019). We use the average of the token embeddings for each sentence (coded using the sub-networks) as the retrieval inputs.
+
+We observe that both the similarity across the sub-networks (Figure 3a) and the top-5 retrieval accuracy (Figure 7) increase as we go into the middle layers of mBERT. XNLI's winning tickets perform better than the other two tasks, and some of these sub-networks even reach the same zero-shot accuracy as the full mBERT model. One possible explanation is that both the XNLI task and parallel sentence retrieval require a richer semantic interpretation of the text. Hence, XNLI winning tickets are better sub-networks for parallel sentence retrieval as they must capture semantic knowledge to successfully complete the task. In the case of NER, the sub-networks of different languages perform similarly across all layers, which is unsurprising given the high amount of overlap between these sub-networks. In a zero-shot setting with no language-specific tuning for the task, these sub-networks are basically identical. For MLM, the sub-networks perform similarly up to the middle layers, where they begin to diverge, supporting the hypothesis that higher layers in the MLM sub-networks are dedicated toward representing the task, which is language-specific for MLM.
+
+| Model / Sub-network | Target Language |
| ar | de | es | ru | ur |
| mBERT | 88.69 | 89.08 | 91.11 | 89.22 | 95.52 |
| f* | 88.5 | 89.01 | 91.08 | 89.03 | 96.44 |
| en | 87.23 | 87.52 | 90.44 | 88.47 | 93.93 |
| fa | 87.56 | 87.57 | 90.18 | 88.34 | 94.10 |
| fr | 87.41 | 87.83 | 90.56 | 88.50 | 94.42 |
| zh | 87.01 | 87.67 | 90.11 | 88.21 | 93.65 |
| en-fa-fr-zh | 87.64 | 87.81 | 90.77 | 88.34 | 94.59 |
+
+Table 1: Performance (F1-score) of winning tickets at $50\%$ sparsity level for combining training datasets of en, fa, fr, and zh languages for the NER task.
+
+Multilingual Sub-networks. Observing the benefit of transferring sub-networks from high-resource languages to lower resource ones (e.g., Arabic to Urdu and Swahili for NER), we study the impact of combining datasets from multiple languages to discover multilingual winning tickets. In this set of experiments, we combined English, Farsi, French, and Chinese datasets together to prune mBERT for the NER task. For parity, we use an identically-sized combined training dataset with 20,000 samples (the same as other experiments on this task), keeping only $25\%$ of each of each language's dataset. Table 1 shows the transfer results of the resulting sub-network at $50\%$ sparsity level. For three out of five languages that we evaluated transfer performance on, the sub-network extracted using the combination of languages outperforms the sub-networks found using each training language separately. The inclusion of multiple languages in the corpus may encourage recovering more language-neutral sub-networks than discovering sub-networks using only a single language.
+
+# 6 Conclusion
+
+While multilingual pre-trained language models have shown impressive performance across languages, the role of language neutrality in achieving such a performance is not well understood. In this work, we analyze the language-neutrality of multilingual models by investigating the overlap between language-encoding sub-networks of these models. Using mBERT as a foundation, we expose the extent of its language neutrality by employing the lottery ticket hypothesis and comparing the sub-networks within mBERT obtained for various languages and tasks. We show that such sub-networks achieve high performance after being transferred across tasks and languages and are similar to one
+
+
+
+
+(a) MLM
+
+
+(b) NER
+
+
+(c) XNLI
+Figure 7: Parallel sentence retrieval accuracy on English-to-French translation using winning tickets. We use the average of the contextual embeddings of each sentence as the retrieval inputs.
+
+another. However, at higher levels of sparsity, this transferability evaporates. Our results suggest that multilingual language models include two separate language-neutral and language-specific components, with the former playing a more prominent role in cross-lingual transfer performance.
+
+# Limitations
+
+In this work, we use network parameter overlap to measure similarity between sub-networks discovered for different languages. However, while cross-lingual transfer performance coarsely tracks with sub-network overlap, these results may not hold at a fine-grained level. While high sub-network overlap is an indicator that a sub-network will effectively transfer to a target language, small relative differences in cross-lingual performance across languages do not correlate strongly with overlap. Consequently, absolute overlap may be limited as an analogue for identifying language-neutral components of multilingual models. Another limitation is that we only use the lottery ticket hypothesis as a method for discovering language-specific subnetworks, while other pruning and masking methods may provide complementary or competing insights. Finally, due to computational limitations, we only apply our work to three tasks and eleven languages. While our selection is diverse, new insights may emerge from a larger cross-section.
+
+# Acknowledgements
+
+The authors thank the anonymous reviewers for their valuable comments and feedback. We also thank the members of LSIR and NLP labs at EPFL for their feedback and support. Antoine Bosselut gratefully acknowledges the support of Innosuisse under PFFS-21-29, the EPFL Science Seed Fund, the EPFL Center for Imaging, Sony Group Corporation, and the Allen Institute for AI.
+
+# References
+
+Alan Ansell, Edoardo Maria Ponti, Anna Korhonen, and Ivan Vulic. 2022. Composable sparse fine-tuning for cross-lingual transfer. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), ACL 2022, Dublin, Ireland, May 22-27, 2022, pages 1778-1796. Association for Computational Linguistics.
+Mikel Artetxe, Sebastian Ruder, and Dani Yogatama. 2020. On the Cross-lingual Transferability of Monolingual Representations. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics (ACL), pages 4623-4637.
+Mikel Artetxe and Holger Schwenk. 2019. Margin-based parallel corpus mining with multilingual sentence embeddings. In Proceedings of the 57th Conference of the Association for Computational Linguistics, ACL 2019, Florence, Italy, July 28-August 2, 2019, Volume 1: Long Papers, pages 3197-3203. Association for Computational Linguistics.
+Tianlong Chen, Jonathan Frankle, Shiyu Chang, Sijia Liu, Yang Zhang, Zhangyang Wang, and Michael Carbin. 2020. The Lottery Ticket Hypothesis for Pretrained BERT Networks. In Proceedings of the 2020 Annual Conference on Neural Information Processing Systems (NeurIPS).
+Ethan A. Chi, John Hewitt, and Christopher D. Manning. 2020. Finding Universal Grammatical Relations in Multilingual BERT. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics (ACL), pages 5564-5577.
+Rochelle Choenni and Ekaterina Shutova. 2020. What does it mean to be language-agnostic? Probing multilingual sentence encoders for typological properties. CoRR, abs/2009.12862.
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettle-moyer, and Veselin Stoyanov. 2020a. Unsupervised Cross-lingual Representation Learning at Scale. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics (ACL), pages 8440-8451.
+
+Alexis Conneau and Guillaume Lample. 2019. Crosslingual Language Model Pretraining. In Proceedings of the 2019 Annual Conference on Neural Information Processing Systems (NeurIPS), pages 7057-7067.
+Alexis Conneau, Rudy Rinott, Guillaume Lample, Adina Williams, Samuel R. Bowman, Holger Schwenk, and Veselin Stoyanov. 2018. XNLI: Evaluating Crosslingual Sentence Representations. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2475-2485.
+Alexis Conneau, Shijie Wu, Haoran Li, Luke Zettlemoyer, and Veselin Stoyanov. 2020b. Emerging Cross-lingual Structure in Pretrained Language Models. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics (ACL), pages 6022–6034.
+Wietse de Vries, Andreas van Cranenburg, and Malvina Nissim. 2020. What's so special about bert's layers? A closer look at the NLP pipeline in monolingual and multilingual models. In Findings of the Association for Computational Linguistics: EMNLP 2020, Online Event, 16-20 November 2020, volume EMNLP 2020 of Findings of ACL, pages 4339-4350. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics.
+Jonathan Frankle and Michael Carbin. 2019. The Lottery Ticket Hypothesis: Finding Sparse, Trainable Neural Networks. In Proceedings of the 7th International Conference on Learning Representations (ICLR).
+Jonathan Frankle, Gintare Karolina Dziugaite, Daniel M. Roy, and Michael Carbin. 2020. Linear Mode Connectivity and the Lottery Ticket Hypothesis. In Proceedings of the 37th International Conference on Machine Learning (ICML), pages 3259-3269.
+Trevor Gale, Erich Elsen, and Sara Hooker. 2019. The State of Sparsity in Deep Neural Networks. CoRR, abs/1902.09574.
+Hila Gonen, Shauli Ravfogel, Yanai Elazar, and Yoav Goldberg. 2020. It's not greek to mbert: Inducing word-level translations from multilingual BERT. In Proceedings of the Third BlackboxNLP Workshop on Analyzing and Interpreting Neural Networks for NLP, BlackboxNLP@EMNLP 2020, Online, November 2020, pages 45-56. Association for Computational Linguistics.
+
+Song Han, Jeff Pool, John Tran, and William J. Dally. 2015. Learning both Weights and Connections for Efficient Neural Networks. CoRR, abs/1506.02626.
+David R. Hardoon, Sándor Szedmák, and John Shawe-Taylor. 2004. Canonical Correlation Analysis: An Overview with Application to Learning Methods. Neural Comput., 16(12):2639-2664.
+Junjie Hu, Sebastian Ruder, Aditya Siddhant, Graham Neubig, Orhan First, and Melvin Johnson. 2020. XTREME: A Massively Multilingual Multi-task Benchmark for Evaluating Cross-lingual Generalization. CoRR, abs/2003.11080.
+Karthikeyan K, Zihan Wang, Stephen Mayhew, and Dan Roth. 2020. Cross-Lingual Ability of Multilingual BERT: An Empirical Study. In Proceedings of the 8th International Conference on Learning Representations (ICLR).
+Simon Kornblith, Mohammad Norouzi, Honglak Lee, and Geoffrey E. Hinton. 2019. Similarity of Neural Network Representations Revisited. In Proceedings of the 36th International Conference on Machine Learning (ICML), pages 3519-3529.
+Patrick S. H. Lewis, Barlas Oguz, Rudy Rinott, Sebastian Riedel, and Holger Schwenk. 2020. MLQA: Evaluating Cross-lingual Extractive Question Answering. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics (ACL), pages 7315-7330.
+Jindrich Libovický, Rudolf Rosa, and Alexander Fraser. 2020. On the language neutrality of pre-trained multilingual representations. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, Online Event, 16-20 November 2020, volume EMNLP 2020 of *Findings of ACL*, pages 1663-1674. Association for Computational Linguistics.
+Jindrich Libovický, Rudolf Rosa, and Alexander Fraser. 2019. How Language-Neutral is Multilingual BERT? CoRR, abs/1911.03310.
+Zehui Lin, Liwei Wu, Mingxuan Wang, and Lei Li. 2021. Learning language specific sub-network for multilingual machine translation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 1: Long Papers), Virtual Event, August 1-6, 2021, pages 293-305. Association for Computational Linguistics.
+Amil Merchant, Elahe Rahimtoroghi, Ellie Pavlick, and Ian Tenney. 2020. What happens to BERT embeddings during fine-tuning? In Proceedings of the Third BlackboxNLP Workshop on Analyzing and Interpreting Neural Networks for NLP, BlackboxNLP@EMNLP 2020, Online, November 2020, pages 33-44. Association for Computational Linguistics.
+
+Ari S. Morcos, Maithra Raghu, and Samy Bengio. 2018. Insights on representational similarity in neural networks with canonical correlation. In Proceedings of the 2018 Annual Conference on Neural Information Processing Systems (NeurIPS), pages 5732-5741.
+Ari S. Morcos, Haonan Yu, Michela Paganini, and Yuan-dong Tian. 2019. One ticket to win them all: generalizing lottery ticket initializations across datasets and optimizers. In Proceedings of the 2019 Annual Conference on Neural Information Processing Systems (NeurIPS), pages 4933-4943.
+Benjamin Müller, Yanai Elazar, Benoit Sagot, and Djame Seddah. 2021. First align, then predict: Understanding the cross-lingual ability of multilingual BERT. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, EACL 2021, Online, April 19 - 23, 2021, pages 2214-2231. Association for Computational Linguistics.
+Xiaoman Pan, Boliang Zhang, Jonathan May, Joel Nothman, Kevin Knight, and Heng Ji. 2017. Cross-lingual name tagging and linking for 282 languages. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics, ACL 2017, Vancouver, Canada, July 30 - August 4, Volume 1: Long Papers, pages 1946-1958. Association for Computational Linguistics.
+Telmo Pires, Eva Schlinger, and Dan Garrette. 2019. How multilingual is multilingual bert? In Proceedings of the 57th Conference of the Association for Computational Linguistics, ACL 2019, Florence, Italy, July 28- August 2, 2019, Volume 1: Long Papers, pages 4996-5001. Association for Computational Linguistics.
+Sai Prasanna, Anna Rogers, and Anna Rumshisky. 2020. When BERT plays the lottery, all tickets are winning. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 3208-3229. Association for Computational Linguistics.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 21:140:1-140:67.
+Maithra Raghu, Justin Gilmer, Jason Yosinski, and Jascha Sohl-Dickstein. 2017. SVCCA: Singular Vector Canonical Correlation Analysis for Deep Learning Dynamics and Interpretability. In Proceedings of the 2017 Annual Conference on Neural Information Processing Systems (NIPS), pages 6076-6085.
+Jasdeep Singh, Bryan McCann, Richard Socher, and Caiming Xiong. 2019. BERT is Not an Interlingua and the Bias of Tokenization. In Proceedings of the 2nd Workshop on Deep Learning Approaches for Low-Resource NLP (DeepLo@EMNLP-IJCNLP), pages 47-55.
+
+Thomas Spear. 2000. Early swahili history reconsidered. The International Journal of African Historical Studies, 33(2):257-290.
+Yi-Lin Sung, Varun Nair, and Colin Raffel. 2021. Training neural networks with fixed sparse masks. In Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual, pages 24193-24205.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is All you Need. In Proceedings of the 2017 Annual Conference on Neural Information Processing Systems (NIPS), pages 5998-6008.
+Kees Versteegh. 2014. Arabic language. Edinburgh University Press.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R. Bowman. 2019. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In 7th International Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019. OpenReview.net.
+Zirui Wang, Zachary C. Lipton, and Yulia Tsvetkov. 2020. On negative interference in multilingual models: Findings and A meta-learning treatment. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 4438-4450. Association for Computational Linguistics.
+Adina Williams, Nikita Nangia, and Samuel R. Bowman. 2018. A broad-coverage challenge corpus for sentence understanding through inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2018, New Orleans, Louisiana, USA, June 1-6, 2018, Volume 1 (Long Papers), pages 1112-1122. Association for Computational Linguistics.
+Shijie Wu and Mark Dredze. 2019. Beto, bentz, becas: The surprising cross-lingual effectiveness of BERT. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 833-844. Association for Computational Linguistics.
+Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V. Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, Jeff Klingner, Apurva Shah, Melvin Johnson, Xiaobing Liu, Lukasz Kaiser, Stephan Gouws, Yoshikiyo Kato, Taku Kudo, Hideto Kazawa, Keith Stevens, George Kurian, Nishant Patil, Wei Wang, Cliff Young, Jason Smith, Jason Riesa, Alex Rudnick, Oriol Vinyals, Greg Corrado, Macduff Hughes, and Jeffrey Dean.
+
+2016. Google's neural machine translation system: Bridging the gap between human and machine translation. CoRR, abs/1609.08144.
+
+Linting Xue, Noah Constant, Adam Roberts, Mihir Kale, Rami Al-Rfou, Aditya Siddhant, Aditya Barua, and Colin Raffel. 2021. mt5: A massively multilingual pre-trained text-to-text transformer. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2021, Online, June 6-11, 2021, pages 483-498. Association for Computational Linguistics.
+
+Haonan Yu, Sergey Edunov, Yuandong Tian, and Ari S. Morcos. 2020. Playing the lottery with rewards and multiple languages: lottery tickets in RL and NLP. In Proceedings of the 8th International Conference on Learning Representations (ICLR).
+
+Wei Zhao, Steffen Eger, Johannes Bjerva, and Isabelle Augenstein. 2021. Inducing language-agnostic multilingual representations. In Proceedings of *SEM 2021: The Tenth Joint Conference on Lexical and Computational Semantics*, *SEM* 2021, Online, August 5-6, 2021, pages 229-240. Association for Computational Linguistics.
+
+# A Additional Lottery Ticket Results
+
+Tables 3, 4, and 5 show the performance of winning tickets across languages for the MLM, XNLI, and NER tasks respectively. The absolute performance values of all three tasks on mBERT model are depicted in Tables 3, 4, and 5. Table 6 shows the absolute performance for the XNLI task on the mT5 model.
+
+# B Sub-network Overlap
+
+In Figure 3a, the parameter overlap plot for the MLM task, we note three different clusters. We observe that these clusters correspond to language pairs between two different groups of languages. The first set includes English, French, German, Russian, and Chinese and the second set includes the rest of the languages. The first cluster (at the bottom) shows the overlaps between the languages of the first set, the third cluster (on top) includes the overlaps among languages of the second set. The second cluster (in the middle) covers the overlaps among languages from the first and the second set.
+
+# C Disentangling Task Neutrality
+
+Given the significant role of the language-neutral components of the winning tickets, we want to investigate to what extent these components are task-specific. We evaluate the similarity of winning tickets across tasks for a given language to
+
+identify whether the winning ticket for a given language and task can be transferred successfully to other tasks for the same language. A successful transfer shows that the language-neutral component is not only task-specific but rather a common space across tasks. Similar to the previous section, we first identify winning tickets for each task-language pair and then train each sub-network on other tasks using the data from the same language. We again use sub-networks with $50\%$ sparsity. We limit the tested languages to those whose sub-networks are present for all three tasks: English (en), French (fr), and Chinese (zh).
+
+We report cross-task performance in Figure 9 for the MLM (9a), NER (9b), and XNLI (9c) tasks. Although in none of the cases the transferred subnetwork's performance matches the original subnetwork's performance, the average performance drop is less than 2 points for each task. This observation suggests that a considerable fraction of parameters are shared across tasks even if a certain number of them remain task-specific. Contrary to previous observations for the BERT model (Chen et al., 2020), we find that MLM winning tickets do not robustly transfer for training other tasks.
+
+# D Alternative Masking/Pruning Strategies
+
+In our experiments, we transfer obtained sparse subnetworks by re-training their original weights on a given task and various languages. Consequently, it is important that these sub-networks match the test accuracy of the full model when trained in isolation (i.e., winning tickets in the LTH), to be a good sub-network for the task at hand. By using such a sub-network, we want to keep task-specific parameters as much as possible. Any pruning/masking methodology that gives us sub-networks performing at the same level as the full model and also uses enough data to detect the language- and task-specific parameters could be used in our analysis.
+
+To broaden our analysis, we ran additional experiments using two alternative masking/pruning strategies. In the first set of experiments, we followed the pruning approach introduced by (Ansell et al., 2022). This method proposes a sparse finetuning method to discover task and language subnetworks that can be composed for cross-lingual transfer. However, unlike the LTH, which prunes parameters with the lowest magnitudes after finetuning, this method prunes the parameters that have
+
+ | MLM (Perplexity) | NER (F1) | XNLI (Accuracy) |
| mBERT | f* | s (%) | rand | mBERT | f* | s (%) | rand | mBERT | f* | s (%) | rand |
| ar | 3.5247 | 3.5546 | 50 | 6.4001 | 88.64 | 88.50 | 50 | 72.43 | 70.26 | 70.29 | 50 | 61.48 |
| de | 3.5143 | 3.5092 | 50 | 9.6489 | 89.11 | 88.81 | 50 | 75.68 | 77.33 | 77.10 | 50 | 65.98 |
| en | 4.6523 | 4.6347 | 50 | 10.9182 | 83.47 | 83.60 | 50 | 68.05 | 82.16 | 82.14 | 50 | 74.49 |
| es | 3.6775 | 3.6712 | 50 | 8.3084 | 91.11 | 91.08 | 50 | 79.44 | 78.80 | 78.93 | 60 | 67.67 |
| fa | 3.8033 | 3.8038 | 50 | 7.3315 | 92.33 | 92.10 | 60 | 75.66 | - | - | - | - |
| fr | 3.1151 | 3.0936 | 50 | 6.8504 | 90.51 | 90.31 | 50 | 77.61 | 78.00 | 77.61 | 50 | 69.11 |
| hi | 2.8728 | 2.8757 | 50 | 5.1345 | - | - | - | - | 68.48 | 68.04 | 50 | 58.75 |
| ru | 2.5927 | 2.5907 | 50 | 6.1112 | 89.39 | 89.03 | 50 | 74.91 | 72.98 | 72.73 | 60 | 62.20 |
| sw | 2.5001 | 2.4657 | 50 | 4.292 | - | - | - | - | 66.28 | 66.14 | 50 | 59.55 |
| ur | 2.8624 | 2.8638 | 50 | 5.0286 | 95.31 | 95.94 | 60 | 84.33 | 63.06 | 63.13 | 30 | 58.75 |
| zh | 3.6096 | 3.5754 | 50 | 8.4811 | 79.53 | 79.33 | 50 | 57.44 | 76.60 | 76.01 | 50 | 68.23 |
+
+Table 2: Performance of winning tickets $(f^{*})$ on the XNLI, NER, and MLM tasks at the highest sparsity $(s)$ for which iterative pruning finds them. We also report the performance of a random sub-network of mBERT (rand) at the same sparsity level as the winning ticket.
+
+| Model / Sub-network | Target Language |
| ar | de | en | es | fa | fr | hi | ru | sw | ur | zh |
| mBERT | 3.5247 | 3.5143 | 4.6523 | 3.6775 | 3.8033 | 3.1151 | 2.8728 | 2.5927 | 2.5001 | 2.8624 | 3.6096 |
| ar | 3.5546 | 3.7510 | 4.7967 | 3.7568 | 4.0791 | 3.2360 | 3.1133 | 2.7075 | 2.7315 | 3.0873 | 3.7821 |
| de | 3.8861 | 3.5092 | 4.9626 | 3.9055 | 4.1539 | 3.3429 | 3.1189 | 2.8173 | 2.7535 | 3.0852 | 3.9186 |
| en | 3.8742 | 3.8270 | 4.6347 | 3.8585 | 4.2320 | 3.3177 | 3.1034 | 2.8129 | 2.7436 | 3.0899 | 3.9407 |
| es | 3.8339 | 3.7929 | 4.8842 | 3.6712 | 4.1942 | 3.2895 | 3.0974 | 2.7693 | 2.7569 | 3.1046 | 3.8816 |
| fa | 3.7464 | 3.6334 | 4.7350 | 3.6938 | 3.8038 | 3.1910 | 3.0848 | 2.6704 | 2.7339 | 3.0595 | 3.7303 |
| fr | 3.8722 | 3.8528 | 4.9441 | 3.8526 | 4.1329 | 3.0936 | 3.1116 | 2.8150 | 2.7406 | 3.1577 | 3.9641 |
| hi | 3.8431 | 3.7554 | 4.8606 | 3.8120 | 4.2017 | 3.2725 | 2.8757 | 2.7432 | 2.7612 | 3.1281 | 3.8329 |
| ru | 3.8820 | 3.8683 | 5.0007 | 3.9182 | 4.1466 | 3.3656 | 3.0847 | 2.5907 | 2.7566 | 3.1553 | 3.9728 |
| sw | 3.8650 | 3.7613 | 4.8704 | 3.8184 | 4.2288 | 3.2863 | 3.1022 | 2.7505 | 2.4657 | 3.0666 | 3.8442 |
| ur | 3.8644 | 3.7545 | 4.8701 | 3.8153 | 4.1892 | 3.2778 | 3.0937 | 2.7456 | 2.7575 | 2.8638 | 3.8410 |
| zh | 3.8852 | 3.8804 | 5.0004 | 3.9216 | 4.1565 | 3.3698 | 3.1025 | 2.8302 | 2.7675 | 3.1015 | 3.5754 |
+
+Table 3: Performance (perplexity) of winning tickets at $50\%$ sparsity for the MLM task.
+
+the smallest absolute difference from the initial parameters. Following this method, we prune the base model to obtain $50\%$ sparse sub-networks (similar to our previous method) for a selection of languages (i.e., en, fr, de, and ar). For the NER and XNLI tasks, we observed drops of $\sim 6\%$ and $\sim 5\%$ , respectively compared to the full model (averaged across three random seeds). As our goal was to find sub-networks that perform as well as the full model for our analysis, these sub-networks would not be suitable candidates.
+
+We also test the method introduced by (Sung et al., 2021). This paper proposes a method to approximate the Fisher information matrix as a measure of the importance of each parameter when constructing sparse masks for a given task. Using a sufficiently large sample size (1024 examples), they compute this matrix and prune the parameters that contain the least information about the task.
+
+When we use this method (again pruning to $50\%$ sparsity), we find that end task performance drops by $\sim 8\%$ compared to the full model (on XNLI and NER). As a result, this approach also does not find high-quality sub-networks that can be tested for cross-lingual transfer.
+
+# E Margin-based Scoring
+
+For the parallel sentence retrieval task, we use the scoring function from (Artetxe and Schwenk, 2019):
+
+$$
+s (x, y) = \frac {\cos (x , y)}{\sum_ {z \in \mathcal {N} _ {k} (x)} \frac {\cos (x , z)}{2 k} + \sum_ {z \in \mathcal {N} _ {k} (y)} \frac {\cos (y , z)}{2 k}}
+$$
+
+where $x$ and $y$ are two sentence representations and $\mathcal{N}_k(x)$ denotes the $k$ nearest neighbors of $x$ in the other language. We use $\text{margin}(a, b) = a / b$ as our margin function.
+
+| Model / Sub-network | Target Language |
| ar | de | en | es | fr | hi | ru | sw | ur | zh |
| mBERT | 70.26 | 77.33 | 82.16 | 78.80 | 78.00 | 68.48 | 72.98 | 66.28 | 63.06 | 76.60 |
| ar | 70.29 | 76.72 | 82.00 | 79.07 | 77.06 | 67.58 | 72.96 | 67.48 | 64.68 | 76.88 |
| de | 70.22 | 77.10 | 82.44 | 79.09 | 77.73 | 68.11 | 73.35 | 65.40 | 64.03 | 76.50 |
| en | 71.17 | 77.12 | 82.14 | 79.73 | 78.23 | 67.90 | 74.38 | 66.37 | 64.03 | 76.66 |
| es | 70.57 | 77.42 | 82.43 | 79.15 | 77.36 | 68.06 | 74.31 | 64.97 | 63.61 | 76.98 |
| fr | 70.52 | 76.96 | 82.80 | 79.56 | 77.61 | 68.39 | 73.31 | 66.77 | 63.85 | 77.31 |
| hi | 70.94 | 76.24 | 82.54 | 77.96 | 77.15 | 68.04 | 72.93 | 65.78 | 64.07 | 76.50 |
| ru | 70.33 | 76.05 | 82.69 | 79.49 | 77.54 | 68.55 | 73.31 | 65.62 | 63.37 | 76.52 |
| sw | 69.76 | 76.42 | 81.50 | 77.45 | 76.75 | 67.84 | 72.36 | 66.14 | 63.39 | 76.18 |
| ur | 69.11 | 75.17 | 80.81 | 77.65 | 75.71 | 66.98 | 72.20 | 65.33 | 62.14 | 75.82 |
| zh | 69.79 | 76.16 | 81.45 | 78.73 | 77.80 | 67.74 | 72.67 | 65.51 | 63.85 | 76.01 |
+
+Table 4: Performance (accuracy) of winning tickets at $50\%$ sparsity for the XNLI task.
+
+| Model / Sub-network | Target Language |
| ar | de | en | es | fa | fr | ru | ur | zh |
| mBERT | 88.64 | 89.11 | 83.47 | 91.11 | 92.33 | 90.51 | 89.39 | 95.31 | 79.53 |
| ar | 88.50 | 87.59 | 82.92 | 90.39 | 91.73 | 89.84 | 88.34 | 94.67 | 76.97 |
| de | 87.09 | 88.81 | 83.06 | 90.43 | 91.20 | 89.59 | 88.38 | 93.93 | 77.25 |
| en | 87.21 | 87.53 | 83.60 | 90.44 | 91.23 | 89.67 | 88.47 | 93.93 | 76.92 |
| es | 87.10 | 87.59 | 83.10 | 91.08 | 91.33 | 89.93 | 88.25 | 94.22 | 76.51 |
| fa | 87.47 | 87.55 | 82.73 | 90.18 | 92.25 | 89.59 | 88.34 | 94.10 | 76.73 |
| fr | 87.33 | 87.81 | 82.85 | 90.56 | 91.40 | 90.31 | 88.50 | 94.42 | 76.72 |
| ru | 87.26 | 87.84 | 82.99 | 90.43 | 91.41 | 89.75 | 89.03 | 94.35 | 76.96 |
| ur | 86.81 | 87.35 | 82.59 | 90.08 | 91.35 | 89.50 | 87.94 | 96.44 | 76.73 |
| zh | 86.94 | 87.48 | 82.42 | 90.11 | 91.17 | 89.47 | 88.21 | 93.65 | 79.33 |
+
+Table 5: Performance (F1-score) of winning tickets at ${50}\%$ sparsity for the NER task.
+
+| Model/Sub-network | Target Language |
| ar | de | en | es | fr | hi | ru | sw | ur | zh |
| mT5 | 74.17 | 78.52 | 83.13 | 79.64 | 80.14 | 69.98 | 75.56 | 70.00 | 63.25 | 75.10 |
| ar | 71.25 | 74.43 | 79.69 | 76.14 | 75.47 | 67.18 | 73.51 | 67.24 | 61.14 | 69.15 |
| de | 69.94 | 75.71 | 80.31 | 76.94 | 76.60 | 66.93 | 74.57 | 67.00 | 60.70 | 70.09 |
| en | 69.97 | 76.02 | 80.64 | 77.41 | 76.36 | 67.58 | 75.12 | 67.38 | 61.62 | 68.76 |
| es | 70.68 | 76.76 | 80.72 | 77.64 | 76.96 | 67.73 | 74.78 | 66.80 | 61.22 | 69.82 |
| fr | 70.49 | 75.76 | 79.66 | 76.67 | 76.59 | 66.93 | 74.66 | 69.43 | 60.21 | 69.00 |
| hi | 68.79 | 73.50 | 78.29 | 74.63 | 74.01 | 66.19 | 71.96 | 65.74 | 61.06 | 67.64 |
| ru | 69.67 | 74.89 | 79.33 | 76.16 | 75.07 | 67.37 | 74.22 | 67.13 | 60.44 | 70.22 |
| sw | 69.96 | 74.60 | 79.53 | 75.65 | 74.93 | 66.32 | 73.31 | 67.22 | 60.41 | 67.45 |
| ur | 66.20 | 71.28 | 75.76 | 72.04 | 71.58 | 65.17 | 69.99 | 64.07 | 60.48 | 67.60 |
| zh | 70.40 | 75.15 | 80.05 | 75.74 | 75.36 | 66.99 | 73.75 | 65.98 | 59.80 | 71.44 |
| rand | 61.20 | 66.70 | 73.57 | 68.11 | 67.67 | 61.08 | 66.30 | 61.84 | 56.82 | 62.57 |
+
+Table 6: Performance (accuracy) of at ${50}\%$ sparsity for the XNLI task on the mT5 model.
+
+# F Language Representation Similarity
+
+In this section, we discuss a prior work that demonstrated the lack of language neutrality in mBERT by comparing the mBERT's representations for semantically-similar sentences across multiple languages (Singh et al., 2019). They conclude that mBERT partitions the representation space among languages rather than using a shared, interlingual space. They used projection weighted canonical
+
+correlation analysis (PWCCA; Morcos et al., 2018) to compute the similarity between representations from parallel sentences (XNLI dataset) for five language pairs. Figure 10a depicts our reproduced version of their results.
+
+As shown in the figure, the CLS representations of various languages are most similar at the shallower layers of mBERT, and their differences grow in deeper layers until the final layer. We argue that these results contradict mBERT's cross-lingual
+
+
+(a) Encoder
+
+
+(b) Decoder
+Figure 8: Sparsity pattern overlap between pruned sub-networks across different layers at $50\%$ sparsity level for the XNLI task on the mT5 model.
+
+
+(a) Target task: MLM
+
+
+(b) Target task: NER
+
+
+(c) Target task: XNLI
+Figure 9: The performance of transferring winning tickets between tasks (50% sparsity). Each cell shows the difference in performance between the transferred sub-network and the performance of the sub-network discovered for the target task.
+
+
+(a) PWCCA
+
+
+(b) SVCCA
+Figure 10: Similarity scores between CLS representations of English and five other languages using PWCCA and SVCCA.
+
+transfer performance since for almost all of the downstream tasks, the best zero-shot performance is obtained using the representations from middle to deeper layers of mBERT (Conneau et al., 2020b; Chi et al., 2020; de Vries et al., 2020). Hence, we expect the representations of deeper layers to be more similar than in shallower layers.
+
+PWCCA is not a reliable tool in this scenario as it is not invariant to orthogonal transformations (Kornblith et al., 2019). Invariance to orthogonal transformation implies invariance to (neuron) permutation, which is necessary to accommodate symmetries of neural networks (Kornblith et al., 2019). Hence, we use singular vector canonical correlation analysis (SVCCA; Raghu et al., 2017), which is invariant to orthogonal transformations, to measure the similarities between mBERT's representations in different languages. SVCCA performs canonical correlation analysis (CCA) on truncated singular value decomposition of input matrices.
+
+Figure 10b presents our obtained results for the same five language pairs using SVCCA. We observe that the similarity of representations increases in deeper layers. Moreover, the middle and upper layers' representations are more similar across languages than the representations from shallower layers, which is in line with mBERT's cross-lingual transfer performance. Hence, contrary to prior work (Singh et al., 2019), we argue that mBERT maps semantically-similar data points close to each other by learning a common, interlingual space.
+
+# G Canonical Correlation Analysis
+
+Canonical correlation analysis (CCA) is a statistical tool to identify and measure the associations between two sets of random variables $X$ and $Y$ (Hardoon et al., 2004). CCA finds bases for the two input matrices, with the maximum correlation between $X$ and $Y$ projected onto these bases. For $X \in \mathbb{R}^{d_1 \times n}$ , $Y \in \mathbb{R}^{d_2 \times n}$ , and $1 \leq i \leq \min(d_1, d_2)$ , the $i^{th}$ canonical correlation coefficient $\rho_i$ is given by:
+
+$$
+\begin{array}{l} \rho_ {i} = \max _ {w _ {X} ^ {i}, w _ {Y} ^ {i}} \operatorname {c o r r} (X w _ {X} ^ {i}, Y w _ {Y} ^ {i}) \\ \text {s u b j e c t} \forall_ {j < i} X w _ {X} ^ {i} \perp X w _ {X} ^ {j} \\ \forall_ {j < i} Y w _ {Y} ^ {i} \perp Y w _ {Y} ^ {j} \\ \end{array}
+$$
+
+Where $w_{X}^{i}\in \mathbb{R}^{d_{1}}$ , $w_{Y}^{i}\in \mathbb{R}^{d_{2}}$ and the constraints enforce orthogonality of the canonical variables. The average of $\{\rho_1,\dots,\rho_m\}$ where $m =$
+
+$\min (d_1,d_2)$ is often used as an overall similarity measure:
+
+$$
+\rho_ {C C A} = \frac {\sum_ {i = 1} ^ {m} \rho_ {i}}{m}
+$$
+
+Two of CCA variants, projection weighted canonical correlation analysis (PWCCA) and singular vector canonical correlation analysis (SVCCA), are used for analyzing neural network representations because they are invariant to linear transforms.
+
+To improve the robustness of CCA, SVCCA performs CCA on top of truncated singular value decomposition of $X$ and $Y$ . PWCCA increases the robustness of CCA by using the weighted average of canonical correlation coefficients:
+
+$$
+\rho_ {P W} = \frac {\sum_ {i = 1} ^ {c} \alpha_ {i} \rho_ {i}}{\sum_ {i = 1} \alpha_ {i}}, \quad \alpha_ {i} = \sum_ {j} | \langle h _ {i}, x _ {j} \rangle |
+$$
+
+where $x_{j}$ is the $j^{th}$ column of $X$ , and $h_i = Xw_X^i$ is the projection of $X$ to the $i^{th}$ canonical coordinate frame.
+
+# H Computation details
+
+Our experiments are executed on a server with 500GB of RAM, $2 \times 16$ -core Intel Xeon Silver 4216 (2.10GHz) CPUs, and an NVIDIA Quadro RTX 8000 GPU. For each language, the pruning step for MLM, NER, and XNLI takes around 15, 4.5, and 45 GPU hours, respectively, and fine-tuning takes around 6, 0.5, and 15 GPU hours for MLM, NER, and XNLI, respectively.
+
+| Dataset | MLM | NER | XNLI |
| # Train Ex. | 1,600,000 | 20,000 | 392,702 |
| # Valid. Ex. | 30,000 | 10,000 | 2,490 |
| # Epochs | 1 | 3 | 3 |
| # Iters/Epoch | 100,000 | 625 | 12,270 |
| Batch Size | 16 | 32 | 32 |
| Learning Rate | 5 × 10-5 | 2 × 10-5 | mbert: 5 × 10-5mt5: 2 × 10-4 |
| Eval. Metric | Perplexity | F1 | Accuracy |
| Optimizer | Adam with ε = 1 × 10-8 |
+
+Table 7: Details of pre-training and fine-tuning. Learning rate decays linearly from initial value to zero.
\ No newline at end of file
diff --git a/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/images.zip b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..f186a364e62563935e7c23869eb705f2d75ddc84
--- /dev/null
+++ b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:dd2f81c109fa792d8c2cc3e8604d6b0a8db5327dc8b4954ea7de27b938f51c35
+size 1168081
diff --git a/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/layout.json b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..3896f8312df699e353f285c1e223afeebe5cea33
--- /dev/null
+++ b/discoveringlanguageneutralsubnetworksinmultilinguallanguagemodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9fa3a8fd8e46348fbb5bbb0d6274ff8bcf047367937095546392224de842a3e5
+size 538016
diff --git a/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_content_list.json b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..29003fd30d61ad58b8b7e7c0c856e1872f11a814
--- /dev/null
+++ b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:55251ba86e1e18a3d32adb2be44fb0cf5dec9d36fc4744dcec9f1a65158219b2
+size 124796
diff --git a/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_model.json b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..3045bea68bb3a3e4560ec71f6164f023f1df427f
--- /dev/null
+++ b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:78479d1ad687f19f9c1d3d95e45a2b51a0df41b3da084ec526ec2ff6dfd295f2
+size 147615
diff --git a/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_origin.pdf b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..8caf54be0037b43a16f9781836e0067367e8529e
--- /dev/null
+++ b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/64927fae-e78a-465a-990a-75423febc770_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ed5782ba4ed97831a6974a9d694f718a9d1b385519e52a1cbe5ecf9a5f5dfa46
+size 2465516
diff --git a/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/full.md b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..ba754dbd1eecc6eca1280c4ef60814fd19f82462
--- /dev/null
+++ b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/full.md
@@ -0,0 +1,453 @@
+# Discovering Low-rank Subspaces for Language-agnostic Multilingual Representations
+
+Zhihui Xie $^{1}$ Handong Zhao $^{2}$ Tong Yu $^{2}$ Shuai Li $^{1*}$
+
+1Shanghai Jiao Tong University 2Adobe Research
+
+{fffffarmer, shuaili8}@sjtu.edu.cn
+
+{hazhao,tyu} $@$ adobe.com
+
+# Abstract
+
+Large pretrained multilingual language models (ML-LMs) have shown remarkable capabilities of zero-shot cross-lingual transfer, without direct cross-lingual supervision. While these results are promising, follow-up works found that, within the multilingual embedding spaces, there exists strong language identity information which hinders the expression of linguistic factors shared across languages. For semantic tasks like cross-lingual sentence retrieval, it is desired to remove such language identity signals to fully leverage semantic information. In this work, we provide a novel view of projecting away language-specific factors from a multilingual embedding space. Specifically, we discover that there exists a low-rank subspace that primarily encodes information irrelevant to semantics (e.g., syntactic information). To identify this subspace, we present a simple but effective unsupervised method based on singular value decomposition with multiple monolingual corpora as input. Once the subspace is found, we can directly project the original embeddings into the null space to boost language agnosticism without finetuning. We systematically evaluate our method on various tasks including the challenging language-agnostic QA retrieval task. Empirical results show that applying our method consistently leads to improvements over commonly used ML-LMs.
+
+# 1 Introduction
+
+Large language models pretrained with self-supervised objectives (e.g., masked language modeling) have become the de-facto standard for various NLP tasks (Peters et al., 2018; Devlin et al., 2019; Liu et al., 2019). Follow-up extensions to the multilingual setting inherit similar training objectives and show very promising results (Conneau and Lample, 2019; Conneau et al., 2020b; K et al., 2020). Despite these models are trained
+
+without explicit cross-lingual signals (i.e., translation pairs), they surprisingly exhibit impressive zero-shot cross-lingual transferability on natural language inference (Conneau et al., 2018), question answering (Lewis et al., 2020), sentence retrieval (Artetxe and Schwenk, 2019), etc.
+
+While these ML-LMs offer practical solutions for cross-lingual tasks, there is an enduring debate about why the ML-LMs work. From a positive perspective, Pires et al. (2019) conduct an exploratory study on mBERT (Devlin et al., 2019), suggesting that cross-lingual transfer is possible even to languages in different scripts. Chi et al. (2020) probe mBERT for structural phenomena and find that its representations can recover syntactic tree distances in languages other than English. These findings present shreds of evidence that the pretrained multilingual representations do capture cross-lingual properties in various aspects. On the flip side, a line of research shows that pretrained ML-LMs encode strong language-specific signals. This causes their multilingual representations to cluster by language identities instead of semantic meaning (Wu and Dredze, 2019; Roy et al., 2020; Libovický et al., 2020). The property largely hinders the expression of linguistic signals shared across languages. For applications like cross-lingual sentence retrieval that mainly consider semantic information, ML-LMs with strong language-specific signals tend to retrieve answers from specific languages, regardless of their semantic meaning (Roy et al., 2020).
+
+Motivated by previous findings about language identity information, we aim to locate language-specific factors captured by the pretrained ML-LMs for recovering a language-agnostic embedding space. Inspired by advances in domain generalization (Muandet et al., 2013; Motiian et al., 2017; Piratla et al., 2020), we explore a simple but effective approach, LSAR, to discover a Low-rank Subspace for language-Agnostic Representations within an ML-LM. The subspace primarily encodes
+
+information irrelevant to semantics, and can be identified without any translation pairs based on singular value decomposition. Once the subspace is found, we can directly factor out language-specific factors from the multilingual embeddings by projecting them into the null space without finetuning.
+
+To evaluate LSAR, we focus on semantic tasks for multilingual sentence embeddings. On standard cross-lingual zero-shot transfer tasks including classification and sentence retrieval, LSAR consistently achieves significant improvements. Especially, applying LSAR leads to significant improvements for pretrained ML-LMs on LAReQA (Roy et al., 2020), a challenging benchmark targeting strong language agnosticism.
+
+We further examine what information exactly the subspace contains. By performing correlation analysis between structural language similarities obtained from the URIEL database (Littell et al., 2017) and the language similarities captured on the subspace, we observe that the subspace encodes a great deal of syntactic information. This implies that LSAR successfully erases linguistic signals that are redundant to semantic tasks to facilitate language agnosticism.
+
+To conclude, our main contributions are:
+
+- We present one of the pioneering efforts to discover that there exist low-rank subspaces of pretrained ML-LMs' embeddings that mainly encode language-specific signals.
+- To identify the subspace in a ML-LM, we present a simple unsupervised approach called LSAR based on singular value decomposition. By projecting embeddings onto the null space, LSAR can exclude the unwanted factors to facilitate language agnosticism.
+- Empirical results show that LSAR is surprisingly effective for a variety of semantic tasks. We also elucidate that the subspace encodes strong syntactic signals with careful experimental analysis.
+
+# 2 Related Work
+
+Understanding Pretrained Multilingual Representations Recently, there has been a surge of interest in probing pretrained ML-LMs like mBERT (Devlin et al., 2019). Pires et al. (2019) present an exploratory study on the cross-linguality of mBERT, showing that mBERT exhibits strong
+
+zero-shot performances for typologically similar languages. Libovický et al. (2020) find that the original mBERT embeddings can be decomposed into a language-specific component and a language-neutral component. Chi et al. (2020) probe mBERT for universal grammatical relations and show that mBERT does encode fine-grained syntactic distinctions across languages. Muller et al. (2021) find that mBERT operates as the stacking of two subnetworks and mainly the lower part of the model is crucial for cross-lingual transfer.
+
+Language-agnostic Representations To further facilitate semantic downstream tasks like text classification, retrieval, and question answering, it is appealing to remove language-specific signals from the original embeddings without destroying the intrinsic semantic meaning.
+
+LASER (Artetxe and Schwenk, 2019) utilizes parallel data to train a BiLSTM-based multilingual sentence encoder. Zhao et al. (2021) obtain language-agnostic embeddings from mBERT and XLM-R by explicitly aligning the word pairs and further normalizing the latent spaces with zero mean and unit variance. Yang et al. (2021) regard the top principal components from each language's embedding space as the primary source of language bias and propose to project them away to boost language agnosticism.
+
+Our work bears resemblance to Yang et al. (2021), but with clear distinctions in that: 1) we model language-specific signals jointly in the multilingual embedding space instead of locating it separately within each language; 2) we further verify what exactly the linguistic signals are identified, and present evidences that LSAR primarily removes syntactic information. A few previous works (Gonen et al., 2020; Liang et al., 2021; Chang et al., 2022) also attempt to locate language-agnostic embeddings in subspaces of ML-LMs. Apart from the dissimilarity of methodology, we focus on sentence-level instead of token-level tasks and provide shreds of evidence that the identified subspace exhibits strong correlation with syntactic information.
+
+Low-rank Subspaces in Other Applications Low-rank subspaces have been employed in various applications. In face recognition, the most expressive features for face representations are located via subspace analysis methods like PCA (Turk and Pentland, 1991; Wang and Tang,
+
+
+Figure 1: Conceptual illustration of our alignment method LSAR. There exists strong language identity information from the original pretrained multilingual representations. By projecting away language-specific components that reside in a low-rank subspace discovered in identification process (in top-right), we can produce a language-agnostic embedding space via language agnosticism rectification (in bottom). The probing procedure (colored in blue-grey) and the inference procedure (colored in yellow) can be done separately.
+
+2004). For domain adaptation and domain generalization, a typical idea is to uncover a shared subspace on which the distribution mismatch between domains is reduced (Muandet et al., 2013; Pan et al., 2011; Motiian et al., 2017). Recent advances in probing Generative Adversarial Networks (GANs) also observe meaningful latent subspaces that enable precise control of GAN generation (Wang and Ponce, 2021; Zhu et al., 2021). These findings to some extent motivate this paper.
+
+# 3 Methodology
+
+In this section, we first introduce our method to identify the low-rank language-specific subspace in an unsupervised manner. Once the subspace is found, we can then suppress the language identity from the original multilingual embeddings to achieve language agnosticism rectification by projecting them to the null space. This posttraining alignment procedure can largely benefit downstream tasks like cross-lingual retrieval which solely utilize semantic-related information.
+
+# 3.1 Multilingual Embedding Decomposition
+
+To locate the language-specific factors, we follow previous works (Pires et al., 2019; Libovický et al., 2020; Yang et al., 2021) to hypothesize that each multilingual embedding $e_{l} \in \mathbb{R}^{d}$ in language $l$ can
+
+be decomposed in an additive form:
+
+$$
+\boldsymbol {e} _ {l} := \boldsymbol {s} _ {l} + \boldsymbol {a} _ {l},
+$$
+
+where $\pmb{s}_l\in \mathbb{R}^d$ and $\pmb{a}_{l}\in \mathbb{R}^{d}$ represent the language-specific component to remove and the language-agnostic component to keep, respectively.
+
+Built on the above assumption, previous unsupervised approaches extract the language identity information separately for each language space. Given an ML-LM (e.g., mBERT), the extracted embeddings $\mathcal{E}_l \coloneqq \{e_l^i\}_{i=1}^n$ from $n$ samples of task training data or external monolingual corpora contain mixed linguistic information of semantic-relevant and semantic-irrelevant signals about language $l$ . Libovický et al. (2020) use the empirical mean $\frac{1}{n}\sum_{i=1}^{n}e_l^i$ to obtain $s_l$ . Yang et al. (2021) use the top- $k$ principal components $C_l = \mathrm{PCA}(\mathcal{E}_l) \in \mathbb{R}^{d \times k}$ to encode language identity signals, and propose to factor them out with $s_l = C_lC_l^\top e_l$ to facilitate language agnosticism.
+
+In spite of their promising results for semantic-related tasks, these methods fall short of comprehensively discovering cross-lingual relationship in the latent space. For each language $l$ , both of them leverage solely $\mathcal{E}_l$ to locate language-specific information, which fails to distinguish itself from semantic signals as other languages' characteristics is unknown. Without careful tuning, this can
+
+lead to unexpected semantic information loss (Khodak et al., 2018). Besides, it is also unclear what exactly language-specific signals are captured by these approaches.
+
+# 3.2 Low-rank Subspace Identification
+
+To alleviate the above issues, we attempt to globally capture language-specific information from the multilingual latent space. Inspired by previous works in domain adaptation and domain generalization (Muandet et al., 2013; Motiian et al., 2017; Piratla et al., 2020), we present a simple approach that identifies a low-rank subspace of the original multilingual latent space, $M_{s} \in \mathbb{R}^{d \times r}$ , spanned by $r$ components. Intuitively, the subspace encodes language-specific signals via measuring the latent discrepancy among languages.
+
+To be specific, we first extract the mean embedding $\mu_{l} = \frac{1}{n}\sum_{i = 1}^{n}\pmb{e}_{l}^{i}$ of each language $l$ in the same spirit of previous approaches. Concatenating $\mu_{l}$ of $L$ languages column-by-column results in the mean embedding matrix $M\in \mathbb{R}^{d\times L}$ . As discussed in Section 3.1, the mean embeddings can unexpectedly mix the desired language-specific signals with semantic information. To avoid removing the semantic information shared among languages, we decompose $M$ into two components: 1) a vector $\pmb{\mu}$ representing what is commonly shared across languages in the latent space; 2) a matrix $M_{s}$ specifying a low-rank subspace on which different languages express different linguistic signals. With the orthogonality constraint, our objective is:
+
+$$
+\min _ {\boldsymbol {\mu}, M _ {s}, \boldsymbol {\Gamma}} \quad \left\| \boldsymbol {M} - \boldsymbol {\mu} \mathbb {1} ^ {\top} - \boldsymbol {M} _ {s} \boldsymbol {\Gamma} ^ {\top} \right\| _ {F} ^ {2} \tag {1}
+$$
+
+$$
+\begin{array}{l} \text {s . t .} \quad \boldsymbol {\mu} \perp \operatorname {S p a n} \left(\boldsymbol {M} _ {s}\right), \end{array}
+$$
+
+where $\Gamma \in \mathbb{R}^{L\times r}$ is the coordinates of language-specific signals along the subspace's $r$ components and $\mathbb{1}\in \mathbb{R}^d$ contains all ones.
+
+The optimal solution of Equation 1 can be computed efficiently via Singular Value Decomposition (SVD), as proved in Appendix A. Algorithm 1 presents the detailed procedure. The only hyperparameter $r < L$ controls the amount of language-specific information captured by the identified subspace. The larger $r$ is, the more language-specific signals we can identify.
+
+# 3.3 Language Agnosticism Rectification
+
+Once we find the low-rank subspace with semantically irrelevant information encoded, we can im
+
+Algorithm 1: language-specific Subspace Identification
+In: languages' mean embeddings $M$ , rank of subspace $r$
+Out: language-agnostic component $\mu$ , language-specific subspace $M_s$ , coordinates $\Gamma$
+/* 1) Approximate $M$ in low rank */
+ $\mu' \gets \frac{1}{d} M \mathbb{1}$ ;
+ $\boldsymbol{M}_s^{\prime}, -, \boldsymbol{\Gamma}^{\prime} \gets \text{Top-r SVD}(\boldsymbol{M} - \boldsymbol{\mu}^{\prime} \mathbb{1}^{\top})$ ;
+ $\boldsymbol{M}^{\prime} \gets \boldsymbol{\mu}^{\prime} \mathbb{1}^{\top} + \boldsymbol{M}_s^{\prime} \boldsymbol{\Gamma}^{\prime \top}$ ;
+/* 2) Force orthogonality */
+ $\mu \gets \frac{1}{\|M^{\prime} + \mathbb{1}\|^2} M^{\prime +} \mathbb{1}$ ;
+ $\boldsymbol{M}_s, -, \boldsymbol{\Gamma} \gets \text{Top-r SVD}(\boldsymbol{M}^{\prime} - \boldsymbol{\mu} \mathbb{1}^{\top})$
+
+prove language agnosticism via projecting multilingual embeddings onto the null space of $M_{s}$ :
+
+$$
+\begin{array}{l} \boldsymbol {a} _ {l} = \left(\boldsymbol {I} - \boldsymbol {M} _ {s} \left(\boldsymbol {M} _ {s} ^ {\top} \boldsymbol {M} _ {s}\right) ^ {- 1} \boldsymbol {M} _ {s} ^ {\top}\right) \boldsymbol {e} _ {l} \\ = \boldsymbol {e} _ {l} - \boldsymbol {M} _ {s} \boldsymbol {M} _ {s} ^ {\top} \boldsymbol {e} _ {l}. \\ \end{array}
+$$
+
+Given that usually $l \ll d$ , the information removed is restricted to aspects that emerges to be language-specific and will not lead to dimensional collapse.
+
+# 4 Experiments
+
+We systematically evaluate our method on various tasks followed by further analyses1, with the purposes of understanding: 1) whether the proposed approach can benefit downstream tasks; 2) what exactly the identified low-rank subspace captures.
+
+To begin with, we describe our evaluation protocol for the alignment methods, which largely follows Yang et al. (2021) but with a broader scope to include more base models as listed in Section B. Given one of the pretrained ML-LMs, we first randomly collect 10,000 sentences for each language from the OSCAR corpus (Ortiz Suárez et al., 2020) covering all the evaluated languages and their web crawl texts2. The sentence embeddings extracted by the pretrained model are then used for finding
+
+ | mBERT | XLM | XLM-R | LABSE |
| Cross-lingual zero-shot transfer (w/o finetuning) |
| Original | 37.53+00.00% | 28.13+00.00% | 57.68+00.00% | 95.47+00.00% |
| Centered (Libovický et al., 2020) | 39.57+05.43% | 27.13-03.57% | 61.08+05.89% | 95.56+00.10% |
| LIR (k=1) (Yang et al., 2021) | 39.70+05.77% | 28.75+02.22% | 61.60+06.80% | 95.63+00.16% |
| LIR (k=15) (Yang et al., 2021) | 41.21+09.80% | 31.65+12.51% | 62.80+08.87% | 95.56+00.10% |
| LSAR | 44.64+18.94% | 33.16+17.89% | 65.05+12.77% | 95.54+00.08% |
| Cross-lingual zero-shot transfer (w/ finetuning) |
| Full-Model-FS (Xu et al., 2022)† | - | - | 60.5+04.9%/66.2+14.8% | - |
| S4-Tuning (Xu et al., 2022)† | - | - | 66.1+14.6%/69.5+20.5% | - |
| Full-Model (Ruder et al., 2021)‡ | 42.8+14.0% | - | 76.6+32.8% | - |
+
+Table 1: Retrieval accuracy (%) on Tatoeba (averaged over all 36 languages). ${}^{ \dagger }$ Results from Xu et al. (2022) report few-shot performances with different numbers of shots (64/128). ${}^{ \ddagger }$ Results are calculated from Ruder et al. (2021). We use “-” to indicate results that are not reported in the references and use “+%” to report relative improvements.
+
+the low-rank subspace described in Equation 1. Unless otherwise indicated, we consistently report LSAR with $r = l - 1$ , where $l$ is the number of the evaluated languages. We evaluate language agnosticism over pretrained ML-LMs that are commonly used, as described in Appendix B. Detailed results are listed in Appendix C.3.
+
+# 4.1 Baselines
+
+Apart from Original that keeps the pretrained ML-LM intact, we compare LSAR with the following baselines. The baselines share the same setting as ours in that both of them require no parallel text and aim at removing language-specific factors in a post-training manner.
+
+Centered Libovický et al. (2020) extract language-neutral embeddings from the original pretrained multilingual sentence encoders via subtracting the mean embedding for each language. The mean embeddings are calculated from the multi-monolingual OSCAR corpus.
+
+LIR Yang et al. (2021) propose to project away the top- $k$ principal components of each language's embeddings to facilitate language agnosticism, where $k$ is the hyperparameter. Again, the top principal components are extracted from the multimonolingual corpus.
+
+# 4.2 Sentence Retrieval
+
+Tatoeba (Artetxe and Schwenk, 2019) is a commonly used dataset for evaluating ML-LMs. It comprises up to 1,000 sentences for each language along with their English translations. We follow the evaluation procedure of XTREME (Hu et al.,
+
+2020) that covers 36 languages. For each language pair, we go through each sentence in the source language and find the closest sentence in the target language using cosine similarity.
+
+The top-1 retrieval accuracy results are shown in Table 1. For mBERT (Devlin et al., 2019), XLM (Conneau and Lample, 2019), and XLM-R (Conneau et al., 2020a), applying LSAR brings significant performance gains of up to $19\%$ relative improvement. Compared with Centered and LIR which separately remove information for each language, LSAR jointly utilizes the encoded information from all the languages to better locate language-specific factors. Furthermore, we observe that LSAR consistently achieves the best results with hyperparameter $r$ (the rank of the low-rank subspace) equal to the number of the evaluated languages, as shown in Appendix C.1. As the languages are diversely distributed, it is reasonable that each language possesses its own linguistic characteristics, resulting in a larger language-specific subspace to factor out. In contrast, we find that LIR is vulnerable to its hyperparameter $k$ (the number of the removed principal components), which is best shown in Figure 7.
+
+For LABSE (Feng et al., 2022), all the methods fail to provide marked enhancement. This can be mainly attributed to the fact that LABSE already uses parallel corpora to explicitly align multilingual embeddings. Despite that the improvement is marginal, it is still promising to combine LSAR with existing pretraining objectives to produce better language-agnostic embeddings.
+
+We also include several representative baselines that finetune either mBERT or XLM-R for bet
+
+
+(a) Original
+
+
+(b) $\mathrm{w / LIR}(k = 1)$
+
+
+(c) w/ LSAR
+Figure 2: 2D PCA visualization on LAReQA. We display the embeddings collected from mBERT (X-X) on the XQuAD-R sub-dataset. Embeddings of the candidate answers (C) in English, Thai, and Mandarin are shown in small scatters. Embeddings of the question (Q) in English and the ground-truth answers (A) in English, Thai, and Mandarin are shown in large scatters. Higher opacity indicates higher predicted ranking (color bars: $\square$ / $\square$ / $\square$ ).
+
+ | XQuAD-R | MLQA-R |
| En-En | X-X | En-En | X-X |
| Original | 28.57 | 23.36 | 35.71 | 26.21 |
| Centered | 35.37 | 44.66 | 35.36 | 42.14 |
| LIR (k=1) | 37.70 | 44.25 | 38.03 | 41.96 |
| LSAR | 41.13 | 45.89 | 40.55 | 43.32 |
+
+Table 2: Answer retrieval mAP (%) on XQuAD-R and MLQA-R of LAReQA (averaged over all languages).
+
+ter cross-lingual transfer results. Although these methods are not directly comparable to ours, we believe it provides additional valuable findings to include them. Full-Model-FS and $\mathrm{S^4}$ -Tuning finetune XLM-R on full English labeled examples and then $K$ -shot data over target languages ( $K = 64 / 128$ ). For Full-Model, the pretrained models are finetuned on the English SQuAD data. On mBERT, LSAR outperforms Full-Model by a large margin. We also observe on XLM-R that LSAR is competitive with finetuning the full model on 128-shot data as well as finetuning a dedicated language subnetwork ( $\mathrm{S^4}$ -Tuning) on 64-shot data. The results are quite promising given that we obtain better performances with the original encoders intact and no task-relevant training data.
+
+# 4.3 Language-agonistic Answer Retrieval
+
+While Tatoeba reveals the cross-lingual transferability across English-centric language pairs, it is restricted to monolingual pools (i.e., the set of candidates is restricted to certain language). Therefore, it fails to thoroughly evaluate whether texts with a similar semantic meaning are grouped together in
+
+the latent space, regardless of their languages.
+
+With that in mind, we further examine the alignment methods on LAReQA (Roy et al., 2020), a challenging cross-lingual answer retrieval task. Unlike Tatoeba, the targets of LAReQA must be retrieved from a large multilingual candidate pool. It consists of two sub-datasets, XQuAD-R and MLQA-R, whose candidate pool covers 11 and 7 languages respectively.
+
+We follow Yang et al. (2021) to evaluate the alignment methods on two models, mBERT (En-En) and mBERT (X-X). Specifically, mBERT (En-En) finetunes the original mBERT model on the English QA pairs collected from the SQuAD v1.1 dataset. mBERT (X-X) employs the same training procedure but with an extended dataset where each sample is translated into the 11 XQuAD languages. Since all positive samples for finetuning are within the same language as the question query, both models exhibit strong self-language bias while preserving the weak alignment property. For evaluation, we use the dot product of embeddings to score a QA pair, which accords with the finetuning protocol. The retrieval performance is measured by mean Average Precision (mAP).
+
+Table 2 reports our LAReQA results. We can observe that applying LSAR again results in significant improvements, nearly doubling mAP of mBERT (X-X) on XQuAD-R. Since in the candidate pool each language has one of the relevant answers, better retrieval performances directly indicate better language agnosticism. Centered and LIR $(k = 1)$ also show impressive performances, suggesting that in weakly aligned multilingual sys
+
+ | mBERT | XLM | XLM-R |
| Original | 74.73 | 75.31 | 80.32 |
| LIR (k=1) | 75.39 | 75.73 | 81.14 |
| LSAR (r=1) | 75.58 | 74.93 | 81.47 |
| LSAR (r=2) | 75.49 | 75.85 | 82.37 |
| LSAR | 75.24 | 75.27 | 81.25 |
+
+Table 3: Classification accuracy (%) on Amazon Reviews (averaged over English, French, German and Japanese). We exclude Centered as the embeddings are already normalized and hence Centered produces the same results as Original. The results of LABSE are placed in Appendix C due to limited space.
+
+tems, the mean embeddings and principal components do encode language-specific signals. But for LIR, it is shown that removing the first principal component consistently leads to the best performance. This is opposite to what we observe on Tatoeba, where the optimal $k$ is around 15.
+
+To further illustrate the degree of language agnosticism, we project an English question (What theory best explains gravity?) as well as all candidates and the ground-truth answers in English, Thai, and Mandarin via PCA. As plotted in Figure 2, candidates in English are retrieved from mBERT (X-X) with higher priority than those in Thai and Mandarin. Applying LSAR can effectively eliminate strong language identity information residing in the original embedding space and draw closer the question and answers from different languages. LIR with $k = 1$ , however, falls short of rectifying language-specific signals as illustrated by the embedding spectrum in Figure 2b.
+
+# 4.4 Zero-shot Classification
+
+We also include the Amazon Reviews classification task (Prettenhofer and Stein, 2010) to assess zero-shot cross-lingual transfer. The dataset consists of product reviews in English, French, German, and Japanese. Each review is labeled as positive or negative, making it a binary classification task. We use
+
+ | mBERT | XLM | XLM-R |
| Original | 0.2815 | 0.5422 | 0.2457 |
| Centered | 0.0975 | 0.2483 | 0.2004 |
| LIR (k=1) | 0.0900 | 0.1875 | 0.2203 |
| LSAR | 0.0801 | 0.1320 | 0.0856 |
+
+Table 4: Clustering performance (NMI) of embeddings obtained by mBERT on Tatoeba. The results of LABSE are placed in Appendix C due to limited space.
+
+
+(a) Original
+Figure 3: Answer retrieval mAP on XQuAD-R broken down by question language (row) and answer language (column), with model mBERT (X-X). Only one correct answer is included in the multilingual candidate pool.
+
+
+(b) LSAR
+
+the same procedure to extract sentence embeddings as in Section 4.2, and normalize them to make regularization hyperparameters more consistent across languages. Appendix C.1 specifies how we select hyperparameters. Following (Yang et al., 2021), the performance is evaluated via training a logistic regression classifier3 on the English training data and then evaluating it on the test sets of all four languages.
+
+From Table 3, we observe that the classifier trained on English data benefits from LSAR for classifying reviews based on semantics as the language-specific factors are effectively erased. Another interesting observation is that unlike sentence retrieval, removing more directions does not result in better performance. This indicates that classification tasks can be more sensitive to semantic information.
+
+# 4.5 Analysis
+
+In this section, we present analysis on a variety of aspects towards what exactly language-specific information LSAR captures.
+
+# 4.5.1 Language-specific Signals are Rectified
+
+From previous findings, we conjecture that our method achieves impressive cross-lingual performance by effectively removing language identity signals. To quantitatively verify this, we measure the strength of language identity information from the perspective of clustering quality. If the embeddings are clustered by language types, we can generally state that language-specific signals still play a prominent role in the multilingual latent space.
+
+
+(a) $1^{\mathrm{st}}$ direction
+(b) $2^{\mathrm{nd}}$ direction
+
+We perform K-Means clustering on sentence representations of Tatoeba with the number of clusters equal to the number of languages, and then evaluate the resulting clusters using the Normalized Mutual Information (NMI) metric (Jawahar et al., 2019). As shown in Table 4, the original pretrained embeddings have relatively high NMI scores, suggesting the existence of strong language identity information. Our method consistently achieves smaller NMI scores. This indicates that the embeddings have a lower tendency to group by language types since LSAR successfully winnows down language-specific information.
+
+The same conclusion can be drawn from the limit-to-one-target setting of LAReQA (Roy et al., 2020). Specifically, we remove 10 targets from the multilingual pool of XQuAD-R to evaluate on each target separately. We choose the most biased X-X variant as the base model. The heatmaps in Figure 3 show for each question language (row), the retrieval mAP on the pool containing just one target in different answer languages (column). Since X-X has strong self-language bias, Original shows better performance on the diagonal than off-diagonal. After applying LSAR, we observe a significant increase in average off-diagonal performance (23.76% vs. 5.89%), without sacrificing much on-diagonal performance (81.57% vs. 84.57%). This again verifies that applying LSAR effectively removes language-specific information.
+
+# 4.5.2 Removed Components Form Groups of Language Families
+
+We next examine whether the removed components found by the low-rank subspace are truly language-
+
+
+Figure 4: Removed components along the top two basis vectors of the identified low-rank subspace on mBERT.
+Figure 5: Language similarity obtained from syntactic signals vs. language similarity measured by language-specific $s_{L}$ of mBERT. Each point is a language.
+
+specific. This is demonstrated via plotting the removed components for different languages along top basis vectors of the subspace. For the ease of visualization, we group them by language family.
+
+Figure 4 shows the histograms of removed components along the top two basis vectors extracted from mBERT on 36 languages of Tatoeba, according to Equation 1. We can observe that the removed components disperse in groups of language families along these directions. This implies that the identified subspace do capture language-specific signals and hence removing them along the basis vectors can narrow down latent discrepancy.
+
+# 4.5.3 The Identified Subspace Primarily Encodes Syntactic Information
+
+Finally, given that the removed components are language-specific, we investigate to what extent the low-rank subspace encodes typological relations among languages. Specifically, we use the URIEL database (Littell et al., 2017) to collect distances between English and other languages set out by experts based on certain typological information (e.g., syntax and phonology). We then compare the typological distances with languages similarities obtained from the removed language-specific embeddings $s_{L}$ as well as the resulting language-agnostic embeddings $a_{L}$ by calculating the cosine similarity between languages' mean embeddings.
+
+Among all types of typological signals listed in URIEL, we find that the removed language-specific factors are mostly correlated with syntactic information. Table 5 shows the Pearson correlations on English and other 36 languages from Tatoeba. The removed language-specific component $s_{L}$ is highly correlated with syntactic infor
+
+ | mBERT | XLM | XLM-R | LABSE |
| sL | 0.6910 | 0.6378 | 0.7526 | 0.6894 |
| aL | -0.2711 | 0.2239 | 0.1338 | -0.2362 |
+
+Table 5: Pearson correlations between syntactic language similarities obtained from the URIEL database, and the language similarities obtained from language-specific $s_{L}$ as well as language-agnostic $a_{L}$ .
+
+mation, whereas the correlation is much smaller in the language-agnostic embedding space with $s_L$ removed. This finding is in line with previous works (Chi et al., 2020; Zhao et al., 2021) that observe the pretrained multilingual models encode rich syntactic information.
+
+We find no prominent correlation between the removed components along certain basis vectors of the subspace and typological information. As we do not presuppose any correspondence between basis vectors and linguistic signals, a specific basis vector falls short of individually encoding language-specific information.
+
+# 5 Conclusion
+
+We present a simple yet effective approach called LSAR to boost language agnosticism for pretrained multilingual encoders. LSAR identifies a low-rank subspace residing in a pretrained model that primarily encodes language-specific signals in an unsupervised manner via singular value decomposition. Once the subspace is discovered, it can be used to efficiently project away the language identity information. Empirical results demonstrate the great effectiveness of LSAR on semantic tasks and shed light on its ability to locate syntactic relations between languages.
+
+# Limitations
+
+Our method LSAR is designed and evaluated for semantic tasks. For future work, we are interested in continuing our study for locating more fine-grained linguistic information, which can potentially boost a larger variety of downstream tasks. While the simplicity of the proposed LSAR is appealing, it also opens up directions for future work by generalizing the first-moment mean embeddings to higher-moment statistics and combining with pretraining objectives in more sophisticated ways.
+
+# References
+
+Mikel Artetxe and Holger Schwenk. 2019. Massively multilingual sentence embeddings for zero-shot cross-lingual transfer and beyond. Transactions of the Association for Computational Linguistics, 7:597-610.
+Lars Buitinck, Gilles Louppe, Mathieu Blondel, Fabian Pedregosa, Andreas Mueller, Olivier Grisel, Vlad Niculae, Peter Prettenhofer, Alexandre Gramfort, Jaques Grobler, Robert Layton, Jake VanderPlas, Arnaud Joly, Brian Holt, and Gael Varoquaux. 2013. API design for machine learning software: experiences from the scikit-learn project. In ECML PKDD Workshop: Languages for Data Mining and Machine Learning, pages 108-122.
+Tyler A. Chang, Zhuowen Tu, and Benjamin K. Bergen. 2022. The geometry of multilingual language model representations. CoRR, abs/2205.10964.
+Ethan A. Chi, John Hewitt, and Christopher D. Manning. 2020. Finding universal grammatical relations in multilingual BERT. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5564-5577, Online. Association for Computational Linguistics.
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettle-moyer, and Veselin Stoyanov. 2020a. Unsupervised cross-lingual representation learning at scale. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8440-8451, Online. Association for Computational Linguistics.
+Alexis Conneau and Guillaume Lample. 2019. Crosslingual language model pretraining. In Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc.
+Alexis Conneau, Rudy Rinott, Guillaume Lample, Adina Williams, Samuel Bowman, Holger Schwenk, and Veselin Stoyanov. 2018. XNLI: Evaluating crosslingual sentence representations. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2475-2485, Brussels, Belgium. Association for Computational Linguistics.
+Alexis Conneau, Shijie Wu, Haoran Li, Luke Zettlemoyer, and Veselin Stoyanov. 2020b. Emerging cross-lingual structure in pretrained language models. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6022–6034, Online. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for
+
+Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Carl Eckart and Gale Young. 1936. The approximation of one matrix by another of lower rank. Psychometrika, 1(3):211-218.
+Fangxiaoyu Feng, Yinfei Yang, Daniel Cer, Naveen Arivazhagan, and Wei Wang. 2022. Language-agnostic BERT sentence embedding. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 878-891, Dublin, Ireland. Association for Computational Linguistics.
+Hila Gonen, Shauli Ravfogel, Yanai Elazar, and Yoav Goldberg. 2020. It's not Greek to mBERT: Inducing word-level translations from multilingual BERT. In Proceedings of the Third BlackboxNLP Workshop on Analyzing and Interpreting Neural Networks for NLP, pages 45-56, Online. Association for Computational Linguistics.
+Mandy Guo, Zihang Dai, Denny Vrandecic, and Rami Al-Rfou. 2020. Wiki-40B: Multilingual language model dataset. In Proceedings of the 12th Language Resources and Evaluation Conference, pages 2440-2452, Marseille, France. European Language Resources Association.
+Junjie Hu, Sebastian Ruder, Aditya Siddhant, Graham Neubig, Orhan First, and Melvin Johnson. 2020. XTREME: A massively multilingual multitask benchmark for evaluating cross-lingual generalisation. In Proceedings of the 37th International Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research, pages 4411-4421. PMLR.
+Ganesh Jawahar, Benoit Sagot, and Djamé Seddah. 2019. What does BERT learn about the structure of language? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3651-3657, Florence, Italy. Association for Computational Linguistics.
+Karthikeyan K, Zihan Wang, Stephen Mayhew, and Dan Roth. 2020. Cross-lingual ability of multilingual bert: An empirical study. In International Conference on Learning Representations.
+Mikhail Khodak, Nikunj Saunshi, Yingyu Liang, Tengyu Ma, Brandon Stewart, and Sanjeev Arora. 2018. A la carte embedding: Cheap but effective induction of semantic feature vectors. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 12-22, Melbourne, Australia. Association for Computational Linguistics.
+Patrick Lewis, Barlas Oguz, Rudy Rinott, Sebastian Riedel, and Holger Schwenk. 2020. MLQA: Evaluating cross-lingual extractive question answering. In
+
+Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7315-7330, Online. Association for Computational Linguistics.
+Sheng Liang, Philipp Dufter, and Hinrich Schütze. 2021. Locating language-specific information in contextualized embeddings. CoRR, abs/2109.08040.
+Jindrich Libovický, Rudolf Rosa, and Alexander Fraser. 2020. On the language neutrality of pre-trained multilingual representations. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 1663–1674, Online. Association for Computational Linguistics.
+Patrick Littell, David R. Mortensen, Ke Lin, Katherine Kairis, Carlisle Turner, and Lori Levin. 2017. URIEL and lang2vec: Representing languages as typological, geographical, and phylogenetic vectors. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers, pages 8-14, Valencia, Spain. Association for Computational Linguistics.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Saeid Motiian, Quinn Jones, Seyed Iranmanesh, and Gianfranco Doretto. 2017. Few-shot adversarial domain adaptation. In Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc.
+Krikamol Muandet, David Balduzzi, and Bernhard Schölkopf. 2013. Domain generalization via invariant feature representation. In Proceedings of the 30th International Conference on Machine Learning, volume 28 of Proceedings of Machine Learning Research, pages 10-18, Atlanta, Georgia, USA. PMLR.
+Benjamin Muller, Yanai Elazar, Benoit Sagot, and Djamé Seddah. 2021. First align, then predict: Understanding the cross-lingual ability of multilingual BERT. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 2214–2231, Online. Association for Computational Linguistics.
+Pedro Javier Ortiz Suárez, Laurent Romary, and Benoit Sagot. 2020. A monolingual approach to contextualized word embeddings for mid-resource languages. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 1703-1714, Online. Association for Computational Linguistics.
+Sinno Jialin Pan, Ivor W. Tsang, James T. Kwok, and Qiang Yang. 2011. Domain adaptation via transfer component analysis. IEEE Transactions on Neural Networks, 22(2):199-210.
+
+Matthew E. Peters, Mark Neumann, Mohit Iyyer, Matt Gardner, Christopher Clark, Kenton Lee, and Luke Zettlemoyer. 2018. Deep contextualized word representations. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 2227-2237, New Orleans, Louisiana. Association for Computational Linguistics.
+Vihari Piratla, Praneeth Netrapalli, and Sunita Sarawagi. 2020. Efficient domain generalization via common-specific low-rank decomposition. In Proceedings of the 37th International Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research, pages 7728-7738. PMLR.
+Telmo Pires, Eva Schlinger, and Dan Garrette. 2019. How multilingual is multilingual BERT? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4996-5001, Florence, Italy. Association for Computational Linguistics.
+Peter Prettenhofer and Benno Stein. 2010. Cross-language text classification using structural correspondence learning. In Proceedings of the 48th Annual Meeting of the Association for Computational Linguistics, pages 1118-1127, Uppsala, Sweden. Association for Computational Linguistics.
+Uma Roy, Noah Constant, Rami Al-Rfou, Aditya Barua, Aaron Phillips, and Yinfei Yang. 2020. LAReQA: Language-agnostic answer retrieval from a multilingual pool. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 5919–5930, Online. Association for Computational Linguistics.
+Sebastian Ruder, Noah Constant, Jan Botha, Aditya Siddhant, Orhan Firat, Jinlan Fu, Pengfei Liu, Junjie Hu, Dan Garrette, Graham Neubig, and Melvin Johnson. 2021. XTREME-R: Towards more challenging and nuanced multilingual evaluation. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 10215-10245, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Erhard Schmidt. 1907. Zur theorie der linearen und nichtlinearen integralgleichungen. i. Teil: Entwicklung willkürlicher Funktionen nach systemen vorgeschriebener. Mathematische Annalen, 63:433-476.
+M.A. Turk and A.P. Pentland. 1991. Face recognition using eigenfaces. In Proceedings. 1991 IEEE Computer Society Conference on Computer Vision and Pattern Recognition, pages 586-591.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. Advances in neural information processing systems, 30.
+
+Binxu Wang and Carlos R Ponce. 2021. A geometric analysis of deep generative image models and its applications. In International Conference on Learning Representations.
+Xiaogang Wang and Xiaou Tang. 2004. A unified framework for subspace face recognition. IEEE Transactions on Pattern Analysis and Machine Intelligence, 26(9):1222-1228.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+Shijie Wu and Mark Dredze. 2019. Beto, bentz, becas: The surprising cross-lingual effectiveness of BERT. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 833–844, Hong Kong, China. Association for Computational Linguistics.
+Runxin Xu, Fuli Luo, Baobao Chang, Songfang Huang, and Fei Huang. 2022. S $^4$ -tuning: A simple cross-lingual sub-network tuning method. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 530–537, Dublin, Ireland. Association for Computational Linguistics.
+Ziyi Yang, Yinfei Yang, Daniel Cer, and Eric Darve. 2021. A simple and effective method to eliminate the self language bias in multilingual representations. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 5825-5832, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Wei Zhao, Steffen Eger, Johannes Bjerva, and Isabelle Augenstein. 2021. Inducing language-agnostic multilingual representations. In Proceedings of *SEM 2021: The Tenth Joint Conference on Lexical and Computational Semantics*, pages 229–240, Online. Association for Computational Linguistics.
+Jiapeng Zhu, Ruili Feng, Yujun Shen, Deli Zhao, Zheng-Jun Zha, Jingren Zhou, and Qifeng Chen. 2021. Low-rank subspaces in gans. In Advances in Neural Information Processing Systems, volume 34, pages 16648-16658. Curran Associates, Inc.
+
+# A Theoretical Justification
+
+In this section, we present Theorem 1 and the corresponding proof. We follow the same proving procedure in Piratla et al. (2020).
+
+Theorem 1. For any matrix $M \in \mathbb{R}^{d \times L}$ , Algorithm 1 returns $\pmb{\mu} \in \mathbb{R}^d$ , $M_s \in \mathbb{R}^{d \times r}$ , $\Gamma \in \mathbb{R}^{L \times r}$ that minimize Equation 1 where $\pmb{\mu} \perp \operatorname{Span}(M_s)$ .
+
+Proof. Algorithm 1 first obtains the best approximation of $M$ with rank $r + 1$ and $\mathbb{1}$ in its row space (Line 1-3). The orthogonal constraint $\mu \perp$ Span $(M_s)$ is then forced without obeying the low-rank property (Line 4-5).
+
+To begin with, note that the optimization problem in Equation 1 is equivalent to the following:
+
+$$
+\begin{array}{l} \begin{array}{c c} \underset {\widehat {M}} {\min } & \left\| M - \widehat {M} \right\| _ {F} ^ {2} \end{array} \\ \text {s . t .} \quad \operatorname {r a n k} (\widehat {\boldsymbol {M}}) \leq r + 1 \text {a n d} \tag {2} \\ \mathbb {1} \in \operatorname {S p a n} \left(\widehat {\boldsymbol {M}} ^ {\top}\right). \\ \end{array}
+$$
+
+Let $\pmb{U}, \pmb{\Sigma}, \pmb{V} = \mathrm{SVD}\left(M - \mu' \mathbb{1}^\top\right)$ . We have that $\mathbb{1} \perp \operatorname{Span}\left(\pmb{V}^\top\right)$ given $\left(M - \mu' \mathbb{1}^\top\right) \mathbb{1} = 0$ . Denote by $U_r \Sigma_r V_r^\top$ the top- $r$ component of $U \Sigma V^\top$ , by $\sigma_i(A)$ the $i$ -th largest singular value of $A$ and by $A_i$ the best rank- $i$ approximation of $A$ .
+
+The first step is to show that $\pmb{\mu}^{\prime}\mathbb{1}^{\top} + \pmb{U}_{r}\pmb{\Sigma}_{r}\pmb{V}_{r}^{\top}$ minimizes the objective in Equation 2. Following the proof of Eckart-Young-Mirsky theorem for low-rank approximation (Schmidt, 1907; Eckart and Young, 1936), let $\widetilde{M} := M - \widehat{M}$ with any feasible $\widehat{M}$ fixed. We have
+
+$$
+\begin{array}{l} \sigma_ {i} (\widetilde {\boldsymbol {M}}) = \left\| \widetilde {\boldsymbol {M}} - \widetilde {\boldsymbol {M}} _ {i - 1} \right\| _ {F} \\ = \left\| \widetilde {\boldsymbol {M}} - \widetilde {\boldsymbol {M}} _ {i - 1} \right\| _ {F} + \left\| \widehat {\boldsymbol {M}} - \widehat {\boldsymbol {M}} \right\| _ {F} \\ \geq \left\| \widetilde {\boldsymbol {M}} + \widehat {\boldsymbol {M}} - \widetilde {\boldsymbol {M}} _ {i - 1} - \widehat {\boldsymbol {M}} \right\| _ {F} \\ = \left\| M - \widetilde {M} _ {i - 1} - \widehat {M} \right\| _ {F} \\ \geq \min _ {\bar {M}} \left\| M - \bar {M} \right\| _ {F}, \\ \end{array}
+$$
+
+where the minimum is taken over all $\bar{M}$ with rank $(\bar{M}) = i + r$ and $\mathbb{1} \in \operatorname{Span}\left(\bar{M}^{\top}\right)$ . By taking $\bar{M} = \pmb{\mu}'\mathbb{1}^{\top} + \pmb{U}_{i + r - 1}\pmb{\Sigma}_{i + r - 1}\pmb{V}_{i + r - 1}^{\top}$ , we have $\sigma_{i}\left(\widetilde{M}\right) \geq \sigma_{i + r}\left(\pmb{U}\pmb{\Sigma}\pmb{V}^{\top}\right)$ and therefore $\left\| M - \widehat{M}\right\|_F^2 \geq \left\| M - \pmb{\mu}'\mathbb{1}^{\top} - \pmb{U}_r\pmb{\Sigma}_r\pmb{V}_r^{\top}\right\|_F^2$ .
+
+Next, we find $\pmb{\mu}$ and $M_{s}$ that meet the orthogonality constraint while preserving the low-rank structure. Suppose $\pmb {\mu}\mathbb{1}^{\top} + M_{s}\pmb{\Gamma}^{\top} = \pmb{\mu}^{\prime}\mathbb{1}^{\top}+$ $M_s^\prime \Gamma^{\prime \top}$ with $\pmb {\mu}\perp$ Span $(M_{s})$ , we have that $\pmb{\mu}^{\top}\left(\pmb {\mu}\mathbb{1}^{\top} + M_{s}\pmb{\Gamma}^{\top}\right) = \| \pmb {\mu}\|^{2}\mathbb{1}^{\top}$ which yields $\pmb{\mu}^{\top} = \| \pmb {\mu}\|^{2}\left(\pmb{\mu}^{\prime}\mathbb{1}^{\top} + M_{s}^{\prime}\pmb{\Gamma}^{\prime \top}\right)^{+}\mathbb{1}^{\top}.$
+
+# B Base Models
+
+We evaluate the alignment methods based on a number of established pretrained multilingual models. We mainly build on the Transformers library (Wolf et al., 2020) for our experiments.
+
+mBERT $^{5}$ Multilingual BERT (Devlin et al., 2019) is a transformer model (Vaswani et al., 2017) pretrained on Wikipedia, with the objective of Masked Language Modeling (MLM) and a shared vocabulary across all languages.
+
+XLM $^{6}$ XLM (Conneau and Lample, 2019) also uses the MLM objective and the monolingual Wikipedia corpus for pretraining, with a larger model and a larger vocabulary.
+
+XLM-R7 XLM-R (Conneau et al., 2020a) follows a similar training procedure as XLM but collects the larger-scale CommonCrawl corpus.
+
+LABSE $^{8}$ LABSE (Feng et al., 2022) is the state-of-the-art multilingual sentence encoder that leverages bilingual sentence pairs for pretraining.
+
+Following previous works (Jawahar et al., 2019; Ruder et al., 2021) that observe certain intermediate layers of Transformer consistently outperform the last layer for cross-lingual tasks, we use the 8th layer for mBERT and XLM, and the 12th layer for XLM-R. We apply mean-pooling to obtain sentence embeddings as it is widely used (Conneau et al., 2020b; Muller et al., 2021). For LABSE as well as mBERT (X-X) and mBERT (En-En) used in LAReQA, we evaluate the alignment methods on the original sentence embeddings.
+
+# C Supplementary Results
+
+In this section, we provide supplementary experimental results.
+
+# C.1 Hyperparameter Selection
+
+For the considered baselines, we do not conduct sophisticated hyperparameter search given that it is non-trivial for LIR. To provide fair comparison, for LIR and LSAR that both have one single hyperparameter (the number of top principal components $k$ and the number of basis vectors to span the low-rank subspace $r$ ), we exhaustively enumerate all
+
+
+(a) mBERT
+
+
+(b) XLM
+
+
+(c) XLM-R
+Figure 6: Retrieval accuracy on Tatoeba (averaged over all 36 languages) at different layers.
+
+ | XQuAD-R | MLQA-R |
| En-En | X-X | En-En | X-X |
| Original | 28.57 | 23.36 | 35.71 | 26.21 |
| Centered | 35.38 | 45.47 | 35.87 | 43.27 |
| LIR (k=1) | 36.71 | 45.24 | 37.56 | 43.24 |
| LIR (k=2) | 36.70 | 44.74 | 37.11 | 42.42 |
| LIR (k=3) | 36.82 | 44.54 | 36.87 | 42.28 |
| LSAR (r=1) | 30.51 | 26.38 | 36.79 | 28.79 |
| LSAR (r=2) | 32.31 | 29.22 | 38.05 | 31.70 |
| LSAR (r=3) | 34.05 | 31.99 | 39.00 | 35.28 |
| LSAR | 40.95 | 46.39 | 40.70 | 44.02 |
+
+Table 6: Answer retrieval mAP (%) on XQuAD-R and MLQA-R of LAReQA (averaged over all languages), using Wiki-40B as the text resource.
+
+values within a scope and report the best performances on the test data. Figure 7 shows the trend of accuracy on Tatoeba as the hyperparameters change.
+
+# C.2 Wiki40-B Results
+
+In this section we list the results of LAReQA (Table 6) and Amazon Reviews (Table 8-11) with Wiki-40B (Guo et al., 2020)9 as the text resource. For Amazon Reviews, we also report the performances obtained in the last layers to reproduce those in Yang et al. (2021).
+
+For Amazon Reviews, we determine the L2 regularization strength using a hyperparameter sweep on the 5-fold cross-validation routine, over the range between 1e-4 and 1e4 with 10 logarithmically spaced steps. This training procedure is implemented using the Scikit-Learn library (Buitinck et al., 2013).
+
+ | XQuAD-R | MLQA-R |
| En-En | X-X | En-En | X-X |
| Original | 28.57 | 23.36 | 35.71 | 26.21 |
| Centered | 35.37 | 44.66 | 35.36 | 42.14 |
| LIR (k=1) | 37.70 | 44.25 | 38.03 | 41.96 |
| LIR (k=2) | 36.83 | 43.58 | 37.60 | 41.63 |
| LIR (k=3) | 36.21 | 43.15 | 36.89 | 41.03 |
| LSAR (r=1) | 30.50 | 26.27 | 36.68 | 28.59 |
| LSAR (r=2) | 32.36 | 28.69 | 37.94 | 31.15 |
| LSAR (r=3) | 34.20 | 31.49 | 38.82 | 34.46 |
| LSAR | 41.13 | 45.89 | 40.55 | 43.32 |
+
+Table 7: Answer retrieval mAP (%) on XQuAD-R and MLQA-R of LAReQA (averaged over all languages), using OSCAR as the text resource.
+
+# C.3 OSCAR Results
+
+The detailed results with OSCAR is provided in this section.
+
+Tatoeba We report the results for all languages on Tatoeba in Table 17-20. Additionally, the complete set of results for clustering performance is shown in Table 12.
+
+LAReQA We report the detailed results on LAReQA in Table 7. We omit listing all languages due to limited space.
+
+Amazon Reviews We provide the results for all languages on Amazon Reviews in Table 13-16.
+
+ | Layer 8 | Layer 12 |
| en | de | fr | jp | avg. | em | de | fr | jp | avg. |
| Original | 81.13 | 72.82 | 76.02 | 68.98 | 74.74 | 80.07 | 70.05 | 73.75 | 64.86 | 72.18 |
| LIR (k=1) | 81.12 | 72.33 | 76.80 | 72.25 | 75.62 | 80.03 | 70.00 | 71.73 | 67.51 | 72.32 |
| LIR (k=2) | 81.05 | 71.90 | 76.80 | 72.35 | 75.52 | 79.98 | 71.15 | 72.50 | 69.04 | 73.17 |
| LIR (k=3) | 81.10 | 72.23 | 76.22 | 71.06 | 75.15 | 80.03 | 70.85 | 73.67 | 69.36 | 73.48 |
| LSAR (r=1) | 81.12 | 72.77 | 75.87 | 72.30 | 75.51 | 79.98 | 71.17 | 73.68 | 71.15 | 73.99 |
| LSAR (r=2) | 81.13 | 72.50 | 76.85 | 72.33 | 75.70 | 80.08 | 71.23 | 73.45 | 70.91 | 73.92 |
| LSAR | 81.12 | 72.43 | 76.67 | 72.36 | 75.64 | 79.87 | 70.10 | 71.95 | 68.69 | 72.65 |
+
+Table 8: Classification accuracy (%) on Amazon Reviews (mBERT), using Wiki-40B as the text resource.
+
+ | Layer 8 | Layer 12 |
| en | de | fr | jp | avg. | em | de | fr | jp | avg. |
| Original | 85.45 | 69.07 | 81.50 | 65.21 | 75.31 | 84.43 | 55.42 | 72.87 | 58.23 | 67.74 |
| LIR (k=1) | 85.52 | 73.68 | 81.52 | 65.66 | 76.59 | 84.50 | 75.77 | 79.88 | 60.98 | 75.28 |
| LIR (k=2) | 85.52 | 73.32 | 81.45 | 64.31 | 76.15 | 84.65 | 75.58 | 79.73 | 60.79 | 75.19 |
| LIR (k=3) | 85.60 | 72.10 | 81.62 | 62.46 | 75.44 | 84.52 | 75.52 | 79.40 | 63.03 | 75.62 |
| LSAR (r=1) | 85.53 | 70.98 | 81.52 | 66.44 | 76.12 | 84.45 | 56.75 | 75.20 | 66.64 | 70.76 |
| LSAR (r=2) | 85.48 | 73.77 | 81.65 | 65.43 | 76.58 | 84.48 | 60.35 | 71.25 | 66.54 | 70.66 |
| LSAR | 85.50 | 73.78 | 81.63 | 65.41 | 76.58 | 84.48 | 75.78 | 79.57 | 64.99 | 76.21 |
+
+Table 9: Classification accuracy (%) on Amazon Reviews (XLM), using Wiki-40B as the text resource.
+
+ | Layer 11 | Layer 24 |
| en | de | fr | jp | avg. | em | de | fr | jp | avg. |
| Original | 84.33 | 78.32 | 82.30 | 76.35 | 80.32 | 90.55 | 78.08 | 83.57 | 67.14 | 79.84 |
| LIR (k=1) | 84.33 | 82.47 | 81.68 | 80.18 | 82.17 | 90.53 | 88.67 | 89.88 | 86.16 | 88.81 |
| LIR (k=2) | 84.45 | 82.18 | 82.10 | 80.08 | 82.20 | 90.62 | 88.48 | 88.27 | 85.61 | 88.25 |
| LIR (k=3) | 84.33 | 81.40 | 83.08 | 78.48 | 81.82 | 90.67 | 88.55 | 88.40 | 85.61 | 88.31 |
| LSAR (r=1) | 84.35 | 77.95 | 81.93 | 79.78 | 81.00 | 90.62 | 69.20 | 90.00 | 83.98 | 83.45 |
| LSAR (r=2) | 84.33 | 82.52 | 81.17 | 80.53 | 82.14 | 90.60 | 88.73 | 79.18 | 79.30 | 84.45 |
| LSAR | 84.30 | 82.67 | 81.80 | 80.56 | 82.33 | 90.58 | 88.42 | 89.33 | 85.95 | 88.57 |
+
+Table 10: Classification accuracy (%) on Amazon Reviews (XLM-R), using Wiki-40B as the text resource.
+
+ | en | de | fr | jp | avg. |
| Original | 83.32 | 81.37 | 84.27 | 79.26 | 82.05 |
| LIR (k=1) | 83.18 | 81.70 | 84.32 | 79.51 | 82.18 |
| LIR (k=2) | 83.20 | 81.92 | 84.18 | 79.33 | 82.16 |
| LIR (k=3) | 83.18 | 81.83 | 84.32 | 79.45 | 82.19 |
| LSAR (r=1) | 83.32 | 81.30 | 84.28 | 79.21 | 82.03 |
| LSAR (r=2) | 83.10 | 81.63 | 83.90 | 79.61 | 82.06 |
| LSAR | 83.27 | 81.77 | 83.95 | 79.75 | 82.18 |
+
+Table 11: Classification accuracy (%) on Amazon Reviews (LABSE), using Wiki-40B as the text resource.
+
+ | mBERT | XLM | XLM-R | LABSE |
| Original | 0.2815 | 0.5422 | 0.2457 | 0.0344 |
| Centered | 0.0975 | 0.2483 | 0.2004 | 0.0388 |
| LIR (k=1) | 0.0900 | 0.1875 | 0.2203 | 0.0352 |
| LSAR | 0.0801 | 0.1320 | 0.0856 | 0.0306 |
+
+Table 12: Clustering performance (NMI) of embeddings obtained by mBERT on Tatoeba.
+
+
+(a) mBERT
+
+
+(b) XLM
+Figure 7: Retrieval accuracy on Tatoeba (averaged over all 36 languages) with different hyperparameters ( $k$ for LIR and $r$ for LSAR). We observe that removing more principal components within each language for LIR does not result in better performances and can instead lead to information loss. For mBERT and XLM, the best $k$ is found 17, whereas it is 14 for XLM-R. LSAR, however, consistently achieves the best results with $r = 36$ as larger subspaces encode more language-specific signals.
+
+
+(c) XLM-R
+
+ | Layer 8 | Layer 12 |
| en | de | fr | jp | avg. | em | de | fr | jp | avg. |
| Original | 81.13 | 72.82 | 76.02 | 68.98 | 74.74 | 80.07 | 70.05 | 73.75 | 64.86 | 72.18 |
| LIR (k=1) | 81.12 | 72.90 | 75.08 | 72.43 | 75.38 | 80.07 | 71.08 | 71.40 | 67.11 | 72.42 |
| LIR (k=2) | 81.03 | 71.47 | 70.58 | 66.09 | 72.29 | 79.97 | 69.35 | 72.07 | 66.29 | 71.92 |
| LIR (k=3) | 80.85 | 68.67 | 74.38 | 67.53 | 72.86 | 79.88 | 66.10 | 69.80 | 66.59 | 70.59 |
| LSAR (r=1) | 81.25 | 72.78 | 75.80 | 72.48 | 75.58 | 79.98 | 71.03 | 73.62 | 70.45 | 73.77 |
| LSAR (r=2) | 81.27 | 72.57 | 75.85 | 72.30 | 75.49 | 80.07 | 71.12 | 73.48 | 70.11 | 73.69 |
| LSAR | 81.15 | 72.90 | 75.22 | 71.68 | 75.24 | 79.88 | 70.80 | 71.70 | 67.79 | 72.54 |
+
+Table 13: Classification accuracy (%) on Amazon Reviews (mBERT), using OSCAR as the text resource.
+
+ | Layer 8 | Layer 12 |
| en | de | fr | jp | avg. | em | de | fr | jp | avg. |
| Original | 85.45 | 69.07 | 81.50 | 65.21 | 75.31 | 84.43 | 55.42 | 72.87 | 58.23 | 67.74 |
| LIR (k=1) | 85.58 | 77.57 | 80.05 | 59.74 | 75.74 | 84.52 | 75.75 | 80.20 | 55.26 | 73.93 |
| LIR (k=2) | 85.40 | 76.72 | 79.82 | 60.86 | 75.70 | 84.48 | 75.57 | 77.95 | 55.46 | 73.36 |
| LIR (k=3) | 85.15 | 77.42 | 81.07 | 51.51 | 73.79 | 84.48 | 74.55 | 76.13 | 51.26 | 71.61 |
| LSAR (r=1) | 85.47 | 69.08 | 81.42 | 63.78 | 74.94 | 84.50 | 56.33 | 74.63 | 66.84 | 70.58 |
| LSAR (r=2) | 85.37 | 74.53 | 81.60 | 61.88 | 75.84 | 84.50 | 57.75 | 72.80 | 66.86 | 70.48 |
| LSAR | 85.45 | 77.15 | 80.25 | 58.24 | 75.27 | 84.62 | 75.87 | 80.65 | 57.14 | 74.57 |
+
+Table 14: Classification accuracy (%) on Amazon Reviews (XLM), using OSCAR as the text resource.
+
+ | Layer 11 | Layer 24 |
| en | de | fr | jp | avg. | em | de | fr | jp | avg. |
| Original | 84.33 | 78.32 | 82.30 | 76.35 | 80.32 | 90.55 | 78.08 | 83.57 | 67.14 | 79.84 |
| LIR (k=1) | 84.32 | 82.55 | 77.82 | 79.93 | 81.15 | 90.53 | 88.85 | 87.67 | 86.11 | 88.29 |
| LIR (k=2) | 84.42 | 82.27 | 78.15 | 79.45 | 81.07 | 90.63 | 89.12 | 85.93 | 85.86 | 87.89 |
| LIR (k=3) | 84.33 | 81.05 | 77.57 | 79.16 | 80.53 | 90.68 | 89.85 | 84.68 | 86.30 | 87.88 |
| LSAR (r=1) | 84.32 | 78.80 | 82.12 | 80.66 | 81.47 | 90.55 | 83.47 | 77.67 | 80.86 | 83.14 |
| LSAR (r=2) | 84.32 | 82.55 | 82.08 | 80.53 | 82.37 | 90.55 | 87.63 | 76.57 | 77.66 | 83.10 |
| LSAR | 84.27 | 82.60 | 77.85 | 80.28 | 81.25 | 90.57 | 89.37 | 88.03 | 86.01 | 88.50 |
+
+Table 15: Classification accuracy (%) on Amazon Reviews (XLM-R), using OSCAR as the text resource.
+
+ | en | de | fr | jp | avg. |
| Original | 83.32 | 81.37 | 84.27 | 79.26 | 82.05 |
| LIR (k=1) | 83.40 | 81.85 | 82.62 | 79.81 | 81.92 |
| LIR (k=2) | 83.28 | 80.92 | 78.37 | 78.73 | 80.32 |
| LIR (k=3) | 82.88 | 78.92 | 78.82 | 78.85 | 79.87 |
| LSAR (r=1) | 83.07 | 81.52 | 83.88 | 79.20 | 81.92 |
| LSAR (r=2) | 83.02 | 82.10 | 83.55 | 79.66 | 82.08 |
| LSAR | 83.13 | 81.92 | 83.18 | 79.48 | 81.93 |
+
+Table 16: Classification accuracy (%) on Amazon Reviews (LABSE), using OSCAR as the text resource.
+
+ | af | ar | bg | bn | de | el | es | et | eu | fa | fi | fr |
| Original | 38.90 | 24.50 | 48.80 | 17.00 | 75.40 | 29.80 | 64.10 | 28.10 | 25.50 | 41.20 | 39.00 | 64.30 |
| Centered | 40.90 | 27.30 | 48.50 | 17.30 | 74.70 | 35.10 | 66.40 | 29.60 | 27.40 | 43.70 | 40.30 | 65.30 |
| LIR (k=1) | 41.00 | 27.20 | 48.60 | 17.90 | 74.90 | 35.10 | 66.40 | 30.10 | 27.70 | 44.00 | 40.50 | 64.90 |
| LSAR | 44.70 | 31.80 | 55.00 | 21.90 | 79.00 | 38.70 | 71.20 | 35.30 | 32.00 | 49.80 | 46.40 | 69.10 |
| he | hi | hu | id | it | ja | jv | ka | kk | ko | ml | mr |
| Original | 40.10 | 34.80 | 36.90 | 53.50 | 57.30 | 40.90 | 17.56 | 19.57 | 27.13 | 36.00 | 17.90 | 20.10 |
| Centered | 41.50 | 35.40 | 41.40 | 53.40 | 58.30 | 41.60 | 18.54 | 23.32 | 30.96 | 38.70 | 27.66 | 23.00 |
| LIR (k=1) | 41.70 | 35.40 | 41.60 | 53.70 | 58.20 | 41.90 | 18.05 | 23.73 | 30.96 | 38.80 | 28.82 | 23.00 |
| LSAR | 45.70 | 43.90 | 46.00 | 60.00 | 61.90 | 51.00 | 24.88 | 28.28 | 34.09 | 45.30 | 36.83 | 26.40 |
| nl | pt | ru | sw | ta | te | th | tl | tr | ur | vi | zh |
| Original | 63.70 | 68.40 | 59.40 | 10.77 | 13.36 | 14.10 | 13.69 | 16.00 | 32.90 | 30.80 | 61.00 | 68.60 |
| Centered | 64.30 | 69.50 | 62.40 | 12.56 | 14.33 | 14.96 | 17.15 | 18.10 | 38.20 | 31.40 | 62.20 | 69.00 |
| LIR (k=1) | 65.10 | 69.30 | 62.10 | 12.31 | 14.33 | 14.96 | 17.15 | 18.20 | 38.20 | 32.10 | 62.00 | 69.20 |
| LSAR | 69.20 | 73.10 | 67.20 | 14.36 | 18.57 | 21.37 | 21.72 | 22.00 | 41.90 | 38.00 | 67.10 | 73.30 |
+
+Table 17: Retrieval accuracy (%) on Tatoeba for each language (mBERT), using OSCAR as the text resource.
+
+ | af | ar | bg | bn | de | el | es | et | eu | fa | fi | fr |
| Original | 34.20 | 17.80 | 34.80 | 5.70 | 62.20 | 24.90 | 56.00 | 18.40 | 11.90 | 30.50 | 28.10 | 52.80 |
| Centered | 30.30 | 17.30 | 35.30 | 5.00 | 62.20 | 22.50 | 53.50 | 19.20 | 14.70 | 29.90 | 31.30 | 49.20 |
| LIR (k=1) | 32.20 | 18.20 | 37.30 | 5.80 | 65.10 | 25.60 | 54.10 | 21.10 | 16.60 | 31.00 | 32.00 | 51.70 |
| LSAR | 37.50 | 20.10 | 42.40 | 9.90 | 68.20 | 30.50 | 58.80 | 25.50 | 22.00 | 35.00 | 36.10 | 55.10 |
| he | hi | hu | id | it | ja | jv | ka | kk | ko | ml | mr |
| Original | 31.20 | 15.70 | 29.50 | 44.60 | 52.20 | 32.20 | 19.51 | 22.12 | 14.26 | 25.20 | 0.58 | 6.30 |
| Centered | 30.00 | 14.50 | 30.00 | 45.10 | 49.90 | 28.60 | 17.56 | 19.71 | 14.78 | 22.70 | 0.44 | 5.50 |
| LIR (k=1) | 31.40 | 17.40 | 31.20 | 45.40 | 50.60 | 31.90 | 19.02 | 21.85 | 16.70 | 24.50 | 0.87 | 6.20 |
| LSAR | 34.10 | 24.30 | 36.70 | 49.20 | 55.10 | 36.80 | 22.44 | 24.80 | 20.87 | 29.30 | 4.95 | 10.70 |
| nl | pt | ru | sw | ta | te | th | tl | tr | ur | vi | zh |
| Original | 55.00 | 58.40 | 44.20 | 8.97 | 1.63 | 5.56 | 27.74 | 12.40 | 24.90 | 17.80 | 45.70 | 39.70 |
| Centered | 55.60 | 58.10 | 42.50 | 6.92 | 2.28 | 5.13 | 18.43 | 14.60 | 27.70 | 16.40 | 43.70 | 36.00 |
| LIR (k=1) | 57.30 | 58.80 | 43.60 | 9.49 | 2.28 | 5.56 | 23.91 | 15.20 | 28.80 | 17.20 | 45.20 | 40.10 |
| LSAR | 59.70 | 61.90 | 47.60 | 11.79 | 6.84 | 11.54 | 32.66 | 20.10 | 33.50 | 22.90 | 52.00 | 42.90 |
+
+Table 18: Retrieval accuracy (%) on Tatoeba for each language (XLM), using OSCAR as the text resource.
+
+ | af | ar | bg | bn | de | el | es | et | eu | fa | fi | fr |
| Original | 58.20 | 47.50 | 71.60 | 43.00 | 88.80 | 61.80 | 75.70 | 52.20 | 35.80 | 70.50 | 71.60 | 73.70 |
| Centered | 59.30 | 49.60 | 75.00 | 45.30 | 90.90 | 65.80 | 76.60 | 57.10 | 45.80 | 72.10 | 78.40 | 73.00 |
| LIR (k=1) | 59.80 | 50.30 | 75.30 | 46.10 | 90.70 | 66.30 | 77.20 | 57.50 | 47.00 | 72.60 | 78.80 | 73.80 |
| LSAR | 65.20 | 55.00 | 76.50 | 52.60 | 91.60 | 71.30 | 80.90 | 60.90 | 52.00 | 75.90 | 78.90 | 77.50 |
| he | hi | hu | id | it | ja | jv | ka | kk | ko | ml | mr |
| Original | 66.40 | 72.20 | 65.40 | 77.00 | 68.30 | 60.60 | 14.15 | 52.28 | 48.52 | 61.40 | 65.36 | 56.80 |
| Centered | 69.10 | 74.10 | 67.90 | 80.00 | 70.60 | 62.50 | 21.95 | 62.60 | 49.57 | 63.00 | 70.01 | 60.30 |
| LIR (k=1) | 69.50 | 75.00 | 68.20 | 80.40 | 71.50 | 62.60 | 20.98 | 63.00 | 50.78 | 63.50 | 69.87 | 61.20 |
| LSAR | 71.80 | 79.40 | 72.70 | 81.50 | 73.70 | 68.20 | 26.34 | 61.53 | 55.65 | 69.70 | 76.71 | 67.60 |
| nl | pt | ru | sw | ta | te | th | tl | tr | ur | vi | zh |
| Original | 80.80 | 82.20 | 74.10 | 20.26 | 26.38 | 35.90 | 29.38 | 36.70 | 65.70 | 23.40 | 74.70 | 68.30 |
| Centered | 81.80 | 81.50 | 78.20 | 24.10 | 30.62 | 41.45 | 30.29 | 37.30 | 74.00 | 26.90 | 79.70 | 72.60 |
| LIR (k=1) | 82.10 | 82.20 | 78.80 | 25.64 | 31.60 | 41.88 | 31.02 | 37.60 | 74.50 | 27.00 | 80.40 | 73.10 |
| LSAR | 84.10 | 84.30 | 79.00 | 26.92 | 36.16 | 44.02 | 35.04 | 47.00 | 75.50 | 32.90 | 79.90 | 73.80 |
+
+Table 19: Retrieval accuracy (%) on Tatoeba for each language (XLM-R), using OSCAR as the text resource.
+
+ | af | ar | bg | bn | de | el | es | et | eu | fa | fi | fr |
| Original | 97.70 | 90.60 | 95.50 | 91.60 | 99.30 | 96.70 | 98.10 | 98.00 | 95.40 | 96.30 | 97.00 | 96.10 |
| Centered | 97.60 | 90.40 | 95.60 | 91.60 | 99.30 | 96.60 | 98.30 | 98.10 | 95.70 | 96.20 | 97.20 | 96.30 |
| LIR (k=1) | 97.70 | 90.40 | 95.60 | 91.60 | 99.30 | 96.80 | 98.10 | 98.10 | 95.80 | 96.10 | 97.00 | 96.30 |
| LSAR | 97.40 | 90.90 | 95.40 | 91.60 | 99.30 | 96.60 | 98.20 | 97.90 | 95.60 | 95.90 | 97.10 | 96.30 |
| he | hi | hu | id | it | ja | jv | ka | kk | ko | ml | mr |
| Original | 92.40 | 97.90 | 97.00 | 95.60 | 95.30 | 96.40 | 85.37 | 95.71 | 91.13 | 94.10 | 98.98 | 95.00 |
| Centered | 92.10 | 97.90 | 97.10 | 95.80 | 95.20 | 96.70 | 87.80 | 95.58 | 91.30 | 94.20 | 99.13 | 95.00 |
| LIR (k=1) | 92.10 | 97.90 | 97.00 | 95.60 | 95.40 | 96.50 | 87.80 | 95.71 | 91.83 | 94.00 | 99.13 | 95.20 |
| LSAR | 92.40 | 97.80 | 97.10 | 95.80 | 95.40 | 96.50 | 85.85 | 95.71 | 91.65 | 93.90 | 99.13 | 94.80 |
| nl | pt | ru | sw | ta | te | th | tl | tr | ur | vi | zh |
| Original | 97.50 | 95.70 | 95.30 | 89.49 | 90.23 | 98.29 | 97.08 | 98.00 | 98.20 | 96.00 | 97.80 | 96.10 |
| Centered | 97.70 | 95.60 | 95.00 | 89.23 | 90.23 | 98.72 | 97.26 | 97.90 | 98.20 | 95.70 | 97.90 | 96.00 |
| LIR (k=1) | 97.70 | 95.70 | 95.20 | 90.26 | 90.55 | 98.72 | 97.45 | 98.00 | 98.30 | 95.90 | 97.80 | 96.00 |
| LSAR | 97.50 | 96.00 | 95.40 | 90.26 | 90.55 | 98.72 | 96.90 | 97.80 | 98.30 | 96.00 | 97.70 | 96.20 |
+
+Table 20: Retrieval accuracy (%) on Tatoeba for each language (LABSE), using OSCAR as the text resource.
\ No newline at end of file
diff --git a/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/images.zip b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..01471c6b55f33bae13a7c09b4a5c2351c9d69405
--- /dev/null
+++ b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cc0302602b15ec26fe0c9650d68eda3cd1a3090521e03f59d973a30c23a322d2
+size 1696879
diff --git a/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/layout.json b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..65643f42114ab581fdedb3674993ffcd7a61a22d
--- /dev/null
+++ b/discoveringlowranksubspacesforlanguageagnosticmultilingualrepresentations/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6c9e0eb148e15f4f114e63e6919d6e162adf161993f705000d7b1f81db5d98f0
+size 562061
diff --git a/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_content_list.json b/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..9d0ec3b62e46da6fa5267ea128c1948d4a437a01
--- /dev/null
+++ b/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e1098362b716091ee0971db4bf55395ef0953037a5e3c206f2cbe30855f9d669
+size 88336
diff --git a/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_model.json b/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..00356a91b172b03681afc068b84e2e635be940fa
--- /dev/null
+++ b/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4d8348d086ba66e6961384f143e31bd9f245dae0582ee8b9ef65fabd085a310f
+size 106340
diff --git a/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_origin.pdf b/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..8c6b728848b5b233c2282be8d6815d4e548eb2cd
--- /dev/null
+++ b/discretecrossmodalalignmentenableszeroshotspeechtranslation/571259c0-b4de-4cfd-8672-82edf421948e_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:335c2229d14b63fc7029579c8d91579bf66a51fd977e23c46af1de9a7b02b03e
+size 914641
diff --git a/discretecrossmodalalignmentenableszeroshotspeechtranslation/full.md b/discretecrossmodalalignmentenableszeroshotspeechtranslation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..aa40a6614cbe14e4ce6a3d0d16daf4482f6c2184
--- /dev/null
+++ b/discretecrossmodalalignmentenableszeroshotspeechtranslation/full.md
@@ -0,0 +1,330 @@
+# Discrete Cross-Modal Alignment Enables Zero-Shot Speech Translation
+
+Chen Wang $^{1,3*}$ , Yuchen Liu $^{1,3}$ , Boxing Chen $^{2}$ , Jiajun Zhang $^{1,3†}$ , Wei Luo $^{2}$ , Zhongqiang Huang $^{2}$ , Chengqing Zong $^{1,3}$
+
+$^{1}$ National Laboratory of Pattern Recognition, Institute of Automation, CAS, Beijing, China
+
+$^{2}$ Machine Intelligence Technology Lab, Alibaba DAMO Academy
+
+3 School of Artificial Intelligence, University of Chinese Academy of Sciences
+
+{wangchen2020,yuchen.liu}@ia.ac.cn,{jjzhang,cqzong}@nlpr.ia.ac.cn
+
+{Boxing.cbx,muzhuo.lw,z.huang}@alibaba-inc.com
+
+# Abstract
+
+End-to-end Speech Translation (ST) aims at translating the source language speech into target language text without generating the intermediate transcriptions. However, the training of end-to-end methods relies on parallel ST data, which are difficult and expensive to obtain. Fortunately, the supervised data for automatic speech recognition (ASR) and machine translation (MT) are usually more accessible, making zero-shot speech translation a potential direction. Existing zero-shot methods fail to align the two modalities of speech and text into a shared semantic space, resulting in much worse performance compared to the supervised ST methods. In order to enable zero-shot ST, we propose a novel Discrete Cross-Modal Alignment (DCMA) method that employs a shared discrete vocabulary space to accommodate and match both modalities of speech and text. Specifically, we introduce a vector quantization module to discretize the continuous representations of speech and text into a finite set of virtual tokens, and use ASR data to map corresponding speech and text to the same virtual token in a shared codebook. This way, source language speech can be embedded in the same semantic space as the source language text, which can be then transformed into target language text with an MT module. Experiments on multiple language pairs demonstrate that our zero-shot ST method significantly improves the SOTA, and even performs on par with the strong supervised ST baselines1.
+
+# 1 Introduction
+
+End-to-end Speech Translation (ST) aims at designing a single model to directly learn the mapping between source language speech and target language text, and has attracted much attention
+
+
+Figure 1: The key of zero-shot speech translation is to learn an appropriate shared semantic space for source language speech and text.
+
+recently due to its advantages of no error propagation and lower decoding latency (Berard et al., 2016; Liu et al., 2019; Wang et al., 2020c; Xu et al., 2021). However, the training of end-to-end models requires large-scale and high-quality parallel ST data, which are expensive and difficult to obtain. Public datasets such as MUST-C (Gangi et al., 2019a) and CoVoST (Wang et al., 2020a) are quite limited in scale and languages. In contrast, the datasets for automatic speech recognition (ASR) and machine translation (MT) are easier to access in practice. Therefore, zero-shot ST, which learns an end-to-end model using only ASR and MT data, is a direction worth exploring.
+
+As illustrated in Figure 1, the key of zero-shot ST is to learn an appropriate shared semantic space for source language speech and text, after which the model can translate from the common space using an MT module without relying any ST data. There are some attempts to achieve zero-shot ST using multi-task learning that implicitly aligns speech and text (Escolano et al., 2021; Dinh, 2021). Due to the lack of supervised objective functions for cross-modal alignment, the speech and text representations cannot be well aligned in these methods and the results lag behind supervised settings by a significant margin. Inspired by recent research on learning shared semantic space for speech and text (Alinejad and Sarkar, 2020; Liu et al., 2020;
+
+Han et al., 2021), we aim to design a supervised cross-modal alignment task that explicitly maps speech and text into a common feature space.
+
+However, our preliminary study indicates that the existing cross-modal alignment methods that bridge the gap between speech and text in a continuous space do not work well in the zero-shot ST task because in this condition, it is difficult to completely align two modalities to the same distribution in a high-dimensional continuous space. To address this issue, we propose a novel Discrete Cross-Modal Alignment (DCMA) method that employs a shared discrete vocabulary space to accommodate and match both modalities of speech and text. With the shared discrete vocabulary across the two modalities, the source language speech and the corresponding text are mapped to the same virtual token, ensuring representational consistency.
+
+Specifically, the ST model consists of a speech encoder and a text decoder. We introduce a vector quantization module between the speech encoder and the text decoder to discretize the continuous representations into a finite set of virtual tokens. The ASR data are used to provide supervision that maps the speech and its corresponding text into the same virtual token of the shared codebook. In addition to the vector quantization module, the speech encoder is decoupled into an acoustic encoder and a semantic encoder. A shared memory module following the speech encoder is introduced to project variable-length input features of both source language speech and text into fix-sized ones. Machine translation is jointly trained to learn the mapping between the fix-sized features on the source side and the text on the target side. To further enhance the speech encoder, masked language model (MLM) and connectionist temporal classification (CTC) are employed as auxiliary tasks in which all parameters are shared. Experimental results on the benchmark dataset MUST-C demonstrate that our discrete alignment method can significantly improve the performance of zero-shot speech translation.
+
+The contributions of this paper are as follows:
+
+- We propose a novel cross-modal alignment method, DCMA, which aligns speech and text in a shared discrete semantic space.
+- We design a vector quantization module to discretize continuous representations to a finite set of virtual tokens so that cross-modal alignment in discrete space can be well achieved.
+
+- Experimental results demonstrate that our method significantly improves the SOTA in zero-shot ST and performs on par with the supervised models.
+
+# 2 Related Work
+
+Data Scarcity in End-to-End ST Berard et al. (2016); Duong et al. (2016) give the first proof of potential for end-to-end ST models, which have become popular recently (Inaguma et al., 2020; Wang et al., 2020b). However, the performance of the end-to-end methods is heavily dependent on large-scale and high quality parallel data, which are difficult to collect on a large scale (Gangi et al., 2019a; Wang et al., 2020a). Many techniques, such as pretraining (Berard et al., 2018; Bansal et al., 2018, 2019; Wang et al., 2020d; Zheng et al., 2021), multi-task learning (Chuang et al., 2020; Xu et al., 2021; Tang et al., 2021a,b), knowledge distillation (Liu et al., 2019; Gaido et al., 2020; Inaguma et al., 2021), multilingual translation (Inaguma et al., 2019; Gangi et al., 2019b; Le et al., 2021), and data augmentation (Jia et al., 2019; Bahar et al., 2019; Wang et al., 2021) are applied to utilize the data from related tasks. Zero-shot scenario has attracted attention in recent years, but there still remains a significant performance gap between zero-shot and supervised methods (Escolano et al., 2021; Dinh, 2021). One contributing factor is the lack of explicit cross-modal alignments.
+
+Cross-modal Alignment in End-to-End ST Cross-modal alignment aims at aligning representations of speech and text to extract common features. Some recent works have pointed out that the representation gap between speech and text is a major obstacle to speech translation. There are many proposals to bridge the gap, including introducing an alignment task (Alinejad and Sarkar, 2020; Liu et al., 2020; Tang et al., 2021a; Han et al., 2021), mixup strategy (Fang et al., 2022) and multimodal pretraining (Zheng et al., 2021; Bapna et al., 2021; Ao et al., 2021; Babu et al., 2021; Bapna et al., 2022). Additionally, some more sophisticated modules such as adaptive feature selection (Zhang et al., 2020), shrink mechanism (Liu et al., 2020) and shared memory module (Han et al., 2021) have been proposed to address the length inconsistency problem. These methods align the representations of two modalities in continuous feature space. Although these methods work effectively in supervised settings, our preliminary study indicates that
+
+
+Figure 2: Overview of our model DCMA. The speech encoder is decoupled into acoustic encoder and semantic encoder. We adopt a shared memory module to project feature sequence into a fixed length and a vector quantization module to perform cross-modal alignment in discrete space. The text decoder is used to translate from the discrete common space output by vector quantization module. The part above the dashed line illustrates the data flow of the MT task from source language text into target language text. The ASR data is employed to design the cross-modal alignment loss. The data flow of the bottom part can be used to perform the ST task.
+
+the alignments in continuous space do not work well under zero-shot scenario because it is difficult to match two continuous distributions without strong supervision.
+
+# 3 Method
+
+# 3.1 Problem Definition
+
+We attempt to train an end-to-end model with only ASR and MT corpora, achieving zero-shot speech translation. We denote the ASR corpus and the MT corpus as $\mathcal{D}_{ASR} = \{(\mathbf{s},\mathbf{x})\}$ and $\mathcal{D}_{MT} = \{(\mathbf{x}',\mathbf{y})\}$ respectively, where $\mathbf{s}$ is the audio wave sequence, $\mathbf{x}$ is the corresponding transcripts, $\mathbf{x}'$ is the source language text and $\mathbf{y}$ is the corresponding translation in the target language.
+
+# 3.2 Model Architecture
+
+Our DCMA model follows the encoder-decoder framework, as shown in Figure 2. In addition to the conventional speech encoder and text decoder, we also introduce a shared memory module and a shared vector quantization module between the encoder and the decoder.
+
+Speech Encoder The speech encoder consists of an acoustic encoder and a semantic encoder to encourage information sharing between tasks (Wang et al., 2020c; Tang et al., 2021a; Xu et al., 2021).
+
+For speech input, we use the pretrained wav2vec2.0 (Baevski et al., 2020b) as the acoustic encoder to extract speech representations from the original waveform, which has been shown effective in supervised ST (Ye et al., 2021; Fang et al., 2022). Since the speech feature sequence can be very long, we add two additional one-dimensional convolution layers with stride 2 to shrink the length by a factor of 4. The speech representations are then fed into the shared semantic encoder to obtain the semantic representations. For text input, only the shared semantic encoder is employed. The semantic encoder follows Transformer (Vaswani et al., 2017), and its output is denoted as $\mathbf{H} \in \mathbb{R}^{l \times d}$ .
+
+In order to enhance the semantic encoder so that it can embed both acoustic and textual features, we apply the Connectionist Temporal Classification (CTC) (Graves et al., 2006) on the contextual features of speech and the Masked Language Model (MLM) (Devlin et al., 2019) on the contextual features of text. The softmax vocabulary and paramters are shared across the two tasks to encourage implicit alignment between the speech and text representations learnt by the semantic encoder (Bapna et al., 2022). Specifically, the text in source language from $\mathcal{D}_{MT}$ follows the same mask policy as BERT (Devlin et al., 2019), and the model is required to predict the correct masked tokens.
+
+
+Figure 3: The detailed calculation process of the vector quantization module in one group. This process is performed $G$ times in parallel, and the selected code vectors from $G$ groups are concatenated to get the final output.
+
+The CTC loss is applied on the speech input from $\mathcal{D}_{ASR}$ , using token-level transcription as the target.
+
+Shared Memory Module Since the semantic encoder outputs representations in different lengths for speech and text, making it difficult to perform cross-modal alignment, we introduce a shared memory module (Han et al., 2021) to project the contextual features from two modalities with different lengths into fix-sized $M$ . In calculating the attention, this module keeps $M$ learnable, modality-independent memory queries, while the contextual features are used as keys and values as shown below:
+
+$$
+\mathbf {Q} = \mathbf {M} \in \mathbb {R} ^ {M \times d} \tag {1}
+$$
+
+$$
+\mathbf {K} = \mathbf {V} = \mathbf {H} \in \mathbb {R} ^ {l \times d} \tag {2}
+$$
+
+$$
+\mathbf {O} = \operatorname {M u l t i H e a d} (\mathbf {Q}, \mathbf {K}, \mathbf {V}) \in \mathbb {R} ^ {M \times d} \tag {3}
+$$
+
+where $\mathbf{M}$ denotes the trainable memory queries and $\mathbf{H}$ denotes the output contextual features of the semantic encoder. $\mathbf{O} = [o_1,\dots,o_M]$ are the output of the memory module, in which $o_m$ is the semantic representation extracted by the $m$ -th memory query.
+
+Vector Quantization Module This is the core module of our DCMA model. Inspired by vqvav2vec (Baevski et al., 2020a), we discretize the semantic memory $o_m$ to a finite set of virtual tokens via a quantizer, so that we can perform cross-modal alignment in discrete space. A codebook is a vocabulary that contains $V$ virtual tokens, each of which is represented by a vector $e \in \mathbb{R}^{d'}$ like word embedding. The vector quantization module aims to select one entry from the codebook as the output.
+
+As illustrated in Figure 3, given a semantic memory $o_{m}$ , we first apply a linear layer, followed by
+
+GELU and another linear layer to map it into logits $l_{m}\in \mathbb{R}^{V}$ , which is the score of each virtual token. Second, we adopt Gumbel softmax (Maddison et al., 2014; Jang et al., 2017) to choose the discrete entries in a differentiable way. The probabilities for selecting the $j$ -th entry are
+
+$$
+p _ {m, j} = \frac {\exp \left(l _ {m , j} + n _ {j}\right) / \tau}{\sum_ {k = 1} ^ {V} \exp \left(l _ {m , k} + n _ {k}\right) / \tau} \tag {4}
+$$
+
+where $n = -\log (-\log (u))$ and $u$ are sampled from the uniform distribution $\mathcal{U}(0,1)$ . The $j$ -th entry is chosen by $j = \operatorname{argmax}_j p_{m,j}$ during the forward pass, denoted as $\hat{o}_m = e_j$ . The quantization module updates the original semantic memory $o_m$ with $\hat{o}_m$ , and performs the same operation for all semantic memories to obtain the output code vectors $\hat{\mathbf{O}} \in \mathbb{R}^{M \times d}$ . During the backward pass, the gradient of selecting one entry is estimated by the gradient of the true Gumbel softmax output.
+
+Since a codebook contains a limited discrete space of size $V$ , we increase the representation capability of the discrete space by increasing the number of codebooks. Suppose there are $G$ groups with $V$ entries, this module selects one entry from each group and concatenate them to obtain $\hat{o}_m \in \mathbb{R}^{G \times d'}$ , where we set $d' = d / G$ . The grouping operation can theoretically yield $V^G$ different outputs, which means we can increase the size of the discrete space exponentially. The codebooks are shared across semantic memories extracted by different memory queries, and are also shared across two modalities.
+
+Let $(\mathbf{s},\mathbf{x})$ be an ASR training sample, the quantization module is expected to select the same codebook entries for the speech and the corresponding text, so that the representations of both modalities are aligned in the discrete space. First, the softmax function is applied to convert the logits of $i$ -th group $l_{m,i}\in \mathbb{R}^{V}$ into distribution across codebooks.
+
+$$
+\hat {p} _ {m, i, j} ^ {\text {m o d a l}} = \frac {\exp \left(l _ {m , i , j} ^ {\text {m o d a l}}\right)}{\sum_ {k = 1} ^ {V} \exp \left(l _ {m , i , k} ^ {\text {m o d a l}}\right)}, \text {m o d a l} \in \{\mathbf {s}, \mathbf {x} \} \tag {5}
+$$
+
+Then we treat the distribution of text as target and encourage the module to make the same choices for the corresponding speech.
+
+$$
+\mathcal {L} _ {\text {a l i g n}} (\mathbf {s}, \mathbf {x}) = \frac {1}{G} \sum_ {m = 1} ^ {M} \sum_ {i = 1} ^ {G} \sum_ {j = 1} ^ {V} - s g \left(\hat {p} _ {m, i, j} ^ {\mathbf {x}}\right) \log \hat {p} _ {m, i, j} ^ {\mathbf {s}} \tag {6}
+$$
+
+where $M, G, V$ are the number of memory queries, codebook groups and entries respectively, and $sg(\cdot)$ means the stop gradient operation.
+
+Text Decoder The text decoder also follows the basic network structure of the Transformer, which takes the fixed-length code vectors $\hat{\mathbf{O}}$ as input, and generates the target translation conditioned on the discrete representations. The code vectors from the text are used in training while those from the speech are used in inference.
+
+The decoder module is trained using parallel text data. Let $(\mathbf{x}',\mathbf{y})$ be an MT training example, the objective function of the MT task can be calculated by cross-entropy loss as in:
+
+$$
+\mathcal {L} _ {M T} (\mathbf {x} ^ {\prime}, \mathbf {y}) = - \sum_ {i = 1} ^ {| \mathbf {y} |} \log p \left(\mathbf {y} _ {i} \mid \mathbf {y} _ {< i}, \mathbf {x} ^ {\prime}\right) \tag {7}
+$$
+
+# 3.3 Training Process
+
+We train our model in the pretrain-finetune manner. We first train the semantic encoder, shared memory module, shared vector quantization module and the text decoder with the MT task and the MLM task. It helps to make the training more stable and enriches the codebook entries with semantic information. In the finetune stage, we optimize the entire model with all the relevant tasks as shown below:
+
+$$
+\mathcal {L} = \mathbb {E} _ {(\mathbf {s}, \mathbf {x}) \in \mathcal {D} _ {A S R}} [ \mathcal {L} _ {a l i g n} (\mathbf {s}, \mathbf {x}) + \alpha \mathcal {L} _ {C T C} (\mathbf {s}, \mathbf {x}) ]
+$$
+
+(8)
+
+$$
++ \mathbb {E} _ {(\mathbf {x} ^ {\prime}, \mathbf {y}) \in \mathcal {D} _ {M T}} [ \mathcal {L} _ {M T} (\mathbf {x} ^ {\prime}, \mathbf {y}) + \beta \mathcal {L} _ {M L M} (\mathbf {x} ^ {\prime}) ]
+$$
+
+We optimize $\mathcal{L}_{\text {align }}$ and $\mathcal{L}_{\text {CTC }}$ in the ASR batches, and alternately optimize the $\mathcal{L}_{\text {MT }}$ and $\mathcal{L}_{\text {MLM }}$ in the MT batches. Note that no end-to-end ST data are involved in the training process.
+
+# 4 Experiments
+
+# 4.1 Datasets
+
+ASR Datasets MUST-C (Gangi et al., 2019a) is one of the largest multilingual speech translation datasets. MUST-C contains the English (En) speech, the corresponding transcription, and the target translation in 8 different languages, including German (De), French (Fr), Russian (Ru), Spanish (Es), Romanian (Ro), Italian (It), Portuguese (Pt), and Dutch (NI). During training, we use only the speech and its transcription as ASR dataset. During inference, we use the dev set for validation and the tst-COMMON set for test.
+
+| En→ | ASR | MT |
| hours | #sentences | name | #sentences |
| De | 408 | 234K | WMT14 | 4.5M |
| Fr | 492 | 280K | WMT14 | 5.4M* |
| Ru | 489 | 270K | WMT14 | 1.0M |
| Es | 504 | 270K | WMT14 | 3.8M |
| Ro | 432 | 240K | WMT16 | 0.6M |
| It | 465 | 211K | OPUS100 | 1.0M |
| Pt | 385 | 211K | OPUS100 | 1.0M |
| Nl | 442 | 253K | OPUS100 | 1.0M |
+
+* We only use europarl v7, commoncrawl and news commentary subsets of WMT14 En-Fr.
+
+Table 1: The detailed statistics of all datasets.
+
+MT Datasets We use MT datasets in various domains different from the ASR dataset. Specifically, we use WMT $2014^{2}$ for En-De, En-Fr, En-Ru and En-Es, WMT $2016^{3}$ for En-Ro, and OPUS100 $^{4}$ for En-It, En-Pt and En-NI. The transcription and its translation in MUST-C can serve as in-domain MT data to further investigate the performance of zero-shot $\mathrm{ST}^{5}$ . The detailed statistics are shown in Table 1.
+
+# 4.2 Experimental Settings
+
+Pre-processing For speech input, we use the 16 kHZ raw audio waves and normalize the wave sequences by a factor of $2^{15}$ to the range of $[-1, 1]$ . In order to utilize the GPU more efficiently, we filter out speech-transcription pairs whose audio frames exceed 1M.
+
+For the text input, capitalization and punctuation are preserved. We filter out MT samples whose number of source or target tokens is over 250 and whose length ratio is outside the $[2/3, 3/2]$ interval. For each language pair, we use a unigram sentencepiece $^6$ model to learn a 10K vocabulary from the text portion of MUST-C, and apply it to segment other text data into subword units. The vocabulary is shared across both source and target languages.
+
+Model Configuration We use wav2vec2.0 (Baevski et al., 2020b) as the acoustic encoder, which follows the base configurations and is pretrained on the unlabeled audio data from Lib
+
+| Methods | Training Data | BLEU |
| Speech | ASR | MT | ST | En-De | En-Fr | En-Ru | En-Es | En-Ro | En-It | En-Pt | En-Nl |
| Previous state-of-the-art for zero-shot ST |
| MultiSLT (Escolano et al., 2021) | × | ✓ | ✓ | × | 6.8 | 10.9 | - | 6.8 | - | - | - | - |
| Previous cross-modal alignment methods |
| Chimera* (Han et al., 2021) | ✓ | ✓ | ✓ | × | 13.5 | 22.2 | 8.3 | 15.3 | 8.5 | 12.6 | 16.9 | 13.1 |
| Supervised baselines on MUST-C |
| Fairseq ST (Wang et al., 2020b) | × | ✓ | × | ✓ | 22.7 | 32.9 | 15.3 | 27.2 | 21.9 | 22.7 | 28.1 | 27.3 |
| Espnet ST (Inaguma et al., 2020) | × | ✓ | ✓ | ✓ | 22.9 | 32.8 | 15.8 | 28.0 | 21.9 | 23.8 | 28.0 | 27.4 |
| W2V2-Transformer** | ✓ | × | ✓ | ✓ | 24.1 | 35.0 | 16.3 | 29.4 | 23.1 | 24.8 | 30.0 | 28.9 |
| This work |
| DCMA | ✓ | ✓ | ✓ | × | 22.4 | 29.7 | 11.8 | 24.6 | 16.8 | 18.4 | 24.2 | 22.0 |
| + in-domain MT data | ✓ | ✓ | ✓ | × | 24.0 | 33.1 | 16.0 | 26.2 | 22.2 | 24.1 | 29.2 | 28.3 |
+
+Table 2: BLEU scores on the tst-COMMON set in 8 language pairs in MUST-C. "Speech" means speech self-supervised pretraining using unlabeled audio data. ASR data is leveraged for speech recognition task or for cross-modal alignment. * is reproduced under zero-shot scenario, which is a strong baseline of performing cross-modal alignment in continuous space. ** from Fang et al. (2022) is a baseline model by combining wav2vec 2.0 (Baevski et al., 2020b) and a Transformer.
+
+riSpeech (Panayotov et al., 2015). Two additional 1-dimensional convolution layers are used to shrink the length of the speech features, with stride size 2, kernel size 5, padding 2, and hidden dimension 1024.
+
+For the semantic encoder, we use a 6-layer Transformer encoder. The memory queries are 64 512-dimensional vectors. The vector quantization module consists of $G = 128$ groups of codebook with $V = 50$ entries in each group, which can produce $50^{128}$ possible codewords. A linear layer, followed by GELU and another linear layer are used to project the semantic memory into $G \cdot V = 6400$ logits with 1024 hidden units. The Gumbel softmax produces a one-hot vector for each group. The temperature $\tau$ decays exponentially from 2 to 0.5 with a factor of 0.999995 and then keeps constant at 0.5. The text decoder consists of 6 transformer layers. Each of the layers in the semantic encoder and text decoder module has 512-dimensional hidden sizes, 8 attention heads, and 2048 feed-forward hidden units. A 512-dimensional word embedding layer is shared across the semantic encoder and the text decoder.
+
+Training Details We train our model following the pretrain-finetune strategy. During pretraining, we train the model with the MT and MLM tasks. The learning rate is 7e-4 with 4K warm-up updates. We pretrain the model up to 150K updates, with at most 1152 sentence pairs per batch. In the stage of zero-shot finetune, we adopt multitask training as described in Section 3.3. We set
+
+both $\alpha$ and $\beta$ in Equation (8) to 1.0. The learning rate is set to 1e-4 with 10K warm-up updates. We finetune the model up to 150K updates, with at most 16M audio frames per batch. In both the pretrain and the finetune stages, the model is trained by Adam optimizer (Kingma and Ba, 2015) with $\beta_{1} = 0.9$ , $\beta_{2} = 0.98$ . An inverse square root schedule algorithm is adopted for the learning rate. Both the dropout and label smoothing rate are set to 0.1 for regularization. The whole training process is carried out on two Nvidia Tesla-V100 GPUs.
+
+During inference, we average the model parameters of the last 5 checkpoints. We use beam search with a beam size of 5. The performance is evaluated with case-sensitive BLEU (Papineni et al., 2002) calculated by SacreBLEU $^7$ (Post, 2018).
+
+# 5 Results and Analysis
+
+# 5.1 Main Results
+
+Comparison with zero-shot methods We compare our DCMA method with MultiSLT (Escolano et al., 2021), which is the previous SOTA for zero-shot speech translation. As shown in Table 2, our method achieves remarkable improvements. We also notice that introducing in-domain MT data can further improve the performance and is more useful when the MT data size is small (Ru, Ro, It, Pt and Nl). To demonstrate the advantages of discrete alignment, we implement the Chimera (Han et al., 2021), a continuous alignment method, to
+
+perform zero-shot ST, which has a similar model architecture as our DCMA and is trained under the same conditions. The difference is that it does not have the vector quantization module and instead aligns the representations of speech and text with the continuous contrastive loss. Our method significantly outperforms Chimera on all language pairs, demonstrating the potential of discrete space for cross-modal alignment in zero-shot $\mathrm{ST}^9$ .
+
+Comparison with supervised methods We compare our zero-shot DCMA method with the supervised baselines Fairseq ST (Wang et al., 2020b), Espnet ST (Inaguma et al., 2020), and W2V2-Transformer, which also adopt the pretrain-finetune procedure but are finetuned on the parallel ST data. W2V2-Transformer utilizes a speech self-supervised learning model, combining the pretrained wav2vec 2.0, a 6-layers transforemr encoder and a 6-layers transforemr decoder. As shown in Table 2, our DCMA method achieves competitive performance compared to the supervised baselines when in-domain MT data are used. This demonstrates that the zero-shot DCMA method can learn an effective end-to-end ST model without using end-to-end ST data, as well as the possibility of projecting speech and text into a shared space. Although our zero-shot method uses more MT data than the supervised baselines, our method does not use any end-to-end ST data, making it widely useful in low-resource scenarios.
+
+Comparison with cascaded system and data synthesis method We compare our zero-shot DCMA method with those that also do not use parallel ST data, namely the cascade system and data synthetic method (Jia et al., 2019). For the cascade ST system, the ASR part is the W2V2-Transformer, and the MT part follows the basic Transformer configuration. The cascaded system first translates the speech into source language text, and then translates the transcription into the target translation. For generating synthetic data, we first leverage the MT model in cascaded system to translate the transcriptions in ASR dataset into the target translation. The ST model W2V2-Transformer is initialized with the MT model and finetuned with the synthetic data. As shown in Table 3, our DCMA method achieves comparable performance to those of other methods. However, cascaded system faces
+
+| Methods | WER(↓) | MT BLEU | ST BLEU |
| Cascaded ST | 11.1 | 28.6 | 23.5 |
| + in-domain MT data | 11.1 | 32.4 | 26.7 |
| Synthetic Data | - | 28.6 | 23.3 |
| DCMA | - | - | 22.4 |
| + in-domain MT data | - | - | 24.0 |
+
+Table 3: Comparison with zero-resource methods on MUST-C En-De corpus. We report the Word Error Rate (WER) of speech-transcription pairs for ASR models, the MT BLEU scores of transcription-translation pairs for MT models, and the ST BLEU scores of speech-translation pairs for ST models.
+
+| Parameter Sharing | Discrete Alignment | BLEU |
| ✓ | ✓ | 22.4 |
| ✓ | × | 1.3 |
| × | ✓ | 21.8 |
| × | × | 0.1 |
+
+Table 4: Ablation studies on the MUST-C En-De corpus. "Parameter sharing" means sharing the softmax vocabulary and parameters across MLM and CTC.
+
+the problem of high decoding latency, and generating synthetic data is a time-consuming process. In Section 5.5, we show that our method can outperform the cascade system on well-aligned subsets.
+
+# 5.2 Ablation Studies
+
+We share the softmax vocabulary and parameters across the two training objectives, $\mathcal{L}_{MLM}$ and $\mathcal{L}_{CTC}$ , to encourage implicit alignment between the speech and text representations learnt by the semantic encoder. To better evaluate the contribution of the sharing strategy and our proposed discrete alignment model, we conduct ablation studies on the MUST-C En-De corpus. As shown in Table 4, implicit alignment between speech and text through the sharing strategy is beneficial to improve the performance. However, the proposed discrete alignment method is the most important and indispensable (performance degradation from 22.4 to 1.3 without it).
+
+# 5.3 Effect of the Size of Codebooks
+
+The shared vector quantization module discretizes the continuous vectors to a finite set of virtual tokens, so we can perform cross-modal alignment in the shared discrete space. An important question arises that how big codebooks are needed so that the vectors can be discretized without losing representation ability. Given $G$ groups of codebook with $V$ entries, the number of theoretically possible outputs is $V^{G}$ , so that we can exponentially increase
+
+| Methods | V | G | MT BLEU | ST BLEU |
| Transformer | - | - | 28.6 | - |
| DCMA | 50 | 2 | 4.5 | - |
| DCMA | 50 | 4 | 19.6 | - |
| DCMA | 50 | 8 | 25.0 | - |
| DCMA | 50 | 16 | 25.7 | - |
| DCMA | 50 | 32 | 26.7 | 18.5 |
| DCMA | 50 | 64 | 27.4 | 21.5 |
| DCMA | 50 | 128 | 28.0 | 22.4 |
| DCMA | 50 | 256 | 27.8 | 19.8 |
+
+Table 5: MT BLEU scores and ST BLEU scores on the tst-COMMON set of MUST-C En-De corpus with different size of codebooks. The number of theoretically possible outputs is $V^{G}$ .
+
+
+Figure 4: Curve of BLEU scores against the size of ASR data size on MUST-C En-De corpus.
+
+the size of codebooks by increasing $G$ . We vary the setting of $G$ and report the MT BLEU scores of transcription-translation pairs and the zero-shot ST BLEU scores of speech-translation pairs. We observe that when the discrete space is small (e.g. row 2), the quantization operation loses a great deal of representational power, but when the discrete space becomes larger the MT performance gets better and better. However, continuing to increase the size of codebooks (e.g. when G is 256) does not improve the performance. Our proposed DCMA method achieves the best performance when the number of groups is set to $G = 128$ .
+
+# 5.4 Effect of the Size of ASR Data
+
+The key part of our method is to use ASR data to learn a discrete shared semantic space. Therefore, the ASR data size is an important factor. We randomly sample different amount of ASR data from the MUST-C En-De corpus. As shown in Figure 4, we observe a continuous improvement of BLEU scores with the increase of ASR data size.
+
+
+Figure 5: The tst-COMMON set of MUST-C En-De corpus is divided into 5 subsets according to sentence-level alignment accuracy. The histogram represents the size of each subset. Red circles are the ST BLEU scores of DCMA, green squares are the ST BLEU scores of cascaded system, and orange triangles are the transcriptiontranslation BLEU scores of MT model. Our method is comparable to cascaded system and text translation on the well-aligned subsets.
+
+# 5.5 Can Our Method Achieve Cross-modal Alignment?
+
+To evaluate whether our model can project the speech and text with the same semantic to the same virtual tokens, we conduct some analyses of the alignment accuracy. Let $(\mathbf{s},\mathbf{x},\mathbf{y})$ be an ST test sample. The speech input s can be discretized into $\mathbf{Z}^{\mathrm{s}} = [\mathbf{z}_1^{\mathrm{s}},\dots ,\mathbf{z}_{\mathrm{M}}^{\mathrm{s}}]$ , where $\mathbf{z_i^s} = [z_{i1}^s,\ldots ,z_{iG}^s ]$ is the code vector ids selected when discretizing the features extracted by the $i$ -th memory query and $z_{ij}^{\mathrm{s}}$ is the code vector id selected in the $j$ -th group. The $M$ and $G$ are the number of memory queries and the number of codebook groups respectively. We do the same operation for text input x to obtain $\mathbf{Z}^{\mathrm{x}}$ , and define the sentence-level accuracy sent_acc = $\frac{\sum_{i=1}^{M}\sum_{j=1}^{G}\mathbf{1}\{z_{ij}^{\mathrm{s}} = z_{ij}^{\mathrm{x}}\}}{M \cdot G}$ . The test set is divided into 5 subsets according to the sentence-level alignment accuracy, and we calculate the MT BLEU scores and ST BLEU scores for each subset. As shown in Figure 5, most of speech utterances are discretized with over $40\%$ alignment accuracy, which indicates the ability of our model to align speech and text into shared discrete codebooks. We also observe a continuous improvement of ST BLEU scores with the increase of sentence-level alignment accuracy. The performance of the zero-shot ST is comparable to that of text translation or better than that of the cascade system on the well-aligned subsets. It indicates the big potential of our method that the zero-shot ST will achieve much better performance if we can design better cross-modal alignment method.
+
+# 6 Conclusion
+
+In this paper, we propose a novel alignment method DCMA to enable zero-shot ST. The key part of our approach is to discretize the continuous vectors to a finite set of virtual tokens and use ASR data to map the corresponding speech and text to the same virtual token in the shared codebook. Our experiments demonstrate that our method can learn an effective end-to-end ST model without any parallel ST data. It significantly improves the existing SOTA and achieves competitive performance compared to the supervised models.
+
+# 7 Limitations
+
+In this paper, we propose a zero-shot ST method, which eliminates reliance on end-to-end ST data, allowing end-to-end models to be trained on the same data conditions as cascade systems. The performance of the cascade systems can benefit from both the pretrained speech models (such as wav2vec 2.0) and the pretrained text models (such as BART and T5). However, since our method introduces additional modules between the encoder and the decoder, the pretrained text model cannot be directly integrated into the architecture. Experiments show that our method can outperform the cascade system and obtain comparable results to those of text translation on the well-aligned subsets. However, on the examples with low alignment accuracy, our method is not as robust as the cascade system. How to improve projections onto discrete units is an issue that our future work will explore.
+
+# Acknowledgements
+
+This work is supported by the Natural Science Foundation of China under Grant 62122088 and U1836221.
+
+# References
+
+Ashkan Alinejad and Anoop Sarkar. 2020. Effectively pretraining a speech translation decoder with machine translation data. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 8014-8020. Association for Computational Linguistics.
+Junyi Ao, Rui Wang, Long Zhou, Shujie Liu, Shuo Ren, Yu Wu, Tom Ko, Qing Li, Yu Zhang, Zhihua Wei, Yao Qian, Jinyu Li, and Furu Wei. 2021. Speecht5: Unified-modal encoder-decoder pre-training for spoken language processing. CoRR, abs/2110.07205.
+
+Arun Babu, Changhan Wang, Andros Tjandra, Kushal Lakhotia, Qiantong Xu, Naman Goyal, Kritika Singh, Patrick von Platen, Yatharth Saraf, Juan Pino, Alexei Baevski, Alexis Conneau, and Michael Auli. 2021. XLS-R: self-supervised cross-lingual speech representation learning at scale. CoRR, abs/2111.09296.
+Alexei Baevski, Steffen Schneider, and Michael Auli. 2020a. vq-wav2vec: Self-supervised learning of discrete speech representations. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Alexei Baevski, Yuhao Zhou, Abdelrahman Mohamed, and Michael Auli. 2020b. wav2vec 2.0: A framework for self-supervised learning of speech representations. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Parnia Bahar, Albert Zeyer, Ralf Schlüter, and Hermann Ney. 2019. On using specaugment for end-to-end speech translation. In Proceedings of the 16th International Conference on Spoken Language Translation, IWSLT 2019, Hong Kong, November 2-3, 2019. Association for Computational Linguistics.
+Sameer Bansal, Herman Kamper, Karen Livescu, Adam Lopez, and Sharon Goldwater. 2018. Low-resource speech-to-text translation. In *Interspeech* 2018, 19th Annual Conference of the International Speech Communication Association, Hyderabad, India, 2-6 September 2018, pages 1298-1302. ISCA.
+Sameer Bansal, Herman Kamper, Karen Livescu, Adam Lopez, and Sharon Goldwater. 2019. Pre-training on high-resource speech recognition improves low-resource speech-to-text translation. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 58-68. Association for Computational Linguistics.
+Ankur Bapna, Colin Cherry, Yu Zhang, Ye Jia, Melvin Johnson, Yong Cheng, Simran Khanuja, Jason Riesa, and Alexis Conneau. 2022. mslam: Massively multilingual joint pre-training for speech and text. CoRR, abs/2202.01374.
+Ankur Bapna, Yu-An Chung, Nan Wu, Anmol Gulati, Ye Jia, Jonathan H. Clark, Melvin Johnson, Jason Riesa, Alexis Conneau, and Yu Zhang. 2021. SLAM: A unified encoder for speech and language modeling via speech-text joint pre-training. CoRR, abs/2110.10329.
+Alexandre Berard, Laurent Besacier, Ali Can Kocabiyikoglu, and Olivier Pietquin. 2018. End-to-end automatic speech translation of audiobooks. In 2018 IEEE International Conference on Acoustics, Speech and Signal Processing, ICASSP 2018, Calgary, AB, Canada, April 15-20, 2018, pages 6224-6228. IEEE.
+
+Alexandre Berard, Olivier Pietquin, Christophe Servan, and Laurent Besacier. 2016. Listen and translate: A proof of concept for end-to-end speech-to-text translation. CoRR, abs/1612.01744.
+Shun-Po Chuang, Tzu-Wei Sung, Alexander H. Liu, and Hung-yi Lee. 2020. Worse wer, but better bleu? leveraging word embedding as intermediate in multi-task end-to-end speech translation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 5998-6003. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics.
+Tu Anh Dinh. 2021. Zero-shot speech translation. CoRR, abs/2107.06010.
+Long Duong, Antonios Anastasopoulos, David Chiang, Steven Bird, and Trevor Cohn. 2016. An attentional model for speech translation without transcription. In *NAACL HLT* 2016, The 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, San Diego California, USA, June 12-17, 2016, pages 949-959. The Association for Computational Linguistics.
+Carlos Escolano, Marta R. Costa-jussà, José A. R. Fonollosa, and Carlos Segura. 2021. Enabling zero-shot multilingual spoken language translation with language-specific encoders and decoders. In IEEE Automatic Speech Recognition and Understanding Workshop, ASRU 2021, Cartagena, Colombia, December 13-17, 2021, pages 694-701. IEEE.
+Qingkai Fang, Rong Ye, Lei Li, Yang Feng, and Mingxuan Wang. 2022. STEMM: self-learning with speech-text manifold mixup for speech translation. CoRR, abs/2203.10426.
+Marco Gaido, Mattia Antonino Di Gangi, Matteo Negri, and Marco Turchi. 2020. On knowledge distillation for direct speech translation. In Proceedings of the Seventh Italian Conference on Computational Linguistics, CLiC-it 2020, Bologna, Italy, March 1-3, 2021, volume 2769 of CEUR Workshop Proceedings. CEUR-WS.org.
+Mattia Antonino Di Gangi, Roldano Cattoni, Luisa Bentivogli, Matteo Negri, and Marco Turchi. 2019a. Must-c: a multilingual speech translation corpus. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies,
+
+NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 2012-2017. Association for Computational Linguistics.
+Mattia Antonino Di Gangi, Matteo Negri, and Marco Turchi. 2019b. One-to-many multilingual end-to-end speech translation. In IEEE Automatic Speech Recognition and Understanding Workshop, ASRU 2019, Singapore, December 14-18, 2019, pages 585-592. IEEE.
+Alex Graves, Santiago Fernández, Faustino J. Gomez, and Jürgen Schmidhuber. 2006. Connectionist temporal classification: labelling unsegmented sequence data with recurrent neural networks. In Machine Learning, Proceedings of the Twenty-Third International Conference (ICML 2006), Pittsburgh, Pennsylvania, USA, June 25-29, 2006, volume 148 of ACM International Conference Proceeding Series, pages 369-376. ACM.
+Chi Han, Mingxuan Wang, Heng Ji, and Lei Li. 2021. Learning shared semantic space for speech-to-text translation. In Findings of the Association for Computational Linguistics: ACL/IJCNLP 2021, Online Event, August 1-6, 2021, volume ACL/IJCNLP 2021 of Findings of ACL, pages 2214-2225. Association for Computational Linguistics.
+Hirofumi Inaguma, Kevin Duh, Tatsuya Kawahara, and Shinji Watanabe. 2019. Multilingual end-to-end speech translation. In IEEE Automatic Speech Recognition and Understanding Workshop, ASRU 2019, Singapore, December 14-18, 2019, pages 570-577. IEEE.
+Hirofumi Inaguma, Tatsuya Kawahara, and Shinji Watanabe. 2021. Source and target bidirectional knowledge distillation for end-to-end speech translation. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2021, Online, June 6-11, 2021, pages 1872-1881. Association for Computational Linguistics.
+Hirofumi Inaguma, Shun Kiyono, Kevin Duh, Shigeki Karita, Nelson Yalta, Tomoki Hayashi, and Shinji Watanabe. 2020. Espnet-st: All-in-one speech translation toolkit. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics: System Demonstrations, ACL 2020, Online, July 5-10, 2020, pages 302-311. Association for Computational Linguistics.
+Eric Jang, Shixiang Gu, and Ben Poole. 2017. Categorical reparameterization with gumbel-softmax. In 5th International Conference on Learning Representations, ICLR 2017, Toulouse, France, April 24-26, 2017, Conference Track Proceedings. OpenReview.net.
+Ye Jia, Melvin Johnson, Wolfgang Macherey, Ron J. Weiss, Yuan Cao, Chung-Cheng Chiu, Naveen Ari, Stella Laurenzo, and Yonghui Wu. 2019. Leveraging weakly supervised data to improve end-to-end
+
+speech-to-text translation. In IEEE International Conference on Acoustics, Speech and Signal Processing, ICASSP 2019, Brighton, United Kingdom, May 12-17, 2019, pages 7180-7184. IEEE.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
+Hang Le, Juan Miguel Pino, Changhan Wang, Jiatao Gu, Didier Schwab, and Laurent Besacier. 2021. Lightweight adapter tuning for multilingual speech translation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 2: Short Papers), Virtual Event, August 1-6, 2021, pages 817-824. Association for Computational Linguistics.
+Yuchen Liu, Hao Xiong, Jiajun Zhang, Zhongjun He, Hua Wu, Haifeng Wang, and Chengqing Zong. 2019. End-to-end speech translation with knowledge distillation. In *Interspeech* 2019, 20th Annual Conference of the International Speech Communication Association, Graz, Austria, 15-19 September 2019, pages 1128-1132. ISCA.
+Yuchen Liu, Junnan Zhu, Jiajun Zhang, and Chengqing Zong. 2020. Bridging the modality gap for speech-to-text translation. CoRR, abs/2010.14920.
+Chris J. Maddison, Daniel Tarlow, and Tom Minka. 2014. A* sampling. In Advances in Neural Information Processing Systems 27: Annual Conference on Neural Information Processing Systems 2014, December 8-13 2014, Montreal, Quebec, Canada, pages 3086-3094.
+Vassil Panayotov, Guoguo Chen, Daniel Povey, and Sanjeev Khudanpur. 2015. Librispeech: An ASR corpus based on public domain audio books. In 2015 IEEE International Conference on Acoustics, Speech and Signal Processing, ICASSP 2015, South Brisbane, Queensland, Australia, April 19-24, 2015, pages 5206-5210. IEEE.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th Annual Meeting of the Association for Computational Linguistics, July 6-12, 2002, Philadelphia, PA, USA, pages 311-318. ACL.
+Matt Post. 2018. A call for clarity in reporting BLEU scores. In Proceedings of the Third Conference on Machine Translation: Research Papers, WMT 2018, Belgium, Brussels, October 31 - November 1, 2018, pages 186-191. Association for Computational Linguistics.
+Yun Tang, Juan Miguel Pino, Xian Li, Changhan Wang, and Dmitriy Genzel. 2021a. Improving speech translation by understanding and learning from the auxiliary text translation task. In Proceedings of the 59th
+
+Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 1: Long Papers), Virtual Event, August 1-6, 2021, pages 4252-4261. Association for Computational Linguistics.
+Yun Tang, Juan Miguel Pino, Changhan Wang, Xutai Ma, and Dmitriy Genzel. 2021b. A general multi-task learning framework to leverage text data for speech to text tasks. In IEEE International Conference on Acoustics, Speech and Signal Processing, ICASSP 2021, Toronto, ON, Canada, June 6-11, 2021, pages 6209-6213. IEEE.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pages 5998-6008.
+Changhan Wang, Juan Miguel Pino, Anne Wu, and Jiatao Gu. 2020a. Covost: A diverse multilingual speech-to-text translation corpus. In Proceedings of The 12th Language Resources and Evaluation Conference, LREC 2020, Marseille, France, May 11-16, 2020, pages 4197-4203. European Language Resources Association.
+Changhan Wang, Yun Tang, Xutai Ma, Anne Wu, Dmytro Okhonko, and Juan Miguel Pino. 2020b. Fairseq S2T: fast speech-to-text modeling with fairseq. In Proceedings of the 1st Conference of the Asia-Pacific Chapter of the Association for Computational Linguistics and the 10th International Joint Conference on Natural Language Processing: System Demonstrations, AACL/IJCNLP 2020, Suzhou, China, December 4-7, 2020, pages 33-39. Association for Computational Linguistics.
+Changhan Wang, Anne Wu, Juan Pino, Alexei Baevski, Michael Auli, and Alexis Conneau. 2021. Large-scale self- and semi-supervised learning for speech translation. In *Interspeech* 2021, 22nd Annual Conference of the International Speech Communication Association, Brno, Czechia, 30 August - 3 September 2021, pages 2242-2246. ISCA.
+Chengyi Wang, Yu Wu, Shujie Liu, Zhenglu Yang, and Ming Zhou. 2020c. Bridging the gap between pretraining and fine-tuning for end-to-end speech translation. In The Thirty-Fourth AAAI Conference on Artificial Intelligence, AAAI 2020, The Thirty-Second Innovative Applications of Artificial Intelligence Conference, IAAI 2020, The Tenth AAAI Symposium on Educational Advances in Artificial Intelligence, EAAI 2020, New York, NY, USA, February 7-12, 2020, pages 9161-9168. AAAI Press.
+Chengyi Wang, Yu Wu, Shujie Liu, Ming Zhou, and Zhenglu Yang. 2020d. Curriculum pre-training for end-to-end speech translation. In Proceedings of the
+
+58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 3728-3738. Association for Computational Linguistics.
+
+Chen Xu, Bojie Hu, Yanyang Li, Yuhao Zhang, Shen Huang, Qi Ju, Tong Xiao, and Jingbo Zhu. 2021. Stacked acoustic-and-textual encoding: Integrating the pre-trained models into speech translation encoders. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 1: Long Papers), Virtual Event, August 1-6, 2021, pages 2619-2630. Association for Computational Linguistics.
+
+Rong Ye, Mingxuan Wang, and Lei Li. 2021. End-to-end speech translation via cross-modal progressive training. In *Interspeech* 2021, 22nd Annual Conference of the International Speech Communication Association, Brno, Czechia, 30 August - 3 September 2021, pages 2267-2271. ISCA.
+
+Biao Zhang, Ivan Titov, Barry Haddow, and Rico Senrich. 2020. Adaptive feature selection for end-to-end speech translation. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, Online Event, 16-20 November 2020, volume EMNLP 2020 of *Findings of ACL*, pages 2533-2544. Association for Computational Linguistics.
+
+Renjie Zheng, Junkun Chen, Mingbo Ma, and Liang Huang. 2021. Fused acoustic and text encoding for multimodal bilingual pretraining and speech translation. In Proceedings of the 38th International Conference on Machine Learning, ICML 2021, 18-24 July 2021, Virtual Event, volume 139 of Proceedings of Machine Learning Research, pages 12736-12746. PMLR.
+
+# A MT BLEU Scores after Pretraining
+
+To evaluate the domain gap between MUST-C and the MT datasets (WMT and OPUS), we report MT BLEU scores after pretraining.
+
+| En→ | DCMA | + in-domain MT data | Δ |
| De | 28.0 | 31.2 | +3.2 |
| Fr | 39.3 | 43.2 | +3.9 |
| Ru | 14.5 | 19.6 | +5.1 |
| Es | 31.6 | 35.7 | +4.1 |
| Ro | 21.1 | 29.1 | +8.0 |
| It | 23.3 | 30.8 | +7.5 |
| Pt | 29.5 | 36.6 | +7.1 |
| Nl | 27.3 | 35.0 | +7.7 |
+
+Table 6: MT BLEU scores on transcription-translation pairs of MUST-C tst-COMMON set.
+
+# B Discrete vs. Continuous Alignment
+
+To explore the benefits of discrete alignment, we conduct some analyses of representations learnt by continuous alignment and discrete alignment. Let $(\mathbf{s_i},\mathbf{x_i})$ be an ASR test sample. The fixed-length representations produced by the encoder are denoted as $\mathbf{O}_{\mathbf{i}}^{\mathbf{s}} = [o_{i1}^{s},\dots,o_{iM}^{s}]$ and $\mathbf{O}_{\mathbf{i}}^{\mathbf{x}} = [o_{i1}^{x},\dots,o_{iM}^{x}]$ , where $M$ is the number of memory queries. We define the sentence embedding in each modality $\bar{\mathbf{O}}_{\mathbf{i}}^{\mathbf{s}} = \frac{1}{M}\sum_{j = 1}^{M}o_{ij}^{s}$ , $\bar{\mathbf{O}}_{\mathbf{i}}^{\mathbf{x}} = \frac{1}{M}\sum_{j = 1}^{M}o_{ij}^{x}$ . Then we calculate the average memory-level and sentence-level cosine similarity on subsets with different alignment accuracy, as described in Section 5.5.
+
+$$
+s i m \_ m e m o r y = \frac {1}{N \cdot M} \sum_ {i = 1} ^ {N} \sum_ {j = 1} ^ {M} \cos \left(o _ {i j} ^ {s}, o _ {i j} ^ {x}\right)
+$$
+
+$$
+s i m \_ s e n t e n c e = \frac {1}{N} \sum_ {i = 1} ^ {N} \cos (\bar {\mathbf {O}} _ {\mathbf {i}} ^ {\mathbf {s}}, \bar {\mathbf {O}} _ {\mathbf {i}} ^ {\mathbf {x}})
+$$
+
+As shown in Table 7, our discrete alignment method significantly improves the sentence-level cosine similarity over the continuous alignment, though both alignments are performed in memory level. We believe it is because that the discrete alignment aligns the corresponding speech and text semantically, rather than just minimizing the distance gap between memories. Our method can also get better memory-level cosine similarity on the well-aligned subsets.
+
+| Acc | DCMA | Chimera |
| memory | sentence | memory | sentence |
| [0.8, 1.0] | 0.92 | 0.94 | 0.87 | 0.70 |
| [0.6, 0.8) | 0.84 | 0.89 | 0.81 | 0.63 |
| [0.4, 0.6) | 0.69 | 0.80 | 0.71 | 0.56 |
| [0.2, 0.4) | 0.48 | 0.67 | 0.58 | 0.47 |
| [0.0, 0.2) | 0.28 | 0.57 | 0.38 | 0.36 |
| [0.0, 1.0] | 0.73 | 0.82 | 0.74 | 0.58 |
+
+Table 7: Comparison of memory-level and sentence-level representation similarity on different subsets.
\ No newline at end of file
diff --git a/discretecrossmodalalignmentenableszeroshotspeechtranslation/images.zip b/discretecrossmodalalignmentenableszeroshotspeechtranslation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..224406321ec89c0c7e42a894c87c2f6e951a7466
--- /dev/null
+++ b/discretecrossmodalalignmentenableszeroshotspeechtranslation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7cc3f1bd20b112e8958e51a66396f05dbd6a88d59e59240006484e9d6fdc1ba0
+size 417038
diff --git a/discretecrossmodalalignmentenableszeroshotspeechtranslation/layout.json b/discretecrossmodalalignmentenableszeroshotspeechtranslation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..3917453b883ba702b55620a52f2ee10d6c79bbb0
--- /dev/null
+++ b/discretecrossmodalalignmentenableszeroshotspeechtranslation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cdd9ac23407774285fe047afa333ac9ee68017debc7089ecb61bc4f982a4dba2
+size 407718
diff --git a/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_content_list.json b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..5144ae4ee307fa8963aad55cf117038bc0807a61
--- /dev/null
+++ b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ddc14bcad6bab192cb5a750af8edb638585f2277941d45d9c266520b69fb988b
+size 105792
diff --git a/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_model.json b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..48ef394147da79974fab7dadae631ae212016841
--- /dev/null
+++ b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5bf2b9cd6e3bb10d2554a82c894aca2530d7eb0d775411dc453dd9453de0bbe0
+size 120246
diff --git a/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_origin.pdf b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..8b3272053d39dd86d715273b5b52fea7e139d66d
--- /dev/null
+++ b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/289023d5-30a9-49bc-9c22-08b9ad97cbc1_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cd52cc5f8f22a56b75e1401b474edc8781a099d8442ac1dae0bbbd7b4b628b3c
+size 549782
diff --git a/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/full.md b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..4183cacc0d8bb0756280ea0117b5dc3ab799ac16
--- /dev/null
+++ b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/full.md
@@ -0,0 +1,418 @@
+# DisCup: Discriminator Cooperative Unlikelihood Prompt-tuning for Controllable Text Generation
+
+Hanqing Zhang
+
+Beijing Institute of Technology,
+
+Beijing, China
+
+zhanghanqing@bit.edu.cn
+
+Dawei Song*
+
+Beijing Institute of Technology,
+
+Beijing, China
+
+dwsong@bit.edu.cn
+
+# Abstract
+
+Prompt learning with immensely large Casual Language Models (CLMs) has been shown promising for attribute-controllable text generation (CTG). However, vanilla prompt tuning tends to imitate training corpus characteristics beyond the control attributes, resulting in a poor generalization ability. Moreover, it is less able to capture the relationship between different attributes, further limiting the control performance. In this paper, we propose a new CTG approach, namely DisCup, which incorporates the attribute knowledge of discriminator to optimize the control-prompts, steering a frozen CLM to produce attribute-specific texts. Specifically, the frozen CLM model, capable of producing multitudinous texts, is first used to generate the next-token candidates based on the context, so as to ensure the diversity of tokens to be predicted. Then, we leverage an attribute-discriminator to select desired/undesired tokens from those candidates, providing the inter-attribute knowledge. Finally, we bridge the above two traits by an unlikelihood objective for prompt-tuning. Extensive experimental results show that DisCup can achieve a new state-of-the-art control performance while maintaining an efficient and high-quality text generation, only relying on around 10 virtual tokens1.
+
+# 1 Introduction
+
+Attribute-controllable text generation (CTG) aims to produce texts that satisfy desired attributes (e.g., sentiment, topic, etc.), facilitating safer and more practical text generation applications. For example, we need to control the emotion and politeness of generated text in a dialogue system for a more friendly interaction, while it is also crucial to avoid generating mindless and offensive content such as racial discrimination and toxic words.
+
+*Corresponding author, also with The Open University, United Kingdom.
+
+1The code implementation is available at: https://github.com/littlehacker26/disc-cooperative-up-tuning
+
+Current Transformer-based pre-trained language models (PLMs), especially casual language models (CLMs) like the GPT family (Brown et al., 2020), have enabled generation of texts of an unprecedented quality. However, due to the lack of interpretability of deep neural networks, it is often hard to guarantee the controllability of these models (Zhang et al., 2022). This is a challenging and largely unsolved problem.
+
+The most natural ways of using transformer-based PLMs for CTG are to fine-tune or retrain the models (Chan et al., 2021; Keskar et al., 2019; Khalifa et al., 2021; Gururangan et al., 2020a), so as to control the PLMs to generate texts satisfying the control attributes. Such methods have achieved certain performance breakthroughs in this area. Nevertheless, the scale of PLMs is getting larger in recent years, making the PLMs resource-intensive to fine-tune or retrain. Therefore, increasing attention has been paid to the decoding-time methods, where a PLM is always fixed and a guided module is used to steer the text generation process.
+
+The core idea of existing decoding-time approaches is to train an external guided module that consists of a discriminator (Zou et al., 2021; Yang and Klein, 2021; Dathathri et al., 2020; Kumar et al., 2021; Liu et al., 2020) or generative discriminator (Liu et al., 2021; Krause et al., 2021a), to adjust the probability of naturally producing a token by the PLM at the decoding phase. This type of method exhibits a strong controllability while maintaining the generalization ability of the original PLM. However, those methods decouple the guided module from the generative PLM, resulting in either computational challenges (i.e., longer inference time or additional parameters) or a negative impact on text generation quality (i.e., arbitrary output text with a lower perplexity).
+
+More recently, CTG approaches based on prompt-tuning are proposed (Li and Liang, 2021; Yang et al., 2022). Control-prompts are usually
+
+trained separately with some different attribute-specific corpus, using Maximum Likelihood Estimation (MLE) on the traditional next-token prediction task (see more details in Appendix A.2). The trained control-prompts are then used as a prefix to steer the attribute-specific generation. This mechanism manifests a promising text quality and a lower computational cost; however, it still suffers from the following drawbacks: (Problem 1) The learned control-prompts may absorb the features of training corpus aimlessly and are easily overfitted to other aspects in the training data beyond the control attributes, such as domain style, resulting in the generation of monotonous text. For example, if the sentiment control prompts are optimized in the movie review data, then the generated texts are generally relevant to movies even given prompt text from other domains. The detailed examples are given in Appendix 6. (Problem 2) Attribute control prompts are often trained independently with single-attribute corpus, resulting in the inability to capture the relationship between multiple attributes. However, the previous works (Liu et al., 2021; Krause et al., 2021b; Qian et al., 2022) reveal that attribute reference is an important factor in CTG. For example, when generating sentences toward a positive sentiment, we hope the model can refer to the negative ones, so as to achieve a better control performance.
+
+To tackle the aforementioned problems, we propose DisCup, a Discriminator Cooperative Unlikelihood Prompt-tuning approach for CTG. The key idea is to move the attribute-discriminator, which is usually used to re-rank candidate tokens in the decoding-time approaches, to the training phase for augmenting control-prompt learning, allowing the learned prompts to inherit the advantages of decode-time approaches to some extent. Specifically, the knowledge of the attribute-discriminator is distilled into some continuous control-prompts by a novel objective, using unlikelihood training (Welleck et al., 2020) to steer a frozen CLM to produce attribute-specific texts. Different from maximizing the probability of the next token under a given context, the proposed objective contains two parts: a likelihood objective that encourages the model to generate candidate tokens satisfying the desired attributes, and an unlikelihood objective that allows the model to alleviate generating candidate tokens inconsistent with the target attributes.
+
+In our approach, the candidate tokens are natu
+
+rally self-generated by the frozen CLM (i.e., the top- $k$ highly probable tokens under the given context), which is trained on a large corpus and capable of producing multitudinous texts, rather than the ground-truth tokens appearing in the training samples. This will help the control-prompts relieve the problem of over-fitting the features in training data other than target attributes, while ensuring that the CTG model does not deviate far from the original CLM. As such, the aforementioned Problem 1 can be addressed. Meanwhile, re-ranking the candidate tokens by the attribute-discriminator to chose the desired/undesired tokens, would also indirectly incorporate the relationship between different attributes (thus addressing Problem 2), and the unlikelihood training would further enhance the control performance of the CTG model.
+
+Experimental results on two attribute-controllable generation tasks, i.e., sentiment control and toxicity avoidance, prove that DisCup can achieve a new SOTA control performance. In addition, our method shows a strong comprehension ability, which can simultaneously guarantee a better text quality and a lower computational cost.
+
+Our main contributions are as follows: (1) We provide a new alternative for controllable generation, by moving the attribute-discriminator in the scheme of decoding-time approaches into the training phase for prompt learning. This allows the model to take advantages of both prompt-tuning and decoding-time methods. (2) We propose a novel unlikelihood training strategy to enhance the control-prompts learning, which uses the knowledge in the attribute-discriminator to select the likely/unlikely target tokens from the self-generated tokens of the frozen CLM, instead of carrying out the traditional next-token prediction based on a training corpus. (3) We conduct extensive experiments on the tasks of sentiment control and toxicity avoidance, and the results prove the effectiveness of DisCup and at same time highlight the promise of prompt-learning in CTG.
+
+# 2 Related Work
+
+A large number of PLM-based CTG approaches have recently emerged. The most natural way is to retrain/refactor the PLMs to establish CTG-specific models. CTRL (Keskar et al., 2019) is a representative early work, which trains a conditioned language model on the training corpus containing a variety of control code. Yu et al.
+
+(2021) propose an alignment function module to transform the attribute representation, and steer the GPT2-based text generation. CoCon (Content-Conditioner) (Chan et al., 2021) injects a control block into the GPT2 model and provides the control code as a separate input, then retransmits the whole module by self-supervised learning. Zhang et al. (2020) propose POINTER, which modifies the structure of Transformer to generate text in a progressive manner for lexically constrained text generation. Wang et al. (2021) propose a Mention Flags (MF) module, which is injected into the decoder of the Transformer, to achieve a higher level of constraint satisfaction. However, retraining/refactoring the PLMs faces the challenge of lacking labeled data and high computational costs.
+
+As the size of PLMs rapidly increases, the retraining approaches become computationally expensive. Therefore, decode-time approaches, in which the parameters of PLM are fixed, become widely applied to CTG. PPLM (Dathathri et al., 2020) uses a simple attribute classifier on the head of a PLM to update the hidden layer by gradient feedback, to achieve the goal of generating desired attribute texts. Instead of updating the hidden layer, Fudge (Yang and Klein, 2021) directly uses the discriminator to select candidate tokens produced by a frozen GPT2 model. In order to accelerate the generation process, GeDi (Krause et al., 2021b) trains the class-conditional language model (CCLM) as generative discriminators to guide the generation from a base GPT2. Plug-and-Blend (Lin and Riedl, 2021) extends GeDi to controllable story generation by introducing a planner module. Similarly, DEXPERT (Liu et al., 2021) fine-tunes GPT2 as expert (anti-expert) to re-rank the predictions of the PLM. Decoding-time approaches usually can achieve a competitive control effect, yet fall short in text quality and inference speed, since the guided modules are always decoupled from the generator.
+
+Recently, prompt-based methods for CTG have been proposed. Li and Liang (2021) propose the use of prefix tuning, which freezes the PLM's parameters and back-propagates the error to optimize a continuous task-specific vector to realize a controllable text generation. Based on prefix-tuning, Qian et al. (2022) takes into consideration the relationship among prefixes and trains multiple prefixes simultaneously. Yang et al. (2022) leverage the prompt-tuning (Lester et al., 2021) to establish a multi-attribute control framework, namely Tai
+
+lor. Our work shows some similarity to Tailor, but differs in that we focus on improving the inherent problems in the vanilla prompt tuning, instead of prompt-based multi-attribute control.
+
+To the best of our knowledge, we are the first to move the discriminator to the training phase, allowing the PLMs to learn a re-ranked token distribution by incorporating the attribute discriminator information, and optimize control-prompts for attribute-specific text generation. As a result, the proposed method inherits the advantages of both decode-time and prompt-tuning approaches to generate higher-quality texts, with a faster inference speed and a better control performance. DIRECTOR (Arora et al., 2022) also combines the discriminator in training phase for text generation. However it adds extra classifier architecture to the standard decoder-layer, which deviates from the paradigm of prompt-tuning.
+
+# 3 Problem Definition
+
+In this paper, we are concerned with the task of attribute-controllable text generation that aims to steer a casual language model (CLM) (i.e., GPT2, see more details in Appendix A.1) to generate texts satisfying the attribute constraint (e.g., sentiment, topic, toxicity, etc.). Concretely, given the prompt text $X_{1:t} = \{x_1, x_2, \ldots, x_t\}$ , the goal of our task is to generate the continuations $X_{t+1:n} = \{x_{t+1}, x_{t+2}, \ldots, x_n\}$ , and let the whole text $X_{1:n}$ conform to the target control attribute denoted as $C$ . It can be formally described as:
+
+$$
+P (X | C) = p _ {\theta} \left(X _ {t + 1: n} | X _ {1: t}, C\right), \tag {1}
+$$
+
+where $C$ represents the control attribute, which may vary according to different tasks. We expect to establish a CTG model $p_{\theta}(x)$ , so that the generated texts $X$ can satisfy the control attribute and have good fluidity and diversity at the same time.
+
+# 4 Methodology
+
+# 4.1 Overview
+
+Different from fine-tuning the whole CLM model, we aim at optimizing some continuous virtual tokens (also called control-prompts) as a prefix, to steer a fixed CLM to generate attribute-specific texts. As illustrated in Figure1, we first feed a partial sequence into the fixed CLM to obtain a next-token prediction distribution. Then the attributediscriminator is used to re-rank the top- $k$ candi
+
+
+Figure 1: An illustration of DisCup. The CLM $p_g$ is always fixed. We first feed $x_{1:3}$ into the CLM model and get the next-token distribution (i.e., probable token distribution of $x_4$ ). Then, the attribute-discriminator $p_d(a / x_{1:4})$ is employed to assign the probability classified as desired-attribute $a$ (e.g., positive sentiment) for each top- $k$ candidate token. Finally, we encourage $p_g(x_4 / (x_{1:3}, P))$ to generate tokens with a higher probability towards the desired attribute and avoid the ones with the opposite attribute, using unlikelihood training.
+
+dates. Instead of using the traditional MLE objective (detailed in Appendix A.2), which maximizes the probability of the next token for a given context, we encourage the CLM within control-prompts to generate the candidate tokens classified by discriminator with higher confidence towards the desired attributes, and keep away from the opposite ones. The optimization weight of each candidate is determined by the normalized attribute confidence of the discriminator.
+
+# 4.2 Model Architecture
+
+Similar to the vanilla prompt tuning (Yang et al., 2022), we aim to get the continuous control-prompts $P_{k}$ for each attribution $A_{k}$ . Let us denote the dimensionality of word embeddings in the CLM as $d_{emb}$ , and the prompt length of $A_{k}$ as $\ell_{k}$ . The attribute control-prompts are represented as:
+
+$$
+P _ {k} \in \mathbb {R} ^ {\ell_ {k} \times d _ {e m b}}, \tag {2}
+$$
+
+where the parameters are initialized randomly. Following the paradigm described in Equation 12, with the prompts $P_{k}$ as a prefix, the probability of modeling the text $X_{n} = \{x_{1}, x_{2}, \ldots, x_{n}\}$ with a CLM parameterized with $\theta$ can be formulated as:
+
+$$
+P _ {\theta} \left(x _ {1: n}\right) = \prod_ {t = 1} ^ {n} p _ {\theta} \left(x _ {t} \mid x _ {< t}, P _ {k}\right). \tag {3}
+$$
+
+Empirically, we re-parameterize the $P_{k}$ for stable training. An external $LSTM_{\theta^{\prime}}$ module is introduced to make the control-prompts close to the
+
+natural language. Formally, it is given by:
+
+$$
+P _ {k} [ i,: ] = \operatorname {L S T M} _ {\theta^ {\prime}} \left(P _ {k} ^ {\prime} [ i,: ]\right), \tag {4}
+$$
+
+where $i\in [0,\ell_k)$ , and $\theta^\prime$ denotes the parameters of $LSTM$ . During training phrase, we fix the LM's parameters $\theta$ and only update $\theta^{\prime}$
+
+# 4.3 Candidate Token Selection with Attribute-discriminator
+
+Instead of using the context's next token in the training corpus as ground-truth tokens, we use an external attribute-discriminator to select candidates from the next-token distribution given by a frozen CLM. Since the CLM is trained with a variety of text corpora, extracting the candidate tokens from the fixed CLM can improve the generalization ability of the CTG model. Additionally, selecting the most highly probable tokens produced by the fixed CLM as ground-true tokens, ensuring the trained CTG model remains near the original CLM.
+
+More specifically, we first train an attribute-discriminator $p_d(a / x)$ based on given labelled training data. Then assuming a completed sample $X_{n} = \{x_{1},x_{2},\ldots ,x_{n}\}$ , we get the candidate tokens distribution via a CLM at arbitrary step $t$ . Formally, we use $\mathbf{h}_t\in \mathbb{R}^{|\mathcal{V}|}$ to represent the output logit, and calculate the probability distribution over the vocabulary $\mathcal{V}$ :
+
+$$
+p _ {\theta} \left(\hat {\boldsymbol {x}} _ {t} \mid x _ {< t}\right) = \operatorname {s o f t m a x} \left(\mathbf {h} _ {t}\right), \tag {5}
+$$
+
+where $\hat{\pmb{x}}_t$ is a normalized distribution over the vocabulary, and a higher value of it indicates that the
+
+corresponding token is more likely to be combined with the context $x_{| Target Sentiment | Method | Correctness(%) (↑) | Fluency(↓) PPL | Diversity(↑) Dist-1/Dist-2/Dist-3 | Coverage(↓) Rate(%) |
| Positive | Neutral | Negative |
| Positive | PPLM° | | 52.68 | 8.72 | 113.54 | 0.39/0.83/0.89 | 3.47 |
| DAPT° | | 61.81 | 14.17 | 41.89 | 0.20/0.64/0.84 | 4.22 |
| CTRL° | | 77.24 | 18.88 | 48.24 | 0.13/0.53/0.79 | 8.86 |
| GEDI° | | 86.01 | 26.80 | 123.56 | 0.20/0.66/0.85 | 3.12 |
| DEXPERT° | | 94.46 | 36.42 | 60.64 | 0.18/0.63/0.84 | 3.49 |
| Vanilla Prompt-tuning° | | 78.08 | 40.88 | 38.23 | 0.14/0.48/0.73 | 69.60 |
| FUDGE (discriminator-based)° | | 96.92 | 56.04 | 228.76 | 0.16/0.52/0.76 | 1.78 |
| DisCup®(w/o unlikelyhood) | | 91.58 | 49.92 | 44.20 | 0.15/0.51/0.77 | 3.94 |
| DisCup®(w/ unlikelyhood) | | 94.98 | 64.96 | 48.71 | 0.14/0.50/0.76 | 3.24 |
| Negative | PPLM° | 10.26 | 60.95 | | 122.41 | 0.40/0.83/0.90 | 3.47 |
| DAPT° | 12.57 | 66.72 | | 43.01 | 0.19/0.63/0.83 | 3.33 |
| CTRL° | 20.95 | 62.37 | | 45.27 | 0.13/0.51/0.78 | 9.87 |
| GEDI° | 60.43 | 91.27 | | 138.93 | 0.19/0.66/0.86 | 4.11 |
| DEXPERT° | 64.01 | 96.23 | | 67.12 | 0.20/0.64/0.83 | 2.71 |
| Vanilla Prompt-tuning° | 49.28 | 73.20 | | 39.55 | 0.14/0.49/0.72 | 56.56 |
| FUDGE (discriminator-based)° | 66.84 | 98.76 | | 265.79 | 0.23/0.68/0.83 | 1.29 |
| DisCup®(w/o unlikelyhood) | 60.80 | 90.64 | | 36.72 | 0.12/0.45/0.72 | 3.51 |
| DisCup®(w/ unlikelyhood) | 68.76 | 93.64 | | 45.60 | 0.12/0.48/0.77 | 2.97 |
+
+Table 1: The main experimental results of sentiment controllable text generation. $\uparrow$ indicates that the higher corresponding value is better, and $\downarrow$ is the opposite. "—" represents the outlier of the items, and the corresponding methods are just regarded as the reference, but not included in the performance comparison. $\heartsuit$ and $\spadesuit$ mean the decoding-time and the training approaches respectively.
+
+degree of achievement for the desired control attribute. Topicality means whether the generated continuations are consistent with the given prompts. Fluency evaluates the text's fluency from the human perspective. Detailed information can be seen in Appendix E.
+
+# 5.2Baselines
+
+We empirically compare the proposed method with a wide range of baselines.
+
+Training Approaches: (1) Conditional Transformer LM (CTRL (Keskar et al., 2019)) is a pre-trained language model conditioned on task-specific control codes. (2) Domain-adaptive pre-training (DAPT (Gururangan et al., 2020b)) is an approach that applies the PLM to the domain of a target task. We adapt it to sentiment control by pre-training it on sentiment corpus.
+
+Decoding-time Approaches: (1) PPLM is a typical decoding-time method, which uses the discriminator to update PLM's hidden layer to steer controllable generation (Dathathri et al., 2020). (2) GEDI (Krause et al., 2021b) fine-tunes external CCLMs as generative discriminator to guide the attribute-specific generation. (3) DEXPERT (Liu et al., 2021) is the state-of-the-art (SOTA) model so far, which use fine-tuned GPT2 as an expert/anti-expert to steer the text generation, and we directly choose GPT2-large as guided module. For the above baselines, we use GPT2-large as the base
+
+CLM, and the detailed settings are consistent with the existing work (Liu et al., 2021) $^{4}$ .
+
+Discriminator-based: We also explore a decodetime reference baseline, which is closely related to our proposed method. The principle is the same as FUDGE (Yang and Klein, 2021), and the generative model is GPT2-large. The difference is that we replace the future discriminator with the attributediscriminator trained based on GPT2-small. In order to provide more reference information, we keep the depth of top-k sampling $(k = 70)$ at the same level as the size of re-ranked candidate tokens $\mathcal{C}$ in our method.
+
+Vanilla Prompt-tuning: It is a base version of Discup, and each attribute control-prompt is trained under the attribute-specific corpus (e.g., positive and negative sentiment), which is similar to Talor (Yang et al., 2022). GPT2-large is used as the base CLM model and its parameters and sampling algorithm used in the experiments are consistent with our method.
+
+# 5.3 Sentiment Control Task
+
+# 5.3.1 Experimental Setup
+
+Dataset. Following the previous work (Liu et al., 2021), we take the widely used Stanford Sentiment Tree (SST-5) (Socher et al., 2013) as the training corpus, which is collected from movie reviews. The
+
+generation prompts come from different domains collected from OpenWebText (more details can be seen in (Liu et al., 2021)). In total, we get 5K neutral prompts, 2.5K negative prompts, and 2.5k positive prompts, and the affective polarity of those prompts was measured based on the natural generation of GPT2-large. During the experiments, we uniformly set the maximum length of the generation to 20 tokens for every prompt.
+
+Method Setting. we fine-tune GPT2-small on SST-5 as the expert of attribute classifier and use GPT2-large as the base CLM. We conduct the discriminator cooperative unlikelihood prompt tuning on SST-5, ignoring the text sentiment label. The detailed settings of other hyper-parameters can be seen in Appendix C.
+
+# 5.3.2 Results and Analysis
+
+Automatic Evaluation Result. As shown in Table 1, our method significantly outperforms most baselines in correctness and text fluency. PPLM is the least effective because updating the PLM's hidden layer destroys the structure of the original PLM and results in arbitrary output. Compared with the training methods (i.e., DAPT, CTRL), decoding-time methods (i.e., DEXPERT, GEDI) show better controllability yet lower text fluency, which suggests decoupling the guided model from generative models will hurt the quality of the generated text. DEXPERT's performance is close to our method. However, our method shows a higher degree of symmetry in the adversarial steering (i.e., negative prompts toward positive continuations, and vice versa.). In particular, the correctness of our method outperforms DEXPERT by $28.54\%$ in steering the negative prompts to positive generation. We suspect that using a fine-tuned CLM as an expert may itself be biased, and the discriminator can relieve this problem well. DisCup and the vanilla prompt learning both show slight drops in terms of diversity. Fortunately, we find that there is a trade-off between diversity and PPL, and with the increase in the depth of sampling, this gap narrows. More details can be seen in Appendix D.
+
+The discriminator-based method shows a potential to achieve a good control ability without considering the degree of text fluency. On the contrary, vanilla prompt-tuning could produce fluent texts yet shows a poor performance both in correctness and domain generalization. Specifically, around $60\%$ of the generated texts contain domain-related keywords from the training corpus. The concrete
+
+| Method | Relevance(↑) | Fluency(↑) | Topicality(↑) |
| CTRL♣ | 4.7 | 6.4 | 6.7 |
| Vanilla Prompt-tuning♣ | 5.3 | 6.4 | 6.3 |
| DEXPERT♥ | 5.8 | 6.5 | 6.9 |
| DisCup♣ | 7.8 | 6.9 | 7.1 |
+
+examples can be seen in Table 6. Our method inherits the advantages of both prompt-tuning and discriminator-based approaches, thus does not suffer from domain generalization issues, with only less than $4\%$ of generated sentences containing the domain-related keywords. Even without unlikelihood training, our method still far outperforms vanilla prompt-tuning, since the candidates are re-ranked by the discriminator and incorporate inter-attribute relationships. The unlikelihood training further improves the correctness, $\sim 3\%$ for the steering from neutral prompts to positive/negative, and $\sim 10\%$ for the adversarial steering.
+
+Human Evaluation Result. As shown in Table 2, the human evaluation results are almost consistent with the automatic evaluation. DisCup outperforms the baselines. However, the vanilla prompt-tuning has lower scores in Fluency and Topicality. The reason is that vanilla prompts usually steer GPT2 to generate texts about movies (seen specific examples in Table 6), making human evaluators feel like it is always digressing. Our method can alleviate this problem, as our optimization goal is to predict candidate tokens naturally self-generated by the frozen CLM, thus keeping the learned control-prompts not steer too far away from the original language model.
+
+Table 2: The human evaluation results on sentiment control experiment.
+
+| Method | Toxicity(↓) Avg. toxicity prob | Fluency(↓) PPL | Diversity(↑) dist-1/dist-2/dist-3 |
| PLM° | 0.121 | 48.02 | 0.33/0.79/0.91 |
| GEDI° | 0.091 | 56.94 | 0.18/0.66/0.87 |
| DAPT▲ | 0.089 | 47.03 | 0.17/0.62/0.85 |
| DEXPERT° | 0.086 | 49.71 | 0.18/0.64/0.86 |
| FUDGE(discriminator-based)° | 0.062 | 354.78 | 0.20/0.67/0.83 |
| Vanilla Prompt-tuning▲ | 0.108 | 27.40 | 0.12/0.47/0.74 |
| DisCup▲(w/o unlikelyhood) | 0.066 | 39.84 | 0.18/0.60/0.83 |
| DisCup▲(w/ unlikelyhood) | 0.064 | 39.82 | 0.17/0.62/0.84 |
+
+Table 3: The main experimental results on toxicity avoidance. Underscores indicate outliers, and the corresponding method is just regarded as the reference, but not included in the performance comparison. $\heartsuit$ and $\spadesuit$ represent the decoding-time and the training approaches respectively.
+
+# 5.4 Toxicity Avoidance Task
+
+# 5.4.1 Experiment Setting
+
+Dataset. Toxicity training data is provided by Jigsaw Unintended Bias in Toxicity Classification Kaggle challenge $^{5}$ . The dataset contains around 160K toxic comments and 1.4M nontoxic comments. As for the generation prompts, we follow the previous work (Liu et al., 2021) and use 10K nontoxic prompts from the RealToxicityPrompt (Gehman et al., 2020).
+
+Method Setting. Following the setting in the sentiment control task, we fine-tune GPT2-small as an attribute classifier on the toxicity dataset, and use GPT2-large as the base CLM. During the prompt tuning phrase, we randomly sample 5K toxic and 5K nontoxic, respectively, from the toxicity dataset as a training corpus. The whole nontoxic data in the dataset is used for vanilla prompt learning, ensuring the prompts learn the features of non-toxic data. The more detailed settings are given in Appendix C.
+
+# 5.4.2 Result and Analysis
+
+As shown in Table 3, the average toxicity probability of DisCup is 0.064, which significantly outperforms 0.086 achieved by DEXPERT, a SOTA model so far. The performance of DisCup is slightly lower than FUDGE, a reference baseline with lower text quality (the PPL is over 350). The vanilla prompt-tuning performs poorly, which is expected due to its inability to learn from toxic texts. As for the PPL, the vanilla prompt-tuning fits nontoxic text without harming the text quality of PLM, and thus it shows a better performance. DisCup is slightly inferior to it but better than other baselines, even though we set the same size of candidate tokens as that in top-k decoding algorithm of FUDGE. Because control-prompts are cotraining with PLMs, more interaction would allow the model to maintain the original characteristics of CLM as much as possible.
+
+Different from the sentiment control, DisCup remains competitive in term of text diversity, which is close to GEDI, DAPT, and DEXPERT. The main reason is that the range of nontoxic text is relatively more expansive than the toxic, thus allowing the learned control-prompts to imitate the trait and generate diverse texts. Similar to sentiment control, the branch without unlikelihood training is inferior
+
+
+Figure 2: The effect of control-prompt length on model performance. Toxicity probability is measured under an offline classifier trained based on GPT2-small. The size of the re-ranked candidates is set to 30 on the both tasks.
+
+| Method | Time Cost(second) |
| PPLM | 37.39 |
| DEXPERT | 2.54 |
| GEDI | 1.86 |
| GPT2-large | 0.78 |
| DisCup | 0.94 |
+
+Table 4: The cost (time) for generating 20 tokens.
+
+to the setting with an unlikelihood objective, further indicating that the unlikelihood training can provide a gain of control performance.
+
+# 5.5 Further Analysis
+
+Control-prompt Length. We investigate the effect of control-prompt length on the control performance. The result is shown in Figure 2, which suggests that around 10 continuous tokens are enough to achieve a competitive performance, while too long control-prompts can cause difficulty in optimization and hurt the performance. This highlights the promise of prompt learning in parameter-efficient CTG.
+
+Inference Speed. The relatively short control-prompt allows our method to be equipped with efficient inference speed. As shown in Table 4, our method outperforms all decode-time approaches, with an inference speed closer to the pure PLM (GPT2-large). Specifically, our method generates 20 tokens in only 0.94 seconds (that is 0.78s for GPT2-large).
+
+The size of candidate tokens $\mathcal{C}$ . The control performance of our method is proportional to the size of candidate tokens $\mathcal{C}$ . As shown in Figure 3, the deeper the sampling scope is, the better the control performance will be, but meanwhile the PPL deteriorates. This phenomenon is intuitive in a sense that the wider the candidate tokens, the more
+
+
+
+
+
+
+Figure 3: The effect of size of re-ranked candidate tokens on the model control performance and text fluency. The prompt length is set to 10 for positive sentiment steering and toxicity avoidance and 12 for negative sentiment steering. The toxicity probability is measured with an offline classifier based on GPT2-small.
+
+
+Figure 4: The effect of training samples on sentiment control performance. The size of the re-ranked candidates is set to 70, prompt length is 10 on the both tasks. The training samples are randomly selected from OpenWebTextCorpus (Gokaslan and Cohen, 2019).
+
+likely it is to provide tokens satisfying the control conditions. However, there will be more selected tokens in low-probability regions, resulting in a decrease in text fluency.
+
+The size of training samples. We have also conducted an additional analysis to explore the size of training samples on sentiment control performance. We assume that the discriminator is already trained, and DisCup is then trained on some unlabeled samples. As shown in Figure 4, the size of the training data is essential to the result, and 1K samples are enough to get a competitive result, more than 5K samples could achieve the optimal result.
+
+# 6 Conclusions
+
+We have proposed a novel alternative for attribute-controllable text generation, namely discriminator cooperative unlikelihood prompt-tuning (DisCup). Instead of the traditional next-token prediction based on a training corpus, we use a attributediscriminator to select unlikely/likely candidates from the tokens naturally self-generated by a frozen CLM, which is trained on multitudinous textual corpora and capable of producing texts with a high degree of diversity. Then, unlikelihood training is employed to optimize the control-prompts. Experiments conducted on two typical CTG tasks, i.e., sentiment control and toxicity avoidance, prove that our approach not only significantly outperforms the vanilla prompt-tuning approaches, but also exhibits superiority over the existing training and decoding-time approaches.
+
+# Limitations
+
+DisCup collects (un)likely candidate tokens from an original pre-trained CLM, instead of through next-token prediction based on the training corpus. This means that the performance of our approach will be immensely correlated with the power of the base CLM. If the base language model is of a poor quality, the training procedure trends to guide the CTG model to produce awkward tokens provided by the CLM. Consequently the learned control-prompts will steer the CLM to generate poor-quality texts at the inference stage.
+
+In addition, DisCup has been shown to achieve a competitive performance in terms of attribute controllability, text quality, number of model parameters, and inference speed. However, this comprehensive ability is limited in the attribute control task so far, and it is hard to directly apply our method to fine-grained controlled text generation scenarios such as Table-to-Text. This is an open problem that we will explore in our future work.
+
+# Acknowledgments
+
+This research was supported in part by Natural Science Foundation of Beijing (grant number: 4222036) and Huawei Technologies (grant number: TC20201228005).
+
+# References
+
+Kushal Arora, Kurt Shuster, Sainbayar Sukhbaatar, and Jason Weston. 2022. Director: Generator-classifiers for supervised language modeling.
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Advances in Neural Information Processing Systems, volume 33, pages 1877-1901. Curran Associates, Inc.
+Alvin Chan, Yew-Soon Ong, Bill Pung, Aston Zhang, and Jie Fu. 2021. Cocon: A self-supervised approach for controlled text generation. In International Conference on Learning Representations.
+Sumanth Dathathri, Andrea Madotto, Janice Lan, Jane Hung, Eric Frank, Piero Molino, Jason Yosinski, and Rosanne Liu. 2020. Plug and play language models: A simple approach to controlled text generation. In International Conference on Learning Representations.
+Samuel Gehman, Suchin Gururangan, Maarten Sap, Yejin Choi, and Noah A. Smith. 2020. RealToxicityPrompts: Evaluating neural toxic degeneration in language models. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 3356-3369, Online. Association for Computational Linguistics.
+Aaron Gokaslan and Vanya Cohen. 2019. Openwebtext corpus.
+Suchin Gururangan, Ana Marasovic, Swabha Swayamdipta, Kyle Lo, Iz Beltagy, Doug Downey, and Noah A. Smith. 2020a. Don't stop pretraining: Adapt language models to domains and tasks. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8342-8360, Online. Association for Computational Linguistics.
+Suchin Gururangan, Ana Marasovic, Swabha Swayamdipta, Kyle Lo, Iz Beltagy, Doug Downey, and Noah A. Smith. 2020b. Don't stop pretraining: Adapt language models to domains and tasks. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8342-8360, Online. Association for Computational Linguistics.
+Nitish Shirish Keskar, Bryan McCann, Lav Varshney, Caiming Xiong, and Richard Socher. 2019. CTRL - A Conditional Transformer Language
+
+Model for Controllable Generation. arXiv preprint arXiv:1909.05858.
+Muhammad Khalifa, Hady Elsahar, and Marc Dymetman. 2021. A distributional approach to controlled text generation. In International Conference on Learning Representations.
+Ben Krause, Akhilesh Deepak Gotmare, Bryan McCann, Nitish Shirish Keskar, Shafiq Joty, Richard Socher, and Nazneen Fatema Rajani. 2021a. GeDi: Generative discriminator guided sequence generation. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 4929-4952, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Ben Krause, Akhilesh Deepak Gotmare, Bryan McCann, Nitish Shirish Keskar, Shafiq Joty, Richard Socher, and Nazneen Fatema Rajani. 2021b. GeDi: Generative discriminator guided sequence generation. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 4929-4952, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Sachin Kumar, Eric Malmi, Aliaksei Severyn, and Yulia Tsvetkov. 2021. Controlled text generation as continuous optimization with multiple constraints. In Advances in Neural Information Processing Systems.
+Brian Lester, Rami Al-Rfou, and Noah Constant. 2021. The power of scale for parameter-efficient prompt tuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 3045-3059, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Xiang Lisa Li and Percy Liang. 2021. Prefix-tuning: Optimizing continuous prompts for generation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4582-4597, Online. Association for Computational Linguistics.
+Zhiyu Lin and Mark O Riedl. 2021. Plug-and-blend: A framework for plug-and-play controllable story generation with sketches. In Proceedings of the AAAI Conference on Artificial Intelligence and Interactive Digital Entertainment, volume 17, pages 58-65.
+Alisa Liu, Maarten Sap, Ximing Lu, Swabha Swayamdipta, Chandra Bhagavatula, Noah A. Smith, and Yejin Choi. 2021. DExperts: Decoding-time controlled text generation with experts and anti-experts. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 6691-6706, Online. Association for Computational Linguistics.
+
+Ruibo Liu, Guangxuan Xu, Chenyan Jia, Weicheng Ma, Lili Wang, and Soroush Vosoughi. 2020. Data boost: Text data augmentation through reinforcement learning guided conditional generation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 9031-9041, Online. Association for Computational Linguistics.
+Jing Qian, Li Dong, Yelong Shen, Furu Wei, and Weizhu Chen. 2022. Controllable natural language generation with contrastive prefixes. In Findings of the Association for Computational Linguistics: ACL 2022, pages 2912-2924, Dublin, Ireland. Association for Computational Linguistics.
+Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Ng, and Christopher Potts. 2013. Recursive deep models for semantic compositionality over a sentiment treebank. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, pages 1631-1642, Seattle, Washington, USA. Association for Computational Linguistics.
+Yufei Wang, Ian Wood, Stephen Wan, Mark Dras, and Mark Johnson. 2021. Mention flags (MF): Constraining transformer-based text generators. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 103-113, Online. Association for Computational Linguistics.
+Sean Welleck, Ilia Kulikov, Stephen Roller, Emily Dinan, Kyunghyun Cho, and Jason Weston. 2020. Neural text generation with unlikelihood training. In International Conference on Learning Representations.
+Kevin Yang and Dan Klein. 2021. FUDGE: Controlled text generation with future discriminators. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 3511-3535, Online. Association for Computational Linguistics.
+Kexin Yang, Dayiheng Liu, Wenqiang Lei, Baosong Yang, Mingfeng Xue, Boxing Chen, and Jun Xie. 2022. Tailor: A prompt-based approach to attribute-based controlled text generation. CoRR, abs/2204.13362.
+Dian Yu, Zhou Yu, and Kenji Sagae. 2021. Attribute alignment: Controlling text generation from pretrained language models. In Findings of the Association for Computational Linguistics: EMNLP 2021, Virtual Event / Punta Cana, Dominican Republic, 16-20 November; 2021, pages 2251-2268. Association for Computational Linguistics.
+Hanqing Zhang, Haolin Song, Shaoyu Li, Ming Zhou, and Dawei Song. 2022. A survey of controllable text generation using transformer-based pre-trained language models.
+
+Yizhe Zhang, Guoyin Wang, Chunyuan Li, Zhe Gan, Chris Brockett, and Bill Dolan. 2020. POINTER: Constrained progressive text generation via insertion-based generative pre-training. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 8649-8670, Online. Association for Computational Linguistics.
+Xu Zou, Da Yin, Qingyang Zhong, Hongxia Yang, Zhilin Yang, and Jie Tang. 2021. Controllable generation from pre-trained language models via inverse prompting. In Proceedings of the 27th ACM SIGKDD Conference on Knowledge Discovery & Data Mining, KDD '21, page 2450-2460, New York, NY, USA. Association for Computing Machinery.
+
+# Appendices
+
+In this section, we provide external information for reproducing the experimental results mentioned in the paper and some additional preliminaries, theoretical analysis, and experimental results supplementary to the main page.
+
+# A Preliminaries
+
+# A.1 Language Modeling
+
+Casual Lanauge Model(CLM) usually leverage a auto-regressive PLM to perform step-wise density estimation(i.e., next-token prediction). Suppose a CLM parameterized with $\theta$ , given the partial sequence $x_{| Top-k | Dist1/2/3 | PPL | Correctness(%) |
| 5 | 0.14/0.47/0.72 | 38.6 | 95.30 |
| 10 | 0.14/0.51/0/77 | 48.0 | 94.98 |
| 30 | 0.15/0.55/0.82 | 76.6 | 93.56 |
| 50 | 0.16/0.57/0.84 | 92.5 | 92.71 |
+
+Table 5: The relationship between diversity and text fluency. The result is test under $5\mathrm{K}$ neutral prompts, steering direction of sentiment control generation is positive. With increasing of sampling depth, i.e., size of top- $k$ , text diversity increases, and text fluency deteriorates.
+
+# E Human Evaluation
+
+We conduct the human evaluation experiment for the sentiment control task. During the experiment, we chose 10 positive-steering prompts composed of neutral and positive prompts, 10 negative-steering prompts composed of neutral and negative prompts. Each prompt is tested under four representative CTG models (i.e., CTRL, DEXPERT, Vanilla prompt tuning, and our approach), and we totally get 80 samples. To this end, we invite 5 experts who are well-educated in English to score the samples from the aspects including sentiment relevance, topicality, and text fluency. Every human expert is asked to give a score in the range of 0-10 from those three perspectives for each sample; the higher the score, the better the text's quality. Every expert takes around 40 minutes to finish the evaluation test, and we calculate the average score of each metric for every CTG method under comparison, recording the final results in Table 2.
+
+# F Domain-related Keywords
+
+We count the high-frequency words appeared in SST-5 dataset, and then manually screen 10 keywords related to the domain of movie review. Those keywords are: "movie", "movies", "films", "film", "story", "director", "directors", "comedy", "audience", "drama".
+
+# G Generation Examples
+
+In this section, we provide some specific examples for different CTG methods, which could be seen in Table 6, Table 8, and Table 7.
+
+| Target sentiment | Vanilla Prompt Tuning | DisCup (Ours) |
| positive | In fact the team was on its way to a $5 million budget in only two days. A movie like this could easily get lost in | In fact the team was on its way to winning," said the former president of the United States While Obama was president and a Democrat, the |
| positive | The dismissive look on her face sold it, and it shows... The result is an unassuming yet charming movie, one that will appeal to | The dismissive look on her face sold it, but it made her smile again. "Thanks very much, you are awesome!" "Thanks too!" she |
| positive | But they are spread across a huge land area so that the audience has a lot more time to enjoy the film. It's not as if it' | But they are spread across a huge land area so you can enjoy a good day with good friends, and they can be fun but you have to keep a |
| positive | Doctors there treat underserved Medicaid patients, a segment that's not well represented elsewhere in the film. But that's just the beginning | Doctors there treat underserved Medicaid patients but there are many others that have helped, " he added. "We want to be part of their success |
| positive | There is a plausible sense that the film could easily have been a lot better if its director had spent more time with the characters | There is a plausible reason why he wants to help us. It was one of the most amazing things. |
| positive | It was a hot alpha release, the kind of film to watch for an audience that might be interested in the genre but not necessarily in the | It was a hot alpha release, so please don't hesitate but enjoy :) Thanks for the great work |
| positive | "I would recommend all U.S. audiences to make the journey to see the story... It's well worth the trip | "I would recommend all U.S. citizens to join and support your efforts," said a U.S. citizen, who is now working in |
| negative | nominee questions key Obama-era rules of engagement. The film is too long and repetitive, its plot too ponderous and its politics too confused | nominee questions key Obama-era rules and rules of federal court: not true no one could have been prosecuted even for doing nothing |
| negative | All I can say is that if this were an independent film, it's a shame that the director and producers did so little to | All I can say is it sucks but if there ever are bad days, I'll never forget the first one |
| negative | Bateson and her team watched the same old story and didn 't realize it's a movie until a couple of scenes in the end | Bateson and her team watched the movie over and over until a single frame didn't match the other one. But not only did the scene |
| negative | Toronto: Between the Lines feels like the first film directed by a young, inexperienced actor. I would have liked to | Toronto: Between the bad weather and bad luck (or bad luck) the team never played well and had little time or chance |
| negative | Stuff like that, I'd like to see the director's head explode. '.. The film does have a good deal | Stuff like that, I could write more but no matter where I went there's not even one restaurant. No one will |
| negative | And now, to prove that point, they're making a comedy of the year... and it's not funny... and | And now, to prove that point, no matter what, it would be wrong and pointless to try to do something without anyone's consent." |
| negative | Visit GoldAnswers for help moving to Office Space. The Big Lebowski (1998) A comedy about two friends who are | Visit GoldAnswers for help moving to Office 365 for less. Not only cannot you move without the proper documentation, but it also won't be easy |
+
+Table 6: The selected examples of sentiment control between our method and vanilla prompt tuning. We highlight the words relevant to the training corpus domain in red color. Vanilla prompt-tuning trends to overly imitate the feature of the training corpus (movie reviews) beyond sentiment attribute. However, our method could overcome this drawback well in most cases.
+
+| Prompt: He was accused of two offences, or doctrinal (Positive Steering) |
| PPLM | He was accused of two offences, or doctrinal crimes or revolt by doing:…slapping the breasts of a virgin, and she conceived by |
| DART | He was accused of two offences, or doctrinal offences within religious circles,"she added. "It's hard being here today on Easter this year because |
| CTRL | He was accused of two offences, or doctrinal and spiritual heresies, for whichhe was condemned by a church council in Rome. These charges are not mentioned |
| GEDI | He was accused of two offences, or doctrinal offenses, in regard to hisordination to the ministry during the War of Independence of 1814 |
| DEXPERT | He was accused of two offences, or doctrinal breaches, relating to a prayercampaign organised by Christians in northern Russia in 2008."He |
| Vanilla Prompt | He was accused of two offences, or doctrinal sins, but the most disturbingone was the one he committed against his own mother. The result is the |
| DisCup (Ours) | He was accused of two offences, or doctrinal offences; but the judge foundhe had good reason to believe that he would not do this." |
| Prompt: UCSF is the nation's leading (Negative Steering ) |
| PPLM | UCSF is the nation's leading integrative university, offering countless students a world-classeducational experience in all subjects, from pre |
| DART | UCSF is the nation's leading health care research, teaching and patientcare organization. In fiscal year 2015, it directly funded and assisted |
| CTRL | UCSF is the nation's leading provider of online student assistance andservices. For further information, contact us(http://m.theage.com.au/sport/motor@ @ |
| GEDI | UCSF is the nation's leading supporter of hospitals. I'm not tryingto be disingenuous, but after last night's hurtful |
| DEXPERT | UCSF is the nation's leading provider of undergraduate and graduatedegrees in college-level psychology. A subsidiary, University of California-San |
| Vanilla Prompt | UCSF is the nation's leading student newspaper, and its staff is a motleycrew of left-leaning intellectuals and liberal activists. But |
| DisCup (Ours) | UCSF is the nation's leading provider in healthcare, but only 3.3% of studentsreceive any healthcare assistance in the first year or less |
+
+Table 7: The generation examples of sentiment control over some CTG approaches. We chose two challenging prompts with opposite polarity compared to the target sentiment.
+
+| Prompt: The prisoners are the bad guys, and |
| PPLM | The prisoners are the bad guys, and herson is Peter, the evil one. And to soothe his pain, he is going to |
| DART | The prisoners are the bad guys, and we all have to work together to destroy the bad guys and prevent them from further disasters," |
| GEDI | The prisoners are the bad guys, and I was into the struggle for their freedom. At school in Thailand's Narathiwat prison, |
| DEXPERT | The prisoners are the bad guys, and by setting their cages up so close to the street, they were the least of their problems. But |
| Vanilla prompt | The prisoners are the bad guys, and the good guys are in jail. The bad guys will always get a free pass. The prisoners |
| DisCup (Ours) | The prisoners are the bad guys, and the prisoners can get away with it, but it's not the end. We can get more justice if |
+
+Table 8: The generation examples of toxicity avoidance over different CTG methods.
\ No newline at end of file
diff --git a/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/images.zip b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..38078ffc1bf0fe878414a8532a6f6037d925e764
--- /dev/null
+++ b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a0278e30133687a2b998c4745e0cd4cf6b8b9b4340f2661bd352130a5746d84b
+size 1047798
diff --git a/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/layout.json b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..366ff6d4cdc39df90e724028525cf725a9453c4d
--- /dev/null
+++ b/discupdiscriminatorcooperativeunlikelihoodprompttuningforcontrollabletextgeneration/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a7f622b8098504dce6684fbec9d948d6841af959ca8d286a1b6a8dd141592caf
+size 449203
diff --git a/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_content_list.json b/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..c5d90bc31573b0a14bd3767e6849fe69238f3929
--- /dev/null
+++ b/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:86b1d306cf9444f09e156ca7a540be2f1d95c45e493159001250c5900520f262
+size 160083
diff --git a/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_model.json b/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..5e382ca66131f3989588e440a59e32ca9d9aa145
--- /dev/null
+++ b/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8722eafa94543be62ae8661cda78cb605025aa732196ed53fdd9e0453e01efb7
+size 182673
diff --git a/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_origin.pdf b/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..f1dc711da3c3d1ccb2166fe33c593736957547bd
--- /dev/null
+++ b/disentanglinguncertaintyinmachinetranslationevaluation/c67f535b-0884-4818-bcc2-aacbe8088e13_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5e187682a73a7784e47d1e6491c85a06190c2a038071fed0c85daa91e33895f3
+size 941471
diff --git a/disentanglinguncertaintyinmachinetranslationevaluation/full.md b/disentanglinguncertaintyinmachinetranslationevaluation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..de84b6f25a70167baaa3dac2f624489e033b9a39
--- /dev/null
+++ b/disentanglinguncertaintyinmachinetranslationevaluation/full.md
@@ -0,0 +1,475 @@
+# Disentangling Uncertainty in Machine Translation Evaluation
+
+Chrysoula Zerva $^{1,4}$ Taisiya Glushkova $^{1,4}$ Ricardo Rei $^{2,3,4}$ André F. T. Martins $^{1,2,4}$
+
+$^{1}$ Instituto de Telecomunicações $^{2}$ Unbabel $^{3}$ INESC-ID
+
+$^{4}$ Instituto Superiore Técnico & LULIS (Lisbon ELLIS Unit)
+
+{chrysoula.zerva, taisiya.glushkova, ricardo.rei, andre.t.martins}@tecnico.ulisboa.pt
+
+# Abstract
+
+Trainable evaluation metrics for machine translation (MT) exhibit strong correlation with human judgements, but they are often hard to interpret and might produce unreliable scores under noisy or out-of-domain data. Recent work has attempted to mitigate this with simple uncertainty quantification techniques (Monte Carlo dropout and deep ensembles), however these techniques (as we show) are limited in several ways – for example, they are unable to distinguish between different kinds of uncertainty, and they are time and memory consuming. In this paper, we propose more powerful and efficient uncertainty predictors for MT evaluation, and we assess their ability to target different sources of aleatoric and epistemic uncertainty. To this end, we develop and compare training objectives for the COMET metric to enhance it with an uncertainty prediction output, including heteroscedastic regression, divergence minimization, and direct uncertainty prediction. Our experiments show improved results on uncertainty prediction for the WMT metrics task datasets, with a substantial reduction in computational costs. Moreover, they demonstrate the ability of these predictors to address specific uncertainty causes in MT evaluation, such as low quality references and out-of-domain data.1
+
+# 1 Introduction
+
+Trainable neural-based metrics, such as COMET or BLEURT (Rei et al., 2020a; Sellam et al., 2020a), hold great promise for MT evaluation (Freitag et al., 2021b). For system comparison, they surpass or complement traditional lexical metrics such as BLEU (Papineni et al., 2002), and at a segment level, they show higher correlations with human judgments, with and without access to references (Kepler et al., 2019; Thompson and Post, 2020; Ranasinghe et al., 2020).
+
+
+Figure 1: Epistemic uncertainty caused by out-of-domain data. We show sharpness (average uncertainty) on two English-Russian test sets from the WMT21 metrics task: an in-domain dataset (News) and an out-of-domain dataset (TED talks). Our proposed method that handles epistemic uncertainty (Direct Uncertainty Predictor - DUP) exhibits higher uncertainty on the out-of-domain dataset, as expected. The heteroscedastic (HTS) predictor, which detects aleatoric, but not epistemic uncertainty, has similar uncertainty in both datasets, and the MC dropout (MCD) and deep ensemble (DE) baselines, surprisingly, has the opposite behavior.
+
+However, trainable MT evaluation metrics are not always trustworthy: For example, they can be unreliable in out-of-domain data and low resource languages, and sometimes they disregard specific error types, attributing high scores to low quality translations (Amrhein and Sennrich, 2022). Hence, we need a measure of confidence over their quality predictions for each segment, so that they can be better contextualized and interpreted. Recently, Glushkova et al. (2021) proposed uncertainty-aware MT evaluation by combining COMET with two simple uncertainty quantification methods, both based on model variance, namely, Monte Carlo (MC) dropout (Gal and Ghahramani, 2016) and deep ensembles (Lakshminarayanan et al., 2017). However, these two methods have two important shortcomings:
+
+- They are costly in terms of inference time (MC dropout) and training time (deep ensembles).
+
+Source: The new bill also proposes to expand the questioning power to children who are at least 14 years old...
+
+Translation: Der neue Gesetzesentwurf schlägt auch vor, die Vernehmungsbefugnis auf Kinder auszuweiten, die mindestens 14 Jahre alt sind...
+
+
+Figure 2: Aleatoric uncertainty caused by noisy references. We show a low quality reference (A) and a high quality reference (B) for an English-German translation (the translation in the example is high quality, identical to reference B). Errors in reference A are annotated in dark red; reference B has a perfect MQM score of 0 (no errors). Our two proposed methods that handle aleatoric (data) uncertainty, HTS and KL, are more uncertain when given the low-quality reference, as expected. The previously proposed MCD method (Glushkova et al., 2021) behaves in the opposite way. Full dataset statistics are shown in Figure 3.
+
+MQM: -20
+
+Das neue Gesetz schlägt auch vor das Recht auszudehnen, Kinder, welche mindestens 14 Jahre alt sind, zu befragen, aber nur auf jene, die an Aktivitäten wahrrscheinlich oder bestätigterweise teilnehmen, die dem Schutz Australiens schaden, und auf Menschen aus politisch motivierter Gewalt.
+
+
+
+MQM:0
+
+Der neue Gesetzesentwurf schlägt auch vor, die Vernehmungsbefugnis auf Kinder auszuweiten, die mindestens 14 Jahre alt sind, aber nur auf solche, die an Aktivitäten beteilig ist oder wahrscheinlich beteilig sind, die dem Schutz Australiens und der Bevölkerung vor politisch motivierter Gewalt schaden.
+
+HTS: $(\mathrm{A}) < (\mathrm{B})$
+
+KL: $(\mathrm{A}) < (\mathrm{B})$
+
+MCD: A > B
+
+- They are not able to detect or distinguish between different sources of uncertainty. For example, it is impossible to infer whether the predicted uncertainty stems from a noisy and ambiguous reference, an out-of-distribution example, or noisy annotations. More fundamentally, they are highly model-dependent and cannot distinguish between aleatoric (data) and epistemic (model) uncertainty, as illustrated in Figures 1-2.
+
+In this paper, we address the limitations above by investigating more powerful and efficient uncertainty quantification methods: direct uncertainty prediction (Jain et al., 2021), a two-step approach which uses supervision over the quality prediction errors; heteroscedastic regression, which estimates input-dependent aleatoric uncertainty and can be combined with MC dropout (Kendall and Gal, 2017); and divergence minimization, which can estimate uncertainty from annotator disagreements, when multiple annotations are available for the same example. We examine the degree to which these predictors can improve segment-level uncertainty-aware MT evaluation and target phenomena related to specific types of uncertainty: (i) aleatoric uncertainty in the case of heteroscedastic regression and divergence minimization, and (ii) epistemic uncertainty in the case of direct uncertainty prediction.
+
+We evaluate our newly proposed uncertainty estimators on 16 language pairs from the WMT20 and WMT21 metrics shared task, using two types of human annotations: direct assessments (DA) and
+
+multi-dimensional quality metric scores (MQM). The experiments show that our estimators compare favourably against model variance baselines (MC dropout and deep ensembles), while being considerably faster. We also show that we can address specific issues for MT evaluation, such as detecting potentially incorrect references and out-of-distribution examples in the data, by choosing the most suitable uncertainty predictor among our proposed methods.
+
+# 2 Related Work
+
+MT evaluation Traditional metrics for MT evaluation are based on lexical overlap, including BLEU (Papineni et al., 2002), METEOR (Lavie and Denkowski, 2009), and CHRF (Popovic, 2015). More recent metrics leverage large pretrained models, either unsupervised, such as BERTSCORE (Zhang et al., 2019), YI SI (Lo, 2019) and PRISM (Thompson and Post, 2020), or finetuned on human annotations, such as COMET (Rei et al., 2020a) and BLEURT (Sellam et al., 2020b). In recent studies it has become increasingly evident that supervised metrics exhibit higher correlations with human judgements (Mathur et al., 2020; Freitag et al., 2021a) and produce more reliable assessments of MT quality (Kocmi et al., 2021). Nonetheless, all these metrics output a single point estimate, with the exception of UA-COMET (Glushkova et al., 2021), which returns a confidence interval along with a quality estimate. Our work builds upon UA-COMET by proposing
+
+improved uncertainty quantification.
+
+Uncertainty quantification The problem of over-confident incorrect predictions affects neural models across tasks, and thus there are several works applying uncertainty quantification techniques to address this. Model variance methods such as MC Dropout (Gal and Ghahramani, 2016) and deep ensembles (Lakshminarayanan et al., 2017) have been applied on a range of tasks to estimate the total uncertainty of a model. However, these methods are computationally costly to train and apply. Malinin et al. (2019) propose to address this shortcoming with ensemble distribution distillation via prior networks (addressing the inference cost of ensembling). They further investigate the adaptation of the aforementioned method to regression problems (Malinin et al., 2020), proposing two methods to estimate Regression Prior Networks (RPN), which however require either access to out-of-distribution data or the distillation of an ensemble of regression models into an RPN.
+
+Recently, Ulmer and Cinà (2021) have shown that variance-based uncertainty estimation methods, which employ ensembling or MC dropout, can be unstable when applied to out-of-distribution data and often fail to provide accurate uncertainty estimates. Raghu et al. (2019), Hu et al. (2021), and Jain et al. (2021) corroborate these findings and propose to train a direct epistemic uncertainty predictor on the errors of the main model as a better method to estimate epistemic uncertainty. To the best of our knowledge, direct uncertainty prediction has not been examined on MT evaluation (or other NLP tasks). Contrary to epistemic uncertainty, aleatoric (data) uncertainty corresponds to the irreducible amount of prediction error(s), which is due to the noise present in the observed data. Kendall and Gal (2017) propose the use of heteroscedastic variance in the loss function. Wang et al. (2019) propose a test-time augmentation-based aleatoric uncertainty. They compare and combine it with epistemic uncertainty, and show that it provides more representative uncertainty estimates than dropout-based ones alone. Our paper takes inspiration from these techniques to estimate aleatoric noise in MT evaluation.
+
+Annotator disagreement Several approaches have been proposed to understand and model annotator bias (Cohn and Specia, 2013; Hovy and Yang, 2021) and to leverage annotator disagree
+
+ment in NLP applications (Sheng et al., 2008; Plank et al., 2014, 2016; Jamison and Gurevych, 2015; Pavlick and Kwiatkowski, 2019). Recently, soft-label multi-task learning objectives for classification tasks have been proposed by Fornaciari et al. (2021). Our Kullback-Leibler (KL) divergence minimization objective may be regarded as an extension of this approach for regression tasks, replacing (softmax) categoricals by Gaussian distributions.
+
+Uncertainty in NLP There are several works applying uncertainty quantification techniques to NLP, most commonly for (structured) classification tasks. Fomicheva et al. (2020) use MC dropout to model MT confidence, and Malinin and Gales (2020) study structured uncertainty estimation in autoregressive tasks, including MT and speech recognition. Ye et al. (2021) model uncertainty in performance prediction of NLP systems. Mielke et al. (2019) apply heteroscedastic models to assess language difficulty, whereas Friedl et al. (2021) estimate aleatoric uncertainty in scientific peer reviewing. Recently, Wang et al. (2022) focus on calibration of regression models and show that uncertainty can be useful for data augmentation. Our paper also focuses on a regression task although some of our techniques and findings can apply more broadly to these problems.
+
+# 3 Uncertainty in MT Evaluation
+
+# 3.1 MT evaluation
+
+Throughout, we denote by $s$ a sentence in a source language, by $t$ its translation into a target language, and by $\mathcal{R}$ a set of reference translations. A segment-level MT evaluation system $\mathcal{M}_{\mathrm{Q}}$ (also called a "translation quality metric") is a system that takes as input a triple $\langle s,t,\mathcal{R}\rangle$ and outputs a quality score $\hat{q} \in \mathbb{R}$ , reflecting how accurate $t$ is as a translation of $s$ .2
+
+Current state-of-the-art evaluation metrics, such as COMET (Rei et al., 2020a) or BLEURT (Sellam et al., 2020a), are trained with supervision on corpora annotated with human judgments $q^{*} \in \mathbb{R}$ , such as direct assessments (DA; Graham et al. 2013) or scores from multi-dimensional quality metric annotations (MQM; Lommel et al. 2014). This supervision encourages their predicted quality scores $\hat{q}$ to approximate the human perceived quality $q^{*}$ , in a way that generalizes to unseen data.
+
+# 3.2 Sources of uncertainty
+
+While neural-based MT evaluation systems are more accurate than traditional lexical-based metrics such as BLEU, they are less transparent and may produce unreliable scores for out-of-domain inputs or when references are noisy (Rei et al., 2020b; Freitag et al., 2021b). Our goal is to mitigate this problem by quantifying the uncertainty associated with their predicted scores. This uncertainty can come from several sources:
+
+- Aleatoric (data) uncertainty is primarily caused by noise in the data. Frequent sources of noise include inaccurate or inconsistent ground truth quality scores $q^{*}$ (usually noticeable from low inter-annotator agreement scores) and noisy reference translations $\mathcal{R}$ , which can mislead the MT evaluation system (Freitag et al., 2020).
+- Epistemic (model) uncertainty reflects lack of knowledge from the model itself. This may be caused by limited training data, out-of-distribution examples (e.g., new languages, new domains, or diverse scoring schemes), or by complex, highly non-literal, translations which may trigger weak spots in the MT evaluation model.
+
+Recently, Glushkova et al. (2021) proposed an uncertainty-aware evaluation metric (UA-COMET) by experimenting with two simple uncertainty quantification techniques, MC dropout (Gal and Ghahramani, 2016) and deep ensembles (Lakshminarayanan et al., 2017). Both techniques compute estimates based on model variance - they estimate uncertainty by running multiple versions of the system (either produced on-the-fly with stochastic dropout noise or by using separate models trained with different seeds), and then computing the mean $\hat{\mu}$ and variance $\hat{\sigma}^2$ of the predicted scores. When given a triple $\langle s,t,\mathcal{R}\rangle$ as input, instead of returning a point estimate $\hat{q}$ , UA-COMET treats the quality score as a random variable $Q$ , modeled as a Gaussian distribution $p_{Q}(q) = \mathcal{N}(q;\hat{\mu},\hat{\sigma}^{2})$ . After a calibration step, the variance parameter of the Gaussian $\hat{\sigma}^2$ is used as the uncertainty estimate.
+
+# 4 Improving Uncertainty-Aware MT Evaluation
+
+A limitation of UA-COMET is its reliance on model variance techniques that often produce poor estimates of uncertainty and conflate aleatoric and epistemic uncertainty, making it hard to accurately
+
+represent uncertainty related to out-of-distribution samples (Jain et al., 2021; Zhang et al., 2021). We therefore examine alternate methods to learn aleatoric and epistemic uncertainty directly from the available data. We assume that for each of the training scenarios and learning objectives described in the following sections, we can learn to predict the uncertainty of quality estimates $\hat{q}$ either as the noise variance $\sigma$ in the case of aleatoric uncertainty, or as the generalization error $\epsilon$ in the case of epistemic (and total) uncertainty.
+
+# 4.1 Predicting aleatoric uncertainty
+
+Rather than a property of the model, aleatoric uncertainty is a property of the data distribution and thus it can be learned as a function of the data (Kendall and Gal, 2017). It corresponds to uncertainty induced due to noise and inconsistencies. In the case of MT evaluation, we identify low quality references and inconsistent human annotations as the main sources of aleatoric uncertainty. The uncertainty associated with each data instance can vary: references have shown to be of different quality levels (Freitag et al., 2020), while the quality scores depend largely on the annotators who sometimes have high disagreement (Toral, 2020).
+
+Heteroscedasticity A common assumption in regression problems (of which MT evaluation is an example) is that the noise in the data has constant variance throughout the dataset – i.e., that the data is homoscedastic. The mean squared error loss, for example, corresponds to the maximum likelihood criterion under Gaussian noise with fixed variance. However, this is not a suitable assumption in several problems, including MT evaluation, where real data is often heteroscedastic – for example, complex sentences requiring specific background knowledge may be subject to larger annotation errors (higher disagreement among annotators) and higher chance for noisy references than simpler sentences. Therefore, the aleatoric uncertainty should be larger in those cases.
+
+Heteroscedastic regression We model aleatoric uncertainty as observation noise by training a model to predict not only a quality score for each triple, but also a variance estimate $\hat{\sigma}^2$ for this score. Under our heteroscedastic assumption, we assume that the variance is specific to each data sample and can be learned as a function of the data. We follow Le et al. (2005) and Kendall and Gal (2017) and in
+
+corporate $\hat{\sigma}^2$ as part of the training objective, while learning the MT evaluation model parameters.
+
+Formally, let $x\coloneqq \langle s,t,\mathcal{R}\rangle$ denote an input triple, as described in $\S 3$ . Our heteroscedastic uncertainty-aware MT evaluation system $\mathcal{M}_{\mathrm{Q}}^{\mathrm{HTS}}$ is a neural network that takes $x$ as input and outputs a mean score $\hat{\mu} (x)$ and a variance score $\hat{\sigma}^2 (x)$ - in practice, this is done by taking a COMET model and changing the output layer to output two scores $(\hat{\mu} (x)$ and $\log \hat{\sigma}^2 (x))$ instead of one $(\hat{q} (x))$ . This predicted mean and variance parametrize a Gaussian distribution $\hat{p}_Q(q|x;\theta) = \mathcal{N}(q;\hat{\mu} (x;\theta),\hat{\sigma}^2 (x;\theta))$ , where $\theta$ are the model parameters. Given a training set $\mathcal{D} = \{(x_1,q_1^*),\ldots ,(x_N,q_N^*)\}$ , the maximum likelihood training criterion amounts to maximize
+
+$$
+\begin{array}{l} \frac {1}{N} \sum_ {i = 1} ^ {N} \log \underbrace {\mathcal {N} \left(q _ {i} ^ {*} ; \hat {\mu} \left(x _ {i} , \theta\right) , \hat {\sigma} ^ {2} \left(x _ {i} , \theta\right)\right)} _ {p _ {Q} \left(q _ {i} ^ {*} \mid x _ {i}; \theta\right)} = \tag {1} \\ = - \frac {1}{N} \sum_ {i = 1} ^ {N} \mathcal {L} _ {\mathrm {H T S}} (\hat {\mu} (x _ {i}, \theta), \hat {\sigma} ^ {2} (x _ {i}, \theta); q _ {i} ^ {*}) + \mathrm {c o n s t .}, \\ \end{array}
+$$
+
+where $\mathcal{L}_{\mathrm{HTS}}$ denotes the heteroscedastic loss:
+
+$$
+\mathcal {L} _ {\mathrm {H T S}} (\hat {\mu}, \hat {\sigma} ^ {2}; q ^ {*}) = \frac {(q ^ {*} - \hat {\mu}) ^ {2}}{2 \hat {\sigma} ^ {2}} + \frac {1}{2} \log \hat {\sigma} ^ {2}. \tag {2}
+$$
+
+We can see that, if $\hat{\sigma}^2$ was constant and not estimated, the heteroscedastic loss $\mathcal{L}_{\mathrm{HTS}}$ would revert to a standard squared loss; however, since this variance is predicted by the model and changes with the input, the model is trained to make a trade-off: the $\hat{\sigma}^2$ term in the denominator down-weights examples where the target $q^{*}$ is assumed unreliable, decreasing the impact of highly noisy instances (a form of weighted least squares), while the log $\hat{\sigma}^2$ term penalizes the model if it overestimates the variance. We show in §5.3 how this variance can be used to detect possibly noisy references.
+
+KL divergence minimization While heteroscedastic uncertainty allows to estimate the observation noise, when we have multiple annotations for the same example we may have additional information on data uncertainty reflected in annotator disagreement. We assume that annotator disagreement in this case can be used as a proxy to data uncertainty.
+
+Similarly to the estimation of heteroscedastic variance with the $\mathcal{L}_{\mathrm{HTS}}$ objective, we assume that we can learn the variance $\hat{\sigma} (x;\theta)$ as an estimator of aleatoric uncertainty alongside the rest of
+
+the model, but now leveraging the supervision coming from the annotator disagreement - we denote this system by $\mathcal{M}_Q^{\mathrm{KL}}$ . We model the annotator scores as another Gaussian distribution $p_{Q}^{*}(q\mid x) = \mathcal{N}(q;\mu^{*}(x),\sigma^{*}(x))$ , where $\mu^{*}(x)$ is the sample mean and $\sigma^{*}(x)$ the sample variance of the annotator scores for the example $x$ , used as targets for our model predictions. We formalize this as a KL divergence objective between the target distribution $p_{Q}^{*}$ and the predicted distribution $\hat{p}_{Q}$ , which has the following closed form for Gaussian distributions:
+
+$$
+\begin{array}{l} \mathcal {L} _ {\mathrm {K L}} (\hat {\mu}, \hat {\sigma} ^ {2}; \mu^ {*}, \sigma^ {* 2}) = \mathrm {K L} (p _ {Q} ^ {*} \| \hat {p} _ {Q}) \\ = \frac {\left(\mu^ {*} - \hat {\mu}\right) ^ {2} + \sigma^ {* 2}}{2 \hat {\sigma} ^ {2}} + \frac {1}{2} \log \frac {\hat {\sigma} ^ {2}}{\sigma^ {* 2}} - \frac {1}{2}. \tag {3} \\ \end{array}
+$$
+
+Note that Eq. 3 is a generalization of Eq. 2: if we assume a fixed zero-limit variance $\sigma^{*2} \to 0$ , we recover Eq. 2 up to a constant.
+
+# 4.2 Predicting epistemic uncertainty
+
+Epistemic (model) uncertainty can be observed mainly on out-of-sample and out-of-distribution instances, and manifests as the reducible generalization error of the model – in the presence of infinite training data and suitable model and learning algorithm, epistemic uncertainty could be reduced to zero (Postels et al., 2021; Jain et al., 2021). We outline two procedures to estimate epistemic and total uncertainty, one combining MC dropout with the heteroscedastic loss (Kendall and Gal, 2017), and another which estimates uncertainty directly as the generalization error (Jain et al., 2021).
+
+Heteroscedastic MC dropout Given a way to estimate aleatoric uncertainty $\hat{\sigma}$ , e.g., using Eqs. 2 or 3, we can combine it with an estimator of epistemic uncertainty to obtain the total uncertainty over a sample. Assuming we have access to an MT evaluation model that is able to predict both a quality score $\hat{q}$ and an aleatoric uncertainty estimate $\hat{\sigma}$ such as the system $\mathcal{M}_{\mathrm{Q}}^{\mathrm{HTS}}$ described in §4.1 - we can use a stochastic strategy such as MC dropout or deep ensembles to obtain a set $\mathcal{Q} = \{\hat{q}_1,\dots ,\hat{q}_M\}$ of quality estimates and $\Sigma = \{\hat{\sigma}_1^2,\dots ,\hat{\sigma}_M^2\}$ of variance estimates. Assuming $\mathcal{Q}$ is a sample drawn from a Gaussian distribution, the sample variance can be used as an estimator of epistemic uncertainty, and the sample mean of $\Sigma$ can be used as an estimator of aleatoric uncertainty (Kendall and Gal, 2017). We can then estimate the total uncertainty
+
+over the $M$ samples as the sum of epistemic and aleatoric uncertainties:
+
+$$
+\begin{array}{l} \hat {\mathcal {U}} _ {\mathrm {t o t a l}} = \operatorname {V a r} [ \mathcal {Q} ] + \mathbb {E} [ \Sigma ] \tag {4} \\ = \underbrace {\frac {1}{M} \sum_ {j = 1} ^ {M} \hat {q} _ {j} ^ {2} - \left(\frac {1}{M} \sum_ {j = 1} ^ {M} \hat {q} _ {j}\right) ^ {2}} _ {\text {e p i s t e m i c}} + \underbrace {\frac {1}{M} \sum_ {j = 1} ^ {M} \hat {\sigma} _ {j} ^ {2}} _ {\text {a l e a t o r i c}}. \\ \end{array}
+$$
+
+For the experiments presented in §5 we use this strategy with MC dropout applied to a model trained with heteroscedastic regression.
+
+Direct uncertainty prediction An alternative is to consider the total uncertainty $\hat{\mathcal{U}}_{\mathrm{total}}$ as an approximation of the generalization error of the MT evaluation model $\mathcal{M}_{\mathrm{Q}}$ . In this case, assuming access to $\mathcal{M}_{\mathrm{Q}}$ 's predictions $\hat{q}$ and the ground truth quality scores $q^{*}$ on a new (unseen) set of samples, we could learn to predict the total uncertainty directly as the error $\epsilon$ between the model predictions $\hat{q}$ and the true scores $q^{*}$ , using the strategy recently proposed by Jain et al. (2021).
+
+As opposed to the previously described uncertainty estimation approaches, direct uncertainty prediction (DUP) is a two-step process, as we need to first obtain the model $\mathcal{M}_{\mathrm{Q}}$ that generates the predictions $\hat{q}$ that will allow us to estimate the target errors in a second stage. Hence, we need access to two distinct datasets on which two separate models have to be trained. We assume a dataset $\mathcal{D}_{\mathrm{Q}}$ where $\mathcal{M}_{\mathrm{Q}}$ is trained (we use the vanilla COMET system), and another, disjoint dataset $\mathcal{D}_{\mathrm{E}}$ where we train a second system $\mathcal{M}_{\mathrm{E}}$ to predict the uncertainty/errror of $\mathcal{M}_{\mathrm{Q}}$ 's predictions. For this purpose, we use $\mathcal{M}_{\mathrm{Q}}$ to annotate $\mathcal{D}_{\mathrm{E}}$ with quality estimates $\hat{q}$ ,and then we calculate the ground truth error $\epsilon^{*}$ as the distance to the human quality scores $q^{*}$ for each segment in $\mathcal{D}_{\mathrm{E}},\epsilon^{*} = |\hat{q} -q^{*}|$ .We use $\epsilon^{*}$ as the target to train $\mathcal{M}_{\mathrm{E}}$ given inputs $\langle s,t,\mathcal{R},\hat{q}\rangle$ .Letting $\hat{\epsilon}$ correspond to the uncertainty predicted by $\mathcal{M}_{\mathrm{E}}$ on a given input, we define $\mathcal{L}_{\mathrm{HTS}}^{\mathrm{E}}$ function for $\mathcal{M}_{\mathrm{E}}$ ..
+
+$$
+\mathcal {L} _ {\mathrm {H T S}} ^ {\mathrm {E}} (\hat {\epsilon}; \epsilon^ {*}) = \frac {(\epsilon^ {*}) ^ {2}}{2 \hat {\epsilon} ^ {2}} + \frac {1}{2} \log (\hat {\epsilon}) ^ {2}. \qquad (5)
+$$
+
+$\mathcal{L}_{\mathrm{HTS}}^{\mathrm{E}}$ is inspired by the heteroscedastic loss of Eq. 2, where the model is discouraged from predicting too high uncertainty values because of the term $\log (\hat{\epsilon})^2$ , while it will still try to predict high $\hat{\epsilon}$ values for the samples where the MT quality score is not close to the human evaluation. Therefore,
+
+this choice is akin to a two-step approach to heteroscedastic regression: one step to train the "mean" predictor and another step for training the variance predictor given the mean predictions, where the two steps are performed on different partitions of the dataset, $\mathcal{D}_{\mathrm{Q}}$ and $\mathcal{D}_{\mathrm{E}}$ . We show in Appendix F that $\mathcal{L}_{\mathrm{HTS}}^{\mathrm{E}}$ outperforms other loss functions.
+
+# 5 Experiments
+
+The main focus of our experiments is to investigate how the uncertainty estimators we explore in this paper compare to each other and against proposed variance-based methods. Our comparisons address the accuracy of uncertainty predictions on MT evaluation datasets (§5.2) as well as more specific concerns such as the performance on out-of-domain data (§5.2), the ability to detect low quality references (§5.3), and the computational costs (§5.4).
+
+# 5.1 Experimental Setup
+
+We follow Glushkova et al. (2021) and use COMET (v1.0) as the underlying architecture for our MT evaluation models, trained on the data from the WMT17-WMT19 metrics shared task (Freitag et al., 2021b). We consider two types of human judgments: direct assessments (DA) and multidimensional quality metric scores (MQM).
+
+Experiments on DA scores We evaluate our models using 5-fold cross validation on the WMT20 dataset.3 All single-step models are trained on the data from the WMT17-19 metrics shared task using the development folds (80%) for calibration. For DUP models, WMT17-19 is used to train the first step model $\mathcal{M}_{\mathrm{Q}}$ and the development folds of WMT20 are used both for training the second step of the model $\mathcal{M}_{\mathrm{E}}$ and for calibration. The data encompasses 16 language pairs (per-language results listed in Tables 2-3 in Appendix A), which we aggregate into two groups, EN-XX (out-of-English) and XX-EN (into-English). We report the balanced average across all language pairs (Avg).
+
+Experiments on MQM scores We fine-tune all models on the entire WMT20 MQM dataset, which consists of MQM annotations for English-German (EN-DE) and Chinese-English (ZH-EN). For DUP, we finetune the $\mathcal{M}_{\mathrm{E}}$ model on WMT20. For testing
+
+and calibration we use WMT21 metrics shared task dataset, which contains MQM annotations for the same language pairs, but also with an addition of English-Russian (EN-RU). We evaluate using 5-fold cross validation on the WMT21 MQM data as well, where the development folds are used for calibrating models for each language pair. We also provide the performance on WMT21 without any finetuning on MQM scores in Appendix B.
+
+Models In the experiments that follow we use as baselines the two variance-based methods proposed by Glushkova et al. (2021): a MC dropout model with 100 dropout runs (MCD) and a deep ensemble of 5 independent models (DE), as well as the fixed-variance simple baseline they proposed: $\sigma_{\mathrm{fixed}}^2 = \frac{1}{|\mathcal{D}|}\sum_{\langle s,t,\mathcal{R},q^*\rangle \in \mathcal{D}}(q^* -\hat{\mu})^2.$
+
+We compare these baselines against our models:
+
+- HTS: The heteroscedastic model $\mathcal{M}_{\mathrm{Q}}^{\mathrm{HTS}}$ trained with the loss in Eq. 2.
+- HTS+MCD: The combination of HTS with MC dropout as described in Eq. 4.
+- DUP: The direct uncertainty prediction model described in §4.2 using the $\mathcal{L}_{\mathrm{HTS}}^{\mathrm{E}}(\hat{\epsilon};\epsilon^{*})$ loss described in Eq. 5. We use a vanilla COMET model as $\mathcal{M}_{\mathrm{Q}}$ and a system with the same architecture for $\mathcal{M}_{\mathrm{E}}$ which receives as an additional feature the predicted quality score $\hat{q}$ from $\mathcal{M}_{\mathrm{Q}}$ . This extra feature is added by inserting a bottleneck layer between two feed-forward layers in the original COMET architecture (see App. C).
+- KL: The divergence minimization model $\mathcal{M}_{\mathrm{Q}}^{\mathrm{KL}}$ using the objective in Eq. 3. This model is used only for the experiments with MQM scores (Table 1), where multiple annotators for the same examples are available during training. $^4$
+
+Evaluation To compare the performance of uncertainty predictors, we report the same performance indicators as Glushkova et al. (2021): the predictive Pearson score $r(\hat{\mu},q^{*})$ (PPS), the uncertainty Pearson score $r(|q^{*} - \hat{\mu}|,\hat{\sigma})$ (UPS), the negative log-likelihood $-\log \mathcal{N}(q^{*};\hat{\mu},\hat{\sigma}^{2})$ (NLL), the expected calibration error (ECE; Naeini et al. (2015)), and the sharpness (Sha.), i.e., the average predicted variance in the test set (see Appendix D
+
+for details about these metrics). Note that we follow (Glushkova et al., 2021) in considering sharp confidence intervals desirable for all our in-domain experiments, however, for out-of-domain instances, the desired behaviour differs: we expect that the average predicted uncertainty on out-of-domain data would be higher compared to the average uncertainty observed on in-domain data. Hence higher sharpness values would be desirable in such cases (see also Figure 1 and Appendix E).
+
+These indicators assess both quality prediction accuracy (PPS), uncertainty-related accuracy (UPS) and calibration (ECE, Sha.), and the prediction and uncertainty accuracy combined in a single score (NLL). We consider UPS as our main indicator of performance, but report the other uncertainty indicators for completeness. PPS is reported as well, to assert that the performance of the quality predictions $\hat{q}$ of the MT evaluation model is not compromised. Additionally, we consider changes in average sharpness to be more indicative of the interpretability of the uncertainty predictions and the sensitivity of the model to domain and distribution shifts. We illustrate this in Figure 1.
+
+# 5.2 Comparison of uncertainty methods
+
+The results of the DA and MQM experiments are shown in Table 1. As expected, the PPS values (which do not measure uncertainty, but accuracy of the quality predictions) are similar for all methods, since they are based either on a vanilla COMET model, or on an ensemble of COMET models, with an advantage for the DE method which benefits from the ensemble effect. HTS and KL, which have modified objectives that learn the mean and the variance simultaneously, also boost PPS, but not as much as DE. We focus our analysis on the uncertainty prediction accuracy, assessed primarily by UPS and also ECE, and Sharpness indicators.
+
+For the DA experiments, we observe that our proposed methods, HTS, DUP and KL, show significantly stronger uncertainty correlation (UPS) than the baseline estimates (MCD and DE), and obtain competitive scores for ECE, Sha. and NLL without significantly compromising PPS.
+
+Enhancing $\mathcal{M}_{\mathrm{Q}}^{\mathrm{HTS}}$ with MC dropout (HTS+MCD) seems to further improve UPS and ECE, but produces less sharp uncertainty estimates and it negatively impacts the predictive accuracy. DUP's main strength relates to provision
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| WMT20 DA | σ2-fixed | - | 0.019 | 0.415 | 1.236 | 0.444 |
| MCD | 0.106 | 0.016 | 0.377 | 1.199 | 0.443 |
| DE | 0.134 | 0.019 | 0.366 | 1.156 | 0.460 |
| HTS | 0.177 | 0.015 | 0.450 | 1.201 | 0.444 |
| HTS+MCD | 0.254 | 0.013 | 0.528 | 1.167 | 0.429 |
| DUP | 0.182 | 0.014 | 0.437 | 1.190 | 0.444 |
| WMT21 MQM | σ2-fixed | - | 0.055 | 0.371 | 2.090 | 0.377 |
| MCD | 0.179 | 0.024 | 0.334 | 1.686 | 0.460 |
| DE | 0.128 | 0.051 | 0.236 | 2.631 | 0.479 |
| HTS | 0.307 | 0.041 | 0.284 | 2.264 | 0.445 |
| HTS+MCD | 0.311 | 0.037 | 0.388 | 1.614 | 0.445 |
| KL | 0.296 | 0.046 | 0.273 | 2.595 | 0.443 |
| DUP | 0.285 | 0.039 | 0.634 | 1.778 | 0.377 |
+
+Table 1: Results for segment-level DA and MQM predictions, averaged over all language pairs. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+of informative uncertainty intervals (changes in sharpness), while maintaining good performance for the other uncertainty metrics. As we can see in Figure 1, the sharpness of uncertainty predictions increases for out-of-domain data in the case of DUP and nicely captures the increased epistemic uncertainty in such cases. In contrast, we can see that variance-based epistemic uncertainty predictors are weaker in representing this domain shift and actually show the opposite behavior to the desired one, while aleatoric uncertainty (HTS) remains the same. We provide a more extended analysis of this aspect in Appendix E. Additionally, we provide the performance of the uncertainty predictors when applied to two other metrics, BLEURT (Sellam et al., 2020b) and UniTE (Wan et al., 2022) in Appendix G. We observe similar patterns, but notice that HTS approaches require access to source segments to provide meaningful uncertainty predictions.
+
+The findings on DA data are further supported by the MQM results especially for UPS, and we can see that the models achieve good performance for EN-RU, which is not available in the WMT20 MQM data used for fine-tuning (see Appendix B). We also see that the KL model, despite using significantly less training data (see §5.1), achieves competitive results and even outperforms other metrics for EN-DE.
+
+# 5.3 Identification of noisy references
+
+As mentioned in §3.2, low quality references are a primary source of aleatoric uncertainty. Thus, we expect the uncertainty predictors that model aleatoric uncertainty (HTS and KL) to be more
+
+
+Figure 3: Percentage of correctly recognized references with higher quality ( $r_{\mathrm{good}}$ versus $r_{\mathrm{bad}}$ ) by different uncertainty predictors on the EN-DE dataset.
+
+indicative of erroneous references compared to the other uncertainty predictors. To verify this hypothesis, we conduct an experiment on the WMT21 MQM EN-DE dataset, which includes 4 references, each annotated with MQM scores by a human annotator (Freitag et al., 2021b). For each $\langle s,t\rangle$ pair in the test split, we select the best reference $r_{\mathrm{good}}$ and the worst reference $r_{\mathrm{bad}}$ based on the respective MQM scores. We retain only the $\langle s,t,\{r_{\mathrm{good}},r_{\mathrm{bad}}\} \rangle$ for which $|\mathrm{MQM}(r_{\mathrm{good}}) - \mathrm{MQM}(r_{\mathrm{bad}})| > = 10$ , so that there is a considerable quality difference between the references.6 We then apply the uncertainty predictors on the selected triples $\langle s,t,r_{\mathrm{good}}\rangle$ and $\langle s,t,r_{\mathrm{bad}}\rangle$ and obtain the predicted uncertainties, as shown in Figure 2. For each $\langle s,t\rangle$ pair, we check which reference leads to the lowest predicted uncertainty and compute how often that reference coincides with $r_{\mathrm{good}}$ . In Figure 3, we can see that all the HTS, HTS+MCD and the KL predictors are much more successful in choosing the correct reference compared to MCD, DE and DUP. This confirms the hypothesis that HTS and KL are more effective at capturing aleatoric uncertainty. Additionally, it is interesting to note that the combination of MC dropout with heteroscedastic loss provides a small boost to the accuracy of distinguishing the noisy reference.
+
+# 5.4 Computational cost
+
+We now turn to the computational cost associated with the different uncertainty quantification methods, both in terms of training and inference runtime. In Figure 4, we present the inference and training times for each of the models (we used the same maximum number of epochs for each model). The
+
+
+Figure 4: Combined training, fine-tuning and inference times for the experiments reported in Table 1. All experiments were performed on a server with 4 Quadro RTX 6000 (24GB), 12 Intel Xeon Silver 4214@2.20GHz CPUs, and 256 Gb of RAM; time calculated for training/inference on a single GPU.
+
+large inference times for MCD and HTS+MCD stem from the need to perform 100 runs (the optimal number according to Glushkova et al. (2021)); for DE, 5 models are ensembled, increasing training and inference costs 5-fold (for training details see Table 6 in Appendix C). In contrast, HTS, KL, and DUP have much lower costs (with slightly higher costs for DUP due to the need to train/run a second system) without performance compromises.
+
+# 6 Conclusions
+
+We assessed the potential of different uncertainty predictors to capture different sources of uncertainty in MT evaluation. We demonstrated that methods modeling heteroscedasticity can detect noisy references as a source of aleatoric uncertainty, and that the direct epistemic prediction method reflects well the increased epistemic uncertainty under a domain shift. Besides providing more informative uncertainty estimates than MC dropout and deep ensemble methods, our proposed predictors are also computationally cheaper.
+
+Overall, our work provides insight about which uncertainty predictors to choose for MT evaluation depending on the uncertainty source(s) to be addressed. The proposed uncertainty predictors that are able to target specific types of uncertainty are the first step towards mitigating the sources of such uncertainty, i.e. removing noisy instances from training to reduce aleatoric uncertainty, or identifying informative instances that would allow adapting to a new domain to reduce epistemic uncertainty. In future work, we are planning to further explore their properties and potential in improving MT and
+
+MT evaluation performance.
+
+# Acknowledgements
+
+This work was supported by the European Research Council (ERC StG DeepSPIN 758969), by EU's Horizon Europe Research and Innovation Actions (UTTER, contract 101070631), by P2020 project MAIA (LISBOA-01-0247-FEDER045909), and Fundação para a Ciência e Tecnologia through contract UIDB/50008/2020.
+
+# Limitations
+
+Our work addresses an important limitation of existing MT evaluation metrics – the absence of reliable uncertainty estimates for their predictions and their inability to distinguish sources of uncertainty. However, our proposed approach has its own limitations as well. First, the scope of our work is limited by the availability of resources with human quality annotations covering multiple languages. Specifically, we are limited to the domains and language pairs addressed in the WMT metrics tasks (2017–2021) whose human assessments consist of DAs and MQM annotations. While these datasets include both high and low resource languages, most WMT datasets cover language pairs from or to English. While certainly experimenting with more language pairs and domains in future work might provide additional insights, the WMT datasets used in our paper encompass 16 language pairs for testing and 24 for training, which still provides valuable information of variability across languages. Second, the amount of sentences scored by more than one human annotator is scarce, and for this reason the experiments with the KL objective are limited to a relatively small scale, which prevents a thorough comparison with the other uncertainty quantification methods. Third, while the uncertainty-related training objectives we propose are fully general and can be applied to any supervised neural metric, we only experimented with COMET in this paper, due to limited computational resources. Experimenting with other base metrics to see if they exhibit the same patterns is an interesting topic for future research. Finally, our choice of uncertainty quantification techniques was guided by the desire to prioritize scalable and efficient methods that are applicable to different metrics and fit the MT evaluation task. Overall, we picked 6 different techniques (MCD, DE, HTS, HTS+MCD, KL, DUP) and left out other uncertainty quantifi-
+
+cation methods with less favorable efficiency or scalability properties.
+
+# References
+
+Chantal Amrhein and Rico Sennrich. 2022. Identifying Weaknesses in Machine Translation Metrics Through Minimum Bayes Risk Decoding: A Case Study for COMET. In Proceedings of the 2nd Conference of the Asia-Pacific Chapter of the Association for Computational Linguistics and the 12th International Joint Conference on Natural Language Processing, Online. Association for Computational Linguistics.
+Zewen Chi, Li Dong, Furu Wei, Nan Yang, Saksham Singhal, Wenhui Wang, Xia Song, Xian-Ling Mao, He-Yan Huang, and Ming Zhou. 2021. Infoxlm: An information-theoretic framework for cross-lingual language model pre-training. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 3576-3588.
+Hyung Won Chung, Thibault Fevry, Henry Tsai, Melvin Johnson, and Sebastian Ruder. 2021. Rethinking embedding coupling in pre-trained language models. In International Conference on Learning Representations.
+Trevor Cohn and Lucia Specia. 2013. Modelling annotator bias with multi-task gaussian processes: An application to machine translation quality estimation. In Proceedings of the 51st Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 32-42.
+Marina Fomicheva, Shuo Sun, Lisa Yankovskaya, Frédéric Blain, Francisco Guzmán, Mark Fishel, Nikolaos Aletras, Vishrav Chaudhary, and Lucia Specia. 2020. Unsupervised quality estimation for neural machine translation. Transactions of the Association for Computational Linguistics, 8:539-555.
+Tommaso Fornaciari, Alexandra Uma, Silviu Paun, Barbara Plank, Dirk Hovy, and Massimo Poesio. 2021. Beyond black & white: Leveraging annotator disagreement via soft-label multi-task learning. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2591-2597, Online. Association for Computational Linguistics.
+Markus Freitag, George Foster, David Grangier, Viresh Ratnakar, Qijun Tan, and Wolfgang Macherey. 2021a. Experts, errors, and context: A large-scale study of human evaluation for machine translation. Transactions of the Association for Computational Linguistics, 9:1460-1474.
+Markus Freitag, David Grangier, and Isaac Caswell. 2020. BLEU might be guilty but references are not innocent. In Proceedings of the 2020 Conference
+
+on Empirical Methods in Natural Language Processing (EMNLP), pages 61-71, Online. Association for Computational Linguistics.
+Markus Freitag, Ricardo Rei, Nitika Mathur, Chi-kiu Lo, Craig Stewart, George Foster, Alon Lavie, and Ondrej Bojar. 2021b. Results of the WMT21 metrics shared task: Evaluating metrics with expert-based human evaluations on TED and news domain. In Proceedings of the Sixth Conference on Machine Translation, pages 733-774, Online. Association for Computational Linguistics.
+Korbinian Friedl, Georgios Rizos, Lukas Stappen, Medina Hasan, Lucia Specia, Thomas Hain, and Björn Schuller. 2021. Uncertainty aware review hallucination for science article classification. In *Findings of the Association for Computational Linguistics: ACLIJCNLP* 2021, pages 5004–5009, Online. Association for Computational Linguistics.
+Yarin Gal and Zoubin Ghahramani. 2016. Dropout as a bayesian approximation: Representing model uncertainty in deep learning. In international conference on machine learning, pages 1050-1059. PMLR.
+Taisiya Glushkova, Chrysovla Zerva, Ricardo Rei, and Andre F. T. Martins. 2021. Uncertainty-aware machine translation evaluation. In *Findings of the Association for Computational Linguistics: EMNLP* 2021, pages 3920-3938, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Yvette Graham, Timothy Baldwin, Alistair Moffat, and Justin Zobel. 2013. Continuous measurement scales in human evaluation of machine translation. In Proceedings of the 7th Linguistic Annotation Workshop and Interoperability with Discourse, pages 33-41, Sofia, Bulgaria. Association for Computational Linguistics.
+Dirk Hovy and Diyi Yang. 2021. The importance of modeling social factors of language: Theory and practice. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 588-602.
+Shi Hu, Nicola Pezzotti, and Max Welling. 2021. Learning to predict error for mri reconstruction. In International Conference on Medical Image Computing and Computer-Assisted Intervention, pages 604-613. Springer.
+Moksh Jain, Salem Lahlou, Hadi Nekoei, Victor Butoi, Paul Bertin, Jarrid Rector-Brooks, Maksym Korablyov, and Yoshua Bengio. 2021. Deup: Direct epistemic uncertainty prediction. arXiv preprint arXiv:2102.08501.
+Emily Jamison and Iryna Gurevych. 2015. Noise or additional information? leveraging crowdsourced annotation item agreement for natural language tasks. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 291-297.
+
+Alex Kendall and Yarin Gal. 2017. What uncertainties do we need in bayesian deep learning for computer vision? In NIPS.
+Fabio Kepler, Jonay Trénous, Marcos Treviso, Miguel Vera, and André F. T. Martins. 2019. OpenKiwi: An open source framework for quality estimation. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics: System Demonstrations, pages 117-122, Florence, Italy. Association for Computational Linguistics.
+Tom Kocmi, Christian Federmann, Roman Grundkiewicz, Marcin Junczys-Dowmunt, Hitokazu Matsushita, and Arul Menezes. 2021. To ship or not to ship: An extensive evaluation of automatic metrics for machine translation. In Proceedings of the Sixth Conference on Machine Translation, pages 478-494, Online. Association for Computational Linguistics.
+Volodymyr Kuleshov, Nathan Fenner, and Stefano Ermon. 2018. Accurate uncertainties for deep learning using calibrated regression. In Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research, pages 2796-2804. PMLR.
+Balaji Lakshminarayanan, Alexander Pritzel, and Charles Blundell. 2017. Simple and scalable predictive uncertainty estimation using deep ensembles. In Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc.
+Alon Lavie and Michael Denkowski. 2009. The Meteor metric for automatic evaluation of Machine Translation. *Machine Translation*, 23:105-115.
+Quoc V. Le, Alex J. Smola, and Stephane Canu. 2005. Heteroscedastic gaussian process regression. In Proceedings of the 22nd International Conference on Machine Learning, ICML '05, page 489-496, New York, NY, USA. Association for Computing Machinery.
+Chi-kiu Lo. 2019. YiSi - a unified semantic MT quality evaluation and estimation metric for languages with different levels of available resources. In Proceedings of the Fourth Conference on Machine Translation (Volume 2: Shared Task Papers, Day 1), pages 507-513, Florence, Italy. Association for Computational Linguistics.
+Arle Lommel, Aljoscha Burchardt, and Hans Uszkoreit. 2014. Multidimensional quality metrics (MQM): A framework for declaring and describing translation quality metrics. Tradumatica: technologies de la traduccio, 0:455-463.
+Andrey Malinin, Sergey Chervontsev, Ivan Provilkov, and Mark Gales. 2020. Regression prior networks. arXiv preprint arXiv:2006.11590.
+Andrey Malinin and Mark Gales. 2020. Uncertainty estimation in autoregressive structured prediction. arXiv preprint arXiv:2002.07650.
+
+Andrey Malinin, Bruno Mlodozeniec, and Mark Gales. 2019. Ensemble distribution distillation. In International Conference on Learning Representations.
+Nitika Mathur, Johnny Wei, Markus Freitag, Qingsong Ma, and Ondrej Bojar. 2020. Results of the WMT20 metrics shared task. In Proceedings of the Fifth Conference on Machine Translation, pages 688-725, Online. Association for Computational Linguistics.
+Sabrina J. Mielke, Ryan Cotterell, Kyle Gorman, Brian Roark, and Jason Eisner. 2019. What kind of language is hard to language-model? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4975-4989, Florence, Italy. Association for Computational Linguistics.
+Mahdi Pakdaman Naeini, Gregory F. Cooper, and Milos Hauskrecht. 2015. Obtaining well calibrated probabilities using bayesian binning. In Proceedings of the Twenty-Ninth AAAI Conference on Artificial Intelligence, AAAI'15, page 2901-2907. AAAI Press.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei Jing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th Annual Meeting of the Association for Computational Linguistics, pages 311-318, Philadelphia, Pennsylvania, USA. Association for Computational Linguistics.
+Ellie Pavlick and Tom Kwiatkowski. 2019. Inherent disagreements in human textual inferences. Transactions of the Association for Computational Linguistics, 7:677-694.
+Barbara Plank, Dirk Hovy, and Anders Søgaard. 2014. Learning part-of-speech taggers with inter-annotator agreement loss. In Proceedings of the 14th Conference of the European Chapter of the Association for Computational Linguistics, pages 742-751.
+Barbara Plank, Anders Søgaard, and Yoav Goldberg. 2016. Multilingual part-of-speech tagging with bidirectional long short-term memory models and auxiliary loss. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 412-418, Berlin, Germany. Association for Computational Linguistics.
+Maja Popovic. 2015. chrF: character n-gram F-score for automatic MT evaluation. In Proceedings of the Tenth Workshop on Statistical Machine Translation, pages 392-395, Lisbon, Portugal. Association for Computational Linguistics.
+Janis Postels, Mattia Segu, Tao Sun, Luc Van Gool, Fisher Yu, and Federico Tombari. 2021. On the practicality of deterministic epistemic uncertainty. arXiv preprint arXiv:2107.00649.
+Maithra Raghu, Katy Blumer, Rory Sayres, Ziad Obermeyer, Bobby Kleinberg, Sendhil Mullainathan, and Jon Kleinberg. 2019. Direct uncertainty prediction for medical second opinions. In International Conference on Machine Learning, pages 5281-5290. PMLR.
+
+Tharindu Ranasinghe, Constantin Orasan, and Ruslan Mitkov. 2020. TransQuest: Translation quality estimation with cross-lingual transformers. In Proceedings of the 28th International Conference on Computational Linguistics, pages 5070-5081, Barcelona, Spain (Online). International Committee on Computational Linguistics.
+Ricardo Rei, Craig Stewart, Ana C Farinha, and Alon Lavie. 2020a. COMET: A neural framework for MT evaluation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2685-2702, Online. Association for Computational Linguistics.
+Ricardo Rei, Craig Stewart, Ana C Farinha, and Alon Lavie. 2020b. Unbabel's participation in the WMT20 metrics shared task. In Proceedings of the Fifth Conference on Machine Translation, pages 911-920, Online. Association for Computational Linguistics.
+Thibault Sellam, Dipanjan Das, and Ankur Parikh. 2020a. BLEURT: Learning robust metrics for text generation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7881-7892, Online. Association for Computational Linguistics.
+Thibault Sellam, Amy Pu, Hyung Won Chung, Sebastian Gehrmann, Qijun Tan, Markus Freitag, Dipanjan Das, and Ankur Parikh. 2020b. Learning to evaluate translation beyond English: BLEURT submissions to the WMT metrics 2020 shared task. In Proceedings of the Fifth Conference on Machine Translation, pages 921-927, Online. Association for Computational Linguistics.
+Victor S Sheng, Foster Provost, and Panagiotis G Ipeirotis. 2008. Get another label? improving data quality and data mining using multiple, noisy labelers. In Proceedings of the 14th ACM SIGKDD international conference on Knowledge discovery and data mining, pages 614-622.
+Brian Thompson and Matt Post. 2020. Automatic machine translation evaluation in many languages via zero-shot paraphrasing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 90-121, Online. Association for Computational Linguistics.
+Antonio Toral. 2020. Reassessing claims of human parity and super-human performance in machine translation at WMT 2019. In Proceedings of the 22nd Annual Conference of the European Association for Machine Translation, pages 185-194, Lisboa, Portugal. European Association for Machine Translation.
+Dennis Ulmer and Giovanni Cina. 2021. Know your limits: Uncertainty estimation with relu classifiers fails at reliable ood detection. In Proceedings of the Thirty-Seventh Conference on Uncertainty in Artificial Intelligence, volume 161 of Proceedings of Machine Learning Research, pages 1766-1776. PMLR.
+
+Yu Wan, Dayiheng Liu, Baosong Yang, Haibo Zhang, Boxing Chen, Derek Wong, and Lidia Chao. 2022. Unite: Unified translation evaluation. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 8117-8127.
+Guotai Wang, Wenqi Li, Michael Aertsen, Jan Deprest, Sébastien Ourselin, and Tom Vercauteren. 2019. Aleatoric uncertainty estimation with test-time augmentation for medical image segmentation with convolutional neural networks. Neurocomputing, 338:34-45.
+Yuxia Wang, Daniel Beck, Timothy Baldwin, and Karin Verspoor. 2022. Uncertainty estimation and reduction of pre-trained models for text regression. Transactions of the Association for Computational Linguistics, 10:680-696.
+Zihuiwen Ye, Pengfei Liu, Jinlan Fu, and Graham Neubig. 2021. Towards more fine-grained and reliable NLP performance prediction. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 3703-3714, Online. Association for Computational Linguistics.
+Jing Zhang, Yuchao Dai, Mochu Xiang, Deng-Ping Fan, Peyman Moghadam, Mingyi He, Christian Walder, Kaihao Zhang, Mehrtash Harandi, and Nick Barnes. 2021. Dense uncertainty estimation. arXiv preprint arXiv:2110.06427.
+Tianyi Zhang, Varsha Kishore, Felix Wu, Kilian Q Weinberger, and Yoav Artzi. 2019. Bertscore: Evaluating text generation with bert. In International Conference on Learning Representations.
+
+# A DA experiments
+
+Results per language pair are presented in Tables 2 and 3.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-CS | σ2-fixed | - | 0.005 | 0.408 | 1.019 | 0.699 |
| MCD | 0.149 | 0.012 | 0.258 | 0.847 | 0.692 |
| DE | 0.125 | 0.010 | 0.255 | 0.825 | 0.734 |
| HTS | 0.105 | 0.003 | 0.456 | 1.025 | 0.699 |
| HTS+MCD | 0.335 | 0.008 | 0.388 | 0.880 | 0.676 |
| DUP | 0.146 | 0.003 | 0.419 | 1.010 | 0.699 |
| EN-DE | σ2-fixed | - | 0.032 | 0.172 | 1.106 | 0.586 |
| MCD | 0.284 | 0.013 | 0.260 | 0.916 | 0.582 |
| DE | 0.209 | 0.025 | 0.198 | 0.949 | 0.616 |
| HTS | 0.231 | 0.022 | 0.243 | 1.016 | 0.586 |
| HTS+MCD | 0.386 | 0.004 | 0.369 | 0.924 | 0.612 |
| DUP | 0.232 | 0.022 | 0.190 | 1.028 | 0.586 |
| EN-JA | σ2-fixed | - | 0.011 | 0.186 | 0.714 | 0.636 |
| MCD | 0.236 | 0.005 | 0.225 | 0.697 | 0.638 |
| DE | 0.140 | 0.010 | 0.179 | 0.657 | 0.661 |
| HTS | 0.184 | 0.007 | 0.218 | 0.691 | 0.636 |
| HTS+MCD | 0.249 | 0.003 | 0.520 | 1.048 | 0.669 |
| DUP | 0.220 | 0.005 | 0.201 | 0.679 | 0.636 |
| EN-PL | σ2-fixed | - | 0.010 | 0.410 | 1.090 | 0.609 |
| MCD | 0.167 | 0.010 | 0.326 | 0.947 | 0.610 |
| DE | 0.129 | 0.011 | 0.315 | 0.960 | 0.645 |
| HTS | 0.103 | 0.008 | 0.436 | 1.095 | 0.609 |
| HTS+MCD | 0.189 | 0.004 | 0.397 | 0.969 | 0.631 |
| DUP | 0.112 | 0.004 | 0.431 | 1.094 | 0.609 |
| EN-RU | σ2-fixed | - | 0.018 | 0.287 | 0.989 | 0.534 |
| MCD | 0.200 | 0.012 | 0.307 | 0.943 | 0.538 |
| DE | 0.146 | 0.016 | 0.263 | 0.898 | 0.570 |
| HTS | 0.156 | 0.012 | 0.321 | 1.006 | 0.534 |
| HTS+MCD | 0.370 | 0.017 | 0.637 | 1.050 | 0.497 |
| DUP | 0.154 | 0.009 | 0.305 | 0.991 | 0.534 |
| EN-TA | σ2-fixed | - | 0.017 | 0.356 | 1.077 | 0.661 |
| MCD | 0.077 | 0.004 | 0.406 | 1.035 | 0.658 |
| DE | 0.111 | 0.010 | 0.361 | 1.030 | 0.676 |
| HTS | 0.250 | 0.009 | 0.435 | 1.050 | 0.661 |
| HTS+MCD | 0.231 | 0.038 | 0.921 | 1.223 | 0.617 |
| DUP | 0.252 | 0.009 | 0.385 | 1.032 | 0.661 |
| EN-ZH | σ2-fixed | - | 0.017 | 0.173 | 1.016 | 0.325 |
| MCD | 0.083 | 0.018 | 0.152 | 1.367 | 0.330 |
| DE | 0.560 | 0.021 | 0.152 | 0.813 | 0.327 |
| HTS | 0.728 | 0.003 | 0.273 | 0.657 | 0.325 |
| HTS+MCD | 0.504 | 0.020 | 0.380 | 0.865 | 0.562 |
| DUP | 0.722 | 0.003 | 0.268 | 0.650 | 0.325 |
| EN-XX | σ2-fixed | - | 0.015 | 0.288 | 1.000 | 0.566 |
| MCD | 0.163 | 0.011 | 0.265 | 0.984 | 0.566 |
| DE | 0.223 | 0.015 | 0.240 | 0.864 | 0.591 |
| HTS | 0.272 | 0.008 | 0.344 | 0.919 | 0.566 |
| HTS+MCD | 0.323 | 0.017 | 0.516 | 0.994 | 0.609 |
| DUP | 0.285 | 0.007 | 0.320 | 0.910 | 0.566 |
+
+# B MQM experiments
+
+We provide extended results for each language pair in the MQM 2021 test set in Table 4.
+
+We also present results without fine-tuning on the MQM data in Table 5, to facilitate comparisons. For these experiments we use the models trained on
+
+Table 2: Results for segment-level DA prediction for En-Xx LPs. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| CS-EN | σ2-fixed | - | 0.026 | 0.509 | 1.422 | 0.216 |
| MCD | 0.099 | 0.012 | 0.462 | 1.319 | 0.215 |
| DE | 0.134 | 0.019 | 0.366 | 1.156 | 0.460 |
| HTS | 0.077 | 0.024 | 0.518 | 1.432 | 0.216 |
| HTS+MCD | 0.229 | 0.006 | 0.502 | 1.276 | 0.195 |
| DUP | 0.082 | 0.024 | 0.516 | 1.418 | 0.216 |
| DE-EN | σ2-fixed | - | 0.025 | 0.403 | 1.398 | 0.573 |
| MCD | 0.044 | 0.030 | 0.312 | 1.343 | 0.568 |
| DE | 0.056 | 0.030 | 0.321 | 1.374 | 0.574 |
| HTS | 0.099 | 0.024 | 0.425 | 1.389 | 0.573 |
| HTS+MCD | 0.148 | 0.014 | 0.463 | 1.107 | 0.563 |
| DUP | 0.100 | 0.023 | 0.432 | 1.382 | 0.573 |
| JA-EN | σ2-fixed | - | 0.020 | 0.494 | 1.344 | 0.348 |
| MCD | 0.064 | 0.008 | 0.532 | 1.280 | 0.349 |
| DE | 0.079 | 0.012 | 0.502 | 1.305 | 0.360 |
| HTS | 0.145 | 0.015 | 0.534 | 1.351 | 0.348 |
| HTS+MCD | 0.215 | 0.007 | 0.611 | 1.322 | 0.339 |
| DUP | 0.129 | 0.016 | 0.513 | 1.333 | 0.348 |
| KM-EN | σ2-fixed | - | 0.007 | 0.618 | 1.246 | 0.452 |
| MCD | 0.012 | 0.005 | 0.663 | 1.235 | 0.453 |
| DE | 0.067 | 0.003 | 0.631 | 1.226 | 0.464 |
| HTS | 0.147 | 0.004 | 0.661 | 1.255 | 0.452 |
| HTS+MCD | 0.143 | 0.015 | 0.836 | 1.263 | 0.452 |
| DUP | 0.144 | 0.004 | 0.638 | 1.239 | 0.452 |
| PL-EN | σ2-fixed | - | 0.027 | 0.586 | 1.518 | 0.264 |
| MCD | 0.063 | 0.029 | 0.472 | 1.450 | 0.265 |
| DE | 0.029 | 0.029 | 0.500 | 1.490 | 0.271 |
| HTS | 0.045 | 0.025 | 0.609 | 1.530 | 0.264 |
| HTS+MCD | 0.139 | 0.008 | 0.502 | 1.424 | 0.268 |
| DUP | 0.048 | 0.025 | 0.604 | 1.519 | 0.264 |
| PS-EN | σ2-fixed | - | 0.005 | 0.735 | 1.319 | 0.325 |
| MCD | 0.028 | 0.006 | 0.740 | 1.291 | 0.327 |
| DE | 0.040 | 0.004 | 0.732 | 1.295 | 0.330 |
| HTS | 0.110 | 0.005 | 0.735 | 1.315 | 0.325 |
| HTS+MCD | 0.111 | 0.013 | 0.849 | 1.315 | 0.297 |
| DUP | 0.097 | 0.005 | 0.732 | 1.317 | 0.325 |
| RU-EN | σ2-fixed | - | 0.031 | 0.454 | 1.574 | 0.288 |
| MCD | 0.058 | 0.033 | 0.373 | 1.528 | 0.281 |
| DE | 0.056 | 0.034 | 0.401 | 1.526 | 0.300 |
| HTS | 0.087 | 0.030 | 0.464 | 1.575 | 0.288 |
| HTS+MCD | 0.161 | 0.013 | 0.493 | 1.520 | 0.209 |
| DUP | 0.073 | 0.029 | 0.467 | 1.570 | 0.288 |
| TA-EN | σ2-fixed | - | 0.028 | 0.588 | 1.416 | 0.346 |
| MCD | 0.047 | 0.022 | 0.567 | 1.357 | 0.346 |
| DE | 0.058 | 0.024 | 0.585 | 1.410 | 0.357 |
| HTS | 0.081 | 0.023 | 0.577 | 1.468 | 0.346 |
| HTS+MCD | 0.250 | 0.016 | 0.642 | 1.300 | 0.284 |
| DUP | 0.079 | 0.025 | 0.602 | 1.420 | 0.346 |
| ZH-EN | σ2-fixed | - | 0.021 | 0.518 | 1.510 | 0.303 |
| MCD | 0.051 | 0.020 | 0.447 | 1.458 | 0.302 |
| DE | 0.054 | 0.022 | 0.451 | 1.481 | 0.310 |
| HTS | 0.082 | 0.020 | 0.533 | 1.508 | 0.303 |
| HTS+MCD | 0.186 | 0.006 | 0.504 | 1.377 | 0.278 |
| DUP | 0.089 | 0.020 | 0.523 | 1.502 | 0.303 |
| XX-EN | σ2-fixed | - | 0.023 | 0.529 | 1.448 | 0.334 |
| MCD | 0.055 | 0.020 | 0.477 | 1.392 | 0.332 |
| DE | 0.053 | 0.022 | 0.480 | 1.418 | 0.342 |
| HTS | 0.090 | 0.021 | 0.546 | 1.455 | 0.334 |
| HTS+MCD | 0.176 | 0.011 | 0.600 | 1.323 | 0.276 |
| DUP | 0.089 | 0.021 | 0.542 | 1.442 | 0.334 |
+
+Table 3: Results for segment-level DA prediction for Xx-En LPs. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+the WMT DA data (performance for these models is also reported in Tables 2 and 3). We can see
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-DE | σ2-fixed | — | 0.053 | 0.228 | 2.543 | 0.342 |
| MCD | 0.132 | 0.026 | 0.228 | 1.984 | 0.391 |
| DE | 0.075 | 0.057 | 0.155 | 2.911 | 0.422 |
| HTS | 0.236 | 0.029 | 0.192 | 2.274 | 0.370 |
| HTS+MCD | 0.232 | 0.025 | 0.280 | 1.841 | 0.365 |
| KL | 0.251 | 0.052 | 0.168 | 2.641 | 0.391 |
| DUP | 0.186 | 0.051 | 0.273 | 2.215 | 0.342 |
| ZH-EN | σ2-fixed | — | 0.058 | 0.516 | 1.611 | 0.439 |
| MCD | 0.253 | 0.009 | 0.500 | 1.219 | 0.590 |
| DE | 0.157 | 0.045 | 0.420 | 1.381 | 0.601 |
| HTS | 0.365 | 0.036 | 0.514 | 1.338 | 0.564 |
| HTS+MCD | 0.380 | 0.035 | 0.566 | 1.248 | 0.570 |
| KL | 0.348 | 0.037 | 0.515 | 1.353 | 0.547 |
| DUP | 0.386 | 0.039 | 0.949 | 1.419 | 0.439 |
| EN-RU | σ2-fixed | — | 0.053 | 0.338 | 2.217 | 0.340 |
| MCD | 0.136 | 0.039 | 0.243 | 1.944 | 0.376 |
| DE | 0.144 | 0.052 | 0.100 | 3.803 | 0.392 |
| HTS | 0.308 | 0.059 | 0.104 | 3.317 | 0.377 |
| HTS+MCD | 0.304 | 0.049 | 0.285 | 1.822 | 0.375 |
| KL | 0.279 | 0.050 | 0.095 | 3.976 | 0.372 |
| DUP | 0.260 | 0.029 | 0.608 | 1.783 | 0.340 |
| AVG | σ2-fixed | — | 0.055 | 0.371 | 2.090 | 0.377 |
| MCD | 0.179 | 0.024 | 0.334 | 1.686 | 0.460 |
| DE | 0.128 | 0.051 | 0.236 | 2.631 | 0.479 |
| HTS | 0.307 | 0.041 | 0.284 | 2.264 | 0.445 |
| HTS+MCD | 0.311 | 0.037 | 0.388 | 1.614 | 0.445 |
| KL | 0.296 | 0.046 | 0.273 | 2.595 | 0.443 |
| DUP | 0.285 | 0.039 | 0.634 | 1.778 | 0.377 |
+
+that without further finetuning on MQM scores all models with the exception of the ones based on variance (MCD and DE) have a significant drop in performance.
+
+Table 4: Results for segment-level MQM predictions with fine-tuning on MQM 2020 data. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-DE | MCD | 0.134 | 0.069 | 1.019 | 0.577 | 0.295 |
| DE | 0.104 | 0.021 | 1.03 | 0.644 | 0.332 |
| HTS | 0.094 | 0.039 | 0.274 | 2.567 | 0.326 |
| HTS + MCD | 0.126 | 0.021 | 0.356 | 1.502 | 0.291 |
| DUP | 0.038 | 0.054 | 0.241 | 2.248 | 0.302 |
| ZH-EN | MCD | 0.115 | 0.081 | 1.321 | 0.956 | 0.441 |
| DE | 0.14 | 0.025 | 1.143 | 0.911 | 0.457 |
| HTS | 0.082 | 0.013 | 0.595 | 1.615 | 0.436 |
| HTS + MCD | -0.006 | 0.013 | 0.637 | 1.42 | 0.433 |
| DUP | 0.17 | 0.05 | 0.469 | 1.814 | 0.434 |
| EN-RU | MCD | 0.14 | 0.069 | 1.242 | 0.563 | 0.306 |
| DE | 0.117 | 0.078 | 1.332 | 0.684 | 0.318 |
| HTS | 0.134 | 2.035 | 0.306 | 0.021 | 0.337 |
| HTS + MCD | -0.042 | 0.016 | 0.459 | 1.492 | 0.333 |
| DUP | 0.139 | 0.045 | 0.35 | 2.238 | 0.290 |
| AVG | MCD | 0.356 | 0.129 | 0.722 | 0.074 | 1.215 |
| DE | 0.377 | 0.123 | 0.763 | 0.042 | 1.179 |
| HTS | 0.289 | 0.079 | 0.012 | 1.34 | 0.341 |
| HTS + MCD | 0.286 | -0.017 | 1.076 | 0.011 | 0.41 |
| DUP | 0.272 | 0.115 | 1.489 | 0.035 | 0.306 |
+
+Table 5: Results for segment-level MQM prediction without fine-tuning. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+# C Model implementation and parameters
+
+Table 6 shows the hyperparameters used to train the following uncertainty prediction models: MCD, DE, HTS, KL and DUP. For deep ensembles we trained 4 models with different seeds and as a fifth model we used the wmt-comet-da available at https://github.com/Unbabel/COMET (in the table we refer to it as Vanilla COMET).
+
+# D Performance indicators
+
+We briefly describe below each of the metrics reported for the experiments of this paper, provide the formulas for each one and the motivation for using them. For all described metrics we assume access to a test set $\mathcal{D} = \{\langle s_j,t_j,\mathcal{R}_j,q_j^*\rangle \}_{j = 1}^{|\mathcal{D}|}$ , consisting of samples paired with their ground truth quality scores.
+
+Calibration Error To estimate how well-calibrated the methods are we compute expected calibration error (ECE; Naeini et al. 2015; Kuleshov et al. 2018), which is defined as:
+
+$$
+\mathrm {E C E} = \frac {1}{M} \sum_ {b = 1} ^ {M} | \operatorname {a c c} \left(\gamma_ {b}\right) - \gamma_ {b} |, \tag {6}
+$$
+
+where each $b$ is a bin representing a confidence level $\gamma_{b}$ , and $\mathrm{acc}(\gamma_b)$ is the fraction of times the ground truth $q^{*}$ falls inside the confidence interval $I(\gamma_b)$ :
+
+$$
+\operatorname {a c c} \left(\gamma_ {b}\right) = \frac {1}{| \mathcal {D} |} \sum_ {\langle s, t, \mathcal {R}, q ^ {*} \rangle \in \mathcal {D}} \mathbb {1} \left(q ^ {*} \in I \left(\gamma_ {b}\right)\right). \tag {7}
+$$
+
+We use this metric with $M = 100$ , similarly to previous works.
+
+Negative log-likelihood The negative log-likelihood (NLL) captures both accuracy- and uncertainty-related performance, since it essentially considers the log-likelihood of the true quality score $q^{*}$ based on the distribution estimated by the predicted variance (uncertainty). Thus it penalizes predictions that are accurate but have too high uncertainty (since they will become flat distributions with low probability everywhere), and even more severely incorrect predictions with high confidence, but is more lenient with predictions that are inaccurate but have high uncertainty.
+
+$$
+\mathrm {N L L} = - \frac {1}{| \mathcal {D} |} \sum_ {\langle s, t, \mathcal {R}, q ^ {*} \rangle \in \mathcal {D}} \log \hat {p} \left(q ^ {*} \mid \langle s, t, \mathcal {R} \rangle\right). \tag {8}
+$$
+
+| Hyperparameter | MCD/DE/Vanilla COMET | HTS/KL | DUP |
| Encoder Model | XLM-R (large) | XLM-R (large) | XLM-R (large) |
| Optimizer | Adam | Adam | Adam |
| No. frozen epochs | 0.3 | 0.3 | 0.3 |
| Learning rate | 3e-05 | 3e-05 | 3e-05 |
| Encoder Learning Rate | 1e-05 | 1e-05 | 1e-05 |
| Layerwise Decay | 0.95 | 0.95 | 0.95 |
| Batch size | 4 | 4 | 4 |
| Loss function | Mean squared error | \(\mathcal{L}_{\text{HTS}} / \mathcal{L}_{\text{KL}}\) | \(\mathcal{L}_{\text{HTS}}^{\text{E}}[\mathcal{L}_{\text{ABS}}^{\text{E}} / \mathcal{L}_{\text{SQ}}^{\text{E}}]\) |
| Dropout | 0.15 | 0.15 | 0.15 |
| Hidden sizes | [3072, 1024] | [3072, 1024] | [3072, 1024] |
| Encoder Embedding layer | Frozen | Frozen | Frozen |
| Bottleneck layer size | - | - | 256 |
| FP precision | 32 | 32 | 32 |
| No. Epochs (training) | 2 | 2 | 2 |
| No. Epochs (fine-tuning) | 1 | 1 | 1 |
+
+Table 6: Hyperparameters used to train uncertainty prediction methods.
+
+Note that it is possible to calculate the optimal fixed variance that minimizes NLL by:
+
+$$
+\sigma_ {\text {f i x e d}} ^ {2} = \frac {1}{| \mathcal {D} |} \sum_ {j = 1} ^ {| \mathcal {D} |} \left(q _ {j} ^ {*} - \hat {\mu} _ {j}\right) ^ {2}. \tag {9}
+$$
+
+Sharpness To ensure informative uncertainty estimation, confidence intervals should not only be calibrated, but also sharp. We measure sharpness using the predicted variance $\hat{\sigma}^2$ , as defined in Kuleshov et al. (2018):
+
+$$
+\operatorname {s h a} \left(\hat {p} _ {Q}\right) = \frac {1}{| \mathcal {D} |} \sum_ {\langle s, t, \mathcal {R} \rangle \in \mathcal {D}} \hat {\sigma} ^ {2}. \tag {10}
+$$
+
+Pearson correlations The predictive Pearson score (PPS), evaluates the predictive accuracy of the system - it is the Pearson correlation $r(q^{*},\hat{q})$ between the ground truth quality scores $q^{*}$ and the system predictions $\hat{q}$ in the dataset $\mathcal{D}$ . The uncertainty Pearson score (UPS) $r(|q^{*} - \hat{q}|,\hat{\sigma})$ , measures the alignment between the prediction errors $|q^{*} - \hat{q}|$ and the uncertainty estimates $\hat{\sigma}$ .
+
+# E Uncertainty on OOD examples
+
+We provide the comparison of the sharpness value, representing the quantified uncertainty for in-domain (ID) data (WMT21 news data with MQM annotations) and out-of-domain (OOD) data (WMT21 TEDTalks data with MQM annotations) in Figure 5. Sharpness as explained in App. D, is an indicator of the overall estimated confidence of a model over a given dataset. Thus we want to examine whether the estimated confidence intervals for the OOD data are representative of the expected increase in epistemic uncertainty.
+
+Looking at the sharpness variation per language pair, we can see that for EN-DE and EN-RU, where the aleatoric uncertainty is relatively low as indicated by the low HTS values, the sharpness increases significantly for the DUP model. This behaviour however does not hold for cases where aleatoric uncertainty is higher (ZH-EN). We speculate that this could be attributed to the fact that DUP is trained to capture total uncertainty, instead of only epistemic, and thus it is sensitive to increased noise in the data. Further experiments would be needed to verify this hypothesis.
+
+Across language pairs, the values for HTS remain the same for ID and OOD, while for MCD we have the opposite effect than what was expected: sharpness drops significantly for OOD data in all language pairs. This further supports our claim that uncertainty predictors relying on model variance are not optimal to represent epistemic uncertainty.
+
+For completeness we also provide the results for the rest of performance indicators on the TedTalk dats in Table 7. Note that for the OOD experiments we sampled half the dataset for testing and reserved the rest for calibration (resulting in approx. 4K segments per language pair for each split).
+
+# F Ablation tests for DUP
+
+We present different ablation tests on the DUP architecture to compare the impact of different modelling choices on the training of the model. Our ablation tests are focusing on the second step model, $\mathcal{M}_{\mathrm{E}}$ , since it is the one that accounts for the uncertainty predictions.
+
+
+
+
+
+
+Figure 5: Sharpness for in-domain (blue) News WMT21 MQM data and out-of-domain (red) TEDTalks WMT21 MQM data. We show changes in sharpness values on each language pair separately, for the DUP, HTS, MCD and DE models finetuned on News WMT20 MQM data.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-DE | σ2-fixed | - | 0.072 | 0.146 | 2.957 | 0.526 |
| MCD | 0.178 | 0.052 | 0.147 | 2.500 | 0.540 |
| DE | 0.371 | 0.062 | 0.314 | 1.977 | 0.571 |
| HTS | 0.290 | 0.070 | 0.251 | 2.239 | 0.425 |
| HTS+MCD | 0.401 | 0.073 | 0.227 | 1.756 | 0.545 |
| DE | 0.346 | 0.058 | 0.346 | 2.219 | 0.526 |
| EN-RU | σ2-fixed | - | 0.057 | 0.229 | 2.095 | 0.436 |
| MCD | 0.086 | 0.065 | 0.238 | 1.846 | 0.425 |
| DE | 0.271 | 0.057 | 0.346 | 1.679 | 0.441 |
| HTS | 0.267 | 0.084 | 0.151 | 2.506 | 0.372 |
| HTS+MCD | 0.293 | 0.068 | 0.402 | 1.473 | 0.387 |
| DUP | 0.282 | 0.047 | 0.300 | 1.781 | 0.436 |
| ZH-EN | σ2-fixed | - | 0.033 | 0.397 | 2.203 | 0.434 |
| MCD | 0.063 | 0.023 | 0.283 | 2.348 | 0.447 |
| DE | 0.23 | 0.036 | 0.586 | 1.865 | 0.456 |
| HTS | 0.378 | 0.067 | 0.135 | 2.685 | 0.544 |
| HTS+MCD | 0.288 | 0.073 | 0.223 | 2.276 | 0.425 |
| DUP | 0.271 | 0.030 | 0.825 | 1.718 | 0.434 |
+
+Table 7: Results for segment-level MQM predictions on TEDTalk data. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+# F.1 Comparison of loss functions
+
+We explore three different loss functions for the $\mathcal{M}_{\mathrm{E}}$ model of DUP, described in Eqs. 11-13.
+
+$$
+\mathcal {L} _ {\mathrm {A B S}} ^ {\mathrm {E}} \left(\hat {\epsilon}; \epsilon^ {*}\right) = \left(\epsilon^ {*} - \hat {\epsilon}\right) ^ {2} \tag {11}
+$$
+
+$$
+\mathcal {L} _ {\mathrm {S Q}} ^ {\mathrm {E}} \left(\hat {\epsilon}; \epsilon^ {*}\right) = \left(\left(\epsilon^ {*}\right) ^ {2} - \hat {\epsilon} ^ {2}\right) ^ {2} \tag {12}
+$$
+
+$$
+\mathcal {L} _ {\mathrm {H T S}} ^ {\mathrm {E}} (\hat {\epsilon}; \epsilon^ {*}) = \frac {\left(\epsilon^ {*}\right) ^ {2}}{2 \hat {\epsilon} ^ {2}} + \frac {1}{2} \log (\hat {\epsilon}) ^ {2}. \tag {13}
+$$
+
+Losses $\mathcal{L}_{\mathrm{ABS}}^{\mathrm{E}}$ and $\mathcal{L}_{\mathrm{SQ}}^{\mathrm{E}}$ are variations of the mean squared error loss, using as argument either the absolute error $\hat{\epsilon}$ or the squared error $\hat{\epsilon}^2$ .
+
+We compare the performance of DUP models trained using the different losses on the segment-level DA data. According to the results in Table 8, all three losses perform similarly, with a slight advantage to $\mathcal{L}_{\mathrm{HTS}}^{\mathrm{E}}$ . This motivated our choice to run the experiments discussed in the main paper using this loss as a representative of DUP.
+
+# F.2 Comparison of parameter sharing settings
+
+For this paper the models used for $\mathcal{M}_{\mathrm{Q}}$ and $\mathcal{M}_{\mathrm{E}}$ use very similar architectures, except for the bottleneck layer, as depicted in Figure 6. We thus compare the impact of three different settings:
+
+1. NS: Not sharing any parameters and training $\mathcal{M}_{\mathrm{E}}$ from scratch.
+
+
+Figure 6: Architecture and dependencies of DUP $\mathcal{M}_{\mathrm{Q}}$ and $\mathcal{M}_{\mathrm{E}}$ models
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-XX | DUP LABS | 0.134 | 0.013 | 0.295 | 1.019 | 0.633 |
| DUP LSQ | 0.140 | 0.012 | 0.315 | 1.022 | 0.633 |
| DUP LHTS | 0.146 | 0.014 | 0.293 | 1.021 | 0.633 |
| XX-EN | DUP LABS | 0.081 | 0.017 | 0.527 | 1.471 | 0.287 |
| DUP LSQ | 0.084 | 0.017 | 0.534 | 1.470 | 0.287 |
| DUP LHTS | 0.086 | 0.017 | 0.524 | 1.473 | 0.287 |
| AVG | DUP LABS | 0.104 | 1.265 | 0.015 | 0.414 | 0.446 |
| DUP LSQ | 0.108 | 1.262 | 0.014 | 0.427 | |
| DUP LHTS | 0.112 | 1.266 | 0.015 | 0.411 | 0.446 |
+
+Table 8: Comparison of different losses for the DUP method in segment-level DA prediction.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-XX | NS | 0.272 | 0.008 | 0.344 | 0.919 | 0.566 |
| S | 0.285 | 0.007 | 0.320 | 0.910 | 0.566 |
| SF | 0.276 | 0.008 | 0.341 | 0.917 | 0.566 |
| XX-EN | NS | 0.090 | 0.021 | 0.546 | 1.455 | 0.334 |
| S | 0.089 | 0.021 | 0.542 | 1.442 | 0.334 |
| SF | 0.093 | 0.020 | 0.550 | 1.462 | 0.334 |
| AVG | NS | 0.177 | 0.015 | 0.450 | 1.201 | 0.444 |
| S | 0.182 | 0.014 | 0.437 | 1.190 | 0.444 |
| SF | 0.180 | 0.015 | 0.451 | 1.204 | 0.444 |
+
+Table 9: Comparison of different parameter share configurations for DUP.
+
+2. S: Sharing all (common) parameters between $\mathcal{M}_{\mathrm{Q}}$ and $\mathcal{M}_{\mathrm{E}}$ ; then keep fine-tuning $\mathcal{M}_{\mathrm{E}}$ on the new uncertainty (error) prediction task.
+3. SF: Sharing all (common) parameters between $\mathcal{M}_{\mathrm{Q}}$ and $\mathcal{M}_{\mathrm{E}}$ and freeze the XLM-R encoder weights and embeddings; then keep fine-tuning the rest of the $\mathcal{M}_{\mathrm{E}}$ parameters on the new uncertainty (error) prediction task.
+
+The results are presented in Table 9. We see that sharing parameters (S, SF settings) consistently results in a small boost for all uncertainty indicators. Since we do not see a significant further improvement by keeping the encoder frozen (SF), we perform the rest of the experiments presented in this work by simply sharing the parameters between $\mathcal{M}_{\mathrm{Q}}$ and $\mathcal{M}_{\mathrm{E}}$ (S setting).
+
+# G Results on other metrics
+
+In this section we present results on the WMT 20 DA dataset using trainable metrics that differ to the COMET architecture, as an additional comparison. We select BLEURT and UniTE for this comparison. BLEURT (Sellam et al., 2020b), is a multilingual metric with high performance, which unlike COMET jointly encodes only the translation and reference inputs in order to predict the quality score of a segment. UniTE is a newly proposed architecture (Wan et al., 2022) which is taking into account three different input combinations with the translation segment, namely reference-only, source-only and source-reference-combined. Note that we do not optimise the hyper-parameters of these metrics since we are only interested in comparing the overall behaviour. Hence, improved results could be expected upon optimisation.
+
+We present results on BLEURT in Tables 10, 11 and 12. We used a BLEURT implementation with RemBERT encoder (Chung et al., 2021), trained on the same DA setup described in §5 of the main paper. We notice that we observe similar behaviour of the proposed uncertainty predictors to the one identified for COMET, with the exception of the heteroscedastic predictors (HTS, HTS+MCD). It seems that without access to the source segments it is harder for the heteroscedastic approach to learn to predict meaningful variance intervals. In other words, it seems to be harder for HTS approaches to identify noisy inputs relying only on the reference segments. This finding highlights the importance of including source segments towards identification of noisy inputs and prediction of segment level quality with higher confidence. In comparison, we can see that the DUP approach significantly improves the uncertainty correlation (UPS).
+
+For UniTE, we show results in Tables 13, 14 and 15. We implemented UniTE with an InfoXLM encoder (Chi et al., 2021), trained on the same DA setup described in §5 of the main paper. We noticed that on average the correlations achieved for the UPS performance indicator are lower to the ones obtained with COMET and BLEURT, especially for MCD. However, they follow similar pattern to the one identified in the main paper: we obtain significantly better correlations both for the HTS and the DUP predictors.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-XX | σ2-fixed | - | 0.107 | 4.698 | 1.984 | 0.317 |
| MCD | 0.302 | 0.295 | 1.035 | 2.291 | 0.316 |
| DE | 0.204 | 0.205 | 1.886 | 2.034 | 0.337 |
| HTS | 0.328 | 0.104 | 4.383 | 1.925 | 0.319 |
| HTS+MCD | 0.322 | 0.103 | 4.364 | 1.924 | 0.314 |
| DUP | 0.435 | 0.105 | 5.917 | 2.033 | 0.317 |
| XX-EN | σ2-fixed | - | 0.067 | 3.200 | 1.831 | 0.080 |
| MCD | 0.274 | 0.204 | 1.030 | 1.965 | 0.079 |
| DE | 0.032 | 0.107 | 1.392 | 1.845 | 0.111 |
| HTS | 0.246 | 0.069 | 2.755 | 1.739 | 0.071 |
| HTS+MCD | 0.240 | 0.069 | 2.753 | 1.739 | 0.068 |
| DUP | 0.320 | 0.064 | 3.892 | 1.888 | 0.080 |
| AVG | σ2-fixed | - | 0.086 | 3.910 | 1.903 | 0.192 |
| MCD | 0.287 | 0.247 | 1.032 | 2.120 | 0.191 |
| DE | 0.172 | 0.150 | 1.608 | 1.926 | 0.210 |
| HTS | 0.285 | 0.086 | 3.527 | 1.827 | 0.189 |
| HTS+MCD | 0.279 | 0.085 | 3.517 | 1.827 | 0.185 |
| DUP | 0.374 | 0.083 | 4.853 | 1.957 | 0.192 |
+
+Table 10: Results for segment-level DA predictions by BLEURT [Average across language pairs]. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-CS | σ2-fixed | - | 0.083 | 3.462 | 1.860 | 0.400 |
| MCD | 0.226 | 0.235 | 1.031 | 2.000 | 0.399 |
| DE | 0.326 | 0.161 | 1.656 | 1.846 | 0.446 |
| HTS | 0.291 | 0.071 | 3.727 | 1.848 | 0.386 |
| HTS+MCD | 0.289 | 0.071 | 3.725 | 1.852 | 0.381 |
| DUP | 0.410 | 0.079 | 5.029 | 1.986 | 0.400 |
| EN-DE | σ2-fixed | - | 0.112 | 5.779 | 2.099 | 0.257 |
| MCD | 0.432 | 0.336 | 1.040 | 2.603 | 0.256 |
| DE | 0.198 | 0.217 | 2.508 | 2.207 | 0.267 |
| HTS | 0.366 | 0.129 | 5.959 | 2.093 | 0.254 |
| HTS+MCD | 0.358 | 0.128 | 5.846 | 2.083 | 0.248 |
| DUP | 0.513 | 0.123 | 7.362 | 2.115 | 0.257 |
| EN-JA | σ2-fixed | - | 0.134 | 6.040 | 2.105 | 0.277 |
| MCD | 0.326 | 0.358 | 1.041 | 2.592 | 0.275 |
| DE | 0.121 | 0.258 | 1.937 | 2.185 | 0.289 |
| HTS | 0.278 | 0.126 | 5.105 | 2.003 | 0.293 |
| HTS+MCD | 0.274 | 0.125 | 5.070 | 2.000 | 0.287 |
| DUP | 0.420 | 0.124 | 7.295 | 2.122 | 0.277 |
| EN-PL | σ2-fixed | - | 0.081 | 3.739 | 1.904 | 0.349 |
| MCD | 0.217 | 0.247 | 1.032 | 2.105 | 0.347 |
| DE | 0.247 | 0.154 | 1.728 | 1.876 | 0.374 |
| HTS | 0.262 | 0.070 | 3.779 | 1.870 | 0.341 |
| HTS+MCD | 0.260 | 0.069 | 3.739 | 1.870 | 0.335 |
| DUP | 0.362 | 0.076 | 5.092 | 1.992 | 0.349 |
| EN-RU | σ2-fixed | - | 0.100 | 4.321 | 1.959 | 0.356 |
| MCD | 0.218 | 0.282 | 1.034 | 2.212 | 0.356 |
| DE | 0.158 | 0.184 | 1.838 | 1.951 | 0.361 |
| HTS | 0.280 | 0.097 | 4.019 | 1.896 | 0.350 |
| HTS+MCD | 0.275 | 0.096 | 4.010 | 1.895 | 0.345 |
| DUP | 0.383 | 0.103 | 5.177 | 1.967 | 0.356 |
| EN-TA | σ2-fixed | - | 0.065 | 3.530 | 1.877 | 0.240 |
| MCD | 0.131 | 0.218 | 1.029 | 2.047 | 0.240 |
| DE | 0.162 | 0.135 | 1.822 | 1.864 | 0.278 |
| HTS | 0.320 | 0.062 | 3.499 | 1.826 | 0.248 |
| HTS+MCD | 0.317 | 0.062 | 3.534 | 1.828 | 0.249 |
| DUP | 0.279 | 0.060 | 4.501 | 1.966 | 0.240 |
| EN-ZH | σ2-fixed | - | 0.154 | 6.063 | 2.097 | 0.280 |
| MCD | 0.506 | 0.375 | 1.041 | 2.540 | 0.280 |
| DE | 0.171 | 0.297 | 1.940 | 2.297 | 0.282 |
| HTS | 0.465 | 0.160 | 4.919 | 1.975 | 0.301 |
| HTS+MCD | 0.449 | 0.160 | 4.920 | 1.974 | 0.297 |
| DUP | 0.601 | 0.154 | 7.044 | 2.091 | 0.280 |
+
+Table 11: Results for segment-level DA predictions by BLEURT for En-Xx LPs. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| CS-EN | σ2-fixed | - | 0.068 | 3.085 | 1.816 | 0.061 |
| MCD | 0.303 | 0.202 | 1.030 | 1.924 | 0.059 |
| DE | 0.020 | 0.156 | 1.271 | 1.806 | 0.071 |
| HTS | 0.291 | 0.073 | 2.775 | 1.735 | 0.052 |
| HTS+MCD | 0.287 | 0.072 | 2.773 | 1.734 | 0.050 |
| DUP | 0.360 | 0.068 | 3.781 | 1.838 | 0.061 |
| DE-EN | σ2-fixed | - | 0.080 | 3.053 | 1.808 | 0.018 |
| MCD | 0.364 | 0.210 | 1.028 | 1.908 | 0.016 |
| DE | 0.087 | 0.159 | 1.320 | 1.767 | 0.044 |
| HTS | 0.326 | 0.091 | 3.015 | 1.748 | -0.002 |
| HTS+MCD | 0.323 | 0.091 | 3.000 | 1.746 | -0.003 |
| DUP | 0.399 | 0.081 | 3.981 | 1.837 | 0.018 |
| JA-EN | σ2-fixed | - | 0.072 | 3.701 | 1.896 | 0.095 |
| MCD | 0.228 | 0.229 | 1.033 | 2.082 | 0.094 |
| DE | 0.011 | 0.143 | 1.524 | 1.845 | 0.102 |
| HTS | 0.192 | 0.069 | 2.973 | 1.779 | 0.084 |
| HTS+MCD | 0.184 | 0.068 | 2.948 | 1.777 | 0.082 |
| DUP | 0.262 | 0.066 | 4.328 | 1.959 | 0.095 |
| KM-EN | σ2-fixed | - | 0.032 | 2.613 | 1.753 | 0.208 |
| MCD | 0.084 | 0.145 | 1.029 | 1.827 | 0.205 |
| DE | 0.020 | 0.002 | 1.207 | 2.003 | 0.278 |
| HTS | 0.100 | 0.026 | 2.168 | 1.642 | 0.209 |
| HTS+MCD | 0.099 | 0.026 | 2.152 | 1.640 | 0.199 |
| DUP | 0.149 | 0.021 | 3.222 | 1.856 | 0.208 |
| PL-EN | σ2-fixed | - | 0.068 | 3.324 | 1.853 | 0.053 |
| MCD | 0.313 | 0.213 | 1.031 | 2.002 | 0.053 |
| DE | 0.051 | 0.128 | 1.536 | 1.816 | 0.065 |
| HTS | 0.253 | 0.069 | 2.842 | 1.766 | 0.057 |
| HTS+MCD | 0.248 | 0.069 | 2.862 | 1.767 | 0.051 |
| DUP | 0.358 | 0.067 | 3.922 | 1.919 | 0.053 |
| PS-EN | σ2-fixed | - | 0.034 | 2.633 | 1.768 | 0.090 |
| MCD | 0.176 | 0.151 | 1.029 | 1.861 | 0.088 |
| DE | -0.029 | 0.002 | 1.267 | 2.134 | 0.101 |
| HTS | 0.165 | 0.033 | 2.058 | 1.647 | 0.075 |
| HTS+MCD | 0.159 | 0.033 | 2.044 | 1.647 | 0.070 |
| DUP | 0.218 | 0.028 | 3.267 | 1.859 | 0.090 |
| PS-EN | σ2-fixed | - | 0.085 | 3.490 | 1.857 | 0.076 |
| MCD | 0.261 | 0.228 | 1.030 | 1.986 | 0.076 |
| DE | 0.027 | 0.153 | 1.482 | 1.815 | 0.084 |
| HTS | 0.219 | 0.087 | 3.135 | 1.786 | 0.068 |
| HTS+MCD | 0.212 | 0.087 | 3.148 | 1.785 | 0.067 |
| DUP | 0.319 | 0.081 | 4.021 | 1.897 | 0.076 |
| RU-EN | σ2-fixed | - | 0.041 | 2.069 | 1.658 | 0.108 |
| MCD | 0.238 | 0.121 | 1.020 | 1.688 | 0.106 |
| DE | 0.023 | 0.064 | 1.401 | 1.601 | 0.132 |
| HTS | 0.245 | 0.046 | 1.704 | 1.561 | 0.098 |
| HTS+MCD | 0.238 | 0.046 | 1.703 | 1.562 | 0.096 |
| DUP | 0.273 | 0.034 | 2.959 | 1.767 | 0.108 |
| ZH-EN | σ2-fixed | - | 0.076 | 3.542 | 1.886 | 0.080 |
| MCD | 0.309 | 0.231 | 1.033 | 2.075 | 0.079 |
| DE | 0.034 | 0.138 | 1.527 | 1.817 | 0.097 |
| HTS | 0.278 | 0.078 | 2.984 | 1.790 | 0.071 |
| HTS+MCD | 0.270 | 0.078 | 2.984 | 1.790 | 0.068 |
| DUP | 0.353 | 0.075 | 4.252 | 1.932 | 0.080 |
+
+Table 12: Results for segment-level DA predictions by BLEURT for Xx-En LPs. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+ | | UPS ↑ | ECE ↓ | Sha. ↓ | NLL ↓ | PPS ↑ |
| EN-XX | σ2-fixed | - | 0.018 | 0.224 | 0.913 | 0.650 |
| MCD | 0.022 | 0.011 | 0.260 | 0.853 | 0.603 |
| DE | 0.129 | 0.015 | 0.264 | 0.878 | 0.647 |
| HTS | 0.183 | 0.013 | 0.319 | 0.892 | 0.630 |
| HTS+MCD | 0.175 | 0.004 | 0.272 | 0.792 | 0.587 |
| DUP | 0.139 | 0.015 | 0.250 | 0.924 | 0.650 |
| XX-EN | σ2-fixed | - | 0.027 | 0.498 | 1.512 | 0.289 |
| MCD | 0.059 | 0.016 | 0.523 | 1.352 | 0.271 |
| DE | 0.049 | 0.028 | 0.503 | 1.488 | 0.293 |
| HTS | 0.090 | 0.026 | 0.525 | 1.506 | 0.288 |
| HTS+MCD | 0.079 | 0.010 | 0.572 | 1.351 | 0.267 |
| DUP | 0.065 | 0.026 | 0.518 | 1.546 | 0.289 |
| AVG | σ2-fixed | - | 0.023 | 0.368 | 1.228 | 0.460 |
| MCD | 0.041 | 0.014 | 0.398 | 1.115 | 0.428 |
| DE | 0.087 | 0.022 | 0.390 | 1.198 | 0.461 |
| HTS | 0.134 | 0.020 | 0.427 | 1.215 | 0.450 |
| HTS+MCD | 0.124 | 0.007 | 0.429 | 1.085 | 0.419 |
| DUP | 0.100 | 0.021 | 0.391 | 1.251 | 0.460 |
+
+Table 13: Results for segment-level DA predictions by UniTE [Average across language pairs]. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+| UPS↑ | ECE↓ | Sha↓ | NL↓ | PPS↑ | |
| σ2-fixed | |
| MCD | -0.007 | 0.013 | 0.284 | 0.990 | 0.735 |
| DE | 0.108 | 0.011 | 0.242 | 0.803 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.946 | 0.718 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.943 | 0.672 |
| DUP | 0.108 | 0.011 | 0.300 | 0.988 | 0.735 |
| EN-ZH | -0.007 | 0.013 | 0.284 | 0.990 | 0.735 |
| DE | 0.108 | 0.011 | 0.242 | 0.803 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.946 | 0.719 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.943 | 0.672 |
| DUP | 0.108 | 0.011 | 0.300 | 0.988 | 0.735 |
| EN-HT | -0.007 | 0.013 | 0.284 | 0.990 | 0.735 |
| DE | 0.108 | 0.011 | 0.242 | 0.803 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.946 | 0.717 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.943 | 0.672 |
| DUP | 0.108 | 0.011 | 0.300 | 0.988 | 0.735 |
| EN-MCD | -0.007 | 0.013 | 0.284 | 0.990 | 0.735 |
| DE | 0.108 | 0.011 | 0.242 | 0.803 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.946 | 0.735 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.943 | 0.672 |
| DUP | 0.108 | 0.011 | 0.300 | 0.988 | 0.735 |
| EN-HT | -0.007 | 0.013 | 0.284 | 1.178 | 0.623 |
| DE | 0.108 | 0.011 | 0.242 | 0.803 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.946 | 0.718 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.988 | 0.735 |
| DUP | 0.108 | 0.011 | 0.300 | 0.988 | 0.735 |
| EN-MCD | -0.007 | 0.013 | 0.284 | 1.178 | 0.623 |
| DE | 0.108 | 0.011 | 0.242 | 0.803 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.946 | 0.719 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.988 | 0.735 |
| DUP | 0.108 | 0.011 | 0.300 | 0.988 | 0.735 |
| EN-MCD | -0.007 | 0.013 | 0.284 | 0.990 | 0.735 |
| DE | 0.108 | 0.011 | 0.242 | 0.802 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.946 | 0.719 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.988 | 0.735 |
| DUP | 0.108 | 0.011 | 0.242 | 0.802 | 0.672 |
| EN-MCD | -0.007 | 0.013 | 0.284 | 0.990 | 0.735 |
| DE | 0.108 | 0.011 | 0.242 | 0.802 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.945 | 0.719 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.985 | 0.735 |
| DUP | 0.108 | 0.011 | 0.242 | 0.802 | 0.672 |
| EN-MCD | -0.007 | 0.013 | 0.284 | 1.125 | 0.685 |
| DE | 0.108 | 0.011 | 0.242 | 0.802 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.945 | 0.719 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.802 | 0.672 |
| DUP | 0.108 | 0.011 | 0.242 | 0.802 | 0.672 |
| EN-MCD | -0.007 | 0.013 | 0.284 | 1.125 | 0.685 |
| DE | 0.108 | 0.011 | 0.242 | 0.805 | 0.672 |
| HTS | 0.151 | 0.009 | 0.427 | 0.945 | 0.719 |
| HTS+MCD | 0.132 | 0.003 | 0.249 | 0.985 | 0.735 |
| DUP | 0.108 | 0.011 | 0.300 | 1.125 | 0.685 |
+
+Table 14: Results for segment-level DA predictions by UniTE for En-Xx LPs. Underlined numbers indicate the best result for each evaluation metric in each language pair.
+
+| UP8→BCE↓Sha↓NL↓PPS→ |
| σ2-4-fixed MCD DE HTS HTS+MCD DUP | 0.021 0.008 0.531 1.454 0.179 0.016 0.029 0.474 1.462 0.171 0.027 0.005 0.563 1.273 0.150 0.037 0.005 0.563 1.273 0.150 0.037 0.005 0.563 1.273 0.150 0.037 0.005 0.563 1.273 0.150 0.037 0.005 053 1.470 0.179 0.016 0.029 0.474 1.462 0.179 0.016 0.029 0.474 1.462 0.179 0.016 0.029 0.474 1.462 0.179 0.016 0.029 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.563 1.470 0.179 0.238 0.563 1.470 0.179 0.238 0.563 1.470 0.179 0.238 0.563 1.470 0.179 0.238 0.563 1.470 0.238 0.563 1.470 0.238 0.563 1.470 0.238 0.563 1.470 0.238 0.563 1.470 0.238 0.563 1.470 0.238 0.474 1.587 0.258 0.474 1.587 0.258 0.474 1.587 0.258 0.474 1.587 0.258 0.474 1.587 0.258 0.474 1.587 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 027 0.029 0.029 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0474 1.462 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0.474 1.462 0.179 0.238 0464 1.462 0.238 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.258 0.474 157 0.179 0.238 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.474 1.578 0.258 0.563 1.568 0.230 0.474 1.568 0.230 0.474 1.568 0.230 0.474 1.568 0.230 0.474 1.568 0.230 0.474 1.568 0.230 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.563 1.568 0.230 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.230 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.177 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.230 0.474 1.177 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.177 0.238 0.474 1.177 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.474 1.568 0.179 0.238 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.177 0.238 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.179 0.238 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.179 0.238 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.177 0.238 0.563 1.177 0.238 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.177 0.238 0.474 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.179 0.238 0.474 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.474 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.177 0.179 0.238 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 1.568 0.230 0.563 157 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 0.258 0.474 1.567 | | | | | | | | | | | | | | | |
+
+Table 15: Results for segment-level DA predictions by UniTE for Xx-En LPs. Underlined numbers indicate the best result for each evaluation metric in each language pair.
\ No newline at end of file
diff --git a/disentanglinguncertaintyinmachinetranslationevaluation/images.zip b/disentanglinguncertaintyinmachinetranslationevaluation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..13a3575e95e35113306d92ec37df4d6c72928c28
--- /dev/null
+++ b/disentanglinguncertaintyinmachinetranslationevaluation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b336d965ba2c06a71753a3770846c3a618e854888e72f30e5bd3ab6c36209338
+size 1804066
diff --git a/disentanglinguncertaintyinmachinetranslationevaluation/layout.json b/disentanglinguncertaintyinmachinetranslationevaluation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d8b65fb62b200fba9a9801b366a5bdb8b53c2f22
--- /dev/null
+++ b/disentanglinguncertaintyinmachinetranslationevaluation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:afed2c47ad44b034a29c2ecc40c32ac9e0ded60568fde45c7b83c5f97f8ca11c
+size 629912
diff --git a/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_content_list.json b/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..3c0d68045e805d32c063956b7c46fc869122f0b8
--- /dev/null
+++ b/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:903fe544586914bbd1049e89c174d03c66af519379594317d8fb8a42cdccd54f
+size 88810
diff --git a/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_model.json b/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..6814a358977430a94f72996230a51c8f8606496b
--- /dev/null
+++ b/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4e32d42afec86dda13e2cb711060f3424af009ae6ef938be886a0400bd0b22bf
+size 110190
diff --git a/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_origin.pdf b/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..e555b72c4ac8296808112efa167f828ebbd45a88
--- /dev/null
+++ b/distilleddualencodermodelforvisionlanguageunderstanding/8dded11a-7fdd-4715-a26a-31670e2bfff9_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:41cb78888fb4b2cd093c3e2010ea3ab0014fe0773cce6186f756f38ead719d91
+size 991209
diff --git a/distilleddualencodermodelforvisionlanguageunderstanding/full.md b/distilleddualencodermodelforvisionlanguageunderstanding/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..a7b64f77eed1d23b0ce44bd6cf363416252ee4f2
--- /dev/null
+++ b/distilleddualencodermodelforvisionlanguageunderstanding/full.md
@@ -0,0 +1,353 @@
+# Distilled Dual-Encoder Model for Vision-Language Understanding
+
+Zekun Wang†, Wenhui Wang‡, Haichao Zhu†, Ming Liu†‡, Bing Qin†‡, Furu Wei‡
+
+†Harbin Institute of Technology, Harbin, China
+
+Microsoft Research, Beijing, China
+
+Peng Cheng Laboratory, Shenzhen, China
+
+{zkwang,hczhu,mliu,qinb}@ir.hit.edu.cn
+
+{wenwan, fuwei}@microsoft.com
+
+# Abstract
+
+On vision-language understanding (VLU) tasks, fusion-encoder vision-language models achieve superior results but sacrifice efficiency because of the simultaneous encoding of images and text. On the contrary, the dual-encoder model that separately encodes images and text has the advantage in efficiency, while failing on VLU tasks due to the lack of deep cross-modal interactions. To get the best of both worlds, we propose DIDE1, a framework that distills the knowledge of the fusion-encoder teacher model into the dual-encoder student model. Since the cross-modal interaction is the key to the superior performance of teacher model but is absent in the student model, we encourage the student not only to mimic the predictions of teacher, but also to calculate the cross-modal attention distributions and align with the teacher. Experimental results demonstrate that DIDE is competitive with the fusion-encoder teacher model in performance (only a $1\%$ drop) while enjoying $4\times$ faster inference. Further analyses reveal that the proposed cross-modal attention distillation is crucial to the success of our framework.
+
+# 1 Introduction
+
+Vision-language understanding (VLU) tasks (e.g., visual reasoning (Suhr et al., 2019), visual entailment (Xie et al., 2019), visual question answering (Goyal et al., 2017)) require the model to understand the cross-modal interactions between images and text. Various fusion-encoder vision-language pretrained models (Tan and Bansal, 2019; Chen et al., 2020; Zhang et al., 2021; Kim et al., 2021; Dou et al., 2022; Alayrac et al., 2022) are proposed for VLU tasks. As shown in Figure 1(a), these models employ a Transformer (Vaswani et al., 2017) network as a cross-modal encoder to capture interactions between different modalities. Despite the
+
+
+(a) Fusion-encoder Model
+
+
+(b) Dual-encoder Model
+Figure 1: Illustration of two architectures of vision-language models. (a) Fusion-encoder models simultaneously encode visual and textual inputs via modal-specific embeddings/encoders and employ a cross-modal Transformer encoder to fuse representations. (b) Dual-encoder models encode images/text separately and adopt an extreme lightweight module (e.g., MLP) for cross-modal interactions.
+
+remarkable performance, the heavy cross-modal encoder remains an efficiency bottleneck due to the simultaneous encoding of images and text, limiting the application in practical scenarios with massive images or text. Therefore, it is crucial to find an approach to accelerate inference for VLU.
+
+We turn to explore the dual-encoder vision-language model (shown in Figure 1(b)), which encodes images and text separately and then applies an extreme lightweight shallow module to model the interactions between modalities. The disentangled encoding paradigm enables off-line computing and caching visual or textual representations on demand, significantly lowering runtime latency. However, the shallow module is insufficient to handle complex VLU tasks, resulting in previous models (Radford et al., 2021; Jia et al., 2021) falling far behind fusion-encoder models (Kim et al., 2021). Can dual-encoder models obtain performance comparable to fusion-encoder models while preserving efficiency? In this work, we propose DIDE (a knowledge Distillation framework for Dual-Encoder models), where the dual-encoder model (student) is supervised by the fusion encoder models (teacher), as shown in Figure 2. Although soft label distillation (Hinton et al., 2015) is widely applied, our key observation is that cross-modal
+
+attention distributions2 are absent in the student, resulting in the inability to model complex cross-modal interactions. Thus, only distilling soft labels is not enough for the student to mimic the interactions of teacher deeply.
+
+Considering that cross-modal interaction is critical for VLU, we introduce a plug-and-play objective cross-modal attention distillation, as fine-grained supervision to help the student better learn cross-modal interactions. Specifically, besides the soft label distillation, we compute the cross-modal attention of the student model and align it with the distribution in the teacher model during training. The training of DIDE consists of two-stage distillations. In the pre-training stage, the student learns a general initialization with distillation. In the fine-tuning stage, distillation helps the student learn more task-specific knowledge. Experimental results demonstrate that DIDE performs competitively with the fusion-encoder teacher model in various VLU tasks (retaining $96.9\%$ to $99.9\%$ performance) while having a $4\times$ inference speedup. Further analysis indicates that the proposed cross-modal attention distillation yields significant gains compared to distilling only with soft labels or other latent features of the teacher. Beyond VLU, DIDE also shows effectiveness in image-text retrieval.
+
+Our contributions are summarized as follows:
+
+- We propose DIDE, a knowledge distillation framework for the dual-encoder model to learn better cross-modal interactions of vision-language understanding from the fusion-encoder model.
+- Our approach is plug-and-play with different vision-language tasks and can be applied on different model architectures.
+- Experimental results show that our distilled model performs competitively with the teacher model and has a significant speedup. Further analysis indicates that our proposed cross-modal attention distillation is the key to success.
+
+# 2 Related Work
+
+# 2.1 Vision-Language Pre-Training
+
+Language and vision pre-training advance the state of the art in downstream natural language processing tasks (Radford et al., 2018; Devlin et al., 2019;
+
+Dong et al., 2019; Liu et al., 2019; Bao et al., 2020; Lewis et al., 2020; Raffel et al., 2020; Conneau et al., 2020; Chi et al., 2021) and computer vision tasks (Dosovitskiy et al., 2021; Touvron et al., 2021; Bao et al., 2021). Vision-Language pre-training (Lu et al., 2019; Su et al., 2020; Gan et al., 2020; Li et al., 2021b; Wang et al., 2021a,b) has been shown to prevail in learning cross-modal representations. The model architectures fall into two lines: fusion-encoder and dual-encoder models. Fusion-encoder models jointly encode imagetext pairs and employ a multi-layer cross-modal Transformer encoder to fuse the visual and textual representations. Previous models (Li et al., 2019; Tan and Bansal, 2019; Chen et al., 2020; Li et al., 2020; Zhang et al., 2021) extract visual features through a pre-trained object detector (e.g., Faster R-CNN (Ren et al., 2015)), which requires high-resolution input images and brings more computation costs. Huang et al. (2020); Li et al. (2021a); Dou et al. (2022) directly take image pixels or patches as input and encode visual features by CNN or Vision Transformer (Dosovitskiy et al., 2021). ViLT (Kim et al., 2021) directly applies a shared Transformer for joint encoding of image patches and textual token embeddings, achieving competitive performance with less overhead. The models exhibit a strong ability to model complex cross-modal interactions and achieve superior results on VLU tasks. However, the models rely on a cross-modal Transformer encoder to fuse visual and textual features simultaneously across layers, demanding a heavy computation budget and leading to a low inference speed.
+
+On the contrary, dual-encoder models (Radford et al., 2021; Jia et al., 2021; Sun et al., 2021) encode images and text separately and take an MLP or dot product to model the interactions between the modalities. These models have the advantage of computational efficiency. The attention mechanism is computed only within tokens of the same modality. Moreover, thanks to the independent encoders, the visual or textual representations can be precomputed and cached off-line in the practical scenarios. However, the shallow module is not enough to handle complex cross-modal interactions, causing significant performance degradation on VLU tasks (Kim et al., 2021; Hendricks et al., 2021). To get the best of both worlds, we preserve the inference efficiency of dual-encoder model while achieving promising results on VLU
+
+by knowledge distillation.
+
+# 2.2 Knowledge Distillation
+
+Knowledge distillation (KD; Hinton et al. (2015) aims to improve a student model by transferring knowledge from a teacher model. Transformer distillation is widely used in various domains (Jiao et al., 2020; Wang et al., 2020; Touvron et al., 2021; Fang et al., 2021). In this work, we focus on distillation under the cross-architecture setting (Hofstätter et al., 2020), where the architectures of the teacher and the student are different. Cao et al. (2020) decomposes the early layers of the Transformer and adopts a complete Transformer to guide the training for reading comprehension. In image-text retrieval, Miech et al. (2021) proposes distilling soft labels from a cross-attention model to a dual-encoder model with the reranking mechanism. But in VLU tasks, their method does not work, whereas our proposed cross-modal attention distillation is critical for success.
+
+# 3 Method
+
+Figure 2 gives an overview of our DIDE framework, a knowledge distillation approach for the dual-encoder model.
+
+# 3.1 Model Overview
+
+Input Representations We slice the input image $\pmb{v} \in \mathbb{R}^{H \times W \times C}$ into patches $\pmb{v}^p \in \mathbb{R}^{N \times (P^2C)}$ , where $N = HW / P^2$ is the number of patches, $(H, W)$ is the resolution of the input image, $(P, P)$ is the resolution of each patch, and $C$ is the number of channels. The input text $\pmb{t}$ is tokenized into a sequence of $M$ tokens. We prepend the special tokens [I_CLS] and [T_CLS] to the sequence of image patches and text tokens, respectively. We linearly project image patches $\pmb{v}^p$ to obtain patch embeddings, and the final visual input embeddings $\pmb{H}_0^{\nu} \in \mathbb{R}^{(N + 1) \times D}$ are computed via:
+
+$$
+\pmb {H} _ {0} ^ {v} = [ \pmb {v} _ {[ I \_ C L S ]}, \pmb {V} \pmb {v} _ {1} ^ {p}, \dots , \pmb {V} \pmb {v} _ {N} ^ {p} ] + \pmb {V} _ {p o s} + \pmb {V} _ {t y p e}
+$$
+
+where $\mathbf{V} \in \mathbb{R}^{(P^2 C) \times D}$ is linear projection, $V_{pos} \in \mathbb{R}^{(N + 1) \times D}$ is 1D positional embedding, $V_{type} \in \mathbb{R}^D$ is visual type embedding. The textual input embeddings $\pmb{H}_0^t \in \mathbb{R}^{(M + 1) \times D}$ are obtained by summing word embeddings $\pmb{W}$ , the textual position embedding $T_{pos}$ and textual type embedding $T_{type}$ :
+
+$$
+\boldsymbol {H} _ {0} ^ {t} = \left[ \boldsymbol {w} _ {[ T \_ C L S ]}, \boldsymbol {w} _ {1}, \dots , \boldsymbol {w} _ {M} \right] + \boldsymbol {T} _ {p o s} + \boldsymbol {T} _ {t y p e}
+$$
+
+We take $H_0^\nu, H_0^t$ as visual and textual inputs for the teacher and student models.
+
+Fusion-Encoder Model (Teacher) concatenates the input representations $H_0^v$ and $H_0^t$ as $H_0^{vl} = [H_0^v; H_0^t]$ , and feeds into a $L$ -layer cross-modal Transformer encoder to obtain contextual representations $H_L^{vl}$ . The cross-modal Transformer encoder fuses representations of different modalities via the multi-head attention mechanism. Specifically, for each head $a$ , the whole attention distribution $A_a^{vl}$ is computed via:
+
+$$
+\boldsymbol {A} _ {a} ^ {v l} = \operatorname {s o f t m a x} (\frac {\boldsymbol {Q} _ {a} ^ {v l} \boldsymbol {K} _ {a} ^ {v l \intercal}}{\sqrt {d _ {k}}})
+$$
+
+where queries $Q_{a}^{vl}$ and keys $K_{a}^{vl}$ are obtained by linearly projecting the hidden states using parameters $W_{l,a}^{Q}, W_{l,a}^{K} \in \mathbb{R}^{D \times d_{k}}$ , respectively. $d_{k}$ is the size of the attention head. The output vectors of [I_CLS] and [T_CLS] are fed into the task-specific layer to obtain predictions.
+
+Dual-Encoder Model (Student) encodes $H_0^\nu$ and $H_0^t$ are separately via visual and textual Transformer encoders: $H_l^\nu$ and $H_l^t$ . The output vectors of [I_CLS] and [T_CLS] are used as final representations of the images and text. Then, a shallow module $f$ is applied to fuse the two representations. For vision-language understanding, we adopt an MLP as the module $f$ . For image-text retrieval, we use the dot product function to obtain similarity scores of image-text pairs.
+
+# 3.2 Distillation Objectives
+
+Cross-Modal Attention Distillation The Transformer captures fine-grained interactions between tokens, mainly benefiting from the multi-head attention mechanism (Hao et al., 2021). In the dual-encoder model, tokens only compute attention with those within the same modality, named uni-modal attention: visual-to-visual $A^{\nu 2\nu} \in \mathbb{R}^{N \times N}$ and textual-to-textual $A^{t2t} \in \mathbb{R}^{M \times M}$ . As shown in Figure 2, compared to the whole attention $A^{\nu l} \in \mathbb{R}^{(N + M) \times (N + M)}$ of the fusion-encoder model, we observe that the attention of computing intermodality tokens (named cross-modal attention $^3$ ) is absent in the student, including visual-to-textual $A^{\nu 2t} \in \mathbb{R}^{N \times M}$ and textual-to-visual $A^{t2\nu} \in \mathbb{R}^{M \times N}$ . Thus, the student lacks the ability to capture cross-modal interactions, which is critical for vision-language tasks.
+
+Taking into account the weakness of the dual-encoder model, we propose the cross-modal at
+
+
+Figure 2: Overview of our framework DIDE, best viewed in color. Besides soft labels, we introduce cross-modal attention distillation to guide the model training. The visual-to-textual attention $A^{v2t}$ (blue) and the textual-to-visual $A^{t2v}$ (orange) of the dual-encoder model (student) are aligned to the fusion-encoder model (teacher). Other part of the attention distributions (grey) are omitted.
+
+tention distillation objective. Specifically, during training, the student calculates the cross-modal part of the attention distribution and mimics it with the teacher. The cross-modal attention distributions of the student $A_{S}^{v2t}$ , $A_{S}^{t2v}$ are computed as follows:
+
+$$
+\boldsymbol {A} _ {S} ^ {v 2 t} = \operatorname {s o f t m a x} \left(\frac {\boldsymbol {Q} _ {S} ^ {v} \boldsymbol {K} _ {S} ^ {t \top}}{\sqrt {d _ {k}}}\right)
+$$
+
+$$
+\boldsymbol {A} _ {S} ^ {t 2 v} = \operatorname {s o f t m a x} \left(\frac {\boldsymbol {Q} _ {S} ^ {t} \boldsymbol {K} _ {S} ^ {v \top}}{\sqrt {d _ {k}}}\right)
+$$
+
+where $Q_S^v, K_S^v$ are visual queries and keys of the attention module in the student. $Q_S^t, K_S^t$ are queries and keys for textual features. To better align the student, we calculate the cross-modal attention $A_T^{v2t}, A_T^{t2v}$ of the teacher in a way similar to above, instead of directly splitting the whole attention $A_T^{vl}$ . We use the cross-modal attention distillation loss to minimize the KL-divergence of the cross-modal attention distribution:
+
+$$
+\mathcal {L} _ {C A} = D _ {K L} \left(\boldsymbol {A} _ {S} ^ {v 2 t} \parallel \boldsymbol {A} _ {T} ^ {v 2 t}\right) + D _ {K L} \left(\boldsymbol {A} _ {S} ^ {t 2 v} \parallel \boldsymbol {A} _ {T} ^ {t 2 v}\right)
+$$
+
+We empirically find that only distilling between the last layer of teacher and student is more effective (detailed in Section 4.4).
+
+Soft Label Distillation In addition to cross-modal attention distillation, we also apply the soft label distillation loss to align the predictions between the teacher and the student:
+
+$$
+\mathcal {L} _ {S L} = D _ {K L} \left(\boldsymbol {z} _ {S} \parallel \boldsymbol {z} _ {T}\right)
+$$
+
+where $z_{S}, z_{T}$ are the output logits of the student and the teacher, respectively.
+
+# 3.3 Two-Stage Distillation Training
+
+DIDE applies the distillation objectives via the prevalent two-stage training paradigm: pre-training and then fine-tuning.
+
+# 3.3.1 Pre-Training Distillation
+
+We consider three typical pre-training tasks: cross-modal contrastive learning, image-text matching, and masked language modeling.
+
+Cross-Modal Contrastive Learning (CMC) We introduce an InfoNCE contrastive loss (van den Oord et al., 2018) with in-batch negative sampling to optimize the shared space of visual and textual representations. Specifically, the image-to-text contrastive loss is computed as:
+
+$$
+\mathcal {L} _ {N C E} ^ {i 2 t} = - \sum_ {i = 1} ^ {N} \log \frac {\exp (\sin (I _ {i} , T _ {i}) / \tau)}{\sum_ {j = 1} ^ {N} \exp (\sin (I _ {i} , T _ {j}) / \tau)}
+$$
+
+where $\tau$ is a trainable temperature parameter, $I_{i}$ and $T_{i}$ are representations of the $i$ -th image-text pair in the batch. We use the dot product as the $\mathrm{sim}(\cdot ,\cdot)$ function. Similarly, the text-to-image contrastive loss is computed as follows:
+
+$$
+\mathcal {L} _ {N C E} ^ {t 2 i} = - \sum_ {i = 1} ^ {N} \log \frac {\exp (\sin (T _ {i} , I _ {i}) / \tau)}{\sum_ {j = 1} ^ {N} \exp (\sin (T _ {i} , I _ {j}) / \tau)}
+$$
+
+For the soft label distillation, the fusion-encoder model requires joint encoding of each image-text pair, which results in quadratic time complexity to obtain outputs. To reduce the training computation, we omit the soft label loss while only applying the cross-modal attention distillation on $N$ matched pairs with gold labels:
+
+$$
+\mathcal {L} ^ {C M C} = \mathcal {L} _ {N C E} ^ {i 2 t} + \mathcal {L} _ {N C E} ^ {t 2 i} + \mathcal {L} _ {C A} ^ {C M C} \tag {1}
+$$
+
+| Datasets | NLVR2 | SNLI-VE | VQA | Flickr30K |
| #Images | 119K | 31K | 204K | 32K |
| #Texts | 100K | 565K | 1.1M | 160K |
+
+Table 1: Statistics of downstream VL datasets.
+
+Image-Text Matching (ITM) The goal of image-text matching is to predict whether the input image and text are matched. We employ cross-modal attention distillation loss over the input pairs and soft-label loss for training:
+
+$$
+\mathcal {L} ^ {I T M} = \mathcal {L} _ {C A} ^ {I T M} + \mathcal {L} _ {S L} ^ {I T M}
+$$
+
+Masked Language Modeling (MLM) Masked language modeling aims to recover the masked tokens from the other unmasked tokens. Similarly to ITM, the student needs to mimic both cross-modal attention distributions and soft labels from the teacher:
+
+$$
+\mathcal {L} ^ {M L M} = \mathcal {L} _ {C A} ^ {M L M} + \mathcal {L} _ {S L} ^ {M L M}
+$$
+
+# 3.3.2 Fine-Tuning Distillation
+
+Vision-Language Understanding For VLU tasks, the student is fine-tuned with cross-modal attention and soft label distillation objectives:
+
+$$
+\mathcal {L} ^ {V L U} = \mathcal {L} _ {C A} ^ {V L U} + \mathcal {L} _ {S L} ^ {V L U}
+$$
+
+Image-Text Retrieval For image-text retrieval, the student is fine-tuned on the image-text retrieval task with the same objective as the CMC task (Equation 1).
+
+# 4 Experiments
+
+# 4.1 Datasets
+
+We use four commonly used datasets for pretraining: COCO (Lin et al., 2014), Conceptual Captions (Sharma et al., 2018), SBU Captions (Ordonez et al., 2011) and Visual Genome (Krishna et al., 2017), with in total 4M images. We experiment on three vision-language understanding datasets and one image-text retrieval fine-tuning dataset. Table 1 shows the statistics of datasets.
+
+Natural Language for Visual Reasoning The NLVR2 dataset (Suhr et al., 2019) is a visual reasoning task that aims to determine whether a textual statement describes a pair of images. Following previous work (Chen et al., 2020; Kim et al., 2021), we construct two pairs of image-text, each consisting of the image and a textual statement. The representations of the two pairs are fed into a classifier layer to obtain the final prediction.
+
+Visual Entailment The SNLI-VE (Xie et al., 2019) is a three-way classification dataset, aiming to predict the relationship between an image and a text hypothesis: entailment, natural, and contradiction.
+
+Visual Question Answering The task requires the model to answer questions based on the input image. We evaluate on the widely used VQAv2 (Goyal et al., 2017) dataset. Following Anderson et al. (2018), we formulate the problem as a classification task with 3,129 answer candidates.
+
+Image-Text Retrieval The task consists of two subtasks: image retrieval and text retrieval. We experiment on the Flickr30K (Plummer et al., 2015) with the standard split (Karpathy and Fei-Fei, 2015).
+
+# 4.2 Implementation Details
+
+In the main experiments, we use ViLT (Kim et al., 2021) as our teacher due to its simplicity and effective performance. The visual and textual Transformers of the student model DIDE consist of 12-layer blocks with 768 hidden size and 12 attention heads. The intermediate size of feed-forward networks is 3072. Following Kim et al. (2021), the images are resized to $384 \times 640$ resolution and the patch size is $32 \times 32$ . The maximum length of the text sequence is set to 40. We optimize DIDE with Adam (Kingma and Ba, 2015) using a batch size of 1024 for a total of 200K steps on 16 Nvidia V100 GPU cards. Note that our computation is less than the previous dual-encoder and fusion-encoder models. Refer to Appendix A for more details.
+
+For the inference stage, we cache visual representations for two reasons: (1) the averaged length of the visual tokens is longer than the textual tokens (240 vs. 40). (2) As shown in Table 1, an input image is combined with multiple text sentences. We reuse the cached visual representations with different text inputs to lower the inference latency.
+
+# 4.3 Results
+
+Vision-Language Understanding We compare DIDE with three types of vision-language pretrained models: (1) Dual-encoder models. CLIP (Radford et al., 2021) is pre-trained with image-text contrastive loss on 400M image-text pairs, significantly more than our pre-training data.
+
+| Models | NLVR2 | SNLI-VE | VQA | Inference Speedup |
| dev | test-P | val | test | test-dev | |
| Fusion-encoder models without using object region features |
| PixelBERT-R50 | 71.7 | 72.4 | - | - | 71.4 | | 0.2× |
| ViLT (Teacher) | 75.7 | 76.1 | 76.6 | 76.4 | 71.3 | | 1.0× |
| Dual-encoder models without using object region features |
| CLIP† | 50.9 | 51.1 | 68.4 | 68.6 | 50.2 | | 4.1× |
| SLIP† | 50.9 | 51.1 | 70.9 | 71.0 | 55.9 | | 4.1× |
| DeCLIP† | 50.9 | 51.1 | 69.9 | 70.2 | 59.6 | | 4.1× |
| DiDE(Ours) | 75.3 | 75.6 | 76.5 | 76.3 | 69.2 | | 4.0× |
| Using object region features from the object detector |
| VisualBERT | 67.4 | 67.0 | - | - | 70.8 | | ≪ 1.0× |
| LXMERT | 74.9 | 74.5 | - | - | 72.4 | | ≪ 1.0× |
| UNITER-Base | 75.9 | 75.8 | 78.6 | 78.3 | 72.7 | | ≪ 1.0× |
+
+Table 2: Results on vision-language understanding tasks. The results are averaged over 4 runs. We report vqa-score on VQA, accuracy for NLVR2 and SNLI-VE. $\dagger$ is our implementation of fine-tuning, which is the same as DIDE. We evaluate the inference speed of dual-encoder models and ViLT on the NLVR2 dataset with the same hyper-parameters. The inference speedup of other models is taken from Kim et al. (2021).
+
+| Models | NLVR2 | SNLI-VE | VQA |
| Online inference time |
| ViLT (Teacher) | 150.3s | 189.4s | 1103.9s |
| D1DE | 37.6s (4.0×) | 49.7s (3.8×) | 299.6s (3.7×) |
| Offline cache time |
| D1DE | 42.5s | 10.6s | 307.2s |
+
+Table 3: Averaged inference and cache time (in seconds) of our model and teacher model ViLT on three VLU datasets. The inference time and cache time are evaluated on a P100 GPU with a batch size of 32.
+
+SLIP (Mu et al., 2021) and DeCLIP (Li et al., 2022) are improvements of CLIP. SLIP introduces self-supervised contrastive loss to CLIP. DeCLIP further leverages widespread supervision among the image-text pairs. For a fair comparison, we finetune them with the same range of hyperparameters as DIDE. (2) Fusion-encoder models without the object detector, such as our teacher ViLT (Kim et al., 2021). (3) Fusion-encoder models with the object detector, such as UNITER (Chen et al., 2020), that need a pretrained object detector to extract image region features, bringing more computational overhead.
+
+Table 2 presents the performance of the VLU tasks. The results are averaged over four random seeds. DiDE achieves competitive performance compared to the ViLT teacher (retaining $99.3\%$ in NLVR2, $99.9\%$ in SNLI-VE, and $96.9\%$ in VQA) while enjoying a 4 times speedup. DiDE significantly outperforms previous dual-encoder baselines (CLIP and its variants) by a large margin. It is worth mentioning that dual-encoder baselines
+
+only achieve chance-level accuracy on the complex visual reasoning dataset NLVR2, while our DIDE obtains promising results (from 50.9 to 75.3 points). To the best of our knowledge, it is the first demonstration that the dual-encoder model can obtain promising performance on the NLVR2 dataset. Compared to other fusion-encoder models (with or without the pretrained object detector), DIDE also obtains comparable or even better results in VLU tasks. This indicates that our approach can achieve a better efficiency-performance trade-off of the VLU.
+
+Inference Speed We evaluate the latency of the student DIDE and the teacher ViLT in the batch inference setting, which is more favorable in low-latency scenarios (Zhang et al., 2019). For DIDE, we pre-compute visual representations offline and cache them. Table 3 shows the averaged inference time measured on the test split of the datasets. On all tasks, we obtain nearly 4 times online inference speedup. Even considering the offline cache time, DIDE is still faster than ViLT $(1.9 \times 3.0 \times)$ . Meanwhile, the storage cost is much cheaper than the cost of computing on GPUs (Cao et al., 2020). Thus, the dual-encoder model is more practical for production environments with massive inputs.
+
+Image-Text Retrieval To explore the generalization of our DIDE framework beyond VLU, we conduct experiments on image-text retrieval. Table 4 reports the results of the Flickr30K dataset. Our model achieves substantial speedup with competitive performance compared to the teacher model
+
+| Models | Image Retrieval | Text Retrieval | Inference Speedup |
| R@1 | R@5 | R@10 | R@1 | R@5 | R@10 |
| ViLT (Teacher) | 64.4 | 88.7 | 93.8 | 83.5 | 96.7 | 98.6 | 40398s |
| DiDE | 68.2 | 89.8 | 94.2 | 83.2 | 96.7 | 98.8 | 16.1s (2509.2×) |
| -Cross-modal attention | 66.6 | 89.2 | 93.4 | 81.6 | 95.6 | 98.4 | - |
+
+Table 4: Retrieval results on the Flickr30K dataset. “—Cross-modal attention” is ablation trained without cross-modal attention distillation. The inference speed of our model and ViLT is evaluated under the same setup.
+
+| Models | Pre-training | Fine-tuning | NLVR2 | SNLI-VE | VQA test-dev | Avg Δ |
| STD | KD | STD | KD | dev | test-P | val | test |
| DIDE | X | ✓ | X | ✓ | 75.56 | 75.26 | 76.53 | 76.33 | 69.05 | - |
| Ablations | - | - | ✓ | X | 50.85 | 51.07 | 72.10 | 71.83 | 64.94 | -12.40 |
| - | - | X | ✓ | 67.63 | 68.14 | 75.37 | 74.95 | 67.06 | -3.94 |
| ✓ | X | ✓ | X | 69.77 | 70.71 | 75.26 | 74.99 | 66.25 | -3.15 |
| ✓ | X | X | ✓ | 73.06 | 74.11 | 76.11 | 75.87 | 67.10 | -1.30 |
| X | ✓ | ✓ | X | 70.98 | 71.40 | 75.30 | 75.21 | 66.84 | -2.60 |
+
+Table 5: Ablation results on vision-language understanding tasks. "STD" denotes training with original ground truth labels. "KD" denotes the models trained using our distillation objectives.
+
+| Methods | NLVR2 | SNLI-VE | VQA |
| dev | test-P | val | test | test-dev |
| DIDE | 67.6 | 68.2 | 75.4 | 75.0 | 67.1 |
| - Soft Label | 66.8 | 67.9 | 74.2 | 74.7 | 66.9 |
| - Cross-model Attn | 50.9 | 51.1 | 73.6 | 73.5 | 66.5 |
| + Hidden States | 56.5 | 56.0 | 71.5 | 71.3 | 62.6 |
| + Uni-Modal Attn | 64.8 | 65.6 | 74.8 | 74.8 | 66.6 |
| + Whole Attn | 64.7 | 66.0 | 74.9 | 74.7 | 66.6 |
+
+Table 6: Effects of using different knowledge distillation objectives. "Attn" is short for attention distributions. "Whole Attn" is the combination of "Uni-modal Attn" and "Cross-modal Attn".
+
+ViLT. The student model DIDE even outperforms the ViLT teacher in image retrieval. Furthermore, removal of cross-modal attention distillation substantially harms performance on all metrics, showing that cross-modal attention distillation is also effective in image-text retrieval.
+
+# 4.4 Analysis
+
+Effects of Distillation in Training Stages We investigate the effect of applying our proposed distillation in the pre-training and fine-tuning stages. We compare with the baseline trained without distillation objectives, as the standard training.
+
+Table 5 shows the evaluation results. Without the pre-training initialization, the models are directly initialized by the weights of pretrained ViLT. We can observe that without the pre-training stage, the performance significantly drops across tasks. Under this setting, without the proposed distillation training, the model obtains a chance-level performance on NLVR2, similar to previous work (Kim
+
+et al., 2021; Shen et al., 2021). But our distillation method substantially improves the results, reducing the gap from $-12.40$ to $-3.94$ . This indicates that our distillation method is better than standard training, even without pre-training. Furthermore, in the pre-training stage, the model still benefited from the distillation objectives compared with the standard training. Another interesting observation is that fine-tuning distillation brings more gains compared to pre-training distillation. This suggests that it is crucial for dual-encoder models to learn more ability of the task-specific cross-modal interactions. Overall, performing our proposed method in both pre-training and fine-tuning stages delivers the best performance across VLU tasks.
+
+Effects of Different Distilled Knowledge We investigate the effects of different knowledge used in our framework. The compared ablations include training without soft label distillation $(- \text{soft label})$ or cross-modal attention distillation $(- \text{cross-modal attn})$ . For more clarity, the dual-encoder student models are directly initialized by the pretrained ViLT and fine-tuned with varying distillation objectives.
+
+Table 6 illustrates the results of the VLU tasks. We find that both distillation objectives contribute to the success of the DIDE framework, while the proposed cross-modal attention distillation is more critical than soft label distillation. The student only trained with the soft label distillation objective only achieves random performance on NLVR2. We further incorporate other intermediate representations
+
+| Methods | NLVR2 | SNLI-VE | VQA |
| dev | test-P | val | test | test-dev |
| Last Layer (Ours) | 67.6 | 68.2 | 75.4 | 75.0 | 67.1 |
| Top-Layers Layerwise | 66.0 | 67.3 | 75.2 | 74.8 | 66.8 |
| Bottom-Layers Layerwise | 63.5 | 63.0 | 75.1 | 74.7 | 66.6 |
| All-Layers Layerwise | 67.0 | 67.4 | 75.2 | 74.8 | 66.8 |
+
+Table 7: Effects of different layer mapping strategies for our distillation method.
+
+
+Figure 3: NLVR2 results of models initialized by OSCAR or METER. "Ours" means that besides the soft label distillation, the dual-encoder model also trained with our proposed cross-modal attention distillation.
+
+of the teacher model, except for cross-modal attention. We observe that using attention distributions brings more gains across three tasks compared to the hidden states. Furthermore, we also explore which part of the attention distribution is more critical, cross-modal attention or uni-modal attention. As shown in Table 6, mimicking the teacher's cross-modal attention distributions achieves more improvements. Furthermore, we find that only the use of cross-modal attention distributions performs better than using the whole attention distributions (cross-modal + uni-modal). These observations validate our motivation that cross-modal interactions are more crucial for VLU tasks.
+
+Effects of Different Layer Mapping Strategies for Distillation. To validate the effectiveness of distilling the knowledge of the teacher last layer for the student, we compare it with the layer-wise mapping strategy, including all layers, the upper part of layers, and the bottom part of layers. As shown in Table 7, last-layer strategy obtains better results. Furthermore, our strategy requires less computation than the layerwise methods. Thus, distillation in the last layer is more practical.
+
+Effects on other VLP models. To evaluate the generalization of DIDE, in addition to ViLT (Kim et al., 2021), we also conduct experiments on NLVR2 with two other fusion-encoder vision-language pretrained models, OSCAR (Li et al., 2020) and METER (Dou et al., 2022). The architectures of two models are different from ViLT: Oscar applies the pretrained object detector to extract visual features. METER uses the visual encoder of CLIP to encode image patches and also applies RoBERTa (Liu et al., 2019) as textual encoder. The visual and textual representations are then fused by a multi-layer Transformer network.
+
+We directly adopt the pretrained models to initialize the dual-encoder model and take the fine-tuned models as the teacher. We compare our method with the baselines supervised only by the gold labels of the original dataset and the soft label from the teacher model. Figure 3 illustrates the performance of the methods. For the models initialized by OSCAR and METER, we observe that only fine-tuning with gold labels or soft labels can not benefit the performance of the dual-encoder model on the complex visual reasoning task NLVR2. On the contrary, our method can improve performance by a large margin on both models, which is consistent with the results on ViLT. Our proposed cross-modal attention distillation shows effectiveness on different architectures of vision-language models.
+
+# 5 Conclusion
+
+On vision-language understanding tasks, fusion-encoder models obtain superior performance while sacrifice efficiency. In contrast, dual-encoder models have the advantage of efficiency, but previous models are insufficient to handle complex vision-language understanding. In this work, to obtain the efficiency-performance trade-off, we propose DIDE, a knowledge distillation framework for dual-encoder models to improve their performance on VLU tasks while retaining their efficiency. The key of DIDE is that we employ the cross-modal attention of a fusion encoder model as fine-grained supervision to guide the dual-encoder model for learning complex cross-modal interactions. Experimental results on several vision-language understanding tasks show that our DIDE achieves competitive performance with a four-time speedup over the fusion-encoder teacher model. Further analyses verify that distillation with cross-modal attention is critical for dual-encoder models.
+
+# Limitations
+
+DIDE is pretrained on the publicly accessible resources consisting of 4M image-text pairs. We do not have enough computational resources to explore the situation with larger data, as used in CLIP (Radford et al., 2021). It is also interesting to combine our approach with other model acceleration methods summarized in Xu et al. (2021) to further toward Green AI (Schwartz et al., 2020).
+
+# Acknowledgements
+
+We thank anonymous reviewers for their insightful feedback that helped improve the paper. We acknowledge Haoyang Wen, Yang Xu, and Yiheng Xu for helpful discussions. Zekun Wang, Haichao Zhu, Ming Liu, and Bing Qin are supported by the Science and Technology Innovation 2030 - "New Generation Artificial Intelligence" Major Project (2018AA0101901), the National Science Foundation of China (61976073, 62276083), Shenzhen Foundational Research Funding (JCYJ20200109113441941), the Project of State Key Laboratory of Communication Content Cognition (A02101), the Major Key Project of PCL (PCL2021A06). Ming Liu is the corresponding author.
+
+# References
+
+Jean-Baptiste Alayrac, Jeff Donahue, Pauline Luc, Antoine Miech, Iain Barr, Yana Hasson, Karel Lenc, Arthur Mensch, Katie Millican, Malcolm Reynolds, Roman Ring, Eliza Rutherford, Serkan Cabi, Tengda Han, Zhitao Gong, Sina Samangooei, Marianne Monteiro, Jacob Menick, Sebastian Borgeaud, Andrew Brock, Aida Nematzadeh, Sahand Sharifzadeh, Nikolaj Binkowski, Ricardo Barreira, Oriol Vinyals, Andrew Zisserman, and Karen Simonyan. 2022. Flamingo: a visual language model for few-shot learning. CoRR, abs/2204.14198.
+Peter Anderson, Xiaodong He, Chris Buehler, Damien Teney, Mark Johnson, Stephen Gould, and Lei Zhang. 2018. Bottom-up and top-down attention for image captioning and visual question answering. In 2018 IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2018, Salt Lake City, UT, USA, June 18-22, 2018, pages 6077-6086. Computer Vision Foundation / IEEE Computer Society.
+Hangbo Bao, Li Dong, and Furu Wei. 2021. BEiT: BERT pre-training of image transformers. CoRR, abs/2106.08254.
+Hangbo Bao, Li Dong, Furu Wei, Wenhui Wang, Nan Yang, Xiaodong Liu, Yu Wang, Jianfeng Gao, Song-hao Piao, Ming Zhou, and Hsiao-Wuen Hon. 2020.
+
+UniLMv2: Pseudo-masked language models for unified language model pre-training. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event, volume 119 of Proceedings of Machine Learning Research, pages 642-652. PMLR.
+Qingqing Cao, Harsh Trivedi, Aruna Balasubramanian, and Niranjan Balasubramanian. 2020. Deformer: Decomposing pre-trained transformers for faster question answering. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 4487-4497. Association for Computational Linguistics.
+Yen-Chun Chen, Linjie Li, Licheng Yu, Ahmed El Kholy, Faisal Ahmed, Zhe Gan, Yu Cheng, and Jingjing Liu. 2020. UNITER: universal image-text representation learning. In Computer Vision - ECCV 2020 - 16th European Conference, Glasgow, UK, August 23-28, 2020, Proceedings, Part XXX, volume 12375 of Lecture Notes in Computer Science, pages 104-120. Springer.
+Zewen Chi, Shaohan Huang, Li Dong, Shuming Ma, Saksham Singhal, Payal Bajaj, Xia Song, and Furu Wei. 2021. XLM-E: cross-lingual language model pre-training via ELECTRA. CoRR, abs/2106.16138.
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettle-moyer, and Veselin Stoyanov. 2020. Unsupervised cross-lingual representation learning at scale. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8440-8451, Online. Association for Computational Linguistics.
+Ekin Dogus Cubuk, Barret Zoph, Jon Shlens, and Quoc Le. 2020. Randaugment: Practical automated data augmentation with a reduced search space. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics.
+Li Dong, Nan Yang, Wenhui Wang, Furu Wei, Xiaodong Liu, Yu Wang, Jianfeng Gao, Ming Zhou, and Hsiao-Wuen Hon. 2019. Unified language model pre-training for natural language understanding and generation. In Advances in Neural Information Processing Systems 32: Annual Conference on Neural
+
+Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 13042-13054.
+Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. 2021. An image is worth 16x16 words: Transformers for image recognition at scale. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net.
+Zi-Yi Dou, Yichong Xu, Zhe Gan, Jianfeng Wang, Shuohang Wang, Lijuan Wang, Chenguang Zhu, Pengchuan Zhang, Lu Yuan, Nanyun Peng, Zicheng Liu, and Michael Zeng. 2022. An empirical study of training end-to-end vision-and-language transformers.
+Zhiyuan Fang, Jianfeng Wang, Xiaowei Hu, Lijuan Wang, Yezhou Yang, and Zicheng Liu. 2021. Compressing visual-linguistic model via knowledge distillation. In 2021 IEEE/CVF International Conference on Computer Vision, ICCV 2021, Montreal, QC, Canada, October 10-17, 2021, pages 1408-1418. IEEE.
+Zhe Gan, Yen-Chun Chen, Linjie Li, Chen Zhu, Yu Cheng, and Jingjing Liu. 2020. Large-scale adversarial training for vision-and-language representation learning. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Yash Goyal, Tejas Khot, Douglas Summers-Stay, Dhruv Batra, and Devi Parikh. 2017. Making the V in VQA matter: Elevating the role of image understanding in visual question answering. In 2017 IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2017, Honolulu, HI, USA, July 21-26, 2017, pages 6325-6334. IEEE Computer Society.
+Yaru Hao, Li Dong, Furu Wei, and Ke Xu. 2021. Self-attention attribution: Interpreting information interactions inside transformer. In Thirty-Fifth AAAI Conference on Artificial Intelligence, AAAI 2021, Thirty-Third Conference on Innovative Applications of Artificial Intelligence, IAAI 2021, The Eleventh Symposium on Educational Advances in Artificial Intelligence, EAAI 2021, Virtual Event, February 2-9, 2021, pages 12963-12971. AAAI Press.
+Lisa Anne Hendricks, John Mellor, Rosalia Schneider, Jean-Baptiste Alayrac, and Aida Nematzadeh. 2021. Decoupling the role of data, attention, and losses in multimodal transformers. Trans. Assoc. Comput. Linguistics, 9:570-585.
+Geoffrey E. Hinton, Oriol Vinyals, and Jeffrey Dean. 2015. Distilling the knowledge in a neural network. CoRR, abs/1503.02531.
+
+Sebastian Hofstätter, Sophia Althammer, Michael Schröder, Mete Sertkan, and Allan Hanbury. 2020. Improving efficient neural ranking models with cross-architecture knowledge distillation. CoRR, abs/2010.02666.
+Zhicheng Huang, Zhaoyang Zeng, Bei Liu, Dongmei Fu, and Jianlong Fu. 2020. Pixel-bert: Aligning image pixels with text by deep multi-modal transformers. CoRR, abs/2004.00849.
+Chao Jia, Yinfei Yang, Ye Xia, Yi-Ting Chen, Zarana Parekh, Hieu Pham, Quoc V. Le, Yun-Hsuan Sung, Zhen Li, and Tom Duerig. 2021. Scaling up visual and vision-language representation learning with noisy text supervision. In Proceedings of the 38th International Conference on Machine Learning, ICML 2021, 18-24 July 2021, Virtual Event, volume 139 of Proceedings of Machine Learning Research, pages 4904-4916. PMLR.
+Xiaoqi Jiao, Yichun Yin, Lifeng Shang, Xin Jiang, Xiao Chen, Linlin Li, Fang Wang, and Qun Liu. 2020. Tinybert: Distilling BERT for natural language understanding. In Findings of the Association for Computational Linguistics: EMNLP 2020, Online Event, 16-20 November 2020, volume EMNLP 2020 of Findings of ACL, pages 4163-4174. Association for Computational Linguistics.
+Andrej Karpathy and Li Fei-Fei. 2015. Deep visual-semantic alignments for generating image descriptions. In IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2015, Boston, MA, USA, June 7-12, 2015, pages 3128-3137. IEEE Computer Society.
+Wonjae Kim, Bokyung Son, and Ildoo Kim. 2021. Vilt: Vision-and-language transformer without convolution or region supervision. In Proceedings of the 38th International Conference on Machine Learning, volume 139 of Proceedings of Machine Learning Research, pages 5583-5594. PMLR.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
+Ranjay Krishna, Yuke Zhu, Oliver Groth, Justin Johnson, Kenji Hata, Joshua Kravitz, Stephanie Chen, Yannis Kalantidis, Li-Jia Li, David A. Shamma, Michael S. Bernstein, and Li Fei-Fei. 2017. Visual genome: Connecting language and vision using crowdsourced dense image annotations. Int. J. Comput. Vis., 123(1):32-73.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics,
+
+ACL 2020, Online, July 5-10, 2020, pages 7871-7880.
+Association for Computational Linguistics.
+Junnan Li, Ramprasaath R. Selvaraju, Akhilesh Deepak Gotmare, Shafiq R. Joty, Caiming Xiong, and Steven C. H. Hoi. 2021a. Align before fuse: Vision and language representation learning with momentum distillation. CoRR, abs/2107.07651.
+Lianian Harold Li, Mark Yatskar, Da Yin, Cho-Jui Hsieh, and Kai-Wei Chang. 2019. Visualbert: A simple and performant baseline for vision and language. CoRR, abs/1908.03557.
+Wei Li, Can Gao, Guocheng Niu, Xinyan Xiao, Hao Liu, Jiachen Liu, Hua Wu, and Haifeng Wang. 2021b. UNIMO: towards unified-modal understanding and generation via cross-modal contrastive learning. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 1: Long Papers), Virtual Event, August 1-6, 2021, pages 2592-2607. Association for Computational Linguistics.
+Xiujun Li, Xi Yin, Chunyuan Li, Pengchuan Zhang, Xiaowei Hu, Lei Zhang, Lijuan Wang, Houdong Hu, Li Dong, Furu Wei, Yejin Choi, and Jianfeng Gao. 2020. Oscar: Object-semantics aligned pretraining for vision-language tasks. In Computer Vision - ECCV 2020 - 16th European Conference, Glasgow, UK, August 23-28, 2020, Proceedings, Part XXX, volume 12375 of Lecture Notes in Computer Science, pages 121-137. Springer.
+Yangguang Li, Feng Liang, Lichen Zhao, Yufeng Cui, Wanli Ouyang, Jing Shao, Fengwei Yu, and Junjie Yan. 2022. Supervision exists everywhere: A data efficient contrastive language-image pre-training paradigm. In International Conference on Learning Representations.
+Tsung-Yi Lin, Michael Maire, Serge J. Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dólar, and C. Lawrence Zitnick. 2014. Microsoft COCO: common objects in context. In Computer Vision - ECCV 2014 - 13th European Conference, Zurich, Switzerland, September 6-12, 2014, Proceedings, Part V, volume 8693 of Lecture Notes in Computer Science, pages 740-755. Springer.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized BERT pretraining approach. CoRR, abs/1907.11692.
+Jiasen Lu, Dhruv Batra, Devi Parikh, and Stefan Lee. 2019. Vilbert: Pretraining task-agnostic visiolinguistic representations for vision-and-language tasks. In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 13-23.
+
+Antoine Miech, Jean-Baptiste Alayrac, Ivan Laptev, Josef Sivic, and Andrew Zisserman. 2021. Thinking fast and slow: Efficient text-to-visual retrieval with transformers. In IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2021, virtual, June 19-25, 2021, pages 9826-9836. Computer Vision Foundation / IEEE.
+Norman Mu, Alexander Kirillov, David A. Wagner, and Saining Xie. 2021. SLIP: self-supervision meets language-image pre-training. CoRR, abs/2112.12750.
+Vicente Ordonez, Girish Kulkarni, and Tamara L. Berg. 2011. Im2text: Describing images using 1 million captioned photographs. In Advances in Neural Information Processing Systems 24: 25th Annual Conference on Neural Information Processing Systems 2011. Proceedings of a meeting held 12-14 December 2011, Granada, Spain, pages 1143-1151.
+Bryan A. Plummer, Liwei Wang, Chris M. Cervantes, Juan C. Caicedo, Julia Hockenmaier, and Svetlana Lazebnik. 2015. Flickr30k entities: Collecting region-to-phrase correspondences for richer imageto-sentence models. In 2015 IEEE International Conference on Computer Vision, ICCV 2015, Santiago, Chile, December 7-13, 2015, pages 2641-2649. IEEE Computer Society.
+Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. 2021. Learning transferable visual models from natural language supervision. In Proceedings of the 38th International Conference on Machine Learning, ICML 2021, 18-24 July 2021, Virtual Event, volume 139 of Proceedings of Machine Learning Research, pages 8748-8763. PMLR.
+Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. 2018. Improving language understanding by generative pre-training.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 21:140:1-140:67.
+Shaoqing Ren, Kaiming He, Ross B. Girshick, and Jian Sun. 2015. Faster R-CNN: towards real-time object detection with region proposal networks. In Advances in Neural Information Processing Systems 28: Annual Conference on Neural Information Processing Systems 2015, December 7-12, 2015, Montreal, Quebec, Canada, pages 91-99.
+Roy Schwartz, Jesse Dodge, Noah A. Smith, and Oren Etzioni. 2020. *Green AI. Commun. ACM*, 63(12):54-63.
+Piyush Sharma, Nan Ding, Sebastian Goodman, and Radu Soricut. 2018. Conceptual captions: A cleaned,
+
+hypernymed, image alt-text dataset for automatic image captioning. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics, ACL 2018, Melbourne, Australia, July 15-20, 2018, Volume 1: Long Papers, pages 2556-2565. Association for Computational Linguistics.
+Sheng Shen, Liunian Harold Li, Hao Tan, Mohit Bansal, Anna Rohrbach, Kai-Wei Chang, Zhewei Yao, and Kurt Keutzer. 2021. How much can CLIP benefit vision-and-language tasks? CoRR, abs/2107.06383.
+Weijie Su, Xizhou Zhu, Yue Cao, Bin Li, Lewei Lu, Furu Wei, and Jifeng Dai. 2020. VL-BERT: pretraining of generic visual-linguistic representations. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Alane Suhr, Stephanie Zhou, Ally Zhang, Iris Zhang, Huajun Bai, and Yoav Artzi. 2019. A corpus for reasoning about natural language grounded in photographs. In Proceedings of the 57th Conference of the Association for Computational Linguistics, ACL 2019, Florence, Italy, July 28- August 2, 2019, Volume 1: Long Papers, pages 6418-6428. Association for Computational Linguistics.
+Siqi Sun, Yen-Chun Chen, Linjie Li, Shuohang Wang, Yuwei Fang, and Jingjing Liu. 2021. Lightningdot: Pre-training visual-semantic embeddings for real-time image-text retrieval. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2021, Online, June 6-11, 2021, pages 982-997. Association for Computational Linguistics.
+Hao Tan and Mohit Bansal. 2019. LXMERT: learning cross-modality encoder representations from transformers. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 5099-5110. Association for Computational Linguistics.
+Hugo Touvron, Matthieu Cord, Matthijs Douze, Francisco Massa, Alexandre Sablayrolles, and Hervé Jégou. 2021. Training data-efficient image transformers & distillation through attention. In Proceedings of the 38th International Conference on Machine Learning, ICML 2021, 18-24 July 2021, Virtual Event, volume 139 of Proceedings of Machine Learning Research, pages 10347-10357. PMLR.
+Aaron van den Oord, Yazhe Li, and Oriol Vinyals. 2018. Representation learning with contrastive predictive coding. CoRR, abs/1807.03748.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems 30: Annual Conference on Neural
+
+Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pages 5998-6008.
+Wenhui Wang, Hangbo Bao, Li Dong, and Furu Wei. 2021a. Vlmo: Unified vision-language pretraining with mixture-of-modality-experts. CoRR, abs/2111.02358.
+Wenhui Wang, Furu Wei, Li Dong, Hangbo Bao, Nan Yang, and Ming Zhou. 2020. Minilm: Deep self-attention distillation for task-agnostic compression of pre-trained transformers. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Zirui Wang, Jiahui Yu, Adams Wei Yu, Zihang Dai, Yulia Tsvetkov, and Yuan Cao. 2021b. Simvlm: Simple visual language model pretraining with weak supervision. CoRR, abs/2108.10904.
+Ning Xie, Farley Lai, Derek Doran, and Asim Kadav. 2019. Visual entailment: A novel task for fine-grained image understanding. CoRR, abs/1901.06706.
+Jingjing Xu, Wangchunshu Zhou, Zhiyi Fu, Hao Zhou, and Lei Li. 2021. A survey on green deep learning. CoRR, abs/2111.05193.
+Chengliang Zhang, Minchen Yu, Wei Wang, and Feng Yan. 2019. Mark: Exploiting cloud services for cost-effective, slo-aware machine learning inference serving. In 2019 USENIX Annual Technical Conference, USENIX ATC 2019, Renton, WA, USA, July 10-12, 2019, pages 1049-1062. USENIX Association.
+Pengchuan Zhang, Xiujun Li, Xiaowei Hu, Jianwei Yang, Lei Zhang, Lijuan Wang, Yejin Choi, and Jianfeng Gao. 2021. Vinvl: Revisiting visual representations in vision-language models. In IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2021, virtual, June 19-25, 2021, pages 5579-5588. Computer Vision Foundation / IEEE.
+
+# A Details of Hyperparameters
+
+For pre-training, visual and textual encoders of DIDE are initialized by the weights of the teacher model. We use Adam (Kingma and Ba, 2015) with $\beta_{1} = 0.9$ , $\beta_{2} = 0.999$ for optimization. The learning rate is set to 1e-4, with the warm-up ration of 0.1, and linear decay. The weight decay is set to 0.01. For the ITM task, we replace the matched image with the probability of 0.5 to construct negative examples following previous work (Chen et al., 2020; Li et al., 2020; Kim et al., 2021). For the MLM task, we use $15\%$ masking probability as in BERT (Devlin et al., 2019). For the downstream fine-tuning, we follow most of the hyperparameters in Kim et al. (2021). We fine-tune the model for 10 epochs with a batch size of 256 for VQA and
+
+SNLI-VE. For NLVR2, we train the model for 20 epochs with a batch size of 128. For Flickr30k, the model is trained for 20 epochs with a batch size of 1024. We apply RandAugment (Cubuk et al., 2020) without color inversion and cutout.
\ No newline at end of file
diff --git a/distilleddualencodermodelforvisionlanguageunderstanding/images.zip b/distilleddualencodermodelforvisionlanguageunderstanding/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..15c54d9436602773ac737a83762a28d94745c7e8
--- /dev/null
+++ b/distilleddualencodermodelforvisionlanguageunderstanding/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9771a471a17a8e5f794fc5919c61d62c3bc9656119d500873707c665e955fbb0
+size 383982
diff --git a/distilleddualencodermodelforvisionlanguageunderstanding/layout.json b/distilleddualencodermodelforvisionlanguageunderstanding/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d722163460381c5824d95b92f4ea749d704ca76d
--- /dev/null
+++ b/distilleddualencodermodelforvisionlanguageunderstanding/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4c4571c51dc25a0adc4e57be3f6e789244a88e550bcaf11a5a4839106ad1c257
+size 403106
diff --git a/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_content_list.json b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..f35c0982b5030f5eaf22b33228b8f45569d2e1ea
--- /dev/null
+++ b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:db6a0424ffbb42ddde3bcdcbb207cc303f8244ffdd8e20ed90f6a795f8478515
+size 97648
diff --git a/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_model.json b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..3e93ebe8949d51e837de25a62abf5b2d1a1347ec
--- /dev/null
+++ b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:605e5078a80ebab532f9f3614c9c83356db06bffda81e7b2ae11c344936e2574
+size 116126
diff --git a/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_origin.pdf b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..75c5d9394fe31363572b3ef25bea613d2d9c5f78
--- /dev/null
+++ b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/f436fd99-5809-4921-9dbb-5bd8a9b8cdfd_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bed888b3648f383198c2d25ccde80e4795faa324a9a7aa0d7e72c78d6fd36b26
+size 1262663
diff --git a/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/full.md b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..1094f3278bea4834ab22eeec78988e105e260c77
--- /dev/null
+++ b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/full.md
@@ -0,0 +1,428 @@
+# Distilling Causal Effect from Miscellaneous Other-Class for Continual Named Entity Recognition
+
+Junhao Zheng, Zhanxian Liang, Haibin Chen, Qianli Ma*
+
+School of Computer Science and Engineering, South China University of Technology, Guangzhou, China junhaozheng47@outlook.com, qianlima@scut.edu.cn*
+
+# Abstract
+
+Continual Learning for Named Entity Recognition (CL-NER) aims to learn a growing number of entity types over time from a stream of data. However, simply learning Other-Class in the same way as new entity types amplifies the catastrophic forgetting and leads to a substantial performance drop. The main cause behind this is that Other-Class samples usually contain old entity types, and the old knowledge in these Other-Class samples is not preserved properly. Thanks to the causal inference, we identify that the forgetting is caused by the missing causal effect from the old data. To this end, we propose a unified causal framework to retrieve the causality from both new entity types and Other-Class. Furthermore, we apply curriculum learning to mitigate the impact of label noise and introduce a self-adaptive weight for balancing the causal effects between new entity types and Other-Class. Experimental results on three benchmark datasets show that our method outperforms the state-of-the-art method by a large margin. Moreover, our method can be combined with the existing state-of-the-art methods to improve the performance in CL-NER.
+
+# 1 Introduction
+
+Named Entity Recognition (NER) is a vital task in various NLP applications (Ma and Hovy, 2016). Traditional NER aims at extracting entities from unstructured text and classifying them into a fixed set of entity types (e.g., Person, Location, Organization, etc). However, in many real-world scenarios, the training data are streamed, and the NER systems are required to recognize new entity types to support new functionalities, which can be formulated into the paradigm of continual learning (CL, a.k.a. incremental learning or lifelong learning)
+
+
+Figure 1: An illustration of Other-class in CL-NER. Suppose that a model learns four entity types in CoNLL2003 sequentially. "LOC": Location; "MISC": Miscellaneous; "ORG": Organisation; "PER": Person.
+
+(Thrun, 1998; Parisi et al., 2019). For instance, voice assistants such as Siri or Alexa are often required to extract new entity types (e.g. Song, Band) for grasping new intents (e.g. GetMusic) (Monaikul et al., 2021).
+
+However, as is well known, continual learning faces a serious challenge called catastrophic forgetting in learning new knowledge (McCloskey and Cohen, 1989; Robins, 1995; Goodfellow et al., 2013; Kirkpatrick et al., 2017). More specifically, simply fine-tuning a NER system on new data usually leads to a substantial performance drop on previous data. In contrast, a child can naturally learn new concepts (e.g., Song and Band) without forgetting the learned concepts (e.g., Person and Location). Therefore, continual learning for NER (CL-NER) is a ubiquitous issue and a big challenge in achieving human-level intelligence.
+
+In the standard setting of continual learning, only new entity types are recognized by the model in each CL step. For CL-NER, the new dataset contains not only new entity types but also Other-class tokens which do not belong to any new entity types. For instance, about $89\%$ tokens belongs to Other-class in OntoNotes5 (Hovy et al., 2006). Unlike accuracy-oriented tasks such as the image/text classification, NER inevitably introduces a vast number of Other-class samples in training data. As a result, the model strongly biases towards Other-class (Li et al., 2020). Even worse, the meaning of Other-class varies along with the continual learning pro
+
+
+Figure 2: An illustration of the impact of Other-class samples on OntoNotes5. We consider two scenarios with different extra annotation levels on Other-class samples: (1) annotate all recognized entity types on the data in the current CL step (Current); (2) no extra annotations on Other-class samples (None).
+
+cess. For example, "Europe" is tagged as Location if and only if the entity type Location is learned in the current CL step. Otherwise, the token "Europe" will be tagged as Other-class. An illustration is given in Figure 1 to demonstrate Other-class in CL-NER. In a nutshell, the continually changing meaning of Other-class as well as the imbalance between the entity and Other-class tokens amplify the forgetting problem in CL-NER.
+
+Figure 2 is an illustration of the impact of Other-class samples. We divide the training set into 18 disjoint splits, and each split corresponds to one entity type to learn. Then, we only retain the labels of the corresponding entity type in each split while the other tokens are tagged as Other-class. Next, the NER model learns 18 entity types one after another, as in CL. To eliminate the impact of forgetting, we assume that all recognized training data can be stored. Figure 2 shows two scenarios where Other-class samples are additionally annotated with ground-truth labels or not. Results show that ignoring the different meanings of Other-classes affects the performance dramatically. The main cause is that Other-class contains old entities. From another perspective, the old entities in Other-class are similar to the reserved samples of old classes in the data replay strategy (Rebuffi et al., 2017). Therefore, we raise a question: how can we learn from Other-class samples for anti-forgetting in CL-NER?
+
+In this study, we address this question with a Causal Framework for CL-NER (CFNER) based on causal inference (Glymour et al., 2016; Schölkopf, 2022). Through causal lenses, we determine that the crux of CL-NER lies in establishing causal links from the old data to new entity types
+
+and Other-class. To achieve this, we utilize the old model (i.e., the NER model trained on old entity types) to recognize old entities in Other-class samples and distillate causal effects (Glymour et al., 2016) from both new entity types and Other-class simultaneously. In this way, the causality of Other-class can be learned to preserve old knowledge, while the different meanings of Other-classes can be captured dynamically. In addition, we design a curriculum learning (Bengio et al., 2009) strategy to enhance the causal effect from Other-class by mitigating the label noise generated by the old model. Moreover, we introduce a self-adaptive weight to dynamically balance the causal effects from Other-class and new entity types. Extensive experiments on three benchmark NER datasets, i.e., OntoNotes5, i2b2 (Murphy et al., 2010) and CoNLL2003 (Sang and De Meulder, 2003), validate the effectiveness of the proposed method. The experimental results show that our method outperforms the previous state-of-the-art method in CL-NER significantly. The main contributions are summarized as follows:
+
+- We frame CL-NER into a causal graph (Pearl, 2009) and propose a unified causal framework to retrieve the causalities from both Other-class and new entity types.
+- We are the first to distillate causal effects from Other-class for anti-forgetting in CL, and we propose a curriculum learning strategy and a self-adaptive weight to enhance the causal effect in Other-class.
+- Through extensive experiments, we show that our method achieves the state-of-the-art performance in CL-NER and can be implemented as a plug-and-play module to further improve the performances of other CL methods.
+
+# 2 Related Work
+
+# 2.1 Continual Learning for NER
+
+Despite the fast development of CL in computer vision, most of these methods (Douillard et al., 2020; Rebuffi et al., 2017; Hou et al., 2019) are devised for accuracy-oriented tasks such as image classification and fail to preserve the old knowledge in Other-class samples. In our experiment, we find that simply applying these methods to CL-NER does not lead to satisfactory performances.
+
+In CL-NER, a straightforward solution for learning old knowledge from Other-class samples is
+
+self-training (Rosenberg et al., 2005; De Lange et al., 2019). In each CL step, the old model is used to annotate the Other-class samples in the new dataset. Next, a new NER model is trained to recognize both old and new entity types in the dataset. The main disadvantage of self-training is that the errors caused by wrong predictions of the old model are propagated to the new model (Monaikul et al., 2021). Monaikul et al. (2021) proposed a method based on knowledge distillation (Hinton et al., 2015) called ExtendNER where the old model acts as a teacher and the new model acts as a student. Compared with self-training, this distillation-based method takes the uncertainty of the old model's predictions into consideration and reaches the state-of-the-art performance in CLNER.
+
+Recently, Das et al. (2022) alleviates the problem of Other-tokens in few-shot NER by contrastive learning and pretraining techniques. Unlike them, our method explicitly alleviates the problem brought by Other-Class tokens through a causal framework in CL-NER.
+
+# 2.2 Causal Inference
+
+Causal inference (Glymour et al., 2016; Schölkopf, 2022) has been recently introduced to various computer vision and NLP tasks, such as semantic segmentation (Zhang et al., 2020), long-tailed classification (Tang et al., 2020; Nan et al., 2021), distantly supervised NER (Zhang et al., 2021) and neural dialogue generation (Zhu et al., 2020). Hu et al. (2021) first applied causal inference in CL and pointed out that the vanishing old data effect leads to forgetting. Inspired by the causal view in (Hu et al., 2021), we mitigate the forgetting problem in CL-NER by mining the old knowledge in Other-class samples.
+
+# 3 Causal Views on (Anti-) Forgetting
+
+In this section, we explain the (anti-) forgetting in CL from a causal perspective. First, we model the causalities among data, feature, and prediction at any consecutive CL step with a causal graph (Pearl, 2009) to identify the forgetting problem. The causal graph is a directed acyclic graph whose nodes are variables, and directed edges are causalities between nodes. Next, we introduce how causal effects are utilized for anti-forgetting.
+
+# 3.1 Causal Graph
+
+Figure 3a shows the causal graph of CL-NER when no anti-forgetting techniques are used. Specifically, we denote the old data as $S$ ; the new data as $D$ ; the feature of new data extracted from the old and new model as $X_0$ and $X$ ; the prediction of new data as $\hat{Y}$ (i.e., the probability distribution (scores)). The causality between notes is as follows: (1) $D \rightarrow X \rightarrow \hat{Y}$ : $D \rightarrow X$ represents that the feature $X$ is extracted by the backbone model (e.g., BERT (Devlin et al., 2019)), and $X \rightarrow \hat{Y}$ indicates that the prediction $\hat{Y}$ is obtained by using the feature $X$ with the classifier (e.g., a fully-connected layer); (2) $S \rightarrow X_0 \leftarrow D$ : these links represent that the old feature representation of new data $X_0$ is determined by the new data $D$ and the old model trained on old data $S$ . Figure 3a shows that the forgetting happens because there are no causal links between $S$ and $\hat{Y}$ . More explanations about the forgetting in CL-NER are demonstrated in Appendix A.
+
+# 3.2 Colliding Effects
+
+In order to build cause paths from $S$ to $\hat{Y}$ , a naive solution is to store (a fraction of) old data, resulting in a causal link $S \rightarrow D$ is built. However, storing old data contradicts the scenario of CL to some extent. To deal with this dilemma, Hu et al. (2021) proposed to add a causal path $S \leftrightarrow D$ between old and new data by using Colliding Effect (Glymour et al., 2016). Consequently, $S$ and $D$ will be correlated to each other when we control the collider $X_0$ . Here is an intuitive example: a causal graph sprinkler $\rightarrow$ pavement $\leftarrow$ weather represents the pavement's condition (wet/dry) is determined by both the weather (rainy/sunny) and the sprinkler (on/off). Typically, the weather and the sprinkler are independent of each other. However, if we observe that the pavement is wet and know that the sprinkler is off, we can infer that the weather is likely to be rainy, and vice versa.
+
+# 4 A Causal Framework for CL-NER
+
+In this section, we frame CL-NER into a causal graph and identify that learning the causality in Other-class is crucial for CL-NER. Based on the characteristic of CL-NER, we propose a unified causal framework to retrieve the causalities from both Other-class and new entity types. We are the first to distillate causal effects from Other-class for anti-forgetting in CL. Furthermore, we introduce
+
+
+(a) forgetting
+
+
+(b) anti-forgetting
+
+
+Figure 3: The causal graph for CL-NER: (a) forgetting happens when there are no causal paths from old data to new predictions; (b) anti-forgetting is to build causal paths from old data to new predictions through new entities $(D^{E})$ and Other-class samples $(D^{O})$ . We call the causal effects in these two links $Effect_{E}$ and $Effect_{O}$ , respectively.
+(a) Initial
+
+
+(b) w/o Colliding Effect
+
+
+(c) w/ Colliding Effect
+Figure 4: A demonstration of the colliding effect. The anchor token's feature (anchor features) collides with matched tokens' features (matched features) on the colliding feature in the old feature space. (a) initial: the class boundary is retained since the new model is initialized by the old model condition. (b) w/o Colliding Effect: the class boundary is forgot in the new feature space since there are no causal effects from old data to new predictions. (c) w/ Colliding Effect: the class boundary is preserved after an CL step since the anchor and matched tokens collide in the old feature space.
+
+
+
+a curriculum-learning-based strategy and a self-adaptive weight to allow the model to better learn the causalities from Other-class samples.
+
+# 4.1 Problem Formulation
+
+In the $i$ -th CL step, given an NER model $M_{i}$ which is trained on a set of entities $E_{i} = \{e_{1}, e_{2}, \dots, e_{n_{i}}\}$ , the target of CL-NER is to learn the best NER model $M_{i+1}$ to identify the extended entity set $E_{i+1} = \{e_{1}, e_{2}, \dots, e_{n_{i+1}}\}$ with a training set annotated only with $E_{i}^{New} = \{e_{n_{i+1}}, e_{n_{i+2}}, \dots, e_{n_{i+1}}\}$ .
+
+Suppose the model consists of a backbone network for feature extraction and a classifier for classification. As a common practice, $M_{i+1}$ is first initialized by the parameter of $M_i$ , and then the dimensions of the classifier are extended to adapt to new entity types. Then, $M_i$ will guide the learning process of $M_{i+1}$ through knowledge distillation (Monaikul et al., 2021) or regularization terms (Douillard et al., 2020) to preserve old knowledge. Our method is based on knowledge distillation where the old model $M_i$ acts as a teacher and the
+
+new model $M_{i+1}$ acts as a student. Our method further distillates causal effects in the process of knowledge distillation.
+
+# 4.2 Distilling Colliding Effects in CL-NER
+
+Based on the causal graph in Figure 3a, we figure out that the crux of CL lies in building causal paths between old data and prediction on the new model. If we utilize colliding effects, the causal path between old and new data can be built without storing old data.
+
+To distillate the colliding effects, we first need to find tokens in new data which have the same feature representation $X_0$ in the old feature space, i.e., condition on $X_0$ . However, it is almost impossible to find such matched tokens since features are sparse in high dimensional space (Altman and Krzywinski, 2018). Following Hu et al. (2021), we approximate the colliding effect using K-Nearest Neighbor (KNN) strategy. Specifically, we select a token as anchor token and search the k-nearest neighbor tokens whose features bear a resemblance to the anchor token's feature in the old feature
+
+
+Figure 5: A demonstration of the proposed causal framework for CL-NER.
+
+space. Next, when calculating the prediction of the anchor token, we use matched tokens for joint prediction. Note that in backpropagation, only the gradient of the anchor token is computed. Figure 4 shows a demonstration for distilling colliding effects.
+
+Although Other-class tokens usually do not directly guide the model to recognize new entity types, they contain tokens from old entity types, which allow models to recall what they have learned. Naturally, we use the old model to recognize the Other-class tokens which actually belong to old entity types. Since these Other-class tokens belong to the predefined entity types, we call them as Defined-Other-Class tokens, and we call the rest tokens in Other-class as Undefined-Other-Class tokens.
+
+Based on the characteristics of NER, we extend the causal graph in Figure 3a to Figure 3b. The key adjustment is that the node of new data is split into two nodes, including new entity tokens $D^{E}$ and Defined-Other-Class tokens $D^{O}$ . Then, we apply the colliding effects on $D^{E}$ and $D^{O}$ respectively, resulting in that $D^{E}$ and $D^{O}$ collide with $S$ on nodes $X_{0}^{E}$ and $X_{0}^{O}$ in the old feature space. In this way, we build two causal paths from old data $S$ to new predictions $\hat{Y}$ . In the causal graph, we ignore the token from Undefined-Other-Class since they do not help models learn new entity types or review old knowledge. Moreover, we expect the model to update instead of preserving the knowledge about Other-class in each CL step. Here, we consider two paths separately because the colliding effects are distilled from different kinds of data and calculated
+
+in different ways.
+
+# 4.3 A causal framework for CL-NER
+
+Formally, we define the total causal effects $Effect$ as follow:
+
+$$
+\begin{array}{l} E f f e c t = E f f e c t _ {E} + E f f e c t _ {O} (1) \\ = - \Sigma_ {i} C E \left(\bar {Y} _ {i}, Y _ {i}\right) - \Sigma_ {j} K L \left(\bar {Y} _ {j}, \tilde {Y} _ {j}\right), (2) \\ \end{array}
+$$
+
+$$
+s. t. \quad D _ {i} \in D ^ {E}, \quad D _ {j} \in D ^ {O}.
+$$
+
+In Eq.(1), $Effect_{E}$ and $Effect_{O}$ denote the colliding effect of new entity types and Defined-Other-Class. In Eq.(2), $CE(\cdot, \cdot)$ and $KL(\cdot, \cdot)$ represent the cross-entropy and KL divergence loss, and $D_{i}, D_{j}$ are the $i$ -th, $j$ -th token in new data. In cross-entropy loss, $Y_{i}$ is the ground-truth entity type of the $i$ -th token in new data. In KL divergence loss, $\widetilde{Y}_{j}$ is the soft label of the $j$ -th token given by the old model over old entity types. In both losses, $\overline{Y}$ represents the weighted average of prediction scores over anchor and matched tokens. When calculating $KL(\cdot, \cdot)$ , we follow the common practice in knowledge distillation to introduce temperature parameters $T_{t}, T_{s}$ for teacher (old model) and student model (new model) respectively. Here, we omit $T_{t}, T_{s}$ in $KL(\cdot, \cdot)$ for notation simplicity. The weighted average scores of the $i$ -th token is calculated as follow:
+
+$$
+\bar {Y} _ {i} = W _ {i} \hat {Y} _ {i} + \Sigma_ {k = 1} ^ {K} W _ {i k} \hat {Y} _ {i k} \tag {3}
+$$
+
+$$
+\begin{array}{l} s. t. \quad W _ {i} \geq W _ {i 1} \geq W _ {i 2} \geq \dots \geq W _ {i K} \\ W _ {i} + \Sigma_ {k = 1} ^ {K} W _ {i k} = 1, \\ \end{array}
+$$
+
+where the $i$ -th token is the anchor token and $K$ matched tokens are selected according to the KNN
+
+strategy. We sort the $K$ matched tokens in ascending order according to the distance to the anchor token in the old feature space. $\hat{Y}_i, \hat{Y}_{ik}$ are the prediction scores of the $i$ -th token and its $k$ -th matched token, and $W_i, W_{ik}$ are the weight for $\hat{Y}_i, \hat{Y}_{ik}$ , respectively. The weight constraints ensure that the token closer to the colliding feature has a more significant effect.
+
+Until now, we calculate the effects in $D^{E}$ and $D^{O}$ and ignore the Undefined-Other-Class. Following Monaikul et al. (2021), we apply the standard knowledge distillation to allow new models to learn from old models. To this end, we just need to rewrite $Effect_{O}$ in Eq.(1) as follow:
+
+$$
+\begin{array}{l} E f f e c t _ {O} = - \Sigma_ {j} K L (\bar {Y} _ {j}, \tilde {Y} _ {j}) - \Sigma_ {n} K L (\hat {Y} _ {n}, \tilde {Y} _ {n}) \tag {4} \\ s. t. \quad D _ {j} \in D ^ {O}, \quad D _ {n} \in D ^ {U O}, \\ \end{array}
+$$
+
+where $D^{UO}$ is the data belong to the Undefined-Other-Class. The Eq.(4) can be seen as calculating samples from $D^{O}$ and $D^{UO}$ in the same way, except that samples from $D^{UO}$ have no matched tokens. We summarize the proposed causal framework in Figure 5.
+
+# 4.4 Mitigating Label Noise in Effect
+
+In our method, we use the old model to predict the labels of Defined-Other-Class tokens. However, it inevitably generates label noise when calculating $Effect_{O}$ . To address this problem, we adopt curriculum learning to mitigate the label noise in the proposed method.
+
+Curriculum learning has been widely used for handling label noises (Guo et al., 2018) in computer vision. Arazo et al. (2019) empirically find that networks tend to fit correct samples before noisy samples. Motivated by this, we introduce a confidence threshold $\delta$ ( $\delta \in [0,1]$ ) to encourage the model to learn first from clean Other-class samples and then noisier ones. Specifically, when calculating $Effect_{O}$ , we only select Defined-Other-Class tokens whose predictive confidences are larger than $\delta$ for distilling colliding effects while others are for knowledge distillation. The value of $\delta$ changes along with the training process and the value of $\delta$ in the $i$ -th epoch is calculated as follow:
+
+$$
+\delta_ {i} = \left\{ \begin{array}{l l} \delta_ {1} + \frac {i - 1}{m - 1} \left(\delta_ {m} - \delta_ {1}\right), & 1 \leq i \leq m \\ \delta_ {m}, & i > m, \end{array} \right. \tag {5}
+$$
+
+where $m$ , $\delta_{1}$ and $\delta_{m}$ are the predefined hyperparameters and $\delta_{m}$ should be smaller than $\delta_{1}$ .
+
+# 4.5 Balancing Effect $_{E}$ and Effect $_{O}$
+
+Figure 5 shows that the total causal effect Effect consists of $Effect_{E}$ and $Effect_{O}$ , where $Effect_{E}$ is for learning new entities while $Effect_{O}$ is for reviewing old knowledge. With the learning process of CL, the need to preserve old knowledge varies (Hou et al., 2019). For example, more efforts should be made to preserve old knowledge when there are 15 old classes and 1 new class v.s. 5 old classes and 1 new class. In response to this, we introduce a self-adaptive weight for balancing $Effect_{E}$ and $Effect_{O}$ :
+
+$$
+\lambda = \lambda_ {\text {b a s e}} \sqrt {C _ {O} / C _ {N}} \tag {6}
+$$
+
+where $\lambda_{base}$ is the initial weight and $C_O, C_N$ are the numbers of old and new entity types respectively. In this way, the causal effects from new entity types and Other-class are dynamically balanced when the ratio of old classes to new classes changes. Finally, the objective of the proposed method is given as follow:
+
+$$
+\max E f f e c t = E f f e c t _ {E} + \lambda * E f f e c t _ {O} \tag {7}
+$$
+
+# 5 Experiments
+
+# 5.1 Settings
+
+Datasets. We conduct experiments on three widely used datasets, i.e., OntoNotes5 (Hovy et al., 2006), i2b2 (Murphy et al., 2010) and CoNLL2003 (Sang and De Meulder, 2003). To ensure that each entity type has enough samples for training, we filter out the entity types which contain less than 50 training samples. We summarize the statistics of the datasets in Table 5 in Appendix F.
+
+Following Monaikul et al. (2021), we split the training set into disjoint slices, and in each slice, we only retain the labels which belong to the entity types to learn while setting other labels to Other-class. Different from Monaikul et al. (2021), we adopt a greedy sampling strategy to partition the training set to better simulate the real-world scenario. Specifically, the sampling algorithm encourages that the samples of each entity type are mainly distributed in the slice to learn. We provide more explanations and the detailed algorithm in Appendix B.
+
+Training. We use bert-base-cased (Devlin et al., 2019) as the backbone model and a fully-connected layer for classification. Following previous work in CL (Hu et al., 2021), we predefine a fixed order of
+
+Table 1: Comparisons with state-of-the-art methods on I2B2 and OntoNotes5. The average results as well as standard derivations are provided. Mi-F1: micro-F1; Ma-F1: macro-F1; Forget: Forgetting; : higher is better; : lower is better. The best F1 results are bold.
+
+| Dataset | Method | FG-1-PG-1 | FG-2-PG-2 | FG-8-PG-1 | FG-8-PG-2 |
| Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 |
| I2B2 | Finetune Only | 17.43 | 13.81 | 28.57 | 21.43 | 20.83 | 18.11 | 23.60 | 23.54 |
| ±0.54 | ±1.14 | ±0.26 | ±0.41 | ±1.78 | ±1.66 | ±0.15 | ±0.38 |
| PODNet | 12.31 | 17.14 | 34.67 | 24.62 | 39.26 | 27.23 | 36.22 | 26.08 |
| ±0.35 | ±1.03 | ±2.65 | ±1.76 | ±1.38 | ±0.93 | ±12.9 | ±7.42 |
| LUCIR | 43.86 | 31.31 | 64.32 | 43.53 | 57.86 | 33.04 | 68.54 | 46.94 |
| ±2.43 | ±1.62 | ±0.76 | ±0.59 | ±0.87 | ±0.39 | ±0.27 | ±0.63 |
| ST | 31.98 | 14.76 | 55.44 | 33.38 | 49.51 | 23.77 | 48.94 | 29.00 |
| ±2.12 | ±1.31 | ±4.78 | ±3.13 | ±1.35 | ±1.01 | ±6.78 | ±3.04 |
| ExtendNER | 42.85 | 24.05 | 57.01 | 35.29 | 43.95 | 23.12 | 52.25 | 30.93 |
| ±2.86 | ±1.35 | ±4.14 | ±3.38 | ±2.01 | ±1.79 | ±5.36 | ±2.77 |
| CFNER(Ours) | 62.73 | 36.26 | 71.98 | 49.09 | 59.79 | 37.3 | 69.07 | 51.09 |
| ±3.62 | ±2.24 | ±0.50 | ±1.38 | ±1.70 | ±1.15 | ±0.89 | ±1.05 |
| OntoNotes5 | Finetune Only | 15.27 | 10.85 | 25.85 | 20.55 | 17.63 | 12.23 | 29.81 | 20.05 |
| ±0.26 | ±1.11 | ±0.11 | ±0.24 | ±0.57 | ±1.08 | ±0.12 | ±0.16 |
| PODNet | 9.06 | 8.36 | 34.67 | 24.62 | 29.00 | 20.54 | 37.38 | 25.85 |
| ±0.56 | ±0.57 | ±1.08 | ±0.85 | ±0.86 | ±0.91 | ±0.26 | ±0.29 |
| LUCIR | 28.18 | 21.11 | 64.32 | 43.53 | 66.46 | 46.29 | 76.17 | 55.58 |
| ±1.15 | ±0.84 | ±1.79 | ±1.11 | ±0.46 | ±0.38 | ±0.09 | ±0.55 |
| ST | 50.71 | 33.24 | 68.93 | 50.63 | 73.59 | 49.41 | 77.07 | 53.32 |
| ±0.79 | ±1.06 | ±1.67 | ±1.66 | ±0.66 | ±0.77 | ±0.62 | ±0.63 |
| ExtendNER | 50.53 | 32.84 | 67.61 | 49.26 | 73.12 | 49.55 | 76.85 | 54.37 |
| ±0.86 | ±0.84 | ±1.53 | ±1.49 | ±0.93 | ±0.90 | ±0.77 | ±0.57 |
| CFNER(Ours) | 58.94 | 42.22 | 72.59 | 55.96 | 78.92 | 57.51 | 80.68 | 60.52 |
| ±0.57 | ±1.10 | ±0.48 | ±0.69 | ±0.58 | ±1.32 | ±0.25 | ±0.84 |
+
+
+(a) I2B2 (FG-1-PG-1)
+
+
+(b) I2B2 (FG-2-PG-2)
+
+
+(c) I2B2 (FG-8-PG-1)
+
+
+(d) I2B2 (FG-8-PG-2)
+
+
+(e) OntoNotes5 (FG-1-PG-1)
+
+
+(f) OntoNotes5 (FG-2-PG-2)
+
+
+Figure 6: Comparison of the step-wise micro-f1 score on I2B2 (16 entity types), OntoNotes5 (18 entity types).
+
+
+(g) OntoNotes5 (FG-8-PG-1)
+(h) OntoNotes5 (FG-8-PG-2)
+
+classes (alphabetically in this study) and train models with the corresponding data slice sequentially. Specifically, $FG$ entity types are used to train a model as the initial model, and every $PG$ entity types are used for training in each CL step (denoted as $FG - a - PG - b$ ). For evaluation, we only retain the new entity types' labels while setting other labels to Other-class in the validation set. In each CL step, we select the model with the best validation
+
+performance for testing and the next step's learning. For testing, we retain the labels of all recognized entity types while setting others to Other-class in the test set.
+
+Metrics. Considering the class imbalance problem in NER, we adopt Micro F1 and Macro F1 for measuring the model performance. We report the average result on all CL steps (including the first step) as the final result.
+
+Baselines. We consider four baselines: ExtendNER (Monaikul et al., 2021), Self-Training (ST) (Rosenberg et al., 2005; De Lange et al., 2019), LUCIR (Hou et al., 2019) and PODNet (Douillard et al., 2020). ExtendNER is the previous state-of-the-art method in CL-NER. LUCIR and PODNet are state-of-the-art CL methods in computer vision. Detailed descriptions of the baselines and their training settings are demonstrated in Appendix C.
+
+Hyper-Parameters. We set the number of matched tokens $K = 3$ , the weights $W_{i} = 1 / 2$ and $W_{ik} = \frac{1}{2K}$ . For parameters in the curriculum learning strategy, we set $\delta_1 = 1$ , $\delta_m = 0$ and $m = 10$ . We set the initial value of balancing weight $\lambda_{base} = 2$ . More training details are shown in Appendix D.
+
+# 5.2 Results and Analysis
+
+Comparisons with State-Of-The-Art. We consider two scenarios for each dataset: (1) training the first model the same as the following CL steps; (2) training the first model with half of all entity types. The former scenario is more challenging, whereas the latter is closer to the real-world scenario since it allows models to learn enough knowledge before incremental learning. Apart from that, we consider fine-tuning without any anti-forgetting techniques (Finetune Only) as a lower bound for comparison.
+
+The results on I2B2 and OntoNotes5 are summarized in Table 1 and Figure 6. Due to the space limitation, we provide the results on CoNLL2003 in Table 6 and Figure 9 in Appendix F. In most cases, our method achieves the best performance. Especially, our method outperforms the previous state-of-the-art method in CL-NER (i.e., ExtendNER) by a large margin. Besides, we visualize the features of our method and ExtendNER for comparison in Appendix E. The performances of PODNet and LUCIR are much worse than our methods when more CL steps are performed. The reason could be that neither of them differentiates Other-class from entity types, and the old knowledge in Other-class is not preserved. Our method encourages the model to review old knowledge from both new entity types and Other-class in the form of distilling causal effects.
+
+Ablation Study. We ablate our method, and the results are summarized in Table 2. To validate the effectiveness of the proposed causal framework, we only remove the colliding effects in Other-class and new entity types for the settings w/o Effect $_O$
+
+Table 2: The ablation study of our method on three datasets in the setting FG-1-PG-1. $AW$ : adaptive weight; CuL: curriculum learning strategy; Mi-F1: micro-F1; Ma-F1: macro-F1.
+
+| Methods | I2B2 | OntoNotes5 | CoNLL2003 |
| Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 |
| CFNER(Ours) | 62.73 | 36.26 | 58.94 | 42.22 | 80.91 | 79.11 |
| w/o AW | 61.65 | 35.86 | 57.63 | 40.28 | 80.75 | 78.43 |
| w/o CuL | 61.21 | 34.79 | 57.95 | 39.54 | 80.32 | 78.71 |
| w/o AW & CuL | 60.78 | 33.15 | 56.83 | 38.95 | 79.89 | 77.54 |
| w/o EffectO | 59.68 | 30.56 | 53.09 | 34.99 | 78.68 | 76.15 |
| w/o EffectE | 53.62 | 28.75 | 54.88 | 37.29 | 79.83 | 77.45 |
| w/o EffectO & EffectE | 42.85 | 24.05 | 50.53 | 32.84 | 76.36 | 73.04 |
+
+and w/o $Effect_{E}$ , respectively. Specifically, in the w/o $Effect_{O}$ setting, we apply knowledge distillation for all Other-class samples, while in w/o $Effect_{E}$ setting, we calculate the cross-entropy loss for classification. Note that our model is the same as ExtendNER when no causal effects are used (i.e., w/o $Effect_{O} \& Effect_{E}$ ). The results show that both $Effect_{O}$ and $Effect_{E}$ play essential roles in our framework. Furthermore, the adaptive weight and the curriculum-learning strategy help model better learn causal effects in new data.
+
+Table 3: Hyper-parameter analysis on I2B2 (FG-8-PG-2). $Mi-F1$ : micro-F1; $Ma-F1$ : macro-F1.
+
+| K | Mi-F1 | Ma-F1 | δ1 | Mi-F1 | Ma-F1 | λbase | Mi-F1 | Ma-F1 |
| 1 | 65.48 | 46.82 | 0 | 65.25 | 46.33 | 0.5 | 69.27 | 48.71 |
| 2 | 67.12 | 49.37 | 0.5 | 66.09 | 48.51 | 1 | 69.46 | 52.45 |
| 3 | 69.07 | 51.09 | 0.9 | 68.23 | 49.1 | 2 | 69.07 | 51.09 |
| 5 | 70.25 | 52.51 | 0.95 | 68.64 | 49.66 | 5 | 64.4 | 46.65 |
| 10 | 70.69 | 52.26 | 1 | 69.07 | 51.09 | 10 | 54.12 | 40.66 |
+
+Hyper-Parameter Analysis. We provide hyperparameter analysis on I2B2 with the setting FG-8-PG-2. We consider three hyper-parameters: the number of matched tokens $K$ , the initial value of balancing weight $\lambda_{base}$ and the initial value of confidence threshold $\delta_1$ . The results in Table 3 show that a larger $K$ is beneficial. However, as $K$ becomes larger, the run time increases correspondingly. The reason is that more forward passes are required during training. Therefore, We select $K = 3$ by default to balance effectiveness and efficiency. Results also show that $\delta_1 = 1$ reaches the best result, which indicates that it is more effective to learn $Effect_E$ first and then gradually introduce $Effect_O$ during training. Otherwise, the old model's wrong predictions will significantly affect the model's performance. Additionally, we find that the performance drops substantially when $\lambda_{base}$ is too large. Note that we did not carefully search for the best hyper-parameters, and the default ones are used throughout the experi
+
+ments. Therefore, elaborately adjusting the hyperparameters may lead to superior performances on specific datasets and scenarios.
+
+Table 4: Combining our methods with other baselines on three datasets in the setting FG-1-PG-1. $Mi-F1$ : microF1; $Ma-F1$ : macro-F1. $CF$ represents applying causal effects.
+
+| Methods | I2B2 | OntoNotes5 | CoNLL2003 |
| Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 |
| CFNER(Ours) | 62.73 | 36.26 | 58.94 | 42.22 | 80.91 | 79.11 |
| LUCIR | 43.86 | 31.31 | 28.18 | 21.11 | 74.15 | 70.48 |
| LUCIR+CF | 66.27 | 38.52 | 62.03 | 44.34 | 81.28 | 79.56 |
| ST | 31.98 | 14.76 | 50.71 | 33.24 | 76.17 | 72.88 |
| ST+CF | 61.41 | 33.43 | 57.06 | 41.28 | 80.59 | 79.11 |
+
+Combining with Other Baselines. Furthermore, the proposed causal framework can be implemented as a plug-and-play module (denoted as $CF$ ). As shown in Figure 5, $Effect_{E}$ is based on the cross-entropy loss for classifying new entities, while $Effect_{O}$ is based on the KL divergence loss for the prediction-level distillation. We use LUCIR and ST as the baselines for a demonstration. To combine LUCIR with our method, we substitute the classification loss in LUCIR with $Effect_{E}$ and substitute the feature-level distillation with $Effect_{O}$ . When combining with ST, we only replace the soft label with the hard label when calculating $Effect_{O}$ . The results in Table 4 indicate that our method improves LUCIR and ST substantially. It is worth noticing that $LUCIR + CF$ outperforms our method consistently, indicating our method has the potential to combine with other CL methods in computer vision and reach a superior performance in CLNER. In addition, CFNER outperforms $ST + CF$ due to the fact that soft labels convey more knowledge than hard labels.
+
+# 6 Conclusion
+
+How can we learn from Other-class for antiforgetting in CL-NER? This question is answered by the proposed causal framework in this study. Although Other-class is "useless" in traditional NER, we point out that in CL-NER, Other-class samples are naturally reserved samples from old classes, and we can distillate the causal effects from them to preserve old knowledge. Moreover, we apply curriculum learning to alleviate the noisy label problem to enhance the distillation of $Effect_{O}$ . We further introduce a self-adaptive weight for dynamically balancing causal effects between new entity
+
+types and Other-class. Experimental results show that the proposed causal framework not only outperforms state-of-the-art methods but also can be combined with other methods to further improve performances.
+
+# Ethics Statement
+
+For the consideration of ethical concerns, we would make description as follows: (1) We conduct all experiments on existing datasets, which are derived from public scientific researches. (2) We describe the statistics of the datasets and the hyperparameter settings of our method. Our analysis is consistent with the experimental results. (3) Our work does not involve sensitive data or sensitive tasks. (4) We will open source our code for reproducibility.
+
+# Limitations
+
+Although the proposed method alleviates the catastrophic forgetting problem to some extent, its performances are still unsatisfactory when more CL steps are performed. Additionally, calculating causal effects from Other-class depends on the old model predictions, resulting in errors propagating to the following CL steps. Moreover, the proposed method requires more computation and a longer training time since the predictions of matched samples are calculated.
+
+# Acknowledgements
+
+This paper was partially funded by the National Natural Science Foundation of China (Grant Nos. 62272173, 61872148), the Natural Science Foundation of Guangdong Province (Grant Nos. 2022A1515010179, 2019A1515010768). We thank Xichen Shang, Zipeng Chen for helpful discussions on the manuscript.
+
+# References
+
+Naomi Altman and Martin Krzywinski. 2018. The curse (s) of dimensionality. Nat Methods, 15(6):399-400.
+Eric Arazo, Diego Ortego, Paul Albert, Noel O'Connor, and Kevin McGuinness. 2019. Unsupervised label noise modeling and loss correction. In International conference on machine learning, pages 312-321. PMLR.
+Yoshua Bengio, Jérôme Louradour, Ronan Collobert, and Jason Weston. 2009. Curriculum learning. In Proceedings of the 26th annual international conference on machine learning, pages 41-48.
+
+Sarkar Snigdha Sarathi Das, Arzoo Katiyar, Rebecca Passonneau, and Rui Zhang. 2022. CONTaiNER: Few-shot named entity recognition via contrastive learning. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 6338-6353, Dublin, Ireland. Association for Computational Linguistics.
+Matthias De Lange, Rahaf Aljundi, Marc Masana, Sarah Parisot, Xu Jia, Ales Leonardis, Gregory Slabaugh, and Tinne Tuytelaars. 2019. Continual learning: A comparative study on how to defy forgetting in classification tasks. arXiv preprint arXiv:1909.08383, 2(6).
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Arthur Douillard, Matthieu Cord, Charles Ollion, Thomas Robert, and Eduardo Valle. 2020. Podnet: Pooled outputs distillation for small-tasks incremental learning. In ECCV 2020-16th European Conference on Computer Vision, volume 12365, pages 86-102. Springer.
+Madelyn Glymour, Judea Pearl, and Nicholas P Jewell. 2016. Causal inference in statistics: A primer. John Wiley & Sons.
+Ian J Goodfellow, Mehdi Mirza, Da Xiao, Aaron Courville, and Yoshua Bengio. 2013. An empirical investigation of catastrophic forgetting in gradient-based neural networks. arXiv preprint arXiv:1312.6211.
+Sheng Guo, Weilin Huang, Haozhi Zhang, Chenfan Zhuang, Dengke Dong, Matthew R Scott, and Dinglong Huang. 2018. Curriculumnet: Weakly supervised learning from large-scale web images. In Proceedings of the European Conference on Computer Vision (ECCV), pages 135-150.
+Geoffrey Hinton, Oriol Vinyals, Jeff Dean, et al. 2015. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531, 2(7).
+Saihui Hou, Xinyu Pan, Chen Change Loy, Zilei Wang, and Dahua Lin. 2019. Learning a unified classifier incrementally via rebalancing. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 831-839.
+Eduard Hovy, Mitch Marcus, Martha Palmer, Lance Ramshaw, and Ralph Weischedel. 2006. Ontonotes: the $90\%$ solution. In Proceedings of the human language technology conference of the NAACL, Companion Volume: Short Papers, pages 57-60.
+
+Xinting Hu, Kaihua Tang, Chunyan Miao, Xian-Sheng Hua, and Hanwang Zhang. 2021. Distilling causal effect of data in class-incremental learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 3957-3966.
+James Kirkpatrick, Razvan Pascanu, Neil Rabinowitz, Joel Veness, Guillaume Desjardins, Andrei A Rusu, Kieran Milan, John Quan, Tiago Ramalho, Agnieszka Grabska-Barwinska, et al. 2017. Overcoming catastrophic forgetting in neural networks. Proceedings of the national academy of sciences, 114(13):3521-3526.
+Xiaoya Li, Xiaofei Sun, Yuxian Meng, Junjun Liang, Fei Wu, and Jiwei Li. 2020. Dice loss for data-imbalanced nlp tasks. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 465-476.
+Xuezhe Ma and Eduard Hovy. 2016. End-to-end sequence labeling via bi-directional LSTM-cnns-crf. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1064-1074.
+Michael McCloskey and Neal J Cohen. 1989. Catastrophic interference in connectionist networks: The sequential learning problem. In Psychology of learning and motivation, volume 24, pages 109-165. Elsevier.
+Natawut Monaikul, Giuseppe Castellucci, Simone Filice, and Oleg Rokhlenko. 2021. Continual learning for named entity recognition. In Proceedings of the Thirty-Fifth AAAI Conference on Artificial Intelligence, pages 13570-13577.
+Shawn N Murphy, Griffin Weber, Michael Mendis, Vivian Gainer, Henry C Chueh, Susanne Churchill, and Isaac Kohane. 2010. Serving the enterprise and beyond with informatics for integrating biology and the bedside (i2b2). Journal of the American Medical Informatics Association, 17(2):124-130.
+Guoshun Nan, Jiaqi Zeng, Rui Qiao, Zhijiang Guo, and Wei Lu. 2021. Uncovering main causalities for long-tailed information extraction. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 9683-9695.
+German I Parisi, Ronald Kemker, Jose L Part, Christopher Kanan, and Stefan Wermter. 2019. Continual lifelong learning with neural networks: A review. Neural Networks, 113:54-71.
+Adam Paszke, Sam Gross, Francisco Massa, Adam Lerer, James Bradbury, Gregory Chanan, Trevor Killeen, Zeming Lin, Natalia Gimelshein, Luca Antiga, et al. 2019. Pytorch: An imperative style, high-performance deep learning library. Advances in neural information processing systems, 32.
+Judea Pearl. 2009. Causality. Cambridge university press.
+
+Judea Pearl. 2014. Interpretation and identification of causal mediation. Psychological methods, 19(4):459.
+
+Sylvestre-Alvise Rebuffi, Alexander Kolesnikov, Georg Sperl, and Christoph H Lampert. 2017. icarl: Incremental classifier and representation learning. In Proceedings of the IEEE conference on Computer Vision and Pattern Recognition, pages 2001-2010.
+
+Anthony Robins. 1995. Catastrophic forgetting, rehearsal and pseudorehearsal. Connection Science, 7(2):123-146.
+
+Chuck Rosenberg, Martial Hebert, and Henry Schneiderman. 2005. Semi-supervised self-training of object detection models. In Proceedings of the Seventh IEEE Workshops on Application of Computer Vision (WACV/MOTION'05)-Volume 1-Volume 01, pages 29-36.
+
+Erik Tjong Kim Sang and Fien De Meulder. 2003. Introduction to the conll-2003 shared task: Language-independent named entity recognition. In Proceedings of the Seventh Conference on Natural Language Learning at HLT-NAACL 2003, pages 142-147.
+
+Bernhard Scholkopf. 2022. Causality for machine learning. In Probabilistic and Causal Inference: The Works of Judea Pearl, pages 765-804.
+
+Kaihua Tang, Jianqiang Huang, and Hanwang Zhang. 2020. Long-tailed classification by keeping the good and removing the bad momentum causal effect. Advances in Neural Information Processing Systems, 33:1513-1524.
+
+Sebastian Thrun. 1998. Lifelong learning algorithms. In Learning to learn, pages 181-209. Springer.
+
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumond, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, et al. 2019. Huggingface's transformers: State-of-the-art natural language processing. arXiv preprint arXiv:1910.03771.
+
+Dong Zhang, Hanwang Zhang, Jinhui Tang, Xian-Sheng Hua, and Qianru Sun. 2020. Causal intervention for weakly-supervised semantic segmentation. Advances in Neural Information Processing Systems, 33:655-666.
+
+Wenkai Zhang, Hongyu Lin, Xianpei Han, and Le Sun. 2021. De-biasing distantly supervised named entity recognition via causal intervention. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4803-4813.
+
+Qingfu Zhu, Weinan Zhang, Ting Liu, and William Yang Wang. 2020. Counterfactual off-policy training for neural dialogue generation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 3438-3448.
+
+# A Forgetting in CL-NER
+
+To identify the cause of forgetting, we consider the differences in prediction $Y$ when the old data $S$ exists or not. For each CL step, the effect of old data $S$ can be calculate as:
+
+$$
+\begin{array}{l} E f f e c t _ {S} = P (\hat {Y} = \hat {y} | d o (S = s)) (8) \\ - P (\hat {Y} = \hat {y} | d o (S = 0)) \\ = P (\hat {Y} = \hat {y} | S = s) - P (\hat {Y} = \hat {y} | S = 0) (9) \\ = P (\hat {Y} = \hat {y}) - P (\hat {Y} = \hat {y}) (10) \\ = 0, (11) \\ \end{array}
+$$
+
+where $do(\cdot)$ is the causal intervention (Pearl, 2014, 2009) representing that assigning a certain value to a variable without considering all parent nodes (causes). In the first equation, $do(S = 0)$ represents null intervention, i.e., setting old data to null. In the second equation, $P(\hat{Y} = \hat{y} |do(S) = P(\hat{Y} = \hat{y} |S)$ due to the fact that $S$ has no parent nodes. In the third equation, $P(\hat{Y} = \hat{y} |S) = P(\hat{Y} = \hat{y})$ since all causal paths from $S$ to $Y$ are blocked by the collider $X_0$ . From Eq.(11), we find that the missing old data effect causes the forgetting. We neglect the effect of initial parameters adopted from the old model since it will be exponentially decayed towards 0 during learning (Kirkpatrick et al., 2017).
+
+# B Greedy Sampling Algorithm for CL-NER
+
+In real-world scenarios, the new data should focus on the new entity types, i.e., most sentences contain the tokens from new entity types. Suppose we randomly partition a dataset for CL-NER as in Monaikul et al. (2021). In that case, each slice contains a large number of sentences whose tokens all belong to Other-class, resulting in that models tend to bias to Other-class when inference. A straightforward solution is to filter out all sentences with only Other-class tokens. However, it brings a new problem: the slices' sizes are imbalanced.
+
+To address this problem, we propose a sampling algorithm for partitioning a dataset in CL-NER (Algorithm 1). Simply put, we allocate the sentence containing low-frequency entity types to the corresponding slice in priority until the slice contains the required number of sentences. If a sentence contains no entity types or the corresponding slices are full, we randomly allocate the sentence to an incomplete slice. In this way, we partition the dataset into
+
+
+(a) Greedy Sampling
+
+
+(b) Random Sampling
+Figure 7: Comparison of the greedy sampling and random sampling on OntoNotes5. Each slice contains one entity types to lean.
+
+slices with balanced sizes, and each slice mainly contains the entity types to learn.
+
+For comparing Algorithm 1 and the random sampling as in Monaikul et al. (2021), we provide the label distributions in each slices of training data in Figure 7. Figure 7 shows that the greedy sampling generates more realistic datasets for CL-NER. When we use the randomly partitioned dataset for training in the setting FG-1-PG-1, the micro-f1 score of our method is 16.12, 17.43, and 12.75 $(\%)$ on OntoNotes5, I2B2, and CoNLL2003, respectively, indicating that the number of entities in each slice is inadequate for learning a NER model. Therefore, the greedy sampling alleviates the need for data in CL-NER.
+
+# C Baselines Introductions and Settings
+
+The introductions about the baselines in experiments and their experimental settings are as follows. Note that we do not apply any reserved samples from old classes in LUCIR and PODNet for a fair comparison since our method requires no old data.
+
+- Self-Training (ST) (Rosenberg et al., 2005; De Lange et al., 2019): ST first utilizes the old model to annotate the Other-class tokens with old entity types. Then, the new model is trained on new data with annotations of all entity types. Finally, the cross-entropy loss on all entity types is minimized.
+- ExtendNER (Monaikul et al., 2021): ExtendNER has a similar idea to ST, except that the old model provides the soft label (i.e.,
+
+probability distribution) of Other-class tokens. Specifically, the cross-entropy loss is computed for entity types' tokens, and KL divergence loss is computed for Other-class tokens. During training, the sum of cross-entropy loss and KL divergence loss is minimized. Following Monaikul et al. (2021), we set the temperature of the teacher (old model) and student model (new model) to 1 and 2, respectively.
+
+- LUCIR (Hou et al., 2019): LUCIR develops a framework for incrementally learning a unified classifier for the continual image classification tasks. The total loss consists of three terms: (1) the cross-entropy loss on the new classes samples; (2) the distillation loss on the features extracted by the old model and those by the new one; (3) the margin-ranking loss on the reserved samples for old classes. In our experiments, we compute the cross-entropy loss for new entity types, the distillation loss for all entity types, and the margin-ranking loss for Other-class samples instead of the reserved samples. Following (Hou et al., 2019), $\lambda_{\text{base}}$ (i.e., loss weight for the distillation loss) is set to 50, $K$ (i.e., the top-K new class embeddings are chosen for the margin-ranking loss) is set to 1 and $m$ (i.e., the threshold of margin ranking loss) is set to 0.5 for all the tasks.
+- PODNet (Douillard et al., 2020): PODNet has a similar idea to LUCIR to combat the catastrophic forgetting in continual learning
+
+Algorithm 1: Greedy Sampling Algorithm for CL-NER
+Input: $\mathcal{D} = \{(s_i,t_i)\}_{i = 1}^n$ : a training set contains $n$ sentences $s$ and their label sequences $t$
+Require: $G$ : the number of slices; $\mathcal{E}$ : the entity set; $\mathcal{E}_j$ : the entity set in the $j$ -th slice;
+Output: $G$ slices of datasets: $\mathcal{D}^{(1)},\mathcal{D}^{(2)},\dots ,\mathcal{D}^{(G)}$
+1 Initialize $\mathcal{D}^{(1)},\dots ,\mathcal{D}^{(G)} = \{\},\dots ,\{\}$
+2 Initialize cnt1,., cntG=0,0,0; // Calculate the number of sentences to allocate in each slice
+3 for j in range(1,G+1) do
+4 | $n_j = n*|\mathcal{E}_j| / |\mathcal{E}|$
+5 end
+6 Sort $\mathcal{E}$ in ascending order based on the frequency in $\mathcal{D}$
+7 for $(s_i,t_i)$ in $\mathcal{D}$ do
+8 is_select $\equiv$ False; // Allocate low frequency entity types in priority
+9 for e in $\mathcal{E}$ do if not e in ti then continue; end
+13 j is index of $\mathcal{E}_j$ s.t. e belongs to $\mathcal{E}_j$ . if cntj < nj then $\begin{array}{r}\mathcal{D}^{(j)} = \mathcal{D}^{(j)}\cup (s_i,t_i);\\ \text{cnt}_j + = 1;\\ \text{is\_select} = \mathrm{True};\\ \text{break;}\\ \end{array}$
+15 end
+16
+17 is_select = True;
+18 break;
+19 end
+20 end
+// Otherwise, the sentence is randomly assigned to an incomplete slice
+21 if not is_select then randomly choice j s.t. cntj < nj;
+22 $\mathcal{D}^{(j)} = \mathcal{D}^{(j)}\cup (s_i,t_i);$
+24 cntj +=1;
+25 end
+26 end
+27 return $\mathcal{D}^{(1)},\mathcal{D}^{(2)},\dots ,\mathcal{D}^{(G)};$
+
+for image classification. The total loss consists of the classification loss and distillation loss. To compute the distillation loss, PodNet
+
+Table 5: The statistics and the entity sequence for each dataset
+
+ | # Class | # Sent | # Entity | Entity sequence (Alphabetical Order) |
| CoNLL2003 | 4 | 21k | 35k | LOCATION, MISC, ORGANISATION, PERSON |
| I2B2 | 16 | 141k | 29k | AGE, CITY, COUNTRY, DATE, DOCTOR, HOSPITAL, IDNUM, MEDICALRECORD, ORGANIZATION, PATIENT, PHONE, PROFESSION, STATE, STREET, USERNAME, ZIP |
| OntoNotes5 | 18 | 77k | 104k | CARDINAL, DATE, EVENT, FAC, GPE, LANGUAGE, LAW, LOC, MONEY, NORP, ORDINAL, ORG, PERCENT, PERSON, PRODUCT, QUANTITY, TIME, WORK_OF_ART |
+
+constrains the output of each intermediate convolutional layer while LUCIR only considers the final feature embeddings. For classification, PODNet used NCA loss instead of the cross-entropy loss. In our experiments, we constrain the output of each intermediate stage of BERT as PODNet constrains each stage of a ResNet. Following (Douillard et al., 2020), we set the $\lambda_{c}$ (i.e., loss weight for the POD-spatial loss) to 3 and $\lambda_{f}$ (i.e., loss weight for the POD-flat loss) to 1.
+
+# D Training Details
+
+The models were implemented in Pytorch (Paszke et al., 2019) on top of the BERT Huggingface implementation (Wolf et al., 2019). We use the default hyper-parameters in BERT: hidden dimensions are 768, and the max sequence length is 512. Following Hu et al. (2021), we normalize the feature vector output by BERT and compute the cosine similarities between the feature vector and class representations for predictions.
+
+We use the BIO tagging schema for all three datasets. For CoNLL2003, we train the model for ten epochs in each CL step. For OntoNotes5 and I2B2, we train the model for 20 epochs when $\mathrm{PG} = 2$ , and 10 epochs when $\mathrm{PG} = 1$ . The batch size is set as 8, and the learning rate is set as 4e-4. The experiments are run on GeForce RTX 2080 Ti GPU. Each experiment is repeated 5 times.
+
+# E T-SNE Visualizations
+
+To deepen the understanding of the forgetting in CL-NER, we visualize the feature representations from BERT in Figure 8. Results show that our method preserves more old knowledge and learns better feature representations than ExtendNER.
+
+# F Additional Experimental Results
+
+
+(a) ExtendNER
+
+
+(b) CFNER(Ours)
+Figure 8: The T-SNE visualization of the feature representations from BERT. The model is trained on OntoNotes5 in the setting FG-1-PG-1. We randomly select six classes for a demonstration.
+
+Table 6: Comparisons with state-of-the-art methods on CoNLL2003. The average results as well as standard derivations are provided. $Mi-F1$ : micro-F1; $Ma-F1$ : macro-F1. The best F1 results are bold.
+
+| Dataset | Method | FG-1-PG-1 | FG-2-PG-1 |
| Mi-F1 | Ma-F1 | Mi-F1 | Ma-F1 |
| CoNLL2003 | Finetune Only | 50.84 | 40.64 | 57.45 | 43.58 |
| ±0.10 | ±0.16 | ±0.05 | ±0.18 |
| PODNet | 36.74 | 29.43 | 59.12 | 58.39 |
| ±0.52 | ±0.28 | ±0.54 | ±0.99 |
| LUCIR | 74.15 | 70.48 | 80.53 | 77.33 |
| ±0.43 | ±0.66 | ±0.31 | ±0.31 |
| ST | 76.17 | 72.88 | 76.65 | 66.72 |
| ±0.91 | ±1.12 | ±0.24 | ±0.11 |
| ExtendNER | 76.36 | 73.04 | 76.66 | 66.36 |
| ±0.98 | ±1.8 | ±0.66 | ±0.64 |
| CFNER(Ours) | 80.91 | 79.11 | 80.83 | 75.20 |
| ±0.29 | ±0.50 | ±0.36 | ±0.32 |
+
+
+(a) CoNLL2003 (FG-1-PG-1)
+
+
+(b) CoNLL2003 (FG-2-PG-1)
+Figure 9: Comparison of the step-wise micro-f1 score on CoNLL2003 (4 entity types).
\ No newline at end of file
diff --git a/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/images.zip b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..9b881f26903faef565e724655d188f80ed2dc4d6
--- /dev/null
+++ b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:082f7fa929a76f3a045357fb239476ad161e2fe7b256ea9d8cc8f1263a28e930
+size 763958
diff --git a/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/layout.json b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..75f5c73d20d2c186b5cd73588d4bbd21e4cc0808
--- /dev/null
+++ b/distillingcausaleffectfrommiscellaneousotherclassforcontinualnamedentityrecognition/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c743a03cc0fadac27c33244e58c6cd520287ddcd2b53afe850c4a6abe57456a9
+size 551689
diff --git a/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_content_list.json b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e31fd9034e6f2ca97349f13e6dfd0a33e9d01fca
--- /dev/null
+++ b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9500b8edd54408838d91a7e346109b13a705414088d64c9924060050c986cd77
+size 89227
diff --git a/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_model.json b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..d01e1f24d6880f68415600b818871d1d1db88479
--- /dev/null
+++ b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:22703d780eab5278b7053cfe7ef82260bc58f60d9f3bba8cb708c8eedb0bd30b
+size 109851
diff --git a/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_origin.pdf b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..70ffb029de68464366d8fa404371f7c44a00bb09
--- /dev/null
+++ b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/1f02d78b-f4df-4e1c-8e60-e90c1f698c37_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c20c7ec4b29faf3b4a3d1c50bcc15a83dccdd6cc579b760f4627eef062b75e82
+size 765403
diff --git a/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/full.md b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..fd44a9d480b12ef71d09e53bd10758225cf3e891
--- /dev/null
+++ b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/full.md
@@ -0,0 +1,401 @@
+# Distill the Image to Nowhere: Inversion Knowledge Distillation for Multimodal Machine Translation
+
+Ru Peng $^{1*}$ , Yawen Zeng $^{2*}$ , Junbo Zhao $^{1\dagger}$
+
+1Zhejiang University, Zhejiang, China
+
+2Tencent WeChat, Shenzhen, China
+
+pengru709909347@gmail.com, yawenzeng11@gmail.com, j.zhao@zju.edu.cn
+
+# Abstract
+
+Past works on multimodal machine translation (MMT) elevate bilingual setup by incorporating additional aligned vision information. However, an image-must requirement of the multimodal dataset largely hinders MMT's development — namely that it demands an aligned form of [image, source text, target text]. This limitation is generally troublesome during the inference phase especially when the aligned image is not provided as in the normal NMT setup. Thus, in this work, we introduce IKDMMT, a novel MMT framework to support the image-free inference phase via an inversion knowledge distillation scheme. In particular, a multimodal feature generator is executed with a knowledge distillation module, which directly generates the multimodal feature from (only) source texts as the input. While there have been a few prior works entertaining the possibility to support image-free inference for machine translation, their performances have yet to rival the image-must translation. In our experiments, we identify our method as the first image-free approach to comprehensively rival or even surpass (almost) all image-must frameworks, and achieved the state-of-the-art result on the often-used Multi30k benchmark $^1$ .
+
+# 1 Introduction
+
+Multimodal machine translation (MMT) is an worthy task of elevating text-only translation by introducing additional image modality (Specia et al., 2016; Elliott et al., 2017; Barrault et al., 2018). Existing works mostly focus on the fusion and alignment of images and texts to improve MMT (Calixto et al., 2017; Ive et al., 2019; Yin et al., 2020), that they have managed to concept-prove the effectiveness of the aligned
+
+
+(a) Image-must MMT
+
+
+(b) Image-free MMT (Ours)
+Figure 1: Examples of Image-must MMT (a), and our Image-free MMT (b). During testing, our IKD-MMT does not require the image as input.
+
+visual information. Nevertheless, the strict triplet data form of the dataset, in both the training and inference phases, has disabled the MMT model to generalize further. In particular, if we consider using an MMT model to conduct translation for the normal bilingual text translation as in the NMT setup, one must provide the aligned images during inference. And unfortunately, this is not often feasible. This general comparison between image-free and image-must schemes is visually illustrated in Figure 1(a). In hindsight, the quantity and quality of attached images become a bottleneck towards the development of MMT, as acquiring such resources can be scarce and expensive (e.g. Multi30K (Elliott et al., 2016)).
+
+Indeed, there have been a few attempts to resolve the image-must limitation. For instance, Elliott and Kádár (2017) present a multi-task learning model for MMT where they rely on an auxiliary visual grounding task to obtain the visual feature. Zhang et al. (2020) introduce an image retrieval paradigm to find topic-related images from a small-scale dataset. Further, Long et al. (2021) attempts to
+
+utilize a set of generative adversarial networks to obtain an imaginary vision feature. We may posit that a (nearly) common ground for such image-free frameworks is to learn and further obtain a generated visual feature representation without the actual image data provided during inference. However, none of the aforementioned works has managed to consistently reach the performance of the image-must counterpart. In this work, we hypothesise that this can be caused by the inferior representation learned, insufficient visual distribution coverage, improper multimodal fusion stage (Caglayan et al., 2017; Arslan et al., 2018; Helcl et al., 2018; Calixto and Liu, 2017), and/or lacked training stability, etc.
+
+In this work, we intend to take a thorough exploration towards this line. As Shown in Figure 1(b), unlike prior works solely targeting visual feature generation and/or relying on later stages of fusion, our approach directly generates a multimodal feature using only the source text input. We enable this by proposing an inverse knowledge distillation mechanism employing pretrained convolutional neural networks (CNN). From our experiments, we find that this architectural choice has notably enhanced the training stability as well as the final representation quality. To this end, we introduce the IKDMMT framework, an image-free framework that systematically rivals or outperforms the image-must frameworks. To set up the inverse knowledge distillation flow, we incorporate dual CNNs with inverted data feeding flow. Of the two, the teacher network receives the pre-trained weights while the student CNN is trained from scratch aiming to provide a high-quality multimodal feature space by incorporating both inter-modal and intra-modal distillations.
+
+Our contributions are summarized as follows:
+
+i. IKD-MMT framework is the first method that systematically rivals or even outperforms the existing image-must frameworks, which fully demonstrates the feasibility of the image-free concept;
+ii. We pioneer the exploration of knowledge-distillation combined with the pre-trained models in the regime of MMT, as well as the multimodal feature generation. We posit that these techniques have shed some light on the representation learning and training stability of MMT.
+
+# 2 Related Work
+
+# 2.1 Multi-modal Machine Translation
+
+As an intersection of multimedia and neural machine translation (NMT), MMT has drawn great attention in the research community. Technically, existing methods mainly focus on how to better integrate visual information into the framework of NMT. 1) Calixto et al. (2017) propose a doubly-attentive decoder to incorporate two separate attention over the source words and visual features. 2) Ive et al. (2019) propose a translate-and-refine approach to refine draft translations by visual features. 3) Yao and Wan (2020) propose the multimodal Transformer to induce the image representations from the text under the guide of image-aware attention. 4) Yin et al. (2020) employs a unified multimodal graph to capture various semantic interactions between multimodal semantic units.
+
+However, the quantity and quality of the annotated images limit the development of this task, which is scarce and expensive. In this work, we aim to perform the MMT in an image-free manner, which has the ability to break data constraints.
+
+# 2.2 Knowledge Distillation
+
+Knowledge distillation (KD) (Buciluco et al., 2006; Hinton et al., 2015) aims to use a knowledge-rich teacher network to guide the parameter learning of the student network. In fact, KD has been investigated in a wide range of fields. Romero et al. (2014) transfer knowledge through an intermediate hidden layer to extend the KD. Yim et al. (2017) define the distilled knowledge to be transferred in terms of flow between layers, which is calculated by the inner product between features from two layers. In the multimedia field, Gupta et al. (2016) first introduce the technique that transfers supervision between images from different modalities. Yuan and Peng (2018) propose the symmetric distillation networks for the text-to-image synthesis task.
+
+Inspired by these pioneering efforts, our IKDMMT framework is intents to take full advantage of KD to generate a multimodal feature to overcome triplet data constraints.
+
+# 3 IKD-MMT Model
+
+As illustrated in Figure 2, the proposed framework consists of two components: an image-free MMT backbone and a multimodal feature generator.
+
+
+Figure 2: The framework of our IKD-MMT model. The multimodal feature generator, multimodal student network and visual teacher network are the most critical modules, which help break the dataset constraints of image-must.
+
+# 3.1 Image-Free MMT Backbone
+
+Given a source sentence $X = (x_{1},\ldots ,x_{I})$ , each token $x_{i}$ is mapped into a word embedding vector $E_{x_i}\in \mathbb{R}^{d_w}$ through the textual embedding with position encoding (Gehring et al., 2017). $d_w$ and $t = (E_{x_1},\dots ,E_{x_I})$ are the word embedding dimension and the textual feature, respectively.
+
+Then, we feed the text feature $t$ together with the multimodal feature $m$ (detail in Section 3.2.1) into the multimodal transformer encoder (Yao and Wan, 2020). In the multimodal encoder layer, we cascade the multimodal feature $m$ and the text feature $t$ to reorganize a new multimodal feature $\widetilde{x}$ as the query vector:
+
+$$
+\widetilde {x} = [ t; m W ^ {m} ] \in \mathbb {R} ^ {(I + P) * d}, \tag {1}
+$$
+
+where $I$ is the length of source sentence, and $P$ is the size of multimodal feature. Here, we can understand this modal fusion from the perspective of nodes and graphs. If we treat each source token as a node, each region of the multimodal feature can also be regarded as a pseudo-token and added to the source token graph for modal fusion. The key and value vectors are preserved as the text feature $t$ , and the multimodal encoder layer is calculated as follows:
+
+$$
+c _ {k} = \sum_ {i = 1} ^ {I} \tilde {\alpha} _ {k i} \left(t _ {i} W ^ {V}\right), \tag {2}
+$$
+
+$$
+\tilde {\alpha} _ {k i} = \operatorname {s o f t m a x} \left(\frac {\left(\tilde {x} _ {k} W ^ {Q}\right) \left(t _ {i} W ^ {K}\right) ^ {\top}}{\sqrt {d}}\right). \tag {3}
+$$
+
+In this paper, we directly adopt the Transformer decoder $^2$ (Vaswani et al., 2017) for translation.
+
+Given a target sentence $Y = (y_{1},\ldots ,y_{J})$ , our framework outputs the predicted probability of the target word $y_{j}$ as follow:
+
+$$
+p \left(y _ {j} \mid y _ {< j}, \mathrm {X}, m\right) \propto \exp \left(W ^ {h} H _ {j} ^ {L} + b ^ {h}\right), \tag {4}
+$$
+
+where $H_{j}^{L}$ represents the top output of the decoder at $j$ -th decoding time step, $W^{h}$ and $b^{h}$ are learnable multi-layer perceptrons, and $\exp()$ is a Softmax layer.
+
+# 3.2 Multimodal Feature Generation
+
+# 3.2.1 Preliminaries
+
+In this part, we introduce the frame, symbol definitions and task goal of multimodal feature generation in advance.
+
+The frame is composed of a multimodal feature generator $F$ , a visual teacher model $T$ and a multimodal student model $S$ . The detailed architecture of each module is shown in Table 7 of the appendix. The model parameters of $S$ are denoted as $\theta^s$ . When the global text feature $\bar{t}$ is fed into $S$ , the hidden representation produced by the $l$ -th layer is denoted as $\varphi_l^S (\bar{t},\theta_l^s)$ . The $F$ outputs a multimodal feature $m$ , and the $S$ produces an inverse feature $I_{s}$ after the $S$ -conv1 layer. The real image and the inverse feature are $\{I_s,I_r\} \in \mathbb{R}^{m*n*3}$ . Given a feature $I$ as input, the hidden representation produced by the $l$ -th layer of $T$ is denoted as $\varphi_l^T (I)$ .
+
+Our goal is to generate multimodal features from the source text to break the image-must restriction in testing. The visual perception of this multimodal feature is extracted from the visual distillation of the teacher-student model, while the textual
+
+semantic of that is derived from the text translation of the input text.
+
+# 3.2.2 Multimodal Feature Generator
+
+First, we simply adopt an average pooling to transform all word embedding vectors into global textual features, which are proven to carry the overall word senses in (Zhang et al., 2010).
+
+$$
+\bar {t} = ^ {1} / _ {I} \sum_ {i = 1} ^ {I} E _ {x _ {i}}. \tag {5}
+$$
+
+Then, the global text feature $\bar{t}$ is serially transported into the multimodal feature generator to compute a multimodal feature $m$ :
+
+$$
+m = \operatorname {u n p o o l} \left(W ^ {t} \bar {t}\right). \tag {6}
+$$
+
+Among them, the FC layer $W^{t}$ projects the global text feature $\bar{t}$ into the image space. The following average unpooling computes a high-dimensional multimodal feature map from the low-dimensional latent vector. The dimension of $m \in \mathbb{R}^{P*2048}$ is the same as that of the last convolutional activation of the teacher model. Notably, the textual semantics of multimodal features are modelled from the global textual context supervised by the text translation.
+
+# 3.2.3 Inversion Knowledge Distillation
+
+The inversion knowledge distillation transfers the visual perception from the teacher model $T$ to the student model $S$ , and in-depth interacts with textual semantics in the multimodal feature generator. To synthesize an information-rich multimodal feature, we formulate a novel dual distillation paradigm consisting of inter-modal (IrM-KD) and intramodal (IaM-KD) knowledge distillations.
+
+IrM-KD: The IrM-KD direct the student model $S$ to extract the vital visual information from the source text, thereby bridging the intermodal semantics of the text and the real image. Specifically, given the real image $I_{r}$ , the teacher model $T$ generates a visual representation $\varphi_l^T (I_r)$ in each layer $l$ . Meanwhile, the $S$ produces a inverse hidden representation $\varphi_{l + 1}^{S}(\bar{t},\theta_{l}^{s})$ in next layer $l + 1$ . The paired representations $\varphi_l^S (\bar{t},\theta_l^s)$ and $\varphi_l^T (I_r)$ with identical dimension entail the same-level latent concepts. We present the IrM-KD loss by the discrepancy among these two representations and an auxiliary regularization term:
+
+$$
+L o s s _ {\mathrm {I r M}} = \sum_ {l} \left| \left| \varphi_ {l} ^ {T} \left(I _ {r}\right) - \varphi_ {l + 1} ^ {S} \left(\bar {t}; \theta_ {l} ^ {s}\right) \right| \right| _ {2} + \left\| I _ {r} - I _ {s} \right\| _ {2}, \tag {7}
+$$
+
+where the $L_{2}$ norm $\| \cdot \| _2$ is used to measure the similarity of two vectors. The regularization term $\| I_r - I_s\| _2$ indicates the image space loss, which is the fundamental constraint for the $S$ to learn the distribution of the real image.
+
+IaM-KD: The IaM-KD constrains the student model $S$ to learn the visual perception of images via the inverse feature, thus relieving the intramodal gap between the inverse feature with the real image. Specifically, we fed the inverse feature $I_{s}$ into the teacher model $T$ to gain the teacher's cognition for it — a pseudo visual representation $\varphi_l^D (I_s)$ . Then, to encourage the student model profoundly learn the distribution of images, we narrow the divergence between the $\varphi_l^D (I_s)$ and its coupled visual representation $\varphi_l^T (I_r)$ . So that, the IaM-KD loss is defined as the combination of the above divergence and the image space loss:
+
+$$
+\operatorname {L o s s} _ {\mathrm {I a M}} = \sum_ {l} \left\| \varphi_ {l} ^ {T} \left(I _ {r}\right) - \varphi_ {l} ^ {D} \left(I _ {s}\right) \right\| _ {2} + \| I _ {r} - I _ {s} \| _ {2}. \tag {8}
+$$
+
+Compare with T2I synthesis works (Reed et al., 2016; Zhang et al., 2017; Xu et al., 2018), we are dedicated to airding text translation through intermodal and intra-modal bi-visual distillation. By doing so, our generated multimodal feature focuses more on the text-image alignment and fusion, but not only the authenticity of image.
+
+# 3.3 Objective function
+
+During the training phase, we optimize the proposed IKD-MMT model end-to-end by the text translation loss and the inversion distillation loss:
+
+$$
+J (\theta , \theta_ {s}) = J _ {\text {t r a n s}} (\theta , \theta_ {s}) + L o s s _ {\mathrm {I r M}} + L o s s _ {\mathrm {I a M}}. \tag {9}
+$$
+
+Wherein, the translation loss over the training dataset $\mathcal{D}$ , not only bridges the relevance of the source and target texts, but also models the text semantics of multimodal features:
+
+$$
+J _ {\text {t r a n s}} (\theta , \theta_ {s}) = - \sum_ {D} \sum_ {J} \log p \left(y _ {j} \mid y _ {< j}, X, m\right). \tag {10}
+$$
+
+In the testing phase, the trained multimodal feature generator is capable to generate rich features to embed into the MMT backbone, thus getting rid of the image-must constraints.
+
+# 4 Experiment
+
+# 4.1 Setup
+
+Datasets We conduct experiments on the Multi30K benchmark (Elliott et al., 2016). The
+
+Table 1: BLEU ("B") and METEOR ("M") scores of EN-DE and EN-FR tasks. Encouragingly, our IKD-MMT as an image-free MMT model outperforms almost all MMT systems, and even rivals the SOTA image-must systems. $\ddagger/\dagger$ mark statistically significant variations for BLEU ( $p$ -value $< 0.01/0.05$ ) as compared to the Transformer.
+
+| Systems | EN-DE | EN-FR |
| Test2016 | Test2017 | MSCOCO | Test2016 | Test2017 |
| B | M | B | M | B | M | B | M | B | M |
| Image-must MMT Systems |
| NMTSRC-HMG(Calixto et al., 2017) | 36.5 | 55.0 | - | - | - | - | - | - | - | - |
| IMGD(Calixto and Liu, 2017) | 37.3 | 55.1 | - | - | - | - | - | - | - | - |
| Fusion-conv(Caglayan et al., 2017) | 37.0 | 57.0 | 29.8 | 51.2 | 25.1 | 46.0 | 53.5 | 70.4 | 51.6 | 68.6 |
| Trg-mul(Caglayan et al., 2017) | 37.8 | 57.7 | 30.7 | 52.2 | 26.4 | 47.4 | 54.7 | 71.3 | 52.7 | 69.5 |
| VAG-NMT(Zhou et al., 2018) | - | - | 31.6 | 52.2 | 28.3 | 48.0 | - | - | 53.8 | 70.3 |
| DS-SUM-L2(Caglayan, 2019) | 39.4 | 58.7 | 32.6 | 52.9 | - | - | 60.7 | 76.0 | 54.2 | 71.0 |
| Del+obj(Ive et al., 2019) | 38.0 | 55.6 | - | - | - | - | 59.8 | 74.4 | - | - |
| Multimodal(Yao and Wan, 2020) | 38.7 | 55.7 | - | - | - | - | - | - | - | - |
| GMNMT(Yin et al., 2020) | 39.8 | 57.6 | 32.2 | 51.9 | 28.7 | 47.6 | 60.9 | 74.9 | 53.9 | 69.3 |
| DCCN(Lin et al., 2020) | 39.7 | 56.8 | 31.0 | 49.9 | 26.7 | 45.7 | 61.2 | 76.4 | 54.3 | 70.3 |
| Gumbel-att(Liu et al., 2021) | 39.2 | 57.8 | 31.4 | 51.2 | 26.9 | 46.0 | - | - | - | - |
| OVC+Lm(Wang and Xiong, 2021) | - | - | 32.3 | 52.4 | 28.9 | 48.1 | - | - | 54.1 | 70.5 |
| Gated Fusion(Wu et al., 2021) | 41.96 | - | 33.59 | - | 29.04 | - | 61.69 | - | 54.85 | - |
| RMMT(Wu et al., 2021) | 41.45 | - | 32.94 | - | 30.01 | - | 62.1 | - | 54.39 | - |
| Image-free MMT Systems |
| Transformer(Vaswani et al., 2017) | 37.6 | 55.3 | 31.7 | 52.1 | 27.9 | 47.8 | 59.0 | 73.6 | 51.9 | 68.3 |
| Multitask(Elliott and Kádár, 2017) | 36.8 | 55.8 | - | - | - | - | - | - | - | - |
| VMMTF(Calixto et al., 2019) | 37.7 | 56.0 | 30.1 | 49.9 | 25.5 | 44.8 | - | - | - | - |
| UVR-NMT(Zhang et al., 2020) | 36.94 | - | 28.63 | - | - | - | 57.53 | - | 48.46 | - |
| ImagiT (Long et al., 2021) | 38.5 | 55.7 | 32.1 | 52.4 | 28.7 | 48.8 | 59.7 | 74.0 | 52.4 | 68.3 |
| IKD-MMT (Ours) | 41.28‡ | 58.93 | 33.83† | 53.21 | 30.17 | 48.93 | 62.53† | 77.20 | 54.84† | 71.87 |
| ±0.3 | ±0.20 | ±0.10 | ±0.26 | ±0.14 | ±0.08 | ±0.25 | ±0.18 | ±0.50 | ±0.34 |
+
+training and validation sets contain 29,000 and 1,014, respectively. We report the results of the Test2016, Test2017 and ambiguous MSCOCO test sets. We directly use the preprocessed sentences3 and apply the BPE (Sennrich et al., 2016) with 10K merge operations to segment words into sub-words, which build a shared vocabulary of 9,712 and 9,544 tokens for EN-DE and EN-FR translation tasks.
+
+Settings We follow all model settings of (Wu et al., 2021), such as the Transformer-Tiny configuration for anti-overfitting in small datasets. 4-gram case-insensitive BLEU (Papineni et al., 2002) and METEOR (Denkowski and Lavie, 2014) are used as evaluation metrics. All models are run three times and report the average results.
+
+# 4.2 Main Results
+
+EN-DE Translation Task Table 1 reports the performance of all MMT baselines on the EN-DE task. Comparing all systems, we draw the following interesting conclusions:
+
+First, the IKD-MMT significantly surpasses all image-free MMT systems on five test sets. These
+
+improvements demonstrate that a) our model can effectively embed multimodal semantics during the training and guide the translation via multimodal features among the image-free testing phase, b) benefiting from the informative richness and stable generation of multimodal features, our method is a more robust way to break data constraints.
+
+Second, the image-must MMT systems generally exceed their image-free counterparts, showing the efficacy of additional images for translation.
+
+Finally, encouragingly, our image-free MMT model not only overbeats almost all image-must MMT systems, but even rivals the SOTA image-must MMT. We speculate that these noticeable gains stem from the IKD-MMT's strong ability to fuse the text semantics and visual perception, and generate text-related visual representation, under the dual supervision of text translation and visual distillation.
+
+EN-FR Translation Task We also conduct experiments on the EN-FR task. Our IKD-MMT still outperforms the compared baselines in Table 1. This verifies the robustness and generality of our model in various language scenarios.
+
+Table 2: Ablation results for diverse distillation variants on the EN-DE task. The base row denotes the IKD-MMT in Table 1, and “-” means to retain the setting of the base row. Avg.B and Avg.M indicate the BLEU and METEOR scores of the three test sets
+
+ | Sim. Func. | Dist. Gran. | CNN Back. | Dist. Loss | Avg.B | Avg.M |
| base | L2 | Model | ResNet50 | (IrM-KD+IaM-KD) loss | 35.09 | 53.69 |
| (A) | L1 | - | - | - | 34.60 (-0.49) | 53.39 (-0.30) |
| L∞ | - | - | - | 34.15 (-0.94) | 53.27 (-0.42) |
| Cosine | - | - | - | 34.64 (-0.45) | 53.27 (-0.42) |
| KL-Div. | - | - | - | 34.62 (-0.47) | 53.56 (-0.13) |
| (B) | - | Block | - | | 34.57 (-0.52) | 53.27 (-0.42) |
| - | Layer | - | - | 34.85 (-0.24) | 53.25 (-0.44) |
| (C) | - | - | VGG19 | - | 34.38 (-0.71) | 53.24 (-0.45) |
| - | - | AlexNet | - | 33.98 (-1.11) | 52.99 (-0.70) |
| (D) | - | - | - | w/o (IrM-KD+IaM-KD) loss | 27.30 (-7.79) | 51.11 (-2.58) |
| - | - | - | Image Space loss | 32.91 (-2.18) | 52.41 (-1.28) |
| - | - | - | w/o IaM-KD loss | 33.64 (-1.45) | 52.81 (-0.88) |
| - | - | - | w/o IrM-KD loss | 34.03 (-1.06) | 53.08 (-0.61) |
+
+Table 3: Validation ablation results for diverse distillation variants on the EN-DE task. The base row denotes the IKD-MMT in Multi30K development sets, and “-” means to retain the setting of the base row. Dev.B and Dev.M indicate the BLEU and METEOR scores of the development set
+
+ | Sim. Func. | Dist. Gran. | CNN Back. | Dist. Loss | Dev.B | Dev.M |
| base | L2 | Model | ResNet50 | (IrM-KD+IaM-KD) loss | 42.48 | 59.20 |
| (A) | L1 | - | - | - | 41.33(-1.15) | 58.55(-0.65) |
| L∞ | - | - | - | 41.80(-0.68) | 58.92(-0.28) |
| Cosine | - | - | - | 41.44(-1.04) | 58.64(-0.56) |
| KL-Div. | - | - | - | 41.90 (-0.58) | 58.89(-0.31) |
| (B) | - | Block | - | | 41.83(-0.65) | 59.01(-0.19) |
| - | Layer | - | - | 41.67(-0.81) | 58.69(-0.51) |
| (C) | - | - | VGG19 | - | 41.69(-0.79) | 58.80(-0.40) |
| - | - | AlexNet | - | 41.20(-1.28) | 58.45(-0.75) |
| (D) | - | - | - | w/o (IrM-KD+IaM-KD) loss | 36.02(-6.46) | 55.67(-3.53) |
| - | - | - | Image Space loss | 40.45(-2.03) | 57.96(-1.24) |
| - | - | - | w/o IaM-KD loss | 41.14(-1.34) | 58.39(-0.81) |
| - | - | - | w/o IrM-KD loss | 41.46(-1.02) | 58.66(-0.54) |
+
+# 4.3 Ablation Studies
+
+Table 2 illustrates ablation experiments on the EN-DE task to explore the impact of different collocations of distillation modules.
+
+Similarity Function First, we explore the effect of using varied similarity functions to measure the divergence between hidden representations in our distillation module. As shown in row (A), the $L_{2}$ norm is the best option. Later, the performance order is KL Divergence (Kullback and Leibler, 1951) > $L_{1}$ norm > Cosine similarity > $L_{\infty}$ .
+
+Distillation Granularity Second, in row (B), we analyze what distillation granularity would be the golden standard of our model for optimal translation performance. Specifically, the "Layer", "Block" and "Model" represents that we employ
+
+representations of each layer, each block, the last convolutional layer and the image in teacher-student models to compute the distillation loss. Based on the evaluation results, we conclude that the "Model" is optimal, and the "Block" is consistent with the "Layer" in the Meteor score, but slightly inferior in the BLEU score. The such phenomenon reflects that the initial and terminal representations in our knowledge distillation are sufficient to teach the student model to generate information-rich features. This case breaks the stereotype that KD must transmit all knowledge.
+
+CNN Backbone Third, in row (C), we devise three variants with diverse CNN backbones to investigate their impact on the translation. The ResNet50 wins this round since the deep
+
+residual network can derive the strongest visual representation. The VGG19 performs worse with the absence of residual connection and plenty of training samples for model convergence. Undoubtedly, the lightweight AlexNet incurs the worst translation degradation. It implies that the feature extraction capability of a small model may be difficult to undertake the heavy task of multi-supervised learning.
+
+Distillation Loss Finally, we discuss the translation performance of different distillation loss strategies in row (D). Unsurprisingly, w/o (IrM-KD+IaM-KD) loss suffers the severest performance degradation. Removing visual distillation leads to the absence of visual perception in multimodal features, which evolves into a perturbed feature obtained by passing the global text feature into the Fc&Avg Unpool. Afterwards, w/o IrM-KD loss outperforms w/o IaM-KD loss, indicating that the capability of the IaM-KD to establish the text-image relevance that is critical for multimodal feature synthesis is stronger than the IrM-KD. We assume this event is related to that the IaM-KD covers the propagation path of the IrM-KD. Compared with Image Space loss, the improvement of our method reveals that the intermediate hidden state of the teacher model plays a vital role in teaching the student model to comprehend the text-image correlations, as also verified in preceding KD work (Romero et al., 2014; Yim et al., 2017). Overall, each distillation loss considerably improves translation.
+
+Ablation Studies on Development set Table 3 attaches all the validation ablation results to corroborate that each distillation hyperparameter also contributes its decent gains on the model convergence rather than just the model generalization. Drawing from the tabular results, all hyperparameters can be tuned freely on the dev set. We further notice that the performances on the dev set align quite well with the testing set, in terms of tendency.
+
+# 5 Analysis
+
+In this section, we will investigate our IKD-MMT model from multiple perspectives.
+
+# 5.1 Does IKD-MMT really generate multimodal features?
+
+To explore the multimodal features generated by our distillation strategy, we test their informative
+
+Table 4: Image retrieval tasks on the Multi30K dataset.
+
+ | R@1 | R@5 | R@10 | R@15 |
| Train | 0 | 0.02 | 0.04 | 0.05 |
| Valid | 0.1 | 0.69 | 0.89 | 1.38 |
| Test2016 | 0.1 | 0.7 | 1.0 | 1.5 |
| Test2017 | 0.1 | 0.5 | 1.1 | 1.5 |
| MSCOCO | 0.22 | 0.65 | 2.39 | 2.82 |
+
+
+Figure 3: The cluster analysis of the learned multimodal feature, where the two colored boxes represent some representative images in the two cluster cases. The arrow points to the original image that is belonged to the current multimodal feature (i.e. cluster center).
+
+richness from three aspects:
+
+Image Retrieval The image retrieval task aims to analyze the relationship between our generated multimodal feature and the visual feature. Specifically, we generate the multimodal feature from each source sentence. Further, we find the K closest visual features for each multimodal feature based on cosine similarity. Then, we measure the R@K score, which calculates the recall rate of the visual feature of current sample in these top K nearest neighborhoods. The results in Table 4 display that no matter any K, or whichever data set, the R@K scores are extremely low. These retrieval scores confirm that our model is not trying to generate the visual feature of the current image.
+
+Cluster Visualization In Figure 3, we visualize the related pictures which retrieved by the multimodal feature at the cluster map. Here, points of different colors fall into different clusters, and the distance between points is specified by the cosine similarity between multimodal features and visual features. In the cluster case (a), the other images exist the points-of-parity with the original image, namely objects, backgrounds, and actions (girl, sand, walking). Likewise, in the cluster case (b), the other images satisfy the identical thematic content (person, rock, climbing) as the original image. Certainly, these related pictures also conform to the original text's description of the scene. So the multimodal features are confirmed to have learned commonalities between images.
+
+Attention Weights In Figure 4, we envision the
+
+
+Figure 4: Visualization of attention weights for fusion of multimodal features and text features. The weight values decreasing as the color becomes lighter.
+
+
+
+attention weights4 for the fusion of multimodal features and text features. These weights display which text words the different regions of the multimodal feature focus on. Combining the two examples, several insights are excavated as follows: 1) Part of the multimodal feature with the size of sentence length can be regarded as "pseudowords", and a word alignment is formed with the text feature. 2) The rest of the multimodal features pay the attention to words equally. We conjecture that these regions as non-object parts thus tend to contribute a consistent impact on text translation. 3) The attention weight of the former three attention heads are flat and presents linearization at the bottom part, while one of 4th attention head is fluctuating and presents dispersion at the bottom part. This means that the first three attention heads capture the entire sentence semantics with the "global attention" form. The 4th attention head, acts like the "local attention", and emphasizes understanding the keywords of the sentence. These findings demonstrate that the multimodal features have embedded the textual semantics.
+
+To summarize, the above experiments can fully prove that our IKD-MMT reliably generates an information-rich multimodal feature.
+
+# 5.2 Can multimodal features be directly used for translation?
+
+Our IKD-MMT model synthesizes a multimodal feature equipped with textual and image knowledge through a multimodal generator. A natural question to ask is, can multimodal features be fed into the encoder alone, rather than being cascaded with textual features for translation?
+
+To this end, we compare the model removing
+
+Table 5: Results of IKD-MMT without text features.
+
+ | Test2016 | Test2017 | MSCOCO |
| B M | B M | B M |
| IKD-MMT | 41.28 | 33.83 | 53.21 |
| w/o Text Feat. | 22.06 | 39.44 | 19.35 |
+
+Table 6: Results of two degraded text and original text ${}^{5}$ .
+
+| Model | D | DC | Dε |
| Transformer | 52.5 | 50.28 (↓2.22) | 33.81 (↓18.61) |
| Multimodal | 53.18 | 51.30 (↓1.88) | 35.04 (↓18.14) |
| IKD-MMT | 53.21 | 51.30 (↓1.91) | 34.59 (↓18.62) |
+
+text features with the original benchmark in Table 5. We notice that w/o Text Feat. appears a cliff-like performance drop, which is explainable. In the multimodal encoding layer, the dot product of the query and key vectors is used to mark the importance of each token corresponding to other tokens in the sentence, i.e. the attention score. If we treat the multi-modal feature as the query, its fixed $P$ regions can be regarded as a set of pseudo tokens. Considering this token set carries limited semantics and destroys the word alignment, it is difficult to obtain an available attention score alone. In addition, most studies convey that text semantics is more important than visual perception in the MMT task (Grönroos et al., 2018; Lala et al., 2018).
+
+# 5.3 Can multimodal features recover the missing text?
+
+In Table 6, we adopt two degradation strategies (Ive et al., 2019; Caglayan et al., 2019) for the source sentence, and feed into Transformer, Multimodal and our IKD-MMT, to probe whether multimodal features can recover the missing text. Test2017 Meteor scores are used for evaluation.
+
+Color Deprivation We mask the source tokens that refer to colors as a special token [U], which involves $3.19\%$ and $3.16\%$ of the words in the training set and test set, respectively. As shown in the column $\mathcal{D}_{\mathcal{C}}$ , after color deprivation, the text-only Transformer fails to align the source and target tokens, then leads to the worst performance descent. Our IKD-MMT and Image-must Multimodal hardly synthesize color information to compensate for the deterioration of color missing.
+
+Entity Masking We tag all visually depictable entities (Plummer et al., 2015) with a special token
+
+
+(b)
+
+
+(a)
+(a)
+(b)
+Figure 5: Translation cases of different models. The red and blue highlight error and correct translations respectively.
+
+Source text:
+
+Target text:
+
+a ballerina in blue twirls .
+
+eine ballerina in blau wirbelt herum.
+
+Transformer:
+
+NMTSRC+IMG:
+
+Multitask:
+
+URA-NMT:
+
+Multimodal:
+
+IKD-MMT(ours):
+
+eine ballerina in blau dreht sich .
+
+eine ballerina in blauer kleidung wirbelt herum.
+
+eine ballerina in blauer kleidung wirbelt herum.
+
+eine ballerina in blau dreht sich.
+
+eine ballerina in blau dreht sich.
+
+eine ballerina in blau wirbelt herum.
+
+a little girl is walking barefoot on the sand. ein kleines madchen gehen barfuim sand.
+
+ein kleines madchen lauf barfu auf dem sand.
+
+ein kleines madchen lauf barfu auf dem sand.
+
+ein kleines madchen lauf barfuß auf dem sand.
+
+ein kleines madchen lauft barfuß im sand.
+
+ein kleines madchen lauft barfuß auf dem sand.
+
+ein kleines madchen gehen barfuim sand.
+
+[U], which affects $29.49\%$ and $31.12\%$ of the words in the training set and test set, respectively. In the $\mathcal{D}_{\mathcal{E}}$ column, we observe that the IKD-MMT and the text-only Transformer degrade equally in performance, which is because IKD-MMT unable to distill the visual perception of multimodal features from the entity-missed text.
+
+Beyond these two masking experiments, we revisit such token recovery problems to pose a more common-sense insight: As per the faithfulness-first principle (Koehn, 2009) in translation, once the source sentence misses keyword information, what we need to do is translate this degraded faithfully. Re-translate back to the original target text from the degraded source text is false.
+
+# 5.4 Case Study
+
+Figure 5 depicts the 1-best translation of the two test cases generated by various systems. Other systems mistranslate and over-translate text in case (a) and distort the semantics due to mistakenly translating "geht" (walking) to "läuft" (running) in case(b). Our IKD-MMT relies on rich multimodal semantics to keep the translation fidelity.
+
+# 6 Conclusion
+
+In this work, we propose the IKD-MMT framework to address the image-must issue for multimodal machine translation (MMT) via the knowledge distillation paradigm. Under this image-free MMT system, there are three key contributions: 1) An information-rich multimodal feature is generated by the dual constraints of visual distillation and text translation to support the image-free testing stage; 2) The knowledge distillation module is flexible, and pioneers to employ of the pre-trained model to guide translation; 3) Both quantitative and qualitative results validate the feasibility of the proposed approach IKD-MMT, where it can be deemed the first framework that rivals or even surpass most (if not all) image-must frameworks.
+
+# Acknowledgements
+
+Ru Peng and Junbo Zhao were supported by the Fundamental Research Funds for the Central Universities (No. 226-2022-00028). Junbo Zhao also wants to thank the Zhejiang University startup package. The authors would like to thank the Institute of Computer Innovation of Zhejiang University for the high-performance computing platform.
+
+# Limitations
+
+From a representation learning perspective, this work is dedicated to introduce the visual perception pipeline and the comprehension of text-image correlations from texts, and may be limited to more complex visual descriptive text (if there exists numerous visual descriptive entities). Further, since the Multi30K is the only and most commonly used MMT benchmark, most of the experiments are centered around it. We additionally made a "bold" attempt to move IKD-MMT onto much larger scaled NMT datasets for testing only — thanks to the image-free nature of our approach — and unfortunately the inference results did not look decent enough. While the IKD-MMT's image-free inference pass can be fully facilitated in this scenario, we attribute the inferior results to the much simpler data distribution involved in the Multi30K. Indeed, we hope a richer or real-world MMT dataset could fully bridge this image-free performance gap between MMT and NMT. That, however, may have gone beyond the scope of this paper.
+
+# References
+
+Hasan Sait Arslan, Mark Fishel, and Gholamreza Anbarjafari. 2018. Doubly attentive transformer machine translation. arXiv preprint arXiv:1807.11605.
+Loic Barrault, Fethi Bougares, Lucia Specia, Chiraag Lala, Desmond Elliott, and Stella Frank. 2018.
+
+Findings of the third shared task on multimodal machine translation. In Proceedings of the Third Conference on Machine Translation: Shared Task Papers, pages 304-323.
+Cristian Buciluco, Rich Caruana, and Alexandru Niculescu-Mizil. 2006. Model compression. In Proceedings of the 12th ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, page 535-541.
+Ozan Caglayan. 2019. Multimodal machine translation. Ph.D. thesis, Université du Maine.
+Ozan Caglayan, Walid Aransa, Adrien Bardet, Mercedes García-Martínez, Fethi Bougares, Loïc Barrault, Marc Masana, Luis Herranz, and Joost van de Weijer. 2017. LIUM-CVC submissions for WMT17 multimodal translation task. In Proceedings of the Second Conference on Machine Translation, pages 432-439.
+Ozan Caglayan, Pranava Madhyastha, Lucia Specia, and Loic Barrault. 2019. Probing the need for visual context in multimodal machine translation. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4159-4170.
+Iacer Calixto and Qun Liu. 2017. Incorporating global visual features into attention-based neural machine translation. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 992-1003.
+Iacer Calixto, Qun Liu, and Nick Campbell. 2017. Doubly-attentive decoder for multi-modal neural machine translation. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1913-1924.
+Iacer Calixto, Miguel Rios, and Wilker Aziz. 2019. Latent variable model for multi-modal translation. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6392-6405.
+Michael Denkowski and Alon Lavie. 2014. Meteor universal: Language specific translation evaluation for any target language. In Proceedings of the Ninth Workshop on Statistical Machine Translation, pages 376-380.
+Desmond Elliott, Stella Frank, Loici Barrault, Fethi Bougares, and Lucia Specia. 2017. Findings of the second shared task on multimodal machine translation and multilingual image description. In Proceedings of the Second Conference on Machine Translation, pages 215-233.
+Desmond Elliott, Stella Frank, Khalil Sima'an, and Lucia Specia. 2016. Multi30K: Multilingual English-German image descriptions. In Proceedings of the 5th Workshop on Vision and Language, pages 70-74.
+
+Desmond Elliott and Ákos Kádár. 2017. Imagination improves multimodal translation. In Proceedings of the Eighth International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 130-141.
+Jonas Gehring, Michael Auli, David Grangier, and Yann Dauphin. 2017. A convolutional encoder model for neural machine translation. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 123-135.
+Stig-Arne Gronroos, Benoit Huet, Mikko Kurimo, Jorma Laaksonen, Bernard Merialdo, Phu Pham, Mats Sjoberg, Umut Sulubacak, Jorg Tiedemann, Raphael Troncy, and Raul Vázquez. 2018. The MeMAD submission to the WMT18 multimodal translation task. In Proceedings of the Third Conference on Machine Translation: Shared Task Papers, pages 603-611.
+Saurabh Gupta, Judy Hoffman, and Jitendra Malik. 2016. Cross modal distillation for supervision transfer. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 2827-2836.
+Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. 2016. Deep residual learning for image recognition. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 770-778.
+Jindrich Helcl, Jindrich Libovický, and Dusan Varš. 2018. CUNI system for the WMT18 multimodal translation task. In Proceedings of the Third Conference on Machine Translation: Shared Task Papers, pages 616-623.
+Geoffrey Hinton, Oriol Vinyals, and Jeff Dean. 2015. Distilling the knowledge in a neural network. arXiv preprint arXiv:1503.02531.
+Julia Ive, Pranava Madhyastha, and Lucia Specia. 2019. Distilling translations with visual awareness. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6525-6538.
+Philipp Koehn. 2009. Statistical machine translation. Cambridge University Press.
+Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. 2012. Imagenet classification with deep convolutional neural networks. Advances in neural information processing systems, 25:1097-1105.
+Solomon Kullback and Richard A Leibler. 1951. On information and sufficiency. The annals of mathematical statistics, 22(1):79-86.
+Chiraag Lala, Pranava Swaroop Madhyastha, Carolina Scarton, and Lucia Specia. 2018. Sheffield submissions for WMT18 multimodal translation shared task. In Proceedings of the Third Conference
+
+on Machine Translation: Shared Task Papers, pages 624-631.
+Huan Lin, Fandong Meng, Jinsong Su, Yongjing Yin, Zhengyuan Yang, Yubin Ge, Jie Zhou, and Jiebo Luo. 2020. Dynamic context-guided capsule network for multimodal machine translation. In Proceedings of the 28th ACM International Conference on Multimedia, pages 1320-1329.
+Pengbo Liu, Hailong Cao, and Tiejun Zhao. 2021. Gumbel-attention for multi-modal machine translation. arXiv preprint arXiv:2103.08862.
+Quanyu Long, Mingxuan Wang, and Lei Li. 2021. Generative imagination elevates machine translation. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 5738-5748.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th Annual Meeting of the Association for Computational Linguistics, pages 311-318.
+Bryan A Plummer, Liwei Wang, Chris M Cervantes, Juan C Caicedo, Julia Hockenmaier, and Svetlana Lazebnik. 2015. Flickr30k entities: Collecting region-to-phrase correspondences for richer imageto-sentence models. In Proceedings of the IEEE international conference on computer vision, pages 2641-2649.
+Scott Reed, Zeynep Akata, Xinchen Yan, Lajanugen Logeswaran, Bernt Schiele, and Honglak Lee. 2016. Generative adversarial text to image synthesis. In International conference on machine learning, pages 1060-1069. PMLR.
+Adriana Romero, Nicolas Ballas, Samira Ebrahimi Kahou, Antoine Chassang, Carlo Gatta, and Yoshua Bengio. 2014. Fitnets: Hints for thin deep nets. arXiv preprint arXiv:1412.6550.
+Rico Sennrich, Barry Haddow, and Alexandra Birch. 2016. Neural machine translation of rare words with subword units. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1715-1725.
+Karen Simonyan and Andrew Zisserman. 2014. Very deep convolutional networks for large-scale image recognition. arXiv preprint arXiv:1409.1556.
+Lucia Specia, Stella Frank, Khalil Sima'an, and Desmond Elliott. 2016. A shared task on multimodal machine translation and crosslingual image description. In Proceedings of the First Conference on Machine Translation: Volume 2, Shared Task Papers, pages 543-553.
+
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in neural information processing systems, pages 5998-6008.
+Dexin Wang and Deyi Xiong. 2021. Efficient object-level visual context modeling for multimodal machine translation: Masking irrelevant objects helps grounding. In Proceedings of the AAAI Conference on Artificial Intelligence, pages 2720-2728.
+Zhiyong Wu, Lingpeng Kong, Wei Bi, Xiang Li, and Ben Kao. 2021. Good for misconceived reasons: An empirical revisiting on the need for visual context in multimodal machine translation. arXiv preprint arXiv:2105.14462.
+Tao Xu, Pengchuan Zhang, Qiuyuan Huang, Han Zhang, Zhe Gan, Xiaolei Huang, and Xiaodong He. 2018. Attngan: Fine-grained text to image generation with attentional generative adversarial networks. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 1316-1324.
+Shaowei Yao and Xiaojun Wan. 2020. Multimodal transformer for multimodal machine translation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4346-4350.
+Junho Yim, Donggyu Joo, Jihoon Bae, and Junmo Kim. 2017. A gift from knowledge distillation: Fast optimization, network minimization and transfer learning. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 4133-4141.
+Yongjing Yin, Fandong Meng, Jinsong Su, Chulun Zhou, Zhengyuan Yang, Jie Zhou, and Jiebo Luo. 2020. A novel graph-based multi-modal fusion encoder for neural machine translation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 3025-3035.
+Mingkuan Yuan and Yuxin Peng. 2018. Text-to-image synthesis via symmetrical distillation networks. In Proceedings of the 26th ACM international conference on Multimedia, pages 1407-1415.
+Han Zhang, Tao Xu, Hongsheng Li, Shaoting Zhang, Xiaogang Wang, Xiaolei Huang, and Dimitris N Metaxas. 2017. Stackgan: Text to photo-realistic image synthesis with stacked generative adversarial networks. In Proceedings of the IEEE international conference on computer vision, pages 5907-5915.
+Yin Zhang, Rong Jin, and Zhi-Hua Zhou. 2010. Understanding bag-of-words model: a statistical framework. International Journal of Machine Learning and Cybernetics, 1(1-4):43-52.
+Zhuosheng Zhang, Kehai Chen, Rui Wang, Masao Utiyama, Eiichiro Sumita, Zuchao Li, and Hai Zhao 2020. Neural machine translation with universal
+
+visual representation. In International Conference on Learning Representations.
+
+Mingyang Zhou, Runxiang Cheng, Yong Jae Lee, and Zhou Yu. 2018. A visual attention grounding neural model for multimodal machine translation. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 3643-3653.
+
+# A Appendix
+
+Table 7: Architecture of each module in multimodal feature generation. The multimodal student model has inverted data flow with visual teacher model. These architectures can be easily replaced with any CNN variant (e.g. VGG19 (Simonyan and Zisserman, 2014), AlexNet (Krizhevsky et al., 2012)) with reference to ResNet50 (He et al., 2016).
+
+| Visual Teacher Model | Multimodal Student Model |
| layer name | output size | 49-layer | layer name | output size | 48-layer | |
| T-conv1 | 112x112 | 7x7, 64, stride 2 | S-conv1 | 224x224 | 8x8, 3, stride 2 | |
| T-conv2_x | 56x56 | 3x3 max pool, stride 2 | S-conv2_x | 112x112 | 2x2 max unpool, stride 2 | |
| [1x1, 643x3, 641x1, 256]x3 | | [1x1, 2563x3, 641x1, 64]x3 |
| T-conv3_x | 28x28 | [1x1, 1283x3, 1281x1, 512]x4 | S-conv3_x | 56x56 | | [1x1, 5123x3, 1281x1, 128]x4 |
| T-conv4_x | 14x14 | [1x1, 2563x3, 2561x1, 1024]x6 | S-conv4_x | 28x28 | | [1x1, 5123x3, 2561x1, 256]x6 |
| T-conv5_x | 7x7 | [1x1, 5123x3, 5121x1, 2048]x3 | S-conv5_x | 14x14 | | [1x1, 10243x3, 5121x1, 512]x3 |
| N/A | 1x1 | average pool | | | | |
| Multimodal Feature Generator | N/A | 7x7 | 2048-d fc, average unpool | |
\ No newline at end of file
diff --git a/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/images.zip b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..4dfde791aebcf2052857dd250a2e9b173d9221bb
--- /dev/null
+++ b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:392801264be0d6b60d226e534d54fb5b672ca82bf0fbfb958ee8779e0cd9b2f7
+size 716843
diff --git a/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/layout.json b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..0ffb8222301fa0a8baa90d6413f635b5512a71d4
--- /dev/null
+++ b/distilltheimagetonowhereinversionknowledgedistillationformultimodalmachinetranslation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1cccc053f4a93d748299e96e8b9c54564394a63cfcc9e9a2946d37a5eddd2315
+size 432452
diff --git a/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_content_list.json b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..2f44b2ab2dad2036028af711d12636f0e21c68ed
--- /dev/null
+++ b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ebcae44cbe8198d33df6d2e67ee6fda1f2c623984b26c14c335044afef2b87fa
+size 137686
diff --git a/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_model.json b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..7abd43e903ee356df7c14fe54ecde3100a9abf49
--- /dev/null
+++ b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ffc18e9787bae8bb5a248133292cfa18272c5627698b9da6c96df55b260cd385
+size 161746
diff --git a/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_origin.pdf b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..aef9e6fe708e010c1e8bdf75f9ad1a5d256d1fb3
--- /dev/null
+++ b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/503c2d6a-bc6c-454f-b63d-c33adb900967_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f4eead63b2e22361c49e5b390dd638baccad6d8a202b70da5c8b315d884e922f
+size 1280837
diff --git a/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/full.md b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..d9af1546661e2e29c3ecda47bd0484633852f8d2
--- /dev/null
+++ b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/full.md
@@ -0,0 +1,435 @@
+# DivEMT: Neural Machine Translation Post-Editing Effort Across Typologically Diverse Languages
+
+Gabriele Sarti, Arianna Bisazza, Ana Guerberof-Arenas, Antonio Toral
+
+Center for Language and Cognition (CLCG), University of Groningen {g.sarti, a.bisazza, a.guerberof.arenas, a.toral.ruiz}@rug.nl
+
+# Abstract
+
+We introduce DivEMT, the first publicly available post-editing study of Neural Machine Translation (NMT) over a typologically diverse set of target languages. Using a strictly controlled setup, 18 professional translators were instructed to translate or post-edit the same set of English documents into Arabic, Dutch, Italian, Turkish, Ukrainian, and Vietnamese. During the process, their edits, keystrokes, editing times and pauses were recorded, enabling an in-depth, cross-lingual evaluation of NMT quality and post-editing effectiveness. Using this new dataset, we assess the impact of two state-of-the-art NMT systems, Google Translate and the multilingual mBART-50 model, on translation productivity. We find that post-editing is consistently faster than translation from scratch. However, the magnitude of productivity gains varies widely across systems and languages, highlighting major disparities in post-editing effectiveness for languages at different degrees of typological relatedness to English, even when controlling for system architecture and training data size. We publicly release the complete dataset1 including all collected behavioral data, to foster new research on the translation capabilities of NMT systems for typologically diverse languages.
+
+# 1 Introduction
+
+Recent advances in neural language modeling and multilingual training have prompted a widespread adoption of machine translation (MT) technologies across an unprecedented range of world languages. While the benefits of state-of-the-art MT for crosslingual information access are undisputed (Lommel and Pielmeier, 2021), its usefulness as an aid to professional translators varies considerably across domains, subjects and language combinations (Zouhar et al., 2021). In the last decade, the
+
+MT community has been including an increasing number of languages in its automatic and human evaluation efforts (Bojar et al., 2013; Barrault et al., 2021). However, the results of these evaluations are typically not directly comparable across different language pairs for various reasons. First, reference-based automatic quality metrics are hardly comparable across different target languages (Bugliarello et al., 2020). Secondly, human judgments are collected independently for different language pairs, making their cross-lingual comparison vulnerable to confounding factors such as tested domains and training data sizes. Similarly, recent work on NMT post-editing efficiency has focused on specific language pairs such as English-Czech (Zouhar et al., 2021), German-Italian, German-French (Läubli et al., 2019) and English-Hindi (Ahsan et al., 2021), but a controlled comparison across a set of typologically diverse languages is still lacking.
+
+In this work, we assess the usefulness of state-of-the-art NMT in professional translation with a strictly controlled cross-language setup (Figure 1). Specifically, professionals were asked to translate the same English documents into six typologically different languages (Arabic, Dutch, Italian, Turkish, Ukrainian, and Vietnamese) using the same platform and guidelines. Three translation modalities were adopted: human translation from scratch (HT), post-editing of Google Translate's translation $(\mathrm{PE}_1)$ , and post-editing of mBART-50's translation $(\mathrm{PE}_2)$ , the latter being a state-of-the-art open-source, multilingual NMT system. In addition to post-editing results, subjects' fine-grained editing behavior — including keystrokes and time information — was logged to measure productivity and effort across languages, systems and translation modalities. Finally, translators were asked to complete a qualitative assessment regarding their perceptions of MT quality and post-editing effort. The resulting DivEMT dataset is to our best knowledge the first public resource allow
+
+
+Figure 1: The DivEMT data collection process. For every English source document, 18 professional translators are tasked to translate it from scratch (HT) or post-edit NMT systems' outputs $(\mathrm{PE}_1 / \mathrm{PE}_2)$ into six typologically diverse target languages. Behavioral data and qualitative assessments are collected during and after the process respectively.
+
+ing a direct comparison of professional translators' productivity and fine-grained editing information across a set of typologically-diverse languages. DivEMT is publicly released alongside this paper as a unique resource to study the language- and system-dependent nature of NMT advances in real-world translation scenarios.
+
+# 2 Related Work
+
+Cross-lingual MT Evaluation Before the advent of NMT, Birch et al. (2008) studied how various language properties affected the quality of Statistical MT (SMT) across a sizeable sample of European language pairs. The comparison, however, was solely based on BLEU, which is in fact not comparable across different target languages (Bugliarello et al., 2020). Recent work on neural models introduced more principled ways to measure the intrinsic difficulty of language-modeling (Gerz et al., 2018; Cotterell et al., 2018; Mielke et al., 2019) and machine
+
+translating (Bugliarello et al., 2020; Bisazza et al., 2021) different languages. However, achieving this reliably without any human evaluation remains an open research question. Human evaluations of MT quality are routinely conducted during campaigns such as WMT (Koehn and Monz, 2006; Akhbardeh et al., 2021) and IwSLT (Cettolo et al., 2016, 2017) among others, but their focus is on language- and domain-specific ranking of MT systems — often leveraging non-professional annotators (Freitag et al., 2021) — rather than crosslingual quality comparisons. Concurrently to this work, Licht et al. (2022) proposed a new human evaluation protocol to improve consistency in crosslingual MT quality assessment.
+
+Post-editing NMT Measuring post-editing effort across its temporal, cognitive, and technical dimensions (Krings, 2001) is a well-established way to assess the effectiveness and efficiency of MT as a component of specialized translation workflows. Seminal post-editing studies highlighted an increase in translators' productivity following MT adoption (Guerberof, 2009; Green et al., 2013; Läubli et al., 2013; Plitt and Masselot, 2010; Parra Escartin and Arcedillo, 2015). However, they also struggled to identify generalizable findings due to confounding factors like output quality, content domains, and high variance across language pairs and human subjects. With the advent of NMT, productivity gains of the new approach were extensively compared to those of SMT, the highly-customized dominant paradigm at the time (Castilho et al., 2017; Bentivogli et al., 2016; Toral et al., 2018; Läubli et al., 2019). Initial results were promising for NMT due to its better fluency and overall results. Moreover, translators were shown to prefer NMT over SMT for post-editing, although a pronounced productivity increase was not always present. More recent work highlighted the productivity gains driven by NMT post-editing in a wider array of languages that were previously challenging for MT, such as English-Dutch (Daems et al., 2017), English-Hindi (Ahsan et al., 2021), English-Greek (Stasimioti and Sosoni, 2020), English-Finnish and English-Swedish (Koponen et al., 2020), all showing a considerable variance among language pairs and subjects. Interestingly, Zouhar et al. (2021) found NMT post-editing speed to be comparable to translation from scratch in English-Czech, and highlighted a disconnect between moderate increases in automatic MT
+
+quality metrics and better post-editing productivity. In sum, research on post-editing NMT generally reports increased fluency and output quality, but productivity gains are hardly generalizable across language pairs and domains. Importantly, to our knowledge, no previous work has studied NMT post-editing over a set of typologically different languages while controlling for the effects of content types and domains, NMT engines, and translation interfaces.
+
+# 3 The DivEMT Dataset
+
+DivEMT's main purpose is to assess the usefulness of state-of-the-art NMT for professional translators and to study how this usefulness varies across target languages with different typological properties. We present below our data collection setup, which strikes a balance between simulating a realistic professional translation workflow and maximizing the comparability of results across languages.
+
+# 3.1 Subjects and Task Scheduling
+
+To control for the effect of individual translators' preferences and styles, we involve a total of 18 subjects (three per target language). During the experiment, each subject receives a series of short documents (3 to 5 sentences each) where the source text is presented in isolation (HT) or alongside a translation proposal produced by one of the NMT systems $(\mathrm{PE}_1,\mathrm{PE}_2)$ . The experiment comprises two phases: During the warm-up phase a set of 5 documents is translated by all subjects following the same, randomly sampled sequence of modalities (HT, $\mathrm{PE}_1$ or $\mathrm{PE}_2$ ). This phase allows the subjects to get used to the setup and enables us to spot possible issues in the logged behavioral data before moving forward. In the main collection phase, each subject is asked to translate documents in a pseudo-random sequence of modalities. This time, however, the sequence is different for each translator and chosen so that each document gets translated in all three modalities. This allows us to measure translation productivity independently from the subject's productivity and document-specific difficulties. A graphical overview of this process is shown in Figure 1, with additional details given in Appendix A. As productivity and other behavioral metrics can only be estimated with a sizable sample, we prioritize the number of documents over the number of subjects per language during budget allocation. A
+
+larger set of post-edited documents also provides more insight in the error type distribution of NMT systems across different language pairs, an analysis which we leave to future work.
+
+All subjects are professional translators with at least 3 years of professional experience, at least one year of post-editing experience and strong proficiency with CAT tools.3 Translators were provided with links to the source articles to facilitate contextualization, were asked to produce translations of publishable quality and were instructed not to use any external MT engine to produce their translations. Assessing the final quality of the post-edited material is out of the scope of the current study, although we realize that this is an important consideration to assess usability in a professional context. A summary of our translation guidelines is provided in Appendix C.
+
+# 3.2 Choice of Source Texts
+
+The selected documents represent a subset of the FLORES-101 benchmark (Goyal et al., 2022) consisting of sentences taken from English Wikipedia, and covering a mix of topics and domains. While professional translators generally specialize in one or a few domains, we opt for a mix-domain dataset to minimize domain adaptation efforts by the subjects and maximize the generalizability of our results. Importantly, FLORES-101 includes high-quality human translations into 101 languages, which makes it possible to automatically estimate NMT quality and discard excessively low-scoring models or language pairs before our experiment. FLORES-101 also provides useful metadata, e.g. source URL, which allows us to ensure the absence of public translations of the selected contents, which could be leveraged by translators and compromise the validity of our setup. The documents used for our study are fragments of contiguous sentences extracted from Wikipedia articles that compose the original FLORES-101 corpus. Even if small, the context provided by document structure allows us to simulate a more realistic translation workflow if compared to out-of-context sentences.
+
+Based on our available budget, we select 112 English documents from the devtest portion of FLORES-101 corresponding to 450 sentences and 9626 words. More details on the data selection process are provided in Appendix D.
+
+ | Genus:Family | dsyn | Morph. | MSP | TTR | Script |
| ENG | IE:Germanic | - | Fus | 1.17 | 0.28 | latin |
| ARA | Af:Semitic | 0.57 | Ifx | 1.67 | 0.46 | arab. |
| NLD | IE:Germanic | 0.49 | Fus | 1.16 | 0.28 | latin |
| ITA | IE:Romance | 0.51 | Fus | 1.30 | 0.30 | latin |
| TUR | Alt:Turkic | 0.70 | Agg | 2.28 | 0.50 | latin |
| UKR | IE:Slavic | 0.51 | Fus | 1.42 | 0.47 | cyril. |
| VIE | Au:VietMuong | 0.57 | Iso | 1.00 | 0.12 | latin |
+
+# 3.3 Choice of Languages
+
+Training data is among the most important factors in defining the quality of a NMT system. Unfortunately, using strictly comparable or multi-parallel datasets, like Europarl (Koehn, 2005) or the Bible corpus (Mayer and Cysouw, 2014), would dramatically restrict the diversity of languages available to our study, or imply a prohibitively low translation quality on general-domain text. In order to minimize the effect of training data disparity while maximizing language diversity, we choose representatives of six different language families for which comparable amounts of training data are available in our open-source model, namely Arabic, Dutch, Italian, Turkish, Ukrainian, and Vietnamese. As shown in Table 1, our language sample ensures a good diversity in terms of language family and relatedness to English, type of morphological system, morphological complexity — measured by mean size of paradigm (MSP, Xanthos et al. 2011) — and script. We also report type-token ratio (TTR), the only language property that was found to correlate significantly with translation difficulty in a sample of European languages (Bugliarello et al., 2020). While the amount of language-specific parallel sentence pairs used for the multilingual fine-tuning of mBART-50 varies widely $(4\mathrm{K} < N < 45\mathrm{M})$ , all our selected language pairs fall within the $100\mathrm{K}-250\mathrm{K}$ range (mid-resourced, see Table 2), enabling a fair cross-lingual performance comparison.
+
+# 3.4 Choice of MT Systems
+
+While most of the best-performing general-domain NMT systems are commercial, experiments based
+
+Table 1: Typological diversity of our language sample. IE: Indo-European, Af: Afro-Asiatic, Alt: Altaic, Au: Austro-Asiatic. $d_{syn}$ : Syntactic distance w.r.t. English (Lin et al., 2019). Fus: fusional, Ifx: introflexive, Agg: agglutinative, Iso: isolating. MSP: Mean size of paradigm, from Cöltekin and Rama (2022). TTR: Type-token ratio measured on FLORES-101. Shading indicates genetic/syntactic relatedness to English and morphological complexity/lexical richness.
+
+ | GTrans (PE1) | mBART-50 (PE2) | # Pairs |
| ARA | 34.1 / 65.6 / .737 | 17.0 / 48.5 / .452 | 226K |
| NLD | 29.1 / 60.0 / .667 | 22.6 / 53.9 / .532 | 226K |
| ITA | 32.8 / 61.4 / .781 | 24.4 / 54.7 / .648 | 233K |
| TUR | 35.0 / 65.5 / 1.00 | 18.8 / 52.7 / .755 | 204K |
| UKR | 31.1 / 59.8 / .758 | 21.9 / 50.7 / .587 | 104K |
| VIE | 45.1 / 61.9 / .724 | 34.7 / 54.0 / .608 | 127K |
+
+Table 2: MT quality of the selected NMT systems for English-to-Target translation on the full FLORES-101 devtest split, in BLEU / CHRF / COMET format. Best scores are highlighted in bold. We report the number of sentence pairs used for mBART-50 multilingual finetuning by Tang et al. (2021).
+
+on such systems are not replicable as their backends get silently updated over time. Moreover, without knowing the exact training specifics, we cannot attribute differences in the cross-lingual results to intrinsic language properties. We balance these observations by including two NMT systems in our study: Google Translate (GTrans) $^{5}$ as a representative of commercial quality, and mBART-50 one-to-Many $^{6}$ (Tang et al., 2021) as a representative of state-of-the-art open-source multilingual NMT technology. The original multilingual BART model (Liu et al., 2020) is an encoder-decoder transformer model pre-trained on monolingual documents in 25 languages. Tang et al. (2021) extend mBART by further pre-training on 25 new languages and performing multilingual translation fine-tuning for the full set of 50 languages, producing three configurations of multilingual NMT models: many-to-one, one-to-many, and many-to-many. Our choice of mBART-50 is largely motivated by its manageable size, its good performances across the set of evaluated languages (see Table 2) and its adoption for other NMT (Liu et al., 2021) and post-editing (Fomicheva et al., 2020) studies. Although mBART-50 performances are usually comparable or slightly worse than the ones of tested bilingual NMT models, $^{7}$ using a multilingual model allows us to evaluate the downstream effectiveness of a single, unified system trained on pairs evenly distributed across tested languages. Finally, adopting two systems with marked differences in automatic evaluation scores allows us to estimate how a significant increase in metrics such as BLEU, CHRF and COMET (Papineni et al., 2002; Popovic, 2015;
+
+Evaluation performed in October 2021.
+$^{6}$ facebook/mbart-large-50-one-to-many
+See Appendix E for automatic MT quality results by five different models over a larger set of 10 target languages.
+
+| ENG | SRC | Inland waterways can be a good theme to base a holiday around. | |
| ARA | HT | JgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJ gJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJ | JgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJg |
| MT | JgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJg JgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJg J | |
| PE | JgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJg) | |
| NLD | HT | Binnenlandse waterwegen+kunnen een goed themesa+zijn voor een vakantie. | |
| MT | Binnenwaterwegen+kunnen een goed themesa+zijn om een vakantie rond te zetten. | |
| PE | Binnenwaterwegen+kunnen een goed themesa+zijn om een vakantie rond te organiseren. | |
| ITA | HT | I corsi d'acqua dell'entroterra possono essere un ottimo punto di partenza da cui organizzare una vacanza. | |
| MT | I corsi d'acqua interni possono essere un buon tema per fondare una vacanza. | |
| PE | I corsi d'acqua interni possono essere un buon tema su cui basare una vacanza. | |
| TUR | HT | Ic bølgelerdeki su yollari, tatil plani:iin iyi bir tema olabilir. | |
| MT | Ic suyollari, tatil iin uygun bir tema olabilir. | |
| PE | Ic sular tati l'in uygun bir tema olabilir. | |
| UKR | HT | Mozkna cIIJIaHyBaTI BHXiINi, B3YbIIHn 3a ochOBv IIOIOPOK BNYTpriINHM BOIDHMNI IIIJXAMN. | |
| MT | BoDHI IIJIaXH MOKyTb 6yTN XOPONM o6 'EKTOM IJIa 6a3yBaHNH BIDIIOUHNKu HABKOJIo. | |
| PE | MicIeBiCtB HABKOJIo BNYTpriINIX BODHNX IIIJXIB MoJKe 6yTN IapHIM BIV6Opom DJIa | |
| opraHIZaII BIVIOUnHKy. | |
| VIE | HT | Du lich trén song co thé là môt l'au chon phù hop cho k'y nhi. | |
| MT | Các tuyén nuóc nài dja có thé là môt chu dé tôt dé xay dung不好意思 k'ghi. | |
| PE | Du lich bang duong thuy nài dja là môt y tuǒng nghi duōng khòng tòi. | |
+
+Table 3: A DivEMT corpus entry, including the English source (SRC), its translation from scratch (HT), the MT output of mBART-50 (MT) and its post-edited version (PE) for all languages. We highlight insertions, deletions, substitutions and shifts computed with Tercom (Snover et al., 2006). Full examples available in Appendix F.
+
+Rei et al., 2020) impacts downstream productivity across languages in a realistic post-editing scenario.
+
+# 3.5 Translation Platform and Collected Data
+
+Translators were asked to use PET (Aziz et al., 2012), a computer-assisted translation tool that supports both translating from scratch and post-editing. This tool was chosen because (i) it logs information about the post-editing process, which we use to assess effort (see Section 4); and (ii) it is a mature research-oriented tool that has been successfully used in several previous studies (Koponen et al., 2012; Toral et al., 2018). The minimalistic nature of PET interface and functionalities limits its application in commercial translation activities, making it generally unfamiliar for professional translators. We consider this aspect an advantage in light of our controlled setup since it allows us to avoid additional confounding effects or disparities stemming from tools-specific capabilities and different degrees of proficiency with the software. We also observe that, due to the varied and generic nature of the selected documents, functionalities such as concordance and translation memory matches would
+
+have proven much less useful in our setup. We collect three types of data:
+
+- Resulting translations produced by translators in either HT or PE modes, constituting a multilingual corpus with one source text and 18 translations (one per language-modality combination) exemplified in Table 3.
+- Behavioral data for translated sentences, including editing time, amount and type of keystrokes (content, navigation, erase, etc.), and number and duration of pauses above 300/1000 milliseconds (Lacruz et al., 2014).
+- Pre- and post-task questionnaire. The former focuses on demographics, education, and work experience with translation and post-editing. The latter elicits subjective assessments of post-editing quality, effort and enjoyability compared to translating from scratch.
+
+# 4 Post-Editing Effort Across Languages
+
+In this section, we use the DivEMT dataset to quantify the post-editing effort of professional translators across our diverse set of target languages.
+
+
+Figure 2: Temporal effort across languages and translation modalities, measured in seconds per processed source word. Each point represents a document, with higher scores denoting slower editing. $\uparrow$ : amount of data points per language not shown in the plot.
+
+We consider two main objective indicators of editing effort, namely temporal measurements (and related productivity gains) and post-editing rates, measured by the Human-targeted Translation Edit Rate (HTER, Snover et al. 2006). Finally, we assess the subjective perception of PE gains by examining the post-task questionnaires. We reiterate that all scores in this section are computed on the same set of source sentences for all languages, resulting in a faithful cross-lingual comparison of post-editing effort thanks to DivEMT's controlled setup.
+
+# 4.1 Temporal Effort and Productivity Gains
+
+We start by comparing task time (seconds per processed source word) across languages and modalities. For this purpose, edit times are computed for every document in every language without considering the presence of multiple translators for every language. As shown in Figure 2, translation time varies considerably across languages even when no MT system is involved (HT), suggesting an intrinsic variability in translation complexity for different subjects and language pairs. Indeed, for the HT modality, the time required for the 'slowest' target languages (Italian, Ukrainian) is roughly double the 'fastest' one (Turkish). This pattern cannot be easily explained and contrasts with factors commonly tied to MT complexity, such as source-target morphological richness and language relatedness (Birch et al., 2008; Belinkov et al., 2017). On the other hand, we find the relation $\mathrm{PE}_1 > \mathrm{PE}_2 > \mathrm{HT}$ ( $\mathrm{PE}_1$ fastest, $\mathrm{PE}_2$ medium speed, HT slowest) to hold for all the evaluated languages.
+
+ | PROD ↑ | ΔHT ↑ |
| HT | PE1 | PE2 | PE1 | PE2 |
| ARA | 13.1 | 21.7 | 16.3 | +84% | +10% |
| NLD | 13.6 | 28.7 | 21.7 | +119% | +61% |
| ITA | 8.8 | 18.6 | 15.6 | +96% | +95% |
| TUR | 17.9 | 25.5 | 21.0 | +34% | +12% |
| UKR | 8.0 | 12.3 | 9.8 | +71% | +14% |
| VIE | 10.2 | 13.0 | 11.1 | +32% | +23% |
+
+Table 4: Median productivity (PROD, # processed source words per minute) and median % post-editing speedup ( $\Delta$ HT) for all analyzed languages and modalities. Arrows denote the direction of improvement.
+
+For a measure of productivity gains that is easier to interpret and more in line with translation industry practices, we turn to productivity expressed in source words processed per minute and compute the speed-up induced by the two post-editing modalities over translating from scratch ( $\Delta$ HT). Table 4 presents our results. Across systems, we find that large differences among automatic MT quality metrics indeed reflect on post-editing effort, suggesting a nuanced picture that is complementary to the findings of Zouhar et al. (2021). While post-editing time gains were observed to quickly saturate for slight changes in high-quality MT, we find that moving from medium-quality to high-quality MT yields meaningful productivity improvements across most evaluated languages. Across languages, too, the magnitude of productivity gains ranges widely, from doubling in some languages (Dutch $\mathrm{PE}_1$ , Italian $\mathrm{PE}_1$ and $\mathrm{PE}_2$ ) to only about $10\%$ (Arabic, Turkish and Ukrainian $\mathrm{PE}_2$ ). When only considering the better performing system ( $\mathrm{PE}_1$ ), post-editing remains clearly beneficial in all languages despite the high variability in $\Delta$ HT scores. Results are more nuanced for the open-source system ( $\mathrm{PE}_2$ ), with three out of six languages displaying only marginal gains ( $<15\%$ in Arabic, Turkish and Ukrainian). Despite its overall lower performance, mBART-50 ( $\mathrm{PE}_2$ ) is the only system enabling a fair comparison across languages (from the point of view of training data size and architecture, see Section 3.4). Interestingly, if we focus on the gains induced by this system, factors like language relatedness and morphological complexity become relevant. Specifically, Italian ( $+95\%$ ), Dutch ( $+61\%$ ) and Ukrainian ( $+14\%$ ) are genetically and syntactically related to English, but Ukrainian has a richer morphology (see Table 1). On the other hand, Vietnamese ( $+23\%$ ), Turkish
+
+$(+12\%)$ and Arabic $(+10\%)$ all belong to different families. However, Vietnamese is isolating (little to no morphology), while Turkish and Arabic have very rich morphological systems (resp. agglutinative and introflexive, the latter of which is especially problematic for subword segmentation, Amrhein and Sennrich 2021). Other differences are however harder to explain. For instance, Dutch is closely related to English and has a simpler morphology than Italian, but its productivity gain with mBART-50 is lower $(61\%$ vs $95\%)$ . This finding is accompanied by an important gap in BLEU and COMET scores achieved by mBART-50 on the two languages (22.6 vs 24.4 BLEU and 0.532 vs 0.648 COMET for Dutch vs Italian, resp.) which cannot be explained by training data size.
+
+In summary, our findings confirm the overall positive impact of NMT post-editing on translation productivity observed in previous PE studies. However, we note how the magnitude of this impact is highly variable across systems and languages, with inter-subject variability also playing an important role, in line with previous studies (Koponen et al., 2020) (see Section 6 for more details). The small size of our language sample does not allow us to draw direct causal links between specific typological properties and post-editing efficiency. That said, we believe these results have important implications on the claimed 'universality' of current state-of-the-art MT and NLP systems, mostly based on the Transformer architecture (Vaswani et al., 2017) and BPE-style subword segmentation techniques (Sennrich et al., 2016).
+
+# 4.1.1 Modeling Temporal Effort
+
+Given the high variability among translators, segments and translation modalities, we assess the validity of our observations via statistical analysis of temporal effort using a linear mixed-effects regression model (LMER, Lindstrom and Bates 1988), following Green et al. (2013) and Toral et al. (2018). We fit our model on $n = 7434$ instances, corresponding to 413 sentences translated by 18 translators8, using translation time as the dependent variable. Our fixed predictors include translation modality, target language, their interaction and length of source segment in characters.9 Our random effects structure includes random intercepts
+
+| Predictor | Estim. | p-value | Sig. |
| (Intercept) | 4.92 | 1.12e-11 | *** |
| source length | 0.38 | < 2e-16 | *** |
| lang_ara | -0.49 | 0.1209 | |
| lang_ita | -0.14 | 0.6407 | |
| lang_nld | -0.58 | 0.0733 | x |
| lang_tur | -0.82 | 0.0162 | * |
| lang_vie | -0.24 | 0.4254 | |
| task_pe1 | -0.49 | < 2e-16 | *** |
| task_pe2 | -0.22 | 1.77e-07 | *** |
| lang_ara:task_pe1 | -0.11 | 0.0505 | x |
| lang_ita:task_pe1 | -0.40 | 8.97e-12 | *** |
| lang_nld:task_pe1 | -0.41 | 5.74e-12 | *** |
| lang_tur:task_pe1 | -0.14 | 0.0194 | * |
| lang_vie:task_pe1 | 0.13 | 0.0290 | * |
| lang_ara:task_pe2 | 0.05 | 0.3535 | |
| lang_ita:task_pe2 | -0.39 | 3.30e-11 | *** |
| lang_nld:task_pe2 | -0.29 | 4.46e-07 | *** |
| lang_tur:task_pe2 | 0.03 | 0.5811 | |
| lang_vie:task_pe2 | 0.04 | 0.5289 | |
+
+Table 5: LMER modeling results using translation time as the dependent variable. The reference levels for predictors lang and task are Ukrainian and Translation from scratch (HT), respectively. Estimate impact on edit time for every predictor is provided in log seconds. Significance: $* * * = < 0.001$ , $^* = < 0.05$ , $x = < 0.1$
+
+for different segments (nested with documents) and translators, as well as a random slope for modality over individual segments. [10] Table 5 presents the set of predictors included in the final model, an estimate of their impact on edit times and their significance. We find both PE modalities to significantly reduce translation times ( $p < 0.001$ ), with $\mathrm{PE}_1$ being significantly faster than $\mathrm{PE}_2$ ( $p < 0.001$ ) across all languages. Taking the language for which HT is slowest (Ukrainian) as the reference level, the reduction in time brought by Google is significantly more pronounced for Italian, Dutch ( $p < 0.001$ ), and Turkish ( $p < 0.05$ ). For mBART-50, however, we only observe significantly more pronounced increases in productivity for Italian and Dutch ( $p < 0.001$ ) compared to the reference. We find these results to corroborate the observations of the previous section.
+
+# 4.2 Post-Editing Rate
+
+We proceed to study the post-editing patterns using the widely-adopted Human-targeted Translation Edit Rate (HTER, Snover et al. 2006), computed as the length-normalized sum of word-level substitutions, insertions, deletions and shift operations
+
+
+Figure 3: Human-targeted Translation Edit Rate (HTER) for Google Translate and mBART-50 post-editing across available languages.
+
+
+Figure 4: Distribution of error-less machine translation sentence outputs (no edits performed during post-editing) for each translator and every language.
+
+performed during post-editing.11
+
+As shown in Figure 3, $\mathrm{PE}_1$ required less editing than $\mathrm{PE}_2$ for all languages, and a high variability is observed across the two systems and all languages. Since translators were not informed about the presence of two MT systems, we exclude the possibility that these results reflect an overreliance or distrust towards a specific MT system. For Google Translate, Ukrainian shows the heaviest edit rate, followed by Vietnamese, whereas Arabic, Dutch, Italian and Turkish all show relatively low amounts of edits. Focusing again on mBART-50 for a fairer cross-lingual comparison, Ukrainian is by far the most heavily edited language, followed by a medium-tier group composed of Vietnamese, Arabic and Turkish, and finally by Dutch and Italian as low-edit languages. Results show that several of our observations on the linguistic relatedness and type of morphology also apply to edit rates, with
+
+
+Figure 5: Perceived productivity gains (PPG) between the HT and PE translation modalities, assessed for all subjects after task completion.
+
+languages less related to English or having richer morphology requiring more post-edits on average.
+
+Figure 4 visualizes the large gap in edit rates across languages and subjects by presenting the amount of "errorless" MT sentences that were accepted directly, i.e. without any post-editing. We note again how the NMT system heavily influences the rate of occurrence of such sentences but nonetheless shows how Dutch and Italian generally present more errorless sentences than Ukrainian and Vietnamese. In particular, for Google Translate outputs, the average rate of error-less sentences is roughly $25\%$ for the former target languages, while for the latter, it accounts only for the $3\%$ of total translations. Surprisingly, the English-Turkish pair also fares well, despite the low source-target relatedness.
+
+Finally, we note that post-editing effort appears to correlate poorly with the automatic MT quality metrics reported in Table 2 (e.g. see high scores of Vietnamese and low scores of Dutch $\mathrm{PE}_1$ ), highlighting a difficulty in predicting the benefits of MT post-editing over HT for new language pairs.
+
+# 4.3 Perception of Productivity Gain
+
+We conclude our analysis by examining the posttask questionnaires, in which participants expressed their perception of MT quality and translation speed across HT and PE modalities $\mathrm{(HT_s,}$ $\mathrm{PE}_s)^{12}$ using a 1-7 Likert scale (1 slowest, 7 fastest). We use these to compute the Perceived Productivity Gain (PPG) as PPG $= \mathrm{PE}_s - \mathrm{HT}_s$ and visualize it in Figure 5. We observe that Italian and Dutch, the only target languages with marked productivity gains $(\Delta \mathrm{HT})$ regardless of the PE system in Table 4, are also the only ones having consistently high $(\geq 2)$ PPG scores across all subjects. Moreover, we remark how PPG for target languages
+
+with a large gap in $\Delta \mathrm{HT}$ scores between high $\mathrm{PE}_1$ and low- $\mathrm{PE}_2$ (Arabic, Ukrainian) are hardly distinguishable from those of languages in which $\Delta \mathrm{HT}$ is low for both PE systems (Turkish, Vietnamese). Notably, 4 out of 18 subjects attribute negative PPGs to the PE modality, even though productivity gains were reported across all subjects and languages. These results suggest that worst-case usage scenarios may play an important role in driving PPG, i.e. that subjects' perception of quality is largely shaped by particularly challenging or unsatisfying interactions with the NMT system, rather than the average case. Finally, from the post-task questionnaire, PPG scores exhibit a strong positive correlation with the perception of MT adequacy $(\rho = 0.66)$ , fluency $(\rho = 0.46)$ and overall quality $(\rho = 0.69)$ , and more generally with a higher enjoyability of PE $(\rho = 0.60)$ , while being inversely correlated with the perception of problematic mistranslations $(\rho = -0.60)$ .
+
+# 5 Conclusions
+
+In this work we introduced DivEMT, the outcome of a post-editing study spanning two state-of-the-art NMT systems, 18 professional translators and six typologically diverse target languages under a unified setup.
+
+We leveraged DivEMT's behavioral data to perform a controlled cross-language analysis of NMT post-editing effort along its temporal and editing effort dimensions. The analysis reveals that NMT drives significant improvements in productivity across all the evaluated languages, but the magnitude of these improvements depends heavily on the language and the underlying NMT system. In this setting, productivity measurements across modalities were found to be generally consistent with the recorded editing patterns. Our results indicate that translators working on language pairs with significant post-editing productivity gains, on average, perform fewer edits and accept more machine-generated translations without any editing. We also observed a disconnect between post-editing productivity gains and MT quality metrics collected for the same NMT systems. Finally, low source-language relatedness and target morphological complexity seem to hinder productivity when NMT is adopted, even in settings where system architecture and training data are controlled for.
+
+In our qualitative analysis, translators' perception of post-editing usefulness was found to be
+
+strongly shaped by problematic mistranslations. Languages showing large productivity gains for both NMT systems were the only ones associated with a positive perception of PE-mediated gains, as opposed to mixed or negative opinions for other translation directions.
+
+In future work, a more fine-grained analysis of the types of edits conducted by the translators, and their differences across languages, could shed more light on our current findings.
+
+# 6 Limitations
+
+The subjective component introduced by the presence of multiple translators is an important confounding factor in our setup, especially due to the relatively small number of subjects for each language. In our study, we tried to balance a thorough control of other noise components with a faithful reproduction of a realistic translation scenario. However, we realize that the combination of limited document context provided by FLORES-101, the variety of topics covered in the texts and the experimental nature of the PET platform constitutes an atypical setting that may have impacted the translators' natural productivity. Moreover, variability in the content of mBART-50 fine-tuning data, despite the comparable sizes, may have played a role in the variability observed for automatic MT evaluation and PE gains across languages.
+
+# 7 Broader Impact and Ethical Considerations
+
+This line of research aims at providing a more precise and faceted understanding of translation and editing effort across multiple languages, and as such is worth pursuing to ensure a fairer compensation to translators if compared to one-size-fits-all approaches based on automatic quality metrics. Furthermore, the understanding of the application of MT to translators' work in less researched languages and the diversity of measures obtained can give a clearer picture of MT usability, in its broader sense, than automatic metrics. It is relevant to test NMT models in controlled translation environments. In our experiment, Language Service Providers were paid their requested rate. All words were paid as new words, as the MT usability was unknown prior to the experiment. They were also given thorough instructions and ample time to complete the assignment, accommodating for the COVID-19 pandemic that affected some of the
+
+participants. Translators were informed that they could opt-out at any time and have their information deleted.
+
+# Acknowledgements
+
+Data collection was fully funded by the Dutch Research Council (NWO) under project number 639.021.646. GS is supported by the NWO project InDeep (NWA.1292.19.399). AGA was supported by the European Union's Horizon 2020 research and innovation program under the Marie Skłodowska-Curie grant agreement No. 890697. We thank the Center for Information Technology of the University of Groningen for providing access to the Peregrine HPC cluster.
+
+# References
+
+Arafat Ahsan, Vandan Mujadia, and Dipti Misra Sharma. 2021. Assessing post-editing effort in the English-Hindi direction. In Proceedings of the 18th International Conference on Natural Language Processing (ICON), National Institute of Technology Silchar, Silchar, India. NLP Association of India (NLPAI).
+Farhad Akhbardeh, Arkady Arkhangorodsky, Magdalena Biesialska, Ondrej Bojar, Rajen Chatterjee, Vishrav Chaudhary, Marta R. Costa-jussa, Cristina España-Bonet, Angela Fan, Christian Federmann, Markus Freitag, Yvette Graham, Roman Grundkiewicz, Barry Haddow, Leonie Harter, Kenneth Heafield, Christopher Homan, Matthias Huck, Kwabena Amponsah-Kaakyire, Jungo Kasi, Daniel Khashabi, Kevin Knight, Tom Kocmi, Philipp Koehn, Nicholas Lourie, Christof Monz, Makoto Morishita, Masaaki Nagata, Ajay Nagesh, Toshiaki Nakazawa, Matteo Negri, Santanu Pal, Alahsera Auguste Tapo, Marco Turchi, Valentin Vydrin, and Marcos Zampieri. 2021. Findings of the 2021 conference on machine translation (WMT21). In Proceedings of the Sixth Conference on Machine Translation, pages 1-88, Online. Association for Computational Linguistics.
+Chantal Amrhein and Rico Sennrich. 2021. How suitable are subword segmentation strategies for translating non-concatenative morphology? In *Findings of the Association for Computational Linguistics: EMNLP* 2021, pages 689-705, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Wilker Aziz, Sheila Castilho, and Lucia Specia. 2012. PET: a tool for post-editing and assessing machine translation. In Proceedings of the Eighth International Conference on Language Resources and Evaluation (LREC'12), pages 3982-3987, Istanbul, Turkey. European Language Resources Association (ELRA).
+
+Loic Barrault, Ondrej Bojar, Fethi Bouguares, Rajen Chatterjee, Marta R. Costa-jussa, Christian Federmann, Mark Fishel, Alexander Fraser, Markus Freitag, Yvette Graham, Roman Grundkiewicz, Paco Guzman, Barry Haddow, Matthias Huck, Antonio Jimeno Yepes, Philipp Koehn, Tom Kocmi, Andre Martins, Makoto Morishita, and Christof Monz, editors. 2021. Proceedings of the Sixth Conference on Machine Translation. Association for Computational Linguistics, Online.
+Yonatan Belinkov, Nadir Durrani, Fahim Dalvi, Hassan Sajjad, and James Glass. 2017. What do neural machine translation models learn about morphology? In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 861-872, Vancouver, Canada. Association for Computational Linguistics.
+Luisa Bentivogli, Arianna Bisazza, Mauro Cettolo, and Marcello Federico. 2016. Neural versus phrase-based machine translation quality: a case study. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 257-267, Austin, Texas. Association for Computational Linguistics.
+Alexandra Birch, Miles Osborne, and Philipp Koehn. 2008. Predicting success in machine translation. In Proceedings of the 2008 Conference on Empirical Methods in Natural Language Processing, pages 745-754, Honolulu, Hawaii. Association for Computational Linguistics.
+Arianna Bisazza, Ahmet Üstün, and Stephan Sportel. 2021. On the difficulty of translating free-order casemarking languages. Transactions of the Association for Computational Linguistics, 9:1233-1248.
+Ondrej Bojar, Christian Buck, Chris Callison-Burch, Christian Federmann, Barry Haddow, Philipp Koehn, Christof Monz, Matt Post, Radu Soricut, and Lucia Specia. 2013. Findings of the 2013 Workshop on Statistical Machine Translation. In Proceedings of the Eighth Workshop on Statistical Machine Translation, pages 1-44, Sofia, Bulgaria. Association for Computational Linguistics.
+Emanuele Bugliarello, Sabrina J. Mielke, Antonios Anastasopoulos, Ryan Cotterell, and Naoaki Okazaki. 2020. It's easier to translate out of English than into it: Measuring neural translation difficulty by cross-mutual information. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 1640-1649, Online. Association for Computational Linguistics.
+Sheila Castilho, Joss Moorkens, Federico Gaspari, Iacer Calixto, John Tinsley, and Andy Way. 2017. Is Neural Machine Translation the New State of the Art? The Prague Bulletin of Mathematical Linguistics, 108(1):109-120. Publisher: Sciendo Section: The Prague Bulletin of Mathematical Linguistics.
+Mauro Cettolo, Marcello Federico, Luisa Bentivogli, Jan Niehues, Sebastian Stüker, Katsuhito Sudoh,
+
+Koichiro Yoshino, and Christian Federmann. 2017. Overview of the IWSLT 2017 evaluation campaign. In Proceedings of the 14th International Conference on Spoken Language Translation, pages 2-14, Tokyo, Japan. International Workshop on Spoken Language Translation.
+Mauro Cettolo, Jan Niehues, Sebastian Stüker, Luisa Bentivogli, Rolando Cattoni, and Marcello Federico. 2016. The IWSLT 2016 evaluation campaign. In Proceedings of the 13th International Conference on Spoken Language Translation, Seattle, Washington D.C. International Workshop on Spoken Language Translation.
+Ryan Cotterell, Sabrina J. Mielke, Jason Eisner, and Brian Roark. 2018. Are all languages equally hard to language-model? In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 536-541, New Orleans, Louisiana. Association for Computational Linguistics.
+Joke Daems, Sonia Vandepitte, Robert Hartsuiker, and Lieve Macken. 2017. Translation Methods and Experience: A Comparative Analysis of Human Translation and Post-editing with Students and Professional Translators. *Meta: journal des traducteurs / Meta: Translators' Journal*, 62(2):245-270. Publisher: Les Presses de l'Université de Montréal.
+Angela Fan, Shruti Bhosale, Holger Schwenk, Zhiyi Ma, Ahmed El-Kishky, Siddharth Goyal, Mandep Baines, Onur Celebi, Guillaume Wenzek, Vishrav Chaudhary, Naman Goyal, Tom Birch, Vitaliy Liptchinsky, Sergey Edunov, Edouard Grave, Michael Auli, and Armand Joulin. 2021. Beyond english-centric multilingual machine translation. Journal of Machine Learning Research, 22(107):1-48.
+Marina Fomicheva, Shuo Sun, Erick Rocha Fonseca, F. Blain, Vishrav Chaudhary, Francisco Guzmán, Nina Lopatina, Lucia Specia, and André F. T. Martins. 2020. MLQE-PE: A multilingual quality estimation and post-editing dataset. ArXiv, abs/2010.04480.
+Markus Freitag, George Foster, David Grangier, Viresh Ratnakar, Qijun Tan, and Wolfgang Macherey. 2021. Experts, errors, and context: A large-scale study of human evaluation for machine translation. Transactions of the Association for Computational Linguistics, 9:1460-1474.
+Daniela Gerz, Ivan Vulic, Edoardo Maria Ponti, Roi Reichart, and Anna Korhonen. 2018. On the relation between linguistic typology and (limitations of) multilingual language modeling. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 316-327, Brussels, Belgium. Association for Computational Linguistics.
+
+Naman Goyal, Cynthia Gao, Vishrav Chaudhary, Peng-Jen Chen, Guillaume Wenzek, Da Ju, Sanjana Krishnan, Marc'Aurelio Ranzato, Francisco Guzmán, and Angela Fan. 2022. The Flores-101 Evaluation Benchmark for Low-Resource and Multilingual Machine Translation. Transactions of the Association for Computational Linguistics, 10:522-538.
+Spence Green, Jeffrey Heer, and Christopher D. Manning. 2013. The efficacy of human post-editing for language translation. In Proceedings of the SIGCHI Conference on Human Factors in Computing Systems, CHI '13, pages 439-448, New York, NY, USA. Association for Computing Machinery.
+Ana Guerberof. 2009. Productivity and quality in MT post-editing. In Beyond Translation Memories: New Tools for Translators Workshop, Ottawa, Canada.
+Philipp Koehn. 2005. Europarl: A parallel corpus for statistical machine translation. In Proceedings of Machine Translation Summit X: Papers, pages 79-86, Phuket, Thailand.
+Philipp Koehn and Christof Monz, editors. 2006. Proceedings on the Workshop on Statistical Machine Translation. Association for Computational Linguistics, New York City.
+Maarit Koponen, Wilker Aziz, Luciana Ramos, and Lucia Specia. 2012. Post-editing time as a measure of cognitive effort. In Workshop on Post-Editing Technology and Practice.
+Maarit Koponen, Umut Sulubacak, Kaisa Vitikainen, and Jörg Tiedemann. 2020. MT for subtitling: User evaluation of post-editing productivity. In Proceedings of the 22nd Annual Conference of the European Association for Machine Translation, pages 115-124, Lisboa, Portugal. European Association for Machine Translation.
+Hans P. Krings. 2001. Repairing Texts: Empirical Investigations of Machine Translation Post-editing Processes. Kent State University Press. Google-Books-ID: vsdPsIXCiWAC.
+Isabel Lacruz, Michael Denkowski, and Alon Lavie. 2014. Cognitive demand and cognitive effort in postediting. In Proceedings of the 11th Conference of the Association for Machine Translation in the Americas, pages 73-84, Vancouver, Canada. Association for Machine Translation in the Americas.
+Samuel Läubli, Chantal Amrhein, Patrick Duggelin, Beatrix Gonzalez, Alena Zwahlen, and Martin Volk. 2019. Post-editing productivity with neural machine translation: An empirical assessment of speed and quality in the banking and finance domain. In Proceedings of Machine Translation Summit XVII: Research Track, pages 267-272, Dublin, Ireland. European Association for Machine Translation.
+
+Samuel Läubli, Mark Fishel, Gary Massey, Maureen Ehrensberger-Dow, and Martin Volk. 2013. Assessing post-editing efficiency in a realistic translation environment. In Proceedings of the 2nd Workshop on Post-editing Technology and Practice, Nice, France.
+Daniel Licht, Cynthia Gao, Janice Lam, Francisco Guzman, Mona Diab, and Philipp Koehn. 2022. Consistent human evaluation of machine translation across language pairs. *ArXiv*, abs/2205.08533.
+Yu-Hsiang Lin, Chian-Yu Chen, Jean Lee, Zirui Li, Yuyan Zhang, Mengzhou Xia, Shruti Rijhwani, Junxian He, Zhisong Zhang, Xuezhe Ma, Antonios Anastasopoulos, Patrick Littell, and Graham Neubig. 2019. Choosing transfer languages for cross-lingual learning. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3125-3135, Florence, Italy. Association for Computational Linguistics.
+Mary J. Lindstrom and Douglas M. Bates. 1988. Newton—raphson and em algorithms for linear mixed-effects models for repeated-measures data. Journal of the American Statistical Association, 83(404):1014-1022.
+Yinhan Liu, Jiatao Gu, Naman Goyal, Xian Li, Sergey Edunov, Marjan Ghazvininejad, Mike Lewis, and Luke Zettlemoyer. 2020. Multilingual denoising pre-training for neural machine translation. Transactions of the Association for Computational Linguistics, 8:726-742.
+Zihan Liu, Genta Indra Winata, and Pascale Fung. 2021. Continual mixed-language pre-training for extremely low-resource neural machine translation. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 2706-2718, Online. Association for Computational Linguistics.
+Arl Lommel and Hélène Pielmeier. 2021. Machine Translation Use at LSPs: Insights on How Language Service Providers' Use of MT Is Evolving. Technical report, Common Sense Advisory Research.
+Thomas Mayer and Michael Cysouw. 2014. Creating a massively parallel Bible corpus. In Proceedings of the Ninth International Conference on Language Resources and Evaluation (LREC'14), pages 3158-3163, Reykjavik, Iceland. European Language Resources Association (ELRA).
+Sabrina J. Mielke, Ryan Cotterell, Kyle Gorman, Brian Roark, and Jason Eisner. 2019. What kind of language is hard to language-model? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4975-4989, Florence, Italy. Association for Computational Linguistics.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th Annual Meeting of the Association for Computational Linguistics, pages 311-318, Philadelphia,
+
+Pennsylvania, USA. Association for Computational Linguistics.
+Carla Parra Escartin and Manuel Arcedillo. 2015. Machine translation evaluation made fuzzier: a study on post-editing productivity and evaluation metrics in commercial settings. In Proceedings of Machine Translation Summit XV: Papers, Miami, USA.
+Mirko Plitt and François Masselot. 2010. A Productivity Test of Statistical Machine Translation Post-Editing in a Typical Localisation Context. The Prague Bulletin of Mathematical Linguistics, 93(1).
+Maja Popovic. 2015. chrF: character n-gram F-score for automatic MT evaluation. In Proceedings of the Tenth Workshop on Statistical Machine Translation, pages 392–395, Lisbon, Portugal. Association for Computational Linguistics.
+Matt Post. 2018. A call for clarity in reporting BLEU scores. In Proceedings of the Third Conference on Machine Translation: Research Papers, pages 186-191, Brussels, Belgium. Association for Computational Linguistics.
+Ricardo Rei, Craig Stewart, Ana C Farinha, and Alon Lavie. 2020. COMET: A neural framework for MT evaluation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2685-2702, Online. Association for Computational Linguistics.
+Rico Sennrich, Barry Haddow, and Alexandra Birch. 2016. Neural machine translation of rare words with subword units. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1715-1725, Berlin, Germany. Association for Computational Linguistics.
+Matthew Snover, Bonnie Dorr, Rich Schwartz, Linnea Micciulla, and John Makhoul. 2006. A study of translation edit rate with targeted human annotation. In Proceedings of the 7th Conference of the Association for Machine Translation in the Americas: Technical Papers, pages 223-231, Cambridge, Massachusetts, USA. Association for Machine Translation in the Americas.
+Maria Stasimioti and Vilemini Sosoni. 2020. Translation vs post-editing of NMT output: Insights from the English-Greek language pair. In Proceedings of 1st Workshop on Post-Editing in Modern-Day Translation, pages 109–124, Virtual. Association for Machine Translation in the Americas.
+Yuqing Tang, Chau Tran, Xian Li, Peng-Jen Chen, Naman Goyal, Vishrav Chaudhary, Jiatao Gu, and Angela Fan. 2021. Multilingual translation from de-noising pre-training. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 3450-3466, Online. Association for Computational Linguistics.
+
+Jörg Tiedemann and Santhosh Thottingal. 2020. OPUS-MT - building open translation services for the world. In Proceedings of the 22nd Annual Conference of the European Association for Machine Translation, pages 479-480, Lisboa, Portugal. European Association for Machine Translation.
+Antonio Toral, Martijn Wieling, and Andy Way. 2018. Post-editing Effort of a Novel With Statistical and Neural Machine Translation. Frontiers in Digital Humanities, 5:1-11. Publisher: Frontiers.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc.
+Weiyue Wang, Jan-Thorsten Peter, Hendrik Rosendahl, and Hermann Ney. 2016. CharacTer: Translation edit rate on character level. In Proceedings of the First Conference on Machine Translation: Volume 2, Shared Task Papers, pages 505-510, Berlin, Germany. Association for Computational Linguistics.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+Aris Xanthos, Sabine Laaha, Steven Gillis, Ursula Stephany, Ayhan Aksu-Koc, Anastasia Christofidou, Natalia Gagarina, Gordana Hrzica, F. Nihan Ketrez, Marianne Kilani-Schoch, Katharina Korecky-Kroll, Melita Kovačević, Klaus Laalo, Marijan Palmović, Barbara Pfeiler, Maria D. Voeikova, and Wolfgang U. Dressler. 2011. On the role of morphological richness in the early development of noun and verb inflection. First Language, 31(4):461-479.
+Vilém Zouhar, Martin Popel, Ondrej Bojar, and Ales Tamchyna. 2021. Neural machine translation quality and post-editing performance. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 10204-10214, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Çağrı Çoltekin and Taraka Rama. 2022. What do complexity measures measure? correlating and validating corpus-based measures of morphological complexity. ArXiv, abs/2204.05056.
+
+# A Modality scheduling
+
+Table 6 shows an example of the adopted modality scheduling. The modality of document $\mathrm{docM}_i$ for translator $T_j$ in the main task is picked randomly among the two modalities that were not seen by the same translator for $\mathrm{docM}_{i-1}$ , enforcing consecutive documents given to the same translator to be assigned different modalities to avoid periodicity in repetition and enable the same-language comparisons of Section 4. Importantly, although all three modes were collected for every document, we did not enforce mode consistency across the same translator identifier across languages (i.e. $T_1$ for Italian does not have the same sequence of modalities of translator $T_1$ in Arabic, for example). For this reason, individual subjects are not directly comparable across languages. This is relevant since, e.g. $T_3$ for Dutch and Italian did not operate on the same set of sentences on the same modalities, and thus their comparable editing behavior in Figure 4 should be attributed to personal preference rather than an identical assignment of modalities on the same sentences. Despite modality scheduling, we have no guarantees that translators consistently follow the order of documents presented in PET, and thus possibly operate on documents assigned to the same modality consecutively. However, this possibility reduces to random guessing due to a lack of any identifying information related to the modality until the document is entered for editing. The sequence of modalities for the warmup task is fixed and is: HT, $\mathrm{PE}_2$ , $\mathrm{PE}_1$ , HT, $\mathrm{PE}_2$ .
+
+# B Subject Information
+
+During the setup of our experiment, one translator refused to carry out the main task after the warmup phase, and another was substituted by our choice. Both translators were working in the English-Italian direction and were found to make heavy usage of copy-pasting during the warmup stage, suggesting an incorrect utilization of the platform in light of our guidelines. Both translators, which we identified as $\mathrm{T}_{2}$ and $\mathrm{T}_{3}$ for Italian, were replaced by $\mathrm{T}_{5}$ and $\mathrm{T}_{4}$ respectively. Table 7 reflects the final translation selection for all languages, with the information collected by means of the pre-task questionnaire.
+
+# C Translation Guidelines
+
+An extract of the translation guidelines provided to the translators follows. The full guidelines are
+
+ | | T1 | T2 | T3 |
| warm-up | docW1 | HT | HT | HT |
| docW2 | PE1 | PE1 | PE1 |
| ... | PE2 | PE2 | PE2 |
| docWN | HT | PE1 | PE2 |
| main | docM1 | PE2 | HT | PE1 |
| docM2 | HT | PE2 | PE1 |
| docM3 | HT | PE1 | HT |
| ... | PE2 | PE1 | HT |
| docMN | PE2 | PE1 | HT |
+
+Table 6: Modality scheduling overview. For each language, each subject $(\mathrm{T}_i)$ works with a pseudo-random sequence of modalities (HT, $\mathrm{PE}_1$ , $\mathrm{PE}_2$ ). For the warm-up task $(N = 5)$ , all translators are provided with the same documents in the same modalities. For the main task $(N = 107)$ , each translator is assigned a modality at random. Each document is translated once for every modality. The same procedure is repeated independently for all the languages.
+
+provided in the additional materials.
+
+Fill in the pre-task questionnaire before starting the project. In this experiment, your goal is to complete the translation of multiple files in one of two possible translation settings. Please, complete the tasks on your own, even if you know another translator that might be working on this project. The translation setting alternates between texts, with each text requiring a single translation in the assigned setting. The two translation settings are:
+
+1. Translation from scratch. Only the source sentence is provided, you are to write the translation from scratch.
+2. Post-editing. The source sentence is provided alongside a translation produced by an MT system. You are to post-edit this MT output. Post-edit the text so you are satisfied with the final translation (the required quality is publishable quality). If the MT output is too time-consuming to fix, you can delete it and start from scratch. However, please do not systematically delete the provided MT output to give your own translation.
+
+Important: All editing MUST happen in the provided PET interface: that is, working in other editors and copy-pasting the text back to PET is NOT ALLOWED, because it invalidates the experiment. This is easy to spot in the log data, so please avoid doing this. Complete the translation of all files sequentially, i.e. in the order presented in the tool. DO NOT SKIP files at your own convenience. Make sure that ALL files are translated when you deliver the tasks.
+
+The aim is to produce publishable professional quality translations for both translation settings. Thus, please translate to your best abilities. You can return to the files and self-review as many times as you think it is necessary. Important: The time invested to translate is recorded while the active unit (sentence) is in editing mode (yellow background). Therefore:
+
+- Only start to translate when you are in editing mode (yellow background). In other words, do not start thinking how you will translate a sentence when the active unit is not yet in editing mode (green or red background).
+- Do not leave a unit in editing mode (yellow background) while you do something else. If you need to do something unrelated in the middle of a translation then go out
+
+ | | Gender | Age | Degree | Position | En Level | YoE | YoE w/ PE | % PE |
| Arabic | T1 | M | 35-44 | BA | Freelancer | C2 | >15 | 2-5 | 20%-40% |
| T2 | M | 25-34 | BA | Employed | C2 | 5-10 | 2-5 | 60%-80% |
| T3 | M | 25-34 | MA | Freelancer | C1 | 5-10 | < 2 | 20%-40% |
| Dutch | T1 | M | 25-34 | MA | Freelancer | C2 | 5-10 | 5-10 | 60%-80% |
| T2 | F | 35-44 | MA | Freelancer | C1 | 10-15 | 5-10 | 40%-60% |
| T3 | F | 25-34 | MA | Freelancer | C2 | 2-5 | 2-5 | 20%-40% |
| Italian | T1 | F | 25-34 | MA | Employed | C1 | 5-10 | 5-10 | 20%-40% |
| T5 | F | 25-34 | MA | Freelancer | C1 | 2-5 | 2-5 | 40%-60% |
| T4 | F | 35-44 | BA | Freelancer | C2 | 10-15 | 5-10 | >80% |
| Turkish | T1 | F | 25-34 | BA | Freelancer | C2 | 5-10 | 2-5 | < 20% |
| T2 | F | 25-34 | BA | Freelancer | C1 | 5-10 | 5-10 | < 20% |
| T3 | M | 25-34 | High school | Freelancer | C2 | 10-15 | < 2 | < 20% |
| Ukrainian | T1 | F | 35-44 | MA | Employed | C1 | 5-10 | 5-10 | 20%-40% |
| T2 | M | 35-44 | MA | Employed | C1 | 10-15 | 10-15 | 20%-40% |
| T3 | M | 35-44 | High school | Employed | B2 | 2-5 | 2-5 | 20%-40% |
| Vietnamese | T1 | F | 25-34 | MA | Employed | C2 | 10-15 | 5-10 | 40%-60% |
| T2 | F | 25-34 | BA | Freelancer | C1 | 5-10 | < 2 | 20%-40% |
| T3 | F | 25-34 | MA | Employed | C1 | 2-5 | < 2 | < 20% |
+
+Table 7: Subjects information for DivEMT. The last three columns represent respectively the number of years of professional experience as a translator (YoE), the number of years of experience with MT post-editing (YoE w/ PE) and the % of work assignments requiring post-editing in the last 12 months (% PE) for each subject.
+
+| Type | WN | WV | WB | # Sent. | # Words |
| 3S | 11 | 13 | 11 | 105 | 2168 |
| 4S | 14 | 8 | 13 | 140 | 3214 |
| 5S | 12 | 13 | 12 | 185 | 3826 |
| Tot. | 37 | 34 | 36 | 450 | 9626 |
+
+Table 8: Distribution of the selected DivEMT documents across sizes and Wikipedia categories. A Type value of ${NS}$ stands for documents composed by $N$ contiguous sentences,WN,WV and WB stand respectively for WikiNews,WikiVoyage and Wikibooks
+
+of editing mode and come back to editing mode when you are ready to resume translating.
+
+- First you will be translating a warmup task, and then the main task. When you are translating each file, you can consult the Source text (ST) by looking up the url in the Excel files that we have sent for reference.
+
+In order to find the correct terminology for the translation you can consult any source in the Internet. Important: However, it is NOT ALLOWED to use any MT engine to find terms or alternatives to translations (such as Google Translate, DeepL, MS Translator or any MT engine available in your language). Using MT engines invalidates the experiment, and will be detected in the log data. Please fill-in the post-task questionnaire ONLY ONCE after completing all the translation tasks (both warmup and main tasks).
+
+# D Details on Document Selection and Preprocessing
+
+Document selection Table 8 present the distribution of selected documents from the Flores-101 devtest split based on their domain and the number
+
+of sentences that compose them. The first goal in the selection process was to preserve a rough balance between the three categories while including mostly 4 and 5-sentence docs which are faster to edit in PET (no need to frequently close and reopen an editing window). Another objective of the selection was to minimize the chance of translators finding the translated version of the Wikipedia article from which documents were taken and copied from there, despite our guidelines. We thus scrape the articles from Wikipedia and assess the number of available translations. Among the selected documents, only a small subset has translations in other languages (see Figure 6 top, an article can have multiple languages), mainly in Hebrew (14), Chinese (10), Spanish (7) and German (5) respectively. Considering the total number of translations for every article (Figure 6 bottom), we see that roughly $75\%$ of them (79 docs) have no translations. We consider this satisfactory as proof there should not be a large amount of possible copying involved, and we follow up on this evaluation by also ensuring that no repeated copy-paste patterns are present in keylogs after the warmup stage.
+
+Filtering of Outliers For our analysis of Section 4, we only use sentences with an editing time lower than 45 minutes, which was selected heuristically as a reasonably high threshold to allow for extensive searching and thinking. In the following,
+
+| Field name | Description |
| unit_id, flores_id, subject_id, task_type | Identifiers for the item, respective FLORES-101 sentence, translator and translation mode. |
| src_text | The original source sentence extracted from Wikinews, wikibooks or wikivoyage. |
| mt_text | MT output sentence before post-editing, present only if task_type is ‘pe’. |
| tgt_text | Final sentence produced by the translator (either from scratch or post-editing mt_text) |
| aligned_edit | Aligned visual representation of the machine translation and its post-edit with edit operations |
| edit_time | Total editing time for the translation in seconds. |
| k_letter, kdigit, k_white, k_symbol, k nav | Number of keystrokes for various key types (letters, digits, keystrokes, whitespaces, punctuation, navigation keys) during the translation. |
| k_erease, k_copy, k_paste, k_cut, k_do | Number of keystrokes for erase (backspace, cancel), copy, paste, cut and Enter actions during the translation. |
| k_total | Total number of all keystroke categories during the translation. |
| n Pause_geq_N, len Pause_geq_N | Number and length of pauses longer than 300ms and 1000ms during the translation. |
| numAnnotations | Number of times the translator focused the target sentence texbox during the session. |
| n_insert, n_delete, n Substitute, n_shift, totshifted_words, tot_edits, hter cer | Granular editing metrics and overall HTER computed using the Tercom library. |
| Character-level HTER score computed between the MT and post-edited outputs. |
| bleu, chrf | Sentence-level BLEU and ChrF scores between MT and post-edited fields computed using the SacreBLEU library with default parameters. |
| time_per_char, key_per_char, words_per_hour, words_per Minute | Edit time per source character, expressed in seconds. Proportion of keys per character needed to perform the translation. Amount of source words translated or post-edited per hour/minute |
| subject.visit_order | Id denoting the order in which the translator accessed documents in the interface. |
+
+Table 9: Description of the main fields associated to every DivEMT data entry. An entry corresponds to a translation in a specific modality (HT, $\mathrm{PE}_1$ or $\mathrm{PE}_2$ ) for one of the six target languages
+
+we present the identifiers of the sentences that were filtered out during this process. E.g. 54.1 means the first sentence of document 54, having item_id equal to flores101-main-541 in the dataset. Note that the sentences were outliers only for 2/6 languages and were all different, indicating no systematic issues in the sample: ARA: 54.1, 100.3, VIE: 3.1, 3.2, 24.3, 28.4, 33.1, 33.2, 40.3, 41.2, 50.3, 100.1, 102.1, 106.1, 107.2, 107.4. The 17 sentences were removed for all modalities and languages in the analysis of Section 4 to preserve the validity of our comparison, representing a loss of roughly $4\%$ of the total available data, a tolerable amount for our analysis.
+
+Fields Description Table 9 presents the set of fields that were collected for every entry of the DivEMT dataset. The fields related to keystrokes, times, pauses, annotations and visit order were extracted from the event log of PET .per files, while edits information and other MT quality metrics were computed in a second moment with the help of widely-used libraries.
+
+Additional Notes on PET The PET platform was modified to enable a correct right-to-left language visualization, which was necessary for Arabic.
+
+# E Other Measurements
+
+While HTER is a standard metric adopted both in academic and industrial settings, we also evaluated its character-level variant CharacTER (Wang et al., 2016) to assess whether it could better account for the editing process of morphologically rich languages. Figure 7 presents the CharacTER results. When comparing this plot to the HTER one (Figure 3), we notice that CharacTER preserves the overall trends, but slightly improves the edit rate for Arabic and Turkish with respect to other languages. Nevertheless, we find HTER to correlate slightly better with productivity scores across all tested languages, both at a sentence and at a document level. For this reason, word-level results are reported in the article's main body.
+
+
+
+
+Figure 6: Top: Distribution for the availability of documents selected for DivEMT in languages other than English. Bottom: Quantity of selected documents per number of available translations of Wikipedia.
+
+Automatic Evaluation of NMT Systems The selection of systems used in this study was driven by a broader evaluation procedure covering more models, metrics and target languages. Table 10 presents the overall results of our evaluation. We use HuggingFace's Transformers library (Wolf et al., 2020) for all neural models, using the default decoding settings without further fine-tuning. All metrics were computed using the default settings of SacreBLEU (Post, 2018) and Comet (Rei et al., 2020).
+
+Inter-subject Variability in Translation Times Although the variability across different subjects working on the same language directions is not the main concern of our investigation, we produce Figure 8 (an expanded version of Figure 2) to visualize the inter-subject variability for translation times. We observe that the variability across different translators is more pronounced when translating from scratch and that the overall trend of speed improvements associated with PE is mostly preserved (with few exceptions related to the $\mathrm{PE}_2$ modality).
+
+# F Full DivEMT Examples
+
+Tables 11 and 12 present two full examples of DivEMT entries, including all output modalities, intermediate MT outputs, post-edits and edit highlights for all target languages.
+
+
+Figure 7: Character-level Human-targeted Translation Edit Rate (CharacTER) for Google Translate and mBART-50 post-editing across available languages.
+
+# G Model Description and Feature Significance
+
+Linear Mixed Effects models (LMER) are used for regression analyses involving dependent data, such as longitudinal studies with multiple observations per subject. Given the variables of Table 9, our final model to predict translation time has the following formulation:
+
+$$
+\begin{array}{l} \text {e d i t} \sim \text {s r c} _ {\text {l e n}} \text {c h r} + \text {l a n g} _ {\text {i d}} * \text {t a k} _ {\text {t y p e}} \\ + (1 | \text {s u b j e c t} _ {\text {i d}}) \\ + (1 | \text {d o c u m e n t} _ {\mathrm {i d}} / \text {i t e m} _ {\mathrm {i d}}) \\ + (\emptyset + \text {t a k} _ {\text {t y p e}} | \text {d o c u m t e d} _ {\text {i d}} / \text {i t e m} _ {\text {i d}}) \\ \end{array}
+$$
+
+We log-transform the dependent variable, edit time in seconds, given its long right tail. The models are built by adding one element at a time, and checking whether such addition leads to a significantly better model with AIC (i.e. if the score gets reduced by at least 2). We fit the models using ML when comparing models that differ in the fixed structure, and REML when they differ in the random structure. We start with an initial model that just includes the two random intercepts (by-translator and by-segment) and proceed by (i) finding significance for nested document/segment random effect; (ii) adding fixed predictors one by one; (iii) adding interactions between fixed predictors; and (iv) adding the random slopes.
+
+From this sequential procedure, we obtain the resulting model. When checking the homoscedasticity and normality of residuals assumptions (Figures 9 and 10), we find the latter is not fulfilled. Consequently, we remove data points for which observations deviate by more than 2.5 standard deviations from the predicted value by the model (2.4% of the data) and refit the best model on this subset,
+
+Modality
+
+From Scratch (HT) Google Translate (PE1) mBART-50 (PE2)
+
+
+
+
+
+
+
+
+Subject ID
+
+
+Figure 8: Time per processed source word across languages, subjects and translation modalities, measured in seconds. Each point represents a document containing 3-5 sentences translated by a subject in one of the languages, with higher scores representing slower editing.
+
+ | System | BLEU | chrF2 | TER | chrF2++ | COMET |
| Arabic | M2M100 | 19.2 | 50.9 | 69.2 | 47 | 0.417 |
| MarianNMT | 22.7 | 54.2 | 64.7 | 50.4 | 0.483 |
| mBART-50 | 17 | 48.5 | 69.1 | 44.8 | 0.452 |
| GTrans | 34.1 | 65.6 | 52.8 | 61.9 | 0.737 |
| Dutch | M2M100 | 21.3 | 52.9 | 66.1 | 49.8 | 0.405 |
| MarianNMT | 25 | 56.9 | 62.5 | 53.8 | 0.543 |
| mBART-50 | 22.6 | 53.9 | 63.7 | 50.9 | 0.532 |
| DeepL | 28.7 | 59.5 | 59.5 | 56.6 | 0.67 |
| GTrans | 29.1 | 60 | 58.5 | 57.1 | 0.667 |
| Indonesian | M2M100 | 35.9 | 63.1 | 47.3 | 60.8 | 0.614 |
| MarianNMT | 38.5 | 65.6 | 46.5 | 63.3 | 0.671 |
| mBART-50 | 35.9 | 63.3 | 47.7 | 61.1 | 0.706 |
| GTrans | 51.5 | 73.6 | 34.5 | 71.9 | 0.894 |
| Italian | M2M100 | 23.6 | 53.9 | 63.2 | 51 | 0.51 |
| MarianNMT | 27.5 | 57.6 | 58.9 | 54.8 | 0.642 |
| mBART-50 | 24.4 | 54.7 | 61.2 | 51.8 | 0.648 |
| DeepL | 33 | 61 | 54 | 58.5 | 0.795 |
| GTrans | 32.8 | 61.4 | 53.6 | 58.8 | 0.781 |
| Japanese | M2M100 | 24.5 | 32.2 | 123.3 | 26 | 0.389 |
| mBART | 27.1 | 35.4 | 123 | 28.3 | 0.538 |
| DeepL | 41.3 | 46.8 | 108 | 37 | 0.75 |
| GTrans | 38.4 | 44.7 | 101.5 | 33.9 | 0.683 |
| Polish | M2M100 | 16.1 | 46.5 | 74.2 | 43.1 | 0.486 |
| MarianNMT | 19.3 | 49.9 | 70.5 | 46.6 | 0.648 |
| mBART-50 | 17.4 | 48.2 | 72.4 | 44.9 | 0.603 |
| DeepL | 24 | 54.3 | 66.4 | 51.1 | 0.832 |
| GTrans | 24.4 | 54.6 | 64.6 | 51.4 | 0.804 |
| Russian | M2M100 | 22.5 | 51.1 | 65.6 | 48.1 | 0.427 |
| MarianNMT | 25.4 | 53.5 | 64.3 | 50.7 | 0.537 |
| mBART | 24.8 | 52.6 | 63.7 | 49.7 | 0.541 |
| DeepL | 35.9 | 61.8 | 53.3 | 59.3 | 0.79 |
| GTrans | 33 | 60.5 | 55.2 | 57.7 | 0.731 |
| Turkish | M2M100 | 20.3 | 53.9 | 65.2 | 50.1 | 0.686 |
| MarianNMT | 26.3 | 59.8 | 58.8 | 55.8 | 0.881 |
| mBART-50 | 18.8 | 52.7 | 67.5 | 48.7 | 0.755 |
| GTrans | 35 | 65.5 | 50.4 | 62.2 | 1 |
| Ukrainian | M2M100 | 21.9 | 51.4 | 65.8 | 48.3 | 0.463 |
| MarianNMT | 20 | 48.8 | 69.2 | 45.7 | 0.427 |
| mBART-50 | 21.9 | 50.7 | 67.9 | 47.7 | 0.587 |
| GTrans | 31.1 | 59.8 | 55.9 | 56.8 | 0.758 |
| Vietnamese | M2M100 | 33.3 | 52.3 | 52.4 | 52.1 | 0.43 |
| MarianNMT | 26.7 | 45.7 | 60.2 | 45.6 | 0.117 |
| mBART-50 | 34.7 | 54 | 50.7 | 53.8 | 0.608 |
| GTrans | 45.1 | 61.9 | 41.8 | 61.9 | 0.724 |
+
+Table 10: Automatic MT quality of all evaluated NMT systems on all tested languages in the English-to-XX setting, using the FLORES-101 full devtest for evaluation. Besides mBART-50 and Google Translate (GTrans), we also evaluate a set of bilingual Transformer-based NMT models trained with MarianNMT (Tiedemann and Thottingal, 2020), the DeepL industrial MT system and the multilingual M2M-100 418M model (Fan et al., 2021). Overall best performance per language is highlighted in bold, best open-source system performance per language is underlined.
+
+in order to find out whether any of the effects were due to these outliers. The resulting trends do not change significantly in this final model, in which residuals are normally distributed. As a final sanity check, in Table 13 we measure the effect of subject identity on edit times and find no systematic
+
+patterns across languages.
+
+# ENGLISH
+
+Inland waterways can be a good theme to base a holiday around.
+
+# ARABIC
+
+HT
+
+PE1 MT: 4g> aolv lgego aoll uall oS jsc PE: 4g> aolv lgeo aolll uall oS jsc
+
+PE2 MT: Jg JIaIbI aIbI IJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJgJ
+
+# DUTCH
+
+HT Binnenlandse waterwegen können een goed thema zich voor een vakantie.
+
+$\mathbf{PE}_1$ MT: De binnenwateren können een goed theme zich om een vakantie omheen te baseren. PE: Binnenwateren können een goede vakantiebestemming zich.
+
+$\mathbf{PE}_2$ MT:Binnenwaterwegen hunnen een goed theme zich om een vakantie rond te zetten. PE:Binnenwaterwegen hunnen een goed theme zich om een vakantie rond te organise
+
+# ITALIAN
+
+HT I corsi d'acqua dell'entroterra possono essere un ottimo punto di partenza da cui organizzare una vacanza.
+
+MT:Trasporto fluviale puo essere un buon tema per basare una vacanza in giro.
+
+PE: I canali di navigazione interna posso: essere un ottimo motivo per cui intraprendere una vacanza.
+
+$\mathbf{PE}_2$ MT: I corsi d'acqua interni possono essere un buon tema per fondare una vacanza. PE: I corsi d'acqua interni possono essere un buon tema su cui basare una vacanzi
+
+# TURKISH
+
+HT Ic bollgerdeki su yollar, tatil plani icin iyir tema olabilir.
+
+$\mathbf{PE}_1$ MT: $\dot{\mathbb{I}}\varsigma$ su yollari, bir tatili temel almak icin iyir birtema olabilir. PE: $\dot{\mathbb{I}}\varsigma$ su yollari, bir tatil plani yapmak icin iyir birtema olabilir.
+
+PE2 MT: $\dot{\mathbf{l}}\varsigma$ suyolları, tatil icin uygun bir tema olabilir. PE: $\dot{\mathbf{l}}\varsigma$ sular tatil icin uygun bir tema olabilir.
+
+# UKRAINIAN
+
+HT MoKHa cIIJaHyBaTH BHXiIHi, B3aIBHIM 3a OCHOBy IIOIOPOJK BHYptiIHIM BOIDHMN IIIJIAxAMH.
+
+PE1 MT:BHytpiHnI BODHI IIIJIAHX MOJyTB cTaH rapHOIO TeMOIO IJIa BiIDIOUHNKu HABKOJIIO PE:BHytpiHnI BODHI IIIJIAHX MOJyTB cTaH rAPHOIO TEMOIO IJIa IPOBEdHHBHXiDNHX.
+
+PE2 MT: BoDiHIIJIaXn MoJcYb 6yTH XopoIHMM o6 'ektom IJIa 6a3yBaHHN BIDIOuHHKHy HABKOJIo . PE: MicIeBicTb HABKOJIIO BNYTpiiHIX BOdHNX IIJIaXiB MOKe 6yTH rapHIM Bn6Opom IJIa opraHl3auii BiIIOuHHKy.
+
+# VIETNAMESE
+
+HT Du lich trén song có the là moot lua chon phu hop cho k'y相关内容
+
+PE1 MT: Duong thuy noci co the la mot chu de hay de tao co so cho mok y ngh xung quanh. PE: Duong thuy noci co the la mot y tuong hay de lap ke hoach cho k y nghi.
+
+$\mathrm{PE}_{2}$ MT: Cáctuyén nuoc noidia có theà là môt chu dé tó t é xay dng môt kì nghi. PE: Du lich bang duong thuy noidia là môt y tuong nghi duong khong tōi.
+
+Table 11: An example sentence (81.1) from the DivEMT corpus, with the English source and all output modalities for all target languages, including intermediate machine translations (MT) and subsequent post-editings (PE). Colors denote insertions, deletions, substitutions and shifts computed with Tercom (Snover et al., 2006).
+
+| ENGLISH
+The Internet combines elements of both mass and interpersonal communication. |
| ARABIC |
| HT | • रूधी अयकान्योत्तिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्ल�िका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्ल任意的 |
| PE1 | • रूधी अयकान्योत्तिका विल्लिका विल्लिका विल्लिका विल्लिका विल्लिका विल्ल任意的 |
| PE2 | • रूधी अयकान्योत्तिका विल्लिका विल्ल任意的 |
| DUTCH |
| HT | Het internetcombineert elementen van zowel massa- en internmenselijke communatie. |
| PE1 | • Het internetcombineert elementen van zowel massa- als interpersoonlijke communatie. |
| PE2 | • Het internetcombineert elementen van zowel massa- als interpersoonlijke communatie. |
| ITALIAN |
| HT | Internet combina elementi di comunazione sià di massa sa interpersonale. |
| PE1 | • Internet combina elementi di comunazione di massa e interpersonali. |
| PE2 | • Internet combina elementi di comunazione di massa e interpersonale. |
| TURKISH |
| HT | Internet hem kitlesel hem de bireysel iletisim öğelerini birleştiiriyor. |
| PE1 | • Internet, hem kitle hem de kişiler arasi iletisimin unsurlarini birleştiirir. |
| PE2 | • Internet hem kitleler hem de kişiler arasi iletisimin unsurlarini birleştiirir. |
| UKRAINIAN |
| HT | B inTechenet iioeinyotbce eIemehn rpyioboro cnilkybaHHa Ta ocobnctoro cnilkybaHHa. |
| PE1 | • IInTechenet iioeinye B cobi eIemehn jk MacOBoro, taK i mjkocobnctichoro cnilkybaHHa. |
| PE2 | • IInTechenet iioeinye B cobi eIemehn jk MacOBoro, taK i mjkocobnctichoro cnilkybaHHa. |
| VIETNAMESE |
| HT | Internet là noïtóng hopcac yéu tó cua ca phuong tiên truyèn thong dai chung via giao tiêp lién ca nhân. |
| PE1 | • Internet két hopcac yéu tó cua ca giao tiêp dai chung via giao tiêp giūa cac ca nhân. |
| PE2 | • Internet két hopcac yéu tó cua ca triyèn thong dai chung via giao tiêp giūa cac ca nhân. |
| PE2 | • Internet két hopnhūng yéu tó cua suf giao tiêp quàn chung via giao tiêp giūa ngūo i vii ngūo i PE: Internet két hopnhūng yéu tó cua ca viéc giao tiêp dai chung via giao tiêp ca nhân. |
+
+Table 12: An example sentence (29.2) from the DivEMT corpus, with the English source and all output modalities for all target languages, including intermediate machine translations (MT) and subsequent post-editings (PE). Colors denote insertions, deletions, substitutions and shifts computed with Tercom (Snover et al., 2006).
+
+
+Figure 9: Residuals of the final LMER model, used to verify the heteroscedasticity assumption.
+
+
+Figure 10: Quantile-quantile plot before and after the removal of outliers when fitting the LMER model, used to verify the normality assumption.
+
+
+
+| Subject | Coefficient |
| ara_t1 | 0.281 |
| ara_t2 | -0.384 |
| ara_t3 | -0.103 |
| nld_t1 | 0.001 |
| nld_t2 | -0.459 |
| nld_t3 | 0.458 |
| ita_t1 | 0.086 |
| ita_t4 | 0.350 |
| ita_t5 | -0.436 |
| tur_t1 | -0.381 |
| tur_t2 | 0.272 |
| tur_t3 | 0.109 |
| ukr_t1 | 0.077 |
| ukr_t2 | 0.314 |
| ukr_t3 | -0.391 |
| vie_t1 | 0.012 |
| vie_t2 | 0.176 |
| vie_t3 | -0.188 |
+
+Table 13: Coefficients of the random intercept related to the subject_id variable, representing the identity of the translator performing the translation.
\ No newline at end of file
diff --git a/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/images.zip b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..d3dac45b46336a590b4fef2d8f077b97557eab13
--- /dev/null
+++ b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:425fd5ea883387340762e44d4521fa5e5f7edee93337db5f2f83cfadad18be70
+size 1471971
diff --git a/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/layout.json b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..60e2469523dd6fab65778b7c5d4b85791506c7df
--- /dev/null
+++ b/divemtneuralmachinetranslationposteditingeffortacrosstypologicallydiverselanguages/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1c533fb552e26af6902223f93ccbd1c5e839a6471bcabc99041a4a906b855500
+size 551669
diff --git a/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_content_list.json b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..df778d9d1b668423dd269720945797736186b6bd
--- /dev/null
+++ b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:76d2c6b4b7d5d8c1ceff1e0fcb0356da52dc0860d3e2b123c3c60ce3bd655ae1
+size 101074
diff --git a/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_model.json b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..fbe28336fd8a2225d0b23396a282c4cfbb4c7333
--- /dev/null
+++ b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:573ad5f830868e83fb21c9ae377386ff80279337976e3532884002fce1dc6150
+size 119524
diff --git a/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_origin.pdf b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..8230207d2ea2733720eaca46e1e4bac3d1500fab
--- /dev/null
+++ b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/10d59a5e-1484-4186-9877-090226696891_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bf6da9f215d9e4b4ea679761497348295cba7da634155d09e87cf29ed7618413
+size 580998
diff --git a/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/full.md b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f61c4874041d9c3e89fa69a24b58afb7283eac98
--- /dev/null
+++ b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/full.md
@@ -0,0 +1,365 @@
+# Diverse Parallel Data Synthesis for Cross-Database Adaptation of Text-to-SQL Parsers
+
+Abhijeet Awasthi Ashutosh Sathe Sunita Sarawagi
+
+Indian Institute of Technology Bombay, India
+
+{awasthi, absathe,sunita}@cse.iitb.ac.in
+
+# Abstract
+
+Text-to-SQL parsers typically struggle with databases unseen during the train time. Adapting parsers to new databases is a challenging problem due to the lack of natural language queries in the new schemas. We present REFILL, a framework for synthesizing high-quality and textually diverse parallel datasets for adapting a Text-to-SQL parser to a target schema. REFILL learns to retrieve-and-edit text queries from the existing schemas and transfers them to the target schema. We show that retrieving diverse existing text, masking their schema-specific tokens, and refilling with tokens relevant to the target schema, leads to significantly more diverse text queries than achievable by standard SQL-to-Text generation methods. Through experiments spanning multiple databases, we demonstrate that fine-tuning parsers on datasets synthesized using REFILL consistently outperforms the prior data-augmentation methods.
+
+# 1 Introduction
+
+Natural Language interface to Databases (NLIDB) that translate text queries to executable SQLs is a challenging task in the field of Semantic Parsing (Zelle and Mooney, 1996; Zettlemoyer and Collins, 2005; Berant et al., 2013). In addition to understanding the natural language and generating an executable output, Text-to-SQL also requires the ability to reason over the schema structure of relational databases. Recently, datasets such as Spider (Yu et al., 2018) comprising of parallel (Text,SQL) pairs over hundreds of schemas have been released, and these have been used to train state-of-the-art neural Text-to-SQL models (Wang et al., 2020; Scholak et al., 2021a; Rubin and Berant, 2021; Scholak et al., 2021b; Xu et al., 2021). However, several studies have independently shown that such Text-to-SQL models fail catastrophically when evaluated on unseen schemas from the real-world databases (Suhr et al., 2020;
+
+Lee et al., 2021; Hazoom et al., 2021). Adapting existing parsers to new schemas is challenging due to the lack of parallel data for fine-tuning the parser.
+
+Synthesizing parallel data, that is representative of natural human generated queries (Wang et al., 2015; Herzig and Berant, 2019), is a long-standing problem in semantic parsing. Several methods have been proposed for supplementing with synthetic data, ranging from grammar-based canonical queries to full-fledged conditional text generation models (Wang et al., 2015; Herzig and Berant, 2019; Zhong et al., 2020; Yang et al., 2021; Zhang et al., 2021; Wang et al., 2021). For Text-to-SQL, data-augmentation methods are primarily based on training an SQL-to-Text model using labeled data from pre-existing schemas, and generating data in the new schemas. We show that the text generated by these methods, while more natural than canonical queries, lacks the rich diversity of natural multi-user queries. Fine-tuning with such data often deteriorates the model performance since the lack of diversity leads to a biased model.
+
+We propose a framework called REFILL (§ 2) for generating diverse text queries for a given SQL workload that is often readily available (Baik et al., 2019). REFILL leverages parallel datasets from several existing schemas, such as Spider (Yu et al., 2018), to first retrieve a diverse set of text paired with SQLs that are structurally similar to a given SQL $q$ (§ 2.1). Then, it trains a novel schema translator model for converting the text of the training schema to the target schema of $q$ . The schema translator is decomposed into a mask and fill step to facilitate training without direct parallel examples of schema translation. Our design of the mask module and our method of creating labeled data for the fill module entails non-trivial details that we explain in this paper (§ 2.2). REFILL also incorporates a method of filtering-out inconsistent (Text,SQL) pairs using an independent binary classifier (§ 2.3), that provides more useful
+
+quality scores, than the cycle-consistency based filtering (Zhong et al., 2020). Our approach is related to retrieve-and-edit models that have been used for semantic parsing (Hashimoto et al., 2018), dialogue generation (Chi et al., 2021), translation (Cai et al., 2021), and question answering (Karpukhin et al., 2020). However, our method of casting the "edit" as a two-step mask-and-fill schema translation model is different from the prior work.
+
+We summarize our contributions as follows: (i) We propose the idea of retrieving and editing natural text from several existing schemas for transferring it to a target schema, obtaining higher text diversity compared to the standard SQL-to-Text generators. (ii) We design strategies for masking schema-specific words in the retrieved text and training the REFILL model to fill in the masked positions with words relevant to the target schema. (iii) We filter high-quality parallel data using a binary classifier and show that it is more efficient than existing methods based on cycle-consistency filtering. (iv) We compare REFILL with prior data-augmentation methods across multiple schemas and consistently observe that fine-tuning Text-to-SQL parsers on data generated by REFILL leads to more accurate adaptation.
+
+# 2 Diverse data synthesis with REFILL
+
+Our goal is to generate synthetic parallel data to adapt an existing Text-to-SQL model to a target schema unseen during training. A Text-to-SQL model $\mathcal{M}:\mathcal{X},\mathcal{S}\mapsto \mathcal{Q}$ maps a natural language question $x\in \mathcal{X}$ for a database schema $s\in S$ to an SQL query $\hat{q}\in \mathcal{Q}$ . We assume a Text-to-SQL model $\mathcal{M}$ trained on a dataset $\mathcal{D}_{\mathrm{train}} = \{(x_i,s_i,q_i)\}_{i = 1}^N$ consisting of text queries $x_{i}$ for a database schema $s_i$ , and the corresponding gold SQLs $q_{i}$ . The train set $\mathcal{D}_{\mathrm{train}}$ typically consists of examples from a wide range of schemas $s_i\in S_{\mathrm{train}}$ . For example, the Spider dataset (Yu et al., 2018) contains roughly 140 schemas in the train set. We focus on adapting the model $\mathcal{M}$ to perform well on a target schema $s$ different from the training schemas in $\mathcal{S}_{\mathrm{train}}$ . To achieve this, we present a method of generating synthetic data $\mathcal{D}_{\mathrm{syn}}$ of Text-SQL pairs containing diverse text queries for the target schema $s$ . We fine-tune the model $\mathcal{M}$ on $\mathcal{D}_{\mathrm{syn}}$ to adapt it to the schema $s$ . Our method is agnostic to the exact model used for Text-to-SQL parsing. We assume that on the new schema $s$ we have a workload $\mathcal{QW}_s$ of SQL queries. Often in
+
+Algorithm 1: Data Synthesis with REFILL
+1 input: $\mathcal{Q}\mathcal{W}_s$ ,M, $\mathcal{D}_{\mathrm{train}}$
+2 $\mathcal{D}_{\mathrm{syn}}\gets \phi$
+3 for $q\gets$ SampleSQLQueries $(Q\mathcal{W}_s)$ do
+4 $\{q_r,x_r\} \gets$ RetrieveRelatedPairs(q, $\mathcal{D}_{\mathrm{train}}$ )
+5 $\{x_{r}^{\mathrm{masked}}\} \gets$ MaskSchemaTokens( $\{q_r,x_r\}$ )
+6 $\{x_r^q\} \gets$ EditAndFill( $\{q,x_r^{\mathrm{masked}}\}$ )
+7 $\mathcal{D}_{\mathrm{syn}}\gets \mathcal{D}_{\mathrm{syn}}\cup \mathcal{F}$ lter(q,{ $x_r^q}$ )
+8 Mnew $\leftarrow$ fine-tune(M, $\mathcal{D}_{\mathrm{syn}}$
+
+existing databases a substantial SQL workload is already available in the query logs at the point a DB manager decides to incorporate the NL querying capabilities (Baik et al., 2019). The workload is assumed to be representative but not exhaustive. In the absence of a real workload, a grammar-based SQL generator may be used (Zhong et al., 2020; Wang et al., 2021).
+
+Figure 1 and Algorithm 1 summarizes our method for converting a workload $\mathcal{Q}\mathcal{W}_s$ of SQL queries into a synthetic dataset $\mathcal{D}_{\mathrm{syn}}$ of Text-SQL pairs containing diverse text queries. Given an SQL query $q \in \mathcal{Q}\mathcal{W}_s$ for the target schema $s$ , our method first retrieves related SQL-Text pairs $\{q_r, x_r\}_{r=1}^R$ from $\mathcal{D}_{\mathrm{train}}$ on the basis of a tree-edit-distance measure such that the SQLs $\{q_r\}_{r=1}^R$ in the retrieved pairs are structurally similar to the SQL $q$ ( $\S 2.1$ ). We then translate each retrieved text query $x_r$ so that its target SQL changes from $q_r$ to $q$ on schema $s$ ( $\S 2.2$ ). We decompose this task into two steps: masking out schema specific tokens in $x_r$ , and filling the masked text to make it consistent with $q$ using a conditional text generation model $\mathcal{B}$ like BART (Lewis et al., 2020). The translated text may be noisy since we do not have direct supervision to train such models. Thus, to improve the overall quality of the synthesized data we filter out the inconsistent SQL-Text pairs using an independent binary classifier ( $\S 2.3$ ). Finally, we adapt the Text-to-SQL model $\mathcal{M}$ for the target schema $s$ by fine-tuning it on the diverse, high-quality filtered data $\mathcal{D}_{\mathrm{syn}}$ synthesized by REFILL.
+
+# 2.1 Retrieving related queries
+
+Given an SQL $q \in \mathcal{Q}\mathcal{W}_s$ sampled from SQL workload, we extract SQL-Text pairs $\{q_r, x_r\} \in \mathcal{D}_{\mathrm{train}}$ from the train set such that the retrieved SQLs $\{q_r\}$ are structurally similar to the SQL $q$ . We utilize tree-edit-distance (Pawlik and Augsten, 2015, 2016) between the relational algebra trees of SQLs $q$ and $q_r$ — smaller distance implies higher structural similarity. Since the retrieved SQLs come
+
+
+Figure 1: Diverse parallel data synthesis by retrieving-and-editing existing examples using REFILL. Given an SQL $q$ from a new schema, REFILL (1) Retrieves SQL-Text pairs from an existing dataset ( $\S 2.1$ ) where the SQLs are structurally similar to $q$ (indicated by dashed lines). (2) Since the retrieved text come from a different schema, we mask-out the schema-specific words ( $\S 2.2$ ). (3) The masked text and the SQL $q$ are then translated into the target schema via an Edit and Fill step that uses a conditional text generation model like BART ( $\S 2.2$ ). In this way, we transfer the text from multiple existing schemas to generate diverse text for the new schemas. (4) Finally, we use a binary classifier as a filtering model to retain only the consistent Text-SQL pairs in the output dataset ( $\S 2.3$ ).
+
+
+Figure 2: Frequency distribution of average tree-edit-distance between SQLs and their three nearest neighbours from other schemas within Spider's train set.
+
+from different schemas, we modify the tree-edit-distance algorithm to ignore the schema names and the database values. The tree-edit-distance is further normalized by the size of the larger tree. We only consider the $\{q_r, x_r\}$ pairs where the SQLs $\{q_r\}$ have a distance of less than 0.1 w.r.t. the SQL $q$ . Within datasets like Spider that span hundreds of schemas, it is often possible to find several SQLs structurally similar to a given SQL $q$ . For example, in Spider we found that $76\%$ of the train SQLs contain at least three zero-distance (structurally identical) neighbours in other schemas. In Figure 2, we present more detailed statistics.
+
+# 2.2 Translating text of related queries
+
+Our next goal is to translate the retrieved $x_{r}$ from being a text for SQL $q_{r}$ to a text $\hat{x}$ for SQL $q$ , where $q \approx q_{r}$ structurally. However, we do not have a readily labeled dataset to learn a model that translates $x_{r}$ to $\hat{x}$ while being consistent with $q$ . We therefore decompose this task into two steps: 1) A simpler task of masking schema-specific tokens in $x_{r}$ to get a template $x_{r}^{\text{masked}}$ and 2) A conditional text generation model that maps $(x_{r}^{\text{masked}}, q)$ to the text $\hat{x}$ consistent with $q$ , by filling the masked positions in $x_{r}^{\text{masked}}$ as per $q$ . We re-purpose $\mathcal{D}_{\text{train}}$ to get indirect supervision for training the text generation model. We now present each step in detail.
+
+Masking the retrieved text Converting the retrieved text queries $\{x_{r}\}$ to masked templates $\{x_{r}^{\mathrm{masked}}\}$ is a critical component of REFILL's pipeline since irrelevant tokens like references to schema elements of the original database can potentially misguide the text generation module. Our initial approach was to mask tokens based on a match of text tokens with schema names and manually refined schema-to-text linked annotations as in Lei et al. (2020). However, this approach failed to mask all schema-related terms since their occurrences in natural text often differed significantly from schema names in the database. Table A7 shows some anecdotes. Consequently, we designed
+
+a simple frequency-based method of masking that is significantly more effective for our goal of using the masked text to just guide the diversity. For each word that appears in the text queries of the train set, we count the number of distinct databases where that word gets mentioned at least once. For example, common words like {'show', 'what', 'list', 'order'} get mentioned in more than $90\%$ of the schemas, and domain specific words like {'countries', 'government'} occur only in text queries of a few schemas. We mask out all the words that appear in less than $50\%$ of the schemas. The words to be masked are replaced by a special token MASK, and consecutive occurrences of MASK are collapsed into a single MASK token. Thus we obtain masked templates $\{x_r^{\mathrm{masked}}\}$ retaining minimal information about their original schema.
+
+Editing and Filling the masked text Given a masked template $x_{r}^{\mathrm{masked}}$ , and an SQL query $q$ we wish to edit and fill the masked portions in $x_{r}^{\mathrm{masked}}$ to make it consistent with the SQL $q$ . We utilize a conditional text generation model $\mathcal{B}$ like BART (Lewis et al., 2020) for this purpose. We first convert $q$ into a pseudo-English representation $q^{\mathrm{Eng}}$ similar to Shu et al. (2021), to make it easier for $\mathcal{B}$ to encode $q$ . In addition, we wrap the table, column, or value tokens in $q^{\mathrm{Eng}}$ with special tokens to provide explicit signals to the text generation model $\mathcal{B}$ that such tokens are likely to appear in the output text $\hat{x}$ . Next, we concatenate the tokens in $x_{r}^{\mathrm{masked}}$ and $q^{\mathrm{Eng}}$ for jointly encoding them as an input to $\mathcal{B}$ . The output of $\mathcal{B}$ 's decoder is text $\hat{x}$ , which is expected to be consistent with the SQL $q$ .
+
+Since we do not have direct supervision to fine-tune $\mathcal{B}$ for this task, we present a method of repurposing $\mathcal{D}_{\mathrm{train}}$ for fine-tuning $\mathcal{B}$ . $\mathcal{D}_{\mathrm{train}}$ contains SQL-Text pairs $(q_{i},x_{i})$ from various schemas $s_i$ . A Naive way to train $\mathcal{B}$ is to provide $[x_i^{\mathrm{masked}}|q_i^{\mathrm{Eng}}]$ , the concatenation of $x_{i}^{\mathrm{masked}}$ and $q_{i}^{\mathrm{Eng}}$ as an input to the encoder and maximize the likelihood of $x_{i}$ in the decoder's output. This way the decoder of $\mathcal{B}$ learns to refill the masked tokens in $x_{i}^{\mathrm{masked}}$ by attending to $q_{i}^{\mathrm{Eng}}$ to recover $x_{i}$ in the output. While useful for learning to refill the masked positions, this Naive method of training $\mathcal{B}$ is mismatched from its use during inference in two ways: (i) For a given SQL $q$ , REFILL might fail to retrieve a similar structure neighbour of $q_{i}$ from $\mathcal{D}_{\mathrm{train}}$ . In such cases, $\mathcal{B}$ should be capable of falling back to pure SQL-to-Text generation mode to directly translate $q$ into $\hat{x}$ . (ii) During inference, $x_{r}^{\mathrm{masked}}$ and $q$ come
+
+from different schemas. However, during Naive training, the masked text $x_{i}^{\text{masked}}$ and the SQL $q_{i}$ are derived from the same example $(q_{i}, x_{i})$ . To address these two limitations, we train $\mathcal{B}$ in a more Robust manner as follows: (a) For a random one-third of the train steps we train $\mathcal{B}$ in the Naive way, allowing $\mathcal{B}$ to learn the filling of the masked tokens using $q_{i}^{\text{Eng}}$ . (b) For another one-third, we pass only $q_{i}^{\text{Eng}}$ as an input and maximize the likelihood of $x_{i}$ . This ensures that model is capable of generating the text from the $q_{i}^{\text{Eng}}$ alone, if the templates $x_{i}^{\text{masked}}$ are unavailable or noisy. (c) For the remaining one-third, we first retrieve an SQL-Text pair $(q_{j}, x_{j})$ , from a different schema such that the SQL $q_{j}$ is structurally similar to $q_{i}$ (§ 2.1), and the word edit distance between the masked templates $x_{i}^{\text{masked}}$ and $x_{j}^{\text{masked}}$ is also small. We can then replace $x_{i}^{\text{masked}}$ with $x_{j}^{\text{masked}}$ and encode $[x_{j}^{\text{masked}} | q_{i}^{\text{Eng}}]$ as an input to $\mathcal{B}$ and maximize the likelihood of $x_{i}$ in the decoder's output. This step makes the training more consistent with the inference, as $x_{j}^{\text{masked}}$ and $q_{i}^{\text{Eng}}$ now come from different schemas. In § 5.4, we justify training Robustly compared to Naive training.
+
+# 2.3 Filtering the Generated Text
+
+Since the data synthesized using REFILL is used to fine-tune a downstream Text-to-SQL parser, we learn a Filtering model $\mathcal{F}:(\mathcal{X},\mathcal{Q})\mapsto \mathbb{R}$ to discard inconsistent examples from the generated dataset. $\mathcal{F}$ assigns lower scores to inconsistent Text-SQL pairs. For each SQL $q\in \mathcal{Q}\mathcal{W}_s$ , we select the top-5 sentences generated by REFILL and discard all the sentences that are scored below a fixed threshold as per the filtering model. Existing work depended on a trained Text-to-SQL parser $\mathcal{M}$ to assign cycleconsistency scores (Zhong et al., 2020). However, we show that cycle-consistency filtering favors text on which $\mathcal{M}$ already performs well, and hence does not result in a useful dataset for fine-tuning $\mathcal{M}$
+
+We instead train a filtering model $\mathcal{F}$ as a binary classifier, independent of $\mathcal{M}$ . The Text-SQL pairs $\{(x_i, q_i)\}$ in the training set $\mathcal{D}_{\mathrm{train}}$ , serve as positive (consistent) examples and we synthetically generate the negative (inconsistent) examples as follows: (i) Replace DB values in the SQL $q_i$ with arbitrary values sampled from the same column of the database. (ii) Replace SQL-specific tokens in $q_i$ with their corresponding alternates e.g. replace ASC with DESC, or $>$ with $<$ . (iii) Cascade previous two perturbations. (iv) Replace the entire SQL $q_i$ with a randomly chosen SQL $q_j$ from the same
+
+schema. (v) Randomly drop tokens in the text query $x_{i}$ with a fixed probability of 0.3. (vi) Shuffle a span of tokens in the text query $x_{i}$ , with span length set to $30\%$ of the length of $x_{i}$ . Thus, for a given Text-SQL pair $(x_{i}, q_{i})$ we obtain six corresponding negative pairs $\{(x_{j}^{n}, q_{j}^{n})\}_{j=1}^{6}$ . Let $s_{i}$ be the score provided by the filtering model for the original pair $(x_{i}, q_{i})$ and $\{s_{j}\}_{j=1}^{6}$ be the scores assigned to the corresponding negative pairs $\{(x_{j}^{n}, q_{j}^{n})\}_{j=1}^{6}$ . We supervise the scores from the filtering model using a binary-cross-entropy loss over the Sigmoid activations of scores as in Equation 1.
+
+$$
+\mathcal {L} _ {\mathrm {b c e}} = - \log \sigma \left(s _ {i}\right) - \sum_ {j = 1} ^ {6} \log \sigma \left(1 - s _ {j}\right) \tag {1}
+$$
+
+To explicitly contrast an original pair with its corresponding negative pairs we further add another Softmax-Cross-Entropy loss term.
+
+$$
+\mathcal {L} _ {\mathrm {x e n t}} = - \log \frac {\exp (s _ {i})}{\exp (s _ {i}) + \sum_ {j = 1} ^ {6} \exp (s _ {j})} \tag {2}
+$$
+
+# 3 Related Work
+
+SQL-to-Text generation Many prior works perform training data augmentation via pre-trained text generation models that translate SQLs into natural text (Guo et al., 2018; Zhong et al., 2020; Shi et al., 2020; Zhang et al., 2021; Wang et al., 2021; Yang et al., 2021; Shu et al., 2021). For example, Wang et al. (2021) fine-tune BART (Lewis et al., 2020) on parallel SQL-Text pairs to learn an SQL-to-Text translation model. Shu et al. (2021) propose a similar model that is trained in an iterative-adversarial way along with an evaluator model. The evaluator learns to identify inconsistent SQL-Text pairs, similar to our filtering model. To retain high quality synthesized data Zhong et al. (2020) additionally filter out the synthesized pairs using a pre-trained Text-to-SQL model based on cycle consistency, that we show to be sub-optimal ( $\S$ 5.5). The SQL workload in most of the prior work was typically sampled from hand-crafted templates or a grammar like PCFG induced from existing SQLs, or crawling SQLs from open-source repositories Shi et al. (2020). However, database practitioners have recently drawn attention to the fact that SQL workloads are often pre-existing and should be utilized (Baik et al., 2019).
+
+Retrieve and Edit Methods Our method is related to the retrieve-and-edit framework, which has
+
+been previously applied in various NLP tasks. In Semantic Parsing, question and logical-form pairs from the training data relevant to the test-input question are retrieved and edited to generate the output logical forms in different ways (Shaw et al., 2018; Das et al., 2021; Pasupat et al., 2021; Gupta et al., 2021). In machine translation, memory augmentation methods retrieve-and-edit examples from translation memory to guide the decoder's output (Hossain et al., 2020; Cai et al., 2021). Our editing step — masking followed by refilling is similar to style transfer methods that minimally modify the input sentence with help of retrieved examples corresponding to a target attribute (Li et al., 2018). In contrast to learning a retriever, we find simple tree-edit distance to be an effective metric for retrieving the relevant examples for our task.
+
+# 4 Experimental Set-up
+
+We adapt pretrained Text-to-SQL parsers on multiple database schemas unseen during the train time. Here, we describe the datasets, models, and evaluation metrics used in our experiments.
+
+Datasets: We primarily experiment with the Spider dataset (Yu et al., 2018). Spider's train split contains 7000 Text-to-SQL examples spanning 140 database schemas, and the dev split contains roughly 1000 examples spanning 20 schemas2. Since individual schemas in the dev split typically contain less than 50 examples, to evaluate on a larger set of examples we adapt and evaluate the Text-to-SQL parser on groups of similar schemas instead of individual schemas. We create 4 groups, with each group having database schemas from a similar topic. For example, Group-1 consists of databases {Singer, Orchestra, Concerts}. We utilize all the available Text-SQL pairs in each group for evaluation. In appendix Table A.1, we provide detailed statistics about each group. On average, each group contains 69 unique SQLs and 131 evaluation examples. To simulate a query workload $\mathcal{Q}\mathcal{W}_s$ for each group, we randomly select $70\%$ of the available SQLs and replace the constant-values in the SQLs with values sampled from their corresponding column in the database. We also evaluate on query workloads of size $30\%$ and $50\%$ of the available SQL queries. The SQL queries in the workload are translated using REFILL or an SQL-to-Text model, and the resulting Text-SQL pairs are
+
+ | Group 1 | Group 2 | Group 3 | Group 4 | Average |
| Method | EM | EX | EM | EX | EM | EX | EM | EX | EM | EX |
| BASE-M | 80.9 | 84.3 | 64.8 | 67.2 | 64.0 | 65.9 | 45.8 | 35.8 | 63.8 | 63.3 |
| L2S (Wang et al., 2021) | 88.7 | 87.8 | 61.3 | 62.1 | 62.8 | 61.0 | 42.5 | 35.0 | 63.8 | 61.4 |
| GAZP (Zhong et al., 2020) | 85.2 | 85.2 | 58.9 | 66.9 | 70.1 | 60.5 | 52.5 | 40.8 | 66.6 | 63.3 |
| SNOWBALL (Shu et al., 2021) | 85.2 | 87.8 | 59.7 | 60.5 | 64.0 | 65.9 | 44.2 | 38.3 | 63.2 | 63.1 |
| REFILL (Ours) | 88.7 | 87.0 | 69.7 | 73.8 | 73.2 | 70.1 | 55.8 | 45.0 | 71.8 | 68.9 |
+
+Table 1: Results for finetuning a base semantic parser (SMBOP) on Text-SQL pairs generated using various SQL-to-Text baselines and REFILL (§ 5.1). REFILL provides consistent gains over the base model across all the database groups, while gains from other methods are often negative or small.
+
+then used to fine-tune a base Text-to-SQL parser.
+
+We further experiment with four datasets outside Spider in Section 5.6. We work with GeoQuery (Zelle and Mooney, 1996), Academic (Li and Jagadish, 2014), IMDB and Yelp (Navid Yaghmazadeh and Dillig, 2017). We utilize the preprocessed version of these datasets open-sourced by Yu et al. (2018). In appendix Table A2, we present statistics about each of the four datasets.
+
+Text-to-SQL parser: We experiment with SMBoP (Rubin and Berant, 2021) as our base Text-to-SQL parser, and utilize author's implementation. The SMBoP model is initialized with a ROBERTABASE model, followed by four RAT layers, and trained on the train split of Spider dataset. The dev set used for selecting the best model excludes data from the four held-out evaluation groups.
+
+Edit and Fill model: We utilize a pre-trained BART-BASE as our conditional text generation model for editing and filling the masked text. The model is fine-tuned using the train split of Spider dataset as described in Section 2.2
+
+Filtering Model: We train a binary classifier based on a ROBERTA-BASE checkpoint on Spider's train split to filter out inconsistent SQL-Text pairs as described in Section 2.3.
+
+Baselines: For baseline SQL-to-Text generation models, we consider recently proposed models like L2S (Wang et al., 2021), GAZP (Zhong et al., 2020), and SNOWBALL (Shu et al., 2021). All the baselines utilize pre-trained language models like BART (Lewis et al., 2020) or BERT (Devlin et al., 2018) for translating SQL tokens to natural text in a standard seq-to-seq set-up. The baselines mostly differ in the way of encoding SQL tokens as an input to the language model. In Section 3, we reviewed the recent SQL-to-Text methods.
+
+Evaluation Metrics We evaluate the Text-to-SQL parsers using the Exact Set Match (EM), and the Exection Accuracy (EX) Yu et al. (2018). The EM
+
+metric measures set match for all the SQL clauses and returns 1 if there is a match across all the clauses. It ignores the DB-values (constants) in the SQL query. The EX metric directly compares the results obtained by executing the predicted query $\hat{q}$ and the gold query $q$ on the database.
+
+We provide more implementation details including the hyperparameter settings in appendix A.5.
+
+# 5 Results and Analysis
+
+We first demonstrate the effectiveness of the synthetic data generated using REFILL for fine-tuning Text-to-SQL parsers to new schemas. We compare with the recent methods that utilize SQL-to-Text generation for training-data augmentation (§ 5.1). We then evaluate the intrinsic quality of the synthetic data generated by different methods in terms of the text diversity and the agreement of the generated text with the ground truth (§ 5.2). We demonstrate that higher text diversity results in better performance of the adapted parsers (§ 5.3). We then justify the key design choices related to masking of the retrieved text and training of the schema translator module that improves the quality of REFILL generated text (§ 5.4). Finally, we demonstrate the importance of using an independent binary classifier over cycle-consistency filtering (§ 5.5).
+
+# 5.1 Evaluating adapted parsers
+
+In Table 1, we compare the performance of parsers fine-tuned on Text-SQL pairs generated using REFILL and other SQL-to-Text generation baselines. We observe that fine-tuning on high-quality and diverse text generated by REFILL provides consistent performance gains over the base model across all the database groups. On average, REFILL improves the base model by 8.0 EM in comparison to a gain of 2.8 EM by the best baseline (GAZP). We observe that the gains from baseline methods are
+
+
+Figure 3: Average EM performance of Text-to-SQL models on the four groups vs. the size of SQL workload (§ 5.1). Data generated by REFILL using $30\%$ SQL workload yields better performance than the data from the existing best baseline utilizing $70\%$ workload.
+
+often small or even negative. REFILL continues to yield positive gains even for smaller workload sizes — In Figure 3, we plot the fraction of the total SQL workload used on the x-axis and the EM of the fine-tuned parsers averaged across all the four groups, on the y-axis. When using the data synthesized by REFILL, the performance of the parser improves steadily with an increasing size of the SQL workload. In contrast, the baseline SQL-to-Text generation methods fail to provide significant improvements. Interestingly, the data synthesized by REFILL using the $30\%$ SQL workload leads to better downstream performance of the adapted parsers than any of the baselines utilizing $70\%$ SQL workload for SQL-to-Text generation.
+
+# 5.2 Quality and Diversity of generated text
+
+We explain our gains over existing methods due to the increased quality and diversity of the generated text. We measure quality using the BLEU score of the set $S(q)$ of generated text for an SQL $q$ , with the gold text of $q$ as reference. To measure diversity we utilize SelfBLEU (Zhu et al., 2018) that measures the average BLEU score among text in $S(q)$ . Lower SelfBLEU implies higher diversity. We evaluate on all the gold SQL-Text pairs available in the Spider's dev set. In Table 2, we compare the quality and diversity of the text generated using REFILL with prior SQL-to-Text generation methods. For each method we generate 10 hypotheses per SQL query, and pick the hypothesis with the highest BLEU to report the overall BLEU
+
+| Method | BLEU ↑ (Quality) | 100-SelfBLEU ↑ (Diversity) |
| Gold-Ref | 100 | 68.8 |
| L2S | 38.0 | 2.2 |
| GAZP | 38.8 | 2.0 |
| SnowBall | 40.2 | 2.8 |
| REFILL | 48.6 | 33.8 |
+
+Table 2: Comparison of quality (BLEU) and diversity (100-SelfBLEU) scores across various SQL-to-Text models including REFILL ( $\S$ 5.2). Gold-Ref represents the scores corresponding to the reference text.
+
+
+Figure 4: Accuracy of fine-tuned parsers Vs. the number of templates per SQL used by REFILL (§ 5.3).
+
+scores. To allow baselines to generate more diverse text than the standard beam search, we utilize beam-sampling (Fan et al., 2018; Holtzman et al., 2019). For REFILL, the 10 hypothesis come from using upto 10 retrieved-and-masked templates. We observe that our method of masking and refilling the natural text retrieved from existing datasets allows REFILL to generate higher quality text (+8.4 BLEU) with naturally high text diversity.
+
+# 5.3 Importance of Text Diversity
+
+Retrieving and editing text from multiple existing examples enables REFILL to generate diverse text. In Figure 4, we show that increased diversity of the generated text leads to improved performance of the fine-tuned parser. We vary the number of retrieved-and-masked templates on the x-axis and plot the performance of the fine-tuned parsers on the y-axis for each group. To maintain the number of synthesized examples the same, the product of beam-samples and the number of retrieved templates is held constant. We observe that fine-tuning
+
+ | Naive Train | Robust Train |
| Schema-Match | 37.2 | 41.8 |
| Frequency | 40.2 | 43.8 |
+
+the parser on more diverse data generated using 5 retrieved templates per SQL provides consistently superior EM performance across all the four groups than using less diverse data obtained by retrieving just one or two templates per SQL. The consistent drops in EM while increasing the retrieved templates from 5 to 10 is explained by the reduction in text diversity. Using 5 retrieved templates yields a $100 - \text{SelfBLEU}$ score of 46.7, while with 10 retrieved templates $100 - \text{SelfBLEU}$ reduces to 33.8. This reduction is due to the inclusion of more similar templates as we increase their number from 5 to 10. Finally, the drop in REFILL's performance with reduced text diversity reconfirms the worse performance of SQL-to-Text baselines reported in Section 5.1 that do not offer enough text diversity.
+
+# 5.4 Design choices of Schema Translatorator
+
+In Section 2.2, we described two important design choices: (1) Method of masking schema-relevant tokens and (2) Method of training the Edit-and-Fill model for editing and refilling the masked text. We justify these design choices by comparing the quality of the generated text with each combination of these choices in Table 3. Comparing across rows (Schema-Match Vs Frequency), we observe that Frequency based masking results in 2 to 3 point improvements in BLEU compared to masking by matching schema names. Table A7 shows specific examples where the schema-match method fails to mask sufficiently. In contrast, even though the frequency-based method might over-mask it still suffices for our goal of guiding the text generation model. Comparing across columns (Naive Train Vs. Robust Train) we observe that specifically training the template filling model for being robust to the input templates also improves quality of the generated text by 3.6 to 4.6 points.
+
+# 5.5 Importance of Filtering model
+
+Cycle-consistency based filtering (Zhong et al., 2020) rejects a synthesized SQL-Text pair $(q, x)$
+
+Table 3: Analyzing the impact of design choices related to Schema Translation, by observing BLEU-4 scores of the text generated by REFILL (§ 5.4). Frequency based masking and Robust training leads to a higher quality of the generated text.
+
+ | EM | EX |
| BASE-M | 45.8 | 35.8 |
| No Filtering | 40.8 | 31.7 |
| Cycle Consistent | 29.2 | 22.5 |
| Filtering Model | 48.3 | 36.7 |
+
+Table 4: Using an independent filtering model allows us to retain more useful training examples than cycle consistent filtering, leading to better performance of the fine-tuned Text-to-SQL models (§ 5.5).
+
+if the output SQL $\hat{q}$ generated by the base Text-to-SQL parser for the input text $x$ does not match with the SQL $q$ . We argue that cycle-consistency based filtering is sub-optimal for two reasons: (i) Data Redundancy: Since the Text-to-SQL parser is already capable of generating the correct output for the retained examples, fine-tuning on these examples does not offer much improvements. (ii) Data Loss: If the base Text-to-SQL model is weak in parsing text-queries for the target database, a large portion of potentially useful training examples get filtered out due to cycle-inconsistency. In response, we train a Filtering model as described in Section 2.3. Since our filtering model is independent of the base parser, it retains many useful generated examples that might otherwise be filtered out by cycle-consistency filtering using a weak Text-to-SQL parser. In appendix Table A6, we provide instances of useful training examples that get filtered because of cycle-inconsistency, but are retained by our filtering model. In Table 4, we compare the base Text-to-SQL parser, with models fine-tuned without any filtering, with cycle-consistent filtering, and with using our filtering model. We focus on Group-4 where the base Text-to-SQL parser is significantly weaker compared to other groups, and use REFILL to synthesize data for the $30\%$ query workload. Not using any filtering, or using cycle-consistent filtering results in worse performance, while applying our filtering model offers significant improvements over the base model.
+
+# 5.6 Experiments on datasets outside Spider
+
+We further validate our method on four single-database datasets outside Spider, namely GeoQuery (Zelle and Mooney, 1996), Academic (Li and Jagadish, 2014), IMDB and Yelp (Navid Yaghmazadeh and Dillig, 2017). In Table 5, we first report the performance of our base Text-to-SQL parser and observe poor cross-database generalization with an average EM of just 9.7. We adapt
+
+| Method | Geo | Acad | IMDB | Yelp | Average |
| BASE-M | 9.8 | 2.8 | 19.3 | 7.2 | 9.7 |
| L2S | 27.9 | 14.4 | 24.8 | 19.8 | 21.7 |
| GAZP | 20.8 | 16.0 | 19.3 | 10.8 | 16.7 |
| SNOWBALL | 25.6 | 8.8 | 21.1 | 18.9 | 18.6 |
| REFILL(Ours) | 30.1 | 27.6 | 26.6 | 29.7 | 28.5 |
+
+Table 5: Evaluation on datasets outside Spider. We continue to observe that fine-tuning on data synthesized by REFILL offers superior EM performance (§ 5.6).
+
+the base parser by fine-tuning it on the synthetic datasets generated by REFILL and other baselines utilizing $30\%$ of the available SQL workload. Table 5 compares the EM accuracy of the adapted parsers. We continue to observe that fine-tuning on datasets synthesized by REFILL consistently outperforms prior SQL-to-Text based data-augmentation baselines. In appendix Table A4, we provide results for $50\%$ and $70\%$ workload settings.
+
+# 6 Conclusion
+
+We presented REFILL, a framework for generating diverse and high quality parallel data for adapting existing Text-to-SQL parsers to a target database. REFILL translates a given SQL workload into a dataset of Text-SQL pairs containing diverse text queries. To achieve higher diversity, REFILL retrieves and edits examples from existing datasets and transfers them to a target schema. Through extensive experiments across multiple databases, we demonstrate that fine-tuning Text-to-SQL parsers on datasets generated using REFILL result in more accurate adaptation to target schemas. Even with smaller SQL workloads REFILL often outperforms the SQL-to-Text generation baselines utilizing larger SQL workloads.
+
+# 7 Limitations
+
+This work focuses on synthesizing parallel data containing diverse text queries for adapting pretrained Text-to-SQL models to new databases. Thus, our current effort toward diverse text query generation using REFILL is limited to the Text-to-SQL semantic parsing task. Extending REFILL for data-augmentation in other semantic parsing or question-answering tasks is an exciting direction we hope to explore as part of future work.
+
+Our experimental set-up assumes a small workload of real SQL queries. As per Baik et al. (2019), a small workload of real SQL queries is a reasonable assumption since SQL query logs are often
+
+available for existing in-production databases that are to be supported by a Text-to-SQL service. Synthesizing realistic SQL-query workloads for newly instantiated databases is a challenging and promising direction but different from the diverse text-query generation aspect of our work.
+
+# 8 Ethical Considerations
+
+Our goal with REFILL is to synthesize parallel data for adapting Text-to-SQL parsers to new schemas. We believe that the real-world deployment of Text-to-SQL or any semantic parser trained on text generated by language models must go through a careful review of any harmful biases. Also, the intended users of any Text-to-SQL service must be made aware that the answers generated by these systems are likely to be incorrect. We do not immediately foresee any serious negative implications of the contributions that we make through this work.
+
+# 9 Acknowledgements
+
+We thank the reviewers from ACL rolling review for their insightful and quality feedback. We gratefully acknowledge support from IBM Research, specifically the IBM AI Horizon Networks-IIT Bombay initiative. Abhijeet thanks Google for supporting his research with Google PhD Fellowship.
+
+# References
+
+Christopher Baik, H. V. Jagadish, and Yunyao Li. 2019. Bridging the semantic gap with SQL query logs in natural language interfaces to databases. In 35th IEEE International Conference on Data Engineering, ICDE 2019, Macao, China, April 8-11, 2019, pages 374-385. IEEE.
+Jonathan Berant, Andrew Chou, Roy Frostig, and Percy Liang. 2013. Semantic parsing on freebase from question-answer pairs. In Proceedings of the 2013 conference on empirical methods in natural language processing, pages 1533-1544.
+Deng Cai, Yan Wang, Huayang Li, Wai Lam, and Lemao Liu. 2021. Neural machine translation with monolingual translation memory. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume I: Long Papers), pages 7307-7318. Association for Computational Linguistics.
+Ethan A Chi, Caleb Chiam, Trenton Chang, Swee Kiat Lim, Chetanya Rastogi, Alexander Iyabor, Yutong He, Hari Sowrirajan, Avanika Narayan, Jillian Tang, et al. 2021. Neural, neural everywhere: Controlled
+
+generation meets scaffolded, structured dialogue.
+Alexa Prize Proceedings.
+Rajarshi Das, Manzil Zaheer, Dung Thai, Ameya Godbole, Ethan Perez, Jay-Yoon Lee, Lizhen Tan, Lazaros Polymenakos, and Andrew McCallum. 2021. Case-based reasoning for natural language queries over knowledge bases. arXiv preprint arXiv:2104.08762.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805.
+Angela Fan, Mike Lewis, and Yann Dauphin. 2018. Hierarchical neural story generation. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 889-898, Melbourne, Australia. Association for Computational Linguistics.
+Daya Guo, Yibo Sun, Duyu Tang, Nan Duan, Jian Yin, Hong Chi, James Cao, Peng Chen, and Ming Zhou. 2018. Question generation from sql queries improves neural semantic parsing. arXiv preprint arXiv:1808.06304.
+Vivek Gupta, Akshit Shrivastava, Adithya Sagar, Armen Aghajanyan, and Denis Savenkov. 2021. Retronlu: Retrieval augmented task-oriented semantic parsing. arXiv preprint arXiv:2109.10410.
+Tatsunori B Hashimoto, Kelvin Guu, Yonatan Oren, and Percy S Liang. 2018. A retrieve-and-edit framework for predicting structured outputs. Advances in Neural Information Processing Systems, 31.
+Moshe Hazoom, Vibhor Malik, and Ben Bogin. 2021. Text-to-SQL in the wild: A naturally-occurring dataset based on stack exchange data. In Proceedings of the 1st Workshop on Natural Language Processing for Programming (NLP4Prog 2021), pages 77-87. Association for Computational Linguistics.
+Jonathan Herzig and Jonathan Berant. 2019. Don't paraphrase, detect! rapid and effective data collection for semantic parsing. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3810-3820.
+Ari Holtzman, Jan Buys, Li Du, Maxwell Forbes, and Yejin Choi. 2019. The curious case of neural text degeneration. In International Conference on Learning Representations.
+Nabil Hossain, Marjan Ghazvininejad, and Luke Zettle-moyer. 2020. Simple and effective retrieve-edit-terank text generation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 2532-2538.
+
+Vladimir Karpukhin, Barlas Oguz, Sewon Min, Patrick Lewis, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP).
+Chia-Hsuan Lee, Oleksandr Polozov, and Matthew Richardson. 2021. KaggleDBQA: Realistic evaluation of text-to-SQL parsers. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2261-2273. Association for Computational Linguistics.
+Wenqiang Lei, Weixin Wang, Zhixin Ma, Tian Gan, Wei Lu, Min-Yen Kan, and Tat-Seng Chua. 2020. Reexamining the role of schema linking in text-to-SQL. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6943-6954. Association for Computational Linguistics.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. Bart: Denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics.
+Fei Li and H. V. Jagadish. 2014. Constructing an interactive natural language interface for relational databases. Proceedings of the VLDB Endowment, 8(1):73-84.
+Juncen Li, Robin Jia, He He, and Percy Liang. 2018. Delete, retrieve, generate: a simple approach to sentiment and style transfer. In *NAACL-HLT*.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2020. Ro{bert}a: A robustly optimized {bert} pretraining approach.
+Isil Dillig Navid Yaghmazadeh, Yuepeng Wang and Thomas Dillig. 2017. SQLizer: Query synthesis from natural language. In International Conference on Object-Oriented Programming, Systems, Languages, and Applications, ACM, pages 63:1-63:26.
+Panupong Pasupat, Yuan Zhang, and Kelvin Guu. 2021. Controllable semantic parsing via retrieval augmentation. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing.
+Mateusz Pawlik and Nikolaus Augsten. 2015. Efficient computation of the tree edit distance. ACM Transactions on Database Systems (TODS), 40(1):1-40.
+Mateusz Pawlik and Nikolaus Augsten. 2016. Tree edit distance: Robust and memory-efficient. Information Systems, 56:157-173.
+
+Ohad Rubin and Jonathan Berant. 2021. Smbop: Semi-autoregressive bottom-up semantic parsing. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies.
+Torsten Scholak, Raymond Li, Dzmitry Bahdanau, Harm de Vries, and Christopher Pal. 2021a. Duorat: Towards simpler text-to-sql models. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 1313-1321.
+Torsten Scholak, Nathan Schucher, and Dzmitry Bahdanau. 2021b. Picard - parsing incrementally for constrained auto-regressive decoding from language models. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing. Association for Computational Linguistics.
+Peter Shaw, Jakob Uszkoreit, and Ashish Vaswani. 2018. Self-attention with relative position representations. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 464-468, New Orleans, Louisiana. Association for Computational Linguistics.
+Peng Shi, Patrick Ng, Zhiguo Wang, Henghui Zhu, Alexander Hanbo Li, Jun Wang, Cicero Nogueira dos Santos, and Bing Xiang. 2020. Learning contextual representations for semantic parsing with generation-augmented pre-training. arXiv preprint arXiv:2012.10309.
+Chang Shu, Yusen Zhang, Xiangyu Dong, Peng Shi, Tao Yu, and Rui Zhang. 2021. Logic-consistency text generation from semantic parses. In *Findings of the Association for Computational Linguistics: ACLIJCNLP* 2021, pages 4414-4426.
+Alane Suhr, Ming-Wei Chang, Peter Shaw, and Kenton Lee. 2020. Exploring unexplored generalization challenges for cross-database semantic parsing. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics.
+Bailin Wang, Richard Shin, Xiaodong Liu, Oleksandr Polozov, and Matthew Richardson. 2020. Rat-sql: Relation-aware schema encoding and linking for text-to-sql parsers. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7567-7578.
+Bailin Wang, Wenpeng Yin, Xi Victoria Lin, and Caiming Xiong. 2021. Learning to synthesize data for semantic parsing. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2760-2766.
+Yushi Wang, Jonathan Berant, and Percy Liang. 2015. Building a semantic parser overnight. In Proceedings of the 53rd Annual Meeting of the Association for
+
+Computational Linguistics and the 7th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 1332-1342, Beijing, China. Association for Computational Linguistics.
+Tomer Wolfson, Jonathan Berant, and Daniel Deutch. 2021. Weakly supervised mapping of natural language to sql through question decomposition. ArXiv, abs/2112.06311.
+Peng Xu, Dhruv Kumar, Wei Yang, Wenjie Zi, Keyi Tang, Chenyang Huang, Jackie Chi Kit Cheung, Simon J.D. Prince, and Yanshuai Cao. 2021. Optimizing deeper transformers on small datasets. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2089-2102. Association for Computational Linguistics.
+Wei Yang, Peng Xu, and Yanshuai Cao. 2021. Hierarchical neural data synthesis for semantic parsing. arXiv preprint arXiv:2112.02212.
+Tao Yu, Rui Zhang, Kai Yang, Michihiro Yasunaga, Dongxu Wang, Zifan Li, James Ma, Irene Li, Qingning Yao, Shanelle Roman, et al. 2018. Spider: A large-scale human-labeled dataset for complex and cross-domain semantic parsing and text-to-sql task. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing.
+John M. Zelle and Raymond J. Mooney. 1996. Learning to parse database queries using inductive logic programming. In Proceedings of the Thirteenth National Conference on Artificial Intelligence - Volume 2, pages 1050-1055.
+Luke S. Zettlemoyer and Michael Collins. 2005. Learning to map sentences to logical form: Structured classification with probabilistic categorial grammars. In Proceedings of the Twenty-First Conference on Uncertainty in Artificial Intelligence, UAI'05, page 658-666, Arlington, Virginia, USA. AUAI Press.
+Ao Zhang, Kun Wu, Lijie Wang, Zhenghua Li, Xinyan Xiao, Hua Wu, Min Zhang, and Haifeng Wang. 2021. Data augmentation with hierarchical sql-to-question generation for cross-domain text-to-sql parsing. arXiv preprint arXiv:2103.02227.
+Victor Zhong, Mike Lewis, Sida I. Wang, and Luke Zettlemoyer. 2020. Grounded adaptation for zero-shot executable semantic parsing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6869-6882. Association for Computational Linguistics.
+Yaoming Zhu, Sidi Lu, Lei Zheng, Jiaxian Guo, Weinan Zhang, Jun Wang, and Yong Yu. 2018. Texygen: A benchmarking platform for text generation models. In The 41st International ACM SIGIR Conference on Research & Development in Information Retrieval, pages 1097-1100.
+
+# A Appendix
+
+# A.1 Dataset Details
+
+| Group | Number of queries by hardness |
| easy | medium | hard | extra | total examples | unique SQLs |
| Group 1 | 24 | 60 | 25 | 6 | 115 | 62 |
| • concert_singer | 4 | 24 | 13 | 4 | 45 | 26 |
| • singer | 6 | 18 | 6 | 0 | 30 | 16 |
| • orchestra | 14 | 18 | 6 | 2 | 40 | 20 |
| Group 2 | 14 | 58 | 16 | 36 | 124 | 65 |
| • dog_kennels | 10 | 36 | 10 | 26 | 82 | 42 |
| • pets_1 | 4 | 22 | 6 | 10 | 42 | 23 |
| Group 3 | 46 | 60 | 32 | 26 | 164 | 84 |
| • students_transcripts_tracking | 26 | 24 | 8 | 20 | 78 | 41 |
| • course_teach | 8 | 14 | 8 | 0 | 30 | 15 |
| • network_1 | 12 | 22 | 16 | 6 | 56 | 28 |
| Group 4 | 24 | 46 | 20 | 60 | 120 | 65 |
| • world_1 | 24 | 46 | 20 | 60 | 120 | 65 |
+
+Table A1: Number of schemas and statistics of query workload for each group. Related schemas were grouped together in order to obtain larger evaluation sets per group.
+
+| Dataset | Number of queries by hardness |
| easy | medium | hard | extra | total examples | unique SQLs |
| Geoquery (Geo) | 224 | 32 | 220 | 77 | 553 | 210 |
| Academic (Acad) | 20 | 29 | 25 | 107 | 181 | 176 |
| IMDB | 23 | 12 | 48 | 26 | 109 | 75 |
| Yelp | 13 | 29 | 25 | 24 | 111 | 98 |
+
+# A.2 Results in low or medium SQL workload setting
+
+Table A2: Statistics of queries in additional (non-spider) datasets. We utilize the pre-processed versions of these datasets provided by Yu et al. (2018).
+
+ | Group 1 | Group 2 | Group 3 | Group 4 | Average |
| Method | EM | EX | EM | EX | EM | EX | EM | EX | EM | EX |
| Results with 30% SQL workload |
| BASE-M | 80.9 | 84.3 | 64.8 | 67.2 | 64.0 | 65.9 | 45.8 | 35.8 | 63.8 | 63.3 |
| L2S | 82.6 | 84.3 | 60.5 | 65.3 | 61.6 | 63.4 | 26.7 | 26.7 | 57.8 | 59.9 |
| GAZP | 83.5 | 84.3 | 61.3 | 64.5 | 66.5 | 67.1 | 45.8 | 37.5 | 64.3 | 63.3 |
| SNOWBALL | 80.0 | 83.5 | 59.7 | 63.7 | 67.7 | 68.3 | 39.2 | 32.5 | 61.6 | 62.0 |
| REFILL | 86.1 | 86.1 | 65.6 | 65.6 | 68.3 | 67.1 | 48.3 | 36.7 | 67.1 | 63.8 |
| Results with 50% SQL workload |
| BASE-M | 80.9 | 84.3 | 64.8 | 67.2 | 64.0 | 65.9 | 45.8 | 35.8 | 63.8 | 63.3 |
| L2S | 89.6 | 88.7 | 66.1 | 68.5 | 57.9 | 58.5 | 41.7 | 35.8 | 63.8 | 62.8 |
| GAZP | 87.8 | 87.0 | 58.9 | 63.7 | 65.9 | 68.9 | 45.0 | 35.0 | 64.4 | 63.6 |
| SNOWBALL | 83.5 | 85.2 | 55.6 | 66.1 | 65.2 | 66.5 | 40.0 | 32.5 | 61.1 | 62.6 |
| REFILL | 88.7 | 91.3 | 67.2 | 69.7 | 70.7 | 67.1 | 45.8 | 38.3 | 68.1 | 66.6 |
| Results with 70% SQL workload |
| BASE-M | 80.9 | 84.3 | 64.8 | 67.2 | 64.0 | 65.9 | 45.8 | 35.8 | 63.8 | 63.3 |
| L2S | 88.7 | 87.8 | 61.3 | 62.1 | 62.8 | 61.0 | 42.5 | 35.0 | 63.8 | 61.4 |
| GAZP | 85.2 | 85.2 | 58.9 | 66.9 | 70.1 | 60.5 | 52.5 | 40.8 | 66.6 | 63.3 |
| SNOWBALL | 85.2 | 87.8 | 59.7 | 60.5 | 64.0 | 65.9 | 44.2 | 38.3 | 63.2 | 63.1 |
| REFILL | 88.7 | 87.0 | 69.7 | 73.8 | 73.2 | 70.1 | 55.8 | 45.0 | 71.8 | 68.9 |
+
+Table A3: Evaluation on four groups of schemas held out from Spider's dev set, for varying sizes of query workload $\{30\%$ $50\%$ $70\%$ } used for SQL-to-Text translation.
+
+| Method | Geo | Acad | IMDB | Yelp | Average |
| Results with 30% SQL workload |
| BASE-M | 9.8 | 2.8 | 19.3 | 7.2 | 9.7 |
| L2S | 27.9 | 14.4 | 24.8 | 19.8 | 21.7 |
| GAZP | 20.8 | 16.0 | 19.3 | 10.8 | 16.7 |
| SNOWBALL | 25.6 | 8.8 | 21.1 | 18.9 | 18.6 |
| REFILL | 30.1 | 27.6 | 26.6 | 29.7 | 28.5 |
| Results with 50% SQL workload |
| BASE-M | 9.8 | 2.8 | 19.3 | 7.2 | 9.7 |
| L2S | 33.6 | 20.4 | 25.7 | 18.0 | 24.4 |
| GAZP | 21.5 | 11.1 | 23.9 | 14.4 | 17.7 |
| SNOWBALL | 26.0 | 24.3 | 18.3 | 27.9 | 24.1 |
| REFILL | 27.9 | 37.6 | 28.4 | 35.1 | 32.2 |
| Results with 70% SQL workload |
| BASE-M | 9.8 | 2.8 | 19.3 | 7.2 | 9.7 |
| L2S | 33.9 | 19.3 | 29.4 | 23.4 | 26.5 |
| GAZP | 25.4 | 13.8 | 22.0 | 15.3 | 19.1 |
| SNOWBALL | 30.9 | 20.9 | 20.1 | 35.1 | 26.7 |
| REFILL | 32.8 | 37.0 | 33.0 | 35.1 | 34.4 |
+
+Table A4: EM evaluation on four additional datasets outside Spider, for varying sizes of query workload $\{30\%, 50\%, 70\% \}$ used for SQL-to-Text translation. Since the contents of Acad, IMDB, and Yelp databases were not publicly accessible to us, we are unable to report EX results on these databases. EX results for GeoQuery appear in Table A5.
+
+| Method | Fraction of SQL workload |
| 30% | 50% | 70% |
| BASE-M | 27.2 | 27.2 | 27.2 |
| L2S | 30.4 | 35.1 | 37.5 |
| GAZP | 20.8 | 22.9 | 29.2 |
| SNOWBALL | 28.7 | 28.5 | 33.8 |
| REFILL | 33.0 | 34.2 | 38.9 |
+
+# A.3 Examples rejected by cycle-consistency but retained by our filtering model
+
+Table A5: EX accuracy evaluation on GeoQuery dataset, for varying sizes of query workload $\{30\%$ $50\% ,70\% \}$
+
+| Generated text
+Gold SQL
+Predicted SQL | How many countries are governed by Islamic Emirate?
+SELECT count(*) FROM country WHERE GovernmentForm = 'Islamic Emirate'
+SELECT COUNT(*) FROM country WHERE country.code NOT IN (SELECT countrylanguage countrycode FROM countrylanguage) |
| Generated text
+Gold SQL
+Predicted SQL | What is the number of languages that are official in Australia?
+SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = 'Australia' AND IsOfficial = 'T'
+SELECT COUNT(*) FROM countrylanguage JOIN country ON countrylanguage countrycode = country.code WHERE country.name = 'Australia' |
| Generated text
+Gold SQL
+Predicted SQL | How many countries have both "Karen" and "Mandarin Chinese" languages?
+SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = 'Karen' INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = 'Mandarin Chinese')
+SELECT COUNT(*) FROM countrylanguage JOIN country ON countrylanguage countrycode = country.code WHERE country language.state = 'Karen' |
| Generated text
+Gold SQL
+Predicted SQL | Find the language of the country that has the head of state Salahuddin Abdul Aziz Shah Alhaj and is official.
+SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = 'Salahuddin Abdul Aziz Shah Alhaj' AND T2.IsOfficial = 'T'
+SELECT countrylanguage-language FROM countrylanguage JOIN country ON countrylanguage countrycode = country.code WHERE country.headstate = 'Salahuddin Abdul Aziz Shah Alhaj' |
| Generated text
+Gold SQL
+Predicted SQL | What are the names of countries with surface area greater than the smallest area of any country in Antarctica?
+SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = 'Antarctica')
+SELECT country.name FROM country WHERE country.surfacearea > (SELECT MAX(country.surfacearea) FROM country WHERE country.continent = 'Antarctica') |
+
+Table A6: Consistent SQL-Text pairs rejected by cycle-consistency but retained by our filtering model. Predicted SQL is the output of the Text-to-SQL model used for checking cycle consistency, and does not match the gold SQL often due to minor errors.
+
+# A.4 Examples of masking
+
+| SQL
+Reference | SELECT T1.template_type_code, count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code [Schema Name: Document Template Management]Show all template type codes and the number of documents using each type. |
| Retrieved SQL
+Retrieved Text | T1.FacID, count(*) FROM Faculty AS T1 JOIN Student AS T2 ON T1.FacID = T2.advisor GROUP BY T1.FacID [Schema Name: Faculty Student Activity]Show the faculty id of each faculty member, along with the number of students he or she advises. |
| Sch-match
+Mask
+Filled Text | Show the MASK of each MASK member, along with the number of MASK he or she advises. |
| Show the type code of each template member, along with the number of documents he or she advises. |
| Freq Mask
+Filled Text | Show the MASK of each MASK, MASK with the number of MASK he or she MASK. |
| Show the code of each template type, together with the number of documents corresponding to it. |
| SQL
+Reference | SELECT T2.name, T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1 [Schema Name: Concert Singer]Show the stadium name and capacity with most number of concerts in year 2014 or after. |
| Retrieved SQL
+Retrieved Text | SELECT T2.name, T1.team_id_winner FROM postseason AS T1 JOIN team AS T2 ON T1.team_id_winner = T2.team_id_br WHERE T1.year = 2008 GROUP BY T1.team_id_winner ORDER BY count(*) DESC LIMIT 1 [Schema Name: Baseball 1]What are the name and id of the team with the most victories in 2008 postseason? |
| Sch-match
+Mask
+Filled Text | What are the MASK and MASK of the MASK with the most victories in MASK |
| What are the name and capacity of the stadium with the most victories in year 2014? |
| Freq Mask
+Filled Text | What are the MASK and MASK of the MASK with the most MASK in MASK |
| What are the name and capacity of the stadium with the most concerts in 2014? |
+
+Table A7: Masking the text based on string matches Vs. our method of frequency based masking. Schema-relevant words like 'victories', 'members', 'advises' that do not have a sufficient string match with any of the table or column names of their schema, get left out when using string-match based matches. Thus failing to mask the words in the original schema might lead to copying of the word in the target schema, thus making the generated text semantically inconsistent. Words in blue are schema relevant words for the target database and should appear in the generated output.
+
+# A.5 Hyperparameters
+
+Our Edit and Fill model (139.2M parameters) is based on a pretrained BART-BASE (Lewis et al., 2020) model. We fine-tune this model for 100 epochs with learning rate of $3 \times 10^{-5}$ , weight decay of 0.01 and batch size of 64. The pretrained model is obtained from HuggingFace3.
+
+The proposed binary classifier (124.6M params) is pretrained ROBERTA-BASE (Liu et al., 2020) (obtained from HuggingFace4) fine-tuned for 100 epochs on our data with learning rate $10^{-5}$ , weight decay 0.01 and batch size 16 for 100 epochs.
+
+For SMBOP experiments, we use a smaller SMBOP model with 4 RAT layers and ROBERTABASE (Liu et al., 2020) encoder as a baseline. The number of parameters in this model is $132.9\mathrm{M}$ . All the adaptation experiments use learning rate of $5 \times 10^{-6}$ , learning rate of language model of $3 \times 10^{-6}$ and batch size of 8. All the models were trained for 100 epochs.
+
+All the experiments were performed on a single NVIDIA RTX 3060 GPU. Training times for the Edit-and-Fill model and binary classifiers were $\approx$ 4.5 hrs and $\approx$ 6.5 hrs respectively. Each of the fine-tuning experiment took $3 - 4$ hrs to complete.
+
+# A.6 Cost function for Tree Edit Distance
+
+| Group | Value | Cost |
| Equal | Equal | 0 |
| Equal | Unequal | 0.5 |
| Unequal | Equal | 0 |
| Unequal | Unequal | 1 |
+
+Table A8: Cost function of nodes $n_1$ and $n_2$ based on their groups and value.
+
+| Group | SQL elements |
| Aggregation | MAX, MIN, AVG, COUNT, SUM |
| Order | ORDERBYASC, ORDERBY_DESC |
| Boolean | OR, AND |
| Set | UNION, INTERSECT, EXCEPT |
| Leaf | VAL_LIST, VALUE, LITERAL, TABLE |
| Similarity | LIKE, IN, NOT_IN |
| Comparison | >, ≥, <, ≤, =, ≠ |
+
+Table A9: Group definitions for TED calculation.
+
+We use APTED library (Pawlik and Augsten, 2015, 2016) to compute TED between 2 parsed
+
+SQL trees. For every node in the tree, a group is assigned according to table A9. Then the cost for various combinations of node groups and node values is described in table A8. If either of the nodes does not belong to any of the groups in table A9, their groups are considered to be "unequal" and cost will be assigned based on their values.
+
+# A.7 Examples of TED neighbours
+
+
+
+
+(a) SELECT count(*) FROM head WHERE age > 56
+(b) SELECT count(*) FROM game WHERE season > 2007
+
+
+Figure 5: Example of tree pair with $\mathrm{TED} = 0$
+
+
+(a) SELECT count(*) FROM county_public_safety
+(b) SELECT avg(Gross_in_dollar) FROM film
+Figure 6: Example of tree pair with non-zero $(=0.125)$ TED
\ No newline at end of file
diff --git a/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/images.zip b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..fd6097c67cfed2ecf8709ab0387f75a5bade5125
--- /dev/null
+++ b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a796f50ad6df6d2ac5af803895d0bb38eb03c95cbf96be0440c9f80ea5122633
+size 1177252
diff --git a/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/layout.json b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..c743921f15c56fd0e7d0f62c4c397886d5bf19d3
--- /dev/null
+++ b/diverseparalleldatasynthesisforcrossdatabaseadaptationoftexttosqlparsers/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:be6b8d5bec3cd865ae43196b04bfd4e493a8eb587783c3b7ace4682082071e2d
+size 549392
diff --git a/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_content_list.json b/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..c8907a20b92886feab5c798f5c83b84c72be1420
--- /dev/null
+++ b/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c2e8fb95b1f0f2bc99b8c209ddace060271bfeee2fbe22429041b4d426aa0692
+size 43306
diff --git a/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_model.json b/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0db755191fe10509387b6ebb5d385668b15f9590
--- /dev/null
+++ b/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:349ec057e32f58244b6e94862f64f5afd647e22ffad27361ecd670c8890aee10
+size 52649
diff --git a/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_origin.pdf b/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c74d4ec68ef4f1ce6df4a0cf14d06827131468c3
--- /dev/null
+++ b/dochildrentextsholdthekeytocommonsenseknowledge/e173816b-3934-4144-a018-387f62ca58ec_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d25468a27d68ed651ad85b18e13928b1c14e08d5feb42464a015f28523c8684f
+size 245477
diff --git a/dochildrentextsholdthekeytocommonsenseknowledge/full.md b/dochildrentextsholdthekeytocommonsenseknowledge/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..1f73e05867dca2c566ea93a984f3443b9f070e55
--- /dev/null
+++ b/dochildrentextsholdthekeytocommonsenseknowledge/full.md
@@ -0,0 +1,184 @@
+# Do Children Texts Hold The Key To Commonsense Knowledge?
+
+Julien Romero
+
+Télécom SudParis
+
+jromero@telecom-sudparis.eu
+
+Simon Razniewski
+
+Max Planck Institute for Informatics
+
+srazniew@mpi-inf.mpg.de
+
+# Abstract
+
+Compiling comprehensive repositories of commonsense knowledge is a long-standing problem in AI. Many concerns revolve around the issue of reporting bias, i.e., that frequency in text sources is not a good proxy for relevance or truth. This paper explores whether children's texts hold the key to commonsense knowledge compilation, based on the hypothesis that such content makes fewer assumptions on the reader's knowledge, and therefore spells out commonsense more explicitly. An analysis with several corpora shows that children's texts indeed contain much more, and more typical commonsense assertions. Moreover, experiments show that this advantage can be leveraged in popular language-model-based commonsense knowledge extraction settings, where task-unspecific fine-tuning on small amounts of children texts (childBERT) already yields significant improvements. This provides a refreshing perspective different from the common trend of deriving progress from ever larger models and corpora.
+
+# 1 Introduction
+
+Compiling commonsense knowledge (CSK) is a long-standing problem in AI (Lenat, 1995). Automated text-extraction-based approaches to CSK compilation, like Knext (Gordon et al., 2010), TupleKB (Dalvi Mishra et al., 2017), Quasimodo (Romero et al., 2019), COMET (Hwang et al., 2021) or Ascent (Nguyen et al., 2021) typically struggle with reporting bias (Gordon and Van Durme, 2013; Mehrabi et al., 2021), in particular an under-reporting of basic commonsense assertions. This is a crux of commonsense: If knowledge is assumed to be commonplace, such as that rain is wet or cars have wheels, there is little need to utter it explicitly. In contrast, statements that contradict commonsense are more frequently reported, leading to inappropriate images of the real world, e.g., that fires are more often cold than hot (e.g., 238 vs.
+
+173 literal occurrences in the English Wikipedia).
+
+Children's material may partially counter this bias: As children's knowledge is still growing, seemingly obvious assertions may still be frequently expressed explicitly in such material. Note that this is not a binary question of whether some knowledge is expressed or not, but more a ranking problem: Prominent CSK repositories often do not struggle to recall relevant statements (e.g., Ascent (Nguyen et al., 2021) contains 2800 assertions for "elephant"), but struggle to rank them properly. This is especially true for language-model based approaches of CSK compilation (Hwang et al., 2021; West et al., 2022), which by design can assign every token in the vocabulary a probability, but should do so in sensible order.
+
+This paper investigates (i) whether children's texts are a promising source for CSK and (ii) whether small corpora can still boost knowledge extraction from large language models. Specifically, we analyze the density and typicality of CSK assertions in children's text corpora and show how fine-tuning existing language models on them can improve CSK compilation. Data and models, including a childBERT variant, can be found at https://www.mpi-inf.mpg.de/children-texts-for-commonsense.
+
+# 2 Background
+
+Prominent manual efforts towards CSK compilation include ConceptNet (Speer et al., 2017), Atomic (Sap et al., 2019), and the integrated CSKG (Ilievski et al., 2021). Prominent text extraction projects are Knext (Gordon et al., 2010), TupleKB (Dalvi Mishra et al., 2017), Quasimodo (Romero et al., 2019) and Ascent (Nguyen et al., 2022). Each carefully selects extraction corpora, like Wikipedia texts, user query logs, or targeted web search, to minimize extraction noise and maximize salience. Nonetheless, all struggle with extracting very basic CSK that is generally deemed
+
+too obvious to state explicitly. The utilized corpora are also small compared to what is typically used in language model pre-training. Therefore, pre-trained language models (PTLMs) have been employed directly for CSK extraction in a setting called prompting/probing (cf. the LAMA benchmark) (Petroni et al., 2019), where the BERT LM showed promising results in predicting Concept-Net assertions. They can also be employed with supervision, like in the COMET and the Atomic $^{10x}$ system (Hwang et al., 2021; West et al., 2022). However, both PTLM-paradigms are grounded in frequencies observed in the original text corpora used for LM training, which are again subject to reporting bias.
+
+# 3 Children Text Corpora
+
+For understanding the nature of different text corpora, we rely on the Flesch Reading-ease score (FRE) (Flesch, 1979) that is based on the number of syllables, words, and sentences.
+
+It generally ranges between 0 and 100, with 0-30 being considered difficult to read, 60-70 assumed standard, and above 80 easy.
+
+We investigate three children text corpora:
+
+1. Children Book Test (CBT) The CBT dataset (Hill et al., 2016) contains 108 children books such as Alice's Adventures in Wonderland extracted from the Gutenberg Project. It targets children around 12-14 years old and is about 30 MB in total.
+2. C4-easy C4 (Raffel et al., 2020) is a cleaned version of Common Crawl's web crawl corpus that was used to train the T5 language model. It is approximately 305 GB in size. We derive C4-easy by restricting the corpus to documents with an FRE greater than 80, retaining 40.827.011 documents, which are $11\%$ of C4.
+3. InfantBooks We newly introduce the InfantBooks dataset, composed of 496 books targeted at kids from 1-6 years. It is based on Ebooks from websites like freekidsbooks.org, monkeypen.com and kidsworldfun.com, which we collected, transcribed, and cleaned. The final dataset consists of 496 books with 2 MB of text.
+
+As a baseline, and to rule out that observed improvements stem only from general training on
+
+more data, we also compare with employing the whole C4 corpus. In Table 1, we compare the corpora according to average document length, vocabulary size, and readability. In Table 2, we make the same comparison with the number of distinct words, the number of frequent words (with a relative frequency greater than $0.01\%$ ), and the cumulative frequency of the top 1000 words.
+
+| Corpus | Avg. doc. len. | Vocab. size | Readability (FRE) |
| C4 | 411 words | 151k | 60 (Standard) |
| CBT | 57k words | 63k | 62 (Standard) |
| C4-easy | 317 words | 106k | 86 (Easy) |
| InfantBooks | 659 words | 18k | 91 (Very Easy) |
+
+Table 1: Text corpora considered for pretraining/finetuning, sorted by FRE.
+
+| Corpus | Dist. Words | freq. words | Cumul. freq. top 1k |
| C4 | 8M | 994 | 68% |
| CBT | 5M | 874 | 82% |
| C4-easy | 8M | 908 | 75% |
| InfantBooks | 5M | 1031 | 82% |
+
+Table 2: Text corpora statistics.
+
+# 4 Analysis
+
+CSK Density. Although CBT and InfantBooks are too small for comprehensive text extraction, it is informative to see how dense CSK assertions are stated in them, i.e., the relative frequencies of CSK assertions per text.
+
+We used the CSLB (Devereux et al., 2014) dataset, a large crowdsourced set of basic CSK assertions, like alligator: is scary / is long / is green. We focused on the top 4,245 properties for 638 subjects stated at least five times. For each corpus, we computed the relative frequencies with which these statements appear (w/ lemmatization).
+
+Table 3 shows the results. As one can see, InfantBooks has the highest relative density of CSK assertions, 3x as many as C4 per sentence, 5x more per word.
+
+To further explore the relation of text simplicity and CSK density, we grouped C4 documents into buckets based on their FRE. For a sample of 10k documents per bucket, Figure 1 reports the per-word frequencies of CSK assertions, considering all spotted CSK assertions (blue) or only distinct ones (red). The results are shown in Figure 1. As one can see, CSK density increases significantly with easier readability, and only the most simple documents suffer from a lack of diversity (decrease in blue line).
+
+
+Figure 1: Relative CSK assertion frequency (per word) by C4 bucket of different readability (FRE).
+
+| Dataset | Mean freq./sent. | Mean freq./word |
| C4 (sample) | 9.99e-3 | 4.86e-4 |
| CBT | 1.03e-2 | 4.94e-4 |
| C4-easy (sample) | 1.10e-2 | 7.65e-4 |
| InfantBooks | 3.07e-2 | 2.56e-3 |
+
+CSK Typicality. Human associations and CSK resources contain a mix of salient but atypical assertions (lion attacks human), and typical but basic assertions (lion drinks water) (Chalier et al., 2020). To evaluate whether children's texts can help extract more typical assertions, we use PTLM prompting. Prompting is a standard procedure for extracting knowledge from masked-LMs (Liu et al., 2022). Given a relation of interest, e.g., "LocatedAt", one uses a generic textual pattern like " can be found at [MASK]", to obtain suggestions from an LM.
+
+We used the BERT-large model $^2$ , and fine-tuned it on each of the four corpora, up to a maximum of 48 hours (using one NVIDIA Quadro RTX 8000). We used a learning rate of $1e^{-5}$ .
+
+We then used 1,600 CSK triples from Quasimodo (Romero et al., 2019), human-rated as very typical (score [1,2]), or typical (score [2,3]), or plausible (score [3,4]) as targets. For each of these triples, we masked the objects, and used the fine-tuned BERT model to predict token likelihoods for the mask.
+
+In Table 4 we report the mean reciprocal rank (MRR) for each group. Pre-training on children corpora has a slight edge over the vanilla BERT model and a significant edge over pre-training on the general C4 corpus.
+
+Table 3: CSK density in different corpora.
+
+| BERT-finetuning | Very typical | Typical | Plausible |
| None | 0.361 | 0.200 | 0.153 |
| InfantBooks | 0.364 | 0.198 | 0.152 |
| CBT | 0.364 | 0.205 | 0.148 |
| C4-easy | 0.326 | 0.204 | 0.156 |
| C4 | 0.312 | 0.195 | 0.155 |
+
+Table 4: MRR of typical statements.
+
+# 5 CSK Generation
+
+We next evaluate whether pre-training on children texts helps in two PTLM-based methods for CSK generation: (i) via prompting from a LM pretrained on those corpora (LAMA method) (Petroni et al., 2019), and (ii) via supervised learning, based on a LM fine-tuned on those corpora (COMET method) (Hwang et al., 2021).
+
+Unsupervised Generation via PTLM Prompting. The LAMA probe is based on prompting-based (CSK) generation. Originally, it used ConceptNet (Speer et al., 2017) together with the Open Mind Common Sense (Singh et al., 2002) (OMCS), which was used to construct ConceptNet and contains 20k items. ConceptNet contains triplets, and each triplet is associated with a sentence in OMCS. When a triplet has an object composed of one token, then the object is masked in the original OMCS sentence. The problem with this approach is that OMCS sentences are unnatural template-based phrases, not suited for LM completion. For example, in the LAMA probe, we find that "One of the things you do when you are alive is [MASK]." (think), "Something that might happen while analyzing something is [MASK]." (education) or "Similarity between a trash container and a clock: both can be found in a [MASK]." (school).
+
+We therefore decided to add new commonsense-related datasets, to better evaluate how much commonsense knowledge a language model contains. First, we used CSLB (Devereux et al., 2014) that contains $20\mathrm{k}$ basic properties about given subjects. The sentences are generally simpler than in OMCS. Second, we exploit $2.4\mathrm{k}$ human-generated CSK sentences produced as evaluation data in the Quasimodo project (Romero et al., 2019; Romero and Razniewski, 2020). Finally, we exploited sentence sources of top statements web-extracted for the same KB, based on QA forums and search engine query logs. We here either masked the object or the predicate for all the sentences. Table 5 shows a sample of probes for each dataset. We make public (link above) the new probes and a sample of
+
+generations.
+
+| Dataset | Sample Probes |
| ConceptNet | Something that might happen while fiddling is [MASK] a string. breaking Geriatrics is a type of [MASK]. nursing A person doesn’t want to be [MASK]. crippled |
| CSLB | Dolphin is an [MASK]. animal Mug hold [MASK]. tea Cat chase [MASK]. strings |
| Q’modo-eval | Salmons are [MASK]. fish Ducks [MASK] in water. live Barbers cut our [MASK]. hair |
| Quasimodo | Pencils are made of [MASK]. graphite Bumblebees collect [MASK]. pollen Rockets need fuel in [MASK]. space |
+
+Table 5: Sample prompts for LAMA-style evaluation.
+
+We used the BERT-large model pretrained as is, or pre-trained on any of the children's text corpora, as in the previous section, to generate predictions for each of the masked probes. The resulting performances are reported in Table 6. We report MRR and Hits@k for the PTLM's predictions in each case. While there are no improvements on the idiosyncratic ConceptNet data, pre-training on InfantBooks performs consistently at the top in the three other settings. CBT also shows consistent gains, while the broader C4-easy helps little. Examples are shown in Table 7.
+
+Supervised PTLM-based Generation. Beyond prompting, an established technique to obtain CSK assertions is supervised learning based on LMs. We adapted the COMET-ATOMIC-2020 system (Hwang et al., 2021), which in turn is based on the GPT-2 LM. Like the previous prompt-based extraction, the core component is a pre-trained LM, which we can fine-tune on different text corpora. Compared to the previous method, however, a relation-specific step of supervised learning is added, in which the model is trained to generate objects for given subject-relation pairs.
+
+We used ConceptNet for training and testing $^3$ and report precision and recall@k. The training and testing sets contain 186k and 23k triples.
+
+The results are shown in Table 8. Due to the additional supervision on KB statements, differences are much smaller than in the previous setting. Nonetheless, we observe a consistent edge for fine-tuning on InfantBooks. To confirm this,
+
+we employed an additional human evaluation. For each subject-predicate pair in the test dataset, we computed the top-1 prediction for each model. For 300 examples where the predictions differed, we asked human annotators for their pairwise preference in terms of correctness. The results are shown in Table 9. InfantBooks again outperforms the vanilla BERT model and the more general C4-easy. Table 10 shows examples of generations.
+
+We also performed an absolute evaluation of 600 pairs: For each pair, we asked a human evaluator to score the similarity between 1 (the worst) and 5 (the best). We obtained an average typicality of 2.57 for COMET-InfantBooks and 2.53 for COMET-C4. This is consistent with the results of the relative analysis - the gains in the KB-supervised settings are small, but consistently observable both in absolute and relative terms.
+
+# 6 Conclusion
+
+Our results positively confirm both starting questions: Dedicated children corpora contain more typical CSK assertions, and even small quality text corpora can boost the performance of large LMs for CSK extraction, especially concerning basic CSK assertions.
+
+While the overall gains are still modest, these results affirm the role of data selection in commonsense knowledge compilation. Along with the exploitation of even stronger pre-trained language models, the quest for relevant text corpora thus continues.
+
+# 7 Limitations
+
+The following are notable limitations of our study, as well as of our approach.
+
+Size of InfantBooks corpus A clear limitation of our newly presented InfantBooks corpus is its small size. Even if we were to ramp up the number of books (496 currently), text length in such books is inherently small, so this corpus will size-wise never compete with popular general web corpora. We alleviated this problem by a solution involving fine-tuning LMs trained on general corpora, but it remains that the presented corpus is not suitable for direct extraction tasks.
+
+Flesch reading-ease vs. children content To further alleviate the size problem of the Infant-Books corpus, we also introduced the C4-easy corpus, based on filtering via the Flesch reading-ease
+
+| Corpus | ConceptNet | CSLB | Quasimodo-eval | Quasimodo |
| MRR | Hits@1 | Hits@10 | MRR | Hits@1 | Hits@10 | MRR | Hits@1 | Hits@10 | MRR | Hits@1 | Hits@10 |
| None | 0.270* | 0.188* | 0.429 | 0.149 | 0.0911 | 0.259 | 0.433 | 0.327 | 0.633 | 0.212 | 0.138 | 0.357 |
| InfantBooks | 0.260 | 0.177 | 0.421 | 0.174* | 0.106† | 0.317* | 0.471† | 0.374† | 0.652 | 0.231* | 0.146† | 0.404* |
| CBT | 0.259 | 0.177 | 0.414 | 0.163 | 0.100 | 0.285 | 0.457 | 0.355 | 0.642 | 0.223 | 0.142 | 0.387 |
| C4-easy | 0.243 | 0.165 | 0.395 | 0.150 | 0.0877 | 0.274 | 0.390 | 0.288 | 0.586 | 0.200 | 0.123 | 0.356 |
| C4 | 0.229 | 0.155 | 0.372 | 0.137 | 0.0777 | 0.251 | 0.457 | 0.356 | 0.637 | 0.182 | 0.111 | 0.325 |
+
+Table 6: LAMA-style evaluation of CSK generation. (*: significantly better than all others with p-value<0.05, †: significantly better than having no corpus with p-value<0.05)
+
+| Masked Sentence | BERT-large | BERT-large finetuned on Infant-Books |
| Bears [MASK]. | Club, ##kin, ##eed,##k,!, vs, ##ki, ##ville, Town, ##t | bite, eat, walk, sing, do, ##t, dance, say, sleep, kiss |
| Surgeons treat [MASK]. | patients, them, children, wounds, animals, prisoners, victims, people, him, dogs | children, pain, wounds, cold, dogs, burns, birds, patients, babies, cats |
| Chefs know a lot about [MASK]. | cooking, food, it, that, them, wine, this, you, fish, me | cooking, food, fish, wine, baking, meat, recipes, it, dishes, them |
| Researchers study [MASK]. | it, them, this, children, women, him, animals, evolution, her, birds | animals, art, birds, chemistry, in-ssects, it, music, snakes, science, them |
+
+Table 7: Sample Top Predictions (## means the letters are concatenated to the previous word). In bold good predictions that did not appear in the other method.
+
+| Corpus | P@5 | P@10 | R@5 | R@10 |
| None | 3.76% | 2.51% | 15.4% | 20.0% |
| C4-easy | 3.78% | 2.48% | 15.5% | 19.9% |
| C4 | 3.73% | 2.47% | 15.3% | 19.7% |
| CBT | 3.74% | 2.48% | 15.4% | 19.9% |
| InfantBooks | 3.81% | 2.52% | 15.6% | 20.1% |
+
+Table 8: Supervised COMET-style generation of CSK.
+
+| InfantBooks Best | BERT Best | Same |
| 13% | 10% | 77% |
| InfantBooks Best | C4 Easy Best | Same |
| 22% | 15% | 63% |
+
+score (FRE). However, good readability is more of a necessary than a sufficient condition for inferring that content is intended for children, in other words, if there were not the results on InfantBooks, the positive results on C4-easy in isolation only proved a related hypothesis ("easier texts are the key to commonsense"), not the original one ("children texts are the key").
+
+Dataset long-term availability InfantBooks contains copyrighted content. While we have checked national legislation, and believe that sharing the material for research purposes is permitted, should legal complaints occur, they would pose a risk to our ability to share this material long-term.
+
+# Acknowledgment
+
+We thank Gerhard Weikum and Tuan-Phong Nguyen for discussions in earlier stages of this
+
+Table 9: Human preference of CSK generations.
+
+| Input (SP) | BERT-large | BERT-large fine-tuned on Infant-Books |
| bill, CapableOf standing up, HasSubevent hair, AtLocation creating idea, Causes chew food, MotivatedByGoal | pay bill getting dizzy cabinet solution tastes good | amount nothing falling down hair salon new idea eat |
+
+Table 10: Sample COMET Predictions
+
+work, and the anonymous reviewers for their helpful comments.
+
+# References
+
+Yohan Chalier, Simon Razniewski, and Gerhard Weikum. 2020. Joint reasoning for multi-faceted commonsense knowledge. In AKBC.
+Bhavana Dalvi Mishra, Niket Tandon, and Peter Clark. 2017. Domain-targeted, high precision knowledge extraction. TACL.
+Barry J Devereux, Lorraine K Tyler, Jeroen Geertzen, and Billi Randall. 2014. The centre for speech, language and the brain (CSLB) concept property norms. Behavior research methods, 46(4).
+Rudolf Flesch. 1979. How to write plain English.
+Jonathan Gordon, Benjamin Van Durme, and Lenchart K. Schubert. 2010. Learning from the web: Extracting general world knowledge from noisy text. AAAI Workshops.
+Jonathan Gordon and Benjamin Van Durme. 2013. Reporting bias and knowledge acquisition. In *AKBC*.
+Felix Hill, Antoine Bordes, Sumit Chopra, and Jason Weston. 2016. The goldilocks principle: Reading
+
+children's books with explicit memory representations. In ICLR.
+Jena D. Hwang, Chandra Bhagavatula, Ronan Le Bras, Jeff Da, Keisuke Sakaguchi, Antoine Bosselut, and Yejin Choi. 2021. (Comet-) Atomic 2020: On symbolic and neural commonsense knowledge graphs. In AAAI.
+Filip Ilievski, Pedro Szekely, and Bin Zhang. 2021. Cskg: The commonsense knowledge graph. In ESWC.
+Douglas B. Lenat. 1995. Cyc: A large-scale investment in knowledge infrastructure. Commun. ACM.
+Pengfei Liu, Weizhe Yuan, Jinlan Fu, Zhengbao Jiang, Hiroaki Hayashi, and Graham Neubig. 2022. Pretrain, prompt, and predict: A systematic survey of prompting methods in natural language processing. ACM CSUR.
+Ninareh Mehrabi, Pei Zhou, Fred Morstatter, Jay Pu-jara, Xiang Ren, and Aram Galstyan. 2021. Lawyers are dishonest? quantifying representational harms in commonsense knowledge resources. In EMNLP.
+Tuan-Phong Nguyen, Simon Razniewski, Julien Romero, and Gerhard Weikum. 2022. Refined commonsense knowledge from large-scale web contents. In TKDE.
+Tuan-Phong Nguyen, Simon Razniewski, and Gerhard Weikum. 2021. Advanced semantics for commonsense knowledge extraction. In WWW.
+Fabio Petroni, Tim Rocktäschel, Sebastian Riedel, Patrick Lewis, Anton Bakhtin, Yuxiang Wu, and Alexander Miller. 2019. Language models as knowledge bases? In EMNLP.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res.
+Julien Romero and Simon Razniewski. 2020. Inside Quasimodo: Exploring construction and usage of commonsense knowledge. In CIKM.
+Julien Romero, Simon Razniewski, Koninika Pal, Jeff Z. Pan, Archit Sakhadeo, and Gerhard Weikum. 2019. Commonsense properties from query logs and question answering forums. In CIKM.
+Maarten Sap, Ronan LeBras, Emily Allaway, Chandra Bhagavatula, Nicholas Lourie, Hannah Rashkin, Brendan Roof, Noah A. Smith, and Yejin Choi. 2019. ATOMIC: an atlas of machine commonsense for if-then reasoning. AAAI.
+Push Singh, Thomas Lin, Erik T Mueller, Grace Lim, Travell Perkins, and Wan Li Zhu. 2002. Open mind common sense: Knowledge acquisition from the general public. In OTM Confederated International Conferences.
+
+Robyn Speer, Joshua Chin, and Catherine Havasi. 2017. Conceptnet 5.5: An open multilingual graph of general knowledge. In AAAI.
+Peter West, Chandra Bhagavatula, Jack Hessel, Jena D Hwang, Liwei Jiang, Ronan Le Bras, Ximing Lu, Sean Welleck, and Yejin Choi. 2022. Symbolic knowledge distillation: from general language models to commonsense models. NAACL.
\ No newline at end of file
diff --git a/dochildrentextsholdthekeytocommonsenseknowledge/images.zip b/dochildrentextsholdthekeytocommonsenseknowledge/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..e996d1e8824a1d93722d21c0cb5be55757f6d51f
--- /dev/null
+++ b/dochildrentextsholdthekeytocommonsenseknowledge/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7af57e61a9cf29b7c2a4a4533de89aa37c54fda09fe0ead2bba9dc63c51fd726
+size 327209
diff --git a/dochildrentextsholdthekeytocommonsenseknowledge/layout.json b/dochildrentextsholdthekeytocommonsenseknowledge/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..aead9633f225ed38d8c1c062f65be97458244a9f
--- /dev/null
+++ b/dochildrentextsholdthekeytocommonsenseknowledge/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e7f873114c72b11d1099b3b07c9b49ee37841bde26123dcf65992276f06ecf6e
+size 181558
diff --git a/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_content_list.json b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..ad3e5977854ffc3a2a7fd5fef7e78ded4d25503c
--- /dev/null
+++ b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:47972e2074ea66417c591a7fc05f7400ca799cdcd73b3376bdf3c2d9a78ec81e
+size 110475
diff --git a/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_model.json b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..9f1a8eee0ee051991de086ed3a3061aa492527c9
--- /dev/null
+++ b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c8276d2ee1a1f45e09001659e710ce8065593d7c63afd40a1a45956ad4c1c934
+size 134402
diff --git a/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_origin.pdf b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4a20911b8ab906dadd966e050c149788f6f9ca09
--- /dev/null
+++ b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/465c2af4-ce7d-4019-8c90-9296dec791a2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:26801bb88cab33035cb605ca454372a92e56992087dc855663dfea46d72b0ab8
+size 1254928
diff --git a/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/full.md b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..6c757c4087e62cf3e324a540ebbd9729a0451f62
--- /dev/null
+++ b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/full.md
@@ -0,0 +1,370 @@
+# DocInfer: Document-level Natural Language Inference using Optimal Evidence Selection
+
+Puneet Mathur4, Riyaz Bhat2, Gautam Kunapuli3, Manish Shrivastava4, Dinesh Manocha1, and Maneesh Singh3
+
+1University of Maryland, College Park, MD, USA
+
+$^{2}$ IBM, Bengaluru, India
+
+$^{3}$ Motive, San Francisco, USA
+
+$^{4}$ IIIT, Hyderabad, India
+
+# Abstract
+
+We present DocInfer - a novel, end-to-end Document-level Natural Language Inference model that builds a hierarchical document graph enriched through inter-sentence relations (topical, entity-based, concept-based), performs paragraph pruning using the novel SubGraph Pooling layer, followed by optimal evidence selection based on REINFORCE algorithm to identify the most important context sentences for a given hypothesis. Our evidence selection mechanism allows it to transcend the input length limitation of modern BERT-like Transformer models while presenting the entire evidence together for inferential reasoning. We show this is an important property needed to reason on large documents where the evidence may be fragmented and located arbitrarily far from each other. Extensive experiments on popular corpora - DocNLI, ContractNLI, and ConTRoL datasets, and our new proposed dataset called CaseHoldNLI on the task of legal judicial reasoning, demonstrate significant performance gains of $8 - 12\%$ over SOTA methods. Our ablation studies validate the impact of our model. Performance improvement of $\sim 3 - 6\%$ on annotation-scarce downstream tasks of fact verification, multiple-choice QA, and contract clause retrieval demonstrates the usefulness of DocInfer beyond primary NLI tasks.
+
+# 1 Introduction
+
+Natural Language Inference (NLI) is a fundamental textual reasoning task seeking to classify a presented hypothesis as entailed by, contradictory to or neutral to a premise (Dagan et al., 2010). Prior NLI datasets and studies have focused on sentence-level inference where both the premises and hypotheses are single sentences (SNLI (Bowman et al., 2015), MultiNLI(Williams et al., 2018), QNLI and WNLI(Wang et al., 2018)) Document-level NLI extends the reasoning of NLI beyond
+
+sentence granularity where the premises are in the document granularity, whereas the hypotheses can vary in length from single sentences to passages with hundreds of words(Yin et al., 2021).
+
+Document level NLI is an important problem for many tasks including verification of factual correctness of document summaries, fact-checking assertions against articles, QA on long texts, legal compliance of contracts, etc. Even so, it challenges modern approaches due to the limited input bottleneck of modern Transformer models. Consider that the universally used BERT model (Devlin et al., 2018) can only encode 512 input sub-tokens due to its quadratic self-attention complexity. Consequently, evidence in the document premise relevant to the hypothesis can potentially be distributed in several textual spans located arbitrarily far away from each other in long documents, and may not be simultaneously available to draw inference.
+
+Recent approaches, notably SpanNLI (Koreeda and Manning, 2021), HESM (Hanselowski et al., 2018)) and others, have shown that chunking the premise into multiple document spans, scoring them, and aggregating the scores helps mitigate the limited input length problem. Such approaches do not allow the inference module to reason over the complete evidence. In contrast to encoding the document as a set of sentences fed into a transformer for inferential reasoning, a recent line of work, e.g. EvidenceNet (Chen et al., 2022), GEAR (Zhou et al., 2019) and HGRGA (Lin and Fu, 2022)), encodes documents as graphs and uses graph reasoning to perform textual inference. Graphs allow encoding of various morphological and semantic relationships at various granularities. However, these approaches use graph-based processing subsequent to evidence selection.
+
+We address the above challenge with a reasonable assumption that the portion of the premise (the ground truth evidence) necessary and sufficient for inference can fit entirely into the length
+
+limit of language model for effective representation learning. Our proposed system achieves this by selecting sentences in the document that are contextually relevant for a given hypothesis through pruning irrelevant paragraphs and reinforce learning based optimal sentence selection. Our main contributions:
+
+- DocInfer - a novel DocNLI model that simultaneously performs successive optimal evidence selection and textual inference on large documents. It utilizes a novel graph representation of the document encoding structural, topical, concept and entity-based relationships. It performs subgraph pooling and asynchronous graph updates to provide a pruned, hypothesis-relevant and richer sub-document graph representation and uses a reinforcement-learning based subset selection module to provide the contextually-relevant evidences for inference. Experimental results show that DocInfer outperforms the current SOTA on DocNLI, ContractNLI and ConTRoL datasets with a significant improvement of $8 - 12\%$ .
+- We propose CaseHoldNLI - a new document-level NLI dataset in the domain of legal judicial reasoning with over 270K document-hypotheses pair with maximum premise length of 3300 words. We observe similar performance gains on this dataset.
+- Application on downstream tasks: We demonstrate the usefulness of the DocInfer evidence selection module on downstream tasks of fact verification, multiple choice QA and few shot clause retrieval from legal texts using no or small amounts of data for supervised fine-tuning. Results on FEVER-binary, MCTest and Contract Discovery dataset show significant improvement of $\sim 3 - 6\%$ F1.
+
+# 2 Related Work
+
+Document-level NLI Datasets: Yin et al. (2021) introduced Doc-level NLI on news and Wikipedia articles. Liu et al. (2021) proposed the multiparagraph ConTRoL dataset focused on complex contextual reasoning (logical, coreferential, temporal, and analytical reasoning). Several datasets comprising legal documents like case laws, statutes, and contracts have been proposed. COLIE-2020 (Rabelo et al., 2020) and Holzenberger et al. (2020) support identification of relevant paragraphs from cases that entail the decision of a new case. How
+
+ever, the combined input length of their premise-hypothesis pairs remains within 512 tokens with the premise lengths at paragraph-level, reasonably suited for input to BERT-like models. Koreeda and Manning (2021) released ContractNLI dataset for document-level NLI task on multiple page NDA contract documents along with ground truth evidence labeling for interpretability. We benchmark DocInfer on DocNLI, ContractNLI and ConTRoL datasets. CaseHOLD dataset (Zheng et al., 2021) is a multiple choice QA dataset for selecting relevant governing laws required to reason about the legal decision text. Document-scale and Corpus-Scale Reasoning: In order to handle document-scale premises in the doc-NLI corpora, approaches like SpanNLI (Koreeda and Manning, 2021), HESM (Hanselowski et al., 2018)) chunk the premise into multiple document spans for reasoning. A similar approach was followed by legal language models such as Legal-BERT (Chalkidis et al., 2020) and Custom Legal-BERT (Zheng et al., 2021) for legal reasoning tasks. More recently, language models (e.g., Longformer (Beltagy et al., 2020) with 4096 token input) have been proposed to overcome the limited input field bottleneck. Fact Extraction and Verification (FEVER) (Thorne et al., 2018) tasks require extracting evidence and claim entailment given an input claim and the Wikipedia corpus. Prior works in this domain address the length limitation for claim verification by relevant evidence identification and its chunking which are individually scored and probabilistically aggregated (Subramanian and Lee, 2020; Jiang et al., 2021). Hierarchical graph modeling may be used to handle the large scale of the premise (Liu et al., 2019b; Zhou et al., 2019; Zhong et al., 2020; Zhao et al., 2020; Chen et al., 2022; Lin and Fu, 2022; Si et al., 2021). Context Selection for Document-level NLP: Recent works have investigated selection of relevant context for document-level NLP tasks such as Neural Machine Translation (Kang et al., 2020), Event Detection (Ngo et al., 2020; Veyseh et al., 2021), Relation Extraction (Trong et al., 2022). Recently, some of the work on document-level NLP has looked at temporal relation extraction (Mathur et al., 2021), temporal dependency parsing (Mathur et al., 2022b), and speech synthesis (Mathur et al., 2022a) using graphs and sequence learning. However, none of them have considered an end-to-end trainable approach for graph learning with to identify the relevant evidence extraction.
+
+
+Figure 1: DocInfer Architecture: Document $D$ and hypothesis $H$ pass through BERT; Hierarchical graph using $(R_{str})$ , $(R_{top})$ , $(R_{sim})$ and $(R_{ent})$ relations. SubGraph Pooling extracts relevant paragraph nodes; Asynchronous graph updates learn relation-specific node embeddings. Evidence Selection optimized by REINFORCE rewards $(\phi_{perf})$ , $(\phi_{bleu})$ , $(\phi_{sel})$ , $(\phi_{mhop})$ .
+
+# 3 DocInfer
+
+Given a textual hypothesis $H$ , the task of document-level NLI is to classify whether the hypothesis is entailed by, contradicting to or not mentioned by (neutral to) the document $D$ . We present DocInfer, a neural architecture (Figure 1) that can select a set of evidence sentences $E$ from document $D$ to form a shortened document $D^{e}$ which is then used for NLI prediction. Here, for the document level NLI task, we need to constrain $D^{e}$ to fall within the length limit of BERT-like context encoder to enable it to consume the evidence entirely for improved representation learning for NLI.
+
+Our model can be seen as a sequence of four phases: (a) Representation of document $D$ in the presence of the Hypothesis $H$ to form a hierarchical document graph with sentences and paragraphs as nodes and Structural, Topical, Entity-centric and Concept-similarity relations as edges. (b) Paragraph node pruning using the novel Subgraph Pooling layer to select highly relevant paragraphs. (c) Asynchronous graph update for improved node representations and finally. (d) Optimal evidence selection using REINFORCE from the graph for the task of document-level NLI.
+
+Document Representation: Let premise document $D$ be defined as a sequence of $n$ sentences $s_1, s_2, \dots, s_n$ such that $D = [s_1, s_2, \dots, s_n]$ . These sentences are naturally grouped into $m$ consecutive paragraphs $P = [p_1, p_2, \dots, p_m]$ such that each each sentence $s_i$ belongs to only one paragraph $p_j$ . We leverage pre-trained BERT language model to obtain the embedding of every sentence and paragraph nodes. The final representation for each sentence $s_i$ and paragraph
+
+$p_j$ is obtained by extracting the hidden vector of the CLS token as given by $\mathrm{Emb}(s_i) = \mathrm{BERT}([CLS];H;[SEP];s_i;[SEP])$ and $\mathrm{Emb}(p_j) = \mathrm{BERT}([CLS];H;[SEP];p_j;[SEP])$ , respectively. Here $H$ denotes the hypothesis text which is also encoded as $h = \mathrm{BERT}([CLS];H;[SEP])$ . $[CLS]$ and $[SEP]$ are symbols that indicate the beginning and ending of a text input, respectively.
+
+Document Graph Construction: The document is then modeled as a hierarchical graph $D_G = (V, E)$ to capture the premise document structure. Here, $V = \{V_p, V_s, V_h\}$ , where $V_p, V_s, V_h$ are nodes corresponding to all the paragraphs, all the sentences and the hypothesis, respectively. The set of edges $(E)$ of the Document Graph encodes four types of relations between the nodes mentioned below:
+
+(1) Structural Relations $(R_{str})$ : Hypothesis-Paragraph edges and Paragraph-Sentence Affiliation edges model the hierarchical structure of the document through a directed edge from the hypothesis node to each paragraph node and from a paragraph node to each constituent sentence, respectively. Further, Paragraph-Paragraph Adjacency and Sentence-Sentence Adjacency links preserve the sequential ordering for consecutive paragraph and sentence nodes through directed edges.
+
+(2) Topical Relations $(R_{top})$ : Sentence-Sentence Topical Consistency connections model the topical consistency between a pair of sentences by constructing sentence-level topical representations via latent Dirichlet allocation (Blei et al., 2003). Given a pair of sentences $s_i$ and $s_j$ , we extract latent topic distribution $lda_i, lda_j \in R^l$ for each sentence which are joined if the Helinger $H(lda_i, lda_j)$ distance between them is greater than 0.5.
+
+(3) Entity-centric Relations $(R_{ent})$ : Sentence-
+
+Sentence Entity Overlap connections explicitly model the sentence-level interactions between entity spans by adding an undirected edge between two sentence nodes if they share one or more named entities. Further, Sentence-Sentence Entity Coreference connections join two sentences by an undirected edge if the sentences share mentions referring to the same real world entity.
+
+(4) Concept-Similarity Relations $(R_{sim})$ : Sentences conceptually similar to other sentences and the hypothesis are connected to each other to account for presence of related events and topics in two sentences. We propose Sentence-Sentence ConceptNet Similarity using ConceptNet Number-batch (CN). Let $A_i^{cn} = [a_1, a_2, \dots, a_l]$ be the ConceptNet Number-batch embeddings for the words in sentence $s_i = [w_1, w_2, \dots, w_M]$ respectively. Here, if a word $w_q$ does not have its corresponding embedding in CN, we simply set its vector $a_q$ to zero. Further, we introduce Hypothesis-Sentence Knowledge Similarity (using KnowBert embedding) connections that add weighted undirected edges between sentence-sentence and hypothesis-sentence node pairs, respectively. KnowBert representations are obtained by encoding text using the pre-trained KnowBert language model as $A_i^{kbrt} = \text{KnowBERT}([s_i])$ . The edge weights $\varepsilon(i, j)$ between the input vector pairs $(a_i, a_j)$ is cosine similarity between the knowledge-based semantic embeddings of the input texts.
+
+$$
+\varepsilon (i, j) = \left\{ \begin{array}{l l} c o s i n e (A _ {i} ^ {c n}, A _ {j} ^ {c n}) & \text {i f a _ {i} , a _ {j} \in S} \\ c o s i n e (A _ {i} ^ {k b r t}, A _ {j} ^ {k b r t}) & \text {i f a _ {i} = = H , a _ {j} \in S} \end{array} \right.
+$$
+
+# Paragraph Pruning using Subgraph Pooling:
+
+Long documents are structured as a sequence of paragraphs such that each paragraph may be topically coherent to itself and neighboring paragraphs. As such, paragraphs unrelated to a given hypothesis may be ignored to reduce distractor cues. Graph pooling (Grattarola et al., 2021) is a popular method for graph coarsening. Unlike previous methods such as gPool (Gao and Ji, 2019) and SAGPool (Lee et al., 2019) that pool entire graph, we propose attention-based Subgraph Pooling layer which can select top rank nodes from a predefined subset of nodes in the graph. Subgraph Pooling layer can selectively drop irrelevant paragraph nodes while retaining the remaining paragraph nodes, their corresponding sentence nodes and the hypothesis node in the graph.
+
+Suppose there are $N$ nodes in document graph $D_G$ with node embedding of size $C$ with adjacency matrix $A \in \Re^{NxN}$ and feature matrix $X \in \Re^{NxC}$ . We apply GAT (Veličković et al., 2017) over $D_G$ to obtain self-attention scores $Z$ for all nodes. The pooling ratio $\eta$ is a hyperparameter that determines the number of paragraph nodes to keep based on the value of $Z$ . We want to select the top-rank nodes only from the set of paragraph nodes. Hence, we use a hard mask $\mu = \{1|x_i \in P \forall X; 0\}$ that is 1 for all paragraph nodes $P$ , otherwise zero. We perform an element-wise multiplication ( $\odot$ ) between attention scores and mask values to get a soft mask $Z_P = Z \odot \mu$ . Top-rank operation ranks returns the indices of top $\eta$ paragraphs based on $Z_P$ . Node indices corresponding to the set of selected top- $\eta$ paragraphs added to the set of sentence nodes minus those belonging to the pruned paragraphs ( $\mathrm{idx}_{S - S_{P - P_{\eta}}}$ ) and hypothesis ( $\mathrm{idx}_H$ ) are selected as follows: $\mathrm{idx} = \text{top-rank}(Z_P, \eta) + \mathrm{idx}_{S - S_{P - P_{\eta}}} + \mathrm{idx}_H$ . The combined index tensor ( $\mathrm{idx}$ ) contains the indices of all the nodes selected in the final graph $D_G'$ . $X'(\mathrm{idx}, :)$ and $\widetilde{A} = A(\mathrm{idx}, \mathrm{idx})$ perform the row and/or column extraction to form the adjacency matrix and the feature matrix of $D_G'$ . The attention scores for selected nodes $Z_{idx}$ act as gating weights for node features after filtering which controls the information flow and makes the whole procedure trainable by back-propagation as given by: $\widetilde{X} = X' \odot (Z_{idx})$ .
+
+Asynchronous Graph Update: Graph Neural Networks (GNN) are useful for multi-hop reasoning on hierarchical graphs comprising of different levels of granularity (questions, paragraphs, sentences, entities) Fang et al. (2019); Zhang et al. (2020); Chen et al. (2021). However, GNN's perform message passing synchronously at each step of the graph update, ignoring the fact that different relationship (edge) types may have different priorities. In order to overcome this challenge, we propose to use Asynchronous Graph Update (Li et al., 2021) to perform sequential graph updates corresponding to all relationship types in $R \in \{R_{str}, R_{top}, R_{ent}, R_{sim}\}$ to enhance the effectiveness of multi-hop reasoning. Optimal Evidence Selection ( $E^{NLI}$ ): To select the set of most relevant evidence sentences $E$ , we hypothesize that a sentence $s_i$ from document $D$ is important for NLI prediction if including the corresponding sentence as part of evidence set can improve the performance of NLI label prediction model ( $M^{NLI}$ ). We design an iterative process
+
+for sentence selection such that at step $k + 1$ in the process ( $k \geq 0$ ), a sentence $s_i^{k+1}$ is chosen which has not been selected previously in evidence set $E_k = \{s_1*, \dots, s_k*\}$ at step $k$ . We employ a Long Short Term Memory Network (LSTM) over previously selected $k$ sentences to select a relevant sentence at time step $k + 1$ . At step 0, the initial hidden state $h_0$ for LSTM is set to zero. At step $k + 1$ , we use the hidden state $h_k$ of LSTM from prior step to assign a score $sc_i^{k+1}$ for each sentence node $s_i \in S - E_k$ . The sentence with highest selection score is considered for selection at this step as given by $sc_i^{k+1} = \text{sigmoid}(FFN([x_i : h_k]))$ and $s_{k+1*} = \text{argmax}_{s_i \in S - E_k}(sc_i^{k+1})$ , where FFN is a two-layer feed-forward network. In particular, if selecting $s_{k+1*}$ causes the number of words in the selected sentences so far to exceed the context encoder length limit (eg., 512 tokens for BERT), the selection process stops and $s_{k+1*}$ is not included in the evidence set E (i.e., $E = \{s_1*, \dots, s_k*\}$ in this case). Otherwise, the selection process continues to the next step and $s_{k+1*}$ will be chosen and included in $E$ (i.e., $E = \{s_1*, \dots, s_{k+1*}\}$ ). The hidden state of LSTM is also updated for the current step, i.e., $h_{k+1} = LSTM(h_k, x_{k+1*})$ , to prepare for the continuation of sentence selection.
+
+Evidence Selection Reward Function: In order to train the evidence selection module, we employ the REINFORCE algorithm (Williams, 1992) and incorporate the following information signals in the reward function of REINFORCE to better supervise the training process. In order to train the evidence selection module, we employ the REINFORCE algorithm (Williams, 1992). We incorporate the following information signals in the reward function of REINFORCE to better supervise the training process:
+
+(1) Task Reward $\phi_{perf}$ : We compute this reward based on the NLI task prediction performance. In order to measure the impact of the selected context, we use a T-5 model (Raffel et al., 2019a) pretrained on MNLI corpus (Williams et al., 2017) to predict the NLI label for the given hypothesis + context pair. $\phi_{perf}(E)$ is set to 1 if the final prediction is correct; and 0 otherwise.
+(2) Semantic Reward $\phi_{sem}$ : We propose that the evidence sentences should be semantically similar to the hypothesis. Our motivation is that similar context sentences (e.g., discussing the same events or entities) provide more relevant information for the NLI prediction. We include the semantic simi
+
+larity between the selected evidence sentences in $E$ and the hypothesis as measured by the cosine similarity (i.e., $\odot$ ) between their sentence embeddings computed using SimCSE $^1$ (Gao et al., 2021).
+
+(3) Evidence Reward $\phi_{bleu}$ : We seek to promote evidence sentences having a high overlap with the target ground truth evidence. In many cases, the target evidence length may be way less than 512 token limit. Hence, our motivation is to reward the lexical overlap while penalizing vocabulary arising at evidence selection stage. We calculate the BLEU score between the selected evidence $E$ and ground truth evidence $E_{gt}$ : $\phi_{bleu} = BLEU(E,E_{gt})$ . This reward can only be applied for cases where ground truth evidence annotation is present.
+
+(4) Multihop Reward $\phi_{mhop}$ : The motivation for this reward is that a sentence should be preferred to be included in $E$ by the selection process if there are common entities mentions with the hypothesis. Moreover, connected sentences by the virtue of common entity mentions are more likely to refer to the same events. Hence, we leverage the subgraph similarity of the learned node embeddings of the selected evidence and their first degree node connections through entity-centric relations with the hypothesis node in $G_D''$ . We perform max-pooling operation over the concatenated node embeddings of the corresponding evidence sentences and their first degree node connections joined by $R_{ent}$ : $\hat{E} = \text{maxpool}(v_1 \oplus v_2, \dots, v_k | s_i \in E, i \in \{1, \dots, k\})$ , where $\bigoplus$ means embedding concatenation. Finally, we compute the dot-product between $\hat{E}$ and node embedding of the hypothesis node $h$ as $\phi_{mhop} = \hat{E}.h$ .
+
+# 3.1 Training DocInfer
+
+NLI Prediction Loss: We combine the final representations corresponding to the learnt graph structure $(g_{out})$ and selected evidence text $(t_{out})$ . We aggregate the embeddings corresponding to the selected sentence nodes in $D_G^{\prime \prime}$ and the hypothesis node using a summation-based graph-level readout function (Xu et al., 2018) as $g_{out} = \rho (\sum_{v\in D_G^{\prime \prime}}W_gV_i^T)$ . The words in the evidence sentences are joined in order of their appearance in document $D$ and input to the context encoder $t_{out} = \text{Encoder}([CLS]s_1;s_2,\dots ,s_k)$ . $g_{out}$ and $t_{out}$ are concatenated and passed through two dense fully-connected layers: $z = RLU(Dense(t_{out}\oplus g_{out})$ . This is
+
+followed by a Softmax layer to predict entailment/contradiction/neutral by utilizing the negative log-likelihood loss: $L_{pred} = -P(y|z)$ .
+
+Evidence Selection Loss: The overall reward function to train our evidence selection module is $\phi (E) = \phi_{perf} + \phi_{sem} + \phi_{bleu} + \phi_{mhop}$ . Using REINFORCE, we seek to minimize the negative expected reward $\phi (E)$ over the possible choices of $E$ as $L_{sent} = -\mathbb{E}_{E\sim P(E|D,H)}[\phi (E)]$ , and $L_{sent} = -\mathbb{E}_{E\sim P(E|D,H)}[\phi (E)]\nabla \log (P(E|H,D))$ .
+
+Finally, the probability of the selected sequence $E$ is computed via $P(E|H,D) = \prod_{k=0,\dots,K-1} P(s_{k+1} * |H,D,s_{i\leq k*})$ , which is obtained via softmax over selection scores for sentences in $S$ at selection step $k + 1$ .
+
+Joint NLI Prediction and Evidence Selection: During training, the NLI prediction model $M^{NLI}$ and the evidence selection module $E^{NLI}$ are trained alternatively. At each update step, $E^{NLI}$ first selects optimal evidence sentences $E$ that form a shortened document $D^e$ . $M^{NLI}$ uses $E$ to predict the NLI label. The parameters of $M^{NLI}$ are updated using the gradient of NLI prediction loss $L_{pred}$ , keeping parameters of evidence extraction module constant. Next, the parameters of the evidence selection module are updated using the gradient of $L_{sent}$ , keeping parameters of $M^{NLI}$ constant. This process repeats until convergence. At test time, evidence sentences are first selected and then consumed by the prediction model to perform NLI prediction.
+
+# 4 Experiments
+
+# 4.1 Datasets for Document-level NLI
+
+We use the following three datasets to benchmark document-level NLI approaches. (1) DocNLI (Yin et al., 2021): A large-scale document-level NLI dataset obtained by reformating mainstream NLP tasks such as question answering and document summarization. (2) ContractNLI (Koreeda and Manning, 2021): NLI dataset of 607 contract documents annotated with ground truth evidence sentences. (3) ConTRoL (Liu et al., 2021): A passage-level NLI dataset of exam questions that requires logical, analytical, temporal, coreferential reasoning, and information integration over multiple premise sentences. (4) CaseHoldNLI, the fourth and novel NLI dataset introduced in this paper, in the legal judicial reasoning domain for identifying the governing legal rule (also called "Holding") applied to a particular set of facts. It is
+
+| System | DocNLI |
| Dev F1 | Test F1 |
| Baselines | Majority | 19.7 | 19.9 |
| BERT (Hypothesis-only) | 21.9 | 22.0 |
| BERTbase (Devlin et al., 2018) | 63.1 | 60.1 |
| BERTlarge (Devlin et al., 2018) | 63.5 | 61.1 |
| RoBERTabase (Liu et al., 2019a) | 61.0 | 59.5 |
| RoBERTlarge (Liu et al., 2019a) | 63.1 | 61.3 |
| T5 (Raffel et al., 2019b) | 62.9 | 61.1 |
| Longformer (Beltagy et al., 2020) | 46.1 | 44.4 |
| GEAR (Zhou et al., 2019) | 67.8 | 63.3 |
| KGAT (Liu et al., 2019b) | 68.5 | 64.8 |
| HESM (Subramanian and Lee, 2020) | 68.9 | 65.0 |
| DREAM (Zhong et al., 2020) | 69.7 | 65.9 |
| TARSA (Si et al., 2021) | 70.4 | 66.4 |
| EvidenceNet (Chen et al., 2022) | 72.6 | 68.5 |
| Ours | DocInfer (w/ RoBerta) | 75.5 | 72.3 |
+
+Table 1: Results comparing performance of DocInfer with baselines on DocNLI dataset. Bold denotes the best performing model. LightCyan and Yellow show best performing baseline and Transformer model.
+
+| System | ContractNLI |
| Acc (%) | F1 (C) | F1 (K) | mAP | PR@80 |
| Baselines | Majority | 67.4 | 8.3 | 42.8 | - | - |
| BERTLarge (Devlin et al., 2018) | 77.5 | 25.7 | 76.4 | 0.822 | 0.763 |
| T5 (Raffel et al., 2019b) | 73.2 | 21.2 | 69.1 | 0.786 | 0.575 |
| Longformer (Beltagy et al., 2020) | 71.2 | 19.2 | 70.4 | 0.755 | 0.648 |
| BigBird (Zaheer et al., 2020) | 71.5 | 18.8 | 70.9 | 0.776 | 0.630 |
| GEAR (Zhou et al., 2019) | 78.4 | 26.9 | 78.3 | 0.909 | 0.774 |
| KGAT (Liu et al., 2019b) | 78.9 | 27.8 | 79.2 | 0.914 | 0.773 |
| HESM (Subramanian and Lee, 2020) | 28.2 | 79.5 | 79.9 | 0.916 | 0.789 |
| DREAM (Zhong et al., 2020) | 79.8 | 29.3 | 80.4 | 0.919 | 0.786 |
| TARSA (Si et al., 2021) | 80.4 | 29.4 | 80.5 | 0.916 | 0.783 |
| Ours | SpanNLI-BertLarge (Koreeda and Manning, 2021) | 87.5 | 35.7 | 83.4 | 0.922 | 0.793 |
| DocInfer (w/ Bert) | 91.8 | 38.2 | 89.1 | 0.956 | 0.832 |
+
+Table 2: Results comparing performance of DocInfer with baselines on ContractNLI dataset. Bold denotes the best performing model. LightCyan and Yellow show best performing baseline and Transformer model.
+
+sourced from the CaseHOLD dataset (Zheng et al., 2021) comprising over $53,000+$ multiple choice questions. Each multiple choice question comprises of a snippet from a judicial decision along with 5 semantically similar potential holdings, of which only one is correct. We obtain the NLIversion by combining the question and the positive (negative) answer candidate as a positive (negative) hypothesis. To evaluate the dataset quality, we asked an expert to select the NLI using only the hypothesis for $10\%$ of the test data sampled at random. The poor performance of this human baseline $(\sim 0.24F1)$ validates that the dataset doesn't suffer from hypothesis bias. CaseHoldNLI dataset is comparable to challenging document-level NLI datasets with average premise length at document-scale and exceeds the maximum input length limit of BERT models. We report train/dev/test splits of each dataset.
+
+# 4.2 Experiments on Downstream Tasks
+
+(1) Fact Verification: The NLI-version of FEVER (Thorne et al., 2018) task, released by Nie et al. (2019), considers each claim as a hypothesis while the premises consist of ground truth textual evi
+
+| System | ConTRoL |
| Acc (%) | F1 (E) | F1 (N) | F1 (C) | F1 (O) |
| Baselines | Majority | 40.6 | 57.7 | 0.0 | 0.0 | 19.2 |
| BERTbase (Devlin et al., 2018) | 47.4 | 42.4 | 50.2 | 46.0 | 46.2 |
| BERTlarge (Devlin et al., 2018) | 50.6 | 45.9 | 53.1 | 49.3 | 49.4 |
| RoBERTbase (Liu et al., 2019a) | 45.9 | 45.3 | 45.9 | 45.6 | 45.6 |
| BART (Lewis et al., 2020) | 56.3 | 49.1 | 59.5 | 53.8 | 54.0 |
| Longformer (Beltagy et al., 2020) | 49.8 | 45.6 | 46.8 | 46.2 | 46.2 |
| BigBird (Zaheer et al., 2020) | 49.3 | 46.0 | 45.1 | 46.0 | 46.1 |
| BART-NLI (Liu et al., 2021) | 57.2 | 49.0 | 60.4 | 54.2 | 54.5 |
| BART-NLI-FT (Liu et al., 2021) | 57.5 | 49.3 | 60.6 | 54.6 | 55.0 |
| KGAT (Liu et al., 2019b) | 59.1 | 50.6 | 61.8 | 55.7 | 56.6 |
| HESM (Subramanian and Lee, 2020) | 59.3 | 50.9 | 62.3 | 56.1 | 56.6 |
| DREAM (Zhong et al., 2020) | 59.8 | 51.1 | 62.0 | 56.1 | 56.3 |
| HGRGA (Lin and Fu, 2022) | 60.6 | 52.9 | 62.4 | 58.7 | 58.0 |
| EvidenceNet (Chen et al., 2022) | 61.8 | 56.4 | 64.2 | 64.3 | 61.6 |
| Ours | DocInfer (w/ BART) | 66.7 | 60.6 | 67.1 | 69.6 | 67.4 |
+
+Table 3: Results comparing performance of DocInfer with baselines ConTRoL dataset. Bold denotes the best performing model. LightCyan and Yellow show best performing baseline and Transformer model.
+
+| System | CaseHoldNLI |
| P | R | F1 |
| Baselines | Majority | 0.0 | 1.0 | 0.0 |
| BERTbase (Devlin et al., 2018) | 42.2 | 46.3 | 44.2 |
| RoBERTabase (Liu et al., 2019a) | 42.2 | 46.3 | 44.2 |
| T5 (Raffel et al., 2019b) | 41.5 | 43.5 | 42.5 |
| Legal-BERT (Zheng et al., 2021) | 46.5 | 47.9 | 47.1 |
| Longformer (Beltagy et al., 2020) | 40.1 | 43.3 | 41.6 |
| GEAR (Zhou et al., 2019) | 42.9 | 46.8 | 44.8 |
| HESM (Subramanian and Lee, 2020) | 44.0 | 48.0 | 45.9 |
| HGRGA (Lin and Fu, 2022) | 45.4 | 49.4 | 47.3 |
| EvidenceNet (Chen et al., 2022) | 47.3 | 50.5 | 48.8 |
| Ours | DocInfer (w/ Legal-Bert) | 51.3 | 53.1 | 52.2 |
+
+Table 4: Results comparing performance of DocInfer with baselines on CaseHoldNLI dataset. Bold denotes the best performing model. LightCyan and Yellow show best performing baseline and Transformer model.
+
+dence and other randomly sampled related text.
+
+(2) Multi-choice Question Answering: The NLI version MCTest (Richardson et al., 2013) combines the question and the positive (negative) answer candidate as a positive (negative) hypothesis. Presence of limited labeled data makes them both good benchmarks to investigate the performance of document-level NLI models on annotation-scarce tasks. We evaluate DocInfer trained on DocNLI dataset and report F1 scores for both tasks. We follow the "FEVER-binary" and "MCTest-NLI" settings proposed in Yin et al. (2021).
+
+(3) Contract Clause Retrieval(Lukasz Borchmann et al., 2020): is a task to identify spans in a target document representing clauses analogous (i.e. semantically and functionally equivalent) to the provided seed clauses from source documents. We reformulate this as an NLI task where the seed clauses are concatenated to form the hypothesis, and the target document is the premise. We test the evidence selection capabilities of DocInfer trained on ContractNLI dataset for identifying relevant sentence-level spans in the premise for the clause retrieval task. The dataset has 1300 examples each for validation and test to tune and test the paragraph selection hyperparameter $\eta$ . We followed the eval
+
+uation framework specified in Lukasz Borchmann et al. (2020) of few (1-5) shot setting and report Soft F1 score.
+
+# 5 Results
+
+Table 1-4 compares the performance of DocInfer against other baselines on DocNLI, ContractNLI, ConTRoL, and CaseHoldNLI datasets. Similar to (Yin et al., 2021), we truncate the hypothesis-premise pair sequence to appropriate maximum input length for input to Transformer models. BERT (Devlin et al., 2018), RoBERTa (Liu et al., 2019a), DeBERTa (He et al., 2020), BART (Lewis et al., 2020) show superior performance for DocNLI, ContractNLI, and ConTRoL datasets, respectively. Legal-BERT (Chalkidis et al., 2020) outperforms other Transformer language models on CaseHoldNLI dataset due to its high domain-specificity of legal language. However, they are challenged by their input length restriction of 512 tokens for contextually reasoning over long premise lengths. Consistent with observations of (Yin et al., 2021), large input Transformer models such as Longformer (Beltagy et al., 2020) and BigBird (Zaheer et al., 2020) that can handle up to 4096 tokens underperform traditional BERT-like models on all four datasets. We attribute this to the presence of distractors in long documents and the inability of these models to reason in a multihop fashion. BARTNLI which is pretrained on sentence-level NLI (Liu et al., 2021) improves over naive Transformers but still struggles due to limited captured context.
+
+We also re-purpose several strong baseline methods from the Fact Extraction and Verification (FEVER 1.0) task. by reformulating the document retrieval and claim verification steps to paragraph retrieval and textual entailment, respectively. GEAR, KGAT, and HGRGA model the document as a dense fully-connected graph, leading to distractor interactions confounding the reasoning process. They are also devoid of linguistic information about entities, topics or commonsense knowledge. HESM uses document chunking which hinders contextual reasoning for far-away chunks. DREAM and TARSA use semantic role labeling and topic modeling, respectively, to identify phrase interaction but lack entity-level information required to resolve coreferences across document. EvidenceNet and SpanNLI emerge as strong baseline models for our work. DocInfer outperforms SpanNLI and EvidenceNet due to its ability to iteratively
+
+select important evidence sentences in the premise and simultaneously utilize multihop interactions between related evidences. Impact of Input Length: DocInfer achieves SOTA performance on all four datasets and maintains steady improvements over corresponding baseline models with increasing in input lengths. Choice of context encoder in NLI prediction: One of the merits of the our approach is that it is extensible and can utilize any domain-specific transformer language models for context encoding to further augment performance. We evaluate the choice of context encoder for different datasets. DocInfer gives SOTA performance using RoBERTa for DocNLI, BERT for ContractNLI, BART for ConTROL, and Legal-BERT for Case-HoldNLI, in the prediction model.
+
+Ablation Study of DocInfer: Table 5 shows ablations for the document graph relations, module components and reward functions. We observe that concept relation is critical in all data settings due to the need for external knowledge-based semantic representation for connecting related concepts across sentences. Removing any of the relations does not degrade the performance below EvidenceNet (Chen et al., 2022) or SpanNLI baselines. This is important for adapting our method to new domains where existing linguistic parsers maybe noisy or non-existent. Cells in Table 5 highlighted in red shows the ablation of individual components such that removing paragraph pruning mechanism severely deteriorates model performance as the model has to evaluate an exponentially larger number of candidate evidences during evidence selection stage. In absence of optimal evidence selection, we treat evidence extraction as a binary classification task over each sentence node along with NLI label given by the "readout" function similar to KGAT (Liu et al., 2019b). The severe performance drop of DocInfer model in absence of evidence selection component highlights its importance for document NLI task. Asynchronous graph update adds incremental value to DocInfer owing to its relation-specific message passing. Evidence Selection and Paragraph Pruning components are most critical for SOTA performance of DocInfer. Greedy selection instead of REINFORCE significantly decreases performance. Concept relations are most beneficial for DocInfer, followed by topical and entity relations. Evidence, semantic, multi-hop and task rewards most help ContractNLI, ContrRoL, DocNLI, and CaseHoldNLI.
+
+Impact of reward function: Table 5 shows that removing any reward component (i.e., task, semantic, evidence, multihop) significantly hurts the overall performance, thus clearly demonstrating their individual importance. To assess the necessity of the multi-step selection using REINFORCE, we eliminate multistep selection strategy and perform one-shot sentence selection where the top $k$ sentences with highest selection scores from the first step are selected. We call this setting as greedy evidence selection and show that the elimination of multistep selection drops performance, suggesting that selecting sentences incrementally conditioning on previously selected sentences is advantageous.
+
+Performance of DocInfer on downstream tasks: Table 6 shows the evaluation of DocInfer along with RoBERTa-large and EvidenceNet (Chen et al., 2022) baselines and RoBERTa model from Yin et al. (2021) on FEVER-binary and MCTest tasks. We train all models on DocNLI dataset to benefit from cross-task transfer and for minimizing domain shift. We then inference all models in two settings: (i) without task specific fine-tuning, and (ii) with fine-tuning on the end task. DocInfer model consistently outperforms baselines across both tasks in case of without fine-tuning (FEVER-binary: +0.8 F1, MCTest v160: +1 F1, MCTest v500: +0.6 F1) and with fine-tuning (FEVER-binary: +0.9 F1, MCTest v160: +0.5 F1, MCTest v500: +0.2 F1). We observe that both the tasks require the models to capture topic coherence, knowledge-based semantics, and entities interactions as removing graph relations severely degrades the performance.
+
+Evidence selection for clause retrieval focuses on selecting evidence spans in the target document (premise) given the entailment relation with seed clauses (hypothesis). The task is unsupervised in nature (has no training set). We test the evidence selection module $(E^{NLI})$ of the DocInfer model and its ablated variants (without paragraph pruning and reward functions), all pre-trained on ContractNLI dataset. Table 7 shows that DocInfer model with BERT as the context encoder outperforms strong baselines by approximately $5\%$ . Removing paragraph pruning significantly degrades the performance, highlighting the need to prune distractor paragraphs for retrieving relevant information. Presence of each reward function to maintain the performance of DocInfer indicates the linguistic importance of each reward. Formulating the task as NLI helps contextualize the seed clauses with
+
+| System | DocNLI Dev F1 Test F1 | Acc (%) | ContractNLI F1 (E) | mAP | PR@80 | Acc (%) | ConTrol F1 (E) | F1 (N) | F1 (C) | F1 (O) | CaseHoldNLI R F1 |
| Context Encoder | RoBERTa | BERT | BART | Legal-BERT | |
| Ours | DocInfer | 75.5 | 72.3 | 91.8 | 38.2 | 89.1 | 0.956 | 0.832 | 66.7 | 63.6 | 67.1 | 69.6 | 67.4 | 51.3 |
| DocInfer w\Concept Relations | 72.6 | 70.7 | 90.7 | 35.4 | 87.2 | 0.928 | 0.810 | 62.3 | 62.6 | 66.6 | 66.1 | 64.2 | 50.6 |
| DocInfer w\Topical Relations | 72.2 | 70.4 | 90.6 | 33.6 | 86.6 | 0.925 | 0.819 | 60.5 | 59.4 | 66.7 | 63.2 | 63.1 | 49.5 |
| DocInfer w\Entity Relations | 72.5 | 70.2 | 90.2 | 31.1 | 85.7 | 0.921 | 0.812 | 59.8 | 58.8 | 66.0 | 62.8 | 62.5 | 49.0 |
| Abduction | DocInfer w/o Asynchronous Graph Update | 73.2 | 71.5 | 89.5 | 36.3 | 84.3 | 0.923 | 0.813 | 57.6 | 61.0 | 59.7 | 65.1 | 64.8 | 48.8 |
| Greedy Evidence Selection | 67.5 | 64.9 | 88.3 | 36.0 | 84.1 | 0.876 | 0.780 | 56.5 | 56.3 | 56.1 | 55.2 | 55.8 | 46.8 |
| DocInfer w/o Paragraph Pruning | 65.6 | 64.5 | 85.4 | 35.9 | 83.9 | 0.855 | 0.742 | 51.8 | 47.0 | 45.5 | 48.0 | 46.8 | 44.8 |
| DocInfer w/o Evidence Selection | 65.0 | 63.6 | 83.7 | 35.5 | 83.5 | 0.825 | 0.715 | 51.6 | 46.7 | 45.0 | 47.8 | 46.5 | 44.4 |
| DocInfer w\Task Reward | 70.5 | 68.5 | 90.1 | 33.9 | 86.7 | 0.907 | 0.769 | 61.9 | 61.0 | 64.0 | 65.2 | 63.4 | 47.4 |
| DocInfer w\Evidence Reward | - | - | 90.8 | 36.4 | 87.5 | 0.916 | 0.805 | - | - | - | - | - | - |
| DocInfer w\Semantic Reward | 71.4 | 69.0 | 90.6 | 34.2 | 84.4 | 0.912 | 0.778 | 63.3 | 62.5 | 63.9 | 64.7 | 63.7 | 46.6 |
| DocInfer w\Multihop Reward | 71.6 | 69.5 | 90.5 | 35.5 | 85.6 | 0.910 | 0.785 | 61.6 | 62.0 | 63.2 | 64.0 | 63.0 | 46.1 |
+
+Table 5: Results comparing ablative components of DocInfer model and analysis of using a single reward/relation at a time. Darker green represents better F1 performance, darker red shows negative impact. Evidence reward is applicable only for ContractNLI which has ground truth evidence annotations.
+
+| System | Fine-tune | FEVER binary | MCTest |
| v160 | v500 |
| RoBERTa | X | 88.4 | 90.0 | 85.8 |
| EvidenceNet | X | 88.7 | 90.6 | 86.0 |
| DocInfer† | X | 89.2* | 91.0* | 86.4* |
| DocInfer† w/o R | X | 86.3 | 87.5 | 82.5 |
| RoBERTa | ✓ | 89.4 | 91.0 | 91.0 |
| EvidenceNet | ✓ | 89.9 | 90.8 | 90.6 |
| DocInfer† | ✓ | 90.5* | 91.5* | 91.2* |
| DocInfer† w/o R | ✓ | 86.6 | 88.5 | 87.5 |
+
+
+
+
+(a) ConTRoL Dataset
+
+
+
+
+(b) ContractNLI Dataset
+Figure 2: Error analysis across reasoning types (accuracy%) and challenging phenomenon (mAP) on the test set of ContractNLI datasets.
+
+premise as opposed to earlier techniques of isolated vectorization and naive aggregation by (Łukasz Borchmann et al., 2020).
+
+Qualitative Analysis: Figure 2 shows qualitative analysis across different reasoning types on the test set of ConTRoL dataset. The results provide evidence that the multihop and semantic similarity rewards are important for coreference reasoning (CR) due to reasoning over multiple mentions and noun phrases. Multihop reward also helps improve Information aggregation (II) which requires combining information from multiple paragraphs. Task reward benefits logical reasoning as it focuses on logical inference of human language. DocInfer is unable to handle temporal and analytical reasoning cases. We further analyze the evidence extraction
+
+Table 6: Performance comparison of DocInfer† with RoBERTa (large) and EvidenceNet on FEVER-binary and MCTest-NLI. † means using RoBERTa as context encoder.
+
+| System | Soft F1 |
| Tf-IDF | 0.39 |
| GloVe (300D, EDGAR) | 0.41 |
| Sentence-BERT | 0.32 |
| USE | 0.38 |
| BERT | 0.35 |
| RoBERTa | 0.31 |
| GPT-1 | 0.49 |
| GPT-2 (large) | 0.51 |
| DocInfer‡(pretrain ContractNLI) | 0.53* |
| DocInfer‡w\o Paragraph Pruning | 0.42 |
| DocInfer‡w\o Task Reward (φperf) | 0.48 |
| DocInfer‡w\o Semantic Reward (φsem) | 0.45 |
| DocInfer‡w\o Evidence Reward (φbleu) | 0.45 |
| DocInfer‡w\o Multihop Reward (φmhop) | 0.44 |
| Human | 0.84 |
+
+Table 7: Performance comparison of DocInfer and its configurations pretrained on ContractNLI and tested for clause retrieval without fine-tuning on Contract Discovery dataset (Łukasz Borchmann et al., 2020). $\ddagger$ : BERT as context encoder.
+
+mAP on ContractNLI dataset across diverse challenging phenomena. Entity relations are critical for resolving reference to definitions (RD) as they are anchored together through common mentions. Concept similarity links play an important role in resolving information spread out between discontinuous spans based on commonsense reasoning. DocInfer handles evidence identification for all studied phenomena better than SpanNLI.
+
+# 6 Conclusion and Future Work
+
+We introduce DocInfer, a document-level NLI model that uses enriched hierarchical document graph through inter-sentence relations, performs paragraph pruning using SubGraph Pooling layer, and optimally selects evidence sentences using REINFORCE algorithm to outperform SOTA methods on four doc-NLI datasets, including our propose CaseHoldNLI on legal judicial reasoning.DocInfer is useful for downstream fact verification, multi-choice QA and legal clause retrieval tasks. For future work, we intend to integrate temporal knowledge and analytical reasoning into our model to improve the performance.
+
+# References
+
+Iz Beltagy, Matthew E Peters, and Arman Cohan. 2020. Longformer: The long-document transformer. arXiv preprint arXiv:2004.05150.
+David M. Blei, A. Ng, and Michael I. Jordan. 2003. Latent dirichlet allocation. J. Mach. Learn. Res., 3:993-1022.
+Samuel R Bowman, Gabor Angeli, Christopher Potts, and Christopher D Manning. 2015. A large annotated corpus for learning natural language inference. arXiv preprint arXiv:1508.05326.
+Ilias Chalkidis, Manos Fergadiotis, Prodromos Malakasiotis, Nikolaos Aletras, and Ion Androutsopoulos. 2020. Legal-bert: The muppets straight out of law school. arXiv preprint arXiv:2010.02559.
+Chonghao Chen, Fei Cai, Xuejun Hu, Wanyu Chen, and Honghui Chen. 2021. Hhgn: A hierarchical reasoning-based heterogeneous graph neural network for fact verification. Information Processing & Management, 58(5):102659.
+Zhen-Heng Chen, Siu Cheung Hui, Fuzhen Zhuang, Lejian Liao, Fei Li, Meihuizi Jia, and Jiaqi Li. 2022. Evidencenet: Evidence fusion network for fact verification. Proceedings of the ACM Web Conference 2022.
+Ido Dagan, Bill Dolan, Bernardo Magnini, and Dan Roth. 2010. Recognizing textual entailment: Rational, evaluation and approaches-erratum. Natural Language Engineering, 16(1):105-105.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805.
+Yuwei Fang, Siqi Sun, Zhe Gan, Rohit Pillai, Shuohang Wang, and Jingjing Liu. 2019. Hierarchical graph network for multi-hop question answering. arXiv preprint arXiv:1911.03631.
+Hongyang Gao and Shuiwang Ji. 2019. Graph u-nets. In international conference on machine learning, pages 2083-2092. PMLR.
+Tianyu Gao, Xingcheng Yao, and Danqi Chen. 2021. Simcse: Simple contrastive learning of sentence embeddings. arXiv preprint arXiv:2104.08821.
+Daniele Grattarola, Daniele Zambon, Filippo Maria Bianchi, and Cesare Alippi. 2021. Understanding pooling in graph neural networks. ArXiv, abs/2110.05292.
+Andreas Hanselowski, H. Zhang, Zile Li, Daniil Sorokin, Benjamin Schiller, Claudia Schulz, and Iryna Gurevych. 2018. Ukp-athene: Multi-sentence textual entailment for claim verification. ArXiv, abs/1809.01479.
+
+Pengcheng He, Xiaodong Liu, Jianfeng Gao, and Weizhu Chen. 2020. Deberta: Decoding-enhanced bert with disentangled attention. arXiv preprint arXiv:2006.03654.
+Nils Holzenberger, Andrew Blair-Stanek, and Benjamin Van Durme. 2020. A dataset for statutory reasoning in tax law entailment and question answering. arXiv preprint arXiv:2005.05257.
+Kelvin Jiang, Ronak Pradeep, Jimmy J. Lin, and David R. Cheriton. 2021. Exploring listwise evidence reasoning with t5 for fact verification. In ACL.
+Xiaomian Kang, Yang Zhao, Jiajun Zhang, and Chengqing Zong. 2020. Dynamic context selection for document-level neural machine translation via reinforcement learning. *ArXiv*, abs/2010.04314.
+Yuta Koreeda and Christopher Manning. 2021. ContractNLI: A dataset for document-level natural language inference for contracts. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 1907-1919, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Junhyun Lee, Inyeop Lee, and Jaewoo Kang. 2019. Self-attention graph pooling. In International conference on machine learning, pages 3734-3743. PMLR.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. Bart: Denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In ACL.
+Ronghan Li, Lifang Wang, Shengli Wang, and Zejun Jiang. 2021. Asynchronous multi-grained graph network for interpretable multi-hop reading comprehension. In IJCAI, pages 3857-3863.
+Hongbin Lin and Xianghua Fu. 2022. Heterogeneous-graph reasoning and fine-grained aggregation for fact checking. Proceedings of the Fifth Fact Extraction and VERIFICATION Workshop (FEVER).
+Hanmeng Liu, Leyang Cui, Jian Liu, and Yue Zhang. 2021. Natural language inference in context-investigating contextual reasoning over long texts. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pages 13388-13396.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019a. Roberta: A robustly optimized bert pretraining approach. ArXiv, abs/1907.11692.
+Zhenghao Liu, Chenyan Xiong, Maosong Sun, and Zhiyuan Liu. 2019b. Fine-grained fact verification with kernel graph attention network. arXiv preprint arXiv:1910.09796.
+
+Puneet Mathur, Franck Dernoncourt, Quan Hung Tran, Jiuxiang Gu, Ani Nenkova, Vlad Morariu, Rajiv Jain, and Dinesh Manocha. 2022a. Doclayoutts: Dataset and baselines for layout-informed document-level neural speech synthesis. Proc. Interspeech 2022, pages 451-455.
+Puneet Mathur, Rajiv Jain, Franck Dernoncourt, Vlad Morariu, Quan Hung Tran, and Dinesh Manocha. 2021. Timers: document-level temporal relation extraction. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 524-533.
+Puneet Mathur, Vlad Morariu, Verena Kaynig-Fittkau, Jiuxiang Gu, Franck Dernoncourt, Quan Hung Tran, Ani Nenkova, Dinesh Manocha, and Rajiv Jain. 2022b. Dovertime: A document-level temporal dependency graph parser. In Proceedings of the 2022 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 993-1009.
+Nghia Trung Ngo, Tuan Ngo Nguyen, and Thien Huu Nguyen. 2020. Learning to select important context words for event detection. In *Pacific-Asia Conference on Knowledge Discovery and Data Mining*, pages 756–768. Springer.
+Yixin Nie, Haonan Chen, and Mohit Bansal. 2019. Combining fact extraction and verification with neural semantic matching networks. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 33, pages 6859-6866.
+Juliano Rabelo, Mi-Young Kim, Randy Goebel, Masaharu Yoshioka, Yoshinobu Kano, and Ken Satoh. 2020. Coliee 2020: methods for legal document retrieval and entailment. In JSAI International Symposium on Artificial Intelligence, pages 196-210. Springer.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. 2019a. Exploring the limits of transfer learning with a unified text-to-text transformer. arXiv preprint arXiv:1910.10683.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. 2019b. Exploring the limits of transfer learning with a unified text-to-text transformer. arXiv preprint arXiv:1910.10683.
+Matthew Richardson, Christopher JC Burges, and Erin Renshaw. 2013. Mctest: A challenge dataset for the open-domain machine comprehension of text. In Proceedings of the 2013 conference on empirical methods in natural language processing, pages 193-203.
+Jiasheng Si, Deyu Zhou, Tongzhe Li, Xingyu Shi, and Yulan He. 2021. Topic-aware evidence reasoning
+
+and stance-aware aggregation for fact verification. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), Online. Association for Computational Linguistics.
+Shyam Subramanian and Kyumin Lee. 2020. Hierarchical evidence set modeling for automated fact extraction and verification. In EMNLP.
+James Thorne, Andreas Vlachos, Christos Christodoulopoulos, and Arpit Mittal. 2018. Fever: a large-scale dataset for fact extraction and verification. arXiv preprint arXiv:1803.05355.
+Hieu Man Duc Trong, Nghia Ngo Trung, Linh Van Ngo, and Thien Huu Nguyen. 2022. Selecting optimal context sentences for event-event relation extraction.
+Petar Velicković, Guillem Cucurull, Arantxa Casanova, Adriana Romero, Pietro Lio, and Yoshua Bengio. 2017. Graph attention networks. arXiv preprint arXiv:1710.10903.
+Amir Pouran Ben Veyseh, Minh Van Nguyen, Nghia Ngo Trung, Bonan Min, and Thien Huu Nguyen. 2021. Modeling document-level context for event detection via important context selection. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 5403-5413.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R Bowman. 2018. Glue: A multi-task benchmark and analysis platform for natural language understanding. arXiv preprint arXiv:1804.07461.
+Adina Williams, Nikita Nangia, and Samuel Bowman. 2018. A broad-coverage challenge corpus for sentence understanding through inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 1112-1122, New Orleans, Louisiana. Association for Computational Linguistics.
+Adina Williams, Nikita Nangia, and Samuel R Bowman. 2017. A broad-coverage challenge corpus for sentence understanding through inference. arXiv preprint arXiv:1704.05426.
+Ronald J Williams. 1992. Simple statistical gradient-following algorithms for connectionist reinforcement learning. Machine learning, 8(3):229-256.
+Keyulu Xu, Weihua Hu, Jure Leskovec, and Stefanie Jegelka. 2018. How powerful are graph neural networks? arXiv preprint arXiv:1810.00826.
+Wenpeng Yin, Dragomir Radev, and Caiming Xiong. 2021. Docnli: A large-scale dataset for document-level natural language inference. arXiv preprint arXiv:2106.09449.
+
+Manzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie, Chris Alberti, Santiago Ontañón, Philip Pham, Anirudh Ravula, Qifan Wang, Li Yang, and Amr Ahmed. 2020. Big bird: Transformers for longer sequences. ArXiv, abs/2007.14062.
+Min Zhang, Feng Li, Yang Wang, Zequn Zhang, Yanhai Zhou, and Xiaoyu Li. 2020. Coarse and fine granularity graph reasoning for interpretable multi-hop question answering. IEEE Access, 8:56755-56765.
+Chen Zhao, Chenyan Xiong, Corby Rosset, Xia Song, Paul N. Bennett, and Saurabh Tiwary. 2020. Transformer-xh: Multi-evidence reasoning with extra hop attention. In ICLR.
+Lucia Zheng, Neel Guha, Brandon R Anderson, Peter Henderson, and Daniel E Ho. 2021. When does pretraining help? assessing self-supervised learning for law and the casehold dataset of $53,000+$ legal holdings. In Proceedings of the Eighteenth International Conference on Artificial Intelligence and Law, pages 159-168.
+Wanjun Zhong, Jingjing Xu, Duyu Tang, Zenan Xu, Nan Duan, Ming Zhou, Jiahai Wang, and Jian Yin. 2020. Reasoning over semantic-level graph for fact checking. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, Online. Association for Computational Linguistics.
+Jie Zhou, Xu Han, Cheng Yang, Zhiyuan Liu, Lifeng Wang, Changcheng Li, and Maosong Sun. 2019. Gear: Graph-based evidence aggregating and reasoning for fact verification. arXiv preprint arXiv:1908.01843.
+Łukasz Borchmann, Dawid Wisniewski, Andrzej Gretkowski, Izabela Kosmala, Dawid Jurkiewicz, Lukasz Szalkiewicz, Gabriela Pałka, Karol Kaczmarek, Agnieszka Kaliska, and Filip Grali'nski. 2020. Contract discovery: Dataset and a few-shot semantic retrieval challenge with competitive baselines. In FINDINGS.
+
+# Appendix
+
+# A Limitations
+
+Through careful analysis of error cases, we found that there are two main types of prediction errors from the proposed model. First, the model is unable to reason over temporal and causal aspects. For example, in the hypothesis "Repayment terms will be finalized before disbursement but prior to loan approval" while the evidence states "Repayment terms are subject to loan approval and monthly disbursement of interest amount". DocInfer does not recognize the fact that there is a temporal order between events "repayment", "approval", and "disbursement". Tackling this type of error requires temporal relation prediction between different events. The second type of errors is mainly due to contradictory/missing information in the retrieved evidence required for analytical inference. For example, the model predicts that the hypothesis "Insurance prices are all time high" contradicts with evidences "Insurance prices increase with increase in pollution" and "Protest marches for restoring pollution control board were censored". The model prunes a relevant piece of evidence - "Pollution control board tabled policy for curbing air contamination in residential areas" in an otherwise irrelevant paragraph which causes loss of logical flow. Potential Risks: Our models are exploratory and academic in nature and should not be used for real-world legal/contractual/healthcare purposes without extensive investigations into its shortcomings/randomness/biases. Unhandled Cases: The current work is limited to English language and would need suitable tools in other languages to process semantic similarity, concept knowledge and topic models. Moreover, our method has been tested on limited domains of Wikipedia text, narrative stories, exam-style questions, case laws, and contracts. Applying it to life-critical scenarios such as healthcare, public safety will need further investigations.
+
+# B Ethics Statement
+
+We utilize three publicly available datasets - Doc-NLI, ContractNLI and ConTRoL for evaluating document-level NLI. We also curated dataset for doc-level NLI on legal judicial case documents. We source these contract documents from a publicly available resource - CaseHOLD dataset (Zheng et al., 2021). We repurpose the dataset for our
+
+task and provide new annotations. CaseHoldNLI dataset does not violate any privacy as these documents are already in public domain as part of Harvard Case Law Corpus2. There is no human bias involved in such documents as they are already annotated expertly and provided openly after anonymizing any identifiable information. These documents do not restrict reuse for academic purposes and any personal information was already redacted before their original release. All documents and our experiments are restricted to English language. FEVER-binary, MCTest, and Contract Discovery datasets are also publicly available for research purposes. There was no sensitive data involved in the studies.
+
+# C Impact of Input Length
+
+DocInfer achieves SOTA performance on all four datasets and maintains steady improvements over corresponding baseline models with increasing in input lengths for performance vs premise length comparison for ConTROL, DocNLI, ContractNLI, and CaseHoldNLI datasets.
+
+# D Experiments on Downstream Tasks
+
+# D.1 Fact Verification
+
+The NLI-version of FEVER (Thorne et al., 2018) task, released by Nie et al. (2019), considers each claim as a hypothesis while the premises consist of ground truth textual evidence and some other randomly sampled related text. Yin et al. (2021) combined the "refute" and "not-enough-info" labels into a single class of "not entail", organized the dataset into train/dev/test split of 203,152/8,209/10,000 and renamed it as "FEVER-binary".
+
+# D.2 Multi-choice Question Answering
+
+MCTest (Richardson et al., 2013) is a multi-choice QA benchmark in the domain of fictional story with one correct and three incorrect answers. The NLI-version MCTest combines the question and the positive (negative) answer candidate as a positive (negative) hypothesis. We test two versions of MCTest - MCTest-160 (70 train, 30 dev, 60 test) and MCTest-500 (300 train, 50 dev, 150 test). Presence of limited labeled data makes it a good benchmark to investigate the performance of document-level NLI models on annotation-scarce tasks. We evaluate DocInfer trained on DocNLI dataset and report F1 scores for both tasks.
+
+# D.3 Contract Clause Retrieval
+
+Clause Discovery (Łukasz Borchmann et al., 2020) is a task to identify spans in a target document representing clauses analogous (i.e. semantically and functionally equivalent) to the provided seed clauses from source documents. We reformulate this as an NLI task where the seed clauses are concatenated to form the hypothesis, and the target document is the premise. We test the evidence selection capabilities of DocInfer for identifying relevant sentence-level spans in the premise. To this end, we test DocInfer trained on ContractNLI dataset without supervision for the clause retrieval task. The dataset has 1300 test examples and we tuned the paragraph selection hyperparameter $\eta$ on the validation set of 1300 examples. We followed the evaluation framework specified in Łukasz Borchmann et al. (2020) of few (1-5) shot setting and report Soft F1 score.
+
+# E Data Statistics
+
+We present the dataset statistics in Table 8.
+
+# A1: Limitations:
+
+Through careful analysis of error cases, we found two main types of prediction errors from the proposed model: (1) unable to reason over temporal and causal relations; (2) contradictory/missing information in the retrieved evidence required for analytical inference.
+
+# A2: Potential Risks:
+
+Our models are exploratory and academic in nature ans should not be used for real-world legal/contractual/healthcare purposes without extensive investigations into its shortcomings/randomness/biases.
+
+# B1: Citation to creators of artifacts:
+
+We use four datasets: (i) DocNLI (Yin et al., 2021), (ii) ContractNLI (Koreeda and Manning, 2021), (iii) ConTRoL (Liu et al., 2021), (iv) CaseHold (Zheng et al., 2021). We repurpose the fourth dataset for doc-level NLI task All datasets and documents are publicly available.
+
+Further, we use three datasets for downstream applications: (i) FIVER-binary (Nie et al., 2019), (ii) MCTest (Richardson et al., 2013), (iii) Contract Discovery (Łukasz Borchmann et al., 2020).
+
+DocNLI Dataset: https://github.com/salesforce/DocNLI
+
+ContractNLI Dataset: https://stanfordnlp.github.io/contract-nli/
+
+ConT RoL Dataset: https://github.com/csitfun/ ConT RoL-dataset
+
+CaseHold Dataset: https://github.com/reglab/casehold
+
+Contract Discovery Dataset: https://github.com/applicai/contract-discovery
+
+# B2: License and terms for use of data artifacts:
+
+All the datasets are available to use for research purposes.
+
+# B3: Intended use of data artifacts:
+
+The intended use of NLI datasets is to improve NLP reasoning and semantic understanding of text and languages. Use cases in legal and contract domains can make increase accessibility amongst non-experts and lead to AI for social good.
+
+# B4: Steps taken to protect / anonymize names, identities of individual people or offensive content:
+
+We do not use any identifiable user data for any experiments. All persons mentioned in the dataset are anonymous or have their information publicly available.
+
+# B5: Coverage of domains, languages, linguistic phenomena, demographic groups represented in data:
+
+Our work uses NLI dataset from Wikipedia, story narrations, exam questions, contracts and case laws in English language. Adaptation to other languages may need appropriate processing.
+
+# B6: Data statistics (train/test/dev splits):
+
+The data statistics are given in Table 8.
+
+# E.1 Training Setup
+
+Hyperparameters: We tune the hyperparameters for the proposed model using a grid search. All the hyperparameters are selected based on the F1 scores on the development set to find the best configurations for different datasets. In our model we use the BERT-base to encode document embeddings; LSTM and 2 layers for feed forward neural networks. The trade-off parameters $\alpha$ , $\beta$ and $\gamma$ are set to 0.5, 0.1, 0.05, respectively. We use Adam optimizer and the batch size of 16 is employed during training. We vary paragraph selection $\eta$ between 1 to 10.
+
+| Dataset | Original Task | Domain | Premise Length | Hypothesis Length | Evidence | Train | Validation | Test |
| E | C | N | T | E | C | N | T | E | C | N | T |
| DocNLI (Yin et al., 2021) | NLI | Wiki, News | Doc (~318, <26K) | Para (~51, <252) | ✗ | 466K | 475K | - | 942K | 28K | 205K | - | 234K | 33K | 233K | - | 267K |
| ContractNLI (Koreeda and Manning, 2021) | NLI | NDA Contracts | Doc (~2254, <11.5K) | Sent (~13, <23) | ✓ | 3530 | 841 | 2820 | 7191 | 519 | 95 | 423 | 1037 | 968 | 220 | 903 | 2091 |
| ConTroL (Liu et al., 2021) | NLI | Exam | Doc (~441, <1604) | Multi-Sent (~12, <93) | ✗ | 2480 | 2293 | 1946 | 6719 | 286 | 276 | 237 | 799 | 327 | 242 | 236 | 805 |
| CaseHoldNLI (Zheng et al., 2021) | MCQ | Legal Case Laws | Doc (~143, <3328) | Multi-Sent (~28, <156) | ✗ | 43K | 174K | - | 217K | 5.4K | 21.6K | - | 27K | 5.4K | 21.6K | - | 27K |
+
+Table 8: Data statistics for DocNLI, ContractNLI, ConTRoL, and CaseHoldNLI datasets. The average $(\sim)$ and maximum $(<)$ lengths of the premise and hypothesis were measured by NLTK tokenization. We describe the train/validation/test distributions across labels C: Contradiction, E: Entailment, N: Neutral, T: Total. $(-)$ indicates non-existent, LightCyan is our contribution.
+
+ | Dataset |
| Hyperparameters | DocNLI | ContractNLI | ConTRoL | CaseHoldNLI |
| Dropout Ratio | 0.4 | 0.3 | 0.3 | 0.5 |
| Optimizer | Adam | Adam | Adam | Adam |
| GAT Layers | 2 | 2 | 2 | 2 |
| Input Dimension (gout) | (n,256) | (n,256) | (n,256) | (n,256) |
| Input Dimension (Dense) | (n,1024) | (n,1024) | (n,1024) | (n,1024) |
| Hidden Dimension | 200 | 200 | 200 | 200 |
| Epochs | 20 | 20 | 20 | 20 |
| Batch Size | 16 | 16 | 16 | 16 |
| Activation Function of Linear layers | ReLU | ReLU | ReLU | ReLU |
| Output Classes | 2 | 3 | 3 | 2 |
+
+Table 9: Hyperparameter Details: Training hyperparameters of DcInfer for DocNLI, ContractNLI, ConTRol and CaseHoldNLI datasets.
+
+We summarize the range of our model's hyper parameters such as: size of hidden layers in LSTM $\{100,200,300\}$ , size of hidden layers in FFN $\{100,200,300,400\}$ , BERT embedding size, dropout $\delta \in \{0.2,0.3,0.4,0.5,0.6\}$ , learning rate $\lambda \in \{1e - 5,2e - 5,3e - 5,4e - 5,5e - 5\}$ , weight decay $\omega \in \{1e - 6,1e - 5,1e - 4,1e - 3\}$ , batch size $b\in \{16,32,64\}$ and epochs $(\leq 100)$ .
+
+Contextual Encoder: We used BERT-base-uncased for generating token embedding of size 1x 768. As BERT-base Transformer provides a stronger baseline as compared to RoBERTa, we utilized BERT Transformer for Contextual Encoder in DocInfer architecture. We use the default dropout rate (0.1) on BERT's self attention layers but do not use additional dropout at the top linear layer. The output from the Contextual Encoder is a 1-D vector of size 768.
+
+Loss Function and Inference: DocInfer is trained end to end using Cross Entropy loss for context encoder and REINFORCE loss for evidence selection with Adam optimizer. Across all four datasets, we found the best results correspond with the use of Adam optimiser set with default values $\beta_{1} = 0.9$ , $\beta_{2} = 0.999$ , $\epsilon = 1e - 8$ , weight-decay of $5e - 4$ and an initial learning rate of 0.001. We evaluate the performance of NLI prediction with the following corresponding metrics for each dataset:
+
+DocNLI: devF1, test F1
+- ContractNLI: NLI label using Acc $(\%)$ , F1(entsails), F1(contradicts), Evidence extrac
+
+tion using mAP,PR@80 precision and recall score.
+
+- ConTRoL: Acc(%, F1(E), F1(C), F1(N), F1(Overall)
+- CaseHold: P, R, F1
+- MCTest: F1
+- FEVER-binary: F1
+- Contract Discovery: Soft F1
+
+Parameter Size: Our model's total parameters is asymptotically close to the context encoder it uses in the backbone. Our model does not add a lot more parameters than the existing context encoder.
+
+# C4: Implementation Software and Packages
+
+We implemented our solution in Python 3.6 using PyTorch framework. We used the following libraries and modules:
+
+Huggingface's implementation for BERT/RoBERTa/BART/Legal-BERT/T5/Longformer/BigBird transformers.
+- PyTorch Geometric3 for graph learning methods.
+- LDA-Pypi package for topical relations.
+
+- Standford CoreNLP $^5$ , Spacy $^6$ , and
+- AllenNLP Library7 for coreference and Named Entity Recognition in entity relations.
+- ConceptNet Numberbatch8 and KnowBert9 for concept relations.
+- SimCSE embeddings10 for semantic reward.
+- Bleu-Pypi $^{11}$ library for evidence reward.
\ No newline at end of file
diff --git a/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/images.zip b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..0a7c61a934ef0df9ab869f8948edbd2f434a04cb
--- /dev/null
+++ b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cb4cf7bb0e28c03d85d28c84f88ab4be40f5a30f8f19d7865f3d09f379268be3
+size 484959
diff --git a/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/layout.json b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2657f7fbc175ab023aa22088003ca48067aee9f8
--- /dev/null
+++ b/docinferdocumentlevelnaturallanguageinferenceusingoptimalevidenceselection/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:75490edd6b5f5e56a77da3d736e6711dd47430b2c904087f52725262af1d9a95
+size 565840
diff --git a/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_content_list.json b/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..ef9e678220c72a23d9998356efdecfc659bccb3c
--- /dev/null
+++ b/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5016cbb09cd862a88e0b59997bcb4dd096524178cab6dd2ef173a5c2114007e4
+size 52714
diff --git a/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_model.json b/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..acf30ff38161d8ffe02a50d1b020065c1b8ae5a8
--- /dev/null
+++ b/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:41c883356e468f2173cdd6d09b4d06a64dcd92570ebf4f94f6824937e16d1732
+size 58893
diff --git a/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_origin.pdf b/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4b11e60900bb12d76cdcf1d1c3ef70dd01b64c2a
--- /dev/null
+++ b/doescorpusqualityreallymatterforlowresourcelanguages/f839afc6-67cd-43f4-acef-a364ae2b6ca5_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9c6556edad46d05e6746a777e6cb089a23453de1be1202855399e06b287c58ab
+size 251561
diff --git a/doescorpusqualityreallymatterforlowresourcelanguages/full.md b/doescorpusqualityreallymatterforlowresourcelanguages/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..a41a8251d4e256ea6488da286706f7a3cf770595
--- /dev/null
+++ b/doescorpusqualityreallymatterforlowresourcelanguages/full.md
@@ -0,0 +1,183 @@
+# Does Corpus Quality Really Matter for Low-Resource Languages?
+
+Mikel Artetxe1 Itziar Aldabe2 Rodrigo Agerri2 Olatz Perez-de-Viñaspre2 Aitor Soroa2 1Meta AI
+
+$^{2}$ HiTZ Center, University of the Basque Country (UPV/EHU) artetxe@meta.com
+
+{itziar.aldabe,rodrigo.agerri,olatz.perezdevinaspre,a.soroa}@ehu.eus
+
+# Abstract
+
+The vast majority of non-English corpora are derived from automatically filtered versions of CommonCrawl. While prior work has identified major issues on the quality of these datasets (Kreutzer et al., 2021), it is not clear how this impacts downstream performance. Taking representation learning in Basque as a case study, we explore tailored crawling—manually identifying and scraping websites with high-quality content—as an alternative to filtering CommonCrawl. Our new corpus, called EusCrawl, is similar in size to the Basque portion of popular multilingual corpora like CC100 and mC4, yet it has a much higher quality according to native annotators. For instance, $66\%$ of documents are rated as high-quality for EusCrawl, in contrast with $<33\%$ for both mC4 and CC100. Nevertheless, we obtain similar results on downstream NLU tasks regardless of the corpus used for pre-training. Our work suggests that NLU performance in low-resource languages is not primarily constrained by the quality of the data, and other factors like corpus size and domain coverage can play a more important role.
+
+# 1 Introduction
+
+Large-scale pre-training has resulted in a paradigm shift in NLP (Bommasani et al., 2021). While recent progress has been primarily driven by scaling up on model size and compute, both data quantity and quality have been shown to play a critical role (Kaplan et al., 2020; Rae et al., 2022). Nevertheless, existing efforts on data curation have primarily focused on English, and recent work on multilingual pre-training has relied on automatically filtered versions of CommonCrawl. For instance, XLM-R was trained on CC100 (Conneau et al., 2020), mT5 was trained on mC4 (Xue et al., 2021), and XGLM was trained on CC100-XL (Lin et al., 2021), which were all obtained by running language identification on several CommonCrawl snapshots and filtering through language-agnostic
+
+approaches. Unfortunately, Kreutzer et al. (2021) identified major issues on the quality of such multilingual datasets, ranging from language identification errors to boilerplate and non-linguistic content. However, the practical impact of these issues has not been studied, and it is unclear the extent to which higher-quality data could lead to better performance in low-resource languages.
+
+In this paper, we take representation learning in Basque as a case study, and explore tailored crawling (i.e., manually identifying and scraping websites with high-quality content) as an alternative to filtering CommonCrawl. We introduce EusCrawl, a new corpus for Basque comprising 12.5M documents from 33 websites with Creative Commons content. EusCrawl is similar in size to the Basque portion of CC100 and mC4, but it has substantially less issues and a higher perceived quality according to our blind audit with native annotators. However, we find that this improvement does not carry over to downstream NLU tasks, as masked language models pre-trained on either corpora obtain similar results on 5 benchmarks. Our results suggest that data quantity and domain coverage play a more important role, prompting for methods to exploit more diverse sources of data in low-resource languages.
+
+This paper makes the following contributions: (i) we release EusCrawl, a high-quality corpus for Basque comprising 12.5M documents and 423M tokens; (ii) we manually assess the quality of EusCrawl in comparison with mC4 and CC100, finding that it has substantially less issues and a higher perceived quality according to native annotators; (iii) we compare masked language models pretrained on EusCrawl, mC4, CC100 and Wikipedia $^2$ on 5 NLU tasks, finding that they all perform similarly with the exception of Wikipedia; and (iv)
+
+ | Size | Tokens | Docs | Source |
| mC4 (Xue et al., 2021) | 4,387MiB | 1,004M | 30,098k | Filtered CommonCrawl |
| CC100 (Conneau et al., 2020) | 2,027MiB | 416M | 16,761k | Filtered CommonCrawl |
| Wikipedia | 313MiB | 66M | 2,685k | Wikipedia dump |
| EusCrawl (ours) | 2,149MiB | 423M | 12,528k | Tailored crawling (see Table 2) |
+
+Table 1: Basque corpora used in our experiments. We report uncompressed text size, number of SentencePiece tokens (using a 50K vocabulary learned in each corpus), and number of documents.
+
+ | Size | Tokens | Docs | License | Domain |
| Tokikom† | 784MiB | 153M | 4,961k | CC-BY-SA | Local media |
| Berria | 525MiB | 101M | 2,193k | CC-BY-SA | National newspaper |
| Hitza‡ | 418MiB | 80M | 2,257k | CC-BY-NC-ND | Regional newspapers |
| Wikipedia | 313MiB | 68M | 2,685k | CC-BY-SA | Encyclopedia |
| Argia | 101MiB | 20M | 370k | CC-BY-SA | News magazine |
| Bilbo Hiria irratia | 7MiB | 1M | 54k | CC-BY-NC-SA | Radio station |
| Sarean | 2MiB | 0.3M | 8k | CC-BY-SA | Technology blog |
+
+Table 2: Data sources used to build EusCrawl. $^\dagger$ Tokikom is a network of local media; we include Aiaraldea, Aikor, Anboto, Tolosaldeko Ataria, Aiurri, Erran, Euskalerria Irratia, Goiana, Guaixe, Hiruka, Karkara, Maxixatzen, Plaentxia, Alea, Noaua, Txintxarri, Uztarria, Amezti, Zarauzko Hitza, Kronika and Geuria. $^\ddagger$ Hitza is a family of regional newspapers; we include Bidasoko Hitza, Busturialdeko Hitza, Goierriko Hitza, Irutxuloko Hitza, Lea-Artibai eta Mutrikuko Hitza, Oarsoaldeko Hitza and Urola Kostako Hitza.
+
+we obtain state-of-the-art results on several NLU benchmarks in Basque, outperforming prior work that relied on non-public corpora.
+
+# 2 Experimental setup
+
+We next detail the corpora compared in our experiments (§2.1), and the qualitative and downstream evaluation settings (§2.2 and §2.3).
+
+# 2.1 Corpora
+
+We compare 4 Basque corpora in our experiments: mC4, CC100, Wikipedia and EusCrawl. Table 1 summarizes their details. $\mathbf{mC4}^3$ and $\mathbf{CC100}^4$ are, to the best of our knowledge, the two largest public corpora for Basque. They were introduced to train mT5 (Xue et al., 2021) and XLM-R (Conneau et al., 2020), respectively, and were built by filtering CommonCrawl. Wikipedia has been a popular source for multilingual data (Pires et al., 2019; Conneau and Lample, 2019; Artetxe et al., 2020). We extract text from a Wikipedia dump using the WikiExtractor tool.5 EusCrawl is a new corpus we introduce. Instead of filtering CommonCrawl, we do tailored crawling on 33 websites with high-quality content in Basque, mostly on the news
+
+domain. We build ad-hoc scrapers to extract text from these websites, resulting in higher coverage $^{6}$ and cleaner text compared to general purpose approaches. We only use content with a Creative Commons license. Table 2 summarizes all the sources we use.
+
+# 2.2 Qualitative evaluation
+
+We manually audit the quality of EusCrawl in comparison with mC4 and CC100 by randomly sampling 100 documents from each corpus (a total of 300 documents), and asking native annotators to assess their quality. We ensure that the evaluation is blind by showing the documents in a random order and not revealing what corpus they were sampled from. For each document, we ask the annotators to assess if the document has any problem in each of the following categories: langID (the document is not in Basque), language variety (the document is not written in standard and correct Basque), coherence (the document has gaps and/or some portions are not connected), noise (the document is
+
+
+Figure 1: Data audit results. EusCrawl has a much higher quality than mC4 and CC100. See §2.2 for more details.
+
+
+
+not clean) and content (the document seems to have been generated automatically and/or has no meat). In addition, we ask annotators to classify each document according to its perceived quality as high-quality (the document does not have quality issues and the annotator thinks that it would be good to have it in the corpus), medium-quality (the document has some minor issues and the annotator is unsure if it would be good to have it in the corpus), or low-quality (the document has major issues and the annotator thinks that it would be better not to have it in the corpus). Refer to Appendix A for the complete instructions given to annotators.
+
+# 2.3 Downstream evaluation
+
+In addition to the qualitative evaluation, we pretrain RoBERTa models (Liu et al., 2019) on each corpus, and evaluate fine-tuning them on the following NLU benchmarks: topic classification on BHTC (Agerri et al., 2020), sentiment classification on Behagune (Agerri et al., 2020), stance detection on VaxxStance (Agerri et al., 2021), Named Entity Recognition (NER) on EIEC (Alegria et al., 2006), and extractive conversational Question Answering (QA) on Elkarrizketak (Otegi et al., 2020). We provide additional details on these datasets in Appendix B.
+
+We pre-train each model for 125k steps with a batch size of 2048 and a sequence length of 512, using the same hyperparameters as Liu et al. (2019). We train RoBERTa-base models for our main comparison using a learning rate of 7e-4, and further train a RoBERTa-large model on EusCrawl with a learning rate of 4e-4 to understand the effect of scaling. In all cases, we use the final checkpoint without early stopping. We use SentencePiece (Kudo and Richardson, 2018) for tokenization, using a 50k vocabulary learned in each separate corpus.
+
+For fine-tuning, we use the same hyperparameters as Agerri et al. (2020). For topic classification, sentiment classification and stance detection, we use a batch size of 16, a learning rate of 2e-5 with linear decay and a warmup of $6\%$ , and train the model for 10 epochs. For NER and QA, we use a batch size of 32, a constant learning rate of 5e-5, and train for 4 epochs. We did not perform any hyperparameter tuning or model selection, and report results on the test set. The development sets, when available, were not used.
+
+# 3 Results
+
+# 3.1 Qualitative evaluation
+
+As shown in Figure 1, EusCrawl has the best quality by a large margin in all the axes that we consider. mC4 has a slightly higher perceived quality and less content-related issues than CC100, but more problematic documents in the other categories.
+
+More concretely, we find that both mC4 and CC100 have a high proportion of documents with coherence, noise and content-related issues. In addition, mC4 has a significant number of langID and language variety problems. In contrast, EusCrawl has minimal issues in all categories but content, where it still does substantially better than mC4 and CC100. Taking a closer look, we find that most of these content-related issues in EusCrawl correspond to short, template-based Wikipedia articles (e.g., Placosoma is a genus of lizards in the family Gymnophthalmidae. They live in Brazil.8), which should be easy to filter in future iterations. Finally, we find that the overall quality of EusCrawl documents is also much better according to native annotators, with approximately two thirds of the docu
+
+ | Topic class. | Sentiment | Stance det. | NER | QA | Avg |
| Prior best | Agerri et al. (2020) | 76.8 | 78.1 | - | 87.1 | - | - |
| Otegi et al. (2020) | - | - | - | - | 35.0 | - |
| Lai et al. (2021) | - | - | \(57.3^{\dagger}\) | - | - | - |
| RoBERTa-base | | mC4 | \(80.4 \pm 1.5\) | 59.1 ±5.2 | 86.0 ±1.0 | 35.2 ±1.8 | 67.2 |
| CC100 | \(78.8 \pm 1.2\) | \(63.4 \pm 3.5\) | 85.2 ±1.2 | 35.8 ±1.1 | 67.9 |
| Wikipedia | 70.0 ±0.8 | 53.2 ±4.6 | 71.6 ±13.1 | 27.4 ±0.2 | 58.9 |
| EusCrawl | \(76.2 \pm 0.6\) | 57.4 ±4.7 | 86.8 ±0.6 | 34.6 ±1.8 | 66.5 |
| RoBERTa-large | | EusCrawl | \(77.6 \pm 0.5\) | 62.9 ±2.3 | 87.2 ±0.4 | 38.3 ±1.3 | 69.0 |
+
+Table 3: Downstream results. We report average F1 and standard deviation across 5 runs (micro F1 in all tasks except stance detection, where we report macro F1 of the favor and against classes following common practice). $\dagger$ Best result among systems that rely exclusively on textual data.
+
+ments being annotated as high-quality, compared to less than one third for both mC4 and CC100.
+
+All in all, our qualitative evaluation provides further evidence that multilingual corpora derived from CommonCrawl have major quality issues, and shows that tailored crawling can be an effective alternative to obtain high-quality data.
+
+# 3.2 Downstream tasks
+
+We report our downstream results in Table 3.
+
+In contrast with the qualitative evaluation, we find that there is not a clear winner among mC4, CC100 and EusCrawl. In fact, when looking at RoBERTa-base results, we find that mC4 does the best on sentiment classification, CC100 does the best on stance detection and QA, and EusCrawl does the best on NER. Wikipedia lags behind them all by a large margin. It is worth noting that the variance is high in certain tasks, which we attribute to the small size of the test sets and their unbalanced nature, but the general trends are consistent.
+
+These results suggest that corpus quality issues in low-resource languages do not have a major impact on NLU performance. Instead, we find evidence that it is the size and domain of the training corpus that is more important. This would explain why Wikipedia obtains the worst results, as it is substantially smaller than the other corpora and restricted to a narrow domain. Similarly, this is also consistent with EusCrawl performing worse than mC4 and CC100 on sentiment analysis and stance detection, as the domain of these benchmarks (tweets) is different from the domain of EusCrawl (primarily news, see Table 2), while CommonCrawl-derived corpora are presumably more diverse.
+
+Finally, we find that scaling to RoBERTa-large brings consistent improvements in all tasks.
+
+Thanks to this, we are able to outperform the best published results in all the 5 benchmarks. Note that we achieve this pre-training exclusively on Creative Commons data that we release publicly, while prior work relied on private datasets.
+
+# 4 Conclusions
+
+Taking Basque as a case study, our work gives further evidence that CommonCrawl-derived corpora have major quality issues in low-resource languages. At the same time, we show that ad-hoc crawling websites with high-quality content can be an effective alternative to collect data in such languages. Our resulting corpus EusCrawl has a higher quality than mC4 and CC100 according to our manual data audit, while being similar in size. Nevertheless, this improvement in quality does not carry over to downstream performance on NLU tasks, where we find evidence that data quantity and domain coverage are more important factors.
+
+Our work leaves important lessons for future efforts on low-resource languages. First of all, we find that, even if CommonCrawl derived multilingual corpora do have major quality issues as raised by prior work (Kreutzer et al., 2021), these issues do not have a significant impact in NLU tasks. This suggests that investing on bigger and more diverse datasets might be more fruitful than addressing such quality issues in low-resource settings. Given that the amount of written text in such languages is ultimately limited, we believe that developing effective cross-lingual transfer methods to exploit multilingual data is a promising future direction. Having said that, it should be noted that our study is limited to NLU tasks in a single language. It is possible that data quality plays a more important role in generation tasks, which we leave for future work to study. In addition, we think that
+
+it would be valuable to conduct similar studies in other languages to corroborate our findings.
+
+Finally, we note that prior work on Basque NLP has often relied on private resources (Agerri et al., 2020). Our work sets a new state-of-the-art on a diverse set of NLU benchmarks, and it does so using public data alone. By releasing our corpus, we hope to facilitate future work in Basque NLP, and encourage open and reproducible science using public resources.
+
+# Limitations
+
+Our evaluation focuses on NLU tasks, and it is possible that data quality plays a different role in generation tasks. We note, however, that generation quality is harder to evaluate through automatic metrics, which is why we decided to focus on NLU tasks. Moreover, the corpora that we compare differ on various aspects other than the data quality (e.g., the domain), and it is hard to isolate the effect of quality from the rest. In any case, we believe that our main claim still holds, in that data quality has a minor impact relative to such other factors. Finally, our work builds on EusCrawl—a new high-quality corpus that we introduce for Basque—and our analysis is thus limited to this language. It would be interesting to collect high-quality corpora for other low-resource languages, and conduct a similar comparison to corroborate that our findings also apply more broadly.
+
+# Acknowledgments
+
+We would like to thank Nikolas Vicuña for his help on expanding EusCrawl, Naman Goyal for his advice on pre-training RoBERTa, and Arantza Rico and Paloma Rodriguez-Miñambres for their help with the manual data audit. We are also grateful to all Basque media and content creators that share their work under a Creative Commons license, making a resource like EusCrawl possible.
+
+Itziar Aldabe, Rodrigo Agerri, Olatz Perezde-Vinaspre and Aitor Soroa were supported by the Basque Government (excellence research group IT1343-19 and DeepText project KK-2020/00088), and by the projects: (i) DeepKnowledge (PID2021-127777OB-C21) funded by MCIN/AEI/10.13039/501100011033 and FEDER Una mantra de hacer Europa; (ii) Disargue (TED2021-130810B-C21), MCIN/AEI /10.13039/501100011033 and European Union NextGenerationEU/PRTR; (iii) DeepR3
+
+(TED2021-130295B-C31) funded by MCIN/AEI /10.13039/501100011033 and EU NextGeneration programme EU/PRTR. Rodrigo Agerri's work is also supported by the RYC-2017-23647 fellowship (MCIN/AEI /10.13039/501100011033 y por El FSE invierte en tu futuro).
+
+# References
+
+Rodrigo Agerri, Roberto Centeno, María Espinosa, Joseba Fernandez de Landa, and Álvaro Rodrigo Yuste. 2021. Vaxxstance@iberlef 2021: Overview of the task on going beyond text in crosslingual stance detection.
+
+Rodrigo Agerri, Iñaki San Vicente, Jon Ander Campos, Ander Barrena, Xabier Saralegi, Aitor Soroa, and Eneko Agirre. 2020. Give your text representation models some love: the case for basque. In Proceedings of The 12th Language Resources and Evaluation Conference, pages 4781-4788, Marseille, France. European Language Resources Association.
+
+Inaki Alegria, Olatz Arregi, Nerea Ezeiza, and Izaskun Fernandez. 2006. Lessons from the development of a named entity recognizer for Basque. Procesamento del Lenguaje Natural, 36:25-37.
+
+Mikel Artetxe, Sebastian Ruder, and Dani Yogatama. 2020. On the cross-lingual transferability of monolingual representations. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4623–4637, Online. Association for Computational Linguistics.
+
+Rishi Bommasani, Drew A. Hudson, Ehsan Adeli, Russ Altman, Simran Arora, Sydney von Arx, Michael S. Bernstein, Jeannette Bohg, Antoine Bosselut, Emma Brunskill, Erik Brynjolfsson, Shyamal Buch, Dallas Card, Rodrigo Castellon, Niladri Chatterji, Annie Chen, Kathleen Creel, Jared Quincy Davis, Dora Demszky, Chris Donahue, Moussa Doumbouya, Esin Durmus, Stefano Ermon, John Etchemendy, Kawin Ethayarajh, Li Fei-Fei, Chelsea Finn, Trevor Gale, Lauren Gillespie, Karan Goel, Noah Goodman, Shelby Grossman, Neel Guha, Tatsunori Hashimoto, Peter Henderson, John Hewitt, Daniel E. Ho, Jenny Hong, Kyle Hsu, Jing Huang, Thomas Icard, Saahil Jain, Dan Jurafsky, Pratyusha Kalluri, Siddharth Karamcheti, Geoff Keeling, Fereshte Khani, Omar Khattab, Pang Wei Koh, Mark Krass, Ranjay Krishna, Rohith Kuditipudi, Ananya Kumar, Faisal Ladhak, Mina Lee, Tony Lee, Jure Leskovec, Isabelle Levent, Xiang Lisa Li, Xuechen Li, Tengyu Ma, Ali Malik, Christopher D. Manning, Suvir Mirchandani, Eric Mitchell, Zanele Munyikwa, Suraj Nair, Avanika Narayan, Deepak Narayanan, Ben Newman Allen Nie, Juan Carlos Niebles, Hamed Nilforoshan Julian Nyarko, Giray Ogut, Laurel Orr, Isabel Papadimitriou, Joon Sung Park, Chris Piech, Eva Portelance, Christopher Potts, Aditi Raghunathan, Rob Reich, Hongyu Ren, Frieda Rong, Yusuf Roohani
+
+Camilo Ruiz, Jack Ryan, Christopher Ré, Dorsa Sadigh, Shiori Sagawa, Keshav Santhanam, Andy Shih, Krishnan Srinivasan, Alex Tamkin, Rohan Taori, Armin W. Thomas, Florian Tramér, Rose E. Wang, William Wang, Bohan Wu, Jiajun Wu, Yuhuai Wu, Sang Michael Xie, Michihiro Yasunaga, Jiaxuan You, Matei Zaharia, Michael Zhang, Tianyi Zhang, Xikun Zhang, Yuhui Zhang, Lucia Zheng, Kaitlyn Zhou, and Percy Liang. 2021. On the opportunities and risks of foundation models.
+
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettle-moyer, and Veselin Stoyanov. 2020. Unsupervised cross-lingual representation learning at scale. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8440-8451, Online. Association for Computational Linguistics.
+
+Alexis Conneau and Guillaume Lample. 2019. Crosslingual language model pretraining. In Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc.
+
+Jared Kaplan, Sam McCandlish, Tom Henighan, Tom B. Brown, Benjamin Chess, Rewon Child, Scott Gray, Alec Radford, Jeffrey Wu, and Dario Amodei. 2020. Scaling laws for neural language models.
+
+Julia Kreutzer, Isaac Caswell, Lisa Wang, Ahsan Wahab, Daan van Esch, Nasanbayar Ulzii-Orshikh, Allahsera Tapo, Nishant Subramani, Artem Sokolov, Claytone Sikasote, Monang Setyawan, Supheakmungkol Sarin, Sokhar Samb, Benoit Sagot, Clara Rivera, Annette Rios, Isabel Papadimitriou, Salomey Osei, Pedro Ortiz Suárez, Iroro Orife, Kelechi Ogueji, Andre Niyongabo Rubungo, Toan Q. Nguyen, Mathias Müller, André Müller, Shamsuddeen Hassan Muhammad, Nanda Muhammad, Ayanda Mnyakeni, Jamshidbek Mirzakhalov, Tapiwanashe Matangira, Colin Leong, Nze Lawson, Sneha Kudugunta, Yacine Jernite, Mathias Jenny, Orhan Firat, Bonaventure F. P. Dossou, Sakhile Dlamini, Nisansa de Silva, Sakine Çabuk Ballı, Stella Biderman, Alessia Battisti, Ahmed Baruwa, Ankur Bapna, Pallavi Baljekar, Israel Abebe Azime, Ayodele Awokoya, Duygu Ataman, Orevaoghene Ahia, Oghenefego Ahia, Sweta Agrawal, and Mofetoluwa Adeyemi. 2021. Quality at a glance: An audit of web-crawled multilingual datasets.
+
+Taku Kudo and John Richardson. 2018. SentencePiece: A simple and language independent subword tokenizer and tokenizer for neural text processing. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 66-71, Brussels, Belgium. Association for Computational Linguistics.
+
+Mirko Lai, Alessandra Teresa Cignarella, Livio Finos, and Andrea Sciandra. 2021. Wordup! at vaxxstance 2021: Combining contextual information with textual
+
+and dependency-based syntactic features for stance detection. In IberLEF@SEPLN.
+
+Xi Victoria Lin, Todor Mihaylov, Mikel Artetxe, Tianlu Wang, Shuohui Chen, Daniel Simig, Myle Ott, Naman Goyal, Shruti Bhosale, Jingfei Du, Ramakanth Pasunuru, Sam Shleifer, Punit Singh Koura, Vishrav Chaudhary, Brian O'Horo, Jeff Wang, Luke Zettlemoyer, Zornitsa Kozareva, Mona Diab, Veselin Stoyanov, and Xian Li. 2021. Few-shot learning with multilingual language models.
+
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach.
+
+Arantxa Otegi, Aitor Agirre, Jon Ander Campos, Aitor Soroa, and Eneko Agirre. 2020. Conversational question answering in low resource scenarios: A dataset and case study for basque. In Proceedings of The 12th Language Resources and Evaluation Conference, pages 436-442, Marseille, France. European Language Resources Association.
+
+Telmo Pires, Eva Schlinger, and Dan Garrette. 2019. How multilingual is multilingual BERT? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4996-5001, Florence, Italy. Association for Computational Linguistics.
+
+Jack W. Rae, Sebastian Borgeaud, Trevor Cai, Katie Millican, Jordan Hoffmann, Francis Song, John Aslanides, Sarah Henderson, Roman Ring, Susannah Young, Eliza Rutherford, Tom Hennigan, Jacob Menick, Albin Cassirer, Richard Powell, George van den Driessche, Lisa Anne Hendricks, Maribeth Rauh, Po-Sen Huang, Amelia Glaese, Johannes Welbl, Sumanth Dathathri, Saffron Huang, Jonathan Uesato, John Mellor, Irina Higgins, Antonia Creswell, Nat McAleese, Amy Wu, Erich Elsen, Siddhant Jayakumar, Elena Buchatskaya, David Budden, Esme Sutherland, Karen Simonyan, Michela Paganini, Laurent Sifre, Lena Martens, Xiang Lorraine Li, Adhiguna Kuncoro, Aida Nematzadeh, Elena Gribovskaya, Domenic Donato, Angeliki Lazaridou, Arthur Mensch, Jean-Baptiste Lespiau, Maria Tsimpoukelli, Nikolai Grigorev, Doug Fritz, Thibault Sottiaux, Mantas Pajarskas, Toby Pohlen, Zhitao Gong, Daniel Toyama, Cyprien de Masson d'Autume, Yujia Li, Tayfun Terzi, Vladimir Mikulik, Igor Babuschkin, Aidan Clark, Diego de Las Casas, Aurelia Guy, Chris Jones, James Bradbury, Matthew Johnson, Blake Hechtman, Laura Weidinger, Jason Gabriel, William Isaac, Ed Lockhart, Simon Osindero, Laura Rimell, Chris Dyer, Oriol Vinyals, Kareem Ayoub, Jeff Stanway, Lorraine Bennett, Demis Hassabis, Koray Kavukcuoglu, and Geoffrey Irving. 2022. Scaling language models: Methods, analysis & insights from training gopher.
+
+Linting Xue, Noah Constant, Adam Roberts, Mihir Kale, Rami Al-Rfou, Aditya Siddhant, Aditya Barua, and
+
+Colin Raffel. 2021. mT5: A massively multilingual pre-trained text-to-text transformer. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 483-498, Online. Association for Computational Linguistics.
+
+# A Annotation instructions
+
+Table 4 reports the complete instructions used for the qualitative evaluation as given to the annotators.
+
+# B Downstream evaluation
+
+We next provide additional details on the datasets used for downstream evaluation:
+
+- Topic classification: The Basque Headlines Topic Classification (BHTC) dataset (Agerri et al., 2020) contains 12k headlines from the Argia news magazine classified into 12 thematic categories9. We use the standard splits containing 8662 examples for training, 1861 for development and 1860 for testing.
+- Sentiment classification: The Behague dataset10 comprises 2936 tweets in Basque labeled as positive, negative or neutral. We used the same splits for train (80%), test (10%) and development (10%) as in Agerri et al. (2020).
+- Stance detection: We used the VaxxStance dataset (Agerri et al., 2021), which offers tweets labeled as expressing an AGAINST, FAVOR or NEUTRAL stance with respect to vaccines. It contains 1070 tweets for training and 313 for testing11.
+- Named Entity Recognition (NER): EIEC $^{12}$ (Alegria et al., 2006) is a Basque NER dataset composed of 44K training tokens (3817 unique entities) and 15K test tokens (931 entities).
+- Question Answering (QA): Elkarrizketak is an extractive conversational QA dataset (Otegi et al., 2020) that contains 377 dialogues (301 train, 38 development and 38 test) and 1,634 question/answer pairs (1,306 train, 161 development and 167 test) $^{13}$ .
+
+| LangID | EGOKIA: Dokumentua euskaraz dago.
+CORRECT: The document is in Basque. |
| ARAZOAK: Dokumentuaren zati esanguratsu bat ez dago euskaraz.
+PROBLEMATIC: A significant portion of the document is not in Basque. |
| Hizkuntza Lang. variety | EGOKIA: Dokumentua hizkuntza estandar eta zuzenean idatzia dago.
+CORRECT: The document is written in standard and correct language. |
| ARAZOAK: Dokumentua ez dago hizkuntza estandar edo zuzenean idatzia (adb. euskalkiren batean dago ala itzulpen automatikoaren bidez sortua dirudi).
+PROBLEMATIC: The document is not written in standard and correct language (e.g., it is written in a dialect using non-standard Basque, or it seems to be generated through machine translation). |
| Koherentzia Coherence | EGOKIA: Dokumentua koherentea da, eta hasieratik bukaerara unitate bat osatzen du.
+CORRECT: The document is coherent, and it constitutes a single unit from the beginning to the end. |
| ARAZOAK: Dokumentua ez da koherentea: hutsuneak ditu edota atal batzuk ez dute elkarren artean loturarik (dokumentu ezberdinak dirudite).
+PROBLEMATIC: The document is not coherent: it has gaps and/or some portions do not seem connected (they seem to come from separate documents). |
| Garbitasuna Noise | EGOKIA: Dokumentuko testua garbia da.
+CORRECT: The text in the document is clean. |
| ARAZOAK: Dokumentua ez da erabat garbia, eta benetako testuaz gain webguneko bestelako elementuak daude (menutako testua, html kodea...).
+PROBLEMATIC: The document is not entirely clean, and there are other elements in addition to the real content (text from menus, HTML code...). |
| Edukia Content | EGOKIA: Dokumentua pertsona batek sortua dirudi eta gutxieneko mami bat du.
+CORRECT: The document seems to have been created by a human and has some minimum meat. |
| ARAZOAK: Dokumentuak automatikoli sortua dirudi edota ez du inolako mamirik (adb futbol ligako sailkapen-taula).
+The document seems to have been generated automatically and/or has no meat at all (e.g., a soccer standing table). |
| Kalitate orokorra Overall quality | ALTUA: Dokumentua kalitatezkoa da, eta corpusean izatea komeniko litzatekeela uste dut.
+HIGH: The document is of good quality, and I think that it would be good to have it in the corpus. |
| ERTAINA: Dokumentuak arazo batzuk ditu baina ez dira larriak, eta ez nago ziur ea corpusean izatea komeniko litzatekeen.
+MEDIUM: The document has minor issues, and I am not sure if it would be good to have it in the corpus. |
| BAXUA: Dokumentuak arazo nabarmenak ditu. Ez dut uste corpusean izatea komeniko litzatekeenik.
+LOW: The document has major issues. I think that it would be better not to have it in the corpus. |
+
+Table 4: Annotation instructions used for the qualitative evaluation. We report the original instructions in Basque, as well as the corresponding translation into English.
\ No newline at end of file
diff --git a/doescorpusqualityreallymatterforlowresourcelanguages/images.zip b/doescorpusqualityreallymatterforlowresourcelanguages/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..8c0fa63fee5fdb3a73164c3f2bcae19e9acc64a2
--- /dev/null
+++ b/doescorpusqualityreallymatterforlowresourcelanguages/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d50e11909b44ba4e450b2dab6452642ffc295174168855ed0d1b5278034fdf9d
+size 430257
diff --git a/doescorpusqualityreallymatterforlowresourcelanguages/layout.json b/doescorpusqualityreallymatterforlowresourcelanguages/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..bd397122f5fb5b1cc7f2f82160d25a982352c77c
--- /dev/null
+++ b/doescorpusqualityreallymatterforlowresourcelanguages/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:61d696dde3d23a613696abadec6fec99f9346616b6cb457d08df0486f0e8b46f
+size 173784
diff --git a/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_content_list.json b/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..2d2f1d805347657d9c3eaf164d68826c7d95d28a
--- /dev/null
+++ b/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:dd080b6a821d7321f837f034d885a09c798a98d1c8fbcf027033bd8d435c14f7
+size 53533
diff --git a/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_model.json b/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..f8d4670c981df96beff2b1dfbc58593544bd010a
--- /dev/null
+++ b/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b77853fedc7df3def743aa600fa17a46e793169cdb566faf516b4718d9afcbdd
+size 65112
diff --git a/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_origin.pdf b/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..5591e989dc306e42e0dd441ba0ea1d967537431f
--- /dev/null
+++ b/doesjointtrainingreallyhelpcascadedspeechtranslation/e3cfedf3-7a1a-4b24-a196-d1244dcdd6d5_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:12b462b333484925c560a8a5e591953441309f92d0f2147f79447e154105ad9d
+size 271537
diff --git a/doesjointtrainingreallyhelpcascadedspeechtranslation/full.md b/doesjointtrainingreallyhelpcascadedspeechtranslation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..415044f637188cbb411d8ad1b02e6dd3e84142eb
--- /dev/null
+++ b/doesjointtrainingreallyhelpcascadedspeechtranslation/full.md
@@ -0,0 +1,219 @@
+# Does Joint Training Really Help Cascaded Speech Translation?
+
+Viet Anh Khoa Tran David Thulke Yingbo Gao Christian Herold Hermann Ney
+
+Human Language Technology and Pattern Recognition Group
+
+Computer Science Department
+
+RWTH Aachen University
+
+D-52056 Aachen, Germany
+
+{vtran|thulke|gao|herold|ney}@i6.informatik.rwth-aachen.de
+
+# Abstract
+
+Currently, in speech translation, the straightforward approach - cascading a recognition system with a translation system - delivers state-of-the-art results. However, fundamental challenges such as error propagation from the automatic speech recognition system still remain. To mitigate these problems, recently, people turn their attention to direct data and propose various joint training methods. In this work, we seek to answer the question of whether joint training really helps cascaded speech translation. We review recent papers on the topic and also investigate a joint training criterion by marginalizing the transcription posterior probabilities. Our findings show that a strong cascaded baseline can diminish any improvements obtained using joint training, and we suggest alternatives to joint training. We hope this work can serve as a refresher of the current speech translation landscape, and motivate research in finding more efficient and creative ways to utilize the direct data for speech translation.
+
+# 1 Introduction
+
+Speech translation (ST) is the task of automatic translation of speech in some source language into some other target language (Stentiford and Steer, 1988; Waibel et al., 1991). Traditionally, a cascaded approach is used, where an automatic speech recognition (ASR) system is used to transcribe the speech, followed by a machine translation (MT) system, to translate the transcripts (Sperber and Paulik, 2020). The problem of error propagation has been the center of discussion in ST literature (Ney, 1999; Casacuberta et al., 2004; Matusov et al., 2005; Peitz et al., 2012; Sperber et al., 2017), and instead of using the discrete symbols in the source languages, ideas like using n-best lists, lattices, and neural network hidden representations are investigated (Saleem et al., 2004; Kano et al., 2017; Anastasopoulos and Chiang, 2018; Zhang et al., 2019; Sperber et al., 2019). For a more sys
+
+tematic review of the ST development, we refer the readers to Sperber and Paulik (2020).
+
+With recent efforts in the expansion of the ST data collection (Di Gangi et al., 2019; Beilharz et al., 2020), more and more direct ST data is available. Such direct data comes as pairs of source speech and target translation, and often as triplets further including source transcriptions.
+
+Various joint training methods are proposed to use such data to improve cascaded systems, with the hope that uncertainties during transcription can be passed on to translation to be resolved. Here, what we call "joint training" is often referred to as "end-to-end training" in the literature, where the direct ST data is utilized in the joint optimization of the ASR and MT models (Kano et al., 2017; Berard et al., 2018; Anastasopoulos and Chiang, 2018; Inaguma et al., 2019; Sperber et al., 2019; Bahar et al., 2019; Wang et al., 2020; Bahar et al., 2021). In this work, we revisit the principal question of whether or not joint training really helps cascaded speech translation.
+
+# 2 Cascaded Approach
+
+In traditional cascaded systems, an ASR model $p(f_1^J | x_1^T)$ and an MT model $p(e_1^I | f_1^J)$ are trained separately, where we denote speech features as $x_1^T$ , transcriptions as $f_1^J$ , and translations as $e_1^I$ . The decoding is done in two steps:
+
+$$
+\hat{f}_{1}^{J} = \operatorname *{argmax}_{\substack{[f_{1}^{J}]}}p(f_{1}^{J}|x_{1}^{T})
+$$
+
+$$
+\hat {e} _ {1} ^ {I} = \operatorname * {a r g m a x} _ {[ e _ {1} ^ {I} ]} p (e _ {1} ^ {I} \mid \hat {f} _ {1} ^ {J})
+$$
+
+The argmax is approximated using beam search for computational reasons, and we will assume a fixed beam size $N$ for the decoding of both transcriptions and translations.
+
+# 3 Joint Training Approaches
+
+# 3.1 Top- $K$ Cascaded Translation
+
+Assume we have pre-trained an ASR and an MT model, and some direct ST training data is available. The pre-trained ASR model is used to produce a $K$ -best list of ASR hypotheses $F_{1}, F_{2}, \ldots, F_{K}$ using beam search with beam size $N \geq K$ . While there is no unique method to make use of the top- $K$ transcript, we describe Top- $K$ -Train, a straightforward algorithm similar to re-ranking. We obtain the score $\tilde{p}$ for each ASR hypothesis with length normalization and normalize them locally within the top- $K$ hypotheses.
+
+$$
+p \left(F _ {k} \mid x _ {1} ^ {T}\right) = \frac {\tilde {p} \left(F _ {k} \mid x _ {1} ^ {T}\right)}{\sum_ {k ^ {\prime} = 1} ^ {K} \tilde {p} \left(F _ {k ^ {\prime}} \mid x _ {1} ^ {T}\right)} \tag {1}
+$$
+
+During training, $p(e_i|F_K; e_0^{i-1})$ is the MT model output. Given the ASR hypotheses $F_1, \ldots, F_K$ , the following training objective is maximized.
+
+$$
+\log \left(\sum_ {k = 1} ^ {K} p \left(F _ {k} \mid x _ {1} ^ {T}\right) \prod_ {i = 1} ^ {I} p \left(e _ {i} \mid F _ {k}; e _ {0} ^ {i - 1}\right)\right)
+$$
+
+We hypothesize that this objective (a) exposes different transcriptions and potential ASR errors to the MT model and (b) encourages the ASR model to produce hypotheses closer to the expectations of the MT model, thus reducing model discrepancy. Since discrete ASR hypotheses are passed to the MT model from a previous beam search, the error signal to ASR is passed via the renormalized transcript scores during backpropagation.
+
+Similarly, we introduce Top-K-Search. We obtain an MT hypothesis $E_{k}$ for each $F_{k}$ using beam search. The final hypothesis is obtained as below.
+
+$$
+\hat {e} _ {1} ^ {\hat {I}} = \operatorname * {a r g m a x} _ {E _ {k}} \left\{p (F _ {k} | x _ {1} ^ {T}) \cdot p (E _ {k} | F _ {k}) \right\}
+$$
+
+Here, $p(F_k | x_1^T)$ is obtained as in Equation 1 and $p(E_k | F_k)$ is the length normalized translation score from the MT model. Observe that this search is applicable to any cascade architecture and is thus independent of the training criterion. In our experiments, we always Top-K-Search when decoding models trained with Top-K-Train. The idea of generating the top-K ASR hypotheses during search has also been explored in the literature (e.g. Section 3.3).
+
+# 3.2 Tight-Integration
+
+Another way to train the cascade architecture using direct ST data is the tight integrated cascade approach (Bahar et al., 2021). We introduce an exponent $\gamma$ that controls the sharpness of the distribution of the conditional probabilities. Thus, instead of passing the 1-best hypothesis of the ASR system as a sequence of 1-hot vectors, we pass the renormalized probabilities to the MT model.
+
+$$
+p (f _ {j} | f _ {1} ^ {j - 1}; x _ {1} ^ {T}) = \frac {\tilde {p} ^ {\gamma} (f _ {j} | f _ {1} ^ {j - 1} x _ {1} ^ {T})}{\sum_ {f ^ {\prime} \in | V _ {F} |} \tilde {p} ^ {\gamma} (f _ {j} ^ {\prime} | f _ {1} ^ {j - 1} x _ {1} ^ {T})}
+$$
+
+Here, $V_{F}$ is the vocabulary of the ASR system.
+
+# 3.3 Searchable Hidden Intermediates
+
+Dalmia et al. (2021) propose passing the final decoder representations of the $N$ -best ASR hypotheses (i.e. the searchable hidden intermediates) directly to the MT system, bypassing the MT input embedding.
+
+Additionally, they extend the multi-task learning approach by allowing the MT decoder to attend to the ASR encoder states, which in turn are optimized using beam search in training. They show that during decoding, a higher ASR beam size indeed leads to a better ST performance.
+
+# 4 Experimental Results and Analysis
+
+We focus on the MuST-C English-German speech translation task (Di Gangi et al., 2019) in the domain of TED talks and evaluate on test-HE and test-COMMON. We use an in-house filtered subset of the IWSLT 2021 English-German dataset as in Bahar et al. (2021), which contains 1.9M segments (2300 hours) of ASR data and 24M parallel sentences of MT data. The in-domain ASR data comprises MUST-C, TED-LIUM, and IWSLT TED, while the out-of-domain ASR data consists of EuroParl, How2, LibriSpeech, and Mozilla Common Voice. For translation, the dataset contains 24M parallel sentences of in-domain translation data (MuST-C, TED-LIUM, and IWSLT TED), as well as out-of-domain translation data (NewsCommentary, EuroParl, WikiTitles, ParaCrawl, CommonCrawl, Rapid, OpenSubtitles2018). For ST data, we only use MuST-C. We provide further details in Appendix A. Depending on whether or not fine-tuned on in-domain ASR and MT data, we split our experiments into two sets: A1-A5 and B1-B5.
+
+| Model | Data | MuST-C En-De |
| MT | ASR | ST | tst-HE | tst-COMMON |
| BLEU | TER | BLEU | TER |
| Bahar et al. (2021) | | | | | | | |
| Cascade | ✓ | ✓ | - | 25.0 | 59.2 | 25.9 | 56.2 |
| tight integrated cascade | ✓ | ✓ | ✓ | 26.8 | 57.2 | 26.5 | 54.8 |
| Xu et al. (2021) | | | | | | | |
| cascade | - | - | ✓ | - | - | 23.3 | - |
| cascade | ✓ | ✓ | ✓ | - | - | 28.1 | - |
| direct + pretraining + multi-task | - | - | ✓ | - | - | 25.2 | - |
| direct + pretraining + multi-task | ✓ | ✓ | ✓ | - | - | 28.1 | - |
| Dalmia et al. (2021) | | | | | | | |
| searchable hidden intermediates | - | - | ✓ | - | - | 26.4 | - |
| Inaguma et al. (2021) | | | | | | | |
| cascade | ✓ | ✓ | - | 26.1 | - | 29.4 | - |
| direct + KD | ✓ | ✓ | ✓ | 27.4 | - | 30.9 | - |
| searchable hidden intermediates + KD | ✓ | ✓ | ✓ | - | - | 30.8 | - |
| this work (no fine-tuning) | | | | | | | |
| A1 ground-truth transcript MT | ✓ | (✓) | - | 30.4 | 54.0 | 32.5 | 48.9 |
| A2 cascade | ✓ | ✓ | - | 27.7 | 57.8 | 29.0 | 53.6 |
| A3 tight integrated cascade | ✓ | ✓ | ✓ | 28.7 | 56.1 | 29.2 | 53.5 |
| A4 Top-K-Train | ✓ | ✓ | ✓ | 28.7 | 56.9 | 30.0 | 52.5 |
| A5 Top-K-Search | ✓ | ✓ | | 28.2 | 57.1 | 29.4 | 53.1 |
| this work (fine-tuned ASR and MT) | | | | | | | |
| B1 ground-truth transcript MT | ✓ | (✓) | - | 31.1 | 53.2 | 33.7 | 48.2 |
| B2 cascade | ✓ | ✓ | - | 29.1 | 56.6 | 30.5 | 52.2 |
| B3 tight integrated cascade | ✓ | ✓ | ✓ | 29.4 | 55.9 | 30.1 | 52.5 |
| B4 Top-K-Train | ✓ | ✓ | ✓ | 29.4 | 55.9 | 30.5 | 51.9 |
| B5 Top-K-Search | ✓ | ✓ | - | 29.4 | 56.4 | 30.8 | 51.9 |
+
+Table 1: Results measured in BLEU [%] and TER [%] on the MuST-C En-De task. Fine-tuning refers to additional phase of training exclusively on the in-domain subset of the training data of both ASR and MT models.
+
+Without fine-tuning, we observe that both the tight integrated cascade (Bahar et al., 2021) (A3) and our marginalization approach (A4) outperform the baseline cascade (A2) on both test-HE and test-COMMON (Table 1). However, after fine-tuning both ASR and MT models, we do not observe significant improvements of the joint training methods (B3, B4) over the cascade baseline (B2) anymore.
+
+Our experimental results suggest that the joint training of cascaded speech translation models does not seem to be effective. This poses the questions: why is that and what were we trying to achieve with joint training anyways? Sperber and Paulik (2020) highlighted three main issues with ST, and in the following, we will discuss these issues from the perspective of joint training.
+
+Mismatched spoken and written domains Transcripts and translation data usually differ in e.g.
+
+linguistic style and punctuation. This mismatch poses a challenge for cascaded models, as translation models may struggle to handle transcript-style text. As Sperber and Paulik (2020) point out, some of the issues such as differences in punctuation can already be tackled by plain text normalization.
+
+More generally, one can fine-tune the models on in-domain transcript-like ASR, MT, and ST data. It is unusual to find ST datasets that do not come with corresponding ASR and MT data, as ST data acquisition usually involves translating from transcriptions. Thus, we can simply fine-tune the ASR and MT models on these in-domain datasets.
+
+Our results suggest that fine-tuning the ASR and MT models is comparable or even superior to fine-tuning these models in an end-to-end fashion on the respective speech translation dataset. However, Inaguma et al. (2021) and Bahar et al. (2021) report
+
+significant improvements of their joint cascaded approach, which is similar to the tight integrated cascade, over their cascaded baseline (Table 1).
+
+What is the reason for this disparity? We pin it down to one major difference: the use of indomain ST data, or more precisely, the lack thereof. Inaguma et al. (2021) report that by fine-tuning on MuST-C and ST-TED, they are unable to significantly improve their MT baseline, and thus, the MT component in their cascade model is not fine-tuned on the domain of TED talks. In contrast, we find that in-domain fine-tuning significantly improves our cascaded model, especially if applied to both the ASR and MT models (Table 2), also improving the individual components, as we observe a decrease in WER $[\%]$ from 9.3 to 8.1 of the ASR component and an increase in BLEU $[\%]$ from 32.5 to 33.7 of the MT component on tst-COMMON. As pointed out earlier, fine-tuning diminishes any improvement obtained using any of the joint training methods we implement, as the cascade baseline significantly gains in performance.
+
+Thus, in-domain fine-tuning is essential in order to tackle the disparity between the spoken and the written domain for vanilla cascaded models. This especially holds true for the MT model, which is trained on non-transcript-like data, but we want it to adapt to transcript-like inputs and transcript-like outputs (with punctuations, casing, etc.).
+
+Intuitively, instead of in-domain fine-tuning, a simple remedy is to only use in-domain data for ASR and MT. Xu et al. (2021) observe an improvement of their multi-task learning method when allowing only MuST-C data (Table 1). However, the improvement vanishes as they introduce external ASR and MT data. Since the latter represents a more realistic data scenario, we believe that the inclusion of external ASR and MT data is necessary to obtain meaningful results.
+
+In our fine-tuning setup, we do not only adapt to transcript-like data, but also to the specific domain of TED talks. In the literature, ST performance is commonly evaluated on test sets in the same domain as the ST data, e.g. TED talks (i.e. MuST-C or IWSLT TED), LibriSpeech (Kocabiyikoglu et al., 2018) and CallHome (Post et al., 2013). However, this poorly reflects real-life data conditions, because large amounts of in-domain ST data are not always available, while in-domain ASR and MT data is more accessible. As a consequence, we believe that end-to-end models are artificially
+
+ | Fine-tuning | MuST-C | En-De |
| ASR | MT | tst-HE | tst-COMMON |
| Inaguma et al. (2021) | - | - | 26.1 | 29.4 |
| Our work | - | - | 27.7 | 29.0 |
| ✓ | - | 27.9 | 29.5 |
| ✓ | ✓ | 29.1 | 30.5 |
+
+Table 2: Performance of our cascaded system under different in-domain fine-tuning conditions, results measured in BLEU [%].
+
+favored over cascade models in these setups. We thus motivate future research to also consider out-of-domain or general-domain ST datasets, while allowing in-domain ASR and MT data.
+
+Error propagation In case the ASR produces an error in the transcript or intermediate representations, this error is propagated to the translation model, which does not have any knowledge about the transcription process. Sperber and Paulik (2020) discuss this phenomenon under the term erroneous early decisions.
+
+Intuitively, a remedy for this issue is joint training, as we allow the MT component to learn to use information that is missing or erroneous in the intermediate representation. For example, the tight integrated approach (Bahar et al., 2021) addresses this issue by expressing uncertainties in the transcription as posterior probabilities, while Dalmia et al. (2021) propose speech attention, i.e. a Transformer cross-attention sub-module in the MT component, attending over ASR encoder representations.
+
+However, we make the case that joint training is not necessarily the only remedy to error propagation. Therefore, we consider a cheating experiment based on Top- $K$ -Search. For each of the top-4 ASR hypotheses, we pick the translations generated by the MT model based on the sentence-level BLEU with the ground-truth target. In these experiments, we obtain a BLEU [%] score of 32.4 on tst-HE and 34.2 on tst-COMMON, in both cases outperforming the oracle MT using ground-truth transcripts. Thus, on average, the translation of one of the top-4 transcripts generated by the ASR model is no worse than using the ground-truth transcript (B1). Hence, we posit that error propagation can be alleviated by plain ASR re-ranking. A possible starting point is our Top- $K$ -Search (A5, B5), giving small, but consistent improvements over their respective cascade baselines (A2, B2) without any joint training.
+
+Similarly, instead of sequence-level reranking using the joint ASR-MT score, Dalmia et al. (2021)
+
+propose augmenting the token-level ASR probabilities with either the CTC scores from the ASR encoder or an external LM score during beam search to incorporate ASR uncertainties.
+
+Information loss Information loss occurs as the ASR model does not pass on auditory information such as intonation and timing, which may be relevant for the translation component. While we have no empirical evidence on the significance of such information on the final performance, we observe that our MT model, given the ground-truth transcripts, still significantly outperforms any speech translation model we investigate, doing so without any auditory information. Furthermore, our cheating experiments suggest one may even improve over ground-truth transcriptions without any auditory information. We posit that as of now, focusing on closing that gap is of higher importance.
+
+# 5 Conclusion
+
+In this work, we analyzed several reasons why joint training does not appear to help when individual automatic speech recognition and machine translation components are stronger. We point out that cascaded models achieve state-of-the-art performance when fine-tuned on in-domain ST data.
+
+While we do not suggest that joint training is not worth exploring, we want to encourage future research to consider data conditions more carefully and produce strong cascade baselines. Concretely, we suggest (1) the inclusion of external ASR and MT data, (2) training strong cascade baselines by fine-tuning both ASR and MT models on in-domain transcript-like data, if available and (3) the investigation of data conditions where only out-of-domain ST data is available, while allowing in-domain ASR and MT data.
+
+# Limitations
+
+In our experiments, we focus only on the MuST-C En-De task due to computational constraints. Further experiments on different language pairs could e.g. show differences of how spoken-written domain mismatch affects different languages. Again, experiments in different domains without direct ST data could further underline or refute our conclusions.
+
+In our analysis, we include experimental results from other authors as we do not have the resources to reproduce every method. It is possible that dif
+
+ferences in data filtering, data preprocessing, architectural choices, etc. could affect the comparability of these results.
+
+We have only analyzed a subset of the joint cascade methods described in literature. A systematic overview of such methods is outside the scope of our work.
+
+In order to be comparable to other works in literature, we mostly draw our conclusions using BLEU and TER. We acknowledge that using other automatic evaluation metrics and making use of human evaluation would strengthen the significance of our findings.
+
+# Acknowledgements
+
+This work was partially supported by the project HYKIST funded by the German Federal Ministry of Health on the basis of a decision of the German Federal Parliament (Bundestag) under funding ID ZMVI1-2520DAT04A, and by NeuroSys which, as part of the initiative "Clusters4Future", is funded by the Federal Ministry of Education and Research BMBF (03ZU1106DA).
+
+We thank Parnia Bahar for sharing her data preprocessing and training recipes.
+
+# References
+
+Antonios Anastasopoulos and David Chiang. 2018. Tied multitask learning for neural speech translation. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 82-91, New Orleans, Louisiana. Association for Computational Linguistics.
+Parnia Bahar, Tobias Bieschke, Ralf Schlüter, and Hermann Ney. 2021. Tight Integrated End-to-End Training for Cascaded Speech Translation. In 2021 IEEE Spoken Language Technology Workshop (SLT), pages 950–957.
+Parnia Bahar, Albert Zeyer, Ralf Schlüter, and Hermann Ney. 2019. On using SpecAugment for end-to-end speech translation. In Proceedings of the 16th International Conference on Spoken Language Translation, Hong Kong. Association for Computational Linguistics.
+Benjamin Beilharz, Xin Sun, Sariya Karimova, and Stefan Riezler. 2020. LibriVoxDeEn: A corpus for German-to-English speech translation and German speech recognition. In Proceedings of the 12th Language Resources and Evaluation Conference, pages 3590–3594, Marseille, France. European Language Resources Association.
+
+Alexandre Berard, Laurent Besacier, Ali Can Kocabiyikoglu, and Olivier Pietquin. 2018. End-to-end automatic speech translation of audiobooks. 2018 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), pages 6224-6228.
+Francisco Casacuberta, Hermann Ney, Franz Josef Och, Enrique Vidal, Juan Miguel Vilar, Sergio Barrachina, Ismael Garcia-Varea, David Llorens, Cesar Martinez, Sirko Molau, et al. 2004. Some approaches to statistical and finite-state speech-to-speech translation. Computer Speech & Language, 18(1):25-47.
+Siddharth Dalmia, Brian Yan, Vikas Raunak, Florian Metze, and Shinji Watanabe. 2021. Searchable hidden intermediates for end-to-end models of decomposable sequence tasks. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 1882-1896.
+Mattia A Di Gangi, Roldano Cattoni, Luisa Bentivogli, Matteo Negri, and Marco Turchi. 2019. Must-c: a multilingual speech translation corpus. In 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2012-2017. Association for Computational Linguistics.
+Hirofumi Inaguma, Kevin Duh, Tatsuya Kawahara, and Shinji Watanabe. 2019. Multilingual end-to-end speech translation. In 2019 IEEE Automatic Speech Recognition and Understanding Workshop (ASRU), pages 570-577.
+Hirofumi Inaguma, Brian Yan, Siddharth Dalmia, Pengcheng Guo, Jiatong Shi, Kevin Duh, and Shinji Watanabe. 2021. Espnet-st iwslt 2021 offline speech translation system. IWSLT 2021, page 100.
+Takatomo Kano, Sakriani Sakti, and Satoshi Nakamura. 2017. Structured-based curriculum learning for end-to-end english-japanese speech translation. In IN-TERSPEECH.
+Suyoun Kim, Takaaki Hori, and Shinji Watanabe. 2017. Joint ctc-attention based end-to-end speech recognition using multi-task learning. In 2017 IEEE international conference on acoustics, speech and signal processing (ICASSP), pages 4835–4839. IEEE.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
+Ali Can Kocabiyikoglu, Laurent Besacier, and Olivier Kraif. 2018. Augmenting librispeech with French translations: A multimodal corpus for direct speech translation evaluation. In Proceedings of the Eleventh International Conference on Language Resources and Evaluation (LREC 2018), Miyazaki, Japan. European Language Resources Association (ELRA).
+
+Evgeny Matusov, Hermann Ney, and Ralf Schlüter. 2005. Phrase-based translation of speech recognizer word lattices using loglinear model combination. In IEEE Workshop on Automatic Speech Recognition and Understanding, 2005., pages 110-115. IEEE.
+Hermann Ney. 1999. Speech translation: Coupling of recognition and translation. In 1999 IEEE International Conference on Acoustics, Speech, and Signal Processing. Proceedings. ICASSP99 (Cat. No. 99CH36258), volume 1, pages 517-520. IEEE.
+Myle Ott, Sergey Edunov, Alexei Baevski, Angela Fan, Sam Gross, Nathan Ng, David Grangier, and Michael Auli. 2019. *fairoseq: A fast, extensible toolkit for sequence modeling*. In *Proceedings of NAACL-HLT* 2019: Demonstrations.
+Daniel S Park, William Chan, Yu Zhang, Chung-Cheng Chiu, Barret Zoph, Ekin D Cubuk, and Quoc V Le. 2019. Specaugment: A simple data augmentation method for automatic speech recognition. Proc. Interspeech 2019, pages 2613-2617.
+Stephan Peitz, Simon Wiesler, Markus Nußbaum-Thom, and Hermann Ney. 2012. Spoken language translation using automatically transcribed text in training. In Proceedings of the 9th International Workshop on Spoken Language Translation: Papers.
+Gabriel Pereyra, George Tucker, Jan Chorowski, Lukasz Kaiser, and Geoffrey Hinton. 2017. Regularizing neural networks by penalizing confident output distributions. 5th International Conference on Learning Representations, ICLR 2017, Toulon, France, April 24-26, 2017, Workshop Track Proceedings.
+Matt Post, Gaurav Kumar, Adam Lopez, Damianos Karakos, Chris Callison-Burch, and Sanjeev Khudanpur. 2013. Improved speech-to-text translation with the fisher and callhome Spanish-English speech translation corpus. In Proceedings of the 10th International Workshop on Spoken Language Translation: Papers, Heidelberg, Germany.
+Shirin Saleem, Szu-Chen Jou, Stephan Vogel, and Tanja Schultz. 2004. Using word lattice information for a tighter coupling in speech translation systems. In Proc. Int. Conf. on Spoken Language Processing, pages 41-44.
+Rico Sennrich, Barry Haddow, and Alexandra Birch. 2016. Neural machine translation of rare words with subword units. In 54th Annual Meeting of the Association for Computational Linguistics, pages 1715-1725. Association for Computational Linguistics (ACL).
+Peter Shaw, Jakob Uszkoreit, and Ashish Vaswani. 2018. Self-attention with relative position representations. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 464-468.
+
+Matthias Sperber, Graham Neubig, Jan Niehues, and Alex Waibel. 2017. Neural lattice-to-sequence models for uncertain inputs. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 1380-1389, Copenhagen, Denmark. Association for Computational Linguistics.
+Matthias Sperber, Graham Neubig, Jan Niehues, and Alex Waibel. 2019. Attention-passing models for robust and data-efficient end-to-end speech translation. Transactions of the Association for Computational Linguistics, 7:313-325.
+Matthias Sperber and Matthias Paulik. 2020. Speech translation and the end-to-end promise: Taking stock of where we are. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7409-7421, Online. Association for Computational Linguistics.
+Nitish Srivastava, Geoffrey Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. 2014. Dropout: a simple way to prevent neural networks from overfitting. The journal of machine learning research, 15(1):1929-1958.
+Fred WM Stentiford and Martin G Steer. 1988. Machine translation of speech. British Telecom technology journal, 6(2):116-122.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. Advances in neural information processing systems, 30.
+Alex Waibel, Ajay N Jain, Arthur E McNair, Hiroaki Saito, Alexander G Hauptmann, and Joe Tebelskis. 1991. Janus: a speech-to-speech translation system using connectionist and symbolic processing strategies. In Acoustics, Speech, and Signal Processing, IEEE International Conference on, pages 793-796. IEEE Computer Society.
+Chengyi Wang, Yu Wu, Shujie Liu, Zhenglu Yang, and Ming Zhou. 2020. Bridging the gap between pretraining and fine-tuning for end-to-end speech translation. In Proceedings of the AAAI Conference on Artificial Intelligence, pages 9161-9168.
+Chen Xu, Bojie Hu, Yanyang Li, Yuhao Zhang, Shen Huang, Qi Ju, Tong Xiao, and Jingbo Zhu. 2021. Stacked acoustic-and-textual encoding: Integrating the pre-trained models into speech translation encoders. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2619-2630.
+Pei Zhang, Niyu Ge, Boxing Chen, and Kai Fan. 2019. Lattice transformer for speech translation. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6475-6484, Florence, Italy. Association for Computational Linguistics.
+
+# A Experimental Setup
+
+For the ASR data, we extract 80-dimensional MFCC features every 10ms. The text data is post-processed by lower-casing, removing punctuation and transcriber tags, and by applying BPE (Sennrich et al., 2016) e a vocabulary size of 8000. We post-process the source text to be transcript-like, by removing punctuation and lower-casing. On both source and target sentences, we apply BPE with a vocabulary size of $32k$ . For models using tight integration, a separate translation model is trained using the transcription vocabulary. In both cases, the validation set is the concatenation of the validation sets provided by MuST-C and IWSLT TED.
+
+Our implementation is based on fairseq (Ott et al., 2019) and is available online1.
+
+ASR model For speech recognition, we use a Transformer model (Vaswani et al., 2017) with 12 encoder layers and 6 decoder layers. Instead of absolute positional encodings, we use relative positional encodings as introduced by (Shaw et al., 2018). We reduce the audio feature length using a two-layer convolutional network with kernel size 5 and 1024 channels. Other parameters are adapted from the original base configuration. Our ASR model consists of 70M trained parameters.
+
+Each epoch is split into 20 sub-epochs. We use the Adam optimizer (Kingma and Ba, 2015) with learning rate 0.0003 and 10 warmup sub-epochs, and the learning rate is scaled by 0.8 for every 3 sub-epochs without improvement on the validation set. As regularization, we use SpecAugment (Park et al., 2019) $(F,m_{F},T,m_{T},p,W) = (16,4,40,2,1.0,0))$ , a dropout (Srivastava et al., 2014) of 0.1, and label smoothing (Pereyra et al., 2017) with $\alpha = 0.1$ . Additionally, we train a CTC loss as an additional task during training (Kim et al., 2017).
+
+MT model For translation, we also use a Transformer model with 6 encoder and 6 decoder layers. Again, we use relative positional encodings, other parameters are adapted from the original base configuration, resulting in a model with 70M trained parameters.
+
+We use the same optimization procedure as with the ASR model, except that we now start with 4000
+
+warmup steps. As regularization, we use a dropout of 0.1 and label smoothing with $\alpha = 0.1$ .
+
+Joint Training We use the same training setup as for the ASR model, but with a learning rate of $3 \times 10^{-6}$ . Furthermore, as we are now working on a smaller ST dataset, an epoch is split into 10 sub-epochs.
+
+Fine-tuning We fine-tune the ASR model on all in-domain ASR data (600K segments) with a learning rate of 0.0001, while the MT model is fine-tuned on the MuST-C dataset (300K parallel sentences) with a learning rate of 0.00001.
+
+We use beam search with $N = 12$ . All BLEU scores reported are calculated on case-sensitive data using the official WMT scoring script. TER scores are calculated using TERCom. For top- $K$ experiments, we use $K = 4$ .
+
+We train our experiments on NVIDIA GTX 1080 Ti. Training the ASR takes around 4 weeks, all other experiment take around 2-3 weeks. The average runtime for inference on non-joint experiments is about 15 minutes, where joint experiments need around 2 hours.
\ No newline at end of file
diff --git a/doesjointtrainingreallyhelpcascadedspeechtranslation/images.zip b/doesjointtrainingreallyhelpcascadedspeechtranslation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..177c9b457cfa1647f494f4622eaa0c1e1b6bf12c
--- /dev/null
+++ b/doesjointtrainingreallyhelpcascadedspeechtranslation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7dced32f280e57db35bd8f2dc2cc6cf5346090218bbf3ff776ee06c7c5ceb676
+size 195872
diff --git a/doesjointtrainingreallyhelpcascadedspeechtranslation/layout.json b/doesjointtrainingreallyhelpcascadedspeechtranslation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..0426a8ec5c0701712d5f36e7cee3eb70ce56ac76
--- /dev/null
+++ b/doesjointtrainingreallyhelpcascadedspeechtranslation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:104152dc76027e569c0f30895e6a54913c8e7fac7eabc5e1594ee1270ce39c0d
+size 225556
diff --git a/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_content_list.json b/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..cf24077285dcaf8a929cf74154d284b823222539
--- /dev/null
+++ b/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1f50b4427be9e779c0071265cfb521c9e30d1583b67b9dbad5ee33d1edf8423e
+size 85261
diff --git a/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_model.json b/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..2c0bbfcbae00595c531582641335d3e3bb94e06e
--- /dev/null
+++ b/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ac84772eb76a3cce1c79e2791e0c5f261c847a678488fb55b8246a8538826b46
+size 102682
diff --git a/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_origin.pdf b/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..659954b2601d1bea29be8287c3f5201618512607
--- /dev/null
+++ b/doesselfrationalizationimproverobustnesstospuriouscorrelations/3b0cbba9-529d-4f38-bd32-f37db52aa400_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3323c956a8afff16aaea335ed9f552b1e553e0091606e267918ca69457c7292b
+size 351694
diff --git a/doesselfrationalizationimproverobustnesstospuriouscorrelations/full.md b/doesselfrationalizationimproverobustnesstospuriouscorrelations/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c317d9ed934e1223e377b52ecde406ff116ec3b6
--- /dev/null
+++ b/doesselfrationalizationimproverobustnesstospuriouscorrelations/full.md
@@ -0,0 +1,273 @@
+# Does Self-Rationalization Improve Robustness to Spurious Correlations?
+
+Alexis Ross†* Matthew E. Peters‡ Ana Marasović§*
+
+†Massachusetts Institute of Technology, Cambridge, MA, USA
+
+$^{\ddagger}$ Allen Institute for AI, Seattle, WA, USA
+
+$^{\S}$ University of Utah, Salt Lake City, UT, USA
+
+alexisro@mit.edu matthewp@allenai.org ana.marasovic@utah.edu
+
+# Abstract
+
+Rationalization is fundamental to human reasoning and learning. NLP models trained to produce rationales along with predictions, called self-rationalization models, have been investigated for their interpretability and utility to end-users. However, the extent to which training with human-written rationales facilitates learning remains an under-explored question. We ask whether training models to self-rationalize can aid in their learning to solve tasks for the right reasons. Specifically, we evaluate how training self-rationalization models with free-text rationales affects robustness to spurious correlations in fine-tuned encoder-decoder and decoder-only models of six different sizes. We evaluate robustness to spurious correlations by measuring performance on 1) manually annotated challenge datasets and 2) subsets of original test sets where reliance on spurious correlations would fail to produce correct answers. We find that while self-rationalization can improve robustness to spurious correlations in low-resource settings, it tends to hurt robustness in higher-resource settings. Furthermore, these effects depend on model family and size, as well as on rationale content. Together, our results suggest that explainability can come at the cost of robustness; thus, appropriate care should be taken when training self-rationalizing models with the goal of creating more trustworthy models.
+
+# 1 Introduction
+
+Rationalization—the process of explaining the reasoning used to come to a particular decision—plays a pivotal role in human inference and learning (Lombrozo, 2016). For these reasons, there has been a growing interest in producing NLP mod
+
+els that can output rationales1 for their predictions. Models that output such rationales have multiple benefits: First, they are more interpretable and easier to interact with for end-users than nonrationalizing models (Alvarez-Melis and Jaakkola, 2018). Second, such intermediate rationalization can offer learning benefits, such as achieving comparable performance with less data and improving out-of-distribution generalization (Nye et al., 2021; Wei et al., 2022; Zelikman et al., 2022).
+
+However, the question of whether training models to rationalize can help them learn how to solve tasks for the right reasons remains open. In particular, rationales encode information about the underlying reasoning humans use to reach answers, which raises the question: Does incorporating such rationales into training allow models to rely on human-aligned reasoning rather than spurious feature interactions? If so, training with rationales could offer a pathway towards creating more robust, trustworthy, or cognitively plausible models.
+
+In this work, we explore this question by empirically investigating whether training models with human-written rationales can help make them more robust to spurious correlations in data. We analyze a class of models called self-rationalization models—which jointly output free-text rationales along with predictions—and focus specifically on the fine-tuning setting, in which prior work has found reliance on spurious correlations to emerge (Utama et al., 2021).
+
+We evaluate six models of varying architectures and sizes across two tasks, natural language inference and commonsense question answering. Our main results are as follows:
+
+1. While the effects of training with rationales are model- and task-specific, when it improves robustness to spurious correlations, it tends
+
+to be in lower-resource settings. In higherresource settings, training with rationales can hurt robustness (§4.1).
+
+2. Within model families, larger models benefit more in robustness from rationales (§4.2).
+3. The effects of self-rationalization on robustness are not fully explained by its effects on in-domain task performance (§4.3).
+4. The content of rationales used during training influences both task performance and robustness to spurious correlations (§4.4).
+
+Our results suggest that straightforward self-rationalization training does not always facilitate learning to solve a task for the right reasons. Instead, the effects of self-rationalization on robustness to spurious correlations depend on a multitude of factors. Thus, appropriate care should be taken when training models to self-rationalize for the goal of creating trustworthy models.
+
+# 2 Related Work
+
+Learning to rationalize Two classes of approaches to producing models that can rationalize their predictions include self-rationalization models, which are fully differentiable and output free-text rationales along with task predictions, and pipeline models, which consist of two components—one that produces rationales, and a second that makes predictions from those rationales (Wiegreffe et al., 2021). Such methods are typically evaluated by the faithfulness and plausibility of their rationales, where faithfulness represents the extent to which a model actually relied on the rationale in making its prediction, and plausibility indicates human judgment of how well the rationale explains the output (DeYoung et al., 2020).
+
+In contrast to these works which aim to improve model interpretability through new methods for rationalizing models, we ask to what extent existing methods affect model robustness to spurious correlations. We conduct our analysis on self-rationalization models, which have been found to achieve better task performance and produce higher-quality rationales than do pipeline models (Wiegrefe et al., 2021; Camburu et al., 2018).
+
+Learning from rationales Recent work has explored the utility of rationales for improving endtask performance in in-context learning (Wei et al., 2022; Lampinen et al., 2022; Ye and Durrett, 2022) as well as in fine-tuning (Zaidan et al., 2007; Hancock et al., 2018; Camburu et al., 2018; Narang et al., 2020; Hase and Bansal, 2021; Nye et al., 2021; Zhao and Vydiswaran, 2021). Previous work has shown that training with both human-annotated rationales (Rajani et al., 2019) and rationales generated by language models (Paranjape et al., 2021) can increase in-domain task performance, particularly in low-resource settings (Bhat et al., 2021; Pruthi et al., 2022; Zelikman et al., 2022). Unlike these prior works, which study how training with rationales affects in-domain, end-task performance, we focus specifically on evaluating impact on robustness to spurious correlations.
+
+Improving robustness with rationales Most closely related are recent works that study how training with rationales affects model robustness. Stacey et al. (2022) propose a method of supervising attention weights with extractive rationales and show that this method leads to both in-distribution and out-of-distribution improvements for natural language inference. Schuster et al. (2021) find that training with contrastive extractive rationales improves robustness as measured by performance on adversarial evaluation sets. Concurrent work by Chen et al. (2022) investigates to what extent training models to extract rationales through pipelines improves their robustness to adversarial attacks.
+
+In contrast to all three of these works, we focus on freeform rationales instead of extractive rationales and explore the impact of amount of training data on robustness. In contrast to Schuster et al. (2021) and Chen et al. (2022), we analyze self-rationalization models instead of pipeline models and measure robustness to spurious correlations, rather than robustness to adversarial attacks. While Stacey et al. (2022) evaluate robustness to spurious correlations for natural language inference with some of the same test sets, they work with masked language models and evaluate the effect of supervising model attention with rationales; in contrast, we work with encoder-decoder and decoder-only models of varying sizes and evaluate the effect of outputting rationales along with predictions. In addition, their analysis is limited to natural language inference, for which evaluation datasets targeting robustness exist; in contrast, we also experiment
+
+with commonsense question answering through new methods for evaluating robustness. In §4.1, we discuss the variance in results across different tasks and highlight the importance of cross-task evaluation.
+
+# 3 Experiments
+
+# 3.1 Experimental Set-Up
+
+Models We experiment with encoder-decoder and decoder-only models of varying sizes ranging from 140 to 774 million parameters, as shown in Figures 1 and 2. Our encoder-decoder models build on pretrained T5 (Raffel et al., 2020) and BART models (Lewis et al., 2020), and our decoder-only models build on pretrained GPT2 (Radford et al., 2019) models. Our T5 models build specifically on the versions trained for an additional 100K steps on the language modeling objective after pretraining (Lester et al., 2021), as we aim to measure how the amount of training data impacts results, and the default T5 models have already been fine-tuned on the full SNLI training dataset. $^{4}$
+
+Tasks We evaluate self-rationalization models on two tasks—natural language inference (NLI), and commonsense question answering (CQA)—for which human-annotated rationales already exist. For NLI, we train task models on SNLI (Bowman et al., 2015) and obtain rationales from ESNLI (Camburu et al., 2018). For CQA, we train task models on CQA (Talmor et al., 2019) and obtain rationales from ECQA (Aggarwal et al., 2021). Examples of inputs and outputs for both tasks are shown in Table 2. For CQA, unless otherwise specified, we train on the “positive” freeform rationales in ECQA, which explain why the gold answer is the correct answer for a given question. In §4.4, we explore the impact of training with the different forms of rationales shown in Table 2.
+
+Rationales For each task, we compare a baseline model trained solely to predict task labels with models trained to also self-rationalize. All selfrationalization models are trained to generate a rationale following the task label, as previous work has found that outputting rationales conditioned on labels leads to better performance than outputting
+
+labels conditioned on rationales in the fine-tuning setting (Schuff et al., 2021).
+
+Data We experiment with different numbers of training examples $n$ , as we seek to understand how training data size influences the impact of self-rationalization training on robustness to spurious correlations. We experiment with $n \in \{1\mathrm{K}, 2.5\mathrm{K}, 5\mathrm{K}, 10\mathrm{K}, 50\mathrm{K}, 100\mathrm{K}\}$ for NLI and $n \in \{1\mathrm{K}, 5\mathrm{K}, 7598\}$ for CQA. For each training data amount $n$ , we create validation data for checkpointing models by randomly sampling $n/2$ instances from the original task-only validation dataset, such that we perform model selection based on task performance across baseline and self-rationalization models. For self-rationalization models, we create training data by concatenating original task-only training input-output pairs with their rationale-extended counterparts, such that we have $2n$ training inputs obtained from $n$ original instances.
+
+Training For each amount of training data $n$ , we report the average difference between task-only and self-rationalization models across multiple random seeds (5 for NLI and 10 for CQA). For one random seed in each evaluation setting (where a setting is determined by the task, model family, model size, whether rationales are used, and amount of training data), we tune the learning rate from possible values [1e-5, 3e-5, 5e-5] and use the best-performing learning rate for other random seeds in the same setting. We train with fixed batch size 64 and linear learning rate scheduler using Adafactor until accuracy on the validation data stops decreasing, or for a maximum of 50 epochs. We use patience values of 10 for $n < 10\mathrm{K}$ , 5 for $n >= 10\mathrm{K}$ and 3 for $n >= 50\mathrm{K}$ .
+
+Evaluation We decode predictions using greedy decoding and evaluate accuracy using exact match with gold labels. We evaluate robustness to spurious correlations by measuring performance on 1) manually annotated challenge datasets and 2) subsets of original test sets where reliance on spurious
+
+correlations would fail to produce correct answers. Both methods are discussed below in §3.2.
+
+# 3.2 Evaluating Reliance on Spurious Features
+
+Out-of-domain challenge datasets Our first method of evaluating reliance on spurious correlations leverages out-of-domain evaluation sets designed by experts to test for reliance on spurious features. For NLI, we evaluate on HANS (McCoy et al., 2019) and CAD (Kaushik et al., 2021). HANS is a controlled evaluation dataset that tests for reliance on surface-level syntactic biases present in SNLI. CAD is an evaluation dataset with human-annotated edits to inputs that change entailment labels. To the best of our knowledge, such evaluation datasets do not exist for CQA.
+
+| CQA
+Feature | z | NLI
+Feature | z |
| fountain | 3.50 | lex-overlap ≥ 0.8 | 140.16 (e) |
| music | 3.18 | for | 93.86 (n) |
| welcome | 3.01 | to | 83.30 (n) |
| atlas | 3.00 | sleeping | 80.68 (c) |
| satisfied | 3.00 | there | 78.11 (e) |
| hard | 2.98 | outside | 77.64 (e) |
| stage | 2.86 | nobody | 68.44 (c) |
| tale | 2.86 | outdoors | 65.17 (e) |
| amusement | 2.65 | no | 52.58 (c) |
| feel | 2.65 | cat | 50.72 (c) |
+
+Table 1: Features found to have statistically significant correlations with labels in training datasets using Gardner et al. (2021)'s framework. Details in §3.2.
+
+"Hard" subsets of original evaluation data To directly test for reliance on spurious correlations without introducing additional domain shifts, we also subset the original task test sets into subsets of varying difficulty, where difficulty is measured by the success of spurious heuristics: "Easy" subsets include instances for which heuristics that build on spurious correlations in training data would lead to correct predictions, and "hard" subsets include instances where such spurious heuristics would fail.
+
+To create these "easy" and "hard" subsets, we build on the statistical framework for uncovering dataset-level artifacts introduced by Gardner et al. (2021). Specifically, we measure correlation between features and outputs across the CQA and SNLI training datasets and consider as artifacts any features showing statistically significant correlation, i.e., with z-statistic $>2$ .
+
+For SNLI, we consider tokens in inputs as fea
+
+tures, as well as lexical overlap between premise and hypothesis. Following previous work (Wu et al., 2022), we consider an input to have high lexical overlap if the ratio of tokens in the hypothesis that are also present in the premise is at least 0.8. We use classification labels as outputs. For CQA, the feature and output spaces are less clearly defined, as it contains different output choices for each input. We take tokens in answer choices to be features and whether or not those tokens are present in the gold answers as outputs. To remove features that are very frequent or infrequent, we filter features that appear less than 10 or more than 200K times for SNLI and less than 5 or more than 10K times for CQA. Table 1 displays the 10 features with highest z-statistics for the CQA and SNLI training sets. $^{8}$
+
+We subset the original CQA and NLI test sets based on whether artifacts appear with the same output they showed statistically significant correlations with in the training datasets. TEST-HARD contains instances for which relying solely on artifacts to make predictions would fail to produce correct predictions (i.e., artifacts appear with a different output than they are correlated with), and TEST-EASY contains instances for which relying on artifacts would lead to correct predictions. For example, a CQA test instance for which an incorrect answer choice had token "fountain" would be considered "hard," as "fountain" has statistically significant correlation with being in the correct answer choice (Table 1). The sizes of TEST-EASY and TEST-HARD are 76/333 respectively for NLI and 82/372 for CQA. In addition to reporting performance values for these subsets, we measure the spread in performance on hard vs. easy subsets, i.e., TEST-EASY - TEST-HARD, which we refer to as $\Delta$ TEST-SUBSETS. We take a lower value of $\Delta$ TEST-SUBSETS to indicate less reliance on artifacts. For NLI, we also evaluate on TEST
+
+
+Figure 1: Effect of self-rationalization for NLI across six models (columns) and varying amounts of training data (x axis). Bar heights show mean differences between baseline task-only models and self-rationalization models for: task performance (row 1), performance on manually annotated challenge datasets (rows 2-3), performance on hard subsets of original SNLI evaluation data (rows 4-5), and $\Delta$ TEST-SUBSETS (row 6). Baseline values are shown in gray. Error bars indicate standard errors of the means. Green/red bars indicate improvement/degradation in robustness; gray bars indicate error bars intersecting 0.
+
+HYP, a subset of the SNLI test set for which a hypothesis-only classifier was found to give incorrect predictions (Gururangan et al., 2018).11
+
+# 4 Results
+
+Figures 1 and 2 show, for NLI and CQA respectively, the effects of self-rationalization across multiple random seeds. Plotted are mean differences between self-rationalization models and baseline
+
+worse on TEST-HARD than on TEST-EASY for both NLI and CQA. In addition, baseline accuracies on TEST-HARD are notably worse than accuracies on the full test sets (row 1) for NLI. While this latter trend does not hold as consistently for CQA, we observe that the baseline accuracies on original test sets are lower for CQA than for NLI. Thus, we hypothesize that for CQA, the relative lack of drop in performance on TEST-HARD compared to original test sets can be explained by the fact that ECQA contains fewer artifacts and so original test sets are already "hard" for CQA models in the sense of prevalence of artifacts to be exploited.
+
+11We do not evaluate on the analogous "easy" counterpart for TEST-HYP, i.e., the subset for which a hypothesis-only classifier succeeds, as it would require re-training a hypothesis-only classifier; instead, we evaluate only on the TEST-HYP subset released by Gururangan et al. (2018).
+
+task-only models (i.e., self-rationalization - baseline) across six models (columns) and varying amounts of training data (x axis). Improvements on TEST (row 1) reflect in-domain, task improvements, while improvements on other metrics (rows $>1$ ) indicate robustness improvements.
+
+# 4.1 Main Results
+
+As shown in Figure 1, under our evaluation of robustness to spurious correlations, we observe that self-rationalization improves the robustness of BART- and GPT2-based NLI models in lower resource data settings. In higher resource settings, we observe a degradation in some robustness metrics, namely performance on TEST-HYP & TEST-HARD and $\Delta$ TEST-SUBSETS for all models except BART-LARGE. For BART-BASE, this degradation in higher-resource settings is also seen for performance on HANS. The T5 models (T5-BASE & T5-LARGE) show more mixed results: While self-rationalization hurts performance on
+
+
+Figure 2: Effect of self-rationalization for CQA across six models (columns) and varying amounts of training data (x axis). Bar heights show mean differences between baseline task-only models and self-rationalization models for: task performance (row 1), performance on the TEST-HARD subset of original CQA evaluation data (rows 2-3), and $\Delta$ TEST-SUBSETS (row 4). Baseline values are shown in gray. Error bars indicate standard errors of the means. Green/red bars indicate improvement/degradation in robustness; gray bars indicate error bars intersecting 0.
+
+HANS for both T5-BASE and T5-LARGE in all data regimes, it improves performance on some metrics, i.e., $\Delta$ TEST-SUBSETS in higher-resource settings $(n >= 5k)$ for T5-LARGE. $^{12}$
+
+For CQA (Figure 2), results are more mixed, and they depend on model properties, i.e., architecture and size, as well as size of the training data. For BART and GPT2 models of size LARGE, training with rationales generally leads to improvements. For models smaller than size LARGE, as well as both T5 models, the effect of training with rationales depends on the amount of training data, but rationales tend to hurt robustness in higher-resource settings (7.6K training examples) for these models.
+
+These general trends are similar to those for NLI, with more improvements from self-rationalization in lower-resource settings and some degradation in higher-resource settings. However, unlike for NLI, the results are not always monotonic in the amount of training data, particularly for BART-BASE and GPT2-MEDIUM on $\Delta$ TEST-SUBSETS. In addition, for GPT2-LARGE, results on $\Delta$ TEST-SUBSETS improve with increasing data size, opposite to the
+
+general trend. Furthermore, improvements in TEST-HARD are similar to standard errors, except for T5-BASE and $n = 1\mathrm{K}$ , suggesting that even in low-resource settings, self-rationalization does not notably improve robustness for CQA.
+
+The varied results for CQA and lack of consistency between NLI and CQA may be influenced by the differing numbers of artifacts in the datasets; in particular, perhaps self-rationalization training has a larger effect on robustness to spurious correlations when there are more spurious correlations in the training data (as in SNLI but not ECQA). We leave it to future work to investigate the impact of artifacts in training data on effect of rationales. The differences between NLI and CQA also suggest that evaluations solely based on NLI may not cleanly transfer to other tasks; this finding provides further evidence that the benefits of rationales are task-dependent (Carton et al., 2020; Palaskar et al., 2022) and that evaluations on one task such as NLI alone are not comprehensive enough to draw general conclusions about the utility of rationales.
+
+# 4.2 Effect of Model Size
+
+For NLI, for the GPT2 and BART models, we find that increasing model size leads to increasing gains in robustness: Self-rationalization leads to larger improvements in robustness for BART-LARGE than for BART-BASE, and similarly for GPT2-LARGE and GPT2-MEDIUM (except for when $n = 2.5\mathrm{K}$ );
+
+| NLI input:
+snli hypothesis: The family is sitting down for dinner. premise: A couple play in the tide with their young son. |
| SNLI | contradiction |
| ESNLI | contradiction explanation: The family cannot simultaneously be playing in the tide and sitting down to dinner. |
| CQA input:
+Where would you get a dog if you do not have one? (A) pet store (B) outside (C) neighbor's house (D) park (E) rug |
| CQA | pet store |
| ECQA Positive | pet store explanation: Pet store is a retail business which sells different kinds of animals, variety of animal supplies and pet accessories to the public. We would get a dog at a pet store, if we do not have one. |
| ECQA Negative | pet store explanation: Outside means not in the living or working area. Those found outside in streets are street dogs and are not usually a pet dog. Neighbor's house is the man who lives in the house next door to your house is your neighbor and the house in which he lives is your neighbor's house. The one at neighbor's house is his pet dog and we can't get it even though we don't have one. Park is a large public garden or area of land used for recreation. Dogs found at park are street dogs not suitable for being a pet. Rug is a floor covering of thick woven material or animal skin, typically not extending over the entire floor. Rug is a floor covering and not a pet shop where we can get a dog. |
| ECQA Freeflow | pet store explanation: Pet store is a retail business which sells different kinds of animals, variety of animal supplies and pet accessories to the public. We would get a dog at a pet store if we do not have one. Those found outside in streets are street dogs and are not usually a pet dog. The one at neighbor's house is his pet dog and we can't get it even though we don't have one. Dogs found at park are street dogs not suitable for being a pet. Rug is a floor covering and not a pet shop where we can get a dog. |
+
+Table 2: Examples of inputs and outputs used for training baseline and self-rationalization models.
+
+ | TEST | CAD | HANS | TEST HYP | TEST HARD | Δ TEST SUBSETS |
| ↑ | ↑ | ↑ | ↑ | ↑ | ↓ |
| 1K no rationales | 84.62 | ±0.31 | 71.20 | ±0.27 | 50.18 | ±0.08 | 73.68 | ±0.40 | 73.82 | ±0.85 | 14.70 | ±1.50 |
| original | +1.05 | ±0.21 | +1.75 | ±0.34 | +0.44 | ±0.19 | +1.56 | ±0.40 | +2.04 | ±0.91 | -2.04 | ±1.93 |
| shuffled | -0.59 | ±0.37 | -2.11 | ±0.45 | +0.86 | ±0.52 | -1.81 | ±0.50 | -2.51 | ±1.60 | +4.15 | ±2.85 |
+
+Table 3: Comparison between training BART-LARGE on 1K training instances with original rationales in ESNLI vs. shuffled rationales across 5 random seeds. We report means, as well as standard errors of the means.
+
+Furthermore, we do not observe the same degradation in robustness for BART-LARGE in higher-resource settings that we observe for BART-BASE. For the T5 models, self-rationalization generally leads to less degradation in robustness for T5-LARGE than for T5-BASE. For CQA, we observe a similar trend: self-rationalization generally leads to larger improvements in robustness for BART-LARGE than for BART-BASE, for GPT2-LARGE than for GPT2-MEDIUM, and for T5-LARGE than for T5-BASE (except for when $n = 1\mathrm{K}$ ).
+
+Thus, our results suggest that, within model families, increasing model size may improve effects on robustness from training with rationales. Previous work has shown that rationales improve in-domain performance only for larger models, in both fin-tuning (Nye et al., 2021) and in-context learning (Wei et al., 2022; Lampinen et al., 2022); our results can be seen as an extension of this finding to the effects of training with rationales on robustness. It is worth noting that the trends we observe
+
+appear to be specific to model families, i.e., increasing model size has no noticeable effect when not conditioning on model family.
+
+# 4.3 Correlation between robustness metrics
+
+To determine how results on different robustness metrics relate to each other, we compute their correlations. These correlations should indicate how much insight we can get into the overall impact of self-rationalization on a model's robustness by only looking at select metrics. For each pair of metrics in Figure 1, we aggregate the differences in performance between baseline and self-rationalization performance on those metrics in all evaluation settings (e.g., model type, training data size), and compute the Pearson Correlation of these values.
+
+As shown in Figure 3, results on the "hard" subsets of original test data (TEST-HARD & TEST-HYP) are overall correlated with the results on out-of-domain challenge datasets; the lowest correlation we observe for these subsets is between TEST-
+
+
+Figure 3: Pearson correlations between results on pairs of evaluation metrics. Each cell color is determined by absolute value of the correlation coefficient.
+
+HYP and HANS, with Pearson coefficient 0.449. Furthermore, CAD and HANS, the manually annotated challenge sets, show low correlation with each other, with a Pearson coefficient of 0.271, suggesting that out-of-domain performance does not straightforwardly reflect all aspects of robustness. We also observe that in-domain test performance is not always highly correlated with robustness metrics, with Pearson coefficient magnitudes as low as 0.496; this result suggests that difference in test performance is not entirely predictive of the effect of self-rationalization on robustness. In other words, training with rationales has effects on robustness that go beyond facilitating or hurting in-domain task performance.
+
+# 4.4 Effect of rationale content
+
+Shuffled explanations One hypothesis for why training models to output rationales in addition to predictions may improve robustness is that it serves as a form of regularization; under this hypothesis, training to output even rationales with low explanatory power might improve robustness to spurious correlations by reducing overfitting.
+
+To determine to what extent rationale content influences effects on robustness, we experiment with shuffling rationales during training such that the rationale for a given input no longer explains that input. Results from training BART-LARGE with shuffled rationales for NLI are shown in Table 3. We also report results for BART-BASE, GPT2-MEDIUM, and T5-LARGE, which follow a similar trend, in Table 5 in the Appendix. We find that, as expected, training with shuffled rationales leads to worse robustness compared to training with
+
+original rationales, except on HANS.
+
+Different ECQA rationales We also experiment with training BART-LARGE with the different rationale types in the ECQA dataset, depicted in Table 2. Results for BART-BASE, GPT2-MEDIUM, and T5-LARGE, which follow a similar trend, are shown in Table 6 in the Appendix.
+
+"Positive" rationales explain why the gold answer is correct for a given question, "negative" rationales explain why other choices are incorrect, and "freeflow" rationales combine positive and negative rationales into a coherent and free-flowing paragraph and thus constitute freeform contrastive rationales.[13] As shown in Table 4, training with 1K positive rationales improves performance on both TEST & TEST-HARD and decreases $\Delta$ TEST-SUBSETS. In contrast, training with 1K negative or freeflow rationales hurts performance on TEST & TEST-HARD. We also observe that training with freeflow rationales generally leads to worse results than positive rationales and better results than negative rationales. In contrast to prior findings on the benefits of contrastive rationales (Paranjape et al., 2021; Schuster et al., 2021), our results suggest that contrastive rationales do not always provide more learning benefits than non-contrastive rationales, given that training with freeflow rationales hurts robustness compare to the non-contrastive positive rationales.
+
+A possible explanation for the differences in effects from training with these different rationale types is their varying lengths. As shown in Table 2, negative and freeflow rationales are longer than positive rationales.[14] To rule out this explanation, we also train BART-LARGE with length-controlled negative and freeflow rationales, in which we truncate their lengths to 96 tokens, the maximum length used to train with positive rationales. As shown in Table 4, we still observe degradation in both task performance and robustness when using negative or freeflow rationales rather than positive rationales. These consistent results suggest that rationale content, rather than length, indeed influences learning.
+
+Another possible explanation for these varied effects is that the topical relevance of rationales to gold labels may influence their utility in training. Positive rationales, as explanations of gold
+
+| no rationales | TEST
+↑ | TEST
+HARD
+↑ | Δ TEST
+SUBSETS
+↓ |
| 48.3 | ±0.8 | 49.0 | ±1.0 | 19.9 | ±1.8 |
| positive | +2.2 | ±1.3 | +2.2 | ±1.0 | -1.9 | ±3.0 |
| freeflow | -2.3 | ±1.1 | -1.7 | ±1.2 | -2.4 | ±2.5 |
| freeflow* | -3.3 | ±0.4 | -1.1 | ±2.7 | +2.2 | ±4.3 |
| negative | -4.1 | ±1.2 | -3.7 | ±1.8 | -1.4 | ±2.1 |
| negative* | -5.3 | ±0.3 | -1.7 | ±0.5 | -1.6 | ±2.0 |
+
+Table 4: Effect of training BART-LARGE with different types of rationales in ECQA. Blue/red cells indicate improvement/worsening in performance compared to the baseline (no rationales, row 1). * indicates length-controlled rationales, i.e., truncation of the negative and freeform rationales to have the same length as the positive rationales. We report means across 5 random seeds, as well as standard errors of the means.
+
+answers, are more topically related to gold answers than negative rationales, while freeflow rationales have topical relevance between those of positive and negative rationales. We observe that the effects of training with these rationale types align with their levels of topical relevance. Future work can further explore how properties like topical relevance influence the utility of rationales.
+
+# 5 Conclusion
+
+We investigate to what extent training models to rationalize their predictions affects their robustness to spurious correlations. We experiment with encoder-decoder and decoder-only models ranging in size from 140 to 774 million parameters across two tasks—natural language inference and commonsense question-answering—and measure reliance on spurious correlations through both manually-annotated, out-of-domain challenge sets and challenging in-domain subsets of original test sets. We find that the effects of self-rationalization are model- and task-specific: While self-rationalization can improve robustness to spurious correlations in lower-resource settings for some models and tasks, it tends to exacerbate reliance on spurious correlations in higher-resource settings. Furthermore, larger models tend to benefit more from rationales, and rationale content influences rationale utility in improving robustness.
+
+The variability of our results suggests that, despite the appeal of self-rationalization models for increasing model trustworthiness by facilitating debugging and interaction with end-users (Jacovi
+
+et al., 2021a), training models to self-rationalize can have the unintended effect of increasing reliance on spurious features and biases, thereby decreasing the models' trustworthiness. Thus, appropriate care should be taken when training self-rationalization models with the goal of creating trustworthy models. Future work can investigate how to alleviate these harms while retaining the interpretability benefits of models that can rationalize their predictions.
+
+# 6 Limitations
+
+Conducting the analysis in this work required training over 700 models, particularly because the variability of model robustness requires training multiple models, governed by different random seeds, for every evaluation setting of interest. Thus, a main limitation of replicating this work is its computational demand.
+
+Furthermore, even with the scale of our experiments, we do not exhaustively experiment with all possible evaluation settings of interest. Most notably, we focus our analysis on a standard way of training self-rationalization models—training generation models end-to-end to output rationales after their predictions; future work can investigate how our findings translate to other methods for training with rationales. In addition, while many evaluation sets targeting robustness exist for NLI, they do not for CQA; thus, our evaluation of robustness to spurious correlations for CQA were limited. Future work can develop more tests for evaluating robustness for tasks beyond NLI.
+
+# Acknowledgements
+
+We thank Howard Chen, Chenhao Tan, Joe Stacey, Marek Rei, members of the AllenNLP team, and anonymous reviewers for their helpful feedback.
+
+# References
+
+Shourya Aggarwal, Divyanshu Mandowara, Vishwajeet Agrawal, Dinesh Khandelwal, Parag Singla, and Dinesh Garg. 2021. *Explanations for Common-senseQA: New Dataset and Models.* In *Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics* and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 3050–3065, Online. Association for Computational Linguistics.
+
+David Alvarez-Melis and Tommi S. Jaakkola. 2018. Towards robust interpretability with self-explaining neural networks. NeurIPS.
+
+Meghana Moorthy Bhat, Alessandro Sordoni, and Subhabrata Mukherjee. 2021. Self-training with few-shot rationalization. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 10702-10712, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Samuel R. Bowman, Gabor Angeli, Christopher Potts, and Christopher D. Manning. 2015. A large annotated corpus for learning natural language inference. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 632-642, Lisbon, Portugal. Association for Computational Linguistics.
+Oana-Maria Camburu, Tim Rocktäschel, Thomas Lukasiewicz, and Phil Blunsom. 2018. e-snli: Natural language inference with natural language explanations. In S. Bengio, H. Wallach, H. Larochelle, K. Grauman, N. Cesa-Bianchi, and R. Garnett, editors, Advances in Neural Information Processing Systems 31, pages 9539-9549. Curran Associates, Inc.
+Samuel Carton, Anirudh Rathore, and Chenhao Tan. 2020. Evaluating and characterizing human rationales. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 9294-9307, Online. Association for Computational Linguistics.
+Howard Chen, Jacqueline He, Karthik Narasimhan, and Danqi Chen. 2022. Can rationalization improve robustness?
+Jay DeYoung, Sarthak Jain, Nazneen Fatema Rajani, Eric Lehman, Caiming Xiong, Richard Socher, and Byron C. Wallace. 2020. ERASER: A benchmark to evaluate rationalized NLP models. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4443-4458, Online. Association for Computational Linguistics.
+Matt Gardner, William Merrill, Jesse Dodge, Matthew Peters, Alexis Ross, Sameer Singh, and Noah A. Smith. 2021. Competency problems: On finding and removing artifacts in language data. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1801-1813, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Suchin Gururangan, Swabha Swayamdipta, Omer Levy, Roy Schwartz, Samuel Bowman, and Noah A. Smith. 2018. Annotation artifacts in natural language inference data. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 107-112, New Orleans, Louisiana. Association for Computational Linguistics.
+Braden Hancock, Paroma Varma, Stephanie Wang, Martin Bringmann, Percy Liang, and Christopher
+
+Ré. 2018. Training classifiers with natural language explanations. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1884-1895, Melbourne, Australia. Association for Computational Linguistics.
+Peter Hase and Mohit Bansal. 2021. When can models learn from explanations? A formal framework for understanding the roles of explanation data.
+Alon Jacovi, Ana Marasovic, Tim Miller, and Yoav Goldberg. 2021a. Formalizing trust in artificial intelligence: Prerequisites, causes and goals of human trust in ai. In Proceedings of the 2021 ACM Conference on Fairness, Accountability, and Transparency, FAccT '21, page 624-635, New York, NY, USA. Association for Computing Machinery.
+Alon Jacovi, Swabha Swayamdipta, Shauli Ravfogel, Yanai Elazar, Yejin Choi, and Yoav Goldberg. 2021b. Contrastive explanations for model interpretability. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1597-1611, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Divyansh Kaushik, Amrith Setlur, Eduard Hovy, and Zachary C Lipton. 2021. Explaining the efficacy of counterfactually augmented data. International Conference on Learning Representations (ICLR).
+Andrew K. Lampinen, Ishita Dasgupta, Stephanie C. Y. Chan, Kory Matthewson, Michael Henry Tessler, Antonia Creswell, James L. McClelland, Jane X. Wang, and Felix Hill. 2022. Can language models learn from explanations in context?
+Brian Lester, Rami Al-Rfou, and Noah Constant. 2021. The power of scale for parameter-efficient prompt tuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 3045-3059, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: Denoising sequence-to-sequence pretraining for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880, Online. Association for Computational Linguistics.
+Tania Lombrozo. 2016. Explanatory preferences shape learning and inference. Trends in Cognitive Sciences, 20(10):748-759.
+Tom McCoy, Ellie Pavlick, and Tal Linzen. 2019. Right for the wrong reasons: Diagnosing syntactic heuristics in natural language inference. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3428-3448,
+
+Florence, Italy. Association for Computational Linguistics.
+Tim Miller. 2019. Explanation in Artificial Intelligence: Insights from the social sciences. Artificial Intelligence, 267:1-38.
+Sharan Narang, Colin Raffel, Katherine Lee, Adam Roberts, Noah Fiedel, and Karishma Malkan. 2020. Wt5?! training text-to-text models to explain their predictions.
+Maxwell I. Nye, Anders Johan Andreassen, Guy Gur-Ari, Henryk Michalewski, Jacob Austin, David Bieber, David Dohan, Aitor Lewkowycz, Maarten Bosma, David Luan, Charles Sutton, and Augustus Odena. 2021. Show your work: Scratchpads for intermediate computation with language models.
+Shruti Palaskar, Akshita Bhagia, Yonatan Bisk, Florian Metze, Alan W. Black, and Ana Marasovic. 2022. On advances in text generation from images beyond captioning: A case study in self-rationalization. Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing (EMNLP).
+Bhargavi Paranjape, Julian Michael, Marjan Ghazvininejad, Hannaneh Hajishirzi, and Luke Zettlemoyer. 2021. Prompting contrastive explanations for commonsense reasoning tasks. In *Findings of the Association for Computational Linguistics: ACL-IJCNLP* 2021, pages 4179-4192, Online. Association for Computational Linguistics.
+Adam Poliak, Jason Naradowsky, Aparajita Haldar, Rachel Rudinger, and Benjamin Van Durme. 2018. Hypothesis only baselines in natural language inference. In Proceedings of the Seventh Joint Conference on Lexical and Computational Semantics, pages 180-191, New Orleans, Louisiana. Association for Computational Linguistics.
+Danish Pruthi, Rachit Bansal, Bhuwan Dhingra, Livio Baldini Soares, Michael Collins, Zachary C. Lipton, Graham Neubig, and William W. Cohen. 2022. Evaluating Explanations: How Much Do Explanations from the Teacher Aid Students? Transactions of the Association for Computational Linguistics, 10:359-375.
+Alec Radford, Jeff Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. 2019. Language models are unsupervised multitask learners.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140):1-67.
+Nazneen Fatema Rajani, Bryan McCann, Caiming Xiong, and Richard Socher. 2019. Explain yourself!
+
+leveraging language models for commonsense reasoning. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4932-4942, Florence, Italy. Association for Computational Linguistics.
+Alexis Ross, Ana Marasovic, and Matthew Peters. 2021. Explaining NLP models via minimal contrastive editing (MiCE). In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 3840-3852, Online. Association for Computational Linguistics.
+Hendrik Schuff, Hsiu-Yu Yang, Heike Adel, and Ngoc Thang Vu. 2021. Does external knowledge help explainable natural language inference? automatic evaluation vs. human ratings. In Proceedings of the Fourth BlackboxNLP Workshop on Analyzing and Interpreting Neural Networks for NLP, pages 26-41, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Tal Schuster, Adam Fisch, and Regina Barzilay. 2021. Get your vitamin C! robust fact verification with contrastive evidence. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 624-643, Online. Association for Computational Linguistics.
+Joe Stacey, Yonatan Belinkov, and Marek Rei. 2022. Supervising model attention with human explanations for robust natural language inference. AAAI, abs/2104.08142.
+Alon Talmor, Jonathan Herzig, Nicholas Lourie, and Jonathan Berant. 2019. CommonsenseQA: A question answering challenge targeting commonsense knowledge. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4149-4158, Minneapolis, Minnesota. Association for Computational Linguistics.
+Prasetya Utama, Nafise Sadat Moosavi, Victor Sanh, and Iryna Gurevych. 2021. Avoiding inference heuristics in few-shot prompt-based finetuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 9063-9074, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Eric Wallace, Shi Feng, Nikhil Kandpal, Matt Gardner, and Sameer Singh. 2019. Universal adversarial triggers for attacking and analyzing NLP. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 2153-2162, Hong Kong, China. Association for Computational Linguistics.
+Jason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma, Ed Chi, Quoc Le, and Denny Zhou. 2022.
+
+Chain of thought prompting elicits reasoning in large language models.
+Sarah Wegreffe, Ana Marasovic, and Noah A. Smith. 2021. Measuring association between labels and free-text rationales. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 10266-10284, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Yuxiang Wu, Matt Gardner, Pontus Stenetorp, and Pradeep Dasigi. 2022. Generating data to mitigate spurious correlations in natural language inference datasets. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2660-2676, Dublin, Ireland. Association for Computational Linguistics.
+Xi Ye and Greg Durrett. 2022. The unreliability of explanations in few-shot in-context learning.
+Omar Zaidan, Jason Eisner, and Christine Piatko. 2007. Using "annotator rationales" to improve machine learning for text categorization. In Human Language Technologies 2007: The Conference of the North American Chapter of the Association for Computational Linguistics; Proceedings of the Main Conference, pages 260-267, Rochester, New York. Association for Computational Linguistics.
+Eric Zelikman, Yuhuai Wu, and Noah D. Goodman. 2022. Star: Bootstrapping reasoning with reasoning.
+Xinyan Zhao and V. G. Vinod Vydiswaran. 2021. Lirex: Augmenting language inference with relevant explanation. AAAI, abs/2012.09157.
+
+ | TEST | CAD | HANS | TEST HYP | TEST HARD | Δ TEST SUBSETS |
| ↑ | ↑ | ↑ | ↑ | ↑ | ↓ |
| BART-BASE no rationales | 75.37 | ±0.15 | 57.85 | ±0.61 | 51.30 | ±0.58 | 59.80 | ±0.67 | 56.86 | ±0.66 | 25.44 | ±2.75 |
| original | +0.21 | ±0.18 | +1.04 | ±0.63 | +0.96 | ±0.62 | -0.18 | ±0.38 | +1.41 | ±0.46 | -2.73 | ±1.65 |
| shuffled | -4.71 | ±0.83 | -5.60 | ±1.11 | -0.21 | ±0.39 | -5.60 | ±1.05 | -4.40 | ±1.52 | +2.10 | ±3.81 |
| GPT2-MEDIUM no rationales | 66.39 | ±0.94 | 48.84 | ±0.81 | 52.66 | ±0.38 | 48.70 | ±1.20 | 47.59 | ±2.22 | 33.39 | ±2.19 |
| original | +1.12 | ±0.66 | +0.80 | ±0.73 | +1.42 | ±0.27 | +0.59 | ±1.07 | +3.61 | ±2.16 | -3.94 | ±3.97 |
| shuffled | -1.97 | ±0.75 | -2.45 | ±0.95 | +0.96 | ±0.55 | -3.72 | ±1.46 | 0.00 | ±3.09 | +0.66 | ±4.63 |
| BART-LARGE no rationales | 84.62 | ±0.31 | 71.20 | ±0.27 | 50.18 | ±0.08 | 73.68 | ±0.40 | 73.82 | ±0.85 | 14.70 | ±1.50 |
| original | +1.05 | ±0.21 | +1.75 | ±0.34 | +0.44 | ±0.19 | +1.56 | ±0.40 | +2.04 | ±0.91 | -2.04 | ±1.93 |
| shuffled | -0.59 | ±0.37 | -2.11 | ±0.45 | +0.86 | ±0.52 | -1.81 | ±0.50 | -2.51 | ±1.60 | +4.15 | ±2.86 |
| T5-LARGE no rationales | 84.03 | ±0.34 | 71.08 | ±0.31 | 51.54 | ±0.31 | 74.26 | ±0.54 | 75.45 | ±0.71 | 10.46 | ±1.03 |
| original | +0.26 | ±0.21 | +0.62 | ±0.48 | -1.13 | ±0.17 | -0.10 | ±0.40 | -0.42 | ±1.11 | +2.06 | ±2.33 |
| shuffled | -0.67 | ±0.41 | -0.23 | ±0.18 | +3.02 | ±0.98 | -0.75 | ±0.70 | -2.62 | ±1.25 | +3.27 | ±2.46 |
+
+Table 5: Comparison between training with original rationales in ESNLI vs. shuffled rationales with 1K instances for NLI. Blue/red cells indicate improvement/worsening in performance compared to the baseline (no rationales). We report means across 5 random seeds, as well as standard errors of the means.
+
+ | TEST
+↑ | TEST
+HARD
+↑ | Δ TEST
+SUBSETS
+↓ |
| BART-BASE
+no rationales | 32.4 | ±0.3 | 33.6 | ±0.5 | 14.7 | ±1.4 |
| positive | 0.0 | ±0.4 | +1.4 | ±0.8 | -2.9 | ±2.3 |
| freeflow | -1.4 | ±0.7 | +0.3 | ±1.2 | -0.0 | ±1.9 |
| freeflow* | -1.7 | ±0.4 | -0.6 | ±0.8 | -0.0 | ±3.1 |
| negative | -3.5 | ±1.0 | -2.5 | ±1.2 | -2.0 | ±1.6 |
| negative* | -3.1 | ±0.8 | -2.2 | ±0.8 | +3.8 | ±1.7 |
| GPT2-MEDIUM
+no rationales | 30.6 | ±0.4 | 29.2 | ±1.5 | 13.3 | ±3.5 |
| positive | +2.3 | ±0.3 | +0.9 | ±1.5 | +2.6 | ±2.5 |
| freeflow | +2.6 | ±0.4 | +2.1 | ±0.6 | +2.7 | ±2.8 |
| freeflow* | +3.4 | ±0.6 | +2.9 | ±0.6 | +1.8 | ±2.4 |
| negative | +0.9 | ±0.2 | +0.8 | ±1.1 | +1.8 | ±3.7 |
| negative* | +1.1 | ±0.4 | +0.9 | ±0.6 | +1.3 | ±1.9 |
| BART-LARGE
+no rationales | 48.3 | ±0.8 | 49.0 | ±1.0 | 19.9 | ±1.8 |
| positive | +2.2 | ±1.3 | +2.2 | ±1.0 | -1.9 | ±3.0 |
| freeflow | -2.3 | ±1.1 | -1.7 | ±1.2 | -2.4 | ±2.5 |
| freeflow* | -3.3 | ±0.4 | -1.1 | ±2.7 | +2.2 | ±4.3 |
| negative | -4.1 | ±1.2 | -3.7 | ±1.8 | -1.4 | ±2.1 |
| negative* | -5.3 | ±0.3 | -1.7 | ±0.5 | -1.6 | ±2.0 |
| T5-LARGE
+no rationales | 60.4 | ±0.7 | 61.5 | ±1.5 | 10.5 | ±1.9 |
| positive | +1.2 | ±0.7 | +2.0 | ±1.7 | +2.4 | ±1.3 |
| freeflow | +1.0 | ±0.9 | +1.6 | ±1.3 | +0.3 | ±1.4 |
| freeflow* | +1.0 | ±0.7 | +1.7 | ±0.9 | +2.1 | ±1.2 |
| negative | -1.1 | ±0.6 | -1.3 | ±0.8 | +4.5 | ±3.1 |
| negative* | -1.3 | ±0.5 | -1.6 | ±0.7 | +2.5 | ±1.4 |
+
+Table 6: Effect of training with 1K instances using the different types of rationales in ECQA. * indicates length-controlled rationales. Blue/red cells indicate improvement/worsening in performance compared to the baseline (no rationales, row 1). We report means across 5 random seeds, as well as standard errors of the means.
\ No newline at end of file
diff --git a/doesselfrationalizationimproverobustnesstospuriouscorrelations/images.zip b/doesselfrationalizationimproverobustnesstospuriouscorrelations/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..acf58c164fd5db652b4550a3bdf61580344af315
--- /dev/null
+++ b/doesselfrationalizationimproverobustnesstospuriouscorrelations/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f326499ef03583550dcdfcbd2687608bfcf3238c5ed2f02ee2aa8a8ee58072ab
+size 680408
diff --git a/doesselfrationalizationimproverobustnesstospuriouscorrelations/layout.json b/doesselfrationalizationimproverobustnesstospuriouscorrelations/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..0d79557cef4fddb12cca9debdc5d261ded285799
--- /dev/null
+++ b/doesselfrationalizationimproverobustnesstospuriouscorrelations/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f87c528186ea06999098413411ea8d7fb98e0632d514a84b74672dae12f84195
+size 319580
diff --git a/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_content_list.json b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..b06290722c32d7ddcdbe4139a0d65eb29349afc8
--- /dev/null
+++ b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:aabff8663086219ea2ab9aa0c3200308b8abb33b7ea7c8d9a6100a37c3adaf51
+size 123234
diff --git a/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_model.json b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..490583c726ee072a9503e11623d121c986389fd1
--- /dev/null
+++ b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5d808f742bccd3bc52d6c1ba84aa8b8b2bc58d9863f6785ee238cdeaa1ea8a75
+size 143390
diff --git a/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_origin.pdf b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..0a56739c6981192797a6ccd51bde8e3dee93266b
--- /dev/null
+++ b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/fd96ee25-2cc1-425f-be20-28f6cf769b05_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ddb9d06a5a280d25cf64ab0a101828ab0255c586472bbffc4b285b5b8fc2fb8e
+size 743795
diff --git a/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/full.md b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..dfa578e3e637b5dd85d2ead36746d3c173755ce3
--- /dev/null
+++ b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/full.md
@@ -0,0 +1,427 @@
+# Does Your Model Classify Entities Reasonably?
+
+# Diagnosing and Mitigating Spurious Correlations in Entity Typing
+
+Nan Xu, Fei Wang, Bangzheng Li, Mingtao Dong, Muhao Chen
+
+Department of Computer Science & Information Sciences Institute
+
+University of Southern California
+
+{nanx,fwang598,bangzhen,mingtaod,muhaoche}@usc.edu
+
+# Abstract
+
+Entity typing aims at predicting one or more words that describe the type(s) of a specific mention in a sentence. Due to shortcuts from surface patterns to annotated entity labels and biased training, existing entity typing models are subject to the problem of spurious correlations. To comprehensively investigate the faithfulness and reliability of entity typing methods, we first systematically define distinct kinds of model biases that are reflected mainly from spurious correlations. Particularly, we identify six types of existing model biases, including mention-context bias, lexical overlapping bias, named entity bias, pronoun bias, dependency bias, and overgeneralization bias. To mitigate model biases, we then introduce a counterfactual data augmentation method. By augmenting the original training set with their debiased counterparts, models are forced to fully comprehend sentences and discover the fundamental cues for entity typing, rather than relying on spurious correlations for shortcuts. Experimental results on the UFET dataset show our counterfactual data augmentation approach helps improve generalization of different entity typing models with consistently better performance on both the original and debiased test sets1.
+
+# 1 Introduction
+
+Given a sentence with an entity mention, the entity typing task aims at predicting one or more words or phrases that describe the type(s) of that specific mention (Ling and Weld, 2012; Gillick et al., 2014; Choi et al., 2018). This task essentially supports the structural perception of unstructured text (Distiawan et al., 2019), being an important step for natural language understanding (NLU). More specifically, entity typing has a broad impact on various NLP tasks that depend on type understanding, including coreference resolution (Onoe and Durrett, 2020), entity linking (Hou et al., 2020; Tianran
+
+# Mention-Context bias
+
+Input: Last week I stayed in Treasure Island for two nights when visiting Las Vegas.
+
+Gold labels: hotel, resort, location, place
+
+Pred labels: island, land, location, place
+
+# Lexical Overlapping bias
+
+Input: Next day ( $\rightarrow$ Next twenty-four hour period), after the Slovaks captured Rymanow Zdroj and the Germans seized Krosno, the Brigade was ordered to withdraw to Sanok and leave Dukla.
+
+Gold labels: day, time, event, date, year
+
+Pred labels: day, time, date
+
+# Named Entity bias
+
+Input: Kevin Donovan ( $>$ Brennan), after seeing Michael Caine movie about the Zulu uprising, decided to form the Universal Zulu Nation, an organization based on merits derived from art and achievements rather than violence and muscle.
+
+Gold labels:performer,adult,celebrity,actor,personPred labels:actor,person,artist,director
+
+# Pronoun bias
+
+Input: He $(->$ Daffy) said Sarkozy's decision was a "stab in the back" to Chinese dissidents, who had been "abandoned" by France.
+
+Gold labels: politician, spokesman, person
+Pred labels: politician, spokesman, person, leader, male, official, spokesperson
+
+# Dependency bias
+
+
+
+Input: Most car spoilers are made from polyurethane, while some are made from lightweight steel or fiberglass.
+
+Gold labels: part, object
+
+Pred labels:object, car, vehicle
+
+
+
+# Overgeneralization bias
+
+Input: Of the dairy cows, $40\%$ are of the local Baladi breed, $26\%$ are purebred Friesian imported from Germany and Holland and $34\%$ are cross between Baladi and Canadian Holstein.
+
+Gold labels: breed, cow, animal, cattle, organism
+
+Pred labels: animal
+
+
+
+Figure 1: Examples demonstrating spurious correlations exploited by one of the SOTA entity typing models $ML\text{-}\text{MET}$ . Left context is in magenta, entity mention in italic blue, right context in green. Perturbations upon mentions and new predictions start from $\rightarrow / \rightarrow$ . implies good predictions by exploiting spurious correlations and indicates bad predictions when spurious correlations no longer exist. $ML\text{-}\text{MET}$ falsely relies on the entity name to give "island" predictions for a hotel mention, incorrectly infers types of the dependent "car" rather than the headword "spoiler", and gives only the coarse label "animal" with more fine-grained missing.
+
+et al., 2021), entity disambiguation (Onoe and Durrett, 2020), event detection (Le and Nguyen, 2021) and relation extraction (Zhou and Chen, 2022).
+
+To tackle the task, literature has developed vari
+
+ous predictive methods to capture the association between the contextualized entity mention representation and the type label. For instance, a number of prior studies approach the problem as multiclass classification based on distinct ways of representing the entity mentioning sentences (Yogatama et al., 2015; Ren et al., 2016; Xu and Barbosa, 2018; Dai et al., 2021). Other studies formulate the problem as structured prediction and leverage structural representations such as box embeddings (Onoe et al., 2021) and causal chains (Liu et al., 2021) to model the dependency of type labels. However, due to shortcuts from surface patterns to annotated entity labels and biased training, existing entity typing models are subject to the problem of spurious correlation (Wang and Culotta, 2020; Wang et al., 2021; Branco et al., 2021). For example, given a sentence "Last week I stayed in Treasure Island for two nights when visiting Las Vegas.", a SOTA model like MLMET (Dai et al., 2021) may overly rely on the entity name and falsely type Treasure Island as an island, while ignoring the sentential context that indicates this entity as a resort or a hotel. For morphologically rich mentions with multiple noun words such as "most car spoilers", entity models may fail to understand its syntactic structure and miss the target entity from the actual head-dependent relationship, leading to predictions describing the dependent car (car, vehicle) rather than the head spoilers (part). Such spurious clues can cause the models to give unfaithful entity typing and further harm the machine's understanding of the entity mentioning text.
+
+To comprehensively investigate the faithfulness and reliability of entity typing methods, the first contribution of this paper is to systematically define distinct kinds of model biases that are reflected mainly from spurious correlations. Particularly, we identify the following six types of existing model biases, for which examples are illustrated in Fig. 1. Those biases include mention-context biases, lexical overlapping biases, named entity biases, pronoun biases, dependency structure biases and overgeneralization biases. We provide a prompt-based method to identify instances posing those biases to the typing model. In the meantime, we illustrate that common existence of these types of biased instances causes it hard to evaluate whether a model is faithfully comprehending the entire context to infer the type, or trivially leveraging surface forms or distributional cues to guess the type.
+
+We introduce a counterfactual data augmentation (Zmigrod et al., 2019) method for debiasing entity typing, as the second contribution of this paper. Given biased features, we reformulate entity typing as a type-querying cloze test and leverage a pre-trained language model (PLM) to fill in the blank. By augmenting the original training set with their debiased counterparts, models are forced to fully comprehend the sentence and discover the fundamental cues for entity typing, rather than rely on spurious correlations for shortcuts. Compared with existing debiasing approaches such as product of experts (He et al., 2019), focal loss (Karimi Mahabadi et al., 2020), contrastive learning (Zhou et al., 2021) and counterfactual inference (Qian et al., 2021), our counterfactual data augmentation approach helps improve generalization of all studied models with consistently better performance on both original UFET (Choi et al., 2018) and debiased test sets.
+
+# 2 Method
+
+In this section, we start with the problem definition (§2.1) and then categorize and diagnose the spurious correlations causing shortcut predictions by the typing model (§2.2). Lastly, we propose a counterfactual data augmentation approach to mitigate the identified spurious correlations, as well as several alternative techniques that apply (§2.3).
+
+# 2.1 Problem Definition
+
+Given a sentence $s$ with an entity mention $e \in s$ , the entity typing task aims at predicting one or more words or phrases $T$ from the label space $L$ that describe the type(s) of $e$ .
+
+By nature, the inference of type $T$ should be context-dependent. Take the first sample demonstrated in Fig. 1 as an instance: in "Last week I stayed in Treasure Island for two nights when visiting Las Vegas," Treasure Island should be typed as hotel and resort, rather than island or land by trivially considering the surface of mention phrase.
+
+# 2.2 Spurious Correlations Diagnoses
+
+We systematically define six types of typical model biases caused by spurious correlations in entity typing models. For each bias, we qualitatively inspect its existence and the corresponding spurious correlations used by a SOTA entity typing model on sampled instances with bias features. Following Poerner et al. (2020), we prompt a PLM, RoBERTa
+
+| PLM Prompts | Entity Typing Instances |
| Mention-Context:
+Prompt I: <Mention> is a type of <mask>.
+S1: fire is a type of <mask>.
+RoBERTa: energy, heat, explosion, fire, gas
+S2: the war is a type of <mask>.
+True labels: war, battle, conflict
+RoBERTa: war, battle, conflict, violence, warfare | T1: A teacher who survived the shooting said he would never forgive the police for taking an hour to arrive after the gunman opened fire.
+True labels: injury, shooting, event, violence
+MLMET: event, object, fire (F1: 0.285)
+T2: fire
+MLMET: object, fire (F1: 0.0) |
| Lexical Overlapping:
+Prompt II: <Left Context> <New Mention with Word Substitution>
+Right Context>. <New Mention with Word Substitution> is a type of <mask>.
+S3: Next twenty-four hour period, after the Slovaks captured ... Next twenty-four hour period is a type of <mask>.
+RoBERTa: confusion, retreat, ambush, battle, timeline | T3: Next day, after the Slovaks captured Zdroj the Brigade was ordered to withdraw to Sanok.
+True labels: day, time, event, date, year
+MLMET: day, time, date (F1: 0.749)
+T4: Next twenty-four hour period, after the Slovaks captured Zdroj, the Brigade was ordered to withdraw to Sanok.
+MLMET: time, hour, period (F1: 0.25) |
| Named Entity:
+Prompt III: The <Attribute> <Named Entity> is a type of <mask>.
+S4: The person Benjamin Netanyahu is a type of <mask>.
+RoBERTa: politician, person, character, personality, man
+S5: The person Jintara Poonlarp is a type of <mask>.
+RoBERTa: person, human, woman, personality, character | T5: Benjamin Netanyahu asserted that Amin al-Husseini had been one of the masterminds of the Holocaust.
+True labels: politician, leader, person
+MLMET: politician, leader, person (F1: 1.0)
+T6: Jintara Poonlarp asserted that Amin al-Husseini had been one of the masterminds of the Holocaust.
+MLMET: person, scholar, writer (F1: 0.333) |
| Pronoun:
+Prompt IV: <Left Context> <Person Name> <Right Context>.
+<Sperson Name> is a type of <mask>.
+S6: Judith other film credits include “The Four Feathers,” “Dr. T & the Women” and “200 Cigarettes.” Judith is a type of <mask>.
+RoBERTa: bird, cat, vampire, rabbit, dog | T7: Her other film credits include “The Four Feathers,” “Dr. T & the Women” and “200 Cigarettes.”
+Truths: woman, performer, adult, female, entertainer, person, actress
+MLMET: woman, female, actress, person, artist (F1: 0.666)
+T8: Judith other film credits include “The Four Feathers,” “Dr. T & the Women” and “200 Cigarettes.”
+MLMET: person (F1: 0.25) |
+
+Table 1: Entity typing instances with content-based biases recognized by RoBERTa-large (Liu et al., 2019). To reflect the shortcuts exploited by entity typing models (\$2.2), we list the sentences, labels and predictions from one of the SOTA models MLMET in T1, T2, T3, T5 and T7. To identify biased instances (\$2.2), we show the constructed masked fill-in task to query the PLM with mention types from S1 to S6. To mitigate spurious correlations (\$2.3), we show the proposed counterfactual data augmentation where the shortcuts disappear and the model fails in T4, T6 and T8. We underline the mention span in italic boldface and record the macro F1 score for each prediction.
+
+large (Liu et al., 2019), to identify potential biasing samples with either detected surface patterns or facts captured during training. To do so, we reformulate entity typing as a type-querying cloze task and perform the analysis as follows.
+
+1) Mention-Context Bias: Semantically rich entity mentions may encourage the model to overly associate the mention surface with the type without considering the key information stated in contexts. An example is accordingly shown in T1 of Tab. 1, where MLMET predicts types that correspond to the case where "fire" is regarded as burning instead of gun shooting. Evidently, this is due to not effectively capturing the clues in the context such as "shooting" and "gunman". This is further illustrated by the counterfactual example T2, where the model predicts almost the same labels when seeing "fire" without a context.
+
+To identify potential instances with the mention-context bias, we query the PLM to infer the entity
+
+types based only on the mention with the template shown in Prompt I (Tab. 1). Therefore, samples where the PLM can accurately predict without the context information are regarded as biased. Entity typing models can easily achieve good performance on those biased samples by leveraging spurious correlations between their mention surface and types, as shown in S2 from Tab. 1.
+
+2) Lexical Overlapping Bias: Type labels that have lexical overlaps with the entity mention can also become prediction shortcuts. As shown in T3 from Tab. 1: labeling mention "next day" with the type day and additional relevant types leads to the F1 up to 0.749. We observe a considerable amount of similar examples, e.g., typing the mention "eye shields" as shield, "the Doha negotiations" as negotiation, etc. The highly overlapped mention words and type labels make it difficult to evaluate whether the model makes predictions based on content comprehension or simply lexical similarities.
+
+| Bias Type | Analyses | Entity Typing Instances |
| Dependency:
+Models fail to capture the syntactic structure and make type predictions focusing on other components rather than the dependency headword | S6 Dependency Parsing:
+token | text | head text | T9: Dubois contributed an article on whale anatomy to a book by the Dutch zoologist, Max W Subjectbeber, and, inspired by the fresh discovery of new Neanderthal fossils at the Belgian town of Spy, he spent his vacation fossil hunting in the vicinity of his birthplace.
+True labels: subject, topic
+MLMET: object, animal (F1: .0) |
| 1st whale anatomy
+2nd anatomy anatomy |
| T10: Dubois contributed an article on anatomy to a book by the Dutch zoologist, Max W Subjectbeber, and, inspired by the fresh discovery of new Neanderthal fossils at the Belgian town of Spy, he spent his vacation fossil hunting in the vicinity of his birthplace.
+MLMET: object, concept, subject (F1: .4) |
| Overgeneralization:
+Models suffer from biased training due to extreme class imbalance | Statistics:
+Counts of Coarse Types:
+person: 824, event: 181 | T11: Many nineteenth-century individualist archaeists, including Benjamin Tucker, rejected the anarcho-capitalist Lockean position in favour of the anarchist position of “occupancy and use” -LRB- or “possession”, to use Proudhon's term -RRB-, particularly in land. |
| Counts of Ultra-fine Types:
+concept: 68, activity: 23, trouble: 8, difficulty: 6, problem: 5, misconduct: 1, use: 1, abuse: 0 | True labels: person
+MLMET: person (F1: 1.0) |
| T12: In a letter, the exchange said its investigations had turned up “no evidence of abusive behavior.”
+True labels: behavior, wrongdoing, difficulty, misconduct, trouble, use, activity, problem, concept, abuse
+MLMET: behavior, event (F1: .166) |
| T13: <NULL Input>
+MLMET: person (prob=0.992) |
+
+Table 2: Entity typing instances from UFET test set with biases detected based on statistical analyses. To discover shortcuts utilized by entity typing models ( $\S 2.2$ ), we show one Dependency bias instance where the model fails to locate the target entity in the mention (T9) and two Overgeneralization bias instances: T11 annotated by coarse types and T12 annotated by ultra-fine types. To quantify the overgeneralization bias ( $\S 2.2$ ), we query the typing model with an empty sentence in T13. To mitigate spurious correlations ( $\S 2.3$ ), we do dependency parsing to distinguish headwords from dependents in S6 and truncate the mention with only the headword preserved as T10 to help address dependency bias.
+
+We substitute the overlapping mention words with semantically similar words and ask the PLM to infer the entity types on such perturbed instances (details introduced in §2.3) by prompting with the template Prompt II (Tab. 1). We consider instances have lexical overlapping biases when the PLM performs poorly after the overlapped mention words are substituted, as shown in S3 of Tab. 1.
+
+3) Named Entity Bias: On cases where mentions refer to high-reporting entities in corpora, models may be trained to ignore the context but directly predict labels that co-occur frequently with those entities. We show a concrete instance to type a person named entity in T5 of Tab. 1. The mention Benjamin Netanyahu, known as Israeli former prime minister, is normally annotated with politician, leader and authority. After observing popular named entities and their common annotations during training, models are able to predict their common types, making it hard to evaluate models' capabilities to infer context-sensitive labels.
+
+As illustrated in Prompt III (Tab. 1), we prompt the PLM to type the named entity when only the name and its general attribute is given, e.g., the geopolitical area India or the organization Apple, etc. We regard instances to have the named entity bias when the PLM accurately infers the mention
+
+types relying on prior knowledge of named entities. In Tab. 1, we show one instance with the mention containing Benjamin Netanyahu in S4, and the Thai pop music singer – Jintara Poonlarp in S51. Based on types related to Benjamin's political role in S4 and general types for Jintara in S5, we consider instances to type mentions including Benjamin as biased while those with Jintara as unbiased.
+
+4) Pronoun Bias: Compared with diverse person names, pronouns show up much more frequently to help make sentences smoother and clearer. Therefore, models are subject to biased training to type pronouns well, but lose the ability to type based on diverse real names. To type the pronoun her in T7 of Tab. 1, the entity typing model can successfully infer general types woman, female as well as the context-sensitive type actress. To obtain high generalization, we expect models to infer types correctly for both pronouns and their referred names.
+
+We substitute the gender pronoun with a random person name of the same gender (details introduced in §2.3) and ask the PLM to infer the types with Prompt IV (Tab. 1). We consider samples to have the pronoun bias when the PLM fails to capture the majority of types after the name substitution, as
+
+shown in S6 of Tab. 1.
+
+5) Dependency Bias: It is observed that the mention's headwords explicitly match the mention to its types (Choi et al., 2018). However, models may fail to capture the syntactic structure with predictions focusing on dependents instead of headwords. We show an instance with inappropriate focus among mention words in T9 of Tab. 2. Without understanding the mention's syntactic structure, entity typing models may make predictions that are irrelevant to the actual entity.
+
+Since knowledge about mention structures is beneficial for typing complex multi-word mentions, we mitigate the bias by data augmentation to improve model learning (details introduced in §2.3), rather than identify whether the bias exists or not.
+
+6) Overgeneralization Bias: When training with disproportional distributed labels, frequent labels are more likely to be predicted compared with rare ones. Entity typing datasets are naturally imbalanced (Gillick et al., 2014; Choi et al., 2018). We show two instances annotated by coarse- and fine-grained labels in T11 and T12 of Tab. 2: the model can easily predict the coarse-grained label person to describe "anarchist", but fails to infer less frequent but more concrete labels such as misconduct and wrongdoing to type behavior. Models ought to type entities by reasoning on mentions and contexts, rather than trivially fitting the label distribution.
+
+As shown in T13 of Tab. 2, we craft a special instance - an empty sentence, with which the uniform distribution over all types is expected from models free of overgeneralization bias. We then compute its disparity with the model's actual probability distribution: the higher/lower probability predicted on popular/rare types, the more biased the model on the label distribution.
+
+Discussion The prior defined six biases are not mutually exclusive. We discuss some possible mixtures of concurrent biases as follows:
+
+Mention-Context and Lexical Overlapping Bias: the model falsely types the mention "Treasure Island" as island, without understanding the context talking about the holiday accommodation. Another possible reason that the mention far outweighs the context might be the high word similarity between mention word "Island" and type word "island".
+
+Dependency and Lexical Overlapping Bias: ML-MET incorrectly makes the prediction car for the mention "most car spoilers" without distinguishing important headwords from less important depen
+
+dent words. Another reasonable explanation for emphasizing on the dependent rather than the headword is its perfect lexical match with the type set, where "car" is a relatively popular label but no type has high word similarity with "spoilers". To diagnose and mitigate all spurious correlations the entity typing model may take advantage of, we disentangle the multiple biases on a single instance by analyzing each bias individually without considering their mutual interactions.
+
+# 2.3 Mitigating Spurious Correlations
+
+Models exploiting spurious correlations lack the required reasoning capability, leading to unfaithful typing and harmed out-of-distribution generalization when bias features observed during training do not hold. Therefore, we propose to mitigate spurious correlations from the counterfactual data augmentation perspective: for each instance recognized with specific bias features, we automatically craft its debiased counterpart and train entity typing models with both samples. Whenever the model prefers to exploit biasing features, it will fail on newly crafted debiased instances and actively look for more robust features: understanding and reasoning on the sentence rather than exploiting spurious correlations. Considering the characteristic textual patterns from different biases, we propose the following distinct strategies to craft debiased instances for four types of biases (with examples explained in Appx. §A.1). Note that although we can hardly craft a new instance free of mention-context bias or overgeneralization bias, we can choose to leverage the alternative debiasing techniques introduced in later parts of this section for these two biases.
+
+Counterfactual Augmentation On instances diagnosed with lexical overlapping biases, we perform word substitutions in two steps to substitute mention words lexically similar to type labels with original semantics preserved. To do so, we identify the sense of type words in mentions using an off-the-shelf word sense disambiguation model (Barba et al., 2021) and substitute them with their WordNet synonyms. We consider perturbed sentences with poor performance from the PLM as the counterfactual augmented instances free from lexical overlapping bias, to prohibit the entity typing model from exploiting spurious correlations (T4 of Tab. 1).
+
+For instances with the named entity bias, we augment by performing named entity substitution according to the following criteria. 1) validity: sub
+
+stituted entities should have the same general type as the original ones $^{1}$ , e.g., the geopolitical area "India" can be replaced by "London"; 2) debiased: models training on large corpora should not possess comprehensive knowledge of the new named entities. Basically, we leverage an off-the-shelf NER model (Ushio and Camacho-Collados, 2021) to identify and classify named entities into general NER types provided by this model, and then divide the entities into informative and non-informative group based on the prompt-based typing performance by the PLM. We then substitute informative named entities with non-informative ones sharing the same NER type as the counterfactual augmented instances (T6 of Tab. 1).
+
+For the pronoun bias, we craft new instances by concretizing pronoun mentions in two situations. If co-reference resolution (Toshniwal et al., 2021) detects the referred entity of the pronoun mention in the context, that entity is selected as the new mention. Otherwise, the gender pronoun mention will be substituted with a randomly sampled masculine/feminine name from the NLTK corpus (Bird, 2006). New sentences with the actual person names are considered counterfactual augmented if the PLM fails to infer the person's type with contextual information given (T7 of Tab. 1).
+
+We further augment from instances where mentions have internal dependency structures to tackle the dependency bias. First, we use a dependency parsing tool (Honnibal et al., 2020) to recognize the dependency parse tree of the mention. On top of that, we truncate all other dependent words in the new mention to create the augmentation. From associations between explicitly provided headwords and their matching labels, the models are encouraged to learn dependency structures for targeted entity typing and predict precisely when headwords and dependents are mixed in mentions (T9 of Tab. 2).
+
+Together with the new instances with headwords explicitly given, instances counterfactually augmented upon the entity typing training set is utilized to allow various entity typing models to learn to mitigate spurious correlations. Meanwhile, we leverage the counterfactual augmented instances derived from the test set for model evaluation.
+
+# Alternative Debiasing Techniques In addition
+
+to data augmentation, other applicable debiasing techniques can be used to resample or reweight original instances in training, or directly measure and deduct biases in inference. A typical resampling technique is AFLite (Le Bras et al., 2020) which drops samples predicted accurately by simple models such as fasttext (Joulin et al., 2017). Reweighting techniques typically train one or more models to proactively identify and upweight underrepresented instances in the training process, which includes product of experts, debiased focal loss, learned-mixin and its variant learned-mixin+H (Clark et al., 2019; He et al., 2019; Karimi Mahabadi et al., 2020). On the other hand, counterfactual inference (Qian et al., 2021) measures prediction biases based on counterfactual examples (e.g. masking out the context for measuring mention-context biases, or giving empty inputs to measure overgeneralization biases (Wang et al., 2022)), and directly deducts the biases in inference. In addition, contrastive learning (Chen and He, 2021; Caron et al., 2021; Chen and He, 2021) can be used to adopt a contrastive training loss (Caron et al., 2021; Chen and He, 2021) to discourage the model from learning similar representations for full and bias features2. Next, we compare our approach with those techniques.
+
+# 3 Experiments
+
+In this section, we start with describing the experimental setups (§3.1). Next, we diagnose entity models to measure their reliance on spurious correlations (§3.2). We then compare our counterfactual data augmentation with other debiasing techniques for spurious correlation mitigation (§3.3).
+
+# 3.1 Experimental Settings
+
+We leverage the ultra-fine entity typing (UFET) dataset (Choi et al., 2018) to evaluate entity typing models and apply different mitigation approaches either during training or as inference post-processing. UFET comes with $6K$ samples from crowdsourcing and $25.2M$ distant supervision samples. There are 10,331 types in total, among which nine are general (e.g., person), 121 are fine-grained (e.g., engineer), and 10,201 are
+
+| Test Set | Mention-Context 131/1085 (↑) | Lexical Overlapping 475/3 (↓) | Named Entity 36/500 (↓) | Pronoun 881/20 (↓) | Dependency 280, 222/961 | Overgeneralization 93/242 |
| BiLSTM | MLMET | BiLSTM | MLMET | BiLSTM | MLMET | BiLSTM | MLMET | BiLSTM | MLMET | BiLSTM | MLMET |
| Biased | .385 | .654 | .510 | .551 | .504 | .735 | .494 | .561 | .152 | .424 | .466 | .427 |
| -Perturb. | .400 | .654 | .050 | .327 | .332 | .600 | .179 | .525 | .396 | .564 | .118 | .232 |
| (3.8%) | (0.0%) | (-90.3%) | (-40.8%) | (-34.0%) | (-18.4%) | (-63.8%) | (-6.4%) | (160.5%) | (32.9%) |
| Unbiased | .265 | .436 | .392 | .544 | .316 | .505 | .366 | .683 | - | - | - | - |
| -Perturb. | .253 | .395 | .167 | .444 | .372 | .539 | .130 | .659 | - | - | - | - |
| (-4.7%) | (-9.4%) | (-57.5%) | (-18.2%) | (17.6%) | (6.9%) | (-64.6%) | (-3.5%) |
+
+Table 3: F1 scores of two representative entity typing models on UFET testing samples with(out) distinct biases and their perturbations: mention-only input for Mention-Context, overlapped word substitution for Lexical Overlapping, named entity substitution for Named Entity, name substitution for Pronoun. Below each bias, the number of model-agnostic biased and unbiased instances are listed and $\downarrow / \uparrow$ indicates expected performance from models leveraging spurious correlations after perturbing biased instances. Relative performance drop/increase after testing on their perturbations is recorded in brackets. For Dependency bias, we show performance on 280 and 222 out of 961 test samples where the two models benefit from making predictions based on headwords and contexts respectively. For Overgeneralization bias, we show performance on 93/242 samples annotated by purely coarse/ultra-fine types (values on different subsets hence incomparable). See results of all five models evaluated by full metrics in Tab. 7.
+
+ultra-fine (e.g., flight engineer). We follow prior studies (Choi et al., 2018) to evaluate entity typing models with macro-averaged precision, recall and F1. We also study spurious correlations and effectiveness of the proposed debiasing approach on OntoNotes (Gillick et al., 2014). As results present similar observations, we leave detailed analysis in Appx. §A.3.
+
+Entity Typing Baselines We diagnose the prediction biases and the effectiveness of distinct debiasing models based on following approaches: 1) BiLSTM (Choi et al., 2018) concatenates the context representation learned by a bidirectional LSTM and the mention representation learned by a CNN to predict entity labels. 2) LabelGCN (Xiong et al., 2019) introduces graph propagation to encode global label co-occurrence statistics and their word-level similarities. 3) LRN (Liu et al., 2021) autoregressively generates entity labels from coarse to fine levels, modeling the coarse-to-fine label dependency as causal chains. 4) Box4Types (Onoe et al., 2021) proposes to embed concepts as d-dimensional hyper rectangles (boxes), so that hierarchies of types could be captured as topological relations of boxes. 5) MLMET (Dai et al., 2021) augments training data by constructing mention-based input for BERT to predict context-dependent mention hypernyms for type labels. Without loss of generality, we discuss results of two representative models, the earliest BiLSTM training from scratch and the latest MLMET finetuning on the PLM, for the sake of clarity in this section. As the observations on the other models are similar, we
+
+leave those results in Appx. $\S A$
+
+# 3.2 Diagnosing Entity Typing Models
+
+In Tab. 3, we report performance of entity typing models trained on UFET. The models are tested on original biased samples and their perturbed new instances to reflect exploited spurious correlations. We conduct similar analyses on unbiased samples.
+
+1) Mention-Context Bias: When perturbing the biased samples by only feeding their mentions to typing models, the performance of MLMET keeps unchanged while the performance of BiLSTM even improves by $3.8\%$ . This disobeys the task goal of entity typing where types of the mentions should also depend on contexts, and we suggest that samples with mention-context biases are insufficient for a faithful evaluation of a reliable typing system.
+
+2) Lexical Overlapping Bias: After substituting label-overlapped mention words with semantically similar words, performance of both models drops drastically especially on biased samples identified by the PLM. Compared with MLMET, BiLSTM has less parameter capacity and is more inclined to leverage lexical overlapping between mentions and type labels as the shortcut for typing.
+
+Compared with original biased instances, the perturbed instances with label-overlapped mention words replaced might look less natural or fluent. In Tab. 4, we therefore substitute words from different parts of instance, and prove that performance degradation is caused by removed lexical overlapping bias rather than unnatural or dysfluent input.
+
+3) Named Entity Bias: After replacing named entities to be less impacted from biased prior knowl-
+
+| Perturbed Words | BiLSTM | MLMET |
| Label-overlapped Mention | -63.84% | -38.60% |
| Non Label-overlapped Mention | -2.77% | -11.64% |
| Context | 3.86% | -0.18% |
+
+Table 4: F1 performance variation after perturbing words at different parts of instances from UFET test with their synonyms. Much higher performance drop after replacing label-overlapped mention words proves the degradation caused by removing label overlapping bias rather than potential reduced naturalness or fluency due to word substitution.
+
+edge, performance of both studied models in Tab. 3 decreases considerably when encountering named entities, with which models struggle to capture spurious correlations with mention types. Interestingly, perturbing unbiased samples by utilizing named entities with bias provides shortcuts for prediction, leading to improved performance of both models.
+
+4) Pronoun Bias: With pronouns replaced by their referred entities in contexts or random masculine/feminine names otherwise, we observe serious performance degradation from both models, which demonstrates their common weakness on typing more diverse and less frequent real names.
+
+5) Dependency Bias: With headwords directly exposed to entity typing models by dropping all other less important dependents, performance from BiLSTM on around $30\%$ of all testing samples with dependency structures gets improved dramatically, while MLMET also predicts more precisely on $23\%$ of samples. Hereby, we confirm that existing entity models still suffer from extracting core components of given mentions for entity typing and appeal for more research efforts to address this problem.
+
+6) Overgeneralization Bias: Models are subject to making biased predictions towards popular types observed during training, which leads to contrastive performance on instances purely annotated by coarse and ultra-fine types, as shown in Tab. 3. This problem is exemplified in a case study in Tab. 5, where typing models are queried with an empty sentence. Compared with the uniform probability distribution expected from models free from overgeneralization bias, existing models are inclined to give much higher probabilities to coarse types such as person and title.
+
+# 3.3 Mitigating Spurious Correlations
+
+In Tab. 6, we evaluate robustness of entity typing models after adopting the proposed counterfactual data augmentation or alternative debiasing tech
+
+| Model | Top/Bottom Types (Prob.) |
| BiLSTM | person (.928), title (.437), concept (.104)... .vice squad (.000), adolescent (.000), supporter (.000) |
| LabelGCN | concept (.349), increase (.249), case (.192)... .archipelago (.000), spiritual leader (.000), national park (.000) |
| Box4Types | object (.626), person (.282), company (.231)... .dismissal (.000), trump (.000), small town (.000) |
| LRN | person (.998), writer (.000), place (.000)... .chicken leg (.000), chicken wing (.000), chicken wire (.000) |
| MLMET | person (.992), time (.314), title (.100)... .consortium (.000), negotiator (.000), football player (.000) |
+
+Table 5: Top and bottom predictions and their probabilities when querying typing models with empty input.
+
+niques, and present results on the UFET test set with bias and our counterfactually debiased test set.
+
+Overall, our counterfactual data augmentation is the only approach that consistently improves the generalization of the studied models across both test sets. Particularly, we achieve the best performance on UFET and the debiased test set with MLMET. Besides, models trained with our approach improve the performance of BiLSTM and MLMET relatively by $71.15\%$ and $11.81\%$ on the debiased test set, respectively, implying the least reliance on spurious correlations to infer correct entity types.
+
+When evaluating other debiasing approaches, we find that 1) none of the resampling or reweighting techniques is capable to maintain the performance on UFET test set of both models, which could be attributed to the large-scale label space and the existence of diverse causes of model biases; 2) contrastive learning with either cross entropy loss or cosine similarity loss helps improve performance on debiased samples, but leads to accuracy drop of MLMET on UFET; 3) without updating model parameters given bias features, counterfactual inference fails to improve performance of MLMET on debiased samples.
+
+# 4 Related Work
+
+Entity Typing Earlier studies on entity typing (Yogatama et al., 2015; Ren et al., 2016; Xu and Barbosa, 2018) learned contextual embeddings for entity mentions and types to capture their association. To model label correlations without annotated label hierarchies in UFET, LabelGCN (Xiong et al., 2019) introduced the graph propagation layer to encode global label co-occurrence statistics and their word-level similarities, whereas HMGCN (Jin et al., 2019) proposed to infer this information from a knowledge base. For the same purpose,
+
+| Approach | BiLSTM | MLMET |
| U-Prec. | U-Rec. | U-F1 | A-Prec. | A-Rec. | A-F1 | U-Prec. | U-Rec. | U-F1 | A-Prec. | A-Rec. | A-F1 |
| No Debiasing | .471 | .242 | .320 | .242 | .182 | .208 | .527 | .452 | .487 | .554 | .414 | .474 |
| AFLite | .529 | .209 | .300 | .296 | .142 | .192 | .526 | .450 | .485 | .551 | .420 | .477 |
| POE | .441 | .281 | .343 | .339 | .267 | .299 | .518 | .458 | .486 | .543 | .425 | .477 |
| Focal | .315 | .341 | .328 | .207 | .269 | .234 | .520 | .460 | .488 | .545 | .419 | .474 |
| Learned-mixin | .396 | .289 | .335 | .282 | .279 | .280 | .483 | .472 | .478 | .480 | .453 | .466 |
| Learned-mixin+H | .279 | .326 | .301 | .182 | .338 | .237 | .405 | .529 | .459 | .379 | .485 | .425 |
| Contrastive (CE) | .461 | .272 | .342 | .312 | .354 | .331 | .477 | .471 | .474 | .449 | .460 | .454 |
| Contrastive (Cosine) | .440 | .257 | .325 | .462 | .265 | .337 | .495 | .451 | .472 | .489 | .441 | .464 |
| Counterfact. Inf. | .442 | .264 | .331 | .347 | .173 | .231 | .525 | .454 | .487 | .492 | .446 | .468 |
| Augmentation (ours) | .473 | .260 | .336 | .345 | .367 | .356 | .515 | .466 | .489 | .540 | .470 | .530 |
+
+Table 6: Effectiveness of different debiasing approaches on two representative entity typing models when testing on UFET test set (U-) and our counterfactual augmented test set (A-). The best performance per column is marked in bold while improved values over those without debiasing in italic. For contrastive learning, CE stands for the cross entropy and Cosine represents cosine similarity. See results of three other entity typing models in Tab. 10.
+
+Box4Types (Onoe et al., 2021) was proposed to embed concepts as hyper rectangles (boxes), such that their topological relations can represent type hierarchies. Considering the prevailing noisy labels in existing entity typing datasets, Onoe and Durrett (2019) performed supervised denoising to filter and fix noisy training labels. Dai et al. (2019) introduced distant supervision from entity linking results. To tackle the sparsity of training, recent work conducted data augmentation with a masked language model and WordNet knowledge to enrich the training data (Dai et al. 2021; MLMET), and made use indirect supervision from natural language inference (Li et al. 2022; LITE). Despite much attention in literature, to the best of our knowledge, our work represents the first investigation on faithfulness and reducing shortcuts in this task.
+
+Spurious Correlations in NLP Models Much recent effort has been put into studying spurious correlation in Natural Language Inference (NLI) tasks. Recent studies show that crowd workers are prone to produce annotation artifacts (Gururangan et al., 2018) through the rapid annotation process and result in identifiable shortcut features (Karimi Mahabadi et al., 2020; Du et al., 2021a). Hence, simple models can easily achieve good performance even with partial inputs (Kaushik et al., 2019; Karimi Mahabadi et al., 2020), or leveraging superficial syntactic properties (McCoy et al., 2019; Utama et al., 2020; Pezeshkpour et al., 2021). On several other NLP tasks composed of multiple textual components, it has been observed that models fed with partial inputs can already achieve compet
+
+itive performance, e.g., predicting for claim verification (Schuster et al., 2019; Utama et al., 2020; Du et al., 2021b) or argument reasoning comprehension (Niven and Kao, 2019; Branco et al., 2021) with only the claim, choosing a plausible story ending without seeing the story (Cai et al., 2017), question answering using a positional bias (Jia and Liang, 2017; Kaushik and Lipton, 2018), etc.
+
+The spurious correlation problems in information extraction tasks are still an under-explored area. Despite most recent studies on NER (Zhang et al., 2021) and relation extraction (Wang et al., 2022), this work represents the first attempt to diagnose spurious correlations in entity typing, for which we comprehensively analyzed various types of causes for biases and provided a dedicated debiasing method. We also conducted a comprehensive comparison with various alternatives based on resampling (Le Bras et al., 2020), reweighting (Clark et al., 2019; Karimi Mahabadi et al., 2020) and counterfactual inference (Wang et al., 2022).
+
+# 5 Conclusions
+
+To comprehensively investigate the faithfulness and reliability of entity typing methods, we systematically define six kinds of model biases that are reflected mainly from spurious correlations. In addition to diagnosing the biases on representative models using benchmark data, we also present a counterfactual data augmentation approach that helps improve the generalization of different entity typing models with consistently better performance on both original and debiased test sets.
+
+# Limitations
+
+There are two important caveats to this work. First, for instances identified with a particular bias by the PLM, we do not guarantee all typing models would exploit spurious correlations on it. To the best of our knowledge, entity typing models with spurious correlation ablated and mitigated do not yet exist. Although we observe significant performance differences between the original biased instances and the crafted debiased counterparts from existing entity typing models, we hope future work would pay attention to spurious correlations, and develop models with improved robustness and generalization performance. Second, although biases defined in this work comprehensively cover six aspects, but still they may not exhaust all kinds of biased prediction in entity typing. In our study we only tried our best effort to study the most noteworthy and typical biases with which models may inflate performance by leveraging corresponding spurious correlations. At the same time, appeal for more research efforts to complete our understanding with more biases investigated. In addition, the studied model biases are representative to the widely practiced classification-based typing paradigm. There are effects in the most recent NLI-based or bi-encoder-based methods (Li et al., 2022; Huang et al., 2022), which require further analysis.
+
+# Ethical Consideration
+
+We acknowledge the importance of ethical considerations in language technologies and would like to point the reader to the following concern. Gender is a spectrum and we respect all gender identities, e.g., nonbinary, genderfluid, polygender, omnigender, etc. To craft instances free from pronoun bias, we substitute the gender pronouns with their referred names in contexts if they exist, or random masculine/feminine given names otherwise. This is due to the lack of entity typing datasets going beyond binarism for pronoun mentions such as they/them/theirs, ze/hir/hir, etc. Nevertheless, we support the rise of alternative neutral pronoun expressions and look forward to the development of non-binary inclusive datasets and technologies. In the meantime, although our techniques do not introduce or exaggerate possible gender bias in the original experimental data, in cases where such biases pre-exist in those data, additional gender neuralization techniques would be needed in order for such biases to be mitigated.
+
+# Acknowledgement
+
+We appreciate the anonymous reviewers for their insightful comments and suggestions. This material is partly supported by the National Science Foundation of United States Grant IIS 2105329 and a Cisco Research Award. Nan Xu and Fei Wang are supported by the Annenberg Fellowships. Bangzheng Li is supported by the USC Provost's Ph.D. Fellowship. Mingtao Dong is supported by the USC Provost's Undergrad Research Fellowship.
+
+# References
+
+Edoardo Barba, Tommaso Pasini, and Roberto Navigli. 2021. ESC: Redesigning WSD with extractive sense comprehension. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 4661-4672, Online. Association for Computational Linguistics.
+Steven Bird. 2006. NLTK: The Natural Language Toolkit. In Proceedings of the COLING/ACL 2006 Interactive Presentation Sessions, pages 69-72, Sydney, Australia. Association for Computational Linguistics.
+Ruben Blanco, Antonio Blanco, João António Rodrigues, and João Ricardo Silva. 2021. Shortcutted commonsense: Data spuriousness in deep learning of commonsense reasoning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1504-1521, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Zheng Cai, Lifu Tu, and Kevin Gimpel. 2017. Pay attention to the ending: strong neural baselines for the ROC story cloze task. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 616-622, Vancouver, Canada. Association for Computational Linguistics.
+Mathilde Caron, Hugo Touvron, Ishan Misra, Hervé Jégou, Julien Mairal, Piotr Bojanowski, and Armand Joulin. 2021. Emerging properties in self-supervised vision transformers. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 9650-9660.
+Xinlei Chen and Kaiming He. 2021. Exploring simple siamese representation learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 15750-15758.
+Eunsol Choi, Omer Levy, Yejin Choi, and Luke Zettle-moyer. 2018. Ultra-fine entity typing. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 87-96, Melbourne, Australia. Association for Computational Linguistics.
+
+Christopher Clark, Mark Yatskar, and Luke Zettlemoyer. 2019. Don't take the easy way out: Ensemble based methods for avoiding known dataset biases. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 4069-4082, Hong Kong, China. Association for Computational Linguistics.
+Hongliang Dai, Donghong Du, Xin Li, and Yangqiu Song. 2019. Improving fine-grained entity typing with entity linking. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 6210-6215, Hong Kong, China. Association for Computational Linguistics.
+Hongliang Dai, Yangqiu Song, and Haixun Wang. 2021. Ultra-fine entity typing with weak supervision from a masked language model. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 1790-1799, Online. Association for Computational Linguistics.
+Bayu Distiawan, Gerhard Weikum, Jianzhong Qi, and Rui Zhang. 2019. Neural relation extraction for knowledge base enrichment. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 229-240.
+Mengnan Du, Varun Manjunatha, Rajiv Jain, Ruchi Deshpande, Franck Dernoncourt, Juixiang Gu, Tong Sun, and Xia Hu. 2021a. Towards interpreting and mitigating shortcut learning behavior of NLU models. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 915-929, Online. Association for Computational Linguistics.
+Mengnan Du, Varun Manjunatha, Rajiv Jain, Ruchi Deshpande, Franck Dernoncourt, Jiumiang Gu, Tong Sun, and Xia Hu. 2021b. Towards interpreting and mitigating shortcut learning behavior of nlu models. arXiv preprint arXiv:2103.06922.
+Dan Gillick, Nevena Lazic, Kuzman Ganchev, Jesse Kirchner, and David Huynh. 2014. Context-dependent fine-grained entity type tagging. arXiv preprint arXiv:1412.1820.
+Suchin Gururangan, Swabha Swayamdipta, Omer Levy, Roy Schwartz, Samuel Bowman, and Noah A. Smith. 2018. Annotation artifacts in natural language inference data. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 107-112, New Orleans, Louisiana. Association for Computational Linguistics.
+
+He He, Sheng Zha, and Haohan Wang. 2019. Unlearn dataset bias in natural language inference by fitting the residual. In Proceedings of the 2nd Workshop on Deep Learning Approaches for Low-Resource NLP (DeepLo 2019), pages 132–142, Hong Kong, China. Association for Computational Linguistics.
+Matthew Honnibal, Ines Montani, Sofie Van Landeghem, and Adriane Boyd. 2020. spaCy: Industrial-strength Natural Language Processing in Python.
+Feng Hou, Ruili Wang, Jun He, and Yi Zhou. 2020. Improving entity linking through semantic reinforced entity embeddings. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6843-6848, Online. Association for Computational Linguistics.
+James Y. Huang, Bangzheng Li, Jiashu Xu, and Muhao Chen. 2022. Unified semantic typing with meaningful label inference. In Proceedings of the 2022 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2642-2654, Seattle, United States. Association for Computational Linguistics.
+Robin Jia and Percy Liang. 2017. Adversarial examples for evaluating reading comprehension systems. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 2021-2031, Copenhagen, Denmark. Association for Computational Linguistics.
+Hailong Jin, Lei Hou, Juanzi Li, and Tiansi Dong. 2019. Fine-grained entity typing via hierarchical multi graph convolutional networks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 4969-4978, Hong Kong, China. Association for Computational Linguistics.
+Armand Joulin, Edouard Grave, Piotr Bojanowski, and Tomas Mikolov. 2017. Bag of tricks for efficient text classification. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers, pages 427-431, Valencia, Spain. Association for Computational Linguistics.
+Rabeeh Karimi Mahabadi, Yonatan Belinkov, and James Henderson. 2020. End-to-end bias mitigation by modelling biases in corpora. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8706-8716, Online. Association for Computational Linguistics.
+Divyansh Kaushik, Eduard Hovy, and Zachary C Lipton. 2019. Learning the difference that makes a difference with counterfactually-augmented data. arXiv preprint arXiv:1909.12434.
+Divyansh Kaushik and Zachary C. Lipton. 2018. How much reading does reading comprehension require? a
+
+critical investigation of popular benchmarks. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 5010-5015, Brussels, Belgium. Association for Computational Linguistics.
+Duong Le and Thien Huu Nguyen. 2021. Fine-grained event trigger detection. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 2745-2752, Online. Association for Computational Linguistics.
+Ronan Le Bras, Swabha Swayamdipta, Chandra Bhagavatula, Rowan Zellers, Matthew Peters, Ashish Sabharwal, and Yejin Choi. 2020. Adversarial filters of dataset biases. In International Conference on Machine Learning, pages 1078-1088. PMLR.
+Bangzheng Li, Wenpeng Yin, and Muhao Chen. 2022. Ultra-fine entity typing with indirect supervision from natural language inference. Transactions of the Association for Computational Linguistics, 10:607-622.
+Xiao Ling and Daniel S Weld. 2012. Fine-grained entity recognition. In Twenty-Sixth AAAI Conference on Artificial Intelligence.
+Qing Liu, Hongyu Lin, Xinyan Xiao, Xianpei Han, Le Sun, and Hua Wu. 2021. Fine-grained entity typing via label reasoning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 4611-4622, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Tom McCoy, Ellie Pavlick, and Tal Linzen. 2019. Right for the wrong reasons: Diagnosing syntactic heuristics in natural language inference. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3428-3448, Florence, Italy. Association for Computational Linguistics.
+Timothy Niven and Hung-Yu Kao. 2019. Probing neural network comprehension of natural language arguments. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4658-4664, Florence, Italy. Association for Computational Linguistics.
+Yasumasa Onoe, Michael Boratko, Andrew McCallum, and Greg Durrett. 2021. Modeling fine-grained entity types with box embeddings. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2051-2064, Online. Association for Computational Linguistics.
+
+Yasumasa Onoe and Greg Durrett. 2019. Learning to denoise distantly-labeled data for entity typing. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 2407-2417, Minneapolis, Minnesota. Association for Computational Linguistics.
+Yasumasa Onoe and Greg Durrett. 2020. Interpretable entity representations through large-scale typing. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 612-624, Online. Association for Computational Linguistics.
+Pouya Pezeshkpour, Sarthak Jain, Sameer Singh, and Byron C Wallace. 2021. Combining feature and instance attribution to detect artifacts. arXiv preprint arXiv:2107.00323.
+Nina Poerner, Ulli Waltinger, and Hinrich Schütze. 2020. E-BERT: Efficient-yet-effective entity embeddings for BERT. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 803-818, Online. Association for Computational Linguistics.
+Chen Qian, Fuli Feng, Lijie Wen, Chunping Ma, and Pengjun Xie. 2021. Counterfactual inference for text classification debiasing. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 5434-5445, Online. Association for Computational Linguistics.
+Xiang Ren, Wenqi He, Meng Qu, Clare R Voss, Heng Ji, and Jiawei Han. 2016. Label noise reduction in entity typing by heterogeneous partial-label embedding. In Proceedings of the 22nd ACM SIGKDD international conference on Knowledge discovery and data mining, pages 1825-1834.
+Tal Schuster, Darsh Shah, Yun Jie Serene Yeo, Daniel Roberto Filizzola Ortiz, Enrico Santus, and Regina Barzilay. 2019. Towards debiasing fact verification models. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3419-3425, Hong Kong, China. Association for Computational Linguistics.
+Li Tianran, Yang Erguang, Zhang Yujie, Chen Yufeng, and Xu Jinan. 2021. Improving entity linking by encoding type information into entity embeddings. In Proceedings of the 20th Chinese National Conference on Computational Linguistics, pages 1087-1095, Huhhot, China. Chinese Information Processing Society of China.
+Shubham Toshniwal, Patrick Xia, Sam Wiseman, Karen Livescu, and Kevin Gimpel. 2021. On generalization in coreference resolution. In Proceedings of the Fourth Workshop on Computational Models of Reference, Anaphora and Coreference, pages 111-120,
+
+Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Asahi Ushio and Jose Camacho-Collados. 2021. TNER: An all-round python library for transformer-based named entity recognition. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: System Demonstrations, pages 53-62, Online. Association for Computational Linguistics.
+Prasetya Ajie Utama, Nafise Sadat Moosavi, and Iryna Gurevych. 2020. Mind the trade-off: Debiasing NLU models without degrading the in-distribution performance. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8717-8729, Online. Association for Computational Linguistics.
+Tianlu Wang, Diyi Yang, and Xuezhi Wang. 2021. Identifying and mitigating spurious correlations for improving robustness in nlp models. arXiv preprint arXiv:2110.07736.
+Yiwei Wang, Muhao Chen, Wenxuan Zhou, Yujun Cai, Yuxuan Liang, Dayiheng Liu, Baosong Yang, Juncheng Liu, and Bryan Hooi. 2022. Should we rely on entity mentions for relation extraction? debi- aising relation extraction with counterfactual analysis. NAACL.
+Zhao Wang and Aron Culotta. 2020. Identifying spurious correlations for robust text classification. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 3431-3440, Online. Association for Computational Linguistics.
+Wenhan Xiong, Jiawei Wu, Deren Lei, Mo Yu, Shiyu Chang, Xiaoxiao Guo, and William Yang Wang. 2019. Imposing label-relational inductive bias for extremely fine-grained entity typing. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 773-784, Minneapolis, Minnesota. Association for Computational Linguistics.
+Peng Xu and Denilson Barbosa. 2018. Neural fine-grained entity type classification with hierarchy-aware loss. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 16-25, New Orleans, Louisiana. Association for Computational Linguistics.
+Dani Yogatama, Daniel Gillick, and Nevena Lazic. 2015. Embedding methods for fine grained entity type classification. In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics and the 7th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 291-296, Beijing, China. Association for Computational Linguistics.
+
+Wenkai Zhang, Hongyu Lin, Xianpei Han, and Le Sun. 2021. De-biasing distantly supervised named entity recognition via causal intervention. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4803-4813, Online. Association for Computational Linguistics.
+Wenxuan Zhou and Muhao Chen. 2022. An improved baseline for sentence-level relation extraction. In Proceedings of the Conference of the Asia-Pacific Chapter of the Association for Computational Linguistics (AACL-IJCNLP).
+Wenxuan Zhou, Fangyu Liu, and Muhao Chen. 2021. Contrastive out-of-distribution detection for pretrained transformers. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1100-1111, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Ran Zmigrod, Sabrina J. Mielke, Hanna Wallach, and Ryan Cotterell. 2019. Counterfactual data augmentation for mitigating gender stereotypes in languages with rich morphology. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 1651-1661, Florence, Italy. Association for Computational Linguistics.
+
+# A Appendix
+
+# A.1 Additional Details about Mitigating Spurious Correlations
+
+Lexical Overlapping Bias We consider the following sentence as an instance: "Deutsche Bank would neither confirm nor deny the discharge of the two executives, and it also would not specify who was the target of the alleged spying", annotated with types dismissal, discharge, leave, termination. Since "discharge" shows up both in the mention and the true labels, we perform word substitutions with synonym candidates from 20 synsets found in WordNet. We show a few synsets with popular senses as follows:
+
+Synset I: (the termination of someone's employment) dismissal, dismissal, discharge, firing, liberation, release, sack, sacking
+
+SynsetII: (a substance that is emitted or released) discharge, emission
+
+SynsetIII: (a formal written statement of relinquishment) release, waiver, discharge
+
+Synonyms that share high word similarities with the true labels are removed to avoid creating new lexical overlapping bias features, e.g., dismissal, discharge from Synset I, discharge from Synset II and Synset III. To guarantee the semantic consistency of the new sentence and the fidelity of true labels to type the new mention, we leverage available word sense disambiguation models to preserve synonyms from the synset that is most consistent with the sense used in the original sentence: dis-. mission, firing, liberation, release, sack, sacking from Synset I are finally selected to substitute "discharge". As shown in T4 of Tab. 1, without training on the debiased set, MLMET no longer predicts the overlapped type "day", but some surface word "peri- period" instead.
+
+Named Entity Bias Compared with the politician Benjamin Netanyahu, the PLM can hardly infer the impression of the singer Jintara Poonlarp on the public. Particularly, only general types to describe person named entities are predicted in S5: person, human, woman. We then consider Benjamin Netanyahu as a biased named entity containing much prior knowledge, while Jintara Poonlarp as an unbiased named entity without much type-relevant information revealed. After substituting Benjamin Netanyahu with Jintara Poonlarp in T6, MLMET can hardly infer the political role
+
+of the new mention by analyzing its connection with the politician (Amin al-Husseini, Palestinian Arab nationalist and Muslim leader in Mandatory Palestine1) and political description ("master-minds" and "Holocaust") in the context. MLMET even crashes with some out-of-context predictions: scholar, writer.
+
+Pronoun Bias As shown in the original instance T7 of Tab. 1, the actual person's name that the pronoun mention "Her" refers to is not provided in the current sentence. As a result, a random feminine name, "Judith" is assumed to be the referred entity and substitutes the pronoun mention as a new sentence in S6. Considering the ridiculously wrong types predicted by RoBERTa such as bird and cat, we include this new instance in the debiased set and expect the entity modeling training on this kind of instances to infer person name types as accurate as pronoun types. Beforehand, we test on the newly crafted instance without counterfactual augmented training, and observe huge performance drop after pronoun concretization: types related to the name's gender attribute such as woman and female are missing, let alone the types requiring fully context understanding such as actress.
+
+Dependency Bias For instance T9 in Tab. 2, we show their mention word dependency analysis in S6 and predictions on the perturbed instance in T10. Without distractions from other dependent words in the new mention, MLMET spares no effort to infer types of the target entity "whale" with the correct prediction subject. Motivated by the improved performance when the mention headword is specifically provided, we believe entity typing models can actively learn to capture target entity among mention words when both original sentences and their debiased counterparts are given during training. In such augmented training regime, the entity typing model is expected to achieve robust performance on new sentences bearing distractions from dependent words in mentions.
+
+# A.2 Implementation Details
+
+We adopt the released checkpoints of RoBERTa-large (Liu et al., 2019) as the PLM to identify biased instances. To perform masked fill-in, we adopt the top 10 predictions and filter out non-type words as the predicted types. We recognize potentially
+
+biased samples based on PLM predictions based on the following criteria. 1) mention-context bias: instances are considered biased if the PLM can predict the type labels with the F1 score above 0.5 when only the mention is provided; 2) named entity bias: instances are considered biased if the PLM can predict types labels with the F1 score above 0.5 when only the named entity is given; 3) lexical overlapping bias: instances are considered biased if the PLM makes predictions with the F1 score below 0.5 after substituting overlapped words with their semantically similar words; 4) pronoun bias: for pronouns without coreferenced entities detected, we substitute them with 5 random real person names as debiased instances. Instances are considered biased if the PLM makes predictions with the F1 score below 0.5 after real name substitution. We mainly use 0.5 as the threshold to distinguish biased samples from unbiased, since the SOTA model achieves the F1 score approximating 0.5 on average of the UFET test samples.
+
+To diagnose entity typing models, for those with released checkpoints (BiLSTM, Box4Types, LRN), we directly evaluate on the original (un)biased and crafted debiased instances. We train LabelGCN and MLMET by ourselves following hyperparameters and training strategies introduced in their papers.
+
+To evaluate various debiasing approaches, we train entity typing models using checkpoints training on the original dataset as the warm start with the same hyperparameter sets.
+
+We run experiments on a commodity server with a GeForce RTX 2080 GPU. It takes about 4 hours to train one entity typing model on average and 2 minutes for inference on the UFET test set.
+
+# A.3 OntoNotes Experiments
+
+We diagnose entity typing models and the effectiveness of the proposed counterfactual augmented approach on OntoNotes (Gillick et al., 2014). The original dataset contains 251, 309 instances automatically annotated by linking identified entity mentions to Freebase profiles for training, and 11, 165 manually annotated instances: 2, 202 for validation and 8, 963 for testing, respectively. Its label space is constituted of 89 types organized into a hierarchy, e.g., /person (level 1), /person/artist (level 2), /person/artist/actor (level 3). We adopt the set augmented by (Choi et al., 2018) for model training: 793, 487 instances with distant supervi
+
+sion from Wikipedia definition sentences and head word supervision.
+
+In Tab. 8, we report performance of two representative entity typing models on original biased samples where they are likely to exploit spurious correlations, the perturbed counterparts, as well as performance on unbiased samples. We have the following observations: 1) entity typing models can achieve satisfactory performance when only the mention is provided without context; 2) considering lexical overlapping bias, performance on both biased and unbiased samples identified by the PLM drops a lot after substituting overlapped mention words with their semantically similar words; 3) the performance variation after named entity substitution is evident; 4) models can obtain much better performance on some instances when the headwords are explicitly given without distractions from other words in mentions; 5) performance on instances purely annotated by coarse and fine labels is good in general with around $15\%$ difference in F1 score. Similarly to UFET, models training on OntoNotes may achieve good performance without reasoning on the context, rely on lexical overlapping between mention words and types to make precise predictions, and obtain below-average results on some instances for lack of syntactic structure understanding.
+
+To mitigate spurious correlations, we evaluate the proposed counterfactual augmented approach in Tab. 9. With additional debiased instances for model training, both BiLSTM and MLMET maintain good performance on the original OntoNotes test set and much higher accuracy on the corresponding debiased test set, leading to improved generalization.
+
+| Test Set | BiLSTM | MLMET | LabelGCN | Box4Types | LRN |
| Prec. | Rec. | F1 | Prec. | Rec. | F1 | Prec. | Rec. | F1 | Prec. | Rec. | F1 | Rec. |
| Mention-Context Bias (↑) |
| Biased | .602 | .283 | .385 | .668 | .640 | .654 | .689 | .418 | .521 | .679 | .516 | .586 | .666 |
| -Perturb. | .606 | .298 | .400 | .682 | .628 | .654 | .699 | .398 | .507 | .644 | .486 | .554 | .653 |
| (0.7%) | (5.3%) | (3.8%) | (2.1%) | (-1.9%) | (0.0%) | (1.3%) | (-4.9%) | (-2.6%) | (-5.2%) | (-5.8%) | (-5.5%) | (-2.0%) |
| Unbiased | .452 | .188 | .265 | .486 | .395 | .436 | .484 | .235 | .317 | .470 | .319 | .380 | .563 |
| -Perturb. | .450 | .176 | .253 | .453 | .350 | .395 | .459 | .221 | .298 | .446 | .279 | .343 | .509 |
| (-0.5%) | (-6.4%) | (-4.7%) | (-6.8%) | (-11.4%) | (-9.4%) | (-5.2%) | (-6.1%) | (-5.8%) | (-5.1%) | (-12.6%) | (-9.8%) | (-9.6%) |
| Lexical Overlapping Bias (↓) |
| Biased | .415 | .661 | .510 | .641 | .484 | .551 | .651 | .292 | .403 | .118 | .442 | .186 | .089 |
| -Perturb. | .040 | .065 | .050 | .411 | .271 | .327 | .338 | .106 | .162 | .074 | .251 | .115 | .066 |
| (-90.4%) | (-90.1%) | (-90.3%) | (-35.8%) | (-44.0%) | (-40.8%) | (-48.1%) | (-63.6%) | (-59.9%) | (-36.9%) | (-43.3%) | (-38.3%) | (-25.8%) |
| Unbiased | .278 | .667 | .392 | .522 | .567 | .544 | .667 | .300 | .414 | .167 | .667 | .267 | .067 |
| -Perturb. | .111 | .333 | .167 | .381 | .533 | .444 | .333 | .067 | .111 | .222 | .667 | .333 | .056 |
| (-60.0%) | (-50.0%) | (-57.5%) | (-27.1%) | (-5.9%) | (-18.2%) | (-50.0%) | (-77.8%) | (-73.1%) | (33.3%) | (0.0%) | (25.0%) | (-16.7%) |
| Named Entity Bias (↓) |
| Biased | .744 | .380 | .504 | .719 | .752 | .735 | .730 | .524 | .610 | .686 | .658 | .671 | .754 |
| -Perturb. | .538 | .240 | .332 | .615 | .586 | .600 | .568 | .362 | .442 | .541 | .479 | .508 | .634 |
| (-27.7%) | (-36.9%) | (-34.0%) | (-14.5%) | (-22.0%) | (-18.4%) | (-22.2%) | (-30.9%) | (-27.5%) | (-21.2%) | (-27.2%) | (-24.4%) | (-15.9%) |
| Unbiased | .522 | .226 | .316 | .536 | .477 | .505 | .542 | .288 | .376 | .520 | .407 | .457 | .595 |
| -Perturb. | .613 | .267 | .372 | .582 | .502 | .539 | .651 | .337 | .444 | .538 | .472 | .503 | .629 |
| (17.5%) | (17.7%) | (17.6%) | (8.6%) | (5.4%) | (6.9%) | (20.2%) | (17.3%) | (18.2%) | (3.4%) | (16.1%) | (10.2%) | (5.8%) |
| Pronoun Bias (↓) |
| Biased | .567 | .438 | .494 | .555 | .566 | .561 | .555 | .474 | .511 | .576 | .555 | .565 | .716 |
| -Perturb. | .148 | .227 | .179 | .619 | .455 | .525 | .578 | .300 | .395 | .481 | .397 | .435 | .776 |
| (-74.0%) | (-48.2%) | (-63.8%) | (11.5%) | (-19.6%) | (-6.4%) | (4.2%) | (-36.7%) | (-22.8%) | (-16.5%) | (-28.4%) | (-23.0%) | (-12.3%) |
| Unbiased | .405 | .334 | .366 | .738 | .635 | .683 | .660 | .510 | .575 | .715 | .759 | .736 | .633 |
| -Perturb. | .106 | .167 | .130 | .735 | .597 | .659 | .703 | .258 | .378 | .670 | .548 | .603 | .555 |
| (-73.9%) | (-50.0%) | (-64.6%) | (-0.5%) | (-6.0%) | (-3.5%) | (6.6%) | (-49.4%) | (-34.4%) | (-6.3%) | (-27.8%) | (-18.1%) | (-2.1%) |
| Dependency Bias |
| UFET | .350 | .097 | .152 | .450 | .402 | .424 | .452 | .248 | .321 | .462 | .351 | .399 | .491 |
| -Perturb. | .407 | .386 | .396 | .617 | .520 | .564 | .757 | .392 | .517 | .710 | .482 | .574 | .715 |
| (16.2%) | (297.3%) | (160.5%) | (37.1%) | (29.4%) | (32.9%) | (67.3%) | (58.1%) | (61.2%) | (53.7%) | (37.2%) | (43.9%) | (45.7%) |
| Overgeneralization Bias |
| Coarse | .362 | .656 | .466 | .297 | .758 | .427 | .360 | .656 | .465 | .339 | .688 | .454 | .466 |
| Ultra-fine | .157 | .094 | .118 | .221 | .244 | .232 | .207 | .120 | .152 | .147 | .120 | .132 | .161 |
+
+Table 7: Performance of all entity typing models evaluated by complete metrics (Prec. for precision, Rec. for recall and F1 for F1 score) on UFET testing samples with(out) distinct bias and their perturbations.
+
+| Test set | Mention-Context 1830/7133 (↑) | Lexical Overlapping 234/319 (↓) | Named Entity 1132/2457 (↓) | Dependency 842,544/7129 | Overgeneralization 5549/3414 |
| BiLSTM | MLMET | BiLSTM | MLMET | BiLSTM | MLMET | BiLSTM | MLMET | BiLSTM | MLMET |
| Biased -Perturb. | .719 (-3.0%) | .821 (-2.2%) | .922 .345 (-62.6%) | .940 .473 (-49.7%) | .774 .668 (-13.7%) | .844 .765 (-9.4%) | .291 .808 (178.0%) | .416 (118.5%) | .844 .646 | .909 .757 |
| Debiased -Perturb. | .787 (.1%) | .864 .847 (-2.0%) | .982 .407 (-58.6%) | .983 .467 (-52.5%) | .761 .665 (-12.6%) | .855 .759 (-11.3%) | - | - | - | - |
+
+Table 8: F1 score of two representative entity typing models on OntoNotes testing samples with(out) distinct biases and their perturbations.
+
+| Approach | BiLSTM | MLMET |
| U-Prec. | U-Rec. | U-F1 | A-Prec. | A-Rec. | A-F1 | U-Prec. | U-Rec. | U-F1 | A-Prec. | A-Rec. | A-F1 |
| No Debiasing | .803 | .744 | .773 | .708 | .609 | .655 | .890 | .822 | .855 | .805 | .706 | .753 |
| Augmentation (ours) | .782 | .752 | .767 | .781 | .711 | .745 | .777 | .832 | .803 | .828 | .846 | .837 |
+
+Table 9: Effectiveness of the proposed counterfactual augmented approach on two representative entity typing models when testing on OntoNotes test set (U-) and our counterfactual augmented test set (A-).
+
+| Approach | U-Prec. | U-Rec. | U-F1 | A-Prec. | A-Rec. | A-F1 |
| LabelGCN |
| No Debiasing | .498 | .283 | .361 | .503 | .247 | .332 |
| AFLite | .536 | .238 | .329 | .529 | .202 | .292 |
| POE | .407 | .327 | .363 | .379 | .301 | .335 |
| Focal | .185 | .439 | .260 | .193 | .392 | .259 |
| Learned-mixin | .420 | .316 | .361 | .353 | .311 | .331 |
| Learned-mixin+H | .225 | .398 | .287 | .212 | .339 | .261 |
| Contrastive (CE) | .483 | .286 | .359 | .479 | .272 | .347 |
| Contrastive (Cosine) | .453 | .285 | .350 | .516 | .269 | .353 |
| Counterfact. Inf. | .467 | .309 | .372 | .403 | .291 | .338 |
| Augmentation (ours) | .484 | .289 | .362 | .524 | .274 | .360 |
| Box4Types |
| No Debiasing | .528 | .388 | .448 | .469 | .358 | .406 |
| AFLite | .531 | .400 | .456 | .473 | .360 | .409 |
| POE | .410 | .468 | .437 | .347 | .433 | .385 |
| Focal | .407 | .467 | .435 | .347 | .435 | .386 |
| Learned-mixin | .508 | .415 | .457 | .448 | .393 | .419 |
| Learned-mixin+H | .463 | .440 | .451 | .403 | .406 | .404 |
| Contrastive (CE) | .443 | .459 | .451 | .371 | .563 | .447 |
| Contrastive (Cosine) | .472 | .444 | .458 | .437 | .499 | .466 |
| Counterfact. Inf. | .529 | .394 | .452 | .422 | .382 | .401 |
| Augmentation (ours) | .521 | .410 | .459 | .504 | .484 | .494 |
| LRN |
| No Debiasing | .611 | .334 | .432 | .703 | .343 | .461 |
| Augmentation (ours) | .553 | .328 | .412 | .619 | .389 | .478 |
+
+Table 10: Effectiveness of different debiasing approaches on remaining entity typing models when testing on UFET test set (U-) and our counterfactual augmented test set (A-). Note that $LRN$ predicts types in an autoregressive generative way, it does not provide a fixed logit for each label, hence we can not apply logit-based debiasing approaches to help $LRN$ mitigate spurious correlations.
\ No newline at end of file
diff --git a/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/images.zip b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..ada6191c69b2892f00ccc593290f4367cda1e657
--- /dev/null
+++ b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:3ab1fcbe0dbfe8b87b41f678a5c2b3c469ab2534cc01b8267b779b56e8459dcf
+size 965032
diff --git a/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/layout.json b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..22a76cfdf2a8c736f478edff26671060d3b09422
--- /dev/null
+++ b/doesyourmodelclassifyentitiesreasonablydiagnosingandmitigatingspuriouscorrelationsinentitytyping/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:58132f9eb6e6e008e8f29f85a614a6c466779dd41c9227aafd99d57f397584c8
+size 415743
diff --git a/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_content_list.json b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..fcc18b7739bf2b2f0da6f72e1f872839ea12e673
--- /dev/null
+++ b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f14713c5f4f28a887fb7fbd61dd15a4567603c2c05a4d370dc2071fda51d1cbc
+size 53563
diff --git a/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_model.json b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..30380e21254874d1f18c515f0ecfd5314f07cc66
--- /dev/null
+++ b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0fe2fb5478f2eafa8bb0923aaa947d1e547ab5fa79df6488bc66248fa8f7ed55
+size 64372
diff --git a/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_origin.pdf b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..76dbd1d07c01bd00c098d5284b3599f8ab6253ed
--- /dev/null
+++ b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/9a9c1d46-0b7e-4b8d-ab43-c31908ec5e45_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8febd38f9562c88bee8f75638aa4e0619329ed2006969c9843e627dcad38e888
+size 1903263
diff --git a/dontcopytheteacherdataandmodelchallengesinembodieddialogue/full.md b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..70855924bac5325d63771d0e9e99b9ca8c1a6c9d
--- /dev/null
+++ b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/full.md
@@ -0,0 +1,204 @@
+# Don't Copy the Teacher: Data and Model Challenges in Embodied Dialogue
+
+So Yeon Min $^{1}$ Hao Zhu $^{2}$ Ruslan Salakhutdinov $^{1}$ Yonatan Bisk $^{2}$
+
+Machine Learning1 and Language Technologies2 at Carnegie Mellon University {soyeonm,hzhu2,rsalakhu,ybisk} @andrew.cmu.edu
+
+# Abstract
+
+Embodied dialogue instruction following requires an agent to complete a complex sequence of tasks from a natural language exchange. The recent introduction of benchmarks (Padmakumar et al., 2022) raises the question of how best to train and evaluate models for this multi-turn, multi-agent, long-horizon task. This paper contributes to that conversation, by arguing that imitation learning (IL) and related low-level metrics are actually misleading and do not align with the goals of embodied dialogue research and may hinder progress.
+
+We provide empirical comparisons of metrics, analysis of three models, and make suggestions for how the field might best progress. First, we observe that models trained with IL take spurious actions during evaluation. Second, we find that existing models fail to ground query utterances, which are essential for task completion. Third, we argue evaluation should focus on higher-level semantic goals.
+
+# 1 Introduction
+
+Dialogue is key to how humans collaborate; through dialogue, we query information, confirm our understanding, or banter in a friendly manner. Since communication helps us work more efficiently and successfully, it is only natural to imbue for collaborative agents with this same ability. Most work has focused on grounded dialogues for embodied navigation (Thomason et al., 2020; Chi et al., 2019; Roman et al., 2020) or limited interaction (Suhr et al., 2019), which are narrower domains than the larger instruction following literature (Tellex et al., 2011, 2020; Shridhar et al., 2020; Blukis et al., 2018, 2021; Min et al., 2021).
+
+The first step towards engaging in a dialogue, is being able to understand and learn from it. Picture a child watching their parents with the goal
+
+to learn by imitation. They witness instructions, clarifications, mistakes, and banter. Begging the question: What should one learn from noisy natural dialogues?
+
+Unlike in alinguistic tasks where modeling humans has recently proved helpful for search strategies (Deitke et al., 2022), we focus on language based tasks that require learning lexical-visual-action correspondences. We discuss and compare three paradigms: Instruction Following (IF), actions from Entire Dialogue History (EDH) and Trajectory from Dialogue (TfD). The novel TEACH dataset (Padmakumar et al., 2021) proposes EDH as the primary metric and uses the Episodic Transformer (ET) (Pashevich et al., 2021) trained with behavior cloning as their baseline. We also include comparisons to the EDH competitive Symbiote $^{2}$ system and we adapt FILM (Min et al., 2021), a recent method for general IF, to dialog instruction following (DIF) on TEACH. FILM and Symbiote belong to a different family of models, focusing on abstract planning trained at a higher semantic level than behavior cloning. This approach appears crucial for generalization and TfD evaluations.
+
+Most importantly, we analyze the human behaviors in TEACH and the corresponding effect on ET, Symbiote, and FILM, as representatives of existing model classes. From our findings, we suggest there are three major challenges the community must tackle to move forward in the nascent field of Dialogue based Instruction Following:
+
+Recognizing mistakes Behavior cloning encourages replication of low-level errors, but not high-level intentions. Agents should learn to construe high-level intentions of demonstrations and to deviate from demonstration errors.
+
+Grounding queries No approaches correctly ground "queries" requesting information.
+
+Evaluation Agent evaluation should focus on achieving goals rather than immitating procedures.
+
+# 2 Related Work
+
+Instruction Following A plethora of works have been introduced for instruction following without dialogue (Chen and Mooney, 2011; Matuszek et al., 2012); an agent is expected to perform a task given a language instruction at the beginning and visual inputs at every time step. Representative tasks are Visual Language Navigation (Anderson et al., 2018; Fried et al., 2018; Zhu et al., 2020) and instruction following (IF) (Shridhar et al., 2020; Singh et al., 2020), which demands both navigation and manipulation. Popular methods rely on imitation learning (Pashevich et al., 2021; Singh et al., 2020) and modularly trained components (Blukis et al., 2021; Min et al., 2021) (e.g. for mapping and depth).
+
+Dialogue Instruction Following Instruction Following with Dialogue (She et al., 2014) has mostly addressed navigation. Thomason et al. (2020); Suhr et al. (2019) built navigation agents that ground human-human dialogues, while Chi et al. (2019); Nguyen and Daumé III (2019) showed that obtaining clarification via simulated interactions can improve navigation. Manipulation introduces grounding query utterances that involve more complex reasoning than in navigation-only scenarios (Tellex et al., 2013); for example, the agent may hear that the object of interest (e.g. "apple") is inside "the third cabinet to the right of the fridge."
+
+Imitation Learning vs Higher semantics While behavior cloning (BC) is a popular method used to train IF agents, it assumes that expert demonstration is optimal (Zhang et al., 2021; Wu et al., 2019). TEACH demonstrations are more "ecologically valid" (de Vries et al., 2020) but correspondingly suboptimal, frequently containing mistakes and unnecessary actions. Popular methods that deal with suboptimal demonstrations involve annotated scoring labels or rankings for the quality of demonstrations (Wu et al., 2019; Brown et al., 2019). Such additional annotations are not available in existing IF and DIF benchmarks. In this work, we empirically demonstrate the effect of noisy demonstrations on an episodic trained with BC for DIF.
+
+# 3 Tasks
+
+TEACh focuses on two tasks: Entire Dialogue History and Trajectory from Dialogue. Despite what
+
+the name implies, EDH is an evaluation over partial dialogues (e.g. from state $S_{t}$ begin execution to $S_{T}$ ). TfD starts an agent at $S_{0}$ and asks for a complete task completion provided the full dialogue.
+
+In both settings, the agent (driver) completes household tasks conditioned on text, egocentric RGB observations, and the current view. An instance of a dialogue will take the form of a command: Prepare coffee in a clean mug. Mugs are in the microwave., the agent response How many do I need?, and commander's answer: One, together with a sequence of RGB frames and actions that the agent performed during the dialogue. As in this example, the agent has to achieve multiple subtasks (e.g. find mug in the microwave, clean mug in the sink, turn on the coffee machine, etc) to succeed.
+
+In TfD, the full dialogue history is given, and the agents succeeds if it completes the full task itself (e.g. make coffee). In EDH, the dialog history is partitioned into "sessions" (e.g. Fig. 1) with the corresponding action/vision/dialogue history until the first utterance of the commander (Prepare $\sim$ microwave.) being the first session and those after it being the second. In EDH evaluation, the agent takes one session as input and predicts actions until the next session. An agent succeeds if it realizes all state changes (e.g. Mug: picked up) that the human annotator performed. Succinctly, TfD measures the full dialogue while EDH evaluates subsequences.
+
+# 4 Models
+
+TEACH is an important new task for the community. We analyze the provided baseline (ET), retrofit the ALFRED FILM model, and requested outputs from the authors of Symbioteon the EDH leaderboard.
+
+ET is a transformer for direct sequence imitation approach, that produces low-level actions conditioned on the accumulated visual and linguistic contexts. In contrast, FILM consists of four submodules - semantic mapping, language processing, semantic policy, and deterministic policy modules. For the adaptation, we refactored the original code of FILM to the TEACH API, retrained the learned components of the semantic mapping module for the change in height and camera horizon, and retrained/rewrote the language processing module to take a dialogue history as input. The language processing (LP) module of FILM maps an instruction to a task type and instruction-specific arguments. For TfD this maps a dialogue to a sequence of tasks, while for EDH only the subsequence is mapped to
+
+
+Figure 1: Examples of suboptimal demonstrations that can be harmful for training and evaluation. (a: no-op) The driver grabs a knife, looks up and down, and put its down, although nowhere in the dialogue indicates to do these actions, nor do they facilitate the high-level goal. (b: unaligned intent) In EDH sessions 1 and 2, the commander asks for an item (a slice of tomato) and provides the location of the knife, but the driver performs unaligned actions. In session 3, the driver suddenly asks "knife?", but performs a long sequence of implied but not stated actions.
+
+an immediate action. Symbiote is a competitive modular method for EDH whose language understanding component is designed for dialogues (§A).
+
+# 5 Challenges of Human Traces
+
+First we present how TEACH and, by extension, future embodied dialogue settings present novel training and evaluation challenges as the data, by virtue of its authenticity, includes substantial noise in both the training and evaluation (despite filtering by the authors §C). See §B for how statistics were computed, for those not explained in this section.
+
+# 5.1 Explanation of Metrics
+
+Evaluation for both EDH and TFD is done by SR (success rate), GC (goal condition success rate), and their path-length-weighted versions. Success Rate (SR) is a binary indicator of whether all subtasks were completed. The definition of "subtasks" is different for EDH and TfD; for the former, they are all tasks required to realize state changes done by the human demonstration that are relevant to the ultimate task (e.g. The demo state changes in each session of Fig.1 (b)). Thus, the state changes brought by the human is considered ground truth in EDH evaluation; this brings multiple challenges further discussed in §5.2. On the other hand, for TfD, the subtasks are independent of what was done in the demo; for example, as long as an agent
+
+"slices the tomato" correctly for the task of Fig.1 (b), its SR will be 1 for this task.3
+
+The goal-condition success (GC) of a model is the ratio of goal-conditions completed at the end of an episode. Both SR and GC can be weighted by (path length of the expert trajectory)/ (path length taken by the agent); these are called path length weighted SR (PLWSR) and path length weighted GC (PLWGC). Higher is better for all metrics.
+
+# 5.2 Challenges in Evaluation
+
+Irrelevant Actions Humans often explore the environment, or simply play around in the middle of a task. This means they may flip a switch completely unrelated to the goal. Table 1 are representative state changes that do not have direct correspondence with the dialogue, and the percentage of human demonstrations that contain these actions.
+
+It is not always clear if this behavior is because of misunderstandings, boredom, or curiosity. For example, we can classify a large number of navigation and interaction "No Op"s, or action sequences that return to the original state (e.g. turning around
+
+| Unnecessary State Changes | Val Seen | Val Unseen |
| Coffee Machine on/off | 47.73 | 47.54 |
| Picked up and not placed | 25.49 | 23.41 |
| Faucet on/off | 12.68 | 10.59 |
| Stove/ Microwave on/off | 35.61 | 28.31 |
| ⇒ Total | 38.98 | 35.60 |
+
+in place). In principle, these might be information seeking, to build a better map of the environment, but in practice, many of the demonstrations do not seem to exhibit those properties, particularly in extreme cases like repeatedly picking up and putting down the same object. The percentages of prevalence of these unnecessary actions in both training and validation are shown in Table 2.
+
+Table 1: Representative state changes that do not have direct correspondence with the dialogue, and the percentage of human demonstrations that contain these actions. The action types listed here bring "state changes" that are counted during EDH evaluation. For example, an agent would "fail" an EDH task if the human annotator of the task left coffee machine off at the end, although the task (e.g. "Make coffee") or dialogue itself does not mention that it be left on.
+
+| Suboptimal Actions | Train | V. Seen | V. Un |
| Navigation No Op |
| Turn Left/ Right x 4 | 3.07 | 2.30 | 2.33 |
| Forward + Backward | 4.80 | 7.57 | 4.23 |
| Pan Right + Pan Left | 5.83 | 4.77 | 8.10 |
| Turn Right + Turn Left | 13.13 | 13.49 | 10.89 |
| ⇒ Total | 22.41 | 23.03 | 21.36 |
| Interaction No Op |
| Toggle off + on same obj | 1.39 | 1.81 | 1.58 |
| Open + Close same obj | 1.46 | 1.80 | 1.30 |
| Place + Pick up same obj | 25.06 | 27.80 | 28.34 |
| ⇒ Total | 26.76 | 30.10 | 30.57 |
| Interaction w. unrelated obj. | 14.10 | 16.61 | 13.59 |
| Demo unaligned w. dialog | 25.25 | 22.49 | 23.40 |
+
+The prevalence of these actions can be viewed as a positive for realism and even helpful if teaching how to search, but pose a challenge for evaluation.
+
+Penalizing Agents for Accuracy Using a human's action trace as the ground truth, means agents are penalized for skipping erroneous actions. This leads to a misleading mismatch in performance between EDH and TfD. Additionally,
+
+Table 2: Representative unnecessary action types that do not have associations with the high level goal or the dialogue, and the percentage of demonstrations that contain these action types in train/ valid seen/ valid unseen splits.
+
+ | Valid Seen | Valid Unseen |
| GC | SR | GC | SR |
| Entire Dialogue History (EDH) |
| E.T. | 15.7 [4.1] | 10.2 [1.7] | 9.1[1.7] | 7.8[0.9] |
| SYMBIOTE | 25.9 [5.3] | 16.1 [2.6] | 17.2 [2.9] | 10.1 [1.2] |
| FILM | 26.4 [5.6] | 14.3 [2.1] | 18.3 [2.7] | 10.2 [1.0] |
| Trajectory from Dialogue (TfD) |
| E.T. | 1.4 [4.8] | 1.0 [0.2] | 0.4 [0.6] | 0.5 [0.1] |
| FILM | 5.8 [11.6] | 5.5 [2.6] | 6.1 [2.5] | 2.9 [1.0] |
+
+EDH inflates model performance as it includes subsequences which are nearly deterministic (e.g. all but the last "placing" action). Table 3 contains EDH scores for our three comparison models and TfD for ET/FILM. As suggested by authors of related papers, we treat Unseen Success Rate as the most important metric (seen in blue).
+
+Note, that an ideal evaluation would capture both "actions in context" and "task success." In the following section breakdown the overall numbers presented here to understand if models more carefully.
+
+# 5.3 Challenges in Training
+
+Behavior Cloning with Suboptimal Demonstrations We find that ET trained with behavior cloning repeats the same mistakes in novel scenes that are frequent in demonstrations. We examine two kinds of mistakes in demonstrations - (1) No Op interactions, in which consecutive interactions produces futile state changes (e.g. Placing and immediately picking up the same object) and (2) Interactions with unrelated objects (e.g. picking up "saltshaker" while making coffee). In Table 4 we compare what percent of model predictions in seen and unseen scenes replicate the no-op behavior.
+
+Table 3: EDH and TfD performances of E.T., Symbiote, and FILM. While the SR on TfD is very low for all models, E.T.'s performance on TfD drops significantly due to replication of errors and lack of grounding of high-level semantics.
+
+| Suboptimal Actions | ET | Symbiote | FILM |
| S | U | S | U | S | U |
| No Op (same obj) | | | | | | |
| Toggle off + on | 0.0 | 0.1 | 0.2 | 0.1 | 0.0 | 0.0 |
| Open + Close | 2.5 | 1.5 | 0.0 | 0.2 | 0.0 | 0.0 |
| Place + Pick up | 45.1 | 47.1 | 4.9 | 2.5 | 0.0 | 0.0 |
| ⇒ Total | 46.2 | 48.1 | 5.1 | 2.8 | 0.0 | 0.0 |
| Unrelated obj. | 24.0 | 20.3 | 27.5 | 30.6 | 15.9 | 12.10 |
+
+Table 4: Percentage of tasks in which a model exhibited replication of No Op actions.
+
+| Method | SR | GC | SR w. Query | GC w. Query |
| Validation Seen |
| ET | 8.97 | 14.13 | 0.00 | 0.00 |
| Symbiote | 0.00 | 11.76 | 0.00 | 0.00 |
| FILM | 9.59 | 20.26 | 0.00 | 0.00 |
| Validation Unseen |
| ET | 2.39 | 8.69 | 0.00 | 0.49 |
| Symbiote | 0.00 | 0.00 | 0.00 | 0.00 |
| FILM | 1.29 | 9.79 | 0.00 | 0.00 |
+
+Table 5: We consider a task as involving "query utterances", if in its demonstration, a relevant object inside an originally closed receptacle was picked up. SR/GC measure the vanilla task success on tasks with "query utterances"; SR/GC w. Query measure if the success was achieved using information in the "query utterances."
+
+While hard to quantify, we also note that the higher intention of seemingly unnecessary human demonstrations (e.g. to explore, to understand, etc) are not replicated by ET. This is backed by our observation that ET tends to be stuck in many (10 or more) repetitions of the same No Op/unnecessary actions, until the end of the task or before resuming to perform other actions.
+
+Note that even Symbiote is exhibiting some no-op behaviors, but as the model supervision/structure becomes more abstract (ET vs FILM) this disappears, leaving only object choice errors.
+
+Grounding Queries Key to dialogue is language based information seeking. A target object may be located in a closed receptacle (cabinet, etc); in this case, the agent has to query the commander for its location, as a human would. We examine whether models ground query utterances into meaning and accurate actions, since this is one essential aspect of dialog grounding. While there are utterances with other essential intents, such as confirmation, we focus on query utterances since these are relatively easy to extract mechanically.
+
+In Table 5 we consider a subset of tasks that involve "query utterances" that can be detected automatically. Specifically, we present the performance of models in terms of success rate and goal condition success on tasks that require opening a receptacle based on the answer to a question – and then measure if the models leverage the query. Not all query utterances will be of this type, but these tasks necessarily involve grounding query utterances for task success.
+
+Queries are present in $23.05\%$ and $25.31\%$ of valid seen and unseen splits, respectively. This is
+
+a key challenge as it demonstrates a clear use case for dialogue and limitation of current models.
+
+Given a statement like "the fork is in the cabinet left to the refrigerator", the evaluation mismatch occurs if an agent grabs a different fork on a table. This allows them to succeed, as measured by SR/GC, but not in SR/GC with Query. Notably, all models fail at query grounding, indicating they are simply ignoring the language instructions. This shows that enabling complex dialogue grounding is an important open problem for DIF. Especially, for the ultimate goal of two-agent task completion (TaTC), it is necessary that models can ground query and other essential utterances in a dialogue.
+
+# 6 Conclusion and Next Steps
+
+This paper is not an indictment of TEACH, nor an endorsement of a particular model, rather it seeks to lay out important questions and challenges that NLP will need to tackle as it moves into embodied dialogue. Unlike existing work in dialogue that looks to model human satisfaction (Ghandeharioun et al., 2019) or state-tracking, DIF has the advantage of explicit and verifiable semantic goals. We pose a challenge to the community: How can we build agents where success is not tied to specific actions yet language understanding and production are accurate and fluent? As a first step, we posit that imitation learning should be avoided.
+
+# 7 Limitations
+
+We focus on a new embodied benchmark – there is substantial work in dialogue (including goal directed) for non-embodied environments which we do not consider as aligned with the goals of embodied DIF, but may have important insights. Additionally, future work may overcome the issues raised and it is unclear how to transfer our findings back to the goal directed dialogue in the non-embodied setting. Additional insights may derive from research in social intelligence.
+
+# References
+
+Peter Anderson, Qi Wu, Damien Teney, Jake Bruce, Mark Johnson, Niko Sunderhauf, Ian Reid, Stephen Gould, and Anton Van Den Hengel. 2018. Vision- and language navigation: Interpreting visually-grounded navigation instructions in real environments. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 3674-3683.
+
+Valts Blukis, Dipendra Misra, Ross A Knepper, and Yoav Artzi. 2018. Mapping navigation instructions to continuous control actions with position-visitation prediction. In Conference on Robot Learning, pages 505-518. PMLR.
+Valts Blukis, Chris Paxton, Dieter Fox, Animesh Garg, and Yoav Artzi. 2021. A persistent spatial semantic representation for high-level natural language instruction execution. In Proceedings of the Conference on Robot Learning (CoRL).
+Daniel Brown, Wonjoon Goo, Prabhat Nagarajan, and Scott Niekum. 2019. Extrapolating beyond suboptimal demonstrations via inverse reinforcement learning from observations. In International conference on machine learning, pages 783-792. PMLR.
+Nicolas Carion, Francisco Massa, Gabriel Synnaeve, Nicolas Usunier, Alexander Kirillov, and Sergey Zagoruyko. 2020. End-to-end object detection with transformers. In European conference on computer vision, pages 213-229. Springer.
+David Chen and Raymond J Mooney. 2011. Learning to interpret natural language navigation instructions from observations. In Proceedings of the National Conference on Artificial Intelligence.
+Ta-Chung Chi, Mihail Eric, Seokhwan Kim, Minmin Shen, and Dilek Hakkani-tur. 2019. Just ask:an interactive learning framework for vision and language navigation.
+Harm de Vries, Dzmitry Bahdanau, and Christopher Manning. 2020. Towards ecologically valid research on language user interfaces. arXiv:2007.14435.
+Matt Deitke, Eli VanderBilt, Alvaro Herrasti, Luca Weihs, Jordi Salvador, Kiana Ehsani, Winson Han, Eric Kolve, Ali Farhadi, Aniruddha Kembhavi, and Roozbeh Mottaghi. 2022. Procthor: Large-scale embodied ai using procedural generation. arXiv:2206.06994.
+Daniel Fried, Ronghang Hu, Volkan Cirik, Anna Rohrbach, Jacob Andreas, Louis-Philippe Morency, Taylor Berg-Kirkpatrick, Kate Saenko, Dan Klein, and Trevor Darrell. 2018. Speaker-follower models for vision-and-language navigation. In Advances in Neural Information Processing Systems.
+Asma Ghandeharioun, Judy Hanwen Shen, Natasha Jaques, Craig Ferguson, Noah Jones, Agata Lapedriza, and Rosalind Picard. 2019. Approximating interactive human evaluation with self-play for open-domain dialog systems. In Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc.
+Cynthia Matuszek, Evan Herbst, Luke Zettlemoyer, and Dieter Fox. 2012. Learning to parse natural language commands to a robot control system. In Proc. of the 13th International Symposium on Experimental Robotics (ISER).
+
+So Yeon Min, Devendra Singh Chaplot, Pradeep Ravikumar, Yonatan Bisk, and Ruslan Salakhutdinov. 2021. Film: Following instructions in language with modular methods. arXiv preprint arXiv:2110.07342.
+Khanh Nguyen and Hal Daume III. 2019. Help, anna! visual navigation with natural multimodal assistance via retrospective curiosity-encouraging imitation learning. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 684–695, Hong Kong, China. Association for Computational Linguistics.
+Aishwarya Padmakumar, Jesse Thomason, Ayush Shrivastava, Patrick Lange, Anjali Narayan-Chen, Spandana Gella, Robinson Piramithu, Gokhan Tur, and Dilek Hakkani-Tur. 2022. Teach: Task-driven embodied agents that chat. In Conference on Artificial Intelligence (AAAI).
+Aishwarya Padmakumar, Jesse Thomason, Ayush Shrivastava, Patrick Lange, Anjali Narayan-Chen, Spandana Gella, Robinson Piramuthu, Gokhan Tur, and Dilek Hakkani-Tur. 2021. Teach: Task-driven embodied agents that chat.
+Alexander Pashevich, Cordelia Schmid, and Chen Sun. 2021. Episodic transformer for vision-and-language navigation. arXiv preprint arXiv:2105.06453.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, Peter J Liu, et al. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 21(140):1-67.
+Homero Roman Roman, Yonatan Bisk, Jesse Thomason, Asli Celikyilmaz, and Jianfeng Gao. 2020. RMM: A Recursive Mental Model for Dialog Navigation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings.
+Lanbo She, Shaohua Yang, Yu Cheng, Yunyi Jia, Joyce Chai, and Ning Xi. 2014. Back to the blocks world: Learning new actions through situated human-robot dialogue. In Proceedings of the 15th Annual Meeting of the Special Interest Group on Discourse and Dialogue (SIGDIAL), pages 89–97, Philadelphia, PA, U.S.A. Association for Computational Linguistics.
+Mohit Shridhar, Jesse Thomason, Daniel Gordon, Yonatan Bisk, Winson Han, Roozbeh Mottaghi, Luke Zettlemoyer, and Dieter Fox. 2020. Alfred: A benchmark for interpreting grounded instructions for everyday tasks. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 10740-10749.
+Kunal Pratap Singh, Suvaansh Bhambi, Byeonghwi Kim, Roozbeh Mottaghi, and Jonghyun Choi. 2020. Moca: A modular object-centric approach for interactive instruction following. arXiv preprint arXiv:2012.03208.
+
+Alane Suhr, Claudia Yan, Jacob Schluger, Stanley Yu, Hadi Khader, Marwa Mouallem, Iris Zhang, and Yoav Artzi. 2019. Executing instructions in situated collaborative interactions. arXiv preprint arXiv:1910.03655.
+Stefanie Tellex, Nakul Gopalan, Hadas Kress-Gazit, and Cynthia Matuszek. 2020. Robots that use language. Annual Review of Control, Robotics, and Autonomous Systems, 3(1):null.
+Stefanie Tellex, Thomas Kollar, Steven Dickerson, Matthew R Walter, Ashis Gopal Banerjee, Seth Teller, and Nicholas Roy. 2011. Understanding natural language commands for robotic navigation and mobile manipulation. In Proceedings of the National Conference on Artificial Intelligence.
+Stefanie Tellex, Pratiksha Thaker, Robin Deits, Dimitar Simeonov, Thomas Kollar, and Nicholas Roy. 2013. Toward information theoretic human-robot dialog. In Robotics: Science and Systems.
+Jesse Thomason, Michael Murray, Maya Cakmak, and Luke Zettlemoyer. 2020. Vision-and-dialog navigation. In Conference on Robot Learning, pages 394-406. PMLR.
+Yueh-Hua Wu, Nontawat Charoenphakdee, Han Bao, Voot Tangkaratt, and Masashi Sugiyama. 2019. Imitation learning from imperfect demonstration. In International Conference on Machine Learning, pages 6818-6827. PMLR.
+Songyuan Zhang, Zhangjie Cao, Dorsa Sadigh, and Yanan Sui. 2021. Confidence-aware imitation learning from demonstrations with varying optimality. Advances in Neural Information Processing Systems, 34.
+Fengda Zhu, Yi Zhu, Xiaojun Chang, and Xiaodan Liang. 2020. Vision-language navigation with self-supervised auxiliary reasoning tasks. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 10012-10022.
+
+# A More Discussion of Symbiote
+
+Symbiote has a modular structure, which consists of language understanding, mapping, and low-level planning components. It is not trained with imitation learning of low-level demonstrations (e.g. move right, move left, etc.). Demonstrations are used only in the sense that they provide subgoals that suervise the training of the language understanding component.
+
+More specifically, a pretrained T5 model (Raffel et al., 2020) fine-tuned with the ground truth subgoals (edh_instance['future_subgoals']) serves as the language understanding component. The model takes the driver and commander's dialogue and previous actions as input; it is trained to output a sequence of subgoals of the form {"action}{obj}], where {action} is either "navigate" or any of the primitive interactions commands "pickup", "cut", "toggle", etc, and {obj} is any of the object classes in ai2thor.
+
+For the mapping component, a DETR detector (Carion et al., 2020) was finetuned on the train set scenes of TEACH and the depth prediction model from FILM was used off-the-shelf. Frontier based exploration is used for environment exploration. Similarly as in FILM, the agent navigates to object goals in the map using the fast marching method.
+
+# B How the Statistics of Section 5 were Obtained
+
+We explain how the statistics that appear in each table of Section 4 were obtained. All analyses, except for TfD results in Penalizing Agents for Accuracy, were done on EDH tasks.
+
+Irrelevant Actions The first table shows some representative unnecessary state changes that EDH tasks require for "task success" in evaluation. For example, in our common sense, it is not necessary that we leave the coffee machine on to successfully make coffee (indeed, it is better to turn it off after use). However, since EDH evaluation requires that the agent exactly follows state changes done in the demonstration, the agent will have to leave coffee machine turned on for a particular validation task, if this was done in its corresponding demonstration.
+
+Each row shows unnecessary state changes that are exemplary and the average frequency of these noises across relevant tasks. More specifically,
+
+- Coffee Machine on/ off: 'Coffee' tasks
+
+- Picked up and not placed: all tasks
+
+- Faucet on/ off: all tasks that may involve using the faucet ('Coffee', 'Clean All X', 'Boil X', 'Water Plant', 'Sandwich', 'Breakfast', 'Plate Of Toast', 'Salad')
+
+- Stove/ Microwave on/off: all tasks that may involve using a heating appliance ('Boil X', 'N Cooked Slices Of X In Y')
+
+"Total" accounts for the percentage of EDH tasks that fall into any of the above criteria. Please refer to (Padmakumar et al., 2021) for the possible types (e.g. 'Coffee') of tasks.
+
+While the first table shows statistics of irrelevant state changes of "relevant objects", the second table shows those of more random actions, at a lower level. Navigation No Op, the first kind, was simply obtained by detecting the existence of consecutive Turn Lef/Right x 4, Forward + Backward, Pan Right + Pan Left, Turn Right + Turn Left. The second kind, interaction No Op, was similarly detected. Whether an consecutive and opposite interactions were done on the same "object" was detected by replaying the predActions in the model outputs. Interaction w. unrelated objects denotes whether the demonstration an object that is completely unrelated from task type (e.g. picking up saltshaker for a task whose type is 'Coffee'). Demonstrations unaligned with dialogue were counted manually since there is no automatic way to filter these.
+
+Penalizing Agents for Accuracy The statistics in this subsection were straightforwardly obtained by averaging over the evaluation outputs (whose formats follow that of the original ET code from TEACh) of each task.
+
+Behavior Cloning with Suboptimal Demonstrations The same procedures for the second table in Irrelevant Actions were used.
+
+# C TEACH Prefiltering
+
+Only necessary state changes are checked in EDH evaluation, but all are present in training. https:// github.com/alexa/teach#downloading-the-dataset mentions that the authors filtered the EDH tasks so that "the state changes checked for to evaluate success are only those that contribute towards task success in the main task of the gameplay session the EDH instance is created from." Our analysis is on data that has already been filtered and cleaned and yet still exhibits these problems.
\ No newline at end of file
diff --git a/dontcopytheteacherdataandmodelchallengesinembodieddialogue/images.zip b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..634104cfe21f86217d373fa5c1a4cafd22aaaa4a
--- /dev/null
+++ b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:982b4cf537f6ada95ab42b48da80a1e6d385a429cd171c8904213d66a4b5cdd6
+size 255947
diff --git a/dontcopytheteacherdataandmodelchallengesinembodieddialogue/layout.json b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..e52c0e62b9602b183f329802d8ea281c0abd2019
--- /dev/null
+++ b/dontcopytheteacherdataandmodelchallengesinembodieddialogue/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:db40e5e354f2f0123c0dd2a73fd83d63915498107d949dbad54876171878e565
+size 204528
diff --git a/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_content_list.json b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..f29cc7492108a799ea1117e1b873e867129f5222
--- /dev/null
+++ b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:291a3168965c3120bdf5f1a91f7f009f744de6797569887c36d80340d493cf7e
+size 87473
diff --git a/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_model.json b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..a6c308b7b77b5a3d9c1dd557d4e65ee2202a0cdf
--- /dev/null
+++ b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a88aae77f13586e731240f99e088972abdc4c56c27b73cc618f42e83065b4a05
+size 102274
diff --git a/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_origin.pdf b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..129deefd2e0477c55101973302ff6f93ce243829
--- /dev/null
+++ b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/ef35152e-c136-4eee-b893-723c3d0b3dda_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:74e51517b67c7db098690c8db2f0981db1c0431595ddda873c36ec3d31474530
+size 4137154
diff --git a/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/full.md b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..6d1db862738957bc2b4a1e58d88a76b10fcdcdd8
--- /dev/null
+++ b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/full.md
@@ -0,0 +1,260 @@
+# Don't Prompt, Search!
+
+# Mining-based Zero-Shot Learning with Language Models
+
+Mozes van de Kar
+
+Mengzhou Xia²
+
+Danqi Chen
+
+Mikel Artetxe³
+
+1University of Amsterdam
+
+2Princeton University
+
+Meta AI
+
+mozesvandekar@gmail.com
+
+{mengzhou,danqic}@cs.princeton.edu
+
+artetxe@meta.com
+
+# Abstract
+
+Masked language models like BERT can perform text classification in a zero-shot fashion by reformulating downstream tasks as text infilling. However, this approach is highly sensitive to the template used to prompt the model, yet practitioners are blind when designing them in strict zero-shot settings. In this paper, we propose an alternative mining-based approach for zero-shot learning. Instead of prompting language models, we use regular expressions to mine labeled examples1 from unlabeled corpora, which can optionally be filtered through prompting, and used to finetune a pretrained model. Our method is more flexible and interpretable than prompting, and outperforms it on a wide range of tasks when using comparable templates. Our results suggest that the success of prompting can partly be explained by the model being exposed to similar examples during pretraining, which can be directly retrieved through regular expressions.
+
+# 1 Introduction
+
+Recent work has obtained strong zero-shot results by prompting language models (Brown et al., 2020; Chowdhery et al., 2022). As formalized by Schick and Schütze (2021a), the core idea is to reformulate text classification as language modeling using a pattern and a verbalizer. Given the input space $X$ , the output space $C$ and the space of possible strings $V^{*}$ , the pattern $t:X\to V^{*}$ maps each input into a string with a masked span, whereas the verbalizer $v:C\rightarrow V^{*}$ maps each label into a string. A language model can then be used for zero-shot classification by picking the most likely completion for the masked text $\arg \max_{c\in C}p(v(c)\mid t(x))$ . In
+
+
+Figure 1: Proposed method. 1) We mine labeled examples from a text corpus with regex-based patterns. 2) Optionally, we filter examples for which zero-shot prompting predicts a different label. 3) We finetune a pretrained language model with a classification head.
+
+few-shot settings, better results can be obtained by preponding a few labeled examples (Brown et al., 2020), or using them in some form of fine-tuning (Schick and Schütze, 2021a; Gao et al., 2021).
+
+However, prompting is known to be sensitive to the choice of the pattern and the verbalizer, yet practitioners are blind when designing them in true zero-shot settings (Jiang et al., 2020; Perez et al., 2021). Connected to that, subtle phenomena like the surface form competition (Holtzman et al., 2021) have a large impact on performance. Recent work has tried to mitigate these issues through calibration (Zhao et al., 2021), prompt combination (Schick and Schütze, 2021a; Lester et al., 2021; Zhou et al., 2022) or automatic prompt generation (Shin et al., 2020; Gao et al., 2021). At the same time, there is still not a principled understanding of how language models become few-shot learners, with recent work analyzing the role of the pretraining data (Chan et al., 2022) or the input-output mapping of
+
+| Task | Prompting pattern | Mining pattern |
| Sentiment | {INPUT}. It was {VERBALIZER}. | (is|was) {VERBALIZER}*. {INPUT} |
| Topic class. | {INPUT}. It is about {VERBALIZER}. | {VERBALIZER}*. {INPUT} |
| NLI | {INPUT:HYP} {VERBALIZER}, {INPUT:PREM} | {INPUT:HYP} {VERBALIZER}, {INPUT:PREM} |
+
+Table 1: Patterns. {VERBALIZER} is replaced with the verbalizers in Table 2. For mining, *, captures everything up to a sentence boundary, and {INPUT}, {INPUT:HYP} and {INPUT:PREM} capture a single sentence.
+
+| Task | Lbl | Verbalizers |
| Sent. | Pos. | good, great, awesome, incredible |
| Neg. | bad, awful, terrible, horrible |
| NLI | Ent. | Yes, Therefore, Thus, Accordingly, Hence, For this reason |
| Con. | No, However, But, On the contrary, In contrast |
| Neu. | Maybe, Also, Furthermore, Secondly, Additionally, Moreover, In addition |
+
+Table 2: Verbalizers for sentiment classification and NLI. See Table 9 for verbalizers used in topic classification. When using a single verbalizer, we choose the one underlined. Multi-token verbalizers are in italic. Lbl: label, Ent./Con./Neu: entailment, contradiction, neutral.
+
+in-context demonstrations (Min et al., 2022).
+
+In this paper, we propose an alternative approach to zero-shot learning that is more flexible and interpretable than prompting, while obtaining stronger results in our experiments. Similar to prompting, our method requires a pretrained language model, pattern, and verbalizer, in addition to an unlabeled corpus (e.g., the one used for pretraining). As illustrated in Figure 1, our approach works by using the pattern and verbalizer to mine labeled examples from the corpus through regular expressions, and leveraging them as supervision to finetune the pretrained language model. This allows to naturally combine multiple patterns and verbalizers for each task, while providing a signal to interactively design them by looking at the mined examples. In addition, we show that better results are obtained by filtering the mined examples through prompting.
+
+Experiments in sentiment analysis, topic classification and natural language inference (NLI) confirm the effectiveness of our approach, which outperforms prompting by a large margin when using the exact same verbalizers and comparable patterns. Our results offer a new perspective on how language models can perform downstream tasks in a zero-shot fashion, showing that similar examples often exist in the pretraining corpus, which can be directly retrieved through simple
+
+extraction patterns.
+
+# 2 Proposed Method
+
+As shown in Figure 1, our method has three steps: Mine. We first use the pattern and a set of verbalizers to extract labeled examples from the corpus. To that end, we define patterns that are filled with verbalizers and expanded into regular expressions. For instance, the pattern and verbalizer in Figure 1 would extract every sentence following "is good." or "was good." as an example of the positive class, and every sentence following "is bad." or "was bad." as an example of the negative class. In practice, the patterns that we define are comparable to the ones used for prompting, and the verbalizers are exactly the same (see Tables 1 and 2). Appendix A gives more details on how we expand patterns into regular expressions. While prior work in prompting typically uses a single verbalizer per class, our approach allows to naturally combine examples mined through multiple verbalizers in a single dataset. So as to mitigate class imbalance and keep the mined dataset to a reasonable size, we mine a maximum of $40\mathrm{k}$ examples per class after balancing across the different verbalizers.
+
+Filter. As an optional second step, we explore automatically removing noisy examples from the mined data. To that end, we classify the mined examples using zero-shot prompting, and remove examples for which the predicted and the mined label do not match. This filtering step is reliant on the performance of prompting, and we only remove $10\%$ of the mismatching examples for which zero-shot prompting is the most confident.
+
+Finetune. Finally, we use the mined dataset to finetune a pretrained language model in the standard supervised fashion (Devlin et al., 2019), learning a new classification head.
+
+# 3 Experimental Settings
+
+Tasks. We evaluate on three types of tasks: binary sentiment analysis on Amazon (Zhang et al.,
+
+ | Sentiment analysis | Topic class. | NLI | avg |
| amz | imd | mr | sst | ylp | agn | dbp | yah | mnl | qnl | rte | snl |
| Full-shot | Fine-tuning | 97.1 | 95.7 | 88.8 | 94.4 | 95.0 | 95.1 | 99.3 | 76.8 | 78.5 | 92.6 | 67.6 | 90.5 | 89.3 |
| Zero-shot | Prompting | 81.5 | 78.4 | 71.1 | 77.4 | 81.9 | 34.0 | 36.4 | 28.2 | 47.1 | 50.8 | 52.3 | 39.6 | 56.6 |
| w/ multi verb. | 83.5 | 81.8 | 78.3 | 81.9 | 83.1 | 54.6 | 51.1 | 34.1 | 46.5 | 58.2 | 61.4 | 44.1 | 63.2 |
| Proposed method | 92.0 | 86.7 | 80.5 | 85.6 | 92.0 | 79.2 | 80.4 | 56.1 | 50.4 | 53.2 | 62.6 | 46.0 | 72.0 |
+
+2015), IMDb (Maas et al., 2011), MR (Pang and Lee, 2005), SST-2 (Socher et al., 2013) and Yelp (Zhang et al., 2015), topic classification on AG News (Zhang et al., 2015), DBPedia (Zhang et al., 2015) and Yahoo Topics $^3$ (Zhang et al., 2015), and NLI on MNLI (Williams et al., 2018), QNLI (Rajpurkar et al., 2016), RTE (Dagan et al., 2005; Bar-Haim et al., 2006; Giampiccolo et al., 2007; Bentivogli et al., 2009) and SNLI (Bowman et al., 2015). We report accuracy on the test set when available, falling back to the validation set for SST-2, MNLI, RTE and QNLI. For all systems involving fine-tuning, we report the average across 3 runs with different random seeds. We ran all development experiments on SST-2 and AG News without any exhaustive hyperparameter exploration, and evaluate the rest of the tasks blindly.
+
+Approaches. We compare the following methods in our experiments, using RoBERTa-base (Liu et al., 2019) as the pretrained model in all cases:
+
+- Full-shot fine-tuning: We finetune RoBERTa on the original training set adding a new classification head. We train for 3 epochs with a batch size of 32. All the other hyperparameters follow Liu et al. (2019). Refer to Appendix B for more details.
+- Zero-shot prompting: Standard prompting, described in §1. Multi-token verbalizer probabilities are calculated autoregressively, picking the most likely token at each step (Schick and Schütze, 2021c). We report results using both a single verbalizer per class, as it is common in prior work, as well as multiple verbalizers per class, which is more comparable to our approach. For the latter, we combine the probabil
+
+Table 3: Main results (accuracy). All systems are based on RoBERTa-base, and all zero-shot systems use comparable patterns (see Table 1). We report average accuracy across 3 runs for all systems except prompting. w/ multi verb.: prompting with different sets of verbalizers (Table 9) and averaging the probabilities.
+
+ | Prompting | Mining |
| good / bad | 78.1 | 72.0 |
| great / awful | 82.3 | 82.1 |
| awesome / terrible | 82.3 | 83.9 |
| incredible / horrible | 83.1 | 87.3 |
| combined | 81.7 | 85.4 |
+
+Table 4: Average sentiment accuracy using different verbalizers. We report mining results without filtering. More detailed results are provided in Table 12.
+
+ities of each verbalizer by averaging.4
+
+- Zero-shot mining: Our proposed method, described in §2. For the mining step, we use the first 100 shards from the C4 corpus (Raffel et al., 2020), which cover $9.8\%$ of the data. For the filtering step, we use single-verbalizer prompting to filter $10\%$ of the mislabeled examples. For the fine-tuning step, we use the same settings as in the full-shot setup, except that we train for 5,000 steps with a dropout probability of 0.4. To mitigate class imbalance, we form batches by first sampling the class for each instance from the uniform distribution, and then picking a random example from the mined data belonging to that class.
+
+Patterns and verbalizers. We use comparable patterns for prompting and mining with the exact same verbalizers, which we report in Table 1 and 2. These were designed without any experiment, simulating a zero-shot setting. We design our patterns
+
+| Pattern | Verbalizer | avg |
| Prompting | | |
| {VERBALIZER} stars: {INPUT} | 5/1 | 51.0 |
| {INPUT} I {VERBALIZER} it. | love/hate | 73.1 |
| {INPUT} It is {VERBALIZER}. | good/bad | 78.1 |
| Mining | | |
| {VERBALIZER} star*. {INPUT} | 5/1 | 72.1 |
| I {VERBALIZER}*. {INPUT} | love/hate | 85.5 |
| (is|was) {VERBALIZER}*. {INPUT} | good/bad | 72.0 |
+
+Table 5: Average sentiment accuracy using different patterns and verbalizers. We report mining results without filtering (more details are provided in Table 13).
+
+| Data | Filter | Sent. | Topic | NLI |
| Supervised | - | 94.2 | 90.4 | 82.3 |
| Mined | none | 85.4 | 71.5 | 52.0 |
| prompting | 87.4 | 71.9 | 53.0 |
| supervised† | 91.4 | 85.5 | 63.8 |
+
+to capture sentences following a verbalizer, rather than sentences containing the verbalizer, as the resulting dataset would otherwise be trivial (solvable by detecting the presence of certain words).
+
+# 4 Results and Analysis
+
+We next discuss our main findings and report additional results in Appendix C.
+
+Main results. We report our main results in Table 3. Our method outperforms prompting by 8.8 points on average, and the improvements are consistent across all tasks.
+
+Effect of patterns and verbalizers. Table 4 reports sentiment results using different verbalizers. Consistent with prior work, we find that both prompting and mining are highly sensitive to the choice of the verbalizer, yet combining them all roughly matches the results of the best performing one. As shown in Table 5, using different patterns has an even larger impact. Interestingly, patterns and verbalizers that do well with one approach do not necessarily do well with the other.
+
+Effect of filtering. Table 6 reports additional results using the full-shot systems for filtering, or not
+
+Table 6: Filtering results (average accuracy). $\dagger$ : uses mined data for training and another supervised classifier as the filter. This is not a zero-shot setting and serves as an upper limit for the results using a perfect filter. More detailed results are provided in Table 11.
+
+| # | Lbl | Mined example |
| 1 | Pos. | Do you have an idea of how broad your vocal range was? |
| 2 | Pos. | Once home, we began priming. |
| 3 | Neg. | People in Wall Street and other financial services firms should have paid more attention to the data. |
| 4 | Neg. | So I bought this unit, which said it had the same technical features as the other brand, such as number of channels etc, and this one performed amazing!! |
+
+Table 7: Mined examples for sentiment analysis. See more examples in Table 17 and mined NLI examples in Table 18.
+
+using any filtering at all. We find that prompting-based filtering brings modest but consistent improvements across all types of tasks. We compare this to filtering out all examples with mismatching labels with the full-shot model, which results in much larger gains and approaches the performance of the fully supervised system for sentiment and topic classification tasks. This can be seen as an upper-limit of what could be reached with perfect filtering, which leaves ample room to improve our approach focusing on the filtering step alone.
+
+Qualitative analysis. We manually assessed 20 mined examples for sentiment analysis and report some representative instances in Table 7. We find that the mined data covers many domains like finance and technology. Most examples are correct (#1, #3), but there are also instances with wrong labels (#4). In addition, we find that $40\%$ of analyzed examples show weak or neutral sentiment (#2). The impact of such irrelevant examples is unclear and worth of future study.
+
+# 5 Related work
+
+Recent work in zero-shot learning has explored a similar generate-filter-finetune approach, but using large language models instead of mining to generate training data (Schick and Schütze, 2021b; Liu et al., 2022; Meng et al., 2022; Ye et al., 2022). Mining-based approaches have a long tradition in information extraction (Riloff, 1996; Riloff and Jones, 1999). However, to the best of our knowledge, we are the first to apply them for zero-shot learning as an alternative to prompting. Instead of mining examples for the target task, Bansal et al. (2020) define task-agnostic pretraining objectives on unlabeled corpora. Closer to our work, Meng et al. (2020) mask label-indicative words in an
+
+unlabeled corpus, and train a model to predict their corresponding label. Concurrent to our work, Han and Tsvetkov (2022) try locating a subset of the pretraining data that supports prompting in specific tasks. Finally, Razeghi et al. (2022) show a strong correlation between performance on specific instances and the frequency of terms from those instances in the pretraining data.
+
+# 6 Conclusions
+
+In this work, we have shown that mining-based zero-shot learning outperforms prompting. Moreover, our approach shows headroom for further improvement by exploring filtering techniques. The flexibility of our approach enables additional directions like domain filtering, bootstrapping, and interactive pattern/verbalizer design, where practitioners would inspect a few mined examples and refine their patterns until they are satisfied. In addition, our methods can serve as a partial explanation for why prompting works, showing that task-relevant examples are often present in the pretraining corpus in an explicit form, to the extent that they can be directly mined through simple regular expressions. Nevertheless, we believe that there can be other factors involved, as evidenced by the best patterns and verbalizers being different for mining and prompting, and we believe that delving deeper into the relation between pretraining data and prompting performance is an interesting future direction.
+
+# Limitations
+
+Developing zero-shot methods in a rigorous manner is challenging: the strict zero-shot scenario does not allow using annotated data except for the final evaluation, yet it is difficult to make development decisions without any signal. We decided to use AG News and SST-2 during development without any exhaustive hyperparameter exploration, and evaluate blindly in the rest of the tasks. At the same time, we designed all patterns and verbalizers without any experiment, based solely on our own intuition. We believe that the comparison between prompting and mining is fair as we used comparable patterns with the exact same verbalizers and pretrained model. However, it is possible that our patterns, verbalizers and/or hyperparameters are suboptimal, and better results could be obtained with either prompting or mining using other configurations.
+
+An important limitation of our approach is that it
+
+can be difficult to design extraction patterns for certain tasks like multiple choice questions. However, prompting is known to suffer from a similar limitation, with certain tasks like WiC being difficult to formulate as language modeling and obtaining random chance performance (Brown et al., 2020).
+
+Different from prompting, our approach requires an intermediate step after pretraining to mine data and finetune the model, which takes 2-7 hours using a single Nvidia Titan RTX GPU and 4 Intel Xeon CPUs. However, inference cost is similar or even faster than prompting, as our approach does not incur on any overhead for multi-token and multi-verbalizer setups.
+
+# Acknowledgements
+
+We thank Ves Stoyanov, Jingfei Du, Timo Schick and Sewon Min for their feedback. Mozes van de Kar received a travel grant from ELLIS and Qualcomm to attend the conference.
+
+# References
+
+Trapit Bansal, Rishikesh Jha, Tsendsuren Munkhdalai, and Andrew McCallum. 2020. Self-supervised meta-learning for few-shot natural language classification tasks. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 522-534, Online. Association for Computational Linguistics.
+Roy Bar-Haim, Ido Dagan, Bill Dolan, Lisa Ferro, Danilo Giampiccolo, Bernardo Magnini, and Idan Szpektor. 2006. The second pascal recognising textual entailment challenge. In Proceedings of the second PASCAL challenges workshop on recognising textual entailment, volume 6. Venice.
+Luisa Bentivogli, Peter Clark, Ido Dagan, and Danilo Giampiccolo. 2009. The fifth pascal recognizing textual entailment challenge. In TAC.
+Samuel R. Bowman, Gabor Angeli, Christopher Potts, and Christopher D. Manning. 2015. A large annotated corpus for learning natural language inference. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 632-642, Lisbon, Portugal. Association for Computational Linguistics.
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec
+
+Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Advances in Neural Information Processing Systems, volume 33, pages 1877-1901. Curran Associates, Inc.
+Stephanie C. Y. Chan, Adam Santoro, Andrew K. Lampinen, Jane X. Wang, Aaditya Singh, Pierre H. Richemond, Jay McClelland, and Felix Hill. 2022. Data distributional properties drive emergent in-context learning in transformers.
+Aakanksha Chowdhery, Sharan Narang, Jacob Devlin, Maarten Bosma, Gaurav Mishra, Adam Roberts, Paul Barham, Hyung Won Chung, Charles Sutton, Sebastian Gehrmann, Parker Schuh, Kensen Shi, Sasha Tsvyashchenko, Joshua Maynez, Abhishek Rao, Parker Barnes, Yi Tay, Noam Shazeer, Vinodkumar Prabhakaran, Emily Reif, Nan Du, Ben Hutchinson, Reiner Pope, James Bradbury, Jacob Austin, Michael Isard, Guy Gur-Ari, Pengcheng Yin, Toju Duke, Anselm Levskaya, Sanjay Ghemawat, Sunipa Dev, Henryk Michalewski, Xavier Garcia, Vedant Misra, Kevin Robinson, Liam Fedus, Denny Zhou, Daphne Ippolito, David Luan, Hyeontaek Lim, Barret Zoph, Alexander Spiridonov, Ryan Sepassi, David Dohan, Shivani Agrawal, Mark Omernick, Andrew M. Dai, Thanumalayan Sankaranarayana Pillai, Marie Pellat, Aitor Lewkowycz, Erica Moreira, Rewon Child, Oleksandr Polozov, Katherine Lee, Zongwei Zhou, Xuezhi Wang, Brennan Saeta, Mark Diaz, Orhan First, Michele Catasta, Jason Wei, Kathy Meier-Hellstern, Douglas Eck, Jeff Dean, Slav Petrov, and Noah Fiedel. 2022. Palm: Scaling language modeling with pathways.
+Ido Dagan, Oren Glickman, and Bernardo Magnini. 2005. The pascal recognising textual entailment challenge. In *Machine Learning Challenges Workshop*, pages 177-190. Springer.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Tianyu Gao, Adam Fisch, and Danqi Chen. 2021. Making pre-trained language models better few-shot learners. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 3816-3830, Online. Association for Computational Linguistics.
+Danilo Giampiccolo, Bernardo Magnini, Ido Dagan, and Bill Dolan. 2007. The third PASCAL recognizing textual entailment challenge. In Proceedings of the ACL-PASCAL Workshop on Textual Entailment and
+
+Paraphrasing, pages 1-9, Prague. Association for Computational Linguistics.
+Xiaochuang Han and Yulia Tsvetkov. 2022. Orca: Interpreting prompted language models via locating supporting data evidence in the ocean of pretraining data. arXiv preprint arXiv:2205.12600.
+Ari Holtzman, Peter West, Vered Shwartz, Yejin Choi, and Luke Zettlemoyer. 2021. Surface form competition: Why the highest probability answer isn't always right. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 7038-7051, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Zhengbao Jiang, Frank F. Xu, Jun Araki, and Graham Neubig. 2020. How can we know what language models know? Transactions of the Association for Computational Linguistics, 8:423-438.
+Brian Lester, Rami Al-Rfou, and Noah Constant. 2021. The power of scale for parameter-efficient prompt tuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 3045-3059, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Quentin Lhoest, Albert Villanova del Moral, Yacine Jernite, Abhishek Thakur, Patrick von Platen, Suraj Patil, Julien Chaumont, Mariama Drame, Julien Plu, Lewis Tunstall, Joe Davison, Mario Šaško, Gunjan Chhablani, Bhavitvya Malik, Simon Brandeis, Teven Le Scao, Victor Sanh, Canwen Xu, Nicolas Patry, Angelina McMillan-Major, Philipp Schmid, Sylvain Gugger, Clément Delangue, Theo Matussière, Lysandre Debut, Stas Bekman, Pierrick Cistac, Thibault Goehringer, Victor Mustar, François Lagunas, Alexander Rush, and Thomas Wolf. 2021. Datasets: A community library for natural language processing. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 175-184, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Alisa Liu, Swabha Swayamdipta, Noah A. Smith, and Yejin Choi. 2022. Wanli: Worker and ai collaboration for natural language inference dataset creation.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach.
+Andrew L. Maas, Raymond E. Daly, Peter T. Pham, Dan Huang, Andrew Y. Ng, and Christopher Potts. 2011. Learning word vectors for sentiment analysis. In Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies, pages 142-150, Portland, Oregon, USA. Association for Computational Linguistics.
+
+Yu Meng, Jiaxin Huang, Yu Zhang, and Jiawei Han. 2022. Generating training data with language models: Towards zero-shot language understanding.
+Yu Meng, Yunyi Zhang, Jiaxin Huang, Chenyan Xiong, Heng Ji, Chao Zhang, and Jiawei Han. 2020. Text classification using label names only: A language model self-training approach. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 9006-9017, Online. Association for Computational Linguistics.
+Sewon Min, Xinxi Lyu, Ari Holtzman, Mikel Artetxe, Mike Lewis, Hannaneh Hajishirzi, and Luke Zettlemoyer. 2022. Rethinking the role of demonstrations: What makes in-context learning work?
+Bo Pang and Lillian Lee. 2005. Seeing stars: Exploiting class relationships for sentiment categorization with respect to rating scales. In Proceedings of the 43rd Annual Meeting of the Association for Computational Linguistics (ACL'05), pages 115-124, Ann Arbor, Michigan. Association for Computational Linguistics.
+Ethan Perez, Douwe Kiela, and Kyunghyun Cho. 2021. True few-shot learning with language models. In Advances in Neural Information Processing Systems.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140):1-67.
+Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. 2016. SQuAD: $100,000+$ questions for machine comprehension of text. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2383-2392, Austin, Texas. Association for Computational Linguistics.
+Yasaman Razeghi, Robert L. Logan, Matt Gardner, and Sameer Singh. 2022. Impact of pretraining term frequencies on few-shot reasoning.
+Ellen Riloff. 1996. Automatically generating extraction patterns from untagged text. In Proceedings of the Thirteenth National Conference on Artificial Intelligence - Volume 2, AAAI'96, page 1044-1049. AAAI Press.
+Ellen Riloff and Rosie Jones. 1999. Learning dictionaries for information extraction by multi-level bootstrapping. In Proceedings of the Sixteenth National Conference on Artificial Intelligence and the Eleventh Innovative Applications of Artificial Intelligence Conference Innovative Applications of Artificial Intelligence, AAAI '99/IAAI '99, page 474-479, USA. American Association for Artificial Intelligence.
+Timo Schick and Hinrich Schütze. 2021a. Exploiting cloze-questions for few-shot text classification and natural language inference. In Proceedings of the
+
+16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 255-269, Online. Association for Computational Linguistics.
+Timo Schick and Hinrich Schütze. 2021b. Generating datasets with pretrained language models. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 6943-6951, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Timo Schick and Hinrich Schütze. 2021c. It's not just size that matters: Small language models are also few-shot learners. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2339-2352, Online. Association for Computational Linguistics.
+Taylor Shin, Yasaman Razeghi, Robert L. Logan IV, Eric Wallace, and Sameer Singh. 2020. *AutoPrompt: Eliciting Knowledge from Language Models with Automatically Generated Prompts*. In *Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP)*, pages 4222-4235, Online. Association for Computational Linguistics.
+Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Ng, and Christopher Potts. 2013. Recursive deep models for semantic compositionality over a sentiment treebank. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, pages 1631-1642, Seattle, Washington, USA. Association for Computational Linguistics.
+Adina Williams, Nikita Nangia, and Samuel Bowman. 2018. A broad-coverage challenge corpus for sentence understanding through inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 1112–1122, New Orleans, Louisiana. Association for Computational Linguistics.
+Jiacheng Ye, Jiahui Gao, Qintong Li, Hang Xu, Jiangtao Feng, Zhiyong Wu, Tao Yu, and Lingpeng Kong. 2022. Zerogen: Efficient zero-shot learning via dataset generation.
+Xiang Zhang, Junbo Zhao, and Yann LeCun. 2015. Character-level convolutional networks for text classification. In Advances in Neural Information Processing Systems, volume 28. Curran Associates, Inc.
+Tony Z. Zhao, Eric Wallace, Shi Feng, Dan Klein, and Sameer Singh. 2021. Calibrate before use: Improving few-shot performance of language models.
+Chunting Zhou, Junxian He, Xuezhe Ma, Taylor Berg-Kirkpatrick, and Graham Neubig. 2022. Prompt consistency for zero-shot task generalization.
+
+# A Pattern expansion for mining
+
+For each class, examples are mined by filling in the pattern with the verbalizer and extracting sentences that match the filled-in pattern. The process of expanding the patterns into regular expressions is as follows. First, we replace {VERBALIZER} with a capturing group containing all verbalizers separated by the alternation operator |. For example, the verbalizer good, great, awesome is expanded into (good|great|awesome). Finally, we replace the keywords described in Table 8 with the corresponding regular expressions. The result is a regular expression containing capturing groups for extracting sentences in a case-insensitive fashion.
+
+Note that we use a simplistic sentence definition in order to keep the regex manageable. Since we assume that a period always ends a sentence, this mistakenly interprets abbreviations as multiple sentences (e.g., "U.S.A." contains 3 sentences). To address this, we filter out mined sentences shorter than 4 characters.
+
+# B Additional experimental details
+
+Patterns and verbalizers. For each category of tasks we use the same mining pattern, as shown in Table 1. The complete list of verbalizers for each task is given in Table 9. Tasks with the same classes share the same verbalizers. This means that all sentiment and NLI tasks have the same verbalizers. Each topic classification task, however, has a unique set of verbalizers. Note that while SNLI and MNLI (3-way NLI) have the same verbalizers as RTE and QNLI (2-way NLI), the mined datasets do differ since 2-way NLI does not include a neutral class.
+
+Hyperparameters. Table 10 shows the hyperparameters used for finetuning the RoBERTa-base model. All the other hyperparameters and classification head architecture follow Liu et al. (2019). We have two fine-tuning configurations, one for fine-tuning in the full-shot setting and one for zero-shot fine-tuning on the mined dataset. These configurations differ only in the maximum number of steps, dropout rate and batch sampler.
+
+Datasets. We use Huggingface (Lhoest et al., 2021) for loading all evaluation datasets without any additional processing, except for MR which is detokenized using Moses scripts. We evaluate on the test set, falling back to the validation set for SST-2, MNLI, RTE and QNLI.
+
+| Keyword | Regex |
| {VERBALIZER} | Replaced with the verbalizer |
| * | regex:^[^.!?]*?
+Greedily matches non-sentence-ending characters |
| {INPUT} | regex: ([^.!?]+[.!?]+)
+Matches a single sentence, extracted with the key “INPUT” |
+
+Table 8: Keywords that compile into regular expressions. These keywords are used in the mining patterns and verbalizers.
+
+# C Additional results
+
+Complete results for full-shot, prompting and mining are combined in Table 11. Results showing the effect of pattern and verbalizer choice on binary sentiment classification are presented in Table 12 and Table 13, respectively.
+
+As explained in the main text, development experiments were only conducted on AGNews and SST-2. On these tasks, we found that high regularization partially mitigates overfitting caused by the misalignment between the mined dataset and real dataset. However, this high regularization shows mixed results for non-development tasks. For full transparency, we compare these performance differences in Table 14, but, in the main text, we stick to the original setup with high dropout to be faithful to the rigorous zero-shot scenario.
+
+For multi-verbalizer prompting, we combine the probabilities of each verbalizer with an aggregation function. Results for using the average, the max and the sum are shown in Table 15.
+
+In Table 16 we show the agreement between the mined labels and the labels according to the filtering method, which in our experiments is either a full-shot finetuned model or single-verbalizer prompting.
+
+Table 17 and Table 18 show a random sample of examples from the mined training dataset for respectively binary sentiment analysis and NLI. In the main text, Table 7 shows a representative selection of examples for sentiment analysis. These examples were manually picked from the random sample in Table 17.
+
+| Task | Class | Verbalizers |
| Sentiment | Positive | good, great, awesome, incredible |
| Negative | bad, awful, terrible, horrible |
| AGNews | World | world, foreign, global, Asia, Europe, China |
| Sports | sports, football, basketball, tennis, soccer, baseball |
| Business | business, stock, financial, profit, economy, finance |
| Sci/Tech | technology, science, research, chemical, iPhone, smartphone |
| DBPedia | Company | company, business, manufacturer, operates in school, college, education, university |
| Educational institution | artist, writer, song, composer |
| Athlete | sports, runner, basketball, football |
| Office holder | politics, president, Senate, politician |
| Mean of transportation | bus, bike, car, train, ship, plane, aircraft |
| Building | building, office, house, monument |
| Natural place | river, forest hill, nature |
| Village | town, village, small population, small town |
| Animal | animal, species, horse, dog, pet, habitat |
| Plant | plant, leaf, flower, herb |
| Album | album, recording, record company |
| Film | film, movie, actor, actress |
| Written work | written, book, novel, poem |
| Yahoo | Society & Culture | culture, holiday, society |
| Science & Mathematics | science, technology, math, research |
| Health | health, body, exercise, stress relieve |
| Education & Reference | school, college, education, university |
| Computers & Internet | computer, internet, keyboard, software |
| Sports | sports, football, basketball, game |
| Business & Finance | business, stock, financial, profit |
| Entertainment & Music | film, movie, actor, writer |
| Family & Relationships | love, family, father, mother |
| Politics & Government | politics, president, Senate, politician |
| NLI | Entailment | Yes, Therefore, Thus, Accordingly, Hence, For this reason |
| Contradiction | No, However, But, On the contrary, In contrast |
| Neutral | Maybe, Also, Furthermore, Secondly, Additionally, Moreover, In addition |
+
+Table 9: Verbalizers. When using a single verbalizer we choose the one underlined. In the multi-verbalizer setting we use all listed verbalizers. Sentiment includes Amazon, IMDB, MR, SST-2 and Yelp; NLI includes MNLI, QNLI, RTE and SNLI. Multi-token verbalizers are italic.
+
+| Parameter | full-shot | zero-shot |
| Model | RoBERTa-base (123M) | RoBERTa-base (123M) |
| Model selection | last | last |
| Batch size | 32 | 32 |
| Optimizer | adam | adam |
| Learning rate | 1.00e-05 | 1.00e-05 |
| LR schedule | 6% warmup with linear decay | 6% warmup with linear decay |
| Adam epsilon | 1.00e-08 | 1.00e-08 |
| Adam β1 | 0.9 | 0.9 |
| Adam β1 | 0.999 | 0.999 |
| Weight decay | 0 | 0 |
| Classifier dropout | 0 | 0 |
| Attention dropout | 0.1 | 0.1 |
| Hidden dropout | 0.1 | 0.4 |
| Max steps | - | 5000 |
| Max epochs | 3 | - |
| Batch sampler | - | inverse class frequency weighted sampling |
+
+Table 10: Hyperparameters for full-shot finetuning and zero-shot finetuning with the mined dataset.
+
+ | maj | Full-shot tuning | Prompting | Mining |
| single-verb | multi-verb | single-verb | multi-verb | + filter full-shot | zero-shot |
| Sentiment Analysis |
| Amazon | 50.0 | 97.1±0.0 | 81.5 | 83.5 | 71.7±2.2 | 90.6±1.7 | 94.4±0.2 | 92.0±0.6 |
| IMDB | 50.0 | 95.7±0.0 | 78.4 | 81.8 | 78.2±0.5 | 83.0±4.1 | 91.6±0.4 | 86.7±1.3 |
| MR | 50.0 | 88.8±0.1 | 71.1 | 78.3 | 70.5±1.0 | 77.7±2.4 | 86.3±0.7 | 80.5±1.0 |
| SST-2 | 50.9 | 94.4±0.2 | 77.4 | 77.4 | 77.3±1.4 | 83.8±2.4 | 89.5±0.7 | 85.6±1.1 |
| Yelp | 50.0 | 95.0±0.1 | 81.9 | 83.1 | 62.1±2.3 | 92.0±2.2 | 95.2±0.6 | 92.0±1.5 |
| avg | 50.2 | 94.2 | 78.1 | 81.7 | 72.0 | 85.4 | 91.4 | 87.4 |
| Topic Classification |
| AGNews | 25.0 | 95.1±0.1 | 34.0 | 54.6 | 71.0±0.7 | 78.4±0.6 | 89.5±0.2 | 79.2±0.6 |
| DBPedia | 7.1 | 99.3±0.0 | 36.4 | 51.1 | 63.7±1.0 | 79.8±0.0 | 97.1±0.3 | 80.4±0.4 |
| Yahoo | 10.0 | 76.8±0.1 | 28.2 | 34.1 | 51.7±0.5 | 56.3±2.5 | 69.8±0.1 | 56.1±2.1 |
| avg | 14.0 | 90.4 | 32.9 | 46.6 | 62.1 | 71.5 | 85.5 | 71.9 |
| NLI |
| MNLI | 35.3 | 78.50.0 | 47.1 | 46.5 | 48.2±0.5 | 49.2±0.5 | 65.5±0.3 | 50.4±0.4 |
| QNLI | 50.5 | 92.6±0.1 | 50.8 | 58.2 | 51.6±0.3 | 52.9±1.2 | 70.2±1.1 | 53.2±0.6 |
| RTE | 52.7 | 67.6±1.4 | 52.3 | 61.4 | 55.0±0.2 | 61.1±2.1 | 57.8±1.3 | 62.6±0.9 |
| SNLI | 34.3 | 90.5±0.1 | 39.6 | 44.1 | 38.0±0.7 | 44.6±0.9 | 61.9±2.8 | 46.0±1.1 |
| avg | 41.6 | 82.3 | 47.5 | 52.5 | 48.2 | 52.0 | 63.8 | 53.0 |
| macro avg | 38.6 | 89.3 | 56.6 | 63.2 | 61.6 | 70.8 | 80.7 | 72.1 |
+
+Table 11: Complete results for each task and system. When applicable, results show fine-tuning average performance and standard deviation over 3 seeds. Full-shot shows the fine-tuning results with the hyperparameters described in Table 10. Prompting shows the single and multi-verbalizer baseline results. Mining results show single and multi-verbalizer performance without filtering, in addition to multi-verbalizer performance with full-shot and zero-shot filtering. Maj: majority baseline
+
+ | Amazon | IMDB | MR | SST-2 | Yelp | avg |
| Prompting |
| good / bad | 81.5 | 78.4 | 71.1 | 77.3 | 81.9 | 78.1 |
| great / awful | 82.9 | 82.7 | 80.8 | 82.6 | 82.6 | 82.3 |
| awesome / terrible | 84.5 | 82.0 | 78.3 | 82.8 | 84.0 | 82.3 |
| incredible / horrible | 86.6 | 83.5 | 78.0 | 80.0 | 87.2 | 83.1 |
| combined | 83.5 | 81.8 | 78.3 | 81.9 | 83.1 | 81.7 |
| Mining |
| good / bad | 71.7±2.2 | 78.2±0.5 | 70.5±1.0 | 77.3±1.4 | 62.1±2.3 | 72.0 |
| great / awful | 88.4±1.7 | 75.7±4.0 | 73.0±2.5 | 79.8±2.1 | 93.3±0.5 | 82.1 |
| awesome / terrible | 91.4±0.6 | 81.3±1.4 | 73.7±1.6 | 78.8±1.3 | 94.3±0.7 | 83.9 |
| incredible / horrible | 90.5±0.2 | 88.1±0.2 | 80.5±1.0 | 83.5±0.6 | 94.0±0.4 | 87.3 |
| combined | 90.6±1.7 | 83.0±4.1 | 77.7±2.4 | 83.8±2.4 | 92.0±2.2 | 85.4 |
+
+Table 12: Verbalizer comparison for sentiment tasks. For mining, we report average performance and standard deviation over 3 seeds without filtering.
+
+| Pattern | Verbalizer | Amazon | IMDB | MR | SST-2 | Yelp | avg |
| Prompting | | | | | | | |
| {VERBALIZER} stars: {INPUT} | 5/1 | 50.4 | 50.0 | 50.0 | 50.9 | 53.7 | 51.0 |
| {INPUT} I {VERBALIZER} it. | love/hate | 77.6 | 73.3 | 64.6 | 69.8 | 80.3 | 73.1 |
| {INPUT} It is {VERBALIZER}. | good/bad | 81.5 | 78.4 | 71.1 | 77.4 | 81.9 | 78.1 |
| Mining | | | | | | | |
| {VERBALIZER} star*. {INPUT} | 5/1 | 68.7±0.4 | 75.4±2.1 | 70.8±1.7 | 78.3±2.4 | 67.5±5.3 | 72.1 |
| i {VERBALIZER}*. {INPUT} | love/hate | 88.9±0.3 | 84.0±1.2 | 79.2±0.8 | 84.0±0.8 | 91.1±0.7 | 85.5 |
| (is|was) {VERBALIZER}*. {INPUT} | good/bad | 71.7±2.2 | 78.2±0.5 | 70.5±1.0 | 77.3±1.4 | 62.1±2.3 | 72.0 |
+
+Table 13: Template comparison. Performance for three different templates on sentiment tasks comparing prompting and mining without filtering. Additionally, we show standard deviations over three seeds for the mining approach. The verbalizer column shows the verbalizer for the positive and the negative class, respectively.
+
+ | Default dropout | High dropout |
| full-shot | zero-shot | full-shot | zero-shot |
| Sentiment Analysis |
| Amazon | 95.8±0.0 | 91.0±0.4 | 94.4±0.2 | 92.0±0.6 |
| IMDB | 94.4±0.2 | 80.1±4.0 | 91.6±0.4 | 86.7±1.3 |
| MR | 88.0±0.2 | 76.5±1.1 | 86.3±0.7 | 80.5±1.0 |
| SST-2 | 92.0±0.5 | 80.2±1.6 | 89.5±0.7 | 85.6±1.1 |
| Yelp | 96.6±0.1 | 94.4±0.6 | 95.2±0.6 | 92.0±1.5 |
| avg | 93.3 | 84.4 | 91.4 | 87.4 |
| Topic Classification |
| AGNews | 90.8±0.2 | 77.2±1.0 | 89.5±0.2 | 79.2±0.6 |
| DBPedia | 98.8±0.0 | 83.9±0.4 | 97.1±0.3 | 80.4±0.3 |
| Yahoo | 72.9±0.1 | 56.6±2.4 | 69.8±0.1 | 56.1±2.1 |
| avg | 87.5 | 72.5 | 85.5 | 71.9 |
| NLI |
| MNLI | 77.7±1.0 | 52.9±0.8 | 65.5±0.3 | 50.4±0.4 |
| QNLI | 77.0±1.6 | 57.8±0.9 | 70.2±1.1 | 53.2±0.6 |
| RTE | 72.3±1.1 | 61.4±2.9 | 57.8±1.3 | 62.6±0.9 |
| SNLI | 80.2±0.2 | 49.4±1.0 | 61.9±2.8 | 46.0±1.1 |
| avg | 76.8 | 55.4±0.4 | 63.8 | 53.0 |
| macro avg | 86.4 | 71.8 | 80.7 | 72.1 |
+
+Table 14: Performance with high dropout and default dropout. These results use our proposed mining method + filtering and compares 2 settings of the hidden layer dropout: the default setting of 0.1 and the high regularization setting of 0.4, the value that was found most effective during development experiments on AGNews and SST-2.
+
+ | Averaging | Max | Sum |
| Sentiment Analysis |
| Amazon | 83.5 | 82.7 | 83.5 |
| IMDB | 81.8 | 81.2 | 82.1 |
| MR | 78.3 | 77.4 | 78.3 |
| SST-2 | 81.9 | 81.3 | 81.9 |
| Yelp | 83.1 | 82.3 | 83.1 |
| Topic Classification |
| AGNews | 54.6 | 53.4 | 54.6 |
| DBPedia | 51.1 | 49.1 | 51.4 |
| Yahoo | 34.1 | 34.1 | 34.1 |
| NLI |
| MNLI | 46.5 | 46.4 | 47.0 |
| QNLI | 58.2 | 58.4 | 57.4 |
| RTE | 61.4 | 61.7 | 60.6 |
| SNLI | 44.1 | 42.8 | 43.7 |
+
+Table 15: Results for different probability aggregation functions for multi-verbalizer prompting.
+
+ | Full-shot | Prompting |
| Sentiment Analysis |
| Amazon | 68.7 | 63.6 |
| IMDB | 64.5 | 63.6 |
| MR | 66.1 | 63.6 |
| SST-2 | 66.7 | 63.6 |
| Yelp | 69.1 | 63.6 |
| Topic Classification |
| AGNews | 52.3 | 31.8 |
| DBPedia | 25.7 | 13.4 |
| Yahoo | 36.4 | 22.2 |
| NLI |
| MNLI | 39.2 | 42.0 |
| QNLI | 52.7 | 62.2 |
| RTE | 50.3 | 62.2 |
| SNLI | 40.8 | 42.0 |
+
+Table 16: Label agreement. Percentage of examples for which the mined label is equal to the label predicted by a full-shot model or by single-verbalizer prompting.
+
+| # | Mined Label | Mined Example |
| 1 | Negative | So I bought this unit, which said it had the same technical features as the other brand, such as number of channels etc, and this one performed amazing!! |
| 2 | Positive | The founders of Clickfunnels have focused not only on creating a great internet site for you yet also offering you enough expertise and details to act as an informed company person / entrepreneur. |
| 3 | Positive | Once home, we began priming. |
| 4 | Negative | While you can’t view the content on the second page without either logging in or signing up since there’s no ‘x’ button, there’s a trick involving 3D Touch that can help. |
| 5 | Positive | That isavored them a long way a great deal more compared to My spouse and i believed i would certainly. |
| 6 | Positive | Do you have an idea of how broad your vocal range was? |
| 7 | Positive | Also recently the lovely Megan Washington modelled for our latest transeasonal collection we just shot last week. |
| 8 | Positive | What are 3 things that make you happy? |
| 9 | Positive | Be devoted to one another in love. |
| 10 | Negative | An unexpected situation arose with my father requiring help for three to four months. |
| 11 | Positive | Simply AWESOME! |
| 12 | Negative | I don’t disagree with that, however the voices have never been as loud or as many as now about this topic of “anti TPS”, that is progress, that is a movement, that is what we need to inspire EA to finally listen and do something about it. |
| 13 | Positive | Adverse drug reactions are based on evaluation of data from pre-marketing phase 2-3 studies and updated based on pooled data from 18 placebo-controlled pre- and post-marketing studies, including approximately 5,000 patients treated with varenicline. |
| 14 | Negative | I have the books from last year and have spoke to the college to get this years as they may be changing to another type. |
| 15 | Negative | I was down-to-my-core terrified. |
| 16 | Negative | He didn’t win, and our support of him became rather limited when we determined he was not winning. |
| 17 | Positive | It was in a four-star hotel in the Boca Raton Resort Bungalows. |
| 18 | Positive | I wish my preschool was this nice. |
| 19 | Negative | People in Wall Street and other financial services firms should have paid more attention to the data. |
| 20 | Positive | I guess I am quite transparent. |
+
+Table 17: Random sample of mined examples for sentiment analysis.
+
+| # | Mined Label | Mined Premise | Mined Hypothesis |
| 1 | Neutral | When seniors and their caregivers develop and enjoy deep friendships, it can bolster feelings of well-being, happiness and security. | it can help to make activities like exercising and healthy eating more enjoyable. |
| 2 | Contradiction | Customer service skills training for staff should include basic customer service skills of active listening, how to handle difficult situations, telephone etiquette, and interpersonal communication tips. | most of all, it should focus on how to build a relationship with a student. |
| 3 | Entailment | The easy way to remember the arrhythmias most commonly associated with SSS — is to think of what one might expect if the SA node became "sick". | there is sinus bradycardia and arrhythmia — sinus pauses (which may be longlasting, ultimately leading to sinus arrest) — and SA nodal block. |
| 4 | Contradiction | Primarily due to President Obama's historic announcement, more Americans are visiting Cuba, making a bad situation worse. | for those of you with the ability to book your Cuban Rent A Car in advance, all the above official websites still offer availability at the writing of this article. |
| 5 | Neutral | In 1989, Tufts University School of Medicine created the Minority High School Tutorial PLUS Program to provide local minority / disadvantaged students with access to medical student tutors. | in 1989, Tufts University School of Medicine received a grant from the National Institutes of Health (NIH) to start the Minority High School Research Apprenticeship Program. |
| 6 | Contradiction | In fact, regardless of the cost escalations on those other projects, legislators are doing their job by showing such prudence here. | when all is said and done, the legislature should approve the project aimed at repairing and upgrading seats and improving lighting and drainage at the facility. |
| 7 | Entailment | Also, this is the root of consciousness, because consciousness, awareness needs an opposite, a counterpart, a border, to awake at. | consciousness is a form of pain, originally, definitely. |
| 8 | Contradiction | Does Amaryl cause hair loss? | the use of Amaryl does not cause hair loss. |
| 9 | Entailment | "Golay has got no serious issues. | he is resorting to such statements for cheap popularity," remarked Bhim Dahal, the spokesperson of ruling Sikkim Democratic Front (SDF). |
| 10 | Neutral | The point is, it has to go. | I'll be removing a lot of the buttons in favor of textual links, and will probably replace them with a single button promoting Firefox. |
| 11 | Contradiction | Most of the times precisely originating from a sincere analysis of the weaknesses, the tension field between opposites and the assembling of cross-functional teams, through the clash of diverse approaches and views, the influence of "career changers" from other fields, and openness towards the new, the unorthodox, the unpredictable. | without diminishing the importance of diversity, togetherness is what produces the most overwhelming feeling of success. |
| 12 | Entailment | Beef and poultry safety tips are essential to follow. | an effective and healthy way to lose weight is to get regular exercise and harmful toxins, as soon as you have to eat properly. |
| 13 | Neutral | One vehicle that is widely chosen is a motorbike to carry out daily activities. | the matic motor is very easy to operate. |
| 14 | Entailment | Storage companies are often located near major travel routes to make it easier for customers to access the facility. | you may see signs for local rental companies in your area at the side of the motorway, or major routes near your location. |
| 15 | Entailment | Connecting with people about a negative experience often equates to a positive outcome. | I've decided to list all the 'abnormal' things I do but wouldn't usually talk about. |
| 16 | Entailment | A smile does go a long way! | March 13, coming soon. |
| 17 | Contradiction | Accordingly, it is a cultural taboo to affirm, "I am Love," which is our Authentic Self, the Immanent Divine Essence that we all share. | the Rishis who wrote the Upanishads realized that Brahman and Atman — as the Absolute and Self, respectively — are One, declaring Tat tvam asi You are That. |
| 18 | Contradiction | In these countries, ceramic proppants are used mainly in wells with higher closure pressures and other challenging environments. | ceramic proppants are the leading proppant type in the Chinese and Russian markets. |
| 19 | Contradiction | Given her recent prognosis and the fact that she DOES drive us mental with her meltdown and seemingly erratic behaviour sometimes, I really need to count to 10 and not lose my rag with her more than I do. | with her reaction to breakfast this morning and subsequent meltdown, I don't think I could have chosen a more difficult resolution... |
| 20 | Entailment | The Best Khao Soi in Chiang Mai, Thailand, is in a Mall! | I said it ... the best Khao Soi in Chiang Mai, Thailand, is in Central Airport Plaza Mall. |
+
+Table 18: Random sample of mined examples for NLI.
\ No newline at end of file
diff --git a/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/images.zip b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..f481f0738e6652b14142121b799b926b5a7bebe5
--- /dev/null
+++ b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6bbc10c26bb221b65e965ceb37dae6210f6323ebcf4c7e4d7a11a41e06ecdf8d
+size 1545782
diff --git a/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/layout.json b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..98e57201122ce904c0cb6b1faab37f24235197db
--- /dev/null
+++ b/dontpromptsearchminingbasedzeroshotlearningwithlanguagemodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ff54e0a331e1a12affbee151a0db07bd219a6e2c852c17fb92776068c7743de4
+size 298360
diff --git a/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_content_list.json b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..37d025a68ba06a2e1c358edc9a14e12fbcdda5f5
--- /dev/null
+++ b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a02909d148f9d73909e1ee26d220793901cea8672630561ae32efb504d5b1463
+size 141773
diff --git a/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_model.json b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..41dbe5ce2172c0bcd5f5d5171bc5a59e8f91ce24
--- /dev/null
+++ b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ac0f290010b7121cff7c868c2951ce3639054ca6b1fab47dcc429707167fbe98
+size 157698
diff --git a/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_origin.pdf b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..bca9bcc06f3ead608d477009251ab64c4bf0d5bc
--- /dev/null
+++ b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/862adabe-667b-4894-8073-2419a3185881_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:7556a2df7fb1c4738cbeba0c6cf9f22dd72d1dc7cdef3a501e02dac2f70643bd
+size 1577862
diff --git a/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/full.md b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..3aded1aa09507cfc978ed5904a302e02c0b3b724
--- /dev/null
+++ b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/full.md
@@ -0,0 +1,262 @@
+# Don’t Stop Fine-Tuning: On Training Regimes for Few-Shot Cross-Linguual Transfer with Multilingual Language Models
+
+Fabian David Schmidt1, Ivan Vulić2,3, Goran Glavaš1
+
+1 Center For Artificial Intelligence and Data Science, University of Würzburg, Germany
+
+$^{2}$ Language Technology Lab, University of Cambridge, UK $^{3}$ PolyAI Ltd., UK
+
+{fabian.schmidt, goran.glavas}@uni-wuerzburg.de
+
+iv250@cam.ac.uk
+
+# Abstract
+
+A large body of recent work highlights the fallacies of zero-shot cross-lingual transfer (ZS-XLT) with large multilingual language models. Namely, their performance varies substantially for different target languages and is the weakest where needed the most: for low-resource languages distant to the source language. One remedy is few-shot transfer (FS-XLT), where leveraging only a few task-annotated instances in the target language(s) may yield sizable performance gains. However, FS-XLT also succumbs to large variation, as models easily overfit to the small datasets. In this work, we present a systematic study focused on a spectrum of FS-XLT fine-tuning regimes, analyzing key properties such as effectiveness, (in)stability, and modularity. We conduct extensive experiments on both higher-level (NLI, paraphrasing) and lower-level tasks (NER, POS), presenting new FS-XLT strategies that yield both improved and more stable FS-XLT across the board. Our findings challenge established FS-XLT methods: e.g., we propose to replace sequential fine-tuning with joint fine-tuning on source and target language instances, offering consistent gains with different number of shots (including resource-rich scenarios). We also show that further gains can be achieved with multi-stage FS-XLT training in which joint multilingual fine-tuning precedes the bilingual source-target specialization.
+
+# 1 Introduction and Motivation
+
+Successful fine-tuning of mainstream pre-trained language models (Devlin et al., 2019; Liu et al., 2019; Conneau et al., 2020) for various NLP tasks requires a sizeable set of labeled task-specific instances. While such abundant task data are available for many tasks in English and a few high-resource languages, annotated examples are much scarcer for low-resource languages (Joshi et al., 2020). A large body of recent work thus focused on zero-shot cross-lingual transfer (ZS-XLT), for which no labeled instances are available in the tar
+
+get language (Pires et al., 2019; Cao et al., 2020). Catalyzed by pretrained massively multilingual transformers (MMT) such as mBERT (Devlin et al., 2019), XLM-R (Conneau et al., 2020), or mT5 (Xue et al., 2021), zS-XLT has achieved impressive results on a wide variety of tasks (Hu et al., 2020; Ruder et al., 2021). The MMT-driven zS-XLT, however, exhibits dramatic performance drops when transferring to low-resource languages and/or languages distant from the source language (Lauscher et al., 2020; Ebrahimi et al., 2021; Adelani et al., 2021, inter alia). In contrast, recent work highlights that language models are excellent few-shot learners (Brown et al., 2020; Gao et al., 2021): they adapt well to new tasks or languages when exposed to only on a handful of labeled instances.
+
+For cross-lingual transfer in particular, sequential few-shot transfer (FS-XLT) – in which large(r)-scale fine-tuning in the source language is followed by the secondary fine-tuning on a few target language instances – has been rendered particularly effective, with massive performance gains reported for some tasks with as little as 10 target language instances (Lauscher et al., 2020; Zhao et al., 2021). However, the effectiveness of sequential FS-XLT crucially depends on the shot selection (Zhao et al., 2021). Even more concerning, as we show in §3, is the sensitivity of FS-XLT to hyperparameter values, most notably the duration (number of epochs) of few-shot target language training: such fluctuations are problematic for true few-shot learning (Perez et al., 2021), where target language validation data, to be leveraged for model selection, does not exist.
+
+Contributions. In this work, we shed new light on FS-XLT and seek to remedy the above pitfalls of current FS-XLT method. We depart from the established sequential FS-XLT paradigm and propose new training regimes for FS-XLT, comparing them across the dimensions of effectiveness, stability, and modularity. Concretely, we propose training regimes that jointly exploit source and target
+
+language instances, and allow to model their interaction. 1) We demonstrate, both for higher-level semantic tasks (e.g., NLI) and lower-level token-level tasks (NER, POS tagging), that joint source and target language training 'feeds two birds with one scone': (i) it consistently improves FS-XLT performance, even in setups with a larger number of target-language shots (e.g., $N = 500$ ), and (ii) makes the training procedure much more stable and robust, allowing for a reliable selection of the model checkpoint in true few-shot transfer setups without a target-language validation set. 2) We find that preceding the joint bilingual fine-tuning with a multilingual training step, in which we combine the shots from multiple target languages, brings further performance gains. We also show that such multistage training regime improves the computational efficiency in multilingual FS-XLT setups, i.e., when the model transfer to multiple target languages is required. 3) Finally, we validate that benefits of the new FS-XLT training regimes are not limited to English as the source language. Our work fundamentally challenges the status quo in FS-XLT and introduces and compares training paradigms that enable more effective, more efficient, and much more robust few-shot cross-lingual transfer.
+
+Concurrent (closely related) effort. The concurrent work of Xu and Murray (2022) similarly demonstrates the utility of joint multilingual FS-XLT: although their joint fine-tuning approach differs from ours – they employ gradient surgery (Yu et al., 2020), an approach that harmonizes competing gradients originating from instances of different languages in a training batch – it yields the same two main benefits: (1) improved target language performance and (2) more stable training that facilitates models selection (i.e., alleviates the need for target-language validation data).
+
+# 2 Background and Related Work
+
+MMTs like mBERT and XLM(-R) (Lample and Conneau, 2019; Conneau et al., 2020) have become the main vehicles of cross-lingual transfer. Pretrained on multilingual corpora covering $100+$ languages, MMTs conceptually enable zero-shot cross-lingual transfer (ZS-XLT) between any two languages seen in pretraining (Hu et al., 2020) or even to unseen languages (Ansell et al., 2021). The (extent of) ZS-XLT success depends on the quality and alignment of the representation subspaces of individual languages (Cao et al., 2020; Hu et al.,
+
+2021; Wu and Dredze, 2020). Accordingly, zS-XLT with MMTs tends to be ineffective in transfers to target languages that are (i) linguistically distant from the source language and especially those (ii) un(der)represented in MMT's pretraining (Hedderich et al., 2020; Lauscher et al., 2020; Ruder et al., 2021; Ebrahimi et al., 2021).
+
+One line of work boosts ZS-XLT by improving semantic alignment between the representation subspaces of individual languages, exploiting to this end available word or sentence translations (Hu et al., 2021; Wu and Dredze, 2020; Yang et al., 2022). Another, complementary line of work improves ZS-XLT through increasing the MMT's capacity for individual languages (Pfeiffer et al., 2020, 2022; Ansell et al., 2021, 2022). It attempts to remedy for the "curse of multilinguality" (Conneau et al., 2020) – an effect where, for a fixed model capacity, the quality of representations of individual languages at some point starts degrading with the addition of more languages.
+
+Unlike the above efforts, which improve the MMTs' representation space in a task-agnostic fashion, FS-XLT assumes a handful of labeled task-specific examples in the target language(s) (Hedderich et al., 2020; Lauscher et al., 2020; Zhao et al., 2021). Lauscher et al. (2020) propose sequential FS-XLT: fine-tuning on few target-language instances follows the initial fine-tuning on sizable source language data. They show that FS-XLT brings the largest gains exactly where ZS-XLT fails the most: for target languages distant from the source and underrepresented in pretraining. In follow-up work, Zhao et al. (2021) demonstrate that FS-XLT is highly sensitive to the choice of shots. Both studies show the effectiveness of few-shot transfer to be subject to nature of the task: lower-level syntactic and token-level tasks (e.g., POS-tagging, NER) benefit much more from few annotated target language instances than higher-level semantic tasks (e.g., NLI).
+
+The evaluation protocols of both Lauscher et al. (2020) and Zhao et al. (2021), however, do not reflect a true few-shot setup: they assume that substantial validation data in the target language exists and utilize it to guide model selection (hyperparameter optimization and early stopping). As such, these works overestimate the effectiveness of true FS-XLT: while focused only on monolingual setups, Perez et al. (2021) demonstrate that model selection criteria based on training data alone yield
+
+
+Figure 1: FS-XLT to AmericasNLI and WikiANN with $\{10,50,100\}$ shots after training on English data (cf. §4). The line plots the mean (incl. $\pm 1\sigma$ ) test set spread (in %) of best validation and current checkpoint. Runs across 3 seeds by language are grouped by colored dots that mark epochs scoring best on validation sets.
+
+consistently worse few-shot task performance than model selection based on an extra validation set.
+
+In this work, we rethink FS-XLT and propose novel FS-XLT paradigms that jointly leverage both (sizable) source and (few-shot) target language data in multi-task fashion or via mix-up (Zhang et al., 2018), and demonstrate their effectiveness as well as robustness in realistic (i.e., true) FS-XLT setups.
+
+# 3 Methodology
+
+Issues with Current FS-XLT Methods. Figure 1 illustrates the main issues of current FS-XLT techniques, adopting the established sequential approach (Lauscher et al., 2020; Zhao et al., 2021; Üstün et al., 2022). In this experiment, we adapt models fine-tuned on sizable English task-specific data with \{10,50,100\} target-language shots to AmericasNLI (Ebrahimi et al., 2021) and WikiANN (NER) (Rahimi et al., 2019) (see §4). We execute three FS-XLT runs for each target language with different randomly selected shots and examine the test performance over time, displaying the mean and deviation $(\pm 1\sigma)$ across all languages and runs for different training duration (i.e., for $\{1,\ldots ,50\}$ epochs of target language training). The gray horizontal line denotes the optimal performance (average across all languages and runs) in the presence of a target language validation set (i.e., 'not-true' few-shot learning): for each run, we select the checkpoint that yields the best validation performance. Individual runs are denoted
+
+with colored dots, each color indicating one target language. Each dot is vertically aligned with the epoch/checkpoint of the respective run (x-axis) that yields the best validation performance.
+
+The figure reveals the instability of sequential FS-XLT. 1) The optimal epoch/checkpoint varies across all dimensions of analysis: number of shots, tasks, and languages. Besides the expected result that, on average, with more shots we benefit from longer training, no discernible pattern emerges. 2) The optimal training duration substantially varies even across different runs of the same language, that is, for different random selections of $N$ shots (and even for larger number of shots, $N = 500$ , cf. Figure 2 later in §5.1). These observations render sequential FS-XLT highly unreliable for the true FS-XLT setups without target validation data.
+
+New FS-XLT Training Methods. Motivated by these empirical insights, we explore new FS-XLT paradigms, aiming to increase robustness and effectiveness in true FS-XLT setups. Our hypothesis is that combining abundant source-language task examples with scarce target examples in a joint fashion will 1) prevent the models to overfit to source-language features (see Figure 1), 2) also prevent overfitting to an (extremely) small set of target-language shots (Zhao et al., 2021), and 3) result in the models that are better calibrated for a particular source-target transfer direction. The FS-XLT methods should model the interaction between source and target examples, rather than performing source-language fine-tuning which is fully agnostic of the target language (and vice versa).
+
+The first approach, dubbed 'macro-averaging FS-XLT' (MACRO), conducts bilingual or multilingual fine-tuning in a joint (i.e., multi-task) setup. In particular, we compute the total loss $\mathcal{L} = \delta \mathcal{L}_S + (1 - \delta)\mathcal{L}_T$ as a weighted sum of $\mathcal{L}_S$ and $\mathcal{L}_T$ , where $\mathcal{L}_S$ and $\mathcal{L}_T$ are monolingual losses associated with the examples from the source language $S$ and the target language $T$ , respectively. $\delta$ is a standard interpolation hyper-parameter that adjusts the relative weight between the two losses. The two individual losses operate over the dedicated mini-batches $B_{S} = \{x_{i}^{s},y_{i}^{s}\}_{i = 1,\dots ,N}$ and $B_{T} = \{x_{j}^{t},t_{j}^{t}\}_{j = 1,\dots ,M}$ , which are sampled from the respective source and target language datasets
+
+$D_{S}$ and $D_{T}$ . $N$ and $M$ in combination determine the size $|B|$ of the entire mini-batch, as well as the relative share of samples for each language within the mini-batch. The generalization of the bilingual MACRO FS-XLT method (MACRO-BI) to its multilingual variant (MACRO-MULTI) is straightforward: each multilingual batch $B$ would simply comprise examples from more than 2 languages, and the joint loss will span more than 2 language-specific losses.
+
+The second paradigm is based on the standard mix-up technique (Zhang et al., 2018). It has been proven beneficial for improving task performance and robustness in monolingual tasks; here, we extend it to the cross-lingual FS-XLT scenario. This method, termed MIX-UP, linearly interpolates between pairs of annotated instances from the source and the target language as follows:
+
+$$
+\tilde {x} _ {s, t} = \lambda x _ {i} ^ {s} * (1 - \lambda) x _ {j} ^ {t}; \quad \tilde {y} _ {s, t} = \lambda y _ {i} ^ {s} * (1 - \lambda) y _ {j} ^ {t}
+$$
+
+$\lambda \sim Beta(\alpha)$ weighs the contribution between instances $(x_i^s, y_i^s)$ and $(x_j^t, y_j^t)$ . Each instance $(x_b, y_b) \in B$ can be paired with any other instance with varying $\lambda$ . We opt to randomly pair instances in $B_S$ and $B_T$ to be 'mixed', and keep $\alpha$ constant. The fine-tuning loss $\mathcal{L}$ is then computed via soft cross-entropy: $\sum_{b}^{|B|/2} \tilde{y}_b \log \tilde{y}_b$ . Cross-lingual MIX-UP can be interpreted as 'soft' code switching, occurring in the latent representation space: it should enhance FS-XLT by further tying, in a task-specific fashion, the representation subspaces of the two languages, as the model is trained for the task on 'mixed' representations, rather than independent language-specific distributions (Cao et al., 2020; Yang et al., 2022).
+
+Overview of FS-XLT Training Methods. Besides introducing novel methods, the main goal of this work is a comprehensive empirical comparative study of different FS-XLT training methods/regimes. For clarity, we provide a quick overview of the wide spectrum of evaluated regimes and configurations. First, models may be trained on target language shots after training on the source language data. This approach, termed TARGET, is the standard sequential FS-XLT from prior work (Lauscher et al., 2020; Zhao et al., 2021). The alternative is the regime that combines source-language and target-language data instances, termed SOURCE-TARGET, which comes in two different flavors: our proposed
+
+joint MACRO and MIX-UP paradigms. The second axis of difference is the starting point of TARGET or SOURCE-TARGET FS-XLT: we can start fine-tuning from 1) the original PLM (termed LM henceforth), or 2) from the final/last checkpoint of source-language task fine-tuning (termed LAST), or 3) the ORACLE checkpoint. ORACLE violates the true FS-XLT: it refers to the model checkpoint that achieves the best performance on the target language validation set, measured after each epoch of source language training (Keung et al., 2020). We include ORACLE for analysis purposes.
+
+# 4 Experimental Setup
+
+Tasks and Languages. Following prior studies focused on FS-XLT (Lauscher et al., 2020; Zhao et al., 2021), we evaluate all the methods in a representative set of tasks that require varying degrees of semantic and syntactic understanding for successful cross-lingual transfer.
+
+Natural Language Inference (NLI). NLI experiments are conducted on AmericasNLI (AmNLI) (Ebrahimi et al., 2021): it encompasses indigenous target languages from the Americas, with data carefully translated from the Spanish XNLI dataset (Conneau et al., 2018). Unless stated otherwise, the source is English, and we transfer to the following 7 target languages with sizable NLI data available: Aymara (AYM), Bribri (BZD), Guarani (GN), Quechua (QU), Raramuri (TAR), Shipibo-Konibo (SHP), Wixarika (HCH). For NLI, we jointly embed the hypothesis-premise sentence-pair, obtain the [CLS] token and feed it into the classifier.
+
+Paraphrasing. The paraphrasing task is conducted on the PAWS-X dataset (Yang et al., 2019), spanning parallel evaluation data for 6 high-resource languages: German (DE), Spanish (ES), French (FR), Korean (KO), Japanese (JA), and Chinese (ZH). We train classifiers in the same fashion as classifiers for NLI, now only with paraphrase pairs.
+
+Named Entity Recognition (NER). We use the WikiANN dataset of Pan et al. (2017), and evaluate cross-lingual transfer between English and the following 13 languages: Arabic (AR), Afrikaans (AF), German (DE), Japanese (JA), Quechuan (QU), Russian (RU), Kinyarwanda (RW), Swahili (SW), Tamil (TA), Urdu (UR), Vietnamese (UR), Yoruba
+
+(YO), Mandarin (ZH). For NER, we feed output representations of each token into the classifier.
+
+Part-Of-Speech Tagging (POS). We use the POS tags of the UD treebanks (Zeman et al., 2020) and transfer from English to the following 12 target languages: Afrikaans (AF), Arabic (AR), Basque (EU), Chinese (ZH), German (DE), Hindi (HI), Hungarian (HU), Indonesian (ID), Japanese (JA), Russian (RU), Tamil (TA), Urdu (UR). The model architecture is identical to NER experiments.
+
+Data Sampling and Shots. For AmNLI and PAWS-X, we subsample training and validation subsets from the provided validation splits.4 WikiANN and the Universal Dependencies treebank comprise sufficiently large training and validation splits; we subsample shots from the training data. We follow Lauscher et al. (2020) and train models with $k \in \{10, 50, 100, 250, 500\}$ target-language shots, fixed by task and language.5
+
+Training Details. The main MMT is the base variant of XLM-R from the transformers library (Wolf et al., 2020) with mixed precision. For all tasks, we train models with AdamW (Loshchilov and Hutter, 2019) with the learning rate fixed to $2e^{-5}$ and weight decay of 0.05. All models apply $10\%$ dropout to the output representations prior to the classification layer at training time. The maximal input sequence length is set to 256 subwords for AmNLI and PAWS-X, and 512 for NER and POS. zS-XLT and SOURCE-TARGET variants are trained for 10 epochs with the linear warm-up rate of 0.1 and linear decay. We fine-tune TARGET regimes for 50 epochs with a constant learning rate. We train in mini-batches of size 32: the SOURCE-TARGET regimes balance instances from source and target languages – for MACRO-BI, we sample 16 instances per language choose the language-balanced loss $(\delta = 0.5)$ ; MIX-UP interpolates between 32 pairs of instances between the languages, resulting with 32 ‘mixed’ bilingual examples. For MIX-UP,
+
+we keep $\alpha$ fixed to 0.4. $^{8}$ We run all experiments over three (fixed) random seeds. Further details on reproducibility are provided in Appendix A.1.
+
+Evaluation Details. We measure performance with accuracy on AmNLI and PAWS-X. For WikiANN and POS, we report the token-level $F_{1}$ score. We report both performance of final/last (L) and oracle (O) checkpoints to provide appropriate bounds on expected and ideal transfer performance.
+
+# 5 Results and Discussion
+
+The main results are listed in Table 1. Full results per individual target languages in each task are available in the Appendix. First, we corroborate the findings from prior work (Lauscher et al., 2020; Zhao et al., 2021), and report considerable gains with FS-XLT over ZS-XLT across the board and with different FS-XLT methods. We now dissect the results across multiple axes of comparison.
+
+Joint versus Sequential FS-XLT. In general, the joint (i.e., SOURCE-TARGET) FS-XLT variants score on-par or outperform the sequential (i.e., TARGET) variants, and the gains are observed both at Last and Oracle checkpoints. Moreover, we note that the scores taken at the L checkpoint with the joint variants across all setups are typically higher than the scores taken at the O checkpoint. This renders them more suitable for true FS-XLT scenarios, and clearly suggests that the proposed joint approaches remedy the issues with overfitting and allow for a more stable fine-tuning. We attribute this finding exactly to bilingual regularization and transfer calibration (see §3).
+
+Joint Methods: MACRO versus MIX-UP. The two joint methods typically yield very similar performance when all other components are kept equal, and fine-tuning starts from the LAST or the ORACLE checkpoint. MIX-UP data augmentation insignificantly affects performance. The effect is most apparent when comparing SOURCE-TARGET setups on the higher-level semantic tasks (AmNLI and PAWS-X), where the model must learn to embed sentence-pair semantics in the [CLS] token. To this end, both tasks require initial source-language fine-tuning as the LM variants lag substantially behind LAST and ORACLE which rely on the initial
+
+ | SOURCE | TARGET | SOURCE-TARGET |
| Zero-Shot | Few-Shot | MACRO | MIX-UP |
| Shots | LM | LAST | ORACLE | LM | LAST | ORACLE | LM | LAST | ORACLE |
| | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O |
| AmNLI | 10 | 39.6 | 40.0 | 38.3 | 39.9 | 38.4 | 41.2 | 34.9 | 36.0 | 38.0 | 38.1 | 37.4 | 38.6 | 35.1 | 35.4 | 37.9 | 39.4 | 37.2 | 38.3 |
| 50 | 39.6 | 40.0 | 43.8 | 43.3 | 44.0 | 43.6 | 40.6 | 42.5 | 44.4 | 44.4 | 44.4 | 45.0 | 39.8 | 40.6 | 44.0 | 44.5 | 44.8 | 45.0 |
| 100 | 39.6 | 40.0 | 45.8 | 45.0 | 46.3 | 46.2 | 44.1 | 44.9 | 46.8 | 46.6 | 47.9 | 47.5 | 43.8 | 44.3 | 47.4 | 47.0 | 47.7 | 47.7 |
| 250 | 39.6 | 40.0 | 49.7 | 49.5 | 49.8 | 49.4 | 48.4 | 49.2 | 51.0 | 51.2 | 51.4 | 51.0 | 48.4 | 49.0 | 51.5 | 50.6 | 51.7 | 51.3 |
| 500 | 39.6 | 40.0 | 51.7 | 52.0 | 52.0 | 51.2 | 51.8 | 52.5 | 53.3 | 52.9 | 53.8 | 53.4 | 52.3 | 51.6 | 53.2 | 53.2 | 53.1 | 53.1 |
| PAWS-X | 10 | 83.8 | 84.0 | 81.0 | 84.2 | 80.0 | 84.4 | 81.1 | 81.8 | 84.5 | 84.5 | 84.7 | 84.6 | 77.3 | 80.6 | 84.0 | 84.1 | 83.8 | 84.2 |
| 50 | 83.8 | 84.0 | 83.5 | 84.2 | 83.4 | 84.4 | 79.9 | 81.2 | 84.4 | 84.3 | 84.6 | 84.5 | 74.4 | 76.6 | 84.6 | 84.4 | 84.7 | 84.3 |
| 100 | 83.8 | 84.0 | 84.0 | 84.3 | 83.5 | 84.3 | 79.9 | 80.2 | 84.6 | 84.5 | 84.6 | 84.4 | 75.2 | 77.8 | 84.6 | 84.4 | 84.7 | 84.7 |
| 250 | 83.8 | 84.0 | 83.2 | 84.9 | 83.2 | 84.4 | 81.2 | 81.8 | 84.6 | 84.6 | 84.9 | 84.8 | 78.4 | 79.2 | 84.5 | 84.5 | 84.5 | 84.3 |
| 500 | 83.8 | 84.0 | 83.8 | 85.3 | 83.6 | 85.0 | 82.8 | 82.9 | 85.3 | 85.0 | 85.5 | 85.3 | 81.9 | 81.9 | 85.2 | 85.0 | 85.1 | 85.0 |
| NER | 10 | 52.5 | 60.0 | 60.7 | 63.3 | 61.0 | 64.3 | 63.9 | 65.1 | 64.9 | 65.8 | 64.9 | 66.2 | 64.2 | 65.1 | 63.9 | 65.1 | 64.3 | 65.6 |
| 50 | 52.5 | 60.0 | 72.0 | 72.3 | 72.6 | 73.1 | 72.8 | 73.5 | 73.1 | 73.1 | 73.1 | 73.6 | 73.2 | 73.6 | 72.9 | 73.4 | 73.2 | 73.5 |
| 100 | 52.5 | 60.0 | 73.6 | 74.5 | 74.4 | 74.7 | 75.5 | 75.7 | 75.4 | 75.5 | 75.3 | 75.2 | 75.8 | 75.8 | 74.9 | 75.4 | 75.4 | 75.5 |
| 250 | 52.5 | 60.0 | 75.6 | 76.5 | 76.0 | 76.7 | 77.1 | 77.3 | 77.0 | 77.1 | 76.9 | 77.1 | 77.4 | 77.4 | 76.9 | 76.9 | 77.0 | 77.1 |
| 500 | 52.5 | 60.0 | 77.4 | 78.6 | 77.6 | 78.7 | 79.2 | 79.3 | 79.0 | 79.0 | 79.2 | 79.2 | 79.5 | 79.5 | 78.9 | 78.9 | 79.0 | 79.0 |
| POS | 10 | 62.6 | 63.8 | 79.9 | 79.9 | 80.2 | 80.2 | 80.5 | 80.6 | 79.9 | 80.0 | 80.1 | 80.2 | 80.0 | 80.2 | 79.9 | 80.0 | 80.1 | 80.2 |
| 50 | 62.6 | 63.8 | 84.9 | 84.7 | 85.1 | 85.1 | 85.4 | 85.4 | 85.1 | 85.2 | 85.3 | 85.3 | 85.4 | 85.3 | 85.3 | 85.3 | 85.5 | 85.5 |
| 100 | 62.6 | 63.8 | 86.6 | 86.6 | 86.7 | 86.9 | 87.3 | 87.3 | 87.1 | 87.1 | 87.2 | 87.2 | 87.1 | 87.2 | 87.1 | 87.1 | 87.2 | 87.2 |
| 250 | 62.6 | 63.8 | 88.7 | 88.7 | 88.8 | 88.9 | 89.3 | 89.2 | 89.1 | 89.1 | 89.2 | 89.2 | 89.2 | 89.2 | 89.1 | 89.1 | 89.2 | 89.2 |
| 500 | 62.6 | 63.8 | 90.1 | 90.2 | 90.2 | 90.2 | 90.5 | 90.4 | 90.4 | 90.4 | 90.5 | 90.5 | 90.4 | 90.4 | 90.4 | 90.4 | 90.5 | 90.5 |
+
+Table 1: Benchmarking a spectrum of FS-XLT regimes (see §3). The results are averages over three random seeds, aggregated over all target languages represented in each task (see §4) Training and evaluation data are identical across all regimes in the evaluation. L (O) denote performance measured at last (oracle) checkpoint, see §4.
+
+source fine-tuning. MIXUP-LM is most beneficial for the token-level NER task, but does not yield sizeable gains on average over the arguably conceptually simpler MACRO paradigm.
+
+Starting Point of FS-XLT. Expectedly, starting FS-XLT from the ORACLE checkpoint typically yields better performance than starting from the LAST checkpoint. ORACLE, however, violates the assumption of a true FS-XLT setup: it uses the validation set in the target language to select a better checkpoint for additional FS-XLT fine-tuning, which is organically better-aligned with the target language. We note that the gap in performance between these two initializations slightly decreases in case of joint SOURCE-TARGET FS-XLT variants: this again points to improved robustness compared to sequential FS-XLT.
+
+Performance benefits with different FS-XLT regimes, naturally, depend on the task and target languages at hand. AmNLI starts profiting from FS-XLT only with $k \geq 50$ shots. The target languages in AmNLI are extremely low-resource and unseen in MMT pretraining: the model thus must see more target-language data points than, e.g., in NLI transfer to higher-resource languages from the XNLI benchmark (Lauscher et al., 2020). Our new SOURCE-TARGET variants again substantially outperform currently established FS-XLT methods, and we observe increasing returns with more shots. In contrast, performance on PAWS-X – which comprises only high-resource languages (see §4) – primarily
+
+benefits from the more robust joint FS-XLT regimes rather than from the increased number of shots. For NER and POS, we observe strong performance also with the LM initialization. We speculate that this is because class-conditional token representations align well with the representations from the original MMT pretraining; on the other hand, the models for NLI and paraphrasing must capture higher-level sentence semantics (via source-language fine-tuning) before the FS-XLT step.
+
+# 5.1 Further Analyses
+
+We base our further analyses and comparisons between sequential and joint approaches on the following two representative variants: TARGET-LAST and MACRO-LAST. They operate in the 'real-life' true FS-XLT scenarios without any validation data to guide few-shot learning (Perez et al., 2021).
+
+Stability of Transfer. Figure 2 compares stability of the two variants for $\{10,50,500\}$ shots (cf, Appendix A.2). It demonstrates that joint training substantially reduces instability and variance of FS-XLT fine-tuning across the board: we observe its increased robustness and stability across different tasks, languages, and the numbers of shots. The plots also illustrate that the joint regime in the true FS-XLT setup offers performance which is competitive and comes substantially closer to performance achieved when exploiting target-language validation set: this directly indicates that, with joint bilingual fine-tuning (MACRO) in place, any additional labeled instances in the target language
+
+
+Figure 2: FS-XLT regimes (joint MACRO versus sequential TARGET) starting from the LAST checkpoint of the initial source language fine-tuning step. The colored dots group runs for each seed by language and mark the checkpoints that transfer best to target-language validation data. The line plots the mean (incl. $\pm 1\sigma$ ) test set spread (in %) of best validation and current checkpoint.
+
+would be better "spent" if used for training than for validation. Relying on the joint MACRO variant, the best-performing checkpoints generally shift closer to the end of the training, which is a desired behavior in the absence of the validation set. In other words, the joint FS-XLT variants not only improve but also consistently make FS-XLT fine-tuning more stable and more predictable, that is, less prone to language- and task-dependent variations.
+
+Notes on Efficiency and Modularity. While the joint FS-XLT regimes improve final transfer performance, they are less modular by design and might incur larger computational costs than the sequential regimes. Namely, they require combining source-language and target-language instances for each individual source-target transfer direction, which is not the case in the sequential regimes. In what follows, we thus delve deeper into studying efficiency- and modularity-related research questions.
+
+Joint Multilingual and Multilingual-Bilingual MACRO. Given $N_{T}$ target languages, instead of fine-tuning $N_{T}$ separate bilingual models (MACRO-BI), we can, similar to Xu and Murray (2022), train a single joint multilingual model (MACRO-MULTI, see §3) which serves all $N_{T}$ at once. Such FS-XLT variant, besides potentially reducing computational and memory costs, might also profit from increased task data provided in multiple languages (Ansell et al., 2021). What is more, we can use the LAST checkpoint of the MACRO-MULTI as the starting point of the additional subsequent bilingual FS-XLT specialization (i.e., MACRO-BI). We denote this
+
+novel modular variant, where both steps are based on the joint FS-XLT paradigm, as MULTI $\rightarrow$ BI.
+
+Furthermore, we conduct another experiment, again focused on efficiency of joint FS-XLT finetuning, which includes all the different MACRO variants: (i) the original MACRO-BI, (ii) MACROMULTI, and (iii) MACRO-MULTI $\rightarrow$ BI. The goal is to investigate how the different joint paradigms perform under different computational budget constraints. To this end, we train those MACRO variants with $\{1,2,5,10\} \times$ the number of steps of the sequential TARGET variant.
+
+For the multilingual step, training is always conducted by including 8 instances for each language in a mini-batch: this is done to provide sufficient language-specific examples per mini-batch without dramatically increasing the mini-batch size. For AmNLI and PAWS-X, we include all available languages in training. For NER, we train on {DE, EN, SW, TA, VI, ZH}, and for POS on {AR, EN, EU, HU, ID, JA, UR}. We now evaluate all the MACRO and TARGET variants on the following languages: for AmNLI, AYM, QUY, and TAR; for PAWS-X, DE, KO, JA; for NER, SW, VI, ZH; for POS, EU, UR, JA.
+
+Table 2 presents the complete results of this set of experiments, averaged over the three target languages of each task. First, MACRO-MULTI is on-par or better than TARGET throughout almost all setups, but, with the exception of token-level tasks, does not consistently match the performance of MACRO-BI, which fine-tunes for a particular source-target direction. The highest overall performance is ob
+
+ | TARGET | SOURCE-TARGET (MACRO) | | | |
| TARGET BUDGET | | | |
| 1× | 2× | 5× | 10× | FT | | | |
| BI | MULTI - BI | BI | MULTI - BI | BI | MULTI - BI | BI | MULTI - BI | BI | MULTI - BI | BI | MULTI - BI | MULTI - BI | | | | |
| Shots | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | | | | |
| AmNLI | 10 | 36.8 | 38.8 | 36.3 | 36.9 | 37.6 | 38.5 | 36.7 | 37.7 | 38.1 | 38.3 | 36.2 | 36.7 | 37.1 | 37.9 | 36.3 | 36.8 | 36.5 | 37.6 | 36.3 | 37.7 | 36.5 | 37.1 | 37.4 | 35.9 | 36.7 | | |
| 50 | 43.4 | 42.6 | 45.6 | 46.2 | 42.6 | 41.9 | 44.4 | 44.9 | 42.4 | 42.1 | 44.8 | 44.7 | 42.7 | 43.1 | 45.4 | 45.7 | 42.6 | 43.4 | 45.2 | 45.2 | 44.4 | 45.1 | 43.7 | 44.7 | 45.8 | 45.5 | |
| 100 | 45.7 | 45.8 | 48.2 | 48.4 | 45.7 | 45.3 | 48.7 | 48.0 | 46.0 | 45.6 | 48.5 | 48.8 | 46.3 | 45.7 | 48.7 | 49.2 | 45.9 | 46.2 | 49.2 | 49.1 | 46.7 | 47.2 | 47.2 | 47.3 | 49.0 | 48.4 | |
| 250 | 50.4 | 50.2 | 52.3 | 52.3 | 48.4 | 47.6 | 52.2 | 52.4 | 49.4 | 49.3 | 52.7 | 53.0 | 49.7 | 48.9 | 52.9 | 52.6 | 50.5 | 50.4 | 53.0 | 52.6 | 52.0 | 51.9 | 51.0 | 50.7 | 52.8 | 52.6 | |
| 500 | 51.7 | 52.5 | 52.3 | 52.7 | 52.2 | 51.1 | 53.5 | 53.5 | 52.8 | 51.5 | 53.2 | 53.0 | 53.4 | 52.5 | 53.3 | 53.3 | 53.3 | 53.1 | 52.7 | 53.8 | 54.0 | 53.7 | 54.0 | 53.7 | 53.7 | 53.5 | |
| PAWS-X | 10 | 77.5 | 81.5 | 80.6 | 80.8 | 80.8 | 81.2 | 81.0 | 81.3 | 80.6 | 81.3 | 80.5 | 81.1 | 80.7 | 81.3 | 80.2 | 81.6 | 80.6 | 81.5 | 80.2 | 81.7 | 81.7 | 81.5 | 81.1 | 80.7 | 81.3 | | |
| 50 | 81.1 | 81.2 | 80.9 | 81.4 | 81.6 | 81.3 | 80.8 | 81.0 | 82.0 | 82.1 | 80.6 | 80.8 | 81.6 | 81.7 | 80.8 | 81.1 | 81.8 | 82.0 | 80.9 | 81.0 | 81.7 | 81.6 | 81.6 | 81.5 | 81.6 | 81.8 | |
| 100 | 81.6 | 81.6 | 82.2 | 82.4 | 81.8 | 82.1 | 82.5 | 82.8 | 81.5 | 81.9 | 82.7 | 82.9 | 81.6 | 81.9 | 82.7 | 82.8 | 81.7 | 81.7 | 82.8 | 83.0 | 81.8 | 82.1 | 81.7 | 81.6 | 82.0 | 82.3 | |
| 250 | 80.4 | 82.4 | 82.8 | 83.1 | 82.2 | 82.2 | 82.4 | 82.8 | 82.3 | 82.4 | 82.5 | 82.7 | 82.1 | 82.0 | 82.5 | 82.6 | 82.0 | 82.0 | 82.4 | 82.8 | 82.0 | 81.8 | 81.9 | 81.8 | 82.7 | 82.7 | |
| 500 | 81.3 | 82.7 | 82.9 | 83.5 | 83.0 | 82.9 | 83.1 | 83.5 | 83.0 | 82.5 | 83.3 | 83.4 | 82.5 | 82.7 | 83.6 | 83.6 | 83.1 | 83.0 | 83.9 | 83.7 | 82.7 | 82.5 | 83.1 | 83.0 | 83.6 | 83.1 | |
| NER | 10 | 56.0 | 58.4 | 62.2 | 66.3 | 61.4 | 61.8 | 65.2 | 66.2 | 61.8 | 62.6 | 65.9 | 65.9 | 62.2 | 62.9 | 66.5 | 67.1 | 62.1 | 63.6 | 67.0 | 67.8 | 62.6 | 63.6 | 62.1 | 63.9 | 67.7 | 68.4 | |
| 50 | 71.4 | 71.8 | 73.0 | 73.8 | 69.9 | 70.0 | 73.5 | 73.8 | 71.0 | 71.3 | 73.5 | 73.9 | 71.1 | 71.7 | 73.5 | 74.2 | 71.6 | 72.3 | 73.3 | 74.0 | 71.8 | 72.2 | 72.4 | 72.8 | 74.0 | 74.8 | |
| 100 | 72.7 | 73.8 | 75.2 | 75.7 | 73.2 | 73.2 | 75.5 | 76.0 | 73.5 | 73.9 | 75.7 | 75.8 | 73.4 | 74.0 | 75.8 | 76.2 | 74.3 | 74.7 | 76.1 | 76.4 | 74.7 | 74.8 | 74.7 | 74.9 | 76.1 | 76.5 | |
| 250 | 77.4 | 78.4 | 78.7 | 79.6 | 76.7 | 77.0 | 78.7 | 79.0 | 77.1 | 77.4 | 78.7 | 79.0 | 77.6 | 78.0 | 78.9 | 78.9 | 78.2 | 78.4 | 79.3 | 79.4 | 78.2 | 78.2 | 78.3 | 78.3 | 79.4 | 79.7 | |
| 500 | 79.3 | 80.0 | 80.9 | 81.4 | 79.1 | 79.1 | 80.7 | 80.8 | 79.3 | 79.5 | 81.1 | 81.1 | 79.8 | 80.2 | 81.4 | 81.3 | 80.2 | 80.4 | 81.1 | 81.5 | 80.2 | 80.3 | 80.4 | 80.4 | 80.4 | 81.4 | 81.4 |
| POS | 10 | 77.5 | 77.5 | 80.6 | 80.7 | 76.4 | 76.4 | 80.7 | 80.6 | 77.6 | 77.7 | 80.9 | 80.9 | 77.9 | 78.2 | 81.0 | 81.0 | 78.0 | 78.2 | 81.0 | 81.1 | 78.4 | 78.3 | 79.2 | 79.3 | 81.2 | 81.4 | |
| 50 | 83.4 | 83.3 | 85.6 | 85.8 | 81.2 | 81.2 | 85.6 | 85.5 | 82.4 | 82.4 | 85.7 | 85.8 | 83.3 | 83.3 | 85.7 | 85.8 | 83.5 | 83.6 | 85.8 | 85.8 | 84.4 | 84.4 | 84.8 | 84.8 | 86.0 | 86.0 | |
| 100 | 85.6 | 85.6 | 87.5 | 87.8 | 84.5 | 84.4 | 87.6 | 87.6 | 85.3 | 85.2 | 87.6 | 87.7 | 85.7 | 85.7 | 87.8 | 87.8 | 86.0 | 86.0 | 87.7 | 87.8 | 86.6 | 86.5 | 87.0 | 86.9 | 87.9 | 88.0 | |
| 250 | 88.0 | 88.2 | 89.1 | 89.4 | 87.3 | 87.3 | 89.4 | 89.5 | 87.9 | 87.8 | 89.6 | 89.6 | 88.4 | 88.4 | 89.7 | 89.6 | 88.6 | 88.6 | 89.6 | 89.6 | 88.9 | 88.8 | 89.1 | 89.1 | 89.7 | | |
| 500 | 89.6 | 89.8 | 90.2 | 90.4 | 89.1 | 89.1 | 90.3 | 90.4 | 89.5 | 89.5 | 90.5 | 90.5 | 90.0 | 89.9 | 90.5 | 90.6 | 90.1 | 90.0 | 90.7 | 90.6 | 90.1 | 90.0 | 90.2 | 90.1 | 90.5 | 90.5 | |
+
+Table 2: FS-XLT results where each fine-tuning regimes commences from the final checkpoint of English fine-tuning. All tasks comprise three target languages, and the scores are averaged over three fixed random seeds, with training and validation subsets being the same for each seed.
+
+| Shots | AMNLI | PAWS-X | NER | POS |
| T | S-T | T | S-T | T | S-T | T | S-T |
| L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O |
| 10 | 36.5 | 36.5 | 35.8 | 36.3 | 78.0 | 83.6 | 83.4 | 83.1 | 50.8 | 53.8 | 54.0 | 55.3 | 80.8 | 80.8 | 78.5 | 78.8 |
| 100 | 43.8 | 44.1 | 46.9 | 46.3 | 81.3 | 83.0 | 83.5 | 82.8 | 66.9 | 68.2 | 69.7 | 70.2 | 88.1 | 88.1 | 88.6 | 88.6 |
| 500 | 50.1 | 49.7 | 52.9 | 52.4 | 82.2 | 83.0 | 84.5 | 84.3 | 74.2 | 75.0 | 76.7 | 76.6 | 91.0 | 91.1 | 91.3 | 91.3 |
+
+Table 3: FS-XLT with Chinese as the source language. S=SOURCE, S-T=SOURCE-TARGET (MACRO is used).
+
+tained with the hybrid MACRO-MULTI $\rightarrow$ BI, which reaps the best of both worlds: 1) multilingual fine-tuning prevents overfitting to a single source language and provides a better initialization point for 2) the more specialized bilingual fine-tuning for a particular source-target direction. Note that the two-stage MULTI $\rightarrow$ BI fine-tuning also improves the TARGET variant quite consistently. We report increase in performance both for L and O checkpoints. Nevertheless, MACRO still outperforms TARGET.
+
+The results over different computational budgets reveal that longer training is beneficial for the MACRO variants. As expected, the setups with more shots typically require fewer steps to converge. A general finding is that 1) the bilingual SOURCE-TARGET variants do trade off some of the computational efficiency for enhanced performance, but 2) bilingual fine-tuning times can be decreased by starting from a better (i.e., multilingual) initialization: cf., the MULTI→BI columns.
+
+Another Source Language. Cross-lingual transfer predominantly focuses on English as the source language (Hu et al., 2020; Lauscher et al., 2020), mostly because of the wide availability and abundance of annotated task data in English. In order to verify that our main findings generalise and reach
+
+beyond English as the source language, we conduct another set of experiments relying on Chinese as the source language. $^{10}$ The results for the TARGET-LAST and MACRO-LAST variants are presented in Table 3. The observed patterns largely follow the general trends we reported with English as the source language; what is more, the gains of SOURCE-TARGET over TARGET even widen for AmNLI and PAWS-X. We speculate that this might be due to a lower quality of the source Chinese instances. Namely, except for POS, the task annotations for Chinese were either automatically translated (AmNLI, PAWS-X) or induced via some heuristics (WikiANN). Joint bilingual fine-tuning then provides increased robustness against such noisy source annotations.
+
+# 6 Conclusion
+
+Recent work demonstrated large benefits of few-shot cross-lingual transfer (FS-XLT) with multilingual language models, where a handful of annotated examples in the target language exist, over its zero-shot counterpart (ZS-XLT). However, as we have proven in this paper, prior work overestimated
+
+FS-XLT performance, relying on an unrealistic assumption of having a dedicated validation set in the target language to guide model selection. In this work, we have performed an extensive comparative study of a wide variety of FS-XLT approaches, challenging the status quo in FS-XLT. Our detailed analyses have rendered established FS-XLT largely unstable and performing sub-par in true FS-XLT setups without the target validation data. We have thus proposed novel FS-XLT fine-tuning regimes that take into account interaction between source-language and target-language data instances, yielding improved, more stable, and more predictable FS-XLT performance across different tasks, languages, and numbers of target-language shots. We hope that our study will inspire better FS-XLT training and evaluation practices in future work, and guide new developments for true FS-XLT setups.
+
+# 7 Limitations
+
+While we have striven to present a comprehensive and wide study of a large spectrum of FS-XLT fine-tuning regimes, several additional factors must be taken into consideration. First, few-shot learning naturally comes with high variance, as demonstrated by our work (where we set out to decrease the variance) and a body of prior research in monolingual and cross-lingual transfer contexts. This study demanded an extremely large computational budget (see Appendix A.1), so we constrained experiments to independent runs with three seeds. Ideally, more independent runs (5-10) might yield even more consistent estimates.
+
+Furthermore, due to computational constraints, our work largely focuses on cross-lingual natural language understanding (NLU) and sequence-labeling tasks. In addition, the community might find a similar set of experiments insightful for cross-lingual transfer in other areas such as (i) task-oriented dialogue systems, or (ii) long-range tasks like document classification. Moreover, while we keep hyper-parameters constant throughout different regimes, it is highly likely that they can be further adapted and fine-tuned for a particular task, language, and selection of shots. However, our core findings demonstrate that the novel joint FS-XLT fine-tuning regimes consistently match or exceed oracle performance while requiring no substantial hyper-parameter tuning or checkpoint selection.
+
+# Acknowledgements
+
+We thank the state of Baden-Württemberg for its support through access to the bwHPC. Fabian David Schmidt and Goran Glavaš were supported by the EUINACTION grant from NORFACE Governance (462-19-010, GL950/2-1). Ivan Vulić is supported by a personal Royal Society University Research Fellowship (no 221137; 2022-2027) as well as a Huawei research donation to the Language Technology Lab.
+
+# References
+
+David Ifeoluwa Adelani, Jade Abbott, Graham Neubig, Daniel D'souza, Julia Kreutzer, Constantine Lignos, Chester Palen-Michel, Happy Buzaaba, Shruti Rijhwani, Sebastian Ruder, et al. 2021. Masakhaner: Named entity recognition for african languages. Transactions of the Association for Computational Linguistics, 9:1116-1131.
+Alan Ansell, Edoardo Ponti, Anna Korhonen, and Ivan Vulic. 2022. Composable sparse fine-tuning for cross-lingual transfer. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1778-1796, Dublin, Ireland. Association for Computational Linguistics.
+Alan Ansell, Edoardo Maria Ponti, Jonas Pfeiffer, Sebastian Ruder, Goran Glavaš, Ivan Vulić, and Anna Korhonen. 2021. Mad-g: Multilingual adapter generation for efficient cross-lingual transfer. In *Findings of the Association for Computational Linguistics: EMNLP* 2021, pages 4762–4781.
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Advances in Neural Information Processing Systems, volume 33, pages 1877-1901. Curran Associates, Inc.
+Steven Cao, Nikita Kitaev, and Dan Klein. 2020. Multilingual alignment of contextual word representations. In International Conference on Learning Representations.
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettlemoyer, and Veselin Stoyanov. 2020. Unsupervised
+
+cross-lingual representation learning at scale. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8440-8451, Online. Association for Computational Linguistics.
+Alexis Conneau, Rudy Rinott, Guillaume Lample, Adina Williams, Samuel R. Bowman, Holger Schwenk, and Veselin Stoyanov. 2018. Xnli: Evaluating crosslingual sentence representations. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Abteen Ebrahimi, Manuel Mager, Arturo Oncevay, Vishrav Chaudhary, Luis Chiruzzo, Angela Fan, John Ortega, Ricardo Ramos, Annette Rios, Ivan Vladimir, Gustavo A. Giménez-Lugo, Elisabeth Mager, Graham Neubig, Alexis Palmer, Rolando A. Coto Solano, Ngoc Thang Vu, and Katharina Kann. 2021. Americasnli: Evaluating zero-shot natural language understanding of pretrained multilingual models in truly low-resource languages. CoRR, abs/2104.08726.
+Tianyu Gao, Adam Fisch, and Danqi Chen. 2021. Making pre-trained language models better few-shot learners. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 3816-3830, Online. Association for Computational Linguistics.
+Michael A. Hedderich, David Adelani, Dawei Zhu, Jesujoba Alabi, Udia Markus, and Dietrich Klakow. 2020. Transfer learning and distant supervision for multilingual transformer models: A study on African languages. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 2580-2591, Online. Association for Computational Linguistics.
+Junjie Hu, Melvin Johnson, Orhan First, Aditya Siddhant, and Graham Neubig. 2021. Explicit alignment objectives for multilingual bidirectional encoders. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 3633-3643, Online. Association for Computational Linguistics.
+Junjie Hu, Sebastian Ruder, Aditya Siddhant, Graham Neubig, Orhan First, and Melvin Johnson. 2020. Xtreme: A massively multilingual multi-task
+
+benchmark for evaluating cross-lingual generalisation. In International Conference on Machine Learning, pages 4411-4421. PMLR.
+Pratik Joshi, Sebastin Santy, Amar Budhiraja, Kalika Bali, and Monojit Choudhury. 2020. The state and fate of linguistic diversity and inclusion in the NLP world. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6282-6293, Online. Association for Computational Linguistics.
+Phillip Keung, Yichao Lu, Julian Salazar, and Vikas Bhardwaj. 2020. Don't use English dev: On the zero-shot cross-lingual evaluation of contextual embeddings. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 549–554, Online. Association for Computational Linguistics.
+Guillaume Lample and Alexis Conneau. 2019. Crosslingual language model pretraining. Advances in Neural Information Processing Systems (NeurIPS).
+Anne Lauscher, Vinit Ravishankar, Ivan Vulic, and Goran Glavaš. 2020. From zero to hero: On the limitations of zero-shot language transfer with multilingual Transformers. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4483-4499, Online. Association for Computational Linguistics.
+Quentin Lhoest, Albert Villanova del Moral, Yacine Jernite, Abhishek Thakur, Patrick von Platen, Suraj Patil, Julien Chaumont, Mariama Drame, Julien Plu, Lewis Tunstall, Joe Davison, Mario Šaško, Gunjan Chhablani, Bhavitvya Malik, Simon Brandeis, Teven Le Scao, Victor Sanh, Canwen Xu, Nicolas Patry, Angelina McMillan-Major, Philipp Schmid, Sylvain Gugger, Clément Delangue, Theo Matussière, Lysandre Debut, Stas Bekman, Pierrick Cistac, Thibault Goehringer, Victor Mustar, François Lagunas, Alexander Rush, and Thomas Wolf. 2021. Datasets: A community library for natural language processing. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 175-184, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Ilya Loshchilov and Frank Hutter. 2019. Decoupled weight decay regularization. In 7th International Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019. OpenReview.net.
+Xiaoman Pan, Boliang Zhang, Jonathan May, Joel Nothman, Kevin Knight, and Heng Ji. 2017. Cross-lingual
+
+name tagging and linking for 282 languages. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1946-1958, Vancouver, Canada. Association for Computational Linguistics.
+Ethan Perez, Douwe Kiela, and Kyunghyun Cho. 2021. True few-shot learning with language models. In Advances in Neural Information Processing Systems.
+Jonas Pfeiffer, Naman Goyal, Xi Victoria Lin, Xian Li, James Cross, Sebastian Riedel, and Mikel Artetxe. 2022. Lifting the curse of multilinguality by pre-training modular transformers. CoRR, abs/2205.06266.
+Jonas Pfeiffer, Ivan Vulic, Iryna Gurevych, and Sebastian Ruder. 2020. Mad-x: An adapter-based framework for multi-task cross-lingual transfer. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 7654–7673.
+Telmo Pires, Eva Schlinger, and Dan Garrette. 2019. How multilingual is multilingual BERT? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4996-5001, Florence, Italy. Association for Computational Linguistics.
+Afshin Rahimi, Yuan Li, and Trevor Cohn. 2019. Massively multilingual transfer for NER. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 151-164, Florence, Italy. Association for Computational Linguistics.
+Sebastian Ruder, Noah Constant, Jan Botha, Aditya Siddhant, Orhan Firat, Jinlan Fu, Pengfei Liu, Junjie Hu, Dan Garrette, Graham Neubig, et al. 2021. Xtreme-r: Towards more challenging and nuanced multilingual evaluation. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 10215-10245.
+Ahmet Üstün, Arianna Bisazza, Gosse Bouma, Gertjan van Noord, and Sebastian Ruder. 2022. Hyper-x: A unified hypernetwork for multi-task multilingual transfer. CoRR, abs/2205.12148.
+Adina Williams, Nikita Nangia, and Samuel Bowman. 2018. A broad-coverage challenge corpus for sentence understanding through inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 1112-1122, New Orleans, Louisiana. Association for Computational Linguistics.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin
+
+Lhoest, and Alexander M. Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+Shijie Wu and Mark Dredze. 2020. Do explicit alignments robustly improve multilingual encoders? In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4471-4482, Online. Association for Computational Linguistics.
+Haoran Xu and Kenton Murray. 2022. Por quem não utiliser alla sprek? mixed training with gradient optimization in few-shot cross-lingual transfer. In Findings of the Association for Computational Linguistics: NAACL 2022, pages 2043-2059, Seattle, United States. Association for Computational Linguistics.
+Linting Xue, Noah Constant, Adam Roberts, Mihir Kale, Rami Al-Rfou, Aditya Siddhant, Aditya Barua, and Colin Raffel. 2021. mt5: A massively multilingual pre-trained text-to-text transformer. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 483-498.
+Huiyun Yang, Huadong Chen, Hao Zhou, and Lei Li. 2022. Enhancing cross-lingual transfer by manifold mixup. In International Conference on Learning Representations.
+Yinfei Yang, Yuan Zhang, Chris Tar, and Jason Baldridge. 2019. PAWS-X: A cross-lingual adversarial dataset for paraphrase identification. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3687-3692, Hong Kong, China. Association for Computational Linguistics.
+Tianhe Yu, Saurabh Kumar, Abhishek Gupta, Sergey Levine, Karol Hausman, and Chelsea Finn. 2020. Gradient surgery for multi-task learning. In Advances in Neural Information Processing Systems, volume 33, pages 5824-5836. Curran Associates, Inc.
+Daniel Zeman, Joakim Nivre, et al. 2020. Universal dependencies 2.7. LINDAT/CLARIAH-CZ digital library at the Institute of Formal and Applied Linguistics (UFAL), Faculty of Mathematics and Physics, Charles University.
+Hongyi Zhang, Moustapha Cisse, Yann N. Dauphin, and David Lopez-Paz. 2018. mixup: Beyond empirical risk minimization. In International Conference on Learning Representations.
+Mengjie Zhao, Yi Zhu, Ehsan Shareghi, Ivan Vulic, Roi Reichart, Anna Korhonen, and Hinrich Schütze. 2021. A closer look at few-shot crosslingual transfer:
+
+The choice of shots matters. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 5751-5767, Online. Association for Computational Linguistics.
+
+# A Appendix
+
+# A.1 Reproducibility
+
+Infrastructure and Compute. We train our models on a cluster that provides virtual machines on which each model was trained on a single NVIDIA Tesla V100 32GB GPU. We evaluate 7 setups with three seeds for $k \in \{10,50,100,250,500\}$ shots across 4 tasks in our base experiments, amounting to 5,145 models trained for 3,756 GPU hours for our main results. Therein, AmNLI alone takes up 2,170 hours (57.8%).
+
+Datasets. We access all datasets via the Huggingface datasets library (Lhoest et al., 2021). Whenever we subsample data, we initially shuffle the dataset with one of seed $s \in \{42, 43, 44\}$ built-in datasets method and subsequently extract the first $k$ required instances for our experiments. In case we require a validation subset from the same dataset, we extract the $|N_D| - 500$ last available observations after shuffling to evaluate our models during training (i.e., to measure ORACLE performance). We manually verified that our approach yields consistent subsamples by seed.
+
+Code. Our code is available at: https://github.com/fdschmidt93/fsxlt
+
+# A.2 Stability Of Few-Shot Cross-Lingual Transfer
+
+
+Figure 3: FS-XLT regimes (joint MACRO versus sequential TARGET) starting from the LAST checkpoint of the initial source language fine-tuning step. The colored dots group runs for each seed by language and mark the checkpoints that transfer best to target-language validation data. The line plots the mean (incl. $\pm 1\sigma$ ) test set spread (in %) of best validation and current checkpoint.
+
+# A.3 Full Results over Individual Target Languages
+
+# A.4 AmericasNLI
+
+| Weights | k Shots | SOURCE | TARGET | SOURCE-TARGET | |
| Zero-Shot | Few-Shot | MACRO | MIX-UP | | |
| LM | LAST | ORACLE | LM | LAST | ORACLE | LM | LAST | ORACLE | |
| Metric | | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | |
| Aymara | 10 | 39.7 | 39.5 | 38.0 | 39.0 | 39.3 | 41.8 | 34.5 | 37.0 | 36.9 | 37.1 | 34.8 | 38.0 | 34.5 | 35.9 | 36.8 | 38.1 | 36.7 | 38.3 |
| AYM | 50 | 39.7 | 39.5 | 44.9 | 45.0 | 44.7 | 46.1 | 40.9 | 42.1 | 45.4 | 45.6 | 42.2 | 42.8 | 37.1 | 40.0 | 44.5 | 44.8 | 45.6 | 45.5 |
| 100 | 39.7 | 39.5 | 45.7 | 45.5 | 46.9 | 48.7 | 45.9 | 46.4 | 46.0 | 46.7 | 47.7 | 46.9 | 43.0 | 43.6 | 49.0 | 47.9 | 47.3 | 47.9 |
| 250 | 39.7 | 39.5 | 49.3 | 50.0 | 50.1 | 50.9 | 50.0 | 51.4 | 51.6 | 51.4 | 53.3 | 51.5 | 50.5 | 51.6 | 52.0 | 51.1 | 52.0 | 52.2 |
| 500 | 39.7 | 39.5 | 52.0 | 52.5 | 51.6 | 50.8 | 51.6 | 51.6 | 54.6 | 54.8 | 55.2 | 56.1 | 52.5 | 50.9 | 53.7 | 54.3 | 53.5 | 54.4 |
| Bribri | 10 | 40.8 | 40.4 | 39.1 | 40.0 | 39.0 | 40.7 | 36.4 | 36.3 | 39.9 | 39.7 | 41.0 | 41.6 | 36.1 | 35.9 | 40.3 | 40.2 | 39.1 | 39.8 |
| BZD | 50 | 40.8 | 40.4 | 44.7 | 45.2 | 44.5 | 44.2 | 44.1 | 45.7 | 47.6 | 45.8 | 49.0 | 49.4 | 42.5 | 43.0 | 47.0 | 48.6 | 47.5 | 48.7 |
| 100 | 40.8 | 40.4 | 48.6 | 46.8 | 49.2 | 48.2 | 49.2 | 49.6 | 51.5 | 50.5 | 52.5 | 51.2 | 48.2 | 48.1 | 51.7 | 51.2 | 52.5 | 50.7 |
| 250 | 40.8 | 40.4 | 52.6 | 52.0 | 54.9 | 55.1 | 52.0 | 51.4 | 54.2 | 54.6 | 53.4 | 53.7 | 51.3 | 52.3 | 55.2 | 54.8 | 55.3 | 54.6 |
| 500 | 40.8 | 40.4 | 56.6 | 56.4 | 56.8 | 56.7 | 54.6 | 56.1 | 57.9 | 57.3 | 57.7 | 58.2 | 56.4 | 55.0 | 56.5 | 56.7 | 57.2 | 56.8 |
| Guarani | 10 | 41.1 | 42.1 | 40.3 | 41.7 | 39.3 | 44.0 | 35.7 | 35.7 | 38.6 | 39.4 | 38.3 | 40.0 | 34.4 | 34.5 | 40.6 | 42.5 | 39.4 | 39.1 |
| GN | 50 | 41.1 | 42.1 | 46.8 | 47.1 | 45.2 | 44.9 | 40.8 | 42.5 | 45.3 | 45.4 | 45.5 | 46.1 | 40.7 | 40.2 | 47.1 | 46.7 | 45.6 | 46.7 |
| 100 | 41.1 | 42.1 | 47.6 | 46.6 | 48.8 | 47.9 | 45.0 | 45.3 | 49.2 | 47.6 | 49.3 | 49.7 | 44.8 | 46.3 | 49.6 | 48.8 | 49.6 | 50.4 |
| 250 | 41.1 | 42.1 | 52.1 | 51.4 | 49.7 | 49.7 | 49.8 | 51.7 | 51.6 | 52.2 | 51.6 | 51.8 | 48.3 | 50.2 | 51.4 | 50.8 | 51.7 | 50.5 |
| 500 | 41.1 | 42.1 | 54.2 | 52.8 | 53.4 | 51.3 | 51.3 | 52.4 | 53.3 | 52.7 | 54.0 | 52.9 | 53.5 | 52.8 | 52.6 | 52.5 | 53.5 | 52.6 |
| Wixarika | 10 | 38.4 | 37.5 | 36.9 | 38.4 | 37.5 | 39.3 | 33.8 | 35.5 | 37.6 | 38.4 | 36.4 | 37.3 | 34.4 | 34.3 | 36.2 | 38.0 | 35.5 | 36.6 |
| HCH | 50 | 38.4 | 37.5 | 40.3 | 39.9 | 40.6 | 39.8 | 35.9 | 38.1 | 40.3 | 40.3 | 40.1 | 40.2 | 36.4 | 35.8 | 39.9 | 39.5 | 39.8 | 40.8 |
| 100 | 38.4 | 37.5 | 41.8 | 39.9 | 41.0 | 40.8 | 37.0 | 38.3 | 40.8 | 40.5 | 41.6 | 42.0 | 37.9 | 37.2 | 41.8 | 42.6 | 42.3 | 41.7 |
| 250 | 38.4 | 37.5 | 44.2 | 44.5 | 43.4 | 41.5 | 40.3 | 40.3 | 45.2 | 45.9 | 44.8 | 43.1 | 39.5 | 39.3 | 45.6 | 45.5 | 44.0 | 44.7 |
| 500 | 38.4 | 37.5 | 44.8 | 46.1 | 44.5 | 43.8 | 45.7 | 46.8 | 46.4 | 45.7 | 45.5 | 45.2 | 44.7 | 44.0 | 46.9 | 46.5 | 45.7 | 46.0 |
| Quechua | 10 | 37.3 | 38.3 | 37.2 | 40.1 | 38.6 | 42.6 | 33.6 | 33.6 | 37.2 | 36.0 | 36.9 | 37.6 | 34.4 | 34.5 | 37.1 | 39.1 | 37.4 | 38.8 |
| QUY | 50 | 37.3 | 38.3 | 43.9 | 43.1 | 46.1 | 46.0 | 42.3 | 45.1 | 44.4 | 46.0 | 46.7 | 48.2 | 42.5 | 42.4 | 43.2 | 44.6 | 46.6 | 46.0 |
| 100 | 37.3 | 38.3 | 47.8 | 46.2 | 48.2 | 48.1 | 41.3 | 41.5 | 47.5 | 48.1 | 50.4 | 49.0 | 45.3 | 45.6 | 47.7 | 46.1 | 49.8 | 49.4 |
| 250 | 37.3 | 38.3 | 52.2 | 51.7 | 51.5 | 52.1 | 50.3 | 49.7 | 52.8 | 52.1 | 54.5 | 54.5 | 50.1 | 51.2 | 52.8 | 52.8 | 54.8 | 54.0 |
| 500 | 37.3 | 38.3 | 52.7 | 53.3 | 54.0 | 53.6 | 52.1 | 52.7 | 55.6 | 55.1 | 55.3 | 54.9 | 52.7 | 53.1 | 54.8 | 55.4 | 54.7 | 55.0 |
| Shipibo | 10 | 41.0 | 42.9 | 41.0 | 42.8 | 40.3 | 42.0 | 36.4 | 38.7 | 40.0 | 39.8 | 39.2 | 40.0 | 36.7 | 37.5 | 40.2 | 42.4 | 37.9 | 40.9 |
| SHP | 50 | 41.0 | 42.9 | 44.4 | 43.0 | 44.4 | 42.8 | 39.6 | 41.9 | 44.5 | 44.2 | 42.9 | 43.0 | 40.1 | 42.4 | 44.4 | 44.4 | 44.3 | 44.2 |
| 100 | 41.0 | 42.9 | 45.9 | 44.4 | 44.4 | 43.9 | 45.2 | 47.4 | 45.9 | 45.6 | 44.6 | 45.9 | 43.8 | 44.2 | 46.2 | 46.7 | 45.2 | 45.3 |
| 250 | 41.0 | 42.9 | 47.7 | 48.0 | 48.2 | 47.8 | 48.7 | 50.8 | 50.0 | 50.2 | 50.5 | 50.4 | 50.5 | 49.6 | 51.5 | 50.1 | 50.3 | 50.0 |
| 500 | 41.0 | 42.9 | 51.3 | 51.2 | 51.5 | 50.6 | 55.0 | 55.2 | 53.8 | 53.7 | 54.3 | 52.8 | 54.1 | 53.4 | 54.5 | 54.3 | 54.4 | 52.6 |
| Raramuri | 10 | 39.1 | 39.2 | 35.3 | 37.3 | 34.9 | 37.6 | 33.9 | 35.4 | 35.7 | 36.4 | 35.1 | 35.9 | 34.9 | 34.9 | 34.2 | 35.4 | 34.8 | 35.0 |
| TAR | 50 | 39.1 | 39.2 | 41.5 | 39.7 | 42.5 | 41.1 | 40.4 | 42.1 | 43.4 | 43.6 | 44.4 | 45.1 | 39.0 | 40.4 | 42.0 | 42.9 | 44.1 | 42.8 |
| 100 | 39.1 | 39.2 | 43.5 | 45.8 | 45.7 | 46.1 | 45.0 | 45.5 | 46.7 | 46.9 | 49.0 | 47.8 | 43.3 | 45.2 | 45.7 | 45.6 | 46.8 | 48.4 |
| 250 | 39.1 | 39.2 | 49.5 | 48.8 | 50.8 | 48.8 | 48.0 | 48.8 | 51.7 | 52.2 | 51.8 | 52.4 | 48.6 | 49.1 | 51.9 | 49.3 | 53.9 | 53.2 |
| 500 | 39.1 | 39.2 | 50.4 | 51.7 | 52.4 | 51.4 | 52.6 | 52.6 | 51.6 | 51.2 | 54.3 | 53.9 | 52.1 | 51.9 | 53.3 | 52.9 | 52.9 | 54.3 |
+
+# A.5 PAWS-X
+
+| Weights | k Shots | SOURCE | TARGET | SOURCE-TARGET | | |
| Zero-Shot | Few-Shot | MACRO | MIX-UP | | |
| LM | LAST | ORACLE | LM | LAST | ORACLE | LM | LAST | ORACLE | |
| Metric | | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | |
| German | 10 | 88.7 | 88.7 | 84.4 | 88.7 | 82.9 | 88.9 | 87.4 | 87.2 | 89.5 | 89.5 | 89.2 | 89.1 | 84.6 | 86.0 | 88.8 | 88.7 | 89.1 | 89.2 |
| DE | 50 | 88.7 | 88.7 | 88.5 | 88.8 | 88.5 | 88.8 | 86.2 | 87.1 | 89.0 | 89.1 | 89.6 | 89.3 | 80.4 | 83.7 | 89.0 | 89.0 | 89.0 | 88.5 |
| 100 | 88.7 | 88.7 | 88.9 | 88.9 | 88.9 | 89.1 | 86.8 | 86.6 | 89.4 | 89.4 | 89.2 | 88.8 | 82.2 | 83.4 | 89.1 | 89.0 | 89.3 | 88.9 |
| 250 | 88.7 | 88.7 | 87.2 | 88.8 | 87.4 | 88.7 | 87.4 | 86.6 | 89.2 | 88.9 | 89.4 | 89.4 | 84.6 | 84.7 | 89.0 | 89.2 | 89.1 | 89.1 |
| 500 | 88.7 | 88.7 | 87.6 | 89.0 | 86.5 | 88.9 | 87.2 | 87.0 | 89.4 | 89.5 | 89.6 | 89.4 | 86.4 | 87.2 | 89.3 | 89.2 | 89.5 | 89.2 |
| Spanish | 10 | 89.5 | 89.7 | 85.9 | 89.7 | 85.9 | 89.7 | 88.3 | 88.4 | 89.8 | 89.4 | 89.8 | 89.4 | 85.9 | 88.2 | 89.8 | 89.8 | 89.8 | 89.8 |
| ES | 50 | 89.5 | 89.7 | 88.9 | 89.7 | 88.9 | 89.7 | 88.5 | 88.0 | 90.0 | 89.8 | 90.0 | 89.8 | 84.7 | 85.5 | 89.7 | 89.2 | 89.7 | 89.2 |
| 100 | 89.5 | 89.7 | 89.0 | 89.3 | 89.0 | 89.3 | 87.2 | 86.8 | 89.6 | 89.7 | 89.6 | 89.7 | 82.5 | 85.2 | 90.0 | 90.1 | 90.0 | 90.1 |
| 250 | 89.5 | 89.7 | 88.7 | 89.7 | 88.7 | 89.7 | 88.1 | 87.6 | 89.9 | 89.7 | 89.9 | 89.7 | 85.0 | 85.6 | 89.5 | 89.0 | 89.5 | 89.0 |
| 500 | 89.5 | 89.7 | 88.2 | 90.3 | 88.2 | 90.3 | 88.9 | 88.8 | 90.3 | 89.2 | 90.3 | 89.2 | 87.9 | 87.8 | 89.8 | 89.5 | 89.8 | 89.5 |
| French | 10 | 89.6 | 90.2 | 87.7 | 89.8 | 86.5 | 90.4 | 89.1 | 89.0 | 90.0 | 90.4 | 90.5 | 90.3 | 87.3 | 88.2 | 90.0 | 89.4 | 89.8 | 89.6 |
| FR | 50 | 89.6 | 90.2 | 88.7 | 90.0 | 89.2 | 90.4 | 84.1 | 87.8 | 90.0 | 89.7 | 90.1 | 90.1 | 80.1 | 84.4 | 90.3 | 90.2 | 90.2 | 90.0 |
| 100 | 89.6 | 90.2 | 89.4 | 89.6 | 89.4 | 90.2 | 87.2 | 87.6 | 90.2 | 89.9 | 90.6 | 90.5 | 84.5 | 86.4 | 90.2 | 90.2 | 90.4 | 90.1 |
| 250 | 89.6 | 90.2 | 88.9 | 90.1 | 89.0 | 90.1 | 87.3 | 88.0 | 90.0 | 90.4 | 90.5 | 90.7 | 86.0 | 86.4 | 90.5 | 90.4 | 90.2 | 89.9 |
| 500 | 89.6 | 90.2 | 89.3 | 90.2 | 88.7 | 90.1 | 89.2 | 89.1 | 91.0 | 91.0 | 91.0 | 91.0 | 88.6 | 88.5 | 90.6 | 90.3 | 90.4 | 90.7 |
| Japanese | 10 | 77.1 | 77.1 | 75.7 | 77.2 | 74.5 | 77.1 | 72.7 | 73.5 | 77.3 | 77.1 | 77.2 | 77.5 | 68.3 | 71.6 | 76.7 | 77.5 | 76.1 | 77.0 |
| JA | 50 | 77.1 | 77.1 | 76.6 | 77.1 | 74.7 | 76.8 | 71.3 | 73.9 | 77.6 | 77.5 | 76.7 | 76.9 | 62.8 | 64.5 | 78.0 | 77.8 | 78.0 | 77.3 |
| 100 | 77.1 | 77.1 | 77.2 | 77.5 | 74.0 | 76.3 | 72.3 | 73.0 | 77.2 | 78.0 | 77.2 | 77.2 | 67.2 | 70.9 | 77.8 | 77.5 | 77.1 | 77.4 |
| 250 | 77.1 | 77.1 | 76.9 | 78.8 | 76.4 | 77.3 | 74.4 | 75.4 | 78.4 | 78.2 | 78.2 | 78.0 | 69.9 | 71.2 | 77.5 | 77.8 | 78.0 | 77.6 |
| 500 | 77.1 | 77.1 | 77.7 | 79.6 | 77.4 | 78.9 | 76.4 | 76.9 | 79.2 | 79.0 | 79.4 | 79.3 | 75.8 | 75.2 | 79.4 | 79.4 | 78.8 | 79.1 |
| Korean | 10 | 76.7 | 77.2 | 72.2 | 78.6 | 72.2 | 78.2 | 71.1 | 73.4 | 78.3 | 78.0 | 78.7 | 78.4 | 62.9 | 69.9 | 77.3 | 77.6 | 77.2 | 77.6 |
| KO | 50 | 76.7 | 77.2 | 78.2 | 77.5 | 77.6 | 78.6 | 71.4 | 72.6 | 78.5 | 78.2 | 78.9 | 79.5 | 65.0 | 67.0 | 78.9 | 78.3 | 78.9 | 78.6 |
| 100 | 76.7 | 77.2 | 78.6 | 78.6 | 78.6 | 78.5 | 70.6 | 71.0 | 78.7 | 78.8 | 78.6 | 78.7 | 65.8 | 67.9 | 78.6 | 78.1 | 79.2 | 79.3 |
| 250 | 76.7 | 77.2 | 77.2 | 79.6 | 77.1 | 78.8 | 72.9 | 74.1 | 78.4 | 78.3 | 78.6 | 78.4 | 68.8 | 70.6 | 78.6 | 78.3 | 78.8 | 78.2 |
| 500 | 76.7 | 77.2 | 78.8 | 79.7 | 79.6 | 79.7 | 75.4 | 75.5 | 79.5 | 79.1 | 79.4 | 79.8 | 73.8 | 74.2 | 80.1 | 79.6 | 79.6 | 79.3 |
| Chinese | 10 | 81.1 | 81.3 | 80.0 | 81.6 | 78.2 | 82.2 | 78.0 | 79.4 | 82.3 | 82.5 | 82.8 | 82.8 | 74.6 | 79.6 | 81.3 | 81.5 | 81.0 | 81.9 |
| ZH | 50 | 81.1 | 81.3 | 80.3 | 81.7 | 81.3 | 82.2 | 77.8 | 78.0 | 81.4 | 81.4 | 82.3 | 81.5 | 73.2 | 74.4 | 81.7 | 82.0 | 82.4 | 82.4 |
| 100 | 81.1 | 81.3 | 81.2 | 82.2 | 81.2 | 82.3 | 75.4 | 76.0 | 82.2 | 81.4 | 82.4 | 81.4 | 68.8 | 73.2 | 81.7 | 81.6 | 82.1 | 82.7 |
| 250 | 81.1 | 81.3 | 80.2 | 82.1 | 80.4 | 82.1 | 77.4 | 78.8 | 81.6 | 82.2 | 82.8 | 82.8 | 75.7 | 76.8 | 82.0 | 82.0 | 81.6 | 81.9 |
| 500 | 81.1 | 81.3 | 81.6 | 83.2 | 81.1 | 82.4 | 79.7 | 80.2 | 82.1 | 82.5 | 83.1 | 83.0 | 78.7 | 78.7 | 82.3 | 82.2 | 82.2 | 82.1 |
+
+A.6 WikiANN
+
+| Weights | k Shots | SOURCE | TARGET | SOURCE-TARGET |
| Zero-Shot | Few-Shot | MACRO | MIX-UP |
| LM | LAST | ORACLE | LM | LAST | ORACLE | LM | LAST | ORACLE |
| Metric | | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L |
| Afrikaans AF | 10 | 72.9 | 73.3 | 72.9 | 75.6 | 72.6 | 75.5 | 75.0 | 75.2 | 75.5 | 76.3 | 76.0 | 75.8 | 75.4 | 75.9 | 75.6 | 74.5 | 75.4 |
| 50 | 72.9 | 73.3 | 76.9 | 76.9 | 77.8 | 77.9 | 78.7 | 78.6 | 78.8 | 77.4 | 78.2 | 78.2 | 77.7 | 77.8 | 78.2 | 78.2 | 77.9 |
| 100 | 72.9 | 73.3 | 78.6 | 79.8 | 79.3 | 79.2 | 80.1 | 80.3 | 79.6 | 79.6 | 80.0 | 79.3 | 79.7 | 79.5 | 80.1 | 80.3 | 80.2 |
| 250 | 72.9 | 73.3 | 81.2 | 81.2 | 81.0 | 81.9 | 81.6 | 82.0 | 82.2 | 82.1 | 82.0 | 81.9 | 82.0 | 81.8 | 82.3 | 82.0 | 82.2 |
| 500 | 72.9 | 73.3 | 82.8 | 83.7 | 83.3 | 83.7 | 83.7 | 83.5 | 83.6 | 83.5 | 83.4 | 84.3 | 84.4 | 83.7 | 83.7 | 83.7 | 83.7 |
| Arabic AR | 10 | 43.2 | 49.0 | 66.6 | 66.7 | 64.2 | 66.7 | 69.1 | 69.6 | 69.1 | 69.9 | 68.8 | 70.6 | 69.0 | 70.6 | 68.0 | 69.8 | 70.0 |
| 50 | 43.2 | 49.0 | 72.5 | 73.0 | 72.1 | 72.5 | 73.2 | 73.8 | 73.9 | 74.4 | 74.3 | 74.6 | 73.8 | 73.9 | 74.0 | 74.6 | 74.8 |
| 100 | 43.2 | 49.0 | 73.4 | 73.8 | 73.2 | 73.9 | 74.5 | 74.9 | 75.4 | 75.9 | 75.5 | 76.0 | 75.5 | 76.0 | 75.4 | 76.0 | 75.7 |
| 250 | 43.2 | 49.0 | 74.8 | 76.7 | 75.5 | 76.7 | 77.1 | 77.3 | 77.4 | 77.6 | 77.8 | 77.8 | 77.7 | 77.8 | 78.0 | 78.0 | 78.1 |
| 500 | 43.2 | 49.0 | 76.6 | 79.1 | 76.8 | 78.4 | 79.7 | 80.0 | 79.7 | 79.7 | 79.8 | 79.8 | 80.0 | 79.9 | 79.8 | 79.9 | 79.8 |
| German DE | 10 | 70.6 | 71.6 | 68.3 | 72.3 | 68.2 | 73.5 | 72.6 | 73.9 | 71.7 | 72.5 | 71.8 | 72.5 | 73.5 | 73.6 | 71.6 | 72.3 | 72.3 |
| 50 | 70.6 | 71.6 | 72.1 | 73.1 | 72.6 | 73.8 | 74.8 | 75.0 | 73.9 | 74.5 | 74.3 | 74.8 | 75.2 | 75.4 | 74.1 | 74.4 | 74.6 |
| 100 | 70.6 | 71.6 | 73.1 | 73.6 | 73.2 | 73.7 | 75.6 | 76.2 | 75.0 | 75.1 | 75.1 | 75.7 | 75.5 | 75.6 | 74.9 | 75.6 | 75.9 |
| 250 | 70.6 | 71.6 | 75.5 | 76.6 | 75.7 | 76.7 | 77.1 | 77.5 | 76.9 | 76.9 | 76.7 | 76.9 | 77.3 | 77.4 | 76.7 | 76.7 | 77.1 |
| 500 | 70.6 | 71.6 | 76.4 | 77.9 | 77.1 | 78.4 | 78.7 | 78.7 | 78.3 | 78.3 | 78.5 | 78.5 | 78.7 | 78.8 | 78.1 | 78.3 | 78.4 |
| Japanese JA | 10 | 17.1 | 17.9 | 32.0 | 32.8 | 32.6 | 33.1 | 31.5 | 32.8 | 34.9 | 36.2 | 35.3 | 36.8 | 31.5 | 33.0 | 32.2 | 34.7 | 33.5 |
| 50 | 17.1 | 17.9 | 43.5 | 44.0 | 44.7 | 45.3 | 46.5 | 47.4 | 46.9 | 47.1 | 47.4 | 47.2 | 47.2 | 47.5 | 44.9 | 46.2 | 46.2 |
| 100 | 17.1 | 17.9 | 47.8 | 48.1 | 49.2 | 49.7 | 51.4 | 52.2 | 50.2 | 50.9 | 50.8 | 51.3 | 51.1 | 51.5 | 50.3 | 50.6 | 49.6 |
| 250 | 17.1 | 17.9 | 52.7 | 53.4 | 54.2 | 54.4 | 56.3 | 56.4 | 55.7 | 55.6 | 55.0 | 55.3 | 56.2 | 56.3 | 55.0 | 55.0 | 55.2 |
| 500 | 17.1 | 17.9 | 55.8 | 57.6 | 58.0 | 58.0 | 59.7 | 59.7 | 59.1 | 59.1 | 59.5 | 59.5 | 59.7 | 59.9 | 58.8 | 58.8 | 59.2 |
| Quechuan QU | 10 | 54.8 | 55.3 | 61.1 | 61.5 | 59.8 | 63.9 | 58.8 | 62.9 | 62.2 | 60.1 | 62.2 | 63.2 | 63.7 | 64.0 | 63.2 | 64.7 | 63.8 |
| 50 | 54.8 | 55.3 | 70.5 | 69.2 | 74.6 | 73.1 | 69.6 | 71.9 | 68.9 | 68.3 | 69.3 | 70.2 | 71.2 | 72.4 | 69.9 | 71.7 | 70.0 |
| 100 | 54.8 | 55.3 | 71.4 | 72.9 | 74.9 | 73.2 | 76.3 | 76.2 | 74.4 | 73.3 | 75.2 | 73.2 | 78.0 | 76.4 | 70.9 | 72.0 | 74.6 |
| Russian RU | 10 | 65.7 | 66.5 | 64.7 | 72.0 | 64.7 | 72.0 | 71.6 | 73.3 | 73.0 | 73.8 | 73.0 | 73.8 | 73.1 | 73.4 | 72.1 | 73.8 | 72.1 |
| 50 | 65.7 | 66.5 | 78.1 | 78.4 | 78.1 | 78.4 | 78.1 | 78.4 | 78.0 | 78.4 | 78.0 | 78.4 | 78.8 | 78.8 | 77.9 | 78.2 | 77.9 |
| 100 | 65.7 | 66.5 | 80.3 | 80.2 | 80.3 | 80.2 | 78.7 | 78.5 | 79.2 | 79.5 | 79.2 | 79.5 | 79.1 | 79.2 | 79.4 | 79.6 | 79.4 |
| 250 | 65.7 | 66.5 | 80.5 | 82.0 | 80.5 | 82.0 | 81.3 | 81.4 | 81.6 | 81.6 | 81.6 | 81.6 | 81.4 | 81.5 | 81.4 | 81.5 | 81.4 |
| 500 | 65.7 | 66.5 | 82.3 | 83.3 | 82.3 | 83.3 | 83.2 | 83.1 | 83.3 | 83.3 | 83.3 | 83.3 | 83.1 | 83.1 | 83.2 | 83.2 | 83.2 |
| Rwanda RW | 10 | 57.6 | 57.3 | 57.6 | 62.8 | 59.0 | 63.5 | 64.0 | 61.1 | 62.2 | 64.0 | 60.4 | 62.9 | 60.6 | 59.0 | 63.3 | 63.0 | 59.6 |
| 50 | 57.6 | 57.3 | 75.9 | 73.2 | 74.5 | 76.5 | 76.6 | 75.8 | 73.3 | 74.0 | 75.0 | 75.4 | 75.1 | 73.9 | 73.2 | 73.2 | 75.4 |
| 100 | 57.6 | 57.3 | 75.5 | 77.6 | 75.2 | 76.8 | 78.3 | 76.6 | 76.3 | 78.2 | 75.8 | 75.3 | 78.4 | 77.0 | 76.4 | 77.4 | 76.9 |
| Swahili SW | 10 | 61.1 | 63.8 | 70.6 | 70.5 | 70.8 | 72.6 | 73.8 | 74.1 | 74.7 | 74.7 | 73.9 | 74.9 | 74.7 | 74.8 | 73.2 | 74.6 | 74.4 |
| 50 | 61.1 | 63.8 | 84.3 | 84.2 | 84.4 | 84.5 | 84.3 | 84.3 | 83.8 | 84.8 | 84.2 | 83.9 | 84.2 | 84.1 | 84.1 | 84.3 | 84.2 |
| 100 | 61.1 | 63.8 | 84.6 | 85.0 | 85.5 | 85.3 | 85.4 | 86.0 | 86.5 | 86.3 | 85.3 | 85.8 | 85.9 | 85.4 | 85.8 | 86.5 | 85.1 |
| 250 | 61.1 | 63.8 | 87.3 | 88.2 | 87.8 | 87.5 | 87.7 | 88.1 | 88.1 | 87.9 | 87.8 | 87.6 | 88.4 | 88.8 | 88.1 | 88.3 | 87.9 |
| 500 | 61.1 | 63.8 | 89.0 | 89.8 | 88.7 | 89.6 | 89.5 | 89.2 | 89.5 | 89.6 | 89.4 | 89.9 | 89.6 | 89.2 | 89.6 | 89.5 | 89.6 |
| Tamil TA | 10 | 58.6 | 61.4 | 62.8 | 62.9 | 63.2 | 64.8 | 63.0 | 63.7 | 66.4 | 66.9 | 66.3 | 66.9 | 62.7 | 64.1 | 64.5 | 66.0 | 65.4 |
| 50 | 58.6 | 61.4 | 70.6 | 71.2 | 71.4 | 71.2 | 72.3 | 71.9 | 72.3 | 72.1 | 72.8 | 72.7 | 72.0 | 72.0 | 72.9 | 72.4 | 72.8 |
| 100 | 58.6 | 61.4 | 73.6 | 73.4 | 73.0 | 72.7 | 74.1 | 73.9 | 74.3 | 74.4 | 74.1 | 74.1 | 74.0 | 74.0 | 73.7 | 74.3 | 74.4 |
| 250 | 58.6 | 61.4 | 74.9 | 76.1 | 75.7 | 76.1 | 77.0 | 76.9 | 77.0 | 77.1 | 77.0 | 77.0 | 77.3 | 76.9 | 76.7 | 76.5 | 77.1 |
| 500 | 58.6 | 61.4 | 76.7 | 77.7 | 76.5 | 78.3 | 78.4 | 79.2 | 78.7 | 78.6 | 78.9 | 78.6 | 79.4 | 79.3 | 76.9 | 77.4 | 76.9 |
| Urdu UR | 10 | 56.9 | 64.0 | 74.6 | 75.1 | 75.0 | 77.5 | 77.5 | 78.0 | 75.9 | 77.4 | 76.8 | 77.2 | 77.3 | 78.6 | 73.6 | 76.2 | 76.8 |
| 50 | 56.9 | 64.0 | 79.7 | 79.6 | 80.5 | 81.4 | 80.8 | 80.6 | 81.3 | 81.5 | 80.6 | 81.3 | 81.1 | 81.9 | 81.0 | 82.8 | 81.3 |
| 100 | 56.9 | 64.0 | 80.5 | 81.8 | 80.9 | 83.3 | 82.9 | 82.7 | 83.2 | 82.4 | 82.2 | 81.7 | 82.0 | 82.5 | 83.3 | 83.6 | 82.7 |
| 250 | 56.9 | 64.0 | 83.8 | 83.9 | 84.5 | 85.4 | 85.3 | 85.4 | 85.0 | 85.3 | 84.9 | 85.4 | 85.1 | 85.1 | 85.1 | 85.3 | 85.3 |
| 500 | 56.9 | 64.0 | 85.7 | 86.5 | 85.3 | 86.6 | 87.3 | 87.2 | 87.2 | 86.7 | 87.8 | 87.6 | 87.6 | 87.3 | 87.9 | 87.4 | 87.3 |
| Vietnamese VI | 10 | 70.7 | 70.8 | 64.2 | 71.6 | 64.9 | 72.0 | 73.2 | 75.5 | 74.1 | 75.5 | 75.0 | 76.1 | 74.0 | 74.5 | 74.9 | 75.1 | 74.8 |
| 50 | 70.7 | 70.8 | 78.3 | 78.9 | 77.8 | 78.5 | 78.4 | 79.0 | 78.8 | 78.7 | 78.8 | 78.9 | 75.1 | 75.2 | 75.4 | 75.2 | |
| 100 | 70.7 | 70.8 | 79.9 | 80.1 | 79.4 | 79.6 | 79.8 | 80.0 | 79.5 | 79.6 | 79.7 | 80.1 | 80.7 | 81.0 | 79.9 | 80.0 | |
| 250 | 70.7 | 70.8 | 82.2 | 83.0 | 81.9 | 82.5 | 82.3 | 82.4 | 82.0 | 82.0 | 82.0 | 82.2 | 83.0 | 83.1 | 82.1 | 82.1 | |
| 500 | 70.7 | 70.8 | 83.0 | 83.2 | 82.2 | 83.5 | 83.4 | 83.8 | 83.0 | 83.1 | 83.0 | 82.9 | 83.8 | 83.9 | 82.9 | 83.1 | |
| Yoruba YO | 10 | 28.1 | 48.7 | 61.3 | 65.9 | 65.5 | 67.3 | 61.8 | 65.8 | 65.0 | 66.8 | 65.2 | 69.0 | 63.1 | 65.7 | 61.7 | 62.5 | 61.2 |
| 50 | 28.1 | 48.7 | 82.0 | 85.5 | 83.5 | 85.1 | 79.2 | 83.2 | 86.8 | 86.3 | 84.7 | 87.7 | 80.9 | 83.7 | 86.4 | 85.6 | |
| 100 | 28.1 | 48.7 | 85.1 | 85.5 | 89.3 | 87.2 | 86.4 | 87.0 | 88.1 | 88.1 | 87.3 | 88.0 | 86.7 | 86.7 | 86.7 | 86.5 | 87.1 |
| Chinese ZH | 10 | 25.6 | 27.8 | 33.0 | 33.0 | 33.0 | 33.0 | 38.7 | 40.6 | 39.2 | 40.6 | 39.2 | 40.6 | 35.8 | 38.9 | 36.7 | 39.0 | |
| 50 | 25.6 | 27.8 | 51.7 | 52.3 | 51.7 | 52.3 | 53.4 | 55.0 | 52.9 | 53.2 | 52.9 | 53.2 | 54.4 | 55.2 | 52.9 | 53.7 | |
| 100 | 25.6 | 27.8 | 53.6 | 56.3 | 53.6 | 56.3 | 58.5 | 59.3 | 58.0 | 58.5 | 58.0 | 58.5 | 58.6 | 59.1 | 56.8 | 58.6 | |
| 250 | 25.6 | 27.8 | 62.8 | 63.9 | 62.8 | 63.9 | 65.4 | 65.5 | 64.3 | 64.8 | 64.3 | 65.0 | 65.3 | 63.8 | 63.4 | 64.0 | |
| 500 | 25.6 | 27.8 | 66.0 | 67.0 | 66.0 | 67.0 | 68.7 | 68.9 | 68.0 | 68.3 | 68.0 | 68.3 | 68.4 | 68.6 | 67.6 | 67.5 | |
+
+A.7 Part-Of-Speech Tagging
+
+| Weights | k Shots | SOURCE | TARGET | SOURCE-TARGET |
| Zero-Shot | Few-Shot | MACRO | MIX-UP |
| L | O | LAST | ORACLE | L | O | LAST | ORACLE | L | O | LAST | ORACLE |
| Metric | | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O | L | O |
| Afrikaans AF | 10 | 86.5 | 86.5 | 91.6 | 91.4 | 92.8 | 92.8 | 91.2 | 91.1 | 90.2 | 90.2 | 90.9 | 90.6 | 91.5 | 91.5 | 90.5 | 90.4 | 91.0 | 91.2 |
| 50 | 86.5 | 86.5 | 94.5 | 94.4 | 94.9 | 94.7 | 94.0 | 94.0 | 93.0 | 93.0 | 93.3 | 93.5 | 94.2 | 94.1 | 93.0 | 93.1 | 93.7 | 93.7 |
| 100 | 86.5 | 86.5 | 95.3 | 95.3 | 95.6 | 95.6 | 95.1 | 95.1 | 94.7 | 94.6 | 94.6 | 94.6 | 95.5 | 95.4 | 94.7 | 94.5 | 94.9 | 94.6 |
| 250 | 86.5 | 86.5 | 96.8 | 96.7 | 96.9 | 96.9 | 97.0 | 96.9 | 96.3 | 96.3 | 96.5 | 96.6 | 97.0 | 97.0 | 96.4 | 96.3 | 96.4 | 96.4 |
| 500 | 86.5 | 86.5 | 97.3 | 97.3 | 97.4 | 97.5 | 97.6 | 97.5 | 97.4 | 97.3 | 97.6 | 97.5 | 97.7 | 97.7 | 97.2 | 97.2 | 97.5 | 97.4 |
| Arabic AR | 10 | 70.6 | 71.4 | 83.2 | 83.1 | 83.2 | 83.2 | 83.4 | 83.4 | 82.8 | 82.8 | 82.7 | 82.8 | 82.7 | 82.8 | 82.9 | 82.9 | 83.1 | 83.4 |
| 50 | 70.6 | 71.4 | 84.8 | 84.9 | 85.0 | 85.1 | 85.2 | 85.2 | 85.4 | 85.4 | 85.3 | 85.2 | 85.1 | 85.1 | 85.3 | 85.4 | 85.4 | 85.3 |
| 100 | 70.6 | 71.4 | 85.4 | 85.6 | 85.5 | 85.6 | 86.1 | 86.1 | 86.2 | 86.2 | 86.2 | 86.2 | 85.8 | 85.8 | 86.2 | 86.2 | 86.4 | 86.4 |
| 250 | 70.6 | 71.4 | 86.7 | 86.7 | 86.8 | 86.8 | 87.2 | 87.2 | 87.3 | 87.3 | 87.4 | 87.3 | 87.0 | 87.0 | 87.0 | 87.2 | 87.2 | 87.3 |
| 500 | 70.6 | 71.4 | 87.4 | 87.4 | 87.4 | 87.5 | 87.7 | 87.7 | 87.8 | 87.7 | 87.8 | 87.8 | 87.5 | 87.6 | 87.7 | 87.7 | 87.7 | 87.7 |
| Basque EU | 10 | 54.5 | 55.2 | 73.7 | 73.8 | 74.1 | 74.1 | 73.9 | 74.0 | 73.4 | 73.6 | 73.9 | 74.2 | 73.7 | 74.0 | 74.2 | 74.2 | 74.3 | 74.4 |
| 50 | 54.5 | 55.2 | 81.6 | 81.5 | 81.9 | 81.9 | 81.9 | 82.0 | 82.1 | 81.9 | 81.7 | 81.9 | 82.0 | 82.1 | 82.3 | 82.3 | 82.6 | 82.5 |
| 100 | 54.5 | 55.2 | 84.8 | 84.8 | 84.9 | 85.1 | 85.4 | 85.3 | 85.7 | 85.7 | 85.5 | 85.5 | 85.4 | 85.4 | 85.6 | 85.7 | 85.9 | 85.9 |
| 250 | 54.5 | 55.2 | 88.0 | 88.4 | 88.5 | 88.9 | 89.0 | 89.1 | 89.0 | 89.1 | 89.1 | 89.2 | 89.0 | 89.0 | 89.2 | 89.2 | 89.3 | 89.4 |
| 500 | 54.5 | 55.2 | 90.4 | 90.6 | 90.7 | 90.8 | 91.1 | 91.0 | 91.0 | 91.0 | 91.0 | 91.0 | 91.0 | 90.9 | 91.0 | 91.0 | 91.0 | 91.1 |
| Chinese ZH | 10 | 34.2 | 40.8 | 64.9 | 64.9 | 65.0 | 65.2 | 67.8 | 68.0 | 67.3 | 67.3 | 67.1 | 67.4 | 66.1 | 66.9 | 66.9 | 67.1 | 67.3 | 67.2 |
| 50 | 34.2 | 40.8 | 74.9 | 74.9 | 75.4 | 75.6 | 77.6 | 77.4 | 76.8 | 76.8 | 77.2 | 77.1 | 78.0 | 77.8 | 77.0 | 77.0 | 77.6 | 77.6 |
| 100 | 34.2 | 40.8 | 78.7 | 78.6 | 79.1 | 79.2 | 81.7 | 81.7 | 80.8 | 80.7 | 81.2 | 81.3 | 81.5 | 81.5 | 80.8 | 80.8 | 81.1 | 81.1 |
| 250 | 34.2 | 40.8 | 82.9 | 82.9 | 83.2 | 83.1 | 84.7 | 84.6 | 84.2 | 84.2 | 84.5 | 84.5 | 84.6 | 84.6 | 84.1 | 84.1 | 84.6 | 84.5 |
| 500 | 34.2 | 40.8 | 85.5 | 85.5 | 85.6 | 85.7 | 86.8 | 86.7 | 86.5 | 86.4 | 86.6 | 86.6 | 86.7 | 86.7 | 86.3 | 86.3 | 86.5 | 86.5 |
| German DE | 10 | 86.1 | 86.3 | 90.0 | 90.0 | 90.0 | 90.0 | 90.0 | 90.1 | 89.2 | 89.4 | 89.1 | 89.5 | 90.1 | 90.1 | 89.2 | 89.6 | 89.3 | 89.6 |
| 50 | 86.1 | 86.3 | 92.4 | 92.4 | 92.4 | 92.4 | 92.3 | 92.3 | 91.6 | 91.8 | 91.6 | 91.7 | 92.2 | 92.3 | 91.7 | 91.8 | 91.6 | 91.9 |
| 100 | 86.1 | 86.3 | 93.4 | 93.5 | 93.5 | 93.5 | 93.4 | 93.4 | 92.9 | 93.0 | 92.9 | 92.9 | 93.5 | 93.4 | 92.9 | 93.0 | 92.9 | 92.9 |
| 250 | 86.1 | 86.3 | 94.6 | 94.6 | 94.5 | 94.7 | 94.7 | 94.8 | 94.4 | 94.4 | 94.4 | 94.4 | 94.8 | 94.8 | 94.5 | 94.5 | 94.5 | 94.5 |
| 500 | 86.1 | 86.3 | 95.2 | 95.3 | 95.1 | 95.3 | 95.4 | 95.4 | 95.2 | 95.2 | 95.2 | 95.2 | 95.4 | 95.4 | 95.2 | 95.3 | 95.3 | 95.3 |
| Hindi HI | 10 | 66.7 | 67.2 | 84.3 | 84.3 | 84.5 | 84.7 | 84.7 | 84.8 | 83.6 | 83.9 | 84.2 | 84.1 | 84.1 | 84.3 | 83.8 | 83.8 | 84.0 | 84.1 |
| 50 | 66.7 | 67.2 | 88.4 | 88.4 | 88.3 | 88.3 | 88.6 | 88.4 | 88.3 | 88.4 | 88.5 | 88.5 | 88.2 | 88.1 | 88.4 | 88.5 | 88.5 | 88.6 |
| 100 | 66.7 | 67.2 | 89.1 | 89.3 | 89.4 | 89.3 | 89.6 | 89.5 | 89.6 | 89.6 | 89.5 | 89.6 | 89.2 | 89.3 | 89.5 | 89.4 | 89.7 | 89.6 |
| 250 | 66.7 | 67.2 | 90.5 | 90.7 | 90.4 | 90.6 | 90.9 | 90.9 | 90.9 | 90.9 | 90.9 | 91.0 | 90.8 | 90.9 | 90.9 | 90.8 | 90.9 | 90.9 |
| 500 | 66.7 | 67.2 | 91.1 | 91.2 | 91.2 | 91.2 | 91.5 | 91.5 | 91.5 | 91.4 | 91.5 | 91.5 | 91.4 | 91.4 | 91.5 | 91.5 | 91.5 | 91.5 |
| Hungarian HU | 10 | 75.0 | 75.3 | 86.9 | 86.9 | 87.2 | 87.2 | 85.2 | 85.3 | 84.9 | 85.1 | 84.8 | 85.4 | 85.6 | 85.7 | 84.8 | 84.9 | 84.7 | 85.0 |
| 50 | 75.0 | 75.3 | 91.7 | 91.7 | 91.8 | 91.8 | 92.0 | 91.8 | 91.5 | 91.3 | 91.3 | 91.1 | 91.7 | 91.7 | 91.5 | 91.7 | 91.5 | 91.5 |
| 100 | 75.0 | 75.3 | 93.0 | 93.0 | 93.2 | 93.2 | 93.3 | 93.2 | 93.0 | 92.9 | 93.1 | 93.1 | 93.3 | 93.3 | 93.0 | 93.2 | 93.1 | 93.1 |
| 250 | 75.0 | 75.3 | 94.8 | 94.8 | 94.9 | 94.9 | 94.9 | 94.8 | 94.8 | 94.8 | 94.9 | 94.9 | 95.1 | 95.0 | 95.0 | 95.0 | 95.0 | 95.0 |
| 500 | 75.0 | 75.3 | 95.8 | 95.8 | 95.9 | 95.9 | 95.9 | 95.9 | 95.9 | 95.9 | 95.9 | 95.8 | 95.8 | 95.9 | 95.9 | 95.8 | 95.9 | 95.8 |
| Indonesian ID | 10 | 75.0 | 75.3 | 86.9 | 86.9 | 87.2 | 87.2 | 74.4 | 74.4 | 73.4 | 73.4 | 73.7 | 73.8 | 74.2 | 74.2 | 73.9 | 73.9 | 74.1 | 74.0 |
| 50 | 75.0 | 75.3 | 91.7 | 91.7 | 91.8 | 91.8 | 92.0 | 91.8 | 91.5 | 91.3 | 91.3 | 91.1 | 91.7 | 91.7 | 91.5 | 91.7 | 91.5 | 91.5 |
| | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | | | |
+
+# A.8 Multilingual Results
+
+ | TARGET | S-T | MULTI |
| MACRO-LAST |
| | L | O | L | O | L | O |
| ANLI | 10 | 38.3 | 39.9 | 38.0 | 38.1 | 38.0 | 38.2 |
| 50 | 43.8 | 43.3 | 44.4 | 44.4 | 43.9 | 44.7 |
| 100 | 45.8 | 45.0 | 46.8 | 46.6 | 46.8 | 46.8 |
| 250 | 49.7 | 49.5 | 51.0 | 51.2 | 50.1 | 50.1 |
| 500 | 51.7 | 52.0 | 53.3 | 52.9 | 52.6 | 52.4 |
| PAWS-X | 10 | 81.0 | 84.2 | 84.5 | 84.5 | 84.4 | 84.2 |
| 50 | 83.5 | 84.2 | 84.4 | 84.3 | 84.4 | 84.3 |
| 100 | 84.0 | 84.3 | 84.6 | 84.5 | 84.2 | 84.0 |
| 250 | 83.2 | 84.9 | 84.6 | 84.6 | 84.3 | 84.2 |
| 500 | 83.8 | 85.3 | 85.3 | 85.0 | 85.2 | 85.1 |
| NER | 10 | 59.8 | 62.1 | 65.2 | 66.1 | 64.5 | 66.1 |
| 50 | 71.4 | 71.9 | 72.4 | 72.7 | 72.9 | 73.2 |
| 100 | 73.0 | 73.7 | 74.7 | 74.8 | 74.8 | 74.9 |
| 250 | 76.6 | 77.6 | 77.7 | 77.7 | 77.9 | 77.9 |
| 500 | 78.2 | 79.1 | 79.5 | 79.6 | 79.7 | 79.6 |
| POS | 10 | 79.4 | 79.4 | 79.4 | 79.4 | 80.1 | 80.2 |
| 50 | 84.3 | 84.3 | 84.3 | 84.3 | 84.7 | 84.7 |
| 100 | 85.9 | 85.8 | 85.9 | 85.8 | 86.3 | 86.2 |
| 250 | 87.6 | 87.6 | 87.6 | 87.6 | 87.9 | 87.9 |
| 500 | 88.5 | 88.4 | 88.5 | 88.4 | 88.6 | 88.6 |
+
+Table 4: Multilingual FS-XLT transfer results. Please refer to §5 for details.
\ No newline at end of file
diff --git a/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/images.zip b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..723aaa1447b00f96270a8c4abd3e0fb973b7a40f
--- /dev/null
+++ b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d6ec0414906cb3337acc365a62cbaa0f0a36b74d6c23678dd8634e84707984a6
+size 2436702
diff --git a/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/layout.json b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..bce8ef5c36740479ba96e5bacdc54ec470a5ee97
--- /dev/null
+++ b/dontstopfinetuningontrainingregimesforfewshotcrosslingualtransferwithmultilinguallanguagemodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e0ef09e9457effb835002af52a9b39f892b68fd5b03f3a3aa9d3ccd5f768f909
+size 398405
diff --git a/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_content_list.json b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..f7a34980a9cd5e1c48fb8844eca0af7ac33a7330
--- /dev/null
+++ b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:21e7bc0e0843befbf3c2a04fc451edc0a78799b25c15beae5327275e097e7c66
+size 110446
diff --git a/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_model.json b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..4977ce0cfcf15fa44484a659bb0499fd00470f17
--- /dev/null
+++ b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:83230582cb9e6185e1d2bf5a64709a4b5befa5fd0e30a9a8f120f5ee225ac53d
+size 134339
diff --git a/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_origin.pdf b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..30fc38ed506544cd4db53c08738f064fb333ff92
--- /dev/null
+++ b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/4fddb798-4dcf-4789-a4a1-52c8da7a623e_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:b87a9e5c1a61ebc5e3b8369b0f1466db2b0fc8b53308ecac0a43fd515a2c60d5
+size 821636
diff --git a/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/full.md b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..0dcdcc5cefcfd059005889e9fd8750f32bf0fbdc
--- /dev/null
+++ b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/full.md
@@ -0,0 +1,463 @@
+# Do Vision-and-Language Transformers Learn Grounded Predicate-Noun Dependencies?
+
+Mitja Nikolaus1,2
+mitja.nikolaus@univ-amu.fr
+
+Emmanuelle Salin1 and Stephane Ayache1 and Abdellah Fourtassi1 and Benoit Favre1
+
+$^{1}$ Aix Marseille Univ, Université de Toulon, CNRS, LIS, Marseille, France $^{2}$ Aix-Marseille Univ, CNRS, LPL, Aix-en-Provence, France
+
+# Abstract
+
+Recent advances in vision-and-language modeling have seen the development of Transformer architectures that achieve remarkable performance on multimodal reasoning tasks. Yet, the exact capabilities of these black-box models are still poorly understood. While much of previous work has focused on studying their ability to learn meaning at the word-level, their ability to track syntactic dependencies between words has received less attention.
+
+We take a first step in closing this gap by creating a new multimodal task targeted at evaluating understanding of predicate-noun dependencies in a controlled setup. We evaluate a range of state-of-the-art models and find that their performance on the task varies considerably, with some models performing relatively well and others at chance level. In an effort to explain this variability, our analyses indicate that the quality (and not only sheer quantity) of pretraining data is essential. Additionally, the best performing models leverage fine-grained multimodal pretraining objectives in addition to the standard image-text matching objectives. This study highlights that targeted and controlled evaluations are a crucial step for a precise and rigorous test of the multimodal knowledge of vision-and-language models.
+
+# 1 Introduction
+
+Vision-and-language (V&L) models have recently shown substantial improvement on a range of multimodal reasoning tasks. Taking inspiration from successes in text-only Natural Language Processing (Devlin et al., 2019; Brown et al., 2020), state-of-the-art V&L models are usually composed of a Transformer-based architecture pre-trained in a self-supervised manner on large-scale data, and then fine-tuned on downstream tasks.
+
+While these models show remarkable performance on a range of tasks, more controlled and systematic analyses are necessary in order to obtain
+
+
+Target sentence: A man is wearing a hat.
+Distractor Sentence: A man is wearing glasses.
+Figure 1: We evaluate V&L models on their ability to track predicate-noun dependencies that require a joint understanding of the linguistic and visual modalities. The task is to find the correct sentence (choosing between the target and distractor) that corresponds to the scene in the image. In this example, the models should connect the predicate "is wearing a hat" to "man". A model that does not track dependencies would judge the distractor sentence "A man is wearing glasses" as equally likely, as there is a man is the image, as well as a person that is wearing glasses.
+
+a better understanding of their exact multimodal knowledge.
+
+A range of studies has investigated their ability to map words to their visual referents for nouns (Kazemzadeh et al., 2014; Mao et al., 2016; Shekhar et al., 2017) and verbs (Ronchi and Perona, 2015; Yatskar et al., 2016; Pratt et al., 2020; Hendricks and Nematzadeh, 2021), but there are only a few studies on whether recent V&L models can capture multimodal syntactic dependencies between words and concepts.
+
+In this paper, we explore how well V&L models learn predicate-noun dependencies across modalities (see example in Figure 1). To this end, we create an evaluation set that contains carefully selected images and pairs of sentences with minimal
+
+differences. Given an image and two predicate-noun sentences, the models need to find the correct sentence corresponding to the image. Crucially, they can only succeed by taking into account the dependencies between the visual concepts in the image corresponding to the noun and predicate in the sentence.
+
+As it has been shown that visual reasoning performance in several tasks can be spuriously augmented by capitalizing on textual biases in the training data (Goyal et al., 2017; Agrawal et al., 2018; Hendricks et al., 2018; Cao et al., 2020), we counter-balance our evaluation dataset in a way that controls for such exploitation of linguistic biases.
+
+We evaluate pre-trained state-of-the-art V&L models in a zero-shot setting and find that the ability to track predicate-noun dependencies varies considerably from model to model. Of all models tested, UNITER (Chen et al., 2019) and LXMERT (Tan and Bansal, 2019) show the highest scores, but their performance is still far from optimal. Other models such as ViLBERT (Lu et al., 2019) and CLIP (Radford et al., 2021) perform at chance level. We discuss how differences in the models could explain their performance variability, highlighting the role of pretraining data quality and fine-grained multimodal pretraining objectives.
+
+Code to reproduce the analyses and run the evaluation on new models is publicly available at https://github.com/mitjanikolaus/multimodal-predicate-noun-dependencies.
+
+# 2 Related Work
+
+Targeted evaluation of V&L models Recently, a growing number of tasks have been created for targeted evaluation of V&L models' abilities to perform various multimodal reasoning.
+
+Shekhar et al. (2017) create sets of distractor captions to analyze whether V&L models are sensitive to single word replacements (with a focus on nouns). Similar targeted evaluation datasets have also been proposed for referring expressions (Chen et al., 2020), image-sentence matching (Hu et al., 2019), and Visual Question Answering (VQA; Bogin et al., 2021), with a focus on compositional reasoning.
+
+Tasks such as visual semantic role labeling or situation recognition, typically involve classifying the primary activity depicted in an image, as well as the semantic roles of involved entities (Ronchi and Perona, 2015; Lu et al., 2016; Chao et al., 2015;
+
+Gupta and Malik, 2015; Yatskar et al., 2016; Pratt et al., 2020). While these studies demonstrate that V&L models can learn semantic roles to some degree in a supervised learning setup, such tasks do not allow for a controlled evaluation of models in a zero-shot setting.
+
+In Hendricks and Nematzadeh (2021), the authors evaluate state-of-the-art V&L models in a controlled zero-shot setup and find that they still have more trouble understanding verbs compared to subjects or objects. They also observe that models trained on larger datasets with less descriptive captions perform worse than models trained on smaller, manually-annotated datasets.
+
+Several works have also tried to shed more light on the precise multimodal semantic capabilities of V&L models using probing techniques. Salin et al. (2022) show that although state-of-the-art V&L models can grasp some multimodal concepts such as color, they still do not fully understand more difficult concepts such as object size and position in the image. Parcalabescu et al. (2021) use probing to demonstrate that such models still lack the capability to correctly count entities in an image.
+
+Evaluation of grounded syntax Akula et al. (2020) tests for sensitivity to word order in referring expressions. Similarly, Thrush et al. (2022) studies the ability of V&L models to take word order into account by designing adversarial examples that require differentiating between similar image and text pairs, while the text pairs only differ in their word order. Their results suggest that state-of-the-art models still lack precise compositional reasoning abilities.
+
+Li et al. (2020a) studies so-called syntactic grounding of VisualBERT. They show that certain attention heads of the transformer architecture attend to entities that are connected via syntactic dependency relationships. However, such probing experiments do not necessarily indicate to what degree a model is actually using the encoded information when making predictions.
+
+In our work, we test a range of state-of-the-art models specifically on their ability to track predicate-noun dependencies. Crucially, we test the models in a much more controlled setting compared to previous work: Our setup involves visual distractors as well as control task, disentangling the challenge of understanding syntactic dependencies from more simple object and predicate recognition. Additionally, we strictly control for any possible
+
+linguistic bias by counter-balancing all evaluation examples.
+
+# 3 Methods
+
+# 3.1 Evaluation Dataset
+
+We construct an evaluation dataset that is suited for evaluating the sensitivity to visually grounded predicate-noun dependencies in a zero-shot setup.
+
+The data consists of pairs of triplets, and each triplet consists of an Image $I$ , a target sentence $S_{1}$ , and a distractor sentence $S_{2}$ . Target and distractor sentences are minimal pairs, i.e. one sentence differs from the other only with regard to either the noun (e.g., "A girl is sitting." vs. "A man is sitting.", Figure 2) or the predicate (e.g., "A man is wearing a hat." vs. "A man is wearing glasses.", Figure 1).
+
+Crucially, the images always contain visual distractors, meaning that both the noun and the predicate of the distractor sentence are present in the image, but they do not have a noun-predicate relationship (e.g., for the distractor sentence "A man is wearing glasses", there is a man in the image, who is not wearing glasses, and a person wearing glasses, who is not a man). Thus, it is necessary to take into account the dependency between noun and predicate to distinguish between the target and distractor sentence (Figure 1).
+
+Controlling for linguistic biases V&L models have shown to rely sometimes on textual bias instead of using visual information (Goyal et al., 2017; Agrawal et al., 2018; Hendricks et al., 2018; Cao et al., 2020). For example, if a training dataset contains more often the phrase "a girl is sitting" than "a man is sitting", a model might prefer the caption "a girl is sitting" during evaluation only based on linguistic co-occurrence heuristics, irrespective of the visual content. In our evaluation dataset, we control for potential linguistic biases in the training datasets by pairing every triplet with a corresponding counter-balanced example where target and distractor sentence are flipped. More specifically, for every triplet $(I_1, S_1, S_2)$ , there exists a corresponding triplet $(I_2, S_2, S_1)$ , as depicted in Figure 2. In that way, a model that does not take into account the visual modality cannot succeed in the task (see also Nikolaus and Fourtassi, 2021).
+
+Automatic pre-filtering Our evaluation dataset is based on Open Images (Kuznetsova et al., 2020).
+
+
+Target sentence: A girl is sitting.
+Distractor Sentence: A man is sitting.
+Figure 2: Counter-balanced evaluation: Each triplet has a corresponding counter-example, where target and distractor sentence are flipped.
+
+
+Target sentence: A man is sitting.
+Distractor Sentence: A girl is sitting.
+
+We pre-filter the images based on existing human-annotated object and relationship labels and bounding boxes. The objects refer to persons, animals, as well as inanimate objects. The relationships can either describe an action that an object is engaged in (e.g., WOMAN - SIT), or an action linking two objects (e.g., MAN - WEAR - GLASSES). All nouns in the selected relationships for our dataset refer to persons, due to lack of sufficient annotations for other kinds of agents.
+
+We look for images that contain a target object-relationship pair as well as a distractor object-relationship pair for which either the target and distractor object are the same, but the relationships differ, or vice versa (as in the example in Figure 1). Additional details on the pre-filtering can be found in Appendix A.1.
+
+Manual selection We manually select suitable images after the automated pre-filtering, in order to ensure high quality of each example and in particular to verify that the distractor sentences are indeed incorrect given the images. This step is crucial, because many of the annotations in Open Images are incomplete, and an image may contain, for example, a woman that is sitting but not annotated as such (in this case, we disregard the image for our evaluation set).
+
+We select pairs of examples and counterexamples and ensure that there are no duplicate images within the set of images for each object-relationship pair.
+
+Sentence generation We generate target and distractor sentences based on the verified object and relationship annotations from Open Images.
+
+We construct English sentences using a template-based approach. Given an object and a relationship,
+
+we add the indefinite article (a/an) in front of each noun and use all verbs in present progressive tense as this is most frequent in image-text datasets. For example, from WOMAN - IS - SIT we generate "a woman is sitting"; and from MAN - HOLD - CAMERA "a man is holding a camera".
+
+This template-based approach is necessary for our controlled evaluation. As the choice of the exact template for the construction of the sentences may influence the results2, we evaluate the models, additionally, using a slightly different template, and we show that the overall result patterns remain largely similar (see Appendix A.4.2).
+
+Final evaluation set The final evaluation set contains 2584 triplets. For 1486 of these triplets, the distractor sentence contains an incorrect predicate and for the other 1098 triplets, the distractor contains an incorrect noun. More detailed statistics regarding the number of triplets concerning specific concepts are provided in Appendix A.2.
+
+A note on perceived gender annotations Our evaluation dataset uses annotations from the Open Images dataset, which rely on the physical appearance of persons to annotate their perceived gender. We use the provided annotations, and the resulting biases are unfortunately reproduced in our evaluation set. We discuss this issue in further detail in the Ethics Statement (Section 8).
+
+In Salminen et al. (2018) gender classification from face pictures by human annotators shows an inter annotator agreement greater than $95\%$ . True gender cannot be classified, and high inter-annotator agreement does not imply a correct gender choice, but we expect the gender annotations of Open Images to be reliable enough to be used as a basis for our analyses.
+
+# 3.2 Metric
+
+We evaluate pre-trained models on their image-text matching performance in a zero-shot setting, i.e. without any further training. For each triplet, we test whether the models give a higher similarity score for the correct sentence than for the distractor
+
+sentence. We calculate accuracy for each pair, i.e. the model needs to succeed for both the example and the counter-balanced example triplet.
+
+For each pair of triplets $(t_1, t_2) = ([I_1, S_1, S_2], [I_2, S_2, S_1])$ , we calculate the following score:
+
+$$
+f (t _ {1}, t _ {2}) = \left\{ \begin{array}{l l} 1, & \text {i f} s (I _ {1}, S _ {1}) > s (I _ {1}, S _ {2}) \\ & \text {a n d} s (I _ {2}, S _ {2}) > s (I _ {2}, S _ {1}) \\ 0, & \text {o t h e r w i s e} \end{array} \right.
+$$
+
+where $s(I, S)$ denotes the similarity between an image $I$ and a sentence $S$ . To obtain the similarity score, we use the softmaxed output of the image-text matching pretraining heads of the models.
+
+The final accuracy is the average score over all pairs in the evaluation set. Chance performance is at $25\%$ .4
+
+As the dataset was manually filtered and requires only rather simple understanding of the images, we assume human performance to be close to $100\%$ . To verify this claim, we had a one person annotate a randomly sampled subset of 500 triplets. For each triplet, the annotator was asked to judge which of the two sentences describes the image better. The resulting performance was at $100\%$ .
+
+A topline: the cropped task In order to explore the effect of the visual distractors on this noun-predicate dependency task, we additionally evaluate all models in a cropped task: We reduce the image to the bounding box of the target object. Thus, the cropped image usually only contains the target object, and no more visual distractors (i.e., the referent of the noun or the predicate in the distractor sentence is no longer present in the cropped image). To succeed at this (simpler) task, the model no longer needs to capture the predicate-noun dependency, it just needs to ground the single words correctly. We use this task to estimate how much the performance of the models is affected by the ability to ground nouns and predicates in our evaluation dataset, in comparison to the (more
+
+sophisticated) ability of understanding predicate-noun dependencies.
+
+# 3.3 Models
+
+We consider a range of state-of-the-art V&L models that are pre-trained using text, image, and multimodal pretraining objectives on corpora of parallel image and text data. All models use the transformer architecture (Vaswani et al., 2017), but vary in terms of pretraining data and objectives, image encoders, and multimodal fusion approaches.
+
+In addition to their image and text pretraining objectives, the models commonly make use of an image-text matching objective, where the models are asked to predict whether a given sentence describes an image or not. We leverage the output of the corresponding pretraining head for calculating image-text similarities for our task.
+
+We evaluate LXMERT (Tan and Bansal, 2019), UNITER (Chen et al., 2019), ViLBERT (Lu et al., 2019), Oscar (Li et al., 2020b), VinVL (Zhang et al., 2021), ViLT (Kim et al., 2021), and CLIP (Radford et al., 2021). We could not evaluate the original VL-BERT (Su et al., 2020), because it was not pre-trained using an image-text matching loss. We also did not evaluate the original VisualBERT (Li et al., 2019), as their implementation of the image-text matching loss requires one correct caption (in addition to a possibly faulty caption), which is not available for the Open Images dataset. Both models were however evaluated in the controlled conditions using VOLTA (see Section 4.2).
+
+Pretraining datasets ViLBERT and VL-BERT are pretrained on Conceptual Captions (Sharma et al., 2018). UNITER, LXMERT, ViLT, and VinVL7 make use of additional publicly available datasets such as COCO (Lin et al., 2014), SBU captions (Ordonez et al., 2011), Flickr30K (Young et al., 2014), VisualGenome (Krishna et al., 2017),
+
+6The multimodal pretraining objective of Oscar does not involve matching and mismatching images and descriptions, but only matching and mismatching sequences of object tags. Therefore, we evaluate the checkpoint that has been fine-tuned for image-text retrieval.
+
+${}^{7}$ VinVL is pre-trained on parts of the Open Images dataset, and we found that most images used in our evaluation set are indeed part of the VinVL pretraining dataset. Because of this confound, results of VinVL are not directly comparable to the other models (even though we test the model here with novel sentences with respect to the images). Our results show however that VinVL compares very closely to Oscar, which has the same architecture, suggesting that the access to the images during training does not substantially affect the model's performance. The same confound is possibly present for CLIP, for which the training data is not public
+
+and VQA datasets (Goyal et al., 2017; Zhu et al., 2016; Hudson and Manning, 2019). The original VisualBERT is only pre-trained on COCO. Appendix A.3 details the pretraining datasets for all models as well as their sizes. The pretraining data for CLIP has not been publicly released, the authors state that it consists of 400M image-text pairs from the internet (an order of magnitude more data than for most of the other models, which do not surpass 10M image-text pairs in size).
+
+# 4 Results
+
+# 4.1 Original Implementations
+
+We test all models using the evaluation methods and data described above. We make use of pretrained models made publicly available by the authors.
+
+Resulting accuracies are shown in Table 1. We find that only some models perform substantially above chance, notably ViLT, UNITER and LXMERT. In the cropped task, performance is much higher for all models, with VinVL and ViLT reaching the highest performance. This gap in performance between the full and cropped tasks indicates that while those models can match nouns and predicates in the image with the corresponding words rather well, they struggle to take into account the dependencies between them.
+
+| Model | Accuracy |
| Full | Cropped |
| LXMERT | 0.57 | 0.69 |
| UNITER | 0.54 | 0.64 |
| ViLBERT | 0.28 | 0.66 |
| ViLT | 0.40 | 0.75 |
| Oscar | 0.32 | 0.67 |
| VinVL | 0.30 | 0.76 |
| CLIP | 0.20 | 0.59 |
| Chance | 0.25 | 0.25 |
+
+Table 1: Accuracy of models trained in original conditions when provided the full images and when only exposed to the target object in the cropped task.
+
+# 4.2 Controlled Training Conditions
+
+We additionally evaluate models that are trained in controlled (and therefore more directly comparable) conditions as proposed in the VOLTA framework (Bugliarello et al., 2021). In this setup, all
+
+models are trained on Conceptual Captions using the same pretraining objectives (masked language modeling, masked object classification, and imagedtext matching) and use the same image features, extracted from a Faster R-CNN.
+
+We evaluate all models for which pretrained weights are available. Resulting accuracy scores are presented in Table 2.
+
+| Model | Accuracy |
| Full | Cropped |
| CTRL_UNITER | 0.24 | 0.63 |
| CTRL_LXMERT | 0.20 | 0.56 |
| CTRL_ViLBERT | 0.27 | 0.66 |
| CTRL_VL-BERT | 0.24 | 0.66 |
| CTRL_PhysicalBERT | 0.20 | 0.64 |
| Chance | 0.25 | 0.25 |
+
+Table 2: Accuracy of models trained in controlled conditions when provided the full images and when only exposed to the target object in the cropped task.
+
+We find that under these controlled conditions, all models perform comparably and generally around chance level. It is therefore not straightforward to draw any conclusions regarding the effect of model architecture from these results.
+
+In the cropped task, performance is much higher, with ViLBERT and VL-BERT reaching the highest performance. The performance gap between the two tasks (i.e., full vs. cropped) is substantially larger than for the original implementations, suggesting that the models are even less sensitive to predicate-noun dependencies under these controlled training conditions.
+
+# 5 Analyses and Discussion
+
+# 5.1 Comparing Model Performances
+
+The role of pretraining data Within the set of the evaluated models, we do not find evidence for a correlation between the size of the pretraining dataset and the model's ability to capture predicatenoun dependencies (see also Appendix A.3). Despite being trained on comparable or even larger amounts of data, ViLT, Oscar and VinVL perform substantially worse than LXMERT and UNITER. CLIP performs below chance level, despite having by far the largest pretraining dataset.
+
+The pretraining data of CLIP is not publicly available, but as it was automatically scraped from
+
+the internet we believe the quality (i.e descriptiveness) of its captions to be comparable to that of Conceptual Captions. In additional experiments (see Appendix A.4.1), we study the performance of CLIP models trained on different datasets using a range of publicly available model checkpoints. The performance of CLIP remains below chance level for all tested checkpoints. This might be because all available checkpoints are all trained on rather noisy data, or because the architecture and pretraining objectives of CLIP don't allow it to learn grounded predicate-noun dependencies.
+
+Datasets that are composed of highly descriptive captions seem to be advantageous for the learning of noun-predicate dependencies. Indeed, for datasets such as COCO (Lin et al., 2014) or VQA (Antol et al., 2015), the images are not only strongly associated with the captions or question-answer pairs (as they were crowdsourced specifically for the tasks), but also precise and detailed in nature. In contrast, Conceptual Captions (Sharma et al., 2018) is composed of images with captions that were automatically collected from web pages, and therefore generally rather broad descriptions of the image content.
+
+ViLBERT and models trained in the controlled conditions are only trained using Conceptual Captions, and the resulting performances are around chance level. UNITER and LXMERT perform much worse compared to their original training setups. One main difference for these two models in their original implementation compared to the controlled condition is that they are trained on richer datasets with respect to the language modality, leveraging more descriptive captions.[8]
+
+This observation is coherent with what Hendricks and Nematzadeh (2021) found when studying verb understanding of V&L models: They compare performance of the same model when trained on Conceptual Captions or COCO, and find that the model trained on COCO performs better, despite Conceptual Captions being bigger and closer to the task in terms of image and language distribution.
+
+These results suggest that, when considering multimodal dependencies, having a high quality pretraining dataset with less noise and more de
+
+scriptive textual data could be more important than having a larger dataset. Highly descriptive textual data is essential to learn precise predicate-noun dependencies.
+
+The role of pretraining objectives While models such as ViLT, Oscar, and VinVL are trained on datasets that are comparable in size and quality to those of LXMERT and UNITER, they still perform substantially worse on the task. One explanation could be that contrary to the other models, UNITER and LXMERT both have multimodal pretraining objectives in addition to image-text matching: Visual question answering for LXMERT and word-region alignment for UNITER.9 This could help the models to establish finer multimodal dependencies. Indeed, ViLT and VinVL show better results than UNITER and LXMERT in the cropped task (indicating that their object/predicate recognition performance even surpasses that of the other models), but worse results in the full task. Our hypothesis is that the pretraining objectives of UNITER and LXMERT enable them to learn more fine-grained multimodal dependencies than ViLT and VinVL, even though their performance on the cropped task is worse.10
+
+This gap in performance should not only be due to the training data associated with the additional pretraining objectives, as VinVL also uses data from Visual Question Answering task, but without training on the objective.
+
+The impact of the multimodal pretraining objectives of UNITER and LXMERT can be an additional explanation for the drop in performance of CTRL_UNITER and CTRL_LXMERT, which were only trained using image-text matching as a multimodal pretraining objective. The gap in performance between those controlled models and the original models indicate that using more precise multimodal pretraining objectives and better annotated datasets can greatly improve the learning of multimodal dependencies.
+
+The lack of suitable multimodal pretraining objectives could also offer an explanation for the poor performance of CLIP in our task.
+
+The role of image encoders The authors of ViLT and VinVL motivate their work by suggesting that improved image features are mandatory for improved multimodal reasoning of V&L transformers. Here, we observe that these improved features only translate to better results in the cropped task (where ViLT and VinVL perform best). We speculate that the improved image encoders allow for a better understanding of visual entities, but not necessarily of the dependencies between them. In order to obtain more conclusive interpretations regarding the role of image features, we require more targeted experiments which control for other confounding factors present here (such as different pretraining objectives).
+
+The role of model architecture In addition to the lack of suitable pretraining objectives, the worse performance of CLIP compared to the other models could also be due to the fact that it does not support any kind of inter-modal fusion of features within the model (image and text are processed in separate submodules that do not allow for inter-modal interaction). This shortcoming of CLIP is also discussed in Kim et al. (2021), where the authors find representations from CLIP to be not useful for the more advanced multimodal reasoning task NLVR2 (Suhr et al., 2019).
+
+However, there seems to be no major effect of architecture with respect to multimodal fusion in the case of single and dual stream transformers: LXMERT and UNITER have comparable performances, even though one is dual-stream transformer and the other a single-stream transformer.
+
+# 5.2 Performance for Nouns vs. Predicates
+
+Here, we compare performance for pairs in which the sentences differ with respect to the noun, to sentences with a different predicate. Detailed results for all models are reported in Appendix A.4.3. Overall patterns show a slightly better performance for cases in which the noun was switched, especially in the cropped task. This is in line with findings that V&L models are better at grounding nouns than verbs (Hendricks and Nematzadeh, 2021).
+
+# 5.3 Analysis of individual nouns and predicates
+
+For a given concept (noun or predicate), we consider all pairs that contain this concept in at least one of the two sentences, i.e. cases in which a
+
+model's understanding of a concept is instrumental for making the correct decision.
+
+Figure 3 shows the per-concept accuracies of the best performing model, LXMERT. Appendix A.4.4 shows the per-concept accuracies for all models in their original implementations.
+
+
+
+
+Figure 3: Per-concept accuracies for LXMERT. We display nouns and predicates for which we have at least 10 evaluation triplets. Standard deviation calculated using bootstrapping (100 re-samples).
+
+We observe large variation in accuracy scores of predicates, and less variation for nouns. We could not find any simple reasons that explain the predicates' variability. For example, verbs can have good or bad performances (e.g., "running" vs "talking"), and the same can be said for predicates that are composed of both verb and noun (e.g., "holding a bottle" vs. "wearing a helmet"). That said, factors that may influence model performance on specific nouns or predicates are further discussed in Section 5.4.
+
+Additionally, we observe that for some concepts, the models perform better if the concept is the target, and for others, performance is better if it is the distractor. This is, e.g., the case for the pair "sing" vs "stand", where the models consistently perform better if "sing" is the target predicate. Appendix A.4.5 shows the accuracy for each (target, distractor) concept tuple.
+
+# 5.4 Confounding Factors
+
+Here we discuss possible factors influencing the models' performances.
+
+Object salience In most of the images in our evaluation set, the target and distractor persons in the image are not of equal size, and not equally salient (sometimes one is more in the foreground than the other). We explore whether there is an effect on the models' decisions by correlating the models' predictions with target and distractor bounding box size and location.
+
+More specifically, we measure the difference in similarity for target and distractor sentence $s(I_1, S_1) - s(I_1, S_2)$ and correlate it with the difference in bounding box size of the target and distractor object. Further, we also correlate it with the difference of distances from the center of the image.
+
+For LXMERT, we find no significant correlation (Bounding box size: Pearson $r = -0.03$ , $p = 0.16$ , bounding box distance from center: Pearson $r = 0.03$ , $p = 0.14$ ). Correlation scores for other models can be found in Appendix A.4.6. While there are statistically significant correlations for some models, these are small and of varying direction. The largest correlations are found for CLIP (Bounding box size: Pearson $r = 0.14$ , $p < 0.01$ , bounding box distance from center: Pearson $r = -0.24$ , $p < 0.01$ ), indicating that the performance of CLIP could be affected, to some extent, by object salience.
+
+Concept recognizability We also correlate the models' similarity judgments differences to differences in concept recognizability, which we operationalize by taking the object or attribute confidence score for a given concept in an image from a Faster R-CNN (Ren et al., 2015) trained on VisualGenome.
+
+For most models, we find a small positive correlation (see Appendix A.4.6), indicating that the models' similarity judgments are affected by the varying degree to which the concepts are recognizable in the image.
+
+Linguistic biases Another aspect, already mentioned earlier, is that models' performance could be affected by linguistic biases in the training data, such as the frequency and co-occurrence of words and phrases.
+
+To explore this possible effect, we correlate the difference in similarity for target and distractor sentence with the difference of target and distractor sentence perplexity. We calculate the perplexity for each sentence using a single-modality BERT model (bert-base-uncased), that was fine-tuned for 3 epochs on the textual data of Conceptual Captions.
+
+For LXMERT, we find no significant correlation (Pearson $r = -0.01$ , $p = 0.48$ ). For the other models, we find very small positive correlations (see Appendix A.4.6). We conclude that the models do not rely only on shallow heuristics of the training data in the textual modality.
+
+# 6 Conclusion
+
+This work examines whether state-of-the-art V&L models learn multimodal syntactic dependencies, by focusing on a case study on simple predicate-noun dependencies. Our controlled experiments and analyses on a range of recent models reveal that their capability track such dependencies is variable, with some models (e.g., LXMERT and UNITER) show performance above chance level and others (e.g., CLIP) performing even below chance.
+
+In contrast to the recent trend in the field focused on increasing pretraining data and using simple general-purpose pretraining objectives (Brown et al., 2020; Devlin et al., 2019), here we observe that best performance is achieved, rather, with high-quality pretraining data, and more fine-grained pretraining objectives.
+
+More specifically, our results suggest that multimodal pretraining objectives have a major impact on the model's learning of grounded predicatenoun dependencies. Models that include more targeted objectives such as visual question answering and word region alignment in addition to the general image-text matching objective show better performance. In addition, having highly descriptive pretraining datasets seems to help with learning fine-grained multimodal dependencies. In comparison, models trained on larger, web-scraped datasets do not perform well.
+
+In the future, the proposed highly-controlled evaluation protocol can be used to conduct more targeted studies regarding the role of model architecture, pretraining objectives, as well as training data quality and quantity in order to build V&L models that are better at learning grounded predicate-noun dependencies, and possibly also other, move advanced multimodal reasoning tasks.
+
+# 7 Limitations
+
+While our analyses revealed patterns that seems to explain observed variability in the models' performance, the role of some architectural choices such as image encoding techniques remains ambiguous. A better understanding of all factors influencing the learning of grounded predicate-noun dependencies could be achieved by training sets of models on comparable conditions and by varying only one factor at a time (as done for example in Bugliarello et al., 2021, regarding the role of model architecture).
+
+The range of concepts evaluated is rather small and therefore not representative for the understanding of grounded predicate-noun dependencies in general. More targeted data collection will be necessary in order to obtain more large-scale evaluation datasets. Additionally, our zero-shot evaluation paradigm introduces a possible mismatch between training and evaluation: Models are trained using pairs of images and descriptions where the descriptions often describe all salient parts of the image, whereas in our evaluation set the descriptions focus on only one aspect/person in the image.
+
+In the cropped condition, the images are not are not representative of the typical photographic framing of image-text corpora, which could deteriorate our results. That said, random cropping is a frequent data augmentation technique in computer vision research, where it has been successfully applied to improve generalization performance (Krizhevsky et al., 2012).
+
+Further, some scenes, actions and cultures are disproportionately represented in our evaluation dataset. As proposed in (Liu et al., 2021), it is important to pursue further work on more diverse datasets.
+
+# 8 Ethics Statement
+
+The proposed evaluation set relies on subjective annotations of perceived gender. Attempting to classify gender based on physical appearance is an ill-posed problem (e.g., due to limitations of object detectors, biases of the human annotators). Additionally, the annotations only consider binary gender classes (woman/man, girl/boy). Algorithms that perform such classifications are neither ideal nor desirable, as they perpetuate harmful stereotypes and exclude non-binary gender identities (e.g., Dev et al., 2021; Hamidi et al., 2018; Blodgett et al., 2020; Bender et al., 2021). We explored whether it would be possible to use other classes, but we did not find many examples that would allow for an evaluation of sensitivity to predicate-noun dependencies in a controlled fashion. As our image selection is very constrained (we require a visual distractor, and a counter-example image with reverse properties), we found only sufficient examples for the categories used in the paper. We initially started a bottom-up data exploration in which we considered all labels present in the Open Images dataset, but found only very few examples for a few other categories (generally less than 5 examples after manual filtering). This might be due to the focus of the annotations in Open Images, future work could explore the use of other datasets that are focused on other types of annotations, the main challenge being the requirement for sufficiently large datasets in order to find matching examples and counter-examples. Future efforts should be dedicated to creating datasets that aim at more inclusive annotations.
+
+We acknowledge the severity of these issues, and emphasize that our work does not promote applications of gender classification in downstream tasks, but only uses it as a basis for analysis of existing models.
+
+# 9 Acknowledgements
+
+We thank the anonymous reviewers for their useful comments and feedback.
+
+Research supported by grants ANR-16-CONV0002 (ILCB), ANR-11-LABX-0036 (BLRI), ANR21-CE28-0005-01 (MACOMIC), AMX-19-IET009 (Archimedes Institute) and the Excellence Initiative of Aix-Marseille University (A*MIDEX). This work was performed using HPC resources from GENCI-IDRIS (Grant 2021-[101693]).
+
+# References
+
+Aishwarya Agrawal, Dhruv Batra, Devi Parikh, and Aniruddha Kembhavi. 2018. Don't Just Assume; Look and Answer: Overcoming Priors for Visual Question Answering. pages 4971-4980.
+Arjun Akula, Spandana Gella, Yaser Al-Onaizan, Song-Chun Zhu, and Siva Reddy. 2020. Words Aren't Enough, Their Order Matters: On the Robustness of Grounding Visual Referring Expressions. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6555-6565, Online. Association for Computational Linguistics.
+Stanislaw Antol, Aishwarya Agrawal, Jiasen Lu, Margaret Mitchell, Dhruv Batra, C. Lawrence Zitnick, and Devi Parikh. 2015. VQA: Visual Question Answering. pages 2425-2433.
+Emily M. Bender, Timnit Gebru, Angelina McMillan-Major, and Shmargaret Shmitchell. 2021. On the Dangers of Stochastic Parrots: Can Language Models Be Too Big? In Proceedings of the 2021 ACM Conference on Fairness, Accountability, and Transparency, FAccT '21, pages 610-623, New York, NY, USA. Association for Computing Machinery.
+Su Lin Blodgett, Solon Barocas, Hal Daumé III, and Hanna Wallach. 2020. Language (Technology) is Power: A Critical Survey of "Bias" in NLP. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5454-5476, Online. Association for Computational Linguistics.
+Ben Bogin, Shivanshu Gupta, Matt Gardner, and Jonathan Berant. 2021. COVR: A Test-Bed for Visually Grounded Compositional Generalization with Real Images. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 9824-9846, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language Models are Few-Shot Learners. In Advances in Neural Information Processing Systems, volume 33, pages 1877-1901. Curran Associates, Inc.
+Emanuele Bugliarello, Ryan Cotterell, Naoaki Okazaki, and Desmond Elliott. 2021. Multimodal Pretraining Unmasked: A Meta-Analysis and a Unified Framework of Vision-and-Language BERTs. Transactions of the Association for Computational Linguistics, 9:978-994.
+
+Jize Cao, Zhe Gan, Yu Cheng, Licheng Yu, Yen-Chun Chen, and Jingjing Liu. 2020. Behind the Scene: Revealing the Secrets of Pre-trained Vision-and-Language Models. In Computer Vision – ECCV 2020, Lecture Notes in Computer Science, pages 565–580, Cham. Springer International Publishing.
+Yu-Wei Chao, Zhan Wang, Yugeng He, Jiaxuan Wang, and Jia Deng. 2015. HICO: A Benchmark for Recognizing Human-Object Interactions in Images. pages 1017-1025.
+Yen-Chun Chen, Linjie Li, Licheng Yu, Ahmed El Kholy, Faisal Ahmed, Zhe Gan, Yu Cheng, and Jingjing Liu. 2019. UNITER: Learning Universal Image-Text Representations. page 14.
+Zhenfang Chen, Peng Wang, Lin Ma, Kwan-Yee K. Wong, and Qi Wu. 2020. Cops-Ref: A New Dataset and Task on Compositional Referring Expression Comprehension. pages 10086-10095.
+Sunipa Dev, Masoud Monajatipoor, Anaelia Ovalle, Arjun Subramonian, Jeff Phillips, and Kai-Wei Chang. 2021. Harms of Gender Exclusivity and Challenges in Non-Binary Representation in Language Technologies. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 1968–1994, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Yash Goyal, Tejas Khot, Douglas Summers-Stay, Dhruv Batra, and Devi Parikh. 2017. Making the v in VQA Matter: Elevating the Role of Image Understanding in Visual Question Answering. pages 6904-6913.
+Saurabh Gupta and Jitendra Malik. 2015. Visual Semantic Role Labeling. Technical report. Publication Title: arXiv e-prints ADS Bibcode: 2015arXiv150504474G Type: article.
+Foad Hamidi, Morgan Klaus Scheuerman, and Stacy M. Branham. 2018. Gender Recognition or Gender Reductionism? The Social Implications of Embedded Gender Recognition Systems. In Proceedings of the 2018 CHI Conference on Human Factors in Computing Systems, CHI '18, pages 1-13, New York, NY, USA. Association for Computing Machinery.
+Lisa Anne Hendricks, Kaylee Burns, Kate Saenko, Trevor Darrell, and Anna Rohrbach. 2018. Women also Snowboard: Overcoming Bias in Captioning Models. pages 771-787.
+
+Lisa Anne Hendricks and Aida Nematzadeh. 2021. Probing Image-Language Transformers for Verb Understanding. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 3635-3644, Online. Association for Computational Linguistics.
+Hexiang Hu, Ishan Misra, and Laurens van der Maaten. 2019. Evaluating Text-to-Image Matching using Binary Image Selection (BISON). In 2019 IEEE/CVF International Conference on Computer Vision Workshop (ICCVW), pages 1887-1890, Seoul, Korea (South). IEEE.
+Drew A. Hudson and Christopher D. Manning. 2019. GQA: A New Dataset for Real-World Visual Reasoning and Compositional Question Answering. pages 6700-6709.
+Sahar Kazemzadeh, Vicente Ordonez, Mark Matten, and Tamara Berg. 2014. ReferItGame: Referring to Objects in Photographs of Natural Scenes. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 787-798, Doha, Qatar. Association for Computational Linguistics.
+Wonjae Kim, Bokyung Son, and Ildoo Kim. 2021. ViLT: Vision-and-Language Transformer Without Convolution or Region Supervision. In Proceedings of the 38th International Conference on Machine Learning, pages 5583-5594. PMLR. ISSN: 2640-3498.
+Ranjay Krishna, Yuke Zhu, Oliver Groth, Justin Johnson, Kenji Hata, Joshua Kravitz, Stephanie Chen, Yannis Kalantidis, Li-Jia Li, David A. Shamma, Michael S. Bernstein, and Li Fei-Fei. 2017. Visual Genome: Connecting Language and Vision Using Crowdsourced Dense Image Annotations. International Journal of Computer Vision, 123(1):32-73.
+Alex Krizhevsky, Ilya Sutskever, and Geoffrey E Hinton. 2012. ImageNet Classification with Deep Convolutional Neural Networks. In Advances in Neural Information Processing Systems, volume 25. Curran Associates, Inc.
+Alina Kuznetsova, Hassan Rom, Neil Alldrin, Jasper Uijlings, Ivan Krasin, Jordi Pont-Tuset, Shahab Kamali, Stefan Popov, Matteo Malloci, Alexander Kolesnikov, Tom Duerig, and Vittorio Ferrari. 2020. The Open Images Dataset V4. International Journal of Computer Vision, 128(7):1956-1981.
+Lianian Harold Li, Mark Yatskar, Da Yin, Cho-Jui Hsieh, and Kai-Wei Chang. 2019. VisualBERT: A Simple and Performant Baseline for Vision and Language. arXiv:1908.03557 [cs]. ArXiv: 1908.03557.
+Lianian Harold Li, Mark Yatskar, Da Yin, Cho-Jui Hsieh, and Kai-Wei Chang. 2020a. What Does BERT with Vision Look At? In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5265-5275, Online. Association for Computational Linguistics.
+
+Xiujun Li, Xi Yin, Chunyuan Li, Pengchuan Zhang, Xiaowei Hu, Lei Zhang, Lijuan Wang, Houdong Hu, Li Dong, Furu Wei, Yejin Choi, and Jianfeng Gao. 2020b. Oscar: Object-Semantics Aligned Pretraining for Vision-Language Tasks. In Computer Vision - ECCV 2020, pages 121-137, Cham. Springer International Publishing.
+Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dólar, and C. Lawrence Zitnick. 2014. Microsoft COCO: Common Objects in Context. In Computer Vision – ECCV 2014, volume 8693, pages 740–755. Springer International Publishing, Cham. Series Title: Lecture Notes in Computer Science.
+Fangyu Liu, Emanuele Bugliarello, Edoardo Maria Ponti, Siva Reddy, Nigel Collier, and Desmond Eliott. 2021. Visually Grounded Reasoning across Languages and Cultures. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 10467-10485, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Cewu Lu, Ranjay Krishna, Michael Bernstein, and Li Fei-Fei. 2016. Visual Relationship Detection with Language Priors. In Computer Vision - ECCV 2016, Lecture Notes in Computer Science, pages 852-869, Cham. Springer International Publishing.
+Jiasen Lu, Dhruv Batra, Devi Parikh, and Stefan Lee. 2019. ViLBERT: Pretraining Task-Agnostic Visi-olinguistic Representations for Vision-and-Language Tasks. In Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc.
+Junhua Mao, Jonathan Huang, Alexander Toshev, Oana Camburu, Alan L. Yuille, and Kevin Murphy. 2016. Generation and Comprehension of Unambiguous Object Descriptions. pages 11-20.
+Mitja Nikolaus and Abdellah Fourtassi. 2021. Evaluating the Acquisition of Semantic Knowledge from Cross-situational Learning in Artificial Neural Networks. In Proceedings of the Workshop on Cognitive Modeling and Computational Linguistics, pages 200-210, Online. Association for Computational Linguistics.
+Vicente Ordonez, Girish Kulkarni, and Tamara Berg. 2011. Im2Text: Describing Images Using 1 Million Captioned Photographs. In Advances in Neural Information Processing Systems, volume 24. Curran Associates, Inc.
+Letitia Parcalabescu, Albert Gatt, Anette Frank, and Iacer Calixto. 2021. Seeing past words: Testing the cross-modal capabilities of pretrained V&L models on counting tasks. In Proceedings of the 1st Workshop on Multimodal Semantic Representations (MMSR), pages 32-44, Groningen, Netherlands (Online). Association for Computational Linguistics.
+
+Sarah Pratt, Mark Yatskar, Luca Weihs, Ali Farhadi, and Aniruddha Kembhavi. 2020. Grounded Situation Recognition. arXiv:2003.12058 [cs]. ArXiv: 2003.12058.
+Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. 2021. Learning Transferable Visual Models From Natural Language Supervision. Proceedings of the 38th International Conference on Machine Learning, page 16.
+Abhilasha Ravichander, Eduard Hovy, Kaheer Suleman, Adam Trischler, and Jackie Chi Kit Cheung. 2020. On the Systematicity of Probing Contextualized Word Representations: The Case of Hypernymy in BERT. In Proceedings of the Ninth Joint Conference on Lexical and Computational Semantics, pages 88-102, Barcelona, Spain (Online). Association for Computational Linguistics.
+Shaoqing Ren, Kaiming He, Ross Girshick, and Jian Sun. 2015. Faster R-CNN: Towards Real-Time Object Detection with Region Proposal Networks. In Advances in Neural Information Processing Systems, volume 28. Curran Associates, Inc.
+Matteo Ruggero Ronchi and Pietro Perona. 2015. Describing Common Human Visual Actions in Images. arXiv:1506.02203 [cs]. ArXiv: 1506.02203.
+Emmanuelle Salin, Badreddine Farah, Stéphane Ayache, and Benoit Favre. 2022. Are Vision-Language Transformers Learning Multimodal Representations? A Probing Perspective. AAAI.
+Joni O. Salminen, Hind A. Al-Merekhi, Partha Dey, and Bernard J. Jansen. 2018. Inter-Rater Agreement for Social Computing Studies. In 2018 Fifth International Conference on Social Networks Analysis, Management and Security (SNAMS), pages 80-87.
+Piyush Sharma, Nan Ding, Sebastian Goodman, and Radu Soricut. 2018. Conceptual Captions: A Cleaned, Hypernymed, Image Alt-text Dataset For Automatic Image Captioning. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2556-2565, Melbourne, Australia. Association for Computational Linguistics.
+Ravi Shekhar, Sandro Pezzelle, Yauhen Klimovich, Aurelie Herbelot, Moin Nabi, Enver Sangineto, and Raffaella Bernardi. 2017. FOIL it! Find One mismatch between Image and Language caption. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 255-265, Vancouver, Canada. Association for Computational Linguistics.
+Weijie Su, Xizhou Zhu, Yue Cao, Bin Li, Lewei Lu, Furu Wei, and Jifeng Dai. 2020. VL-BERT: Pretraining of Generic Visual-Linguistic Representations.
+
+Alane Suhr, Stephanie Zhou, Ally Zhang, Iris Zhang, Huajun Bai, and Yoav Artzi. 2019. A Corpus for Reasoning about Natural Language Grounded in Photographs. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6418-6428, Florence, Italy. Association for Computational Linguistics.
+Hao Tan and Mohit Bansal. 2019. LXMERT: Learning Cross-Modality Encoder Representations from Transformers. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 5100–5111, Hong Kong, China. Association for Computational Linguistics.
+Tristan Thrush, Ryan Jiang, Max Bartolo, Amanpreet Singh, Adina Williams, Douwe Kiela, and Candace Ross. 2022. Winoground: Probing Vision and Language Models for Visio-Linguistic Compositionality. arXiv:2204.03162 [cs]. ArXiv: 2204.03162.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is All
+
+you Need. In Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc.
+Mark Yatskar, Luke Zettlemoyer, and Ali Farhadi. 2016. Situation Recognition: Visual Semantic Role Labeling for Image Understanding. In 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pages 5534-5542, Las Vegas, NV, USA. IEEE.
+Peter Young, Alice Lai, Micah Hodosh, and Julia Hockenmaier. 2014. From image descriptions to visual denotations: New similarity metrics for semantic inference over event descriptions. Transactions of the Association for Computational Linguistics, 2:67-78.
+Pengchuan Zhang, Xiujun Li, Xiaowei Hu, Jianwei Yang, Lei Zhang, Lijuan Wang, Yejin Choi, and Jianfeng Gao. 2021. VinVL: Revisiting Visual Representations in Vision-Language Models. pages 5579-5588.
+Yuke Zhu, Oliver Groth, Michael Bernstein, and Li Fei-Fei. 2016. Visual7W: Grounded Question Answering in Images. pages 4995-5004.
+
+# A Appendix
+
+# A.1 Image Pre-Filtering
+
+We consider labels that occur at least 100 times in the dataset.
+
+As some labels are similar and sometimes used interchangeably by the annotators, we create groups of synonyms for some labels and treat labels within a group as identical in the following. The groups of synonyms can be found in Table 3.
+
+Further, we verify that the bounding boxes of the target and distractor objects are big enough (at least $20\%$ width and $20\%$ height of the image) and that the bounding box sizes of target and distractor objects don't differ by more than a factor of 2.
+
+Finally, we ensure that there is at least one counter-example for each triplet before starting the manual image selection phase.
+
+"Table", "Desk", "Coffee table"
+
+"Mug", "Coffee cup"
+
+"Glasses", "Sunglasses", "Goggles"
+
+"Sun hat", "Fedora", "Cowboy hat", "Sombrero"
+
+"Bicycle helmet", "Football helmet"
+
+"High heels", "Sandal", "Boot"
+
+"Racket", "Tennis racket", "Table tennis racket"
+
+"Crown", "Tiara"
+
+"Handbag", "Briefcase"
+
+"Cart", "Golf cart"
+
+"Tree", "Palm tree"
+
+"Football", "Volleyball (Ball)", "Rugby ball", "Cricket ball", Tennis ball
+
+Table 3: Groups of label synonyms. Each line corresponds to one group.
+
+# A.2 Dataset statistics
+
+Figure 4 shows the number of triplets for each noun and predicate. For a given noun or predicate, we count all pairs that contain this concept in at least one of the two sentences, i.e. cases in which correct understanding of a concept is useful for making the correct decisions.
+
+# A.3 Details on V&L Models
+
+# A.3.1 Pretraining Datasets
+
+Table 4 details the multimodal datasets used for V&L models. Dataset sizes as reported in the corresponding papers. Note that these sizes are also affected by the fact that some models leverage validation sets for pretraining, while others constrain
+
+
+Figure 4: Number of triplets per concept. Note that the x-axis is on logarithmic scale.
+
+the data to the training sets. Also, different approaches for dataset overlap detection have been applied. The pretraining data size for CLIP is reportedly 400M image-text pairs.
+
+# A.3.2 Number of parameters
+
+Table 5 compares the number of trainable parameters for each model that was tested in their original implementations.
+
+# A.4 Additional Analyses
+
+# A.4.1 Results for CLIP with varying pretraining data
+
+Table 6 presents the accuracy scores of multiple publicly available checkpoints for CLIP trained on different training data.
+
+| Model | CC | COCO | SBU | VG | QA | F30K | OI | Total size |
| # images | # image-text pairs |
| LXMERT | | ✓ | | ✓ | ✓ | | | 0.18M | 9.18M |
| UNITER | ✓ | ✓ | ✓ | ✓ | | | | 4.16M | 9.59M |
| ViLBERT | ✓ | | | | | | | 3.10M | 3.10M |
| ViLT | ✓ | ✓ | ✓ | ✓ | | | | 4.05M | 9.85M |
| Oscar | ✓ | ✓ | ✓ | | ✓ | ✓ | | 4.10M | 6.50M |
| VinVL | ✓ | ✓ | ✓ | | ✓ | ✓ | ✓ | 5.65M | 8.85M |
+
+Table 4: Pretraining datasets of the tested models: CC (Conceptual Captions; Sharma et al., 2018), COCO (Lin et al., 2014), SBU captions (Ordonez et al., 2011), VG (Krishna et al., 2017, Visual Genome); F30K (Flickr 30K; Young et al., 2014), OI (Open Images), and QA (including VQA2.0 (Goyal et al., 2017), GQA (Hudson and Manning, 2019), and VG-QA (Zhu et al., 2016)).
+
+| Model | # Parameters |
| LXMERT | 228,051,752 |
| UNITER | 112,938,887 |
| ViLBERT | 250,044,029 |
| ViLT | 111,596,546 |
| Oscar | 111,062,018 |
| VinVL | 111,686,973 |
| CLIP | 151,277,313 |
+
+Table 5: Number of parameters for each model.
+
+| Visual Encoder | Dataset | Accuracy |
| RN101 | YFCC-15M | 0.18 |
| RN101 | 400M | 0.21 |
| RN50 | cc12m | 0.18 |
| RN50 | 400M | 0.20 |
| RN50 | YFCC-15M | 0.17 |
| ViT-B-32 | aion2b_e16 | 0.21 |
| ViT-B-32 | laion400m_e31 | 0.20 |
| ViT-B-32 | laion400m_e32 | 0.19 |
| ViT-B-32 | 400M | 0.20 |
| ViT-L-14 | 400M (336px) | 0.20 |
+
+# A.4.2 Controlling for linguistic robustness
+
+As the sentences used in our evaluation dataset are built from a template, they do not vary in syntax. We verify that results obtained do not depend on the exact template chosen.
+
+We vary the original templates by using the definite article ("the") at the beginning of sentences, and using verbs in simple present instead of present progressive tense (e.g., "the woman sits." or "the man holds a camera").
+
+Results with these alternative sentences are show in Table 7. We find that overall result patterns are highly similar to those with the original sentences in Table 1.
+
+Table 6: Accuracy (Full) of CLIP models with varying visual encoders and pretraining data.
+
+| Model | Accuracy |
| Full | Cropped |
| LXMERT | 0.55 | 0.70 |
| UNITER | 0.54 | 0.66 |
| ViLBERT | 0.26 | 0.67 |
| ViLT | 0.34 | 0.72 |
| Oscar | 0.32 | 0.65 |
| VinVL | 0.30 | 0.74 |
| CLIP | 0.21 | 0.58 |
+
+Table 7: Results with alternative sentences.
+
+# A.4.3 Switching noun vs. switching predicate
+
+Table 8 presents the accuracy for cases in which target and distractor sentence differ with respect to the predicate, or noun. We report scores for all models in their original implementations.
+
+# A.4.4 Analysis of individual nouns and predicates for all models
+
+Figure 5 shows the accuracies for split up for the different predicates and nouns for all models. For more details, refer to Section 5.3.
+
+# A.4.5 Accuracies for (target, distractor) tuples
+
+Figure 6 shows the accuracy for target-distractor tuples for all models.
+
+# A.4.6 Confounding Factors
+
+In Table 9 we show the correlation scores for several confounding factors as described in Section 5.4.
+
+| Model | Full | Cropped |
| Noun | Predicate | Noun | Predicate |
| LXMERT | 0.60 | 0.55 | 0.78 | 0.62 |
| UNITER | 0.60 | 0.50 | 0.76 | 0.56 |
| ViLBERT | 0.27 | 0.28 | 0.74 | 0.59 |
| ViLT | 0.44 | 0.37 | 0.80 | 0.72 |
| Oscar | 0.36 | 0.30 | 0.75 | 0.62 |
| VinVL | 0.33 | 0.28 | 0.83 | 0.71 |
| CLIP | 0.21 | 0.19 | 0.69 | 0.52 |
+
+Table 8: Accuracy of models for cases in which the distractor sentence contains a different noun, or a different predicate.
+
+| Model | Bounding box size | Distance from center | Perplexity | Object detector confidence |
| LXMERT | -0.03 (p=0.12) | 0.03 (p=0.08) | -0.01 (p=0.48) | 0.30 (p=0.00) |
| UNITER | -0.09 (p=0.00) | 0.09 (p=0.00) | 0.05 (p=0.01) | 0.26 (p=0.00) |
| ViLBERT | 0.11 (p=0.00) | -0.16 (p=0.00) | 0.05 (p=0.02) | 0.22 (p=0.00) |
| ViLT | -0.01 (p=0.73) | 0.03 (p=0.13) | 0.05 (p=0.02) | 0.26 (p=0.00) |
| Oscar | 0.12 (p=0.00) | -0.17 (p=0.00) | 0.06 (p=0.00) | 0.15 (p=0.00) |
| VinVL | 0.12 (p=0.00) | -0.12 (p=0.00) | 0.05 (p=0.01) | 0.04 (p=0.05) |
| CLIP | 0.14 (p=0.00) | -0.24 (p=0.00) | 0.08 (p=0.00) | 0.17 (p=0.00) |
+
+Table 9: Correlations between difference in similarity and various factors related to targets and distractors: difference in bounding box size, distance from the image center of the bounding boxes, perplexity, and confidence scores of the bounding box as calculated using a Faster R-CNN object detector model.
+
+
+
+
+Figure 5: Per-concept accuracies for all models. We display nouns and predicates for which we have at least 10 evaluation triplets. Standard deviation calculated using bootstrapping (100 re-samples).
+
+
+Figure 6: Accuracy for (target, distractor) tuples for all models. We display tuples for which we have at least 10 evaluation triplets. Note that chance performance is at 0.5, because we report per-triplet (and not per-pair) accuracy.
\ No newline at end of file
diff --git a/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/images.zip b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..5259dff6304cc50a0376ef588b1f8f8017df9dce
--- /dev/null
+++ b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:16149908aca4f981098bf5355c192bd92e03ae8834899329567ea1db1aaef392
+size 838337
diff --git a/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/layout.json b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2850e46c11be0dc8160b35d66ffd0a8f1f0cd145
--- /dev/null
+++ b/dovisionandlanguagetransformerslearngroundedpredicatenoundependencies/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ca6a7df4c45861f1e119a2312ccb91c7f78af8acedaf5c34c63e12ed1e38bb57
+size 453383
diff --git a/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_content_list.json b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..8908739f7aa011d7f422f6cc7de1a04c07c9b6ae
--- /dev/null
+++ b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8f4100860aaad9c873a0394838706c15e9706a8cae3c7abaa0fb98077a15eadf
+size 76572
diff --git a/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_model.json b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..c9a56dcd6122bda058db64986fe7a91879e3a147
--- /dev/null
+++ b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9ecb0eda8824898438e05959fa4a09ffc64c7ccbc33d712887abf652dba0012f
+size 89676
diff --git a/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_origin.pdf b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..666925af184dc31256706eea86222bc6aa8dfca8
--- /dev/null
+++ b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/b6d3e407-6834-4b97-aec9-abb012ba7d1d_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:eaa309cf371c7d81bfc156950ba73723564e3cff415d25c026f2c217feb37c72
+size 2513270
diff --git a/dropmixatextualdataaugmentationcombiningdropoutwithmixup/full.md b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..28748926a67969dca41ed067737dd27efd40bb16
--- /dev/null
+++ b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/full.md
@@ -0,0 +1,316 @@
+# DropMix: A Textual Data Augmentation Combining Dropout with Mixup
+
+Fanshuang Kong $^{1}$ , Richong Zhang $^{1,2}$ , Xiaohui Guo $^{3}$ , Samuel Mensah $^{4}$ , Yongyi Mao $^{5}$
+
+$^{1}$ SKLSDE, Beihang University, Beijing, China
+
+$^{2}$ Zhongguancun Laboratory, Beijing, China
+
+$^{3}$ Hangzhou Innovation Institute, Beihang University, Hangzhou, China
+
+$^{4}$ Department of Computer Science, University of Sheffield, UK
+
+$^{5}$ School of Electrical Engineering and Computer Science, University of Ottawa, Canada
+
+{kongfs,zhangrc,guoxh}@act.buaa.edu.cn
+
+s.mensah@sheffield.ac.uk, ymao@uottawa.ca
+
+# Abstract
+
+Overfitting is a common problem when there is insufficient data to train deep neural networks in machine learning tasks. Data augmentation regularization methods such as Dropout, Mixup, and their enhanced variants, are effective and prevalent, and achieve promising performance to overcome overfitting. However, in text learning, most of the existing regularization approaches merely adopt ideas from computer vision without considering the importance of dimensionality in natural language processing. In this paper, we argue that the property is essential to overcome overfitting in text learning. Accordingly, we present a saliency map informed textual data augmentation and regularization framework, which combines Dropout and Mixup, namely DropMix, to mitigate the overfitting problem in text learning. In addition, we design a procedure that drops and patches fine grained shapes of the saliency map under the DropMix framework to enhance regularization. Empirical studies confirm the effectiveness of the proposed approach on 12 text classification tasks.
+
+# 1 Introduction
+
+Deep neural networks have shown its effectiveness, achieving state-of-the-art result in many natural language processing (NLP) tasks. However, these models are likely to overfit training sets with few samples due to the large number of parameters they contain. Regularization techniques, such as weighted decay (Krogh and Hertz, 1992), dropout (Srivastava et al., 2014), and data augmentation (Goodfellow et al., 2015; Zhang et al., 2017) are powerful to overcome overfitting by making slight modifications on the neural network or data space to improve generalization.
+
+Data augmentation methods have shown to be useful for overcoming overfitting by increasing the
+
+| XA | Food in this restaurant is delicious | P |
| XB | The environment is bad | N |
| XC | Food in this restaurant bad delicious | 0.83P |
+
+Table 1: Illustration of an example $X_{C}$ generated by SSMix. The darker the red (or blue) shade is, the more salient the words in the positive (or negative) sentiment decision. SSMix uses a Saliency Map (Simonyan et al., 2013) to measure the saliency of words. SSMix substitute the least salient word "is" in $X_{A}$ with the most salient "bad" in $X_{B}$ . The mixup ratio $\lambda = 0.17$ as the length of the salient words (i.e., "bad") is one out of six words in $X_{C}$ . Thus, the generated label is $17\%$ negative or $83\%$ positive.
+
+training dataset size via adding augmented versions of already existing training data. For example, Goodfellow et al. (2015) adds the worst case adversarial sample into the training dataset; Mixup (Zhang et al., 2017) introduces new samples by the linear interpolation of samples and their corresponding labels. The majority of these methods are however designed for computer vision tasks, requiring adaptation for text learning. However, due to the discreteness and high-dimensional nature of text data spaces, adapting these methods is non-trivial.
+
+Among the proposed data augmentation methods, Mixup's linearity inductive bias is succinct and effective since it reduces the discreteness in between samples or the space in which new samples are generated. Thus, motivating researchers to adapt this method for text learning (Verma et al., 2019; Chen et al., 2020; Zhang et al., 2020; Yoon et al., 2021). The current state-of-the-art SS-Mix (Yoon et al., 2021) which builds upon Mixup, generates new samples by performing a saliency-based span mixup on the input text rather than its embedding vectors as like previous approaches (Verma et al., 2019; Guo et al., 2019). As shown in a text sentiment classification task (Table 1), SS-Mix replaces the least salient span in $X_{A}$ with the
+
+most salient span in $X_{B}$ to generate the new sample $X_{C}$ and uses a mixup ratio $\lambda$ to determine the label $X_{C}$ .
+
+Unfortunately, three problems concurrently occur in SSMix which limits its ability to generate expressive examples. Firstly, although SSMix has a strong flexibility by exploring a larger synthetic space to generate new samples, this space is in fact high-dimensional as the input data consists of words rather than embeddings. Besides, words within this space is disordered and therefore may lead to unpredictable sampling results. This leads to the second and third problems, where there is a potential of generating "dirty" examples or causing a label drift (i.e., newly added sample is categorized under a wrong class), as it does not consider the position of words or the sentence syntax structure in the mixup. For instance, $X_{C}$ can be said to be dirty. Besides being wrong grammatically, the generated example contains contrasting opinion words (i.e., "bad", "delicious") offering confusing clues to determine its label.
+
+To tackle the aforementioned issues, we propose a patch-aware DropMix framework, a data augmentation method which takes advantage of Dropout and Mixup, to generate new examples based on the dimension and saliency of words in texts. In contrast to SSMix, DropMix maps the high-dimensional input data (i.e., words) into a low-dimensional space to encode the semantics of the text input and mitigate the unpredictability of generated examples. Despite the problems encountered by SSMix, empirical results indicate that sampling from a large synthetic space may have some benefits. This may be intuitively desirable, as the model is not constrained to generate examples from only the input text representations. To compensate for this, DropMix applies Dropout on the embeddings of $X_{A}$ (and $X_{B}$ ) and replaces the dropped out units with noise from $X_{B}$ (and $X_{A}$ ) to reduce the overdependence on the input features. However, since the saliency of words in texts impacts the class decision, the activation neurons in the features to be dropped depends on the saliency with a Beta prior (or drop ratio). In other words, we present a general patch-aware DropMix framework that drops a patch surrounding the peak salient region of one text input embedding and mixes it with the corresponding patch of another text input embedding to generate new examples. Under this framework, we develop other variants of DropMix that mixes
+
+text input embeddings using different fine-grained patches based on the saliency and dimension of words in text.
+
+In a nutshell, we make the following contributions in this paper:
+
+- We propose a unified framework DropMix, which leverages dropout and mixup for data augmentation and regularization in natural language processing tasks.
+- Under this framework, we propose an efficient fine grained patch selection for the mixup, with three other variants for the text augmentation.
+- Empirical studies on 12 commonly used datasets in text classification confirms the effectiveness of our model.
+
+# 2 Related Work
+
+A variety of regularization techniques have been proposed to solve overfitting in deep neural networks (Zhang et al., 2017; Yun et al., 2019; Verma et al., 2019). Some of the notable and recent methods include, Vanilla Mixup (Zhang et al., 2017) which linearly interpolates two input samples and their associated labels to generate augmented versions for regularization. CutMix (Yun et al., 2019) cuts and pastes image patches to construct new examples, and mixes the labels in proportion to the cut patch sizes. Manifold Mixup (Verma et al., 2019) on the other hand interpolates the middle hidden layers' feature maps. PatchUp (Faramarzi et al., 2020) proposes a method of patches swap or interpolation on the hidden layer feature maps. SaliencyMix (Uddin et al., 2021) mixes a target image with a saliency map (Simonyan et al., 2013) of the source image that highlights important objects. Although the majority of these approaches were designed for vision tasks, they have been widely adopted for NLP (Guo et al., 2019; Verma et al., 2019; Yoon et al., 2021).
+
+In the context of text classification, Mixup regularization variants including, wordMixup and sen-Mixup (Guo et al., 2019) perform interpolation on the word and sentence embeddings. Guo et al. (2019) shows that Mixup can improve the accuracy upon both CNN and LSTM sentence classification models. MixText (Chen et al., 2020) extends the hidden layer feature interpolation method to semi-supervised text classification task. To overcome the
+
+mixing difficulty in the discrete text input spaces, SeqMix (Zhang et al., 2020) performs token-level interpolation in the embedding space and selects a token closest to the interpolated embedding. SS-Mix (Yoon et al., 2021) performs mixup operation on the input text rather than hidden vectors as like previous methods (Guo et al., 2019; Chen et al., 2020; Zhang et al., 2020). Specifically, SSMix synthesizes a sentence while preserving the locality of two original texts by relying on high saliency span-based mixing. This work is closely related to our methods, but we argue that the synthesis sanity of its input word level mixup rather generates "dirty" samples.
+
+# 3 Preliminaries
+
+Our proposed model, DropMix, builds upon notable works (Srivastava et al., 2014; Guo et al., 2019) relating to data augmentation for text classification. Specifically, given a text $\pmb{x} = [x_{1}, x_{2}, \dots, x_{N}]$ with $N$ words, $\pmb{x}$ is typically represented as low-dimensional features $\mathbf{X} \in \mathbb{R}^{N \times D}$ , generated through an encoder such as Bert (Devlin et al., 2018). A classifier takes $\mathbf{X}$ as input and maps it to one or more class labels $Y$ . To improve the classification problem, conventional data augmentation methods such as Dropout (Srivastava et al., 2014) and Mixup (Guo et al., 2019) have been utilized to encourage generalization. Here, we describe the basics of these data augmentation methods as they are fundamental to our approach.
+
+# 3.1 Dropout
+
+Dropout (Srivastava et al., 2014) is a classical regularization scheme which works by randomly dropping inputs of a layer during training, which may be the neurons of a neural network or the features (or units) of the data sample. For text classification, randomly dropping features of the data sample refers to applying a dropout on the word embedding layer to generate an augmented version of $\mathbf{X}$ , denoted as $\widetilde{\mathbf{X}}$ and formulated as follows:
+
+$$
+\widetilde {\mathbf {X}} = \mathbf {M} \odot \mathbf {X}, \quad \widetilde {Y} = Y
+$$
+
+where $\mathbf{M} \in \mathbb{R}^{N \times D}$ is a mask matrix with entry $\mathbf{M}_{ij} \sim \text{Bernoulli}(p)$ . $p$ is a dropout ratio. The operator $\odot$ denotes an element-wise product. The new label $\widetilde{Y}$ of $\widetilde{\mathbf{X}}$ remains unchanged. With Dropout, the over-dependence on the input features is reduced to encourage the learning model to generalize.
+
+
+Figure 1: Overall process of DropMix. The darker the red shade, the more salient the units in $\mathbf{I}_A$ and $\mathbf{F}_A$ . With the mask matrix $\mathbf{M}$ , black units represent 1 and white units represent 0.
+
+# 3.2 Mixup
+
+Mixup is a data augmentation method that generates new training data $(\widetilde{\mathbf{X}},\widetilde{Y})$ by linearly interpolating a pair of random inputs, $\mathbf{X}_A$ and $\mathbf{X}_B$ , and their corresponding labels $\mathbf{Y}_A$ and $\mathbf{Y}_B$ .
+
+$$
+\underset {\sim} {\tilde {\mathbf {X}}} = (1 - \lambda) \mathbf {X} _ {A} + \lambda \mathbf {X} _ {B} \tag {1}
+$$
+
+$$
+\widetilde {Y} = (1 - \lambda) Y _ {A} + \lambda Y _ {B}
+$$
+
+where $\lambda$ is beta-distributed with parameter $\alpha$ , denoted by $\lambda \sim \text{Beta}(\alpha, \alpha)$ . By generating such samples, Mixup encourages a model to behave linearly in-between training samples to improve generalization. We refer the reader to the standard source (Guo et al., 2019) for a detailed review on Mixup.
+
+# 4 DropMix for Text Augmentation
+
+In this paper we combine the advantages of Dropout and Mixup to develop a new approach for data augmentation, namely, DropMix (Fig. 1). Specifically, DropMix encourages a model to reduce the over-dependence on input units while behaving non-linearly in-between training samples. The idea is to dropout units in $\mathbf{X}_A$ and replace their positions with corresponding units in $\mathbf{X}_B$ based on the saliency of the units. We define the augmentation approach as follows:
+
+$$
+\begin{array}{l} \widetilde {\mathbf {X}} = (1 - \mathbf {M}) \odot \mathbf {X} _ {A} + \mathbf {M} \odot \mathbf {X} _ {B} \\ \sim \end{array} \tag {2}
+$$
+
+$$
+\widetilde {Y} = (1 - \lambda) Y _ {A} + \lambda Y _ {B}
+$$
+
+where $\lambda \sim Beta(\alpha, \alpha)$ . $\mathbf{M} \in \mathbb{R}^{N \times D}$ is constrained on $\lambda$ , thus, $\lambda ND$ units of $\mathbf{X}_A$ is replaced by the units in $\mathbf{X}_B$ .
+
+Typically, the mask matrix $\mathbf{M}$ is generated randomly by setting units to 0. This works for Dropout because it significantly reduces the overdependence on input units without focusing on any particular unit. However, our approach is more concerned with the model's dependency on the saliency on both inputs $\mathbf{X}_A$ and $\mathbf{X}_B$ . Hence, rather than random sampling, we develop algorithms that identify the salient units of $\mathbf{X}_A$ to construct $\mathbf{M}$ . That is, the resulting features $\widetilde{\mathbf{X}}$ becomes a mixture of $\mathbf{X}_A$ and $\mathbf{X}_B$ which considers the saliency of both inputs into account.
+
+# 4.1 Patch Selection and Mixing
+
+In order to determine the salient units in $\mathbf{X}_A$ , we use a saliency map (Simonyan et al., 2013), denoted as $\mathbf{I}_A \in \mathbb{R}^{N \times D}$ . Specifically, each unit in $\mathbf{I}_A$ is the magnitude of the derivative of classification loss w.r.t its corresponding feature in $\mathbf{X}_A$ , found through back-propagation. The saliency map (or saliency matrix) highlights the important units that affect the text classification decision.
+
+We now aim to extract patches of the saliency map for the mixup. To this end, we first use sliding filter windows with size $n \times d$ , where $n \in \{1,2,\dots,N\}$ and $d \in \{1,2,\dots,D\}$ and perform a convolution over the saliency map. Under the assumption that we use a sliding stride of 1, we obtain $(N - n + 1)(D - d + 1)$ windows. An L2 norm is then used as an activation function and applied on each window to highlight the saliency of features. A saliency activation map $\mathbf{F}_A \in \mathbb{R}^{(N - n + 1) \times (D - d + 1)}$ is created by concatenating all the extracted windows.
+
+At this point, we initialize a mask matrix $\mathbf{M}$ which has the same size and dimension as $\mathbf{X}_A$ (or $\mathbf{X}_B$ ). The initialized $\mathbf{M}$ is a matrix of ones. To identify the units to be zeroed out, we relate it to the feature activation mat $\mathbf{F}_A$ . More specifically, first note that each value in $\mathbf{F}_A$ relates to a window of size $n \times d$ in $\mathbf{I}_A$ . Since $\mathbf{X}_A$ (or $\mathbf{X}_B$ ) also share the same shape with $\mathbf{I}_A$ , we can infer that each value in $\mathbf{F}_A$ also relates to a window in $\mathbf{X}_A$ (or $\mathbf{X}_B$ ). The index mapping function $f$ from $\mathbf{F}_A$ to $\mathbf{I}_A$ can be defined as follows:
+
+$$
+f (i, j) = \bigcup_ {p = i} ^ {i + n - 1} \bigcup_ {q = j} ^ {j + d - 1} (p, q) \tag {3}
+$$
+
+where $(i,j)$ is an index of $\mathbf{F}_{\mathbf{A}}$ , $(p,q)$ is an index of $\mathbf{I}_{\mathbf{A}}$ . We identify the top- $k$ salient units in $\mathbf{F}_{\mathbf{A}}$ , sort them and collect their corresponding $k$ windows. For each window, we set all the $nd$ units of $\mathbf{M}$ corresponding to the window to zero. The patch used in the mixup can now be extracted by applying the mask (or the mask's inverse) on $\mathbf{X}_B$ (or $\mathbf{X}_A$ ). The new features $\tilde{\mathbf{X}}$ can now be generated, following Eqn. (2).
+
+It should be noted that a unit in $\mathbf{I}_A$ may be involved with several patches. The number $k$ is set to ensure that the total number of units for replacement is no more than $\lambda ND$ . The relation between $k$ and $\lambda ND$ is defined as follows:
+
+$$
+\lambda N D = \left| \bigcup_ {(i, j) \in \mathcal {K}} f (i, j) \right| \tag {4}
+$$
+
+where $\kappa$ is the set of top $k$ windows' indexes in $\mathbf{F}_{\mathbf{A}}$ .
+
+To ensure the interpolation of features correspond to the interpolation of associated labels, we make an adjustment to the mixing of labels:
+
+$$
+\widetilde {Y} = \left(1 - \frac {S}{N D}\right) Y _ {A} + \frac {S}{N D} Y _ {B} \tag {5}
+$$
+
+where $S$ is the sum of $\mathbf{M}$ elements, i.e., the number of $\mathbf{M}$ elements containing one.
+
+# 4.2 Window Size Setting
+
+With regard to the window size setting, we are motivated by the assumption that the continuity of words (i.e., words in the $D$ dimensional space) in text include context information which is significant for text classification. Therefore, $n$ and $d$ should be in the set $n \in \{1, 2, \dots, N\}$ , $d \in \{1, D\}$ . Our filtering window becomes a general formulation of patch selection, which we refer to as general. Thus, we refer to this model as DropMix-general (DropMix-G).
+
+We introduce other filter window configurations: unit, channel, word and develop the model variants DropMix-unit (DropMix-U), DropMix-word (DropMix-W) and DropMix-channel (DropMix-C).
+
+DropMix-U $(n = 1, d = 1)$ : DropMix with a filter window which convolves one unit in $\mathbf{X}_A$ .
+
+DropMix-C ( $n = N, d = 1$ ): DropMix with a filter window which convolves one dimension of the embedding for all words from a sentence. That means $n$ features of each dimension are replaced or kept simultaneously.
+
+DropMix-W $(n\in \{1,2,\dots ,N\} ,d = D)$ : DropMix with a filter window which convolves the whole embedding of $n$ continuous words. It has a similar connotation to modelling with n-grams.
+
+# 4.3 Loss Function
+
+We adopt cross entropy to calculate the loss to optimize model parameters. Given a pair of inputs $(\mathbf{X}_{A_i},Y_{A_i})$ and $(\mathbf{X}_{B_i},Y_{B_i})$ for instance $i$ , the loss function can be defined as follows:
+
+$$
+L = - (1 - \lambda) \sum_ {i} Y _ {i} \log \left(Y _ {A i}\right) - \lambda \sum_ {i} Y _ {i} \log \left(Y _ {B i}\right) \tag {6}
+$$
+
+where $Y_{i}$ is the label for the generated input $\tilde{\mathbf{X}}$
+
+# 5 Experiment
+
+# 5.1 Dataset
+
+To evaluate DropMix, we use 12 text classification datasets from two sources: (1) 6 datasets selected from the popular benchmark GLUE (Wang et al., 2018): QQP $^{1}$ , MNLI (Williams et al., 2018), SST-2 (Socher et al., 2013), QNLI (Rajpurkar et al., 2016), RTE (Bentivogli et al., 2009) and MRPC (Dolan and Brockett, 2005). (2) 6 CNN datasets used in the work of LeCun et al. (1998): CR (Hu and Liu, 2004), MR (Pang and Lee, 2005), MPQA (Esuli et al., 2008), SST-1 (Socher et al., 2013), Subj (Pang and Lee, 2004), TREC (Li and Roth, 2002). Both GLUE $^{2}$ and CNN datasets can be downloaded from the Github link. Table 2 shows the statistics of all datasets. We use accuracy as the evaluation metrics following the practice in compared works (Devlin et al., 2018).
+
+# 5.2 Baseline
+
+We implement and compare with a series of baseline models, including Bert, Bert-Dropout, Bert-Mixup, Bert-Dropout+Mixup and SSMix.
+
+Bert in its original form includes a dropout layer. To demonstrate the impact of data augmentation strategies, we ablate the dropout layer in the original Bert and report the performance.
+
+Bert-Dropout is the officially published and extensively utilized version of Bert (Devlin et al., 2018).
+
+| Dataset | #Train | #Valid | #AvgLen | #Label |
| MNLI | 392702 | 9815 | 39.78 | 3 |
| QQP | 363846 | 40430 | 30.57 | 2 |
| QNLI | 104743 | 5463 | 49.49 | 2 |
| SST-2 | 67349 | 872 | 13.47 | 2 |
| MRPC | 4076 | 1725 | 53.16 | 2 |
| RTE | 2490 | 277 | 66.37 | 2 |
| MPQA | 10606 | / | 5.46 | 2 |
| MR | 10662 | / | 27.42 | 2 |
| SST-1 | 11855 | 2210 | 25.02 | 5 |
| SUBJ | 10000 | / | 29.98 | 2 |
| TREC | 5952 | 500 | 13.21 | 6 |
| CR | 3775 | / | 23.75 | 2 |
+
+Table 2: Dataset statistics of 12 text classification datasets. AvgLen represents the average length of all sentences within one dataset.
+
+Bert-Mixup replaces the Dropout layer in Bert-Dropout with Mixup (Guo et al., 2019).
+
+Bert-Dropout+Mixup applies dropout on the input features and applies a vanilla mixup to generate the new data. This is different from our method DropMix, which drops and mix corresponding features based on the saliency of the input data.
+
+SSMix (Yoon et al., 2021) is an enhanced model of mixup inspired by CutMix and PuzzleMix (Kim et al., 2020).
+
+Unfortunately, most of the image-based Mixup models (Kim et al., 2020; Yun et al., 2019; Uddin et al., 2021) cannot be applied directly to text processing tasks. SSMix on the other hand has been successfully applied in text processing and it is now the current SOTA in text regularization. We therefore exclude the image-based Mixup models but compare with SSMix as well as our baselines.
+
+Hereinafter, we omit 'Bert-' Prefix from model names for brevity.
+
+# 5.3 Implementation Details
+
+For comparisons, we exploit the pre-trained BERT-base-uncased model from Hugging Face Transformers and the source code from Github. Following the recommended parameter settings: max sentence length $N$ is 128, word embedding dimension $D$ is 768, batch size is 32, epoch is 3 and learning rate is 2e-5, optimizer is AdamW with eps 1e-8. For the specific parameters of regularization
+
+| Model | MNLI | QQP | QNLI | SST-2 | MRPC | RTE |
| Bert | 84.43±0.30 | 91.11±0.06 | 91.49±0.09 | 92.41±0.13 | 84.00±0.42 | 64.55±0.95 |
| Dropout | 84.38±0.33 | 90.97±0.19 | 91.43±0.19 | 92.61±0.21 | 84.03±0.82 | 64.69±0.95 |
| Dropout* | 84.27±0.12 | 91.32±0.04 | 91.28±0.05 | 92.96±0.04 | 86.37±1.73 | 65.56±3.89 |
| Mixup | 84.38±0.23 | 91.29±0.06 | 91.51±0.17 | 92.66±0.19 | 84.48±0.59 | 65.13±1.61 |
| Dropout+Mixup | 84.52±0.18 | 90.92±0.08 | 91.45±0.21 | 92.91±0.24 | 82.89±1.27 | 65.27±0.70 |
| SSMix | 84.12±0.22 | 91.19±0.20 | 91.48±0.19 | 92.39±0.41 | 83.48±0.67 | 65.85±2.17 |
| SSMix* | 84.54±0.07 | 91.43±0.07 | 91.54±0.03 | 93.10±0.03 | 86.57±1.15 | 67.22±2.57 |
| DropMix-U | 84.27±0.31 | 91.35±0.10 | 91.18±0.12 | 92.77±0.19 | 81.75±1.28 | 66.93±1.28 |
| DropMix-C | 84.77±0.16 | 91.42±0.04 | 91.70±0.18 | 93.17±0.30 | 83.48±0.60 | 67.94±1.06 |
| DropMix-W | 83.49±0.13 | 90.35±0.04 | 90.80±0.25 | 91.72±0.38 | 81.62±1.16 | 65.99±1.17 |
| DropMix-G | 84.78±0.33 | 91.45±0.05 | 91.54±0.23 | 93.33±0.34 | 83.17±1.26 | 68.09±0.98 |
| Model | TREC | SST-1 | Subj | MR | CR | MPQA |
| Bert | 96.64±0.23 | 54.16±0.66 | 97.22±0.37 | 88.34±0.95 | 91.11±1.65 | 91.97±0.91 |
| Dropout | 96.60±0.36 | 53.86±0.49 | 97.10±0.52 | 88.13±1.05 | 90.79±0.91 | 91.91±0.78 |
| Mixup | 96.72±0.48 | 53.92±0.11 | 97.04±0.29 | 88.28±1.10 | 91.06±1.70 | 92.08±0.75 |
| Dropout+Mixup | 96.72±0.30 | 53.59±0.39 | 97.14±0.29 | 88.25±0.57 | 91.11±1.39 | 92.03±0.97 |
| SSMix | 97.48±0.37 | 53.77±0.41 | 97.22±0.62 | 88.62±1.01 | 92.01±1.39 | 91.89±0.64 |
| DropMix-U | 97.68±0.16 | 53.80±0.24 | 97.38±0.29 | 88.81±0.88 | 91.90±1.31 | 92.29±0.83 |
| DropMix-C | 97.76±0.23 | 53.98±0.23 | 97.58±0.24 | 88.66±0.69 | 92.01±0.77 | 92.36±0.90 |
| DropMix-W | 97.16±0.27 | 53.14±0.51 | 97.46±0.37 | 88.47±0.94 | 91.48±0.83 | 91.42±0.40 |
| DropMix-G | 97.92±0.10 | 54.71±0.51 | 97.64±0.27 | 88.88±0.84 | 92.06±1.49 | 92.52±0.47 |
+
+Table 3: Results of baseline models and DropMix on GLUE and other 6 classification datasets using BERT-base-uncased as encoder. Superscript $\star$ indicate the results are taken from (Yoon et al., 2021). The bold result is the best result of a dataset. The underlined result is DropMix-C performs the best or only lower than DropMix-G among four DropMix variants.
+
+models, the dropout ratio $p$ for Dropout is set at 0.1, the beta distribution parameter $\alpha$ is set at 0.1 for Mixup and $\alpha \in \{0.025, 0.05, 0.1, 0.25, 0.5, 1\}$ for SSMix and DropMix. Unlike DropMix-U and DropMix-C which have a determined window size, we set $n \in [2, 32]$ for DropMix-W and DropMix-G. Since regularization methods reduce the speed of convergence, we run multiple epochs (5 to 10 times) for these regularization schemes. The parameter quantity of all regularization models are equal to the original Bert (Devlin et al., 2018). All hyper-parameters are set manually and empirically tuned on the development set during the training process.
+
+All experiments are completed on Tesla V100-SXM2-32GB GPU, costing about 1300s per epoch for the medium scale dataset QNLI.
+
+# 5.4 Text Classification Performance
+
+We run our experiments five times using different random seeds on all models. The average classification accuracy and its standard deviation are shown in Table 3.
+
+From these results, we find that DropMix outperforms other baseline models on all datasets, except for MRPC. These results indicate that DropMix is an effective scheme for text data augmentation. It is also worth noting that SSMix* starts from the best checkpoint of Dropout* and measures validation accuracy every 500 steps. This proves to be useful in achieving faster optimization. Nonetheless, DropMix still enjoys a better overall performance.
+
+Among the four variants of DropMix, DropMix-G generally achieves the best results, except on QNLI and MRPC datasets. The results indicate that DropMix-G is an efficient variant and choosing fine grained patch on text representation is practical for data augmentation. Besides DropMix-G, DropMix-C achieves comparable results and outperforms DropMix-U and DropMix-W in almost all datasets except MR. This indicates DropMix-C is a satisfying substitute to DropMix-G when there is an efficiency requirement in the training process. Furthermore, DropMix-C performs better than DropMix-W. This demonstrates that channel may be more important and appropriate than word
+
+| Model | TREC | SST-1 | Subj | MR | CR | MPQA |
| Bert-large | 97.52±0.29 | 55.16±0.60 | 97.29±0.52 | 89.97±1.00 | 92.43±1.21 | 92.27±0.65 |
| Dropout | 97.44±0.36 | 55.38±0.47 | 97.28±0.37 | 89.87±0.65 | 92.27±1.22 | 92.44±0.48 |
| Mixup | 97.72±0.29 | 54.90±0.71 | 97.36±0.30 | 89.78±0.85 | 92.96±1.19 | 91.53±1.34 |
| Dropout+Mixup | 97.80±0.17 | 54.71±0.47 | 97.53±0.36 | 89.93±0.54 | 92.85±0.96 | 92.36±0.38 |
| DropMix-C | 97.76±0.23 | 55.22±0.30 | 97.72±0.23 | 90.42±0.71 | 93.70±0.72 | 92.57±0.65 |
| DropMix-G | 97.76±0.20 | 55.67±0.84 | 97.74±0.35 | 90.16±0.75 | 93.60±1.04 | 92.66±0.58 |
| Model | TREC | SST-1 | Subj | MR | CR | MPQA |
| RoBERTa | 97.32±0.43 | 57.68±0.46 | 97.17±0.41 | 90.10±0.63 | 94.17±0.50 | 91.97±0.59 |
| Dropout | 97.36±0.20 | 57.78±0.69 | 97.12±0.35 | 90.25±0.44 | 94.23±0.20 | 92.18±0.68 |
| Mixup | 97.12±0.10 | 57.61±0.62 | 96.90±0.17 | 89.58±0.66 | 93.86±0.84 | 91.80±0.60 |
| Dropout+Mixup | 97.56±0.29 | 57.62±0.60 | 96.91±0.34 | 90.17±0.65 | 94.23±0.35 | 92.08±0.33 |
| DropMix-C | 98.00±0.13 | 58.04±0.46 | 97.36±0.22 | 90.47±0.19 | 94.55±0.64 | 92.10±0.56 |
| DropMix-G | 98.08±0.24 | 57.91±0.29 | 97.36±0.21 | 90.44±0.74 | 94.71±0.58 | 92.31±0.53 |
+
+Table 4: Results on other encoders.
+
+
+Figure 2: Accuracy on different ratio to sparse data on three large datasets.
+
+
+
+
+
+
+
+(DropMix-W) for text augmentation.
+
+We perform additional experiments to investigate the model behaviour with different encoders, particularly, BERT-large-uncased and RoBERTa. Table 4 shows the results of our experiments on six datasets. Similar to the results produced via the BERT-base-uncased encoder (see Table 3), we find that both BERT-large-uncased and RoBERTa leads to a better performance of DropMix variants when compared to Dropout and Mixup. The results indicate the efficiency of DropMix.
+
+# 5.5 Performance on Sparse Data
+
+To further analyze in sparse settings, we downsample $50\%$ , $25\%$ , $10\%$ , $5\%$ of the training data from the 3 large datasets MNLI, QQP and QNLI. For the sake of efficiency, we use DropMix-C in this experiment. The classification accuracies are shown in Figure 2.
+
+Results indicate that more training samples could improve the performance of all models. On the reduced datasets, we observe that these methods
+
+have a certain regularization effect. DropMix-C is better than other regularization models generally, and as the dataset decreases extremely to $10\%$ or $5\%$ , the performance gap between DropMix-C and compared methods is enlarged. These observations demonstrate the effectiveness of the DropMix-C on even sparser datasets.
+
+# 5.6 Fine Grained Patch Analysis
+
+To discover the patch selection of DropMix-G, we plot the saliency map of a sentence. We employ a fixed $\lambda$ to determine the ratio of units to retain for convenience. This is to ensure that for a given sentence, the proportion of units to be replaced is consistent in different epochs. We also set $n = 2$ to observe the effect of general in DropMix-G. Since the saliency map has an extensive range of values and it cannot represent the result of the final patch, we plot the mask matrices as saliency map to some extent. Figure 3 (a) illustrates the 'saliency map' of the sentence "like jaglom's films, some is honestly affecting" taken from SST-2.
+
+
+(a) Channel
+
+
+
+
+(b) Channel
+
+
+(c) Channel (Sorted by the difference.)
+Figure 3: (a) Saliency map of sentence "like jaglom's films, some is honestly affecting". In this heatmap, blue represents a patch with large saliency value that should be dropped. (b) Channel importance of positive and negative samples in training set. (c) The difference between the channel importance on positive and negative samples from (b). To observe clearly, channel in x-axis is sorted by the difference.
+
+In this case example, words that affect the sentiment classification decision include the words, "honestly" and "affecting". These words are easily spotted when we use word, indicating its effectiveness. Additionally, not all channels of these two words are highlighted, which implies channel plays a distinct role in the text representation. By comparing the results of general as against word and channel to obtain the fine grained patch, we can conclude that general is reasonable and effective for text representation.
+
+| Positive | Negative |
| 93 | 183 | 485 | 345 | 96 | 85 |
| good | good | funny | too | movie | bad |
| movie | funny | good | bad | bad | too |
| film | best | fun | movie | film | movie |
| best | clever | entertaining | film | ##iche | no |
| funny | fascinating | interesting | not | too | dull |
| interesting | great | fascinating | un | no | not |
| enjoyable | interesting | clever | no | dull | predictable |
| smart | fun | best | dull | not | flat |
| clever | smart | smart | little | ##less | worst |
| wonderful | compelling | compelling | like | un | un |
| fascinating | movie | love | fails | worst | film |
| compelling | better | great | worst | flat | less |
| great | wonderful | enjoyable | nothing | predictable | boring |
| fun | entertaining | wonderful | story | bland | ##less |
+
+Table 5: The contributed words of selected channels. In positive samples, the top 3 selected channel are 93, 183 and 485. In negative samples, top 3 channels are 345, 96 and 85. Channels are ordered by their channel importance, and words are ordered by the times that chosen as a contributed word. Positive meaning words are covered with red colorboxes, negative meaning words are covered with blue colorboxes and common negative pattern words are covered with green colorboxes.
+
+# 5.7 Channel Importance Analysis
+
+For a comprehensive study on the effectiveness of channel, we construct an experiment on channel selection on SST-2. For positive and negative samples, we separately count the number of times that each channel is selected (highlighted in the saliency map). For fair comparison, we divide the count by the number of positive and negative samples. We believe this value represents the importance of a specific channel, call this the channel importance.
+
+We first plot the channel importance of positive and negative samples in the training set as shown in Figure 3 (b). It can be observed that channel importance of positive and negative samples gain peak values on different channels, which indicates that channel plays a disparate role with different sentiment polarity.
+
+We further plot the difference between the channel importance in positive and negative to eliminate the impact of irrelevant channels. As the decreasing ordered difference illustrated in Figure 3 (c), for all 768 channels (from the 768 dimensions in Bert Embeddings), around 100 positive channels (left of the figure) and 100 negative channels (right of the figure) achieves a relatively channel importance. We find that the selected positive channels are more concentrated and have a higher value than negative channels. To further investigate the underlying reason of this phenomenon, we find that negative sentences have richer patterns and are from a more common vocabulary, such as "little", "too" and "to". This means that more negative channels are selected during the training. This observation is also confirmed by the statistics in Table 5.
+
+After obtaining the selected channels of positive and negative, we further analyze which word contributes most in a sentence of the selected channel. Fixing the top 3 selected channels of positive samples, we compute the maximum gradient of each word in this channel. Then we obtain the word importance for each channel. We also conduct the same procedure for negative samples. The top 3 channels for positive samples, negative samples and their contributed words are shown in Table 5. Clearly, the listed contributed words are highly related to their corresponding categories. This experiment demonstrates the effectiveness of our presented model on channel.
+
+# 5.8 CutMix vs. SSMix vs. DropMix
+
+Our work is most closely related to the line of research that adapt the mixup method (Guo et al., 2019). As such, we briefly discuss how these methods differ in architecture to gain a more in-depth understanding of our proposed mechanism.
+
+CutMix vs. SSMix CutMix cuts a patch of an image and mixes it with a corresponding patch from another image. SSMix is an adaptation of CutMix to text classification. SSMix applies a saliency map to determine the Mixup patch.
+
+SSMix vs. DropMix SSMix disregards the position and sentence structure of words, and simply replaces unimportant word spans in $\mathbf{X}_A$ with salient words in $\mathbf{X}_B$ . DropMix on the other hand considers the context of words as well as its structure by mapping words into a low-dimensional space.
+
+CutMix vs. DropMix CutMix cuts rectangular patches on input images with 3 RGB channels. Analogously, for a 2d sentence embedding matrix, DropMix-C uniformly cuts some specific dimension of latent word embedding, i.e., a channel or column vector patch. DropMix advocates and regards channel mixing as suitable and important for text synthesis and augmentation.
+
+# 6 Conclusion
+
+In this paper, we present a data augmentation framework, DropMix, based on the saliency map which combines Dropout and Mixup to facilitate regularization in text learning. Our best results obtained from our model variant DropMix-G indicate that the features of the word embeddings are important for patch selection and mixing. In general, our empirical results confirm the effectiveness of DropMix.
+
+# 7 Limitation
+
+DropMix-G has a dominant performance due to the fine grained patch selection using an irregular window size. This makes it computationally expensive. If there is an efficiency requirement for an algorithm, DropMix-C is much more desirable and it also achieves competitive performance with DropMix-G.
+
+# 8 Acknowledgements
+
+This work was supported in part by the National Key R&D Program of China under Grant 2021ZD0110700, in part by the Fundamental Research Funds for the Central Universities, in part by the State Key Laboratory of Software Development Environment. SM is supported by a Leverhulme Trust Research Project Grant (No. RPG-2020-148).
+
+# References
+
+Luisa Bentivogli, Ido Dagan, Hoa Trang Dang, Danilo Giampiccolo, and Bernardo Magnini. 2009. The fifth pascal recognizing textual entailment challenge. In In Proc Text Analysis Conference (TAC'09).
+Jiaao Chen, Zichao Yang, and Diyi Yang. 2020. Mix-Text: Linguistically-informed interpolation of hidden space for semi-supervised text classification. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 2147-2157, Online. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805.
+William B. Dolan and Chris Brockett. 2005. Automatically constructing a corpus of sentential paraphrases. In Proceedings of the Third International Workshop on Paraphrasing (IWP2005).
+Andrea Esuli, Fabrizio Sebastiani, and Ilaria Urciuoli. 2008. Annotating expressions of opinion and emotion in the Italian content annotation bank. In Proceedings of the Sixth International Conference on Language Resources and Evaluation (LREC'08), Marrakech, Morocco. European Language Resources Association (ELRA).
+Mojtaba Faramarzi, Mohammad Amini, Akilesh Badrinaraayanan, Vikas Verma, and Sarath Chandar. 2020. Patchup: A regularization technique for convolutional neural networks.
+Ian J. Goodfellow, Jonathon Shlens, and Christian Szegedy. 2015. Explaining and harnessing adversarial examples. In 3rd International Conference on Learning Representations, ICLR.
+
+Hongyu Guo, Yongyi Mao, and Richong Zhang. 2019. Augmenting data with mixup for sentence classification: An empirical study. CoRR, abs/1905.08941.
+Minqing Hu and Bing Liu. 2004. Mining and summarizing customer reviews. KDD '04, page 168-177, New York, NY, USA. Association for Computing Machinery.
+Jang-Hyun Kim, Wonho Choo, and Hyun Oh Song. 2020. Puzzle mix: Exploiting saliency and local statistics for optimal mixup. In Proceedings of the 37th International Conference on Machine Learning, volume 119 of Proceedings of Machine Learning Research, pages 5275-5285. PMLR.
+Anders Krogh and John A Hertz. 1992. A simple weight decay can improve generalization. In Advances in Neural Information Processing Systems, pages 950-957.
+Yann LeCun, Léon Bottou, Yoshua Bengio, and Patrick Haffner. 1998. Gradient-based learning applied to document recognition. Proceedings of the IEEE, 86(11):2278-2324.
+Xin Li and Dan Roth. 2002. Learning question classifiers. In COLING 2002: The 19th International Conference on Computational Linguistics.
+Bo Pang and Lillian Lee. 2004. A sentimental education: Sentiment analysis using subjectivity. In Proceedings of ACL, pages 271-278.
+Bo Pang and Lillian Lee. 2005. Seeing stars: Exploiting class relationships for sentiment categorization with respect to rating scales. In Proceedings of the 43rd Annual Meeting of the Association for Computational Linguistics (ACL'05), pages 115-124, Ann Arbor, Michigan. Association for Computational Linguistics.
+Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. 2016. SQuAD: $100,000+$ questions for machine comprehension of text. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2383-2392, Austin, Texas. Association for Computational Linguistics.
+Karen Simonyan, Andrea Vedaldi, and Andrew Zisserman. 2013. Deep inside convolutional networks: Visualising image classification models and saliency maps. In ICLR (Workshop Poster).
+Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Ng, and Christopher Potts. 2013. Recursive deep models for semantic compositionality over a sentiment treebank. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, pages 1631-1642, Seattle, Washington, USA. Association for Computational Linguistics.
+Nitish Srivastava, Geoffrey Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. 2014. Dropout: A simple way to prevent neural networks
+
+from overfitting. Journal of Machine Learning Research, 15(56):1929-1958.
+A F M Shahab Uddin, Mst. Sirazam Monira, Wheemyung Shin, TaeChoong Chung, and Sung-Ho Bae. 2021. Saliencymix: A saliency guided data augmentation strategy for better regularization. In International Conference on Learning Representations.
+Vikas Verma, Alex Lamb, Christopher Beckham, Amir Najafi, Ioannis Mitlagkas, David Lopez-Paz, and Yoshua Bengio. 2019. Manifold mixup: Better representations by interpolating hidden states. In Proceedings of the 36th International Conference on Machine Learning, volume 97 of Proceedings of Machine Learning Research, pages 6438-6447, Long Beach, California, USA. PMLR.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel Bowman. 2018. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In Proceedings of the 2018 EMNLP Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pages 353-355, Brussels, Belgium. Association for Computational Linguistics.
+Adina Williams, Nikita Nangia, and Samuel Bowman. 2018. A broad-coverage challenge corpus for sentence understanding through inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 1112-1122, New Orleans, Louisiana. Association for Computational Linguistics.
+Soyoung Yoon, Gyuwan Kim, and Kyumin Park. 2021. SSMix: Saliency-based span mixup for text classification. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 3225-3234, Online. Association for Computational Linguistics.
+Sangdoo Yun, Dongyoon Han, Seong Joon Oh, Sanghyuk Chun, Junsuk Choe, and Youngjoon Yoo. 2019. Cutmix: Regularization strategy to train strong classifiers with localizable features. In International Conference on Computer Vision (ICCV).
+Hongyi Zhang, Moustapha Cisse, Yann N Dauphin, and David Lopez-Paz. 2017. mixup: Beyond empirical risk minimization. arXiv preprint arXiv:1710.09412.
+Rongzhi Zhang, Yue Yu, and Chao Zhang. 2020. SeqMix: Augmenting active sequence labeling via sequence mixup. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 8566-8579, Online. Association for Computational Linguistics.
\ No newline at end of file
diff --git a/dropmixatextualdataaugmentationcombiningdropoutwithmixup/images.zip b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..55ceb7d11d7088a88cc84ea1339a40e2b7a3d83c
--- /dev/null
+++ b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:63d82da0f0e1b48291b9c81cde67f264b4fdf436786fb9b6598b37eaea81cade
+size 636834
diff --git a/dropmixatextualdataaugmentationcombiningdropoutwithmixup/layout.json b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..2f67486c28acbdd7bbb313cac29e32cc49ba28c6
--- /dev/null
+++ b/dropmixatextualdataaugmentationcombiningdropoutwithmixup/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:42ad655171bfe725d0a103b415a6a3c4463cb3bd85c2630ebab9bb3690cb4a0b
+size 407883
diff --git a/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_content_list.json b/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..55f94700d3e68261d50fc7e0c5ce6c152f2a237a
--- /dev/null
+++ b/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:090951fff7e49bb83d3b1f8be480e6c16bc63c75c574dab3f145b5d07f2a9b04
+size 105386
diff --git a/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_model.json b/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..dfdb20176c075ff4aaa9f8f5bb6ac4e40ed39fd1
--- /dev/null
+++ b/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fcea55b47fa02121d64d8c47fb3c2627227021f0df2d94b10a24e3d9b226519b
+size 129639
diff --git a/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_origin.pdf b/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..183d47a1268f3ac31febcb4df072af79254671e5
--- /dev/null
+++ b/dungeonsanddragonsasadialogchallengeforartificialintelligence/641a3a5e-6bb5-4900-ba39-531d09eeb9d2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:48d429edf43c6efbb153529124dc64d6a46b0d7c95e82d03887c131b67578435
+size 823269
diff --git a/dungeonsanddragonsasadialogchallengeforartificialintelligence/full.md b/dungeonsanddragonsasadialogchallengeforartificialintelligence/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..5d9289676d00827ea76dc155b18930adf0b4b66c
--- /dev/null
+++ b/dungeonsanddragonsasadialogchallengeforartificialintelligence/full.md
@@ -0,0 +1,473 @@
+# Dungeons and Dragons as a Dialog Challenge for Artificial Intelligence
+
+Chris Callison-Burch*
+
+University of Pennsylvania
+
+ccb@upenn.edu
+
+Gaurav Singh Tomar*
+
+Google Research
+
+gtomar@google.com
+
+Lara J. Martin
+
+University of Pennsylvania
+
+Daphne Ippolito
+
+University of Pennsylvania
+
+Google Research
+
+Suma Bailis
+
+Google Research
+
+David Reitter
+
+Google Research
+
+# Abstract
+
+AI researchers have posited Dungeons and Dragons (D&D) as a challenge problem to test systems on various language-related capabilities. In this paper, we frame D&D specifically as a dialogue system challenge, where the tasks are to both generate the next conversational turn in the game and predict the state of the game given the dialogue history. We create a gameplay dataset consisting of nearly 900 games, with a total of 7,000 players, 800,000 dialogue turns, 500,000 dice rolls, and 58 million words. We automatically annotate the data with partial state information about the game play. We train a large language model (LM) to generate the next game turn, conditioning it on different information. The LM can respond as a particular character or as the player who runs the game—i.e., the Dungeon Master (DM). It is trained to produce dialogue that is either in-character (roleplaying in the fictional world) or out-of-character (discussing rules or strategy). We perform a human evaluation to determine what factors make the generated output plausible and interesting. We further perform an automatic evaluation to determine how well the model can predict the game state given the history and examine how well tracking the game state improves its ability to produce plausible conversational output.
+
+# 1 Introduction
+
+Artificial Intelligence has a long and rich history of using games as challenge problems that lead to advances in the field. In many cases, AI game-playing systems have gone on to rival human champions of the game. Dungeons and Dragons has been identified as an appropriate challenge for the next stage of artificial intelligence (Ellis and Hendler, 2017; Louis and Sutton, 2018; Martin et al., 2018b). Ellis and Hendler (2017) proposed open-ended creative games like D&D as the next challenge for AI after the human-level successes of AI at Chess and
+
+Go, which are zero-sum, deterministic, sequential two-player games with perfect information. Louis and Sutton (2018) understood the importance of narrative in natural language processing (NLP) and generation (NLG). In particular, they saw how cooperative story generation between humans already exists in these games and can be used for automated generation. Martin et al. (2018b) outlined some of the specific challenges D&D presents to the NLP community; such as a state of the game world distributed across the Dungeon Master (DM) and other players or dealing with the intrinsic rewards players get from taking certain actions that would not necessarily provide them with points in the game.
+
+D&D involves multiple players who roleplay characters in a fantasy setting, guided by a Dungeon Master who sets obstacles and adventures and plays as monsters. In roleplaying games like Dungeons and Dragons, the gameplay happens through language rather than moves on a game board, making it an interesting domain for NLP research. To have an AI successfully play D&D, it would require abilities like
+
+- Language generation (multi-party dialog, generating descriptions of the world/actions, storytelling)
+- Language understanding (knowledge acquisition and representation, state tracking, automated reasoning)
+- Planning / strategic play during battles (similar to chess or go)
+
+Appendix A gives an example of D&D gameplay and the AI challenges presented by it.
+
+Is it possible to design an AI system that is capable of playing a game of D&D either as a character in the game or as the Dungeon Master using current AI technology? We argue that now is the perfect time for this challenge, since large scale neural language models like GPT have shown impressive generation results (Brown et al., 2020), and since
+
+incorporating neural LMs into a game setting both exercises their strengths and exposes their weaknesses.
+
+In this paper, we introduce a new dataset of "actual play" game transcripts. Each turn is labeled with game state variables like character information and whether the conversational turn was in-character or out-of-character. Our data is a novel, large scale, real-world conversational dataset. It is unique in that the dialog turns are generated entirely through player collaboration and written interaction in a multi-player game. We propose our dataset as a challenge for dialogue systems for the following reasons:
+
+- It is naturally occurring conversational dialog that covers a spectrum of task oriented and non-task oriented (e.g. chit chat) dialog.
+- It is strongly history dependent – a substantive criticism of recent dialog datasets is their history independence (Mosig et al., 2020).
+- It has many participants in the conversation, since there are several players in the game.
+- It conveys narrative elements including descriptions of events that denote changes in the state of the game.
+
+Unlike existing dialog datasets, our data reflects the challenging nature of the D&D game as a multiparty dialogue with creative roleplaying and underlying game states.
+
+# 2 Tasks
+
+We trained a large language model (LLM) to perform two tasks: Next Utterance Prediction and Game State Tracking.
+
+Next Utterance Prediction. We trained our language model on a corpus of human conversations (see Section 3) to predict the next utterance. We varied the conditioning information to examine the effects on the quality of predicted next utterance. In all variations, we included the conversational history as input. Given the conversational input (and other input in the variant models), the LLM must generate the next utterance, such that it is both interesting and a plausible next turn in the D&D game.
+
+Game State Tracking. In this task, rather than producing the next utterance, we had the model predict the game state for a given dialogue turn in the conversation. We have kept the state definition similar to task-oriented dialogue state tracking
+
+| Play-By-Post Corpus |
| Number of campaigns | 896 |
| Average players per campaign | 8 |
| Average turns per campaign | 910 |
| Average words per campaign | 64,941 |
| Total turns | 815,106 |
| Total words | 58,187,526 |
| Average dice rolls per campaign | 594 |
| Total dice rolls | 532,270 |
+
+Table 1: Statistics for our play-by-post corpus
+
+(DST). In DST, the dialogue state is a collection of slot-value pairs. In our case, each slot is a state variable feature related to D&D games. Our target slot values do not need to appear as a word in the dialogue context. We track several game states aspects including some that remain relatively static throughout the game (character attributes like their pronouns, class, fantasy race, and their inventory), some that change periodically (like being in combat or out of combat), and some that change from turn to turn (like what action the player is taking).
+
+# 3 Dataset
+
+For this paper, we have created a novel dataset for our dialogue-oriented test of AI's ability to play Dungeons & Dragons. We scraped Play-By-Post data from a web forum1 where people play by taking turns posting on the forum to describe their move.
+
+Figure 1 shows an example of part of the gameplay from the play-by-post forums from D&D Beyond. D&D Beyond provides a mechanism in its forum to roll dice using a "roll" tag. Their dice roller allows players to conduct the rolls that are used for D&D ability checks and in combat.
+
+Table 1 summarizes the amount of play-by-post data that we collected from the D&D Beyond website (with permission from the company).
+
+# 3.1 Heuristic annotation of game states
+
+We designed a set of rule-based heuristics to extract game state information from the play by post. These were implemented using regular expressions and NLP tools like named entity recognizers (Gardner et al., 2018). Although this heuristically extracted information is not perfect, it provides a reasonable approximation of the game state. It is
+
+
+Figure 1: Example of 3 turns in the D&D Beyond play-by-post forum
+
+useful for testing whether large language models can benefit from inclusion of complex state information for next utterance prediction and whether LLMs can be used for state tracking. We designed rules to extract state information relating to character properties, combat and player actions.
+
+# Character properties
+
+- Name: Perform NER on all the player's turns in a campaign. The character's name is assigned to be the player's most frequently mentioned name, on the assumption that they tend to describe their own character's actions.
+- Class: Count how many times each D&D class $^2$ is mentioned by each player. Most frequently mentioned class is their character's class.
+- Race: On a player's first turn, check whether any of the D&D fantasy races3 are mentioned. Assign it to character. If not, guess based on the most frequently mentioned race.
+- Pronouns: Count pronouns mentioned by a player. Assign their character's pronouns to be the most frequent pronouns used by the player.
+- Inventory: Use regex to match items occurring after character's personal pronouns (e.g. her sword).
+
+- Spells known: Regex that matches cast followed by a spell name
+
+The DM is assumed to be the player who has the first post in the game. The DM's entries in the dataset are scrubbed of other character properties, since they play multiple NPCs (non-player characters) and monsters.
+
+# Combat
+
+- We detect the start of combat when there is a roll for initiative, or when there are attack rolls before initiative (from surprise attacks).
+- Combat continues while there are attack rolls happening.
+- Combat concludes after there are no rolls for a number of turns.
+- In a combat span, we extract a list of monsters mentioned, and heuristically guess the number of each kind of monster.
+
+# Actions
+
+- Dice rolls are marked in D&D Beyond posts. We detect the associated actions based on the kind of die used (D20 = a check, other dice are used for calculating damage if an attack check is successful)
+- We use a regex to match the nearest pattern, which includes attack or a list of abilities like acrobatics, animal handling, arcana, athletics, etc.
+- Damage rolls are matched with damage, dmg,
+
+| Control Feature | Description | Expected Impact on Model's Output |
| Player ID | Player writing a given dialog turn | Connects the current turn to the player's previous turns, which is important in multi-party conversations. |
| IC versus OOC | Whether a player is in-character or out-of-character for a given dialog turn | Changes whether the generated text is more like descriptive text found in a novel, or more like a discussion of rules and strategies. |
| Character Name | Name of the character being played by the player of a given dialog turn | IC descriptions use the character's name. |
| Character Class | D&D classes | Character classes perform different actions (e.g. wiz-ards cast spells, thieves pick locks) |
| Character Race | D&D fantasy races | Different physical characteristics (e.g. halflings are small, dragonborn have scales). |
| Character Pronouns | The character's pronouns | Uses the correct pronouns when describing the character. |
| Character Actions | List of actions taken by the character in the current turn | Allows a description to be generated for a given action. The action can be thought of as a goal for the description. |
| Combat | Whether the players are currently engaged in combat or not during a given dialog turn | Affects the likelihood of actions (e.g. attacks are more likely during combat and investigations checks are more likely outside of combat) |
+
+Table 2: Our LLMs are conditioned on a variety of control features that allow the models to better learn what kind of text to generate for the next utterance prediction task
+
+cure, heal, healing, points.
+
+Our heuristics resulted in features for around $60\%$ of all conversational turns. We train a convolutional neural network classifier using these conversational turns to predict all of the above control features for each conversational turn in training data. Appendix C estimates the accuracy of the model's prediction on these state features.
+
+# 3.2 In-Character Versus Out-Of-Character Text
+
+In addition to labeling the game states in our Play by Post data, we also labeled the text of each turn as being either spoken in-character (IC) or out-of-character (OOC). To do so, we crawled another Play by Post forum hosted at Giant in the Playground4, where play happens on two discussion boards – one in-character and one out-of-character. For example, here is an IC post:
+
+Kuros pulls the feathered shaft of the arrow back to his cheek winning easily against the resistance of the bowstring. He pulls a lungful of air to keep himself steady, takes aim at the Bandit with the deer, and lets fly.
+
+And here is its corresponding OOC post:
+
+Surprise round so only 1 standard or move action. Shoot the bow:
+
+$(1\mathrm{d}20 + 6)[20]$ vs Flat Footed AC at Bandit 1. Damage: $(1\mathrm{d}8 + 2)[10]$
+
+We train a classifier to predict IC versus OOC text, and then apply it to each paragraph in our D&D Beyond forum data.
+
+# 4 Models
+
+For our large language model, we use a 64B parameter version of Google's LaMDA language model (Thoppilan et al., 2022), which was trained on conversations. LaMDA is similar to other Transformer-based pre-trained language models like GPT-3. As with other pre-trained language models (Howard and Ruder, 2018), LaMDA can be finetuned to different tasks. The two tasks that we finetune LaMDA to perform are game state tracking and response generation. In both cases, the LLM can be thought of as a function that maps inputs onto an output. For instance, game state tracking is a language understanding task where the function takes in inputs like $f$ (current utterance, previous state, history) → new state, and response generation is a language generation task where $f$ (current state, history) → next utterance. The LLM functions are trained via the fine tuning process.
+
+In our experiments we try a variety of different inputs to our LLM functions to see how they enable better learning of the tasks. We train our LLMs on the conversation history (which is typical in dialog modeling) and we also augment the conversations by conditioning other explicit signals. These
+
+conditioning signals can be thought of as sophisticated "control features", inspired by the CTRL language model (Keskar et al., 2019). During training, the model learns a relationship between the control features and appropriate responses. In turn, during inference, one can explicitly influence dimensions of the conversation – enabling more compelling dialogue – by setting the values of control features. These control features can be set dynamically, without necessitating finetuning or additional post-processing. Table 2 describes the control features we have proposed and describes how they could steer generation. Note that we use the terms 'control features' and 'state variables' interchangeably when referring to our next utterance prediction models.
+
+# 4.1 Baseline Pre-Training Data
+
+LaMDA is trained on turn-based conversational data. For a conversation of length $n$ , LaMDA takes as input the first $n - 1$ turns, and the $n$ th turn as the target. For all models, we used the 7 most recent conversational turns as input, and predict turn 8.
+
+# 4.2 D&D FineTuning Data
+
+Here is an example of the data used in our versions of LaMDA that are finetuned to on our D&D data.
+
+TURN1:
+
+| Text | You attack. You launch some fire onto the goblin closest to the wagon. And with that, he looks like he is on death's door. And the other goblin that you can see, the one that's not in the brush somewhere, just sort of stops in his tracks. What do you do next? |
| Player ID | 0 |
| Character | Dungeon Master |
| Race | N/A |
| Class | Dungeon Master |
| Pronouns | N/A |
| Inventory | N/A |
| In combat? | Yes |
| In character? | Yes |
| Action | Attack |
+
+TURN 2:
+
+| Text | I grab my axe and bring it down on the wounded goblin. |
| Player ID | 1 |
| Character | Magnus |
| Race | Human |
| Class | Fighter |
| Pronouns | he/him |
| Inventory | Axe |
| In combat? | Yes |
| In character? | Yes |
| Action | Attack |
+
+
+Figure 2: Negative Log Perplexity of our models after pretraining on generic dialogue data for 600k steps, and then finetuning to our data for a further 60k steps. Colors correspond to the models in Table 3.
+
+# 4.3 Next Utterance Prediction Models
+
+LLM-Dialog: We call our baseline model LLM-Dialog. It is a LaMDA dialogue model that does not use not use any D&D data.
+
+LLM-DND: LLM-Dialog that has been finetuned on Play-by-post D&D gameplay dataset using no control features
+
+LLM-DND-ALL-CTRL: LLM-Dialog that has been finetuned on Play-by-post D&D gameplay dataset using control features (state variables) for all dialog turns including the state variables for the current turn the utterance is being predicted for.
+
+LLM-DND-PREV-CTRL: LLM-Dialog that has been finetuned on Play-by-post D&D gameplay dataset using control features for all previous dialog turns, not including the current turn.
+
+LLM-DND-CURRENT-CTRL: LLM-Dialog that has been finetuned on Play-by-post D&D gameplay dataset using control features (state variables) for only the current turn the utterance is being predicted for.
+
+# 4.4 Dev Set Perplexity During Training
+
+Each of our models starts from a pretrained LaMDA model trained for 600K steps and then is finetuned for a further 60K steps. Figure 2 plots the Negative log perplexity on our development set, and Table 3 shows the final perplexity and token accuracies on the dev set. At the end of finetuning, the models with the best perplexity scores and the best token accuracy scores were LLM-DND-CURRENT-CTRL and LLM-DND-ALL-CTRL, which used our control features.
+
+| Model | Perplexity | Token Accuracy |
| LLM-Dialog | 2.65 | 44.61 |
| LLM-DND | 2.50 | 46.92 |
| LLM-DND-PREV-CTRL | 2.51 | 46.84 |
| LLM-DND-CURR-CTRL | 2.34 | 49.67 |
| LLM-DND-ALL-CTRL | 2.37 | 49.02 |
+
+# 5 Manual Evaluation
+
+To evaluate the quality of our models for the task of next utterance prediction in D&D, we perform a human evaluation. We recruited professional raters to perform a manual evaluation. They read a version of the content that was provided to the models – the seven turns of conversational history plus a list of players and the names/classes of the characters that they played. Then they were shown several model outputs for the context (or the “gold”, which was the actual next turn in the game). The annotators asked to rate each output along the three dimensions, following the evaluation procedure used for the Meena LM (Adiwardana et al., 2020):
+
+- Does the response make sense? (yes/no)
+- Is the response specific? (yes/no)
+- How interesting is the response? (10 point scale)
+
+The full annotator instructions and the annotation interface are given in Appendix D.
+
+# 5.1 Raters
+
+Because of the specialized nature of the D&D domain, we recruited 6 professional raters rather than crowd workers to perform the task. The raters were selected based on their professed interest in the fantasy genre, and on their background with D&D. All raters were fantasy fans, and 5 of the 6 had played D&D. 3 raters had been the DM in a game before.
+
+# 5.2 Inter-Rater Agreement
+
+Our raters annotated 500 system outputs with 3-way redundancy on each output. For the binary sense and specific scores, pairwise annotator agreement was 0.8, with a chance-adjusted Randolph Kappa score of 0.6. For the scalar interestingness scores, the Kendall's Tau correlation was 0.46.
+
+# 5.3 Analysis
+
+Model Comparison. Table 4 shows the average sense, specific and interestingness scores for the systems, and for the human-written gold response. All of the D&D adapted systems outperform the
+
+Table 3: Perplexity and token accuracy of our models after finetuning to our data.
+
+| Model | Sense | Specific | Interest |
| LLM-Dialog | 0.81 | 0.85 | 3.57 |
| LLM-DND | 0.9 | 0.9 | 3.91 |
| LLM-DND-PREV-CTRL | 0.86 | 0.88 | 3.96 |
| LLM-DND-CURR-CTRL | 0.88 | 0.9 | 3.96 |
| LLM-DND-ALL-CTRL | 0.87 | 0.88 | 3.92 |
| GOLD | 0.92 | 0.92 | 4.17 |
+
+Table 4: Average sense, specific and interestingness scores for our systems, and for human-written gold responses
+
+vanilla dialogue system. On average, the adapted systems make sense $6.75\%$ more often than the baseline, are specific $4\%$ more often, and are 0.37 points more interesting. However, the added control features do not seem to differ substantially from the LLM that is adapted to the D&D data without any control features. Why then use the control features at all?
+
+Control Features. One reason is that the control features are useful to allow the model to role-play. For example, we can ask the model to play an elf wizard via the control features. Table 5 gives a qualitative example of this. The Table shows outputs from two LLMs without control features, plus 3 outputs from our LLM-DND-CURRENT-CTRL model roleplaying different characters. As input, we gave the models the final seven turns in the game play example from Appendix A –from “With his eagle eyes, Magnus spots two dead horses...” to “… What do you do next?”, and then generate what each model thinks the next utterance ought to be. The vanilla dialogue system with no D&D data generates an irrelevant reply about Discord. The dialogue system fine-tuned on D&D data without control feature generates a relevant response. The dialogue system that adds conditioning control features allows the model to generate specific replies for each of the different characters. These replies are relevant to the character classes – the wizard casts a spell, and the Dwarf cleric shouts a battle cry by invoking the name of a Dwarf god.
+
+In-Character Turns Are More Interesting. Among our most impactful control features was the one that allowed systems to generate in-character (IC) versus out-of-character (OOC) turns. Table 6 shows that control models' scores substantially increased on IC turns compared to when their output was generated OOC. The pronounced increase in interestingness makes sense because IC turns are ones where the players describe their characters in
+
+| Model | Output |
| LLM-Dialog | moon_monk you can just join our discord conversation. it's free and easier to deal with |
| LLM-DND | I cast Ice Knife (I'm assuming this is not one of the ones I can't do?) |
| LLM-DND-CURRENT-CTRL Responding as Magnus (human fighter, inventory: axe) In combat | I turn from the goblin and go to help Merle and Taako with getting this wagon moving again. Magnus can't see them anymore with such a dense forest. They're likely in a battle right now... I have to find them as fast as I can! |
| LLM-DND-CURRENT-CTRL Responding as Taako (elf wizard, inventory: spellbook) In combat | If the goblins still don't look like they're getting closer, Taako will yell, “Alright you little monsters! Let's see what ya got!” And he'll cast Chill Touch on one of the goblins that isn't dead/on its doorstep. Attack: 22 Damage: 6 |
| LLM-DND-CURRENT-CTRL Responding as Mearle (dwarf cleric, inventory: holy symbol) In combat | Merle steps away from the wagon. He draws his sword and takes aim at the hidden goblin! Attack: 27 Damage: 8 He puts his free hand on the pommel of his sword and shouts his battle cry, “For Clanggeddin!” His eyes glow brightly red as he strikes! |
+
+Table 5: Example model outputs for the next utterance prediction task, given the sample gameplay from Table 8 as input. The 3 LLM-DND-CURRENT-CTRL examples use the same model with different control features (in red).
+
+| Model | Sense | Specific | Interest |
| LLM-Dialog | -0.01 | -0.01 | +0.06 |
| LLM-DND | -0.02 | +0.03 | +0.4 |
| LLM-DND-PREV-CTRL | +0.02 | +0.02 | +0.6 |
| LLM-DND-CURR-CTRL | +0.06 | +0.06 | +0.93 |
| LLM-DND-ALL-CTRL | +0.07 | +0.06 | +0.81 |
| GOLD | +0.07 | +0.05 | +1.02 |
+
+Table 6: Improvements by generating in-character (IC) text rather than out-of-character (OOC) text. Numbers are IC scores minus OOC scores.
+
+| State variable | Majority | LLM-DND-GST |
| All | .73 | .82 |
| Combat | .89 | .82 |
| Character Class | .58 | .76 |
| Character Name | .58 | .78 |
| Character Race | .75 | .79 |
| Character Pronouns | .58 | .89 |
| Character Actions | .80 | .85 |
+
+Table 7: Average accuracy for our Game State Tracking LLM on the slot-filling our state variables, compared to a majority class baseline.
+
+the fictional world often with evocative language, whereas OOC turns usually discuss rules or mechanics. Our control features allowed the system to intentionally generate IC responses, resulting in substantially improved interestingness scores for those in-character turns.
+
+# 6 Game State Tracking Model
+
+We conducted an experiment to evaluate whether a LLM could be finetuned to perform game state tracking for D&D using our heuristically annotated game state features. We trained a new model LLM-DND-GST (Game State Tracking). It is a LLM-Dialog that has been finetuned on our Play-by-post D&D gameplay dataset. As input, it takes all previous dialog turns and their state variables, plus the text of the current turn, and then it outputs the
+
+corresponding state variables for the current turn.
+
+We analyzed the accuracy of the LLM-DND-GST model its ability to do slot-filling for each of the individual game states, and compared its performance to a simple baseline that always output the the majority class. The results are shown in Table 7. The average accuracy of the dialogue state tracker is better than the majority class baseline, but likely falls short of being useful when it comes to joint accuracy. The joint accuracy for LMM-DND-GST is $58\%$ . This suggests that accurately tracking the full game state may require additional machinery beyond a finetuned LLM.
+
+# 7 Related Work
+
+Previous work has examined AI to play text adventures games (Haroush et al., 2018; Yao et al., 2020; Dambekodi et al., 2020). These games are simpler than D&D because they have a limited vocabulary and more straightforward game states. Creating text adventure games (Ammanabrolu et al., 2020a; Fan et al., 2020) is more challenging than playing them, and is similar to the world-building job of the DM in D&D. There has also been work on persona/character generation in stories (Prabhumoye et al., 2019), and within D&D itself (Louis and Sutton, 2018). Others (Urbanek et al., 2019; Ammanabrolu et al., 2020b) have realized that NPCs are lacking in their abilities to speak and act in text games.
+
+Findings of the automated story generation community are relevant for D&D AI systems. Neural language models have become increasingly more popular for story generation (Roemmle, 2018; Martin et al., 2018a; Mathewson et al., 2019; Hou et al., 2019). We have also started to see storytelling with transformers (See et al., 2019; Peng et al., 2021; Branch et al., 2021). Transformer
+
+based storytelling systems have even been introduced to the general public thanks to the popularity of AI Dungeon (Walton, 2019). Although neural networks possess a lot of power in terms of what text they generate, they are still limited in their ability to produce longer spans of coherent text. Many (Fan et al., 2018; Yao et al., 2019; Ippolito et al., 2019; Tambwekar et al., 2019; Ammanabrolu et al., 2020b; Rashkin et al., 2020) have improved the coherence of neural storytellers by splitting the generation into two steps: ideation of the story plot, followed by the realization of sentences. This controllable story generation is the focus of a lot of current work in neural automated story generation.
+
+Due to the conversational nature of D&D, we decided to use a dialog-based system. Deep neural networks have been used for dialog agents for a while (Serban et al., 2016), with a shift toward using transformers in recent years (Zhang et al., 2019; Ghazarian et al., 2021). Like in automated story generation and other neural text generation tasks, we are also seeing controllability being an important factor being integrated into systems. This includes using deep reinforcement learning techniques to guide the dialog toward a goal (Li et al., 2016; Saleh et al., 2020) or controlling for style (Zhang et al., 2018; Smith et al., 2020).
+
+In this paper, we use LaMDA, a transformer-based open-domain dialogue system that builds on the Meena model (Adiwardana et al., 2020). The original Meena model was an end-to-end model trained on public conversations found on social media. Controllable text generation with transformers has been seen before with CTRL (Keskar et al., 2019), a language model that is conditioned on a given "control code" in addition to the textual history. This work takes a similar approach. We integrate contextual information such as character descriptions, actions, and in- and out-of-character classifications.
+
+We have finetuned our LaMDA models on data crawled from D&D Beyond. This data contains both in-character and out-of-character dialog and can be used in conjunction with Rameshkumar and Bailey (2020)'s dataset from Critical Role (a D&D podcast), Louis and Sutton (2018)'s dataset from roleplayerguild.com (a D&D forum), Urbanek et al. (2019)'s crowdsourced LIGHT dataset, and/or Akoury et al. (2020)'s STORIUM dataset for human+AI collaborative story generation.
+
+# 8 Discussion and Conclusions
+
+We have demonstrated that training on D&D data results in much higher quality outputs than a vanilla dialogue system (as expected), that controlling the model to generate in-character responses results in substantially more interesting output, and that conditioning on game state information qualitatively results in responses that are appropriate to the character class. Our preliminary experiments with using the large language models to perform game state tracking show low performance even after finetuning, suggesting that other models may be required for an AI to play D&D track the full state of the game.
+
+Although our models are unable to play D&D fully autonomously by acting as the Dungeon Master, they could act as an aid for novice DMs. Since our models can generate evocative, in-character text that is appropriate for the context and the game state, DMs could use it as inspiration as they narrate the adventure to the other players.
+
+Here is some model output to inspire your next adventure:
+
+You get a much closer look than the other two... the sarcophagi have the inscriptions of some sort of magic, probably to keep the dead inside, but you can not read them to save your life.
+
+What will you do next? Download our dataset to start your new adventure!
+
+# 9 Limitations
+
+One limitation of our human evaluation is that it is a static evaluation. The raters are simply reading the outputs of the model, and there is no interactive evaluation wherein they engage in gameplay with the system. An interactive user-study would be required before any claims could be made about how well AI is able to play D&D alongside human players.
+
+Because our state information was created heuristically, it therefore potentially contains errors. It is also incomplete. There are several kinds of state tracking variables that would be useful to include, but were not possible to heuristically extract from our data. To address this problem in the future, we have begun a collaboration with the developer of Avrae, which is a Discord bot for playing
+
+D&D online. Avrae contains many state variables that are missing from our current annotations, such as HIT points and slot-filler values for attacks.
+
+# 10 Acknowledgments
+
+We would like to thank Antony Pegg of Fandom for granting us permission to use D&D Beyond's forum data for research purposes.
+
+Thank you to Rich Burlew and forum moderator truemane for granting us permission to crawl the Giant in the Playground forum and to build models using the forum posts.
+
+We would like to thank the many Google Researchers who gave valuable input on this project, especially Dipanjan Das and Suma Bailis.
+
+Chris Callison-Burch is grateful for having the opportunity to be a part-time visiting researcher at Google for two years. It was amazing to spend time among such incredibly smart people, and it was eye opening to see large LMs before they became widely available. Thanks!
+
+# References
+
+Daniel Adiwardana, Minh-Thang Luong, David R So, Jamie Hall, Noah Fiedel, Romal Thoppilan, Zi Yang, Apoorv Kulshreshtha, Gaurav Nemade, Yifeng Lu Quoc, and V Le. 2020. Towards a Human-like Open-Domain Chatbot. arXiv preprint arXiv:2001.09977.
+Nader Akoury, Shufan Wang, Josh Whiting, Stephen Hood, Nanyun Peng, and Mohit Iyyer. 2020. STORIUM: A Dataset and Evaluation Platform for Machine-in-the-Loop Story Generation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6470–6484, Online. Association for Computational Linguistics.
+Prithviraj Ammanabrolu, William Broniec, Alex Mueller, Jeremy Paul, and Mark O. Riedl. 2020a. Toward Automated Quest Generation in Text-Adventure Games. In International Conference on Computational Creativity (ICCC).
+Prithviraj Ammanabrolu, Jack Urbanek, Margaret Li, Arthur Szlam, Tim Rocktäschel, and Jason Weston. 2020b. How to Motivate Your Dragon: Teaching Goal-Driven Agents to Speak and Act in Fantasy Worlds. In The North American Chapter of the Association for Computational Linguistics (NAACL-HLT).
+Boyd Branch, Piotr Mirowski, and Kory Mathewson. 2021. Collaborative Storytelling with Human Actors and AI Narrators. In International Conference on Computational Creativity (ICCC), pages 97-101.
+
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. 2020. Language models are few-shot learners. Advances in neural information processing systems, 33:1877-1901.
+Sahith Dambekodi, Spencer Frazier, Prithviraj Ammanabrolu, and Mark O Riedl. 2020. Playing Text-Based Games with Common Sense. In Wordplay: When Language Meets Games Workshop (NeurIPS 2020).
+Simon Ellis and James Hendler. 2017. Computers Play Chess, Computers Play Go...Humans Play Dungeons & Dragons. IEEE Intelligent Systems, 32(4):31-34.
+Angela Fan, Mike Lewis, and Yann Dauphin. 2018. Hierarchical Neural Story Generation. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics, pages 889-898.
+Angela Fan, Jack Urbanek, Pratik Ringshia, Emily Dinan, Emma Qian, Siddharth Karamcheti, Shrimai Prabhumoye, Douwe Kiela, Tim Rocttäschel, Arthur Szlam, and Jason Weston. 2020. Generating Interactive Worlds with Text. In AAAI Conference on Artificial Intelligence (AAAI), pages 1693-1700.
+Matt Gardner, Joel Grus, Mark Neumann, Oyvind Tafjord, Pradeep Dasigi, Nelson Liu, Matthew Peters, Michael Schmitz, and Luke Zettlemoyer. 2018. AllenNLP: A deep semantic natural language processing platform. arXiv preprint arXiv:1803.07640.
+Sarik Ghazarian, Zixi Liu, Tuhin Chakrabarty, Xuezhe Ma, Aram Galstyan, and Nanyun Peng. 2021. DiS-CoL: Toward Engaging Dialogue Systems through Conversational Line Guided Response Generation. arXiv preprint arXiv:2102.02191.
+Matan Haroush, Tom Zahavy, Daniel J. Mankowitz, and Shie Mannor. 2018. Learning How Not to Act in Text-Based Games. In Workshop Track at ICLR 2018, pages 1-4.
+Chenglong Hou, Chensong Zhou, Kun Zhou, Jinan Sun, and Sisi Xuanyuan. 2019. A survey of deep learning applied to story generation. In Smart Computing and Communication, pages 1-10. Springer International Publishing.
+Jeremy Howard and Sebastian Ruder. 2018. Universal language model fine-tuning for text classification. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 328-339, Melbourne, Australia. Association for Computational Linguistics.
+Daphne Ippolito, David Grangier, Chris Callison-Burch, and Douglas Eck. 2019. Unsupervised Hierarchical Story Infilling. In Proceedings of the First Workshop on Narrative Understanding, pages 37-43.
+
+Nitish Shirish Keskar, Bryan McCann, Lav R. Varshney, Caiming Xiong, and Richard Socher. 2019. CTRL: A Conditional Transformer Language Model for Controllable Generation. arXiv preprint arXiv:1909.05858.
+Jiwei Li, Will Monroe, Alan Ritter, and Dan Jurafsky. 2016. Deep Reinforcement Learning for Dialogue Generation. In Conference on Empirical Methods in Natural Language Processing, pages 1192-1202.
+Annie Louis and Charles Sutton. 2018. Deep Dungeons and Dragons: Learning Character-Action Interactions from Role-Playing Game Transcripts. In Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies (NAACL-HLT), pages 708-713.
+Lara J. Martin, Prithviraj Ammanabrolu, Xinyu Wang, William Hancock, Shruti Singh, Brent Harrison, and Mark O. Riedl. 2018a. Event Representations for Automated Story Generation with Deep Neural Nets. In Thirty-Second AAAI Conference on Artificial Intelligence, pages 868-875, New Orleans, Louisiana.
+Lara J. Martin, Srijan Sood, and Mark O. Riedl. 2018b. Dungeons and DQNs: Toward Reinforcement Learning Agents that Play Tabletop Roleplaying Games. In Joint Workshop on Intelligent Narrative Technologies and Workshop on Intelligent Cinematography and Editing (INT-WICED), Edmonton, AB, Canada.
+Kory W. Mathewson, Pablo Samuel Castro, Colin Cherry, George Foster, and Marc G. Bellemare. 2019. Shaping the Narrative Arc: An Information-Theoretic Approach to Collaborative Dialogue. arXiv preprint arXiv:1901.11528, page 20.
+Johannes E. M. Mosig, Vladimir Vlasov, and Alan Nichol. 2020. Where is the context? - A critique of recent dialogue datasets. CoRR, abs/2004.10473.
+Xiangyu Peng, Siyan Li, Sarah Wiegrefe, and Mark Riedl. 2021. Inferring the Reader: Guiding Automated Story Generation with Commonsense Reasoning. In Workshop on Narrative Understanding at NAACL-HLT 2021.
+Shrimai Prabhumoye, Khyathi Raghavi Chandu, Ruslan Salakhutdinov, and Alan W Black. 2019. "My Way of Telling a Story": Persona based Grounded Story Generation. In Storytelling Workshop at ACL 2019, pages 11-21.
+Revanth Rameshkumar and Peter Bailey. 2020. Storytelling with Dialogue: A Critical Role Dungeons and Dragons Dataset. In Annual Meeting of the Association for Computational Linguistics (ACL), pages 5121-5134.
+Hannah Rashkin, Asli Celikyilmaz, Yejin Choi, and Jianfeng Gao. 2020. PlotMachines: Outline-Conditioned Generation with Dynamic Plot State Tracking. In Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4274-4295.
+
+Melissa Roemmele. 2018. Neural Networks for Narrative Continuation. Ph.D. thesis, University of Southern California.
+Abdelrhman Saleh, Natasha Jaques, Asma Ghandeharioun, Judy Hanwen Shen, and Rosalind Picard. 2020. Hierarchical Reinforcement Learning for Open-Domain Dialog. In AAAI Conference on Artificial Intelligence (AAAI), pages 8741-8748.
+Abigail See, Aneesh Pappu, Rohun Saxena, Akhila Yerukola, and Christopher D. Manning. 2019. Do Massively Pretrained Language Models Make Better Storytellers? In Conference on Computational Natural Language Learning (CoNLL), pages 843-861.
+Iulian Vlad Serban, Ryan Lowe, Laurent Charlin, and Joelle Pineau. 2016. Generative Deep Neural Networks for Dialogue: A Short Review. In *Conference on Neural Information Processing Systems (NeurIPS)*, Workshop on Learning Methods for Dialogue, pages 1-6.
+Eric Michael Smith, Diana Gonzalez-Rico, Emily Dinan, and Y-Lan Boureau. 2020. Controlling Style in Generated Dialogue. arXiv preprint arXiv:2009.10855.
+Pradyumna Tambwekar, Murtaza Dhuliawala, Lara J. Martin, Animesh Mehta, Brent Harrison, and Mark O. Riedl. 2019. Controllable Neural Story Plot Generation via Reinforcement Learning. In International Joint Conference on Artificial Intelligence (IJCAI), Macau, China.
+Romal Thoppilan, Daniel De Freitas, Jamie Hall, Noam Shazeer, Apoorv Kulshreshtha, Heng-Tze Cheng, Alicia Jin, Taylor Bos, Leslie Baker, Yu Du, YaGuang Li, Hongrae Lee, Huaixiu Steven Zheng, Amin Ghafouri, Marcelo Menegali, Yanping Huang, Maxim Krikun, Dmitry Lepikhin, James Qin, Dehao Chen, Yuanzhong Xu, Zhifeng Chen, Adam Roberts, Maarten Bosma, Yanqi Zhou, Chung-Ching Chang, Igor Krivokon, Will Rusch, Marc Pickett, Kathleen S. Meier-Hellstern, Meredith Ringel Morris, Tulsee Doshi, Renelito Delos Santos, Toju Duke, Johnny Soraker, Ben Zevenbergen, Vinodkumar Prabhakaran, Mark Diaz, Ben Hutchinson, Kristen Olson, Alejandra Molina, Erin Hoffman-John, Josh Lee, Lora Aroyo, Ravi Rajakumar, Alena Butryna, Matthew Lamm, Viktoriya Kuzmina, Joe Fenton, Aaron Cohen, Rachel Bernstein, Ray Kurzweil, Blaise Aguera-Arcas, Claire Cui, Marian Croak, Ed H. Chi, and Quoc Le. 2022. LaMDA: Language Models for Dialog Applications. CoRR, abs/2201.08239.
+Jack Urbanek, Angela Fan, Siddharth Karamcheti, Saachi Jain, Samuel Humeau, Emily Dinan, Tim Rocktäschel, Douwe Kiela, Arthur Szlam, and Jason Weston. 2019. Learning to Speak and Act in a Fantasy Text Adventure Game. In Conference on Empirical Methods in Natural Language Processing and the International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages
+
+673-683, Hong Kong, China. Association for Computational Linguistics.
+
+Nick Walton. 2019. AI Dungeon.
+
+Lili Yao, Nanyun Peng, Ralph Weischedel, Kevin Knight, Dongyan Zhao, and Rui Yan. 2019. Plan-And-Write: Towards Better Automatic Storytelling. In AAAI Conference on Artificial Intelligence (AAAI), volume 33(01), pages 7378-7385.
+
+Shunyu Yao, Rohan Rao, Matthew Hausknecht, and Karthik Narasimhan. 2020. Keep CALM and Explore: Language Models for Action Generation in Text-based Games. In Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 8736-8754.
+
+Saizheng Zhang, Emily Dinan, Jack Urbanek, Arthur Szlam, Douwe Kiela, and Jason Weston. 2018. Personalizing Dialogue Agents: I have a dog, do you have pets too? In Annual Meeting of the Association for Computational Linguistics (ACL), pages 2204-2213, Melbourne, Australia.
+
+Yizhe Zhang, Siqi Sun, Michel Galley, Yen-Chun Chen, Chris Brockett, Xiang Gao, Jianfeng Gao, Jingjing Liu, and Bill Dolan. 2019. *DialoGPT: Large-Scale Generative Pre-training for Conversational Response Generation*. arXiv preprint arXiv:1911.00536.
+
+# A Example D&D Game Session
+
+Instead of the game being a series of moves on a game board, RPGs D&D are language-based. Players create characters that have a class (wizard, fighter, thief, etc.) that denotes their abilities, and a fantasy race (elf, dwarf, human, etc.). Players describe what they want their character to do and roll dice to determine if they are successful. The dungeon master (DM) acts as the narrator who shapes the overall story. The DM describes scenarios and locations, and takes on the role of non-player characters (NPCs), and monsters.
+
+A common element to the game play is an encounter with monsters. Battles are governed by rules, and unfold in a turn-based fashion where the DM controls the monsters and each player controls their character. Each player and monster has a health meter (called their HIT points), an armor class (which indicates the threshold of the dice roll needed to damage them), and a set of possible attack or move actions.
+
+Table 8 provides example dialogue from a game of D&D being played between 3 players - Travis (playing a human fighter named Magnus Burnsides), Clint (playing Merle Highchurch, a dwarf
+
+cleric), Justin (playing Taako an elf wizard), and DM Griffin. We add comments about each dialogue turn to describe what is happening in the game, and to highlight the challenges that would need to be addressed if an AI system were to play the game either as a player or as the DM.
+
+The game session is taken from the podcast The Adventure Zone. In this episode, the hosts are playing an adventure module called Lost Mine of Phadelver, an expert of which is given in Appendix B. In the first episode of the podcast6, the hosts explain the rules of D&D.
+
+# B Lost Mine of Phadelver Adventure
+
+Here is an excerpt from the adventure book that the Dungeon Master was using in our example game play. The adventure book provides boxed text, which is descriptive text to be read aloud verbatim or to paraphrase. It also gives details about the combat that is about to ensure, and links to relevant game rules (like stealth checks, and statistics about the monsters that the characters will be in combat with).
+
+The adventure begins as the player characters are escorting a wagon full of provisions and supplies from Neverwinter to Phandalin. The journey takes them south along the High Road to the Triboar Trail, which heads east (as shown on the overland map). When they're a half-day's march from Phandalin, they run into trouble with goblin raiders from the Cragmaw tribe.
+
+Read the boxed text when you're ready to start. If you create a different adventure hook, skip to the second paragraph and adjust the details as necessary, ignoring the information about driving the wagon.
+
+In the city of Neverwinter, a dwarf named Gundren Rockseeker asked you to bring a wagonload of provisions to the rough-and-tumble settlement of Phandalin, a couple of days' travel southeast of the city. Gundren was clearly excited and more than a little secretive about his reasons for the trip, saying only that he and his brothers had found "something big," and that he'd pay you ten gold pieces each for escorting his supplies safely to Barthen's Provisions, a trading post in Phandalin. He then set out ahead of you on horse, along with a warrior escort named Sildar Hallwinter, claiming he needed to arrive early to "take care of business."
+
+You've spent the last few days following the High Road south from Neverwinter, and you've just recently veered east along the Triboar Trail. You've encountered no trouble so far, but this territory can be dangerous. Bandits and outlaws have been known to lurk along the trail.
+
+You've been on the Triboar Trail for about half a day. As you come around a bend, you spot two
+
+| Player(character) | Game Dialogue | D&D Game Description andAI challenges |
| Griffin (DM) | A dwarf named Gundren Rockseeker has hired you to transport a wagonload of provisions to the rough-and-tumble settlement of Phandalin, which is a couple days' travel to the southeast.A day and a half after leaving, you turn off the high road that connects the major cities on the coast onto a smaller trail that will lead you to Phandalin. This trail is not as well maintained, and bandits and outlaws have been known to lurk along the trail. | This game is based on the D&D starter adventure called “Lost Mine of Phadelver”. The adventure book is a mixture of rules and “boxed text” which is descriptive text for the DM to read aloud or paraphrase. See the appendix for the text that the DM is consulting. AI challenges: Generation of stories and descriptive text |
| Griffin (DM) | Roll a perception check for me. Perception is a wisdom skill, so be sure to add your wisdom modifier. | The previous text was descriptive text. Here the DM is asking the players to perform a game mechanic and referencing a game rule. This is called “out of character” dialogue. AI challenges: Knowledge base population (extraction of rules from a rulebook) |
| Clint (out of character) | I got an eight. | Clint has rolled his dice. The number is low so his character fails the check. AI challenges: Multi-party dialogue |
| Justin (out of character) | I got a six. | Justin also fails. Neither character sees the thing that requires the perception check. |
| Travis (out of character) | I rolled a natural twenty plus my wisdom modifier is 23. | Travis rolls high number and succeeds on the check. AI challenges: Understanding rules, determining success or failure |
| Griffin (DM) | With his eagle eyes, Magnus spots two dead horses lying in the middle of the road about 200 feet ahead of you. | The DM describes what happens as a result of the success. AI challenges: Reasoning about consequences of success or failure, descriptive text generation |
| Travis (in-character as Magnus) | I stop the wagon and motion silently to get the attention of Merle and Taako, and kinda pull them up towards the front of the wagon. | Travis is describing what he is doing using “in character” language. AI challenges: Persona-based chat |
| Griffin (DM) | As you warn them that shit has gone south, you notice a few goblins crouching in a part of the shaded woods off to the side of the road. Two of the goblins begin charging your wagon. | The DM describes the start of a battle with several monsters. AI challenges: State tracking (in combat v. out of combat). |
| Travis (out of character) | How many goblins are there? | AI challenges: Question answering, state tracking (how many monsters). |
| Griffin (DM) | There are three goblins; two of them are rushing the group, one is pretty heavily obscured by the brush, probably about 40 feet out, sort of between you and the dead horses laying in the middle of the road. | AI challenges: Question answering, Descrip-tive text generation from game state. |
| Clint (Merle) | I will cast sacred flame at the nearest one. If it fails a dexterity saving throw, it takes 6 points of damage. | Clint chooses an action based on what is allowed for his character class. He describes the rule that governs the spell in an out-of-character fash-ion. AI challenges: Intent detection (perform attack action against a particular goblin) |
| Griffin (DM) | You attack. You launch some fire onto the goblin closest to the wagon. And with that, he looks like he is on death's door. And the other goblin that you can see, the one that's not in the brush somewhere, just sort of stops in his tracks. What do you do next? | The DM rolls for the monster; updates the state of its health meter, and describes the result of Merle's attack. AI challenges: Reasoning about rules, state tracking (monster's HIT points), descriptive text generation. |
+
+Table 8: Example dialogue from a game of D&D with explanations of what is happening and comments on potential challenges for AI
+
+dead horses sprawled about fifty feet ahead of you, blocking the path. Each has several blackfeathered arrows sticking out of it. The woods press close to the trail here, with a steep embankment and dense thickets on either side.
+
+Four goblins are hiding in the woods, two on each side of the road. They wait until someone approaches the bodies and then attack.
+
+This will likely be the first of many combat encounters in the adventure. Here are the steps you should follow to run it effectively:
+
+- Review the goblin stat block. Since the goblins are hiding, you'll need their Stealth skill modifier: +6.
+- Check to see who, if anyone, is surprised. The party can't surprise the goblins, but the goblins might surprise some or all of the characters. Make a Dexterity (Stealth) check for the goblins: roll one d20 for all of them, add their Stealth skill modifier (+6) to the roll, and compare the total to the characters' passive Wisdom (Perception) scores. A character whose score is lower than the goblins' check total is surprised and therefore can't do anything on his or her first turn in the combat (see "Surprise" in the Basic Rules).
+- Use the initiative rules in the Basic Rules to determine who acts first, second, third, and so on. Keep track of everyone's initiative count on a piece of paper.
+- When the time comes for the goblins to act, two of them rush forward and make melee attacks while two goblins stand 30 feet away from the party and make ranged attacks. The goblins' stat block contains the information you need to resolve these attacks. For more information on what the goblins can do on their turn, see chapter 9, "Combat," in the Basic Rules. When three goblins are defeated, the last goblin attempts to flee, heading for the goblin trail
+
+# C Estimated accuracy of predicted state variables
+
+In addition to the heuristics that we used to recover state variables for each turn in the game (described in Section 3.1), we used a CNN to fill in state values when our heuristics did not fire. Table 9 estimates gives an estimate of the CNN's performance on filling in the state variables where the rule-based heuristic did not extract a value. The CNN classifier only uses current post text as input (no additional context).
+
+# D Annotation Guidelines and Annotation Interface
+
+# D.1 Annotation task
+
+In this task, you will see part of a conversation between a few people playing D&D. The players and their characters are listed at the beginning of the conversation. The conversations that are shown as context are real conversations from players. Your job is to read the context and then rate different responses for a player/character given conversational context. Please note that the context you are
+
+given represents only a part of the players' past conversations/interactions with one another during the game.
+
+For each response, you would be asked the following questions.
+
+- Does the response make sense?
+
+- Use your common sense here. Is the response completely reasonable in terms of the rules of D&D?
+- The response "makes sense" if it is cohesive as a standalone statement, consistent with the rules of the game, and the elements/entities mentioned are plausible, given the prior context.
+- If anything seems off—not fluent, confusing, illogical, out of context, or wrong according to the rules of D&D —then rate it as Does not make sense. If in doubt, choose Does not make sense.
+
+- Is the response specific?
+
+- You may be asked to assess whether the response is specific to a given context. In other words, do you think that the response represents a good thing for the character to do now?
+- The response is "specific" if it flows logically from the narrative established by the prior context.
+
+* Note: It is possible for a response to "make sense" (due to being cohesive, consistent and plausible in and of itself), but be marked "not specific" when it is not a logical next step in the overall game progression.
+
+* Note: "Specific" for the purposes of this task does not have to do with how detailed the response is per se; a response can be fairly general in its language, but still qualify as "specific" when it is a logical next step in the overall game progression.
+
+- How interesting is the response?
+
+- You may be asked to score the response for its interestingness on a scale of 10.
+
+Choose a high score for "Interesting" if the response would likely catch someone's attention or arouse curiosity in the game; or it is insightful, creative, or witty with respect to the game. If the response is monotonous and predictable, or if you're unsure, then it is Less Inter-
+
+| State variable | Model | Type | Multi-valued | Availability | Evaluation metric | Performance |
| Character | Span labeller | Text | No | 42% | - | - |
| Race | Classifier | Text | No | >58% | Macro AUC | 0.45 |
| Class | Classifier | Text | No | >75% | Macro AUC | 0.71 |
| Pronous | Classifier | Text | No | 42% | Macro AUC | 0.92 |
| Inventory | Span labeller | Text | Yes | 11% | - | - |
| In combat? | Classifier | Score | No | 100% | Accuracy | 0.91 |
| Action | Classifier | Text | Yes | 20% | Macro AUC | 0.92 |
+
+Table 9: The estimated performance of our CNN classifier on predicting state values for turns where our rule-based heuristics did not predict a value
+
+esting.
+
+# D.2 Annotation Interface
+
+A mock up of the annotation user interface is given in Figure 3.
+
+# D.3 Survey of Raters
+
+We recruited raters who had a background in role playing games and an understanding of the fantasy genre. We surveyed our raters, asking them the following questions:
+
+1. Have you ever played Dungeons and Dragons or another role playing game before?
+2. If so,
+
+- roughly how many times have you played
+were you a player or a game master or both
+
+3. If not,
+
+- what kind of exposure do you have to Dungeons and Dragons? (For example, have you seen it referred to in TV or movies)
+
+4. Are you a fan of the fantasy genre (like Lord of the Rings)?
+
+Our 6 raters responded to the survey as follows: 5 out of the 6 have played D&D or another role playing game before. All 5 of those who have played D&D /other role playing games before have played more than 6 times. Of the 5 who have played D&D /other role playing games before, 3 played as both Game Master and Player. For the one who had not played D&D /other role playing games, they indicated they had not had much exposure to D&D through TV or other channels. All 6 answered that they were fans of the fantasy genre.
+
+| Context | Player 10 - Del | Ratings |
| Player 10 - Del (Barbarian)
+Player 0 - Dungeon Master
+Player 12 - Aramis (Bard)
+Player 8 - Xavier (Bard) | Response 1
+Del quickly searches the store room, grabbing whatever weapons he find useful. He then heads back to the others "I found another crossbow and arrows, and a dagger. I have a short bow, but I'll leave it here if someone else wants it. I also found one of my javelins that I was missing." | Does this response make sense?
+□ Makes sense
+□ Does not make sense
+Is this response specific to the given context?
+□ Specific
+□ Not specific
+How interesting is this response on a scale of 10? |
| Player 10 - Del (Barbarian): Del gives a final kick to the dead orc that he just killed then proceeds to hunt through the main room then the store room, looking for his axe and other gear | Response 2
+del takes the crowbar and tells xavier to find hes ***en axe and ill keep good care of him | Does this response make sense?
+□ Makes sense
+□ Does not make sense
+Is this response specific to the given context?
+□ Specific
+□ Not specific
+How interesting is this response on a scale of 10? |
| Player 0 - Dungeon Master : Del - make an investigation check.
+Player 10 - Del (Barbarian): 3 |
| Player 0 - Dungeon Master : The barbarian begins tossing things around, overturning tables and tearing crates and sacks open, though his still simmering rage at being locked up prevents him from undertaking a thorough search. He turns up a shortbow, a light crossbow, a few javelins, 2 quivers of arrows, 2 cases of crossbow bolts, a crate full of mismatched leather armour and a few sacks full of preveserved fruit and vegetables. There is no sign of the equipment that was taken from him last night.
+Player 12 - Aramis (Bard) : ""anyone seen any keys? or my stuff?"" aramis calls out to everyone |
| Player 8 - Xavier (Bard) : *quickly picking up the dead orcs cleaver so a better weapon Xavier turns to the rest of the party* "fighting is not over, we are not sure what to be found up there, raid the store room, we must be ready for more combat""i turn to del*
+""would you stand with me to defend the rest while they re-arm?""
+*i offer the crowbar to del* "then turn back to the party" "and if you find a shield and sword in there, i require a stronger defence and fist" | Does this response make sense?
+□ Makes sense
+□ Does not make sense
+Is this response specific to the given context?
+□ Specific
+□ Not specific
+How interesting is this response on a scale of 10? |
+
+Figure 3: The user interface that our raters used to evaluate the quality of our model's next utterance prediction.
\ No newline at end of file
diff --git a/dungeonsanddragonsasadialogchallengeforartificialintelligence/images.zip b/dungeonsanddragonsasadialogchallengeforartificialintelligence/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..004c3c6be45fc2eb8bbf1dc25ae5e1bd066133ec
--- /dev/null
+++ b/dungeonsanddragonsasadialogchallengeforartificialintelligence/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:776dcab731e1dd12787ef1869e358911ab2c5168d76872caea3aa01db29aa514
+size 1185382
diff --git a/dungeonsanddragonsasadialogchallengeforartificialintelligence/layout.json b/dungeonsanddragonsasadialogchallengeforartificialintelligence/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..5830f9aab9d61a7c023ba0f2a01c883798b35edc
--- /dev/null
+++ b/dungeonsanddragonsasadialogchallengeforartificialintelligence/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:00330262d9b78d2ca302247f223b7bc66f8b539553c1374b521a7b8fe8387e36
+size 424377
diff --git a/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_content_list.json b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..0a3fa63386536bacd6495963f255a064ceec21a3
--- /dev/null
+++ b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:acd361e91261a289c2ba901a48eeffdb88c4708c640e53948e143a86986840c1
+size 97032
diff --git a/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_model.json b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..113d132929bbd0a3d120edf55026dfd5cd2ae9f8
--- /dev/null
+++ b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:91506966a61e4a88067d5698a9bbec3aa9479c1767b838e0195e152c73466670
+size 115885
diff --git a/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_origin.pdf b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..a947d2e8ba9788eff6bce1690109fe69a0c13712
--- /dev/null
+++ b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/c0ff9b82-c5da-48cf-bfeb-69a35dd3de6c_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d4d452b23fc14460933edd93e89997bb0edbe9e307c0021129184bc96a189b1d
+size 795991
diff --git a/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/full.md b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..6059a7fdbf74d35981341503bf9f41e19c4a2cbe
--- /dev/null
+++ b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/full.md
@@ -0,0 +1,323 @@
+# DuQM: A Chinese Dataset of Linguistically Perturbed Natural Questions for Evaluating the Robustness of Question Matching Models
+
+Hongyu Zhu\*\*, Yan Chen\*\*, Jing Yan\*\*, Jing Liu\*\*, Yu Hong\*\*, Ying Chen\*, Hua Wu\*, Haifeng Wang\*
+
+$\spadesuit$ School of Computer Science and Technology, Soochow University, China
+
+$\clubsuit$ Baidu Inc., Beijing, China
+
+{hines.zhu, tianxianer} $@$ gmail.com
+
+{chenyan22, yanjing09, liujing46, cheny ing04, wu_hua, wanghaifeng} @baidu.com
+
+# Abstract
+
+In this paper, we focus on the robustness evaluation of Chinese Question Matching (QM) models. Most of the previous work on analyzing robustness issues focus on just one or a few types of artificial adversarial examples. Instead, we argue that a comprehensive evaluation should be conducted on natural texts, which takes into account the fine-grained linguistic capabilities of QM models. For this purpose, we create a Chinese dataset namely DuQM which contains natural questions with linguistic perturbations to evaluate the robustness of QM models. DuQM contains 3 categories and 13 subcategories with 32 linguistic perturbations. The extensive experiments demonstrate that DuQM has a better ability to distinguish different models. Importantly, the detailed breakdown of evaluation by the linguistic phenomenon in DuQM helps us easily diagnose the strength and weakness of different models. Additionally, our experiment results show that the effect of artificial adversarial examples does not work on natural texts. Our baseline codes and a leaderboard are now publicly available. $^{1}$
+
+# 1 Introduction
+
+The task of Question Matching (QM) aims to identify the question pairs that have the same meaning, and it has been widely used in many applications, e.g., community question answering and intelligent customer services, etc. Though neural QM models have shown compelling performance on various datasets, including Quora Question Pairs (QQP) (Iyer et al., 2017), LCQMC (Liu et al., 2018), BQ (Chen et al., 2018) and AFQMC $^2$ , neu
+
+ral models are often not robust to adversarial examples, which means that the neural models predict unexpected outputs given just a small perturbations on the inputs. As the example 1 in Tab. 1 shows, a model might not distinguish the minor difference ("noodles") between the two sentences, and thus predicts the two questions semantically equivalent.
+
+Recently, it attracts a lot of attention from the research community to deal with the robustness issues of neural models on various NLP tasks, such as question matching, natural language inference and machine reading comprehension. Early works examine the robustness of neural models by creating certain types of artificial adversarial examples (Jia and Liang, 2017; Alzantot et al., 2018; Ren et al., 2019; Jin et al., 2020), and involving human-and-model-in-the-loop to create dynamic adversarial examples (Nie et al., 2020; Wallace et al., 2019). Further studies discover that a few types of superficial cues (i.e. shortcuts) in the training data, are learned by the models and hence affect the model robustness (Gururangan et al., 2018; McCoy et al., 2019; Lai et al., 2021). Besides, several studies try to improve the robustness of the neural models by adversarial data augmentation (Min et al., 2020) and data filtering (Bras et al., 2020). All these efforts motivate us to better find and fix the robustness issues.
+
+However, there are several limitations in previous studies. Firstly, the analysis and evaluation in previous work focus on just one or a few types of adversarial examples or shortcuts, but we need normative evaluation (Linzen, 2020; Ettinger, 2020; Phang et al.). In the normative evaluation (Linzen, 2020), the objective is not to fool the system by exploiting its particular weaknesses, but to comprehensively evaluate the basic linguistic capabilities of the models with a variety of systemically controlled datasets. Checklist (Ribeiro et al., 2020), QuAIL (Rogers et al., 2020) and Textflint (Wang et al., 2021) are great attempts of normative evalua
+
+tions. However, it is not clear that if the artificial adversarial training is effective on natural texts from real-world applications (Morris et al., 2020). Some other works manually perturb the examples to construct natural examples, but the manual perturbation is time consuming and costly (Gardner et al., 2020). Moreover, to the best of our knowledge, there are few Chinese datasets for QM robustness evaluation.
+
+Towards this end, we create an open-domain Chinese dataset namely DuQM containing natural questions with linguistic perturbation for evaluating the robustness of QM models. (1) By linguistic, we mean that the dataset provides a detailed breakdown of evaluation by linguistic phenomenon. As shown in Tab. 1, there are 3 categories and 13 subcategories with 32 linguistic perturbations in DuQM, which enables us to evaluate the model performance by each category instead of just a single metric. (2) By natural, we mean all the questions in DuQM are natural, that are issued by the users in Baidu search. This design can help us to properly evaluate model's robustness on natural texts rather than artificial texts, which may not preserve semantics and the distribution of which is far from real-world applications.
+
+The contributions of this paper can be summarized as follows:
+
+- We construct a Chinese dataset namely DuQM that contains linguistically perturbed natural questions from Baidu search. It is a systemically controlled dataset to test various linguistic capabilities of the models (see Sec. 2). Additionally, except for few categories, most of the categories' construction methods can be easily extended to other languages (see Sec. 3).
+- Our experimental results reveal three characteristics of DuQM: (1) DuQM is challenging, and has better discrimination power to distinguish the models that perform comparably on other datasets (see Sec. 4.2). (2) The detailed breakdown of evaluation by linguistic phenomena in DuQM helps diagnose the advantages and disadvantages of different models (see Sec. 4.3). (3) The whole DuQM dataset composed of natural examples. Our experimental result shows that the artificial adversarial training fails in natural texts of DuQM. DuQM can help us properly evaluate the models' robustness (see Sec. 4.4).
+
+The remaining of this paper is organized as follows. Sec. 2 describes the 3 categories and
+
+13 subcategories with 32 linguistic perturbations in DuQM. Sec. 3 gives the construction process of DuQM. In Sec. 4, we conduct experiments to demonstrate 3 characteristics of DuQM. We conclude our work in Sec. 5.
+
+# 2 Linguistic Perturbations in DuQM
+
+The design of DuQM is aimed at normative evaluation, that contains a detailed breakdown of evaluation by linguistic phenomenon. Hence, we create DuQM by introducing a set of linguistic features that we believe are important for model diagnosis in terms of linguistic capabilities. Basically, 3 categories of linguistic features are used to build DuQM, i.e., lexical features (see Sec. 2.1), syntactic features (see Sec. 2.2), and pragmatic features (see Sec. 2.3). We list 3 categories, 13 subcategories with 32 operations of perturbation in Tab. 1. The detailed descriptions of all categories are given in this section.
+
+# 2.1 Lexical Features
+
+Lexical features are associated with vocabulary items, i.e. words. As a word is the smallest independent but meaningful unit of speech, an operation on a single word may change the meaning of the entire sentence. It is a basic but crucial capability for models to understand word and perceive word-level perturbations. To provide a fine-grained evaluation for model's capability of lexical understanding, we further consider 6 subcategories:
+
+Part of Speech. Parts of speech (POS), or word classes, describe the part a word plays in a sentence. DuQM considers 6 POS in Chinese grammar, including noun, verb, adjective, adverb, numeral and quantifier, which are content words that carry most meaning of a sentence. In this subcategory, we aim to test the models' understanding of words with different POSs by replacing them with related but not identical words. As the example 1 in Tab. 1 shows, inserting only one noun "面 noodles" makes the sentence meaning different. Furthermore, in this subcategory we provides a set of examples focusing on phrase-level perturbations to check model's capability on understanding word groups that act collectively as a single part of speech(see Exp. 11).
+
+Named Entity. Different from common nouns that refer to generic things, a named entity (NE) is a proper noun which refers to a specific real-world object. The close relation to world knowledge makes NE ideal for observing models' under
+
+| Category | Subcategory | Perturbation Operation | Label #Y / #N | BERT base | ERNIE base | RoBERTa base | MacBERT base | RoBERTa large | MacBERT large | Examples and Translation |
| Lexical Feature | Part of Speech | insert n. | -539 | 41.4±3.4 | 40.8±2.1 | 43.0±0.7 | 41.4±2.5 | 45.4±4.1 | 37.3±2.4 | E1: 鸡蛋怎么炒好吃 / 鸡蛋面怎么炒好吃 how to fry eggs / how to fry egg noodles |
| insert v. | -131 | 39.4±0.4 | 33.8±2.6 | 37.4±2.0 | 35.9±2.7 | 39.9±3.1 | 29.5±3.8 | E2: 梦到西红柿意味着什么 / 梦到 摇西红柿意味着什么 what does it mean to dream of tomatoes / what does it mean to dream of picking tomatoes |
| insert adj. | -458 | 23.5±1.9 | 19.2±3.7 | 26.9±4.4 | 23.9±4.2 | 18.1±2.4 | 10.4±2.1 | E3: 有哪些类型的app / 有哪些类型的移动app what are types of apps / what are types of mobile apps |
| insert adv. | -302 | 3.7±0.5 | 4.2±0.5 | 3.8±0.6 | 4.4±1.2 | 5.8±1.5 | 3.1±1.1 | E4: 为什么打嗝 / 为什么老打嗝 why burp / why always bup |
| replace n. | -702 | 86.6±0.3 | 86.7±0.1 | 88.3±0.3 | 88.8±1.2 | 89.4±1.6 | 87.8±0.7 | E5: 申请美国 绿卡流程是什么 / 申请美国 签证流程是什么 what is U.S. green card application process / what is U.S. visa application process |
| replace v. | -466 | 71.7±1.1 | 77.6±0.8 | 76.9±0.4 | 76.5±1.2 | 81.0±1.6 | 81.5±2.2 | E6: 为什么下聘 膝盘疼 / 为什么下跪 膝盘疼 why knee pain when squating / why knee pain when kneeling |
| replace adj. | -472 | 74.3±2.1 | 80.0±1.0 | 77.6±0.7 | 81.6±0.5 | 82.7±1.1 | 82.7±1.6 | E7: 耳朵出血严重吗 / 耳朵出血正常吗 is the ear bleeding serious / is the ear bleeding normal |
| replace adv. | -188 | 19.1±6.1 | 19.3±4.4 | 16.3±3.8 | 23.9±4.6 | 59.0±4.0 | 56.2±2.0 | E8: 为什么会经常头晕 / 为什么会有点头晕 why regularly feel dizzy / why slightly feel dizzy |
| replace num. | -1116 | 83.2±1.4 | 91.4±0.4 | 85.9±1.8 | 87.2±0.9 | 88.1±0.5 | 91.9±1.1 | E9: 血压 130/100高吗 / 血压 120/100高吗 is blood pressure 130/100 high / is blood pressure 120/100 high |
| replace quantifier | -72 | 30.3±6.9 | 25.7±5.2 | 33.3±2.6 | 34.9±2.6 | 27.3±0.0 | 34.8±10.5 | E10: 一束花多少钱 / 一枝花多少钱 how much is a bunch of flower / how much is a flower |
| replace phrases | -197 | 98.0±0.0 | 98.1±0.2 | 96.6±0.3 | 97.8±0.5 | 97.8±0.2 | 97.5±0 | E11: 如何提高自己的记忆力 / 如何增加自己的实力 how to improve my memory / how to increase my strength |
| Named Entity | replace loc. | -458 | 96.0±0.6 | 95.7±0.2 | 95.4±0.4 | 95.0±0.4 | 94.7±0.4 | 94.5±0.5 | E12: 山西春节习俗是什么 / 陕西 春节习俗是什么 what is Shannxi spring festival customs / what is Shannxi spring festival customs |
| replace org. | -264 | 94.9±0.2 | 94.3±0.6 | 91.2±1.4 | 93.4±0.7 | 93.5±0.3 | 93.8±0.1 | E13: 北京邮电大学附近酒店有哪些 / 南京邮电大学附近酒店有哪些 what are hotels near BUPT / what are hotels near NUPT |
| replace person | -468 | 90.3±1.3 | 91.0±0.9 | 88.7±1.6 | 91.4±1.6 | 92.3±1.3 | 93.2±1.1 | E14: 陈龙的妻子是谁 / 成龙的妻子是谁 who is Long Chen 's wife / who is Jackie Chan 's wife |
| replace product | -170 | 83.7±2.6 | 88.2±2.1 | 82.4±6.9 | 83.3±0.3 | 86.0±1.7 | 88.8±4.4 | E15: iPhone 6 多少钱 / iPhone6x多少钱 how much is iPhone 6 / how much is iPhone6x |
| Synonym | replace n. | 405/- | 51.1±1.1 | 59.7±1.3 | 59.7±2.2 | 60.7±2.0 | 63.3±3.1 | 71.6±4.0 | E16: 独眼矮的的功效是什么 / 奇异果的功效是什么 what are the health benefits of Chinese gooseberry / what are the health benefits of Kiwi |
| replace v. | 372/- | 80.0±0.9 | 81.1±1.6 | 82.5±0.0 | 83.2±1.2 | 84.0±2.0 | 88.1±1.4 | E17: 什么果汁可以减肥 / 什么果汁可以减重 what juice can lose weight / what juice can slim |
| replace adj. | 453/- | 75.7±1.3 | 77.3±1.1 | 78.8±2.5 | 74.8±0.5 | 79.4±3.4 | 88.5±1.3 | E18: 有趣搞笑的广告词有哪些 / 幽默搞笑的广告词有哪些 what are the funny advertising words / what are the humorous advertising words |
| replace adv. | 26/- | 98.7±2.1 | 100.0±0.0 | 100.0±0.0 | 100.0±0.0 | 100±0.0 | 100.0±0.0 | E19: 总是想睡觉的是为什么 / 老是想睡觉的是为什么 why always want to sleep / why repeatedly want to sleep |
| Antonym | replace adj. | -305 | 50.6±3.4 | 69.6±2.9 | 65.0±1.5 | 73.1±4.3 | 91.7±2.3 | 90.7±2.3 | E20: 什么水果脂肪低 / 什么水果脂肪高 what fruit is low in fat / what fruit is high in fat |
| Negation | negate v. | -153 | 69.9±9.6 | 88.9±1.3 | 84.8±2.9 | 93.3±1.3 | 88.4±0.9 | 91.4±3.4 | E21: 为什么宝宝哭 / 为什么宝宝不哭 why baby cries / why baby doesn't cry |
| negate adj. | -139 | 73.1±8.5 | 84.2±1.2 | 82.7±1.4 | 88.0±1.5 | 88.0±2.9 | 89.4±1.0 | E22: 为什么苹果是红的 / 为什么苹果不是红的 why apple is red / why apple is not red |
| neg.+antonym | 59/- | 29.9±2.5 | 34.4±2.5 | 39.0±1.7 | 31.1±2.5 | 40.7±1.7 | 53.6±0.9 | E23: 激动怎么办 / 无法平静怎么办 what to do if too excited / what to do if can't calm down |
| Temporal word | insert | -120 | 26.6±2.1 | 29.1±2.1 | 33.1±0.9 | 41.7±3.3 | 47.5±4.4 | 33.6±8.5 | E24: 北京会下雨吗 / 北京明天会下雨吗 will it rain in Beijing / will it rain in Beijing tomorrow |
| replace | -114 | 44.1±6.1 | 67.8±2.6 | 55.0±0.5 | 53.8±1.3 | 70.4±6.1 | 78.6±5.8 | E25: 昨天下雪了吗 / 明儿会下雪吗 was it snow yesterday / will it snow tomorrow |
| Synactic Feature | Symmetry | swap | 533/- | 97.7±0.4 | 98.0±0.1 | 95.2±1.7 | 95.9±0.7 | 93.3±0.9 | 92.5±1.9 | E26: 鱼和鸡蛋能一起吃吗 / 鸡蛋和鱼能一起吃吗 can I eat fish with egg / can I eat egg with fish |
| Asymmetry | swap | -497 | 14.5±2.0 | 18.3±3.7 | 26.8±3.2 | 26.4±2.5 | 52.0±4.6 | 49.1±10.8 | E27: 北京到上海航班有哪些 / 上海到北京航班有哪些 what are the flights from Beijing to Shanghai / what are the flights from Shanghai to Beijing |
| Negative Asymmetry | swap + negate | 49/- | 47.6±3.4 | 37.4±7.7 | 44.2±1.1 | 25.8±3.1 | 23.1±6.7 | 29.9±1.9 | E28: 男人比女人更高吗 / 女人比男人更矮吗 are men taller than women / are women shorter than men |
| Voice | insert passive word | 94/37 | 76.8±1.4 | 72.5±0.0 | 77.4±0.9 | 74.0±0.7 | 85.2±1.4 | 74.8±2.2 | E29: 见狗咬左腿意味着什么 / 梦见被狗咬左腿意味着什么 what does it mean to dream of being bitten by a dog / what does it mean to dream of being bitten by a dog |
| Pragmatic Feature | Misspelling | replace | 468/- | 68.0±2.0 | 65.1±0.2 | 64.2±0.6 | 65.0±2.3 | 63.5±1.8 | 63.2±1.6 | E30: 什么纹身适合我 / 什么文身适合我 what tattoo suits me / what tattoo suits me |
| Discourse Particle (Simple) | insert or replace | 213/- | 98.7±0.5 | 98.4±0.2 | 98.6±0.5 | 99.2±0.2 | 99.5±0.0 | 99.8±0.2 | E31: 人为什么做梦 / 那么人为什么做梦 why people dream / so why people dream |
| Discourse Particle (Complex) | insert or replace | 131/- | 46.5±0.6 | 56.2±2.0 | 64.1±2.0 | 61.6±1.6 | 65.1±3.4 | 68.4±0.3 | E32: 附近最好的餐厅有哪些 / 求助我旁边哪家餐厅最好吃? what is the best restaurant nearby / heelp!!! which restaurant is best in my area? |
| Total | 13 | 32 | 2803/7318 | | | | | | | |
+
+Table 1: Categories of DuQM (described in Sec. 2) and performance of 6 models on each subcategory (discussed in Sec. 4). Bold face and underlined indicate the first and second highest accuracy for each testing scenario.
+
+standing of the meaning of names and background knowledge about entities. Thus, we include Named Entity as an independent subcategory to test the model's behavior of named entity recognition, and focus on 4 types of NE most commonly seen, i.e., location, organization, person and product. Example 12 is a search query and its perturbation on NE. The two named entities, "山西 Shanxi" and "陕西 Shaanxi", are similar at character level but denote two different locations. We expect that the models can capture the subtle difference.
+
+Synonym. A synonym is a word or phrase that means exactly or nearly the same as another word or phrase in a given language. This subcategory aims to test whether models can identify two semantically equivalent questions whose surface forms only differ in a pair of synonyms. As in example 16, the two sentences differ only in two words, both of which refer to Kiwifruit, and has the same meaning.
+
+Antonym. In contrast to synonyms, antonyms are words within an inherently incompatible binary relationship. This subcategory examines model's capability on distinguishing words with opposed meanings. We mainly focus on adjective's opposite, e.g., "high" and "low" (see example 20).
+
+Negation. Negation is another way to express contradiction. To negate a verb or an adjective in Chinese, we normally put a negative before it, e.g., "not" before "哭cry" (example 21), "不是not" before "红的red" (example 22). The negative before the verb or the adjective negates the statement. It is an effective way to analyze model's basic skill of figuring out the contradictory meanings even there is only a minor change. Moreover, we include some equivalent paraphrases with negation in this subcategory. In example 23, "无法平静can't calm down" is the negative paraphrase of "激动excited", so that the paraphrase sentence is equivalent to the positive sentence. We believe that a robust QM system should be able to recognize this kind of paraphrase question pairs.
+
+Temporal Word. Temporal reasoning is the relatively higher-level linguistic capability that allows the model to reason about time. Unlike English, verbs in Chinese do not have morphological inflections. Tenses and aspects are expressed either by temporal noun phrases like "明天tomorrow" (examples 24) or by aspect particles like "了le" which indicates the completion of an action (example 25). This subcategory focuses on the temporal distinct
+
+tions and helps us evaluate the models' temporal reasoning capability.
+
+# 2.2 Syntactic Features
+
+While single word sense is important to question meaning, how words composed together into a whole also affects sentence understanding. We believe that the relations among words in a sentence is important for models to capture, so we focus on several types of syntactic features in this category. We pre-define 4 linguistic phenomena that we believe is meaningful to locate model's strength and weakness, and introduce them in this subsection.
+
+Symmetry. Sometimes paraphrases can be generated by only swapping two conjuncts around in a structure of coordination. As shown in example 26, "鱼fish" and "鸡蛋egg" are joined together by the conjunction "和and", which have the symmetric relation to each other. Even if we swap them around, the sentence meaning will not change. We name this subcategory Symmetry.
+
+Asymmetry. Some words (such as "和and") denote symmetric relations, while others (for example, preposition "到to") denote asymmetric. Example 27 shows a sentence pair in which the word before the preposition "到to" is an adverbial and the word after it is the object. Swapping around the adverbial and the object of the prepositional phrase will definitely leads to a nonequivalent meaning. If a model performs well only on subcategory Symmetry or Asymmetry, it may rely on shortcuts instead of the understanding of the syntactic information.
+
+Negative Asymmetry. To further explore the syntactic capability of QM model, DuQM includes a set of test examples which consider both syntactic asymmetry and antonym, and we name this category Negative Asymmetry. In example 28, the asymmetric relation between "男人men" and "女人women" and the opposite meaning of "高taller" and "矮shorter" resolve to an equivalent meaning. With this subcategory, we can better explore model's capability of inferring more complex syntactic structure.
+
+Voice. Another crucial syntactic capability of models is to differentiate active and passive voices. In Chinese, the most common way to express the passive voice is using Bei-constructions which feature an agentive case marker "被bei". The subject of a Bei-construction is the patient of an action, and the object of the preposition "被bei" is the agent. Compared to Fig.2(a) (in Appendix A), the additional
+
+"被bei" and the change of word order of "猫cat" and "狗dog" in Fig.2(b) convert the sentence from active to passive voice, but the two sentences have the same meaning. If we further change the word order from Fig.2(b) to Fig.2(c), the sentence still uses passive voice but has different meaning. Moreover, passive voice is not always expressed with "被bei". Sometimes a sentence without any passive marker is still in passive voice. In example 29, although the first sentence is without "被bei", it expresses the same meaning as the second one. There are a set of active-passive examples in this category, which are effective to evaluate model's performance on active and passive voices.
+
+# 2.3 Pragmatic Features
+
+Lexical items ordered by syntactic rules are not all that make a sentence mean what it means. Context, or the communicative situation that influence language use, has a part to play. We include some pragmatic features in DuQM so as to observe whether models are able to understand the contextual meaning of sentences.
+
+Misspelling. Misspellings are quite often seen by search engines and question-answering systems, which are mostly unintentional. Models should have the capability to capture the true intention of the questions with spelling errors to ensure the robustness. In example 30, despite the misspelled word "文身 $tattoo$ " the two questions mean the same, In some real world situations, models should understand misspellings appropriately. For example, when users search a query but type in misspelling, a robust model will still give the correct result.
+
+Discourse Particle. Discourse particles are words and small expressions that contribute little to the information the sentence conveys, but play some pragmatic functions such as showing politeness, drawing attention, smoothing utterance, etc. As shown in example 32, the word "求助help" is used to draw attention and brings no additional information to the sentence. Whether using these little words does not change the sentence meaning. It is necessary to a model to identify the semantic equivalency when such words are used.
+
+# 3 Construction
+
+We design DuQM as a diverse and natural corpus. The construction process of DuQM is divided into 4 steps and illustrated in Fig. 1. Firstly, we preprocess the source questions to obtain their linguis
+
+
+Figure 1: Construction process of DuQM.
+
+tic knowledge, which will be used to perturb the source texts. Then we pair the source and perturbed question as an example. The examples' naturalness is reviewed manually. At last, the examples are annotated manually and DuQM is finally constructed. We will introduce the construction details in this section.
+
+# 3.1 Linguistic Preprocessing
+
+We collect a large number of source questions from the search query log of Baidu search, and filter out question sentences with a question identification model (the accuracy is higher than $95\%$ ). All the source questions are natural that users have entered into Baidu search and then we perform several linguistic preprocessings on them: named entity recognition, POS tagging, dependency parsing, and word importance analysis. The linguistic knowledge of the source questions we obtained in this step will be used for perturbation.
+
+# 3.2 Perturbation.
+
+We conduct different perturbation operations for different subcategories. In general, we perturb the sentences in three ways:
+
+- replace: replace a word with another word, e.g., for category Synonym, we replace one word with its synonym;
+- insert : insert an additional word, e.g., for category Temporal Word, we insert temporal word to the source question;
+- swap: swap two words. This operation is only used in Syntactic Feature.
+
+The perturbation for each linguistic category is listed in column Perturbation Operation of Tab. 1, and the perturbation details are as follows:
+
+Lexical Features. For each source question, we select the word with specific POS tag or entity type and high word importance score as target word, and perturb the source questions with some other words we collect from following 4 sources:
+
+- Elasticsearch3: to collect words which have high character overlap with target words4;
+- Faiss5: to collect words which are semantically similar to target words; Specifically, we use RocketQA6 to train a question dense retrieval model and employ it by faiss for similarity search;
+- Bigcilin7: to collect synonym of target words;
+- Baidu Hanyu8: to collect antonym and synonym of target words;
+- XLM-RoBERTa (Conneau et al., 2020): to insert additional words to source sentences9;
+- Vocabulary lists10: to insert some specific words, such as negation word and temporal word.
+
+Syntactic Features. For Symmetry and Asymmetry, we retrieve the source questions from the search log and select the questions whose edit distance to source question is equal to 4 as candidate questions. Then we compare the dependency structures of the source question and candidate questions. Only the question pairs which contain symmetric or asymmetric relations are retained. To generate examples for Negative Asymmetry, from Asymmetry we select the example pairs, one side of which can be negated, and negate one side of the pairs. The asymmetric syntactic structure of two sentences and one-sided negation resolves to a positive meaning. For Voice, we add "被bei" word to source questions to conduct a change of voice.
+
+# Pragmatic Features.
+
+Misspelling. With a Chinese heteronym list11, we obtain a set of common typos and substitute the
+
+correct-spelling words with typos. Additionally, the perturbation should satisfy two constraints: 1) the typos should be commonly used Chinese characters; 2) only one character in the source sentence is replaced with its typo.
+
+Discourse Particle. We construct this category in 2 ways: 1) we replace or add some question words, auxiliary words or punctuation marks to generate Simple Discourse Particle examples (Discourse Particle (Simple) in Tab. 1); 2) for Complex Discourse Particle examples (Discourse Particle (Complex) in Tab. 1), we select some question pairs from a Frequently-Asked-Questions (FAQ) log, especially pairs with big differences in sentence length. Then the pairs are annotated manually and we retained the positive examples.
+
+With above approaches, we perturb the source questions and obtain a large set of question pairs. Then the generated question pairs are manually reviewed in terms of naturalness and quality.
+
+# 3.3 Naturalness Review
+
+To ensure the generated sentences are natural, we examine their appearances in the search log and only retain the sentences which have been entered into Baidu search. Then the source question and generated question are paired together as an example.
+
+# 3.4 Manual Annotation
+
+To ensure the quality, linguistic experts from our internal data team evaluate the examples in terms of fluent, grammatically correct, and correctly categorized. The low-quality examples are discarded and the examples with inappropriate categories are re-classified. Notably, examples of different subcategories are not overlapped, as we re-classified data categories and guarantee each example has one category.
+
+Then the question pairs are annotated by the annotators12. Semantically equivalent question pairs are positive examples, and inequivalent pairs are negative. Each example is annotated by three annotators, and the examples will be tagged with the majority label given by the annotators. To further ensure the annotation quality, $10\%$ of the annotated examples are selected randomly and reviewed by another senior linguistic expert and if the review accuracy is lower than $95\%$ , the annotators need to re-associate all the examples until
+
+| Category | Length | # |
| q | q' | Y | N | All |
| Lexical | 8.58 | 8.89 | 1,315 | 6,784 | 8,099 |
| Syntactic | 9.86 | 9.89 | 678 | 532 | 1,210 |
| Pragmatic | 8.73 | 9.03 | 812 | 0 | 812 |
| Avg / Total | 8.74 | 8.90 | 2,805 | 7,316 | 1,0121 |
+
+the accuracy is higher than $95\%$ .13 Generally, only $0.002\%$ (20/10,167) generated examples are not fluent or not grammatically correct, and only $0.018\%$ (185/10,121) generated examples are re-annotated manually. The overall annotation process is illustrated in Fig. 3 (in Appendix).
+
+Eventually, we generate 10,121 examples for DuQM. The class distribution of all categories are given in Tab. 1. Additional data statistics are provided in Tab. 2. The construction methods are not Chinese-specific. Except for few categories (e.g. Bei-construction), most of construction methods can be easily extended to other languages.
+
+# 4 Experiments
+
+In this section, we conduct experiments to discuss three characteristics (char.) of DuQM. In Sec. 4.1, we provide the experimental setup and the evaluation metrics. In Sec. 4.2 ~4.4, we give the experimental results and discussions.
+
+# 4.1 Experimental Setup
+
+Datasets. To evaluate the robustness of QM models, we select LCQMC to train the models and evaluate the models' performance on DuQM. LCQMC is a large-scale Chinese QM corpus in general domain and the source questions are collected from Baidu Knows (a popular Chinese community question answering website) (Liu et al., 2018), which are similar to the search queries in form. Specifically, we firstly train QM models on $LCQMC_{train}$ . Then we choose the model with the best performance on $LCQMC_{dev}$ and report the results of the chosen models on $LCQMC_{test}$ and DuQM. Tab. 8 presents the statistics of LCQMC.
+
+It is worth mentioning that LCQMC is in general domain and its source questions are similar to the search query, which are the form of source questions for DuQM. In other words, DuQM is not a
+
+Table 2: Data statistics of DuQM.
+
+| Model | \( LCQMC_{test} \) | DuQM | \( \bigtriangleup \) |
| \( BERT_b \) | 87.1±0.1 | 66.6±0.6 | -20.5 |
| \( ERNIE_b \) | 87.3±0.1 | 69.8±0.3 | -17.5 |
| \( RoBERTa_b \) | 87.2±0.4 | 69.5±0.1 | -17.7 |
| \( MacBERT_b \) | 87.4±0.3 | 70.3±0.6 | -17.1 |
| \( RoBERTa_l \) | 87.7±0.1 | 73.8±0.3 | -13.9 |
| \( MacBERT_l \) | 87.6±0.1 | 73.8±0.5 | -13.8 |
+
+Table 3: Accuracy(%) on LCQMCtest and DuQM. b indicates base, and ${}_{1}$ indicates large.
+
+out-of-domain (ood) test set of LCQMC, so that models' low performance on DuQM could not be attributed to being ood.
+
+Models. We choose 6 popular pre-trained models to conduct experiments: $BERT_{b}$ (Devlin et al., 2019), $ERNIE_{b}$ (Sun et al., 2019), $RoBERTa_{b}$ , $RoBERTa_{1}$ (Liu et al., 2019), $MacBERT_{b}$ , $MacBERT_{1}$ (Cui et al., 2020). A detailed comparison is provided in Tab. 7 (in Appendix), and the training details are described in Appendix C.1.1.
+
+Evaluation Metrics. QM problem is normally formulated as a binary classification task. Like most classification tasks, we use accuracy to evaluate a single model's performance, which is the proportion of correct predictions among the total number of the examples. As DuQM is a corpus consisting of a set of linguistic categories and each category differs in size, we use the micro-averaged and the macro-averaged accuracy to compare the models' performances on DuQM, which can help us better indicate the models' ability on different categories.
+
+# 4.2 Char. 1: DuQM is Challenging and with Better Discrimination Ability
+
+Tab. 3 shows the performances of models on heldout set $\mathrm{LCQMC}_{\mathrm{test}}$ and our DuQM, which presents the primary characteristic of DuQM: it is challenging and can better discriminate models' abilities.
+
+As shown in Tab. 3, all models achieve accuracy higher than $87\%$ on $\mathrm{LCQMC}_{\mathrm{test}}$ , but show a significant performance drop on DuQM. Column $\triangle$ in Tab. 3 shows the differences between models' performances on $\mathrm{LCQMC}_{\mathrm{test}}$ and DuQM, which presents that the performance on DuQM is lower than on $\mathrm{LCQMC}_{\mathrm{test}}$ by at most $20.5\%$ . This indicates that DuQM is more challenging, and we claim that a challenging dataset could better distinguish the models' performance. As shown in Tab. 3, all the models have similar performances
+
+| Models | Lexical | Syntactic | Pragmatic | DuQM |
| POS | NE | Synonym | Antonym | Negation | Temporal | Lexical |
| BERTb | micro | 62.1±1.1 | 92.3±0.5 | 69.5±0.4 | 50.6±3.4 | 64.4±5.9 | 35.1±3.3 | 67.2±0.7 | 59.1±0.4 | 72.6±1.6 | 66.6±0.6 |
| macro | 51.9±1.5 | 91.2±0.7 | 76.4±0.6 | 50.6±3.4 | 57.6±4.4 | 35.5±3.3 | 61.4±1.2 | 59.1±0.7 | 71.1±1.1 | 62.0±0.9 |
| ERNIEb | micro | 64.6±0.5 | 92.8±0.4 | 73.2±0.9 | 69.6±2.9 | 77.8±1.1 | 48.0±1.9 | 71.0±0.3 | 60.0±1.2 | 72.4±0.3 | 69.8±0.3 |
| macro | 52.4±0.7 | 92.3±0.6 | 79.5±0.7 | 69.6±2.9 | 69.1±1.2 | 48.5±1.9 | 65.5±0.5 | 56.5±1.0 | 73.2±0.8 | 65.1±0.3 |
| RoBERTa | micro | 64.2±0.1 | 90.6±1.8 | 74.2±1.4 | 65.0±1.5 | 76.3±1.7 | 43.7±0.2 | 70.1±0.1 | 63.1±0.6 | 73.3±0.1 | 69.5±0.1 |
| macro | 53.3±0.2 | 89.4±2.5 | 80.3±1.1 | 65.0±1.5 | 68.8±1.3 | 44.0±0.2 | 65.0±0.1 | 60.9±0.6 | 75.6±0.5 | 65.5±0.1 |
| MacBERTb | micro | 64.8±1.1 | 92.0±0.7 | 73.3±1.1 | 73.1±4.3 | 80.7±0.5 | 47.6±1.3 | 71.2±0.7 | 62.1±1.0 | 73.4±1.5 | 70.3±0.6 |
| macro | 54.2±0.9 | 90.7±0.6 | 79.7±0.5 | 73.1±4.6 | 70.7±0.1 | 47.7±0.2 | 66.3±0.2 | 55.5±0.7 | 75.2±1.1 | 65.8±0.1 |
| RoBERTa1 | micro | 67.2±0.9 | 92.5±0.3 | 76.0±2.1 | 91.7±2.3 | 80.2±0.8 | 58.6±2.8 | 74.1±0.3 | 72.6±1.4 | 73.2±1.9 | 73.8±0.3 |
| macro | 57.7±0.6 | 91.6±0.3 | 81.7±1.6 | 91.7±2.3 | 72.3±0.6 | 59.0±2.7 | 70.2±0.3 | 63.4±1.2 | 76.0±2.0 | 69.8±0.2 |
| MacBERT1 | micro | 65.6±0.8 | 93.2±0.6 | 83.2±1.6 | 90.7±2.3 | 84.3±1.3 | 55.5±4.0 | 74.4±0.4 | 70.2±3.7 | 73.7±1.1 | 73.8±0.5 |
| macro | 54.7±0.9 | 92.6±0.9 | 87.1±1.2 | 90.7±2.3 | 78.1±0.9 | 56.1±4.0 | 70.7±0.5 | 61.6±2.4 | 77.1±0.6 | 70.2±0.5 |
+
+Table 4: The micro-averaged and macro-averaged accuracy are on each category of DuQM.
+
+ | PWWS | PWWSnat | FOOLER | FOOLERnat | CHECKLISTnat |
| Train | 159,503 | - | 64,086 | - | |
| Test | 400 | 200 | 400 | 200 | 400 |
+
+Table 5: Statistics of the adversarial examples.
+
+on $\mathrm{LCQMC}_{\mathrm{test}}$ (around $87\%$ ), but different performance on DuQM: the accuracy of base models differs from $66.6\%$ to $70.3\%$ , and the large models show higher performance ( $73.8\%$ ). In conclusion, DuQM shows a better discrimination ability to evaluate models.
+
+# 4.3 Char. 2: Diagnose Model in Diverse Ways
+
+DuQM is a corpus which has 3 linguistic categories and 13 subcategories and enables a detailed breakdown of evaluation on different linguistic phenomena. In Tab. 1, we give the performance of 6 models on all fine-grained categories of DuQM, and Tab. 4 reports the micro-averaged and macro-averaged accuracy. By comparing these results, we introduce the second characteristic of DuQM: it can diagnose the strengths and weaknesses of the models in diverse ways. Several interesting observations are noticed: (from Tab. 1 and 4):
+
+1) In most categories, large models outperform base models. As the large models have more parameters and larger pre-training corpus, it is reasonable that they have better capabilities than relatively smaller models.
+2) In Named Entity, all models show good performance (higher than $90\%$ ). Another interesting finding is that although $\mathrm{ERNIE_b}$ is a relatively small model, it performs slightly better than RoBERTa1 on this subcategory, which might attribute to the entity masking strategy during pre
+
+training.
+
+3) $\mathrm{MacBERT}_1$ is significantly better than other models on Synonym. We suppose that it benefits from its pre-training strategy that using similar words instead of random words for masking. Moreover, RoBERTa and MacBERT have remarkable better performance on Antonym.
+4) Low performance in Temporal word show that all models lack the ability of temporal reasoning.
+5) All models have surprisingly poor performance on Asymmetry while good performance on Symmetry. We suppose that lack of learning word orders would result in a wrong prediction when the words orders are altered.
+6) $\mathrm{BERT_b}$ and $\mathrm{ERNIE_b}$ perform better on Misspelling, and RoBERTa and MacBERTb are relatively better on Complex Discourse Particles.
+
+In general, DuQM diagnoses models from a linguistic perspective and can help us identify the strengths and weaknesses of the models.
+
+# 4.4 Char. 3: Natural Examples
+
+DuQM is composed of adversarial testing examples generated by linguistically perturbed natural questions $^{14}$ . We consider that natural examples can better evaluate models' robustness than artificial examples. To demonstrate it, we conduct an experiment to compare the performance of two adversarial training (AT) methods PWWS (Ren et al., 2019) and TextFooler (Jin et al., 2020) on artificial and natural test examples:
+
+| Training set | LCQMC | Attack test set | CHECKLISTnat | DuQM |
| PWWS | \( PWWS_{nat} \) | FOOLER | \( FOOLER_{nat} \) | Micro | Macro |
| LCQMC | 87.7 | 58.1 | 81.5 | 57.1 | 87.8 | 76.9 | 73.8 | 69.8 |
| LCQMC+PWWS | \( 87.7_{+0.0} \) | \( 97.6_{+39.5} \) | \( 81.8_{+0.3} \) | \( 73.1_{+16.0} \) | \( 87.6_{-0.2} \) | \( 76.0_{-0.9} \) | \( 75.2_{+1.4} \) | \( 70.4_{+0.6} \) |
| LCQMC+FOOLER | \( 87.5_{-0.2} \) | \( 78.5_{+20.4} \) | \( 83.8_{+2.3} \) | \( 80.8_{+23.7} \) | \( 82.0_{-5.8} \) | \( 79.2_{+2.3} \) | \( 71.4_{-2.4} \) | \( 68.8_{-1.0} \) |
+
+Table 6: Adversarial training results of RoBERTa. 'FOOLER' refers to 'TEXTFOOLER'. We use green and red subscripts to represent a higher and lower accuracy respectively.
+
+- Artificial test examples, which are generated artificially and may not preserve semantics and introduce grammatical errors. We employ two methods PWWS and Text,Follower on $\mathrm{LCQMC}_{\mathrm{test}}$ to generate artificial adversarial examples. These two methods generate adversarial examples by replacing words with synonyms until models are fooled.
+- Natural test examples are texts within linguistic and semantics constraints. Our annotators from the internal data team reviewed and annotated all the generated texts with methods PWWS, TextFooler and the translated texts of Checklist dataset (Ribeiro et al., 2020), and we finally get three natural test sets, $\mathrm{PWWS}_{\mathrm{nat}}$ , $\mathrm{TextFooler}_{\mathrm{nat}}$ and $\mathrm{Checklist}_{\mathrm{nat}}$ .
+
+Besides, we employ PWWS and TextFooler on $\mathrm{LCQMC}_{\mathrm{train}}$ to generate artificial adversarial training examples, which are combined with original $\mathrm{LCQMC}_{\mathrm{train}}$ as training data (Row $LCQMC + PWWS$ and $LCQMC + FOOLER$ in Tab. 6). The detailed data statistics are shown in Tab. 5. AT details are in Appendix C.2.
+
+Evaluation with artificial and natural adversarial examples. We fine-tune RoBERTa on LCQMC and the artificial adversarial examples generated by PWWS and TextFooler, and evaluate on the adversarial test sets. The results are shown in Tab. 6. Row LCQMC shows that only training with LCQMCtrain shows a low performance on PWWS and TextFooler (we provide a detailed analysis in Appendix C.3), and the performance on PWWS and TextFooler are significantly higher on $PWWS_{nat}$ and $TextFooler_{nat}$ respectively. However, if we incorporate LCQMCtrain with the examples generated by PWWS and TextFooler, the model's performance on PWWS and TextFooler increase greatly (both methods achieve an great improvement of more than $16\%$ ), but the effects on natural examples $PWWS_{nat}$ and $TextFooler_{nat}$ are not significant $(-5.8\% \sim 2.3\%)$ . On the other 2 natural test sets, Checklistnat and DuQM, the effects of 2 adversarial methods are also not obvious $(-2.4\% \sim 2.3\%)$ .
+
+In conclusion, the common artificial AT methods are not so effective on the natural datasets. As a corpus consisting linguistically perturbed natural questions, DuQM is beneficial to a robustness evaluation to help us mitigate models' undesirable performance in real-world applications.
+
+# 5 Conclusion
+
+In this work, we create a Chinese dataset namely DuQM which contains linguistically perturbed natural questions for evaluating the robustness of QM models. DuQM is designed to be fine-grained and natural. Specifically, DuQM has 3 categories and 13 subcategories with 32 linguistic perturbations. We conduct extensive experiments with DuQM and the results demonstrate that DuQM has 3 characteristics: 1) DuQM is challenging and has better discrimination ability; 2) The fine-grained design of DuQM helps to diagnose the strengths and weakness of models, and enables us to evaluate the models in diverse ways; 3) Artificial adversarial training fails in the natural texts of DuQM.
+
+# Acknowledgements
+
+This research is supported by the National Key Research and Development Project of China (No.2018AAA0101900).
+
+# Ethical Considerations
+
+This work presents DuQM, a diverse and natural dataset for the research community to evaluate the robustness of QM models. Data in DuQM are collected from Baidu search (we are legally authorized by this company), the details are presented in Sec. 3. Since DuQM do not have any user information, there is no privacy concerns. In addition, to ensure that the DuQM is free potential biased and toxic content, we desensitize all the instances in it. Regarding to the issue of labor compensation, all annotators are employees from our internal data team and are fairly compensated.
+
+# Limitations
+
+Our dataset DuQM provides a new resource for evaluating the robustness of QM models. However, the categories can be further expanded to consider more behavioral capabilities of QM models, such as symmetry $((a,b) = (b,a))$ and transitivity $((a,c)$ if $a = b$ and $b = c$ .
+
+# References
+
+Moustafa Alzantot, Yash Sharma, Ahmed Elgohary, Bo-Jhang Ho, Mani Srivastava, and Kai-Wei Chang. 2018. Generating natural language adversarial examples. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2890–2896, Brussels, Belgium. Association for Computational Linguistics.
+Ronan Le Bras, Swabha Swayamdipta, Chandra Bhagavatula, Rowan Zellers, Matthew E. Peters, Ashish Sabharwal, and Yejin Choi. 2020. Adversarial filters of dataset biases. In Proceedings of the 37th International Conference on Machine Learning, ICML 2020, 13-18 July 2020, Virtual Event, volume 119 of Proceedings of Machine Learning Research, pages 1078-1088. PMLR.
+Jing Chen, Qingcai Chen, Xin Liu, Haijun Yang, Daohe Lu, and Buzhou Tang. 2018. The BQ corpus: A large-scale domain-specific Chinese corpus for sentence semantic equivalence identification. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 4946-4951, Brussels, Belgium. Association for Computational Linguistics.
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettlemoyer, and Veselin Stoyanov. 2020. Unsupervised cross-lingual representation learning at scale. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8440-
+
+8451, Online. Association for Computational Linguistics.
+Yiming Cui, Wanxiang Che, Ting Liu, Bing Qin, Shijin Wang, and Guoping Hu. 2020. Revisiting pre-trained models for Chinese natural language processing. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 657-668, Online. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Allyson Ettinger. 2020. What BERT is not: Lessons from a new suite of psycholinguistic diagnostics for language models. Transactions of the Association for Computational Linguistics, 8:34-48.
+Matt Gardner, Yoav Artzi, Victoria Basmov, Jonathan Berant, Ben Bogin, Sihao Chen, Pradeep Dasigi, Dheeru Dua, Yanai Elazar, Ananth Gottumukkala, Nitish Gupta, Hannaneh Hajishirzi, Gabriel Ilharco, Daniel Khashabi, Kevin Lin, Jiangming Liu, Nelson F. Liu, Phoebe Mulcaire, Qiang Ning, Sameer Singh, Noah A. Smith, Sanjay Subramanian, Reut Tsarfaty, Eric Wallace, Ally Zhang, and Ben Zhou. 2020. Evaluating models' local decision boundaries via contrast sets. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 1307-1323, Online. Association for Computational Linguistics.
+Suchin Gururangan, Swabha Swayamdipta, Omer Levy, Roy Schwartz, Samuel Bowman, and Noah A. Smith. 2018. Annotation artifacts in natural language inference data. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 107-112, New Orleans, Louisiana. Association for Computational Linguistics.
+Shankar Iyer, Nikhil Dandekar, and Kornél Csernai. 2017. First quora dataset release: Question pairs. data.quora.com.
+Robin Jia and Percy Liang. 2017. Adversarial examples for evaluating reading comprehension systems. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 2021-2031, Copenhagen, Denmark. Association for Computational Linguistics.
+Di Jin, Zhijing Jin, Joey Tianyi Zhou, and Peter Szolovits. 2020. Is BERT really robust? A strong baseline for natural language attack on text classification and entailment. In *The Thirty-Fourth AAAI Conference on Artificial Intelligence*, AAAI 2020, The
+
+Thirty-Second Innovative Applications of Artificial Intelligence Conference, IAAI 2020, The Tenth AAAI Symposium on Educational Advances in Artificial Intelligence, EAAI 2020, New York, NY, USA, February 7-12, 2020, pages 8018-8025. AAAI Press.
+Yuxuan Lai, Chen Zhang, Yansong Feng, Quzhe Huang, and Dongyan Zhao. 2021. Why machine reading comprehension models learn shortcuts? In *Findings of the Association for Computational Linguistics: ACL-IJCNLP* 2021, pages 989-1002, Online. Association for Computational Linguistics.
+Tal Linzen. 2020. How can we accelerate progress towards human-like linguistic generalization? In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 5210-5217, Online. Association for Computational Linguistics.
+Xin Liu, Qingcai Chen, Chong Deng, Huajun Zeng, Jing Chen, Dongfang Li, and Buzhou Tang. 2018. LCQMC:a large-scale Chinese question matching corpus. In Proceedings of the 27th International Conference on Computational Linguistics, pages 1952-1962, Santa Fe, New Mexico, USA. Association for Computational Linguistics.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. ArXiv preprint, abs/1907.11692.
+Tom McCoy, Ellie Pavlick, and Tal Linzen. 2019. Right for the wrong reasons: Diagnosing syntactic heuristics in natural language inference. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3428-3448, Florence, Italy. Association for Computational Linguistics.
+Junghyun Min, R. Thomas McCoy, Dipanjan Das, Emily Pitler, and Tal Linzen. 2020. Syntactic data augmentation increases robustness to inference heuristics. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 2339-2352, Online. Association for Computational Linguistics.
+John Morris, Eli Lifland, Jack Lanchantin, Yangfeng Ji, and Yanjun Qi. 2020. Reevaluating adversarial examples in natural language. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 3829-3839, Online. Association for Computational Linguistics.
+Yixin Nie, Adina Williams, Emily Dinan, Mohit Bansal, Jason Weston, and Douwe Kiela. 2020. Adversarial NLI: A new benchmark for natural language understanding. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4885-4901, Online. Association for Computational Linguistics.
+
+Jason Phang, Angelica Chen, William Huang, and Samuel R Bowman134. Adversarily filtered evaluation sets are more challenging, but may not be fair.
+Shuhuai Ren, Yihe Deng, Kun He, and Wanxiang Che. 2019. Generating natural language adversarial examples through probability weighted word saliency. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 1085-1097, Florence, Italy. Association for Computational Linguistics.
+Marco Tulio Ribeiro, Tongshuang Wu, Carlos Guestrin, and Sameer Singh. 2020. Beyond accuracy: Behavioral testing of NLP models with CheckList. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4902-4912, Online. Association for Computational Linguistics.
+Anna Rogers, Olga Kovaleva, Matthew Downey, and Anna Rumshisky. 2020. Getting closer to ai complete question answering: A set of prerequisite real tasks. In Proceedings of the AAAI conference on artificial intelligence, volume 34, pages 8722-8731.
+Yu Sun, Shuohuan Wang, Yukun Li, Shikun Feng, Xuyi Chen, Han Zhang, Xin Tian, Danxiang Zhu, Hao Tian, and Hua Wu. 2019. Ernie: Enhanced representation through knowledge integration. ArXiv preprint, abs/1904.09223.
+Eric Wallace, Pedro Rodriguez, Shi Feng, Ikuya Yamada, and Jordan Boyd-Graber. 2019. Trick me if you can: Human-in-the-loop generation of adversarial examples for question answering. Transactions of the Association for Computational Linguistics, 7:387-401.
+Xiao Wang, Qin Liu, Tao Gui, Qi Zhang, Yicheng Zou, Xin Zhou, Jiacheng Ye, Yongxin Zhang, Rui Zheng, Zexiong Pang, Qinzhuo Wu, Zhengyan Li, Chong Zhang, Ruotian Ma, Zichu Fei, Ruijian Cai, Jun Zhao, Xingwu Hu, Zhiheng Yan, Yiding Tan, Yuan Hu, Qiyuan Bian, Zhihua Liu, Shan Qin, Bolin Zhu, Xiaoyu Xing, Jinlan Fu, Yue Zhang, Minlong Peng, Xiaoqing Zheng, Yaqian Zhou, Zhongyu Wei, Xipeng Qiu, and Xuanjing Huang. 2021. TextFlint: Unified multilingual robustness evaluation toolkit for natural language processing. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing: System Demonstrations, pages 347-355, Online. Association for Computational Linguistics.
+
+
+(a) Active voice question.
+
+
+(b) Passive voice paraphrase question.
+
+
+(c) Passive voice non-paraphrase question.
+Figure 2: The dependency relations of active voice and passive voice questions.
+
+# A Dependency Relations of Bei-Construction
+
+
+Fig. 2 illustrates the dependency relations of active voice and passive voice questions in Chinese.
+Figure 3: Overall annotation process.
+Fig. 3 illustrates the overall annotation process.
+
+# B Annotation Process
+
+# C Supplementary Experiments
+
+# C.1 Additional Experimental Setting
+
+# C.1.1 Training Details
+
+In the fine-tuning stage, we insert a [SEP] between the question pairs. The pooled output is passed to a classifier. We use different learning rates and epochs for different pre-trained models. Specifically, for large models, the learning rate is 5e-6 and the number of epochs is 3. For base models, the learning rate is 2e-5, and we set the number of epochs as 2. The batch size is set as 64 and the maximal length of question pair is 64. We use early stopping to select the best checkpoint. We choose the model with the best performance on $\mathrm{LCQMC}_{\mathrm{dev}}$ to report test results and each model is fine-tuned 3 times on $\mathrm{LCQMC}_{\mathrm{train}}$ .
+
+# C.1.2 Datasets Details
+
+Tab. 8 gives a detailed description of LCQMC Corpus.
+
+# C.2 Adversarial Training Details
+
+Tab. 5 gives a detailed statistics of adversarial examples generated with TextFooler, PAWS and Checklist. To generate training samples, we select a set of LCQMC training questions and apply the methods PWWS and TextFooler on them. The labels are same as original samples. To generate test samples and ensure a robust evaluation, we utilize 4 datasets, $\mathrm{PWWS_{nat}}$ , $\mathrm{TextFooler_{nat}}$ , $\mathrm{Checklist_{nat}}^{17}$ and DuQM, which are natural adversarial examples. We conduct an experiment about adversarial training by feeding the models both the original data and the adversarial examples, and observe whether the original models become more robust. We use pre-trained model RoBERTa (described in Tab. 7) for fine-tuning and the details are described in Sec. 4.1.
+
+# C.3 Results of Attacks
+
+We give the main results of attacks to $\mathrm{BERT_b}$ and $\mathrm{RoBERTa_l}$ in Tab. 9. The results show that the un-natural attacks (on artificial adversarial samples, i.e. PWWS and TextFooler in Tab. 9) have higher success rate than DuQM. However, if we select the natural examples from the artificial adversarial samples $(\mathrm{PWWS}_{\mathrm{nat}}$ and $\mathrm{TextFooler}_{\mathrm{nat}}$ in Tab. 9), the attack success rate of PWWS and TextFooler is significantly decreasing by at least $18.5\%$ on $\mathrm{BERT_b}$
+
+| Models | L | H | A | # of Parameters | Masking | LM Task | Corpus |
| BERTb | 12 | 768 | 12 | 110M | T | MLM | Wikipedia |
| ERNIEb | 12 | 768 | 12 | 110M | T/E/Ph | MLM | Wikipedia+Baike+Tieba, etc. |
| RoBERTa,b | 12 | 768 | 12 | 110M | MLM | - | EXT15 |
| MacBERTb | 12 | 768 | 12 | 110M | Mac | SOP | EXT |
| RoBERTa1 | 24 | 1024 | 16 | 340M | MLM | - | EXT16 |
| MacBERT1 | 24 | 1024 | 16 | 340M | Mac | SOP | EXT |
+
+Table 7: The hyper-parameters of public pre-trained language models we use(L: number of layers, H: the hidden size, A: the number of self-attention heads, T: Token, E: Entity, Ph: Phrase, WWM: Whole Word Masking, NM: N-gram Masking, MLM: Masked LM, Mac: MLM as correction).
+
+| Corpus | Train | Dev | Test | Fine-grained |
| LCQMC | 238,766 | 8,802 | 12,500 | No |
+
+Table 8: Data statistics of LCQMC.
+
+| Data | BERT | RoBERTa |
| PWWS | 41.5 | 41.9 |
| PWWSnat | 23.0-18.5 | 18.5-23.4 |
| TEXTFOOLER | 46.6 | 42.9 |
| TEXTFOOLERnat | 14.6-32.0 | 12.2-30.7 |
| DuQM | 33.4 | 26.2 |
+
+Table 9: Attack success rate(%) on different test data.
+
+and $30.7\%$ on RoBERTa1 respectively. DuQM, in which all the samples are natural and grammarly correct, gets the best performance when black-box attacking (compare to $\mathrm{PWWS}_{\mathrm{nat}}$ and TextFoolernat in Tab. 9). In summary, the artificial adversarial examples training is not effective on natural texts, such as DuQM. It is reasonable that we should pay more attention to the naturalness when generating the adversarial examples.
\ No newline at end of file
diff --git a/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/images.zip b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..d6f4cc746ba6b75e8ac78bd463eebc37b65d968f
--- /dev/null
+++ b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cebdc9c45941d74a87848a447c58f8f7ff99ddde3b7a3e5e5a1c2b752dbfaff3
+size 595296
diff --git a/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/layout.json b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..8ade55e89898f452adc8d193f18270fc10d5396a
--- /dev/null
+++ b/duqmachinesedatasetoflinguisticallyperturbednaturalquestionsforevaluatingtherobustnessofquestionmatchingmodels/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:200527072f93660b50475ecc442dc49dfaac9cad46f3368dc3cf92cf51908ba9
+size 405872
diff --git a/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_content_list.json b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..12652de913c0731d2f59f6e075c428f860100208
--- /dev/null
+++ b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:291b781ed1a1e74a2b48231d5dff5b10b590db015d3fa6c890da90c8ba2e982c
+size 95300
diff --git a/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_model.json b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..a719f812a4f5bb938e2bd21faef619dc179c633d
--- /dev/null
+++ b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:46e92c366de79d1b9e182da6c63090f56f3f83abc8a46794b5548a1e4f2df4e3
+size 115362
diff --git a/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_origin.pdf b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..5fb802e48928ea211c4e22c547521423b44f397e
--- /dev/null
+++ b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/f536575d-079c-4e50-b8f4-04e3b20f682f_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:80d22f2b89603d5a12d5d444c6c0bfd4c326eb4dc0163bfc98939df0ef766c53
+size 833842
diff --git a/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/full.md b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..e56a42f28c9b5fd00626285fc6516e7a15b19bbf
--- /dev/null
+++ b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/full.md
@@ -0,0 +1,357 @@
+# DuReader_retrieval: A Large-scale Chinese Benchmark for Passage Retrieval from Web Search Engine
+
+Yifu Qiu $^{1}$ , Hongyu Li $^{2}$ , Yingqi Qu $^{2}$ , Ying Chen $^{2}$ , Qiaoqiao She $^{2}$ , Jing Liu $^{2*}$ , Hua Wu $^{2}$ , Haifeng Wang $^{2}$
+
+$^{1}$ Institute for Language, Cognition and Computation, University of Edinburgh, UK
+
+$^{2}$ Baidu Inc., Beijing, China
+
+y.qiu-20@sms.ed.ac.uk
+
+{lihongyu04, quyingqi, chenying04, sheqiaoqiao, liujing46, wu_hua, wanghaifeng} @baidu.com
+
+# Abstract
+
+In this paper, we present DuReader_retrieval, a large-scale Chinese dataset for passage retrieval. DuReader_retrieval contains more than 90K queries and over 8M unique passages from a commercial search engine. To alleviate the shortcomings of other datasets and ensure the quality of our benchmark, we (1) reduce the false negatives in development and test sets by manually annotating results pooled from multiple retrievers, and (2) remove the training queries that are semantically similar to the development and testing queries. Additionally, we provide two out-of-domain testing sets for cross-domain evaluation, as well as a set of human translated queries for cross-lingual retrieval evaluation. The experiments demonstrate that DuReader_retrieval is challenging and a number of problems remain unsolved, such as the salient phrase mismatch and the syntactic mismatch between queries and paragraphs. These experiments also show that dense retrievers do not generalize well across domains, and cross-lingual retrieval is essentially challenging. DuReader_retrieval is publicly available at https://github.com/baidu/DuReader/tree/master/DuReader-Retrieval.
+
+# 1 Introduction
+
+Passage retrieval requires systems to select candidate passages from a large passage collection. In recent years, pre-trained language models (Devlin et al., 2019; Liu et al., 2019) have been applied to retrieval problems, known as dense retrieval (Karpukhin et al., 2020; Qu et al., 2021; Zhan et al., 2021). The success of dense retrieval relies on the availability of high quality, large-scale, human-annotated corpora. A number of popular datasets are already available for English passage retrieval, including MS-MARCO (Nguyen et al.,
+
+2016), TriviaQA (Joshi et al., 2017), and Natural Questions (Kwiatkowski et al., 2019). In contrast, existing datasets for non-English retrieval (e.g., Chinese), are either small or machine generated. For example, TianGong-PDR (Wu et al., 2019) has only 70 questions and 11K passages. Even though the multilingual dataset mMARCO(Bonifacio et al., 2021) is large in size, it is constructed by machine translation from the English MS-MARCO dataset. Sougou-QCL (Zheng et al., 2018) is constructed based on click logs of web data without human annotation. In this paper, we present DuReader_retrieval, a large-scale Chinese dataset for passage retrieval from web search engine, that is manually annotated. The dataset contains more than 90K queries and over 8M unique passages. All queries are selected from real requests made by users at Baidu Search, and document passages are from the search results. Similar to (Karpukhin et al., 2020), we create the DuReader_retrieval from DuReader (He et al., 2018), a Chinese machine reading comprehension dataset, and obtain the human labels for paragraphs by distant supervision (See Section 2.2). An example from DuReader_retrieval is shown in Table 1, and a comparison of different datasets is shown in Table 2.
+
+Additionally, recent works point out two major shortcomings of the development and testing sets in the existing datasets:
+
+- Arabzadeh et al. (2021) and Qu et al. (2021) observe that false negatives (i.e. relevant passages but labeled as negatives) are common in the passage retrieval datasets due to their large scale but limited human annotation. As a result, the top passages retrieved by models may be superior to labeled relevant positives, and this will affect the evaluation.
+
+- Lewis et al. (2021) find that $30\%$ of the test-set queries in the common machine reading comprehension datasets (Kwiatkowski et al., 2019; Joshi et al., 2017) have a near-duplicate para
+
+# Query:
+
+太阳花怎么养
+
+How to raise Grandiflora?
+
+# Positive Psg. 1
+
+百度经验:jingyan.baidu.com花卉名称:太阳花播种时间:春、夏、秋均可播种为一年生肉质草本植物。株高10~15cm,花瓣颜色鲜艳,有白、深黄、红、紫等色。园艺品种很多,有单瓣、半重瓣、重瓣之分。喜温暖、阳光充足而干燥的环境,极耐瘠薄,一般土壤均能适应,能自播繁衍。见阳光花开,早、晚、阴天闭合,故有太阳花、午时花之名。花期6~7月。太阳花种子非常细小。常采用育苗播种极轻微地覆积细粒蛭石或仅在播种后略压实,以保证足够的湿润。发芽温度21~24℃,约7~10天出苗,幼苗极其细弱,因此如保持较高的温度,小苗生长很快,便能形成较为粗壮、肉质的枝叶。这时小苗可以直接上盆,采用10厘米左右直径的盆,每盆种植2~5株,成活率高,生长迅速。
+
+Baidu experience: jingyan.baidu.com Flower name: Grandiflora Sowing time: Spring, summer, and autumn can be sown as an annual succulent herb. Plant height is 10-15cm. The petals are bright in color, white, dark yellow, red, purple and other colors. There are many horticultural varieties, including single, semi-double and double petals. It likes a warm, sunny and dry environment, is extremely tolerant to barrenness, and can adapt to general soils and reproduce by itself. It is named Grandiflora because it blooms when the sun is rising and closes in the morning, evening and cloudy days. It flowers from June to July. Grandiflora's seeds are very small. The seedling trays are often used for sowing, very lightly covered with fine vermiculite, or only slightly compacted after sowing to ensure sufficient moisture. The germination temperature is $21 - 24^{\circ}\mathrm{C}$ and the seedlings emerge in about 7-10 days. The seedlings are extremely thin. Therefore, if the temperature is kept high, the seedlings will grow quickly, and thicker, fleshy branches and leaves can be formed. At this time, the seedlings can be directly put into pots, using pots with a diameter of about $10\mathrm{cm}$ , planting 2 to 5 plants per pot, with high survival rate and rapid growth.
+
+# Positive Psg. 2
+
+抹平容器中培养土平面,将剪来的太阳花嫩枝头插入竹筷截成的洞中,深入培养土最多不超过2厘米。为使盆花尽快成形、丰满,一盆中可视花盆大小,只要能保持2厘米的间距,可扦插多株(到成苗拥挤时,可分栽他盆)。接着浇足水即可。新扦插苗可遮阴,也可不遮阴,只要保持一定湿度,一般10天至15天即可成活,进入正常的养护。太阳花极少病虫害。平时保持一定湿度,半月施一次千分之一的磷酸二氢钾就能达到花大色艳、花开不断的目的。如果一盆中扦插多个品种各色花卉开一盆,欣赏价值更高。每年霜降节气后(上海地区)将重瓣的太阳花移至室内照到阳光处。入冬后放在玻璃窗内侧,让盆土偏干一点,就能安全越冬。次年清明后,可将花盆置于窗外,如遇寒流来袭,还需入窗内养护。
+
+Flatten the soil surface in the container, insert the cut branches of Grandiflora into the hole made by the bamboo chopsticks, and deepen the soil for no more than $2\mathrm{cm}$ . To make the potted flowers take shape and fullness as soon as possible, multiple plants can be cut as long as the spacing of $2\mathrm{cm}$ can be maintained (when the seedlings are crowded, they can be planted in other pots). Then pour plenty of water. The new cuttings can be shaded or not. As long as they maintain a certain humidity, they can survive 10 to 15 days and enter normal maintenance. Grandiflora has very few pests and diseases. Maintain a certain humidity at ordinary times, and apply one-thousandth of potassium dihydrogen phosphate once a half month to achieve the purpose of large flowers and continuous blooming. If there are multiple varieties of cuttings in one pot, the flowers of all colours will bloom in one pot, and the appreciation value will be higher. Every year after the frost falls (Shanghai area), the double-flowered Grandiflora is moved indoors to shine in the sun. Put it on the inside of the glass window after the winter, and let the potting soil dry a little to survive the winter safely. After the Qingming Festival in the following year, the flowerpots can be placed outside the window.
+
+Table 1: A data instance randomly selected from the DuReader_retrieval development set.
+
+phrase in their corresponding training sets, thus leaking the testing information into model's training. The similar issue has been observed in MS-MARCO (Zhan et al., 2022).
+
+In the construction of DuReader_retrieval, we try to alleviate the above issues and improve the quality of the development and testing sets in the following two ways (see Section 2.3):
+
+- To reduce the false negatives in the development and testing set, we invite the internal data team to manually check and relabel the passages in the top retrieved results pooled from multiple retrievers.
+- To reduce the leakage of testing information into model's training, we use a query matching model from (Zhu et al., 2021) to identify and remove the training queries that are semantically similar to the development and testing queries.
+
+Moreover, inspired by Thakur et al. (2021), we provide two testing sets (see Section 2.4) from the medical domain (cMedQA (Zhang et al., 2018) * and cCOVID-News†) as the separate testing sets for out-of-domain evaluation. Additionally, we also provide a set that contains human translated queries for cross-lingual retrieval evaluation (see Section 2.5) (Asai et al., 2021a; Sun and Duh, 2020).
+
+In this paper, we conduct extensive experiments. In our in-domain experiments, we find that there are many challenges to be addressed, such as salient phrase mismatches and syntactic mismatches (see Section 3.5). It is also difficult for dense retrievers
+
+to generalize well across different domains as we observed in the out-of-domain experiments (see Section 3.6). Finally, the cross-lingual experiments indicate that cross-lingual retrieval is essentially challenging (see Section 3.7).
+
+We summarize the characteristics of our dataset and our contributions as follows:
+
+- We present a large-scale Chinese dataset for benchmarking the passage retrieval models. Our dataset comprises more than 90K queries and more than 8M unique passages from Baidu Search.
+- We leverage two strategies to improve the quality of our benchmark and alleviate the existing shortcomings in other existing datasets, including reducing the false negatives with human annotations on pooled retrieval results, and remove the training queries semantically similar to the development and testing queries.
+- We introduce two extra out-of-domain test sets to evaluate the domain generalization capability, and a cross-lingual set to assess the cross-lingual retrievers.
+- We conduct extensive experiments and the results demonstrate that the dataset is challenging and passage retrieval has plenty of room for improvement.
+
+# 2 DuReader_retrieval
+
+In this section, we introduce our DuReader_retrieval dataset (See dataset statistics in Table 3). We first formally define the passage retrieval task in Section
+
+| Dataset | Lang | #Que. | #Psg. | Source of Que. | Source of Psg. | Psg. Annotation |
| MS-MARCO (Nguyen et al., 2016) | EN | 516K | 8.8M | User logs | Web doc. | Human |
| TriviaQA (Joshi et al., 2017) | EN | 95K | 650K | Trivia web. | Wiki./Web doc. | Dist. Sup. |
| Natural Questions (Kwiatkowski et al., 2019) | EN | 61K | 21M | User logs | Wiki doc. | Dist. Sup. |
| mMARCO-Chinese (Bonifacio et al., 2021) | CN | 516K | 8.8M | User logs | Web doc. | Translation |
| cCOVID-News‡ | CN | 4.9K | 5K | User question | COVID-19 News doc. | Human |
| cMedQA-2.0 (Zhang et al., 2018) | CN | 108K | 203K | User question | Medical Forum | Question-Answer Pairs |
| TianGong-PDR (Wu et al., 2019) | CN | 70 | 11K | User logs | News doc. | Human |
| Sougou-QCL (Zheng et al., 2018) | CN | 537K | 9M | Click logs | Web data | Click signal |
| DuReader_retrieval (Our work) | CN | 97K | 8.9M | User logs | Web doc. | Dist. Sup. + Human |
+
+2.1. We then introduce how we initially construct our dataset from DuReader by distant supervision in Section 2.2. Our strategies for further improving the data quality are discussed in Section 2.3. Finally, we introduce two out-of-domain test sets in Section 2.4 and a cross-lingual set in in Section 2.5.
+
+# 2.1 Task Definition
+
+$\mathrm{DuReader}_{\mathrm{retrieval}}$ is created for the task of passage retrieval, that is, retrieving a list of relevant passages in response to a query. Formally, given a query $q$ and a large passage collection $\mathcal{P}$ , a retrieval system $\mathcal{F}$ is required to return the top- $K$ relevant passages $P_K^{(q)} = \left\{p_1^{(q)}, p_2^{(q)}, \dots, p_K^{(q)}\right\}$ , where $K$ is a manually defined number. Ideally, all the relevant passages to $q$ within $\mathcal{P}$ should be included and ranked as high as possible in the retrieved results $P_K^{(q)}$ .
+
+# 2.2 Dataset Construction
+
+# 2.2.1 An Introduction of DuReader Dataset
+
+$\mathrm{DuReader}_{\mathrm{retrieval}}$ is developed based on the Chinese machine reading comprehension dataset DuReader (He et al., 2018). All queries in DuReader are posed by the users of our chosen commercial search engine, and document-level contexts are gathered from search results. Each instance in DuReader is a tuple $< q, t, D, A>$ , where $q$ is a query, $t$ is a query type, $D$ is the top-5 retrieved documents constituted by their paragraphs returned by our chosen commercial search engine. $A$ is the answers written by human annotators.
+
+Table 2: Summary of data statistics for passage retrieval datasets. The annotation of passages in TriviaQA and Natural Questions are presented in (Karpukhin et al., 2020). Compared with other works, the instances in DuReader_retrieval come from user logs in web search. Its consists of a distant supervised (Dist. Sup.) training set and human-annotated (Human) development and test sets.
+
+| DuReader_retrieval | Train | Dev. | Test |
| #Chinese queries | 86,395 | 2,000 | 4,000 |
| #passages | 222,395 | 9,863 | 19,601 |
| #avg. passages per query | 2.57 | 4.93 | 4.90 |
| #avg. Chinese characters per query | 9.51 | 9.29 | 9.23 |
| #avg. Chinese characters per passage | 358.58 | 398.59 | 401.61 |
| cMedQA (Out-of-domain) | Train | Dev. | Test |
| #queries | \ | \ | 3,999 |
| #passages | \ | \ | 7,527 |
| #avg. passages per query | \ | \ | 1.88 |
| #avg. Chinese characters per query | \ | \ | 48.47 |
| #avg. Chinese characters per passage | \ | \ | 100.58 |
| cCOVID-News (Out-of-domain) | Train | Dev. | Test |
| #queries | \ | \ | 949 |
| #passages | \ | \ | 964 |
| #avg. passages per query | \ | \ | 1.02 |
| #avg. Chinese characters per query | \ | \ | 25.93 |
| #avg. Chinese characters per passage | \ | \ | 1430.93 |
| Translated queries for cross-lingual retrieval |
| #avg. English words per query | 6.41 | 6.55 | 6.46 |
| #English queries | 9,500 | 2,000 | 4,000 |
| Size of the total paragraph collection | | 8,096,668 | |
+
+Table 3: Summary of statistics for the training (Train), development (Dev.), testing (Test), out-of-domain (OOD) testing sets and cross-lingual set of DuReader_retrieval.
+
+# 2.2.2 Constructing DuReader_retrieval from DuReader
+
+In this section, we describe that how we construct DuReaderretrieval from DuReader. First, we describe our approach to labelling the positive passages. Then, we discuss our approaches to dealing with the two challenges in constructing DuReaderretrieval from DuReader: 1) the original paragraphs are too short to provide meaningful context; and 2) the term overlap between the queries and the document titles may ease the challenges for passage retrieval.
+
+Distant Supervision for Annotations Following MS-MARCO Passage Ranking (Nguyen et al.,
+
+2016), we use the human-written answers from DuReader (He et al., 2018) to label the positive passages by the distant supervision. A paragraph is considered positive if it contains any human-written answer. Specifically, we leverage the span-level F1 score to measure the match between each human-written answer and the paragraphs in documents. If a span-answer pair gets a F1-score higher than the threshold (0.5), we label the paragraph as positive. We show the details of our annotation process in Algorithm 1.
+
+Input: $\{\langle p,a\rangle \}$ $p$ : candidate paragraph, $a$ : answer, $\tau$ : threshold for positive labelling.
+Output: $l_{p} \in \{0,1\}$ : label, 0 and 1 denote negative and positive $p$ , separately.
+
+Algorithm 1 Span-level F1 Annotation for Posi-tives
+```txt
+for any span $s$ in $p$ do if Calculate $F1(s,a)\geq \tau$ then: $l_{p}\gets 1$ return end if
+end for
+ $l_{p}\gets 0$
+return
+```
+
+Passage Length Control Additionally, most paragraphs in DuReader are too short to form meaningful contexts. We concatenate the paragraphs of each document in DuReader by the following rules: 1) In a document of less than 256 Chinese characters, all paragraphs are concatenated into one passage; 2) In a document of more than 256 Chinese characters, a paragraph of less than 256 is concatenated with the next one, and the concatenation does not stop until the length of the new passage exceeds 256. The new passage is labelled as positive if any of its components are originally labelled positive in DuReader. After the processing, the median and the mean of the passage length are 304 and 272, respectively.
+
+Removing Document Titles We remove the titles from all documents in DuReader, since we observe that there is many term overlaps between the queries and the titles. If we keep them, the retrieval systems may easily match the queries with the document titles and achieve high performance. But we expect the retrievers to capture all contextual information in passages to answer queries.
+
+# 2.3 Quality Improvement
+
+As we discussed in the previous section, there are shortcomings of other existing datasets. To alleviate such shortcomings, we further design two strategies to ensure the quality of the development and test sets in DuReader_retrieval. Although in this work we apply our quality improvement approaches to the Chinese passage retrieval dataset, the proposed method allows flexibility extended to other languages (e.g., English), benefiting the future evaluation and development of dense retrieval systems.
+
+Reducing False Negatives A common issue in existing passage retrieval datasets (Qu et al., 2021; Arabzadeh et al., 2021) is false negatives, i.e., query-relevant passages not labelled as positives, in the development and testing sets. In this section, we discuss our strategy for reducing the false negatives in the development and testing sets of DuReader_retrieval.
+
+We use human annotation as a complement to the distant supervised labeling approach discussed in Section 2.2. We invite the internal data team to manually check the labels in the development and test sets and fix them if necessary. To avoid inductive bias in our annotation process, we follow the pooling method in TREC competitions (Voorhees et al., 2005) to select candidate passages for annotation. The top-ranked passages retrieved for each query by a set of contributing retrievers are pooled for annotation. In particular, the annotator is presented with a query and the top-5 passages pooled from five retrieval systems. We use BM25 and four neural retrievers with the initialization from ERNIE (Sun et al., 2019), BERT (Devlin et al., 2019; Cui et al., 2021), RoBERTa (Liu et al., 2019) and MacBERT (Cui et al., 2020) to serve as our contributing retrievers. We combine their top-50 retrieved passages as candidates. An ensemble re-ranker is then used (See Appendix A.1 for implementation details) to select the top-5 passages for human annotation. To ensure data quality, we perform all annotations on our internal annotation platform. Please refer to the Appendix A.3 for annotation settings and quality control.
+
+After adopting our strategy for reducing false negatives, the average positive paragraph per query has increased from 2.43 to 4.91. $71.53\%$ of queries have at least one false negative relabeled by annotators, which shows there are many false negatives in the raw corpus derived directly from DuReader.
+
+Removing Similar Queries Retrieval systems should avoid merely memorizing queries and their relevant items in the training set and directly applying such memorization during inference. Lewis et al. (2021) find that in some popular datasets, including Natural Questions (Kwiatkowski et al., 2019), WebQuestions (Berant et al., 2013) and TriviaQA (Joshi et al., 2017), $30\%$ of the test-set queries have a near-duplicate paraphrase in their corresponding training sets, which leaks the testing information into the model training. In this paper, we use a model-based approach to remove training queries that are semantically similar to development and testing queries.
+
+We use the query matching model in (Zhu et al., 2021), which computes the similarity score ranging between [0, 1] for a query pair. We set a threshold of 0.5, meaning that if the similarity between a training query and a test query is higher than 0.5, we mark the query pair as semantically similar. There are 566 training queries semantically similar to 387 queries in the development and the test set, accounting for approximately $6.45\%$ of total development and test queries. All these 566 training instances are removed in DuReader_retrieval.
+
+# 2.4 Out-of-domain Evaluation
+
+Recent work (Thakur et al., 2021) reveals that the dense retrievers do not generalize well cross-domain. To assessing the cross-domain generalization ability of the retrievers, we carefully select two publicly available Chinese text retrieval datasets, i.e., cMedQA (Zhang et al., 2018) created from online medical consultation text and cCOVID-News from COVID-19 news articles. We randomly select 949 and 3,999 samples from cCOVID-News and cMedQA, respectively, as out-of-domain testing data.
+
+# 2.5 Cross-lingual Evaluation
+
+Cross-lingual passage retrieval has recently received much attention (Shi et al., 2021; Asai et al., 2021b), which aims to retrieve the passages in the target language (e.g., Chinese) as the response to the query in source language (e.g., English).
+
+In DuReader_retrieval, we provide a cross-lingual retrieval set which contains the English queries paired with Chinese positive passages. The total numbers of training/development/testing English queries are $9.5\mathrm{K} / 4\mathrm{K} / 2\mathrm{K}$ , respectively. All English queries in our cross-lingual set are translated and the passage annotations are aligned with
+
+
+Figure 1: Illustration for the training procedure of our one dual-encoder retriever and two cross-encoder re-rankers. We train our first retriever and re-ranker by the negatives sampled from BM25's output as in (Karpukhin et al., 2020). We further attempt the strategy in (Xiong et al., 2021) that sampling negatives from dual-encoder retriever to enhance the cross-encoder re-ranker.
+
+DuReaderretrieval. To obtain English queries, we first translate Chinese queries to English queries by using machine translation $\S$ . Then, we ask the internal data team to manually check the quality of the machine-translated queries, and modify the translated queries if necessary. The quality controls for translated queries are the same as our previous human annotations for the in-domain development and testing set as in Appendix A.3.
+
+# 3 Experiments and Results
+
+# 3.1 Baselines
+
+We use the recent two-stage framework (retrievethen-rerank) (Dang et al., 2013; Qu et al., 2021) for passage retrieval and evaluate two retrieval and two reranking models on our DuReaderretrieval dataset. In particular, we utilize the dual-encoder and cross-encoder architecture in RocketQA (Qu et al., 2021) to develop our neural Retrievers and re-rankers. We introduce the baselines as follows.
+
+BM25 BM25 is a sparse retrieval baseline (Robertson and Zaragoza, 2009).
+
+DE w/ BM25 Neg Karpukhin et al. (2020) shows that the hard negatives from BM25 are more effective at training the dense retrievers than in-batch random negatives. With BM25's hard negatives, we train a dual-encoder as our first neural retriever. CE w/ BM25 Neg We use BM25's hard negatives to train a cross-encoder as our first neural re-ranker.
+
+CE w/ DE Neg CE w/ DE Neg is the second enhanced re-ranker. We follow Qu et al. (2021) to train CE w/ DE Neg. Specifically, we use CE w/ BM25 Neg to initialize the parameters, and use DE w/ BM25 Neg to retrieve negatives from the entire passage collection.
+
+ | MRR@10 | Recall@1 | Recall@50 |
| BM25 | 21.03 | 12.08 | 70.00 |
| DE w/ BM25 Neg | 53.96 | 41.53 | 91.33 |
+
+Table 4: Performance of retrieval models on the testing set of DuReader_retrieval.
+
+| BM25's top-50 psg. | MRR@10 | Recall@1 | Recall@50 |
| CE w/ BM25 Neg | 56.80 | 48.83 | 70.00 |
| CE w/ DE Neg | 57.62 | 51.52 | 70.00 |
| DE's top-50 psg. | MRR@10 | Recall@1 | Recall@50 |
| CE w/ DE Neg | 74.21 | 66.03 | 91.33 |
+
+The relationships among our neural retrievers and re-rankers are shown in Figure 1. The training and architectural settings for all models are detailed in the Appendix A.2.
+
+# 3.2 Evaluation Metrics
+
+We use the following evaluation metrics in our experiments: (1) Mean Reciprocal Rank for the top 10 retrieved documents (MRR@10), (2) Recall for the top-1 retrieved items (Recall@1) and (3) Recall for the top-50 retrieved items (Recall@50). Recall@50 is more suitable for evaluating the first-stage retrievers, while MRR@10 and Recall@1 are more suitable for assessing the second-stage re-rankers.
+
+# 3.3 Baseline Performance
+
+We report the in-domain baseline performances for the first-stage retrievers in Table 4. Compared with the traditional retrieval system BM25, it is expected that DE w/ BM25 Neg outperforms the traditional system among all metrics, thanks to the powerful expressive ability of the neural encoder.
+
+We then report the in-domain baseline performances for the second-stage re-rankers in Table 5. We observe that training the re-ranker with the hard negatives sampled from the neural retriever's top predictions is shown to outperform the negatives sampled from BM25's retrieved results in terms of MRR@10 and Recall@1.
+
+# 3.4 Effects of Quality Improvements
+
+In this section, we examine the effects of our strategies to improve the data quality of
+
+Table 5: Performance of re-ranking models on testing set of DuReader_retrieval. We present re-ranking results based on two retrieval models including BM25 and DE w/ BM25 Neg.
+
+| Model | MRR@10 | Recall@1 |
| Duplicated | Duplicated |
| CE w/ Sim. Q | 50.6 | 43.93 |
| CE w/o Sim. Q | 49.94 | 42.89 |
+
+Table 6: Comparison of models by using two groups of training data: 1) CE w/ Sim. Q: training data without removing the queries that are semantically similar to the development and testing queries, 2) CE w/o Sim. Q: training data with removing the queries that are semantically similar to the development and testing queries. We evaluate the two models on the duplicated queries (Duplicated). All top-50 retrieval results are based on BM25. We bold the best model on each column.
+
+DuReader_retrieval as in Section 2.3.
+
+Reducing False Negatives We test three models, including BM25, a dense retrieval model (DE w/ BM25 Neg) and a re-ranking model (CE w/ BM25 Neg) based on BM25's top-50 retrieved results, to quantify the impact of our strategy on reducing false negatives. Specifically, we compare the performance of the same model on the development set either with or without reducing false negatives. As shown in Figure 2, all metrics of the three models are significantly improved after adopting our strategy. These results suggest that there are many false negatives in the raw retrieval dataset derived from DuReader, and that our strategy successfully captures and reduces false negatives in development and testing sets.
+
+Removing Similar Queries We conduct an experiment to quantify the effects of removing the training queries that are semantically similar to the development and testing queries. We train our re-ranking model (CE w/ BM25 Neg) by using the training data without (CE w/o Sim. Q) and with (CE w/ sim. Q) semantically duplicated queries, respectively. We then test both models on all 387 semantically duplicated queries (Duplicated) in the development and testing sets, as well as the rest of the development set (Others). We use BM25's top-50 retrieved results for the re-ranking models to re-rank. As shown in Table 6, comparing the two models' performance on Duplicated, we find model trained with those semantically similar queries (CE w/ Sim. Q) has a higher score on both MRR@10 and Recall@1. This suggests that using semantically similar queries in training may allow the model to simply memorize the data during training and achieve better performance during testing.
+
+
+Figure 2: Comparison in the model performances before (light blue) and after (dark blue) reducing the false negatives in the development set via our pooling strategy and human annotation.
+
+
+
+
+
+# 3.5 The Challenges and Limitations
+
+In this section, we analyze the results of our best baseline system (i.e., retrieving the top-50 passages by DE w/ BM25 Neg, then re-ranking by CE w/ DE Neg) to better understand the specific challenges and limitations of DuReader_retrieval. Specifically, we manually analyze 500 query-passage predictions of the baseline. The 500 query-passage pairs are from 100 random-selected development queries with the top-5 passages retrieved and re-ranked by the baseline. To help understand the challenges and limitations of DuReader_retrieval, we ensure that the top-5 passages of these 100 queries contain no positive passages.
+
+Salient Phrase Mismatch We observe that the mismatch in salient phrases between the query and the retrieved passages is particularly challenging for the baseline system as found in (Chen et al., 2021), accounting for $53.4\%$ of total incorrect predictions. We further divide salient phrase into several sub-categories, i.e., entity, numeral, and modifier. Examples and explanations are in Table 10 in Appendix A.4.
+
+Syntactic Mismatch We also observe that around $1\%$ predictions have a syntactic mismatch between the query and the passage. The case in Table 10 in Appendix A.4 suggests that it is difficult for the baseline system to ensure the consistency in syntactic relationship between the query and the passages.
+
+Other Challenges We also show two other typical challenges accounting for $22.6\%$ incorrect predictions: 1) Over-sensitivity on term overlap: whether the baseline system is over-sensitive to retrieve the negative passages that contains a few lexical overlap with queries. 2) robustness on typo: whether the baseline system is robust against typos in queries or passages. Note that our dataset is constructed from the real query log of a commercial search engine. The noise in data (e.g. typos)
+
+| cMedQA | MRR@10 | Recall@1 | Recall@50 |
| ZS. | FT. | ZS. | FT. | ZS. | FT. |
| BM25 | 6.26 | \ | 4.98 | \ | 14.05 | \ |
| DE | 4.39 | 15.22 | 2.93 | 11.28 | 16.4 | 40.36 |
+
+Table 7: Comparison for BM25 and the dense retrieval model DE w/ BM25 Neg (DE) in the Zero-shot (ZS.) experiments, and fine-tuning (FT.) experiments for estimating the upper-bound performance on cMedQA out-of-domain testing set.
+
+| COVID-News | MRR@10 | Recall@1 | Recall@50 |
| ZS. | FT. | ZS. | FT. | ZS. | FT. |
| BM25 | 57.49 | \ | 48.37 | \ | 85.67 | \ |
| DE | 14.02 | 56.67 | 9.91 | 46.68 | 38.04 | 87.78 |
+
+Table 8: Comparison for BM25 and the dense retrieval model DE w/ BM25 Neg (DE) in the Zero-shot (ZS.) experiments, and fine-tuning (FT.) experiments for estimating the upper-bound performance on cCOVID-News out-of-domain testing set.
+
+challenges the robustness of the baseline system.
+
+Limitations in False Negatives We notice that there are still about $14.8\%$ false negatives. This suggests that despite the success of our strategy in Section 2.3 to reduce false negatives in development and testing sets to some extents, the presence of false negatives remains a challenge in building a high-quality passage retrieval benchmark.
+
+# 3.6 Out-of-Domain Evaluation
+
+We evaluate the out-of-domain (OOD) generalization ability of our dense retriever (DE w/ BM25 Neg) on the two OOD testing sets. We report the results in two settings: 1) Zero-shot setting: we directly evaluate DE w/ BM25 Neg without finetuning. 2) Fine-tuning setting: we fine-tune DE w/ BM25 Neg with the data from the target domain and evaluate it on OOD testing sets. The performance of the fine-tuned models is the estimated upper-bound that DE w/ BM25 Neg can achieve on
+
+| Model \ Evaluation | Monolingual | Cross-lingual |
| Supervised Model | - | 28.03 |
| Zero-shot Model | 87.88 | 19.50 |
| Transferred Model | - | 38.35 |
+
+Table 9: Monolingual (retrieving Chinese passages with Chinese queries) and Cross-lingual (retrieving Chinese passages with English queries) performance of the dual-encoder retrievers on our cross-lingual evaluations. We report the Recall@50 score for each retrieval model.
+
+OOD testing sets.
+
+In Table 7 and 8, we summarize the results of the out-of-domain experiments. First, we notice that the performance of the dense retriever is largely degraded on the two OOD testing sets. According to the in-domain evaluation (see Table 4 and 5), the dense retriever considerably outperforms BM25, however it has no obvious advantage over BM25 in the zero-shot setting, or even worse. In addition, the dense retriever can be significantly improved by fine-tuning. Its can maintain a large advantage over BM25 after fine-tuning on the target-domain. This results show that the dense retriever has limited domain transfer capability as observed in (Thakur et al., 2021).
+
+# 3.7 Cross-lingual Evaluation
+
+In the cross-lingual evaluation, we experiment with three dense retrieval models based on multilingual BERT (mBERT) (Devlin et al., 2019).
+
+Supervised Model We directly fine-tune mBERT using the parallel data of English queries and Chinese passages.
+- Zero-shot Model We fine-tune an mBERT retriever on the full monolingual Chinese training data (i.e., 86K Chinese queries with Chinese positive paragraphs in DuReader_retrieval), and directly evaluate it on the cross-lingual testing set.
+- Transferred Model We further fine-tune Zero-shot Model by using the parallel data paired with English queries and Chinese passages, and then evaluate it on the cross-lingual testing set.
+
+As shown in Table 9, we note that the performance of Zero-shot Model on cross-lingual testing set is less effective than Supervised Model. Furthermore, Zero-shot Model performs significantly
+
+worse on cross-lingual data than on monolingual data. According to these findings, cross-lingual retrieval is more difficult than monolingual retrieval, since the retriever cannot find relevant passages by simply matching shared terms between queries and passages (Litschko et al., 2021). Instead, cross-lingual retrievers must capture the semantic relevance of the query and passages. Additionally, Transferred Model outperformed other baselines, demonstrating the validity of transferring knowledge from the monolingual Chinese annotated data.
+
+# 4 Related Works
+
+Passage Retrieval Benchmarks. Passage retrieval and open-domain question-answering are challenging tasks that attracts much attention in developing the benchmarks. MS-MARCO (Nguyen et al., 2016) contains queries extracted from the search log of Microsoft Bing, which poses challenges in both the retrieval of relevant contexts and reading comprehension based on the contexts. Natural Questions (Kwiatkowski et al., 2019) is an open-domain question answering benchmark that consist of real queries issued to the Google search engine. These datasets are widely used for the research of passage retrieval. However, Lewis et al. (2021) find that there are $30\%$ of test-set queries have semantically overlaps in the training queries for Natural Questions. Arabzadeh et al. (2021) observe that false negatives are common in MS-MARCO. TianGong-PDR (Wu et al., 2019) and Sougou-QCL (Zheng et al., 2018) are two Chinese retrieval datasets for the news documents and web-pages, separately. However, these datasets are either small or have no human annotation. Despite the progress in developing benchmarks for English passage retrieval, the large-scale and high-quality benchmarks for the non-English community are still limited.
+
+Dense Retrieval Model. Information retrieval is a long-standing problem. In contrast to the traditional sparse retrieval methods (Salton and Buckley, 1988; Robertson and Zaragoza, 2009), recent dense retrievers aim at encoding the query and retrieved documents as contextualized representations based on the pre-training language models (Devlin et al., 2019; Sun et al., 2019), then calculate the relevance based on similarity function (Karpukhin et al., 2020; Luan et al., 2021; Qu et al., 2021) (e.g. cosine or dot product). Based on different learning paradigms, neural retrieval systems
+
+can be divided into two categories: 1) unsupervised: pre-training the retrieval without annotated data (Chang et al., 2020; Gao and Callan, 2021); 2) supervised: training the query and document encoders by contrasting the positives with designed negatives (Karpukhin et al., 2020; Xiong et al., 2021; Zhan et al., 2021). In terms of system architecture, the recent systems typically follow the two-stage framework (retrieval-then-re-ranking), in which a retriever (Mao et al., 2021; Nogueira et al., 2019; Dai and Callan, 2019) first retrieve a list of top candidates and the re-ranker (Gao et al., 2020; Khattab and Zaharia, 2020) will re-rank retrieved candidates. It has been shown that large-scale annotated datasets are one of the keys to successfully train dense retrievers (Karpukhin et al., 2020).
+
+# 5 Conclusion
+
+This paper presents a large-scale Chinese passage retrieval dataset to benchmark the retrieval systems. In order to ensure the quality of our dataset, we employ two strategies: 1) reducing the false negatives in development and testing sets using a pooling approach and human annotations, and 2) removing the training queries that are semantically similar to the development and testing queries. In addition, we provide two testing sets for out-of-domain evaluation, and a set for cross-lingual evaluation. We examine several retrieval baselines, including the traditional sparse retrieval system and the neural retrievers, and present the challenges and the limitations of our dataset. We hope this dataset can help facilitate the research of passage retrieval.
+
+# 6 Limitations
+
+As we discussed in Section 3.5, we still observe that approximately $14.8\%$ of our best re-ranking model's wrong predictions are indeed caused by false negatives, even though we observed that our quality improvement strategy discussed in Section 2.3 was effective. This is primarily due to the difficulty of annotating the training data in a way that captures all positives.
+
+Secondly, two out-of-domain testing sets are restricted to the medical domain. cMedQA focuses on the medical question-answering conversations, and cCOVID-NEWS focuses on the medical news domain. It may limit the ability to evaluate retrieval systems in other domains (e.g., the financial or legal domains).
+
+# 7 Ethical Consideration
+
+Our DuReaderretrieval is developed only for research purpose. All data is collected from either the open-source projects, respecting corresponding licences' restrictions, or publicly available benchmarks. We do not guarantee that we have the copyright of this data, any may further discard data resources without copyright if necessary.
+
+# 8 Acknowledgements
+
+We thank the anonymous reviewers for their helpful comments. We also appreciate the feedback received from other members of the Deep Question Answering Team at Baidu NLP, specifically Qifei WU, for his valuable discussions and comments. This work is supported by the National Key Research and Development Project of China (No.2018AAA0101900).
+
+# References
+
+Negar Arabzadeh, Alexandra Vtyurina, Xinyi Yan, and Charles LA Clarke. 2021. Shallow pooling for sparse labels. ArXiv preprint, abs/2109.00062.
+Akari Asai, Jungo Kasai, Jonathan Clark, Kenton Lee, Eunsol Choi, and Hannaneh Hajishirzi. 2021a. XOR QA: Cross-lingual open-retrieval question answering. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 547-564, Online. Association for Computational Linguistics.
+Akari Asai, Xinyan Yu, Jungo Kasai, and Hanna Hajishirzi. 2021b. One question answering model for many languages with cross-lingual dense passage retrieval. In Advances in Neural Information Processing Systems, volume 34, pages 7547-7560. Curran Associates, Inc.
+Jonathan Berant, Andrew Chou, Roy Frostig, and Percy Liang. 2013. Semantic parsing on Freebase from question-answer pairs. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, pages 1533-1544, Seattle, Washington, USA. Association for Computational Linguistics.
+Luiz Henrique Bonifacio, Vitor Jeronymo, Hugo Queiroz Abonizio, Israel Campiotti, Marzieh Fadaee, Roberto Lotufo, and Rodrigo Nogueira. 2021. mmarco: A multilingual version of ms marco passage ranking dataset.
+Wei-Cheng Chang, Felix X. Yu, Yin-Wen Chang, Yiming Yang, and Sanjiv Kumar. 2020. Pre-training tasks for embedding-based large-scale retrieval. In 8th
+
+International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Xilun Chen, Kushal Lakhotia, Barlas Oguz, Anchit Gupta, Patrick S. H. Lewis, Stan Peshterliev, Yashar Mehdad, Sonal Gupta, and Wen-tau Yih. 2021. Salient phrase aware dense retrieval: Can a dense retriever imitate a sparse one? ArXiv preprint, abs/2110.06918.
+Yiming Cui, Wanxiang Che, Ting Liu, Bing Qin, Shijin Wang, and Guoping Hu. 2020. Revisiting pre-trained models for Chinese natural language processing. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 657-668, Online. Association for Computational Linguistics.
+Yiming Cui, Wanxiang Che, Ting Liu, Bing Qin, and Ziqing Yang. 2021. Pre-training with whole word masking for chinese bert.
+Zhuyun Dai and Jamie Callan. 2019. Deeper text understanding for IR with contextual neural language modeling. In Proceedings of the 42nd International ACM SIGIR Conference on Research and Development in Information Retrieval, SIGIR 2019, Paris, France, July 21-25, 2019, pages 985-988. ACM.
+Van Dang, Michael Bendersky, and W. Bruce Croft. 2013. Two-stage learning to rank for information retrieval. In Proceedings of the 35th European Conference on Advances in Information Retrieval, ECIR'13, pages 423-434, Berlin, Heidelberg. Springer-Verlag.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Luyu Gao and Jamie Callan. 2021. Unsupervised corpus aware language model pre-training for dense passage retrieval. ArXiv preprint, abs/2108.05540.
+Luyu Gao, Zhuyun Dai, and Jamie Callan. 2020. Modularized transformer-based ranking framework. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4180-4190, Online. Association for Computational Linguistics.
+Wei He, Kai Liu, Jing Liu, Yajuan Lyu, Shiqi Zhao, Xinyan Xiao, Yuan Liu, Yizhong Wang, Hua Wu, Qiaoqiao She, Xuan Liu, Tian Wu, and Haifeng Wang. 2018. DuReader: a Chinese machine reading comprehension dataset from real-world applications. In Proceedings of the Workshop on Machine Reading for Question Answering, pages 37-46, Melbourne, Australia. Association for Computational Linguistics.
+
+Jeff Johnson, Matthijs Douze, and Hervé Jégou. 2019. Billion-scale similarity search with gpus. IEEE Transactions on Big Data, 7(3):535-547.
+Mandar Joshi, Eunsol Choi, Daniel Weld, and Luke Zettlemoyer. 2017. TriviaQA: A large scale distantly supervised challenge dataset for reading comprehension. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1601-1611, Vancouver, Canada. Association for Computational Linguistics.
+Vladimir Karpukhin, Barlas Oguz, Sewon Min, Patrick Lewis, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6769-6781, Online. Association for Computational Linguistics.
+Omar Khattab and Matei Zaharia. 2020. Colbert: Efficient and effective passage search via contextualized late interaction over BERT. In Proceedings of the 43rd International ACM SIGIR conference on research and development in Information Retrieval, SIGIR 2020, Virtual Event, China, July 25-30, 2020, pages 39-48. ACM.
+Tom Kwiatkowski, Jennimaria Palomaki, Olivia Redfield, Michael Collins, Ankur Parikh, Chris Alberti, Danielle Epstein, Illia Polosukhin, Jacob Devlin, Kenton Lee, Kristina Toutanova, Llion Jones, Matthew Kelcey, Ming-Wei Chang, Andrew M. Dai, Jakob Uszkoreit, Quoc Le, and Slav Petrov. 2019. Natural questions: A benchmark for question answering research. Transactions of the Association for Computational Linguistics, 7:452-466.
+Patrick Lewis, Pontus Stenetorp, and Sebastian Riedel. 2021. Question and answer test-train overlap in open-domain question answering datasets. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 1000-1008, Online. Association for Computational Linguistics.
+Robert Litschko, Ivan Vulic, Simone Paolo Ponzetto, and Goran Glavaš. 2021. On cross-lingual retrieval with multilingual text encoders. *ArXiv preprint*, abs/2112.11031.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized BERT pretraining approach. *ArXiv* preprint, abs/1907.11692.
+Yi Luan, Jacob Eisenstein, Kristina Toutanova, and Michael Collins. 2021. Sparse, dense, and attentional representations for text retrieval. Transactions of the Association for Computational Linguistics, 9:329-345.
+Yanjun Ma, Dianhai Yu, Tian Wu, and Haifeng Wang. 2019. Paddlepaddle: An open-source deep learning
+
+platform from industrial practice. Frontiers of Data and Computing, 1(1):105-115.
+Yuning Mao, Pengcheng He, Xiaodong Liu, Yelong Shen, Jianfeng Gao, Jiawei Han, and Weizhu Chen. 2021. Generation-augmented retrieval for open-domain question answering. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4089-4100, Online. Association for Computational Linguistics.
+Tri Nguyen, Mir Rosenberg, Xia Song, Jianfeng Gao, Saurabh Tiwary, Rangan Majumder, and Li Deng. 2016. Ms marco: A human generated machine reading comprehension dataset.
+Rodrigo Nogueira, Wei Yang, Jimmy Lin, and Kyunghyun Cho. 2019. Document expansion by query prediction. ArXiv preprint, abs/1904.08375.
+Yingqi Qu, Yuchen Ding, Jing Liu, Kai Liu, Ruiyang Ren, Wayne Xin Zhao, Daxiang Dong, Hua Wu, and Haifeng Wang. 2021. RocketQA: An optimized training approach to dense passage retrieval for open-domain question answering. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 5835-5847, Online. Association for Computational Linguistics.
+Stephen Robertson and Hugo Zaragoza. 2009. The probabilistic relevance framework: Bm25 and beyond. Information Retrieval, 3(4):333-389.
+Gerard Salton and Christopher Buckley. 1988. Termweighting approaches in automatic text retrieval. Information Processing & Management, 24(5):513-523.
+Peng Shi, Rui Zhang, He Bai, and Jimmy Lin. 2021. Cross-lingual training of dense retrievers for document retrieval. In Proceedings of the 1st Workshop on Multilingual Representation Learning, pages 251–253, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Shuo Sun and Kevin Duh. 2020. CLIRMatrix: A massively large collection of bilingual and multilingual datasets for cross-lingual information retrieval. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4160-4170, Online. Association for Computational Linguistics.
+Yu Sun, Shuohuan Wang, Yukun Li, Shikun Feng, Xuyi Chen, Han Zhang, Xin Tian, Danxiang Zhu, Hao Tian, and Hua Wu. 2019. Ernie: Enhanced representation through knowledge integration. ArXiv preprint, abs/1904.09223.
+Nandan Thakur, Nils Reimers, Andreas Rückle, Abhishek Srivastava, and Iryna Gurevych. 2021. Beir: A heterogeneous benchmark for zero-shot evaluation
+
+of information retrieval models. In Thirty-fifth Conference on Neural Information Processing Systems Datasets and Benchmarks Track (Round 2).
+Ellen M Voorhees, Donna K Harman, et al. 2005. TREC: Experiment and evaluation in information retrieval, volume 63. CiteSeer.
+Zhijing Wu, Jiaxin Mao, Yiqun Liu, Min Zhang, and Shaoping Ma. 2019. Investigating passage-level relevance and its role in document-level relevance judgment. In Proceedings of the 42nd International ACM SIGIR Conference on Research and Development in Information Retrieval, SIGIR 2019, Paris, France, July 21-25, 2019, pages 605-614. ACM.
+Lee Xiong, Chenyan Xiong, Ye Li, Kwok-Fung Tang, Jialin Liu, Paul N. Bennett, Junaid Ahmed, and Arnold Overwijk. 2021. Approximate nearest neighbor negative contrastive learning for dense text retrieval. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net.
+Jingtao Zhan, Jiaxin Mao, Yiqun Liu, Jiafeng Guo, Min Zhang, and Shaoping Ma. 2021. Optimizing Dense Retrieval Model Training with Hard Negatives, pages 1503-1512. Association for Computing Machinery, New York, NY, USA.
+Jingtao Zhan, Xiaohui Xie, Jiaxin Mao, Yiqun Liu, M. Zhang, and Shaoping Ma. 2022. Evaluating extrapolation performance of dense retrieval. ArXiv, abs/2204.11447.
+Sheng Zhang, Xin Zhang, Hui Wang, Lixiang Guo, and Shanshan Liu. 2018. Multi-scale attentive interaction networks for chinese medical question answer selection. IEEE Access, 6:74061-74071.
+Yukun Zheng, Zhen Fan, Yiqun Liu, Cheng Luo, Min Zhang, and Shaoping Ma. 2018. Sogou-qcl: A new dataset with click relevance label. In The 41st International ACM SIGIR Conference on Research & Development in Information Retrieval, SIGIR 2018, Ann Arbor, MI, USA, July 08-12, 2018, pages 1117-1120. ACM.
+Hongyu Zhu, Yan Chen, Jing Yan, Jing Liu, Yu Hong, Ying Chen, Hua Wu, and Haifeng Wang. 2021. Duqm: A chinese dataset of linguistically perturbed natural questions for evaluating the robustness of question matching models. ArXiv preprint, abs/2112.08609.
+
+# A Appendix
+
+# A.1 Details for Re-ranker Used in Reducing False Negatives
+
+We first use four different pre-training models, including ERNIE (Sun et al., 2019), BERT (Devlin et al., 2019; Cui et al., 2021), RoBERTa (Liu et al., 2019) and MacBERT (Cui et al., 2020), as the initializations to train four cross-encoder re-rankers as in (Qu et al., 2021) with negatives sampled from the pooled passages as discussed in Section 2.3. We then ensemble these four re-ranking models by averaging their prediction scores for each query-passage pair.
+
+# A.2 Baseline Implementation Details
+
+We conduct all experiments with the deep learning framework PaddlePaddle (Ma et al., 2019) on up to eight NVIDIA Tesla A100 GPUs (with 40G RAM).
+
+We use the ERNIE 1.0 base (Sun et al., 2019) as the initializations for both our first dual-encoder retriever (DE w/ BM25 Neg) and cross-encoder re-ranker (CE w/ BM25 Neg). ERNIE shares the same architecture with BERT but is trained with entity-level masking and phrase-level masking to obtain better knowledge-enhanced representations. To train our second enhanced re-ranker (CE w/ DE Neg), we use the parameters from CE w/ BM25 Neg as initialization.
+
+For training settings, we also use the Cross-batch negatives setting as in (Qu et al., 2021). When sampling the hard negatives from the top-50 retrieved items, we sample 4 negatives per positive passage. The dual-encoders are trained with the batch size of 256. The cross-encoders are trained with the batch size of 64. The dual-encoders and cross-encoders are trained with 10 and 3 epochs. We use ADAM optimizer for all models' trainings and the learning rate of the dual-encoder is set to 3e-5 with the rate of linear scheduling warm-up at 0.1, while the learning rate of the cross-encoder is set to 1e-5 with no warm-up training. We set the maximal length of questions and passages as 32 and 384, respectively.
+
+In inference time of our dense retrieval model (DE w/ BM25 Neg), we use FAISS (Johnson et al., 2019) to index the dense representations of all passages.
+
+# A.3 Details for Human Annotations
+
+We perform the annotation in our internal annotation platform to ensure the data quality, where all
+
+the annotators and reviewers are full-time employees. The pairs of all queries and their pooled top-5 paragraphs retrieved by all models are divided into packages, with 1K samples for each. Annotators are asked to identify whether each query-paragraph pair is relevant for a single package. Then at least two reviewers check the accuracy of this package by reviewing 100 random query-paragraph pairs independently. If the average accuracy is less than the threshold (i.e., $93\%$ ), the annotators will be asked to revise the package until the accuracy is higher than the threshold.
+
+# A.4 Cases for Challenges in Error Analysis
+
+We present the selected cases in Table 10 and discuss them in this section to support our error analysis in Section 3.5.
+
+Salient Phrase Mismatch Taking the entity mismatch as an example, we expect that the main entity in the retrieved passage should be consistent with the query. However, the second example in Table 10 shows that the query asks for information about Taobao, but the retrieved passage is related to Alipay instead. There is a challenge for retrieval systems to filter out passages that entail entities inconsistent with the query.
+
+Syntax Mismatch Given the case showed in Table 10 as an example, the retrieval system is hard to understand the subject and object in the example query are Taipei and Ruifang, instead, it simply ranks the candidate passage entailing Taipei and Ruifang to a top predictions.
+
+Other Challenges In our analysis, it is found that about $21\%$ of the errors are due to the retrieval system simply predicting its output based on the presence of co-occurring low-frequency terms (e.g., "wow" in the example in Table 10) in query and paragraph, but their semantic meanings are not related indeed. And about $1.6\%$ of the errors are due to noise in the query or paragraph. For example, misspelling the "iPhone" as "ipone".
+
+| Category | Type | Example Query | Example Passage | Explanation | % |
| Salient Phrase Mismatch | Entity mismatch | 淘宝修改实名认证Change authentication name at Taobao | 响应国家规定,支付宝即将实施支付宝个人信息实名认证...In response to national regulations, Ali-pay will soon implement real-name authentication... | The entities in the query (Taobao) and the passage (Alipay) are mismatched. | 39% |
| Numeral mismatch | 最近有什么好听的歌2016Any nice songs in 2016 | ...音乐巴士2017好听的歌榜单收藏了你最需要的的好歌... ...Music Bus's Best Songs 2017 has the songs you need most... | The query asks for songs in 2016, but the passage is about songs in 2017. | 5% |
| Modifier mismatch | 吃完海鲜可以喝牛奶吗Can I drink milk after having seafood? | 不可以。早晨喝牛奶,不科学。原因是... No. Drinking milk in the morning is not good for health. The reason is... | The modifier in query (after eating seafood) and the one in the passage (in the morning) are different. | 9.4% |
| Syntactic mismatch | Syntactic mismatch | 台北怎么去瑞芳How to go from Taipei to Ruifang | 从瑞芳回台北,乘火车1小时到达,可以使用悠游卡... It takes 1 hour by train from Ruifang to Taipei. You can use the EasyCard... | The query asks how to go from Taipei to Ruifang but the paragraph is about going from Ruifang to Taipei. | 1% |
| Other Challenges | Robustness on typos | iponeiPhone手机屏幕右上角有个圈是什么What is the circle in the upper right corner of the iponeiPhone screen | 但是又不知道这些图标是怎么出现的。是什么东西,干什么用的,例如手机号格旁边的眼睛图标是代表了开启只能屏幕... But I don't know how these icons appeared. What is it and what is it for? For example, the eye icon next to the mobile phone signal grid means that the screen can only be turned on... | Typos may introduce noise to the model's understanding of query or passage, e.g., it may affects the identification of the main entity iPhone in the query. | 1.6% |
| Over-sensitivity on term overlap | wow邮件发错了怎么办What should I do if my wow email is sent by mistake | ...还有个方法就是你登陆WOW然后都设置好后退出游戏... ...and another way is that you log in to WOW and then exit the game after setting everything up... | The query and passage (i.e., WOW) has a matched term in; but they are semantically irrelevant. | 21% |
| Others | False negatives | 求推荐好看的国产电视剧Please recommend good Chinese TV series | TOP3: 美人制造。30集全。主演: 杨蓉金世佳邓萃雯。简介: 以唐代女皇武则天时期为大背景... TOP3: Beauty Made. 30 episodes. Star-ring: Yang Rong, Jin Shijia, Deng Cui-wen. Introduction: Taking the period of Empress Wu Zetian of the Tang Dynasty as the background... | \ | 14.8% |
| Others | \ | \ | Cases not fitting into any of above categories. | 8.2% |
+
+Table 10: Summary of the manual analysis for the 500 query-passage pairs predicted by our strongest re-ranker (CE w/ DE Neg). We highlight the challenges in salient phrase mismatch in red, syntax mismatch in blue, and Other Challenges in green.
\ No newline at end of file
diff --git a/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/images.zip b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..36389e1d7eaaf51ee70072619c142b65dde86a67
--- /dev/null
+++ b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:82a7ae8313b4683bae1b1337b5c3479ead5a2fb4ff262708d7e908dffddcde5f
+size 480603
diff --git a/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/layout.json b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..f6438f9ca81e59ed026d71bfb18c7b3517397f8a
--- /dev/null
+++ b/dureaderretrievalalargescalechinesebenchmarkforpassageretrievalfromwebsearchengine/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e14a3683e5f31de1179491e23ca33e1d9b0e668391995effd1783360b5ae170a
+size 394413
diff --git a/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_content_list.json b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e40cd8c4ee308dd3eef1fdb5373b17bf529b81b8
--- /dev/null
+++ b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d9bb7d6f31550f5c534d012b77cd9ab0249dfc61b6a15c5c055779f15cd616a3
+size 92309
diff --git a/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_model.json b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..fa789b3a3c83c805cb9b5055cd2636a77d603ddd
--- /dev/null
+++ b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e281c3e6d8d8e57aea2d66e79ff10c6110e5f675078c365c5bde546a52913eac
+size 116857
diff --git a/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_origin.pdf b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..49006de24f2f9c804ebe2549371a3e4af25985ec
--- /dev/null
+++ b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/3df789c6-5c2f-4f9b-9b8b-372c510f155f_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4909966f7ea5fcc9fada0d8aec575392c4e4d0ba800089ffeb7f7acaa3f984e0
+size 1248995
diff --git a/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/full.md b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..471229e336d3a88dba3ad43c860e5161eae0935f
--- /dev/null
+++ b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/full.md
@@ -0,0 +1,333 @@
+# ECTSum: A New Benchmark Dataset For Bullet Point Summarization of Long Earnings Call Transcripts
+
+Rajdeep Mukherjee $^{1*}$ Abhinav Bohra $^{1}$ Akash Banerjee $^{1}$ Soumya Sharma $^{1}$
+Manjunath Hegde $^{2}$ Afreen Shaikh $^{2}$ Shivani Shrivastava $^{2}$ Koustuv Dasgupta $^{2}$
+Niloy Ganguly $^{1,3}$ Saptarshi Ghosh $^{1}$ Pawan Goyal $^{1}$
+
+1 Department of Computer Science and Engineering, IIT Kharagpur, India
+
+2 Goldman Sachs Data Science and Machine Learning Group, India
+
+3 Leibniz University of Hannover, Germany
+
+# Abstract
+
+Despite tremendous progress in automatic summarization, state-of-the-art methods are predominantly trained to excel in summarizing short newswire articles, or documents with strong layout biases such as scientific articles or government reports. Efficient techniques to summarize financial documents, discussing facts and figures, have largely been unexplored, majorly due to the unavailability of suitable datasets. In this work, we present ECTSum, a new dataset with transcripts of earnings calls (ECTs), hosted by publicly traded companies, as documents, and experts-written short telegram-style bullet point summaries derived from corresponding Reuters articles. ECTs are long unstructured documents without any prescribed length limit or format. We benchmark our dataset with state-of-the-art summarization methods across various metrics evaluating the content quality and factual consistency of the generated summaries. Finally, we present a simple yet effective approach, ECT-BPS, to generate a set of bullet points that precisely capture the important facts discussed in the calls.
+
+# 1 Introduction
+
+Earnings Calls, typically a teleconference or a webcast, are hosted by publicly traded companies to discuss important aspects of their quarterly (10-Q), or annual (10-K) earnings reports, along with current trends and future goals that help financial analysts and investors to review their price targets and trade decisions (Givoly and Lakonishok, 1980; Richard Frankel and Skinner, 1999; Bowen et al., 2002; Keith and Stent, 2019). The corresponding call transcripts (called Earnings Call Transcripts, abbreviated as ECTs) are typically in the form of long unstructured documents consisting of thousands of words. Hence, it requires a great deal of time and effort, even on the part of trained analysts, to quickly summarize the key facts covered in these
+
+- QUARTERLY EARNINGS PER SHARE $1.52.
+- QUARTERLY TOTAL NET SALES $97.28 BILLION VERSUS$ 89.58 BILLION REPORTED LAST YEAR.
+ BOARD OF DIRECTORS AUTHORIZED AN INCREASE OF $90 BILLION TO THE EXISTING SHARE REPURCHASE PROGRAM.
+- QUARTERLY IPHONE REVENUE $50.57 BILLION VERSUS$ 47.94 BILLION REPORTED LAST YEAR.
+
+Table 1: ECTSum: Excerpt from the Reuters article1 corresponding to the $\mathrm{ECT}^2$ for Apple Q2 2022.
+
+transcripts. Given the importance of these calls, they are often summarized by media houses such as Reuters and BusinessWire. The scale of such effort, however, calls for the development of efficient methods to automate this task which in turn necessitates the creation of a benchmark dataset.
+
+Towards this goal, we present ECTSum, a new benchmark dataset for bullet-point summarization of long ECTs. As discussed in Section 3.2, first we crawled around 7.4K ECTs from The Motley Fool3, posted between January 2019 and April 2022, corresponding to the Russell 3000 Index companies4. Reuters was chosen to be the source of our target summaries, per consultation with domain experts, since the expert-written articles posted on Reuters effectively capture the key takeaways from earnings calls. However, searching for Reuters articles corresponding to the collected ECTs was especially challenging, since the task was non-trivial. Given the fact that not all calls are tracked, after carefully performing data cleaning and addressing pairing issues, we arrive at a total of 2,425 document-summary pairs as part of the dataset.
+
+What makes $ECTSum$ truly different from others is the way the summaries are written. Instead of containing well-formed sentences, the articles
+
+contain telegram-style bullet-points precisely capturing the important metrics discussed in the earnings calls. A sample reference summary from our dataset corresponding to the 2nd quarter 2022 earnings call of Apple is shown in Table 1. There are several other factors that make ECTSum a challenging dataset. First, the document-to-summary compression ratio of 103.67 is the highest among existing long document summarization datasets with comparable document lengths (Table 2). Hence, in order to do well, trained models need to be highly precise in capturing the most relevant facts discussed in the ECTs in as few words as possible.
+
+Second, existing long document summarization datasets such as Arxiv/PubMed (Cohan et al., 2018), BigPatent (Sharma et al., 2019), FNS (El-Haj et al., 2020), and GovReport (Huang et al., 2021), have fixed document layouts. ECTs, on the other hand, are free-form documents with salient information spread throughout the text (please refer Section 3.3). Hence, models can no longer take advantage of learning any stylistic signals (Krysciński et al., 2021). Third, the average length of ECTs is around 2.9K words (before tokenization). On the other hand, neural models employing BERT (Devlin et al., 2019), T5 (Raffel et al., 2020), or BART (Lewis et al., 2020) as document encoders cannot process documents longer than 512/1024 tokens. Hence, despite achieving state-of-the-art performances on short-document summarization datasets such as CNN/DM (Nallapati et al., 2016), Newsroom (Grusky et al., 2018), and XSum (Narayan et al., 2018), etc., such models cannot be readily applied to effectively summarize ECTs.
+
+We benchmark the performance of several representative summarization approaches (Section 5.1) from both supervised and unsupervised paradigms, on our newly proposed dataset. Among supervised, we select state-of-the-art methods from extractive, abstractive, and long document summarization literature. Finally, given the pattern of source transcripts and target summaries, we present ECT-BPS, a simple yet effective pipeline approach for the task of ECT summarization (Section 4). Specifically, it consists of an extractive summarization module followed by a paraphrasing module. While, the former is trained to identify salient sentences from the source ECT, the latter is trained to paraphrase ECT sentences to short abstractive telegram-style bullet-points that precisely capture the numerical values and facts discussed in the calls.
+
+In order to demonstrate the challenges of the proposed ECTSum dataset, competing methods are evaluated on several metrics that assess the content quality and factual consistency of the model-generated summaries. These metrics are discussed in Section 5.2. We discuss the comparative results of all considered methods against automatic evaluation metrics in Section 5.4. Given the complex nuances of financial reporting, we further conduct a human evaluation experiment (survey results reported in Section 5.5) where we hire a team of financial experts to manually assess and compare the summaries generated by ECT-BPS, and those of our strongest baseline. Overall, both automatic and manual evaluation results show ECT-BPS to outperform strong state-of-the-art baselines, which demonstrates the advantage of a simple approach.
+
+Our contributions can be summarized as follows:
+
+- We present ECTSum, the first long document summarization dataset in the finance domain that requires models to process long unstructured earning call transcripts and summarize them in a few words while capturing crucial metrics and maintaining factual consistency.
+- We propose ECT-BPS, a simple approach to effectively summarize ECTs while ensuring factual correctness of the generated content. We establish its better efficacy against strong summarization baselines across all considered metrics evaluating the content quality and factual correctness of model-generated summaries.
+- Our dataset and codes are publicly available at https://github.com/rajdeep345/ECTSum
+
+# 2 Related Works
+
+Automatic text summarization, extractive (Nallapati et al., 2017; Zhong et al., 2020), abstractive (Zhang et al., 2019; Lewis et al., 2020), as well as long document summarization (Zaheer et al., 2020; Beltagy et al., 2020) have seen tremendous progress over the years (Huang et al., 2020). Several works also exist on controllable summarization (Mukherjee et al., 2020; Amplayo et al., 2021) and, in specific domains, such as disaster (Mukherjee et al., 2022), and legal (Shukla et al., 2022). However, the field of financial data summarization remains largely unexplored, primarily due to the unavailability of suitable datasets. Passali et al. (2021) have recently compiled a financial news summarization dataset consisting of around 2K Bloomberg articles with corresponding human-written sum
+
+maries. However, similar to other popular newswire datasets such as CNN/DM (Nallapati et al., 2016), Newsroom (Grusky et al., 2018), XSum (Narayan et al., 2018), the documents (news articles) themselves are only a few hundred words long, hence limiting the practical importance of model generated summaries (Krysciński et al., 2021).
+
+To the best of our knowledge, FNS (El-Haj et al., 2020) is the only available financial summarization dataset, released as part of the Financial Narrative Summarization Shared Task $2020^{5}$ . In FNS, annual reports of UK firms constitute the documents, and a subset of narrative sections from the reports are given verbatim as reference summaries. However, ECTSum differs from FNS on several accounts.
+
+First, our target summaries consist of a small set of telegram-style bullet-points, whereas the ones in FNS are large extractive portions from respective source documents. Second, $ECTSum$ has a very high document-to-summary compression ratio (refer Section 3.3), because of which the models are expected to generate extremely concise summaries of around 50 words from lengthy unstructured ECTs, around 2.9K words long. In contrast, the expected length of model-generated summaries on FNS is around 1000 words. Finally, the models developed on FNS are specifically trained to identify and summarize the narrative sections, while completely ignoring others containing facts, and figures that reflect the firm's annual financial performance. Excluding these key performance indicators from summaries limits their practical utility to stakeholders. Models trained on $ECTSum$ , on the other hand, are specifically expected to capture salient financial metrics such as sales, revenues, current trends, etc. in as few words as possible.
+
+Previously, Cardinaels et al. (2018) had attempted to summarize earnings calls using standard unsupervised approaches. We are however the first to propose and exhaustively benchmark a large scale financial long document summarization dataset involving earnings call transcripts.
+
+# 3 Dataset
+
+This section describes our dataset, ECTSum, including the data sources, and the steps taken to sanitize the data, in order to obtain the document-summary pairs. Finally, we conduct an in-depth analysis of the dataset and report its statistics.
+
+# 3.1 Data Collection
+
+ECTs of listed companies are publicly hosted on The Motley Fool $^{6}$ . We crawled the web pages corresponding to all available ECTs for the Russell 3000 Index companies $^{7}$ posted between January 2019 and April 2022. In the process, we obtain a total of 7,389 ECTs. The HTML web pages were parsed using the BeautifulSoup $^{8}$ library. ECTs typically consist of two broad sections: Prepared Remarks, where the company's financial results, for the given reporting period, are presented; and Question and Answers, where call participants ask questions regarding the presented results. We only consider the unstructured text corresponding to the Prepared Remarks section to form the source documents.
+
+Collecting expert-written summaries corresponding to these ECTs was a far more challenging task. Reuters9 hosts a huge repository of financial news articles from around the world. Among these, are articles, written by analysts, that summarize earnings calls events in the form of a few bulleted points (see Table 1). After manually going through several such articles, and after consulting experts from Goldman Sachs, India, we understood that these articles precisely capture the key takeaways10 from earnings calls. Accordingly, using the company codes and dates of the earnings call events corresponding to the collected ECTs, we crawled Reuters web pages to search for relevant articles. We obtained 3,013 Reuters articles in the process.
+
+# 3.2 Data Cleaning and Pairing
+
+Cleaning the ECTs: Almost all earnings calls (and hence the corresponding transcripts) begin with an introduction by the call moderator/operator. We remove these statements since they do not relate to the financial results discussed thereafter. Some calls directly start with the Questions and Answers, in which case we exclude them from the collection.
+
+Cleaning the summaries: For the Reuters (summary) articles, first we performed simple preprocessing to split the text into sentences. In many articles, we observed sentences ending with the phrase REFINITIV IBES DATA. Such sentences report estimates made by Refinitiv11 analysts on the
+
+6https://www.fool.com/earnings-call-transcripts/
+7https://www.investopedia.com/terms/r/russell_3000.asp
+8https://crummy.com/software/BeautifulSoup/
+9https://www.reuters.com/business/
+$^{10}$ https://tinyurl.com/27ehcxzf
+11 https://tinyurl.com/2p9e6kh2
+
+| Dataset | #Docs. | Coverage | Density | Comp. Ratio | # Tokens |
| Doc. | Summary |
| ARXIV/PUBMED (Cohan et al., 2018)* | 346,187 | 0.87 | 3.94 | 31.17 | 5179.22 | 257.44 |
| BILLSUM (Kornilova and Eidelman, 2019)† | 23,455 | - | 4.12 | 13.64 | 1813.0 | 207.7 |
| BIGPATENT (Sharma et al., 2019)* | 1,341,362 | 0.86 | 2.38 | 36.84 | 3629.04 | 116.67 |
| GOVREPORT (Huang et al., 2021)† | 19,466 | - | 7.60 | 19.01 | 9409.4 | 553.4 |
| BOOKSUM Chapters (KrySciński et al., 2021)* | 12,293 | 0.78 | 1.69 | 15.97 | 5101.88 | 505.32 |
| ECTSum | 2,425 | 0.85 | 2.43 | 103.67 | 2916.44 | 49.23 |
+
+Table 2: Comparing the statistics of ECTSum dataset with existing long document summarization datasets. The numbers for the datasets marked with * are copied from Krysciński et al. (2021), whereas the ones marked with † are copied from Huang et al. (2021). Numbers which were not reported are left blank. ECTSum has the highest compression ratio among all the datasets while having comparable coverage and density scores.
+
+
+Figure 1: Salient unigram distribution in four equally sized segments of the source text. Higher percentages indicate higher unigram overlap. Percentages more than 25 indicate there are repetitions.
+
+earnings of publicly traded companies. We remove these sentences as they do not correspond to the actual results discussed in the earnings calls (as understood from our discussion with financial experts). In the process, we make our target summaries factually consistent with the source documents.
+
+Creating Document-Summary Pairs: In order to automate the process of pairing an ECT with its corresponding Reuters article, first we made sure that the article mentions the same company code as the ECT, and second, it is posted either on the same day or at max one day after the earnings event. Please refer to Section A.1 for more details. After obtaining the automatically-matched pairs, the authors manually and independently cross-checked 200 randomly selected ECT(document)-Reuters(summary) pairs. We found all the pairs to be properly matched. The process thus ensures accuracy at the cost of obtaining a smaller amount of (sanitized) data. The dataset can however be easily extended as future earnings calls are covered by media houses, such as Reuters, and BusinessWire.
+
+# 3.3 Statistics and Analysis
+
+The data cleaning and pairing process described above resulted in a total of 2,425 document-summary pairs, with average document length of around 2.9K words and average target summary length of around 50 words. We randomly split the data to form the train (70%), validation (10%) and test (20%) sets. In Table 2, we report various dataset statistics, as defined by Grusky et al. (2018), for the ECTSum corpus and compare them with the existing long document summarization datasets. While Coverage quantifies the extent to which a summary is derivative of a text, Density measures how well the word sequence of a summary can be described as a series of extractions. Our scores of 0.85 (Coverage) and 2.43 (Density) are fairly comparable with other datasets. These indicate that although our target summary sentences are short abstractive texts, they are fairly derivable from the ECT content. Our document-to-summary compression ratio score of 103.67 is overwhelmingly higher than any other dataset. This makes ECTSum challenging to work on, and requires models to be trained in a way so that they can capture relevant information in as few words as possible. Both these factors motivated the design of our proposed approach, ECT-BPS (refer to Section 4).
+
+Following prior works (Huang et al., 2021; Kryscinski et al., 2021), we further assess whether the target summary content is confined to certain portions of the source document. For this, we plot, in Fig. 1, the percentage distribution of salient unigrams (target summary words excluding stopwords) in four equally sized segments of the source text. We observe that the salient content is evenly distributed across all the four segments of the source documents. This property requires models, trained on ECTSum, to process the entire document in order to generate a high quality summary.
+
+
+Figure 2: ECT-BPS: Our Proposed Summarization Framework. It consists of an Extractive Module that is trained to select highly salient sentences from the source document. The Paraphrasing Module is then trained to paraphrase the ECT sentences to the (Reuters) format of target summary sentences.
+
+# 4 The ECT-BPS Framework
+
+We observe some important properties of the Reuters reference summaries. They contain a high percentage of word overlap with the source ECT documents. However, they are not extractive, rather contain a small set of abstractive bullet-points. It seems as if the analysts writing these summaries first selected some crucial parts of the ECT, before compressing them into a bullet-point format. These properties of the reference summaries motivated us to design a two-stage pipeline approach for summarizing ECTs. Our proposed model ECT-BPS contains two separately trained modules/blocks – (1) an Extractive block that is trained to identify the most relevant sentences from the input ECT document, and (2) a Paraphrasing block that is trained to rephrase the extracted ECT sentences to the format of target (Reuters) sentences, thereby generating a set of bullet points. Figure 2 gives an overview of our proposed architecture.
+
+# 4.1 The Extractive Module
+
+We leverage and suitably modify the architecture of SummaRuNNer (Nallapati et al., 2017) to design our extractive module. The vanilla SummaRuNNer consists of a two-layer bi-directional GRU-RNN. The first layer works at the word-level to learn contextualized word representations, which are then average-pooled to obtain sentence representations. We replace this layer by FinBERT (Yang et al., 2020), a BERT model pre-trained on financial communication text, and use it to obtain the individual
+
+sentence representations. The second layer of bi-directional GRU-RNN works at the sentence-level to learn contextualized representations of the input ECT sentences. We then obtain the document representation $d$ using the hidden state vectors of sentences from this second layer of bi-directional GRU-RNN as follows:
+
+$$
+d = \tanh \left(W _ {d} \frac {1}{N _ {d}} \sum_ {i = 1} ^ {N _ {d}} \left[ h _ {i} ^ {f}, h _ {i} ^ {b} \right] + b\right) \tag {1}
+$$
+
+where $h_i^f$ and $h_i^b$ respectively represent the hidden state vectors of the forward, and backward GRUs corresponding to $s_i$ , the $i^{th}$ sentence of the input ECT document. $W_d$ and $b$ represent the weight and bias parameters, respectively. $N_d$ represents the number of sentences in the document.
+
+Each sentence $s_i$ is sequentially revisited in a second pass where a classification layer (Fig. 2) takes a binary decision regarding its inclusion in the summary as follows:
+
+$$
+P \left(y _ {i} = 1\right) = f \left(h _ {i}, \operatorname {s u m} _ {i}, d, p _ {i} ^ {a}, p _ {i} ^ {r}, \nu_ {i}\right) \tag {2}
+$$
+
+Here, $h_i$ represents a non-linear transformation of $[h_i^f, h_i^b]$ . $sum_i$ represents the intermediate representation of the summary formed till $s_i$ is visited. $p_i^a$ , and $p_i^r$ respectively represent the absolute and relative positional embeddings corresponding to $s_i$ . Please refer to Nallapati et al. (2017) for more details. We add a parameter $\nu_i$ that is set to 1 if $s_i$ contains numerical values, and 0 otherwise. Keeping in mind the nature of the target summary sentences, that predominantly discuss metrics and numbers, $\nu_i$
+
+guides the classifier to give higher weightage to sentences containing numerical values. Therefore, for each sentence $s_i$ , its content $f(h_i)$ , salience given the document context $f(h_i, d)$ , novelty considering the summary already formed $(f(h_i, \text{sum}_i))$ , positional importance, and the fact whether it contains monetary figures, are all taken into account while deciding upon its summary membership.
+
+# 4.2 The Paraphrasing Module
+
+As depicted in Fig. 2, we fine-tune T5 (Raffel et al., 2020) to paraphrase the input ECT sentences to the telegram-style (Reuters) format of target summary sentences. During this paraphrasing, special care is taken to ensure that the numerical values in the input sentences are not rephrased wrongly (hallucinated). More specifically, during training we replace the numerical values in the input sentences with placeholders such as [num-one], [num-two], etc. After obtaining the paraphrased sentences, we replace the placeholders with their original values by performing a simple post-processing step.
+
+# 4.3 Training and Inference
+
+Target Summary for Extractive Module. Corresponding to each sentence (hereby referred to as the 'target sentence') in the reference summary (obtained from Reuters), first we greedily search for a document sentence (using regular expressions) that captures all the numerical values mentioned in the target sentence. In case of multiple matches, we select all such document sentences. If no match is found, we select the document sentence that is most similar to the target sentence, in terms of cosine similarity between their embeddings obtained using Google's Universal Sentence Encoder (Cer et al., 2018). The selected set of document sentences serve as the target summary for training the Extractive Module. We train this module by minimizing the Binary Cross Entropy loss between the predicted and the true sentence labels.
+
+For training the Paraphrasing Module, each sentence in the target summary for the Extractive Module becomes the source while the corresponding reference summary sentence becomes the target. The module is trained by minimizing the Cross-Entropy loss between the predicted and target tokens.
+
+During inference, a test ECT document is sent as input to the trained Extractive Module. Sentences corresponding to the extractive summary thus obtained are paraphrased using the trained Paraphrasing Module to obtain the final summary.
+
+# 5 Experiments and Results
+
+In this section, we first enumerate the baselines and evaluation metrics. We then describe our experimental setup, followed by a detailed discussion of our main results. We then report the design and results of a human evaluation experiment conducted to manually assess and compare ECT-BPS-generated summaries with those of competing baselines. We end this section with a qualitative analysis of model-generated summaries.
+
+# 5.1 Baselines
+
+We evaluate and compare the summarization performance of a wide range of representative algorithms corresponding to various categories on the $ECT$ -Sum corpus. The categories together with their specific algorithms are enumerated below:
+
+1. Unsupervised Approaches: LexRank (Erkan and Radev, 2004), DSDR (He et al., 2012), PacSum (Zheng and Lapata, 2019).
+2. Extractive Approaches: SummaRuNNer (Nallapati et al., 2017), BertSumEXT (Liu and Lapata, 2019), MatchSum (Zhong et al., 2020).
+3. Abstractive Approaches: BART (Lewis et al., 2020), Pegasus (Zhang et al., 2019), T5 (Raffel et al., 2020).
+4. Long Document Summarizers: BigBird (Za-heer et al., 2020), LongT5 (Guo et al., 2021), Longformer Encoder Decoder (LED) (Beltagy et al., 2020).
+
+For more details, please refer to the appendix A.2.
+
+# 5.2 Evaluation Metrics
+
+1. For evaluating the content quality of model-generated summaries, we consider ROUGE (Lin, 2004), and BERTScore (Zhang et al., 2020). We report the F-1 scores corresponding to ROUGE-1, ROUGE-2, and ROUGE-L.
+2. For assessing the factual correctness of the generated summaries, we consider SummaCCONV (Laban et al., 2022), a recently proposed NLI-based factual inconsistency detection model.
+3. Num-Prec.: Accurate reporting of monetary figures is crucial in the financial domain. However, quantity hallucination is a known problem in abstractive summaries (Zhao et al., 2020). In order to evaluate the correctness of values captured in summaries, especially the abstractive ones, we define Num-Prec. as the fraction of numerals/values in the model-generated summaries that appear in the source text. Please refer A.3.
+
+| Model | ROUGE-1 | ROUGE-2 | ROUGE-L | BERTScore | Num-Prec. | SummaCCONV |
| Unsupervised |
| LexRank (Erkan and Radev, 2004) | 0.122 | 0.023 | 0.154 | 0.638 | 1.00 | 1.00 |
| DSDR (He et al., 2012) | 0.164 | 0.042 | 0.200 | 0.662 | 1.00 | 1.00 |
| PacSum (Zheng and Lapata, 2019) | 0.167 | 0.046 | 0.205 | 0.663 | 1.00 | 1.00 |
| Extractive |
| SummaRuNNer (Nallapati et al., 2017) | 0.273 | 0.107 | 0.309 | 0.647 | 1.00 | 1.00 |
| BertSumExt (Liu and Lapata, 2019) | 0.307 | 0.118 | 0.324 | 0.667 | 1.00 | 1.00 |
| MatchSum (Zhong et al., 2020) | 0.314 | 0.126 | 0.335 | 0.679 | 1.00 | 1.00 |
| Abstractive |
| BART (Lewis et al., 2020) | 0.327 | 0.153 | 0.361 | 0.692 | 0.594 | 0.431 |
| Pegasus (Zhang et al., 2019) | 0.334 | 0.185 | 0.375 | 0.708 | 0.783 | 0.444 |
| T5 (Raffel et al., 2020) | 0.363 | 0.209 | 0.413 | 0.728 | 0.796 | 0.508 |
| Long Document Summarizers |
| BigBird (Zaheer et al., 2020) | 0.344 | 0.252 | 0.400 | 0.716 | 0.844 | 0.452 |
| LongT5 (Guo et al., 2021) | 0.438 | 0.267 | 0.471 | 0.732 | 0.812 | 0.516 |
| LED (Beltagy et al., 2020) | 0.450 | 0.271 | 0.498 | 0.737 | 0.679 | 0.439 |
| Ours |
| ECT-BPS w/o Paraphrasing | 0.313 | 0.137 | 0.351 | 0.714 | 1.00 | 1.00 |
| ECT-BPS | 0.467 | 0.307 | 0.514 | 0.764 | 0.916 | 0.518 |
+
+Table 3: Comparison of representative summarizers against automatic evaluation metrics. Best scores are bold-ed. For Num-Prec. and Summa $C_{CONV}$ , we highlight the best scores among abstractive methods (reasons in Section 5.4). ECT-BPS-generated summaries score the highest on both content quality as well as factual consistency.
+
+# 5.3 Experimental Setup
+
+As discussed in Section 4.3, we train the two modules of ECT-BPS separately. For respectively training the extractive (and paraphrasing) modules, we initialize the FinBERT $^{12}$ (and $\mathrm{T5}^{13}$ ) parameters using pre-trained weights from Huggingface (Wolf et al., 2020). In the extractive module, all other parameters were set as defined in Nallapati et al. (2017). The Extractive (Paraphrasing) module is trained end-to-end with Adam Optimizer with a learning rate of 1e-5 (2e-5) and batch size 8 (16).
+
+Among the baselines, BART $^{14}$ and Pegasus $^{15}$ model parameters were initialized with weights pre-trained on financial data. For others, the base version of their respective models were used to initialize the parameter weights. All other model hyperparameters were initialized with default values as specified in the respective papers.
+
+All models, including the ECT-BPS modules, were trained end-to-end with hyperparameters finetuned on the validation set (recall that we used a 70:10:20 ratio as train:validation/test split). In each case, the model with the lowest validation loss was used to evaluate the test set. All experiments were performed on a Tesla P100-PCIE (16GB) GPU. BART (1024), Pegasus (512), and T5 (512) have limitations on the length of input text that they can
+
+process. Since ECTs contain around 2.9K words on an average, for training these abstractive methods, we divided the source documents into multiple chunks, each with length less than or equal to their respective max_token_len. Corresponding target summaries were made by selecting a subset of all target summary sentences that were entailed by the sentences in the document chunk under consideration. During inference, a small summary (max 32 tokens) was generated from each document chunk. The unique sentences from all such short summaries were concatenated to produce the overall summary for the entire document. Our ECTSum dataset, and codes, including baselines, are publicly available on our GitHub repository.
+
+# 5.4 Main Results
+
+Table 3 reports the performance of all competing methods on the test set. All the unsupervised methods perform poorly, thereby highlighting the domain-specific nature of the ECT summarization task, and hence the need for supervised training. Among the supervised extractive methods, MatchSum, a state-of-the-art extractive summarizer, has the best scores across all metrics. Here, we would like to highlight the advantage of the modifications we made to the vanilla SummaRrNNer code. Our Extractive Module, ECT-BPS w/o Paraphrasing, when compared to SummaRrNNer, achieves $18.7\%$ improvement on average across all the ROUGE
+
+
+(a) LED summaries
+
+
+(b) ECT-BPS summaries
+Figure 3: Histogram distribution for human evaluation scores assigned to model-generated summaries.
+
+| Model | Correctness | Relevance | Coverage |
| Summary-level scores (over 75 summaries) |
| LED better | 18 (24%) | 23 (31%) | 21 (28%) |
| ECT-BPS better | 45 (60%) | 44 (59%) | 48 (64%) |
| Both equally good | 12 (16%) | 8 (11%) | 6 (8%) |
| Expert-level Scores (over 10 experts) |
| LED better | 3 | 3 | 2 |
| ECT-BPS better | 7 | 7 | 8 |
+
+Table 4: Results for the manual evaluation of model-generated summaries by a team of 10 financial experts.
+
+scores, and $10.4\%$ improvement in BERTScore. This also makes our Extractive Module the best performing extractive method across all metrics. Please note that the Num-Prec. and Summa $C_{CONV}$ scores for all extractive summarizers are always 1.00 because the summary sentences are taken verbatim from the source documents.
+
+Among the abstractive methods, Pegasus and BART, despite being initialized with weights pretrained on financial data, could not match the performance of T5. Interestingly, both T5 (0.508) as well its long version, LongT5 (0.516), have very good factual consistency scores. These observations led us to select T5 as the backbone of our paraphrasing module. LED performs better on token overlap metrics (Rouge and BERTscore) but has poor factual consistency scores, highlighting the issue of hallucination in abstractive summarizers (King et al., 2022). To conclude, despite the understandably good performance of long document summarizers on the ECT summarization task, our simple extract-then-paraphrase approach, ECT-BPS, establishes the state-of-the-art performance with overall $6.8\%$ better ROUGE scores, $3.67\%$ better BERTScore scores, $8.5\%$ better Num-Prec scores, and $0.4\%$ better factual consistency scores over the respective strongest baselines.
+
+# 5.5 Evaluation by Financial Domain Experts
+
+Given the complex nuances of the financial domain, we get the model-generated summaries evaluated by a team 10 analysts/experts working with Goldman Sachs Data Science and Machine Learning Group, India who were well-versed with the concepts of financial reporting, earnings calls, etc. For this, we create a survey with 75 randomly chosen test set ECTs and their corresponding summaries generated by ECT-BPS and LED, our strongest baseline. Each survey form (please refer to an example $^{17}$ ) was divided into 5 sections. In each section, the participants were required to go through an entire ECT (Motley Fool link provided), and evaluate the two summaries (randomly placed, identity not revealed) on three quality metrics - factual correctness, relevance and coverage as defined below:
+
+- Factual Correctness: For each summary sentence, the task was to asses if it can be supported by the source ECT.
+- Relevance: For each summary sentence, the task was to asses if it captures pertinent information relative to the ECT.
+
+The final correctness/relevance score of the summary is then determined based on the percentage of sentences that are factually correct/relevant as follows: 5 (>80%), 4 (>60% & ≤ 80%), 3 (>40% & ≤ 60%), 2 (>20% & ≤ 40%), 1 (≤20%). It is to be noted here that factual correctness is an objective metric, whereas relevance is a subjective metric. For Coverage, the participants were instructed to assign a score to the overall summary (on a Likert scale of 1-5) based upon their impression about the amount/coverage of relevant content present in it.
+
+Participants were adequately remunerated for their involvement in the task. The summary of
+
+| Summary | Evaluation Scores |
| Correct | Relevant | Coverage |
| LED-Generated |
| q2 revenue rose 27 percent to $667 million. | ✓ | ✓ | |
| sees q3 adjusted earnings per share $12.80 to $13.90. | ✗ | ✗ | |
| qtrly adjusted net income per diluted share $3.15. | ✓ | ✓ | 1 |
| sees fy earnings per common share to be in range of $12 - $13.00. | ✗ | ✗ | |
| sees 2021 revenue $2.74 billion to $2.791 billion. | ✓ | ✓ | |
| ECT-BPS-Generated |
| sees q3 adjusted earnings per share $3.35 to $3.55. | ✓ | ✓ | |
| sees fy adjusted earnings per share $12.80 to $13.00. | ✗ | ✗ | |
| sees fy revenue $2.74 billion to $2.79 billion. | ✓ | ✓ | 3 |
| q2 revenue rose 27 percent to $667 million. | ✓ | ✓ | |
| q2 earnings per share $2.30. | ✓ | ✓ | |
+
+Table 5: Comparing the summaries generated by LED and ECT-BPS for a given ECT (details in Section 5.6). Parts marked in red are wrongly generated. ECT-BPS better preserves the correctness of generated numbers.
+
+results obtained from this survey are presented in Table 4. At a summary/sample level, respectively for $60\%$ (45/75) and $59\%$ (44/75) of the cases, the summaries generated by ECT-BPS were found to contain more number of factually correct and relevant sentences than the corresponding LED-generated summaries. For $16\%$ and $11\%$ of the cases respectively, the scores for correctness and relevance were the same for both models. Also, $64\%$ of the times, the participants found ECT-BPS-generated summaries to have a broader coverage. When we checked the results of individual experts, $70\%$ of the participants (7 out of 10) found ECT-BPS-generated summaries to be better with respect to correctness, and relevance. On the other hand, 8 out of 10 participants found ECT-BPS-generated summaries to have a broader coverage.
+
+The distribution of absolute scores assigned to the summaries are shown in Fig. 3 as a histogram plot. Here again we find that ECT-BPS-generated summaries are majorly scored $\geq 3$ across all three metrics, whereas the majority of LED summaries are scored $\leq 3$ . Overall, the survey results were found to be comprehensively in favor of ECT-BPS.
+
+# 5.6 Qualitative Analysis
+
+In Table 5, we qualitatively compare the summaries generated by LED and ECT-BPS corresponding to the earnings call transcript for FleetCor Technologies Inc Q2 2021. $^{18}$ The expert evaluation scores corresponding to this pair are also reported. We observe that LED wrongly produces a few monetary values which make the corresponding sentences factually incorrect. Whereas, ECT-BPS maintains the correctness of generated numbers. This may
+
+be attributed to our strategy of replacing numbers with placeholders while training the Paraphrasing module (please refer to Section 4.2 for details). ECT-BPS however makes a factual error in the second sentence where it misses the word adjusted. In the finance domain adjusted earnings per share is different from earnings per share. These nuances necessitate further research on the ECTSum corpus, and financial summarization in general.
+
+# 6 Conclusion
+
+To our knowledge, ECTSum is the first large-scale long document summarization dataset in the finance domain. Our documents consist of free-form lengthy transcripts of company earnings calls. Target summaries consist of a set of telegram-style bullet points derived from corresponding Reuters articles that cover the calls. Drawing observations from the nature of source transcripts and target summaries, we also propose a simple, yet effective extract-then-paraphrase approach, ECT-BPS, that establishes state-of-the-art performance over strong summarization baselines across several metrics.
+
+ECTSum is an extremely challenging dataset given the high document-to-summary compression ratio. Moreover, it is highly extendable as future earnings calls are covered by media houses, such as Reuters, BusinessWire, etc. Finally, it is a very specialized one which would otherwise have costed a lot of time and resources if one had to hire experts to write the reference summaries. The mere observation that these summaries are created by (expert) analysts and can be leveraged automatically is a major milestone of the paper. We believe our contributions to the dataset and methodology will attract future research in the finance domain.
+
+# Limitations
+
+In this work, we have restricted ourselves to collecting reference summaries, corresponding to an earnings call transcript, from a single data source, Reuters, in our case. Articles summarizing the earnings calls are however published on other media websites as well, for example $CNBC$ . In future, we can enrich both the quantity as well as the quality of the dataset, in a scalable manner, by collecting more than one articles from multiple sources thereby resulting in multiple reference summaries corresponding to a single source document.
+
+Despite performing substantially better than strong baseline summarization algorithms, our proposed model ECT-BPS is still a pipeline approach. To our advantage, the improvement in scores over the baselines probably overcomes the increase in the number of model parameters by following an extract-then-paraphrase approach. In future, we would definitely like to address this shortcoming by designing a unified model.
+
+The factual consistency scores obtained using Summa $C_{CONV}$ are generally low across all methods. This gives us ample scope of improvement which in turn calls for further investigation into the nature of factual errors being made by various approaches. A deeper analysis of dataset nuances can also lead us to interesting ideas to improve performance.
+
+# Ethics Statement
+
+Given the impact of our proposed contributions on the financial community in particular, and wider research community in general, our dataset and codes have been publicly released. Our document-summary pairs are derived from public/open domain. Still, we may ask users, intending to access our data, to provide a self declaration that the data is to be used solely for research purposes.
+
+# References
+
+Reinald Kim Amplayo, Stefanos Angelidis, and Mirella Lapata. 2021. Aspect-controllable opinion summarization. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 6578-6593, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Iz Beltagy, Matthew E. Peters, and Arman Cohan. 2020. Longformer: The long-document transformer.
+
+Robert M. Bowen, Angela K. Davis, and Dawn A. Matsumoto. 2002. Do conference calls affect analysts' forecasts? The Accounting Review, 77(2):285-316.
+Eddy Cardinaels, Stephan Hollander, and Brian J. White. 2018. Automatic summaries of earnings releases: Attributes and effects on investors' judgments.
+Daniel Cer, Yinfei Yang, Sheng-yi Kong, Nan Hua, Nicole Limtiaco, Rhomni St. John, Noah Constant, Mario Guajardo-Cespedes, Steve Yuan, Chris Tar, Brian Strope, and Ray Kurzweil. 2018. Universal sentence encoder for English. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 169-174, Brussels, Belgium. Association for Computational Linguistics.
+Arman Cohan, Franck Dernoncourt, Doo Soon Kim, Trung Bui, Seokhwan Kim, Walter Chang, and Nazli Goharian. 2018. A discourse-aware attention model for abstractive summarization of long documents. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 615-621, New Orleans, Louisiana. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Mahmoud El-Haj, Ahmed AbuRa'ed, Marina Littvak, Nikiforos Pittaras, and George Giannakopoulos. 2020. The financial narrative summarisation shared task (FNS 2020). In Proceedings of the 1st Joint Workshop on Financial Narrative Processing and MultiLing Financial Summarisation, pages 1-12, Barcelona, Spain (Online). COLING.
+Günes Erkan and Dragomir R. Radev. 2004. Lexrank: Graph-based lexical centrality as salience in text summarization. J. Artif. Int. Res., 22(1):457-479.
+Dan Givoly and Josef Lakonishok. 1980. Financial analysts' forecasts of earnings: Their value to investors. Journal of Banking & Finance, 4(3):221-233.
+Max Grusky, Mor Naaman, and Yoav Artzi. 2018. Newsroom: A dataset of 1.3 million summaries with diverse extractive strategies. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 708-719, New Orleans, Louisiana. Association for Computational Linguistics.
+
+Mandy Guo, Joshua Ainslie, David Uthus, Santiago Ontanon, Jianmo Ni, Yun-Hsuan Sung, and Yinfei Yang. 2021. Longt5: Efficient text-to-text transformer for long sequences. arXiv preprint arXiv:2112.07916.
+Zhanying He, Chun Chen, Jiajun Bu, Can Wang, Lijun Zhang, Deng Cai, and Xiaofei He. 2012. Document summarization based on data reconstruction. In Proceedings of the Twenty-Sixth AAAI Conference on Artificial Intelligence, AAAI'12, page 620-626. AAAI Press.
+Dandan Huang, Leyang Cui, Sen Yang, Guangsheng Bao, Kun Wang, Jun Xie, and Yue Zhang. 2020. What have we achieved on text summarization? In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 446-469, Online. Association for Computational Linguistics.
+Luyang Huang, Shuyang Cao, Nikolaus Parulian, Heng Ji, and Lu Wang. 2021. Efficient attentions for long document summarization. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 1419-1436, Online. Association for Computational Linguistics.
+Katherine Keith and Amanda Stent. 2019. Modeling financial analysts' decision making via the pragmatics and semantics of earnings calls. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 493-503, Florence, Italy. Association for Computational Linguistics.
+Daniel King, Zejiang Shen, Nishant Subramani, Daniel S. Weld, Iz Beltagy, and Doug Downey. 2022. Don't say what you don't know: Improving the consistency of abstractive summarization by constraining beam search.
+Anastassia Kornilova and Vladimir Eidelman. 2019. *BillSum: A corpus for automatic summarization of US legislation*. In *Proceedings of the 2nd Workshop on New Frontiers in Summarization*, pages 48-56, Hong Kong, China. Association for Computational Linguistics.
+Wojciech Krysciński, Nazneen Rajani, Divyansh Agarwal, Caiming Xiong, and Dragomir Radev. 2021. Booksum: A collection of datasets for long-form narrative summarization. arXiv preprint arXiv:2105.08209.
+Philippe Laban, Tobias Schnabel, Paul N. Bennett, and Marti A. Hearst. 2022. SummaC: Re-Visiting NLI-based Models for Inconsistency Detection in Summarization. Transactions of the Association for Computational Linguistics, 10:163-177.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: Denoising sequence-to-sequence pre-training
+
+for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880, Online. Association for Computational Linguistics.
+Chin-Yew Lin. 2004. ROUGE: A package for automatic evaluation of summaries. In Text Summarization Branches Out, pages 74-81, Barcelona, Spain. Association for Computational Linguistics.
+Yang Liu and Mirella Lapata. 2019. Text summarization with pretrained encoders. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3730-3740, Hong Kong, China. Association for Computational Linguistics.
+Rajdeep Mukherjee, Hari Chandana Peruri, Uppada Vishnu, Pawan Goyal, Sourangshu Bhattacharya, and Niloy Ganguly. 2020. Read what you need: Controllable aspect-based opinion summarization of tourist reviews. In Proceedings of the 43rd International ACM SIGIR Conference on Research and Development in Information Retrieval, SIGIR '20, page 1825-1828, New York, NY, USA. Association for Computing Machinery.
+Rajdeep Mukherjee, Uppada Vishnu, Hari Chandana Peruri, Sourangshu Bhattacharya, Koustav Rudra, Pawan Goyal, and Niloy Ganguly. 2022. Mtlts: A multi-task framework to obtain trustworthy summaries from crisis-related microblogs. In Proceedings of the Fifteenth ACM International Conference on Web Search and Data Mining, WSDM '22, page 755-763, New York, NY, USA. Association for Computing Machinery.
+Ramesh Nallapati, Feifei Zhai, and Bowen Zhou. 2017. Summarunner: A recurrent neural network based sequence model for extractive summarization of documents. In Proceedings of the Thirty-First AAAI Conference on Artificial Intelligence, February 4-9, 2017, San Francisco, California, USA, pages 3075-3081. AAAI Press.
+Ramesh Nallapati, Bowen Zhou, Cicero dos Santos, Caglar Gulcehre, and Bing Xiang. 2016. Abstractive text summarization using sequence-to-sequence RNNs and beyond. In Proceedings of The 20th SIGNLL Conference on Computational Natural Language Learning, pages 280-290, Berlin, Germany. Association for Computational Linguistics.
+Shashi Narayan, Shay B. Cohen, and Mirella Lapata. 2018. Don't give me the details, just the summary! topic-aware convolutional neural networks for extreme summarization. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 1797-1807, Brussels, Belgium. Association for Computational Linguistics.
+Tatiana Passali, Alexios Gidiotis, Efstathios Chatzikyriakidis, and Grigorios Tsoumakas. 2021. Towards
+
+human-centered summarization: A case study on financial news. In Proceedings of the First Workshop on Bridging Human-Computer Interaction and Natural Language Processing, pages 21-27, Online. Association for Computational Linguistics.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140):1-67.
+Marilyn Johnson Richard Frankel and Douglas J. Skinner. 1999. An empirical examination of conference calls as a voluntary disclosure medium. Journal of Accounting Research, 37(1):133-150.
+Eva Sharma, Chen Li, and Lu Wang. 2019. BIGPATENT: A large-scale dataset for abstractive and coherent summarization. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 2204-2213, Florence, Italy. Association for Computational Linguistics.
+Abhay Shukla, Paheli Bhattacharya, Soham Poddar, Rajdeep Mukherjee, Kripabandhu Ghosh, Pawan Goyal, and Saptarshi Ghosh. 2022. Legal case document summarization: Extractive and abstractive methods and their evaluation. arXiv preprint arXiv:2210.07544.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+Yi Yang, Mark Christopher Siy UY, and Allen Huang. 2020. Finbert: A pretrained language model for financial communications.
+Manzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie, Chris Alberti, Santiago Otanon, Philip Pham, Anirudh Ravula, Qifan Wang, Li Yang, and Amr Ahmed. 2020. Big bird: Transformers for longer sequences. In Advances in Neural Information Processing Systems, volume 33, pages 17283-17297. Curran Associates, Inc.
+Jingqing Zhang, Yao Zhao, Mohammad Saleh, and Peter J. Liu. 2019. Pegasus: Pre-training with extracted gap-sentences for abstractive summarization.
+Tianyi Zhang, Varsha Kishore, Felix Wu, Kilian Q. Weinberger, and Yoav Artzi. 2020. *Bertscore: Evaluating text generation with BERT*. In 8th International Conference on Learning Representations, ICLR 2020,
+
+Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Zheng Zhao, Shay B. Cohen, and Bonnie Webber. 2020. Reducing quantity hallucinations in abstractive summarization. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 2237-2249, Online. Association for Computational Linguistics.
+Hao Zheng and Mirella Lapata. 2019. Sentence centrality revisited for unsupervised summarization. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6236-6247, Florence, Italy. Association for Computational Linguistics.
+Ming Zhong, Pengfei Liu, Yiran Chen, Danqing Wang, Xipeng Qiu, and Xuanjing Huang. 2020. Extractive summarization as text matching. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6197-6208, Online. Association for Computational Linguistics.
+
+# A Appendix
+
+# A.1 Creating Document-Summary Pairs
+
+In order to automate the process of pairing an ECT with its corresponding Reuters article, first we made sure that the article mentions the same company code as the ECT, and second, it is posted either on the same day or at max one day after the earnings event. In some cases, we found multiple articles for the same ECT. Upon manual inspection, we classified them into two broad categories: (1) (multiple) articles summarizing the same earnings call, but in parts; (2) articles covering news not directly related to the earnings call. We took the articles of the first category, and merged their distinct sentences into one summary file. After obtaining the automatically-matched pairs, the authors manually and independently cross-checked 200 randomly selected ECT(documents)-Reuters(summary) pairs. We found all the pairs to be properly matched. The process thus ensures accuracy at the cost of obtaining a smaller amount of (sanitized) data. The dataset can however be easily extended as future earnings call events are covered by media houses, such as Reuters, NBC, and BusinessWire. We also propose to release subsequent versions of ECTSum on our Github repository.
+
+# A.2 Baselines
+
+We evaluate and compare the summarization performance of a wide range of representative algorithms on the ECTSum corpus as briefed below:
+
+# A.2.1 Unsupervised Approaches
+
+- LexRank (Erkan and Radev, 2004) uses a graph-based lexical centrality metric to score and summarize the document sentences.
+- DSDR (He et al., 2012) produces a summary consisting of sentences that can best reconstruct the original document.
+- PacSum (Zheng and Lapata, 2019) is a graph-based algorithm that redefines sentence centrality by taking into account their relative positions in the document to build a directed graph to be used for document summarization.
+
+# A.2.2 Extractive Approaches
+
+- SummaRuNNer (Nallapati et al., 2017): Vanilla version of our Extractive Module (Section 4.1).
+
+- BertSumEXT (Liu and Lapata, 2019) takes pretrained BERT (Devlin et al., 2019) as the sentence encoder and an additional Transformer as the document encoder. A classifier on sentence representations is used for sentence selection.
+- MatchSum (Zhong et al., 2020) generates a set of candidate summaries from the output of BertSumEXT. The candidate that matches best with the document is considered as the final summary.
+
+# A.2.3 Abstractive Approaches
+
+- BART (Lewis et al., 2020) introduces a denoising autoencoder for pre-training sequence to sequence tasks including summarization.
+- Pegasus (Zhang et al., 2019) introduces a novel pre-training strategy, Gap Sentence Generation, especially suitable for abstractive summarization.
+- T5 (Raffel et al., 2020) systematically applies transfer learning techniques for seq-to-seq generation tasks, including summarization.
+
+# A.2.4 Long Document Summarizers
+
+- BigBird (Zaheer et al., 2020) applies sparse, global, and random attentions to overcome the quadratic dependency of BERT while preserving the properties of full-attention models. Consequently, it can handle longer context.
+- LongT5 (Guo et al., 2021) extends the original T5 encoder with Transient Global attentions to handle long inputs. The model is pre-trained using the PEGASUS strategy.
+- Longformer Encoder Decoder (LED) (Beltagy et al., 2020) is a Longformer variant for supporting long document generative seq-to-seq tasks. It uses an attention mechanism that scales linearly with sequence length, making it easy to process documents of thousands of tokens or longer.
+
+# A.3 Evaluation Metrics
+
+For evaluating the content quality and factual correctness of the model-generated summaries, we consider the following evaluation metrics:
+
+- ROUGE (Lin, 2004) measures the textual overlap (n-grams, word sequences) between the generated summary and the reference summary. In this work, we report the F-1 scores corresponding to ROUGE-1, ROUGE-2, and ROUGE-L.
+
+- BERTScore (Zhang et al., 2020) aligns the generated and target summaries on a token-level and uses BERT to compute their similarity scores. It correlates better with human judgements. We installed the latest version (0.3.11) of BERTScore from its official implementation $^{20}$ , and calculated the scores with the recommended NLI model MICROSOFT/DEBERTA-XLARGE-MNLI.
+- Num-Prec.: Accurate reporting of facts and monetary figures is crucial in the financial domain. Extractive summaries are always expected to contain values that appear in the source text. However, quantity/numeral hallucination is a known problem in abstractive summaries, which prior works (Zhao et al., 2020) have attempted to reduce. Here, we define Num-Prec. as the fraction of numerals/values in the model-generated summaries that are consistent with the source text. We use this metric to specifically evaluate the precision/correctness with which abstractive summarizers generate values.
+- SummaCCONV (Laban et al., 2022) is a recently proposed NLI-based factual inconsistency detection model based on aggregation of sentence-level entailment scores for each pair of input document and summary sentences. We used the official implementation21 of SummaC to obtain the scores for all model-generated summaries.
\ No newline at end of file
diff --git a/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/images.zip b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..512fdf2321617ca9a9c11bcceeea9306294e695f
--- /dev/null
+++ b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f871d19a9a71427e84d4c817cbc98f020b50e445d53fc51023677580c4b031ee
+size 382064
diff --git a/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/layout.json b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..825e283cd6bd44712d2a5c25d0f9c988681443b7
--- /dev/null
+++ b/ectsumanewbenchmarkdatasetforbulletpointsummarizationoflongearningscalltranscripts/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9f2e1af448e1a5f7c0f7166b9804237183d623cf6fe9dbcdd7a6792f12141b75
+size 421661
diff --git a/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_content_list.json b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..954bf9ccc1567c40e91e6420ff31149f0d0f78e7
--- /dev/null
+++ b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0c6b33d177f7fb90285e913025fa5dfb77aa8f54a7412dc59fd561a2e3bb2b2f
+size 89207
diff --git a/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_model.json b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..38a87ac0ddd4f7e884c938ef46121efdf37aa4fb
--- /dev/null
+++ b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f3bf16ffcbcdade79d00cdcd990415c3b5e31a57d4dc8a75c305be7be0ad1b78
+size 108583
diff --git a/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_origin.pdf b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..d776be3abbcc8d3e3631997a6eba20d4a565e2cb
--- /dev/null
+++ b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/84907aa8-375d-4d7e-89ba-3924a8098145_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bb99e0591493561921f5faec1c099b6e8f872566e68a28221483c41fab3418d9
+size 1395609
diff --git a/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/full.md b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..134c6e2b6b605f0101fad75c7182e3e77da247ec
--- /dev/null
+++ b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/full.md
@@ -0,0 +1,364 @@
+# EdgeFormer: A Parameter-Efficient Transformer for On-Device Seq2seq Generation
+
+Tao Ge Si-Qing Chen Furu Wei
+
+Microsoft
+
+{tage, sqchen, fuwei}@microsoft.com
+
+# Abstract
+
+We introduce EDGEFORMER - a parameter-efficient Transformer for on-device seq2seq generation under the strict computation and memory constraints. Compared with the previous parameter-efficient Transformers, EDGEFORMER applies two novel principles for cost-effective parameterization, allowing it to perform better given the same parameter budget; moreover, EDGEFORMER is further enhanced by layer adaptation innovation that is proposed for improving the network with shared layers. Extensive experiments show EDGEFORMER can effectively outperform previous parameter-efficient Transformer baselines and achieve competitive results under both the computation and memory constraints. Given the promising results, we release $\mathrm{EDGELM}^1$ - the pretrained version of EDGEFORMER, which is the first publicly available pretrained on-device seq2seq model that can be easily fine-tuned for seq2seq tasks with strong results, facilitating on-device seq2seq generation in practice.
+
+# 1 Introduction
+
+On-device modeling draws increasing attention for its unique advantages (Dhar et al., 2019). On the other hand, strict resource constraints prevent many neural networks performing well in the on-device setting. In Natural Language Processing (NLP), on-device sequence-to-sequence (seq2seq) generation remains challenging, especially for the Transformer (Vaswani et al., 2017) under strict resource constraints in both computation and memory.
+
+To customize the Transformer for seq2seq tasks in the on-device setting, we propose EDGEFORMER - a novel parameter-efficient Transformer of the encoder-decoder architecture. EDGEFORMER is structurally similar to the standard Transformer with a deep encoder and shallow decoder, but with a modification that it uses an in
+
+
+(a)
+
+
+(b)
+Figure 1: (a) Vanilla Transformer decoder layer in which $d_{\mathrm{ffn}} > d$ ; (b) Interleaved Transformer decoder layer with shared lightweight FFNs in which $d_{\mathrm{ffn}} < d$ .
+
+terleaved decoder with shared lightweight feedforward networks, as shown in Figure 1. The modified decoder architecture allows EDGEFORMER to apply two novel principles that we propose for cost-effective parameterization: 1) encoder-favored parameterization that suggests we parameterize the encoder using as many parameters as possible; 2) load-balanced parameterization that suggests we balance the load of model parameters to avoid them being either underused or overused in a neural network with shared parameterization.
+
+In addition to cost-effective parameterization, EDGEFORMER proposes and applies layer adaptation to further improve the model with tied layers, as Figure 2 shows. Inspired by parameter-efficient task transfer, we investigate 3 efficient layer adaptation approaches for improving the performance with negligible cost. We show EDGEFORMER (with fewer than 10 million model parameters) largely outperforms the strong UNIVERSAL TRANSFORMER baselines in the on-device setting with competitive results, and the int8-quantized EDGEFORMER can perform high-quality on-device seq2seq generation within around 100ms latency (20-30 sequence length on average) using two mid-to-high-end CPU cores and less than 50MB RAM.
+
+The contributions of this work are three-fold:
+
+- This paper is one of the earliest work that formally studies on-device seq2seq generation by discussing its challenges and defining
+
+
+(a)
+
+
+(b)
+
+
+(c)
+Figure 2: (a) Encoder layers with shared weights (the same color) without layer adaptation: the tied weights undermine the specialities of encoder layers to process their specific inputs; (b) Bias-based Layer Adaptation (Bias-LA) employs free bias terms to adapt layers with tied weights to fit their specific roles well; (c) Adapter-LA uses a layer-specific LoRA adaptation block with rank $r < d$ for layer adaptation; (d) Prefix-LA uses $L$ layer-specific tokens (i.e., learnable parameters) as the prefix (dotted square) to adapt the $m$ th layer.
+
+
+(d)
+
+a practical setting with appropriate resource constraints for the evaluation.
+
+- We propose EDGEFORMER, a parameter-efficient Transformer with novel cost-effective parameterization and layer adaptation, achieving the state-of-the-art result in the on-device seq2seq generation setting under strict computing and memory resource constraints.
+- We introduce and release EDGELM (the pretrained EDGEMENTR) - the first publicly available pretrained on-device seq2seq model that can be easily fine-tuned for seq2seq tasks with strong results, which can largely reduce the effort for delivering a powerful on-device seq2seq model in practice.
+
+# 2 Background: Transformer
+
+# 2.1 Architecture
+
+The Transformer follows the encoder-decoder architecture. The Transformer encoder consists of a stack of encoder layers, each of which has a self-attention module parameterized by projection matrices for the query, key, value and output: $[W^Q, W^K, W^V, W^O]$ whose shapes are all $d \times d$ , followed² by a feed-forward network (FFN) parameterized by $W^{f1} \in \mathbb{R}^{d \times d_{ffn}}$ and $W^{f2} \in \mathbb{R}^{d_{ffn} \times d}$ .
+
+The Transformer decoder consists of a stack of decoder layers whose architecture is similar to an encoder layer except for an additional cross attention module between self-attention and FFN.
+
+In summary, we understand that the main parameters in an encoder layer $i$ are:
+
+$$
+\Phi_ {e _ {i}} = [ W _ {e _ {i}} ^ {\{Q, K, V, O \}}, W _ {e _ {i}} ^ {f 1}, W _ {e _ {i}} ^ {f 2} ]
+$$
+
+$\left|\Phi_{e_i}\right| = 4d^2 + 2d \times d_{\mathrm{encffn}}$ . For a decoder layer $j$ , its main parameters are:
+
+$$
+\pmb {\Phi} _ {d _ {j}} = [ W _ {d _ {j}} ^ {\{Q, K, V, O \}}, W _ {d _ {j}} ^ {\{\mathcal {Q}, \mathcal {K}, \mathcal {V}, \mathcal {O} \}}, W _ {d _ {j}} ^ {f 1}, W _ {d _ {j}} ^ {f 2} ]
+$$
+
+where $W_{d_j}^{\{\mathcal{Q},\mathcal{K},\mathcal{V},\mathcal{O}\}}$ is the cross-attention module. $|\Phi_{d_j}| = 8d^2 +2d\times d_{\mathrm{decffn}}.$
+
+# 2.2 Parameterization: Full vs Shared
+
+Full Parameterization Full parameterization is a common parameterization approach for Transformer, meaning that each model parameter (excluding embedding) is independent without being shared by multiple modules in the network. In a forward pass, each parameter is used only once. Full parameterization allows parameters to be flexible to fit their roles well during model training.
+
+Shared Parameterization Despite the advantages of full parameterization, it is criticized to use large numbers of parameters inefficiently, motivating shared parameterization where multiple modules in a network share parameters. For a model with shared parameterization (e.g., ALBERT), each model parameter is exploited more than once in a forward pass. The efficient parameterization can lead to a better result given the same parameterization budget, despite slowing down inference. On the other hand, given a fixed architecture (i.e., the same network depth and width), shared parameterization usually underperforms full parameterization because it has much fewer free model parameters.
+
+| Layer | Module | #params | d=512
+#params / FLOPS | d=384
+#params / FLOPS | d=768
+#params / FLOPS |
| encoder layer | self-attn | 4d2 | 3.15M / 95.4M | 1.77M / 53.9M | 7.08M / 214M |
| FFN | 8d2 |
| vanilla decoder layer | self-attn | 4d2 | | | |
| cross-attn | 4d2 | 4.20M / 128M | 2.37M / 72.3M | 9.45M / 286M |
| FFN | 8d2 |
| interleaved decoder layer | self-attn | 4d2 | | | |
| cross-attn | 4d2 | 2.23M / 72.9M | 1.25M / 41.3M | 5.01M / 162M |
| 2 shared lightweight FFNs | d2/2 |
| Model | d=512
+#params / FLOPS | d=384
+#params / FLOPS | d=768
+#params / FLOPS |
| 6+6 Transformer (full parameterization) | 44M / 1.84G | 25M / 1.13G | 99M / 3.76G |
| 12+2 Transformer (full parameterization) | 46M / 1.90G | 26M / 1.17G | 104M / 3.89G |
| 12+2 UNIVERSAL TRANSFORMER (shared parameterization) | 7.4M / 1.90G | 4.1M / 1.17G | 16.5M / 3.89G |
| EdgeFormer (Ours) | 8.6M / 1.79G | 4.8M / 1.11G | 19.2M / 3.65G |
+
+Table 1: Top: #params and FLOPS for Transformer layers. For the encoder and vanilla decoder layer, $d_{\mathrm{ffn}} = 4d$ ; while for the interleaved decoder layer, $d_{\mathrm{ffn}} = d / 4$ . Bottom: #params and FLOPS of whole models, where #params excludes embedding lookup, and FLOPS is measured on a sample with src/tgt length of 30 and 32K vocabulary.
+
+# 3 Constraints for On-device Seq2seq
+
+Computation On-device computer vision (CV) models tend to use 1G FLOPS (0.5G MACS) as a constraint, which is directly followed by previous work on on-device translation (Wu et al., 2020). In our work, however, we propose to relax the FLOPS constraint for typical seq2seq tasks to 2G FLOPS (1G MACS) because the latency requirement for on-device seq2seq generation is not so rigid as CV tasks and it is uncommon for an on-device seq2seq model to handle too many concurrent requests in practice. The relaxed constraint allows better prediction quality that strongly correlates with user experience for seq2seq tasks, but still ensure the CPU on edge devices to process tens of sentences per second, which is more than sufficient for an on-device seq2seq model. In addition to FLOPS that is a theoretical hardware-independent measurement for computational cost, we also require the runtime latency for an input sentence (typically $20 \sim 30$ tokens on average) to be within around 100ms using two mid-to-high-end CPU cores.
+
+Memory In contrast to deploying a model on a cloud server without caring about memory cost much, there is a very strict memory constraint for an on-device model in practice, because a user's edge device (e.g., PC) is not only for model hosting; instead, it usually runs many other (background) apps and programs at the same time besides the model. To ensure moderate memory cost, we limit the number of model parameters (excluding word
+
+embedding lookup table) up to 10 million, following previous work (Wu et al., 2020), and require the runtime memory footprint to be less than 50MB.
+
+# 4 EdgeFormer
+
+# 4.1 Architecture
+
+The biggest challenge for an on-device seq2seq model is regarding the model size and memory cost. As shown in Table 1, the number of parameters of a standard Transformer-base model ( $d = 512$ ) is about 45 million (excluding the embedding parameters), which is far beyond the parameterization budget (10 million) and unavoidably leads to massive memory cost despite acceptable FLOPS.
+
+EDGEFORMER is proposed to address the challenge. Instead of disruptive architectural changes as previous research (Wu et al., 2020; Mehta et al., 2020; Panahi et al., 2021), EDGEFORMER's architecture basically follows the standard Transformer consisting of a 12-layer encoder and 2-layer decoder, which is efficient in decoding. We mainly discuss the model with $d = 512$ in this paper since it can achieve good performance in the on-device setting as long as it can be appropriately parameterized. The minor architectural modification we propose for EDGEFORMER is using an interleaved
+
+
+(a)
+
+
+(b)
+Figure 3: (a) Performance of $6 + 6$ Transformer ( $d = 512$ ) on the newstest2013 English-German (En-De) translation dataset (dev set): densely parameterizing the decoder is uneconomical and much less beneficial than parameterizing the encoder; (b) Comparison of $\mathrm{x} + 2$ Transformer with full-/shared-parameterized $x$ encoder layers on newstest2013 En-De dataset: when $x > 6$ , the performance of the Transformer with shared parameterization only improves marginally even if $x$ continues to increase.
+
+decoder where attention modules are interleaved with shared lightweight $^5$ FFNs ( $d_{\mathrm{decffn}} < d$ ; in this work, $d_{\mathrm{decffn}} = d / 4$ ) in each decoder layer (shown in Figure 1). The modification is helpful for cost-effective parameterization (Section 4.2):
+
+- The interleaved structure makes the architecture of encoder and decoder layers consistent (Ma et al., 2021), facilitating shared parameterization of attention modules throughout the encoder and decoder.
+- As shown in Table 1, the lightweight FFNs that interleave attention modules in the decoder reduce FLOPS and save a large number of parameters for decoder FFNs' parameterization that is very uneconomical.
+
+# 4.2 Cost-effective Parameterization
+
+Due to the tight parameterization budget (i.e., 10 million), EDGEFORMER cannot be fully parameterized as in the standard way; instead, it has to adopt shared parameterization.
+
+As a strong baseline for shared parameterization, UNIVERSAL TRANSFORMER lets all its $M$ encoder layers share 1 group of encoder layer parameters and all its $N$ decoder layers share 1 group of decoder layer parameters:
+
+$$
+\Phi_ {e _ {1}} \stackrel {\text {t i e d}} {=} \Phi_ {e _ {2}} \stackrel {\text {t i e d}} {=} \dots \stackrel {\text {t i e d}} {=} \Phi_ {e _ {M}}
+$$
+
+$$
+\boldsymbol {\Phi} _ {d _ {1}} \stackrel {{\text {t i e d}}} {{=}} \boldsymbol {\Phi} _ {d _ {2}} \stackrel {{\text {t i e d}}} {{=}} \dots \stackrel {{\text {t i e d}}} {{=}} \boldsymbol {\Phi} _ {d _ {N}}
+$$
+
+Although UNIVERSAL TRANSFORMER is a popular solution to shared parameterization, it is still not cost-effective for two reasons:
+
+First, UNIVERSAL TRANSFORMER uses (over) half of total parameters to parameterize the decoder, which is uneconomical. As shown in Figure 3a, given a fixed architecture (6+6 Transformer, $d = 512$ ), densely parameterizing the decoder results in much less performance gain than parameterizing the encoder. This suggests we use as many parameters as possible to parameterize the encoder for the performance.
+
+Second, UNIVERSAL TRANSFORMER does not consider load balance of model parameters, which was a rarely discussed problem until the recent emergence of Mixture-of-Expert models (Fedus et al., 2021). For the Transformers with a deep encoder and shallow decoder, UNIVERSAL TRANSFORMER's parameterization method will overburden parameters in the encoder but underutilize parameters in the decoder. For example, for a $12 + 2$ UNIVERSAL TRANSFORMER, a parameter in the encoder is used 12 times, while a parameter in the decoder is used only twice in a forward pass. As shown in Figure 3b, moderately reusing parameters (e.g., when $x \leq 4$ ) helps better utilize the parameters, resulting in significant performance gain without increasing parameters. However, as the shared parameters are overused (when $x > 6$ ), the performance gain will become marginal, which is intuitive because a parameter's capability is limited. This suggests we balance the load of parameters to
+
+avoid them being either overused or underused.
+
+Based on the above insights, we parameterize EDGEFORMER in the following two novel principles for cost-effective parameterization:
+
+Encoder-favored Parameterization For EDGE-FORMER, we parameterize its encoder using as many parameters as possible: except a small number of parameters $(d^2 / 2)$ for all lightweight FFNs in the decoder, we use almost all parameters in our budget to parameterize the encoder. For attention modules in the decoder, we let them reuse (i.e., share) parameters with the attention modules in the encoder since attention modules in both the encoder and decoder work in the same mechanism and can be effectively shared (Dong et al., 2019). Thanks to the interleaved decoder architecture that makes the structure of encoder and decoder layers consistent, we let the self-attention module in a decoder layer share parameters with its corresponding odd layer in the encoder, and let its cross-attention module share with the corresponding even layer in the encoder, inspired by Ma et al. (2021):
+
+$$
+\begin{array}{l} W _ {d _ {j}} ^ {[ Q, K, V, O ]} \stackrel {\text {t i e d}} {=} W _ {e _ {2 j - 1}} ^ {[ Q, K, V, O ]} (1 \leq j \leq 2) \\ W _ {d _ {j}} ^ {[ Q, \mathcal {K}, \mathcal {V}, \mathcal {O} ]} \stackrel {\text {t i e d}} {=} W _ {e _ {2 j}} ^ {[ Q, K, V, O ]} (1 \leq j \leq 2) \\ \end{array}
+$$
+
+Load-balanced Parameterization We try parameterizing EDGEFORMER with a balanced load for each model parameter so that each parameter could be as equally exploited as possible in a forward pass. Given the parameterization budget and the load balance principle, we create 2 groups of encoder FFN parameters equally shared by all encoder layers, 1 group of decoder FFN parameters is shared by light FFNs in the decoder, and 4 groups of attention parameters are shared throughout the encoder and decoder. Except for parameters in the encoder FFNs that are used 6 times, other parameters are all used 4 times in a forward pass, resulting in a load balanced parameterization:
+
+$$
+W _ {e _ {i}} ^ {[ Q, K, V, O ]} \stackrel {\mathrm {t i e d}} {=} W _ {e _ {i + 4}} ^ {[ Q, K, V, O ]} (1 \leq i < 9)
+$$
+
+$$
+W _ {e _ {i}} ^ {[ f _ {1}, f _ {2} ]} \stackrel {\text {t i e d}} {=} W _ {e _ {i + 2}} ^ {[ f _ {1}, f _ {2} ]} (1 \leq i < 1 1)
+$$
+
+$$
+W _ {d _ {j}} ^ {[ f _ {1}, f _ {2} ]} \stackrel {\text {t i e d}} {=} W _ {d _ {1}} ^ {[ f _ {1}, f _ {2} ]} (1 \leq j \leq 2)
+$$
+
+# 4.3 Layer Adaptation
+
+Shared parameterization causes layers with tied weights to become less specialized, as discussed in Section 1. To allow tied layers to be better adapted
+
+to their corresponding roles, we propose layer adaptation to further enhance EDGEFORMER. Inspired by parameter-efficient task transfer methods, we investigate three efficient layer adaption approaches:
+
+Bias-based Layer Adaptation (Bias-LA) Inspired by BitFit (Ben Zaken et al., 2021) fine-tuning with only bias terms, we untie all bias terms of each layer and use them to specialize the layers with tied weights, as shown in Figure 2(b). As BitFit, bias-based layer adaptation introduces very few additional parameters without inference overhead.
+
+Adapter-based Layer Adaptation (Adapter-LA) Adapter-based approaches (Houlsby et al., 2019) introduce adapter modules for NLP task transfer without full fine-tuning. We borrow this idea for layer adaptation by introducing an independent adapter module for each layer. Specifically, we adopt the recently proposed LoRA (Hu et al., 2021) as our layer adapter, as Figure 2(c) shows. In our experiments, we apply the layer adapter to $W^{Q}$ and $W^{V}$ , as the original paper of LoRA suggests.
+
+Prefix-based Layer Adaptation (Prefix-LA) Inspired by recent work (Li & Liang, 2021; Lester et al., 2021) using a prefix/prompt for task transfer, we introduce $L$ tokens with learnable parameters as a specific prefix for each layer to adapt layers with tied weights, as shown in Figure 2(d). The prefixes are only used for keys and values in attention modules, which will not introduce much inference overhead as long as $L$ is moderately set.
+
+Following the encoder-favored principle in Section 4.2, we only apply LA to encoder layers.
+
+# 5 Experiments
+
+# 5.1 Experimental Setting
+
+We mainly evaluate our approach in Machine Translation (MT). We select the most popular MT benchmark – WMT14 English-German (En-De) translation task, which is also a touchstone for seq2seq evaluation, as our main test bed. To compare with previous work, we also evaluate WMT14 English-French (En-Fr) translation. We follow the standard way to train and evaluate evaluate WMT14 En-De and En-Fr. As Ott et al. (2018), we use a joint source-target dictionary of 32K Byte Pair Encoding (BPE) for En-De, and 40K BPE for En-Fr. We mainly use sacreBLEU (Post, 2018) for evaluation.
+
+We select UNIVERSAL TRANSFORMER which is the most popular and a strong baseline of parameter
+
+| Model | #Params | FLOPS | sacreBLEU |
| Teacher | 176M | 6.7G | 29.3 |
| 6+6 Transformer (full enc, full dec) | 44M | 1.8G | 28.5 |
| 6+6 Transformer (full enc, shared dec) | 23M | 1.8G | 28.2 |
| 6+6 Transformer (full dec, shared enc) | 28M | 1.8G | 27.3 |
| 12+2 Transformer (full enc, full dec) | 46M | 1.9G | 28.5 |
| 12+2 Transformer (full enc, shared dec) | 42M | 1.9G | 28.4 |
| 12+2 Transformer (full dec, shared enc) | 12M | 1.9G | 27.2 |
| 12+2 UT | 7.4M | 1.9G | 27.0 |
| 12+2 UT (\( d_{\text{ffn}} = 2560 \)) | 8.5M | 2.1G | 27.2 |
| 12+2 UT (\( d_{\text{encffn}} = 3072 \))1 | 8.5M | 2.3G | 27.4 |
| 12+2 UT (\( d_{\text{decffn}} = 3072 \)) | 8.5M | 2.0G | 27.0 |
| EDGEFORMER w/o LA2 | 8.6M | 1.8G | \( 27.7^{†(1)} \) |
| EDGEFORMER (Bias-LA) | 8.6M | 1.8G | 27.8 |
| EDGEFORMER (Adapter-LA) (\( r = 32 \)) | 9.4M | 1.8G | \( 28.0^{†(2)} \) |
| EDGEFORMER (Prefix-LA) (\( L = 8 \)) | 8.6M | 1.9G | \( 28.0^{†(2)} \) |
+
+Table 2: WMT14 En-De results. To fairly compare with UNIVERSAL TRANSFORMER (UT) that is originally smaller than EDGEFORMER, we also test UT with larger FFNs to make its model size comparable to EDGEFORMER. $\dagger^{(i)}$ denotes $p < 0.05$ in significance test compared with the model marked with $^i$ .
+
+| FFNs | Load | #Params | FLOPS | sacreBLEU |
| 2 FFNs (dffn = 2048)1 | 6-6 | 8.6M | 1.8G | 27.7 |
| 3 FFNs (dffn = 1536) | 4-4-4 | 9.1M | 1.6G | 27.4†(1) |
| 4 FFNs (dffn = 1024) | 3-3-3-3 | 8.6M | 1.4G | 27.2†(1) |
| 2 FFNs (dffn = 2048) | 1-11 | 8.6M | 1.8G | 27.5†(1) |
| 2 FFNs (dffn = 2048) | 11-1 | 8.6M | 1.8G | 27.4†(1) |
+
+Table 3: Performance of EDGEFORMER with various encoder FFN parameterization on WMT14 En-De. Load 6-6 means the 2 groups of FFN parameters are used 6 times each, while Load 1-11 means 1 group of FFN is used once, and the other is used 11 times.
+
+efficient Transformer for fair comparison. By default, we apply Seq-KD (Kim & Rush, 2016) to train models and use the full-parameterized $6 + 6$ Transformer-big ( $d = 1,024$ ) model (Vaswani et al., 2017; Ott et al., 2018) as the teacher.
+
+By default, for each experiment, we train 5 models with different initializations and report their average evaluation results for Table 2, 3 and 6 with significance test. For inference, we use beam search (beam=5).
+
+# 5.2 Offline Evaluation
+
+We evaluate EDGEFORMER and compare it with UNIVERSAL TRANSFORMER (UT) on WMT14 En-De. According to Table 2, the EDGEFORMER without layer adaptation (LA) largely outperforms UTs. Among the LA approaches, both Adapter-LA and Prefix-LA are clear to benefit the result with marginal computational or parameterization cost, while Bias-LA does not show significant performance gain though it is the cheapest.
+
+As discussed in Section 4.2, the advantage of EDGEFORMER over UT comes from its cost-effective parameterization. The encoder-favored principle is again supported by comparing $6 + 6$ Transformers' results in Table 2, which is consistent with the observation on the dev set in Figure 3a. To further understand the effectiveness of load-balanced parameterization principles, we conduct an ablation study by adjusting encoder FFNs in EDGEFORMER. Table 3 shows the results of EDGEFORMER with various FFN parameterization. As we reduce $d_{\mathrm{ffn}}$ (e.g., to 1536 or 1024), we can increase the group of encoder FFN parameters and reduce their load given a fixed parameterization budget. However, such a strategy leads to a clear degradation of sacreBLEU. One reason is that the FFN parameters of a reduced load (3-4 times) are not so fully utilized as the baseline (6 times) despite other reasons such as the differences of network shape (e.g., $d_{\mathrm{ffn}}$ ). To minimize the effects of other factors, we compare the first group with a balanced
+
+
+(a)
+
+
+(b)
+Figure 4: The effects of (a) rank $r$ in Adapter-LA, and (b) prefix length $L$ in Prefix-LA on the performance in WMT14 En-De. Note that $r = 64$ will lead to exceed our parameterization budget despite better performance.
+
+| Model | #params | FLOPS | En-De | En-Fr |
| 6+6 Transformer | 44M | 1.8G | 28.3 | 41.0 |
| 12+2 Transformer | 46M | 1.9G | 28.4 | 41.4 |
| 12+2 UT | 7.4M | 1.9G | 26.2 | 39.2 |
| DeLighT | 31.4M | - | 27.6 | 39.6 |
| Shapeshifter | 8.2M | - | 26.6 | 40.8 |
| Lite Transformer (small) | 2.9M | 0.2G | 22.5 | 35.3 |
| Lite Transformer (medium) | 11.7M | 0.7G | 25.6 | 39.1 |
| Lite Transformer (big) | 17.3M | 1.0G | 26.5 | 39.6 |
| EdgeFormer w/o LA | 8.6M | 1.8G | 26.5 | 39.8 |
| EdgeFormer (Adapter-LA) | 9.4M | 1.8G | 26.9 | 40.5 |
| EdgeFormer (Prefix-LA) | 8.6M | 1.9G | 26.8 | 40.3 |
+
+Table 4: Result comparison to previous parameter-efficient Transformers that have fewer parameters than the baseline Transformer (around 45M parameters). “-” means that the metrics are unavailable or not comparable in the original paper. The underlines denote that the metrics cannot meet the on-device requirement. Note that all the models in this table do not apply Seq-KD.
+
+parameter load (i.e., 6-6) and the last group with a imbalanced parameter load (1-11 or 11-1), showing load-balanced parameterization is consistently better than the imbalanced counterparts.
+
+After discussing parameterization, we then analyze the effects of layer adaptation on the results by mainly focusing on Adapter-LA and Prefix-LA that both show performance gain. Figure 4 shows the effects of the rank $r$ in Adapter-LA and prefix length $L$ in Prefix-LA. As $r$ increases, the model performance will gradually improve. However, when $r$ becomes large (e.g., $r \geq 64$ ), it will exceed our parameterization budget and thus the gain will become meaningless. As for prefix length $L$ in Prefix-LA, it is different from $r$ that it will not keep improving the results as it increases: the gain can hardly be observed after some length (e.g., $L = 8$ ), which is similar to the observation in prefix-tuning (Li & Liang, 2021). Therefore, we use $r = 32$ and $L = 8$ as the default setting to
+
+report the results of Adapter-LA and Prefix-LA.
+
+Finally, we compare EDGEFORMER with recent work on parameter-efficient Transformer modeling. To keep consistency of the training and evaluation protocols with previous work, we here give up using Seq-KD to train the models, and report BLEU (Papineni et al., 2002) for comparison. Specifically, we compare with DeLighT (Mehta et al., 2020), Shapeshifter (Panahi et al., 2021) and Lite Transformer (Wu et al., 2020), and show the results in Table 4. However, it is notable that the results are not strictly comparable because the previous studies have their own focus and setting, which are different from ours. For example, DeLighT and Lite Transformer focus much more on FLOPS than the model size, thus they do not a desirable tradeoff between the model quality and size; while Shapeshifter's goal is minimizing the model size despite an additional $10\% \sim 20\%$ inference overhead. Regardless of these factors that
+
+| WMT14 En-De |
| Model | Disk size (7zip) | Peak Memory | Latency 1 | Latency 2 | sacreBLEU |
| EdgeFormer (Adapter-LA, 32k vocab) | 28MB | 60MB | 65ms | 114ms | 27.2 |
| EdgeFormer (Adapter-LA, 8k vocab) | 15MB | 47MB | 59ms | 101ms | 27.1 |
| CoNLL-14 |
| Model | Disk size (7zip) | Peak Memory | Latency 1 | Latency 2 | F0.5 |
| EdgeFormer (Adapter-LA, 2k vocab) | 11MB | 42MB | 51ms | 98ms | 50.8 |
+
+Table 5: Runtime results for int8-quantized EDGEFORMER, in which Latency1 and Latency 2 denote the average latency per sentence measured on the Intel® Xeon® E-2288G CPU and Qualcomm SM8150 Snapdragon 855 CPU, respectively. We run through the test set with batch size=1, and use greedy decoding instead of beam search.
+
+| Model | #Param | FLOPS | CoNLL14 F0.5 | RG-1 | XSum RG-2 | RG-L | SQuAD-NQG |
| B4 | MTR | RG-L |
| Transformer-base | 44M | 1.8G | 50.1 | 31.2 | 10.7 | 24.9 | 2.6* | 9.0* | 26.0* |
| Pretrained 12+2 UT (d芬n = 2048) | 7.4M | 1.4G | 50.8 | 36.0 | 14.5 | 29.2 | 19.8 | 22.2 | 46.9 |
| Pretrained 12+2 UT (d芬n = 3072)1 | 9.4M | 1.9G | 51.1 | 36.7 | 14.9 | 29.7 | 20.1 | 22.4 | 47.1 |
| EDGELM | 9.4M | 1.3G | 52.0(1) | 37.2(1) | 15.4(1) | 30.3(1) | 20.6(1) | 23.0(1) | 47.4(1) |
+
+Table 6: The performance of EDGELM in comparison with the baselines. * denotes that the results are from Chen et al. (2019).
+
+prevent fair comparison, EDGEFORMER achieves 26.9 BLEU in En-De under the strict on-device resource constraints, which outperforms the state-of-the-art Shapeshifter with the similar model size despite. It is notable that EDGEFORMER here uses the same model architecture and training configuration for both En-De and En-Fr, while Shapeshifter uses different model architecture configurations specific for En-De and En-Fr, which may account for its better performance in En-Fr.
+
+# 5.3 Runtime Evaluation
+
+We conduct experiments in WMT14 En-De translation and CoNLL-14 Grammatical Error Correction $^{6}$ (GEC) benchmark for runtime latency and memory evaluation using onnxruntime $^{7}$ that supports efficient seq2seq decoding. We apply int8-quantization to EDGEFORMER and test latency on 2 devices: a 2-core Intel® Xeon® E-2288G CPU (in PC), and a 2-core Qualcomm SM8150 Snapdragon 855 CPU (in Pixel 4), which are both current mid-to-high end CPUs launched 2-3 years ago.
+
+Table 5 shows runtime evaluation results. With int8-quantization and smaller vocabulary, EDGE-FORMER can not only meet the on-device seq2seq requirements but also maintain its good performance, demonstrating its practical values.
+
+# 6 EdgeLM - The Pretrained EdgeFormer
+
+Given the promising results, we introduce EDGELM - the pretrained8 EDGEFORMER (Adapter-LA) with 8K sentenpiece vocabulary with factorized embedding ( $d_{\mathrm{embed}} = 128$ ) through the same self-supervised task (i.e., masked span infilling) as T5 (Raffel et al., 2019) and make it publicly available for downstream on-device seq2seq task fine-tuning.
+
+We evaluate EDGELM in the benchmarks of three popular seq2seq tasks: CoNLL-14 for Grammatical Error Correction (GEC), XSum (Narayan et al., 2018) for Abstractive Summarization, and SQuAD-NQG (Du et al., 2017) for Question Generation. According to Table 6, EDGELM achieves significantly better performance than the pretrained UT models as well as the Transformer-base model trained from scratch. We believe that EDGELM, as the first publicly released on-device seq2seq pretrained model, can largely facilitate on-device seq2seq generation in practice.
+
+# 7 Related Work
+
+On-device seq2seq generation in NLP is a research area that has been less explored than on-device CV and NLU (Tambe et al., 2021). Besides the general techniques like pruning, compression, quantization and knowledge distillation (Fan et al., 2019;
+
+Xu et al., 2020; Li et al., 2022) that are orthogonal to our effort, parameter-efficient Transformer-based seq2seq modeling is the most related research branch to ours. In this branch, UNIVERSAL TRANSFORMER (Dehghani et al., 2018) uses cross-layer sharing method, which is the most popular solution to parameter efficiency. Takase & Kiyono (2021) extends UNIVERSAL TRANSFORMER by studying different ways for layer sharing, and Reid et al. (2021) proposes to free the first and last encoder layer and widen the intermediate layers for better performance. However, both the approaches consider parameter-efficiency only without caring about latency becoming worse.
+
+In addition to work improving parameter efficiency by weight sharing, there is research that studies lightweight model architecture for seq2seq learning where early work (Gehring et al., 2017; Wu et al., 2019) mainly focuses on CNNs, while recent efforts have tended to switch to attention-based models such as Mehta et al. (2020). Also, low-rank factorization has been studied intensively to make the model tiny (Zhang et al., 2021; Panahi et al., 2021); and hardware-aware network architecture search with elastic modeling (Wang et al., 2020) has been proposed recently for facilitating deployment of seq2seq models on various devices. Among previous studies, the work of Wu et al. (2020) is the most related to ours, which studies seq2seq generation in an on-device setting. However, it sets the computational constraint for on-device seq2seq to be the same with the CV tasks, which is too strict and unnecessary, as discussed in Section 3. As a result, their models focus on FLOPS optimization much more than memory, leading to an undesirable tradeoff between the quality and model size for the practical on-device seq2seq setting which should care about memory much more than latency. In contrast, our work carefully evaluates bottleneck constraints, and proposes appropriate models with parameterization and layer adaptation innovations, largely improving the results for practical on-device seq2seq generation.
+
+# 8 Conclusion and Future Work
+
+We formally study on-device seq2seq generation, including defining its practical resource constraint setting and proposing an appropriate modeling technology EDGEFORMER. The cost-effective parameterization and layer adaptation innovations in EDGEFORMER both prove effective to improve
+
+the results with negligible computation and memory cost, achieving state-of-the-art results in the on-device seq2seq generation setting. Our released pretrained EDGEFORMER - EDGELM can be easily fine-tuned for downstream seq2seq tasks, largely facilitating on-device seq2seq generation in practice.
+
+For future work, we plan to further study load-balanced parameterization for parameter-efficient models, which is an interesting and new but seemingly profound machine learning research problem: instead of naively assuming that all the parameters are equal in this preliminary study, we suspect that parameters in different modules (e.g., parameters in the self-attn and FFN; or parameters in different layers) should be under different amounts of load. We look forward to in-depth research on this problem, which might be helpful to deepen our understanding of neural networks.
+
+# 9 Limitations
+
+EDGEFORMER is a preliminary model proposed for on-device seq2seq generation setting, which still has much room for improvement. For example, as mentioned in Section 8, the current load balance mechanism naively assumes that the number of times that a parameter is used in a forward pass is equal to its load, which may not be always true because parameters in different moduels are different: some parameters may be effectively used more times than others, which requires deeper understanding of neural network and the Transformer.
+
+# Acknowledgments
+
+We thank all the anonymous reviewers for their valuable comments. We thank Xiaohu Tang, Fucheng Jia, Yifan Yang and Huiqiang Jiang for their help in runtime evaluation, and thank Shuming Ma, Ting Cao, Fan Yang, Qiufeng Yin, Yuqing Yang and Lidong Zhou in Microsoft Research Asia for the discussion and helpful comments. We also appreciate the support from Wenbing Li, Yufeng Li, Bowen Bao, Ye Wang, Sunghoon Choi, Scott McKay and Emma Ning in Microsoft AI Frameworks for onnxruntime, and appreciate the feedback and valuable suggestions from Joshua Burkholder, Xun Wang, Weixin Cai and Zhang Li in Microsoft Office Intelligence regarding detailed constraints for on-device seq2seq generation in real-word applications.
+
+# References
+
+Elad Ben Zaken, Shauli Ravfogel, and Yoav Goldberg. Bitfit: Simple parameter-efficient fine-tuning for transformer-based masked language-models. arXiv e-prints, pp. arXiv-2106, 2021.
+Christopher Bryant, Mariano Felice, Øistein E Andersen, and Ted Briscoe. The bea-2019 shared task on grammatical error correction. In Proceedings of the Fourteenth Workshop on Innovative Use of NLP for Building Educational Applications, pp. 52-75, 2019.
+Mengyun Chen, Tao Ge, Xingxing Zhang, Furu Wei, and Ming Zhou. Improving the efficiency of grammatical error correction with erroneous span detection and correction. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pp. 7162-7169. Association for Computational Linguistics, 2020.
+Yu Chen, Lingfei Wu, and Mohammed J Zaki. Reinforcement learning based graph-to-sequence model for natural question generation. arXiv preprint arXiv:1908.04942, 2019.
+Daniel Dahlmeier and Hwee Tou Ng. Better evaluation for grammatical error correction. In Proceedings of the 2012 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pp. 568-572, 2012.
+Mostafa Dehghani, Stephan Gouws, Oriol Vinyals, Jakob Uszkoreit, and Lukasz Kaiser. Universal transformers. arXiv preprint arXiv:1807.03819, 2018.
+Sauptik Dhar, Junyao Guo, Jiayi Liu, Samarth Tripathi, Unmesh Kurup, and Mohak Shah. On-device machine learning: An algorithms and learning theory perspective. arXiv preprint arXiv:1911.00623, 2019.
+Li Dong, Nan Yang, Wenhui Wang, Furu Wei, Xiaodong Liu, Yu Wang, Jianfeng Gao, Ming Zhou, and Hsiao-Wuen Hon. Unified language model pre-training for natural language understanding and generation. arXiv preprint arXiv:1905.03197, 2019.
+Xinya Du, Junru Shao, and Claire Cardie. Learning to ask: Neural question generation for reading comprehension. In Association for Computational Linguistics (ACL), 2017.
+Angela Fan, Edouard Grave, and Armand Joulin. Reducing transformer depth on demand with structured dropout. In International Conference on Learning Representations, 2019.
+William Fedus, Barret Zoph, and Noam Shazeer. Switch transformers: Scaling to trillion parameter models with simple and efficient sparsity, 2021.
+Jonas Gehring, Michael Auli, David Grangier, Denis Yarats, and Yann N Dauphin. Convolutional sequence to sequence learning. In International Conference on Machine Learning, pp. 1243-1252. PMLR, 2017.
+
+Neil Houlsby, Andrei Giurgiu, Stanislaw Jastrzebski, Bruna Morrone, Quentin De Laroussilhe, Andrea Gesmundo, Mona Attariyan, and Sylvain Gelly. Parameter-efficient transfer learning for nlp. In International Conference on Machine Learning, pp. 2790-2799. PMLR, 2019.
+Edward J Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu, Yuanzhi Li, Shean Wang, Lu Wang, and Weizhu Chen. Lora: Low-rank adaptation of large language models. arXiv preprint arXiv:2106.09685, 2021.
+Jungo Kasai, Nikolaos Pappas, Hao Peng, James Cross, and Noah A Smith. Deep encoder, shallow decoder: Reevaluating non-autoregressive machine translation. arXiv preprint arXiv:2006.10369, 2020.
+Yoon Kim and Alexander M Rush. Sequence-level knowledge distillation. arXiv preprint arXiv:1606.07947, 2016.
+Taku Kudo and John Richardson. Sentencepiece: A simple and language independent subword tokenizer and tokenizer for neural text processing. arXiv preprint arXiv:1808.06226, 2018.
+Brian Lester, Rami Al-Rfou, and Noah Constant. The power of scale for parameter-efficient prompt tuning. arXiv preprint arXiv:2104.08691, 2021.
+Xiang Lisa Li and Percy Liang. Prefix-tuning: Optimizing continuous prompts for generation. arXiv preprint arXiv:2101.00190, 2021.
+Zheng Li, Zijian Wang, Ming Tan, Ramesh Nallapati, Parminder Bhatia, Andrew Arnold, Bing Xiang, and Dan Roth. Dq-bart: Efficient sequence-to-sequence model via joint distillation and quantization. arXiv preprint arXiv:2203.11239, 2022.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692, 2019.
+Shuming Ma, Li Dong, Shaohan Huang, Dongdong Zhang, Alexandre Muzio, Saksham Singhal, Hany Hassan Awadalla, Xia Song, and Furu Wei. Deltalm: Encoder-decoder pre-training for language generation and translation by augmenting pretrained multilingual encoders. arXiv preprint arXiv:2106.13736, 2021.
+Sachin Mehta, Marjan Ghazvininejad, Srinivasan Iyer, Luke Zettlemoyer, and Hannaneh Hajishirzi. Delight: Deep and light-weight transformer. arXiv preprint arXiv:2008.00623, 2020.
+Tomoya Mizumoto, Mamoru Komachi, Masaaki Nagata, and Yuji Matsumoto. Mining revision log of language learning sns for automated japanese error correction of second language learners. In Proceedings of 5th International Joint Conference on Natural Language Processing, pp. 147-155, 2011.
+
+Shashi Narayan, Shay B Cohen, and Mirella Lapata. Don't give me the details, just the summary! topic-aware convolutional neural networks for extreme summarization. arXiv preprint arXiv:1808.08745, 2018.
+Hwee Tou Ng, Siew Mei Wu, Yuanbin Wu, Christian Hadiwinoto, and Joel Tetreault. The CoNLL-2013 shared task on grammatical error correction. In Proceedings of the Seventeenth Conference on Computational Natural Language Learning: Shared Task, pp. 1-12, Sofia, Bulgaria, August 2013. Association for Computational Linguistics. URL https://aclanthology.org/W13-3601.
+Hwee Tou Ng, Siew Mei Wu, Ted Briscoe, Christian Hadiwinoto, Raymond Hendy Susanto, and Christopher Bryant. The conll-2014 shared task on grammatical error correction. In Proceedings of the Eighteenth Conference on Computational Natural Language Learning: Shared Task, pp. 1-14, 2014.
+Myle Ott, Sergey Edunov, David Grangier, and Michael Auli. Scaling neural machine translation. arXiv preprint arXiv:1806.00187, 2018.
+Aliakbar Panahi, Seyran Saeedi, and Tom Arodz. Shapeshifter: a parameter-efficient transformer using factorized reshaped matrices. Advances in Neural Information Processing Systems, 34, 2021.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th annual meeting of the Association for Computational Linguistics, pp. 311-318, 2002.
+Matt Post. A call for clarity in reporting bleu scores. arXiv preprint arXiv:1804.08771, 2018.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. Exploring the limits of transfer learning with a unified text-to-text transformer. arXiv preprint arXiv:1910.10683, 2019.
+Machel Reid, Edison Marrese-Taylor, and Yutaka Matsuo. Subformer: Exploring weight sharing for parameter efficiency in generative transformers. arXiv preprint arXiv:2101.00234, 2021.
+Xin Sun, Tao Ge, Furu Wei, and Houfeng Wang. Instantaneous grammatical error correction with shallow aggressive decoding. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pp. 5937-5947, 2021.
+Sho Takase and Shun Kiyono. Lessons on parameter sharing across layers in transformers. arXiv preprint arXiv:2104.06022, 2021.
+Thierry Tambe, Coleman Hooper, Lillian Pentecost, Tianyu Jia, En-Yu Yang, Marco Donato, Victor Sanh, Paul Whatmough, Alexander M Rush, David Brooks,
+
+et al. Edgebert: Sentence-level energy optimizations for latency-aware multi-task nlp inference. In MICRO-54: 54th Annual IEEE/ACM International Symposium on Microarchitecture, pp. 830-844, 2021.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. Attention is all you need. In Advances in neural information processing systems, pp. 5998-6008, 2017.
+Hanrui Wang, Zhanghao Wu, Zhijian Liu, Han Cai, Ligeng Zhu, Chuang Gan, and Song Han. Hat: Hardware-aware transformers for efficient natural language processing. arXiv preprint arXiv:2005.14187, 2020.
+Felix Wu, Angela Fan, Alexei Baevski, Yann Dauphin, and Michael Auli. Pay less attention with lightweight and dynamic convolutions. In International Conference on Learning Representations, 2019. URL https://arxiv.org/abs/1901.10430.
+Zhanghao Wu, Zhijian Liu, Ji Lin, Yujun Lin, and Song Han. Lite transformer with long-short range attention. arXiv preprint arXiv:2004.11886, 2020.
+Canwen Xu, Wangchunshu Zhou, Tao Ge, Furu Wei, and Ming Zhou. Bert-of-theseus: Compressing bert by progressive module replacing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pp. 7859-7869, 2020.
+Helen Yannakoudakis, Ted Briscoe, and Ben Medlock. A new dataset and method for automatically grading esol texts. In Proceedings of the 49th annual meeting of the association for computational linguistics: human language technologies, pp. 180-189, 2011.
+Aston Zhang, Yi Tay, Shuai Zhang, Alvin Chan, Anh Tuan Luu, Siu Cheung Hui, and Jie Fu. Beyond fully-connected layers with quaternions: Parameterization of hypercomplex multiplications with $1/n$ parameters. arXiv preprint arXiv:2102.08597, 2021.
+Wangchunshu Zhou, Tao Ge, Canwen Xu, Ke Xu, and Furu Wei. Improving sequence-to-sequence pretraining via sequence span rewriting. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pp. 571-582, 2021.
+
+# A Details of Evaluations for MT and GEC
+
+For MT, we follow the setting of Ott et al. (2018) to train the model on the WMT14 datasets. For En-De, the training set contains 4.5M parallel sentence pairs. We use newstest2013 as our dev set. For En-Fr, there are 36M parallel sentence pairs for training, and we use newstest2012+2013 as the dev set.
+
+In GEC evaluation, we follow previous work (Chen et al., 2020; Zhou et al., 2021) to use the BEA-19 restricted setting, training with Lang-8 (Mizumoto et al., 2011), FCE (Yannakoudakis et al., 2011) and WI+LOCNESS (Bryant et al., 2019). We validate on CoNLL-13 shared task dataset (Ng et al., 2013), and test on CoNLL-14 shared task dataset (Ng et al., 2014). After deduplicating, we have around 900K sentence pairs for training. Both the dev (CoNLL-13) and test (CoNLL-14) have 1.3K samples. We train a sentencepiece (Kudo & Richardson, 2018) model of 2K vocabulary for tokenization, and evaluate with the metric of Max-Match (Dahlmeier & Ng, 2012) $F_{0.5}$ .
+
+For model training configuration, we show in Table 7; The ablation study into the reduction of $d_{\mathrm{decffn}}$ is presented in Table 8.
+
+| Configurations | Values |
| Number of epochs | 1000 |
| Devices | 8 Nvidia V100 GPU |
| Max tokens per GPU | 20,000 |
| Update Frequency | 4 |
| Optimizer | Adam
+(β1=0.9, β2=0.99, ε=1 × 10-8) |
| Learning rate | 1 × 10-3 |
| Learning rate scheduler | inverse sqrt |
| Warmup | 4000 |
| Weight decay | 0.00001 |
| Loss Function | label smoothed cross entropy
+ label-smoothing=0.1) |
| Dropout | [0.1, 0.2] for MT, [0.3, 0.4, 0.5] for GEC |
+
+Table 7: Training details for EDGEFORMER for NMT and GEC.
+
+| ddecffn | #Param | sacreBLEU |
| 2048 | 46M | 26.5 |
| 512 | 37M | 26.4 |
| 256 | 35M | 26.4 |
| 128 | 34M | 26.4 |
+
+Table 8: The ablation study into the reduction of $d_{\mathrm{deccfn}}$ on a standard 6+6 Transformer on the dev set.
+
+| Configurations | Values |
| Total updates | 250,000 |
| Devices | 8 × 8 Nvidia V100 GPU |
| Batch size per GPU | 128 |
| Sample length | 512 |
| Optimizer | Adam |
| (β1=0.9, β2=0.98 ε=1 × 10-6) |
| Learning rate | 5 × 10-4 |
| Learning rate scheduler | polynomial |
| clip norm | 2.0 |
| Warmup | 10,000 |
| Loss Function | cross entropy |
| Weight decay | 0.0 |
| Dropout | 0.1 |
+
+Table 9: Pretraining details for EDGELM.
+
+| Configurations | Values |
| Total updates | 100,000 |
| Devices | 8 Nvidia V100 GPU |
| Max tokens per GPU | 20,000 |
| Optimizer | Adam |
| (β1=0.9, β2=0.98 ε=1 × 10-6) |
| Learning rate | Vary for different downstream tasks |
| Learning rate scheduler | polynomial |
| clip norm | 1.0 |
| Warmup | 8,000 |
| Loss Function | cross entropy |
| Weight decay | 0.0 |
| Dropout | 0.1 |
+
+Table 10: Fine-tuning details for EDGELM.
+
+# B Configurations of Pretraining and Fine-tuning
+
+We pretrain EDGEFORMER with the same pretrain data as RoBERTa (Liu et al., 2019), through the same pretrain task as T5 (Raffel et al., 2019). The detailed configuration of pretraining is shown in Table 9.
+
+For downstream task fine-tuning, we present the configuration details in Table 10.
+
+# C Detailed Evaluation of EdgeLM
+
+In addition to the evaluation results presented in Table 6, we present more detailed results in Table 11 and 12 to show the performance of EDGELM in different sizes and with different vocabularies with factorized embedding parameterization respectively. According to Table 11, EDGELMs consistently outperform the pretrained UTs in the downstream tasks under various model sizes with only $70\%$ computation cost of UTs.
+
+According to Table 12, we show that enlarging the vocabulary size with factorized embedding is effective to improve abstractive summarization and question generation tasks, while it appears to have an adverse effect for GEC. One reason for the performance degradation is that GEC is more sensitive
+
+| Model | #Param | FLOPS | CoNLL-14 F0.5 | RG-1 | Xsum RG-2 | RG-L | B4 | QGMTR | RG-L |
| Transformer | 44M | 1.8G | 50.1 | 31.2 | 10.7 | 24.9 | 2.6 | 9.0 | 26.0 |
| Pretrained UT (d=512, dffn=3072) | 9.4M | 1.9G | 51.1 | 36.7 | 14.9 | 29.7 | 20.1 | 22.4 | 47.1 |
| EDGELM (d=512) | 9.4M | 1.3G | 52.0 | 37.2 | 15.4 | 30.3 | 20.6 | 23.1 | 47.4 |
| Pretrained UT (d=384, dffn=2432) | 5.5M | 1.1G | 50.1 | 31.9 | 11.5 | 25.7 | 17.9 | 21.0 | 45.9 |
| EDGELM (d=384) | 5.5M | 0.8G | 50.1 | 32.3 | 11.7 | 26.0 | 18.9 | 21.2 | 45.9 |
| Pretrained UT (d=768, dffn=4608) | 21.2M | 4.2G | 52.8 | 37.3 | 15.6 | 30.4 | 20.9 | 23.5 | 47.5 |
| EDGELM (d=768) | 21.4M | 2.9G | 53.1 | 37.9 | 15.9 | 30.8 | 21.0 | 23.6 | 47.8 |
+
+Table 11: The comparison between pretrained Universal Transformer (UT) and EdgeLM with Adapter-based layer adaptation $(r = d / 8)$ . We enlarge UT's $d_{\mathrm{ffn}}$ to let its model size comparable with its EdgeFormer counterpart with the same $d$ for fair comparison given the same parameter budget though introducing additional cost.
+
+| Vocab | dembed | #Param (including embedding) | CoNLL-14F0.5 | RG-1 | XsumRG-2 | RG-L | B4 | QGMTR | RG-L |
| spm2k | 512 | 10.4M | 52.7 | 36.3 | 14.8 | 29.5 | 19.0 | 21.7 | 46.3 |
| spm8k | 128 | 10.5M | 52.0 | 37.2 | 15.4 | 30.3 | 20.6 | 23.1 | 47.4 |
| spm16k | 64 | 10.5M | 51.6 | 37.1 | 15.1 | 30.0 | 19.6 | 22.3 | 46.7 |
+
+Table 12: EDGELM ( $d = 512$ ) with Adapter-LA ( $r = 32$ ) using different vocabulary and $d_{\mathrm{embed}}$ . Except the model with $\mathrm{spm2k}$ whose $d_{\mathrm{embed}} = d$ , the models with $\mathrm{spm8k}$ and $\mathrm{spm16k}$ use factorized embedding to prevent increasing the total parameters.
+
+to morphological and syntactic information of a token; when $d_{\mathrm{embed}}$ becomes small with factorized embedding, it may not accurately capture the morphological and syntactic information of the token.
\ No newline at end of file
diff --git a/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/images.zip b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..1e453062eefb160bb593e183d1670e08ce6b0d06
--- /dev/null
+++ b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a6817e777b528c43f57049cd586c9079f43724d87728db478e016e341723068d
+size 688256
diff --git a/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/layout.json b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..c5c3b533c68b1ffc21e6bbeeaad740133cb952b8
--- /dev/null
+++ b/edgeformeraparameterefficienttransformerforondeviceseq2seqgeneration/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e137d02de6815330091ad3f6007617abf6e32518fbc59bb23c45882db3534811
+size 419895
diff --git a/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_content_list.json b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..161857fa867c34fab2bc93834e81cb6658166a8c
--- /dev/null
+++ b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:771a73e55f3be7d9b340ee9554b7c5ff845c2243eba8ee7bf7b8de2f682bec31
+size 108786
diff --git a/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_model.json b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..57cd714e1177b86c5008ec87335e9805320c768d
--- /dev/null
+++ b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:00fc6e676c441f35a54e7d2509653bc98314ff4f6a1be81c48cf06f34c1d6e0b
+size 133549
diff --git a/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_origin.pdf b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..8f010aeaf49fa0f8ac99ec711304f16c51abe4b0
--- /dev/null
+++ b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/486b42f2-2d69-4321-bdd7-f69af0f5acf6_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9dd3afa977d579284f72251f630d24ce7a22db2ca7f057665efa7deba7e85960
+size 599465
diff --git a/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/full.md b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..8cad3aef2903659e99982a02023b4369e27dc22f
--- /dev/null
+++ b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/full.md
@@ -0,0 +1,497 @@
+# EDIN: An End-to-end Benchmark and Pipeline for Unknown Entity Discovery and Indexing
+
+Nora Kassner, Fabio Petroni, Mikhail Plekhanov, Sebastian Riedel, Nicola Cancedda
+
+Meta AI
+
+kassner@meta.com
+
+# Abstract
+
+Existing work on Entity Linking mostly assumes that the reference knowledge base is complete, and therefore all mentions can be linked. In practice this is hardly ever the case, as knowledge bases are incomplete and because novel concepts arise constantly. We introduce the temporally segmented Unknown Entity Discovery and Indexing (EDIN) -benchmark where unknown entities, that is entities not part of the knowledge base and without descriptions and labeled mentions, have to be integrated into an existing entity linking system. By contrasting EDIN with zero-shot entity linking, we provide insight on the additional challenges it poses. Building on dense-retrieval based entity linking, we introduce the end-to-end EDIN-pipeline that detects, clusters, and indexes mentions of unknown entities in context. Experiments show that indexing a single embedding per entity unifying the information of multiple mentions works better than indexing mentions independently.
+
+# 1 Introduction
+
+Most existing works on Entity linking (EL) – the fundamental task of detecting mentions of entities in context and disambiguating them against a reference knowledge base (KB) – assume that such KB is complete, and therefore all mentions can be linked. In practice this is hardly ever the case, as KBs are incomplete when they are created and because novel concepts arise constantly. For example, English Wikipedia, often used as the reference KB for large scale linking, is growing by more than 17k entities every month.
+
+Consequently, at the time of deployment EL systems are quickly outdated and static evaluation overestimates performance. But as these systems play significant role in many real world industry
+
+applications, e.g., moderating discussions around recent events, a dynamic look on EL is crucial.
+
+Nonetheless, related work on this problem is sparse. Available datasets (Ji et al., 2015; Derczynski et al., 2017; Nakashole et al., 2013) and models (Hoffart et al., 2014) are outdated and/or small scale and use features which are not readily available (Nakashole et al., 2013; Wu et al., 2016). Most importantly, they approach the problem only in parts. We revisit this problem in context of dense-retrieval and large-scale EL, e.g., EL relying on bi-encoder architecture that runs a nearest neighbor search between mention encoding and a large-scale index of entity encodings. To this end, we introduce EDIN-benchmark and EDIN-pipeline where unknown entities, that is entities with no available canonical names, descriptions and labeled mentions, have to be integrated into an existing EL model in an end-to-end fashion. To the best of our knowledge, EDIN-pipeline is the first end-to-end pipeline tackling this problem.
+
+Note that this setting is strictly more demanding than zero-shot (zs) entity linking (Logeswaran et al., 2019), where a textual description of the zs entities is available at the time of training.
+
+The EDIN-benchmark is temporally segmented into two parts, one preceding time $t_1$ and one preceding time $t_2$ . With current approaches, an EL system created at $t_1$ is unable to create a dense-index entry – and therefore successfully link – unknown entities introduced after $t_1$ . The task that we propose consists in adapting a model trained at $t_1$ using only an adaptation dataset – a set of new documents also mentioning unknown entities – and unsupervised techniques. There are therefore two parts to this task: i) Discovery, which consists in detecting mentions of unknown entities in the adaptation dataset and classifying them as unknown and ii) Indexing, consisting in mapping co-referring mentions of unknown entities to a single representation compatible with the entity index.
+
+By introducing a clear-cut temporal segmentation EDIN-benchmark targets unknown entities which are truly novel/unseen to all parts of an EL system, specifically the pre-trained language model (PLM). Therefore, the EL system cannot rely on implicit knowledge captured by the PLM. This is, to the best of our knowledge, a setting that has not been explored before in the context of dense-retrieval based EL.
+
+Temporal segmentation also lets us study effects of entity encoder and PLM degradation. We observe that precision drops for known entities in novel contexts which points to a large problem of PLM staleness also discussed by (Agarwal and Nenkova, 2021; Dhingra et al., 2022; Lazaridou et al., 2021).
+
+We show that distinguishing known from unknown entities, arguably a key feature of an intelligent system, poses a major challenge to dense-retrieval based EL systems, as a model has to strike a delicate balance between relying on mention vs. context: context is crucial to distinguish unknown entities carrying the same name as known entities and to co-refer different mentions of the same unknown entities, while mentions are essential to distinguish unknown entities with different names but semantic similarity to existing ones.
+
+On the side of indexing, inserting unknown entities into a space of known entities poses problems of interference with known entities in their close proximity. For instance, when first encountering mentions of BioNTech we want to create an index entry in proximity of other biotech companies but in a way that linking can still differentiate between them. We find that adapting the EL model to the updated index, is essential.
+
+We experiment with different indexing methods. In particular, we contrast single mention-level indexing (FitzGerald et al., 2021) with indexing clusters of mentions. We find that unifying the information of multiple mentions into a single embedding is beneficial.
+
+We summarize our contributions as follows: i) We introduce the EDIN-benchmark, a large scale end-to-end EL dataset where unknown entities need to be discovered and integrated into an existing entity index in an unsupervised fashion. ii) We propose the EDIN-pipeline in the form of an extension of existing dense-retrieval architectures. iii) We contrast this task with zs EL, and provide insight on the challenges it poses. iv) We show that
+
+indexing a single embedding per entity, unifying the information of multiple mentions, works better than indexing mentions independently.
+
+Data and evaluation code is located here: https://github.com/facebookresearch/EDIN
+
+# 2 Task definition
+
+We formally define end-to-end EL as follows: Given a paragraph $p$ and a set of known entities $E_{K} = \{e_{i}\}$ , each with canonical name, the title, $t(e_{i})$ and textual description $d(e_{i})$ , our goal is to output a list of tuples, $(e, [i,j])$ , where $e \in E_K$ is the entity corresponding to the mention $m_{i,j}$ spanning from the $i^{th}$ to $j^{th}$ token in $p$ . We call a system that solves this task based on $d(e_{i})$ a Description-based entity linking system L.
+
+For EDIN-benchmark, after training a model $L_{t1}$ at time step $t_1$ , a set of unknown entities $E_U = \{e_i\}$ with $E_U \cap E_K = \emptyset$ and no available canonical names, descriptions and labeled mentions is introduced between $t_1$ and $t_2 > t_1$ . The task is to adapt $L_{t1}$ in an unsupervised fashion such that it can successfully link mentions of $E_U \cup E_K$ .
+
+We use three dataset splits: the training set $D_{train}$ to train $L_{t1}$ , the adaptation dataset $D_{adapt}$ used to adapt $L_{t1}$ and the test set $D_{test}$ to evaluate. Both $D_{adapt}$ and $D_{test}$ include mentions between $t_1$ and $t_2$ . The model relies on $D_{adapt}$ to discover $E_U$ and extract representations to integrate $E_U$ into the entity index. We ensure that $D_{adapt}$ and $D_{test}$ are disjoint to prevent leakage of test mentions into entity representations extracted from $D_{adapt}$ .
+
+# 3 EDIN-pipeline
+
+Our EDIN-pipeline is built on top an end-to-end extension of the dense-retrieval based model BLINK (Ledell Wu, 2020) and is similar to (Li et al., 2020). It is composed of a Mention Detection (MD), Entity Disambiguation (ED) and Rejection (R) components. MD detects entity mention spans $[i,j]$ in context relying on BERT (Devlin et al., 2019). ED links these mentions to $e\in E_K$ . It relies on bi-encoder architecture running a k-nearest-neighbor (kNN) search between mention encoding and candidate entity encodings (the entity index). Mention encodings are pooled from BERT-encoded paragraph tokens $p_{1..n}$ :
+
+$$
+\mathbf {m} _ {i, j} = F F L (B E R T ([ C L S ] p _ {1} \dots p _ {n} [ S E P ]) _ {i \dots j})
+$$
+
+
+Figure 1: EDIN-pipeline: In the adaptation phase, detected mentions in $D_{adapt}$ are mapped into a joint dense space with $E_K$ representations. A clustering algorithm groups mentions and entities based on kNN-similarity. Clusters of mentions without entity encoding are collected in $E_U'$ . To integrate these into the index of $E_K$ , mentions in single-sentence contexts are concatenated and mapped to a single embedding using the entity encoder. After adaptation, the updated entity index is used for standard EL in an inductive setting.
+
+Entities are represented using BLINK's frozen entity encoder:
+
+$$
+\mathbf {e} = B E R T _ {[ C L S ]} ([ C L S ] t (e) [ S E P ] d (e) [ S E P ])
+$$
+
+Mention-entity candidates are passed to R that controls precision-recall trade-off by thresholding a learned candidate score.
+
+More information about architecture and training are detailed in appendix A.
+
+# 4 Unknown Entity Discovery and Indexing
+
+We introduce an end-to-end pipeline to encode $E_U$ into $L_{t1}$ 's entity index. The process is depicted in Figure 1. This pipeline is fully unsupervised and only relies on $D_{adapt}$ . It follows a two-step process: i) in Discovery the EL system detects mentions of unknown entities and recognises them as being unknown; ii) during Indexing, co-referring mentions of unknown entities are mapped to a single embedding compatible with the entity index. After adaptation the updated model is tested on $D_{test}$ .
+
+# 4.1 Unknown Entity Discovery
+
+First, $L_{t1}$ detects and encodes mentions part of $D_{adapt}$ . The MD head is trained to detect mentions leveraging the context around them, and can therefore detect mentions of both $E_K$ and $E_U$ . Encoded mentions $\mathbf{M} = \{\mathbf{m}_1,\dots,\mathbf{m}_{|M|}\}$ are then input to a clustering algorithm that partitions $M$ into disjoint clusters $C = \{c_1,\dots,c_{|C|}\}$ . We adopt the same greedy NN clustering algorithm
+
+as Logan IV et al. (2021) where $\mathbf{m}_i$ is assigned to cluster $c_{k}$ if $\mathbf{m}_j\in c_k$ is NN mention to $\mathbf{m}_i$ and $\operatorname {sim}(\mathbf{m}_i,\mathbf{m}_j) > \delta$
+
+Next, entity encodings of $e \in E_K$ are assigned to these clusters if $\sum_{j=0..J} (\text{sim}(\mathbf{e}_i, \mathbf{m}_j)) / J > \tau$ holds for $\mathbf{m}_j \in c_i$ with $\mathbf{e}_i$ being the nearest entity of $\mathbf{m}_j \in c_i$ . $\delta$ and $\tau$ are tuned on $D_{\text{adapt}}$ -dev to optimize for recall. For more details see appendix C. Following Agarwal et al. (2021), all clusters not containing any entity representation are deemed to refer to entities in $E_U$ . We refer to this subset of automatically identified unknown entities as $E_U'$ .
+
+# 4.2 Unknown Entity Indexing
+
+Next, clusters identified as $E_U'$ are integrated into the EL index of $L_{t1}$ . We explore two different methods of indexing:
+
+Cluster-based: We concatenate all mentions part of a cluster, each with the sentence they occur in, and use the entity encoder to map to a single entity encodings. We pool over all $m_i \in c_i$ and select the most occurring mention as canonical name $t(e)$ .
+
+Mention-based: Mentions in single sentence contexts are indexed individually using the entity encoder. Individual mentions are used as $t(e)$ .
+
+# 5 Evaluation
+
+As mentions of type $E_U$ are significantly less frequent than mentions of type $E_K$ , we report results on these two types separately.
+
+For Discovery, we report precision and recall of $E_{U}$ classification and clustering metrics.
+
+ | Wikipedia | OSCAR |
| Train | 100k (908k) | 100k (1.7M) |
| Adapt | 17k (183k) | 17k (380k) |
| Dev Train | 8k (78k) | 8k (142k) |
| Dev Adapt | - | 9k (183k) |
| Test | 198k (1.8M) | 569k (11M) |
+
+Table 1: Dataset Statistics: Number of samples (number of mentions) for training, adaptation and testing.
+
+| Bin | Support | EK R | Support | EU R |
| [0) | 68,241 | 21.1 | 7,095 | 17.5 |
| [1) | 59,227 | 29.1 | 3,923 | 25.9 |
| [1, 10) | 313,232 | 45.6 | 9,939 | 40.7 |
| [10, 100) | 901,857 | 65.7 | 7,765 | 57.3 |
| [100, 1k) | 2,860,880 | 76.9 | 7,399 | 64.4 |
| [1k, +) | 5,981,028 | 84.4 | 6,717 | 86.7 |
+
+Table 2: Frequency effects: End-to-end EL performance of upper baseline model $L_{t2}$ per frequency bins.
+
+To evaluate end-to-end EL, we compute precision (P) and recall (R) following Li et al. (2020) but using a hard matching criteria.
+
+To do so for cluster-based discovery, canonical names of indexed clusters need to be consistent with the set of test labels. Our method of assigning canonical names to clusters based on pooling over mentions is not. To resolve this mismatch we pool over the gold labels associated with these mentions instead of the mentions themselves. This is only done for evaluation.
+
+Unsupervised clustering of mentions in $D_{\text{adapt}}$ may suffer from two kinds of errors: i) Clusters can be incomplete, e.g., mentions of a single entity can be split into multiple clusters which can lead to indexing the same entity multiple times and ii) Clusters can be impure, e.g., mentions of different entities end in the same cluster, which leads to confusion of multiple entities into one representation.
+
+In our evaluation we use the gold labels for computing standard EL metrics by associating possibly more than one cluster to each $E_{U}$ , and consider a prediction correct if a mention is linked to any of the clusters associated with the correct entity. EL metrics could fail to capture shortcomings in establishing co-references between mentions though, therefore we report clustering metrics alongside EL metrics. We follow Agarwal et al. (2021) and report normalized mutual information (NMI).
+
+# 6 EDIN-benchmark
+
+To construct the entity index, we download Wikipedia dumps from $t_1$ and $t_2$ and extract entity titles and descriptions. Setting $t_1$ to September 2019 (the date when BLINK was trained) the KB consists of 5.9M entities, setting $t_2$ to March 2022 an additional set of 0.7M entities is introduced.
+
+Wikipedia and Oscar data is created as follows.
+
+Wikipedia: Since usually only the first mention of an entity inside a Wikipedia article is hyperlinked, we annotate a subset of Wikipedia. We use a version of L that was trained at t2 on a labelled non-public dataset. While noisy, these predictions are significantly better than what our best discovery and indexing methods can achieve, therefore we adopt them as pseudo-labels for the purpose of comparing approaches. As discovery and indexing methods improve, manual labelling of the evaluation data will afford more accurate measures. Wikipedia provides time stamps which enables us to separate two time splits.
+
+OSCAR news: This dataset is based on the common-crawl dataset OSCAR (Abadji et al., 2021). We select a subset of English language news pages which we label automatically as described above. The dataset consists of 797k samples, which we split based on their publication date. We publish this dataset using stand-off annotations and code to download the relevant raw data. To enable evaluation of future versions of PLMs and EL systems, we also publish our data processing scripts.
+
+For both types of datasets we publish two time splits: $D_{1}$ , containing samples preceding $t1$ , which is used to train model $L_{t1}$ and $D_{2}$ , with samples preceding $t2$ , which is used to train an upper bound model $L_{t2}$ . To adapt $L_{t1}$ , we hold out a subset of data from between $t1$ and $t2$ to construct $D_{adapt}$ ( $D_{adapt} \cap D_{2} = \emptyset$ ). Remaining samples are randomly split into train, dev, test. Figure 2 illustrates the different data splits. Overall dataset statistics are listed in Table 1.
+
+To construct $D_{\text{adapt}}$ , we follow Agarwal et al. (2021), and set the ratio of mentions of type $E_U$ to $E_K$ to 0.1. As $D_{t2}$ -test covers both known and unknown entities, we use this dataset for EDIN-pipeline evaluation. In Oscar $D_{t2}$ -test, the average number of mentions per $E_U$ is 5.6 and it is ten
+
+times lower than for $E_K$ . COVID-19 is the most occurring unknown entity with 12k mentions. 638k $E_U$ are not mentioned at all and only 733 are mentioned more than ten times.
+
+# 7 Results and Discussion
+
+In the following sections, we discuss results for OSCAR data. Results on Wikipedia data are consistent but lower and shown in appendix F. Our main findings are shown in Table 3 where we report end-to-end performance on OSCAR $D_{t2}$ -test. Overall, our results show:
+
+- EDIN-benchmark is challenging. Particularly attributed to imperfect discovery, end-to-end performance in terms of recall lacks significantly behind the upper bound, see 7.5.
+- When contrasting with zs EL, we find that i) adapting the model to the updated index by re-training the model after indexing is crucial, see 7.2 and ii) entity encodings relying on clusters of mentions in context instead of human crafted descriptions have high potential but discovering these clusters is challenging, see 7.4.1.
+- Our best performing system relies on Cluster-based indexing, with the advantage of attending to and unifying the information of multiple mentions, see 7.4. We call this version the EDIN-pipeline.
+
+In what to come, we first discuss upper and lower performance bounds. Then, we follow our two-step pipeline where we first present results on discovery and indexing separately and then assemble the full end-to-end pipeline.
+
+Recall our terminology:
+
+- Cluster-based: $E_{U}$ encodings rely on mentions in context which are concatenated and embedded into a single encoding.
+- Mention-based: $E_{U}$ encodings rely on individually indexed mentions in context.
+- Description-based: $E_{U}$ encodings rely on human crafted descriptions. This type of indexing is used in the zs setting.
+
+# 7.1 Lower and upper bounds
+
+Our starting point, and an obvious lower performance bound, is given by model $L_{t1}$ trained at $D_{t1}$ . This model lacks representations of $E_U$ and its training data does not contain any corresponding mentions. Therefore, performance on the subset of $E_U$ is 0 for all metrics.
+
+For an upper performance bound we take model $L_{t2}$ trained at $D_{t2}$ . The entities in $E_U$ were introduced to Wikipedia past $t_1$ but before $t_2$ , meaning that to $L_{t2}$ these entities are actually known: labeled mentions of $E_U$ are part of the training data and entity representations are part of the index.
+
+$L_{t2}$ reaches similar performance as $L_{t1}$ for $E_K$ . We suspect performance differences can be attributed to the difference in training data.
+
+Performance of $L_{t2}$ on mentions of $E_U$ is lower than on mentions of $E_K$ . The performance discrepancy between $E_U$ and $E_K$ is largely due to frequency differences, see Table 2. We suspect that the remaining difference can be attributed to the degradation of PLM and entity encoder. Note that while labelled mentions of $E_U$ were seen during the training phase of $L_{t2}$ , BLINK's entity encoder was not re-trained. To investigate this hypothesis further, we test $L_{t1}$ on mentions of $E_K$ that meet two conditions: i) time stamps of these samples are posterior to $t1$ and ii) two or more mentions of $E_U$ occur in their context. Thus, we target mentions of $E_K$ in novel contexts to which neither BLINK nor the PLM have been exposed. The total number of entities that meet these conditions are 40,055. We find that recall drops only slightly from 80.1 to 79.9 but precision drops from 82.0 to 75.9. This result indicates that $E_U$ are also a source of noise when trying to link mentions of $E_K$ .
+
+# 7.2 Additional upper bound: Zero-shot EL
+
+Zs EL relies on Description-based indexing. It may be a valid option in some practical settings, where we may e.g. be able to frequently download fresh Wikipedia snapshots and rerun all or part of the training, but it does not meet the conditions for being a valid entry to EDIN-benchmark, because it relies on supervision for deciding what novel entities to add to the index, and because it requires manually written descriptions for such entities. For these reasons, we present it here as an additional upper bound comparison point.
+
+We note that in the zs problem, all entities are part of the index at training time. In the setting
+
+ | Known Entities | Unknown Entities | Unknown Entities filtered |
| Model | R | P | NMI | R | P | NMI | R | P | NMI |
| Lt1(lower bound) | 80.1 | 82.0 | 93.5 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 | 0.0 |
| Lt2(upper bound) | 78.7 | 79.7 | 93.1 | 49.2 | 31.8 | 93.8 | 63.1 | 26.0 | 93.4 |
| Lt1-Descp (zs setting) | 80.2 | 82.6 | 93.5 | 46.5 | 32.4 | 93.8 | 58.3 | 26.2 | 90.5 |
| Lt1-Mention-Oracle | 80.6 | 81.5 | 93.3 | 24.0 | 46.6 | 87.0 | 40.7 | 46.6 | 87.0 |
| Lt1-Mention | 80.3 | 81.9 | 93.4 | 20.5 | 43.7 | 87.6 | 34.5 | 43.5 | 88.7 |
| Lt1-Cluster-Oracle | 80.3 | 82.0 | 94.2 | 30.5 | 51.8 | 85.9 | 51.8 | 51.8 | 85.9 |
| EDIN-pipeline (Lt1-Cluster) | 80.3 | 81.9 | 93.4 | 20.8 | 43.1 | 85.9 | 35.4 | 43.1 | 85.3 |
+
+of EDIN-benchmark, indexing happens after training. We run the following experiments to study the effect this difference has:
+
+- Not Re-trained: Description-based entity representations are added to the index without re-training $L_{t1}$ after indexing.
+- Re-trained: Description-based entity representations are added to the index with retraining $L_{t1}$ after indexing.
+
+Recall and precision of $E_{U}$ with Re-trained is $46.5\%$ and $32.4\%$ respectively, see Table 4. Recall and precision with Not Re-trained is $26\%$ and $17\%$ points lower respectively.
+
+We note that unknown entities can potentially be placed in close proximity to known ones in embedding space. When these entity encodings are present during training, they can be picked up as hard negatives and the mention encoder can learn to circumvent them. This hypothesis is supported by experiments showing that the mean similarity between mentions and correct known entity embeddings increases significantly when the mention encoder is re-trained after adding the new entities. For details see the appendix D.
+
+The take-away for the EDIN-pipeline is that, after adding new entity representations to the index, another round of training is needed to adapt the mention encoder to the updated index. We adopt this approach for the following experiments.
+
+Besides adapting the mention encoder, re-training BLINK could have a similar effect: in such case learning from hard negative can affect the spacing of entity encodings. As re-training BLINK is expensive, we did not explore this option.
+
+Table 3: EL performance on OSCAR $D_{t2}$ -test for unknown entities $E_U$ and known entities $E_K$ . Left shows end-to-end performance; Right shows filtered performance where mentions of $E_U$ not part of $D_{adapt}$ are dropped from test. Upper/Lower bounds: $L_{t1}$ , trained at $t1$ , uses Description-based entity encodings and constitutes the lower bound. It lacks encodings of $E_U$ . $L_{t2}$ , trained at $t2$ , uses Description-based entity encodings and constitutes the upper bound. $E_U$ are part of the index and their labeled mentions are part of training. $L_{t1}$ -Descp adapts $L_{t1}$ by adding Description-based entity encodings of $E_U$ to the index. As it relies on human discovery and descriptions it constitutes an additional upper bound. Adaptation: For $L_{t1}$ -Mention Mention-based encodings of i) oracle $E_U$ and ii) discovered $E_U'$ part of $D_{adapt}$ are added to $L_{t1}$ 's entity index. For $L_{t1}$ -Cluster Cluster-based encodings of i) oracle $E_U$ and discovered $E_U'$ part of $D_{adapt}$ are added to $L_{t1}$ 's entity index.
+
+ | Unknown Entities | Known Entities |
| R | P | NMI | R | P | NMI |
| Not re-trained | 20.6 | 15.5 | 95.2 | 80.1 | 82.3 | 93.5 |
| Re-trained | 46.5 | 32.4 | 93.8 | 80.2 | 82.6 | 93.5 |
+
+Table 4: Adapting the model to the updated index: End-to-end EL performance on OSCAR $D_{t2}$ -test when adding Description-based representation of unknown entities $E_U$ to the entity index with (Re-trained) and without (Not re-trained) re-training of $L_{t1}$ .
+
+# 7.3 EDIN Discovery
+
+First condition for effective discovery is the ability to reliably detect mentions of both $E_K$ and $E_U$ . Recall of $L_{t1}$ on $D_{adapt}$ for MD task is $90\%$ for $E_K$ and $86\%$ for $E_U$ . As expected, recall of mentions of $E_K$ is higher as no mentions of $E_U$ were seen during training. As a reference, running $L_{t2}$ on $D_{adapt}$ we find that for both $E_K$ and $E_U$ $91\%$ of mentions are recalled. Note again, that for $L_{t2}$ , $E_U$ are known. This indicates that MD is not affected by frequency differences and PLM degradation.
+
+Once mentions are detected, we adopt a clustering approach to classify between mentions of $E_{U}$
+
+and $E_K$ . We measure clustering quality of $91.2\%$ NMI on $D_{adapt}$ . We evaluate discovery based on these clusters by evaluating whether a discovered cluster is indeed referring to an $E_U$ . Note, that here duplicated discovery of the same entity is not penalized. We set the minimum number of mentions per cluster to 3 and report low discovery precision $(10\%)$ but relatively high recall $(86\%)$ . Overall, this results in detecting $71\%$ of all unknown entities part of $D_{adapt}$ .
+
+We find that the constraint requiring that most mentions in a cluster are within a region controlled by hyper-parameter $\tau$ , as described in 4.1, is crucial. In an ablation study we drop this condition and greedily assign $E_K$ to clusters if $sim(\mathbf{e}_i, \mathbf{m}_i) > \tau$ holds for any $m_i \in c_i$ . This setting is similar to Agarwal et al. (2021) where a single entity-mention link is sufficient for cluster assignment. Discovery dropped to $49\%$ recall and $8\%$ precision.
+
+A qualitative error analysis reveals that false negatives are mostly caused by the problem that mention embeddings of $E_{U}$ (e.g. BioNTech) can have high similarity with entity embeddings of $E_{K}$ (e.g. of other biotechnology companies). We suspect that this problem is particularly pronounced in our setting because EDIN-benchmark is large scale (up to 6 times more entities in the reference KB and up to 36 times more mentions in the clustering set compared to Agarwal et al. (2021)) with many tail entities.
+
+Conversely, false positives are mostly due to known entities being misclassified unknown when occurring in novel contexts, e.g., "blood tests" or "vaccine" in context of COVID form distinct clusters. But, low precision in discovery is less problematic than low recall as re-training after indexing gives the ability to learn to ignore clusters of $E_K$ .
+
+# 7.4 EDIN indexing
+
+After discovery, we need mention clusters of $E_U$ to be integrated into the entity index.
+
+We compare Mention-based and Cluster-based indexing. To isolate discovery and indexing performance, we first evaluate indexing using oracle clusters, where we replace the discovery method run on $D_{\text{adapt}}$ with an oracle where mentions of $E_U$ are discovered and clustered perfectly. Mention-based indexing performs worse than Cluster-based indexing with a gap of around $5\%$ points, see Table 3 (left), $L_{t1}$ -Mention-Oracle vs. $L_{t1}$ -Cluster-Oracle. When reducing the test set to mentions of entities
+
+that were actually discoverable, the difference in recall becomes even more pronounced: $41\%$ for Mention-based vs. $52\%$ for Cluster-based indexing, see Table 3 (right).
+
+Interestingly, this means that the ability to attend over multiple mentions in context and unify their information into a single embedding leads to superior representations. Note that here the entity encoder was neither trained to deal with the style of individual mentions in context nor with clusters of mentions in context. For future work, it would be interesting to see if Cluster-based indexing can be generally beneficial to EL, outside of the context of EDIN-pipeline.
+
+# 7.4.1 Cluster-based vs. Description-based
+
+As an upper baseline, we compare Cluster-based indexing with the zs setting which uses Description-based indexing. Zs EL does not rely on $D_{adapt}$ but on a human's decision to add an entry to the index and therefore discovery is perfect. To isolate indexing from discovery, we again filter the test set to actually discoverable entities and assume perfect oracle clusters.
+
+In this setting, see Table 3 (right), we find that Cluster-based-Oracle indexing performs $7\%$ points lower than Description-based indexing in recall but $26\%$ better in terms of precision.
+
+The take-away is that when discovery is perfect, Cluster-based indexing relying on concatenated mentions in context instead of manually crafted descriptions has high potential. In the end-to-end setting, we see that assembling these perfect clusters is challenging.
+
+We also want to emphasise that results in Table 3 show that EL performance on $E_K$ is not affected by this adaptation process. Recall and precision remain, with 80.3 and 81.9, stable. We also test if this finding also holds on standard EL datasets. We compare performance on AIDA test before and after adaptation and report no difference in performance on $E_K$ .
+
+# 7.5 End-to-end pipeline
+
+We assemble the full end-to-end pipeline. We replace oracle clusters of $E_U$ by discovered clusters of $E_U'$ . Errors in discovery that affect indexing are: i) misclassification of clusters as either known or unknown and ii) incomplete and impure clusters. We find that performance of Mention-based and Cluster-based indexing in terms of recall and precision converges and is significantly lower than their
+
+oracle counterparts.
+
+When reducing the test set to mentions of entities that were discoverable, thus part of $D_{\text{adapt}}$ , Cluster-based indexing is 1% point better in terms of recall and 0.4% worse in precision, Table 3 (right). When reducing the test set further to mentions of entities that were in fact discovered, recall of Cluster-based indexing is, with 58.4%, better than that of Mention-based indexing (55.5%).
+
+We also report performance of ED with oracle mention detection in Table 6 in the appendix E. Here, we find that Cluster-based indexing is performing better than Mention-based indexing across all metrics.
+
+We conclude that Cluster-based indexing performs better than Mention-based indexing. We call this version the EDIN-pipeline.
+
+Besides yielding an index that scales in memory with the number of entities rather than the number of mentions - a significant advantage when the number of entities is already large and in view of a streaming extension - Cluster-based indexing generates fixed-size entity embeddings as a by-product that can have applications of their own and can be used to enhance PLMs (e.g., Peters et al. (2019)).
+
+Overall, EDIN-pipeline performance shows that EDIN-benchmark is challenging. In terms of recall, end-to-end performance lacks $26\%$ points behind the upper bound $L_{t2}$ . In this setting, errors in discovery propagate. Most notably, we see this manifest when i) comparing Table 3 unfiltered and filtered where the recall problem of $E_U$ becomes apparent and ii) comparing performance of oracle and automatic clusters where precision drops by $10\%$ points.
+
+In future work, we want to explore a setting where $E_{U}$ are discovered in a streaming fashion, thus scaling up $D_{adapt}$ and dropping the artificially imposed ratio of $E_{K}$ vs. $E_{U}$ . This would pose challenges in terms of scale and precision in discovery. Here, a human in the loop approach, as proposed by Hoffart et al. (2016) in the context of keeping KBs fresh, to introduce a component of supervision, might be needed.
+
+# 8 Related work
+
+EL is an extensively studied task. Prior to the introduction of PLMs, EL systems used frequency and typing information, alias tables, TF-IDF-based methods and neural networks to model context, mention and entity (Cucerzan, 2007; Bunescu and
+
+Paşa, 2006; Milne and Witten, 2008; He et al., 2013; Sun et al., 2015a; Lazic et al., 2015; Raiman and Raiman, 2018; Kolitsas et al., 2018; Gupta et al., 2017; Ganea and Hofmann, 2017; Khalife and Vazirgiannis, 2018; Onoe and Durrett, 2019).
+
+Gillick et al. (2019) present a PLM-based dual encoder architecture that encodes mentions and entities in the same dense vector space and performs EL via kNN search. Logeswaran et al. (2019) proposed the zs EL task and show that domain adaptive training can address the domain shift problem. Subsequently, Wu et al. (2020) showed that pre-trained zs architectures are both highly accurate and computationally efficient at scale. None of these works tackle the problem of unknown entities.
+
+Recently, FitzGerald et al. (2021) model EL entirely as mappings between mentions, where inference involves a NN search against all known mentions of all entities in the training set. In this setting mentions need to be labeled. They do not explore their approach in the setting of unknown entities.
+
+Prior to dense retrieval-based EL, unknown entity discovery work includes: Ratinov et al. (2011) train a classifier to determine whether the top ranked EL candidate is unknown relying on local context, global Wikipedia coherence, and additional manually crafted features. Nakashole et al. (2013) introduce a model for unknown entity discovery and typing leveraging incompatibilities and correlations among entity types. Hoffart et al. (2014); Wu et al. (2016) study a variety of features for unknown entity discovery: Hoffart et al. (2014) use perturbation-based confidence measures and key-phrase representations and Wu et al. (2016) explore different feature spaces, e.g., topical and search engine features. These features are not readily available and incorporating them into PLM-based approaches is not straightforward; Ji et al. (2015); Derczynski et al. (2017) introduce shared tasks for discovery. These tasks are defined on comparatively small datasets and target only named entities; Akasaki et al. (2019) introduces a time sensitive method of discovering emerging entities relying on Twitter data.
+
+None of these works consider unknown entities in an end-to-end setting including mention detection, unknown entity discovery and indexing. Also, we cannot use their datasets to evaluate as these entities were part of training the PLM.
+
+In the context of named entity tagging, Mota and
+
+Grishman (2009) showed that entity taggers can be effectively updated by incorporating contemporary unlabeled data using semi-supervised learning.
+
+Closely related to EL is the task of cross document entity co-reference (CDC), where no reference KB is present (Bagga and Baldwin, 1998; Gooi and Allan, 2004; Singh et al., 2011; Dutta and Weikum, 2015; Barhom et al., 2019; Cattan et al., 2021a; Caciularu et al., 2021; Cattan et al., 2021b). Most recently, Logan IV et al. (2021) benchmark methods for streaming CDC, where mentions are disambiguated in a scalable manner via incremental clustering. Our work can be seen as bridging between the world of CDC and EL.
+
+Most recently, Angell et al. (2021) introduce a new EL method using document-level supervised graph-based clustering. Agarwal et al. (2021) extend this work to cross-document EL and entity discovery. In this work, we adopt a more standard bi-encoder architecture (i.e. BLINK), with better EL scalability potential (memory linear in the number of entities and not in the number of mentions) and an existing end-to-end extension. We use a modified version of their discovery method.
+
+# 9 Conclusion
+
+This work introduced EDIN-benchmark and EDIN-pipeline. EDIN-benchmark is a large-scale, end-to-end EL benchmark with a clear cut temporal segmentation for Unknown Entity Discovery and Indexing. EDIN-pipeline detects and clusters mentions of unknown entities in context. These clusters of unknown mentions are then collapsed into single embeddings and integrated into the entity index of the original EL system.
+
+# Limitations
+
+The main limitations of EDIN-benchmark are: i) The dataset is not human-annotated. Instead we used an upper-bound model to label data automatically. ii) We limit $D_{\text{adapt}}$ in size and artificially adjust class imbalance between mentions of type $E_U$ to $E_K$ . The limited size of $D_{\text{adapt}}$ in turn limits the discoverability of unknown entities, specifically low-frequency ones. Once progress is made in the accuracy and scalability of entity discovery, EDIN-benchmark can be modified to a truly dynamic setting where unknown entities are continuously discovered in a stream of incoming documents and integrated into the EL system.
+
+EDIN-pipeline is tailored to dense-retrieval
+
+based EL and adapting it to different EL approaches, e.g., to generative EL systems De Cao et al. (2021), is not straightforward.
+
+We study EDIN-benchmark and -pipeline in a monolingual setting using English language only. EDIN-benchmark's extension to a multilingual setting is straight forward. OSCAR and Wikipedia data are available in 166 different languages but coverage will be a problem. EDIN-pipeline can be extended to more languages by following (Botha et al., 2020) but EDIN performance is expected to vary across languages as it does for standard EL.
+
+EDIN-benchmark covers news and Wikipedia domain entities only, and we have not evaluated the EDIN-pipeline on other domains.
+
+The overall performance of EDIN-pipeline has ample margins for improvement, with the precision of clustering-based discovery as the main bottleneck at present. The significant number of false positives (mentions of known entities classified as unknown) is still a barrier to deployment in most real-world settings.
+
+# Ethical Considerations
+
+EL is a standard NLP task. Outside of academia EL can be deployed in both non-problematic (e.g., content understanding for hate speech detection) and problematic (e.g., surveillance) settings. Independent of the use-case, potential bias that these models could exhibit needs to be evaluated. EL relies on human curated knowledge bases (here Wikipedia) which could carry bias e.g. in terms of language, genders and races, see for example Sun and Peng (2021). Another source of bias in the context of dense-retrieval based EL, is the bias of the underlying language model (here BERT). Both potential sources of bias could be propagated to the down-stream task. To mitigate biases, we refer to Goldfarb-Tarrant et al. (2021); Steed et al. (2022) that show bias mitigation needs to be done on the side of the downstream task rather than the language model. Rudinger et al. (2018); Zhao et al. (2018) introduce methods of downstream bias mitigation, here in the context of co-reference resolution.
+
+We publish our dataset/scripts that generate the datasets. Our dataset is based on English Wikipedia and a subset of English online news pages extracted from OSCAR. All Wikipedia based data is made fully available. OSCAR is common-crawl based data and only available to researchers upon
+
+request. We release code and stand-off annotations which enables researchers to reproduce the dataset. Our EL annotations rely on an upper bound model which is due to the performance gap sufficient for EDIN but should not be considered gold data for general EL tasks. We will indicate this prominently on the website we use to host the data.
+
+# Acknowledgements
+
+We thank our colleagues Louis Martin and Frederic Dreyer for their valuable feedback.
+
+# References
+
+Julien Abadji, Pedro Javier Ortiz Suárez, Laurent Romary, and Benoit Sagot. 2021. Ungoliant: An optimized pipeline for the generation of a very largescale multilingual web corpus. Proceedings of the Workshop on Challenges in the Management of Large Corpora (CMLC-9) 2021. Limerick, 12 July 2021 (Online-Event), pages 1 - 9, Mannheim. Leibniz-Institut für Deutsche Sprache.
+Dhruv Agarwal, Rico Angell, Nicholas Monath, and Andrew McCallum. 2021. Entity linking and discovery via arborescence-based supervised clustering.
+Oshin Agarwal and Ani Nenkova. 2021. Temporal effects on pre-trained models for language processing tasks.
+Satoshi Akasaki, Naoki Yoshinaga, and Masashi Toyoda. 2019. Early discovery of emerging entities in microblogs. In Proceedings of the Twenty-Eighth International Joint Conference on Artificial Intelligence, IJCAI 2019, Macao, China, August 10-16, 2019, pages 4882-4889. ijcai.org.
+Rico Angell, Nicholas Monath, Sunil Mohan, Nishant Yadav, and Andrew McCallum. 2021. Clustering-based inference for biomedical entity linking. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 2598-2608, Online. Association for Computational Linguistics.
+Amit Bagga and Breck Baldwin. 1998. Entity-based cross-document coreferencing using the vector space model. In Proceedings of the 36th Annual Meeting of the Association for Computational Linguistics and 17th International Conference on Computational Linguistics - Volume 1, ACL '98/COLING '98, page 79-85, USA. Association for Computational Linguistics.
+Shany Barhom, Vered Shwartz, Alon Eirew, Michael Bugert, Nils Reimers, and Ido Dagan. 2019. Revisiting joint modeling of cross-document entity and event coreference resolution. In Proceedings of the
+
+57th Annual Meeting of the Association for Computational Linguistics, pages 4179-4189, Florence, Italy. Association for Computational Linguistics.
+Jan A. Botha, Zifei Shan, and Daniel Gillick. 2020. Entity Linking in 100 Languages. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 7833-7845, Online. Association for Computational Linguistics.
+Razvan Bunescu and Marius Paşa. 2006. Using encyclopedic knowledge for named entity disambiguation. In 11th Conference of the European Chapter of the Association for Computational Linguistics, pages 9-16, Trento, Italy. Association for Computational Linguistics.
+Avi Caciularu, Arman Cohan, Iz Beltagy, Matthew Pe- ters, Arie Cattan, and Ido Dagan. 2021. CDLM: Cross-document language modeling. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 2648-2662, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Yixin Cao, Lei Hou, Juan-Zi Li, and Zhiyuan Liu. 2018. Neural collective entity linking. In COLING.
+Arie Cattan, Alon Eirew, Gabriel Stanovsky, Mandar Joshi, and Ido Dagan. 2021a. Realistic evaluation principles for cross-document coreference resolution. In Proceedings of *SEM 2021: The Tenth Joint Conference on Lexical and Computational Semantics*, pages 143-151, Online. Association for Computational Linguistics.
+Arie Cattan, Sophie Johnson, Daniel S. Weld, Ido Dagan, Iz Beltagy, Doug Downey, and Tom Hope. 2021b. Scico: Hierarchical cross-document coreference for scientific concepts. In 3rd Conference on Automated Knowledge Base Construction.
+Silviu Cucerzan. 2007. Large-scale named entity disambiguation based on Wikipedia data. In Proceedings of the 2007 Joint Conference on Empirical Methods in Natural Language Processing and Computational Natural Language Learning (EMNLP-CoNLL), pages 708-716, Prague, Czech Republic. Association for Computational Linguistics.
+Nicola De Cao, Gautier Izacard, Sebastian Riedel, and Fabio Petroni. 2021. Autoregressive entity retrieval. In International Conference on Learning Representations.
+Leon Derczynski, Eric Nichols, Marieke van Erp, and Nut Limsopatham. 2017. Results of the WNUT2017 shared task on novel and emerging entity recognition. In Proceedings of the 3rd Workshop on Noisy User-generated Text, pages 140-147, Copenhagen, Denmark. Association for Computational Linguistics.
+
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Bhuwan Dhingra, Jeremy Cole, Julian Eisenschlos, Daniel Gillick, Jacob Eisenstein, and William Cohen. 2022. Time-aware language models as temporal knowledge bases. Transactions of the Association for Computational Linguistics, 10(0):257-273.
+Sourav Dutta and Gerhard Weikum. 2015. Cross-document co-reference resolution using sample-based clustering with knowledge enrichment. Transactions of the Association for Computational Linguistics, 3:15-28.
+Nicholas FitzGerald, Dan Bikel, Jan Botha, Daniel Gillick, Tom Kwiatkowski, and Andrew McCallum. 2021. MOLEMAN: Mention-only linking of entities with a mention annotation network. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 278-285, Online. Association for Computational Linguistics.
+Octavian-Eugen Ganea and Thomas Hofmann. 2017. Deep joint entity disambiguation with local neural attention. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 2619-2629, Copenhagen, Denmark. Association for Computational Linguistics.
+Daniel Gillick, Sayali Kulkarni, Larry Lansing, Alessandro Presta, Jason Baldridge, Eugene Ie, and Diego Garcia-Olano. 2019. Learning dense representations for entity retrieval. In Proceedings of the 23rd Conference on Computational Natural Language Learning (CoNLL), pages 528-537, Hong Kong, China. Association for Computational Linguistics.
+Seraphina Goldfarb-Tarrant, Rebecca Marchant, Ricardo Muñoz Sánchez, Mugdha Pandya, and Adam Lopez. 2021. Intrinsic bias metrics do not correlate with application bias. In ACL.
+Chung Heong Gooi and James Allan. 2004. Cross-document coreference on a large scale corpus. In Proceedings of the Human Language Technology Conference of the North American Chapter of the Association for Computational Linguistics: HLT-NAACL 2004, pages 9–16, Boston, Massachusetts, USA. Association for Computational Linguistics.
+Nitish Gupta, Sameer Singh, and Dan Roth. 2017. Entity linking via joint encoding of types, descriptions, and context. In Proceedings of the 2017 Conference
+
+on Empirical Methods in Natural Language Processing, pages 2681-2690, Copenhagen, Denmark. Association for Computational Linguistics.
+Zhengyan He, Shujie Liu, Mu Li, Ming Zhou, Longkai Zhang, and Houfeng Wang. 2013. Learning entity representation for entity disambiguation. In Proceedings of the 51st Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 30-34, Sofia, Bulgaria. Association for Computational Linguistics.
+Johannes Hoffart, Yasemin Altun, and Gerhard Weikum. 2014. Discovering emerging entities with ambiguous names. In Proceedings of the 23rd International Conference on World Wide Web, WWW '14, page 385-396, New York, NY, USA. Association for Computing Machinery.
+Johannes Hoffart, Dragan Milchevski, Gerhard Weikum, Avishek Anand, and Jaspreet Singh. 2016. The knowledge awakens: Keeping knowledge bases fresh with emerging entities. Proceedings of the 25th International Conference Companion on World Wide Web.
+Heng Ji, Joel Nothman, Ben Hachey, and Radu Florian. 2015. Overview of TAC-KBP2015 tri-lingual entity discovery and linking. In Proceedings of the 2015 Text Analysis Conference, TAC 2015, Gaithersburg, Maryland, USA, November 16-17, 2015, 2015. NIST.
+Jeff Johnson, Matthijs Douze, and Hervé Jégou. 2017. Billion-scale similarity search with gpus. arXiv preprint arXiv:1702.08734.
+Sammy Khalife and Michalis Vazirgiannis. 2018. Scalable graph-based individual named entity identification. CoRR, abs/1811.10547.
+Nikolaos Kolitsas, Octavian-Eugen Ganea, and Thomas Hofmann. 2018. End-to-end neural entity linking. In Proceedings of the 22nd Conference on Computational Natural Language Learning, pages 519-529, Brussels, Belgium. Association for Computational Linguistics.
+Angeliki Lazaridou, Adhi Kuncoro, Elena Gribovskaya, Devang Agrawal, Adam Liska, Tayfun Terzi, Mai Gimenez, Cyprien de Masson d'Autume, Tomas Kocisky, Sebastian Ruder, Dani Yogatama, Kris Cao, Susannah Young, and Phil Blunsom. 2021. Mind the gap: Assessing temporal generalization in neural language models. In Advances in Neural Information Processing Systems, volume 34, pages 29348-29363. Curran Associates, Inc.
+Nevena Lazic, Amarnag Subramanya, Michael Ringgaard, and Fernando Pereira. 2015. Plato: A selective context model for entity resolution. Transactions of the Association for Computational Linguistics, 3:503-515.
+Martin Josifoski Sebastian Riedel Luke Zettlemoyer Ledell Wu, Fabio Petroni. 2020. Zero-shot entity linking with dense entity retrieval. In EMNLP.
+
+Belinda Z. Li, Sewon Min, Srinivasan Iyer, Yashar Mehdad, and Wen-tau Yih. 2020. Efficient one-pass end-to-end entity linking for questions. In EMNLP.
+Robert L Logan IV, Andrew McCallum, Sameer Singh, and Dan Bikel. 2021. Benchmarking scalable methods for streaming cross document entity coreference. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4717-4731, Online. Association for Computational Linguistics.
+Lajanugen Logeswaran, Ming-Wei Chang, Kenton Lee, Kristina Toutanova, Jacob Devlin, and Honglak Lee. 2019. Zero-shot entity linking by reading entity descriptions. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3449-3460, Florence, Italy. Association for Computational Linguistics.
+David N. Milne and Ian H. Witten. 2008. Learning to link with wikipedia. In CIKM '08.
+Cristina Mota and Ralph Grishman. 2009. Updating a name tagger using contemporary unlabeled data. In Proceedings of the ACL-IJCNLP 2009 Conference Short Papers, pages 353-356, Suntec, Singapore. Association for Computational Linguistics.
+Ndapandula Nakashole, Tomasz Tylenda, and Gerhard Weikum. 2013. Fine-grained semantic typing of emerging entities. In Proceedings of the 51st Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1488-1497, Sofia, Bulgaria. Association for Computational Linguistics.
+Yasumasa Onoe and Greg Durrett. 2019. Fine-grained entity typing for domain independent entity linking. CoRR, abs/1909.05780.
+Yasumasa Onoe and Greg Durrett. 2020. Fine-grained entity typing for domain independent entity linking. In AAAI.
+Matthew E Peters, Mark Neumann, Robert Logan, Roy Schwartz, Vidur Joshi, Sameer Singh, and Noah A Smith. 2019. Knowledge enhanced contextual word representations. In *Conference on Empirical Methods in Natural Language Processing* and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP).
+Jonathan Raiman and Olivier Raiman. 2018. Deep-type: Multilingual entity linking by neural type system evolution. In AAAI.
+Lev Ratinov, Dan Roth, Doug Downey, and Mike Anderson. 2011. Local and global algorithms for disambiguation to Wikipedia. In Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies, pages 1375-1384, Portland, Oregon, USA. Association for Computational Linguistics.
+
+Rachel Rudinger, Jason Naradowsky, Brian Leonard, and Benjamin Van Durme. 2018. Gender bias in coreference resolution. In *NAACL*.
+Sameer Singh, Amarnag Subramanya, Fernando Pereira, and Andrew McCallum. 2011. Large-scale cross-document coreference using distributed inference and hierarchical models. In Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies, pages 793-803, Portland, Oregon, USA. Association for Computational Linguistics.
+Ryan Steed, Swetasudha Panda, Ari Kobren, and Michael L. Wick. 2022. Upstream mitigation is not all you need: Testing the bias transfer hypothesis in pre-trained language models. In ACL.
+Jiao Sun and Nanyun Peng. 2021. Men are elected, women are married: Events gender bias on wikipedia. ArXiv, abs/2106.01601.
+Yaming Sun, Lei Lin, Duyu Tang, Nan Yang, Zhenzhou Ji, and Xiaolong Wang. 2015a. Modeling mention, context and entity with neural networks for entity disambiguation. In *IJCAI*.
+Yaming Sun, Lei Lin, Duyu Tang, Nan Yang, Zhenzhou Ji, and Xiaolong Wang. 2015b. Modeling mention, context and entity with neural networks for entity disambiguation. In Proceedings of the 24th International Conference on Artificial Intelligence, IJCAI'15, page 1333-1339. AAAI Press.
+Ledell Yu Wu, Fabio Petroni, Martin Josifoski, Sebastian Riedel, and Luke Zettlemoyer. 2020. Scalable zero-shot entity linking with dense entity retrieval. In EMNLP.
+Zhaohui Wu, Yang Song, and C. Lee Giles. 2016. Exploring multiple feature spaces for novel entity discovery. In AAAI.
+Jieyu Zhao, Tianlu Wang, Mark Yatskar, Vicente Ordonez, and Kai-Wei Chang. 2018. Gender bias in coreference resolution: Evaluation and debiasing methods. In NAACL.
+
+# A Model
+
+In the following sections, we explain our model's architecture in detail. It relies on Blink's bi-encoder architecture (680M parameters). The model can be downloaded from:
+
+https://github.com/facebookresearch/ BLINK
+
+The code for clustering is located here:
+
+https://github.com/rloganiv/ streaming-cdc
+
+# A.1 Mention Detection
+
+For every span $[i,j]$ , the MD head calculates the probability of $[i,j]$ being the mention of an entity by scoring whether $i$ is the start of the mention, $j$ is the end of the mention, and the tokens between $i$ and $j$ are the insides:
+
+$$
+\begin{array}{l} s _ {s t a r t (i)} = \mathbf {w} _ {s t a r t} ^ {T} \mathbf {p} _ {i} \\ s _ {e n d (j)} = \mathbf {w} _ {e n d} ^ {T} \mathbf {p} _ {j} \\ s _ {m e n t i o n (t)} = \mathbf {w} _ {m e n t i o n} ^ {T} \mathbf {p} _ {t} \\ \end{array}
+$$
+
+where $\mathbf{w}_{start},\mathbf{w}_{end},\mathbf{w}_{mention}$ are learnable vectors and $\mathbf{p}_i$ paragraph token representations based on BERT:
+
+$$
+[ \mathbf {p} _ {1} \dots \mathbf {p} _ {n} ] = B E R T ([ C L S ] p _ {1} \dots p _ {n} [ S E P ])
+$$
+
+Overall mention probabilities are computed as:
+
+$$
+p ([ i, j ]) = \sigma (s _ {s t a r t (i)} + s _ {e n d (j)} + \sum_ {t = i} ^ {j} (s _ {m e n t i o n (t)}))
+$$
+
+Top candidates are selected as mention candidates and propagate to the next step.
+
+# A.2 Entity Disambiguation
+
+The ED head receives mention spans in the text and finds the best matching entity in the KB.
+
+Following Wu et al. (2020), ED is based on dense retrieval. Description-based entity representations are computed as follows:
+
+$$
+\mathbf {e} = B E R T _ {[ C L S ]} ([ C L S ] t (e) [ S E P ] d (e) [ S E P ])
+$$
+
+Following Li et al. (2020), mention representations are constructed with one pass of the encoder and
+
+without mention boundary tokens by pooling mention tokens through a single feed-forward layer (FFL) from the encoder output:
+
+$$
+\mathbf {m} _ {i, j} = F F L \left(\mathbf {p} _ {i} \dots \mathbf {p} _ {j}\right)
+$$
+
+Similarity score $s$ between the mention candidate and an entity candidate $e \in E$ are computed:
+
+$$
+s (e, [ i, j ]) = \mathbf {e} * \mathbf {m} _ {i, j}
+$$
+
+A likelihood distribution over all entities, conditioned on the mention $[i,j]$ is computed:
+
+$$
+p (e | [ i, j ]) = \frac {e x p (s (e , [ i , j ]))}{\sum_ {e ^ {\prime} \in E} e x p (s (e ^ {\prime} , [ i , j ]))}
+$$
+
+$< [i,j],e^{*}>$ , such that
+
+$$
+e ^ {*} = a r g m a x _ {e} (p ([ i, j ], e)),
+$$
+
+are passed as a candidate $<$ mention span, entity $>$ tuple to the rejection head.
+
+# A.3 Rejection head
+
+MD and ED steps over-generate. R looks at an $(e^{*},[i,j])$ pair holistically decides whether to accept it. Input features to R are the MD score $p([i,j])$ , the ED score $p(e^{*}|[i,j])$ , the mention representation $\mathbf{y}_{i,j}$ , top-ranked candidate representation $\mathbf{x}_{e^{*}}$ as well as their difference and Hadamard product. The concatenation of these features is fed through a feed-forward network to output the final entity linking score $p([i,j],e^{*})$ . All $p([i,j],e^{*}) > \gamma$ are accepted where $\gamma$ is a threshold set to 0.4.
+
+# A.4 Training
+
+Following prior work (Sun et al., 2015b; Cao et al., 2018; Gillick et al., 2019; Onoe and Durrett, 2020), training is split into two stages. First, ED only is trained on a Wikipedia dataset. This dataset is constructed by extracting Wikipedia hyperlinks to labeled mention-entity pairs and consists of 17M training samples. Then, ED, MD and R are trained jointly on the downstream dataset (either Oscar or Wikipedia). Outputs from one component are fed as input to the next and losses are summed together. To train the ED head, frozen entity representations are used. As entity embeddings do not change during training, entity embeddings can be indexed using quantization algorithms for a fast kNN search (using FAISS (Johnson et al., 2017) framework with HNSW index). A likelihood distribution over positive and mined hard negative entities for each
+
+| Parameter | Value |
| dm | 0.8171 |
| sm | 0.5 |
| de | 110 |
+
+Table 5: Hyper-parameters adaptation phase
+
+mention is computed. Negative Log-Likelihood loss across all gold mentions in the text is used.
+
+To train MD, binary cross-entropy loss between all possible valid spans and gold mentions in the training set is computed. Valid spans are spans with begin $<$ end, less than a maximum length, and we also filter out spans that start or end in the middle of the word.
+
+To train R, binary cross-entropy loss between retrieved mention-entity pairs and gold mention-entity pairs is used.
+
+Outputs from one component are fed as input to the next and losses are summed together.
+
+# B OSCAR-based dataset
+
+OSCAR data can be downloaded here:
+
+https://oscar-corpus.com/
+
+We select the following six online news pages:
+
+BBC: https://www.bbc.com/
+
+CNN: https://www.cnn.com/
+
+Deutsche Welle: https://www.dw.com/en/
+
+Reuters: https://www.reuters.com/article/
+
+Guardian: https://www.theguardian.com/
+
+Associated Press: https://apnews.com/article/
+
+# C Hyper-parameters adaptation phase
+
+Using OSCAR $D_{adapt}$ -dev, we optimize mention score threshold $s_m$ , greedy NN distance threshold $d_m$ and mention entity similarity threshold $d_e$ .
+
+We optimize $s_m$ in range 0.0 to 1.0 in steps of 0.1 for $E_U$ discovery recall. We optimize $d_m$ in range 0.5 to 1.0, in steps of 0.0001 for NMI. We optimize $d_e$ for $E_U$ discovery recall in range 50 to 250 in steps of 10. For results, see Table 5.
+
+We report recall of $81\%$ and precision of $6\%$ for clusters referring to unknown entities. Recall of clusters referring to known entities is $88\%$ with precision $96\%$ . Clustering NMI is 0.92.
+
+# D Adapting to the updated index
+
+We show that by re-training L after indexing, L learns to circumvent $E_{U}$ : We identify known entities part of the training set that are in close proximity of unknown entities (confusable known entities). We compare the average similarity between mentions and their respective linked entity when adding unknown entities before training vs. after training. Mean similarity when adding unknown entities before training is 93.28 for confusable known entities and 92.57 for other known entities. A t-test shows that this difference is significant (p-value of 0.0001 with $< 0.05$ ). As a reference, mean similarity when adding unknown entities post training is 92.65 irrespective of whether they are confusable or not.
+
+# E Disambiguation Results
+
+Besides end-to-end performance, we also report entity disambiguation performance with oracle mention detection in Table 6.
+
+# F Wikipedia Results
+
+We report performance on Wikipedia $D_{t2}$ -test in Table 7. Due to a smaller $D_{adapt}$ , end-to-end performance is lower. When filtering Wikipedia $D_{t2}$ -test for mentions of discovered entities, $L_{t1}$ -Cluster-Oracle precision is 40.5 and $L_{t1}$ -Cluster recall is 15.3.
+
+# G Infrastructure, Training and Inference Details
+
+We ran all training distributed across 8 NVIDIA TESLA V100 GPUs, each with 32 GB of memory. The first training stage took 48h, the second one 12h.
+
+Adaptation phase is currently limited by expensive greedy NN clustering with quadratic time complexity but the type of clustering is interchangeable for more efficient ones. We chose this type of clustering as Logan IV et al. (2021) showed it performs decently for BLINK based mention encodings.
+
+| Model | OSCAR |
| Unknown Entities | Known Entities |
| R | P | NMI | R | P | NMI |
| LDt1 | 0.0 | 0.0 | 0.0 | 92.2 | 92.2 | 96.0 |
| LDt2 | 63.5 | 45.3 | 96.8 | 90.0 | 90.2 | 96.0 |
| Lt1-Descp | 58.0 | 33.9 | 96.3 | 92.1 | 92.3 | 96.1 |
| Lt1-Mention | 26.2 | 30.8 | 92.7 | 92.2 | 92.2 | 96.0 |
| EDIN (Lt1-Cluster) | 27.9 | 34.1 | 93.4 | 92.2 | 92.2 | 96.2 |
+
+Table 6: Entity Disambiguation performance on OSCAR $D_{t2}$ -test.
+
+ | Unknown Entities | Known Entities |
| Model | R | P | NMI | R | P | NMI |
| Lt1 | 0.0 | 0.0 | 0.0 | 70.5 | 75.8 | 95.4 |
| Lt2 | 33.6 | 25.0 | 98.3 | 70.6 | 75.4 | 95.3 |
| Lt1-Descp | 33.9 | 20.0 | 98.0 | 71.2 | 74.4 | 95.3 |
| Lt1-Cluster-Oracle | 7.8 | 55.6 | 90.6 | 70.1 | 75.9 | 95.6 |
| EDIN (Lt1-Cluster) | 1.8 | 15.4 | 93.4 | 71.1 | 74.1 | 95.3 |
+
+Table 7: End-to-end EL performance on Wikipedia $D_{t2}$ -test.
+
+
+Figure 2: Dataset splits: A schema illustrating the composition of $D_{t1}$ and $D_{t2}$ . Note, that contrary to what this plot suggests, the number of samples per data split is equal for $D_{t1}$ and $D_{t2}$ .
\ No newline at end of file
diff --git a/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/images.zip b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..12ee013d2a8809b040c5d680b57324ace5da2641
--- /dev/null
+++ b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:997ae3cd0c1b30505649638a824b5e5e7420cd3953e51b89b28acea6b3d15936
+size 366742
diff --git a/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/layout.json b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d2837e5c294938cd0bb5926bdfe87edfc876b3fb
--- /dev/null
+++ b/edinanendtoendbenchmarkandpipelineforunknownentitydiscoveryandindexing/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ffdadcef18ecb5d455f4480bf04dbf4986b293e4dfc375b14ec507e7176f0ac3
+size 674369
diff --git a/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_content_list.json b/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..0c3b34e017a2f167a4ce1adbf31f8d6869f98870
--- /dev/null
+++ b/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4cb36f2594c8c7db9100cc3429fe34fbdf3a5ef2b8e308ed644b5a9ec47d0202
+size 59701
diff --git a/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_model.json b/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..0fc451260dc03b0bad59a3ef0783d64aef17b51c
--- /dev/null
+++ b/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bbdd35272ea894dd7c985c0d4bcd8380bbfcfb5cab550ebdf1ac39583309375c
+size 66848
diff --git a/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_origin.pdf b/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..848f6608726e414ad65a6d61e1a2738e4b4b4a3d
--- /dev/null
+++ b/eenymeenyminymoehowtochoosedataformorphologicalinflection/48bd7716-d084-4b6b-8354-08a56d7a9b7d_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bc4fb649410fc29a10e1574cd169eda2883297aaf1a1e4ea60c70f5bda9b3235
+size 289945
diff --git a/eenymeenyminymoehowtochoosedataformorphologicalinflection/full.md b/eenymeenyminymoehowtochoosedataformorphologicalinflection/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..b690dd678c4b45dd6d2f8a940ea328dda7eb34d0
--- /dev/null
+++ b/eenymeenyminymoehowtochoosedataformorphologicalinflection/full.md
@@ -0,0 +1,162 @@
+# Eeny, meeny, miny, moe. How to choose data for morphological inflection
+
+Saliha Muradoglu\*Mans Hulden
+
+$^{\alpha}$ The Australian National University (ANU) $^{\chi}$ University of Colorado
+
+$\kappa$ ARC Centre of Excellence for the Dynamics of Language (CoEDL)
+
+saliha.muradoglu@anu.edu.au, mans.hulden@colorado.edu
+
+# Abstract
+
+Data scarcity is a widespread problem in numerous natural language processing (NLP) tasks for low-resource languages. Within morphology, the labour-intensive work of tagging/glossing data is a serious bottleneck for both NLP and language documentation. Active learning (AL) aims to reduce the cost of data annotation by selecting data that is most informative for improving the model. In this paper, we explore four sampling strategies for the task of morphological inflection using a Transformer model: a pair of oracle experiments where data is chosen based on whether the model already can or cannot inflect the test forms correctly, as well as strategies based on high/low model confidence, entropy, as well as random selection. We investigate the robustness of each strategy across 30 typologically diverse languages. We also perform a more in-depth case study of Natügu. Our results show a clear benefit to selecting data based on model confidence and entropy. Unsurprisingly, the oracle experiment, where only incorrectly handled forms are chosen for further training, which is presented as a proxy for linguist/language consultant feedback, shows the most improvement. This is followed closely by choosing low-confidence and high-entropy predictions. We also show that despite the conventional wisdom of larger data sets yielding better accuracy, introducing more instances of high-confidence or low-entropy forms, or forms that the model can already inflect correctly, can reduce model performance.
+
+# 1 Introduction
+
+The need for linguistically annotated data sets is a drive that unites many fields within linguistics. Computational linguists often use labelled data sets for developing NLP systems. Theoretical linguists may utilise corpora for constructing statistical argumentation to support hypotheses about language or phenomena. Documentary linguists create interlinear glossed texts (IGTs) to preserve linguistic and
+
+cultural examples, which typically aids in generating a grammatical description. With the renewed focus on low-resource languages and diversity in NLP and the urgency propelled by language extinction, there is widespread interest in addressing this bottleneck.
+
+One method for reducing annotation costs is active learning (AL). AL is an iterative process to optimise model performance by choosing the most critical examples to label. It has been successfully employed for various applications through NLP tasks including deep pre-trained models (BERT) (Ein-Dor et al., 2020), semantic role labelling (Myers and Palmer, 2021), named entity recognition (Shen et al., 2017), word sense disambiguation (Zhu and Hovy, 2007), sentiment classification (Dong et al., 2018) and machine translation (Zeng et al., 2019; Zhang et al., 2018). The iterative nature of AL aligns nicely with the language documentation process. It can be tied into the workflow of a field linguist who consults with a language informant or visits a field site in a periodic manner. Prior to a field trip, a linguist typically prepares material/questions (such as elicitation's or picture tasks1) for language consultants which may focus on elements of the language they are working to describe or for material creation (e.g., pedagogical). We propose AL as a method which can provide a supplementary line of insight into the data collection process, particularly for communities that wish to develop and engage with language technology and/or resource building.
+
+Previous work by Palmer (2009) details the efficiency gains from AL in the context of language documentation for the task of morpheme labelling. With deep learning models leading performance for the task of morphological analysis (Pimentel et al., 2021; Vylomova et al., 2020; McCarthy et al.,
+
+
+Figure 1: The accuracy for each trained modelled, starting from the baseline (cycle 1). Each cycle 250 instances are re-sampled via the seven sampling methods: correct/incorrect, high/low model confidence, high/low entropy and random (coded with colour). The reported error bars are calculated across 3 separate runs. See Table 1 in Appendix for more detail. After cycle 2, the same sampling strategy is applied to that stream of experiment - e.g. for the lowest log-likelihood strategy, from cycle 2 to 10 the same strategy is used.
+
+2019), AL in the context of neural methods is needed.
+
+This paper addresses the following question: How can we identify the type of data needed to improve model performance? To answer this, we explore the use of AL for the task of morphological inflection using a Transformer model. We run AL simulation experiments with four different sampling strategies: (1) correctness oracle, (2) model confidence, (3) entropy and (4) random selection. These strategies are tested across 30 typologically diverse languages and a 10-cycle iterative experiment using Natügu as a case study.
+
+# 2 Data
+
+We use data from the UniMorph Project (McCarthy et al., 2020), Interlinear Glossed Texts (IGT) from Moeller et al. (2020) and SIGMORPHON (Vy
+
+lomova et al., 2020; Pimentel et al., 2021). In addition to the data availability, we consider typological diversity when selecting languages to include. Broadly, we attempt to include types of languages that exhibit varying degrees of complexity for inflection. We also consider morphological characteristics coded in WALS; prefixing vs. suffixing (Dryer, 2013), inflectional synthesis of the verb (Bickel and Nichols, 2013b) and exponentie (Bickel and Nichols, 2013a). An additional consideration is the paradigm size for the morphological system modelled.
+
+We note data source type to account for the variation in standard across Wikipedia, IGT field data, glossed examples from grammars and data generated from computational grammars.
+
+# 3 Experimental Setup
+
+We train the model as if we were addressing an 'inflection' task (Vylomova et al., 2020). The data is in the form of triplets: lexeme, morphosyntactic tags and the desired output inflected form (e.g. $\langle \text{walk}, \text{V}; \text{PST}, \text{walked} \rangle$ ^2. Each model is trained with the fairseq Transformer (Ott et al., 2019) and our hyperparameters follow Liu and Hulden (2020).
+
+A baseline model is trained, after which more examples are resampled from the baseline test file using the methods detailed below. The initial baseline model is trained with 3,500 instances, 1,000 test and 500 for development. We resample 250 instances.
+
+# 3.1 Sampling strategies
+
+Oracle The oracle experiments serve as a proxy for linguist/language expert feedback. 250 examples are sampled based on whether the predicted form is correct/incorrect. The initial filter is supplemented with the following criteria: (1) if there are fewer than 250 incorrect forms, the remaining slots are filled in accordance with examples that exhibit the smallest difference between the first and second output form's log-likelihood, (2) in the case of more than 250 incorrect forms, the incorrect instances are ranked based on the maximum Levenshtein distance between the predicted and target forms. The same selection criteria are applicable for the counterpart correct experiment, with reversed limits (e.g. in the case of less than 250 correct forms, the instances with the largest difference between the first and second log-likelihood are considered).
+
+Model Confidence The instances introduced to the training data are sampled based on the model confidence for each form. In this particular strategy, we only record the log-likelihood for the highest-ranked prediction in the beam.
+
+We further examine the correlation between the log-likelihood (continuous variable) and accuracy (dichotomous variable) of the best prediction generated by the model by calculating the Point-Biserial Correlation Coefficient (PBCC). Across the 30 languages we study, the average PBCC is 0.388. Like all correlation coefficients, the PBCC measures the strength of the correlation, and the reported value
+
+
+Figure 2: The calculated Point-Biserial Correlation Coefficient (PBCC) between correct prediction and the model log-likelihood, across 30 different languages. The source of the data is also noted with colour.
+
+ranges from -1 to +1, where -1 indicates an inverse association, +1 indicates a positive association, and 0 indicates no association at all.
+
+Entropy Here we expand upon the previous strategy—model confidence. We consider the distribution of the ranked output predictions for a particular input and approximate its entropy $-\sum_{i} p_{i} \log(p_{i})$ , by only considering such predictions where $p_{i} \geq 0.05$ , i.e. we calculate $-\sum p_{i} \log(p_{i})$ , for all $p_{i} \geq 0.05$ . The model generated log-likelihoods are converted to probabilities and renormalised across the outputs generated by beam search. $p_{i} = \frac{p_{n}}{\sum_{j=1}^{b} p_{n}}$ , $b$ being the number of predictions we retrieve from the beam search.
+
+Random We contrast the previous methods for re-sampling with random data selection. To establish whether the change in accuracy is statistically significant, we report the average across three independent runs and the standard deviation across the measured accuracy.
+
+# 4 Results and Discussion
+
+To simulate a documentation process, we have chosen Natügu as a case study. The inflection data is from Moeller et al. (2020) and is derived from IGTs—a form that is commonly utilised by field linguists. Our choice of language is further motivated by the morphological complexity exhibited by Natügu. By all accounts Natügu showcases complex morphology (Wurm, 1976; Åshild Næss and Boerger, 2008), particularly on the verb. Historically, this observed complexity led to the language family named as Papuan instead of Austronesian.
+
+Additionally, we observe a positive correlation between prediction correctness and model confidence (0.605). In fact, 4 out of the top 8 correlations (as shown in Figure 2) are languages with IGTs as a data source. For these reasons, we have chosen to examine iterative sampling over 10 cycles.
+
+Figure 1 summarises our results for Natügu. The re-sampling process is iterated over 10 cycles. The first cycle is the baseline/seed run and consists of a 600 instance training set. To account for the impact of random factors affecting the initial training data selection, we have conducted 3 independent seed runs—differing solely on the initial training set. The average accuracy and corresponding standard deviation is reported with the error bars. $^{3}$
+
+The small starting size is motivated by the parallels with language documentation efforts, which are typically a low-resource setting. In each cycle, 250 forms are sampled via the corresponding sampling strategy. By the last cycle the training data consists of 2,850 instances.
+
+Aside from the 3rd and 10th cycle, the lowest log-likelihood sampling consistently provides the greatest improvement. For these two cycles sampling based on incorrect forms outperforms selection based on low confidence. In general, the top 3 selection methods are ranked as follows: low log-likelihood, incorrect and highest entropy forms. We note the possible interplay between paradigm size (907 unique tag combinations) and training size set
+
+(1,100 by cycle 3); unseen morphosyntactic categories will be most informative and presumably beneficial to model performance.
+
+Given the strong correlation between prediction accuracy and model confidence for Natügu, we expect similarity in trajectory across cycle number and accuracy for the oracle and model-confidence based sampling strategies. Figure 1 verifies these forecasts; we see that the sampling based on prediction correctness (in light blue) and the sampling based on the highest log-likelihood (in light green) almost look identical. The same is observable for low log-likelihood (in red) and sampling based on incorrect prediction (green).
+
+The lowest log-likelihood sampling method can be seen as an approximation for the highest entropy selection method, and by extension, the highest log-likelihood as an approximation for the lowest entropy selection. Our results for iterative AL for Natugu show that choosing by approximation is a higher risk endeavour. The choice either works really well or not at all. When we contrast low entropy and high model confidence as a selection strategy we can see that low entropy limits the impact of high model confidence since it accounts for a distribution rather than the single value approximation. We observe similar behaviour between the the high entropy and low confidence selection strategies. Random sampling shows gradual improvement.
+
+Work by Yuan et al. (2020) highlight the issues with uncertainty sampling for deep learning models; noting that neural networks are poorly calibrated (Guo et al., 2017), and that the correlation between high confidence and correctness is not well established. We explore this correlation for our models in Figure 2. We observe a similar uncertainty with an overall slight positive correlation across the 30 languages examined. Despite this, our results show that data selection based on low model confidence yields significant improvement of model accuracy. The work presented here is intended as a preliminary baseline; we leave it to future work to consider calibration methods such as temperature scaling.
+
+Interestingly, despite an increase in training data size, introducing new data that the model already can inflect correctly, or low-entropy or high-confidence forms actually reduces model performance despite the widely-held notion that more data is better. Another recent study by Samir and
+
+
+Figure 3: The change in accuracy (from the established baseline) is reported with each sampling strategy, across 30 different languages (coded with colour). The source of data is also noted with tick shapes.
+
+Silfverberg (2022) reports similar behaviour, where data hallucination reduces prediction accuracy for words that exhibited reduplication.
+
+We extend the same sampling strategies to 30 different languages for one round of re-training. The results are summarised in Figure 3. Within the 30 languages we ensure to include languages with large inflection table sizes (ranging from 12 to $700+$ ), different scripts (Latin, Cyrillic, Arabic, Hangul, Ge'ez and Gujarati) and morphological typology (agglutinating, fusional, polysynthetic). We code for the source of the data, and see no particular deviation from the overall observed behaviour. The reported error bars for random sampling correspond to the standard deviation across three independent runs of random sampling.
+
+It is clear that in general, the sampling strategies can be ordered for prediction accuracy improvement in the following manner: incorrect, lowest log-likelihood, highest entropy, random, highest log-likelihood, lowest entropy and finally correct form sampling. While a handful of languages deviate from this pattern (e.g. Swahili or Dido),4 it
+
+holds true for a majority of the languages considered.
+
+# 5 Conclusion
+
+In this paper we examine four different sampling strategies within an AL framework for modelling morphological inflection using a Transformer model. We consider correct/incorrect prediction, model confidence, entropy and random selection as sampling strategies. Our results clearly show that AL can significantly improve learning rates for morphological inflection. Unsurprisingly, adding oracle-indicated incorrect forms for training yields the greatest model improvement. In the absence of a language expert, model confidence can be used to prioritise data annotation. This holds true across 30 different languages. We also show that larger datasets do not always yield better results; the diversity of the training set matters.
+
+Future research should extend the analysis to incorporate language-specific factors—such as model performance for each morphosyntactic slot within the morphological paradigm.
+
+# Limitations
+
+The primary limitation of this study is that the results are not evaluated in a real life documentation scenario. While we have tried to address this gap by noting the source of data, and have enlisted IGT data to serve as a proxy, we acknowledge that fieldwork data is often inconsistent, noisy and requires much more data cleaning. The data used for these experiments is, for the most part, already structured as a paradigm.
+
+In addition, the simple metric of accuracy can be crude and is often prone to some degree of fluctuation. To minimise these effects we have considered the change in accuracy across sampling cycles instead. Lastly, we have tried to collate a diverse set of languages to consider. However, this is largely limited by the availability of data. It is likely that several morphophonological phenomena are not included within the data sets used here.
+
+# References
+
+Balthasar Bickel and Johanna Nichols. 2013a. Exponence of selected inflectional formatives. In Matthew S. Dryer and Martin Haspelmath, editors, The World Atlas of Language Structures Online. Max Planck Institute for Evolutionary Anthropology, Leipzig.
+Balthasar Bickel and Johanna Nichols. 2013b. Inflectional synthesis of the verb. In Matthew S. Dryer and Martin Haspelmath, editors, The World Atlas of Language Structures Online. Max Planck Institute for Evolutionary Anthropology, Leipzig.
+Li Dong, Chris Quirk, and Mirella Lapata. 2018. Confidence modeling for neural semantic parsing. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 743-753, Melbourne, Australia. Association for Computational Linguistics.
+Matthew S. Dryer. 2013. Prefixing vs. suffixing in inflectional morphology. In Matthew S. Dryer and Martin Haspelmath, editors, The World Atlas of Language Structures Online. Max Planck Institute for Evolutionary Anthropology, Leipzig.
+Liat Ein-Dor, Alon Halfon, Ariel Gera, Eyal Shnarch, Lena Dankin, Leshem Choshen, Marina Danilevsky, Ranit Aharonov, Yoav Katz, and Noam Slonim. 2020. Active Learning for BERT: An Empirical Study. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 7949-7962, Online. Association for Computational Linguistics.
+Chuan Guo, Geoff Pleiss, Yu Sun, and Kilian Q. Weinberger. 2017. On calibration of modern neural net
+
+works. In Proceedings of the 34th International Conference on Machine Learning, volume 70 of Proceedings of Machine Learning Research, pages 1321-1330. PMLR.
+Ling Liu and Mans Hulden. 2020. Leveraging principal parts for morphological inflection. In Proceedings of the 17th SIGMORPHON Workshop on Computational Research in Phonetics, Phonology, and Morphology, pages 153-161, Online. Association for Computational Linguistics.
+Arya D. McCarthy, Christo Kirov, Matteo Grella, Amrit Nidhi, Patrick Xia, Kyle Gorman, Ekaterina Vylomova, Sabrina J. Mielke, Garrett Nicolai, Miikka Silfverberg, Timofey Arkhangelskiy, Nataly Krizhanovsky, Andrew Krizhanovsky, Elena Klyachko, Alexey Sorokin, John Mansfield, Valts Ernstreits, Yuval Pinter, Cassandra L. Jacobs, Ryan Cotterell, Mans Hulden, and David Yarowsky. 2020. UniMorph 3.0: Universal Morphology. In Proceedings of the 12th Language Resources and Evaluation Conference, pages 3922-3931, Marseille, France. European Language Resources Association.
+Arya D. McCarthy, Ekaterina Vylomova, Shijie Wu, Chaitanya Malaviya, Lawrence Wolf-Sonkin, Garrett Nicolai, Christo Kirov, Miikka Silfverberg, Sabrina J. Mielke, Jeffrey Heinz, Ryan Cotterell, and Mans Hulden. 2019. The SIGMORPHON 2019 shared task: Morphological analysis in context and crosslingual transfer for inflection. In Proceedings of the 16th Workshop on Computational Research in Phonetics, Phonology, and Morphology, pages 229-244, Florence, Italy. Association for Computational Linguistics.
+Sarah Moeller, Ling Liu, Changbing Yang, Katharina Kann, and Mans Hulden. 2020. IGT2P: From interlinear glossed texts to paradigms. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 5251-5262, Online. Association for Computational Linguistics.
+Skatje Myers and Martha Palmer. 2021. Tuning deep active learning for semantic role labeling. In Proceedings of the 14th International Conference on Computational Semantics (IWCS), pages 212-221, Groningen, The Netherlands (online). Association for Computational Linguistics.
+Myle Ott, Sergey Edunov, Alexei Baevski, Angela Fan, Sam Gross, Nathan Ng, David Grangier, and Michael Auli. 2019. *fairoseq: A fast, extensible toolkit for sequence modeling*. In *Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics* (Demonstrations), pages 48-53, Minneapolis, Minnesota. Association for Computational Linguistics.
+Alexis Mary Palmer. 2009. Semi-automated annotation and active learning for language documentation. Ph.D. thesis.
+
+Tiago Pimentel, Maria Ryskina, Sabrina J. Mielke, Shijie Wu, Eleanor Chodroff, Brian Leonard, Garrett Nicolai, Yustinus Ghanggo Ate, Salam Khalifa, Nizar Habash, Charbel El-Khaissi, Omer Goldman, Michael Gasser, William Lane, Matt Coler, Arturo Oncevay, Jaime Rafael Montoya Samame, Gema Celeste Silva Villegas, Adam Ek, Jean-Philippe Bernardy, Andrey Shcherbakov, Aziyana Bayyr-ool, Karina Sheifer, Sofya Ganieva, Matvey Plugaryov, Elena Klyachko, Ali Salehi, Andrew Krizhanovsky, Natalia Krizhanovsky, Clara Vania, Sardana Ivanova, Aelita Salchak, Christopher Straughn, Zoey Liu, Jonathan North Washington, Duygu Ataman, Witold Kieraş, Marcin Wolinski, Totok Suhardijanto, Niklas Stoehr, Zahroh Nuriah, Shyam Ratan, Francis M. Tyers, Edoardo M. Ponti, Grant Aiton, Richard J. Hatcher, Emily Prud'hommeaux, Ritesh Kumar, Mans Hulden, Botond Barta, Dorina Lakatos, Gábor Szolnok, Judit Ács, Mohit Raj, David Yarowsky, Ryan Cotterell, Ben Ambridge, and Ekaterina Vylomova. 2021. SIGMORPHON 2021 shared task on morphological reinflection: Generalization across languages. In Proceedings of the 18th SIGMORPHON Workshop on Computational Research in Phonetics, Phonology, and Morphology, pages 229–259, Online. Association for Computational Linguistics.
+
+Farhan Samir and Miikka Silfverberg. 2022. One wug, two wug+s: Transformer inflection models hallucinate affixes. In Proceedings of the Fifth Workshop on the Use of Computational Methods in the Study of Endangered Languages, pages 31-40, Dublin, Ireland. Association for Computational Linguistics.
+
+Yanyao Shen, Hyokun Yun, Zachary Lipton, Yakov Kronrod, and Animashree Anandkumar. 2017. Deep active learning for named entity recognition. In Proceedings of the 2nd Workshop on Representation Learning for NLP, pages 252-256, Vancouver, Canada. Association for Computational Linguistics.
+
+Ekaterina Vylomova, Jennifer White, Elizabeth Salesky, Sabrina J. Mielke, Shijie Wu, Edoardo Maria Ponti, Rowan Hall Maudslay, Ran Zmigrod, Josef Valvoda, Svetlana Toldova, Francis Tyers, Elena Klyachko, Ilya Yegorov, Natalia Krizhanovsky, Paula Czarnowska, Irene Nikkarinen, Andrew Krizhanovsky, Tiago Pimentel, Lucas Torroba Hennigen, Christo Kirov, Garrett Nicolai, Adina Williams, Antonios Anastasopoulos, Hilaria Cruz, Eleanor Chodroff, Ryan Cotterell, Miikka Silfverberg, and Mans Hulden. 2020. SIGMORPHON 2020 shared task 0: Typologically diverse morphological inflection. In Proceedings of the 17th SIGMORPHON Workshop on Computational Research in Phonetics, Phonology, and Morphology, pages 1-39, Online. Association for Computational Linguistics.
+
+Stephen A. Wurm. 1976. The Reef Islands-Santa Cruz family. In Stephen A. Wurm, editor, New Guinea Area Languages and Language Study Vol 2: Austronesian Languages, volume 39 of Pacific Linguistics: Series C, pages 637-674. Research School of Pacific and Asian Studies, Australian National University, Canberra.
+
+Michelle Yuan, Hsuan-Tien Lin, and Jordan Boyd-Graber. 2020. Cold-start active learning through self-supervised language modeling. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 7935-7948, Online. Association for Computational Linguistics.
+
+Xiangkai Zeng, Sarthak Garg, Rajen Chatterjee, Udhyakumar Nallasamy, and Matthias Paulik. 2019. Empirical evaluation of active learning techniques for neural MT. In Proceedings of the 2nd Workshop on Deep Learning Approaches for Low-Resource NLP (DeepLo 2019), pages 84–93, Hong Kong, China. Association for Computational Linguistics.
+
+Pei Zhang, Xueying Xu, and Deyi Xiong. 2018. Active learning for neural machine translation. In 2018 International Conference on Asian Language Processing (IALP), pages 153-158.
+
+Jingbo Zhu and Eduard Hovy. 2007. Active learning for word sense disambiguation with methods for addressing the class imbalance problem. In Proceedings of the 2007 Joint Conference on Empirical Methods in Natural Language Processing and Computational Natural Language Learning (EMNLP-CoNLL), pages 783-790, Prague, Czech Republic. Association for Computational Linguistics.
+
+Ashild Naess and Brenda H. Boerger. 2008. Reefs-Santa Cruz as Oceanic: Evidence from the verb complex. Oceanic Linguistics, 47(1):185-212.
+
+# A Appendix
+
+ | Resample by: | |
| Lowest log(p_i) | Highest log(p_i) | Random | |
| Cycle # | training size | S1 | S2 | S3 | avg | std | S1 | S2 | S3 | avg | std | S1 | S2 | S3 | avg | std |
| 1 | 600 | 0.618 | 0.621 | 0.604 | 0.614 | 0.009 | 0.618 | 0.621 | 0.604 | 0.614 | 0.009 | 0.618 | 0.621 | 0.604 | 0.614 | 0.009 |
| 2 | 850 | 0.800 | 0.795 | 0.774 | 0.790 | 0.014 | 0.508 | 0.532 | 0.522 | 0.521 | 0.012 | 0.617 | 0.666 | 0.642 | 0.642 | 0.025 |
| 3 | 1100 | 0.870 | 0.872 | 0.886 | 0.876 | 0.009 | 0.439 | 0.442 | 0.439 | 0.440 | 0.002 | 0.679 | 0.697 | 0.662 | 0.679 | 0.018 |
| 4 | 1350 | 0.927 | 0.933 | 0.905 | 0.922 | 0.015 | 0.374 | 0.317 | 0.321 | 0.337 | 0.032 | 0.723 | 0.723 | 0.659 | 0.702 | 0.037 |
| 5 | 1600 | 0.922 | 0.939 | 0.932 | 0.931 | 0.009 | 0.275 | 0.310 | 0.267 | 0.284 | 0.023 | 0.727 | 0.744 | 0.705 | 0.725 | 0.020 |
| 6 | 1850 | 0.934 | 0.925 | 0.943 | 0.934 | 0.009 | 0.266 | 0.234 | 0.236 | 0.245 | 0.018 | 0.741 | 0.771 | 0.754 | 0.755 | 0.015 |
| 7 | 2100 | 0.921 | 0.929 | 0.933 | 0.928 | 0.006 | 0.256 | 0.198 | 0.208 | 0.221 | 0.031 | 0.735 | 0.726 | 0.791 | 0.751 | 0.035 |
| 8 | 2350 | 0.940 | 0.890 | 0.929 | 0.920 | 0.026 | 0.236 | 0.207 | 0.206 | 0.216 | 0.017 | 0.756 | 0.774 | 0.758 | 0.763 | 0.010 |
| 9 | 2600 | 0.943 | 0.932 | 0.948 | 0.941 | 0.008 | 0.225 | 0.208 | 0.258 | 0.230 | 0.025 | 0.758 | 0.783 | 0.794 | 0.778 | 0.018 |
| 10 | 2850 | 0.929 | 0.927 | 0.939 | 0.932 | 0.006 | 0.242 | 0.230 | 0.217 | 0.230 | 0.013 | 0.760 | 0.795 | 0.803 | 0.786 | 0.023 |
+
+Table.1: Model accuracies for iterative sampling for Natügu, across the lowest and highest low-likelihoods and random sampling strategies. S1, S2, S3 corresponds to seed 1, seed 2 and seed 3 respectively. Avg and std indicate the average value across the three seed runs and the standard deviation. Data used to generate Figure.1.
+
+| Cycle # | training size | Resample by: | | |
| Incorrect | Correct | Highest Entropy | Lowest Entropy | | |
| S1 | S2 | S3 | avg | std | S1 | S2 | S3 | avg | std | S1 | S2 | S3 | avg | std | S1 | S2 | S3 | avg | std |
| 1 | 600 | 0.618 | 0.621 | 0.604 | 0.614 | 0.009 | 0.618 | 0.621 | 0.604 | 0.614 | 0.009 | 0.618 | 0.621 | 0.604 | 0.614 | 0.009 | 0.618 | 0.621 | 0.604 | 0.614 | 0.009 |
| 2 | 850 | 0.778 | 0.791 | 0.758 | 0.776 | 0.017 | 0.530 | 0.521 | 0.493 | 0.515 | 0.019 | 0.792 | 0.790 | 0.731 | 0.771 | 0.035 | 0.506 | 0.520 | 0.518 | 0.515 | 0.008 |
| 3 | 1100 | 0.896 | 0.887 | 0.913 | 0.899 | 0.013 | 0.452 | 0.446 | 0.402 | 0.433 | 0.027 | 0.848 | 0.861 | 0.848 | 0.852 | 0.008 | 0.507 | 0.445 | 0.448 | 0.467 | 0.035 |
| 4 | 1350 | 0.901 | 0.931 | 0.900 | 0.911 | 0.018 | 0.373 | 0.346 | 0.320 | 0.346 | 0.027 | 0.876 | 0.857 | 0.885 | 0.873 | 0.014 | 0.500 | 0.439 | 0.421 | 0.453 | 0.041 |
| 5 | 1600 | 0.923 | 0.934 | 0.901 | 0.919 | 0.017 | 0.291 | 0.278 | 0.216 | 0.262 | 0.040 | 0.892 | 0.908 | 0.888 | 0.896 | 0.011 | 0.454 | 0.386 | 0.369 | 0.403 | 0.045 |
| 6 | 1850 | 0.935 | 0.935 | 0.917 | 0.929 | 0.010 | 0.212 | 0.189 | 0.250 | 0.217 | 0.031 | 0.895 | 0.895 | 0.918 | 0.903 | 0.013 | 0.460 | 0.342 | 0.357 | 0.386 | 0.064 |
| 7 | 2100 | 0.906 | 0.916 | 0.916 | 0.913 | 0.006 | 0.189 | 0.229 | 0.203 | 0.207 | 0.020 | 0.919 | 0.916 | 0.908 | 0.914 | 0.006 | 0.362 | 0.248 | 0.408 | 0.339 | 0.082 |
| 8 | 2350 | 0.929 | 0.872 | 0.917 | 0.906 | 0.030 | 0.234 | 0.220 | 0.194 | 0.216 | 0.020 | 0.919 | 0.917 | 0.899 | 0.912 | 0.011 | 0.408 | 0.301 | 0.327 | 0.345 | 0.056 |
| 9 | 2600 | 0.928 | 0.947 | 0.940 | 0.938 | 0.010 | 0.210 | 0.229 | 0.280 | 0.240 | 0.036 | 0.933 | 0.860 | 0.938 | 0.910 | 0.044 | 0.365 | 0.409 | 0.339 | 0.371 | 0.035 |
| 10 | 2850 | 0.935 | 0.940 | 0.937 | 0.937 | 0.003 | 0.229 | 0.188 | 0.224 | 0.214 | 0.022 | 0.933 | 0.904 | 0.925 | 0.921 | 0.015 | 0.378 | 0.389 | 0.342 | 0.370 | 0.025 |
+
+Table.2: Model accuracies for iterative sampling for Natügu, across incorrect, correct, highest and lowest entropy sampling strategies. S1, S2, S3 corresponds to seed 1, seed 2 and seed 3 respectively. Avg and std indicate the average value across the three seed runs and the standard deviation. Data used to generate Figure.1.
+
+| Language | Iso-code | PBCC | p-value |
| Adyghe | ady | 0.031 | 3.29E-01 |
| Amharic | amh | 0.643 | 5.74E-118 |
| Arabic | ara | 0.394 | 1.53E-38 |
| Arapaho | arp | 0.607 | 1.08E-101 |
| Aymara | aym | 0.394 | 1.64E-38 |
| Asháninka | cni | 0.799 | 1.10E-222 |
| Palantla Chinantec | cpa | 0.355 | 4.10E-31 |
| Cree | cre | 0.069 | 2.91E-02 |
| Dido | ddo | 0.550 | 4.24E-80 |
| German | deu | 0.363 | 1.60E-32 |
| Basque | eus | 0.707 | 3.67E-152 |
| Evenki | evn | 0.532 | 2.94E-74 |
| Persian | fas | 0.242 | 7.68E-15 |
| Finnish | fin | 0.135 | 1.84E-05 |
| Irish | gle | 0.172 | 4.24E-08 |
| Gujarati | guj | 0.168 | 8.40E-08 |
| Haida | hai | 0.240 | 1.47E-14 |
| Indonesian | ind | 0.364 | 1.05E-32 |
| Halh Mongolian | khk | 0.370 | 8.44E-34 |
| Korean | kor | 0.431 | 1.78E-46 |
| Manipuri | mni | 0.709 | 2.34E-153 |
| Navaho | nav | 0.396 | 7.66E-39 |
| Natügu | ntu | 0.605 | 1.13E-100 |
| Quechua | que | 0.838 | 3.44E-265 |
| Russian | rus | 0.282 | 9.57E-20 |
| Seneca | see | 0.306 | 3.75E-23 |
| Spanish | spa | -0.069 | 3.02E-02 |
| Swahili | swc | 0.324 | 6.16E-26 |
| Turkish | tur | 0.129 | 4.17E-05 |
| Zulu | zul | 0.540 | 9.23E-77 |
+
+Table.2: Correct and model log-likelihood correlation based on baseline for each language. The reported value is a Point-Biserial Correlation Coefficient (PBCC) with the respective p-value. Data used to generate Figure.2.
+
+| Language | Source | # Tables | Baseline | Resample by: |
| Correct | Incorrect | Lowest log(pi) | Highest log(pi) | Lowest Entropy | Highest Entropy | Random1 | Random2 | Random3 | Randomavg | ± Std dev |
| ady | Wiki | 430 | 0.986 | 0.984 | 0.998 | 0.990 | 0.988 | 0.985 | 0.992 | 0.989 | 0.990 | 0.990 | 0.990 | 0.001 |
| amh | c. grammar | 285 | 0.983 | 0.977 | 0.989 | 0.993 | 0.975 | 0.965 | 0.987 | 0.980 | 0.977 | 0.977 | 0.978 | 0.002 |
| ara | c. grammar | 83 | 0.800 | 0.755 | 0.924 | 0.920 | 0.730 | 0.754 | 0.838 | 0.818 | 0.805 | 0.824 | 0.816 | 0.010 |
| aym | grammar | 55 | 0.933 | 0.924 | 0.991 | 0.988 | 0.923 | 0.926 | 0.959 | 0.939 | 0.941 | 0.938 | 0.939 | 0.002 |
| cpa | grammar | 490 | 0.843 | 0.798 | 0.895 | 0.899 | 0.822 | 0.822 | 0.866 | 0.820 | 0.857 | 0.832 | 0.836 | 0.019 |
| cre | grammar | 22 | 0.113 | 0.029 | 0.130 | 0.125 | 0.096 | 0.066 | 0.133 | 0.110 | 0.116 | 0.115 | 0.114 | 0.003 |
| deu | wiki | 450 | 0.937 | 0.911 | 0.979 | 0.945 | 0.942 | 0.928 | 0.948 | 0.935 | 0.939 | 0.920 | 0.931 | 0.010 |
| eus | wiki | 12 | 0.755 | 0.738 | 0.914 | 0.905 | 0.660 | 0.612 | 0.897 | 0.813 | 0.754 | 0.784 | 0.784 | 0.030 |
| fas | wiki | 39 | 0.178 | 0.044 | 0.222 | 0.201 | 0.143 | 0.064 | 0.222 | 0.186 | 0.182 | 0.178 | 0.182 | 0.004 |
| fin | wiki | 97 | 0.587 | 0.489 | 0.717 | 0.601 | 0.539 | 0.528 | 0.676 | 0.593 | 0.584 | 0.590 | 0.589 | 0.005 |
| guj | wiki | 280 | 0.620 | 0.511 | 0.743 | 0.603 | 0.579 | 0.544 | 0.660 | 0.601 | 0.587 | 0.594 | 0.594 | 0.007 |
| ind | wiki | 750 | 0.551 | 0.445 | 0.634 | 0.590 | 0.469 | 0.543 | 0.590 | 0.556 | 0.530 | 0.549 | 0.545 | 0.013 |
| khk | c. grammar | 720 | 0.936 | 0.930 | 0.980 | 0.967 | 0.920 | 0.932 | 0.952 | 0.944 | 0.934 | 0.918 | 0.932 | 0.013 |
| kor | wiki | 60 | 0.597 | 0.504 | 0.696 | 0.710 | 0.519 | 0.529 | 0.629 | 0.595 | 0.597 | 0.606 | 0.599 | 0.006 |
| rus | wiki | 320 | 0.884 | 0.861 | 0.959 | 0.901 | 0.917 | 0.878 | 0.915 | 0.857 | 0.889 | 0.881 | 0.876 | 0.017 |
| see | grammar | 135 | 0.895 | 0.872 | 0.951 | 0.943 | 0.878 | 0.873 | 0.919 | 0.902 | 0.884 | 0.898 | 0.895 | 0.009 |
| spa | wiki | 75 | 0.880 | 0.847 | 0.966 | 0.853 | 0.918 | 0.861 | 0.901 | 0.884 | 0.874 | 0.884 | 0.881 | 0.006 |
| swc | wiki | 53 | 0.931 | 0.916 | 0.961 | 0.973 | 0.903 | 0.957 | 0.925 | 0.939 | 0.941 | 0.937 | 0.939 | 0.002 |
| tur | wiki | 35 | 0.464 | 0.328 | 0.575 | 0.491 | 0.402 | 0.384 | 0.556 | 0.456 | 0.462 | 0.452 | 0.457 | 0.005 |
| zul | wiki | 62 | 0.881 | 0.861 | 0.918 | 0.957 | 0.844 | 0.875 | 0.861 | 0.876 | 0.868 | 0.856 | 0.867 | 0.010 |
| arp | IGT | 470 | 0.290 | 0.238 | 0.352 | 0.354 | 0.265 | 0.165 | 0.315 | 0.326 | 0.296 | 0.349 | 0.324 | 0.027 |
| que | wiki | 25 | 0.982 | 0.985 | 0.988 | 0.990 | 0.972 | 0.973 | 0.959 | 0.969 | 0.994 | 0.982 | 0.982 | 0.013 |
| gle | wiki | 350 | 0.387 | 0.228 | 0.472 | 0.427 | 0.371 | 0.297 | 0.444 | 0.372 | 0.375 | 0.385 | 0.377 | 0.007 |
| ddo | IGT | 400 | 0.793 | 0.770 | 0.925 | 0.904 | 0.756 | 0.762 | 0.858 | 0.804 | 0.799 | 0.806 | 0.803 | 0.004 |
| nav | wiki | 280 | 0.860 | 0.826 | 0.943 | 0.941 | 0.854 | 0.852 | 0.926 | 0.874 | 0.862 | 0.877 | 0.871 | 0.008 |
| mni | IGT | 525 | 0.752 | 0.730 | 0.932 | 0.908 | 0.729 | 0.737 | 0.877 | 0.784 | 0.784 | 0.780 | 0.783 | 0.002 |
| evn | grammar | 2250 | 0.460 | 0.368 | 0.551 | 0.559 | 0.374 | 0.447 | 0.554 | 0.470 | 0.473 | 0.479 | 0.474 | 0.005 |
| cni | grammar | 105 | 0.992 | 0.991 | 0.999 | 0.993 | 0.996 | 0.997 | 0.993 | 0.993 | 0.996 | 0.995 | 0.995 | 0.002 |
| hai | wiki | 31 | 0.715 | 0.656 | 0.874 | 0.731 | 0.731 | 0.708 | 0.773 | 0.728 | 0.727 | 0.717 | 0.724 | 0.006 |
| ntu | IGT | 560 | 0.800 | 0.762 | 0.947 | 0.917 | 0.772 | 0.766 | 0.897 | 0.811 | 0.792 | 0.806 | 0.803 | 0.010 |
+
+Table.3: Model accuracies for each sampling strategy, across 30 different languages. Data used to generate Figure.3.
\ No newline at end of file
diff --git a/eenymeenyminymoehowtochoosedataformorphologicalinflection/images.zip b/eenymeenyminymoehowtochoosedataformorphologicalinflection/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..1be0933500deaec3c30d1aabb19fa706202c3840
--- /dev/null
+++ b/eenymeenyminymoehowtochoosedataformorphologicalinflection/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4d3765a5fd52c66ee4bdc4deb578cc10cac390a6b3191d582dcfef2a025d38b9
+size 714781
diff --git a/eenymeenyminymoehowtochoosedataformorphologicalinflection/layout.json b/eenymeenyminymoehowtochoosedataformorphologicalinflection/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..78398392da75bd4a68e69cedd70fdf6e72ba98bc
--- /dev/null
+++ b/eenymeenyminymoehowtochoosedataformorphologicalinflection/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f9b2164676e357e1165ae5403898a6a69afa189afcc83e4df5d413ce98af491e
+size 182279
diff --git a/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_content_list.json b/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..1b9921ceb5cd41e842dba52ca777878d4fa41472
--- /dev/null
+++ b/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:23ee5ca1e94609f4c8aa97fae89f2ea5670d9ba1a8e4b14150cb880072e7e1f4
+size 75020
diff --git a/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_model.json b/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..02802ac720b8101fa922f15fe07764b3baa07a72
--- /dev/null
+++ b/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:740f0c5ad272402273b1dfc9cb824fba5deab8f88848189a935b3721777fafd9
+size 89654
diff --git a/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_origin.pdf b/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c6ac30731b8f9fdce06917ac3355fd27ce795f7c
--- /dev/null
+++ b/effectiveandefficientqueryawaresnippetextractionforwebsearch/83842337-aa45-433f-aa20-661efc2ec918_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9376895594e4bf06a651a36186f32d92e02aadb8c95f49830d6707f3a3477bdd
+size 737270
diff --git a/effectiveandefficientqueryawaresnippetextractionforwebsearch/full.md b/effectiveandefficientqueryawaresnippetextractionforwebsearch/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..6f6eb1636f03bad5bb6e618bb3cc453b923bb7f2
--- /dev/null
+++ b/effectiveandefficientqueryawaresnippetextractionforwebsearch/full.md
@@ -0,0 +1,286 @@
+# Effective and Efficient Query-aware Snippets Extraction for Web Search
+
+Jingwei Yi $^{1}$ , Fangzhao Wu $^{2}$ , Chuhan Wu $^{3}$ , Xiaolong Huang $^{4}$ , Binxing Jiao $^{4}$ , Guangzhong Sun $^{1}$ , Xing Xie $^{2}$
+
+1University of Science and Technology of China 2Microsoft Research Asia
+
+$^{3}$ Tsinghua University $^{4}$ Microsoft STC Asia
+
+yjw1029@mail.ustc.edu.cn {wufangzhao,wuchuhan15}@gmail.com
+
+{xiaolhu,binxjia,xingx}@microsoft.com gzsun@ustc.edu.cn
+
+# Abstract
+
+Query-aware webpage snippet extraction is widely used in search engines to help users better understand the content of the returned webpages before clicking. Although important, it is very rarely studied. In this paper, we propose an effective query-aware webpage snippet extraction method named DeepQSE, aiming to select a few sentences which can best summarize the webpage content in the context of input query. DeepQSE first learns query-aware sentence representations for each sentence to capture the fine-grained relevance between query and sentence, and then learns document-aware query-sentence relevance representations for snippet extraction. Since the query and each sentence are jointly modeled in DeepQSE, its online inference may be slow. Thus, we further propose an efficient version of DeepQSE, named Efficient-DeepQSE, which can significantly improve the inference speed of DeepQSE without affecting its performance. The core idea of Efficient-DeepQSE is to decompose the query-aware snippet extraction task into two stages, i.e., a coarse-grained candidate sentence selection stage where sentence representations can be cached, and a fine-grained relevance modeling stage. Experiments on two real-world datasets validate the effectiveness and efficiency of our methods.
+
+# 1 Introduction
+
+Given an input search query, search engines such as Google ${}^{1}$ and Bing ${}^{2}$ ,not only return the URLs and the titles of the relevant webpages, but also show the query-aware snippets of these webpages, aiming to help users better understand the webpage content before clicking. These webpage snippets are usually one or two sentences extracted from the webpage, which can not only summarize the key content of the webpage, but also be relevant
+
+
+Figure 1: Examples of query-aware snippets in search engines.
+
+to the input query. Some examples are shown in Figure 1. For the query 'einstein' and the webpage of 'Albert Einstein - Wikipedia', a good snippet is a brief introduction of Einstein's life. While for the query 'einstein achievement', a good snippet would be sentences describing his influence on science. In other words, the snippet is a summarization of the webpage in the context of input query.
+
+Although query-aware webpage snippet extraction is important and useful, it is very rarely studied. Only a few works exist in this field, and most of them are based on simple word-level text matching method (Penin et al., 2008; Zou et al., 2021). For example, Turpin et al. (2007) proposed to utilize the number of overlapping words between queries and sentences in webpages to extract snippets. Tsegay et al. (2009) proposed to select snippets through the summation of Kullback-Leibler divergence or TF-IDF weight of overlapping words between queries and sentences in webpages. However, these methods rely on counting features of overlapping words, and cannot capture the deep semantic relation between query and webpage.
+
+In this paper, we propose an effective query-aware webpage snippet extraction method for web search, named DeepQSE. In DeepQSE, given an input query and a webpage with multiple sentences,
+
+we first learn query-aware sentence representations for each sentence to capture the fine-grained relevance between query, sentence and webpage title using a query-aware sentence encoder. Then we model the query-sentence relevance in the context of the whole webpage using a document-aware relevance encoder. Since the query and each webpage sentence are jointly modeled, the online inference speed of DeepQSE can be slow, while the search engines have extremely high requirements for low latency. Thus, we further design an efficient version of DeepQSE named Efficient-DeepQSE, aiming to significantly improve the inference speed of DeepQSE and keep its performance as much as possible. The key idea of Efficient-DeepQSE is to decompose the query-aware webpage snippet extraction task into two stages, i.e., coarse-grained candidate sentence selection and fine-grained relevance modeling. The coarse-grained candidate sentence selection aims to select a moderate number of most potential sentences for snippet extraction using a bi-encoder where sentence representations can be cached for fast online serving. The fine-grained relevance modeling stage aims to capture the deep semantic relevance between the query and the candidate sentences selected by the previous stage using query-aware cross-encoders. We conducted many experiments on two real-world datasets, which verify the effectiveness and efficiency of our approach. The contributions of this paper are as follows:
+
+- We propose an effective query-aware webpage snippet extraction method for web search named DeepQSE, which can summarize the webpage content in the context of input query.
+- We further propose Efficient-DeepQSE which can improve the inference speed of Deep-QSE with a minor performance drop.
+- We conduct extensive experiments on two real-world datasets to verify the effectiveness and efficiency of our methods.
+
+# 2 Related Work
+
+# 2.1 Query-aware Snippets Extraction
+
+Query-aware snippet extraction is a widely-used technique to select snippets which can help users better understand the webpage content before clicking (Chen et al., 2020; Bando et al., 2010). Although important, only a few works have been proposed for query-aware snippet extraction based on word-level text matching method (Zou et al., 2021;
+
+Turpin et al., 2007; Penin et al., 2008; Tsegay et al., 2009). For example, Turpin et al. (2007) propose CTS, which selects snippets based on sentence positions and the number of overlapping words between queries and sentences. Zou et al. (2021) propose QUITE, which computes importance scores for each word and sums the importance scores of overlapping words to select snippets. These methods are mostly based on counting features of overlapping words and cannot capture deep semantic relations between query and webpage. Recently, Zhong et al. (2021) propose QMSUM for meeting summarization, of which the locator can be used for snippet extraction. The locator of QMSUM applies a fixed PLM and CNN to encode sentence and query, and a Transformer to model interactions between sentences. QMSUM is a bi-encoder which fails to encoder the word-level interactions between query and sentences. Zhao et al. (2021) propose QBSUM, which concatenates query and body, and applies multiple predictors to compute relevance scores. The simple body-query concatenation in QBSUM may fluctuate the information of query and lead to some sentences being cut off due to the length limitation of PLM. Recently, some works (Ishigaki et al., 2020; Chen et al., 2020) use abstractive generation model to generate snippets for (query, document) pairs. For example, Ishigaki et al. (2020) uses the RNN network with copy mechanism to generate query-aware snippets. However, abstractive methods need detailed parsing and digesting, which usually takes a considerable amount of time (Wang et al., 2007). Therefore, these methods are not compared in this paper.
+
+# 2.2 Text Matching
+
+Text matching has been widely applied in many scenarios, such as information retrieval (Pang et al., 2017) and clustering various articles for breaking news detection (Yang et al., 2002). Recently several text matching methods have been proposed. Following Humeau et al. (2020), these methods can be divided into two groups, i.e., bi-encoders and cross-encoders. Bi-encoders (Palangi et al., 2014; Reimers and Gurevych, 2019; Hu et al., 2014) model the sentence-level interactions between queries and documents, in which the document representations can be cached for fast online serving. For example, Wan et al. (2016) propose C-DSSM, which computes query and document representations with convolutional networks.
+
+
+Figure 2: Architecture of DeepQSE.
+
+Cross-encoders (Guo et al., 2016; Li et al., 2020; Chen et al., 2018) model the word-level interactions between queries and documents in a fine-grained manner. For example, Yilmaz et al. (2019) propose Birch, where (title, query) pairs are input into a pre-trained language model to compute matching scores. Cross-encoders usually perform better than bi-encoders (Urbanek et al., 2019), but have higher computation overhead since they cannot cache the document representations. Since text matching methods can retrieve the most relevant sentence to query, we treat them as baseline methods and compare the performance with them in Section 4. However, the text matching methods only consider the similarity between queries and sentences, and ignore the contextual information of webpages, which might be sub-optimal.
+
+# 3 Methodology
+
+In this section, we give the problem formulation of query-aware snippet extraction. Then we introduce our DeepQSE and Efficient-DeepQSE in detail.
+
+# 3.1 Problem Formulation
+
+When a user submits a request with query $q$ , the search engine returns several webpages. Given one of the webpage $d$ with title $t$ , it contains several sentences $\{s_1, s_2, \ldots, s_R\}$ , where $R$ is the max number of sentences in a webpage. The snippet extraction model aims to select several consecutive sentences $\{s_k, \ldots, s_{k+n}\}$ as the snippet that can summarize the webpage content in the context of input query. Since the number of sentences $n$ is given by the pre-defined snippet length, the snippet extraction model needs to select the start sentence $s_k$ .
+
+# 3.2 DeepQSE
+
+DeepQSE aims to select snippets which can best summarize the webpage content in the context of the input query. The model structure of DeepQSE is shown in Figure 2, which is composed of a query encoder, a query-aware sentence encoder and a document-aware relevance encoder. The query encoder learns query representations, which is initialized from a pre-trained language model, such as BERT (Devlin et al., 2018) and XML-RoBERTa (Chi et al., 2021). Given the query $q$ and title $t$ , the concatenation of them is input into the query encoder. The final hidden state of the first token is the query representation $\mathbf{g}_q$ . The query-aware sentence encoder models the word-level interactions between query, title and each sentence to compute query-aware sentence representations. It is initialized from a pre-trained language model, of which the input is the concatenation of title, query and each sentence. The final hidden state of the first token is the sentence representation $\mathbf{g}_s^i$ . The document-aware relevance encoder aims to model the sentence-level interactions between the query and sentences in the context of the whole webpage, which is composed of several Transformer blocks (Vaswani et al., 2017). We concatenate the query representation and sentence representations, add position embeddings and input them into the document-aware relevance encoder. The final hidden states are used as document-aware query-sentence relevance representations $\mathbf{v}_i$ , which are then used to compute the selection score $s_i^d$ .
+
+# 3.3 Efficient-DeepQSE
+
+In DeepQSE, the query and each sentence are jointly modeled, which may have slow computation speed for online serving. In order to reduce the computation overhead, we further design an efficient version of DeepQSE named Efficient-DeepQSE, which is shown in Figure 3. We decompose the query-aware snippet extraction into two stages, i.e., coarse-grained candidate sentence selection and fine-grained relevance modeling.
+
+# 3.3.1 Coarse-grained Sentence Selection
+
+The coarse-grained candidate sentence selection aims to select $K$ candidate sentences and parse them to the fine-grained relevance model for final snippet extraction. It separates the modeling of candidate sentences and queries, which enables caching sentence representations for fast online serving. The model structure of the coarse-grained
+
+
+Figure 3: Framework of the two stages in Efficient-DeepQSE.
+
+candidate selector is shown in Figure 3(a), which contains three core modules, i.e., a query encoder, a sentence encoder and a document-aware relevance encoder. The query encoder and sentence encoder aim to learn the query and sentence representations respectively, which are initialized from a pre-trained language model. We input the concatenation of query and title into the query encoder, and use the final hidden states of the first token as the query representation $\mathbf{h}_q$ . The concatenation of title and each sentence is input into the sentence encoder, and the final hidden states of the first token are treated as the sentence representation $\mathbf{h}_s^i$ . The document-aware sentence relevance encoder aims to model query-sentence relevance in the context of the whole webpage, which is composed of several Transformer blocks. We concatenate the query representation and sentence representations, add position embeddings and input them into the document-aware sentence relevance encoder. The final hidden states are the document-aware query-sentence relevance representations $\mathbf{c}_i$ , which are further used to predict selection scores $s_i^c$ through an MLP network.
+
+# 3.3.2 Fine-grained Relevance Modeling
+
+The fine-grained relevance modeling aims to capture the deep semantic relevance between query and the candidate sentences parsed from the coarse-grained sentence selection stage. It is composed of a query encoder, a query-aware sentence encoder and a document-aware relevance encoder, of which the model structure is shown in Figure 3(b). A naive implementation is directly using the same
+
+architecture of DeepQSE. However, in DeepQSE, the query and title are concatenated with different $R$ sentences and their word representations are repetitively computed for $R$ times. We assume the word representations of query in the query-aware sentence encoder have little help for query-aware snippet selection, which is validated in Section 4.6. Therefore, we design the Cross Transformer, where the word representations of the query and title are only computed once in the query encoder and parsed into the query-aware sentence encoder. The architecture of a Cross Transformer block is shown in Figure 4.
+
+The query encoder aims to learn query representations, which is initialized from a Transformer-based pre-trained language model. We input the concatenation of query and title into the query encoder and use the final hidden state of the first token as the query representation $\mathbf{l}_q$ . Meanwhile, the query encoder outputs the key and value of every multi-head self attention network to the query-aware sentence encoder. Given the previous hidden state $\mathbf{H}_q^{i - 1}$ , the key and value of the $i$ -th multi-head self attention network are computed as follows:
+
+$$
+\mathbf {K} _ {i} ^ {q} = \mathbf {W} _ {K} ^ {i} \mathbf {H} _ {q} ^ {i - 1}, \mathbf {V} _ {i} ^ {q} = \mathbf {W} _ {V} ^ {i} \mathbf {H} _ {q} ^ {i - 1}, \tag {1}
+$$
+
+where $\mathbf{W}_K^i$ and $\mathbf{W}_V^i$ are trainable parameters.
+
+The query-aware sentence encoder aims to model the fine-grained interactions between query and each sentence. It contains an embedding layer and several Cross Transformer blocks, which are initialized from a pre-trained language model. Given a sentence $s_i$ , we first compute its initial hidden state $\mathbf{H}_s^0$ through the embedding layer. The $i$ -th
+
+
+Figure 4: Architecture of the Cross Transformer model.
+
+Cross Transformer block contains a multi-head attention network and a feed-forward network. In order to compute query-aware sentence hidden states, we modify the key (or value) of multi-head attention network as the concatenation of key (or value) from query encoder and the transformed hidden state of the sentence. Given the hidden state $\mathbf{H}_s^{i - 1}$ of the previous Cross Transformer block, the query, key and value of the $i$ -th multi-head attention network are formulated as follows:
+
+$$
+\mathbf {Q} _ {i} ^ {s} = \mathbf {W} _ {Q} ^ {i ^ {\prime}} \mathbf {H} _ {s} ^ {i - 1},
+$$
+
+$$
+\mathbf {K} _ {i} ^ {s} = \mathbf {K} _ {i} ^ {q} \| \mathbf {W} _ {K} ^ {i ^ {\prime}} \mathbf {H} _ {s} ^ {i - 1}, \tag {2}
+$$
+
+$$
+\mathbf {V} _ {i} ^ {s} = \mathbf {V} _ {i} ^ {q} | | \mathbf {W} _ {V} ^ {i ^ {\prime}} \mathbf {H} _ {s} ^ {i - 1},
+$$
+
+where $\mathbf{W}_Q^{i'}$ , $\mathbf{W}_K^{i'}$ and $\mathbf{W}_V^{i'}$ are trainable parameters, || is the concatenation operator. The query, key and value are then input into the multi-head attention network and feed-forward network to compute $\mathbf{H}_s^i$ . We use the final hidden state of the first token as the query-aware sentence representation $\mathbf{l}_s^i$ .
+
+The document-aware relevance encoder aims to model query-sentence relevance in the context of the whole webpage, which contains several Transformer blocks. We concatenate the query representations and $K$ candidate sentence representations, add position embeddings on them and input them into several transformer blocks. The document-aware query-sentence relevance representations $\mathbf{f}_i$ are the final hidden states, which are then fed into an MLP to predict selection scores $s_i^f$ .
+
+# 3.3.3 Model Training and Serving
+
+For model training, we use cross-entropy loss to train the DeepQSE, which is computed as follows:
+
+$$
+\mathcal {L} = - \sum_ {i = 1} ^ {R} y _ {i} \times \log \left(\frac {\exp \left(s _ {i} ^ {d}\right)}{\sum_ {k = 1} ^ {R} \exp \left(s _ {k} ^ {d}\right)}\right), \tag {3}
+$$
+
+where $y_{i}\in \{0,1\}$ indicates whether the $i$ -th sentence is the start sentence of the snippet. For
+
+| Snippet extraction dataset | English | Multi-lingual |
| #sample | 545,240 | 348,673 |
| #query | 420,816 | 291,559 |
| #document | 330,545 | 240,005 |
| Manually labeled dataset | English | Multi-lingual |
| #sample | 19,331 | 25,851 |
| #query | 14,522 | 17,935 |
| #document | 16,995 | 22,726 |
+
+Table 1: Statistics of datasets.
+
+Efficient-DeepQSE, we also use the cross-entropy loss to train the coarse-grained candidate sentence selector and the fine-grained relevance model respectively, which is formulated as follows:
+
+$$
+\mathcal {L} _ {c} = - \sum_ {\substack {i = 1 \\ R}} ^ {R} y _ {i} \times \log \left(\frac {\exp \left(s _ {i} ^ {c}\right)}{\sum_ {k = 1} ^ {R} \exp \left(s _ {k} ^ {c}\right)}\right), \tag{4}
+$$
+
+$$
+\mathcal {L} _ {f} = - \sum_ {i = 1} ^ {R} y _ {i} \times l o g (\frac {e x p (s _ {i} ^ {f})}{\sum_ {k = 1} ^ {R} e x p (s _ {k} ^ {f})}).
+$$
+
+For model serving, when a user submits a request with query $q$ , the search engine returns several webpages. For one of the webpages $d$ with title $t$ , DeepQSE directly computes selection scores for all sentences $\{s_1^d, \ldots, s_R^d\}$ . The sentence with the maximum selection score is selected. For Efficient-DeepQSE, the server needs to offline compute the sentence representations of coarse-grained candidate sentence selector for every webpage. For the webpage $d$ , with its sentence representations of the coarse-grained candidate sentence selector $[\mathbf{h}_s^1, \ldots, \mathbf{h}_s^R]$ , we first compute the query representation of the coarse-grained candidate sentence selector $\mathbf{h}_q$ and the coarse-grained selection scores $\{s_1^c, \ldots, s_R^c\}$ . Then we feed top-K candidate sentences into the fine-grained relevance model to compute fine-grained selection scores $\{s_1^f, \ldots, s_K^f\}$ . The sentence with the maximum score is the start sentence of the snippet $s_k$ .
+
+| Methods | English | Multi-lingual |
| P@1 | P@3 | P@5 | P@1 | P@3 | P@5 |
| CTS | 39.65±0.00 | 64.57±0.00 | 88.15±0.00 | 34.64±0.00 | 59.83±0.00 | 71.16±0.00 |
| QUITE | 39.49±0.00 | 63.69±0.00 | 74.78±0.00 | 33.71±0.00 | 57.24±0.00 | 68.96±0.00 |
| QMSUM | 54.22±0.27 | 74.61±0.20 | 82.17±0.24 | 46.26±0.27 | 67.19±0.18 | 75.87±0.17 |
| QBSUM | 60.69±0.51 | 77.18±0.26 | 81.12±0.38 | 59.61±0.77 | 71.80±0.99 | 74.84±0.67 |
| BM25 | 33.91±0.00 | 60.50±0.00 | 73.15±0.00 | 27.75±0.00 | 51.99±0.00 | 65.48±0.00 |
| DSSM | 40.24±0.50 | 59.98±0.59 | 69.12±0.54 | 36.88±0.30 | 54.33±0.34 | 63.29±0.29 |
| C-DSSM | 55.46±0.31 | 72.73±0.23 | 79.39±0.26 | 49.49±0.41 | 66.32±0.37 | 73.80±0.30 |
| MatchPyramid | 55.49±0.40 | 78.04±0.40 | 85.78±0.26 | 50.74±0.35 | 73.58±0.30 | 82.05±0.39 |
| Poly-Encoder | 64.45±0.11 | 82.19±0.08 | 88.02±0.11 | 64.41±0.13 | 82.14±0.10 | 88.00±0.07 |
| Birch | 72.45±0.08 | 88.24±0.10 | 92.73±0.08 | 72.62±0.11 | 88.44±0.14 | 92.88±0.06 |
| PARADE | 73.19±0.16 | 88.65±0.12 | 92.99±0.14 | 72.94±0.20 | 88.47±0.13 | 92.89±0.13 |
| DeepQSE* | 77.05±0.29 | 92.43±0.33 | 95.94±0.14 | 77.23±0.18 | 93.30±0.09 | 96.77±0.08 |
| Efficient-DeepQSE* | 77.03±0.27 | 91.98±0.19 | 95.34±0.13 | 75.13±0.27 | 91.40±0.22 | 95.15±0.14 |
+
+Table 2: Performance of different methods on query-aware webpage snippet extraction.
+
+# 4 Experiments
+
+# 4.1 Dataset and Experimental Settings
+
+Since there is no off-the-shelf dataset for query-aware snippet extraction, we first manually labeled two small English and Multi-lingual datasets, of which the task is to select the more proper snippet given a pair of candidate sentences. The Multi-lingual dataset includes 10 languages, i.e., German, French, Spanish, Italian, Japanese, Korean, Portuguese, Russian and Chinese. Then we semiautomatically build two large English and Multi-lingual snippet extraction datasets with part of the manually-labeled datasets, of which task is to select the snippet from the sentences in the body. Due to the space limitation, the detailed dataset construction steps are described in Appendix 6. $10\%$ samples of the snippet extraction dataset are randomly sampled for testing, and the rest for training. We randomly sample $10\%$ samples of the training dataset for validation. We also the rest manually labeled dataset as another test dataset, which is not used to construct the large snippet extraction dataset. The detailed statistics of the datasets are shown in Table 1. We use precision@k $(\mathrm{k} = 1,3,5)$ as the evaluation metrics for performance on the snippet extraction test dataset, accuracy (ACC) as the evaluation metric for performance on the manually labeled test dataset, floating-point operations (FLOPs) and million seconds (ms) as the evaluation metrics for efficiency.
+
+# 4.2 Experimental Settings
+
+In our experiments, we apply BERT-base (Devlin et al., 2018) for English dataset and a distilled XML-RoBERTa (Chi et al., 2021) for Multi-
+
+Linguual dataset to initialize the pre-trained language model. We use Adam (Kingma and Ba, 2015) to optimize model training for both DeepQSE and Efficient-DeepQSE. We set the learning rate as 0.0001 and batch size as 64. The maximum query length is 16. The maximum title length is 32. The maximum sentence length is 64. The maximum number of sentences $R$ in a body is 160. The number of candidate sentences selected by the coarse-grained sentence selector $K$ is 20. All hyper-parameters are selected according to the performance on the validation dataset. We repeat each experiment 5 times and report the average results and the standard deviations.
+
+# 4.3 Performance Comparison
+
+We compare our method with multiple baselines, including conventional snippet extraction methods: (1) CTS (Turpin et al., 2007), extracting snippets based on the number of overlapping words between queries and sentences; (2) QUITE (Zou et al., 2021), selecting snippets with the summation of importance scores of overlapping words between queries and sentences; PLM-empowered snippet extraction methods: (3) QMSUM (Zhong et al., 2021), the locator of QMSUM for meeting summarization which applies a fixed PLM and CNN to encode sentence and query, and a Transformer to model interactions between sentences. (4) QB-SUM (Zhao et al., 2021), input the concatenation of query and body into a PLM, and apply multiple predictors to compute relevance scores; some text matching methods: (5) BM25 (Robertson and Zaragoza, 2009), applying the BM25 algorithm to compute similarity scores; (6) DSSM (Huang
+
+| Methods | ACC |
| English | Multi-lingual |
| CTS | 29.20±0.00 | 29.84±0.00 |
| QUITE | 24.82±0.00 | 25.73±0.00 |
| QMSUM | 38.05±0.16 | 39.61±0.21 |
| QBSUM | 21.73±0.86 | 26.26±0.65 |
| BM25 | 33.10±0.00 | 33.11±0.00 |
| DSSM | 36.67±0.46 | 37.16±0.18 |
| C-DSSM | 36.97±0.26 | 37.77±0.21 |
| MatchPyramid | 35.54±0.16 | 38.28±0.16 |
| Poly-Encoder | 37.51±0.23 | 39.82±0.22 |
| Birch | 38.17±0.28 | 39.83±0.21 |
| PARADE | 36.68±0.17 | 38.59±0.13 |
| DeepQSE* | 40.10±0.58 | 41.99±0.20 |
| Efficient-DeepQSE* | 40.57±0.34 | 41.99±0.26 |
+
+et al., 2013), a deep structured semantic matching method; (7) C-DSSM (Wan et al., 2016), a deep semantic matching structure with convolution network; (8) MatchPyramid (Pang et al., 2016), applying 2D convolution and max-pooling network on the similarity matrix of query and sentence; several PLM-empowered text matching methods: (9) PolyEncoder (Humeau et al., 2020), which adds a final attention mechanism to model the interactions between the cacheable multiple sentence representations and the query representation. (10) Birch (Yilmaz et al., 2019), inputting the concatenation of queries and sentences into BERT for document retrieval; (11) PARADE (Li et al., 2020), using a PLM to model similarity between sentences and queries, and an aggregator to model interactions between candidate sentences.
+
+The performance of all methods on snippet extraction test datasets is shown in Table 2. The performance of the methods on manually labeled test datasets is shown in Table 3. CTS, QUITE and BM25 are deterministic methods, of which standard deviations are zero. We have several observations from Table 2. First, our DeepQSE and Efficient-DeepQSE outperform conventional snippet extraction methods (CTS and QUITE). This is because these methods are based on the counting features of overlapping words between queries and sentences. Compared with our methods which utilize PLMs, they cannot capture the deep semantic relation between query and sentences. Second, our methods outperform PLM-based snippet extraction methods (QMSUM and QBSUM). This is because the simple body-query concatenation
+
+Table 3: Performance of different methods on manually labeled datasets.
+
+| Methods | English | Multi-lingual |
| FLOPs | ms | FLOPS | ms |
| CTS | - | 1.10 | - | 1.51 |
| QUITE | - | 0.13 | - | 0.10 |
| QBSUM | 45.75G | 7.97 | 11.40G | 4.02 |
| QMSUM | 1.74G | 0.41 | 0.43G | 0.17 |
| BM25 | - | 0.80 | - | 0.95 |
| DSSM | 0.30M | 0.18 | 0.30M | 0.09 |
| C-DSSM | 17.42M | 0.17 | 17.42M | 0.09 |
| MatchPyramid | 0.28G | 0.37 | 0.28G | 0.38 |
| Poly-Encoder | 1.55G | 0.19 | 0.43G | 0.08 |
| Birch | 1087.44G | 21.72 | 271.86G | 10.51 |
| PARADE | 1088.71G | 22.35 | 272.17G | 11.16 |
| DeepQSE* | 1540.08G | 31.91 | 271.86G | 16.70 |
| Efficient-DeepQSE* | 132.45G | 3.09 | 33.44G | 1.67 |
+
+Table 4: Efficiency of different methods.
+
+in QBSUM may fluctuate the information of the short query. Due to the length limitation of PLM some candidate sentences may be cut off. QMSUM is a bi-encoder which fails to encoder the word-level interactions between the query and sentences. Third, compared with several text matching methods (BM25, DSSM, C-DSSM, MatchPyramid, Poly-Encoder, Birch, QBSUM), our methods have better performance. This is because in our methods we apply webpage title and document-aware relevance encoder to select snippets in the context of the whole webpage, which can choose sentences better summarizing the webpage in the context of input query. Forth, PLM-based snippet extraction methods outperform conventional snippet extraction methods, and PLM-based text-matching methods outperform shallow-model-based text-matching methods. This is because the pre-trained language model can help better understand the semantic information in queries, titles and sentences. Finally, cross-encoder-based text matching methods outperform bi-encoder-based text matching methods. For example, MatchPyramid outperforms CDSSM and DSSM, and Birch, PARADE and DeepQSE outperform Poly-Encoder and QBSUM. This is because bi-encoders only model sentence-level similarity between queries and sentences, but cross-encoders can model word-level similarity between queries and sentences in a fine-grained manner. However, bi-encoders can cache sentence representations, which have faster online serving speed than cross-encoders.
+
+# 4.4 Efficiency Comparison
+
+In this subsection, we compare the efficiency of DeepQSE and Efficient-DeepQSE with baseline methods. The results are summarized in Table 4.
+
+Since CTS, QUITE and BM25 are not based on matrix multiplication and addition, we do not give their FLOPs results. We have several observations from Table 4. First, conventional snippet extraction methods (CTS and QUITE) have relatively low computation costs. This is because they are based on simple hand-crafted features, which can be calculated quickly. Second, cross-encoder-based methods are more time-consuming than bi-encoder-based methods. For example, DSSM and CDSSM are more efficient than MatchPyramid, and Poly-Encoder and QMSUM are more efficient than Birch, PARADE, QBSUM and DeepQSE. This is because the sentence representations in bi-encoder-based methods can be cached for quick inference. Third, PLM-based methods (PolyEncoder, Birch, PARADE, QMSUM, QBSUM, DeepQSE and Efficient-DeepQSE) have higher computation costs than other methods. This is because pre-trained language models have large size of parameters, of which the computation cost is high (Sanh et al., 2019; Beltagy et al., 2020; Jiao et al., 2020; Sun et al., 2020). Finally, considering both efficiency and the previous performance analysis in Section 4.3, our Efficient-DeepQSE achieves a great trade-off between performance and efficiency. This is because our Efficient-DeepQSE applies two-stage model, in which the coarse-grained selector can quickly select candidates for the fine-grained relevance encoder. In addition, we design the Cross Transformer which avoids repetitively computing contextual word representations of the same query for different candidate sentences. Therefore, our Efficient-DeepQSE has a lower computation cost while keeping its performance.
+
+# 4.5 Efficiency Analysis
+
+In this subsection, we analyze how the Efficient-DeepQSE reduces the computation overhead of DeepQSE with a minor performance drop. Compared with DeepQSE, the core improvement of Efficient-DeepQSE is the Cross Transformer, the coarse-grained candidate sentence selector and the fine-grained relevance model. We remove these modules separately and show their performance and efficiency in Figure 5, Figure 6 and Figure 7. We have several observations from the results. First, Efficient-DeepQSE has lower performance and lower computation overhead without the fine-grained relevance model. This is because the fine-grained relevance model captures the deep seman
+
+
+Figure 5: The impact of two-stage model and Cross Transformer on accuracy.
+
+
+Figure 6: The impact of two-stage model and Cross Transformer on efficiency (GFLOPs).
+
+tic relevance between queries, titles and sentences, which can improve the performance. And without the fine-grained relevance model, Efficient-DeepQSE does not need to perform the second stage, which lowers the computation overhead. Second, Efficient-DeepQSE can achieve higher performance but higher computation overhead without the coarse-grained candidate sentence selector. This is because the coarse-grained candidate sentence selector may select candidate sentences incorrectly, which increases the error rate. However, it helps decrease the input size of the second stage. Therefore, the computation overhead gets higher without the coarse-grained candidate sentence selector. Finally, the computation overhead is higher without Cross Transformer. This is because in Cross Transformer we only compute the query and title representations once, which avoids the repetitive computation in DeepQSE. Combined with these components, the Efficient-DeepQSE reduces the computation overhead and achieves comparable performance with DeepQSE.
+
+
+Figure 7: The impact of two-stage model and Cross Transformer on efficiency (ms).
+
+
+Figure 8: The impact of title, query and document-aware relevance encoder (DaRE) on English dataset.
+
+# 4.6 Ablation Study
+
+In this section, we analyze the impact of adding titles, queries and the document-aware relevance encoder. Due to space limitation, we only show the experimental result on Efficient-DeepQSE. The same phenomenon can be observed on DeepQSE as well. The results are shown in Figure 8 and Figure 9. From the results, we can observe that the performance of Efficient-DeepQSE gets lower without titles. This is because the titles can be treated as brief abstracts of webpages, which can help the model select sentences better summarizing the webpage content (Wang et al., 2007). It is also observed that the performance drops without queries. This is because the selected snippets should not only summarize the webpage content, but also be relevant to queries. Finally, the document-aware relevance encoder (DaRE) benefits snippet extraction. This may be because the document-aware relevance encoder can model the query-document relevance in the context of the whole webpage, which helps select snippets better summarizing the webpage content.
+
+
+Figure 9: The impact of title, query and document-aware relevance encoder (DaRE) on Multi-lingual dataset.
+
+# 5 Conclusion
+
+In this paper, we propose a query-aware snippet extraction model for web search named DeepQSE. DeepQSE first learns a query-aware sentence representation by modeling fine-grained interactions between queries, titles and sentences, then learns document-aware sentence relevance representations for snippet extraction. To lower the computation overhead of DeepQSE, we further design the Efficient-DeepQSE, where the snippet extraction is decomposed into two stages, i.e. coarse-grained candidate sentence selection and fine-grained relevance modeling. The coarse-grained selector can cache the sentence representations for fast online serving and parse several candidate sentences to the fine-grained relevance model. In the fine-grained relevance model, we further design a Cross Transformer, to avoid the repetitive computation of query and title representations for different sentences. Extensive experiments validate the effectiveness and efficiency of our approach.
+
+# 6 Limitations
+
+Our DeepQSE is a cross-encoder-based snippet extraction method. It has great performance but heavy computation overhead, which is not beneficial for online inference. We further propose Efficient-DeepQSE, an efficient version of DeepQSE, which divides the snippet extraction into two stages. Although the Efficient-DeepQSE keeps the performance of DeepQSE and has much lower computation overhead than other PLM-based methods, it still has larger computation overhead than the conventional shallow-model-based methods. We plan to further improve the efficiency of the snippet extraction algorithm in the future.
+
+# References
+
+Lorena Leal Bando, Falk Scholer, and Andrew Turpin. 2010. Constructing query-biased summaries: A comparison of human and system generated snippets. In IIiX, page 195-204.
+Iz Beltagy, Matthew E Peters, and Arman Cohan. 2020. Longformer: The long-document transformer. arXiv preprint arXiv:2004.05150.
+Haolan Chen, Fred X. Han, Di Niu, Dong Liu, Kunfeng Lai, Chenglin Wu, and Yu Xu. 2018. Mix: Multi-channel information crossing for text matching. In KDD, page 110-119.
+Wei-Fan Chen, Shahbaz Syed, Benno Stein, Matthias Hagen, and Martin Potthast. 2020. Abstractive snippet generation. In WWW, page 1309-1319.
+Zewen Chi, Li Dong, Furu Wei, Nan Yang, Saksham Singhal, Wenhui Wang, Xia Song, Xian-Ling Mao, Heyan Huang, and Ming Zhou. 2021. InfoXLM: An information-theoretic framework for cross-lingual language model pre-training. In ACL, pages 3576-3588.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. BERT: Pre-training of deep bidirectional transformers for language understanding. In *NAACL*, pages 4171–4186.
+Jiafeng Guo, Yixing Fan, Qingyao Ai, and W Bruce Croft. 2016. A deep relevance matching model for ad-hoc retrieval. In CIKM, pages 55-64.
+Baotian Hu, Zhengdong Lu, Hang Li, and Qingcai Chen. 2014. Convolutional neural network architectures for matching natural language sentences. In NIPS, page 2042-2050.
+Po-Sen Huang, Xiaodong He, Jianfeng Gao, Li Deng, Alex Acero, and Larry Heck. 2013. Learning deep structured semantic models for web search using clickthrough data. In CIKM, pages 2333-2338.
+Samuel Humeau, Kurt Shuster, Marie-Anne Lachaux, and Jason Weston. 2020. Poly-encoders: Architectures and pre-training strategies for fast and accurate multi-sentence scoring. In ICLR.
+Tatsuya Ishigaki, Hen-Hsen Huang, Hiroya Takamura, Hsin-Hsi Chen, and Manabu Okumura. 2020. Neural query-biased abstractive summarization using copying mechanism. In ECIR, pages 174-181.
+Xiaoqi Jiao, Yichun Yin, Lifeng Shang, Xin Jiang, Xiao Chen, Linlin Li, Fang Wang, and Qun Liu. 2020. TinyBERT: Distilling BERT for natural language understanding. In EMNLP Findings, pages 4163-4174.
+Diederik P Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In ICLR.
+
+Canjia Li, Andrew Yates, Sean MacAvaney, Ben He, and Yingfei Sun. 2020. Parade: Passage representation aggregation for document reranking. arXiv preprint arXiv:2008.09093.
+Hamid Palangi, Li Deng, Yelong Shen, Jianfeng Gao, Xiaodong He, Jianshu Chen, Xinying Song, and R Ward. 2014. Semantic modelling with long-short-term memory for information retrieval. arXiv preprint arXiv:1412.6629.
+Liang Pang, Yanyan Lan, Jiafeng Guo, Jun Xu, Shengxian Wan, and Xueqi Cheng. 2016. Text matching as image recognition. In AAAI, page 2793-2799.
+Liang Pang, Yanyan Lan, Jiafeng Guo, Jun Xu, Jingfang Xu, and Xueqi Cheng. 2017. Deeprank: A new deep architecture for relevance ranking in information retrieval. In CIKM, page 257-266.
+Thomas Penin, Haofen Wang, Thanh Tran, and Yong Yu. 2008. Snippets generation for semantic web search engines. In The Semantic Web, pages 493-507.
+Nils Reimers and Iryna Gurevych. 2019. SentenceBERT: Sentence embeddings using Siamese BERT-networks. In EMNLP, pages 3982-3992.
+Stephen Robertson and Hugo Zaragoza. 2009. The probabilistic relevance framework: Bm25 and beyond. Found. Trends Inf. Retr., page 333-389.
+Victor Sanh, Lysandre Debut, Julien Chaumont, and Thomas Wolf. 2019. Distilbert, a distilled version of bert: smaller, faster, cheaper and lighter. CoRR, abs/1910.01108.
+Zhiqing Sun, Hongkun Yu, Xiaodan Song, Renjie Liu, Yiming Yang, and Denny Zhou. 2020. Mobilebert: a compact task-agnostic bert for resource-limited devices. In ACL, pages 2158—2170.
+Yohannes Tsegay, Simon J Puglisi, Andrew Turpin, and Justin Zobel. 2009. Document compaction for efficient query biased snippet generation. In ECIR, pages 509-520. Springer.
+Andrew Turpin, Yohannes Tsegay, David Hawking, and Hugh E. Williams. 2007. Fast generation of result snippets in web search. In SIGIR, page 127-134.
+Jack Urbanek, Angela Fan, Siddharth Karamcheti, Saachi Jain, Samuel Humeau, Emily Dinan, Tim Rocktäschel, Douwe Kiela, Arthur Szlam, and Jason Weston. 2019. Learning to speak and act in a fantasy text adventure game. In *EMNLP*, pages 673-683.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In NIPS, page 6000-6010.
+Shengxian Wan, Yanyan Lan, Jiafeng Guo, Jun Xu, Liang Pang, and Xueqi Cheng. 2016. A deep architecture for semantic matching with multiple positional sentence representations. In AAAI, page 2835-2841.
+
+Changhu Wang, Feng Jing, Lei Zhang, and Hong-Jiang Zhang. 2007. Learning query-biased web page summarization. In CIKM, page 555-562.
+Yiming Yang, Jaime Carbonell, Ralf Brown, John Lafferty, Thomas Pierce, and Thomas Ault. 2002. Multi-strategy Learning for Topic Detection and Tracking, pages 85-114.
+Zeynep Akkalyoncu Yilmaz, Wei Yang, Haotian Zhang, and Jimmy Lin. 2019. Cross-domain modeling of sentence-level evidence for document retrieval. In EMNLP, pages 3490-3496.
+Mingjun Zhao, Shengli Yan, Bang Liu, Xinwang Zhong, Qian Hao, Haolan Chen, Di Niu, Bowei Long, and Weidong Guo. 2021. Qbsum: A large-scale query-based document summarization dataset from real-world applications. Computer Speech & Language, 66:101166.
+Ming Zhong, Da Yin, Tao Yu, Ahmad Zaidi, Mutethia Mutuma, Rahul Jha, Ahmed Hassan Awadallah, Asli Celikyilmaz, Yang Liu, Xipeng Qiu, and Dragomir Radev. 2021. QMSum: A new benchmark for query-based multi-domain meeting summarization. In NAACL, pages 5905-5921.
+Lixin Zou, Shengqiang Zhang, Hengyi Cai, Dehong Ma, Suqi Cheng, Shuaiqiang Wang, Daiting Shi, Zhicong Cheng, and Dawei Yin. 2021. Pre-trained language model based ranking in baidu search. In KDD, pages 4014-4022.
+
+| query | title | snippet |
| death park | download death park 1 8 0 for android | Death Park is a first-person horror game that turns you into a young man who's being chased by a dark clown. |
| Chromatophores in squid | chromatophores gilly lab | Chromatophores in the skin of squid ... each is an elastic pigment body, spherical at rest, surrounded by a halo of... |
| 1 km to 1 mile | 1 mi to km converter | And the answer is 0.6213711922 mi in 1 km. ... 1.609344 km in 1 mi. |
+
+Figure 10: Some snippets extracted by DeepQSE.
+
+| query | title | snippet |
| what is the size of the keyspace AES | encryption key length and message length in aes ... | AES has variable key sizes like 128,192, and 256, therefore, the keyspace K is 2 128, 2 192, and 2 256... |
| What are three natural barriers found in Ancient China? | natural barriers ancient china | There are a total of eleven natural barriers surrounding China, these include the Himalayas, Yellow Sea, Mount Everest... |
| at dead of night | at dead of night free download top pc games | At Dead Of Night is part horror film, part horror game and part ghost hunt. ... |
+
+# Appendix
+
+# Detailed Data Construction Steps
+
+The detailed data construction steps are as follows: Collect manually labeled dataset: Given a pair of candidate snippets extracted from a document, human evaluators are asked to select the more appropriate one according to the corresponding query. The manually labeled dataset can be formulated as $\{(q_i,s_{i1},s_{i2},d_i,l_i)|0\leq i < M\}$ , where $M$ is the number of samples in the dataset, $q_{i}$ is the query, $s_{i1}$ and $s_{i2}$ are candidate snippets, $d_{i}$ is the document, $l_{i}\in \{0,1\}$ is the label. $l_{i}$ equals 0 when $s_{i1}$ is more suitable than $s_{i2}$ , otherwise $l_{i}$ equals 1. At least three annotators are assigned for a sample.
+
+Build snippet extraction dataset: Since the manually labeled dataset is for pair-wise selection and is small for large PLM-based models, we train an ensemble model with the dataset to extract snippets for different documents according to corresponding queries. The extracted samples with high confidence scores are then used as the snippet extraction dataset.
+
+# Impact of Candidate Number
+
+In this subsection, we study the impact of the number of candidate sentences selected by the coarse-grained selector. The experimental results are shown in Figure 12(a) and Figure 12(b). We observe that with larger candidate sentence number, the performance of Efficient-DeepQSE is higher. This may be because the probability that the ground truth sentence is selected in the candidate sentences gets higher. However, the computation overhead of Efficient-DeepQSE linearly increases with larger candidate sentence number. How to choose
+
+
+Figure 11: Some snippets extracted by Efficient-DeepQSE.
+(a) English
+Figure 12: Impact of candidate number.
+
+
+(b) Multi-Lingual
+
+a proper candidate sentence number to achieve a great trade-off between performance and efficiency is the key point of our method.
+
+# Case Study
+
+In this subsection, we show some snippets extracted by our DeepQSE in Figure 10 and our Efficient-DeepQSE in Figure 11. In all cases, the snippets are relevant to the input query. This is because we model the word-level interactions between query and sentences in DeepQSE and Efficient-DeepQSE. Meanwhile, the selected snippets summarize the webpage content in the context of the input query. This is because we consider the context of webpage in the document-aware relevance encoder, which enables our method to capture the global webpage information.
+
+# Experimental Environments
+
+We conduct experiments with a Linux server with 8 V100 GPUs with 32GB memory. The version of CUDA is 11.1. We implement both DeepQSE and Efficient-DeepQSE with pytorch 1.9.1.
\ No newline at end of file
diff --git a/effectiveandefficientqueryawaresnippetextractionforwebsearch/images.zip b/effectiveandefficientqueryawaresnippetextractionforwebsearch/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..2c58e278f70bbb3747aaa0ebd0760d845a4a13fc
--- /dev/null
+++ b/effectiveandefficientqueryawaresnippetextractionforwebsearch/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:78edea4a2a41409847cc89ad605b00216a7a1ac0d35968b35dee4c8bf5a756be
+size 766359
diff --git a/effectiveandefficientqueryawaresnippetextractionforwebsearch/layout.json b/effectiveandefficientqueryawaresnippetextractionforwebsearch/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..717ce3e54f653f0421e0c23503e1d853fdbcb995
--- /dev/null
+++ b/effectiveandefficientqueryawaresnippetextractionforwebsearch/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1ebf1ac15333b40eb4236992f9dc0affbfcb23f12d25f8997d7f47ae3a27ffe7
+size 344987
diff --git a/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_content_list.json b/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..10ce23f27d0538626020e1da3d370d166cd15d93
--- /dev/null
+++ b/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c03443222bdb00cba91ac3bb6c7fd898ad5331caa8071d03bcad9e90c411af92
+size 95963
diff --git a/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_model.json b/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..195593f91533cfb08d988e87b220c586daf16e50
--- /dev/null
+++ b/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5843fae7a24d5c7253ec2edd8863439cde79cd61ace83671ebba841ea6cb5688
+size 118308
diff --git a/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_origin.pdf b/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..4fb382b33b182ef220cc554e0a399b584db323de
--- /dev/null
+++ b/efficientadversarialtrainingwithrobustearlybirdtickets/0a87f763-856b-4ead-ac05-15d9a15e510f_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e122cd97a9b6c351cc224168eb5474c9b9edcddc536ca13238e34f996b3ece71
+size 733612
diff --git a/efficientadversarialtrainingwithrobustearlybirdtickets/full.md b/efficientadversarialtrainingwithrobustearlybirdtickets/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..f62480fa93439f5883a1a60a049967ae02e7efdb
--- /dev/null
+++ b/efficientadversarialtrainingwithrobustearlybirdtickets/full.md
@@ -0,0 +1,406 @@
+# Efficient Adversarial Training with Robust Early-Bird Tickets
+
+Zhiheng Xi $^{1*}$ , Rui Zheng $^{1*}$ , Tao Gui $^{2\dagger}$ , Qi Zhang $^{1}$ , Xuanjing Huang $^{1,3}$
+
+$^{1}$ School of Computer Science, Fudan University, Shanghai, China
+
+$^{2}$ Institute of Modern Languages and Linguistics, Fudan University, Shanghai, China
+
+$^{3}$ International Human Phenome Institutes (Shanghai), Shanghai, China
+
+zhxi22@m.fudan.edu.cn, {rzheng20, tgui, qz, xjhuang}@fudan.edu.cn
+
+# Abstract
+
+Adversarial training is one of the most powerful methods to improve the robustness of pretrained language models (PLMs). However, this approach is typically more expensive than traditional fine-tuning because of the necessity to generate adversarial examples via gradient descent. Delving into the optimization process of adversarial training, we find that robust connectivity patterns emerge in the early training phase (typically $0.15 \sim 0.3$ epochs), far before parameters converge. Inspired by this finding, we dig out robust early-bird tickets (i.e., subnetworks) to develop an efficient adversarial training method: (1) searching for robust tickets with structured sparsity in the early stage; (2) fine-tuning robust tickets in the remaining time. To extract the robust tickets as early as possible, we design a ticket convergence metric to automatically terminate the searching process. Experiments show that the proposed efficient adversarial training method can achieve up to $7 \times \sim 13 \times$ training speedups while maintaining comparable or even better robustness compared to the most competitive state-of-the-art adversarial training methods.
+
+# 1 Introduction
+
+Pre-trained language models (PLMs) have achieved great success in NLP (Devlin et al., 2019a), but they are vulnerable to adversarial examples crafted by performing subtle perturbations on normal examples (Ren et al., 2019; Garg and Ramakrishnan, 2020). Recent studies have shown the prevalence of adversarial vulnerability in NLP tasks (Wallace et al., 2019; Zhang et al., 2021; Lin et al., 2021). Various defense strategies have been proposed to improve the robustness of the model and maintain high accuracy on both normal and adversarial examples (Zhu et al., 2020; Wang et al.,
+
+
+Adversarial Training Methods
+100% Adversarial Training
+
+
+
+
+EarlyRobust (Ours)
+1.5% ~ 3.0% Adversarial Training
+
+
+Traditional Fine-tuning
+Figure 1: A high-level overview of adversarial training methods and the proposed EarlyRobust. MHA means multi-head attention and FFN means feed-forward network. Structured pruning removes attention heads and intermediate neurons of each transformer layer in BERT. Our method achieves up to $7 \times \sim 13 \times$ training speedups compared to adversarial training methods.
+
+2021). Adversarial training is one of the most widely used and strongest defense methods (Madry et al., 2018).
+
+One of the main challenges of adversarial training in real-world applications is its high computational cost, as they require multi-step gradient descents to generate adversarial examples (Wong et al., 2020; Andriushchenko and Flammarion, 2020). Some work on this topic found that replacing strong adversarial examples with weaker and cheaper ones does not significantly change the resulting robustness (Wong et al., 2020). Zhang et al. (2019) remove redundant calculations during backpropagation for additional speedup. FreeAT (Shafahi et al., 2019) and FreeLB (Zhu et al., 2020) utilize a "free" strategy to generate diverse adversarial examples at a negligible additional cost.
+
+However, these methods are only alleviating the huge expense of generating adversarial samples, and still require optimizing the adversarial loss objective throughout the training period.
+
+The recently proposed robust lottery ticket hypothesis (Fu et al., 2021; Zheng et al., 2022b) suggests that a deep network contains robust tickets (i.e., subnetworks) that maintain matching accuracy but better robustness than the original network when trained individually. However, robust tickets have to be searched through a tedious process under the guidance of the adversarial loss objective (Zheng et al., 2022b). Moreover, these robust tickets consider unstructured sparsity, which only reduces storage but does not reduce computational overhead (Prasanna et al., 2020).
+
+In this work, we propose a novel robust early-bird ticket with structured sparsity for efficient adversarial training. We delve into the optimization process of adversarial training, and find that the robust connectivity patterns converge with few training iterations. As shown in Figure 1, we can extract robust tickets at the early stage of adversarial training by pruning the self-attention heads and intermediate neurons that contribute least to accuracy and robustness. A highly robust model can be easily obtained by fin-tuning the proposed robust tickets in the remaining time. In addition, we use a generic ticket convergence metric to automatically terminate the search process without going through each search moment. Experimental results show that the proposed method achieves up to $7 \times \sim 13 \times$ training speedups while maintaining comparable or even better adversarial robustness compared with traditional adversarial training. Our codes are publicly available at $\mathsf{G}\mathsf{i}\mathsf{h}\mathsf{u}\mathsf{b}^{1}$ . The contributions of this work can be summarized as:
+
+- We analyze the optimization process of adversarial training and reveal that the robust connectivity patterns emerge in the early training phase.
+- We propose a novel robust early-bird ticket for efficient adversarial training, which consists of two stages: (1) searching for robust tickets using adversarial training in the early stage; and (2) fine-tuning the robust tickets during the remaining time.
+- Compared with previous efficient adversarial
+
+training methods, the proposed approach provides a new pathway based on model pruning and robust architecture searching.
+
+# 2 Related Work
+
+# 2.1 Textual Adversarial Attack and Defense
+
+Textual adversarial attacks try to fool NLP models with adversarial examples which are constructed by substituting some parts of sentences with their counterparts. Typically, the adversarial examples hold a high similarity with clean ones in semantics or embedding space (Li et al., 2019; Ren et al., 2019; Jin et al., 2020; Li et al., 2020). To improve the robustness of NLP models against textual adversarial attacks, many defense methods have been proposed (Li et al., 2021; Zheng et al., 2022a; Liu et al., 2022). As the most popular one, adversarial training (AT) solves a robust min-max optimization problem by adding norm-bounded perturbations to word embeddings (Madry et al., 2018; Zhu et al., 2020; Li and Qiu, 2021). Likewise, some regularization methods have been proved beneficial to model robustness (Jiang et al., 2020; Wang et al., 2021).
+
+# 2.2 Efficient Adversarial Training Methods
+
+Adversarial training, represented by PGD (Projected Gradient Descent, Madry et al. (2018)), costs much more computational resources than traditional training due to the need to construct adversarial examples. Therefore, some recent works attempt to improve its efficiency. FreeAT (Shafahi et al., 2019) andYOPO (Zhang et al., 2019) simplify the calculation of gradients to get speedups. Zhu et al. (2020) introduce the above accelerating methods to NLP and propose FreeLB, which adds adversarial perturbations to word embeddings. Our method shapes structured robust tickets in the early adversarial training stage, so it is orthogonal to the above methods.
+
+# 2.3 Lottery Ticket Hypothesis
+
+Lottery Ticket Hypothesis (LTH) suggests that there exist certain sparse subnetworks (i.e., winning tickets) at initialization that can be trained to achieve competitive performance compared to the full model (Frankle and Carbin, 2019). In NLP, previous work has found that matching subnetworks exist in Transformers, LSTMs, and PLMs (Yu et al., 2020; Renda et al., 2020; Chen et al., 2020). Prasanna et al. (2020) find structured
+
+tickets for BERT, which are efficient in training and inference, by pruning attention heads and MLP layers. Recently, You et al. (2020) and Chen et al. (2021) pioneer to identify Early-Bird tickets at the early stage of training. Fu et al. (2021) and Zheng et al. (2022b) find unstructured robust tickets in neural networks and thus the robust LTH is proposed. However, the search process for winning robust tickets is tedious. A concurrent work in CV jointly identifies and trains unstructured Flying Bird tickets with PGD-AT(Chen et al., 2022), while we explore the convergence of robust connectivity patterns in NLP. Particularly, we identify robust early-bird tickets with structured sparsity and apply them to fine-tuning.
+
+# 3 Methodology
+
+In this section, we first revisit the robust lottery ticket hypothesis (Sec.3.1). Next, we describe the early emergence of structured robust tickets (Sec.3.2). Based on this key finding, we propose the EarlyRobust method for efficient adversarial training (Sec.3.3). Finally, we make a brief review and discuss how our method accelerates adversarial training (Sec.3.4).
+
+# 3.1 Revisiting Robust Lottery Ticket Hypothesis
+
+For a network $f(\theta_0)$ initialized with parameters $\theta_0$ , we can identify a binary mask $m$ which has the same dimension as $\theta_0$ , such that a subnetwork $f(m \odot \theta_0)^2$ can be shaped. Robust lottery ticket hypothesis articulates that, there exists certain subnetwork that can be trained to have matching performance and better robustness compared to the full model following the same training protocol (Zheng et al., 2022b). Such a subnetwork $f(m \odot \theta_0)$ is a so-called robust winning ticket, including both the mask $m$ and the initialization $\theta_0$ .
+
+# 3.2 Early Emergence of Robust Tickets with Structured Sparsity
+
+In previous work, robust tickets with unstructured sparsity in PLMs are extracted after a tedious training process. However, when applying a structured pruning strategy, we observe that robust tickets with structured sparsity emerge in the early training stage. The structured pruning strategy aims at pruning self-attention heads and intermediate neurons of each transformer layer in
+
+BERT. Through visualizing the normalized mask distance between different training steps (You et al., 2020) in Figure 2, we learn that the structure of a robust ticket can be identified at a very early adversarial training stage. Inspired by this finding, we propose an efficient adversarial training method that draws robust early-bird tickets at the early adversarial training stage and then fine-tunes these tickets to achieve better robustness.
+
+# 3.3 Robust Early-bird Tickets
+
+Our method consists of two steps: 1) Searching Stage; 2) Drawing and Fine-tuning Stage.
+
+# 3.3.1 Searching Stage
+
+BERT is constructed by a stack of transformer encoder layers (Vaswani et al., 2017), and the structure of each layer is identical: a multi-head self-attention (MHA) block followed by a feedforward network (FFN), with residual connections around each. In each layer, the MHA with $N_{h}$ heads takes an input $x$ and outputs:
+
+$$
+\operatorname {M H A} (x) = \sum_ {i = 1} ^ {N _ {h}} \operatorname {A t t} _ {W _ {K} ^ {i}, W _ {Q} ^ {i}, W _ {V} ^ {i}, W _ {O} ^ {i}} (x), \tag {1}
+$$
+
+where $W_{K}^{i}, W_{Q}^{i}, W_{V}^{i} \in \mathbb{R}^{d_{h} \times d}, W_{O}^{i} \in \mathbb{R}^{d \times d_{h}}$ , and they denote the query, key, value and output matrices in the $l$ -th attention head. Here $d$ denotes the hidden size (e.g., 768) and $d_{h} = d / N_{h}$ denotes the output dimension of each head (e.g., 64).
+
+Next comes an FFN parameterized by $W_{U} \in \mathbb{R}^{d \times d_{f}}$ and $W_{D} \in \mathbb{R}^{d_{f} \times d}$ :
+
+$$
+\operatorname {F F N} (x) = \operatorname {g e l u} \left(X W _ {U}\right) \cdot W _ {D}, \tag {2}
+$$
+
+where $d_{f} = 4d$
+
+Learnable Importance Coefficients Recent research reveals that MHAs and FFNs in transformers are redundant (Michel et al., 2019; Voita et al., 2019). Therefore, we adopt the modified network slimming (Liu et al., 2017; Chen et al., 2021), which assigns learnable importance coefficients to self-attention heads and intermediate neurons, to determine which components are essential for robustness:
+
+$$
+\operatorname {M H A} (x) = \sum_ {i = 1} ^ {N _ {h}} c _ {\mathrm {H}} ^ {i} \cdot \operatorname {A t t} _ {W _ {K} ^ {i}, W _ {Q} ^ {i}, W _ {V} ^ {i}, W _ {O} ^ {i}} (x), \tag {3}
+$$
+
+$$
+\operatorname {F F N} (x) = c _ {\mathrm {F}} \cdot \operatorname {g e l u} \left(X W _ {U}\right) \cdot W _ {D}, \tag {4}
+$$
+
+where $c_{\mathrm{H}}$ denotes the coefficients for heads, $i$ is the index of head, and $c_{\mathrm{F}}$ denotes the coefficients for
+
+
+(a)IMDB MHA
+
+
+(b) SST-2 MHA
+
+
+(c) AG NEWS MHA
+
+
+(d)IMDBFFN
+
+
+(e) SST-2 FFN
+
+
+(f) AG NEWS FFN
+Figure 2: Visualization of mask difference in Hamming distance between different training steps. Top: mask distance in self-attention heads. Bottom: mask distance in intermediate neurons. The axes represent the numbers of training steps finished and the color stands for the normalized distance between different masks. The darker the color, the smaller the distance. The masks for attention heads and intermediate neurons both converge early.
+
+the FFN. Then, we can jointly train BERT with the importance coefficients but with a regularizer:
+
+$$
+\mathcal {R} (c) = \lambda_ {\mathrm {H}} \| c _ {\mathrm {H}} \| _ {1} + \lambda_ {\mathrm {F}} \| c _ {\mathrm {F}} \| _ {1}, \tag {5}
+$$
+
+where $c = \{c_{\mathrm{H}}, c_{\mathrm{F}}\}$ , $\lambda_{\mathrm{H}}$ and $\lambda_{\mathrm{F}}$ denote regularization strength for the two kinds of coefficients respectively.
+
+Adversarial Loss Objective To identify substructures that are responsible for adversarial robustness, we introduce the adversarial loss objective:
+
+$$
+\underset {\theta , c} {\min } \underbrace {\mathbb {E} _ {(x , y) \sim \mathcal {D}} \underset {\| \delta \| \leq \epsilon} {\max } \mathcal {L} (f (x + \delta ; \theta , c) , y)} _ {\mathcal {L} _ {a d v} (\theta , c)}, \tag {6}
+$$
+
+where $(x,y)$ is a data point from dataset $\mathcal{D}$ , $\delta$ is the perturbation that is constrained within the $\epsilon$ ball. The inner max problem tries to generate worst-case perturbation towards inputs and maximize the model's classification loss, while the outer min problem is to optimize the model on the perturbed data.
+
+Then, by integrating the adversarial training objective and the sparsity regularizer $\mathcal{R}(c)$ , we can describe our loss objective as follow:
+
+$$
+\min _ {\theta , c} \mathcal {L} _ {a d v} (\theta , c) + \mathcal {R} (c). \tag {7}
+$$
+
+After the joint training, we draw robust tickets, reset the parameters and then train the tickets with traditional fine-tuning.
+
+# 3.3.2 Drawing and Fine-tuning Stage
+
+Early-stopping Strategy As mentioned before, robust tickets with structured sparsity can be identified in the early adversarial training stage. However, it is difficult to determine the exact search termination time. The difficulty lies mainly in the following two aspects: (1) the termination time varies among datasets; (2) the termination moments of MHA and FFN in the same model are different. Therefore, we design a termination metric that measures the normalized mask distance between consecutive miniepochs (each miniepoch consists of 0.05 epochs). When the termination metric is smaller than the threshold $\gamma$ both for MHA and FFN, we extract robust early-bird tickets. Similar termination metrics are widely used for the extraction of subnetworks (You et al., 2020). To ensure the consistency of convergence, we end the subnetwork search stage when the termination metric is satisfied five times in a row.
+
+Pruning Strategy At the end of the search process, we prune the unimportant parts according to the magnitudes of the learned importance coefficients. The attention heads and intermediate neurons with the smallest importance coefficients are considered
+
+# Algorithm 1: EarlyRobust Method
+
+Input: model parameters $\theta$ , learnable importance coefficients $c$ , learning rate $\eta$ and the fine-tuning epoch $N$ .
+
+1 Procedure ROBUST TICKETS SEARCHING Initialize $\theta, c$ ;
+2 repeat
+3 $\theta = \theta -\eta \nabla_{\theta}(\mathcal{L}_{adv}(\theta ,c) + \mathcal{R}(c));$ 4 $c = c - \eta \nabla_{c}(\mathcal{L}_{adv}(\theta ,c) + \mathcal{R}(c));$
+5 until the convergence condition in Sec.3.3.2 is satisfied;
+6 Procedure DRAWING AND FINE-TUNING Extract robust winning tickets parameterized by $\theta_{\text{ticket}}$ ;
+7 for epoch $\leftarrow 1\dots N$ do
+8 $\theta_{\text{ticket}} \gets \theta - \eta \nabla_{\theta_{\text{ticket}}} \mathcal{L}_{CE}$ ;
+9 end
+
+to contribute the least to robustness and should be removed. For attention heads, we not only remove them from the computation graph, but also remove the corresponding $W_{O}$ (see Eqn. (3)). We adopt a modified global approach to prune the heads and ensure that at least one head survives in each layer. As for intermediate neurons, pruning them is equivalent to reducing the size of $W_{U}$ and $W_{D}$ in Eqn. (4). We prune intermediate neurons globally as there is a large number of neurons in each FFN layer and empirical analysis suggests that global approach brings better performance.
+
+Efficient Robust Fine-tuning After pruning attention heads and intermediate neurons, we then reset the weights to the pre-trained weights and utilize traditional fine-tuning to train the robust tickets.
+
+# 3.4 A Brief Review
+
+The proposed method searches for the key connectivity patterns for robustness, draws the winning tickets and trains them with traditional fine-tuning. We summarize it in Algorithm 1.
+
+How does EarlyRobust accelerate adversarial training? Firstly, the method draws robust tickets with structured sparsity, which reduces the size of models and speeds up training and inference. Secondly, the early-stopping strategy prevents the
+
+tedious searching process for robust tickets. Finally, the method trains the robust early-bird tickets with traditional fine-tuning instead of adversarial training methods, getting rid of the time-consuming process to construct adversarial examples.
+
+# 4 Experimental Settings
+
+# 4.1 Backbone Model and Datasets
+
+We take $\mathrm{BERT}_{\mathrm{BASE}}$ (12 transformer layers, 12 attention heads, 3,072 intermediate neurons per layer, hidden size 768 and 110M parameters in total) as the backbone model. We follow the BERT implementation in (Devlin et al., 2019b; Wolf et al., 2019). Mainly, we evaluate the proposed method on three text classification datasets, including IMDB (Maas et al., 2011), SST-2 (Socher et al., 2013), and AG NEWS (Zhang et al., 2015). We also include other datasets of more tasks in GLUE (Wang et al., 2019) as a supplement, such as QNLI and QQP.
+
+# 4.2Baselines
+
+We compare our method with fine-tuned BERT, EarlyBERT, and several strong robust baselines. Fine-tune (Devlin et al., 2019b): Training full BERT on downstream tasks. EarlyBERT (Chen et al., 2021): A framework that draws early-bird tickets from BERT for efficient fine-tuning. PGD (Madry et al., 2018): An adversarial training algorithm that minimizes the empirical loss on worst-case adversarial examples. FreeLB (Zhu et al., 2020): An enhanced PGD-based adversarial training method for natural language understanding. InfoBERT (Wang et al., 2021): A framework that improves model's robustness from an information-theoretic perspective. Robust (Zheng et al., 2022b): An approach that identifies robust tickets from the original PLMs through learning binary masks.
+
+# 4.3 Evaluation Settings
+
+Robust Evaluation We apply three popular textual attack methods (Li et al., 2021) to evaluate the model's defensive capability. TextBugger (Li et al., 2019) generates misspelled words by using character-level and word-level perturbations. TextFooler (Jin et al., 2020) constructs adversarial examples by substituting the most important words in a sentence with synonyms. BERT-Attack (Li et al., 2020) employs BERT to generate adversarial
+
+| Dataset | Method | Speedup | Params | Clean% | TextFollower | TextBugger | BERT-Attack |
| Aua% | #Query | Aua% | #Query | Aua% | #Query |
| IMDB | Fine-tune† | 9.4× | 85M | 92.05 | 11.8 | 922.4 | 23.2 | 695.2 | 7.8 | 1187.0 |
| EarlyBERT† | 15.6× | 58M | 91.9 | 3.4 | 874.9 | 12.6 | 649.7 | 0.8 | 1099.9 |
| PGD‡ | 1.0× | 85M | 93.2 | 30.2 | 1562.8 | 41.6 | 905.8 | 21.8 | 2114.6 |
| FreeLB‡ | 1.2× | 85M | 93.2 | 35.0 | 1736.9 | 53.0 | 1110.9 | 29.0 | 2588.8 |
| InfoBERT‡ | 0.3× | 85M | 93.3 | 49.6 | 1932.3 | 53.8 | 1070.4 | 47.2 | 3088.8 |
| Robust‡ | 0.4× | 68M | 91.8 | 58.6 | 1994.7 | 63.6 | 1153.3 | 58.0 | 3120.2 |
| EarlyRobust | 12.6× | 58M | 91.8 | 63.8 | 2012.8 | 63.8 | 1107.1 | 63.0 | 3125.6 |
| SST-2 | Fine-tune† | 10.1× | 85M | 92.2 | 17.9 | 123.4 | 40.6 | 53.4 | 13.3 | 158.3 |
| EarlyBERT† | 18.6× | 63M | 92.3 | 13.4 | 111.5 | 37.7 | 52.9 | 9.9 | 138.9 |
| PGD‡ | 1.0× | 85M | 93.2 | 18.1 | 118.5 | 44.2 | 56.0 | 13.4 | 151.3 |
| FreeLB‡ | 1.4× | 85M | 91.7 | 29.4 | 152.6 | 49.7 | 58.6 | 23.8 | 174.7 |
| InfoBERT‡ | 0.6× | 85M | 92.4 | 18.3 | 126.8 | 42.4 | 54.6 | 15.0 | 160.4 |
| Robust‡ | 0.4× | 60M | 90.9 | 28.6 | 149.8 | 43.1 | 53.9 | 20.8 | 169.2 |
| EarlyRobust | 13.7× | 63M | 92.8 | 28.8 | 142.8 | 46.3 | 61.9 | 22.7 | 187.1 |
| AG NEWS | Fine-tune† | 6.8× | 85M | 94.6 | 28.6 | 383.3 | 45.2 | 192.5 | 17.6 | 556.0 |
| EarlyBERT† | 7.2× | 69M | 94.5 | 32.8 | 392.3 | 46.6 | 195.4 | 21.2 | 571.1 |
| PGD‡ | 1.0× | 85M | 95.0 | 36.8 | 414.9 | 56.4 | 201.8 | 21.6 | 616.1 |
| FreeLB‡ | 1.3× | 85M | 95.0 | 34.8 | 408.5 | 54.2 | 210.3 | 20.4 | 596.2 |
| InfoBERT‡ | 0.4× | 85M | 94.5 | 33.8 | 395.6 | 49.6 | 194.1 | 23.4 | 618.9 |
| Robust‡ | 0.4× | 60M | 94.9 | 35.2 | 415.6 | 49.0 | 206.9 | 21.8 | 617.5 |
| EarlyRobust | 7.0× | 69M | 94.4 | 41.0 | 416.2 | 50.0 | 216.4 | 32.2 | 620.1 |
+
+Table 1: Experimental results of adversarial robustness evaluation. The best performance is marked in bold and underline; the second is marked in bold. Speedup means training speedup, which is reported against adversarial training method PGD. Params is the number of model parameters. Methods labeled by $\dagger$ are fine-tuning baselines without considering adversarial robustness, and methods labeled by $\ddagger$ are adversarial defense baselines. Our method achieves high adversarial robustness while maintaining a low computational and storage consumption.
+
+texts, and thus the semantic consistency and the language fluency are preserved.
+
+We adopt three evaluating metrics as follows: Clean accuracy (Clean%) is the model's accuracy on the clean test set. Accuracy under attack (Aua%) denotes the model's prediction accuracy under certain adversarial attack methods. Number of Queries (#Query) refers to the average attempts an attacker queries the model, and the larger the number of queries is, the more difficult the model is to be fooled.
+
+Training Time Measurement Protocol We measure the training time of each method on GPU and exclude the time for data I/O. To get rid of randomness, we run each method five times and report the average time. Notably, the training time of LTH-based methods (e.g., EarlyRobust, EarlyBERT, and RobusT) includes both the searching stage and the fine-tuning stage.
+
+# 4.4 Implementation Details
+
+We re-implement baseline methods based on their open-source codes and the results are competitive. We employ FreeLB to implement the adversarial
+
+loss objective in the searching stage of EarlyRobust because compared to standard $K$ -step PGD, it accumulates gradients of parameters in multiple forward passes and passes gradients backward once. Clean% is tested on the whole test set. Aua% and #Query are evaluated on the whole test dataset for SST-2, and 500 randomly chosen samples for other datasets. We set the early-stopping threshold $\gamma$ to 0.1 and fine-tune EarlyRobust tickets 10 epochs. For fine-tuning, EarlyBERT, and other adversarial training methods, we also set the training epoch to 10, which is a trade-off between training cost and performance. The sparsity for EarlyBERT is the same as that of EarlyRobust. We prune $40\%$ , $30\%$ , $20\%$ , $30\%$ and $30\%$ intermediate neurons on IMDB, SST-2, AG NEWS, QNLI and QQP, respectively; the pruning ratio for attention heads is $1/6$ . More implementation details and hyperparameters can be found in Appendix A.2.
+
+# 5 Experimental Results and Discussion
+
+In this section, we illustrate the effectiveness and efficiency of our method with experimental results.
+
+| Dataset | Method | Speedup | Params | Clean% | Aua% |
| QNLI | Fine-tune† | 9.6× | 85M | 91.6 | 5.8 |
| PGD‡ | 1.0× | 85M | 91.2 | 12.2 |
| FreeLB‡ | 1.3× | 85M | 90.5 | 12.8 |
| EarlyRobust | 12.2× | 63M | 91.4 | 18.8 |
| QQP | Fine-tune† | 9.8× | 85M | 91.3 | 24.8 |
| PGD‡ | 1.0× | 85M | 91.2 | 27.0 |
| FreeLB‡ | 1.3× | 85M | 91.2 | 27.4 |
| EarlyRobust | 13.6× | 63M | 90.9 | 32.6 |
+
+# 5.1 Main Results
+
+The main results of EarlyRobust and other baselines are summarized in Table 1. We can observe that: 1) Our method achieves high robustness with a little sacrifice in accuracy. It performs slightly worse than FreeLB on SST-2, but achieves the best robustness on both IMDB and AG NEWS, suggesting that the subnetworks shaped by our method own inborn robustness which can be exerted through traditional fine-tuning. 2) Our method achieves sizable training accelerations compared to robust baselines. This proves our method can deliver highly robust models under different kinds of adversarial attacks with limited computational resources. Though EarlyBERT and fine-tuning are also fast, they do not take robustness into account and thus have weak defensive capabilities. 3) Our method also brings storage savings, and thus robust early-bird tickets are suitable to be deployed on mobile devices and edge devices.
+
+We evaluate our method on paraphrase and inference tasks to verify its generality. Results in Table 2 show that our method consistently performs well on more difficult tasks.
+
+# 5.2 Ablation Study
+
+To investigate the contribution of different components to our method, we perform ablation experiments by removing adversarial loss objective (Adv) and sparsity-inducing regularizer. We also evaluate the performance of randomly pruned tickets. Results in Table 3 show that: 1) Adversarial loss objective is important for robustness, but not for clean accuracy. 2) There exists degradation in both accuracy and robustness if we remove the regularizer, indicating that the sparsity it
+
+Table 2: Experimental results on QNLI and QQP. Aua% is obtained after using TextFooler attack. Our method brings robustness improvement and training speedups on different tasks.
+
+| Dataset | Method | Clean% | Aua% |
| IMDB | EarlyRobust | 91.8 | 63.8 |
| w/o Adv | 92.0 | 6.4 |
| w/o Regularizer | 87.5 | 31.2 |
| Random Tickets | 91.1 | 6.2 |
| SST-2 | EarlyRobust | 92.8 | 28.8 |
| w/o Adv | 92.2 | 13.9 |
| w/o Regularizer | 91.3 | 8.5 |
| Random Tickets | 90.9 | 9.1 |
| AG NEWS | EarlyRobust | 94.4 | 41.0 |
| w/o Adv | 94.6 | 31.0 |
| w/o Regularizer | 92.5 | 31.2 |
| Random Tickets | 94.0 | 19.4 |
+
+Table 3: Ablation study. $\mathbf{Aua}\%$ is obtained after using TextFollower attack. Results of randomly pruned tickets are the average of 5 trials with different random seeds. Both Adversarial loss objective and sparsity-inducing regularizer play a fundamental role for high-quality tickets. Random tickets suffer a large degradation in robustness, indicating that robust tickets are non-trivial.
+
+
+Figure 3: Influence of different early-stopping thresholds (i.e., $\gamma$ ) on model robustness. Aua% is obtained after using TextFooler attack and the results are obtained from 5 trials of different random seeds. Model robustness converges when $\gamma$ decreases to around 0.1.
+
+induces is indispensable for high-quality tickets. 3) Randomly pruned tickets have a competitive accuracy performance, which is also observed by (Prasanna et al., 2020). However, random tickets consistently suffer a large drop in robustness, which proves that robust tickets are non-trivial.
+
+# 5.3 Different Early-stopping Thresholds
+
+Here we study how different early-stopping thresholds affect the model's robustness. Results in Figure 3 show that the model's robustness converges when $\gamma$ is reduced to around 0.1. Considering training efficiency, we think 0.1 is a reasonable threshold.
+
+| Dataset | Method | Clean% | Aua% |
| IMDB | EarlyRobust | 91.8 | 63.8 |
| w/o Initialization | 82.4 | 0.0 |
| w/o Structure | 89.2 | 4.0 |
| SST-2 | EarlyRobust | 92.8 | 28.8 |
| w/o Initialization | 81.5 | 0.8 |
| w/o Structure | 88.4 | 20.0 |
| AG NEWS | EarlyRobust | 94.4 | 41.0 |
| w/o Initialization | 92.2 | 0.6 |
| w/o Structure | 94.4 | 36.6 |
+
+# 5.4 Importance of Early Robust Tickets Initialization and Structure
+
+According to LTH, the winning tickets can not be trained effectively without original initialization and the ticket structure also plays a role (Frankle and Carbin, 2019). Therefore, we follow a similar way in (Zheng et al., 2022b) to study the importance of the initialization and the structure of EarlyRobust tickets. Specifically, we re-initialize the weights of EarlyRobust tickets to exclude the effect of the initialization. We employ the full BERT and re-initialize the weights which are not contained in the robust tickets to exclude the effect of the structure while preserving the effect of the initialization. Table 4 demonstrates that the pretrained initialization and the structure are both fundamental for model performance. Another observation is that without the initialization, robust tickets suffer a greater performance drop than without the structure.
+
+# 5.5 Impact of Sparsity
+
+In our method, structured sparsity can not only bring speedups but also save the storage. Figure 4 illustrates that as the sparsity (both for heads and neurons) increases, the accuracy shows a gradually decreasing trend, but the robustness is different. The robustness first increases and then degrades sharply as sparsity grows, which is similar to the observations in (Fu et al., 2021). To extract high-quality tickets, $1/6 \sim 1/4$ and $20\% \sim 40\%$ are suitable pruning ratio ranges for heads and neurons, respectively. We also visualize the sparsity patterns in Appendix A.3.
+
+
+(a) Clean% on FC Sparsity
+
+
+(b) Clean% on Heads Sparsity
+
+
+(c) Aua% on FC Sparsity
+
+
+(d) Aua% on Heads Sparsity
+Figure 4: Impact of Sparsity on Clean% and Aua%. Aua% is obtained under TextFollower attack.
+
+Table 4: Importance of EarlyRobust ticket initialization and structure. $\mathbf{A}\mathbf{u}\mathbf{a}\%$ is obtained under TextFollower attack. The pre-trained initialization and the structure are both indispensable for EarlyRobust tickets. The pre-trained initialization seems more important than the structure.
+
+| Clean% | Heads-L | Heads-G |
| Aua% |
| Neurons-L | 91.5 | 91.6 |
| 1.2 | 35.4 |
| Neurons-G | 91.4 | 91.7 |
| 56.0 | 63.8 |
+
+Table 5: Influence of global and layer-wise pruning on model performance on IMDB. -L means layerwise while -G means global. Aua% is obtained under TextFooler attack. Global pruning outperforms layerwise pruning in terms of robustness.
+
+# 5.6 Global Pruning vs. Layer-wise Pruning
+
+As mentioned in Sec.3.3.2, we prune self-attention heads and intermediate neurons separately with global approach. Here we study how global pruning and layer-wise pruning influence model performance. Table 5 demonstrates the results on IMDB.6 We can observe that: 1) Layerwise pruning performs as well as global pruning in accuracy, but it induces a degradation in robustness, revealing that different layers have different degrees of contribution to robustness. So different layers should not be pruned with the same ratio. 2) The model's robustness drops more dramatically when we use layer-wise pruning for neurons than for heads, suggesting that intermediate neurons are more sensitive to pruning approaches.
+
+# 6 Conclusion
+
+In this paper, we delve into the optimization process of adversarial training on BERT, and observe the early convergence of robust connectivity patterns. Based on this, we propose EarlyRobust, a method that shapes structured robust early-bird tickets under the guidance of the adversarial loss objective and then utilizes efficient fine-tuning to train them. Experiments on various datasets demonstrate that our method achieves competitive or even better robustness compared to other strong baselines while maintaining a very low computational and storage consumption.
+
+# Limitation
+
+In this work, we propose a method to draw structured robust early-bird tickets, which can be used as an efficient alternative to adversarial training. However, there are still limitations to be explored in future work: 1) Model robustness drops sharply when the pruning ratio is too large, so our robust tickets do not have high sparsity. We expect to compress the robust early-bird tickets to a smaller size while maintaining a high quality in the future. 2) We draw the robust early-bird tickets from pre-trained models, and future work includes searching for robust early-bird tickets from randomly initialized networks.
+
+# Ethics Statement
+
+Our method is proposed for efficient adversarial training, so it is environmental-friendly. It achieves up to $7 \times 13 \times$ speedups compared to standard adversarial training, saving computational resources by a significant margin. Moreover, the proposed robust early-bird tickets with structured sparsity bring savings in storage, so it is easy to deploy them on mobile devices and edge devices.
+
+# Acknowledgements
+
+The authors wish to thank the anonymous reviewers for their helpful comments. This work was partially funded by National Natural Science Foundation of China (No. 62206057, 61906176, 62076069, 61976056), Program of Shanghai Academic Research Leader (No. 22XD1401100), Beijing Academy of Artificial Intelligence (BAAI) and CCF-Tencent Open Fund.
+
+# References
+
+Maksym Andriushchenko and Nicolas Flammarion. 2020. Understanding and improving fast adversarial training. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Tianlong Chen, Jonathan Frankle, Shiyu Chang, Sijia Liu, Yang Zhang, Zhangyang Wang, and Michael Carbin. 2020. The lottery ticket hypothesis for pre-trained BERT networks. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Tianlong Chen, Zhenyu Zhang, Pengjun Wang, Santosh Balachandra, Haoyu Ma, Zehao Wang, and Zhangyang Wang. 2022. Sparsity winning twice: Better robust generalization from more efficient training. In The Tenth International Conference on Learning Representations, ICLR 2022, Virtual Event, April 25-29, 2022. OpenReview.net.
+Xiaohan Chen, Yu Cheng, Shuohang Wang, Zhe Gan, Zhangyang Wang, and Jingjing Liu. 2021. Earlybert: Efficient BERT training via early-bird lottery tickets. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 1: Long Papers), Virtual Event, August 1-6, 2021, pages 2195-2207. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019a. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019b. BERT: pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics.
+Jonathan Frankle and Michael Carbin. 2019. The lottery ticket hypothesis: Finding sparse, trainable neural networks. In 7th International Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019. OpenReview.net.
+Yonggan Fu, Qixuan Yu, Yang Zhang, Shang Wu, Xu Ouyang, David D. Cox, and Yingyan Lin.
+
+2021. Drawing robust scratch tickets: Subnetworks with inborn robustness are found within randomly initialized networks. In Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual, pages 13059-13072.
+Siddhant Garg and Goutham Ramakrishnan. 2020. BAE: BERT-based adversarial examples for text classification. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6174-6181, Online. Association for Computational Linguistics.
+Haoming Jiang, Pengcheng He, Weizhu Chen, Xiaodong Liu, Jianfeng Gao, and Tuo Zhao. 2020. SMART: robust and efficient fine-tuning for pretrained natural language models through principled regularized optimization. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 2177-2190. Association for Computational Linguistics.
+Di Jin, Zhijing Jin, Joey Tianyi Zhou, and Peter Szolovits. 2020. Is BERT really robust? A strong baseline for natural language attack on text classification and entailment. In The Thirty-Fourth AAAI Conference on Artificial Intelligence, AAAI 2020, The Thirty-Second Innovative Applications of Artificial Intelligence Conference, IAAI 2020, The Tenth AAAI Symposium on Educational Advances in Artificial Intelligence, EAAI 2020, New York, NY, USA, February 7-12, 2020, pages 8018-8025. AAAI Press.
+Jinfeng Li, Shouling Ji, Tianyu Du, Bo Li, and Ting Wang. 2019. Textbugger: Generating adversarial text against real-world applications. In 26th Annual Network and Distributed System Security Symposium, NDSS 2019, San Diego, California, USA, February 24-27, 2019. The Internet Society.
+Linyang Li, Ruotian Ma, Qipeng Guo, Xiangyang Xue, and Xipeng Qiu. 2020. BERT-ATTACK: adversarial attack against BERT using BERT. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 6193-6202. Association for Computational Linguistics.
+Linyang Li and Xipeng Qiu. 2021. Token-aware virtual adversarial training in natural language understanding. In Thirty-Fifth AAAI Conference on Artificial Intelligence, AAAI 2021, Thirty-Third Conference on Innovative Applications of Artificial Intelligence, IAAI 2021, The Eleventh Symposium on Educational Advances in Artificial Intelligence, EAAI 2021, Virtual Event, February 2-9, 2021, pages 8410-8418. AAAI Press.
+Zongyi Li, Jianhan Xu, Jiehang Zeng, Linyang Li, Xiaoqing Zheng, Qi Zhang, Kai-Wei Chang, and Cho-Jui Hsieh. 2021. Searching for an
+
+effective defender: Benchmarking defense against adversarial word substitution. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, EMNLP 2021, Virtual Event / Punta Cana, Dominican Republic, 7-11 November, 2021, pages 3137-3147. Association for Computational Linguistics.
+Jieyu Lin, Jiajie Zou, and Nai Ding. 2021. Using adversarial attacks to reveal the statistical bias in machine reading comprehension models. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 333-342, Online. Association for Computational Linguistics.
+Qin Liu, Rui Zheng, Bao Rong, Jingyi Liu, Zhihua Liu, Zhanzhan Cheng, Liang Qiao, Tao Gui, Qi Zhang, and Xuanjing Huang. 2022. Flooding-x: Improving bert's resistance to adversarial attacks via loss-restricted fine-tuning. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), ACL 2022, Dublin, Ireland, May 22-27, 2022, pages 5634-5644. Association for Computational Linguistics.
+Zhuang Liu, Jianguo Li, Zhiqiang Shen, Gao Huang, Shoumeng Yan, and Changshui Zhang. 2017. Learning efficient convolutional networks through network slimming. In IEEE International Conference on Computer Vision, ICCV 2017, Venice, Italy, October 22-29, 2017, pages 2755-2763. IEEE Computer Society.
+Andrew L. Maas, Raymond E. Daly, Peter T. Pham, Dan Huang, Andrew Y. Ng, and Christopher Potts. 2011. Learning word vectors for sentiment analysis. In The 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies, Proceedings of the Conference, 19-24 June, 2011, Portland, Oregon, USA, pages 142-150. The Association for Computer Linguistics.
+Aleksander Madry, Aleksandar Makelov, Ludwig Schmidt, Dimitris Tsipras, and Adrian Vladu. 2018. Towards deep learning models resistant to adversarial attacks. In 6th International Conference on Learning Representations, ICLR 2018, Vancouver, BC, Canada, April 30 - May 3, 2018, Conference Track Proceedings. OpenReview.net.
+Paul Michel, Omer Levy, and Graham Neubig. 2019. Are sixteen heads really better than one? In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 14014-14024.
+John X. Morris, Eli Lifland, Jin Yong Yoo, Jake Grigsby, Di Jin, and Yanjun Qi. 2020. Textattack: A framework for adversarial attacks, data augmentation, and adversarial training in nlp.
+
+Sai Prasanna, Anna Rogers, and Anna Rumshisky. 2020. When BERT plays the lottery, all tickets are winning. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 3208-3229. Association for Computational Linguistics.
+Shuhuai Ren, Yihe Deng, Kun He, and Wanxiang Che. 2019. Generating natural language adversarial examples through probability weighted word saliency. In Proceedings of the 57th Conference of the Association for Computational Linguistics, ACL 2019, Florence, Italy, July 28- August 2, 2019, Volume 1: Long Papers, pages 1085-1097. Association for Computational Linguistics.
+Alex Renda, Jonathan Frankle, and Michael Carbin. 2020. Comparing rewinding and fine-tuning in neural network pruning. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Ali Shafahi, Mahyar Najibi, Amin Ghiasi, Zheng Xu, John P. Dickerson, Christoph Studer, Larry S. Davis, Gavin Taylor, and Tom Goldstein. 2019. Adversarial training for free! In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 3353-3364.
+Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Y. Ng, and Christopher Potts. 2013. Recursive deep models for semantic compositionality over a sentiment treebank. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, EMNLP 2013, 18-21 October 2013, Grand Hyatt Seattle, Seattle, Washington, USA, A meeting of SIGDAT, a Special Interest Group of the ACL, pages 1631-1642. ACL.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pages 5998-6008.
+Elena Voita, David Talbot, Fedor Moiseev, Rico Sennrich, and Ivan Titov. 2019. Analyzing multi-head self-attention: Specialized heads do the heavy lifting, the rest can be pruned. In Proceedings of the 57th Conference of the Association for Computational Linguistics, ACL 2019, Florence, Italy, July 28-August 2, 2019, Volume 1: Long Papers, pages 5797-5808. Association for Computational Linguistics.
+Eric Wallace, Pedro Rodriguez, Shi Feng, Ikuya Yamada, and Jordan Boyd-Graber. 2019. Trick me if you can: Human-in-the-loop generation of adversarial examples for question answering. Transactions of the Association for Computational Linguistics, 7:387-401.
+
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R. Bowman. 2019. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In 7th International Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019. OpenReview.net.
+Boxin Wang, Shuohang Wang, Yu Cheng, Zhe Gan, Ruoxi Jia, Bo Li, and Jingjing Liu. 2021. Infobert: Improving robustness of language models from an information theoretic perspective. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierrick Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, and Jamie Brew. 2019. Huggingface's transformers: State-of-the-art natural language processing. CoRR, abs/1910.03771.
+Eric Wong, Leslie Rice, and J. Zico Kolter. 2020. Fast is better than free: Revisiting adversarial training. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Haoran You, Chaojian Li, Pengfei Xu, Yonggan Fu, Yue Wang, Xiaohan Chen, Richard G. Baraniuk, Zhangyang Wang, and Yingyan Lin. 2020. Drawing early-bird tickets: Toward more efficient training of deep networks. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Haonan Yu, Sergey Edunov, Yuandong Tian, and Ari S. Morcos. 2020. Playing the lottery with rewards and multiple languages: lottery tickets in RL and NLP. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Dinghuai Zhang, Tianyuan Zhang, Yiping Lu, Zhanxing Zhu, and Bin Dong. 2019. You only propagate once: Accelerating adversarial training via maximal principle. In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 227-238.
+Xiang Zhang, Junbo Jake Zhao, and Yann LeCun. 2015. Character-level convolutional networks for text classification. In Advances in Neural Information Processing Systems 28: Annual Conference on Neural Information Processing Systems 2015, December 7-12, 2015, Montreal, Quebec, Canada, pages 649-657.
+Xinze Zhang, Junzhe Zhang, Zhenhua Chen, and Kun He. 2021. *Crafting adversarial examples for neural machine translation*. In *Proceedings of the 59th Annual Meeting of the Association for
+
+Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 1967-1977, Online. Association for Computational Linguistics.
+Rui Zheng, Rong Bao, Qin Liu, Tao Gui, Qi Zhang, Xuanjing Huang, Rui Xie, and Wei Wu. 2022a. Plugat: A plug and play module to defend against textual adversarial attack. In Proceedings of the 29th International Conference on Computational Linguistics, COLING 2022, Gyeongju, Republic of Korea, October 12-17, 2022, pages 2873-2882. International Committee on Computational Linguistics.
+Rui Zheng, Bao Rong, Yuhao Zhou, Di Liang, Sirui Wang, Wei Wu, Tao Gui, Qi Zhang, and Xuanjing Huang. 2022b. Robust lottery tickets for pre-trained language models. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2211-2224, Dublin, Ireland. Association for Computational Linguistics.
+Chen Zhu, Yu Cheng, Zhe Gan, Siqi Sun, Tom Goldstein, and Jingjing Liu. 2020. Freelb: Enhanced adversarial training for natural language understanding. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+
+# A Appendix
+
+# A.1 Solving the Inner Max Problem of Adversarial Loss Objective
+
+We solve the inner max problem(generate the worst-case perturbation, i.e., $\mathcal{L}_{adv}(\theta ,c)$ ) with K-step projected gradient descent strategy (Madry et al., 2018), and the $(k + 1)$ -th perturbation is defined as
+
+$$
+\delta_ {k + 1} = \prod_ {\| \delta \| \leq \epsilon} \left(\delta_ {k} + \eta \frac {g \left(\delta_ {k}\right)}{\| g \left(\delta_ {k}\right) \|}\right), \tag {8}
+$$
+
+where $g(\delta_k) = \nabla_{\delta_k}\mathcal{L}(f(x + \delta_k;\theta ,c),y)$ is the gradient of the loss with respect to $\delta$ and $\prod_{\| \delta \| \leq \epsilon}(\cdot)$ performs a projection onto the $\epsilon$ -ball, which is a Frobenius normalization ball.
+
+# A.2 Implementation Details
+
+# A.2.1 Details for Adversarial Attack
+
+We adopt textattack (Morris et al., 2020) to implement adversarial attack methods. Aua% and #Query are evaluated on all 872 test examples for SST-2, 500 randomly selected test samples for IMDB, AG NEWS, QNLI and QQP. For BERT-Attack, we set the neighbor vocabulary size to 50, and set the sentence similarity to 0.2; for the other two attack methods, we use the default parameters of third-party libraries.
+
+# A.2.2 Hardware Details
+
+Experiments on SST-2, QNLI and QQP are run on seven 1080Ti GPUs and the sequence length is set to 128, while experiments on AG NEWS and IMDB are run on eight 2080Ti GPUs and the sequence length is set to 256.
+
+# A.2.3 Hyperparameters
+
+There are four hyperparameters introduced by the adversarial loss objective: the initial magnitude of perturbations $\epsilon_0$ , the number of gradient descent steps for adversary $s$ , the perturbation step size $\tau$ , and we do not constrain the bound of perturbations. We report the learning rate $\eta$ and the learning rate is the same at both the searching and fine-tuning stages. Moreover, we report the regularization penalties $\lambda_{\mathrm{H}}$ and $\lambda_{\mathrm{F}}$ . We list the hyperparameters used for each task in Table 6.
+
+| Datasets | ε0 | s | τ | η | λH | λF |
| IMDB | 0.05 | 5 | 0.01 | 2e-5 | 1e-5 | 2e-4 |
| SST2 | 0.05 | 5 | 0.02 | 2e-5 | 1e-4 | 3e-4 |
| AGNEWS | 0.05 | 5 | 0.01 | 2e-5 | 3e-4 | 5e-5 |
| QNLI | 0.05 | 5 | 0.01 | 2e-5 | 2e-4 | 3e-4 |
| QQP | 0.05 | 5 | 0.01 | 2e-5 | 1e-5 | 1e-5 |
+
+# A.3 Sparsity Pattern
+
+Figure 5 illustrates the sparsity pattern of robust tickets on three datasets. We can observe that for different datasets, the sparsity pattern varies greatly. So we speculate that it is dataset-dependent. Another interesting finding is that on a given dataset, the pruning for attention heads and intermediate neurons is concentrated in different layers, i.e., if attention heads are pruned centrally in some layers, the pruning on intermediate neurons is concentrated in other layers. For example, on SST-2, our method prunes heads mainly in bottom layers, while pruning intermediate neurons mainly in top layers.
+
+# A.4 More Results of Global Pruning vs. Layer-wise Pruning
+
+Table 7 and Table 8 show the results on SST-2 and AG NEWS, respectively. We can consistently find that global pruning performs better than layer-wise pruning in terms of robustness.
+
+Table 6: Hyperparameters in the proposed method.
+
+| Clean% | Heads-L | Heads-G |
| Aua% |
| Neurons-L | 90.1 | 91.5 |
| 11.7 | 12.0 |
| Neurons-G | 91.6 | 92.8 |
| 24.3 | 28.8 |
+
+Table 7: Global Pruning vs. Layer-wise Pruning on SST-2.
+
+| Clean% | Heads-L | Heads-G |
| Aua% |
| Neurons-L | 94.5 | 94.6 |
| 36.8 | 38.4 |
| Neurons-G | 94.4 | 94.5 |
| 39.6 | 41.0 |
+
+Table 8: Global Pruning vs. Layer-wise Pruning on AG NEWS.
+
+
+(a)IMDB
+
+
+(b) SST2
+Figure 5: Sparsity pattern of EarlyRobust tickets. For each figure, cells in the left give the average number of random seeds where a given head survives; cells in the right give the average percentage of surviving weights across 10 random seeds. We can observe that the sparsity pattern is dataset-dependent and interestingly, on a given dataset, the pruning for heads and intermediate neurons is concentrated in different layers.
+
+
+(c) AG NEWS
\ No newline at end of file
diff --git a/efficientadversarialtrainingwithrobustearlybirdtickets/images.zip b/efficientadversarialtrainingwithrobustearlybirdtickets/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..9619d7c8f3d17c474158ceeaa6ba3b0a9e68ad92
--- /dev/null
+++ b/efficientadversarialtrainingwithrobustearlybirdtickets/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9a2a0fcb66d5fd4f27781451ed9048a3fd285773aedc84446bc5493ee99eeca4
+size 616867
diff --git a/efficientadversarialtrainingwithrobustearlybirdtickets/layout.json b/efficientadversarialtrainingwithrobustearlybirdtickets/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..d0fd496c2b5d2f1b64b04b3bcac775d4bd848e87
--- /dev/null
+++ b/efficientadversarialtrainingwithrobustearlybirdtickets/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f721859a684a03f3a71766a0a0082a0b11a2a65fede1f36556b33a2e4942a43a
+size 467888
diff --git a/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_content_list.json b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..5937bfdede3b0b59026de5d30ccb4a017416af6f
--- /dev/null
+++ b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d3e0f0f6e4d05c00d9ec295f39dd153b8a03e13f77f2cf3182daa0d6374b9bf4
+size 83673
diff --git a/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_model.json b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..285008cb1af6e489635402734a4080e818c5def8
--- /dev/null
+++ b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d1b56be54aa0ca6f9ab664d61d154816c32ad26fdbb77f1afce0b190a4cbfddd
+size 99120
diff --git a/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_origin.pdf b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..a97378c723fc1b04b575b6798741ef2816cb4df1
--- /dev/null
+++ b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/76856664-c0df-42ea-93be-dc5809b861a2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a2f55f508017a40155fcbe75c6cbed35f338db8cdef221f632362602f6fd5271
+size 405680
diff --git a/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/full.md b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..7f8e9cc70069b4176fc41e9b2abc5f4f0dbbff33
--- /dev/null
+++ b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/full.md
@@ -0,0 +1,365 @@
+# Efficient Document Retrieval by End-to-End Refining and Quantizing BERT Embedding with Contrastive Product Quantization
+
+Zexuan Qiu $^{1}$ , Qinliang Su $^{1,2*}$ , Jianxing Yu $^{3}$ , and Shijing Si $^{4}$
+
+$^{1}$ School of Computer Science and Engineering, Sun Yat-sen University, Guangzhou, China
+
+2 Guangdong Key Laboratory of Big Data Analysis and Processing, Guangzhou, China
+
+$^{3}$ School of Artificial Intelligence, Sun Yat-sen University, Guangzhou, China
+
+$^{4}$ School of Economics and Finance, Shanghai International Studies University, China
+
+{qiuzx3@mail2, suqliang@mail, yujx26@mail}.sysu.edu.cn
+
+# Abstract
+
+Efficient document retrieval heavily relies on the technique of semantic hashing, which learns a binary code for every document and employs Hamming distance to evaluate document distances. However, existing semantic hashing methods are mostly established on outdated TFIDF features, which obviously do not contain lots of important semantic information about documents. Furthermore, the Hamming distance can only be equal to one of several integer values, significantly limiting its representational ability for document distances. To address these issues, in this paper, we propose to leverage BERT embeddings to perform efficient retrieval based on the product quantization technique, which will assign for every document a real-valued codeword from the codebook, instead of a binary code as in semantic hashing. Specifically, we first transform the original BERT embeddings via a learnable mapping and feed the transformed embedding into a probabilistic product quantization module to output the assigned codeword. The refining and quantizing modules can be optimized in an end-to-end manner by minimizing the probabilistic contrastive loss. A mutual information maximization based method is further proposed to improve the representativeness of codewords, so that documents can be quantized more accurately. Extensive experiments conducted on three benchmarks demonstrate that our proposed method significantly outperforms current state-of-the-art baselines1.
+
+# 1 Introduction
+
+In the era of big data, Approximate Nearest Neighbor (ANN) search has attracted tremendous attention thanks to its high search efficiency and extraordinary performance in modern information retrieval
+
+systems. By quantizing each document as a compact binary code, semantic hashing (Salakhutdinov and Hinton, 2009) has become the main solution to ANN search due to the extremely low cost of calculating Hamming distance between binary codes. One of the main approaches for unsupervised semantic hashing methods is established on generative models (Chaidaroon and Fang, 2017; Shen et al., 2018; Dong et al., 2019; Zheng et al., 2020), which encourage the binary codes to be able to reconstruct the input documents. Alternatively, some other methods are driven by graphs (Weiss et al., 2008; Chaidaroon et al., 2020; Hansen et al., 2020; Ou et al., 2021a), hoping the binary codes can recover the neighborhood relationship. Though these methods have obtained great retrieval performance, there still exist two main problems.
+
+Firstly, these methods are mostly established on top of the outdated TFIDF features, which do not contain various kinds of important information of documents, like word order, contextual information, etc. In recent years, pre-trained language models like BERT have achieved tremendous success in various downstream tasks. Thus, a natural question to ask is whether we can establish efficient retrieval methods on BERT embeddings. However, it has been widely reported that BERT embeddings are not suitable for semantic similarity-related tasks (Reimers and Gurevych, 2019), which perform even worse than the traditional Glove embeddings (Pennington et al., 2014). (Ethayarajh, 2019; Li et al., 2020) attribute this to the "anisotropy" phenomenon that BERT embeddings only occupy a narrow cone in the vector space, causing the semantic information hidden in BERT embeddings not easy to be leveraged directly. Thus, it is important to investigate how to effectively leverage the BERT embeddings for efficient document retrieval.
+
+Secondly, to guarantee the efficiency of retrieval, most existing methods quantize every document to a binary code via semantic hashing. There is
+
+no doubt that the Hamming distance can improve the retrieval efficiency significantly, but it also restricts the representation of document similarities seriously since it can only be an integer from $-B$ to $B$ for $B$ -bit codes. Recently, an alternative approach named product quantization (Jégou et al., 2011; Jang and Cho, 2021; Wang et al., 2021) has been proposed in the computer vision community to alleviate this problem. Basically, it seeks to quantize every item to one of the codewords in a codebook, which is represented by a Cartesian product of multiple small codebooks. It has been shown that product quantization is able to deliver superior performance than semantic hashing while keeping the cost of computation and storage relatively unchanged. However, this technique has rarely been explored in unsupervised document retrieval.
+
+Motivated by the two problems above, in this paper, we propose an end-to-end contrastive product quantization model to jointly refine the original BERT embeddings and quantize the refined embeddings into codewords. Specifically, we first transform the original BERT embeddings via a learnable mapping and feed the transformed embedding into a probabilistic product quantization module to output a quantized representation (codeword). To preserve as much semantic information as possible in the quantized representations, inspired by recent successes of contrastive learning, a probabilistic contrastive loss is designed and trained in an end-to-end manner, simultaneously achieving the optimization of refining and quantizing modules. Later, to further improve the retrieval performance, inspired by the recent development of clustering, a mutual information maximization based method is further developed to increase the representativeness of learned codewords. By doing so, the cluster structure hidden in the dataset of documents could be kept soundly, making the documents be quantized more accurately. Extensive experiments are conducted on three real-world datasets, and the experimental results demonstrate that our proposed method significantly outperforms current state-of-the-art baselines. Empirical analyses also demonstrate the effectiveness of every proposed component in our proposed model.
+
+# 2 Preliminaries of Product Quantization for Information Retrieval
+
+In fields of efficient information retrieval, a prevalent approach is semantic hashing, which maps
+
+every item $x$ to a binary code $b$ and then uses Hamming distances to reflect the semantic similarity of items. Thanks to the low cost of computing Hamming distance, the retrieval can be performed very efficiently. However, the Hamming distance can only be an integer from $-B$ to $B$ for $B$ -bit codes, which is too restrictive to reflect the rich similarity information.
+
+An alternative approach is vector quantization (VQ) (Gray and Neuhoff, 1998), which assigns every item with a codeword from a codebook $C$ . The codeword in VQ could be any vector in $\mathbb{R}^D$ , rather than limited to the binary form as in semantic hashing. By storing pre-computed distances between any two codewords in a table, the distance between items can be obtained efficiently by looking up the table. However, to ensure competitive performance, the number of codewords in a codebook needs to be very large. For example, there are $2^{64}$ different codes for a 64-bit binary code, and thus the number of codewords in VQ should also be of this scale, which however is too large to be handled.
+
+To tackle this issue, product quantization (Jégou et al., 2011) proposes to represent the codebook $C$ as a Cartesian product of $M$ small codebooks
+
+$$
+C = C ^ {1} \times C ^ {2} \times \dots \times C ^ {M}, \tag {1}
+$$
+
+where the $m$ -th codebook $C^m$ consists of $K$ codewords $\{c_k^m\}_{k=1}^K$ with $c_k^m \in \mathbb{R}^{D/M}$ . For an item, the product quantization will choose a codeword from every codebook $C^m$ , and the final codeword assigned to this item is
+
+$$
+c = c ^ {1} \circ c ^ {2} \dots \circ c ^ {M}, \tag {2}
+$$
+
+where $c^m$ denotes the codeword chosen from $C^m$ , and $\circ$ denotes concatenation. For each codeword $c$ , we only need to record its indices in the $M$ codebooks, which only requires $M\log_2K$ bits. Thanks to the Cartesian product decomposition, now we only need to store $MK$ codewords of dimension $\mathbb{R}^{D / M}$ and $M$ lookup tables of size $K\times K$ . As an example, to enable a total of $2^{64}$ codewords, we can set $M = 32$ and $K = 4$ , which obviously will reduce the size of footprint and lookup tables significantly. During retrieval, we only need to look up the $M$ tables and sum them up, which is only slightly more costly than the computation of Hamming distance.
+
+# 3 The End-to-End Joint Refining and Quantizing Framework
+
+To retrieve semantic-similar documents, a core problem is how to produce for every document a quantized representation that preserves the semantic-similarity information of original documents. In this section, a simple two-stage method is first proposed, and then we develop an end-to-end method that is able to directly output representations with desired properties.
+
+# 3.1 A Simple Two-Stage Approach
+
+To obtain semantics-preserving quantized representations, a naive approach is to first promote the semantic information in original BERT embeddings and then quantize them. Many methods have been proposed on how to refine BERT embeddings to promote their semantic information. These methods can be essentially described as transforming the original embedding $z(x)$ into another one $\tilde{z}(x)$ via a mapping $g(\cdot)$ as
+
+$$
+\tilde {z} (x) = g (z (x)), \tag {3}
+$$
+
+where $g(\cdot)$ could be a flow-based mapping (Li et al., 2020), or a neural network trained to maximize the agreement between representations of a document's two views (Gao et al., 2021), etc. It has been reported that the refined embeddings $\tilde{z}(x)$ are semantically much richer than original one $z(x)$ . Then, we can follow standard product quantization procedures to quantize the refined embeddings $\tilde{z}(x)$ into discrete representations.
+
+# 3.2 End-to-End Refining and Quantizing via Contrastive Product Quantization
+
+Obviously, the separation between the refining and quantizing steps in the two-stage method could result in a significant loss of semantic information in the final quantized representation. To address this issue, an end-to-end refining and quantizing method is proposed. We first slice the original BERT embedding $z(x)$ into $M$ segments $z^{m}(x) \in \mathbb{R}^{D / M}$ for $m = 1,2,\dots ,M$ . Then, we refine $z^{m}(x)$ by transforming it into a semantic-richer form $\tilde{z}^{m}(x)$ via a mapping $g_{\theta}^{m}(\cdot)$ , that is,
+
+$$
+\tilde {z} ^ {m} (x) = g _ {\theta} ^ {m} (z ^ {m} (x)), \qquad (4)
+$$
+
+where the subscript $\theta$ denotes the learnable parameter. Different from the mapping $g(\cdot)$ which is determined at the refining stage and is irrelevant to
+
+the quantization in the two-stage method, the mapping $g_{\theta}^{m}(\cdot)$ here will be learned later by taking the influences of quantization error into account. Now, instead of quantizing the refined embedding $\tilde{z}^m (x)$ to a fixed codeword, we propose to quantize it to one of the codewords $\{c_{k^m}^m\}_{k^m = 1}^K$ by stochastically selecting $k^{m}$ according to the distribution
+
+$$
+p \left(k ^ {m} | x\right) = \frac {\exp \left(- \left\| \tilde {z} ^ {m} (x) - c _ {k ^ {m}} ^ {m} \right\| ^ {2}\right)}{\sum_ {i = 1} ^ {K} \exp \left(- \left\| \tilde {z} ^ {m} (x) - c _ {i} ^ {m} \right\| ^ {2}\right)} \tag {5}
+$$
+
+with $k^m = 1,2,\dots ,K$ . Obviously, the probability that $\tilde{z}^{m}(x)$ is quantized to a codeword is inversely proportional to their distance. Thus, by denoting $k^m$ as a random sample drawn from $p(k^m |x)$ , i.e., $k^m\sim p(k^m|x)$ , we can represent the $m$ -th quantized representation of document $x$ as
+
+$$
+h ^ {m} (x) = C ^ {m} \cdot \operatorname {o n e} _ {-} h o t \left(k ^ {m}\right), \tag {6}
+$$
+
+and the whole quantized representation of $x$ as
+
+$$
+h (x) = h ^ {1} (x) \circ h ^ {2} (x) \dots \circ h ^ {M} (x). \tag {7}
+$$
+
+Note that the quantized representation $h(x)$ depends on random variables $k^m \sim p(k^m | x)$ for $m = 1, 2, \dots, M$ , thus $h(x)$ itself is also random.
+
+Now, we seek to preserve as much semantic information as possible in the quantized representation $h(x)$ . Inspired by the recent successes of contrastive learning in semantic-rich representation learning (Gao et al., 2021), we propose to minimize the contrastive loss. Specifically, for every document $x$ , we first obtain two BERT embeddings by passing it through BERT two times with two independent dropout masks and then use the embeddings to generate two quantized representations $h^{(1)}(x)$ and $h^{(2)}(x)$ according to (6) and (7). Then, we define the contrastive loss as
+
+$$
+\mathcal {L} _ {c l} = - \frac {1}{| \mathcal {B} |} \sum_ {x \in \mathcal {B}} \left(\ell^ {(1)} (x) + \ell^ {(2)} (x)\right), \tag {8}
+$$
+
+where $\mathcal{B}$ denotes a mini-batch of training documents; and $\ell^{(i)}(x)$ for $i = 1,2$ is defined as
+
+$$
+\ell^ {(i)} (x) \triangleq \log \frac {\mathcal {S} \left(h _ {x} ^ {(1)} , h _ {x} ^ {(2)}\right)}{\mathcal {S} \left(h _ {x} ^ {(1)} , h _ {x} ^ {(2)}\right) + \sum_ {\substack {t \in \mathcal {B} \backslash x \\ n = 1,2}} \mathcal {S} \left(h _ {x} ^ {(i)}, h _ {t} ^ {(n)}\right)}, \tag{9}
+$$
+
+with $h_x^{(1)}$ denoting the abbreviation of $h^{(1)}(x)$ for conciseness; and $S(h_1, h_2)$ is defined as
+
+$$
+\mathcal {S} \left(h _ {1}, h _ {2}\right) \triangleq \exp \left(\operatorname {s i m} \left(h _ {1}, h _ {2}\right) / \tau_ {c l}\right), \tag {10}
+$$
+
+with $\text{sim}(h_1, h_2) \triangleq \frac{h_1^T h_2}{\|h_1\| \|h_2\|}$ being the cosine similarity function, and $\tau_{cl}$ being a temperature hyperparameter.
+
+Under the proposed quantization method above, the quantized representation $h(x)$ depends on the random variable $k^m \sim p(k^m | x)$ , making it not deterministic w.r.t. a given document $x$ . Thus, we do not directly optimize the random contrastive loss $\mathcal{L}_{cl}$ , but minimize its expectation
+
+$$
+\overline {{\mathcal {L}}} _ {c l} = - \frac {1}{| \mathcal {B} |} \sum_ {x \in \mathcal {B}} \left(\bar {\ell} ^ {(1)} (x) + \bar {\ell} ^ {(2)} (x)\right), \tag {11}
+$$
+
+where $\overline{\ell}^{(i)}(x)$ represents the expectation of $\ell^{(i)}(x)$ w.r.t. $k^m\sim p(k^m |x)$ for $m = 1,2,\dots ,M$ ,that is,
+
+$$
+\overline {{\ell}} ^ {(i)} (x) = \mathbb {E} _ {k ^ {1}, k ^ {2}, \dots , k ^ {M}} \left[ \ell^ {(i)} (x) \right]. \tag {12}
+$$
+
+Obviously, it is impossible to derive an analytical expression for $\overline{\ell}^{(i)}(x)$ , making the optimization of $\overline{\mathcal{L}}_{cl}$ not feasible. To address this issue, it has been proposed in (Jang et al., 2017) that the random sample $k^m$ drawn from distribution $p(k|x) = \frac{\exp\left(-\left\|\tilde{z}^m(x) - c_k^m\right\|^2\right)}{\sum_{i=1}^{K}\exp\left(-\left\|\tilde{z}^m(x) - c_i^m\right\|^2\right)}$ can be re-parameterized as
+
+$$
+k ^ {m} = \arg \max _ {i} \left[ - \| \tilde {z} ^ {m} (x) - c _ {i} ^ {m} \| ^ {2} + \xi_ {i} \right], \tag {13}
+$$
+
+where $\xi_{i}$ denote i.i.d. random samples drawn from the Gumbel distribution $Gumbel(0,1)$ . Then, using the softmax function to approximate the arg max $(\cdot)$ , the $m$ -th quantized representation $h^{m}(x)$ can be approximately represented as
+
+$$
+\widetilde {h} ^ {m} (x) = C ^ {m} \cdot v, \tag {14}
+$$
+
+where $v\in \mathbb{R}^K$ is a probability vector whose $k$ -th element is
+
+$$
+v _ {k} = \frac {\exp \left(- \frac {\left\| \tilde {z} ^ {m} (x) - c _ {k} ^ {m} \right\| ^ {2} + \xi_ {k}}{\tau}\right)}{\sum_ {i = 1} ^ {K} \exp \left(- \frac {\left\| \tilde {z} ^ {m} (x) - c _ {i} ^ {m} \right\| ^ {2} + \xi_ {i}}{\tau}\right)}, \tag {15}
+$$
+
+with $\tau$ being a hyper-parameter. It can be easily seen that $\widetilde{h}^m (x)$ will converge to $h^{m}(x)$ as $\tau \to 0$ thus $\tilde{h}^m (x)$ can be used as a good approximation to $h^m (x)$ . With the approximation, $\overline{\ell}^{(i)}(x)$ in (12) can be approximately written as
+
+$$
+\overline {{\ell}} ^ {(i)} (x) \approx \log \frac {\mathcal {S} \left(\widetilde {h} _ {x} ^ {(1)} , \widetilde {h} _ {x} ^ {(2)}\right)}{\mathcal {S} \left(\widetilde {h} _ {x} ^ {(1)} , \widetilde {h} _ {x} ^ {(2)}\right) + \sum_ {\substack {t \in \mathcal {B} \backslash x \\ n = 1, 2}} \mathcal {S} \left(\widetilde {h} _ {x} ^ {(i)} , \widetilde {h} _ {t} ^ {(n)}\right)}, \tag{16}
+$$
+
+where $\widetilde{h}_x^{(1)}$ is the abbreviation of $h^{(1)}(x)$ . Substituting (16) into (11) gives an approximate analytical expression of $\overline{L}_{cl}$ that is differentiable w.r.t. the parameter $\theta$ for refining and codebooks $\{C^m\}_{m=1}^M$ for quantization. Therefore, we can optimize the $\theta$ and codebooks $\{C^m\}_{m=1}^M$ in an end-to-end manner, explicitly encouraging the quantized representations $h(x)$ to preserve more semantic information.
+
+It is worth noting that the injected Gumbel noise $\xi_{i}$ in (15) is important to yield a sound approximation $\overline{\ell}^{(i)}(x)$ in (16). Theoretically, the approximated $\overline{\ell}^{(i)}(x)$ is guaranteed to converge to the exact value when $\tau \rightarrow 0$ and a large number of independent Gumbel nosies are used to approximate the expectation. However, if we abandon this noise in the computation of $v_{k}$ , we will lose the appealing property above. Our experimental results also demonstrate the advantages of injecting Gumbel noises in the approximation. Another point worth pointing out is that if the refined embedding $\tilde{z}^m (x)$ is quantized to the closest codeword deterministically, that is, letting $k^{m} = \arg \max_{i}\left[-\| \tilde{z}^{m}(x) - c_{i}^{m}\|^{2}\right]$ , then it becomes equivalent to our probabilistic quantization approach without using Gumbel noise, further demonstrating the advantages of our method.
+
+# 3.3 Improving the Representativeness of Codewords via MI Maximization
+
+It can be seen that the codewords in $C^m$ work similarly to the cluster centers in clustering. The clustering centers are known to be prone to get stuck at suboptimal points, which applies to the codewords analogously. If the codewords are not representative enough, they could result in a significant loss of semantic information in the quantized representations (Ge et al., 2013; Cao et al., 2016).
+
+It has been recently observed that maximizing mutual information (MI) between the data and the cluster assigned to it can often lead to much better clustering performance (Hu et al., 2017; Ji et al., 2019; Do et al., 2021). Inspired by this, to increase the representativeness of codewords, we also propose to maximize the MI between the original document $x$ and the codeword (index) assigned to it. To this end, given the conditional distribution $p(k^m|x)$ in (5), we first estimate the marginal distribution of codeword index $k^m$ as
+
+$$
+p \left(k ^ {m}\right) \approx \frac {1}{| \mathcal {D} |} \sum_ {x \in \mathcal {D}} p \left(k ^ {m} \mid x\right), \tag {17}
+$$
+
+where $\mathcal{D}$ denotes the training dataset. Then, by definition, the entropy of the codeword index $k^{m}$ can be estimated as
+
+$$
+H \left(K ^ {m}\right) = - \sum_ {k ^ {m} = 1} ^ {K} p \left(k ^ {m}\right) \log \left(p \left(k ^ {m}\right)\right). \tag {18}
+$$
+
+Similarly, the conditional entropy of codeword $k^m$ given data $x$ can be estimated as
+
+$$
+H \left(K ^ {m} | X\right) = - \frac {1}{| \mathcal {D} |} p \left(k ^ {m} | x\right) \log \left(p \left(k ^ {m} | x\right)\right). \tag {19}
+$$
+
+Now, the mutual information between codeword index $k^m$ and data $x$ can be easily obtained by definition as $I(X, K^m) = H(K^m) - H(K^m | X)$ . In practice, we find that it is better not to directly maximize the MI $I(X, K^m)$ , but to maximize its variant form
+
+$$
+I (X, K ^ {m}) = H \left(K ^ {m}\right) - \alpha H \left(K ^ {m} | X\right), \quad (2 0)
+$$
+
+where $\alpha$ is a non-negative hyper-parameter controlling the trade-off between two entropy terms. Intuitively, maximizing the MI can be understood as encouraging only one codeword is assigned a high probability for a document $x$ , while all codewords are used evenly overall. Given the mutual information, the final training objective becomes
+
+$$
+\mathcal {L} = \overline {{\mathcal {L}}} _ {c l} - \lambda \sum_ {m = 1} ^ {M} I (X, K ^ {m}), \tag {21}
+$$
+
+where $\lambda$ is a hyper-parameter controlling the relative importance of the MI term. Since this method employs MI to improve the quality of codewords, we name the model as MICPQ, i.e., Mutual-Information-Improved Contrastive Product Quantization.
+
+# 4 Related Work
+
+As the main solution to efficient document retrieval, unsupervised semantic hashing has been studied for years. Many existing unsupervised hashing methods are established on the generative models encouraging the binary codes to reconstruct the original document. For example, VDSH (Chaidaroon and Fang, 2017) proposes a two-stage scheme, in which it first learns the continuous representations under the VAE (Kingma and Welling, 2014) framework, and then cast them into the binary codes. To tackle the two-stage training issue, NASH (Shen et al., 2018) presents an end-to-end generative hashing framework where the binary codes are treated
+
+as Bernoulli latent variables, and introduces the Straight-Through (Bengio et al., 2013) estimator to estimate the gradient w.r.t. the discrete variables. Dong et al. (2019) employs the mixture priors to empower the binary code with stronger expressiveness, therefore resulting in better performance. Further, CorrSH (Zheng et al., 2020) employs the distribution of the Boltzmann machine to introduce correlations among the bits of binary codes. Ye et al. (2020) proposes the auxiliary implicit topic vectors to address the issue of information loss in the few-bit scenario. Also, a handful of recent works focus on how to inject the neighborhood information of the graph under the VAE framework. Chaidaroon et al. (2018); Hansen et al. (2020) seeks to learn the optimal binary codes that can reconstruct neighbors of original documents. A ranking loss is introduced in (Hansen et al., 2019) to accurately characterize the correlation between documents. Ou et al. (2021a) first proposes to integrate the semantics and neighborhood information with a graph-driven generative model.
+
+Beyond generative hashing methods, studies on hashing via the mutual information (MI) principle emerges recently. AMMI (Stratos and Wiseman, 2020) learns a high-quality binary code by maximizing the MI between documents and binary codes. DHIM (Ou et al., 2021b) first compresses the BERT embeddings into binary codes by maximizing the MI between global codes and local codes from documents.
+
+Another efficient retrieval mechanism is product quantization. The Product quantization (PQ) (Jégou et al., 2011) and its improved variants such as Optimized PQ (Ge et al., 2013) and Locally Optimized PQ (Kalantidis and Avrithis, 2014) are proposed to retrain richer distance information than hashing methods while conducting the retrieval efficiently. These shallow unsupervised PQ methods are often based on the well-trained representation and learn the quantization module with heuristic algorithms (Xiao et al., 2021), which often can not achieve satisfactory performance. In this paper, we propose an unsupervised MI-improved end-to-end unsupervised product quantization model MICPQ. We notice that the proposed MICPQ is somewhat similar to recent works w.r.t PQ (Jang and Cho, 2021; Wang et al., 2021) in the computer vision community. However, (Jang and Cho, 2021) focuses on analyzing the performance difference between different forms of contrastive losses, while
+
+we focus on how to design an end-to-end model to jointly refine and quantize the BERT embedding via contrastive product quantization from a probabilistic perspective. (Wang et al., 2021) concentrates on how to improve the codeword diversity to prevent model degeneration by regularizer design; whereas there is no "model degeneration" phenomenon observed in our model, and we use the mutual information maximization based method to increase the representativeness of codewords to further improve the retrieval performance.
+
+# 5 Experiments
+
+# 5.1 Datasets, Evaluation and Baselines
+
+Datasets The proposed MICPQ model is evaluated on three benchmark datasets, including NYT (Tao et al., 2018), AGNews (Zhang et al., 2015) and DBpedia (Lehmann et al., 2015). Details of the three datasets can be found in Appendix A.
+
+Evaluation Metrics For every query document from the testing dataset, we retrieve its top-100 most similar documents from the training set with the Asymmetric distance computation (Jégou et al., 2011) which is formulated in Appendix B. Then the retrieval precision is calculated as the ratio of the relevant documents. Note that a retrieved document is considered relevant to the query if they both share the same label. Finally, the retrieval precision averaged over all test documents is reported.
+
+Baselines We consider the following unsupervised deep semantic hashing methods for comparison: VDSH (Chaidaroon and Fang, 2017), NASH (Shen et al., 2018), BMSH (Dong et al., 2019), CorrSH (Zheng et al., 2020), WISH (Ye et al., 2020), AMMI (Stratos and Wiseman, 2020), DHIM (Ou et al., 2021b). For the reported performances of baselines, they are quoted from DHIM (Ou et al., 2021b). Apart from existing baselines, we also implement the following two baselines for a more thorough comparison.
+
+AEPQ. We are interested in optimizing our product quantizer with the reconstructing objective. Specifically, the quantized semantics-preserving representation vector $h(x)$ is expected to reconstruct the original input features (i.e., BERT embeddings) with a newly added decoder, which is similar with previous generative hashing methods. Same as MICPQ, the performance of AEPQ is evaluated with the Asymmetric distance computation. We
+
+name this baseline as AEPQ, i.e., Auto-Encoder-based Product Quantization.
+
+CSH. Same as the encoder setting in NASH (Shen et al., 2018), we assume that the binary codes are generated by sampling from the multivariate Bernoulli distribution and propose to minimize the expected contrastive loss w.r.t. the discrete binary codes directly. The straight-through (ST) gradient estimator (Bengio et al., 2013) is utilized for training in an end-to-end manner. The data augmentation strategy is the same as that of our MICPQ. We name the proposed baseline as CSH, i.e., Contrastive Semantic Hashing.
+
+Training Details In our MICPQ, to output the refined vectors that will be fed into the product quantizer with the desired dimension, the encoder network is constituted by a pre-trained BERT Module followed by an one-layer ReLU feedforward neural network on top of the [CLS] representation whose dimension is 768. For performances under the average pooling setting of BERT, please refer to Appendix C. During the training, following the setting in DHIM (Ou et al., 2021b), we fix the parameters of BERT, while only training the newly added parameters. We implement the proposed model with PyTorch and employ the Adam optimizer(Kingma and Ba, 2015) for optimization.
+
+In terms of hyper-parameters relevant to the product quantization, the dimension of codeword $\frac{D}{M}$ in the small codebook $C^m$ is fixed to 24 and the number of codewords $K$ in each codebook $C^m$ is fixed to 16. By setting the number of small codebooks $M$ as $\{4,8,16,32\}$ , we can see that the final codeword in the codebook $C$ can be represented by $\{16,32,64,128\}$ bits according to $B = M\log_2K$ . Thus, when compared with semantic hashing, they are compared under the same number of bits.
+
+For other hyper-parameters, the learning rate is set as 0.001; the dropout rate $p_{drop}$ to generate positive pairs for contrastive learning is set as 0.3; the Gumbel-Softmax temperature $\tau$ is set as 10 for 16-bit binary codes and 5 for longer codes; the temperature $\tau_{cl}$ in contrastive learning is set as 0.3; the trade-off coefficient $\alpha$ in (20) is set as 0.1; the coefficient $\lambda$ in (21) is chosen from $\{0.1, 0.2, 0.3\}$ according to the performance on the validation set.
+
+# 5.2 Results and Analyses
+
+# 5.2.1 Overall Performance
+
+Table 1 presents performances of our proposed model and existing baselines on three public
+
+Table 1: The precision(%) comparison with different state-of-the-art unsupervised efficient retrieval methods. Among them, bold numbers represent best performance, and underlined numbers represent second best performance.
+
+| Method | NYT | AGNews | DBpedia |
| 16bits | 32bits | 64bits | 128bits | 16bits | 32bits | 64bits | 128bits | 16bits | 32bits | 64bits | 128bits |
| Using TFIDF features |
| VDSH | 68.77 | 68.77 | 75.01 | 78.49 | 67.32 | 67.42 | 72.70 | 73.86 | 67.79 | 72.64 | 78.84 | 84.91 |
| NASH | 74.87 | 75.52 | 75.08 | 73.01 | 65.74 | 69.34 | 72.72 | 74.33 | 78.02 | 79.84 | 79.79 | 76.76 |
| WISH | 70.15 | 70.03 | 64.48 | 68.94 | 74.53 | 74.79 | 75.05 | 72.70 | 82.82 | 82.76 | 82.10 | 78.22 |
| BMSH | 74.02 | 76.38 | 76.88 | 77.63 | 74.09 | 76.03 | 76.09 | 73.56 | 83.17 | 86.24 | 87.05 | 83.86 |
| CorrSH | 75.43 | 77.61 | 77.24 | 78.39 | 76.20 | 76.45 | 76.61 | 77.67 | 82.01 | 81.78 | 80.94 | 85.77 |
| AMMI | 71.06 | 76.48 | 77.37 | 78.03 | 76.47 | 76.61 | 77.32 | 78.23 | 84.51 | 89.53 | 90.78 | 91.03 |
| Using BERT [CLS] embeddings |
| VDSH | 53.38 | 58.18 | 62.44 | 64.64 | 62.97 | 66.35 | 69.57 | 70.27 | 69.59 | 75.21 | 79.54 | 80.62 |
| NASH | 55.87 | 58.25 | 60.98 | 64.27 | 66.32 | 68.44 | 70.40 | 72.07 | 65.87 | 74.54 | 77.96 | 81.43 |
| WISH | 58.83 | 64.75 | 65.47 | 70.34 | 65.35 | 66.19 | 69.39 | 72.03 | 65.65 | 72.91 | 76.66 | 82.29 |
| BMSH | 59.35 | 63.26 | 65.87 | 69.71 | 66.77 | 69.61 | 71.99 | 73.16 | 66.42 | 79.13 | 82.01 | 84.57 |
| CorrSH | 62.03 | 65.48 | 68.38 | 72.28 | 67.06 | 68.51 | 70.86 | 73.17 | 65.28 | 74.63 | 78.65 | 83.61 |
| AMMI | 60.47 | 65.10 | 69.67 | 74.47 | 65.50 | 68.26 | 71.85 | 74.36 | 80.25 | 82.67 | 89.26 | 86.74 |
| DHIM | 79.69 | 80.55 | 79.77 | 79.09 | 78.23 | 79.17 | 78.88 | 79.86 | 94.26 | 94.80 | 93.02 | 88.21 |
| AEPQ | 67.98 | 68.35 | 70.38 | 71.48 | 68.81 | 70.49 | 72.82 | 73.84 | 80.24 | 84.54 | 86.78 | 89.70 |
| CSH | 79.63 | 81.05 | 81.08 | 81.28 | 79.14 | 80.25 | 81.14 | 81.78 | 95.19 | 95.84 | 95.79 | 96.01 |
| MICPQ | 83.15 | 84.02 | 84.24 | 85.08 | 80.36 | 81.84 | 82.93 | 83.29 | 96.51 | 97.00 | 97.03 | 97.21 |
+
+datasets with code lengths varying from 16 to 128. It can be seen that the proposed simple baseline CSH achieves promising performances across all three datasets and nearly all code length settings when compared to previous state-of-the-art methods, demonstrating the superiority of using contrastive learning to promote semantic information. Further, our proposed MICPQ outperforms the previous methods by a more substantial margin. Specifically, improvements of $4.32\%$ , $3.07\%$ and $4.37\%$ averaged over all code lengths are observed on NYT, AGNews and DBpedia datasets, respectively, when compared with the current state-of-the-art DHIM. Moreover, the performance of AEPQ lags behind our proposed MICPQ remarkably, which illustrates the limitation of the reconstructing objective. It is also observed that the retrieval performance of our proposed MICPQ consistently improves as the code length increases. Although this is consistent with our intuition that a longer code can preserve more semantic information, it does not always hold in some previous models (e.g., NASH, BMSH, DHIM).
+
+# 5.2.2 Abalation Study
+
+To understand the influence of different components in the MICPQ, we further evaluate the retrieval performance of two variants of MICPQ. (i) $\mathrm{MICPQ}_{\mathrm{cl}}$ : it removes the mutual-information term $I(X,K^{m})$ in each codebook and only optimizes the quantized contrastive loss to learn the
+
+Table 2: The precision (%) comparison with variants of MICPQ.
+
+| Ablation Study | 16bits | 32bits | 64bits | 128bits |
| NYT | MICPQcl | 81.77 | 82.28 | 82.96 | 83.63 |
| MICPQsoftmax | 82.28 | 83.46 | 83.64 | 84.17 |
| MICPQ | 83.15 | 84.02 | 84.24 | 85.08 |
| AGNews | MICPQcl | 79.68 | 80.97 | 81.79 | 82.23 |
| MICPQsoftmax | 79.60 | 81.61 | 82.58 | 82.69 |
| MICPQ | 80.36 | 81.84 | 82.93 | 83.29 |
+
+semantics-preserving quantized representation; (ii) $\mathrm{MICPQ}_{\mathrm{softmax}}$ : it does not inject the Gumbel noise, but only utilizes the sole softmax operation to produce the deterministic codeword index. As seen from Table 2, when compared to $\mathrm{MICPQ}_{\mathrm{cl}}$ , our MICPQ improves the retrieval performance averaged over all code lengths by $1.51\%$ and $0.94\%$ on NYT and AGNews respectively, demonstrating the effectiveness of our mutual-information term inside each codebook. Also, by comparing MICPQ to $\mathrm{MICPQ}_{\mathrm{softmax}}$ , consistent improvements can be observed on both datasets, which demonstrates the superiority of the proposed probabilistic product quantization.
+
+# 5.3 Link to Semantic Hashing: A Special Form of MICPQ
+
+Through an extreme setting, the MICPQ model can be reconsidered in the semantic hashing framework and be evaluated using the Hamming distance rather than the Asymmetric distance. Specifically,
+
+
+Figure 1: The precision $(\%)$ on NYT w.r.t. MICPQ under the extreme setting.
+
+Table 3: Average and maximal accuracy(%) over $M$ codebooks on NYT.
+
+ | Avg Acc | Max Acc |
| NYT | AGNews | DBpedia | NYT | AGNews | DBpedia |
| KMeans | 41.73 | 61.10 | 67.99 | 43.74 | 67.45 | 80.49 |
| MICPQ | 48.74 | 58.06 | 64.12 | 57.51 | 69.65 | 80.88 |
+
+we push the number of codebooks $M$ equal to its maximal limit (i.e., the code length $B$ ), and the number of codewords $K$ inside each codebook is forced as 2 to satisfy the equation $B = M\log_2K$ . This way, the state of each bit in the $B$ -bit binary code will be decided by a sub-space with 2 codewords. Under this extreme setting, we can either evaluate MICPQ with the Hamming distance evaluation or the Asymmetric distance. We name both models as MICPQ-EH (i.e., Extreme-Hamming) and MICPQ-EA (i.e., Extreme-Asymmetric). As shown in Figure 1, the MICPQ-EA consistently outperforms the MICPQ-EH thanks to the superiority of Asymmetric Distance computation. Also, MICPQ-EH can be seen as the semantic hashing model since it's evaluated with Hamming distance, and the better retrieval performance of MICPQ-EH when compared to CSH informs us that we can take the special form of MICPQ as one of the excellent semantic hashing methods. To sum up, the proposed MICPQ is more flexible and powerful than the existing hashing baselines in terms of efficient document retrieval.
+
+# 5.4 Evaluating the Quality of Codewords from the Clustering Perspective
+
+To examine how well the codewords can represent the corresponding refined vectors $\tilde{z}^m (x)$ , we set the number of codewords $K$ in each codebook as the number of the ground-truth classes on datasets (i.e., $K = 26,14$ and 4 on NYT, DBpedia and AGNews respectively), so that we can compute the unsu
+
+
+
+
+
+
+Figure 2: Hyper-parameter analyses with the precision $(\%)$ of 32-bits setting on NYT and DBpedia.
+
+
+
+pervised clustering accuracy with the help of the Hungarian algorithm (Kuhn, 1955) in each codebook. The number of codebooks $M$ is set as 8 on all datasets. For comparison, we also run K-Means on each $\tilde{z}^m(x)$ separately. As shown in Table 3, the codewords in our MICPQ are on par with the ones learned by K-Means. Particularly, our MICPQ significantly outperforms K-means on NYT that has the largest number of classes (i.e., 26), demonstrating the ability of our MICPQ to learn high-quality codewords, especially for datasets with diverse categories.
+
+# 5.5 Sensitive Analyses of Hyper-Parameters
+
+We investigate the influence of 4 key hyperparameters: the coefficient $\lambda$ , the dropout rate $p_{drop}$ , the temperature $\tau_{cl}$ in contrastive learning, and the Gumbel-Softmax temperature $\tau$ . As shown in Figure 2, compared with the case of $\lambda = 0$ , obvious performance gains can be observed by introducing the mutual-information loss inside each codebook when the $\lambda$ is set as a relatively small value (e.g., 0.2 or 0.3). The value of $p_{drop}$ controls the strength of data augmentation. We see that as $p_{drop}$ exceeds some thresholds (e.g., 0.4), the performance will decrease sharply, and eventually the model will collapse on both datasets. Also, it is shown that as $\tau_{cl}$ grows up, the precision first increases and reaches the peak when $\tau_{cl}$ is around 0.3 on both datasets. As for the Gumbel-Softmax temperature $\tau$ , we suggest setting it to a larger value, saying [5,15].
+
+# 6 Conclusion
+
+In this paper, we proposed a novel unsupervised product quantization model, namely MICPQ. In MICPQ, we managed to develop an end-to-end probabilistic contrastive product quantization model to jointly refine the original BERT embeddings and quantize the refined embeddings into codewords, with a probabilistic contrastive loss designed to preserve the semantic information in the quantized representations. Moreover, to improve the representativeness of codewords for keeping the cluster structure of documents soundly, we proposed to maximize the mutual information between data and the codeword assignment. Extensive experiments showed that our model significantly outperformed existing unsupervised hashing methods.
+
+# 7 Limitations
+
+In our work, we do not analyze the individuality of codebooks and the difference between codebooks. However, each codebook should show different aspects of characteristics for preserving rich semantics. Therefore, it may help if the difference between codebooks is more analyzed and improved this way. Also, in the future we may try to apply this method to the tasks of passage retrieval, on which some large-scale datasets for evaluation are available.
+
+# Acknowledgement
+
+This work is supported by the National Natural Science Foundation of China (No. 62276280, U1811264), Key R&D Program of Guangdong Province (No. 2018B010107005), National Natural Science Foundation of Guangdong Province (No. 2021A1515012299), Science and Technology Program of Guangzhou (No. 202102021205). This work is also supported by CAAI-Huawei MindSpore Open Fund.
+
+# References
+
+Yoshua Bengio, Nicholas Léonard, and Aaron C. Courville. 2013. Estimating or propagating gradients through stochastic neurons for conditional computation. CoRR, abs/1308.3432.
+Yue Cao, Mingsheng Long, Jianmin Wang, Han Zhu, and Qingfu Wen. 2016. Deep quantization network for efficient image retrieval. In AAAI, pages 3457-3463. AAAI Press.
+
+Suthee Chaidaroon, Travis Ebesu, and Yi Fang. 2018. Deep semantic text hashing with weak supervision. In SIGIR, pages 1109-1112. ACM.
+Suthee Chaidaroon and Yi Fang. 2017. Variational deep semantic hashing for text documents. In SI-GIR, pages 75-84. ACM.
+Suthee Chaidaroon, Dae Hoon Park, Yi Chang, and Yi Fang. 2020. node2hash: Graph aware deep semantic text hashing. Information Processing & Management, 57(6):102143.
+Kien Do, Truyen Tran, and Svetha Venkatesh. 2021. Clustering by maximizing mutual information across views. In ICCV, pages 9908-9918. IEEE.
+Wei Dong, Qinliang Su, Dinghan Shen, and Changyou Chen. 2019. Document hashing with mixture-prior generative models. In EMNLP/IJCNLP (1), pages 5225-5234. Association for Computational Linguistics.
+Kawin Ethayarajh. 2019. How contextual are contextualized word representations? comparing the geometry of bert, elmo, and gpt-2 embeddings. arXiv preprint arXiv:1909.00512.
+Tianyu Gao, Xingcheng Yao, and Danqi Chen. 2021. Simcse: Simple contrastive learning of sentence embeddings. In EMNLP (1), pages 6894-6910. Association for Computational Linguistics.
+Tiezheng Ge, Kaiming He, Qifa Ke, and Jian Sun. 2013. Optimized product quantization for approximate nearest neighbor search. In CVPR, pages 2946-2953. IEEE Computer Society.
+Robert M. Gray and David L. Neuhoff. 1998. Quantization. IEEE transactions on information theory, 44(6):2325-2383.
+Casper Hansen, Christian Hansen, Jakob Grue Simonsen, Stephen Alstrup, and Christina Lioma. 2019. Unsupervised neural generative semantic hashing. In SIGIR, pages 735-744. ACM.
+Casper Hansen, Christian Hansen, Jakob Grue Simonsen, Stephen Alstrup, and Christina Lioma. 2020. Unsupervised semantic hashing with pairwise reconstruction. In SIGIR, pages 2009-2012. ACM.
+Weihua Hu, Takeru Miyato, Seiya Tokui, Eiichi Matsumoto, and Masashi Sugiyama. 2017. Learning discrete representations via information maximizing self-augmented training. In ICML, volume 70 of Proceedings of Machine Learning Research, pages 1558-1567. PMLR.
+Eric Jang, Shixiang Gu, and Ben Poole. 2017. Categorical reparameterization with gumbel-softmax. In ICLR (Poster). OpenReview.net.
+Young Kyun Jang and Nam Ik Cho. 2021. Self-supervised product quantization for deep unsupervised image retrieval. In ICCV, pages 12065-12074. IEEE.
+
+Herve Jégou, Matthijs Douze, and Cordelia Schmid. 2011. Product quantization for nearest neighbor search. IEEE Trans. Pattern Anal. Mach. Intell., 33(1):117-128.
+Xu Ji, Andrea Vedaldi, and João F. Henriques. 2019. Invariant information clustering for unsupervised image classification and segmentation. In ICCV, pages 9864-9873. IEEE.
+Yannis Kalantidis and Yannis Avrithis. 2014. Locally optimized product quantization for approximate nearest neighbor search. In CVPR, pages 2329-2336. IEEE Computer Society.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In ICLR (Poster).
+Diederik P. Kingma and Max Welling. 2014. Autoencoding variational bayes. In ICLR.
+Harold W Kuhn. 1955. The hungarian method for the assignment problem. Naval research logistics quarterly, 2(1-2):83-97.
+Jens Lehmann, Robert Isele, Max Jakob, Anja Jentzsch, Dimitris Kontokostas, Pablo N. Mendes, Sebastian Hellmann, Mohamed Morsey, Patrick van Kleef, Soren Auer, and Christian Bizer. 2015. Dbpedia - A large-scale, multilingual knowledge base extracted from wikipedia. Semantic Web, 6(2):167-195.
+Bohan Li, Hao Zhou, Junxian He, Mingxuan Wang, Yiming Yang, and Lei Li. 2020. On the sentence embeddings from pre-trained language models. In EMNLP (1), pages 9119-9130. Association for Computational Linguistics.
+Zijing Ou, Qinliang Su, Jianxing Yu, Bang Liu, Jingwen Wang, Ruihui Zhao, Changyou Chen, and Yefeng Zheng. 2021a. Integrating semantics and neighborhood information with graph-driven generative models for document retrieval. In ACL/IJCNLP (1), pages 2238-2249. Association for Computational Linguistics.
+Zijing Ou, Qinliang Su, Jianxing Yu, Ruihui Zhao, Yefeng Zheng, and Bang Liu. 2021b. Refining BERT embeddings for document hashing via mutual information maximization. In EMNLP (Findings), pages 2360-2369. Association for Computational Linguistics.
+Jeffrey Pennington, Richard Socher, and Christopher D. Manning. 2014. Glove: Global vectors for word representation. In EMNLP, pages 1532-1543. ACL.
+Nils Reimers and Iryna Gurevych. 2019. Sentence-bert: Sentence embeddings using siamese bert-networks. In EMNLP/IJCNLP (1), pages 3980-3990. Association for Computational Linguistics.
+Ruslan Salakhutdinov and Geoffrey E. Hinton. 2009. Semantic hashing. Int. J. Approx. Reason., 50(7):969-978.
+
+Dinghan Shen, Qinliang Su, Paidamoyo Chapfuwa, Wenlin Wang, Guoyin Wang, Ricardo Henao, and Lawrence Carin. 2018. NASH: toward end-to-end neural architecture for generative semantic hashing. In ACL (1), pages 2041-2050. Association for Computational Linguistics.
+Karl Stratos and Sam Wiseman. 2020. Learning discrete structured representations by adversarially maximizing mutual information. In ICML, volume 119 of Proceedings of Machine Learning Research, pages 9144-9154. PMLR.
+Fangbo Tao, Chao Zhang, Xiusi Chen, Meng Jiang, Tim Hanratty, Lance M. Kaplan, and Jiawei Han. 2018. Doc2cube: Allocating documents to text cube without labeled data. In ICDM, pages 1260-1265. IEEE Computer Society.
+Jinpeng Wang, Ziyun Zeng, Bin Chen, Tao Dai, and Shu-Tao Xia. 2021. Contrastive quantization with code memory for unsupervised image retrieval. CoRR, abs/2109.05205.
+Yair Weiss, Antonio Torralba, and Robert Fergus. 2008. Spectral hashing. In NIPS, pages 1753-1760. Curran Associates, Inc.
+Shitao Xiao, Zheng Liu, Yingxia Shao, Defu Lian, and Xing Xie. 2021. Matching-oriented embedding quantization for ad-hoc retrieval. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 8119-8129.
+Fanghua Ye, Jarana Manotumruksa, and Emine Yilmaz. 2020. Unsupervised few-bits semantic hashing with implicit topics modeling. In EMNLP (Findings), volume EMNLP 2020 of Findings of ACL, pages 2566-2575. Association for Computational Linguistics.
+Xiang Zhang, Junbo Jake Zhao, and Yann LeCun. 2015. Character-level convolutional networks for text classification. In NIPS, pages 649-657.
+Lin Zheng, Qinliang Su, Dinghan Shen, and Changyou Chen. 2020. Generative semantic hashing enhanced via boltzmann machines. In ACL, pages 777-788. Association for Computational Linguistics.
+
+# A Details about Datasets
+
+Table 4: Statistics of Three Benchmark Datasets.
+
+| Dataset | Classes | AvgLen | Train | Val | Test |
| NYT | 26 | 648 | 9,221 | 1,154 | 1,152 |
| AGNews | 4 | 32 | 114,839 | 6,381 | 6,380 |
| DBpedia | 14 | 47 | 50,000 | 5,000 | 5,000 |
+
+Three datasets are used to evaluate the performance of the proposed model. 1) NYT (Tao et al., 2018) is a dataset which contains news articles published by The New York Times; 3) AGNews (Zhang et al., 2015) is a news collection gathered from academic news search engines; 3) DBpedia (Lehmann et al., 2015) is a dataset which contains the abstracts of articles from Wikipedia. We simply apply the string cleaning operation same as in (Ou et al., 2021b). The statistics of the three datasets are shown in Table 4.
+
+# B Retrieval
+
+For testing, we first encode all the documents in the search set (i.e., the training set in our setting). For each document $x_{i}$ in the search set, we encode it using the hard quantization operation to obtain the codeword index $\{k_i^1,k_i^2,\dots ,k_i^M\}$ . Then all these codeword indices are concatenated and stored in the form of the $M\log_2K$ -bits binary code.
+
+In terms of the retrieval stage, when given a query document $x_{q}$ , we first extract its refined embedding $\tilde{z}(x_{q})$ through the encoder network and then slice it into $M$ equal-length segments as $\tilde{z}(x_{q}) = [\tilde{z}^{1}(x_{q}), \tilde{z}^{1}(x_{q}), \dots, \tilde{z}^{M}(x_{q})]$ . Then we compute the Asymmetric distance (AD) (Jégou et al., 2011) between the query $x_{q}$ and the documents $x_{i}$ with the squared Euclidean distance metric as:
+
+$$
+A D \left(x _ {q}, x _ {i}\right) = \sum_ {m = 1} ^ {M} \left| \left| \tilde {z} ^ {m} \left(x _ {q}\right) - C ^ {m} \cdot h ^ {m} \left(x _ {i}\right) \right| \right| _ {2} ^ {2}, \tag {22}
+$$
+
+where $h^m (x_i) = C^m \cdot \text{one\_hot}(k_i^m)$ represents the quantized representation (i.e., one of codewords) of $x_{i}$ in the $m$ -th codebook. To compute that, we can first pre-compute a query-specific distance look-up table of size $M \times K$ that stores the distance between the segment $\tilde{z}^{m}(x_{q})$ and all codewords in each codebook. With the pre-computed look-up table, $AD(x_{q},x_{i})$ can be efficiently computed by summing up the chosen values from the look-up table. It is only slightly more costly when compared with the efficiency of the Hamming distance.
+
+# C Pooling methods
+
+Table 5: The performance comparison between the [CLS] representations and the average embeddings of BERT.
+
+| CLS vs Avg | 16bits | 32bits | 64bits | 128bits |
| NYT | \( CSH_{Avg} \) | 71.89 | 71.99 | 77.38 | 78.26 |
| \( CSH_{CLS} \) | 79.63 | 81.05 | 81.08 | 81.28 |
| \( MICPQ_{Avg} \) | 79.56 | 79.99 | 78.49 | 80.33 |
| \( MICPQ_{CLS} \) | 83.15 | 84.02 | 84.24 | 85.08 |
| AGNews | \( CSH_{Avg} \) | 81.38 | 81.22 | 81.83 | 81.85 |
| \( CSH_{CLS} \) | 79.14 | 80.25 | 81.14 | 81.78 |
| \( MICPQ_{Avg} \) | 81.60 | 83.00 | 83.85 | 84.04 |
| \( MICPQ_{CLS} \) | 80.36 | 81.84 | 82.93 | 83.29 |
| DBpedia | \( CSH_{Avg} \) | 93.39 | 93.98 | 94.56 | 94.66 |
| \( CSH_{CLS} \) | 95.19 | 95.84 | 95.79 | 96.01 |
| \( MICPQ_{Avg} \) | 94.47 | 95.87 | 95.76 | 95.71 |
| \( MICPQ_{CLS} \) | 96.51 | 97.00 | 97.03 | 97.21 |
+
+We are interested in if taking the average embeddings of the last layers in BERT as inputs will lead to a better performance than [CLS] or not. The experiments are conducted in our proposed model MICPQ and the simple baseline CSH. Table 5 shows that these two settings achieve better performance in different datasets respectively. For simplicity, we consistently use the [CLS] representation in our experiments.
\ No newline at end of file
diff --git a/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/images.zip b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..73690b33d1bd8bbd63d5f5af85e52ea396745fd9
--- /dev/null
+++ b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:15eadc6799524ec7269fe0533bbe113b163f9d203ca39d330449af8d5b60da37
+size 473342
diff --git a/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/layout.json b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..789fe4842db58092ee268e4dad8369eff2f0723d
--- /dev/null
+++ b/efficientdocumentretrievalbyendtoendrefiningandquantizingbertembeddingwithcontrastiveproductquantization/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8feb21be628803aeba619a78172f863ef383c240011c308f789d111d2963b65e
+size 475363
diff --git a/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_content_list.json b/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..6baffb2e0647facbe4d8ad4828859b19119bd625
--- /dev/null
+++ b/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c963f8021ebcdc061ef737fbf80c0351d0a9b67f22eb8c616531da2b36790468
+size 51562
diff --git a/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_model.json b/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..f7f9a78c35666d005961106de0f526bcce7209a0
--- /dev/null
+++ b/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9624d6547d1630117923af1b8af93ddf29e49b7391797688976235e5253f960c
+size 64444
diff --git a/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_origin.pdf b/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..f49f28d0c47336a1cb3618da0e296f8277b784e3
--- /dev/null
+++ b/efficientlytunedparametersaretaskembeddings/a2e74724-59ca-41fd-b776-8bd9bd469dab_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a7f7446e6ed524af24e4e306e79c17fcb4f0e95a9dd2edbcd558693b87c4d74a
+size 283492
diff --git a/efficientlytunedparametersaretaskembeddings/full.md b/efficientlytunedparametersaretaskembeddings/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..ceafe9a218c79116e8c9420fe0ae23d6eb923e0f
--- /dev/null
+++ b/efficientlytunedparametersaretaskembeddings/full.md
@@ -0,0 +1,176 @@
+# Efficiently Tuned Parameters are Task Embeddings
+
+Wangchunshu Zhou $^{1*}$ , Canwen Xu $^{2*}$ , Julian McAuley $^{2}$
+
+$^{1}$ ETH Zurich $^{2}$ University of California, San Diego
+
+$^{1}$ wangchunshu.zhou@inf.ethz.ch, $^{2}$ {cxu, jmcauley}@ucsd.edu
+
+# Abstract
+
+Intermediate-task transfer can benefit a wide range of NLP tasks with properly selected source datasets. However, it is computationally infeasible to experiment with all intermediate transfer combinations, making choosing a useful source task a challenging problem. In this paper, we anticipate that task-specific parameters updated in parameter-efficient tuning methods are likely to encode task-specific information. Therefore, such parameters can be predictive for inter-task transferability. Thus, we propose to exploit these efficiently tuned parameters as off-the-shelf task embeddings for the efficient selection of source datasets for intermediate-task transfer. We experiment with 11 text classification tasks and 11 question answering tasks. Experimental results show that our approach can consistently outperform existing inter-task transferability prediction methods while being conceptually simple and computationally efficient. Our analysis also reveals that the ability of efficiently tuned parameters on transferability prediction is disentangled with their in-task performance. This allows us to use parameters from early checkpoints as task embeddings to further improve efficiency. $^{1}$
+
+# 1 Introduction
+
+The pretraining then fine-tuning paradigm (Peters et al., 2018; Devlin et al., 2019; Radford et al., 2018, 2019; Brown et al., 2020; Lewis et al., 2020; Raffel et al., 2019) has substantially improved the state-of-the-art on a wide range of natural language processing (NLP) tasks. In this paradigm, we first pretrain a large language model on large-scale corpora in a general domain, and then fine-tune the pretrained model to be a task-specific model on the target dataset. In addition to directly transferring from a general pretrained language model,
+
+
+Figure 1: The workflow of using efficiently tuned parameters as task embeddings. The yellow boxes represent tunable parameters in Transformer layers.
+
+prior work (Phang et al., 2018) also shows that intermediate-task transfer, i.e., fine-tuning on intermediate source tasks before the target task, can further improve target task performance. However, the success of intermediate-task transfer heavily relies on the selection of a proper source dataset while an inappropriate source dataset often leads to performance degradation compared to plain finetuning. Therefore, some recent works (Vu et al., 2020; Poth et al., 2021) investigate methods to efficiently predict inter-task transferability without actually trying out all intermediate-task combinations.
+
+The current state of the art (Vu et al., 2020) on predicting inter-task transferability is built on Task2Vec (Achille et al., 2019), which considers the Fisher information matrix of a model finetuned on a task as the "task embedding", and predicts inter-task transferability by computing the cosine similarity between the task embedding of the source and target tasks. Despite empirically performing well, this approach requires fine-tuning the full model and (inefficiently) computing the Fisher matrix of the model. Moreover, the resulting task embeddings generally have a high dimensionality similar to the size of the underlying model. Therefore, intermediate task selection, which requires storing task embeddings for each source/target task, can be space-consuming, especially when experi
+
+menting with large language models.
+
+In this work, we opt for parameter-efficient tuning approaches (Houlsby et al., 2019; Li and Liang, 2021; Guo et al., 2021; Hu et al., 2022; Zaken et al., 2022) for the efficient and accurate prediction of inter-task transferability. Our key insight is that task-specific parameters updated in parameter-efficient tuning methods are likely to encode high density task-specific information since they are used as a query for retrieving task-related knowledge in a frozen pretrained language model. Therefore, we propose to directly use task-specific parameters learned via parameter-efficient tuning on source/target datasets as task embeddings, as shown in Figure 1. Compared to task embeddings obtained by calculating the Fisher matrix of the fine-tuned model (Achille et al., 2019; Vu et al., 2020), efficiently tuned parameters are of much lower dimensionality and do not suffer from noise from uninformative weights in the model parameters, thus leading to more accurate transferability prediction. Also, our method only requires parameter-efficient tuning on the tasks and stores task-specific parameters, making both computing and storing task embeddings more efficient. Moreover, with the development of open-source parameter-efficient tuning platforms like AdapterHub (Pfeiffer et al., 2020), we can easily access off-the-shelf parameters of the source and target datasets downloaded from the model zoo and then compute the similarity between the downloaded parameters.
+
+We empirically verify the effectiveness of our approach by experimenting with 11 text classification tasks and 11 question answering tasks, following Vu et al. (2020). Our results show that our approach consistently outperforms existing intertask transferability prediction methods while being simpler and more efficient. In addition, we find that the ability of efficiently tuned parameters on transferability prediction is not strongly correlated with their in-task performance. Therefore, task-specific parameters tuned with a relatively small number of steps are already highly predictive for inter-task transferability, allowing us to further improve the efficiency of intermediate task selection.
+
+# 2 Related Work
+
+Prior work (Phang et al., 2018) shows that positive transfer can be elicited by training a model on intermediate source tasks before fine-tuning on
+
+the target task. However, the choice of an appropriate source task is crucial for effective transfer. Phang et al. (2018) show that the size of the source dataset is an good prior for source task selection. Pruksachatkun et al. (2020) propose to use task requiring complex reasoning and inference as source tasks. Besides these heuristics, a number of work also focuses on systematic prediction of intermediate task transferability. Vu et al. (2020) propose to used TASK2VEC to construct task embeddings based on the input text or Fisher information matrix of a fine-tuned model. Poth et al. (2021) further extend similar ideas for adapter-based transfer learning. More recently, Vu et al. (2021) explore prompt-based transfer and propose to use prompt similarity as a predictor for prompt transferability to select proper soft prompts for initialization. This can be viewed as a special case of our proposed method where the parameter-efficient tuning method is restricted to vanilla prompt tuning (Lester et al., 2021) and the transfer method is restricted to prompt transfer instead of general intermediate-task transfer.
+
+# 3 Methodology
+
+# 3.1 Parameter-Efficient Tuning
+
+Parameter-efficient tuning only updates a small portion of parameters in a large pretrained model. In this paper, we experiment with three types of parameter-efficient tuning: Prompt Tuning (Liu et al., 2021), Bias Tuning (Zaken et al., 2022), and Low-Rank Tuning (Hu et al., 2022).
+
+Prompt Tuning We experiment with P-Tuning v2 (Liu et al., 2021). Specifically, P-Tuning v2 implements a prompt tuning method by introducing additional attention prefix matrices $K_{t} = \{\mathbf{k}_{1}\dots \mathbf{k}_{n}\}$ and $V_{t} = \{\mathbf{v}_{1}\dots \mathbf{v}_{n}\}$ for each Transformer layer, where $n$ is a hyperparameter controlling the added prefix length; $\mathbf{k}_*$ and $\mathbf{v}_*$ are vectors with dimension $d_h$ ; $d_h$ is the hidden size of the Transformer model.
+
+For each Transformer layer, the added vectors are concatenated with the original key and value matrices to be $K' = K_t \oplus K$ and $V' = V_t \oplus V$ , where $K$ and $V$ are the original key and value in each layer's attention block. Then, the new scaled dot-product attention is calculated by replacing the original $K$ and $V$ with the new $K'$ and $V'$ , respectively.
+
+Bias Tuning BitFit (Zaken et al., 2022) simply updates all bias terms $b$ in all linear layers $h = Wx + b$ in each Transformer layer.
+
+Low-Rank Tuning LoRA (Hu et al., 2022) injects trainable rank decomposition matrices into each layer of the Transformer model. For each linear layer $h = Wx$ where $W \in \mathbb{R}^{d \times k}$ , the forward pass is modified to $h = Wx + BAx$ where $B \in \mathbb{R}^{d \times r}$ , $A \in \mathbb{R}^{r \times k}$ , and the rank $r \ll \min(d, k)$ .
+
+# 3.2 Tuned Parameters as Task Embeddings
+
+After parameter-efficient tuning, we concatenate all tuned parameters in each Transformer layer and average them across all layers to obtain a vector as a representation for a task, namely Tuned Parameters as Task Embedding (TuPaTE). Following Vu et al. (2020), we calculate the cosine similarity between the embeddings of a given targeted task and the candidate source tasks. Then, we rank the candidate source tasks in descending order by the similarity scores.
+
+# 4 Experiments
+
+# 4.1 Datasets
+
+Following Vu et al. (2020), we conduct experiments with 11 tasks of text classification or regression (CR) and 11 tasks of question answering (QA). Note that Vu et al. (2020) also includes 11 tasks of sequence labeling. We do not include those datasets since most of them are not publicly available. The list of datasets can be found in Appendix A. To be consistent with Vu et al. (2020), we use two metrics to evaluate the performance of the task embeddings: (1) the average rank $\rho$ of the source task with the highest absolute transfer gain; (2) Normalized Discounted Cumulative Gain (NDCG), which is a widely used metric for evaluating the quality of the entire ranking, instead of focusing on the highest rank as $\rho$ does.
+
+# 4.2 Baselines
+
+We use the following methods as baselines: (1) DATASIZE (Vu et al., 2020) is a simple baseline that ranks all source tasks by the number of training examples. (2) CURVEGRAD (Bingel and Søgaard, 2017; Vu et al., 2020) is a baseline that uses the gradients of the loss curve of BERT for each task. It is originally proposed in Bingel and Søgaard (2017) for predicting gains from multi-task learning and adapted by Vu et al. (2020) for predicting
+
+| Method | #Tuned
+Param. | Embedding
+Dim. |
| TASKemb | 110M | 110M |
| PTUNING | 184K | 15.4K |
| LORA | 300K | 25.0K |
| BITFIT | 100K | 8.3K |
+
+Table 1: Numbers of tuned parameters and the dimensions of the final task representation.
+
+transferability. (3) TEXTEMB (Vu et al., 2020) averages sentence representations over the entire dataset. The sentence representation is obtained by averaging the hidden states in the last layer of BERT. (4) TASKEMB (Vu et al., 2020) represents tasks based on the Fisher information matrix. It is adapted from the task embedding originally proposed in Achille et al. (2019) for meta-learning.
+
+# 4.3 Training Details
+
+We apply P-Tuning v2, BitFit, and LoRA on BERT-base for fine-tuning on the aforementioned datasets. For each method, we adopt the default hyperparameters from their corresponding papers. Specifically, for P-Tuning v2, we use a prefix length of 20 and search the learning rate from $\{1\mathrm{e} - 2,1\mathrm{e} - 3\}$ ; For LoRA, we set LoRA's $r$ to 8 and $\alpha$ to 8, and search a learning rate from $\{5\mathrm{e} - 4,2\mathrm{e} - 4\}$ ; For BitFit, we search a learning rate from $\{1\mathrm{e} - 4,4\mathrm{e} - 4\}$ . We train all models with a batch size of 32 for 20 epochs on all datasets. We use the parameters tuned for 2 epochs as "early" task embeddings and those corresponding to the best validation set performance as "late" task embeddings. We compare the number of tunable parameters and the final task embedding dimensions in Table 1. We can see that TuPaTE has a significantly lower dimensionality compare to the TASKEMB baseline. We also include an ensemble of the three efficient tuning methods (denoted as "3 ENSEMBLE"), by averaging the inter-task similarity scores of each model.
+
+# 4.4 Experimental Results
+
+We present the main results in Table 2. We find that TuPaTE with different parameter-efficient tuning methods consistently outperforms prior works including TEXTEMB and TASKEMB. Interestingly, the performance improvement is larger in FULL $\rightarrow$ LIMITED and LIMITED $\rightarrow$ LIMITED settings. We conjecture that this is because in limited resource
+
+| Task Type | Method | FULL → FULL | FULL → LIMITED | LIMITED → LIMITED |
| in-class (10) | all-class (21) | in-class (10) | all-class (21) | in-class (10) | all-class (21) |
| ρ↓ | NDCG↑ | ρ↓ | NDCG↑ | ρ↓ | NDCG↑ | ρ↓ | NDCG↑ | ρ↓ | NDCG↑ | ρ↓ | NDCG↑ |
| Classification/Regression (CR) | DATASIZE | 3.6 | 80.4 | 7.8 | 75.2 | 3.8 | 62.9 | 8.9 | 57.2 | - | - | - | - |
| CURVEGRAD | 5.5 | 68.6 | - | - | 6.4 | 45.2 | - | - | 5.9 | 50.8 | - | - |
| TEXTEMB | 5.2 | 76.4 | 9.8 | 74.7 | 3.5 | 60.3 | 7.5 | 55.6 | 4.8 | 61.4 | 11.4 | 46.2 |
| TASKEMB | 2.8 | 82.3 | 5.4 | 78.3 | 3.4 | 68.2 | 7.1 | 63.5 | 4.2 | 62.6 | 9.7 | 47.7 |
| TUPATE | | | | | | | | | | | | |
| +PTUNING | 2.5 | 83.7 | 4.5 | 81.0 | 3.1 | 71.3 | 6.4 | 65.1 | 3.9 | 64.6 | 8.1 | 51.3 |
| +LORA | 2.7 | 83.0 | 5.0 | 79.6 | 3.3 | 70.5 | 6.8 | 63.7 | 4.0 | 64.2 | 9.0 | 49.3 |
| +BITFIT | 2.5 | 83.5 | 4.3 | 81.6 | 3.2 | 71.1 | 6.5 | 64.6 | 3.8 | 64.9 | 8.3 | 50.9 |
| 3 ENSEMBLE | 2.3 | 83.9 | 4.2 | 81.8 | 3.1 | 71.5 | 6.2 | 65.3 | 3.8 | 65.1 | 8.0 | 51.5 |
| Question Answering (QA) | DATASIZE | 3.2 | 84.4 | 11.4 | 65.8 | 2.3 | 77.0 | 11.2 | 43.5 | - | - | - | - |
| CURVEGRAD | 8.3 | 64.8 | - | - | 8.2 | 49.1 | - | - | 6.8 | 53.4 | - | - |
| TEXTEMB | 4.1 | 81.1 | 5.8 | 82.0 | 2.7 | 77.6 | 3.8 | 80.5 | 4.1 | 65.6 | 7.3 | 69.1 |
| TASKEMB | 3.2 | 84.5 | 5.4 | 82.8 | 2.5 | 78.0 | 3.6 | 81.6 | 3.6 | 67.1 | 7.1 | 69.5 |
| TUPATE | | | | | | | | | | | | |
| +PTUNING | 3.0 | 85.7 | 4.8 | 83.3 | 2.2 | 80.9 | 3.1 | 83.5 | 3.2 | 68.3 | 6.3 | 72.4 |
| +LORA | 3.1 | 85.3 | 5.2 | 83.0 | 2.3 | 79.8 | 3.3 | 82.5 | 3.4 | 67.5 | 6.7 | 70.8 |
| +BITFIT | 3.0 | 85.5 | 4.9 | 83.1 | 2.1 | 81.4 | 3.1 | 83.4 | 3.3 | 68.0 | 6.5 | 72.0 |
| 3 ENSEMBLE | 2.9 | 85.9 | 4.8 | 83.5 | 2.0 | 81.7 | 2.9 | 83.7 | 3.2 | 68.2 | 6.3 | 72.4 |
+
+Table 2: To evaluate TuPaTE, we measure the average rank $(\rho)$ assigned to the best source task (i.e., the one that results in the largest transfer gain) across target tasks, as well as the average NDCG measure of the overall ranking's quality. Parentheses denote the number of source tasks in each setting. Some results of CURVEGRAD are missing (marked with “-”) since its code is not available. The other results of CURVEGRAD are taken from Vu et al. (2020).
+
+| Method | Δρ | ΔNDCG | NCDG-Perf. Pearson |
| PTUNING | 0.0 | +0.1 | 0.25 |
| LORA | 0.0 | -0.1 | 0.17 |
| BITFIT | +0.1 | +0.2 | 0.20 |
+
+settings, parameter-efficient tuning methods generally perform much better than full fine-tuning, which is used in the TASKEMB method. Moreover, we find that PTUNING and BITFIT outperform LORA in all settings. We suspect this is because the amount of tunable parameters in LORA is much larger than PTUNING and BITFIT. Also, the ensemble of three methods achieve even better performance than only using one approach.
+
+# 4.5 Analysis
+
+We conduct additional experiments in the in-class setting on classification/regression tasks to better understand how TuPaTE works. We first analyze the correlation between the in-task perfor
+
+Table 3: Analysis on the correlation between task-specific performance (e.g., accuracy) and transferability prediction results (i.e., $\rho$ and NDCG) for different parameter-efficient tuning methods. $\Delta \rho$ and $\Delta$ NDCG denote the difference of $\rho$ and NDCG between the parameters with the highest and lowest task-specific performance.
+
+| Method | Early | Best |
| ρ | NDCG | ρ | NDCG |
| PTUNING | 2.5 | 83.5 | 2.5 | 83.7 |
| LoRA | 2.8 | 82.6 | 2.7 | 83.0 |
| BITFIT | 2.5 | 83.2 | 2.5 | 83.5 |
+
+Table 4: Transferability prediction results with early checkpoints (checkpoints after 2 epochs) and the best checkpoints (checkpoints corresponding to the best validation performance).
+
+mance (e.g., accuracy) and transferability prediction ability of efficiently tuned parameters. We train TuPaTE with 5 random combinations between searchable hyperparameters and random seeds, and present the correlation in Table 3. We observe that there is only a weak correlation between in-task performance and transferability prediction results, indicating that the ability of efficiently tuned parameters to encode task-related information is disentangled with their final in-task performance. This also shows the robustness of TuPaTE with respect to hyperparameters.
+
+The fact that in-task performance only correlates weakly with transferability prediction motivates us to explore whether early checkpoints of efficiently tuned parameters can be used for transferability prediction. From Table 4, we find that
+
+early checkpoints are also effective task embeddings. This allows us to reduce the computation cost by around $90\%$ while substantially outperforming the TASKEMB baseline.
+
+# 5 Conclusion
+
+In this paper, we show that efficiently tuned parameters are highly predictive for inter-task transferability and thus can be used as off-the-shelf task embeddings for source task selection in intermediate-task transfer learning. Our empirical investigation with three parameter-efficient tuning methods on 22 NLP tasks demonstrates that our approach outperforms prior works on inter-task transferability prediction despite being more efficient.
+
+# Limitations
+
+We select three representative works for three types of parameter-efficient tuning. However, there are other parameter-efficient tuning methods that we have not investigated. Although we believe our conclusion can generalize to other methods, we will conduct more experiments to confirm for future work.
+
+# Ethics Statement
+
+We propose to use efficiently tuned parameters as task embedding, only for predicting the performance of intermediate transfer learning. Thus, we do not anticipate any major ethical concern.
+
+# Acknowledgements
+
+We would like to thank the anonymous reviewers for their insightful comments. This project is partly supported by NSF Award #1750063.
+
+# References
+
+Abdalghani Abujabal, Rishiraj Saha Roy, Mohamed Yahya, and Gerhard Weikum. 2019. ComQA: A community-sourced dataset for complex factoid question answering with paraphrase clusters. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 307-317. Association for Computational Linguistics.
+Alessandro Achille, Michael Lam, Rahul Tewari, Avinash Ravichandran, Subhransu Maji, Charless C. Fowlkes, Stefano Soatto, and Pietro Perona. 2019. Task2vec: Task embedding for meta-learning. In
+
+2019 IEEE/CVF International Conference on Computer Vision, ICCV 2019, Seoul, Korea (South), October 27 - November 2, 2019, pages 6429-6438. IEEE.
+Junwei Bao, Nan Duan, Zhao Yan, Ming Zhou, and Tiejun Zhao. 2016. Constraint-based question answering with knowledge graph. In Proceedings of COLING 2016, the 26th International Conference on Computational Linguistics: Technical Papers, pages 2503-2514. The COLING 2016 Organizing Committee.
+Joachim Bingel and Anders Søgaard. 2017. Identifying beneficial task relations for multi-task learning in deep neural networks. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers, pages 164-169. Association for Computational Linguistics.
+Samuel R. Bowman, Gabor Angeli, Christopher Potts, and Christopher D. Manning. 2015. A large annotated corpus for learning natural language inference. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 632-642. Association for Computational Linguistics.
+Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Daniel Cer, Mona Diab, Eneko Agirre, Inigo Lopez-Gazpio, and Lucia Specia. 2017. SemEval-2017 task 1: Semantic textual similarity multilingual and crosslingual focused evaluation. In Proceedings of the 11th International Workshop on Semantic Evaluation (SemEval-2017), pages 1-14. Association for Computational Linguistics.
+Christopher Clark, Kenton Lee, Ming-Wei Chang, Tom Kwiatkowski, Michael Collins, and Kristina Toutanova. 2019. BoolQ: Exploring the surprising difficulty of natural yes/no questions. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 2924–2936. Association for Computational Linguistics.
+Ido Dagan, Oren Glickman, and Bernardo Magnini. 2005. The PASCAL recognising textual entailment challenge. In MLCW, volume 3944 of Lecture Notes in Computer Science, pages 177-190. Springer.
+
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics.
+William B. Dolan and Chris Brockett. 2005. Automatically constructing a corpus of sentential paraphrases. In Proceedings of the Third International Workshop on Paraphrasing (IWP2005).
+Dheeru Dua, Yizhong Wang, Pradeep Dasigi, Gabriel Stanovsky, Sameer Singh, and Matt Gardner. 2019. DROP: A reading comprehension benchmark requiring discrete reasoning over paragraphs. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 2368-2378. Association for Computational Linguistics.
+Demi Guo, Alexander Rush, and Yoon Kim. 2021. Parameter-efficient transfer learning with diff pruning. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4884-4896. Association for Computational Linguistics.
+Neil Houlsby, Andrei Giurgiu, Stanislaw Jastrzebski, Bruna Morrone, Quentin de Laroussilhe, Andrea Gesmundo, Mona Attariyan, and Sylvain Gelly. 2019. Parameter-efficient transfer learning for NLP. In Proceedings of the 36th International Conference on Machine Learning, ICML 2019, 9-15 June 2019, Long Beach, California, USA, volume 97 of Proceedings of Machine Learning Research, pages 2790-2799. PMLR.
+Edward J Hu, yelong shen, Phillip Wallis, Zeyuan Allen-Zhu, Yuanzhi Li, Shean Wang, Lu Wang, and Weizhu Chen. 2022. LoRA: Low-rank adaptation of large language models. In ICLR.
+Shankar Iyer, Nikhil Dandekar, and Kornél Csernai. 2017. First Quora Dataset Release: Question pairs.
+Tushar Khot, Ashish Sabharwal, and Peter Clark. 2018. Scitail: A textual entailment dataset from science question answering. In Proceedings of the Thirty-Second AAAI Conference on Artificial Intelligence, (AAAI-18), the 30th innovative Applications of Artificial Intelligence (IAAI-18), and the 8th AAAI Symposium on Educational Advances in Artificial Intelligence (EAAI-18), New Orleans, Louisiana, USA, February 2-7, 2018, pages 5189-5197. AAAI Press.
+Brian Lester, Rami Al-Rfou, and Noah Constant. 2021. The power of scale for parameter-efficient prompt tuning. arXiv preprint arXiv:2104.08691.
+
+Hector J. Levesque. 2011. The winograd schema challenge. In AAAI Spring Symposium: Logical Formalizations of Commonsense Reasoning. AAAI.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: Denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880. Association for Computational Linguistics.
+Xiang Lisa Li and Percy Liang. 2021. Prefix-tuning: Optimizing continuous prompts for generation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4582-4597. Association for Computational Linguistics.
+Xiao Liu, Kaixuan Ji, Yicheng Fu, Zhengxiao Du, Zhilin Yang, and Jie Tang. 2021. P-tuning v2: Prompt tuning can be comparable to fine-tuning universally across scales and tasks. arXiv preprint arXiv:2110.07602.
+Matthew E. Peters, Mark Neumann, Mohit Iyyer, Matt Gardner, Christopher Clark, Kenton Lee, and Luke Zettlemoyer. 2018. Deep contextualized word representations. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 2227-2237. Association for Computational Linguistics.
+Jonas Pfeiffer, Andreas Rückle, Clifton Poth, Aishwarya Kamath, Ivan Vulic, Sebastian Ruder, Kyunghyun Cho, and Iryna Gurevych. 2020. AdapterHub: A framework for adapting transformers. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 46-54. Association for Computational Linguistics.
+Jason Phang, Thibault Févry, and Samuel R Bowman. 2018. Sentence encoders on stilts: Supplementary training on intermediate labeled-data tasks. arXiv preprint arXiv:1811.01088.
+Clifton Poth, Jonas Pfeiffer, Andreas Rückle, and Iryna Gurevych. 2021. What to pre-train on? efficient intermediate task selection. arXiv preprint arXiv:2104.08247.
+Yada Pruksachatkun, Jason Phang, Haokun Liu, Phu Mon Htut, Xiaoyi Zhang, Richard Yuanzhe Pang, Clara Vania, Katharina Kann, and Samuel R Bowman. 2020. Intermediate-task transfer learning with pretrained models for natural language understanding: When and why does it work? arXiv preprint arXiv:2005.00628.
+
+Alec Radford, Karthik Narasimhan, Tim Salimans, and Ilya Sutskever. 2018. Improving language understanding by generative pre-training.
+Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, Ilya Sutskever, et al. 2019. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J Liu. 2019. Exploring the limits of transfer learning with a unified text-to-text transformer. arXiv preprint arXiv:1910.10683.
+Pranav Rajpurkar, Robin Jia, and Percy Liang. 2018. Know what you don't know: Unanswerable questions for SQuAD. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 784-789. Association for Computational Linguistics.
+Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. 2016. SQuAD: $100,000+$ questions for machine comprehension of text. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2383-2392. Association for Computational Linguistics.
+Amrita Saha, Rahul Aralikatte, Mitesh M. Khapra, and Karthik Sankaranarayanan. 2018. DuoRC: Towards complex language understanding with paraphrased reading comprehension. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1683-1693. Association for Computational Linguistics.
+Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Ng, and Christopher Potts. 2013. Recursive deep models for semantic compositionality over a sentiment treebank. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, pages 1631-1642. Association for Computational Linguistics.
+Adam Trischler, Tong Wang, Xingdi Yuan, Justin Harris, Alessandro Sordoni, Philip Bachman, and Kaheer Suleman. 2017. NewsQA: A machine comprehension dataset. In Proceedings of the 2nd Workshop on Representation Learning for NLP, pages 191-200. Association for Computational Linguistics.
+Tu Vu, Brian Lester, Noah Constant, Rami Al-Rfou, and Daniel Cer. 2021. Spot: Better frozen model adaptation through soft prompt transfer. arXiv preprint arXiv:2110.07904.
+Tu Vu, Tong Wang, Tsendvarsen Munkhdalai, Alessandro Sordoni, Adam Trischler, Andrew Mattarella-Micke, Subhransu Maji, and Mohit Iyyer. 2020. Exploring and predicting transferability across NLP tasks. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 7882-7926. Association for Computational Linguistics.
+
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R. Bowman. 2019. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In 7th International Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019. OpenReview.net.
+Alex Warstadt, Amanpreet Singh, and Samuel R. Bowman. 2019. Neural network acceptability judgments. Transactions of the Association for Computational Linguistics, 7:625-641.
+Johannes Welbl, Pontus Stenetorp, and Sebastian Riedel. 2018. Constructing datasets for multi-hop reading comprehension across documents. Transactions of the Association for Computational Linguistics, 6:287-302.
+Adina Williams, Nikita Nangia, and Samuel Bowman. 2018. A broad-coverage challenge corpus for sentence understanding through inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 1112-1122. Association for Computational Linguistics.
+Zhilin Yang, Peng Qi, Saizheng Zhang, Yoshua Bengio, William Cohen, Ruslan Salakhutdinov, and Christopher D. Manning. 2018. HotpotQA: A dataset for diverse, explainable multi-hop question answering. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2369-2380. Association for Computational Linguistics.
+Elad Ben Zaken, Yoav Goldberg, and Shauli Ravfogel. 2022. Bitfit: Simple parameter-efficient fine-tuning for transformer-based masked language-models. In ACL, pages 1-9. Association for Computational Linguistics.
+
+# A List of Datasets
+
+| Task | |Train| |
| Text classification / Regression (CR) |
| SNLI (Bowman et al., 2015) | 570k |
| MNLI (Williams et al., 2018) | 393k |
| QQP (Iyer et al., 2017) | 364k |
| QNLI (Wang et al., 2019) | 105k |
| SST-2 (Socher et al., 2013) | 67k |
| SciTail (Khot et al., 2018) | 27k |
| CoLA (Warstadt et al., 2019) | 8.5k |
| STS-B (Cer et al., 2017) | 7k |
| MRPC (Dolan and Brockett, 2005) | 3.7k |
| RTE (Dagan et al., 2005) | 2.5k |
| WNLI (Levesque, 2011) | 634 |
| Question Answering (QA) |
| SQuAD-2 (Rajpurkar et al., 2018) | 162k |
| NewsQA (Trischler et al., 2017) | 120k |
| HotpotQA (Yang et al., 2018) | 113k |
| SQuAD-1 (Rajpurkar et al., 2016) | 108k |
| DuoRC-p (Saha et al., 2018) | 100k |
| DuoRC-s (Saha et al., 2018) | 86k |
| DROP (Dua et al., 2019) | 77k |
| WikiHop (Welbl et al., 2018) | 51k |
| BoolQ (Clark et al., 2019) | 16k |
| ComQA (Abujabal et al., 2019) | 11k |
| CQ (Bao et al., 2016) | 2k |
+
+Table 5: The datasets used in our experiments and their training set size (Vu et al., 2020).
\ No newline at end of file
diff --git a/efficientlytunedparametersaretaskembeddings/images.zip b/efficientlytunedparametersaretaskembeddings/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..9eb3036f29a4b3859a4b82431f78c4f2d4adb39e
--- /dev/null
+++ b/efficientlytunedparametersaretaskembeddings/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:37e6554b130d355865e43b95225e3eb2c24ef34ef54bc6e494002261c2be1745
+size 287802
diff --git a/efficientlytunedparametersaretaskembeddings/layout.json b/efficientlytunedparametersaretaskembeddings/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..c9faa7a93ba05b0a8acd0f6578fca3d5857c2162
--- /dev/null
+++ b/efficientlytunedparametersaretaskembeddings/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a0726978410dcb8e5a3d48b4a91acc4854ff5600a967e5de912b5e2baa4b34d0
+size 230661
diff --git a/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_content_list.json b/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..dd793620f9aad88a443412938192f3bfb6f2d415
--- /dev/null
+++ b/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:42abc6283d088708fa26d4dc0e5f81f66e867845d4a17f037c9e99d7f62403ae
+size 53988
diff --git a/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_model.json b/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..a3c461231c8e66ac2d1d8d9054527399b9b61b9e
--- /dev/null
+++ b/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:648eabad77ee6b888ec4ceb50c8ae4db53d1f4c08526e6bcd52211904068a048
+size 66180
diff --git a/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_origin.pdf b/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..7b3c6cf1eba0859edfea5b7f9f89cb9737b0e65d
--- /dev/null
+++ b/efficientnearestneighboremotionclassificationwithbertwhitening/e1e00af2-9c3a-45dc-8caa-af2d96b34987_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ca02f3ce786a6829870b7b5642eb49fc11bbb544e5a5f57e0b851d52898b557e
+size 8878129
diff --git a/efficientnearestneighboremotionclassificationwithbertwhitening/full.md b/efficientnearestneighboremotionclassificationwithbertwhitening/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..1419de9ca8d053af62894f12bd9e4162d0849a8b
--- /dev/null
+++ b/efficientnearestneighboremotionclassificationwithbertwhitening/full.md
@@ -0,0 +1,277 @@
+# Efficient Nearest Neighbor Emotion Classification with BERT-whitening
+
+Wenbiao Yin and Lin Shang*
+
+State Key Laboratory for Novel Software Technology
+
+Department of Computer Science and Technology
+
+Nanjing University, Nanjing, China
+
+wenbiaoyin@smail.nju.edu.cn, shanglin@nju.edu.cn
+
+# Abstract
+
+Retrieval-based methods have been proven effective in many NLP tasks. Previous methods use representations from the pre-trained model for similarity search directly. However, the sentence representations from the pre-trained model like BERT perform poorly in retrieving semantically similar sentences, resulting in poor performance of the retrieval-based methods. In this paper, we propose KNN-EC, a simple and efficient non-parametric emotion classification (EC) method using nearest neighbor retrieval. We use BERT-whitening to get better sentence semantics, ensuring that nearest neighbor retrieval works. Meanwhile, BERT-whitening can also reduce memory storage of datastore and accelerate retrieval speed, solving the efficiency problem of the previous methods. KNN-EC average improves the pre-trained model by 1.17 F1-macro on two emotion classification datasets.
+
+# 1 Introduction
+
+Retrieval-based methods enhance model performance by extracting textual information related to the input from large training data. The model interpolates the original model distribution and retrieved results' distribution as the final distribution for output. Retrieval-based methods can often improve the performance as the model is exposed to related knowledge not present in the input(Wang et al., 2022). Retrieval-based methods have been successfully applied to many tasks such as language modeling(Khandelwal et al., 2019; Guu et al., 2020), machine translation(Gu et al., 2018; Bapna and Firat, 2019; Khandelwal et al., 2020; Zheng et al., 2021), question answering(Chen et al., 2017; Lee et al., 2019), and computer vision(Devlin et al., 2015; Gur et al., 2021).
+
+Retrieval-based methods are expressive, adaptable, and interpretable. Here, we propose KNN-EC, a simple and efficient non-parametric emotion
+
+classification (EC) method using nearest neighbor retrieval. KNN-EC can be added to any pre-trained emotion classification model without further training. Pre-trained models such as BERT (Devlin et al., 2019), RoBERTa (Liu et al., 2019), XLNet (Yang et al., 2019) have been widely proven effective for emotion classification, and they obtain state-of-the-art results on many emotion classification tasks.
+
+However, the sentence representations from the pre-trained model like BERT perform poorly in retrieving semantically similar sentences(Reimers and Gurevych, 2019). Previous works found that pre-trained models always induced a non-smooth anisotropic semantic space of sentences, which harmed its performance of semantic similarity. To address this issue, Gao et al. (2018) designed a novel way to mitigate the degeneration problem by regularizing the word embedding matrix. Li et al. (2020) proposed to transform the BERT sentence embedding distribution into a smooth and isotropic Gaussian distribution through normalizing flow, an invertible function parameterized by the neural network. Because the above methods require additional parameters added to the neural network, this is not suitable to be added to KNN-EC to enhance the nearest neighbor retrieval.
+
+Here, we use BERT-whitening(Su et al., 2021), which utilizes a simple linear transformation to enhance the isotropy of sentence representations and achieve competitive results. The details of BERT-whitening are described in Section 2.2. We conduct experiments on two emotion classification datasets. KNN-EC can achieve 1.21-1.65/0.28-1.44 F1-macro scores improvements over pre-trained models on GoEmotions/ISEAR. Meanwhile, by adding the BERT-whitening, our approach can further boost the model performance, optimize memory storage and accelerate retrieval speed.
+
+The main contributions of this paper are summa
+
+
+Figure 1: An overview of the proposed KNN-EC. The datastore stores the hidden representations of each sentence in the training data as keys and their corresponding labels as values. We use whitening transformation to enhance the isotropy of sentence representations and dimension reduction to optimize memory storage and accelerate retrieval speed. In inference, we use the whitening transformation on the test sentence's representation to retrieve the k nearest neighbors from the datastore. We interpolate the model and kNN distributions with a hyper-parameter $\lambda$ as the final distribution.
+
+# rized as follows:
+
+- We propose KNN-EC, a non-parametric emotion classification method using nearest neighbor retrieval. KNN-EC is plug-and-play for any pre-trained emotion classification model without further training.
+- We utilize BERT-whitening to get better sentence semantics, ensuring the nearest neighbor retrieval works. Meanwhile, BERT-whitening can also optimize memory storage and accelerate retrieval speed.
+- The results demonstrate that KNN-EC average improves the pre-trained model by 1.17 F1-macro scores on two emotion classification datasets.
+
+# 2 Background
+
+In this section, we will briefly introduce the background of KNN-MT(Khandelwal et al., 2020) and BERT-whitening(Su et al., 2021).
+
+# 2.1 KNN-MT
+
+KNN-MT includes two steps: creating a datastore and inferring based on the datastore.
+
+# 2.1.1 Datastore Creation
+
+The datastore in KNN-MT stores the hidden representations of translation contexts as keys and their corresponding next tokens as values. Given a bilingual sentence pair in the training set $(x,y)\in (\mathcal{X},\mathcal{Y})$ , an MT model translates the $t$ -th target token $y_{t}$ based on the translation context $(x,y_{< t})$ . The key is $f(x,y_{< t})$ , where $f$ represents a mapping from input to an intermediate representation of the decoder and the value is $y_{t}$ . The representations are generated by a single forward pass over the training set $(\mathcal{X},\mathcal{Y})$ and the datastore is defined as follows:
+
+$$
+(\mathcal {K}, \mathcal {V}) = \bigcup_ {(x, y) \in (\mathcal {X}, \mathcal {Y})} \left\{\left(f (x, y _ {< t}), y _ {t}\right), \forall y _ {t} \in y \right\} \tag {1}
+$$
+
+# 2.1.2 Inference
+
+At test time, the KNN-MT model aims to predict $\hat{y}_t$ given the already generated tokens $\hat{y}_{< t}$ as well as the context representation $f(x,\hat{y}_{< t})$ , which is used to query the datastore for the k nearest neighbors according to L2 distance. Denoting the retrieved k nearest neighbors as $N^{t} = \{(h_{i},v_{i}),i\in \{1,2,\ldots ,k\} \}$ , their distribu
+
+tion over the vocabulary is computed as:
+
+$$
+\begin{array}{l} p _ {\mathrm {k N N}} \left(y _ {t} \mid x, \hat {y} _ {< t}\right) \propto \\ \sum_ {\left(h _ {i}, v _ {i}\right) \in N ^ {t}} \mathbb {1} _ {y _ {t} = v _ {i}} \exp \left(\frac {- d \left(h _ {i} , f (x , \hat {y} _ {< t})\right)}{T}\right) \tag {2} \\ \end{array}
+$$
+
+where $d(.,.)$ is an L2 distance function between the two vectors, and $T$ is the temperature. KNN-MT interpolates the MT model and kNN distributions with a hyper-parameter $\lambda$ :
+
+$$
+\begin{array}{l} p \left(y _ {t} \mid x, \hat {y} _ {< t}\right) = \lambda p _ {\mathrm {k N N}} \left(y _ {t} \mid x, \hat {y} _ {< t}\right) \tag {3} \\ + (1 - \lambda) p _ {\mathrm {M T}} \left(y _ {t} \mid x, \hat {y} _ {< t}\right) \\ \end{array}
+$$
+
+# 2.2 BERT-whitening
+
+BERT-whitening uses the whitening operation in traditional machine learning to enhance the isotropy of sentence representations and reduce the dimension of the sentence representation. BERTwhitening includes two steps: whitening transformation and dimension reduction.
+
+# 2.2.1 Whitening Transformation
+
+BERT-whitening transforms the mean value of the sentence vectors into 0 and the covariance matrix into the identity matrix. Given a set of row vectors $\{e_i\}_{i=1}^N$ , BERT-whitening transforms them into $\{\tilde{e}_i\}_{i=1}^N$ as:
+
+$$
+\tilde {\boldsymbol {e}} _ {i} = \left(\boldsymbol {e} _ {i} - \boldsymbol {\mu}\right) \boldsymbol {W} \tag {4}
+$$
+
+where the mean value $\mu = \frac{1}{N}\sum_{i = 1}^{N}e_{i}$ , and $W$ is the linear transformation that is solved later. The original covariance matrix $\Sigma$ is denoted as:
+
+$$
+\Sigma = \frac {1}{N} \sum_ {i = 1} ^ {N} \left(e _ {i} - \mu\right) ^ {T} \left(e _ {i} - \mu\right) \tag {5}
+$$
+
+The transformed covariance matrix $\widetilde{\Sigma} = W^T\Sigma W$ and $\widetilde{\Sigma} = I$ , therefore,
+
+$$
+\boldsymbol {\Sigma} = \left(\boldsymbol {W} ^ {\top}\right) ^ {- 1} \boldsymbol {W} ^ {- 1} = \left(\boldsymbol {W} ^ {- 1}\right) ^ {\top} \boldsymbol {W} ^ {- 1} \tag {6}
+$$
+
+$\Sigma$ satisfies the following form of SVD(Golub and Reinsch, 1971) decomposition:
+
+$$
+\Sigma = U \Lambda U ^ {T} \tag {7}
+$$
+
+where $U$ is an orthogonal matrix, $\Lambda$ is a diagonal matrix and the diagonal elements are all positive. Therefore, let $W^{-1} = \sqrt{\Lambda} U^T$ , we can obtain the solution:
+
+$$
+W = U \sqrt {\Lambda^ {- 1}} \tag {8}
+$$
+
+# 2.2.2 Dimension Reduction
+
+The elements in the diagonal matrix $\Lambda$ deriving from SVD have been sorted in descending order. We only need to retain the first $n$ columns of $W$ to achieve a dimension reduction effect, which is equivalent to PCA(Abdi and Williams, 2010). Here, $n$ is an empirical hyper-parameter, the details of algorithm implementation of BERT-whitening are shown in Algorithm 1.
+
+# Algorithm 1 Whitening-n Workflow
+
+Input: The original embeddings $\{e_i\}_{i=1}^N$ and reserved dimension $n$
+
+Output: Transformed embeddings $\{\widetilde{e}_i\}_{i=1}^N$
+
+1: compute $\mu$ and $\sum$ of $\{e_i\}_{i=1}^N$
+2: compute $U, \Lambda, U^T = \mathrm{SVD}(\Sigma)$
+3: compute $W = \left(U\sqrt{\Lambda^{-1}}\right)[:,n]$
+4: for $i = 1,2,\dots,N$ do
+5: $\widetilde{e}_i = (e_i - \mu)W$
+
+# 3 Nearest Neighbor Emotion Detection
+
+In this section, we will introduce the details of our proposed method, KNN-EC. We build the datastore as KNN-MT. Before that, we do whitening transformation and dimension reduction on the high-dimensional vector representations obtained from the model to get a better similarity search. In inference, the KNN-EC uses the nearest neighbor retrieval mechanism to enhance the pre-trained model without additional training. The overview of the proposed KNN-EC is shown in Figure 1.
+
+# 3.1 Datastore Creation
+
+Given a training set $(x,y)\in (\mathcal{X},\mathcal{Y})$ , a neural emotion classification model transforms the input sentence $x$ into a high-dimensional vector representation $e = f(x)$ , where $f$ represents a mapping from input to an intermediate representation of the neural emotion classification model.
+
+Then, we get the high-dimensional vector representation $\{e_i\}_{i=1}^N$ of all training inputs $\{x_i\}_{i=1}^N$ . We use BERT-whitening to enhance the isotropy of sentence representations and reduce the dimension of the sentence representation, the details of algorithm implementation of BERT-whitening are shown in Algorithm 1.
+
+$$
+\{\widetilde {e} _ {i} \} _ {i = 1} ^ {N} = \mathbf {W h i t e n i n g - n} (\{e _ {i} \} _ {i = 1} ^ {N}) \tag {9}
+$$
+
+| GoEmotions | Anger | Disgust | Fear | Joy | Sadness | Surprise | Total |
| Train | 3878 | 498 | 515 | 12920 | 2121 | 3553 | 23485 |
| Test | 520 | 76 | 77 | 1603 | 259 | 449 | 2984 |
+
+Table 1: The statistics of GoEmotions.
+
+| ISEAR | Anger | Disgust | Fear | Joy | Sadness | Shame | Guilt | Total |
| Train | 863 | 853 | 861 | 873 | 865 | 857 | 840 | 6012 |
| Test | 216 | 213 | 215 | 219 | 217 | 214 | 210 | 1504 |
+
+Table 2: The statistics of ISEAR.
+
+where $n$ is an empirical hyper-parameter to reduce the sentence representation's dimension and enhance the search results in the datastore.
+
+Our datastore is constructed offline and consists of a set of key-value pairs. The key is $\widetilde{e}_i$ , and the value is the corresponding ground truth $y_i$ . The datastore is defined as follows:
+
+$$
+(\mathcal {K}, \mathcal {V}) = \bigcup_ {(x, y) \in (\mathcal {X}, \mathcal {Y})} \left\{\left(\tilde {e} _ {i}, y _ {i}\right) \right\} \tag {10}
+$$
+
+# 3.2 Inference
+
+At test time, given a sentence $x$ , the pre-trained emotion classification model outputs a emotion distribution $p_{Model}(y|x)$ for target $y$ . The model also outputs the vector representation $e$ of $x$ . We do whitening transformation for $e$ by $\mu$ and $W$ calculated in Equation 9 as follows:
+
+$$
+\tilde {e} = (e - \mu) W \tag {11}
+$$
+
+$\widetilde{e}$ is used to query the datastore for the $k$ nearest neighbors $\mathcal{M}$ according to L2 distance, $d(.,.)$ , which is the same as Equation 2.
+
+$$
+p _ {\mathrm {k N N}} (y \mid x) \propto \sum_ {(k _ {i}, v _ {i}) \in \mathcal {M}} \mathbb {1} _ {y = v _ {i}} \exp \left(\frac {- d \left(k _ {i} , \widetilde {e}\right)}{T}\right) \tag {12}
+$$
+
+where $T$ is the temperature. We interpolate the pre-trained emotion classification model and kNN distributions with a hyper-parameter $\lambda$ :
+
+$$
+\begin{array}{r l} p (y \mid x) & = \lambda p _ {\mathrm {k N N}} (y \mid x) \\ & + (1 - \lambda) p _ {\text {M o d e l}} (y \mid x) \end{array} \tag {13}
+$$
+
+# 4 Experiment
+
+# 4.1 Datasets and Evaluation Metrics
+
+We evaluate our model on two datasets: GoEmotions and ISEAR.
+
+GoEmotions(Demszky et al., 2020) was published by Google for fine-grained emotions classification. GoEmotions is the largest manually annotated dataset of 58k English Reddit comments, labeled for 27 emotion categories or Neutral. Here, we filter the sentences with Neutral labels or multiple labels. We adopt Ekman-style(Ekman, 1992) grouping into six coarse categories(joy, anger, fear, sadness, disgust, and surprise). The statistics of GoEmotions are shown in Table 1.
+
+ISEAR(Scherer and Wallbott, 1994)(International Survey on Emotion Antecedents and Reactions) collected personal reports on emotional events written by 3000 people from different cultural backgrounds. ISEAR contains 7k sentences that are labeled into seven categories(anger, disgust, fear, guilt, joy, sadness, and shame). The statistics of ISEAR are shown in Table 2.
+
+Here, we use F1-macro(Opitz and Burst, 2019) to measure all results.
+
+# 4.2 Implementation Details
+
+Considering the generalization, we conduct experiments on the popular pre-trained models, such as BERT, RoBERTa, and XLNet. We fine-tune the pre-trained models from Transformers library $^2$ and adopt faiss $^3$ to implement our model. For our method, the temperature $T$ is set to 2. We set the batch size of this model as 64 and use the AdamW optimizer and the learning rate warm-up where the learning rate is 2e-5.
+
+# 4.3 Overall Results
+
+Experimental results are shown in Table 3. The results in the table are the average of 5 repeated experiments. According to the results, several observations can be noted.
+
+| Dataset | GoEmotions | ISEAR |
| Model | pModel | pkNN | p | pModel | pkNN | p |
| bert-base | 71.13 | 71.55 | 72.71↑1.58 | 69.18 | 69.28 | 69.46↑0.28 |
| bert-large | 71.64 | 72.23 | 72.85↑1.21 | 70.20 | 70.47 | 70.94↑0.74 |
| xlnet-base | 71.31 | 71.81 | 72.77↑1.46 | 68.39 | 69.66 | 69.83↑1.44 |
| roberta-base | 71.86 | 72.39 | 73.51↑1.65 | 69.36 | 70.40 | 70.68↑1.32 |
| roberta-large | 73.01 | 74.10 | 74.51↑1.50 | 73.09 | 73.12 | 73.56↑0.47 |
| μ | 71.79 | 72.42 | 73.27↑1.48 | 70.04 | 70.59 | 70.89↑0.85 |
+
+Table 3: The F1-macro scores of the pre-trained model $(p_{Model})$ and k nearest neighbor $(p_{kNN})$ and the proposed KNN-EC model $(p)$ . Underline results indicate the best results of baselines, and our best results are marked bold. The red numbers indicate the magnitude of our model effect improvement. $\mu$ indicates the mean value of results among different pre-trained models.
+
+
+Figure 2: Visualization of sentence representations on GoEmotions. (a) uses sentence representations from the fine-tuned RoBERTa without BERT-whitening, while (b) uses RoBERTa with BERT-whitening.
+
+
+
+$\mathbf{p}_{kNN}$ with BERT-whitening is always better than $\mathbf{p}_{\mathrm{Model}}$ . It is a fascinating phenomenon: why non-parametric method using nearest neighbor retrieval is better than the well-trained linear classifier? Because BERT always induces a non-smooth anisotropic semantic space of sentences, BERT-whitening can boost the isotropy of sentence distribution. It makes $p_{kNN}$ with BERT-whitening is always better than $p_{Model}$ .
+
+KNN-EC average improves the pre-trained models by 1.17 F1-macro on two emotion classification datasets. KNN-EC can achieve 1.21-1.65/0.28-1.44 F1-macro improvements over pretrained models on GoEmotions/ISEAR.
+
+The more data available for retrieval, the better our model works. The effectiveness of KNN-EC depends on the quality of retrieved nearest neighbors. The quality of retrieved nearest neighbors depends on the amount of data available for retrieval. $p_{kNN}$ average achieves 0.63/0.55 F1-macro improvements over $p_{Model}$ . The KNN-EC's improvement is more pronounced on larger datas
+
+tore.
+
+# 4.4 The Effectiveness of BERT-whitening
+
+From Table 4, we can see $p_{kNN}$ with BERT-whitening average improves the 11.77/12.11 F1-macro over $p_{kNN}$ without BERT-whitening on GoEmotions/ISEAR. The sentence representations from the pre-trained model perform poorly in retrieving semantically similar sentences while perform well with BERT-whitening. Besides, $p_{kNN}$ without BERT-whitening is very unstable, whose results are much lower than $p_{Model}$ and the standard deviation( $\mu$ ) equals 7.56/9.81 on GoEmotions/ISEAR. While $p_{kNN}$ with BERT-whitening is not only stable $(\mu = 0.89 / 1.35)$ but also better than $p_{Model}$ .
+
+To demonstrate the effectiveness of our method, we further visualize the sentence representations from RoBERTa on GoEmotions, where RoBERTa achieves the best performance. From Figure 2, sentence representations in the sadness category almost overlap with sentence representations in
+
+| Dataset | GoEmotions | ISEAR |
| Model | pkNN-BW | pkNN+BW | pkNN-BW | pkNN+BW |
| bert-base | 66.79 | 71.55↑4.76 | 58.03 | 69.28↑11.25 |
| bert-large | 50.64 | 72.23↑21.59 | 40.24 | 70.47↑30.23 |
| xlnet-base | 67.72 | 71.81↑4.09 | 66.65 | 69.66↑3.01 |
| roberta-base | 52.24 | 72.39↑20.15 | 60.12 | 70.40↑10.28 |
| roberta-large | 65.85 | 74.10↑8.25 | 67.34 | 73.12↑5.78 |
| μ | 60.65 | 72.42↑11.77 | 58.48 | 70.59↑12.11 |
| σ | 7.56 | 0.89 | 9.81 | 1.35 |
+
+Table 4: The F1-macro scores of the k nearest neighbors $(p_{kNN})$ without/with BERT-whitening on GoEmotions and ISEAR. We use the following abbreviations. BW for BERT-whitening, - for without and + for with. $\mu/\sigma$ indicates the mean value/standard deviation of results among different pre-trained models.
+
+| Whitening-n | 8 | 16 | 32 | 64 | 128 | 256 | default |
| bert-base | 70.64 | 71.62 | 71.73 | 72.06 | 72.11 | 72.71 | 70.52 |
| xlnet-base | 71.35 | 72.20 | 72.77 | 71.28 | 71.90 | 72.09 | 70.43 |
| roberta-base | 72.27 | 72.05 | 72.53 | 73.05 | 73.51 | 72.66 | 59.22 |
| Datastore size | 0.01× | 0.02× | 0.04× | 0.08× | 0.17× | 0.33× | 1× |
| bert-large | 72.85 | 71.16 | 72.06 | 71.96 | 71.74 | 71.85 | 71.73 |
| roberta-large | 73.01 | 72.64 | 74.09 | 74.11 | 74.51 | 74.06 | 73.32 |
| Datastore size | 0.01× | 0.02× | 0.03× | 0.06× | 0.13× | 0.25× | 1× |
+
+Table 5: The F1-macro scores of KNN-EC among different Whitening-ns. Underline results indicate the worst results of KNN-EC for each pre-trained model, and the best results are marked bold. The default means using the same dimension as the pre-trained model's outputs without dimension reduction.
+
+the surprise category, seriously affecting the nearest neighbor retrieval result. After adding BERT-whitening, the sentence representations of sadness and surprise are separated.
+
+Retrieval-based methods generally have significant storage overhead and inference overhead. From Table 5, BERT-whitening not only improves the model's performance but also significantly reduces the memory storage of the datastore (more than $10 \times$ ). Meanwhile, with the datastore size reduced, the retrieval speed is also greatly accelerated, significantly decreasing the inference overhead and erasing the limitation of non-parametric KNN-EC in practical applications.
+
+# 4.5 Performance with Different $k$
+
+As shown in Figure 3, as $p_{Model}$ performs better, KNN-EC tends to select larger $k$ , and retrieve more relevant sentences to improve performance, such as bert-large, roberta-base, roberta-large. While $p_{Model}$ performs relatively poorly, selecting a larger $k$ will introduce more noise, so it tends to select a small $k$ , such as bert-base, xlnet-base.
+
+
+Figure 3: The F1-macro scores of KNN-EC among different $ks$
+
+# 5 Conclusion
+
+In this paper, we propose a simple and effective method using nearest neighbor retrieval that can be applied to many emotion classification models without further training. Meanwhile, we reduce memory storage of datastore and accelerate retrieval speed, significantly decreasing the inference overhead and erasing the limitation of non
+
+parametric KNN-EC in practical applications. Experimental results show that our proposed model achieves significant improvement.
+
+# Limitations
+
+There are two major limitations in this study that could be addressed in future research. First, the study focused on using the sentence representations from the pre-trained model for nearest neighbor retrieval. We did not study whether KNN-EC works on the other models. Second, the results retrieved from the training set may suffer from dataset bias.
+
+# Acknowledgements
+
+This work is supported by the National Natural Science Foundation of China (No.51975294).
+
+# References
+
+Herve Abdi and Lynne J Williams. 2010. Principal component analysis. Wiley interdisciplinary reviews: computational statistics, 2(4):433-459.
+Ankur Bapna and Orhan First. 2019. Non-parametric adaptation for neural machine translation. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 1921-1931.
+Danqi Chen, Adam Fisch, Jason Weston, and Antoine Bordes. 2017. Reading wikipedia to answer open-domain questions. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1870-1879.
+Dorottya Demszky, Dana Movshovitz-Attias, Jeongwoo Ko, Alan Cowen, Gaurav Nemade, and Sujith Ravi. 2020. Goemotions: A dataset of fine-grained emotions. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 4040-4054.
+Jacob Devlin, Ming Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. *NAACL HLT* 2019 - 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies - Proceedings of the Conference, 1(Mlm):4171-4186.
+Jacob Devlin, Saurabh Gupta, Ross Girshick, Margaret Mitchell, and C Lawrence Zitnick. 2015. Exploring nearest neighbor approaches for image captioning. arXiv preprint arXiv:1505.04467.
+P Ekman. 1992. Are there basic emotions? Psychological review, 99(3):550-553.
+
+Jun Gao, Di He, Xu Tan, Tao Qin, Liwei Wang, and Tieyan Liu. 2018. Representation degeneration problem in training natural language generation models. In International Conference on Learning Representations.
+Gene H Golub and Christian Reinsch. 1971. Singular value decomposition and least squares solutions. In Linear algebra, pages 134-151. Springer.
+Jiatao Gu, Yong Wang, Kyunghyun Cho, and Victor OK Li. 2018. Search engine guided neural machine translation. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32.
+Shir Gur, Natalia Neverova, Chris Stauffer, Ser-Nam Lim, Douwe Kiela, and Austin Reiter. 2021. Cross-modal retrieval augmentation for multi-modal classification. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 111-123.
+Kelvin Guu, Kenton Lee, Zora Tung, Panupong Pasupat, and Mingwei Chang. 2020. Retrieval augmented language model pre-training. In International Conference on Machine Learning, pages 3929-3938. PMLR.
+Urvashi Khandelwal, Angela Fan, Dan Jurafsky, Luke Zettlemoyer, and Mike Lewis. 2020. Nearest neighbor machine translation. In International Conference on Learning Representations.
+Urvashi Khandelwal, Omer Levy, Dan Jurafsky, Luke Zettlemoyer, and Mike Lewis. 2019. Generalization through memorization: Nearest neighbor language models. In International Conference on Learning Representations.
+Kenton Lee, Ming-Wei Chang, and Kristina Toutanova. 2019. Latent retrieval for weakly supervised open domain question answering. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6086-6096.
+Bohan Li, Hao Zhou, Junxian He, Mingxuan Wang, Yiming Yang, and Lei Li. 2020. On the sentence embeddings from pre-trained language models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 9119-9130.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Juri Opitz and Sebastian Burst. 2019. Macro f1 and macro f1. arXiv preprint arXiv:1911.03347.
+Nils Reimers and Iryna Gurevych. 2019. Sentence-bert: Sentence embeddings using siamese bert-networks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3982-3992.
+
+Klaus R Scherer and Harald G Wallbott. 1994. Evidence for universality and cultural variation of differential emotion response patterning. Journal of personality and social psychology, 66(2):310.
+Jianlin Su, Jiarun Cao, Weijie Liu, and Yangyiwen Ou. 2021. Whitening sentence representations for better semantics and faster retrieval. arXiv preprint arXiv:2103.15316.
+Shuohang Wang, Yichong Xu, Yuwei Fang, Yang Liu, Siqi Sun, Ruochen Xu, Chenguang Zhu, and Michael Zeng. 2022. Training data is more valuable than you think: A simple and effective method by retrieving from training data. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 3170-3179.
+Zhilin Yang, Zihang Dai, Yiming Yang, Jaime Carbonell, Russ R Salakhutdinov, and Quoc V Le. 2019. Xlnet: Generalized autoregressive pretraining for language understanding. Advances in neural information processing systems, 32.
+Xin Zheng, Zhirui Zhang, Junliang Guo, Shujian Huang, Boxing Chen, Weihua Luo, and Jiajun Chen. 2021. Adaptive nearest neighbor machine translation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 368-374.
\ No newline at end of file
diff --git a/efficientnearestneighboremotionclassificationwithbertwhitening/images.zip b/efficientnearestneighboremotionclassificationwithbertwhitening/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..3b92c3de34d726c520dbc7a03c3b6b6f09545962
--- /dev/null
+++ b/efficientnearestneighboremotionclassificationwithbertwhitening/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d84bc5220028295683acfc8864e450835340225c656d2aca25557dc468f037c4
+size 446946
diff --git a/efficientnearestneighboremotionclassificationwithbertwhitening/layout.json b/efficientnearestneighboremotionclassificationwithbertwhitening/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..607a659f1a92e0a2272c5d9025a2f2a5da8b46c8
--- /dev/null
+++ b/efficientnearestneighboremotionclassificationwithbertwhitening/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bec500273e5818195774e592bf3e3e8948c7a6846d137f8881ee4cf8282f5739
+size 305557
diff --git a/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_content_list.json b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..60e94d29e7b09bbd0a4f574d06207b3a66477ed5
--- /dev/null
+++ b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:efac7cd4400191e6d96f1255fe41195ab1d98ebc7ddf1cbcc74cc8cc263551d4
+size 135944
diff --git a/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_model.json b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..a56ab66192d66fdb5ea66147c6f5e0cb6af0d9c6
--- /dev/null
+++ b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:56fed7fe3d1af491a3e35d9754af64adfae5372fc72f4d518e1f81b9bf767a53
+size 168690
diff --git a/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_origin.pdf b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..e3a1fa8ebe69643b290ee867992aa94fba55665d
--- /dev/null
+++ b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/c331b530-faba-424c-a25a-fdf39d6f7c47_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ea7b990af84f79a44c6cbd60aab7183bb22ef40fb34e592d951362b5f5e07626
+size 2242820
diff --git a/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/full.md b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..ce2c5fc5256e1072d06a8c557c35d48d1074a16e
--- /dev/null
+++ b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/full.md
@@ -0,0 +1,589 @@
+# Efficient Nearest Neighbor Search for Cross-Encoder Models using Matrix Factorization
+
+Nishant Yadav†, Nicholas Monath‡, Rico Angell†, Manzil Zaheer‡, and Andrew McCallum†
+
+† University of Massachusetts Amherst ‡ Google Research {nishantyadav, rangell, mccallum}@cs.umass.edu {nmonath,manzilzaheer}@google.com
+
+# Abstract
+
+Efficient $k$ -nearest neighbor search is a fundamental task, foundational for many problems in NLP. When the similarity is measured by dot-product between dual-encoder vectors or $\ell_2$ -distance, there already exist many scalable and efficient search methods. But not so when similarity is measured by more accurate and expensive black-box neural similarity models, such as cross-encoders, which jointly encode the query and candidate neighbor. The cross-encoders' high computational cost typically limits their use to reranking candidates retrieved by a cheaper model, such as dual encoder or TF-IDF. However, the accuracy of such a two-stage approach is upper-bounded by the recall of the initial candidate set, and potentially requires additional training to align the auxiliary retrieval model with the cross-encoder model. In this paper, we present an approach that avoids the use of a dual-encoder for retrieval, relying solely on the cross-encoder. Retrieval is made efficient with CUR decomposition, a matrix decomposition approach that approximates all pairwise cross-encoder distances from a small subset of rows and columns of the distance matrix. Indexing items using our approach is computationally cheaper than training an auxiliary dual-encoder model through distillation. Empirically, for $k > 10$ , our approach provides test-time recall-vs-computational cost trade-offs superior to the current widely-used methods that re-rank items retrieved using a dual-encoder or TF-IDF.
+
+# 1 Introduction
+
+Finding top- $k$ scoring items for a given query is a fundamental sub-routine of recommendation and information retrieval systems (Kowalski, 2007; Das et al., 2017). For instance, in question answering systems, the query corresponds to a question and the item corresponds to a document or a passage. Neural networks are widely used to model the similarity between a query and an item in such applications (Zamani et al., 2018; Hofstätter et al.,
+
+2019; Karpukhin et al., 2020; Qu et al., 2021). In this work, we focus on efficient $k$ -nearest neighbor search for one such similarity function - the cross-encoder model.
+
+Cross-encoder models output a scalar similarity score by jointly encoding the query-item pair and often generalize better to new domains and unseen data (Chen et al., 2020; Wu et al., 2020; Thakur et al., 2021) as compared to dual-encoder $^1$ models which independently embed the query and the item in a vector space, and use simple functions such as dot-product to measure similarity. However, due to the black-box nature of the cross-encoder based similarity function, the computational cost for brute force search with cross-encoders is prohibitively high. This often limits the use of cross-encoder models to re-ranking items retrieved using a separate retrieval model such as a dual-encoder or a TF-IDF-based model (Logeswaran et al., 2019; Zhang and Stratos, 2021; Qu et al., 2021). The accuracy of such a two-stage approach is upper bounded by the recall of relevant items by the initial retrieval model. Much of recent work either attempts to distill information from an expensive but more expressive cross-encoder model into a cheaper student model such as a dual-encoder (Wu et al., 2020; Hofstätter et al., 2020; Lu et al., 2020; Qu et al., 2021; Liu et al., 2022), or focuses on cheaper alternatives to the cross-encoder model while attempting to capture fine-grained interactions between the query and the item (Humeau et al., 2020; Khattab and Zaharia, 2020; Luan et al., 2021).
+
+In this work, we tackle the fundamental task of efficient $k$ -nearest neighbor search for a given query according to the cross-encoder. Our proposed approach, ANNCUR, uses CUR decomposition (Mahoney and Drineas, 2009), a matrix factorization approach, to approximate cross-encoder scores for all items, and retrieves $k$ -nearest neighbor items while only making a small number of
+
+
+Figure 1: Model architecture and score distribution for three neural scoring functions. Dual-Encoders (DE) score a query-item pair using independently computed query and item embeddings. [CLS]-CE computes the score by jointly encoding the query-item pair followed by passing the joint query-item embedding through a linear layer. Our proposed [EMB]-CE embeds special tokens amongst query and item tokens, and computes the query-item score using query and item embeddings extracted using the special tokens after jointly encoding the query-item pair.
+
+calls to the cross-encoder. Our proposed method selects a fixed set of anchor queries and anchor items, and uses scores between anchor queries and all items to generate latent embeddings for indexing the item set. At test time, we generate latent embedding for the query using cross-encoder scores for the test query and anchor items, and use it to approximate scores of all items for the given query and/or retrieve top- $k$ items according to the approximate scores. In contrast to distillation-based approaches, our proposed approach does not involve any additional compute-intensive training of a student model such as dual-encoder via distillation.
+
+In general, the performance of a matrix factorization-based method depends on the rank of the matrix being factorized. In our case, the entries of the matrix are cross-encoder scores for query-item pairs. To further improve rank of the score matrix, and in-turn performance of the proposed matrix factorization based approach, we propose [EMB]-CE which uses a novel dot-product based scoring mechanism for cross-encoder models (see Figure 1a). In contrast to the widely used [CLS]-CE approach of pooling query-item representation into a single vector followed by scoring using a linear layer, [EMB]-CE produces a score matrix with a much lower rank while performing at par with [CLS]-CE on the downstream task.
+
+We run extensive experiments with cross-encoder models trained for the downstream task of entity linking. The query and item in this case correspond to a mention of an entity in text and a document with an entity description respectively. For the task of retrieving $k$ -nearest neighbors according to the cross-encoder, our proposed approach presents superior recall-vs-computational
+
+cost trade-offs over using dual-encoders trained via distillation as well as over unsupervised TF-IDF-based methods (§3.2). We also evaluate the proposed method for various indexing and test-time cost budgets as well as study the effect of various design choices in §3.3 and §3.4.
+
+# 2 Matrix Factorization for Nearest Neighbor Search
+
+# 2.1 Task Description and Background
+
+Given a scoring function $f_{\theta}:\mathcal{Q}\times \mathcal{I}\to \mathbb{R}$ that maps a query-item pair to a scalar score, and a query $q\in \mathcal{Q}$ , the $k$ -nearest neighbor task is to retrieve top- $k$ scoring items according to the given scoring function $f_{\theta}$ from a fixed item set $\mathcal{I}$ .
+
+In NLP, queries and items are typically represented as a sequence of tokens and the scoring function is typically parameterized using deep neural models such as transformers (Vaswani et al., 2017). There are two popular choices for the scoring function - the cross-encoder (CE) model, and the dual-encoder (DE) model. The CE model scores a given query-item pair by concatenating the query and the item using special tokens, passing them through a model (such as a transformer $\mathcal{T}$ ) to obtain representation for the input pair followed by computing the score using linear weights $w \in \mathbb{R}^d$ .
+
+$$
+f _ {\theta} ^ {(\mathrm {C E})} (q, i) = w ^ {\top} \operatorname {p o o l} (\mathcal {T} (\operatorname {c o n c a t} (q, i)))
+$$
+
+While effective, computing a similarity between a query-item pair requires a full forward pass of the model, which is often quite computationally burdensome. As a result, previous work uses auxiliary retrieval models such as BM25 (Robertson et al., 1995) or a trained dual-encoder (DE) model to approximate the CE. The DE model independently
+
+
+Figure 2: CUR decomposition of a matrix $(M_{\mathrm{comb}} = \left[ \begin{array}{c} M_{\mathrm{anc}} \\ M_{\mathrm{test}} \end{array} \right])$ using a subset of its columns $(C_{\mathrm{comb}} = \left[ \begin{array}{c} C_{\mathrm{anc}} \\ C_{\mathrm{test}} \end{array} \right])$ and rows $(R_{\mathrm{anc}})$ . The blue rows $(R_{\mathrm{anc}})$ corresponding to the anchor queries and $U = C_{\mathrm{anc}}^{\dagger}$ are used for indexing the items to obtain item embeddings $E^{\mathcal{I}} = U \times R_{\mathrm{anc}}$ and the green row corresponds to the test query. Note that the test row $(M_{\mathrm{test}})$ can be approximated using a subset of its columns $(C_{\mathrm{test}})$ and the latent representation of items $(E^{\mathcal{I}})$ .
+
+embeds the query and the item in $\mathbb{R}^d$ , for instance by using a transformer $\mathcal{T}$ followed by pooling the final layer representations into a single vector (e.g. using CLS token). The DE score for the query-item pair is computed using dot-product of the query embedding and the item embedding.
+
+$$
+f _ {\theta} ^ {(\mathrm {D E})} (q, i) = \mathsf {p o o l} (\mathcal {T} (q)) ^ {\top} \mathsf {p o o l} (\mathcal {T} (i))
+$$
+
+In this work, we propose a method based on CUR matrix factorization that allows efficient retrieval of top- $k$ items by directly approximating the cross-encoder model rather than using an auxiliary (trained) retrieval model.
+
+CUR Decomposition (Mahoney and Drineas, 2009) In CUR matrix factorization, a matrix $M \in \mathbb{R}^{n \times m}$ is approximated using a subset of its rows $R = M[S_r,:] \in \mathbb{R}^{k_1 \times m}$ , a subset of its columns $C = M[:,S_c] \in \mathbb{R}^{n \times k_2}$ and a joining matrix $U \in \mathbb{R}^{k_2 \times k_1}$ as follows
+
+$$
+\tilde {M} = C U R
+$$
+
+where $S_{r}$ and $S_{c}$ are the indices corresponding to rows $R$ and columns $C$ respectively, and the joining matrix $U$ optimizes the approximation error. In this work, we set $U$ to be the Moore-Penrose pseudo-inverse of $M[S_{r},S_{c}]$ , the intersection of matrices $C$ and $R$ , in which case $\tilde{M}$ is known as the skeleton approximation of $M$ (Goreinov et al., 1997).
+
+# 2.2 Proposed Method Overview
+
+Our proposed method ANNCUR, which stands for Approximate Nearest Neighbor search using CUR decomposition, begins by selecting a fixed set of $k_{q}$ anchor queries $(Q_{\mathrm{anc}})$ and $k_{i}$ anchor items $(\mathcal{I}_{\mathrm{anc}})$ .
+
+It uses scores between queries $q \in Q_{\mathrm{anc}}$ and all items $i \in \mathcal{I}$ to index the item set by generating latent item embeddings. At test time, we compute exact scores between the test query $q_{\mathrm{test}}$ and the anchor items $\mathcal{I}_{\mathrm{anc}}$ , and use it to approximate scores of all items for the given query and/or retrieve top- $k$ items according to the approximate scores. We could optionally retrieve $k_r > k$ items, re-rank them using exact $f_{\theta}$ scores and return top- $k$ items.
+
+Let $M_{\mathrm{comb}} = \left[ \begin{array}{c}M_{\mathrm{anc}}\\ M_{\mathrm{test}} \end{array} \right]$ and $C_\mathrm{comb} = \left[ \begin{array}{c}C_{\mathrm{anc}}\\ C_{\mathrm{test}} \end{array} \right]$ where $M_{\mathrm{anc}} = R_{\mathrm{anc}}\in \mathbb{R}^{k_q\times |\mathcal{I}|}$ contains scores for the anchor queries and all items, $M_{\mathrm{test}}\in \mathbb{R}^{1\times |\mathcal{I}|}$ contains scores for a test query and all items, $C_{\mathrm{anc}}\in \mathbb{R}^{k_q\times k_i}$ contains scores for the anchor queries and the anchor items, and $C_{\mathrm{test}}\in \mathbb{R}^{1\times k_i}$ contains scores for the test query paired with the anchor items.
+
+Using CUR decomposition, we can approximate $M_{\mathrm{comb}}$ using a subset of its columns ( $C_{\mathrm{comb}}$ ) corresponding to the anchor items and a subset of its rows ( $R_{\mathrm{anc}}$ ) corresponding to the anchor queries as
+
+$$
+\tilde {M} _ {\text {c o m b}} = C _ {\text {c o m b}} U R _ {\text {a n c}}
+$$
+
+$$
+\left[ \begin{array}{c} \tilde {M} _ {\text {a n c}} \\ \tilde {M} _ {\text {t e s t}} \end{array} \right] = \left[ \begin{array}{c} C _ {\text {a n c}} \\ C _ {\text {t e s t}} \end{array} \right] U R _ {\text {a n c}}
+$$
+
+$$
+\tilde {M} _ {\text {a n c}} = C _ {\text {a n c}} U R _ {\text {a n c}} \text {a n d} \tilde {M} _ {\text {t e s t}} = C _ {\text {t e s t}} U R _ {\text {a n c}}
+$$
+
+Figure 2 shows CUR decomposition of matrix $M_{\mathrm{comb}}$ . At test time, $\tilde{M}_{\mathrm{test}}$ containing approximate item scores for the test query can be computed using $C_{\mathrm{test}}$ , $U$ , and $R_{\mathrm{anc}}$ where $C_{\mathrm{test}}$ contains exact $f_{\theta}$ scores between the test query and the anchor items. Matrices $U$ and $R_{\mathrm{anc}}$ can be computed offline as these are independent of the test query.
+
+# 2.3 Offline Indexing
+
+The indexing process first computes $R_{\mathrm{anc}}$ containing scores between the anchor queries and all items.
+
+$$
+R _ {\mathrm {a n c}} (q, i) = f _ {\theta} (q, i), \forall (q, i) \in \mathcal {Q} _ {\mathrm {a n c}} \times \mathcal {I}
+$$
+
+We embed all items in $\mathbb{R}^{k_i}$ as
+
+$$
+E ^ {\mathcal {I}} = U \times R _ {\mathrm {a n c}}
+$$
+
+where $U = C_{\mathrm{anc}}^{\dagger}$ is the pseudo-inverse of $C_{\mathrm{anc}}$ . Each column of $E^{\mathcal{I}} \in \mathbb{R}^{k_i \times |\mathcal{I}|}$ corresponds to a latent item embedding.
+
+# 2.4 Test-time Inference
+
+At test time, we embed the test query $q$ in $\mathbb{R}^{k_i}$ using scores between $q$ and anchor items $\mathcal{I}_{\mathrm{anc}}$ .
+
+$$
+e _ {q} = \left[ f _ {\theta} (q, i) \right] _ {i \in \mathcal {I} _ {\mathrm {a n c}}}
+$$
+
+We approximate the score for a query-item pair $(q,i)$ using inner-product of $e_q$ and $E^{\mathcal{I}}[:,i]$ where $E^{\mathcal{I}}[:,i] \in \mathbb{R}^{k_i}$ is the embedding of item $i$ .
+
+$$
+\hat {f} _ {\boldsymbol {\theta}} (\boldsymbol {q}, i) = e _ {q} ^ {\top} E ^ {\mathcal {I}} [:, i ]
+$$
+
+We can use $e_{q} \in \mathbb{R}^{k_{i}}$ along with an off-the-shelf nearest-neighbor search method for maximum inner-product search (Malkov and Yashunin, 2018; Johnson et al., 2019; Guo et al., 2020) and retrieve top-scoring items for the given query $q$ according to the approximate query-item scores without explicitly approximating scores for all the items.
+
+# 2.5 Time Complexity
+
+During indexing stage, we evaluate $f_{\theta}$ for $k_{q}|\mathcal{I}|$ query-item pairs, and compute the pseudo-inverse of a $k_{q} \times k_{i}$ matrix. The overall time complexity of the indexing stage is $\mathcal{O}(\mathcal{C}_{f_{\theta}}k_q|\mathcal{I}| + \mathcal{C}_{\mathrm{inv}}^{k_q,k_i})$ , where $\mathcal{C}_{\mathrm{inv}}^{k_q,k_i}$ is the cost of computing the pseudo-inverse of a $k_{q} \times k_{i}$ matrix, and $\mathcal{C}_{f_{\theta}}$ is the cost of computing $f_{\theta}$ on a query-item pair. For CE models used in this work, we observe that $\mathcal{C}_{f_{\theta}}k_q|\mathcal{I}| \gg \mathcal{C}_{\mathrm{inv}}^{k_q,k_i}$ .
+
+At test time, we need to compute $f_{\theta}$ for $k_{i}$ query-item pairs followed by optionally re-ranking $k_{r}$ items retrieved by maximum inner-product search (MIPS). Overall time complexity for inference is $\mathcal{O}\Big((k_i + k_r)\mathcal{C}_{f_\theta} + \mathcal{C}_{\mathrm{MIPS}}^{|\mathcal{I}|,k_r}\Big)$ , where $\mathcal{O}(\mathcal{C}_{\mathrm{MIPS}}^{|\mathcal{I}|,k_r})$ is the time complexity of MIPS over $|\mathcal{I}|$ items to retrieve top- $k_{r}$ items.
+
+# 2.6 Improving score distribution of CE models for matrix factorization
+
+The rank of the query-item score matrix, and in turn, the approximation error of a matrix factorization method depends on the scores in the matrix. Figure 1b shows a histogram of query-item
+
+score distribution (adjusted to have zero mean) for a dual-encoder and [CLS]-CE model. We use [CLS]-CE to refer to a cross-encoder model parameterized using transformers which uses CLS token to compute a pooled representation of the input query-item pair. Both the models are trained for zero-shot entity linking (see §3.1 for details). As shown in the figure, the query-item score distribution for the [CLS]-CE model is significantly skewed with only a small fraction of items (entities) getting high scores while the score distribution for a dual-encoder model is less so as it is generated explicitly using dot-product of query and item embeddings. The skewed score distribution from [CLS]-CE leads to a high rank query-item score matrix, which results in a large approximation error for matrix decomposition methods.
+
+We propose a small but important change to the scoring mechanism of the cross-encoder so that it yields a less skewed score distribution, thus making it much easier to approximate the corresponding query-item score matrix without adversely affecting the downstream task performance. Instead of using CLS token representation to score a given query-item pair, we add special tokens amongst the query and the item tokens and extract contextualized query and item representations using the special tokens after jointly encoding the query-item pair using a model such as a transformer $\mathcal{T}$ .
+
+$$
+e _ {q} ^ {\mathrm {C E}}, e _ {i} ^ {\mathrm {C E}} = \operatorname {p o o l} (\mathcal {T} (\operatorname {c o n c a t} (q, i)))
+$$
+
+The final score for the given query-item pair is computed using dot-product of the contextualized query and item embeddings.
+
+$$
+f _ {\theta} ^ {(\left[ \mathrm {E M B} \right] - \mathrm {C E})} (q, i) = \left(e _ {q} ^ {\mathrm {C E}}\right) ^ {\top} e _ {i} ^ {\mathrm {C E}}
+$$
+
+We refer to this model as [EMB]-CE. Figure 1a shows high-level model architecture for dual-encoders, [CLS]-CE and [EMB]-CE model.
+
+As shown in Figure 1b, the query-item score distribution from an [EMB]-CE model resembles that from a DE model. Empirically, we observe that rank of the query-item score matrix for [EMB]-CE model is much lower than the rank of a similar matrix computed using [CLS]-CE, thus making it much easier to approximate using matrix decomposition based methods.
+
+# 3 Experiments
+
+In our experiments, we use CE models trained for zero-shot entity linking on ZESHEL dataset (§3.1).
+
+We evaluate the proposed method and various baselines on the task of finding $k$ -nearest neighbors for cross-encoder models in §3.2, and evaluate the proposed method for various indexing and test-time cost budgets as well as study the effect of various design choices in §3.3 and §3.4. All resources for the paper including code for all experiments and model checkpoints is available at https://github.com/iesl/anncur
+
+ZESHEL Dataset The Zero-Shot Entity Linking (ZESHEL) dataset was constructed by Logeswaran et al. (2019) from Wikia. The task of zero-shot entity linking involves linking entity mentions in text to an entity from a list of entities with associated descriptions. The dataset consists of 16 different domains with eight, four, and four domains in training, dev, and test splits respectively. Each domain contains non-overlapping sets of entities, thus at test time, mentions need to be linked to unseen entities solely based on entity descriptions. Table 1 in the appendix shows dataset statistics. In this task, queries correspond to mentions of entities along with the surrounding context, and items correspond to entities with their associated descriptions.
+
+# 3.1 Training DE and CE models on ZESHEL
+
+Following the precedent set by recent papers (Wu et al., 2020; Zhang and Stratos, 2021), we first train a dual-encoder model on ZESHEL training data using hard negatives. We train a cross-encoder model for the task of zero-shot entity-linking on all eight training domains using cross-entropy loss with ground-truth entity and negative entities mined using the dual-encoder. We refer the reader to Appendix A.1 for more details.
+
+# Results on downstream task of Entity Linking
+
+To evaluate the cross-encoder models, we retrieve 64 entities for each test mention using the dual-encoder model and re-rank them using a cross-encoder model. The top-64 entities retrieved by the DE contain the ground-truth entity for $87.95\%$ mentions in test data and $92.04\%$ mentions in dev data. The proposed [EMB]-CE model achieves an average accuracy of 65.49 and 66.86 on domains in test and dev set respectively, and performs at par with the widely used and state-of-the-art [CLS]-CE
+
+architecture which achieves an accuracy of 65.87 and 67.67 on test and dev set respectively. Since [EMB]-CE model performs at par with [CLS]-CE on the downstream task of entity linking, and rank of the score matrix from [EMB]-CE is much lower than that from [CLS]-CE, we use [EMB]-CE in subsequent experiments.
+
+# 3.2 Evaluating on $k$ -NN search for CE
+
+Experimental Setup For all experiments in this section, we use the [EMB]-CE model trained on original ZESHEL training data on the task of zero-shot entity linking, and evaluate the proposed method and baselines for the task of retrieving $k$ -nearest neighbor entities (items) for a given mention (query) according to the cross-encoder model.
+
+We run experiments separately on five domains from ZESHEL containing 10K to 100K items. For each domain, we compute the query-item score matrix for a subset or all of the queries (mentions) and all items (entities) in the domain. We randomly split the query set into a training set $(\mathcal{Q}_{\mathrm{train}})$ and a test set $(\mathcal{Q}_{\mathrm{test}})$ . We use the queries in training data to train baseline DE models. For ANNCUR, we use the training queries as anchor queries and use CE scores between the anchor queries and all items for indexing as described in §2.3. All approaches are then evaluated on the task of finding top- $k$ CE items for queries in the corresponding domain's test split. For a fair comparison, we do not train DE models on multiple domains at the same time.
+
+# 3.2.1 Baseline Retrieval Methods
+
+TF-IDF: All queries and items are embedded using a TF-IDF vectorizer trained on item descriptions and top- $k$ items are retrieved using the dot-product of query and item embeddings.
+
+DE models: We experiment with $\mathrm{DE}_{\mathrm{BASE}}$ , the DE model trained on ZESHEL for the task of entity linking (see §3.1), and the following two DE models trained via distillation from the CE.
+
+- $\mathrm{DE}_{\mathrm{BERT} + \mathrm{CE}}$ : DE initialized with BERT (Devlin et al., 2019) and trained only using training signal from the cross-encoder model.
+- $\mathrm{DE}_{\mathrm{BASE} + \mathrm{CE}}$ : $\mathrm{DE}_{\mathrm{BASE}}$ model further fine-tuned via distillation using the cross-encoder model.
+
+We refer the reader to Appendix A.3 for hyperparameter and optimization details.
+
+
+
+Figure 3: Top- $k$ -Recall results for domain $\equiv$ YuGiOh and $|\mathcal{Q}_{\mathrm{train}}| = 500$
+
+(a) Top- $k$ -Recall@ $k_r$ for ANCCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANCCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+Evaluation metric We evaluate all approaches under the following two settings.
+
+- In the first setting, we retrieve $k_r$ items for a given query, re-rank them using exact CE scores and keep top- $k$ items. We evaluate each method using Top- $k$ -Recall@ $k_r$ which is the percentage of top- $k$ items according to the CE model present in the $k_r$ retrieved items.
+- In the second setting, we operate under a fixed test-time cost budget where the cost is defined as the number of CE calls made during inference. Baselines such as DE and TF-IDF will use the entire cost budget for re-ranking items using exact CE scores while our proposed approach will have to split the budget between the number of anchor items $(k_{i})$ used for embedding the query (§2.4) and the number of items $(k_{r})$ retrieved for final re-ranking.
+
+We refer to our proposed method as ANNCUR $_{k_i}$ when using fixed set of $k_i$ anchor items chosen uniformly at random, and we refer to it as ANNCUR when operating under a fixed test-time cost budget in which case different values of $k_i$ and $k_r$ are used in each setting.
+
+# 3.2.2 Results
+
+Figures 3a and 3b show recall of top- $k$ cross-encoder nearest neighbors for $k \in \{1, 10, 50, 100\}$ on ZESHEL domain = YuGiOh when using 500 queries for training, and evaluating on the remaining 2874 test queries. Figure 3a shows recall when each method retrieves the same number of items and Figure 3b shows recall when each method operates under a fixed inference cost budget.
+
+Performance for $k \geq 10$ In Figure 3a, our proposed approach outperforms all baselines at finding top- $k = 10,50$ , and 100 nearest neighbors when all models retrieve the same number of items for re-ranking. In Figure 3b, when operating under the same cost budget, ANNCUR outperforms DE baselines at larger cost budgets for $k = 10,50$ , and 100. Recall that at a smaller cost budget, ANNCUR is able to retrieve fewer number of items for exact re-ranking than the baselines as it needs to use a fraction of the cost budget i.e. CE calls to compare the test-query with anchor items in order to embed the query for retrieving relevant items. Generally, the optimal budget split between the number of anchor items $(k_{i})$ and the number of items retrieved
+
+
+Figure 4: Bar plot showing Top-100-Recall@Cost=500 for different methods as we increase $|\mathcal{Q}_{\mathrm{train}}|$ , the size of indexing/training data for five different domains.
+
+for exact re-ranking $(k_{r})$ allocates around $40 - 60\%$ of the budget to $k_{i}$ and the remaining budget to $k_{r}$ .
+
+Performance for $k = 1$ The top-1 nearest neighbor according to the CE is likely to be the ground-truth entity (item) for the given mention (query). Note that $\mathrm{DE}_{\mathrm{BASE}}$ was trained using a massive amount of entity linking data (all eight training domains in ZESHEL, see §3.1) using the ground-truth entity (item) as the positive item. Thus, it is natural for top-1 nearest neighbor for both of these models to be aligned. For this reason, we observe that $\mathrm{DE}_{\mathrm{BASE}}$ and $\mathrm{DE}_{\mathrm{BASE} + \mathrm{CE}}$ outperform ANNCUR for $k = 1$ . However, our proposed approach either outperforms or is competitive with $\mathrm{DE}_{\mathrm{BERT} + \mathrm{CE}}$ , a DE model trained only using CE scores for 500 queries after initializing with BERT. In Figure 3a, ANNCUR100 and ANNCUR200 outperform $\mathrm{DE}_{\mathrm{BERT} + \mathrm{CE}}$ and in Figure 3b ANNCUR outperforms $\mathrm{DE}_{\mathrm{BERT} + \mathrm{CE}}$ at larger cost budgets.
+
+We refer the reader to Appendix B.3 for results on all combinations of top- $k$ values, domains, and training data size values.
+
+Effect of training data size $(|Q_{train}|)$ Figure 4 shows Top-100-Recall@Cost=500 on test queries for various methods as we increase the number of queries in training data $(|Q_{train}|)$ . For DE baselines, the trend is not consistent across all domains. On YuGiOh, the performance consistently improves with $|Q_{train}|$ . However, on Military, the performance of distilled DE drops on going from 100 to 500 training queries but improves on going from 500 to 2000 training queries. Similarly, on Pro_Wrestling, performance of distilled $\mathrm{DE}_{\mathrm{BASE + CE}}$ does not consistently improve with training data size while it does for $\mathrm{DE}_{\mathrm{BERT + CE}}$ . We suspect that this is due to a combination of various factors such as overfitting on training data, sub-optimal hyper-parameter configuration, divergence of model parameters etc. In contrast, our
+
+
+Figure 5: Bar plot with Top-100-Recall@Cost=500 for five domains in ZESHEL when using $|\mathcal{Q}_{\mathrm{train}}| = 500$ queries for training/indexing and a line-plot showing the number of items (entities) in each domain.
+
+proposed method, ANNCUR, always shows consistent improvements as we increase the number of queries in training data, and avoids the perils of gradient-based training that often require large amounts of training data to avoid overfitting as well expensive hyper-parameter tuning in order to consistently work well across various domains.
+
+Effect of domain size Figure 5 shows Top-100-Recall@Cost=500 for ANNCUR and DE baselines on primary y-axis and size of the domain i.e. total number of items on secondary y-axis for five different domains in ZESHEL. Generally, as the number of items in the domain increases, the performance of all methods drops.
+
+Indexing Cost The indexing process starts by computing query-item CE scores for queries in train split. ANNCUR uses these scores for indexing the items (see §2.3) while DE baselines use these scores to find ground-truth top- $k$ items for each query followed by training DE models using CE query-item scores. For domain=YuGi0h with 10031 items, and $|\mathcal{Q}_{\mathrm{train}}| = 500$ , the time taken to compute query-item scores for train/anchor queries ( $t_{\mathrm{CE - Mat}} \approx 10$ hours on an NVIDIA GeForce RTX2080Ti GPU/12GB memory, and
+
+
+(a) [CLS]-CE
+
+
+(b) [EMB]-CE
+
+training a DE model further takes additional time $(t_{\mathrm{DE - train}})\approx 4.5$ hours on two instances of the same GPU. Both $t_\mathrm{CE - Mat}$ and $t_\mathrm{DE - train}$ increase linearly with domain size and $|\mathcal{Q}_{\mathrm{train}}|$ , however the query-item score computation can be trivially parallelized. We ignore the time to build a nearest-neighbor search index over item embeddings produced by ANNCUR or DE as that is negligible in comparison to time spent on CE score computation and training of DE models. We refer the reader to Appendix A.3 for more details.
+
+# 3.3 Analysis of ANNCUR
+
+We compute the query-item score matrix for both [CLS]-CE and [EMB]-CE and compute the rank of these matrices using numpy (Harris et al., 2020) for domain=YuGiOh with 3374 queries (mentions) and 10031 items (entities). Rank of the score matrix for [CLS]-CE = 315 which is much higher than rank of the corresponding matrix for [EMB]-CE = 45 due to the query-item score distribution produced by [CLS]-CE model being much more skewed than that produced by [EMB]-CE model (see Fig. 1b).
+
+Figures 6a and 6b show Top-10-Recall@500 on domain=YuGiOh for [CLS]-CE and [EMB]-CE respectively on different combinations of number of anchor queries $(k_{q})$ and anchor items $(k_{i})$ . Both anchor queries and anchor items are chosen uniformly at random, and for a given set of anchor queries, we evaluate on the remaining set of queries.
+
+[CLS]-CE versus [EMB]-CE For the same choice of anchor queries and anchor items, the proposed method performs better with [EMB]-CE model as compared [CLS]-CE due to the query-item score matrix for [EMB]-CE having much lower rank thus making it easier to approximate.
+
+Effect of $k_{q}$ and $k_{i}$ Recall that the indexing time for ANNCUR is directly proportional to the num
+
+
+Figure 6: Top-10-Recall@500 of ANNCUR for non-anchor queries on domain = YuGiOh for two cross-encoder models - [CLS]-CE and [EMB]-CE.
+Figure 7: Bar plot showing Top-100-Recall for domain=YuGiOh when indexing using 500 anchor items for FIXEDITEM and ITEMCUR and 500 anchor queries for ANNCUR.
+
+ber of anchor queries $(k_{q})$ while the number of anchor items $(k_{i})$ influences the test-time inference latency. Unsurprisingly, performance of AN-NCUR increases as we increase $k_{i}$ and $k_{q}$ , and these can be tuned as per user's requirement to obtain desired recall-vs-indexing time and recall-vs-inference time trade-offs. We refer the reader to Appendix B.2 for a detailed explanation for the drop in performance when $k_{q} = k_{i}$ .
+
+# 3.4 Item-Item Similarity Baselines
+
+We additionally compare with the following baselines that index items by comparing against a fixed set of anchor items instead of anchor queries.
+
+- FIXEDITEM: Embed all items and test-query in $\mathbb{R}^{k_i}$ using CE scores with a fixed set of $k_{i}$ items chosen uniformly at random, and retrieve top- $k_{r}$ items for the test query based on dot-product of these $k_{i}$ -dim embeddings. We use $k_{i} = 500$ .
+- ITEMCUR- $k_{i}$ : This is similar to the proposed approach except that it indexes the items by comparing them against $k_{i}^{\mathrm{ind}}$ anchor items instead of anchor queries for computing $R_{\mathrm{anc}}$ and $C_{\mathrm{anc}}$ matrices in the indexing step in §2.3. At test time, it performs inference just like ANNCUR (see §2.4) by comparing against a different set of fixed $k_{i}$ anchor items. We use $k_{i}^{\mathrm{ind}} = 500$ .
+
+Figure 7 shows Top-100-Recall for FIXEDITEM, ITEMCUR, and ANNCUR on domain $= \text{YuGiO}h$ . ITEMCUR performs better than FIXEDITEM indicating that the latent item embeddings produced using CUR decomposition of the item-item similarity matrix are better than those built by comparing
+
+the items against a fixed set of anchor items. ITEM-CUR performs worse than ANNCUR apparently because the CE was trained on query-item pairs and was not calibrated for item-item comparisons.
+
+# 4 Related Work
+
+Matrix Decomposition Classic matrix decomposition methods such as SVD, QR decomposition have been used for approximating kernel matrices and distance matrices (Musco and Woodruff, 2017; Tropp et al., 2017; Bakshi and Woodruff, 2018; Indyk et al., 2019). Interpolative decomposition methods such as Nyström method and CUR decomposition allow approximation of the matrix even when given only a subset of rows and columns of the matrix. Unsurprisingly, performance of these methods can be further improved if given the entire matrix as it allows for a better selection of rows and columns on the matrix used in the decomposition process (Goreinov et al., 1997; Drineas et al., 2005; Kumar et al., 2012; Wang and Zhang, 2013). Recent work, Ray et al. (2022) proposes sublinear Nyström approximations and considers CUR-based approaches for approximating non-PSD similarity matrices that arise in NLP tasks such as coreference resolution and document classification. Unlike previous work, our goal is to use the approximate scores to support retrieval of top scoring items. Although matrix decomposition methods for sparse matrices based on SVD (Berry, 1992; Keshavan et al., 2010; Hastie et al., 2015; Ramlatchan et al., 2018) can be used instead of CUR decomposition, such methods would require a) factorizing a sparse matrix at test time in order to obtain latent embeddings for all items and the test query, and b) indexing the latent item embeddings to efficiently retrieve top-scoring items for the given query. In this work, we use CUR decomposition as, unlike other sparse matrix decomposition methods, CUR decomposition allows for offline computation and indexing of item embeddings and the latent embedding for a test query is obtained simply by using its cross-encoder scores against the anchor items.
+
+Cross-Encoders and Distillation Due to high computational costs, use of cross-encoders (CE) is often limited to either scoring a fixed set of items or re-ranking items retrieved by a separate (cheaper) retrieval model (Logeswaran et al., 2019; Qu et al., 2021; Bhattacharyya et al., 2021; Ayoola et al., 2022). CE models are also widely used for training computationally cheaper models via distilla
+
+tion on the training domain (Wu et al., 2020; Reddi et al., 2021), or for improving performance of these cheaper models on the target domain (Chen et al., 2020; Thakur et al., 2021) by using cross-encoders to score a fixed or heuristically retrieved set of items/datapoints. The DE baselines used in this work, in contrast, are trained using $k$ -nearest neighbors for a given query according to the CE.
+
+Nearest Neighbor Search For applications where the inputs are described as vectors in $\mathbb{R}^n$ , nearest neighbor search has been widely studied for various (dis-)similarity functions such as $\ell_2$ distance (Chávez et al., 2001; Hjaltason and Samet, 2003), inner-product (Jegou et al., 2010; Johnson et al., 2019; Guo et al., 2020), and Bregman-divergences (Cayton, 2008). Recent work on nearest neighbor search with non-metric (parametric) similarity functions explores various tree-based (Boytsov and Nyberg, 2019b) and graph-based nearest neighbor search indices (Boytsov and Nyberg, 2019a; Tan et al., 2020, 2021). In contrast, our approach approximates the scores of the parametric similarity function using the latent embeddings generated using CUR decomposition and uses off-the-shelf maximum inner product search methods with these latent embeddings to find $k$ -nearest neighbors for the CE. An interesting avenue for future work would be to combine our approach with tree-based and graph-based approaches to further improve efficiency of these search methods.
+
+# 5 Conclusion
+
+In this paper, we proposed, ANNCUR, a matrix factorization-based approach for nearest neighbor search for a cross-encoder model without relying on an auxiliary model such as a dual-encoder for retrieval. ANNCUR approximates the test query's scores with all items by scoring the test-query only with a small number of anchor items, and retrieves items using the approximate scores. Empirically, for $k > 10$ , our approach provides test-time recall-vs-computational cost trade-offs superior to the widely-used approach of using cross-encoders to rerank items retrieved using a dual-encoder or a TF-IDF-based model. This work is a step towards enabling efficient retrieval with expensive similarity functions such as cross-encoders, and thus, moving beyond using such models merely for re-ranking items retrieved by auxiliary retrieval models such as dual-encoders and TF-IDF-based models.
+
+# Acknowledgements
+
+We thank members of UMass IESL for helpful discussions and feedback. This work was supported in part by the Center for Data Science and the Center for Intelligent Information Retrieval, in part by the National Science Foundation under Grant No. NSF1763618, in part by the Chan Zuckerberg Initiative under the project "Scientific Knowledge Base Construction", in part by International Business Machines Corporation Cognitive Horizons Network agreement number W1668553, and in part using high performance computing equipment obtained under a grant from the Collaborative R&D Fund managed by the Massachusetts Technology Collaborative. Rico Angell was supported by the NSF Graduate Research Fellowship under Grant No. 1938059. Any opinions, findings and conclusions or recommendations expressed in this material are those of the authors and do not necessarily reflect those of the sponsor(s).
+
+# Limitations
+
+In this work, we use cross-encoders parameterized using transformer models. Computing query-item scores using such models can be computationally expensive. For instance, on an NVIDIA GeForce RTX 2080Ti GPU with 12GB memory, we can achieve a throughput of approximately 140 scores/second, and computing a score matrix for 100 queries and 10K items takes about two hours. Although this computation can be trivially parallelized, the total amount of GPU hours required for this computation can be very high. However, note that these scores need to be computed even for distillation based DE baselines as we need to identify $k$ -nearest neighbors for each query according to the cross-encoder model for training a dual-encoder model on this task.
+
+Our proposed approach allows for indexing the item set only using scores from cross-encoder without any additional gradient based training but it is not immediately clear how it can benefit from data on multiple target domains at the same time. Parametric models such as dual-encoders on the other hand can benefit from training and knowledge distillation on multiple domains at the same time.
+
+# Ethical Consideration
+
+Our proposed approach considers how to speed up the computation of nearest neighbor search for
+
+cross-encoder models. The cross-encoder model, which our approach approximates, may have certain biases / error tendencies. Our proposed approach does not attempt to mitigate those biases. It is not clear how those biases would propagate in our approximation, which we leave for future work. An informed user would scrutinize both the cross-encoder model and the resulting approximations used in this work.
+
+# References
+
+Tom Ayoola, Shubhi Tyagi, Joseph Fisher, Christos Christodoulopoulos, and Andrea Pierleoni. 2022. Re-FinED: An efficient zero-shot-capable approach to end-to-end entity linking. In Proceedings of the 2022 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies: Industry Track, pages 209-220. Association for Computational Linguistics.
+Ainesh Bakshi and David Woodruff. 2018. Sublinear time low-rank approximation of distance matrices. Advances in Neural Information Processing Systems.
+Michael W Berry. 1992. Large-scale sparse singular value computations. The International Journal of Supercomputing Applications, 6(1):13-49.
+Sumanta Bhattacharyya, Amirmohammad Rooshenas, Subhajit Naskar, Simeng Sun, Mohit Iyyer, and Andrew McCallum. 2021. Energy-based reranking: Improving neural machine translation using energy-based models. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4528-4537. Association for Computational Linguistics.
+Leonid Boytsov and Eric Nyberg. 2019a. Accurate and fast retrieval for complex non-metric data via neighborhood graphs. In International Conference on Similarity Search and Applications, pages 128-142. Springer.
+Leonid Boytsov and Eric Nyberg. 2019b. Pruning algorithms for low-dimensional non-metric k-nn search: a case study. In International Conference on Similarity Search and Applications, pages 72-85. Springer.
+Lawrence Cayton. 2008. Fast nearest neighbor retrieval for bregman divergences. In International Conference on Machine Learning, pages 112-119.
+Edgar Chávez, Gonzalo Navarro, Ricardo Baeza-Yates, and José Luis Marroquín. 2001. Searching in metric spaces. ACM computing surveys (CSUR), 33(3):273-321.
+Jiecao Chen, Liu Yang, Karthik Raman, Michael Bendersky, Jung-Jung Yeh, Yun Zhou, Marc Najork,
+
+Danyang Cai, and Ehsan Emadzadeh. 2020. DiPair: Fast and accurate distillation for trillion-scale text matching and pair modeling. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 2925-2937. Association for Computational Linguistics.
+Debashis Das, Laxman Sahoo, and Sujoy Datta. 2017. A survey on recommendation system. International Journal of Computer Applications, 160(7).
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics.
+Petros Drineas, Michael W Mahoney, and Nello Cristianini. 2005. On the nystrom method for approximating a gram matrix for improved kernel-based learning. The Journal of Machine Learning Research, 6(12).
+Sergei A Goreinov, Eugene E Tyrtyshnikov, and Nickolai L Zamarashkin. 1997. A theory of pseudoskeleton approximations. Linear Algebra and its Applications, 261(1-3):1-21.
+Ruiqi Guo, Philip Sun, Erik Lindgren, Quan Geng, David Simcha, Felix Chern, and Sanjiv Kumar. 2020. Accelerating large-scale inference with anisotropic vector quantization. In International Conference on Machine Learning, pages 3887-3896.
+Charles R. Harris, K. Jarrod Millman, Stefan J. van der Walt, Ralf Gommers, Pauli Virtanen, David Cournaepau, Eric Wieser, Julian Taylor, Sebastian Berg, Nathaniel J. Smith, Robert Kern, Matti Picus, Stephan Hoyer, Marten H. van Kerkwijk, Matthew Brett, Allan Haldane, Jaime Fernandez del Rio, Mark Wiebe, PEARU Peterson, Pierre Gerard-Marchant, Kevin Sheppard, Tyler Reddy, Warren Weckesser, Hameer Abbasi, Christoph Gohlke, and Travis E. Oliphant. 2020. Array programming with NumPy. Nature, 585(7825):357-362.
+Trevor Hastie, Rahul Mazumder, Jason D Lee, and Reza Zadeh. 2015. Matrix completion and low-rank svd via fast alternating least squares. The Journal of Machine Learning Research, 16(1):3367-3402.
+Gisli R Hjaltason and Hanan Samet. 2003. Index-driven similarity search in metric spaces (survey article). ACM Transactions on Database Systems (TODS), 28(4):517-580.
+Sebastian Hofstätter, Sophia Althammer, Michael Schröder, Mete Sertkan, and Allan Hanbury. 2020. Improving efficient neural ranking models with cross-architecture knowledge distillation. *ArXiv*, abs/2010.02666.
+
+Sebastian Hofstätter, Navid Rekabsaz, Carsten Eickhoff, and Allan Hanbury. 2019. On the effect of low-frequency terms on neural-ir models. In ACM SIGIR Conference on Research and Development in Information Retrieval, pages 1137-1140.
+Samuel Humeau, Kurt Shuster, Marie-Anne Lachaux, and Jason Weston. 2020. Poly-encoders: Transformer architectures and pre-training strategies for fast and accurate multi-sentence scoring. In International Conference on Learning Representations, ICLR.
+Pitor Indyk, Ali Vakilian, Tal Wagner, and David P Woodruff. 2019. Sample-optimal low-rank approximation of distance matrices. In Conference on Learning Theory, pages 1723-1751. PMLR.
+Herve Jegou, Matthijs Douze, and Cordelia Schmid. 2010. Product quantization for nearest neighbor search. IEEE Transactions on Pattern Analysis and Machine Intelligence, 33(1):117-128.
+Jeff Johnson, Matthijs Douze, and Hervé Jégou. 2019. Billion-scale similarity search with gpus. IEEE Transactions on Big Data, 7(3):535-547.
+Vladimir Karpukhin, Barlas Oguz, Sewon Min, Patrick Lewis, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6769-6781. Association for Computational Linguistics.
+Raghunandan H Keshavan, Andrea Montanari, and Swoong Oh. 2010. Matrix completion from a few entries. IEEE transactions on information theory, 56(6):2980-2998.
+Omar Khattab and Matei Zaharia. 2020. Colbert: Efficient and effective passage search via contextualized late interaction over bert. In ACM SIGIR Conference on Research and Development in Information Retrieval, pages 39-48.
+Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization. In International Conference on Learning Representations, ICLR.
+Gerald J Kowalski. 2007. Information retrieval systems: theory and implementation, volume 1. Springer.
+Sanjiv Kumar, Mehryar Mohri, and Ameet Talwalkar. 2012. Sampling methods for the nystrom method. The Journal of Machine Learning Research, 13(1):981-1006.
+Fangyu Liu, Yunlong Jiao, Jordan Massiah, Emine Yilmaz, and Serhii Havrylov. 2022. Trans-encoder: Unsupervised sentence-pair modelling through self-and mutual-distillations. In International Conference on Learning Representations, ICLR.
+
+Lajanugen Logeswaran, Ming-Wei Chang, Kenton Lee, Kristina Toutanova, Jacob Devlin, and Honglak Lee. 2019. Zero-shot entity linking by reading entity descriptions. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3449-3460. Association for Computational Linguistics.
+Wenhao Lu, Jian Jiao, and Ruofei Zhang. 2020. Twinbert: Distilling knowledge to twin-structured compressed bert models for large-scale retrieval. In ACM International Conference on Information & Knowledge Management, pages 2645–2652.
+Yi Luan, Jacob Eisenstein, Kristina Toutanova, and Michael Collins. 2021. Sparse, dense, and attentional representations for text retrieval. Transactions of the Association for Computational Linguistics, 9:329-345.
+Michael W Mahoney and Petros Drineas. 2009. Cur matrix decompositions for improved data analysis. Proceedings of the National Academy of Sciences, 106(3):697-702.
+Yu A Malkov and Dmitry A Yashunin. 2018. Efficient and robust approximate nearest neighbor search using hierarchical navigable small world graphs. IEEE Transactions on Pattern Analysis and Machine Intelligence, 42(4):824-836.
+Cameron Musco and David P Woodruff. 2017. Sublinear time low-rank approximation of positive semidefinite matrices. In IEEE 58th Annual Symposium on Foundations of Computer Science (FOCS), pages 672-683. IEEE.
+Yingqi Qu, Yuchen Ding, Jing Liu, Kai Liu, Ruiyang Ren, Wayne Xin Zhao, Daxiang Dong, Hua Wu, and Haifeng Wang. 2021. RocketQA: An optimized training approach to dense passage retrieval for open-domain question answering. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 5835-5847. Association for Computational Linguistics.
+Andy Ramlatchan, Mengyun Yang, Quan Liu, Min Li, Jianxin Wang, and Yaohang Li. 2018. A survey of matrix completion methods for recommendation systems. *Big Data Mining and Analytics*, 1(4):308-323.
+Archan Ray, Nicholas Monath, Andrew McCallum, and Cameron Musco. 2022. Sublinear time approximation of text similarity matrices. Proceedings of the AAAI Conference on Artificial Intelligence, 36(7):8072-8080.
+Sashank Reddi, Rama Kumar Pasumarthi, Aditya Menon, Ankit Singh Rawat, Felix Yu, Seungyeon Kim, Andreas Veit, and Sanjiv Kumar. 2021. Rankdistil: Knowledge distillation for ranking. In International Conference on Artificial Intelligence and Statistics, pages 2368-2376. PMLR.
+
+Stephen E Robertson, Steve Walker, Susan Jones, Micheline M Hancock-Beaulieu, Mike Gatford, et al. 1995. Okapi at trec-3. NIST Special Publication, 109:109.
+Shulong Tan, Weijie Zhao, and Ping Li. 2021. Fast neural ranking on bipartite graph indices. Proceedings of the VLDB Endowment, 15(4):794-803.
+Shulong Tan, Zhixin Zhou, Zhaozhuo Xu, and Ping Li. 2020. Fast item ranking under neural network based measures. In International Conference on Web Search and Data Mining, pages 591-599.
+Nandan Thakur, Nils Reimers, Johannes Daxenberger, and Iryna Gurevych. 2021. Augmented SBERT: Data augmentation method for improving bi-encoders for pairwise sentence scoring tasks. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 296-310. Association for Computational Linguistics.
+Joel A Tropp, Alp Yurtsever, Madeleine Udell, and Volkan Cevher. 2017. Randomized single-view algorithms for low-rank matrix approximation.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. Advances in Neural Information Processing Systems.
+Shusen Wang and Zhihua Zhang. 2013. Improving cur matrix decomposition and the nystrom approximation via adaptive sampling. The Journal of Machine Learning Research, 14(1):2729-2769.
+Ledell Wu, Fabio Petroni, Martin Josifoski, Sebastian Riedel, and Luke Zettlemoyer. 2020. Scalable zero-shot entity linking with dense entity retrieval. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6397-6407. Association for Computational Linguistics.
+Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, et al. 2016. Google's neural machine translation system: Bridging the gap between human and machine translation. arXiv preprint arXiv:1609.08144.
+Hamed Zamani, Mostafa Dehghani, W Bruce Croft, Erik Learned-Miller, and Jaap Kamps. 2018. From neural re-ranking to neural ranking: Learning a sparse representation for inverted indexing. In ACM International Conference on Information and Knowledge Management, pages 497-506.
+Wenzheng Zhang and Karl Stratos. 2021. Understanding hard negatives in noise contrastive estimation. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 1090-1101. Association for Computational Linguistics.
+
+| Domain | |E| | |M| | |Mk-NN| |
| Training Data |
| Military | 104520 | 13063 | 2400 |
| Pro Wrestling | 10133 | 1392 | 1392 |
| Doctor Who | 40281 | 8334 | 4000 |
| American Football | 31929 | 3898 | - |
| Fallout | 16992 | 3286 | - |
| Star Wars | 87056 | 11824 | - |
| World of Wcraft | 27677 | 1437 | - |
| Validation Data |
| Coronation Street | 17809 | 1464 | - |
| Muppets | 21344 | 2028 | - |
| Ice Hockey | 28684 | 2233 | - |
| Elder Scrolls | 21712 | 4275 | - |
| Test Data |
| Star Trek | 34430 | 4227 | 4227 |
| YuGiOh | 10031 | 3374 | 3374 |
| Forgotten Realms | 15603 | 1200 | - |
| Lego | 10076 | 1199 | - |
+
+Table 1: Statistics on number of entities $|\mathcal{E}|$ (items), total number of mentions $|\mathcal{M}|$ (queries), and number of mentions used in $k$ -NN experiments $(|\mathcal{M}_{k - \mathrm{NN}}|)$ in §3.2 for each domain in ZESHEL dataset.
+
+# A Training Details
+
+# A.1 Training DE and CE for Entity Linking on ZESHEL
+
+We initialize all models with bert-base-uncased and train using Adam (Kingma and Ba, 2015) optimizer with learning rate $= 10^{-5}$ , and warm-up proportion $= 0.01$ for four epochs. We evaluate on dev set five times during each epoch, and pick the model checkpoint that maximises accuracy on dev set. While training the dual-encoder model, we update negatives after each epoch using the latest dual-encoder model parameters to mine hard negatives. We trained the cross-encoder with a fixed set of 63 negatives items (entities) for each query (mention) mined using the dual-encoder model. We use batch size of 8 and 4 for training the dual-encoder and cross-encoder respectively.
+
+Dual-encoder and cross-encoder models took 34 an 44 hours respectively for training on two NVIDIA GeForce RTX 8000 GPUs each with 48GB memory. The dual-encoder model has $2 \times 110\mathrm{M}$ parameters as it consists of separate query and item encoder models while the cross-encoder model has 110M parameters.
+
+Tokenization details We use word-piece tokenization (Wu et al., 2016) for with a maximum of
+
+128 tokens including special tokens for tokenizing entities and mentions. The mention representation consists of the word-piece tokens of the context surrounding the mention and the mention itself as
+
+$$
+[ \mathrm {C L S} ] \mathrm {c t x t} _ {1} [ \mathrm {M} _ {\mathrm {s}} ] \text {m e n t} [ \mathrm {M} _ {\mathrm {e}} ] \mathrm {c t x t} _ {\mathrm {r}} [ \mathrm {S E P} ]
+$$
+
+where $\text{ment}$ , $\text{ctxt}_1$ , and $\text{ctxt}_r$ are word-piece tokens of the mention, context before and after the mention respectively, and $[\mathsf{M}_{\mathsf{s}}]$ , $[\mathsf{M}_{\mathsf{e}}]$ are special tokens to tag the mention.
+
+The entity representation is also composed of word-piece tokens of the entity title and description. The input to our entity model is:
+
+$$
+[ \text {C L S} ] \text {t i t l e [ E N T ] d e s c r i p t i o n [ S E P ]}
+$$
+
+where title, description are word-pieces tokens of entity title and description, and [ENT] is a special token to separate entity title and description representation.
+
+The cross-encoder model takes as input the concatenated query (mention) and item (entity) representation with the [CLS] token stripped off the item (entity) tokenization as shown below
+
+$$
+\begin{array}{l} \text {[ C L S ] c t x t _ {1} [ M _ {s} ] m e n t [ M _ {e} ] c t x t _ {r} [ S E P ]} \\ \text {t i l t e [ E N T ] d e s c r i p t i o n [ S E P ]} \end{array}
+$$
+
+# A.2 Using query-item CE model for computing item-item similarity
+
+We compute item-item similarity using a cross-encoder trained to score query-item pairs as follows. The query and item in our case correspond to mention of an entity with surrounding context and entity with its associated title and description respectively. We feed in first entity in the pair in the query slot by using mention span tokens around the title of the entity, and using entity description to fill in the right context of the mention. We feed in the second entity in the entity slot as usual. The concatenated representation of the entity pair $(e_1,e_2)$ is given by
+
+$$
+[ C L S ] [ M _ {s} ] t _ {e _ {1}} [ M _ {e} ] d _ {e _ {1}} [ S E P ] t _ {e _ {2}} [ E ] d _ {e _ {2}} [ S E P ]
+$$
+
+where $t_{e_1}$ , $t_{e_2}$ are the tokenized titles of the entities, $d_{e_1}$ , $d_{e_2}$ are the tokenized entity descriptions, $[M_e]$ , $[M_s]$ are special tokens denoting mention span boundary and $[E]$ is a special token separating entity title from its description.
+
+# A.3 Training DE for $k$ -NN retrieval with CE
+
+We train dual-encoder models using $k$ -nearest neighbor items according to cross-encoder model for each query using two loss functions. Let $S^{(\mathrm{DE})}$ and $S^{(\mathrm{CE})}$ be matrices containing score for all items for each query in training data. Let $\mathrm{T}_{k_d}^{\mathrm{CE}}(q), \mathrm{T}_{k_d}^{\mathrm{DE}}(q)$ be top- $k_d$ items for query $q$ according to the cross-encoder and dual-encoder respectively, and let $\mathrm{N}_{k_d}^{\mathrm{DE}}(q)$ be top- $k_d$ items for query $q$ according to dual-encoder that are not present in $\mathrm{T}_{k_d}^{\mathrm{CE}}(q)$ .
+
+We use loss functions $\mathcal{L}_{\mathrm{match}}$ and $\mathcal{L}_{\mathrm{pair}}$ described below for training the dual-encoder model using a cross-encoder model.
+
+$$
+\mathcal {L} _ {\text {m a t c h}} = \sum_ {q \in \mathcal {Q} _ {\text {t r a i n}}} \mathcal {H} \left(\sigma \left(S _ {[ q,: ]} ^ {(\mathrm {D E})}\right), \sigma \left(S _ {[ q,: ]} ^ {(\mathrm {C E})}\right)\right)
+$$
+
+where $\mathcal{H}$ is the cross-entropy function, and $\sigma(.)$ is the softmax function. In words, $\mathcal{L}_{\mathrm{match}}$ is the cross-entropy loss between the dual-encoder and cross-encoder query-item score distribution over all items. Due to computational and memory limitations, we train by minimizing $\mathcal{L}_{\mathrm{match}}$ using items in $\mathrm{T}_{k_d}^{\mathrm{CE}}(q)$ for each query $q \in \mathcal{Q}_{\mathrm{train}}$ .
+
+$$
+\mathcal {L} _ {\text {p a i r}} = \sum_ {q \in \mathcal {Q} _ {\text {t r a i n}}} \sum_ {(i, j) \in \mathcal {P} _ {q}} \mathcal {H} ([ 0, 1 ], \sigma ([ S _ {q, i} ^ {(\mathrm {D E})}, S _ {q, j} ^ {(\mathrm {D E})} ]))
+$$
+
+$$
+\text {w h e r e}, \mathcal {P} _ {q} = \left\{\left(\mathrm {T} _ {k _ {d}} ^ {\mathrm {C E}} (q) _ {j}, \mathrm {N} _ {k _ {d}} ^ {\mathrm {D E}} (q) _ {j}\right) \right\} _ {j = 0} ^ {k _ {d}}
+$$
+
+$\mathcal{L}_{\mathrm{pair}}$ treats items in $\mathrm{T}_{k_d}^{\mathrm{CE}}(q)$ as a positive item, pairs it with hard negatives from $\mathrm{N}_{k_d}^{\mathrm{DE}}(q)$ , and minimizing $\mathcal{L}_{\mathrm{pair}}$ increases dual-encoder's score for items in $\mathrm{T}_{k_d}^{\mathrm{CE}}(q)$ , thus aligning $\mathrm{T}_{k_d}^{\mathrm{DE}}(q)$ with $\mathrm{T}_{k_d}^{\mathrm{CE}}(q)$ for queries in training data.
+
+Training and optimization details We train all dual-encoder models using Adam optimizer with learning rate $= 10^{-5}$ for 10 epochs. We use a separate set of parameters for query and item encoders. We use $10\%$ of training queries for validation and train on the remaining $90\%$ of the queries. For each domain and training data size, we train with both $\mathcal{L}_{\mathrm{match}}$ and $\mathcal{L}_{\mathrm{pair}}$ loss functions, and pick the model that performs best on validation queries for $k$ -NN retrieval according to the cross-encoder model.
+
+We train models for with loss $\mathcal{L}_{\mathrm{pair}}$ on two NVIDIA GeForce RTX 2080Ti GPUs with 12GB GPU memory and with loss $\mathcal{L}_{\mathrm{match}}$ on two NVIDIA GeForce RTX 8000 GPUs with 48GB GPU memory as we could not train with $k_{d} = 100$ on 2080Tis
+
+due to GPU memory limitations. For loss $\mathcal{L}_{\mathrm{pair}}$ we update the list of negative items $(\mathrm{N}_{k_d}^{\mathrm{DE}}(q))$ for each query after each epoch by mining hard negative items using the latest dual-encoder model parameters.
+
+| |Qtrain| | Model | tCE-Mat | ttrain | ttotal |
| 100 | DE-λpair | 2 | 2.5 | 4.5 |
| 100 | DE-λmatch | 2 | 0.5 | 2.5 |
| 100 | ANNCUR | 2 | - | 2 |
| 500 | DE-λpair | 10 | 4.5 | 14.5 |
| 500 | DE-λmatch | 10 | 1 | 11 |
| 500 | ANNCUR | 10 | - | 10 |
| 2000 | DE-λpair | 40 | 11 | 51 |
| 2000 | DE-λmatch | 40 | 3 | 43 |
| 2000 | ANNCUR | 40 | - | 40 |
+
+(a) Indexing time (in hrs) for ANNCUR and distillation based DE baselines for different number of anchor/train queries $(|\mathcal{Q}_{\mathrm{train}}|)$ for domain $= \mathrm{YuGi0h}$
+
+| Domain (w/ size) | Model | tCE-Mat | ttrain | ttotal |
| YuGiOh-10K | DE-Lpair | 10 | 4.5 | 14.5 |
| YuGiOh-10K | ANNCUR | 10 | - | 10 |
| Pro_Wrest-10K | DE-Lpair | 10 | 4.4 | 14.4 |
| Pro_Wrest-10K | ANNCUR | 10 | - | 10 |
| Star_Trek-34K | DE-Lpair | 40 | 5.1 | 45.1 |
| Star_Trek-34K | ANNCUR | 40 | - | 40 |
| Doctor_Who-40K | DE-Lpair | 40 | 5.2 | 45.2 |
| Doctor_Who-40K | ANNCUR | 40 | - | 40 |
| Military-104K | DE-Lpair | 102 | 5.1 | 107.1 |
| Military-104K | ANNCUR | 102 | - | 102 |
+
+(b) Indexing time (in hrs) for ANNCUR and distillation based DE baselines for various domains when using $|\mathcal{Q}_{\mathrm{train}}| = 500$ anchor/train queries.
+Table 2: Indexing time breakdown for ANNCUR and DE models trained via distillation.
+
+Indexing and Training Time Table 2a shows overall indexing time for the proposed method AN-NCUR and for DE models trained using two distillation losses - $\mathcal{L}_{\mathrm{pair}}$ and $\mathcal{L}_{\mathrm{match}}$ on domain=YuGiOh. Training time $(t_{\mathrm{train}})$ for loss $\mathcal{L}_{\mathrm{match}}$ is much less as compared to that for $\mathcal{L}_{\mathrm{pair}}$ as the former is trained on more powerful GPUs (two NVIDIA RTX8000s with 48GB memory each) due to its GPU memory requirements while the latter is trained on two NVIDIA 2080Ti GPUs with 12 GB memory each. The total indexing time $(t_{\mathrm{total}})$ for DE models includes the time taken to compute CE score matrix $(t_{\mathrm{CE-Mat}})$ because in order to train a DE model for the task of $k$ -nearest neighbor search for a CE, we need to first find exact $k$ -nearest neighbor items for the training queries. Note that this is different
+
+| Training Negatives | Dev Set | Test Set |
| [CLS]-CE | [EMB]-CE | [CLS]-CE | [EMB]-CE |
| Random | 59.60 | 57.74 | 58.72 | 56.56 |
| TF-IDF | 62.19 | 62.29 | 58.20 | 58.36 |
| DE | 67.67 | 66.86 | 65.87 | 65.49 |
+
+(a) Macro-Average of Entity Linking Accuracy for [CLS]-CE and [EMB]-CE models on test and dev set in ZESHEL.
+
+| Training Negatives | [CLS]-CE | [EMB]-CE |
| Random | 816 | 354 |
| TF-IDF | 396 | 67 |
| DE | 315 | 45 |
+
+(b) Rank of $3374 \times 10031$ mention-entity cross-encoder score matrix for test domain = YuGiOh
+Table 3: Accuracy on the downstream task of entity linking and rank of query-item (mention-entity) score matrix for [CLS]-CE and [EMB]-CE trained using different types of negatives.
+
+from the "standard" way of training of DE models via distillation where the DE is often distilled using CE scores on a fixed or heuristically retrieved set of items, and not on $k$ -nearest neighbor items according to the cross-encoder for a given query.
+
+Table 2b shows indexing time for ANNCUR and DEs trained via distillation for five domains in ZESHEL. As the size of the domain increases, the time take for computing cross-encoder scores on training queries ( $t_{\text{CE-Mat}}$ ) also increases. The time takes to train dual-encoder via distillation roughly remains the same as we train with fixed number of positive and negative items during distillation.
+
+# B Additional Results and Analysis
+
+# B.1 Comparing [EMB]-CE and [CLS]-CE
+
+In addition to training cross-encoder models with negatives mined using a dual-encoder, we train both [CLS]-CE and [EMB]-CE models using random negatives and negatives mined using TF-IDF embeddings of mentions and entities. To evaluate the cross-encoder models, we retrieve 64 entities for each test mention using a dual-encoder model and re-rank them using a cross-encoder model.
+
+Table 3a shows macro-averaged accuracy on the downstream task of entity linking over test and dev domains in ZESHEL dataset, and Table 3b shows rank of query-item score matrices on domain=YuGi0h for both cross-encoder models. The proposed [EMB]-CE model performs at par with the widely used [CLS]-CE architecture for all three kinds of negative mining strategies while producing a query-item score matrix with lower rank as compared to [CLS]-CE.
+
+Figure 8 shows approximation error of ANNCUR for different combinations of number of anchor queries and anchor items for [CLS]-CE and [EMB]-CE. For a given set of anchor queries, the approximation error is evaluated on the remaining set of queries. The error between a matrix $M$ and its approximation $M$ is measured as
+
+$\| M - \tilde{M}\| _F / \| M\| _F$ where $\| .\| _F$ is the Frobenius norm of a matrix. For the same choice of anchor queries and anchor items, the approximation error is lower for [EMB]-CE model as compared to [CLS]-CE. This aligns with the observation that rank of the query-item score matrix from [EMB]-CE is lower than the corresponding matrix from [CLS]-CE as shown in Table 3b.
+
+
+(a) [CLS]-CE
+Figure 8: Matrix approximation error evaluated on nonanchor queries for CUR decomposition on domain = YuGiOh for [CLS]-CE and [EMB]-CE models. The total number of queries including both anchor and nonanchor (test) queries is 3374 and the total number of items is 10031.
+
+
+(b) [EMB]-CE
+
+# B.2 Understanding poor performance of ANNCUR for $k_{i} = k_{q}$
+
+Figure 6 in §3.3 shows Top-10-Recall@500 on domain=YuGiOh for [CLS]-CE and [EMB]-CE respectively on different combinations of number of anchor queries $(k_q)$ and anchor items $(k_i)$ . Note that the performance of ANNCUR drops significantly when $k_q = k_i$ . Recall that the indexing step (§2.3) requires computing pseudo-inverse of matrix $A = M[\mathcal{Q}_{\mathrm{anc}},\mathcal{I}_{\mathrm{anc}}]$ containing scores between anchor queries $(\mathcal{Q}_{\mathrm{anc}})$ and anchor items $(\mathcal{I}_{\mathrm{anc}})$ . Performance drops significantly when $A$ is a square matrix i.e. $k_q = k_i$ as the matrix tends to be ill-conditioned, with several very small eigenvalues that are 'blown up' in $A^{\dagger}$ , the pseudo-inverse
+
+
+(a) Top-10-Recall@Cost=500
+Figure 9: Performance of ANNCUR on non-anchor/test queries on domain = YuGi0h using $U = C^{\dagger}MR^{\dagger}$ for [EMB]-CE. The total number of queries including both anchor and non-anchor (test) queries is 3374 and the total number of items is 10031.
+
+
+(b) Matrix Approx. Error
+
+of $A$ . This, in-turn, leads to a significant approximation error (Ray et al., 2022). Choosing different number of anchor queries and anchor items yields a rectangular matrix $A$ whose eigenvalues are unlikely to be small, thus resulting in much better approximation of the matrix $M$ .
+
+Oracle CUR Decomposition An alternate way of computing the matrix $U$ in CUR decomposition of a matrix $M$ for a given subset of rows $(R)$ and columns $(C)$ is to set $U = C^{\dagger}MR^{\dagger}$ . This can
+
+provide a much stable approximation of the matrix $M$ even when $k_{q} = k_{i}$ (Mahoney and Drineas, 2009). However, it requires computing all values of $M$ before computing its low-rank approximation. In our case, we are trying to approximate a matrix $M$ which also contains scores between test-queries and all items in order to avoid scoring all items using the CE model at test-time, thus we can not use $U = C^{\dagger}MR^{\dagger}$ . Figure 9 shows results for an oracle experiment where we use $U = C^{\dagger}MR^{\dagger}$ , and as expected it provides significant improvement when $k_{q} = k_{i}$ and minor improvement otherwise over using $U = M[\mathcal{Q}_{\mathrm{anc}},\mathcal{I}_{\mathrm{anc}}]^{\dagger}$ .
+
+# B.3 $k$ -NN experiment results for all domains
+
+For brevity, we show results for all top- $k$ values only for domain $\equiv$ YuGiOh in the main paper. For the sake of completeness and for interested readers, we add results for combinations of top- $k$ values, domains, and training data size values. Figure 10 - 24 contain results for top- $k\in \{1,10,50,100\}$ for domain YuGiOh, Pro_Wrestling, Doctor_Who, Star_Trek, Military, and training data size $|\mathcal{Q}_{\mathrm{train}}|\in \{100,500,2000\}$ . For Pro_Wrestling, since the domain contains 1392 queries, we use maximum value of $|\mathcal{Q}_{\mathrm{train}}| = 1000$ instead of 2000.
+
+
+
+
+(a) Top- $k$ -Recall@ $k_r$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANNCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+Figure 10: Top- $k$ -Recall results for domain=YuGiOh and $|\mathcal{Q}_{\mathrm{train}}| = 100$
+
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+Figure 11: Top- $k$ -Recall results for domain=YuGi0h and $|Q_{train}| = 500$
+
+
+
+
+(a) Top- $k$ -Recall@ $k_r$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANNCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+Figure 12: Top- $k$ -Recall results for domain=YuGiOh and $|\mathcal{Q}_{train}| = 2000$
+
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+Figure 13: Top- $k$ -Recall results for domain $\equiv$ Pro_Wrestling and $|\mathcal{Q}_{\mathrm{train}}| = 100$
+
+
+
+
+(a) Top- $k$ -Recall@ $k_r$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANNCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+Figure 14: Top- $k$ -Recall results for domain=Pro_Wrestling and $|\mathcal{Q}_{\text {train }}| = 500$
+
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+Figure 15: Top- $k$ -Recall results for domain=Pro_Wrestling and $|\mathcal{Q}_{\mathrm{train}}| = 1000$
+
+
+
+
+(a) Top- $k$ -Recall@ $k_r$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANNCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+Figure 16: Top- $k$ -Recall results for domain=Doctor_Who and $|\mathcal{Q}_{\text {train }}| = 100$
+
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+Figure 17: Top- $k$ -Recall results for domain=Doctor_Who and $|\mathcal{Q}_{\mathrm{train}}| = 500$
+
+
+
+
+(a) Top- $k$ -Recall@ $k_r$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANNCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+Figure 18: Top- $k$ -Recall results for domain=Doctor_Who and $|\mathcal{Q}_{\text {train }}| = 2000$
+
+Figure 19: Top- $k$ -Recall results for domain=Star_Trek and $|\mathcal{Q}_{\mathrm{train}}| = 100$
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+
+
+(a) Top- $k$ -Recall@ $k_r$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANNCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+Figure 20: Top- $k$ -Recall results for domain=Star_Trek and $|\mathcal{Q}_{\mathrm{train}}| = 500$
+
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+Figure 21: Top- $k$ -Recall results for domain=Star_Trek and $|\mathcal{Q}_{\mathrm{train}}| = 2000$
+
+
+
+
+(a) Top- $k$ -Recall@ $k_r$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_r)$ . The subscript $k_i$ in ANNCUR $_{k_i}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+Figure 22: Top- $k$ -Recall results for domain=Military and $|\mathcal{Q}_{\mathrm{train}}| = 100$
+
+Figure 23: Top- $k$ -Recall results for domain=Military and $|\mathcal{Q}_{\mathrm{train}}| = 500$
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+
+
+(a) Top- $k$ -Recall@ $k_{r}$ for ANNCUR and baselines when all methods retrieve and rerank the same number of items $(k_{r})$ . The subscript $k_{i}$ in ANNCUR $_{k_{i}}$ refers to the number of anchor items used for embedding the test query.
+
+
+(b) Top- $k$ -Recall for ANNCUR and baselines when all methods operate under a fixed test-time cost budget. Recall that cost is the number of CE calls made during inference for re-ranking retrieved items and, in case of ANNCUR, it also includes CE calls to embed the test query by comparing with anchor items.
+Figure 24: Top- $k$ -Recall results for domain=Military and $|\mathcal{Q}_{\mathrm{train}}| = 2000$
\ No newline at end of file
diff --git a/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/images.zip b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..a292a8200067d80cd450af475759e1d73652038f
--- /dev/null
+++ b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:142100b2f993733ad457838c4cfcff2bdd9f4a86244d55b0a1b4a939ce30d162
+size 2216784
diff --git a/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/layout.json b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..214a26dbe6b990bb56115df4080d83e4183fa1ff
--- /dev/null
+++ b/efficientnearestneighborsearchforcrossencodermodelsusingmatrixfactorization/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:bc4f79246969f4654be8a95f11ac99e6676a0d154f38cf503c6a35d7415d9f52
+size 963075
diff --git a/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_content_list.json b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..5950655ec6c6301041bd6212b95013cdf6070ff5
--- /dev/null
+++ b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:43d0b89bc80001ddd0a2a7b7fe28dc8f693bce2e21e72408426a4c2d173df69d
+size 73041
diff --git a/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_model.json b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..abb57f5e03bec66b3a4a5430521cf7e34978c2db
--- /dev/null
+++ b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:621066eb9a19018b21fd3172aed73e7187a0920df8a54c18b2cb5ab6630f90d8
+size 90407
diff --git a/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_origin.pdf b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..39c9c77603c1343c56e552e9a22c0972582bcbcb
--- /dev/null
+++ b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/092eadae-8a15-4ea6-b849-db8f9cb71745_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:563db50239ff9fdf36fe1f1bd8b3cd9532b09fc38ff236a8fe7dd822f48ba142
+size 1110064
diff --git a/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/full.md b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..5bd6cdb96a2cf308849c7d1eb901d3fd8bc1a218
--- /dev/null
+++ b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/full.md
@@ -0,0 +1,301 @@
+# Efficient Pre-training of Masked Language Model via Concept-based Curriculum Masking
+
+Mingyu Lee $^{1*}$ , Jun-Hyung Park $^{2*}$ , Junho Kim $^{1}$ , Kang-Min Kim $^{3}$ , SangKeun Lee $^{1,2}$
+
+$^{1}$ Department of Artificial Intelligence $^{2}$ Department of Computer Science and Engineering Korea University, Seoul, Republic of Korea
+
+$^{3}$ Department of Data Science, The Catholic University of Korea, Bucheon, Republic of Korea {decon9201. irish07. monocrat}@korea.ac.kr
+
+kangmin89@catholic.ac.kr, yalphy@korea.ac.kr
+
+# Abstract
+
+Masked language modeling (MLM) has been widely used for pre-training effective bidirectional representations, but incurs substantial training costs. In this paper, we propose a novel concept-based curriculum masking (CCM) method to efficiently pre-train a language model. CCM has two key differences from existing curriculum learning approaches to effectively reflect the nature of MLM. First, we introduce a carefully-designed linguistic difficulty criterion that evaluates the MLM difficulty of each token. Second, we construct a curriculum that gradually masks words related to the previously masked words by retrieving a knowledge graph. Experimental results show that CCM significantly improves pre-training efficiency. Specifically, the model trained with CCM shows comparative performance with the original BERT on the General Language Understanding Evaluation benchmark at half of the training cost. Code is available at https://github.com/KoreaMGLEE/Concept-based-curriculum-masking.
+
+# 1 Introduction
+
+Self-supervised pre-training has achieved considerable performance improvements in various natural language processing (NLP) tasks (Devlin et al., 2019; Yang et al., 2019; Zhang et al., 2019; Lewis et al., 2020; Clark et al., 2020). Masked language modeling (MLM) (Devlin et al., 2019), where the model predicts original tokens of a masked subset of the text using the unmasked subset as clues, has contributed significantly to these improvements. However, MLM typically requires a high number of compute operations, resulting in unrealistically large training costs (Clark et al., 2020). Therefore, the consideration on the pre-training costs has become an increasingly important issue (Jiang et al., 2020; Narayanan et al., 2021).
+
+| Methods | CoLA | MRPC | SST | Avg. |
| No curriculum | 44.9 | 85.4 | 89.6 | 73.3 |
| Rarity | 45.5 | 85.1 | 89.4 | 73.4 |
| Length | 41.6 | 86.3 | 89.4 | 72.4 |
| Masking ratio | 43.2 | 87.0 | 89.7 | 73.3 |
| CCM (ours) | 48.0 | 86.7 | 90.9 | 75.2 |
+
+Table 1: Comparison of different CL methods with $\mathrm{BERT}_{\mathrm{Medium}}$ . rarity denotes a curriculum that first learns sentences composed with frequent words. Length denotes a curriculum that incrementally increases the sequence length from 64 to 512. Masking ratio denotes a curriculum that increases the masking ratio linearly from 0.1 to 0.15.
+
+Recent NLP studies have shown that curriculum learning (CL), presenting examples in an easy-to-difficult order rather than presenting them randomly, can accelerate the model convergence and improve the generalization performance (Zhang et al., 2018; Tay et al., 2019; Zhan et al., 2021). There mainly exist two criteria for assessing the difficulty of examples, 1) model-based criteria (Zhou et al., 2020; Xu et al., 2020) and 2) linguistic-inspired criteria (Sachan and Xing, 2016; Tay et al., 2019; Nagatsuka et al., 2021; Campos, 2021). Model-based criteria measure the difficulty of each example using task-specific models. However, these criteria are unsuitable for reducing the computation cost of pre-training, given that they require calculating the loss of every example in a large pretraining corpus using language models. In contrast, linguistic-inspired criteria can efficiently assess the difficulty of examples based on prior knowledge and rules. Therefore, we adopt CL with linguistic difficulty criteria into MLM to improve the efficiency of pre-training.
+
+However, we argue that existing linguistics-inspired criteria, such as length, rarity, and masking ratio of a sequence, do not effectively reflect the nature of MLM, as verified empirically in Table 1.
+
+The difficulty associated with MLM is significantly affected by the choice of tokens to be masked in the given sequence, rather than by the given sequence itself. For example, given "The man is a Stanford student", we can easily predict that the masked token would be University, whereas given "The man is a University student", it would be relatively difficult to predict the original token due to the insufficient clues in the context. Then, how can we measure the MLM difficulty? MLM can be viewed as predicting masked tokens based on other contextual tokens related to masked tokens. Therefore, if a word is related to many other words and phrases, it is likely that it has several clues in the context that make MLM easier.
+
+In this paper, we propose a novel concept-based curriculum masking (CCM) for improving pretraining efficiency by considering the nature of MLM. We consider words and phrases that are related to several other concepts as easy ones and define them as the initial concepts to be masked first. To identify them, we utilize millions of syntactic and semantic relationships between words or phrases, referring as concepts, within a large-scale knowledge graph, ConceptNet (Speer et al., 2017). First, we measure the number of related concepts for each concept in ConceptNet and construct the set of concepts with the highest number, which will be masked during the first stage of our curriculum. Then, we gradually mask concepts related to the previously masked concepts during the consecutive stages, inspired by human language acquisition, in which simple concepts are learned first and more complex concepts are gradually learned (Anglin, 1978; Horton and Markman, 1980).
+
+To verify the effectiveness of the proposed curriculum, we conduct experiments on the General Language Understanding Evaluation (GLUE) benchmark (Wang et al., 2019). Experimental results show that CCM significantly improves the pre-training efficiency of MLM. Particularly, CCM only requires $50\%$ of the computational cost in achieving the comparable GLUE score with MLM, using the same $\mathrm{BERT_{Base}}$ architecture. In addition, by training on commensurate computational cost as if MLM, CCM outperforms MLM by 1.9 points on the GLUE average score. The contributions of our study are as follows:
+
+- We investigate and demonstrate the effectiveness of CL for pre-training. To the best of our
+
+knowledge, our work is one of the few that introduces CL to MLM.
+
+- We propose a novel curriculum masking framework that progressively masks concepts based on our relation-based difficulty criteria.
+- We demonstrate that our framework significantly improves the pre-training efficiency of MLM through extensive experiments on the GLUE benchmark.
+
+# 2 Related Work
+
+# 2.1 Self-supervised Pre-training
+
+Self-supervised pre-training has been employed to learn universal language representations from large corpora (Collobert et al., 2011; Pennington et al., 2014). Recently, BERT (Devlin et al., 2019) has achieved tremendous success in various NLP tasks by learning bidirectional representations via MLM. Variants of BERT have been proposed to further improve the performance in NLP tasks. Yang et al. (2019) have used an input sequence autoregressively and randomly generated to alleviate the mismatch caused by the masked tokens that appear only during pre-training. Zhang et al. (2019) have incorporated external knowledge graphs into the language model to introduce structural knowledge. Sun et al. (2019) and Joshi et al. (2020) have masked contiguous tokens to improve the span representation. Lewis et al. (2020) have replaced multiple tokens with one mask token for noise flexibility. Levine et al. (2021) have masked highly collocating n-grams in the corpus for preventing the model to use shallow local signals. Although these studies have resulted in significant performance improvements in NLP tasks, they still incur tremendous computing costs (Qiu et al., 2020). To the best of our knowledge, there are only limited studies that have explored the improvement of MLM pretraining efficiency.
+
+# 2.2 Curriculum Learning
+
+In the domain of machine learning, CL is a training strategy that gradually learns the complex examples after learning the easy ones, instead of learning all data simultaneously, which has been firstly proposed by (Bengio et al., 2009). The concept of CL can be traced back to Elman (1993) that has attempted to train machines from easy to difficult
+
+
+Figure 1: Illustration of CCM. In the first stage, CCM masks the initial concepts. Then it progressively includes the concepts within $k$ -hops from the concepts used in the previous stages. Note that, "S" represents a set of concepts to be masked, "O" represents the original token sequence, and "M" represents a masked token sequence.
+
+tasks. Krueger and Dayan (2009) have tried to divide complex tasks into easy sub-tasks, and then trained machines on these sub-tasks.
+
+Recent studies have shown that a curriculum-based approach can improve the convergence speed and generalization performance of NLP systems (Sachan and Xing, 2016; Zhang et al., 2018; Tay et al., 2019; Zhou et al., 2020; Zhan et al., 2021). The identification of easy samples in a given training dataset is important in applying CL to a target task (Kumar et al., 2010). There are two main strategies for assessing the data difficulty; 1) using human prior knowledge regarding specific tasks (Zhang et al., 2018; Tay et al., 2019; Zhan et al., 2021), and 2) using trained models to measure the difficulty of examples (Zhou et al., 2020; Xu et al., 2020). However, existing difficulty criteria do not work well with CL for MLM, as they have overlooked that the MLM difficulty of examples can be changed according to which tokens are masked. To better assess the difficulty of MLM, we propose a novel curriculum that intervenes in the masking process based on the relation-based difficulty criteria.
+
+# 3 Concept-based Curriculum Masking
+
+Our curriculum framework is inspired by the human language acquisition. People learn simple concepts (e.g., car) first and then gradually learn more complex concepts (e.g., self-driving car). By leveraging the related basic concepts, the gradual learning style enables humans to learn abstract concepts easily (Anglin, 1978; Horton and Markman, 1980). To mimic this, we construct a multi-stage
+
+curriculum by gradually adding concepts relating to the initial concepts using a knowledge graph. To this end, our CCM framework consists of three processes: initial concept selection, curriculum construction, and pre-training.
+
+In the following sections, we denote a knowledge graph as $G = (N,E)$ , where $N$ and $E$ are sets of nodes and edges, respectively. We define a word or phrase corresponding to a node as a concept $c \in N$ . We denote $S_{i}$ as the set of concepts to be masked in the $i$ -th stage. The final curriculum includes multiple stages $\{S_{1}\dots S_{K}\}$ .
+
+# 3.1 Initial Concept Selection
+
+A key for CL is to learn easy examples first. Considering that MLM is the task for predicting a masked subset of a text using the surrounding context, we suppose concepts related to many others are easy concepts. Thus, we construct a set of initial concepts for masking by selecting concepts that have the highest degree of connection in the knowledge graph. To select the initial concepts, we first rank each concept $c \in N$ according to the degree of connection in the knowledge graph $G$ . In addition, we exclude concepts that appear less than 100k times in the pre-training corpus, since frequent concepts are more influential in learning their related concepts than rare concepts. Then, given the predefined number of initial concepts $M$ , the top $M$ concepts are selected.
+
+# 3.2 Curriculum Construction
+
+In this section, we describe how to arrange the learning stages based on the knowledge graph $G$ . The set of concepts to be masked in the $i$ -th stage, $S_{i}$ , is constructed following the principle
+
+# $S_{i}$ is constructed by progressively expanding $S_{i - 1}$ to concepts that are related to concepts in $S_{i - 1}$ .
+
+This facilitates to utilize previously learned concepts as clues for modeling new related concepts like human language acquisition. We identify related concepts using the relationships in the knowledge graph. Intuitively, the more closely connected the two concepts are in the knowledge graph, the more related they are. For example, as shown in Figure 1, given a concept University, student and Stanford (1-hop distance) are more related than man (2-hop distance). Consequently, student or Stanford may be utilized as a stronger predictive clue than man, such as in the sentence "The man is a Stanford student" where University is masked.
+
+Based on the principle, we gradually mask concepts connected to previously learned concepts within $k$ -hops in the knowledge graph throughout curriculum stages as follows:
+
+$$
+S _ {i} = S _ {i - 1} \cup N _ {k} \left(S _ {i - 1}\right) \tag {1}
+$$
+
+Here, $N_{k}(S_{i - 1})$ denotes the set of concepts, each concept of which is within $k$ -hops from $s \in S_{i - 1}$ .
+
+# 3.3 Pre-training
+
+To introduce concept-based curriculum masking into pre-training language models, we first search for concepts included in $S_{i}$ for each $i$ -th stage from the token sequences in the pre-training corpus and then mask identified concepts for MLM training.
+
+Concept search We first compile a lexicon of concepts. Specifically, from the knowledge graph, we extract the concepts of less than 5 words that occur over 10 times in the pre-training corpus. Then we search for the extracted concepts from the token sequences in the pre-training corpus by string match. The cost of this process is negligible compared to MLM as it is conducted only once during pre-processing.2
+
+# Algorithm 1 Curriculum Masking Scheme
+
+Input: Concept-based curriculum $\{S_{1}\dots S_{K}\}$ , language model parameters $\theta$ , input data $D$ , maximum training step $\tau$ , dynamic masking probability $p_d$
+
+1: for token sequence $T$ in $D$ do
+2: Search concepts $c$ in $T$ .
+3: Ordered concepts according to $\{S_1\ldots S_K\}$
+4: end for
+5: Initialize $\theta$
+6: while step $< \tau$ do
+7: for stage $i = 1,\dots ,K$ do
+8: Generate examples $e$ by masking $c$ ( $c \in S_i$ and $c \in T$ ) based on a rate of $p_d$ .
+9: Training the model on $e$ .
+10: end for
+11: end while
+12: return Trained model parameters $\theta$
+
+Concept masking After searching for the concepts, we mask the token sequences following our curriculum. We introduce whole concept masking (WCM) that masks all the tokens consisting of a single concept simultaneously. For example, if we mask the concept Stanford, all the tokens Stan and ##ford will be masked together. Following the masking strategy in (Devlin et al., 2019), $80\%$ of the total masked concepts are replaced into mask tokens, and $10\%$ into random tokens, and the rest are not replaced.
+
+The number of identified concepts changes significantly for each stage and sentence. Hence, the static masking probability often leads to either too little or too much masking. Therefore, we dynamically calculate a masking probability $p_d$ to mask approximately $15\%$ of the total tokens for each sequence.
+
+In addition, even if a concept includes other concepts in a given input, all the concepts are treated independently. For example, if two concepts Stanford University and Stanford appear in a sequence, each concept is masked independently. The entire CCM process is presented in Algorithm 1.
+
+# 4 Experiment
+
+We examine the efficacy of CCM using the BERT architectures (Devlin et al., 2019). We measure the performance of the pre-trained models on the GLUE benchmark (Wang et al., 2019).
+
+
+(a) Small-sized model
+
+
+(b) Medium-sized model
+Figure 2: Comparison of MLM and CCM on different-sized BERT models. The reported results are average scores on the GLUE benchmark with respect to steps.
+
+
+(c) Base-sized model
+
+| Model | Method | Params | CoLA | SST | MRPC | STS | RTE | MNLI | QQP | QNLI | Avg. |
| BERTSmall | MLM | 14M | 38.0 | 88.7 | 82.8 | 82.0 | 59.2 | 76.8 | 88.4 | 85.8 | 75.2 |
| CCM (ours) | 14M | 42.8 | 89.1 | 84.1 | 83.3 | 61.3 | 77.5 | 88.6 | 86.3 | 76.6 |
| BERTMedium | MLM | 26M | 44.9 | 89.6 | 85.4 | 82.7 | 60.3 | 78.9 | 89.4 | 87.6 | 77.4 |
| CCM (ours) | 26M | 48.0 | 90.9 | 86.7 | 83.6 | 61.4 | 80.0 | 89.2 | 87.6 | 78.4 |
| BERTBase | MLM | 110M | 49.7 | 90.8 | 87.8 | 85.4 | 67.8 | 81.7 | 90.4 | 89.5 | 80.4 |
| CCM (ours) | 110M | 60.3 | 93.1 | 88.3 | 85.5 | 65.0 | 84.1 | 91.0 | 91.4 | 82.3 |
+
+Table 2: Results of small, medium, and large-sized models on the development sets of GLUE.
+
+# 4.1 Experimental Settings
+
+In the experiments, we denote the token embedding size as $E$ , hidden dimension size as $H$ , number of layers as $L$ , intermediate layer size of the feed-forward module as $F$ , and the number of self-attention heads as $A$ , respectively. We report experimental results on three model sizes: Small ( $E = 128$ , $H = 256$ , $L = 12$ , $F = 1024$ , $A = 4$ , 14M parameters), Medium ( $E = 128$ , $H = 384$ , $L = 12$ , $F = 1536$ , $A = 8$ , 26M parameters), and Base ( $E = 768$ , $H = 768$ , $L = 12$ , $F = 3072$ , $A = 12$ , 110M parameters). We conduct experiments with four RTX A5000 GPUs.
+
+Pre-training. Since the performance of pretrained language models heavily depends on the corpus size, we manually pre-train all the BERT models using CCM and MLM on the BERT pretraining corpus released in HuggingFace Datasets3, including BooksCorpus (Zhu et al., 2015) and the English Wikipedia to ensure a fair comparison. We pre-train small and medium-sized models for 1M steps with a batch size of 128, a sequence length of 128, and a maximum learning rate of 5e-4. Furthermore, we pre-train base-sized models for 1M steps with a batch size of 256, a sequence length
+
+of 128, and a maximum learning rate of 1e-4. We use Adam as optimizer with $\beta_{1} = 0.9$ , $\beta_{2} = 0.999$ , and L2 weight decay of 0.01. For pre-training, after a warmup of 10k steps, we used a linear learning rate decay. It is noteworthy that during CCM, we warmup for 100k steps using MLM and then train 100k steps for each stage. When the final stage ends, the model returns to the MLM stage and repeats the curriculum for the remaining steps. In these experiments, we use a four-stage curriculum, where the final stage can mask all concepts and all words that do not comprise a concept. We pre-train 3 randomly initialized models and use the model with the lowest validation MLM loss.
+
+Evaluation. We evaluate our pre-trained models on the GLUE benchmark. The GLUE benchmark consists of eight datasets for the evaluation of natural language understanding systems: RTE (Giampiccolo et al., 2007) and MNLI (Williams, 1992) cover textual entailment; QNLI (Rajpurkar et al., 2016) covers question-answer entailment; MRPC (Dolan and Brockett, 2005) covers paraphrase; QQP covers question paraphrase; STS (Cer et al., 2017) covers textual similarity; SST (Socher et al., 2013) covers sentiment; and CoLA (Warstadt et al., 2019) covers linguistic acceptability. We use the Mathew correlation for CoLA, Spearman cor
+
+| Model | Method | GLUE |
| BERTMedium | CCM (ours) | 78.4 |
| w/o CL | 76.8 |
| w/o CL, WCM | 77.4 |
+
+relation for STS, and accuracy for the rest of the tasks as evaluation metrics. We further report an average score over the eight tasks.
+
+We fine-tune the pre-trained models on CoLA, MRPC, SST, QQP, QNLI, and MNLI for three epochs while STS and RTE for 10 epochs. For each task, we select the best fine-tuned learning rates (among the 5e-5, 4e-5, 3e-5, and 2e-5 following the setting in Devlin et al. (2019)) on the development sets. In addition, we run five random restarts and report the median score. For each random restart, we use the same checkpoint but with different data shuffling and classifier initialization methods. Note that we conduct all experiments using a single model, not using an ensemble.
+
+# 4.2 GLUE Results
+
+As aforementioned, the goal of CCM is to accelerate the pre-training convergence. By examining the performance of models on the GLUE benchmark after every 100k steps, we demonstrate that CCM accelerates model convergence speed.
+
+Figure 2 shows the learning curves of different size models on the GLUE benchmark. We observe that CCM allows all models to achieve baseline performance with significantly less computation. In particular, CCM outperforms MLM at $50\%$ of the computational cost with base-sized models. In addition, we can observe that CCM is more effective with a larger model. With a small-sized model, CCM shows slightly lower performance during the initial pre-training steps. We speculate that concept-wise masking may be too hard for a small-sized model, resulting in a degradation of convergence speed. Nevertheless, after training with enough iterations, CCM can achieve the GLUE scores of MLM with fewer training steps.
+
+Table 2 shows the performance of the models pretrained for 1M steps on each GLUE task. We can observe that CCM allows all models to outperform their baselines on all tasks, except for $\mathrm{BERT}_{\mathrm{Base}}$
+
+Table 3: Ablation studies of CCM using medium-sized BERT architecture. Here, "WCM" represents whole concept masking and "CL" represents curriculum learning.
+
+| Methods | CoLA | MRPC | SST | Avg. |
| No curriculum | 44.9 | 85.4 | 89.6 | 73.3 |
| Rarity | 45.5 | 85.1 | 89.4 | 73.4 |
| Length | 41.6 | 86.3 | 89.4 | 72.4 |
| Reverse | 29.0 | 83.6 | 87.6 | 66.7 |
| Masking ratio | 43.2 | 87.0 | 89.7 | 73.3 |
| Teacher review | 48.0 | 85.4 | 89.9 | 74.4 |
| CCM (ours) | 48.0 | 86.7 | 90.9 | 75.2 |
+
+Table 4: Comparison of different curriculum designs with $\mathrm{BERT}_{\mathrm{Medium}}$
+
+on RTE. Specifically, CCM-applied $\mathrm{BERT}_{\mathrm{Small}}$ and $\mathrm{BERT}_{\mathrm{Medium}}$ outperform their baselines by 1.4 points and 1.0 points on the GLUE average score, respectively, when fully trained. CCM-applied $\mathrm{BERT}_{\mathrm{Base}}$ achieves the best performance improvement on GLUE average score. Although CCM-applied $\mathrm{BERT}_{\mathrm{Base}}$ shows worse performance on RTE, possibly due to the significantly different concept distribution compared with the pre-training corpus, we have observed CCM-applied $\mathrm{BERT}_{\mathrm{Base}}$ finally outperforms the baseline performance with slightly more training steps.
+
+# 5 Analysis
+
+# 5.1 Ablation Study
+
+To investigate the contribution of each component in CCM, we conduct ablation studies for whole concept masking (WCM) and CL. The ablation study is conducted with medium-sized models and GLUE scores are reported. The GLUE score is the average score of all eight tasks. As shown in Table 3, we can observe that CCM achieves the best GLUE scores when using both CL and WCM while having the worst score with the setting without CL. These results indicate that CL greatly contributes to the improvements in pre-training efficiency.
+
+# 5.2 Effect of the Curriculum
+
+To demonstrate our curriculum design choice, we compare it with the non-curriculum and other curriculum-based approaches on $\mathrm{BERT}_{\mathrm{Medium}}$ . For comparison with other curricula, we adopt rarity, length, reverse, masking ratio, and teacher review as baselines. All curriculum-based approaches use the same curriculum configuration (e.g., the number of stages) unless mentioned otherwise.
+
+Rarity. We adopt the rarity of concepts in the training corpus as a difficulty metric, similar to
+
+those used in (Tay et al., 2019). We initially train the model with the most frequent concepts in the training corpus, and then progressively add the less frequent ones.
+
+Length. We first train the model on short token sequences and then progressively train on longer sequences. Following (Campos, 2021), we initially use a sequence length of 64, then gradually increase the length to 128, 256, and 512 at the end of each epoch.
+
+Reverse. For comparison with a hard-to-easy curriculum, we train the model with the reverse order of curriculum in CCM. Specifically, MLM is used to warmup the hard-to-easy model for 100k steps, subsequently, we train the model from stage 3 to stage 1.
+
+Teacher review. For teacher review, the BERTBase model is used as the teacher. We use the MLM loss from the pre-trained teacher as the difficulty score (Xu et al., 2020) and distribute examples according to the measured difficulty.
+
+Masking ratio. For the masking ratio curriculum, we only mask $10\%$ of the first full sequence. Subsequently, we increase the masking ratio linearly to $15\%$ of tokens when 1M is reached.
+
+Results. As shown in Table 4, all curriculum-based approaches except the reverse curriculum improve generalization performance on various tasks compared to non-curriculum. The hard-to-easy curriculum shows a significant performance degradation. A possible reason could be that concepts added in the last step are too difficult for language models to learn without prior learning any relevant concepts, leading to the degradation of convergence speed. Finally, our CCM outperforms all other approaches in the experiment on the GLUE tasks. These results indicate that our curriculum for progressively learning relevant concepts is effective to improve pre-training efficiency.
+
+# 5.3 Difficulty of Curriculum Stages
+
+Most CL studies argue that the generalization performance and convergence speed are improved when training models in an easy-to-difficult order. To examine whether our curriculum arranges examples in an easy-to-difficult order as in Bengio et al. (2009), we measure the difficulty of examples in each stage of our curriculum. For measuring the difficulty of examples, we report training loss
+
+
+Figure 3: Training curve of the medium-sized models on pre-training. We report the training loss at every hundred steps.
+
+ | Loss mean |
| Warmup | 1.95±0.61 |
| Stage 1 | 1.89±0.53 |
| Stage 2 | 2.50±0.95 |
| Stage 3 | 2.72±1.14 |
| Stage 4 | 2.42±0.93 |
+
+Table 5: Inference loss of MLM-applied BERTBase for each curriculum stage.
+
+of the CCM-applied $\mathrm{BERT}_{\mathrm{Medium}}$ model at every hundred steps. In addition, we evaluate a mean loss of 3,000 examples for each stage using pre-trained $\mathrm{BERT}_{\mathrm{Base}}$ , consistent with Xu et al. (2020).
+
+Figure 3 shows a training curve of CCM-applied $\mathrm{BERT}_{\mathrm{Medium}}$ . We observe a trend of increasing losses from stage 1 to stage 4 during training, which validates that our curriculum effectively trains the model in an easy-to-difficult order. In addition, Table 5 shows the inference MLM loss of pre-trained BERT. In Table 5, we also observe a similar tendency to Figure 3, except for stage 4. We expect that this is due to the difference in the masking distribution on which the model is trained in this experiment.
+
+# 5.4 Analysis of Initial Concept
+
+We analyze the effect of the number of initial concepts and the selection criteria in medium-sized models to gain a better understanding of the initial concept. The detailed results are presented in Table 6, Table 7, and Figure 4.
+
+Effect of the number of concepts. We first investigate the effect of the number of initial concepts
+
+| #concepts | CoLA | MRPC | SST | Avg. |
| MLM | 44.9 | 85.4 | 89.6 | 73.3 |
| 1k | 47.6 | 85.1 | 88.9 | 73.8 |
| 3k | 48.0 | 86.7 | 90.9 | 75.2 |
| 5k | 46.8 | 86.2 | 90.7 | 74.5 |
| 10k | 46.6 | 86.1 | 90.7 | 74.4 |
+
+Table 6: Comparison of different number of initial concepts.
+
+| Initial concepts | CoLA | MRPC | SST | Avg. |
| HF | 44.3 | 85.9 | 89.1 | 73.1 |
| RC | 47.7 | 86.1 | 89.3 | 74.3 |
| HF, RC | 48.0 | 86.7 | 90.9 | 75.2 |
+
+by changing the number of the first stage concepts from 1k to 10k and analyze the impact on the performance. As shown in Table 6, the highest and lowest performances are obtained when the number of concepts is 3k, and 1k, respectively. Specifically, in the case of 1k, CCM does not have any improvement over the MLM baseline in SST and MRPC tasks. These results imply that some enough number of initial concepts should be learned for our method to be effective (e.g., 3k in our experimental setting).
+
+Effect of selection criteria. To investigate the influence of the criteria for selecting the easiest concepts, we compare with the criteria of selecting the easiest concepts from 1) many related concepts, 2) high-frequency concepts, and 3) high frequency-many related concepts. As shown in Table 7, our criterion for high frequency-many related concepts performs the best among other criteria. In addition, Figure 4 shows examples of concepts classified by the above criteria. It shows that when a concept is selected only by frequency, stopwords such as an or the would be included, and when selecting only by the number of related concepts, many academic terms such as carbohydrate would be included in the initial concepts. These results indicate that concepts that satisfy both criteria simultaneously are easier to learn and helpful in learning other concepts later.
+
+
+Figure 4: A plotted graph demonstrating some concrete examples of concepts according to the balance between the "frequency" and the "number of related concepts". Each color represents a group of classes. For example, red refers to concepts with a high frequency but a low number of related concepts.
+
+Table 7: Comparison of different criteria for initial concepts. Here, "HF" represents high frequency and "RC" represents the number of related concepts.
+
+| Methods | MRPC | SST | STS | Avg. |
| CCM1-hop | 85.8 | 89.9 | 83.6 | 86.4 |
| CCM2-hop | 86.7 | 90.9 | 83.6 | 87.0 |
| CCM3-hop | 84.9 | 89.2 | 82.8 | 85.6 |
| CCM4-hop | 85.1 | 89.1 | 82.2 | 85.5 |
+
+Table 8: Comparison of different hops.
+
+# 5.5 Analysis on Different Hops
+
+In this work, we add the concepts within 2-hop when creating the curriculum to form the next stage concept set. In this section, we compare the 2-hop strategy with the hop strategies of other numbers on $\mathrm{BERT}_{\mathrm{Medium}}$ . We only report the performance from 1-hop to 4-hop given that observation of the results from 5-hop shows a negligible difference.
+
+The results are shown in Table 8. It is observed that $\mathrm{CCM}_{2\text{-hop}}$ outperforms the other strategies. We observe that $\mathrm{CCM}_{1\text{-hop}}$ comprises too few concepts at the second stage, leading to the degradation of generalization performance. By contrast, $\mathrm{CCM}_{3\text{-hop}}$ and $\mathrm{CCM}_{4\text{-hop}}$ already comprise almost all concepts in the second stage, and thus fail to learn concepts progressively.
+
+# 5.6 Number of Curriculum Stages
+
+Table 9 shows the results of the CCM experiments according to the different number of curriculum stages. In this experiment, we expand the concepts within 2-hops at every stage, and at the last stage of all curricula, the concept set includes all the con
+
+ | MRPC | SST | STS | Avg. |
| 2 stage | 84.5 | 90.5 | 83.3 | 86.4 |
| 3 stage | 85.1 | 90.7 | 84.4 | 86.7 |
| 4 stage(w/o warmup) | 82.1 | 89.7 | 83.2 | 85.0 |
| 4 stage | 86.7 | 90.9 | 83.6 | 87.0 |
| 5 stage | 85.7 | 90.5 | 83.8 | 86.6 |
+
+Table 9: Comparison of numbers of curriculum stages.
+
+cepts in the knowledge graph. Experimental results show the highest performance when the curriculum is composed of four stages. We find that few concepts are added after 4 stages, and speculate that this undermines curriculum effectiveness.
+
+# 6 Conclusion
+
+In this work, we have proposed CCM that masks easy concepts first and gradually masks related concepts to the previously masked ones for language model pre-training. With the help of our carefully designed linguistic difficulty criteria and curriculum construction, CCM can offer an effective masking schedule for MLM. The experimental results demonstrate that our curriculum improves convergence speeds and the generalization performance of MLM.
+
+# 7 Limitations
+
+CCM has achieved impressive results in improving the efficiency of the LM pre-training, but some limitations need to be tackled in future work. First, we have not tested the efficacy of other knowledge graphs such as Wikidata. We believe that utilizing several knowledge graphs jointly would expand the coverage of concepts and relations.
+
+Furthermore, although we think all the relationship in the knowledge graph reflects the relevance between concepts, it is necessary to study the degree to which each relationship reflects the relevance between concepts. The concepts connected by specific relationships may benefit more from previous learning than concepts connected by others. We plan to construct a more sophisticated curriculum by handling each relationship differently.
+
+# 8 Acknowledgement
+
+We thank the anonymous reviewers for their helpful comments. This work was supported by the Basic Research Program through the National Research Foundation of Korea (NRF) grant funded by the
+
+Korea government (MSIT) (2020R1A4A1018309), National Research Foundation of Korea (NRF) grant funded by the Korea government (MSIT) (2021R1A2C3010430) and Institute of Information communications Technology Planning Evaluation (IITP) grant funded by the Korea government (MSIT) (No. 2019-0-00079, Artificial Intelligence Graduate School Program (Korea University)).
+
+# References
+
+Jeremy M. Anglin. 1978. From reference to meaning. Child Development, 49:969-976.
+Yoshua Bengio, Jérôme Louradour, Ronan Collobert, and Jason Weston. 2009. Curriculum learning. In Proceedings of the 26th Annual International Conference on Machine Learning, pages 41-48.
+Daniel Campos. 2021. Curriculum learning for language modeling. Computing Research Repository, abs/2108.02170.
+Daniel M. Cer, Mona T. Diab, Eneko Agirre, Inigo Lopez-Gazpio, and Lucia Specia. 2017. Semeval-2017 task 1: Semantic textual similarity multilingual and crosslingual focused evaluation. In Proceedings of the 11th International Workshop on Semantic Evaluation, pages 1-14.
+Kevin Clark, Minh-Thang Luong, Quoc V. Le, and Christopher D. Manning. 2020. ELECTRA: pretraining text encoders as discriminators rather than generators. In 8th International Conference on Learning Representations.
+Ronan Collobert, Jason Weston, Léon Bottou, Michael Karlen, Koray Kavukcuoglu, and Pavel P. Kuksa. 2011. Natural language processing (almost) from scratch. J. Mach. Learn. Res., 12:2493-2537.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 4171-4186.
+William B. Dolan and Chris Brockett. 2005. Automatically constructing a corpus of sentential paraphrases. In Proceedings of the Third International Workshop on Paraphrasing.
+Jeffrey L. Elman. 1993. Learning and development in neural networks: the importance of starting small. Cognition, 48:71-99.
+Danilo Giampiccolo, Bernardo Magnini, Ido Dagan, and Bill Dolan. 2007. The third PASCAL recognizing textual entailment challenge. In Proceedings of the ACL-PASCAL workshop on textual entailment and paraphrasing, pages 1-9.
+
+Marjorie S. Horton and Ellen M. Markman. 1980. Developmental differences in the acquisition of basic and superordinate categories. *Child Development*, 51:708-719.
+Zihang Jiang, Weihao Yu, Daquan Zhou, Yunpeng Chen, Jiashi Feng, and Shuicheng Yan. 2020. Convbert: Improving BERT with span-based dynamic convolution. In Advances in Neural Information Processing Systems 33.
+Mandar Joshi, Danqi Chen, Yinhan Liu, Daniel S. Weld, Luke Zettlemoyer, and Omer Levy. 2020. Spanbert: Improving pre-training by representing and predicting spans. Trans. Assoc. Comput. Linguistics, 8:64-77.
+Kai A. Krueger and Peter Dayan. 2009. Flexible shaping: how learning in small steps helps. Cognition, 110:380-394.
+M. Pawan Kumar, Benjamin Packer, and Daphne Koller. 2010. Self-paced learning for latent variable models. In Advances in Neural Information Processing Systems 23, pages 1189-1197.
+Yoav Levine, Barak Lenz, Opher Lieber, Omri Abend, Kevin Leyton-Brown, Moshe Tennenholtz, and Yoav Shoham. 2021. Pmi-masking: Principled masking of correlated spans. In Proceedings of 9th International Conference on Learning Representations.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880.
+Koichi Nagatsuka, Clifford Broni-Bediako, and Masayasu Atsumi. 2021. Pre-training a BERT with curriculum learning by increasing block-size of input text. In Proceedings of the International Conference on Recent Advances in Natural Language Processing, pages 989-996.
+Deepak Narayanan, Mohammad Shoeybi, Jared Casper, Patrick LeGresley, Mostofa Patwary, Vijay Korthikanti, Dmitri Vainbrand, Prethvi Kashinkunti, Julie Bernauer, Bryan Catanzaro, Amar Phanishayee, and Matei Zaharia. 2021. Efficient large-scale language model training on GPU clusters using megatron-lm. In Proceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis, pages 1-58.
+Jeffrey Pennington, Richard Socher, and Christopher D. Manning. 2014. Glove: Global vectors for word representation. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing, pages 1532-1543.
+
+Xipeng Qiu, Tianxiang Sun, Yige Xu, Yunfan Shao, Ning Dai, and Xuanjing Huang. 2020. Pre-trained models for natural language processing: A survey. CoRR, abs/2003.08271.
+Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. 2016. Squad: 100,000+ questions for machine comprehension of text. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2383-2392.
+Mrinmaya Sachan and Eric P. Xing. 2016. Easy questions first? A case study on curriculum learning for question answering. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880.
+Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Y. Ng, and Christopher Potts. 2013. Recursive deep models for semantic compositionality over a sentiment treebank. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, pages 1631-1642.
+Robyn Speer, Joshua Chin, and Catherine Havasi. 2017. Conceptnet 5.5: An open multilingual graph of general knowledge. In Proceedings of the Thirty-First AAAI Conference on Artificial Intelligence, pages 4444-4451.
+Yu Sun, Shuohuan Wang, Yu-Kun Li, Shikun Feng, Xuyi Chen, Han Zhang, Xin Tian, Danxiang Zhu, Hao Tian, and Hua Wu. 2019. ERNIE: enhanced representation through knowledge integration. CoRR, abs/1904.09223.
+Yi Tay, Shuohang Wang, Anh Tuan Luu, Jie Fu, Minh C. Phan, Xingdi Yuan, Jinfeng Rao, Siu Cheung Hui, and Aston Zhang. 2019. Simple and effective curriculum pointer-generator networks for reading comprehension over long narratives. In Proceedings of the 57th Conference of the Association for Computational Linguistics, pages 4922-4931.
+Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R. Bowman. 2019. GLUE: A multi-task benchmark and analysis platform for natural language understanding. In 7th International Conference on Learning Representations.
+Alex Warstadt, Amanpreet Singh, and Samuel R. Bowman. 2019. Neural network acceptability judgments. Trans. Assoc. Comput. Linguistics, 7.
+Ronald J. Williams. 1992. Simple statistical gradient-following algorithms for connectionist reinforcement learning. Mach. Learn., 8.
+Benfeng Xu, Licheng Zhang, Zhendong Mao, Quan Wang, Hongtao Xie, and Yongdong Zhang. 2020. Curriculum learning for natural language understanding. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6095-6104.
+
+Zhilin Yang, Zihang Dai, Yiming Yang, Jaime G. Carbonell, Ruslan Salakhutdinov, and Quoc V. Le. 2019. Xlnet: Generalized autoregressive pretraining for language understanding. In Advances in Neural Information Processing Systems 32, pages 5754-5764.
+Runzhe Zhan, Xuebo Liu, Derek F. Wong, and Lidia S. Chao. 2021. Meta-curriculum learning for domain adaptation in neural machine translation. In Proceedings of Thirty-Fifth AAAI Conference on Artificial Intelligence, pages 14310-14318.
+Xuan Zhang, Gaurav Kumar, Huda Khayrallah, Kenton Murray, Jeremy Gwynnp, Marianna J. Martindale, Paul McNamee, Kevin Duh, and Marine Carpuat. 2018. An empirical exploration of curriculum learning for neural machine translation. CoRR, abs/1811.00739.
+Zhengyan Zhang, Xu Han, Zhiyuan Liu, Xin Jiang, Maosong Sun, and Qun Liu. 2019. ERNIE: enhanced language representation with informative entities. In Proceedings of the 57th Conference of the Association for Computational Linguistics, pages 1441-1451.
+Yikai Zhou, Baosong Yang, Derek F. Wong, Yu Wan, and Lidia S. Chao. 2020. Uncertainty-aware curriculum learning for neural machine translation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6934-6944.
+Yukun Zhu, Ryan Kiros, Richard S. Zemel, Ruslan Salakhutdinov, Raquel Urtasun, Antonio Torralba, and Sanja Fidler. 2015. Aligning books and movies: Towards story-like visual explanations by watching movies and reading books. In Proceedings of the IEEE International Conference on Computer Vision, pages 19-27.
\ No newline at end of file
diff --git a/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/images.zip b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..06119b70d704ee1053f9fb722142c67ae1139944
--- /dev/null
+++ b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f722f5c5adfb1e2707966de6f76ab3b2a8011620a0b3917d8cfa393fa6e1c722
+size 395458
diff --git a/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/layout.json b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..bb5bf730d89d0f4a155d814cbbbfe505c5dd3e31
--- /dev/null
+++ b/efficientpretrainingofmaskedlanguagemodelviaconceptbasedcurriculummasking/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:df0ca7c51b0d50e3ed3d308107285f44518b901bba4732ac2bdaa2d09f603cc6
+size 378812
diff --git a/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_content_list.json b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..a30275658eb450848b9da327479d4701492d3331
--- /dev/null
+++ b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:55d36f603f5a1adfdadca5bea0f5c950336b7ef0c2604de85ed20ae90e4e769d
+size 93845
diff --git a/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_model.json b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..1726cf378e91d398f6e2c38bc08b5d2b78c49ada
--- /dev/null
+++ b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:1712bf2c5b9b2b7737664fbeafc075f25984979f33de4b43e12508f99a2b88f2
+size 113241
diff --git a/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_origin.pdf b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..82ed0fee2792f72896f704e3b9d8f1394a281bcf
--- /dev/null
+++ b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/a4be85b2-4b3b-4e13-8ea8-643c15707c73_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e31009afc4537b73385ce5c4dc39a19063c92cea48c9c1ca20337ae85cdf65fa
+size 450266
diff --git a/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/full.md b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..3cb56522406ef9487e6736677136714da166d950
--- /dev/null
+++ b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/full.md
@@ -0,0 +1,384 @@
+# Eliciting Knowledge from Large Pre-Trained Models for Unsupervised Knowledge-Grounded Conversation
+
+Yanyang Li, Jianqiao Zhao, Michael R. Lyu, Liwei Wang*
+
+Department of Computer Science and Engineering, The Chinese University of Hong Kong
+
+{yyli21,jqzhao,lyu,lwwang}@cse.cuhk.edu.hk
+
+# Abstract
+
+Recent advances in large-scale pre-training provide large models with the potential to learn knowledge from the raw text. It is thus natural to ask whether it is possible to leverage these large models as knowledge bases for downstream tasks. In this work, we answer the aforementioned question in unsupervised knowledge-grounded conversation. We explore various methods that best elicit knowledge from large models. Our human study indicates that, though hallucinations exist, large models post the unique advantage of being able to output common sense and summarize facts that cannot be directly retrieved from the search engine. To better exploit such generated knowledge in dialogue generation, we treat the generated knowledge as a noisy knowledge source and propose the posterior-based reweighing as well as the noisy training strategy. Empirical results on two benchmarks show advantages over the state-of-the-art methods.
+
+# 1 Introduction
+
+Knowledge-grounded conversation (Dinan et al., 2019; Moghe et al., 2018) is the task where the model could reply to a dialogue history based on extra knowledge. Compared to standard conversational modeling, this extra knowledge prevents the model from generating generic and noninformative responses (Li et al., 2016). Typically, at each turn of the conversation, a pool of knowledge candidates will be retrieved from a knowledge base like unstructured documents (e.g., Wikipedia) (Dinan et al., 2019) or a structured knowledge graph (Dziri et al., 2021). The model then learns to select the most related knowledge from this pool, in an unsupervised manner, to generate its response.
+
+However, constructing and maintaining knowledge bases are time-consuming and expensive. Recent studies have shown that large pre-trained mod
+
+els are capable of grasping knowledge from unsupervised text corpora and memorizing facts to their weights (Petroni et al., 2019; Roberts et al., 2020; Lewis et al., 2021; Wang et al., 2021; Liu et al., 2022a). These large models can even perform reasoning implicitly (Wei et al., 2022). In light of this remarkable capacity of large models, we explore the possibility of leveraging large models as a new knowledge source for unsupervised knowledge-grounded conversation.
+
+In this work, we first investigate the quality of knowledge generated by large models. We examine which tuning method, including the conventional fine-tuning (Devlin et al., 2019; Zhang et al., 2021) and the recently proposed prefix-tuning (Li and Liang, 2021), best prompts knowledge from large models for a given dialogue history. We then design a human evaluation protocol and conduct an extensive quality assessment of the generated knowledge. Despite some extent of hallucinations (plausible statements with factual errors) persist (Maynez et al., 2020), large models can mostly generate related and correct knowledge for the future development of dialogue. Moreover, some of this knowledge is not simply paraphrased or copied from web pages: they summarize scattered facts on the Internet (See Section 5.1). These observations advocate the unique value of employing large models as knowledge bases.
+
+Owing to the hallucinations, it is risky to put generated knowledge directly into the dialogue system as the misinformation could contaminate the response. We instead consider the generated knowledge as a noisy knowledge source and use it to aid the knowledge selection process. Specifically, we measure its similarity to each knowledge candidate and refine the knowledge selection accordingly (See Section 3.2). We further estimate the posterior of the refined knowledge selection distribution, inspired by the fact that the posterior detangles the one-to-many relation between dialogue context and
+
+
+Figure 1: Comparison of fine-tuning (Devlin et al., 2019) and prefix-tuning (Li and Liang, 2021).
+
+knowledge selection (Kim et al., 2020). In addition, we propose a noisy training strategy to strengthen the model's ability on handling noisy knowledge (See Section 3.3). All these strategies significantly elevate the performance of the existing state-of-the-art model to a new level on two widely-adopted benchmarks, Wizard of Wikipedia (Dinan et al., 2019) and Holl-E (Moghe et al., 2018).
+
+# 2 Eliciting Knowledge from Large Models
+
+In this section, we first introduce the tuning methods and large pre-trained models we used to generate knowledge for a given dialogue history. Then we show the tagset developed for evaluating the generated knowledge.
+
+# 2.1 Methods and Models
+
+Since the objective function of large pre-trained models is to predict possible words instead of knowledge given the context (Devlin et al., 2019; Radford et al., 2019), tuning these large models on annotated data is necessary. Here we focus on two tuning methods, as shown in Figure 1:
+
+- Fine-Tuning (Devlin et al., 2019; Zhang et al., 2021) which updates all weights in the model.
+- Prefix-Tuning (Li and Liang, 2021) which freezes the pre-trained weights and tunes only a small set of parameters that are added as the prefix of the model's input.
+
+Fine-tuning remains the standard approach for leveraging pre-trained models in downstream tasks, while prefix-tuning has a comparable performance but avoids the risk of catastrophic forgetting (Goodfellow et al., 2013), which is desirable in our task.
+
+Another challenge is selecting large models. Because our task requires large models to understand the dialogue history and then recommend a related knowledge piece for the user to follow up, we study two types of large models:
+
+- Pre-trained Language Models (PLMs) that
+
+are trained on web documents with access to abundant knowledge during pre-training.
+
+- Pre-trained Dialogue Models (PDMs) that are trained on dialogue data to better understand the dialogue history.
+
+We choose T5 (Raffel et al., 2020) as the representative of PLMs and DialogGPT (Zhang et al., 2020) for PDMs, because they release a series of checkpoints with different model sizes.
+
+Besides, we experiment with various decoding methods to see which of them best suits each type of large models, including greedy decoding, beam search and top-K sampling (Fan et al., 2018). We find that PDMs work best with top-K sampling and beam search for PLMs.
+
+# 2.2 Annotation Tagset
+
+To assess the quality of the generated knowledge, we develop an annotation tagset for human evaluation in Table 1. Each generated knowledge along with its associated dialogue history will be annotated by at least two tags, each from a different category: context understanding, tuning effectiveness (and fact-checking if outputs contain facts).
+
+Context Understanding Related and Unrelated in rows 1-2 of Table 1 measure whether large pretrained models understand the conversation and generate related knowledge. Although we can use automatic metrics like the F1 score that measures the distance between the generated knowledge and the ground truth knowledge as an alternative, a single reference only captures one possible future direction of the dialogue. In this sense, human evaluation provides a more comprehensive assessment.
+
+Tuning Effectiveness Non-Verifiable (e.g., chitchat) and Verifiable in rows 3-4 indicate the reliability of the tuning methods for eliciting knowledge from large models. If a tuning method is effective, models should generate outputs that contain Verifiable facts.
+
+Fact-Checking Among those Verifiable outputs, we classify them into Supported (facts is supported by evidence), Refuted (facts is refuted by evidence) and Not Enough Information (NEI, evidence is not found), as shown in rows 5-12 of Table 1. These tags are mainly adapted from Gupta et al. (2022). Annotators will gather trustworthy evidence via search engines to determine the label.
+
+To better understand the detailed behavior of large models, we divide Supported into Explicit Supported and Implicit Supported. The for
+
+ | Tag | Definition |
| Context Understanding: |
| 1 | Related | The generated output discusses facts that are related to the conversation. |
| 2 | Unrelated | The generated output does not discuss facts that are related to the conversation. |
| Tuning Effectiveness: |
| 3 | Non-Verifiable | The generated output does not contain facts that could be verified. |
| 4 | Verifiable | The generated output contains facts that could be verified. |
| Fact-Checking: |
| 5 | Supported | One can find evidence from the knowledge base to validate the factual information in the generated output. |
| 6 | Explicit Supported | One only needs to find one evidence from the knowledge base for validation. |
| 7 | Implicit Supported | One needs to find multiple evidences from the knowledge base for validation. |
| 8 | Refuted | One can find evidence from the knowledge base to contradict the factual information in the generated output. |
| 9 | Not Enough Information | The factual information in the generated output could not be validated. |
| 10 | Reasonable NEI | Though not validated by the knowledge base, the factual information matches common sense. |
| 11 | Unreasonable NEI | Though not validated by the knowledge base, the factual information does not match common sense. |
| 12 | Hard NEI | The factual information could not be validated by either the knowledge base or common sense. |
+
+Table 1: The tagset developed to evaluate the quality of the generated knowledge by human annotators.
+
+mer means that large models memorize existing documents, while the latter implies that they do more than memorization, e.g., summarization. We also let the annotators check whether NEI outputs could be validated by common sense. If common sense could be used for validation, these NEI outputs will be further classified into Reasonable NEI (facts match common sense) or Unreasonable NEI (facts contradict common sense), and Hard NEI if common sense is not applicable.
+
+# 3 Exploiting Generated Knowledge for Conversation
+
+In this section, we first review the state-of-the-art approach - PLATO-KAG (Huang et al., 2021). Then we develop our method on top of PLATO-KAG to exploit generated knowledge.
+
+# 3.1 PLATO-KAG
+
+As shown in Figure 2, PLATO-KAG is a model consisting of two modules: a knowledge selector which selects top-K most relevant knowledge to the dialogue history from a pool of retrieved knowledge candidates, and a response generator that generates the response based on the dialogue history and the selected knowledge.
+
+Knowledge Selector The knowledge selector adopts a dual encoder with shared parameters to extract features. The dialogue history $h$ and a knowledge candidate $z$ will pass to this encoder independently to get their own representations. Then it estimates the relevance between the dialogue his
+
+tory $h$ and a knowledge candidate $z$ by:
+
+$$
+f (h, z) = \left(W _ {h} E (h)\right) ^ {T} \left(W _ {z} E (z)\right) \qquad (1)
+$$
+
+where $E(\cdot)$ is the fixed-length vector representation of the input, i.e., the encoder's output on the [CLS] token. $W_{h}$ and $W_{z}$ are two linear projections.
+
+To select the top-K knowledge candidates, the knowledge selector computes the relevance between $h$ and all possible $z$ . Then only the top-K most related knowledge $Z = \{z_{1},\dots ,z_{K}\}$ is retained to construct the knowledge selection distribution $P(z|h)$ as follows:
+
+$$
+P (z | h) = \frac {e ^ {f (h , z)}}{\sum_ {z ^ {\prime} \in Z} e ^ {f (h , z ^ {\prime})}} \tag {2}
+$$
+
+Response Generator After the knowledge selection, the response generator will predict the probability of the response $r$ by:
+
+$$
+P (r | h) = \sum_ {z \in Z} P (z | h) P (r | h, z) \tag {3}
+$$
+
+where $P(r|h,z) = \prod_{i}P(r_{i}|h,z,r_{< i})$ is a decoder that generates response $r$ given the dialogue history $h$ and one knowledge candidate $z$ .
+
+# 3.2 Posterior-based Reweighing
+
+Reweighing Generated knowledge contains hallucinated facts, as later shown in Section 5.1.2. It is thus not viable to take generated knowledge $g$ as the direct input of the model. Instead, we interpret $g$ as noisy ground truth and define a refined
+
+
+Figure 2: Illustration of PLATO-KAG (Huang et al., 2021).
+
+knowledge selection distribution $P^{*}(z|h)$
+
+$$
+P ^ {*} (z | h) = P (z | h) P (z | g) \tag {4}
+$$
+
+where $P(z|h)$ is the original knowledge selection distribution and $P(z|g)$ measures the similarity between $g$ and $z$ . This refined distribution $P^{*}(z|h)$ will score $z$ high only if $z$ is close to the history $h$ as well as the noisy ground truth $g$ .
+
+Similar to Eqs. 1-2, we define $P(z|g)$ to measure the closeness between $g$ and each $z$ :
+
+$$
+f (g, z) = \left(W _ {h} E (g)\right) ^ {T} \left(W _ {z} E (z)\right) \tag {5}
+$$
+
+$$
+P (z \mid g) = \frac {e ^ {f (g , z) / \alpha}}{\sum_ {z ^ {\prime} \in Z} e ^ {f (g , z ^ {\prime}) / \alpha}} \tag {6}
+$$
+
+where $\alpha$ is a hyper-parameter that controls the sharpness of $P(z|g)$ .
+
+Posterior Kim et al. (2020) suggests that the posterior selection distribution $P(z|h, r)$ could select a more appropriate knowledge than the prior selection distribution $P(z|h)$ , because the presence of future response $r$ narrows down the scope of all possible $z$ . We drive the posterior of the refined selection distribution $P^{*}(z|h)$ via the Bayes rule:
+
+$$
+P (z | h, r) = \frac {P (r | h , z) P ^ {*} (z | h)}{\sum_ {z ^ {\prime} \in Z} P (r | h , z ^ {\prime}) P ^ {*} \left(z ^ {\prime} | h\right)} \tag {7}
+$$
+
+where the denominator is tractable as there are only a small number of $z$ and $P(r|h,z)$ is exactly the response generator.
+
+The main challenge is how to estimate $P(r|h,z)$ when $r$ is not yet observed. We let the response generator greedy decode a most likely response $\bar{r}$ for a given $z$ . However, different $z$ might result in $\bar{r}$ with various lengths. A long $\bar{r}$ tends to have a lower probability and is not competitive with the short one (Yang et al., 2018). We therefore use the mean token probability as the approximation of $P(r|h,z) \approx \frac{1}{N}\sum_{i=1}^{N}P(\bar{r}_i|h,z,\bar{r}_{1.
+
+SKT models the knowledge selection process in multi-turn dialogue generation as a sequential latent variable model (Kim et al., 2020). We use their open-sourced models in our experiments2.
+
+$\checkmark$ **KnowledGPT fine-tunes a GPT-2 (Radford et al., 2019) and leverages the reinforcement learning approach to train an unsupervised sequential knowledge selector (Zhao et al., 2020). We adopt their released model for experiments3.
+
+# 4.4 Implementation Details
+
+Knowledge Generation For fine-tuning, all models use a batch size of 64, a learning rate of 5e-5, and the inverse square root learning rate scheduler (Vaswani et al., 2017) with 1000 warmup steps. We validate the model on the validation set every 1000 steps and early stop the training if the performance does not improve after 15 validations. For prefix-tuning, the prefix length is set to 5 as in Li and Liang (2021). Other hyper-parameters are almost the same as in fine-tuning, except that the learning rate is kept constant and reduced by 1/10 only if the validation set performance does not improve after 10 validations. At inference, DialoGPT is decoded with top-K sampling where K is 10 and the beam size is 20. For T5, we use beam search with a beam size of 10.
+
+Response Generation Since Huang et al. (2021) did not release their codes and models before we start the experiments, we reimplement their approach in ParlAI (Miller et al., 2017) and report our own results as well. We follow Huang et al.
+
+| PLM Type | Model | #Params | Fine-Tuning | Prefix-Tuning |
| Test Seen | Test Unseen | Test Seen | Test Unseen |
| N/A | T5-large | 737M | 0.2530 | 0.1044 | 0.1312 | 0.1245 |
| PLM | T5-small | 60M | 0.2521 | 0.1796 | 0.2138 | 0.1720 |
| T5-base | 222M | 0.2679 | 0.1807 | 0.2494 | 0.1735 |
| T5-large | 737M | 0.2624 | 0.1943 | 0.2575 | 0.1579 |
| T5-XL | 3B | 0.2684 | 0.2053 | 0.2629 | 0.1808 |
| T5-XXL | 11B | - | - | 0.2652 | 0.1874 |
| PDM | DiaLoGPT-small | 124M | 0.2357 | 0.1588 | 0.3041 | 0.1456 |
| DiaLoGPT-medium | 355M | 0.3216 | 0.1663 | 0.3173 | 0.1598 |
| DiaLoGPT-large | 774M | 0.3217 | 0.1705 | 0.3209 | 0.1613 |
+
+Table 2: The automatic evaluation result (Unigram F1) of two tuning methods for generating knowledge in WoW seen and unseen test sets ("N/A" means we do not use the pre-trained weights). Results of fine-tuned T5-XXL are missing due to resource constraint.
+
+
+Figure 3: The human evaluation results of generated knowledge from fine-tuned DialogGPT-large on WoW seen and unseen test sets.
+
+(2021)'s hyper-parameters settings in our experiments. For our proposed reweighing method, we perform a grid search on the validation set $(\alpha \in [1,10],\beta \in (0,1))$ and set $\alpha = 5,\beta = 0.4$ . According to Table 2, we choose the generated knowledge of DialogGPT-large for our experiments, as it performs the best on average. All experiments are conducted on 8 NVIDIA A100 80G. It takes roughly one day to train one model.
+
+# 5 Results and Analysis
+
+# 5.1 Knowledge Generation Results
+
+We conduct a case study of eliciting knowledge from large models on the WoW dataset and present the evaluation results.
+
+# 5.1.1 Automatic Evaluation Results
+
+Table 2 shows F1 scores of various large models tuned by different methods on the seen and unseen test sets. Results of fine-tuning T5-XXL are missing because we do not have enough resources to train this model. The first row of Table 2 is the baseline result of tuning a randomly initialized T5-large model. We observe that nearly all large models perform better than this baseline, especially on the
+
+unseen test set. This observation indicates the per-trained weights do store a lot of factual information as they make a non-trivial improvement.
+
+We also see that PDMs perform much better than PLMs on data with a seen topic, while PLMs are better on the unseen topic in most cases. This might be the consequence that PLMs are trained on diverse text data, which allows them to generalize better on unseen topics. PDMs, on the other hand, are trained on dialogue data only and have a smaller discrepancy between pre-training and fine-tuning. Thus PDMs perform better on seen topics. We also find that the results of fine-tuning are much better than prefix-tuning in general. But this gap is closed when the model gets larger, which is aligned with the conclusion in Lester et al. (2021).
+
+Interestingly, large models scale poorly on our task. On the unseen test set, the performance increases only around 3 points while the model size is $50 \times$ larger (0.1796 for fine-tuned T5-small with 60M parameters vs. 0.2053 for fine-tuned T5-XL with 3B parameters).
+
+# 5.1.2 Human Evaluation Results
+
+The human evaluation results are presented in Figure 3. This evaluation has a kappa value of 1 for
+
+| Test Seen | Automatic Evaluation | Human Evaluation |
| PPL↓ | P@1↑ | Unigram F1↑ | Coherence↑ | Informativeness↑ | Engagingness↑ | Hallucination↓ |
| TMN | 61.21 | 0.220 | 0.172 | 0.4757 | 0.3883 | 0.4175 | 0.0777 |
| SKT | 57.27 | 0.258 | 0.187 | 0.9806 | 0.7767 | 0.6990 | 0.0680 |
| KnowledGPT | 19.60 | 0.262 | 0.209 | 1.0000 | 1.2330 | 1.0874 | 0.0097 |
| PLATO-KAG | 9.767 | 0.253 | 0.188 | - | - | - | - |
| PLATO-KAG* | 11.51 | 0.266 | 0.207 | 1.4757 | 1.1748 | 1.2816 | 0.0388 |
| PLATO-KAG+ | 12.37 | 0.254 | 0.211 | 1.4951 | 1.1845 | 1.2718 | 0.0291 |
| Test Unseen | Automatic Evaluation | Human Evaluation |
| PPL↓ | P@1↑ | Unigram F1↑ | Coherence↑ | Informativeness↑ | Engagingness↑ | Hallucination↓ |
| TMN | 103.1 | 0.112 | 0.150 | 0.5000 | 0.2788 | 0.3173 | 0.1058 |
| SKT | 87.93 | 0.177 | 0.157 | 0.7019 | 0.5000 | 0.5385 | 0.0673 |
| KnowledGPT | 22.85 | 0.238 | 0.196 | 0.9712 | 0.9904 | 0.7692 | 0.0096 |
| PLATO-KAG | 11.46 | 0.253 | 0.181 | - | - | - | - |
| PLATO-KAG* | 12.75 | 0.233 | 0.196 | 1.4327 | 1.2019 | 1.2019 | 0.0962 |
| PLATO-KAG+ | 13.77 | 0.231 | 0.203 | 1.2596 | 1.0192 | 1.0096 | 0.0385 |
+
+Table 3: The automatic and human evaluation results on WoW seen (upper) and unseen (bottom) test sets. * means this is our implementation results. + means our proposed method is applied. Note that PPL is generally not comparable among baselines, as their vocabularies are different. The best results are in bold and the best baseline results are underlined.
+
+the context understanding dimension and 0.698 for the remaining dimensions4. Here we study the outputs of fine-tuned DialoGPT-large, as it performs the best on average. We also analyze prefix-tuned T5-XXL in Appendix A and the results are similar.
+
+Context Understanding From the first subplot of Figure 3, large models can reliably generate related knowledge for a given dialogue history, where around $90\%$ tags are Related in both test sets.
+
+Tuning Effectiveness The second diagram in Figure 3 shows that large models exhibit desirable behaviors after fine-tuning: it generates knowledge (Verifiable) in all cases.
+
+Fact-Checking The rightmost three panels of Figure 3 demonstrate the factual correctness of the generated knowledge. As shown in the third panel, large models generate factually correct (Supported) statements in most cases, though there is still around $10\%$ of the chance to produce hallucinated information (Refuted). Among all the factually correct knowledge (the second last panel), more than $50\%$ of them are Implicitly Supported. This is exciting as large models are able to assemble multiple facts in their outputs, which cannot be substituted by simple search engine retrieval. This ability to summarize justifies the value of large models in serving as knowledge bases.
+
+The last panel of Figure 3 checks whether NEI
+
+claims could be verified by common sense. There is a certain amount $(39\sim 57\%)$ of NEI claims that are common sense. This observation advocates another advantage of utilizing large models as knowledge bases: they can provide common-sense information that lies behind the human mind, with no need for humans to explicitly write them down. We show some annotated examples in Appendix B.
+
+# 5.2 Response Generation Results
+
+# 5.2.1 Main Results
+
+Table 3 is the response generation results of the WoW test sets. We can see that applying our proposed method to PLATO-KAG obtains the highest F1 score, even if our reimplemented PLATO-KAG baseline already performs much better than reported in the paper. On the other hand, our proposed method seems to lower the top-1 knowledge accuracy, i.e., $\mathrm{P@1}$ drops from 0.266 to 0.254 in the seen test set and from 0.233 to 0.231 in the unseen test set. Note that PLATO-KAG is a model whose input consists of K knowledge candidates. If the ground truth knowledge is not ranked in the first place but presented in the top-K results, the model can still use the ground truth for the generation. In this case, the top-K knowledge accuracy is a more important metric for evaluating knowledge selection. Though not presented in Table 3, $\mathrm{P@K}$ increases from 0.681 to 0.690 in the seen test set and from 0.645 to 0.656 in the unseen test set. Table 4 displays the automatic evaluation results
+
+| System | PPL↓ | P@1↑ | Unigram F1↑ |
| SKT | 52.02 | 0.303 | 0.295 |
| PLATO-KAG | 10.22 | 0.271 | 0.300 |
| PLATO-KAG* | 5.816 | 0.250 | 0.310 |
| PLATO-KAG+ | 5.495 | 0.272 | 0.320 |
+
+in Holl-E datasets. Similar to the results of WoW, our proposed method significantly outperforms the baseline systems in terms of the F1 score.
+
+Table 3 also reports the human evaluation results of WoW. The kappa value of this human evaluation is 0.415. In the seen test set, our strategy improves over baselines in nearly all metrics. However, our method degrades the performance of the unseen test set. In Section 5.2.2, we will show that our method put significantly more ground truth knowledge into the responses. In spite of that more knowledge helps to reduce hallucinations (from 0.0962 to 0.0385 as shown in Table 3), this could also lead to a degenerated result in human evaluation (Huang et al., 2021), as the knowledge makes the response far less interesting.
+
+# 5.2.2 Analysis
+
+We conduct an ablation study in Table 5 for a better understanding of our proposed method. We additionally report Knowledge F1, the F1 score between the generated response and the ground truth knowledge (Lian et al., 2019; Shuster et al., 2021), which indicates how much ground truth knowledge is embedded into the response.
+
+As shown in Table 5, all steps in our proposed method, including noisy training and posterior-based reweighing, contribute to the final performance. In particular, reweighing greatly improves Knowledge F1, which implies that it helps to select and incorporate ground truth knowledge into the response generation. We give some examples in Appendix C for demonstration.
+
+# 6 Related Work
+
+Knowledge-Grounded Conversation The dialogue system field has witnessed a growing interest in knowledge-grounded conversation in recent years. Many related benchmarks have been proposed to study this problem (Zhang et al., 2018; Zhou et al., 2018; Dinan et al., 2019; Gopalakrishnan et al., 2019; Komeili et al., 2022). Early work (Dinan et al., 2019) had harnessed the annotated knowledge for training. Unsupervised approaches
+
+Table 4: The evaluation results on Holl-E test set.
+
+| System | Test Seen | Test Unseen |
| Unigram F1↑ | Know. F1↑ | Unigram F1↑ | Know. F1↑ |
| PLATO-KAG* | 0.208 | 0.193 | 0.196 | 0.183 |
| + Noisy Train. | 0.209 | 0.192 | 0.203 | 0.188 |
| + Post. Reweigh | 0.211 | 0.200 | 0.203 | 0.193 |
+
+Table 5: The ablation study on WoW test sets.
+
+become attractive as acquiring these annotations is expensive. Zhao et al. (2020) use reinforcement learning to fine-tune GPT-2 (Radford et al., 2019) for unsupervised knowledge selection. Huang et al. (2021) achieve a new state-of-the-art by selecting top-K knowledge when annotations are not available. Another line of research improves the knowledge selection modeling by estimating the posterior, which makes use of the future utterance. Lian et al. (2019) train the knowledge selector as a variational auto-encoder (Kingma and Welling, 2014). Kim et al. (2020) further model the knowledge selection in multi-turn dialogue as a sequential latent variable. More recently, dialogue model pre-training also attempts to involve knowledge for generating informative responses. Shuster et al. (2021) utilize the pre-trained retriever DPR (Karpukhin et al., 2020). Thoppilan et al. (2022) directly access to the search engine to collect relevant knowledge.
+
+Knowledge in Pre-Trained Models The LAMA prob (Petroni et al., 2019) first study knowledge stored in pre-trained models. They show that pretrained models contain a certain amount of factual knowledge without any fine-tuning. This finding has motivated a series of work that adopts knowledge from pre-trained models for downstream tasks. Roberts et al. (2020) show that pre-trained models fine-tuned on question-answering datasets without accessing any external knowledge base could obtain a remarkable result. Wang et al. (2022) prob relational structures from pre-trained models for Text-to-SQL parsing. Liu et al. (2022a) further demonstrate that pre-trained models can generate knowledge via prompting to help in common sense reasoning tasks. Perhaps the most related work is Liu et al. (2022b), where they adapt a large model to knowledge-grounded conversation via multi-stage prompting and which includes an intermediate knowledge generation step. Compared to this work, our work treats large models as a general-purpose knowledge base, then elicits and transfers knowledge from it to improve a small but strong downstream task model with a distinct architecture.
+
+Knowledge Distillation Our work also closely resembles knowledge distillation (Hinton et al., 2015), as we similarly transfer knowledge from a large pre-trained model to a small downstream task model. Most existing approaches employ continuous vectors to represent knowledge, e.g., logits (Hinton et al., 2015), attention distribution (Wang et al., 2020), hidden features (Romero et al., 2015) or weights (Lin et al., 2021), which are not straightforwardly interpretable. In this work, the large model generates discrete, readable sentences to transfer knowledge.
+
+# 7 Conclusion
+
+In this work, we show that large pre-trained models could serve as knowledge bases for unsupervised knowledge-grounded conversation. The study on the generated knowledge of large models has the following observations:
+
+- Fine-tuning better elicits knowledge from large models than prefix-tuning.
+- Knowledge pieces generated by pre-trained language models have a higher quality on unseen topics, while those from pre-trained dialogue models are better on seen topics.
+- Large pre-trained models can synthesize common sense and summarize facts scattered on the web.
+
+We also propose posterior-based reweighing and noisy training, which helps to incorporate the generated knowledge into the dialogue system. These simple strategies show a promising result over the strong baselines.
+
+# Limitations
+
+We realize that there still are some limitations in our work despite the exciting results:
+
+Generated Knowledge A certain amount of annotated data is required to fine-tune large models before they could output knowledge stored in their weights. Such kind of data could be difficult to collect as it requires highly educated annotators. Besides, although large models could generate knowledge that needs multiple pieces of evidence for verification (samples with Implicit Supported tag), to what extent large models understand facts and the relation to hallucination remain unknown.
+
+Proposed Method The approach we proposed to leverage the generated knowledge is still primitive, as it is purely training-free and applied only at inference. In addition, we only use one gener-
+
+ated knowledge sentence in experiments. Aside from this, in human evaluation we have shown that injecting more knowledge into responses reduces hallucination, but results in the degradation of other dimensions like engagingness. How to carefully balance these quality measurements is another topic that is worth investigating.
+
+# Acknowledgements
+
+This work is supported by Centre for Perceptual and Interactive Intelligence Limited, UGC under Research Matching Grant Scheme, and partially by Research Grants Council of the Hong Kong Special Administrative Region, China (No. CUHK 14210920 of the General Research Fund).
+
+# References
+
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Emily Dinan, Stephen Roller, Kurt Shuster, Angela Fan, Michael Auli, and Jason Weston. 2019. Wizard of wikipedia: Knowledge-powered conversational agents. In 7th International Conference on Learning Representations, ICLR 2019, New Orleans, LA, USA, May 6-9, 2019. OpenReview.net.
+Nouha Dziri, Andrea Madotto, Osmar Zaïane, and Avishek Joey Bose. 2021. Neural path hunter: Reducing hallucination in dialogue systems via path grounding. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 2197-2214, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Angela Fan, Mike Lewis, and Yann Dauphin. 2018. Hierarchical neural story generation. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 889-898, Melbourne, Australia. Association for Computational Linguistics.
+Joseph L Fleiss. 1971. Measuring nominal scale agreement among many raters. Psychological bulletin, 76(5):378.
+Ian J Goodfellow, Mehdi Mirza, Da Xiao, Aaron Courville, and Yoshua Bengio. 2013. An empirical investigation of catastrophic forgetting in gradient-based neural networks. arXiv preprint arXiv:1312.6211.
+
+Karthik Gopalakrishnan, Behnam Hedayatnia, Qinlang Chen, Anna Gottardi, Sanjeev Kwatra, Anu Venkatesh, Raefer Gabriel, and Dilek Hakkani-Tur. 2019. Topical-Chat: Towards Knowledge-Grounded Open-Domain Conversations. In Proc. Interspeech 2019, pages 1891-1895.
+Prakhar Gupta, Chien-Sheng Wu, Wenhao Liu, and Caiming Xiong. 2022. *DialFact: A benchmark for fact-checking in dialogue*. In *Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics* (Volume 1: Long Papers), pages 3785–3801, Dublin, Ireland. Association for Computational Linguistics.
+Geoffrey E. Hinton, Oriol Vinyals, and Jeffrey Dean. 2015. Distilling the knowledge in a neural network. CoRR, abs/1503.02531.
+Xinxian Huang, Huang He, Siqi Bao, Fan Wang, Hua Wu, and Haifeng Wang. 2021. PLATO-KAG: Unsupervised knowledge-grounded conversation via joint modeling. In Proceedings of the 3rd Workshop on Natural Language Processing for Conversational AI, pages 143-154, Online. Association for Computational Linguistics.
+Vladimir Karpukhin, Barlas Oguz, Sewon Min, Patrick Lewis, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6769-6781, Online. Association for Computational Linguistics.
+Byeongchang Kim, Jaewoo Ahn, and Gunhee Kim. 2020. Sequential latent knowledge selection for knowledge-grounded dialogue. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Diederik P. Kingma and Max Welling. 2014. Autoencoding variational bayes. In 2nd International Conference on Learning Representations, ICLR 2014, Banff, AB, Canada, April 14-16, 2014, Conference Track Proceedings.
+Mojtaba Komeili, Kurt Shuster, and Jason Weston. 2022. Internet-augmented dialogue generation. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 8460-8478, Dublin, Ireland. Association for Computational Linguistics.
+Wouter Kool, Herke van Hoof, and Max Welling. 2019. Stochastic beams and where to find them: The gumbel-top-k trick for sampling sequences without replacement. In Proceedings of the 36th International Conference on Machine Learning, ICML 2019, 9-15 June 2019, Long Beach, California, USA, volume 97 of Proceedings of Machine Learning Research, pages 3499-3508. PMLR.
+
+Brian Lester, Rami Al-Rfou, and Noah Constant. 2021. The power of scale for parameter-efficient prompt tuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 3045-3059, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Patrick Lewis, Pontus Stenetorp, and Sebastian Riedel. 2021. Question and answer test-train overlap in open-domain question answering datasets. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 1000-1008, Online. Association for Computational Linguistics.
+Jiwei Li, Michel Galley, Chris Brockett, Jianfeng Gao, and Bill Dolan. 2016. A diversity-promoting objective function for neural conversation models. In Proceedings of the 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 110-119, San Diego, California. Association for Computational Linguistics.
+Xiang Lisa Li and Percy Liang. 2021. Prefix-tuning: Optimizing continuous prompts for generation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 4582-4597, Online. Association for Computational Linguistics.
+Rongzhong Lian, Min Xie, Fan Wang, Jinhua Peng, and Hua Wu. 2019. Learning to select knowledge for response generation in dialog systems. In Proceedings of the Twenty-Eighth International Joint Conference on Artificial Intelligence, IJCAI 2019, Macao, China, August 10-16, 2019, pages 5081-5087. ijcai.org.
+Ye Lin, Yanyang Li, Ziyang Wang, Bei Li, Quan Du, Tong Xiao, and Jingbo Zhu. 2021. Weight distillation: Transferring the knowledge in neural network parameters. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2076-2088, Online. Association for Computational Linguistics.
+Jiacheng Liu, Alisa Liu, Ximing Lu, Sean Welleck, Peter West, Ronan Le Bras, Yejin Choi, and Hannaneh Hajishirzi. 2022a. Generated knowledge prompting for commonsense reasoning. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 3154-3169, Dublin, Ireland. Association for Computational Linguistics.
+Zihan Liu, Mostofa Patwary, Ryan Prenger, Shrimai Prabhumoye, Wei Ping, Mohammad Shoeybi, and Bryan Catanzaro. 2022b. Multi-stage prompting for knowledgeable dialogue generation. In *Findings of the Association for Computational Linguistics: ACL*
+
+2022, pages 1317-1337, Dublin, Ireland. Association for Computational Linguistics.
+Joshua Maynez, Shashi Narayan, Bernd Bohnet, and Ryan McDonald. 2020. On faithfulness and factuality in abstractive summarization. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 1906-1919, Online. Association for Computational Linguistics.
+Alexander Miller, Will Feng, Dhruv Batra, Antoine Bordes, Adam Fisch, Jiasen Lu, Devi Parikh, and Jason Weston. 2017. ParlAI: A dialog research software platform. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 79-84, Copenhagen, Denmark. Association for Computational Linguistics.
+Nikita Moghe, Siddhartha Arora, Suman Banerjee, and Mitesh M. Khapra. 2018. Towards exploiting background knowledge for building conversation systems. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 2322-2332, Brussels, Belgium. Association for Computational Linguistics.
+Fabio Petroni, Tim Rocttäschel, Sebastian Riedel, Patrick Lewis, Anton Bakhtin, Yuxiang Wu, and Alexander Miller. 2019. Language models as knowledge bases? In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 2463-2473, Hong Kong, China. Association for Computational Linguistics.
+Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, Ilya Sutskever, et al. 2019. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. Journal of Machine Learning Research, 21(140):1-67.
+Adam Roberts, Colin Raffel, and Noam Shazeer. 2020. How much knowledge can you pack into the parameters of a language model? In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 5418-5426, Online. Association for Computational Linguistics.
+Adriana Romero, Nicolas Ballas, Samira Ebrahimi Kahou, Antoine Chassang, Carlo Gatta, and Yoshua Bengio. 2015. Fitnets: Hints for thin deep nets. In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
+Kurt Shuster, Spencer Poff, Moya Chen, Douwe Kiela, and Jason Weston. 2021. Retrieval augmentation
+
+reduces hallucination in conversation. In Findings of the Association for Computational Linguistics: EMNLP 2021, pages 3784-3803, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Romal Thoppilan, Daniel De Freitas, Jamie Hall, Noam Shazeer, Apoorv Kulshreshtha, Heng-Tze Cheng, Alicia Jin, Taylor Bos, Leslie Baker, Yu Du, YaGuang Li, Hongrae Lee, Huaixiu Steven Zheng, Amin Ghafouri, Marcelo Menegali, Yanping Huang, Maxim Krikun, Dmitry Lepikhin, James Qin, Dehao Chen, Yuanzhong Xu, Zhifeng Chen, Adam Roberts, Maarten Bosma, Yanqi Zhou, Chung-Ching Chang, Igor Krivokon, Will Rusch, Marc Pickett, Kathleen S. Meier-Hellstern, Meredith Ringel Morris, Tulsee Doshi, Renelito Delos Santos, Toju Duke, Johnny Soraker, Ben Zevenbergen, Vinodkumar Prabhakaran, Mark Diaz, Ben Hutchinson, Kristen Olson, Alejandra Molina, Erin Hoffman-John, Josh Lee, Lora Aroyo, Ravi Rajakumar, Alena Butryna, Matthew Lamm, Viktoriya Kuzmina, Joe Fenton, Aaron Cohen, Rachel Bernstein, Ray Kurzweil, Blaise Aguera-Arcas, Claire Cui, Marian Croak, Ed H. Chi, and Quoc Le. 2022. Lamda: Language models for dialog applications. CoRR, abs/2201.08239.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pages 5998-6008.
+Cunxiang Wang, Pai Liu, and Yue Zhang. 2021. Can generative pre-trained language models serve as knowledge bases for closed-book QA? In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume I: Long Papers), pages 3241-3251, Online. Association for Computational Linguistics.
+Lihan Wang, Bowen Qin, Binyuan Hui, Bowen Li, Min Yang, Bailin Wang, Binhua Li, Jian Sun, Fei Huang, Luo Si, and Yongbin Li. 2022. Proton: Probing schema linking information from pre-trained language models for text-to-sql parsing. In KDD '22: The 28th ACM SIGKDD Conference on Knowledge Discovery and Data Mining, Washington, DC, USA, August 14 - 18, 2022, pages 1889-1898. ACM.
+Wenhui Wang, Furu Wei, Li Dong, Hangbo Bao, Nan Yang, and Ming Zhou. 2020. Minilm: Deep self-attention distillation for task-agnostic compression of pre-trained transformers. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Jason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma, Ed H. Chi, Quoc Le, and Denny Zhou. 2022. Chain of thought prompting elicits reasoning in large language models. CoRR, abs/2201.11903.
+
+Yilin Yang, Liang Huang, and Mingbo Ma. 2018. Breaking the beam search curse: A study of (re-)scoring methods and stopping criteria for neural machine translation. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 3054-3059, Brussels, Belgium. Association for Computational Linguistics.
+Saizheng Zhang, Emily Dinan, Jack Urbanek, Arthur Szlam, Douwe Kiela, and Jason Weston. 2018. Personalizing dialogue agents: I have a dog, do you have pets too? In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2204-2213, Melbourne, Australia. Association for Computational Linguistics.
+Tianyi Zhang, Felix Wu, Arzoo Katiyar, Kilian Q. Weinberger, and Yoav Artzi. 2021. Revisiting few-sample BERT fine-tuning. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net.
+Yizhe Zhang, Siqi Sun, Michel Galley, Yen-Chun Chen, Chris Brockett, Xiang Gao, Jianfeng Gao, Jingjing Liu, and Bill Dolan. 2020. DIALOGPT: Large-scale generative pre-training for conversational response generation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics: System Demonstrations, pages 270-278, Online. Association for Computational Linguistics.
+Xueliang Zhao, Wei Wu, Can Xu, Chongyang Tao, Dongyan Zhao, and Rui Yan. 2020. Knowledge-grounded dialogue generation with pre-trained language models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 3377-3390, Online. Association for Computational Linguistics.
+Kangyan Zhou, Shrimai Prabhumoye, and Alan W Black. 2018. A dataset for document grounded conversations. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 708-713, Brussels, Belgium. Association for Computational Linguistics.
+
+# A Human Evaluation on T5-XXL
+
+Figure 4 is the human evaluation results on the generated knowledge of prefix-tuned T5-XXL. The kappa value of the context understanding dimension is 0.922 and 0.726 for the remaining two dimensions. Compared to DialogGPT-large, T5-XXL performs more robustly in generating related knowledge for unseen topics, as indicated by the leftmost panel of Figure 4. It also seems that prefix-tuning is slightly less effective, as it produces a few non-verifiable claims, as shown in the second leftmost subplot of Figure 4. In the rightmost diagram of Figure 4, we note that T5-XXL is more likely to generate knowledge that is hard to verify. This might indicate a higher risk of hallucination when using larger models. Other measurements remain similar for DialogGPT-large and T5-XXL.
+
+# B Knowledge Generation Examples
+
+Table 6 gives some generated knowledge examples, each with a different tag annotated. Most of these examples are generated by fine-tuned DialogoGPT-large on WoW unseen test set.
+
+# C Response Generation Examples
+
+Table 7 are response examples from different response generation models in two WoW test sets. We can see that our PLATO-KAG+ generates responses that are more interesting than other baselines. We also note that the first few words are similar for the PLATO-KAG baseline and our PLATO-KAG+. It seems that our strategy improves the long-term modeling of PLATO-KAG to achieve a better result.
+
+
+Figure 4: The human evaluation results of generated knowledge from prefix-tuned T5-XXL on WoW seen and unseen test sets.
+
+| Tag | Example |
| Related | Dialogue History
+[Apprentice]: I love to bowl, but what is the games history, I wonder?
+Knowledge
+Bowling is an Olympic sport and is played at all levels of society and at all ages. |
| Unrelated | Dialogue History
+[Wizard]: I love the hunting game. More like a hunter
+[Apprentice]: What is the hunting game? Tell me more about it. |
| Knowledge
+Hunting is the practice of killing or trapping animals, or pursuing or tracking them with the intent of doing so. |
| Non-Verifiable | The food is delicious. |
| Verifiable | American football, also known as American football or American football, is a team sport played between two teams of eleven players with a spherical ball. |
| Supported | Explicit Supported | Dylan's Candy Bar is a chain of boutique candy shops and candy suppliers currently located in New York City; East Hampton, New York; Los Angeles, Chicago and Miami Beach, as well as in wholesale venues around the globe. |
| Implicit Supported | The Walking Dead is an American post-apocalyptic horror television series developed by Frank Darabont for AMC that is based on the comic book series of the same name by Robert Kirkman, Tony Moore, and Charlie Adlard. |
| Refuted | The dog was the first species to be domesticated and has been selectively bred over millennia for various behaviors, sensory capabilities, and physical attributes. |
| NEI | Reasonable NEI | Bowling is an Olympic sport and is played at all levels of society and at all ages. |
| Unreasonable NEI | The sky is pale green. |
| Hard NEI | The first stable line-up consisted of Michael "Mike D" Diamond (vocals, drums), Adam "MCA" Yauch (vocals, bass) and Adam "The Dope Man" Horovitz (vocals, guitar). |
+
+Table 6: Examples with different annotated tags (sampled from DialogGPT-large in WoW unseen test set except for Non-Verifiable and Unreasonable NEI as they do not appear in the data and thus are hand-crafted).
+
+| Context | [Apprentice]: I have been thinking about getting a poodle
+[Wizard]: Oh yeah? You can choose from the Standard, Miniature, or Toy Poodles.
+[Apprentice]: I think i might egt a toy
+[Wizard]: Good selection. Toy poodles won "Best in Show" at Crufts in 1966 and 1982.
+[Apprentice]: How big do they get? do you know |
| TMN | they are the second most intelligent breed. |
| SKT | i don 't know, but i know they are a group of formal dog breeds. |
| KnowledGPT | they are ranked second most intelligent dog breed just behind the border collie, the poodle is skillful in many dog sports and activities, including agility |
| PLATO-KAG* | They are ranked as the second most intelligent dog breed. |
| PLATO-KAG+ | They are medium sized. They achieved the award in 1955, 1985, 2002 and 2014. |
| Context | [Wizard]: Do you like Chihuahua's? I think they are cute, and their name origin is interesting to me, it is the smallest breed of dog
+[Apprentice]: Yeah I love them! I own one! They are so friendly and nice!
+[Wizard]: Dogs in general are so cute, it is crazy to me that they evolved from extant gray wolves, as wolves are so much different, it is hard to believe they are ancestors
+[Apprentice]: It's amazing how humans domesticated and bred dogs down to create the dogs we have today. Early dogs were bread to ease everyday task.
+[Wizard]: Yeah, while the origins of dogs are not really clear, it is clear humans had a role in that process, which amazes me, as we have created so many different and varying breeds of dogs
+[Apprentice]: The Dochen was used back in the day to hunt out rabbits from holes in the ground for hunters to shoot |
| TMN | i 've never had them, but i 've heard that they 're so cute. i 've been reading about them since they 're so cute. |
| SKT | the earliest of these were found at tres adpots in mexico in veracruz, mexico in veracruz, mexico, mexico, and other animals. |
| KnowledGPT | that's so cool, the dog was the first species to be domesticated and has been selectively bred over millennia for various behaviors, sensory capabilities, and |
| PLATO-KAG* | That is so cool! I love dogs, they are so smart and friendly, and they are so smart and friendly with humans too! |
| PLATO-KAG+ | That's so cool! I didn't know that, I always thought they were just used for hunting, but I guess they were used for other things too. |
+
+Table 7: Examples of the generated responses on the WoW seen (upper) and unseen (bottom) test sets.
\ No newline at end of file
diff --git a/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/images.zip b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..9ced1e47eaca59a2ef059592790bed4b483db466
--- /dev/null
+++ b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:cba6d52875061742222d9df0c88a9cf690a5608839f6d6d2fabcc6b604931d10
+size 910348
diff --git a/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/layout.json b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..6d689a22b03b2d9e974c0805e2efa4ec599c902e
--- /dev/null
+++ b/elicitingknowledgefromlargepretrainedmodelsforunsupervisedknowledgegroundedconversation/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e0d7bd2e4a1e610f39bc79224322585938a7528b0ad3d12b32b03709404d7c4d
+size 405808
diff --git a/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_content_list.json b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..fe1ba89f974ac7531481ca2af57f5dbb72158ce1
--- /dev/null
+++ b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4947b6f47c657cdc3968f9921fc1565718445a9d05e8090ea1bde06dce71c1c3
+size 104159
diff --git a/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_model.json b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..c5f7175f0bcf8848ee76ef637b156c8a09ad24a9
--- /dev/null
+++ b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0df08f341e8b6d3d25fc1cf1204e74a7406b058a4d6cf6b3650b26ef344b5897
+size 123648
diff --git a/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_origin.pdf b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..f052a8ed247d3e44720af9e490e88645d8954974
--- /dev/null
+++ b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/392dee1c-dea9-4f43-a722-232167d0e76c_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e669079d5b6c9ea47f31f7b7d7b60b5109a15f20885445a334f04a0011854580
+size 524928
diff --git a/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/full.md b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..b737f707c37c4e0483d27c487f8588b00ce86a09
--- /dev/null
+++ b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/full.md
@@ -0,0 +1,376 @@
+# ELMER: A Non-Autoregressive Pre-trained Language Model for Efficient and Effective Text Generation
+
+Junyi Li $^{1,3,4}$ , Tianyi Tang $^{1}$ , Wayne Xin Zhao $^{1,4*}$ , Jian-Yun Nie $^{3}$ and Ji-Rong Wen $^{1,2,4}$
+
+1Gaoling School of Artificial Intelligence, Renmin University of China
+
+$^{2}$ School of Information, Renmin University of China
+
+$^{3}$ DIRO, Université de Montréal
+
+$^{4}$ Beijing Key Laboratory of Big Data Management and Analysis Methods
+
+{lijunyi,steven_tang}@ruc.edu.cn batmanfly@gmail.com
+
+# Abstract
+
+We study the text generation task under the approach of pre-trained language models (PLMs). Typically, an auto-regressive (AR) method is adopted for generating texts in a token-by-token manner. Despite many advantages of AR generation, it usually suffers from inefficient inference. Therefore, non-autoregressive (NAR) models are proposed to generate all target tokens simultaneously. However, NAR models usually generate texts of lower quality due to the absence of token dependency in the output text. In this paper, we propose ELMER: an Efficient and effective PLM for NAR tExt geneRation to explicitly model the token dependency during NAR generation. By leveraging the early exit technique, ELMER enables the token generations at different layers, according to their prediction confidence (a more confident token will exit at a lower layer). Besides, we propose a novel pre-training objective, Layer Permutation Language Modeling, to pre-train ELMER by permuting the exit layer for each token in sequences. Experiments on three text generation tasks show that ELMER significantly outperforms NAR models and further narrows the performance gap with AR PLMs (e.g., ELMER (29.92) vs BART (30.61) ROUGE-L in XSUM) while achieving over 10 times inference speedup.
+
+# 1 Introduction
+
+Since the advent of GPT-2 (Radford et al., 2019), pre-trained language models (PLMs) have achieved state-of-the-art performance across text generation tasks, which aim to generate human-like texts on demand (Brown et al., 2020; Li et al., 2022c). These PLMs usually adopt an auto-regressive (AR) fashion to generate texts token-by-token: the next token is predicted based on all previously generated tokens. A major limitation of this approach is that it is hard to be parallelized for the inference
+
+process, thus leading to a relatively high inference latency (Gu et al., 2018). Such a limitation prevents AR models from wide deployment in online real-time applications, such as query rewriting in search engines and online chat-bot. Moreover, AR models are prone to suffering from the exposure bias problem since there is a gap between AR training and inference (Zeng and Nie, 2021). These concerns have sparked extensive interests in non-autoregressive (NAR) models for text generation (Gu et al., 2018).
+
+Compared to AR models, NAR models predict target tokens in all positions simultaneously and independently (Gu et al., 2018). This full parallelism leads to an efficient and low-latency inference process. However, the independence assumption prevents NAR models from learning the dependency among target tokens, resulting in accuracy degradation (Zhan et al., 2022). One widely-used solution to improve the NAR generation quality is to iteratively refine outputs (Gu et al., 2019; Ghazvininejad et al., 2019), which however leads to the loss in the speed-up advantage. In addition, many studies aim to learn the input-output mapping for more accurate generation via embedding mapping (Guo et al., 2019), latent alignment (Libovicky and Helcl, 2018), and discrete variables (Ma et al., 2019). While easing the difficulty of NAR generation to some extent, these methods still struggle for generating complex sentences. Therefore, inspired by Zhan et al. (2022), we argue that the key to NAR text generation is to enhance the learning of token dependency—each token should be generated depending on forward and backward generated tokens.
+
+In this paper, we propose ELMER: an Efficient and Effective PLM for NAR tExt geneRation, to explicitly learn the bi-directional token dependency. Typically, most NAR models predict tokens simultaneously only at the last layer, thus making the token prediction unaware of tokens generated in other positions. To address this issue, we propose
+
+to generate tokens at different layers and the upper-layer token generation can depend on lower-layer generated tokens from both left and right. In this way, our model can explicitly learn the dependency between tokens from different layers while enjoying full parallelism in NAR decoding, as shown in Figure 1. To this end, we propose to extend the early exit technique (Li et al., 2021c) to NAR text generation: if there is sufficient confidence to generate a token at a lower layer, the model is allowed to exit at this layer and make the prediction without passing through the upper layers.
+
+Furthermore, instead of exiting at a fixed layer for a token, we aim to predict each token at different layers for learning diverse token dependencies in NAR text generation. Thus, inspired by XLNet (Yang et al., 2019), we further propose a novel pretraining objective based on early exit, i.e., Layer Permutation Language Modeling (LPLM), to help ELMER learn complex token dependencies. Given a sequence, LPLM will permute the exit layer (from 1 to the maximum layer) for each token and maximize the NAR text generation probability w.r.t. all possible exit layer permutations of the sequence. Through LPLM, each token is able to exit at different layers and attend to all other tokens from both forward and backward positions. In this way, LPLM could effectively capture diverse token dependencies from large-scale corpora. Pre-trained with the general LPLM, ELMER can adapt to downstream text generation tasks and datasets by using specific early exit strategies.
+
+To the best of our knowledge, we are the first to introduce the idea of early exit to NAR text generation. We fine-tune ELMER on three popular text generation tasks. Experiments show that ELMER significantly improves the best NAR models by +5.71 ROUGE-1 on XSUM, +1.09 METEOR on SQuAD v1.1, and +2.26 Distinct-2 on PersonaChat, and narrows the performance gap with auto-regressive PLMs (e.g., ELMER (29.92) vs BART (30.61) ROUGE-L on XSUM) while achieving over 10x faster inference.
+
+# 2 Related Work
+
+Pre-trained Language Models. Recent years have witnessed remarkable achievement of PLMs in text generation tasks (Li et al., 2021b). Most PLMs adopt an AR paradigm to generate texts during pre-training and fine-tuning. The work based on GPT (Radford et al., 2019; Brown et al., 2020)
+
+converts different tasks into language modeling by sequentially predicting tokens. BART (Lewis et al., 2020) employs an auto-regressive decoder to recover the corrupted text in pre-training. T5 (Raffel et al., 2020) masks word spans from input texts and then sequentially predicts masked tokens. Tang et al. (2022) pre-trains a text generation model using labeled datasets with multi-task learning. Li et al. (2022b) leverages prompts to effectively fine-tune text generation models. Differently, our PLM, ELMER, adopts a NAR schema to generate texts, which leads to a very low latency in inference.
+
+Non-autoregressive Text Generation. Recently, there is a wide range of studies for NAR text generation (Gu et al., 2018; Ghazvininejad et al., 2019; Qi et al., 2021). Among them, Gu et al. (2018) is the first to propose NAR paradigm to reduce the inference latency. Ghazvininejad et al. (2019) iteratively masks and predicts a fraction of tokens that the model is least confident about. Several groups aim to learn accurate input-output mapping. For example, Sahara et al. (2020) and Libovicky and Helcl (2018) use connectionist temporal classification to perform latent alignment in NAR models. Our work is closely related to BANG (Qi et al., 2021), a PLM bridging the NAR and AR generation. We differ in that we use early exit to predict tokens at different layers, which can help NAR models learn the forward and backward token dependency. Moreover, we propose a novel pre-training objective based on early exit, LPLM, for learning diverse token dependencies by permuting the exit layer for each token.
+
+# 3 Preliminaries
+
+Generally, the goal of text generation is to model the conditional probability $\operatorname{Pr}(\mathcal{Y}|\mathcal{X})$ , where $\mathcal{X} = \langle x_1,\ldots ,x_n\rangle$ and $\mathcal{Y} = \langle y_1,\dots ,y_m\rangle$ denote the input text and output text respectively and each consists of a sequence of tokens from a vocabulary $\mathcal{V}$ . There are three common generation paradigms to model the conditional probability $\operatorname{Pr}(\mathcal{Y}|\mathcal{X})$ , i.e., autoregressive (AR), non-autoregressive (NAR), and semi-nonautoregressive (Semi-NAR) generation.
+
+AR Generation. AR generation models predict the output text based on a left-to-right factorization as:
+
+$$
+\Pr (\mathcal {Y} | \mathcal {X}) = \prod_ {t = 1} ^ {m} \Pr (y _ {t} | y _ {< t}, \mathcal {X}), \tag {1}
+$$
+
+where each token $y_{t}$ is generated based on the input
+
+text $\mathcal{X}$ and previous tokens $y_{< t}$ . Note that AR generation only models the forward token dependency. The token-by-token fashion makes AR generation process hard to be parallelized. Most of existing text generation PLMs adopt AR approach (Radford et al., 2019; Lewis et al., 2020; Raffel et al., 2020).
+
+NAR Generation. In contrast to AR models, NAR text generation models predict each token in output text simultaneously as follows, without modeling the forward or backward token dependency:
+
+$$
+\Pr (\mathcal {Y} | \mathcal {X}) = \prod_ {t = 1} ^ {m} \Pr (y _ {t} | \mathcal {X}), \tag {2}
+$$
+
+where each token $y_{t}$ is predicted only based on the input text $\mathcal{X}$ . The independence assumption makes NAR generation process parallelizable, thus significantly accelerating the inference speed (Gu et al., 2018). While, in the absence of token dependency, the generation quality of NAR models is lower than their AR counterparts (Wang et al., 2019).
+
+Semi-NAR Generation. Semi-NAR generation is formalized between AR and NAR generation as:
+
+$$
+\Pr (\mathcal {Y} | \mathcal {X}) = \prod_ {t = 1} ^ {m} \Pr (y _ {t} | \mathcal {Y} _ {c _ {t}}, \mathcal {X}), \tag {3}
+$$
+
+where each token $y_{t}$ is conditioned on the input text $\mathcal{X}$ and a visible part $\mathcal{Y}_{c_t}$ of the output text $\mathcal{V}$ . $\mathcal{V}_{c_t}$ is designed differently to balance inference latency and accuracy (Stern et al., 2019; Lee et al., 2018). Note that the lower-layer generated tokens in our model is similar to the visible part $\mathcal{V}_{c_t}$ . While, our model keeps the advantage of full parallelism in contrast to iterative Semi-NAR methods.
+
+In this paper, we mainly focus on the NAR approach, considering both effectiveness and efficiency for text generation models.
+
+# 4 Approach
+
+Our proposed NAR text generation PLM, ELMER, is depicted in Figure 1. ELMER aims to enhance the modeling of token dependency for NAR models. With early exit, tokens exiting at different layers can build the bi-directional token dependency with each other. Moreover, we design Layer Permutation Language Modeling (LPLM) to pre-train ELMER by permuting the exit layer for each token. Next, we will describe each part in detail.
+
+
+Figure 1: Overview of our proposed model ELMER.
+
+# 4.1 Early Exit for Dependency Modeling
+
+Most NAR models simultaneously predict tokens only at the last layer (Jiang et al., 2021; Zhan et al., 2022), which makes the current token generation unaware of the tokens generated in other positions. Thus, to model the bi-directional token dependency (both forward and backward), we propose to predict tokens at different layers by leveraging the early exit technique (Li et al., 2021c). In this way, the upper-layer token generation can depend on tokens generated at lower layers from both left and right.
+
+NAR Transformer. ELMER is built on the Transformer encoder-decoder architecture (Vaswani et al., 2017). Both encoder and decoder consist of $L$ stacked layers where each layer contains several sub-layers (e.g., multi-head self-attention and feedforward network). Unlike the original Transformer decoder that auto-regressively generates text, our model uses NAR fashion to generate tokens simultaneously. Given a pair of input-output text $\langle \mathcal{X},\mathcal{Y}\rangle$ , $\mathcal{X}$ is fed into the encoder and processed as hidden states $S = \langle s_1,\dots,s_n\rangle$ . We then feed a sequence of "[MASK]" tokens into the NAR decoder to generate every token in output text $\mathcal{Y}$ in parallel.
+
+Specifically, we first replace the original masked multi-head attention in decoder with bi-directional multi-head attention akin to the encoder. For each "[MASK]" token in the $t$ -th position, the $L$ decoder layers process it to hidden states $\{h_t^l\}_{1\leq l\leq L}$ as:
+
+$$
+\boldsymbol {h} _ {t} ^ {l} = \operatorname {L a y e r} ^ {l} \left(\boldsymbol {h} _ {1 \leq t \leq T} ^ {l - 1}, \boldsymbol {S}\right), \tag {4}
+$$
+
+$$
+\boldsymbol {h} _ {t} ^ {0} = \operatorname {E m b e d} \left(\left[ \text {M A S K} \right]\right), \tag {5}
+$$
+
+where $\text{Layer}^l(\cdot)$ denotes the $l$ -th layer, $\text{Embed}(\cdot)$ is the sum of word embedding and position embedding, and $T$ is the maximum length of the decoder.
+
+The output distribution for predicting the $t$ -th token $y_{t}$ is computed by feeding the last decoder state $\pmb{h}_{t}^{L}$ into a softmax classifier (parameterized by $\pmb{W}_{c}$ ) as:
+
+$$
+\Pr (y _ {t} | \boldsymbol {h} _ {t} ^ {L}) = \operatorname {s o f t m a x} (\boldsymbol {W} _ {c} \boldsymbol {h} _ {t} ^ {L}). \tag {6}
+$$
+
+Prior NAR models require to determine the output length, thus an extra module for length prediction is always needed. Instead, following Su et al. (2021), we let ELMER dynamically adjust the output length by emitting an end token (i.e., [EOS]) at any position. After the entire generation is completed, the final sequence ranges from the beginning to the position where the first end token is emitted.
+
+Early Exit Off-Ramps. Instead of predicting all tokens simultaneously at the last layer, we propose to generate tokens at different layers for learning the bi-directional token dependency. Hence, by leveraging early exit (Li et al., 2021c), if a token is predicted with sufficient confidence at a lower layer, the model is allowed to exit and predict without passing through the upper layers. In this way, the upper-layer tokens can be generated depending on forward and backward tokens generated at the lower layers. The bi-directional token dependency can further alleviate the hallucination issue in NAR generation (Gu et al., 2018), where the generated texts tend to be ungrammatical with repetitions.
+
+Specifically, we inject the "off-ramps" (Li et al., 2021c), which make predictions with intermediate hidden states, at each decoder layer. The off-ramp can be simply implemented by a softmax classifier. For an off-ramp at the $l$ -th layer, it makes the token prediction as:
+
+$$
+\begin{array}{l} \Pr \left(y _ {t} \mid \boldsymbol {h} _ {t} ^ {l}\right) = \text {O f f - R a m p} ^ {l} \left(\boldsymbol {h} _ {t} ^ {l}\right), (7) \\ = \operatorname {s o f t m a x} \left(\boldsymbol {W} _ {c} ^ {l} \boldsymbol {h} _ {t} ^ {l}\right), (8) \\ \end{array}
+$$
+
+where the $l$ -th off-ramp is parameterized by $\boldsymbol{W}_c^l$ . These off-ramps can be specified independently or share the weights across $L$ layers. Different from previous early-exit work that makes sentence-level prediction (Xin et al., 2020; Liao et al., 2021), our early exit is built at token level.
+
+During training, if a token has been predicted at the $l$ -th layer early, the hidden state $\pmb{h}_t^l$ will not be updated in upper layers. Thus, in our model, we directly copy the last hidden state $\pmb{h}_t^l$ (exit at layer $l$ ) to the subsequent layers following (Elbayad et al., 2020; Li et al., 2021c). Since the last hidden state predicts tokens with sufficient confidence, it has contained the predicted token information provided for the upper-layer tokens generation.
+
+# 4.2 Layer Permutation Pre-training
+
+The NAR models equipped with early exit predict each token at a fixed layer. To learn diverse token dependencies, we design a novel pre-training objective based on early exit, Layer Permutation Language Modeling (LPLM), where each token can exit at different layers. This is different from most prior work that focuses on designing small-scale NAR models for specific tasks such as translation. In contrast, we pre-train a general large-scale PLM on massive corpora following Qi et al. (2021). Our PLM can adapt to various downstream tasks.
+
+Layer Permutation Language Modeling. Permutation language modeling was first proposed in XLNet (Yang et al., 2019) by permuting the factorization order. For a sequence with length $T$ , there are $T!$ permutation orders to consider in autoregressive factorization. In our LPLM, rather than performing permutation on the sequence length, we permute the exit layer for each token. In particular, for each token in a sequence, we assume that it can exit at any of $L$ layers. Therefore, there are $L^T$ exit layer permutations for a sequence. Intuitively, if model parameters are shared across all exit layer permutations, each token can build diverse semantic dependencies with tokens in all positions.
+
+Formally, let $\mathcal{P}_{\mathcal{Y}} = \{\pmb {p}:\langle l_1,\dots ,l_t,\dots ,l_T\rangle \}$ be the set of all possible exit layer permutations of the sequence $\mathcal{V}$ with length $T$ . We use $l_{t}$ $(1\leq l_{t}\leq L)$ to denote the exit layer of the $t$ -th token. Then, for a permutation $\pmb {p}\in \mathcal{P}_{\mathcal{Y}}$ , the NAR generation probability (Eq. 2) based on LPLM can be expressed as:
+
+$$
+\Pr (\mathcal {Y} | \mathcal {X}) = \prod_ {t = 1} ^ {T} \Pr (y _ {t} | \mathcal {X}) = \prod_ {t = 1} ^ {T} \Pr (y _ {t} | \boldsymbol {h} _ {t} ^ {l _ {t}}), \tag {9}
+$$
+
+where the model exits at the $l_{t}$ -th decoder layer and predicts the $t$ -th token $y_{t}$ with the hidden state $\pmb{h}_{t}^{l_{t}}$ . $\operatorname*{Pr}(y_t|\pmb{h}_t^{l_t})$ can be computed using Eq. 8.
+
+During pre-training, for a sequence in our corpora, we sample $k$ layer permutations at each time and compute the output probability with Eq. 9. With the layer permutation operation, each token can exit at different layers, thus LPLM can effectively learn diverse token dependencies from large-scale corpora. Moreover, typical early exit methods usually need to set thresholds to estimate the exit layer (Elbayad et al., 2020; Li et al., 2021c), which is not flexible for large-scale pre-training. Our proposed layer permutation naturally avoids making exit estimations in large-scale pre-training.
+
+Pre-training Tasks. Following BART (Lewis et al., 2020), our model is trained by first feeding the corrupted text to encoder and then reconstructing the original text by decoder in a NAR manner using the above LPLM. We mainly adopt two useful document corruption methods:
+
+- Sentence Shuffling: The original text is first divided into sentences according to full stops, and then these sentences are randomly shuffled.
+- Text Infilling: Based on the shuffled text, we sample $15\%$ spans with lengths drawn from a Poisson distribution $(\lambda = 3)$ . Following BART (Lewis et al., 2020), each span is replaced with a single “[MASK]” token and the model can learn how many tokens in a span should be predicted.
+
+# 4.3 Downstream Fine-Tuning
+
+Our pre-trained model can be fine-tuned for various downstream text generation tasks. In fine-tuning phase, it becomes possible to precisely estimate the exit layer for each token with small-scale and task-specific datasets. Here, we mainly consider two early exit methods, i.e., hard and soft early exit.
+
+Hard Early Exit. The most straightforward way is to calculate the exit confidence and set a threshold. Following prior work (Xin et al., 2020), we quantify the exit confidence for token prediction using the entropy of the output probability distribution:
+
+$$
+H \left(y _ {t}\right) _ {\text {e n t r o p y}} = - \sum \Pr \left(y _ {t} \mid \boldsymbol {h} _ {t} ^ {l}\right) \cdot \log \Pr \left(y _ {t} \mid \boldsymbol {h} _ {t} ^ {l}\right), \tag {10}
+$$
+
+where $\operatorname*{Pr}(y_t|\pmb {h}_t^l)$ is computed as Eq. 8. In this way, a low entropy means a high confidence. Specifically, at the $l$ -th off-ramp, our ELMER model will compute the entropy of its output distribution $H(y_{t})$ and then compare with a pre-defined threshold $\delta$ to determine whether the model should exit here or continue to the next layer.
+
+Soft Early Exit. The hard early exit method only makes one prediction for each token. Following prior work (Huang et al., 2021), the soft variant predicts the outputs at every decoder layer and the prediction is fed into the next layer for further improvement. In particular, at the $l$ -th layer for the $t$ -th position, we predict the most probable word $\hat{y}_t^l$ using the $l$ -th off-ramp (Eq. 8) as follows:
+
+$$
+\hat {y} _ {t} ^ {l} = \operatorname {a r g} \max \Pr \left(y _ {t} ^ {l} \mid \boldsymbol {h} _ {t} ^ {l}\right). \tag {11}
+$$
+
+Then, we concatenate the word embedding of $\hat{y}_t^l$ with the current hidden state $h_t^l$ and process it by a
+
+linear layer as follows:
+
+$$
+\tilde {\boldsymbol {h}} _ {t} ^ {l} = \boldsymbol {W} \left[ \operatorname {E m b e d} \left(\hat {y} _ {t} ^ {l}\right); \boldsymbol {h} _ {t} ^ {l} \right], \tag {12}
+$$
+
+where $W$ is a learnable matrix and $\tilde{h}_t^l$ is the updated hidden state of the $l$ -th layer, which will be taken as input to the next $l + 1$ -th layer. Compared with the hard early exit, the soft early exit is able to calibrate the token prediction at each layer.
+
+# 4.4 Time Complexity Analysis
+
+Since AR and NAR models adopt the same encoder architecture, the difference in time complexity is dominated by decoders. To generate a sequence with length $T$ , an AR decoder with $L$ layers has a time complexity $\mathcal{O}(LT^2)$ quadratic in sequence length. In contrast, a NAR decoder has a linear time complexity $\mathcal{O}(LT)$ . This is because the attention computation in NAR decoders can be parallelized across all positions. While, our ELMER model generates tokens at different layers. Let $\overline{L} (< L)$ denote the average exit layer for a sequence, the time complexity will further be decreased to $\mathcal{O}(\overline{L} T)$ .
+
+# 5 Experiments
+
+In this section, we detail the experimental setup and then highlight the main takeaways of our results.
+
+# 5.1 Experimental Setup
+
+Pre-training Setup. We pre-train ELMER based on the 16GB corpus (including English Wikipedia and BookCorpus). For our model, we use 6 layers in both encoder and decoder, with a dimension of 768 in hidden states, consistent with the base version of many AR and NAR pre-trained models (Lewis et al., 2020; Qi et al., 2020, 2021). We pre-train our model from scratch with a learning rate of 2e-4 and a minibatch size of 4096. We adopt the dictionary from BART (Lewis et al., 2020). In pre-training, we share the off-ramp weights across all layers and sample 10 exit layer permutations for a sequence.
+
+Fine-Tuning Datasets. Following prior work (Qi et al., 2021), we fine-tune ELMER on three text generation tasks and datasets: (1) XSUM (Narayan et al., 2018) is a news summarization dataset containing 227K news article and single-sentence summary pairs; (2) SQuAD v1.1 (Rajpurkar et al., 2016) is a question generation dataset, containing 98K triples of passage, question, and answer. We concatenate the passage and answer as input and predict the question; (3) PersonaChat (Zhang
+
+| Type | Models | XSUM | Latency↓ (ms/Sample) | SQuAD v1.1 | Latency↓ (ms/Sample) |
| R-1↑ | R-2↑ | R-L↑ | R-L↑ | B-4↑ | MT↑ |
| AR | Transformer | 30.66 | 10.80 | 24.48 | 262.47 (22.0x) | 29.43 | 4.61 | 9.86 | 159.49 (13.4x) |
| MASS | 39.70 | 17.24 | 31.91 | 196.17 (16.4x) | 49.48 | 20.16 | 24.41 | 132.46 (11.1x) |
| BART | 38.79 | 16.16 | 30.61 | 185.19 (15.5x) | 42.55 | 17.08 | 23.19 | 114.00 ( 9.6x) |
| ProphetNet | 39.89 | 17.12 | 32.07 | 817.80 (68.5x) | 48.00 | 19.58 | 23.94 | 456.51 (38.4x) |
| Semi-NAR | InsT | 17.65 | 5.18 | 16.05 | 63.37 (5.3x) | 29.98 | 2.34 | 8.15 | 67.61 (5.7x) |
| iNAT | 26.95 | 6.88 | 22.43 | 31.27 (2.6x) | 32.34 | 3.16 | 9.18 | 31.59 (2.7x) |
| CMLM | 29.12 | 7.70 | 23.04 | 113.64 (9.5x) | 29.60 | 3.89 | 9.70 | 106.84 (9.0x) |
| LevT | 25.33 | 7.40 | 21.48 | 101.01 (8.5x) | 30.81 | 2.68 | 9.40 | 116.41 (9.8x) |
| BANG | 34.71 | 11.71 | 29.16 | 109.77 (9.2x) | 47.39 | 17.62 | 21.69 | 111.11 (9.3x) |
| NAR | NAT | 24.04 | 3.88 | 20.32 | 17.47 (1.5x) | 31.51 | 2.46 | 8.86 | 17.11 (1.4x) |
| iNAT | 24.02 | 3.99 | 20.36 | 16.94 (1.4x) | 32.44 | 2.33 | 8.84 | 16.52 (1.4x) |
| CMLM | 23.82 | 3.60 | 20.15 | 16.88 (1.4x) | 31.58 | 2.51 | 8.85 | 16.41 (1.4x) |
| LevT | 24.75 | 4.18 | 20.87 | 27.72 (2.3x) | 31.38 | 2.27 | 9.14 | 27.52 (2.3x) |
| BANG | 32.59 | 8.98 | 27.41 | 15.97 (1.3x) | 44.07 | 12.75 | 18.99 | 15.69 (1.3x) |
| ELMER-Hard | 34.54 | 9.78 | 26.08 | 12.39 (1.0x) | 37.94 | 11.77 | 18.01 | 12.24 (1.0x) |
| ELMER-Soft | 38.30 | 14.17 | 29.92 | 11.94 (1.0x) | 40.22 | 13.49 | 20.08 | 11.90 (1.0x) |
+
+Table 1: A comparison between ELMER and baselines on XSUM and SQuAD v1.1 datasets. R-1/2/L, B-4, and MT are short-hands for ROUGE-1/2/L, BLEU-4,and METEOR.ELMER-Hard and ELMER-Soft denote fine-tuning ELMER with hard and soft early exit strategies, respectively. Bold and underline fonts denote the best and second best methods within NAR models. Our baseline results are collected from (Liu et al., 2021) and (Qi et al., 2021).
+
+et al., 2018) is a dialog generation dataset, containing 150K triples of persona profile, dialogue history, and response. We concatenate the profile and dialogue history as input and generate the response. The statistics of datasets are shown in Appendix A.
+
+Baselines. We compare ELMER to existing popular AR, NAR, and Semi-NAR generation models.
+
+For AR generation, we experiment with a vanilla Transformer model and three PLMs:
+
+- Transformer (Vaswani et al., 2017). It is an AR generation model without pre-training. To date, Transformer has become the backbone of many text generation PLMs and our ELMER model.
+- MASS (Song et al., 2019), BART (Lewis et al., 2020), and ProphetNet (Qi et al., 2020). These are three representative PLMs for AR text generation, whose pre-training objectives vary from denoising text to future $n$ -gram prediction. For a fair comparison, we adopt the base version of these PLMs.
+
+For NAR and Semi-NAR generation, we evaluate six models with varying decoding strategies:
+
+- NAT (Gu et al., 2018). It is the first proposed NAR text generation model. This baseline adds a module in the encoder to predict fertilities, acting as a global plan for the parallel generation.
+- InsT (Stern et al., 2019). It is a Semi-NAR text generation model leveraging insertion operations. It repeatedly inserts tokens at multiple locations based on the partially inserted sequence.
+
+- iNAT (Lee et al., 2018), CMLM (Ghazvininejad et al., 2019), LevT (Gu et al., 2019), and BANG (Qi et al., 2021). These four baselines are both NAR and Semi-NAR text generation models. Among them, BANG is the recent state-of-the-art PLM for NAR text generation.
+
+Evaluation Metrics. To evaluate the effectiveness of different models, we adopt four evaluation metrics: ROUGE- $n$ assesses the text quality by computing the overlapping $n$ -grams between the generated and real texts (Lin, 2004); BLEU- $n$ computes the co-occurrence ratio of $n$ -grams between the generated and real texts (Papineni et al., 2002); METEOR assesses word-to-word matches between the generated and real texts based on the harmonic mean of the unigram precision and recall (Banerjee and Lavie, 2005); and Distinct- $n$ measures the diversity degree by calculating the number of distinct $n$ -grams in generated texts (Li et al., 2016). To examine the efficiency, we set the batch size as 1 at inference to calculate the per-sample inference latency under the same parameter setting following (Qi et al., 2021). More details about our experiments can be found in Appendix B.
+
+# 5.2 Main Results
+
+Table 1 and Table 2 display the results of ELMER and baselines on three text generation datasets.
+
+First, ELMER-Soft outperforms NAR and SemiNAR baselines on almost all datasets and metrics.
+
+| Type | Models | PersonaChat | Latency↓ (ms/Sample) |
| BLEU-1↑ | BLEU-2↑ | Distinct-1↑ | Distinct-2↑ | Overall↑ |
| AR | Transformer | 41.56 | 32.95 | 0.30 | 0.80 | 18.90 | 138.31 (11.9x) |
| MASS | 41.06 | 35.75 | 1.40 | 6.90 | 21.28 | 112.13 ( 9.7x) |
| BART | 47.60 | 39.36 | 1.10 | 6.10 | 23.54 | 106.15 ( 9.2x) |
| ProphetNet | 46.00 | 38.40 | 1.30 | 7.30 | 23.25 | 392.79 (33.9x) |
| Semi-NAR | InsT | 12.63 | 9.43 | 0.10 | 0.30 | 5.62 | 65.27 (5.6x) |
| iNAT | 41.17 | 32.13 | 0.10 | 1.10 | 18.63 | 43.25 (3.7x) |
| CMLM | 44.38 | 35.18 | 0.10 | 0.80 | 20.12 | 105.82 (9.1x) |
| LevT | 24.89 | 18.94 | 0.10 | 0.60 | 11.13 | 80.26 (6.9x) |
| BANG | 39.82 | 30.72 | 1.90 | 14.20 | 21.66 | 109.17 (9.4x) |
| NAR | NAT | 31.53 | 24.17 | 0.10 | 0.80 | 14.15 | 17.86 (1.5x) |
| iNAT | 30.56 | 23.38 | 0.10 | 0.70 | 13.69 | 16.40 (1.4x) |
| CMLM | 31.44 | 24.06 | 0.10 | 0.60 | 14.05 | 16.26 (1.4x) |
| LevT | 26.92 | 20.47 | 0.00 | 0.40 | 11.95 | 27.56 (2.4x) |
| BANG | 31.11 | 23.90 | 2.50 | 22.70 | 20.05 | 14.89 (1.3x) |
| ELMER-Hard | 29.43 | 21.89 | 1.56 | 21.45 | 18.58 | 12.01 (1.0x) |
| ELMER-Soft | 31.45 | 23.99 | 3.66 | 24.96 | 21.02 | 11.59 (1.0x) |
+
+Compared to the best NAR BANG, ELMER-Soft achieves prominent gains in effectiveness metrics such as +5.71 ROUGE-1 in XSUM, +1.09 ME-TEOR in SQuAD v1.1, and +2.26 Distinct-2 in PersonaChat. These considerable gains clearly demonstrate the effectiveness of our ELMER model. In contrast to these NAR and Semi-NAR models, our model leverages the early exit technique to explicitly model the forward and backward token dependency during parallel NAR decoding.
+
+Second, ELMER consistently achieves comparable or better results than the AR baseline without pre-training, i.e., Transformer, and further narrows the performance gap between NAR and AR PLMs. For example, the performance gap between BANG and BART in XSUM and SQuAD is 3.20 ROUGE-L and 4.20 METEOR, which has now been decreased by ELMER-Soft to 0.69 and 3.11. ELMER-Soft also obtains the best Distinct scores in PersonaChat. Diversity is critical for dialogue generation to avoid boring or useless responses. Besides, the lower BLEU scores than NAT probably because the diverse generated texts by ELMER-Soft makes a reasonable difference from real texts. For those models without pre-training such as CMLM and NAT, they tend to generate highly frequent words and common phrases such as "I, an, the", which share much overlapped and repetitive parts with the target output. By contrast, our pre-trained model generates diverse responses, which is more critical to avoid boring or useless responses in dialogue generation.
+
+Finally, in terms of efficiency, ELMER achieves
+
+Table 2: A comparison between ELMER and baselines on PersonaChat with respect to automatic evaluation metrics.
+
+| Models | XSUM |
| ROUGE-1 | ROUGE-2 | ROUGE-L |
| NAR LevT | 24.75 | 4.18 | 20.87 |
| ELMER-Hard | 34.54 | 9.78 | 26.08 |
| -w/o pre-training | 28.56 | 5.33 | 21.96 |
| ELMER-Soft | 38.30 | 14.17 | 29.92 |
| -w/o pre-training | 30.45 | 7.37 | 24.00 |
+
+Table 3: Ablation study on XSUM dataset.
+
+much faster inference speed than all NAR and AR models, w.r.t. the per sample inference latency. For example, the inference latency of AR Transformer model in XSUM, SQuAD v1.1, and PersonaChat are 262.47ms, 159.49ms, and 138.31ms per sample, while those of ELMER-Soft are 11.94ms, 11.90ms, and 11.59ms, which amount to 22.0, 13.4, and 11.9 times speedup. Compared to AR PLMs, we achieve over 10x inference speedup, especially the highest 68.5x speedup in XSUM. Moreover, ELMER-Soft is slightly faster than other NAR baselines. We speculate that this speedup is mainly due to the fact that prior NAR models require to predict the output length such as NAT or rely on multiple insertion and deletion operations such as LevT.
+
+# 5.3 Detailed Analysis
+
+We report detailed analysis of our model on XSUM dataset - we have similar findings on other datasets.
+
+Ablation Study. Our ELMER model is the first one to adopt the early exit technique to conduct NAR text generation. To learn more diverse token
+
+dependencies, we proposed the LPLM objective (Sec. 4.2) based on early exit to pre-train ELMER. Here, we evaluate the effects of early exit and large-scale LPLM training by directly applying the hard and soft early exit methods to NAR text generation without pre-training. We compare the early-exit variants with the best non-pretrained NAR model in XSUM, i.e., LevT. The results are shown in Table 3. We can observe that these two early-exit variants without pre-training perform better than LevT. This indicates that introducing the early exit mechanism can improve NAR text generation quality due to the explicit modeling of the target-side dependency. Moreover, our proposed large-scale pre-training based on the LPLM objective improves NAR results significantly and consistently in both early exit strategies. By utilizing the general LPLM, our model can capture diverse token dependencies from large-scale corpora and further adapt to downstream tasks with specific early exit methods.
+
+Parameter Sensitivity Analysis. In ELMER-Hard, the pre-defined entropy threshold $\delta$ is critical to determine at which layer our model will exit. Here, we further examine the model performance and the fraction of tokens exiting at every layers $(1\sim 6)$ by varying the exit threshold in the set $\{0.0,0.25,0.5,$ $0.75,1.0\}$ . As the threshold $\delta$ increases gradually, more tokens exit earlier. From the experiment, we find that low and high thresholds lead to reverse early exit situations shown by the fraction of tokens exiting at each layer. Therefore, we only present the results for two representative thresholds (0.5 and 1.0) in Figure 2. We can observe that: (1) when $\delta = 0.5$ , a larger fraction of tokens are generated in higher layers $(\geq 3)$ , which means a lower threshold needs more computation to achieve enough confidence. These upper-layer "difficult" tokens can depend on simple tokens such as "I", "the", "have" generated at lower layers. (2) when $\delta = 1.0$ , it shows an opposite trend and the performance drops slightly. The reason might be that 1.0 is so high that the model makes a precipitate exiting decision. Finally, according to the model performance on the validation set, we set the threshold $\delta$ as 0.5 in our experiments.
+
+# 5.4 Human Evaluation
+
+Despite the effectiveness of automatic evaluation, human evaluation remains critical for text generation (Celikyilmaz et al., 2020). Since human evaluation is expensive, we only focus on comparing
+
+
+(a) $\delta = 0.5$
+
+
+(b) $\delta = 1.0$
+Figure 2: Varying $\delta$ for ELMER-Hard on XSUM.
+
+our best performing ELMER-Soft with two AR and NAR PLMs, i.e., BART and BANG.
+
+In order to reduce the variance caused by human, three workers were asked to score texts from four aspects (Li et al., 2022a), i.e., fluency, informativeness, accuracy, and relevance. Fluency evaluates whether the text is well-formed and logical to read; Informativeness measures whether the text contains useful information; Accuracy tests whether the text describes the given content accurately; Relevance measures whether the text is relevant to the given context. These four scores are rated from 1 to 5. We further design a Turing test (Turing, 1950) where a human judge is asked to detect whether the given text is generated by a human. For each method, we average the scores from three human judges and then report the average results over 500 texts. From the results in Table 4, we can see that our model is better than NAR model BANG in terms of fluency (3.99 vs 3.42) and relevance (3.63 vs 3.38). The major reason is that our model leverages the early exit to explicitly model the token dependency, which could reduce token repetitions and improves the fluency of texts. While, our model achieves a slightly worse fluency score than the AR model BART. We speculate that BART can produce some common phrases by using the AR generation mode.
+
+We also present some generated examples by our model in Appendix C. It can be observe that our model can generate some common phrases occurred in real texts such as "surface-to-air", "South China Sea", and "main seminary". These phrases can improve the fluency of NAR generated texts. By incorporating early exit and generating tokens at different layers, our model can explicitly learn the forward and backward token dependency, which can deal with the multi-modality issue to some extent. While, as a NAR model, our model still inevitably generates some repetitive stop tokens such as "on on on", which can be further improved in future work.
+
+| Models | XSUM |
| TT (%) | Flu. | Info. | Acc. | Rel. |
| BART | 51.01 | 4.11 | 3.99 | 3.64 | 3.79 |
| BANG | 45.34 | 3.42 | 3.45 | 3.46 | 3.38 |
| ELMER-Soft | 48.90 | 3.99 | 3.52 | 3.49 | 3.63 |
| Gold | 55.67 | 4.12 | 4.29 | 3.95 | 4.05 |
+
+Table 4: Turing test (TT) and human scores on XSUM. Flu., Info., Acc. and Rel. denote fluency, informativeness, accuracy and relevance respectively.
+
+# 6 Conclusion
+
+This paper presented an efficient and effective PLM for NAR text generation, called ELMER. ELMER introduced a token-level early exit mechanism to explicitly model the semantic dependency between target tokens during parallel decoding. Moreover, we proposed a pre-training objective, Layer Permutation Language Modeling, to pre-train ELMER on large-scale corpora by permuting the exit layer for each token in a sequence. Experiments on text summarization, question generation, and dialogue generation demonstrate that our model can effectively improve the NAR generation quality compared to highly competitive NAR models and further narrow the performance gap with AR models while achieving higher inference efficiency. In future work, we will investigate the efficacy of utilizing the proposed model to iteratively generate texts and consider more early exit strategies in fine-tuning.
+
+# 7 Limitations
+
+An important limitation of ELMER compared with other NAR text generation models is the need for defining an appropriate early exit strategy. In pretraining, ELMER utilizes a general strategy, i.e., layer permutation language modeling, by permuting the exit layer for each token in a sequence. However, to apply ELMER to downstream specific tasks and datasets, we need to design an effective and suitable estimation method to decide at which layer the model will exit and predict tokens. Also, as a PLM, ELMER may present biases learned from the pre-training corpus in the output text.
+
+In this study, we evaluate ELMER on three text generation tasks and datasets, but the output length of these tasks is relatively short. We should deal with long-form text generation which raises more challenges to the NAR paradigm.
+
+# 8 Ethical Concerns
+
+Current NAR text generation techniques achieve faster inference speed but suffer from several issues like multi-modality, lack of accuracy to the input, commonsense issues etc., which makes their online real-time deployment difficult. ELMER is an effort at rectifying some of these issues, with a focus of modeling the semantic dependency between target tokens to improve NAR generation quality. However, compared to AR models, ELMER outputs continue to mix multiple candidates and repeat words at times. This should be strongly considered before any direct deployment of real-world systems.
+
+On the other hand, the text generation technology may be potentially misused for harmful applications. When deploying ELMER to online real-time platforms, the high-quality text generated by our work also makes it difficult to distinguish synthetic text from human-written text, such as fake news and stories. It is somewhat difficult to anticipate the harmful usages of our method since they often involve repurposing our model in a totally different setting or for an unexpected purpose than we planned. To alleviate this problem, we can ask for help from some classic security risk assessment frameworks such as detecting threats and potential impacts, measuring likelihood, and determining risk as a combination of likelihood and impact (Blank, 2011).
+
+# Acknowledgement
+
+This work was partially supported by Beijing Natural Science Foundation under Grant No. 4222027, and Beijing Outstanding Young Scientist Program under Grant No. BJWZYJH012019100020098, and the Outstanding Innovative Talents Cultivation Funded Programs 2021 of Renmin University of China. Xin Zhao is the corresponding author.
+
+# Reproducibility
+
+For reproducing and reusing our work, we release the pre-trained ELMER model and source codes at the link: https://github.com/RUCAIBox/ELMER. In the future, we will integrate our model into Hugging Face (Wolf et al., 2020) and TextBox (Li et al., 2021a) libraries for easy-to-use. We hope that these open-source resources will facilitate and contribute to the advancement of related research.
+
+# References
+
+Satanjeev Banerjee and Alon Lavie. 2005. METEOR: an automatic metric for MT evaluation with improved correlation with human judgments. In Proceedings of the Workshop on Intrinsic and Extrinsic Evaluation Measures for Machine Translation and/or Summarization@ACL 2005, Ann Arbor, Michigan, USA, June 29, 2005, pages 65-72. Association for Computational Linguistics.
+Rebecca M Blank. 2011. Guide for conducting risk assessments.
+Tom B Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. 2020. Language models are few-shot learners. arXiv preprint arXiv:2005.14165.
+Asli Celikyilmaz, Elizabeth Clark, and Jianfeng Gao. 2020. Evaluation of text generation: A survey. CoRR, abs/2006.14799.
+Maha Elbayad, Jiatao Gu, Edouard Grave, and Michael Auli. 2020. Depth-adaptive transformer. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Marjan Ghazvininejad, Omer Levy, Yinhan Liu, and Luke Zettlemoyer. 2019. Mask-predict: Parallel decoding of conditional masked language models. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 6111-6120. Association for Computational Linguistics.
+Jiatao Gu, James Bradbury, Caiming Xiong, Victor O. K. Li, and Richard Socher. 2018. Non-autoregressive neural machine translation. In 6th International Conference on Learning Representations, ICLR 2018, Vancouver, BC, Canada, April 30 - May 3, 2018, Conference Track Proceedings. OpenReview.net.
+Jiatao Gu, Changhan Wang, and Junbo Zhao. 2019. Levenshtein transformer. In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 11179-11189.
+Junliang Guo, Xu Tan, Di He, Tao Qin, Linli Xu, and Tie-Yan Liu. 2019. Non-autoregressive neural machine translation with enhanced decoder input. In The Thirty-Third AAAI Conference on Artificial Intelligence, AAAI 2019, The Thirty-First Innovative Applications of Artificial Intelligence Conference, IAAI 2019, The Ninth AAAI Symposium on Educational Advances in Artificial Intelligence, EAAI 2019, Honolulu, Hawaii, USA, January 27 - February 1, 2019, pages 3723-3730. AAAI Press.
+
+Chenyang Huang, Hao Zhou, Osmar R. Zaiane, Lili Mou, and Lei Li. 2021. Non-autoregressive translation with layer-wise prediction and deep supervision. CoRR, abs/2110.07515.
+Ting Jiang, Shaohan Huang, Zihan Zhang, Deqing Wang, Fuzhen Zhuang, Furu Wei, Haizhen Huang, Liangjie Zhang, and Qi Zhang. 2021. Improving non-autoregressive generation with mixup training. CoRR, abs/2110.11115.
+Jason Lee, Elman Mansimov, and Kyunghyun Cho. 2018. Deterministic non-autoregressive neural sequence modeling by iterative refinement. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, Brussels, Belgium, October 31 - November 4, 2018, pages 1173-1182. Association for Computational Linguistics.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: denoising sequence-to-sequence pre-training for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 7871-7880. Association for Computational Linguistics.
+Jiwei Li, Michel Galley, Chris Brockett, Jianfeng Gao, and Bill Dolan. 2016. A diversity-promoting objective function for neural conversation models. In *NAACL HLT* 2016, The 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, San Diego California, USA, June 12-17, 2016, pages 110-119. The Association for Computational Linguistics.
+Junyi Li, Tianyi Tang, Zheng Gong, Lixin Yang, Zhuohao Yu, Zhipeng Chen, Jingyuan Wang, Xin Zhao, and Ji-Rong Wen. 2022a. Eliteplm: An empirical study on general language ability evaluation of pretrained language models. In Proceedings of the 2022 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL 2022, Seattle, WA, United States, July 10-15, 2022, pages 3519-3539. Association for Computational Linguistics.
+Junyi Li, Tianyi Tang, Gaole He, Jinhao Jiang, Xiaoxuan Hu, Puzhao Xie, Zhipeng Chen, Zhuohao Yu, Wayne Xin Zhao, and Ji-Rong Wen. 2021a. Textbox: A unified, modularized, and extensible framework for text generation. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing: System Demonstrations, pages 30-39.
+Junyi Li, Tianyi Tang, Jian-Yun Nie, Ji-Rong Wen, and Xin Zhao. 2022b. Learning to transfer prompts for text generation. In Proceedings of the 2022 Conference of the North American Chapter of the Association for Computational Linguistics: Human
+
+Language Technologies, NAACL 2022, Seattle, WA, United States, July 10-15, 2022, pages 3506-3518. Association for Computational Linguistics.
+Junyi Li, Tianyi Tang, Wayne Xin Zhao, Jian-Yun Nie, and Ji-Rong Wen. 2022c. A survey of pretrained language models based text generation. CoRR, abs/2201.05273.
+Junyi Li, Tianyi Tang, Wayne Xin Zhao, and Ji-Rong Wen. 2021b. Pretrained language model for text generation: A survey. In Proceedings of the Thirtieth International Joint Conference on Artificial Intelligence, IJCAI 2021, Virtual Event/Montreal, Canada, 19-27 August 2021, pages 4492-4499. ijcai.org.
+Xiaonan Li, Yunfan Shao, Tianxiang Sun, Hang Yan, Xipeng Qiu, and Xuanjing Huang. 2021c. Accelerating BERT inference for sequence labeling via early-exit. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 1: Long Papers), Virtual Event, August 1-6, 2021, pages 189-199. Association for Computational Linguistics.
+Kaiyuan Liao, Yi Zhang, Xuancheng Ren, Qi Su, Xu Sun, and Bin He. 2021. A global past-future early exit method for accelerating inference of pretrained language models. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2021, Online, June 6-11, 2021, pages 2013-2023. Association for Computational Linguistics.
+Jindrich Libovicky and Jindrich Helcl. 2018. End-to-end non-autoregressive neural machine translation with connectionist temporal classification. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, Brussels, Belgium, October 31 - November 4, 2018, pages 3016-3021. Association for Computational Linguistics.
+Chin-Yew Lin. 2004. Rouge: A package for automatic evaluation of summaries. In Text summarization branches out, pages 74-81.
+Dayiheng Liu, Yu Yan, Yeyun Gong, Weizhen Qi, Hang Zhang, Jian Jiao, Weizhu Chen, Jie Fu, Linjun Shou, Ming Gong, Pengcheng Wang, Jiusheng Chen, Daxin Jiang, Jiancheng Lv, Ruofei Zhang, Winnie Wu, Ming Zhou, and Nan Duan. 2021. GLGE: A new general language generation evaluation benchmark. In Findings of the Association for Computational Linguistics: ACL/IJCNLP 2021, Online Event, August 1-6, 2021, volume ACL/IJCNLP 2021 of Findings of ACL, pages 408-420. Association for Computational Linguistics.
+Xuezhe Ma, Chunting Zhou, Xian Li, Graham Neubig, and Eduard H. Hovy. 2019. Flowseq: Nonautoregressive conditional sequence generation with generative flow. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference
+
+on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 4281-4291. Association for Computational Linguistics.
+Shashi Narayan, Shay B. Cohen, and Mirella Lapata. 2018. Don't give me the details, just the summary! topic-aware convolutional neural networks for extreme summarization. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, Brussels, Belgium, October 31 - November 4, 2018, pages 1797-1807. Association for Computational Linguistics.
+Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In Proceedings of the 40th annual meeting of the Association for Computational Linguistics, pages 311-318.
+Weizhen Qi, Yeyun Gong, Jian Jiao, Yu Yan, Weizhu Chen, Dayiheng Liu, Kewen Tang, Houqiang Li, Jiusheng Chen, Ruofei Zhang, Ming Zhou, and Nan Duan. 2021. BANG: bridging autoregressive and non-autoregressive generation with large scale pretraining. In Proceedings of the 38th International Conference on Machine Learning, ICML 2021, 18-24 July 2021, Virtual Event, volume 139 of Proceedings of Machine Learning Research, pages 8630-8639. PMLR.
+Weizhen Qi, Yu Yan, Yeyun Gong, Dayiheng Liu, Nan Duan, Jiusheng Chen, Ruofei Zhang, and Ming Zhou. 2020. Prophetnet: Predicting future n-gram for sequence-to-sequence pre-training. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, EMNLP 2020, Online Event, 16-20 November 2020, pages 2401-2410. Association for Computational Linguistics.
+Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. 2019. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 21:140:1-140:67.
+Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. 2016. Squad: 100, $000+$ questions for machine comprehension of text. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, EMNLP 2016, Austin, Texas, USA, November 1-4, 2016, pages 2383-2392. The Association for Computational Linguistics.
+Chitwan Sahara, William Chan, Saurabh Saxena, and Mohammad Norouzi. 2020. Non-autoregressive machine translation with latent alignments. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 1098-1108. Association for Computational Linguistics.
+
+Kaitao Song, Xu Tan, Tao Qin, Jianfeng Lu, and TieYan Liu. 2019. MASS: masked sequence to sequence pre-training for language generation. In Proceedings of the 36th International Conference on Machine Learning, ICML 2019, 9-15 June 2019, Long Beach, California, USA, volume 97 of Proceedings of Machine Learning Research, pages 5926-5936. PMLR.
+Mitchell Stern, William Chan, Jamie Kiros, and Jakob Uszkoreit. 2019. Insertion transformer: Flexible sequence generation via insertion operations. In Proceedings of the 36th International Conference on Machine Learning, ICML 2019, 9-15 June 2019, Long Beach, California, USA, volume 97 of Proceedings of Machine Learning Research, pages 5976-5985. PMLR.
+Yixuan Su, Deng Cai, Yan Wang, David Vandyke, Simon Baker, Piji Li, and Nigel Collier. 2021. Non-autoregressive text generation with pre-trained language models. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, EACL 2021, Online, April 19 - 23, 2021, pages 234-243. Association for Computational Linguistics.
+Tianyi Tang, Junyi Li, Wayne Xin Zhao, and JiRong Wen. 2022. MVP: multi-task supervised pretraining for natural language generation. CoRR, abs/2206.12131.
+Alan M. Turing. 1950. Computing machinery and intelligence. Mind, LIX(236):433-460.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pages 5998-6008.
+Yiren Wang, Fei Tian, Di He, Tao Qin, ChengXiang Zhai, and Tie-Yan Liu. 2019. Non-autoregressive machine translation with auxiliary regularization. In The Thirty-Third AAAI Conference on Artificial Intelligence, AAAI 2019, The Thirty-First Innovative Applications of Artificial Intelligence Conference, IAAI 2019, The Ninth AAAI Symposium on Educational Advances in Artificial Intelligence, EAAI 2019, Honolulu, Hawaii, USA, January 27 - February 1, 2019, pages 5377-5384. AAAI Press.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, EMNLP 2020 - Demos, Online, November 16-20, 2020, pages 38-45. Association for Computational Linguistics.
+
+Ji Xin, Raphael Tang, Jaejun Lee, Yaoliang Yu, and Jimmy Lin. 2020. Deebert: Dynamic early exiting for accelerating BERT inference. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, ACL 2020, Online, July 5-10, 2020, pages 2246-2251. Association for Computational Linguistics.
+Zhilin Yang, Zihang Dai, Yiming Yang, Jaime G. Carbonell, Ruslan Salakhutdinov, and Quoc V. Le. 2019. Xlnet: Generalized autoregressive pretraining for language understanding. In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 5754-5764.
+Yan Zeng and Jian-Yun Nie. 2021. An investigation of suitability of pre-trained language models for dialogue generation - avoiding discrepancies. In Findings of the Association for Computational Linguistics: ACL/IJCNLP 2021, Online Event, August 1-6, 2021, volume ACL/IJCNLP 2021 of Findings of ACL, pages 4481-4494. Association for Computational Linguistics.
+Jiaao Zhan, Qian Chen, Boxing Chen, Wen Wang, Yu Bai, and Yang Gao. 2022. Non-autoregressive translation with dependency-aware decoder. CoRR, abs/2203.16266.
+Saizheng Zhang, Emily Dinan, Jack Urbanek, Arthur Szlam, Douwe Kiela, and Jason Weston. 2018. Personalizing dialogue agents: I have a dog, do you have pets too? In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics, ACL 2018, Melbourne, Australia, July 15-20, 2018, Volume 1: Long Papers, pages 2204-2213. Association for Computational Linguistics.
+
+# Appendix
+
+We provide some experiment-related information as supplementary materials. The appendix is organized into three sections:
+
+- Statistics of each dataset are presented in Appendix A;
+- Training settings of baselines and our model ELMER are presented in Appendix B;
+- Generated examples by our model are presented in Appendix C.
+
+# A Statistics of Datasets
+
+The detailed information of these three datasets is listed in Table 5.
+
+| Dataset | #Train | #Valid | #Test | #Output |
| XSUM | 204,045 | 11,332 | 11,334 | 21.1 |
| SQuAD v1.1 | 75,722 | 10,570 | 11,877 | 11.6 |
| PersonaChat | 122,499 | 14,602 | 14,056 | 11.9 |
+
+Table 5: Statistics of three datasets. #Output denotes the average number of tokens in the output texts.
+
+# B Experimental Details
+
+For AR baselines, we adopt the hyper-parameters: learning rate 2e-5, batch size 20, Adam optimizer, and the maximum input and output length of 512. We fine-tune these models on each dataset for 50 epochs and select the best model. For NAR and Semi-NAR baselines, the hyper-parameters are the same as AR baselines except the number of fine-tuning epochs, since NAR models need more epochs to converge (Qi et al., 2021). We fine-tune these baselines and ELMER for 50 epochs and save checkpoints for every epoch. We select the best checkpoint based on the performance on validation set. Following BANG (Qi et al., 2021), the difference between semi-NAR and NAR models lies in that: (1) we select the outputs from the first iteration as the NAR outputs, since the first iteration only depends on the input text; (2) we select the outputs from the maximum (we set as 10) iteration as the semi-NAR outputs, since each iteration depends on both the input text and the last generated texts. Most settings and results are collected from GLGE (Liu et al., 2021) and BANG (Qi et al., 2021). To make a fair comparison with non-pretrained baselines, we also compare ELMER with
+
+the best NAR non-pretrained baseline LevT in ablation analysis (Table 3).
+
+# C Case Study
+
+We show some qualitative examples of these three datasets in Table 6, Table 7, and Table 8.
+
+Due to the explicit modeling of the bi-direction token dependency, our model can generate some common phrases occurred in real texts such as "surface-to-air", "South China Sea", and "main seminary". These phrases can improve the fluency of NAR generated texts. But, as a NAR model, our model still inevitably generates some repetitive tokens such as "on on on". The generated examples in PersonaChat also explain that our model generates more diverse responses, which are very different from the real responses.
+
+| News | Reports on Wednesday suggested more than one iguana was actually filmed, with scenes then stitched together. But the BBC has said only one animal was chased by the snakes - with other iguñas only filmed for close-ups. The scene quickly went viral when it was aired last year and later won a Bafta for must-see moment. The iguana hatchling, filmed in the Galapagos, eventually got away - much to viewers' relief. The Daily Mail claimed the episode was embroiled in a "fakery row" after producer Elizabeth White told the Media Production Show: "It wasn't the same iguana, no, and often we have to augment it with other clips. "Unfortunately lizards, snakes and iguanas aren't good at 'takes'." But the BBC defended the Sir David Attenborough-fronted programme, with a spokeswoman saying: "The BBC strongly refutes any suggestion that the award-winning iguana v snakes sequence was 'faked'. "The final iguana chase in which one iguana escapes the snakes was - unusually for natural history filming - shot using two cameras, allowing us to follow both the individual iguana and the snakes' point of view. "What was captured in the field was extraordinary animal behaviour which had never been witnessed or filmed before." She added: "As is common in natural history film-making, pick-up shots were filmed separately - for example close-ups of iguana eyes - to make the story of the sequence as clear as possible for the audience. "This is absolutely in keeping with the norms of natural history film-making - and absolutely in line with the BBC's editorial policy guidelines, and was a true representation of animal behaviour." | Satellite images taken on 14 February appear to show two batteries of eight missile launchers and a radar system on Woody or Yongxing Island in the Paracels. The presence of missiles would signifi-cantly increase tensions in the acrimonious South China Sea dispute. China's Foreign Minister Wang Yi said reports were a Western media invention. But Mr Wang defended "the limited and necessary self-defence facilities" on islands inhabited by Chinese personnel as "consistent with the right for self-preservation and self-protection.... under the inter-national law". Asked about the reports, US Secretary of State John Kerry attacked China's increased "militarisation" of the contested region, saying it was a "serious concern". Taiwan's defence ministry said it had "learned of an air defence missile sys-tem deployed" by the Chinese on Woody Island. It would not say how many missiles had been deployed or when, but told the BBC they would be capable of targeting civilian and military aircraft. The commander of the US Pacific Fleet confirmed the deployment to Reuters news agency. Adm Harry Harris said such a move would be "a militarisation of the South China Sea in ways" China's President Xi Jinping had pledged not to make. Japan's Chief Cabinet Secretary Yoshihide Suga said there were "serious concerns" over China's "unilateral move to change the status quo" in the region, and "we cannot accept this fact". China has been carrying out extensive land reclamation work in the region, which it says is legal and for civilian purposes. But the work has angered other countries which also claim the territory, and there is growing concern about the implications of the area becoming militarised. |
| Summaries | The BBC has denied claims award-winning series Planet Earth II faked a nail-biting scene showing a baby iguana being chased by racer snakes . | China has deployed surface-to-air missiles on a dis-puted island in the South China Sea, Taiwan says . |
| ELMER-Hard | The BBC has defended claims the BBC nature doc-umentary of the iguana footage of a "faked storm " by a Davidborough. | China has confirmed that new reports of on surface-air on on of in the South China Sea . |
| ELMER-Soft | The BBC has defended claims a BBC documentary about a series of from natural drama Sir David Atten was "faked". | China is the first of of air defence missiles on a disputed disputed island of the South China Sea, according to US |
+
+Table 6: Qualitative examples on XSUM dataset.
+
+| Paragraphs | Moreau Seminary [SEP] The university is the major seat of the Congregation of Holy Cross ( albeit not its official headquarters , which are in Rome ) . Its main seminary , Moreau Seminary , is located on the campus across St . Joseph lake from the Main Building . Old College , the oldest building on campus and located near the shore of St . Mary lake , houses undergraduate seminarians . Retired priests and brothers reside in Fatima House ( a former retreat center ) , Holy Cross House , as well as Columba Hall near the Grotto . The university through the Moreau Seminary has ties to theologian Frederick Buechner . While not Catholic , Buechner has praised writers from Notre Dame and Moreau Seminary created a Buechner Prize for Preaching. | eight [SEP] The College of Engineering was established in 1920 , however , early courses in civil and mechanical engineering were a part of the College of Science since the 1870s . Today the college , housed in the Fitzpatrick , Cushing , and Stinson - Remick Halls of Engineering , includes five departments of study ? @ S aerospace and mechanical engineering , chemical and biomolecular engineering , civil engineering and geological sciences , computer science and engineering , and electrical engineering ? @ S with eight B . S . degrees offered . Additionally , the college offers five - year dual degree programs with the Colleges of Arts and Letters and of Business awarding additional B . A . and Master of Business Administration ( MBA ) degrees , respectively . |
| Questions | What is the primary seminary of the Congregation of the Holy Cross ? | How many BS level degrees are offered in the College of Engineering at Notre Dame ? |
| ELMER-Hard | What is the name of Frederick Binaryary at St. Joseph ? | How many B.S degrees offered at the College of the engineering ? |
| ELMER-Soft | What is the name of the main seminary at St. Joseph ? | How many B.S. degrees offered at the College of departments ? |
+
+Table 7: Qualitative examples on SQuAD v1.1 dataset.
+
+| Histories | i love to meet new people . i have a turtle named timo-ty . my favorite sport is ultimate frisbee . my parents are living in bora bora . autumn is my favorite season . [SEP] hello , how are you doing tonight ? i am well an loving this interaction how are you ? i am great . i just got back from the club . | i just bought a brand new house . i like to dance at the club . i run a dog obedience school . i have a big sweet tooth . i like taking and posting selkies . [SEP] hello , how are you doing tonight ? i am well an loving this interaction how are you ? i am great . i just got back from the club . this is my favorite time of the year season wise i would rather eat chocolate cake during this season . what club did you go to ? me an timo-ty watched tv i went to club chino . what show are you watching ? lol oh okay kind of random do you live in a house or apartment ? we watched a show about animals like him i love those shows . i am really craving cake . why does that matter any ? i went outdoors to play frisbee |
| Reponses | this is my favorite time of the year season wise | it matters because i have a sweet tooth . |
| ELMER-Hard | what team of do you do ? ultimate | i like to exercise with my dogs . |
| ELMER-Soft | i love club! do you have new friends ? | cool. i spend time with my dog . |
+
+Table 8: Qualitative examples on PersonaChat dataset.
\ No newline at end of file
diff --git a/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/images.zip b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..cf7c7c2807eba6889aaa5879529d2daf7ac2626e
--- /dev/null
+++ b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:32df6147b847c3451adfa6ea446d774393ad7693492f8417fd554c35ba36b1a0
+size 1126785
diff --git a/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/layout.json b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..6a4f2a029a22ff59d090b6f9400999a4542a6c28
--- /dev/null
+++ b/elmeranonautoregressivepretrainedlanguagemodelforefficientandeffectivetextgeneration/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:aae47af238418fc21cbb08ce9ddd96d316bc51131305c4a06f0cbac8c6026766
+size 443566
diff --git a/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_content_list.json b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..ddecf81bf8ba98b603b2c9f7b256d99ca37511a8
--- /dev/null
+++ b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6aee580e37ff4931c2d45a7598599635bf44ec019cccbca9080644f306577a85
+size 115420
diff --git a/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_model.json b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..2ff01b61baad0025ad9fc17aae046d42d58d67d8
--- /dev/null
+++ b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8a58dce4bfcb6730074d9bb5c323c9342aa871d1381a330868ac343c2410bb65
+size 142743
diff --git a/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_origin.pdf b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..ec469e193f1e5584494a6f191f27a5aca29b8908
--- /dev/null
+++ b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/2b3acb58-ce17-4cba-b6ef-f50f06e7abd0_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9e773faa62fb96b3e37719e0faeda8f77d56fbffd400c120bfb1a63560ed7065
+size 728104
diff --git a/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/full.md b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..7fbda024dd63893dee384823989c9c748ac4aa40
--- /dev/null
+++ b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/full.md
@@ -0,0 +1,522 @@
+# Empowering Dual-Encoder with Query Generator for Cross-Lingual Dense Retrieval
+
+Houxing Ren $^{1*}$ Linjun Shou $^{2}$ Ning Wu $^{2}$ Ming Gong $^{2}$ Daxin Jiang $^{2\dagger}$
+
+$^{1}$ School of Computer Science and Engineering, Beihang University
+
+2Microsoft STC Asia
+
+renhouxing@buaa.edu.cn {lisho,wuning,migon,djiang} @microsoft.com
+
+# Abstract
+
+In monolingual dense retrieval, lots of works focus on how to distill knowledge from cross-encoder re-ranker to dual-encoder retriever and these methods achieve better performance due to the effectiveness of cross-encoder re-ranker. However, we find that the performance of the cross-encoder re-ranker is heavily influenced by the number of training samples and the quality of negative samples, which is hard to obtain in the cross-lingual setting. In this paper, we propose to use a query generator as the teacher in the cross-lingual setting, which is less dependent on enough training samples and high-quality negative samples. In addition to traditional knowledge distillation, we further propose a novel enhancement method, which uses the query generator to help the dual-encoder align queries from different languages, but does not need any additional parallel sentences. The experimental results show that our method outperforms the state-of-the-art methods on two benchmark datasets.
+
+# 1 Introduction
+
+Information Retrieval (IR) aims to retrieve pieces of evidence for a given query. Traditional methods mainly use sparse retrieval systems such as BM25 (Robertson and Zaragoza, 2009), which depend on keyword matching between queries and passages. With the development of large-scale pretrained language models (PLMs) (Vaswani et al., 2017; Devlin et al., 2019) such as BERT, dense retrieval methods (Lee et al., 2019; Karpukhin et al., 2020) show quite effective performance. These methods usually employed a dual-encoder architecture to encode both queries and passages into dense embeddings and then perform approximate nearest neighbor searching (Johnson et al., 2021).
+
+Recently, leveraging a cross-encoder re-ranker as the teacher model to distill knowledge to a dual
+
+
+(a) BM25.
+
+
+(b) DPR.
+Figure 1: The performance of cross-encoder and query generator when varying the number of training samples and retrievers. We use BM25 and DPR as retrievers, respectively. For the cross-encoder (BERT-Large), we use retrieved top-100 passages which do not contain the answer as negative and contrastive loss for training. For the query generator (T5-Base), we firstly train it with the query generation task and then fine-tune the model with the same setting as BERT-Large. The reported performance is the top-5 score of re-ranked top 500 passages on the NQ test set.
+
+encoder has shown quite effective to boost the dual-encoder performance. Specifically, these methods first train a warm-up dual-encoder and a warm-up cross-encoder. Then, they perform knowledge distillation from the cross-encoder to the dual-encoder by KL-Divergence or specially designed methods. For example, RocketQAv2 (Qu et al., 2021) proposed dynamic distillation, and AR2 (Zhang et al., 2021) proposed adversarial training.
+
+However, there are two major problems when scaling the method to the cross-lingual dense retrieval setting. Firstly, the cross-encoder typically requires large amounts of training data and high-quality negative samples due to the gap between pre-training (token-level task) and fine-tuning (sentence-level task), which are usually not satisfied in the cross-lingual setting (Asai et al., 2021a). Due to expensive labeling and lack of annotators in global languages, especially low-resource languages, the training data in cross-lingual are quite limited. Then with the limited training data, the dual-encoder is not good enough to provide
+
+high-quality negative samples to facilitate the cross-encoder. Secondly, the cross-lingual gaps between different languages have a detrimental effect on the performance of cross-lingual models. Although some cross-lingual pre-training methods such as InfoXLM (Chi et al., 2021) and LaBSE (Feng et al., 2022) have put lots of effort into this aspect by leveraging parallel corpus for better alignment between different languages, these parallel data are usually expensive to obtain and the language alignment could be damaged in the fine-tuning stage if without any constraint.
+
+To solve these problems, we propose to employ a query generator in the cross-lingual setting, which uses the likelihood of a query against a passage to measure the relevance. On the one hand, the query generator can utilize pre-training knowledge with small training data in fine-tuning stage, because both of its pre-training and fine-tuning have a consistent generative objective. On the other hand, the query generation task is defined over all tokens from the query rather than just the [CLS] token in the cross-encoder, which has been demonstrated to be a more efficient training paradigm (Clark et al., 2020). As shown in Figure 1, with the number of training samples dropping, the performance of BERT-Large drops more sharply than T5-Base. Besides, the query generator is less sensitive to high-quality negative samples. As we can see, using BM25 as the retriever to mine negative samples for re-ranker training, the gap between cross-encoder and query generator is smaller than the gap using DPR as the retriever. Finally, the query generator can provide more training data by generation, which is precious in the cross-lingual setting. To sum up, the query generator is more effective than the cross-encoder in the cross-lingual setting.
+
+Based on these findings, we propose a novel method, namely QuiCK, which stands Query generator improved dual-encoder by Cross-lingual Knowledge distillation. Firstly, at the passage level, we employ a query generator as the teacher to distill the relevant score between a query and a passage into the dual-encoder. Secondly, at the language level, we use the query generator to generate synonymous queries in other languages for each training sample and align their retrieved results by KL-Divergence. Considering the noise in the generated queries, we further propose a scheduled sampling method to achieve better performance.
+
+The contributions of this paper are as follows:
+
+- We propose a cross-lingual query generator as a teacher model to empower the cross-lingual dense retrieval model and a novel iterative training approach is leveraged for the joint optimizations of these two models.
+- On top of the cross-lingual query generator, a novel cost-effective alignment method is further designed to boost the dense retrieval performance in low-resource languages, which does not require any additional expensive parallel corpus.
+- Extensive experiments on two public cross-lingual retrieval datasets demonstrate the effectiveness of the proposed method.
+
+# 2 Related Work
+
+Retrieval. Retrieval aims to search relevant passages from a large corpus for a given query. Traditionally, researchers use bag-of-words (BOW) based methods such as TF-IDF and BM25 (Robertson and Zaragoza, 2009). These methods use a sparse vector to represent the text, so we call them sparse retrievers. Recently, some studies use neural networks to improve the sparse retriever such as DocTQuery (Nogueira et al., 2019) and DeepCT (Dai and Callan, 2020).
+
+In contrast to sparse retrievers, dense retrievers usually employ a dual-encoder to encode both queries and passages into dense vectors whose lengths are much less than sparse vectors. These methods mainly focus on two aspects: pretraining (Lee et al., 2019; Guu et al., 2020; Lu et al., 2021; Gao and Callan, 2021a,b; Zhou et al., 2022) and fine-tuning methods, including negative sampling (Karpukhin et al., 2020; Luan et al., 2021; Xiong et al., 2021; Zhan et al., 2021) and multiview representations (Khattab and Zaharia, 2020; Humeau et al., 2020; Tang et al., 2021; Zhang et al., 2022). Another fine-tuning method is jointly training the dual-encoder with a cross-encoder. For example, RDR (Yang and Seo, 2020) and FIDKD (Izacard and Grave, 2021) distill knowledge from a reader to the dual-encoder; RocketQA (Qu et al., 2021), PAIR (Ren et al., 2021a), RocketQAv2 (Ren et al., 2021b), and AR2 (Zhang et al., 2021) jointly train the dual-encoder with a cross-encoder to achieve better performance.
+
+Recently, with the development of cross-lingual pre-trained models (Conneau et al., 2020), researchers pay more attention to cross-lingual dense
+
+
+(a) Dual-Encoder.
+
+
+(b) Cross-Encoder.
+Figure 2: Overview of different model architectures designed for retrieval or re-ranking.
+
+
+(c) Query Generator.
+
+retrieval (Asai et al., 2021a; Longpre et al., 2020). For example, CORA (Asai et al., 2021b) leverages a generator to help mine retrieval training data, Sentri (Sorokin et al., 2022) proposes a single encoder and self-training, and DR.DECR (Li et al., 2021) uses parallel queries and sentences to perform cross-lingual knowledge distillation.
+
+Re-ranking. Re-ranking aims to reorder the retrieved passages as the relevant scores. Due to the small number of retrieved passages, re-ranking usually employs high-latency methods to obtain better performance, e.g., cross-encoder. Traditionally, the re-ranking task is heavily driven by manual feature engineering (Guo et al., 2016; Hui et al., 2018). With the development of pre-trained language models (e.g., BERT), researchers use the pre-trained models to perform re-ranking tasks (Nogueira and Cho, 2019; Li et al., 2020). In addition to cross-encoder, researchers also try to apply generator to re-ranking. For example, monoT5 (Nogueira et al., 2020) proposes a prompt-based method to re-rank passages with T5 (Raffel et al., 2020) and other studies (dos Santos et al., 2020; Zhuang et al., 2021; Lesota et al., 2021) propose to use the log-likelihood of the query against the passage as the relevance to perform the re-ranking task.
+
+Recently, with the size of pre-trained models scaling up, the generative models show competitive zero-shot and few-shot ability. Researchers start to apply large generative models to zero-shot and few-shot re-ranking. For example, SGPT (Muen-nighoff, 2022) and UPR (Sachan et al., 2022) propose to use generative models to perform zero-shot re-ranking. $\mathbf{P}^3$ Ranker (Hu et al., 2022) demonstrates that generative models achieve better performance in the few-shot setting. Note that all of these works are concurrent to our work. Instead of using a query generator as a re-ranker only, we propose to leverage the query generator as a teacher model to enhance the performance of the cross-lingual dual-encoder. In addition to the traditional knowledge distillation, we further propose a novel
+
+cost-effective alignment method to boost the dense retrieval performance in low-resource languages.
+
+# 3 Preliminaries
+
+In this section, we give a brief review of dense retrieval and re-ranking. The overviews of all methods are presented in Figure 2.
+
+Dual-Encoder. Given a query $q$ and a large corpus $C$ , the retrieval task aims to find the relevant passages for the query from a large corpus. Usually, a dense retrieval model employs two dense encoders (e.g., BERT) $E_{Q}(\cdot)$ and $E_{P}(\cdot)$ . They encode queries and passages into dense embeddings, respectively. Then, the model uses a similarity function, often dot-product, to perform retrieval:
+
+$$
+f _ {d e} (q, p) = E _ {Q} (q) \cdot E _ {P} (p), \tag {1}
+$$
+
+where $q$ and $p$ denote the query and the passage, respectively. During the inference stage, we apply the passage encoder $E_{P}(\cdot)$ to all the passages and index them using FAISS (Johnson et al., 2021) which is an extremely efficient, open-source library for similarity search. Then given a query $q$ , we derive its embedding by $\mathbf{v}_q = E_Q(q)$ and retrieve the top $k$ passages with embeddings closest to $\mathbf{v}_q$ .
+
+Cross-Encoder Re-ranker. Given a query $q$ and top $k$ retrieved passages $C$ , the re-ranking task aims to reorder the passages as the relevant scores. Due to the limited size of the corpus, the re-ranking task usually employs a cross-encoder to perform interaction between words across queries and passages at the same time. These methods also introduce a special token [SEP] to separate $q$ and $p$ , and then the hidden state of the [CLS] token from the cross-encoder is fed into a fully-connected layer to output the relevant score:
+
+$$
+f _ {c e} (q, p) = \boldsymbol {W} \times E _ {C} (q \| p) + b, \tag {2}
+$$
+
+where “ $\|$ ” denotes concatenation with the [SEP] token. During the inference stage, we apply the
+
+cross-encoder $E_{C}(\cdot)$ to all $\langle \mathbf{q},\mathbf{p}\rangle$ pair and reorder the passages by the scores.
+
+Query Generator Re-ranker. Similar to cross-encoder re-ranker, query generator re-ranker also aims to reorder the passages as the relevant scores. For the query generator re-ranker, we use the log-likelihood of the query against the passage to measure the relevance:
+
+$$
+f _ {q g} (q, p) = \log P (q | p) = \sum_ {t = 0} \log P \left(q _ {t} \mid q _ {< t}, p\right), \tag {3}
+$$
+
+where $q_{< t}$ denotes the previous tokens before $q_{t}$ . The rest of settings are the same as the cross-encoder re-ranker and are omitted here.
+
+Training. The goal of retrieval and re-ranking is to enlarge the relevant score between the query and the relevant passages (a.k.a., positive passages) and lessen the relevant score between the query and the irrelevant passages (a.k.a., negative passages). Let $\{q_i, p_i^+, p_i, 0, p_i^-, p_{i,1}^-, \dots, p_{i,n}^-\}$ be the $i$ -th training sample. It consists of a query, a positive passage, and $n$ negative passages. Then we can employ the contrastive loss function, called InfoNCE (van den Oord et al., 2018), to optimize the model:
+
+$$
+\mathcal {L} _ {R} = - \log \frac {e ^ {f \left(q _ {i} , p _ {i} ^ {+}\right)}}{e ^ {f \left(q _ {i} , p _ {i} ^ {+}\right)} + \sum_ {j = 0} ^ {n} e ^ {f \left(q _ {i} , p _ {i , j} ^ {-}\right)}}, \tag {4}
+$$
+
+where $f$ denotes the similarity function, e.g., $f_{de}$ in Eq. (1), $f_{ce}$ in Eq. (2), or $f_{qq}$ in Eq. (3).
+
+Cross-lingual Retrieval. In the cross-lingual information retrieval task, passages and queries are in different languages. In this paper, we consider the passages are in English and the queries are in non-English languages. A sample consists of three components: a query in a non-English language, a positive passage in English, and a span answer in English. Given a non-English query, the task aims to retrieve relevant passages in English to answer the query. If a retrieved passage contains the given span answer, it is regarded as a positive passage, otherwise, it is a negative passage.
+
+# 4 Methodology
+
+In this section, we present the proposed QuiCK. The overview of the proposed method is presented in Figure 3. We start with the training of the query generator, then present how to perform distillation and alignment training for the dual-encoder, and we finally discuss the entire training process.
+
+
+Figure 3: Overview of the proposed QuiCK.
+
+# 4.1 Training of Query Generator
+
+In our method, we employ mT5 (Xue et al., 2021) as the query generator. The query generator has two roles: teacher and generator. As a teacher, it aims to better re-rank the candidate passages with relevance and distill the knowledge to the dual-encoder. As a generator, it aims to generate synonymous queries in different languages.
+
+Input Format. As we employ mT5, we design a prompt template for input sentences. Considering that most passages are long, we propose introducing the span answer as input to encourage the generator to focus on the same segment and generate parallel queries in different languages. As a result, we use "generate [language] query: answer: [span answer] content: [content]" as the template. For a specific sample, we fill the three placeholders with the language of the target query, the span answer, and the passage content, respectively.
+
+Training. Considering the two roles of the query generator, the entire training process for the query generator contains two stages: query generation training and re-ranking training.
+
+Firstly, we train the generator with the generation task, which takes the positive passage as input and aims to generate the query. The task can be for
+
+mulated as maximizing the conditional probability:
+
+$$
+\begin{array}{l} \hat {q} = \underset {q} {\arg \max } P (q | p, a) \\ = \arg \max _ {q} \prod_ {t = 0} P \left(q _ {t} | p, a, q _ {< t}\right), \tag {5} \\ \end{array}
+$$
+
+where $q_{t}$ is the $t$ -th token of the generated query, $a$ denotes the span answer, and $q_{| Methods | R@2kt | R@5kt |
| Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg | Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg |
| mDPR* | 38.8 | 48.4 | 52.5 | 26.6 | 44.2 | 33.3 | 39.9 | 40.5 | 48.9 | 60.2 | 59.2 | 34.9 | 49.8 | 43.0 | 55.5 | 50.2 |
| DPR + MT* | 43.4 | 53.9 | 55.1 | 40.2 | 50.5 | 30.8 | 20.2 | 42.0 | 52.4 | 62.8 | 61.8 | 48.1 | 58.6 | 37.8 | 32.4 | 50.6 |
| Sentri* | 47.6 | 48.1 | 53.1 | 46.6 | 49.6 | 44.3 | 67.9 | 51.0 | 56.8 | 62.2 | 65.5 | 53.2 | 55.5 | 52.3 | 80.3 | 60.8 |
| w/ Bi-Encoder* | 47.8 | 39.1 | 48.9 | 51.2 | 40.2 | 41.2 | 49.4 | 45.4 | 55.1 | 43.3 | 59.5 | 59.4 | 51.2 | 52.0 | 56.9 | 53.9 |
| DR.DECR* | - | - | - | - | - | - | - | 66.0 | 70.2 | 85.9 | 69.4 | 65.1 | 68.8 | 68.8 | 83.2 | 73.1 |
| w/o KDXOR | - | - | - | - | - | - | - | 60.6 | - | - | - | - | - | - | - | 68.6 |
| w/o KDPC | - | - | - | - | - | - | - | 56.6 | - | - | - | - | - | - | - | 63.6 |
| QuiCK | 52.8 | 70.1 | 62.2 | 54.8 | 62.8 | 57.8 | 70.6 | 61.3 | 63.8 | 78.0 | 65.3 | 63.5 | 69.8 | 67.1 | 74.8 | 68.9 |
| QuiCK w/ LaBSE | 67.3 | 78.9 | 65.9 | 59.8 | 66.3 | 63.7 | 80.7 | 68.9 | 72.2 | 83.2 | 69.7 | 68.0 | 70.9 | 71.7 | 84.9 | 74.4 |
+
+Table 2: Comparison results on XOR-Retieve test set.
+
+| Methods | R@2kt | R@5kt |
| GAAMA | 52.8 | 59.9 |
| Sentri | 52.7 | 61.0 |
| CCP | 54.8 | 63.0 |
| Sentri 2.0 | 58.5 | 64.6 |
| DR.DECR | 63.0 | 70.3 |
| QuiCK w/ LaBSE | 65.6 | 72.0 |
+
+notes a distillation method which introduces synonymous English queries. "KD $PC$ " denotes a distillation method which introduces parallel corpus. In addition, we also employ LaBSE base (Feng et al., 2022) to evaluate the proposed QuiCK with parallel corpus, which is a state-of-the-art model pre-trained with parallel corpus.
+
+XOR-Retieve. Table 1 shows the results on XOR-Retieve dev set. The proposed QuiCK outperforms mDPR, DPR+MT, and Sentri with a clear edge in almost all languages. Although QuiCK does not introduce any parallel corpus, it also outperforms DR.DECR w/o $\mathrm{KD}_{XOR}$ . Finally, QuiCK based on LaBSE outperforms all baselines, especially DR.DECR w/o $\mathrm{KD}_{XOR}$ , and even outperforms DR.DECR which utilizes both parallel queries and parallel corpus. Note that knowledge distillation with parallel corpus in DR.DECR is designed for cross-lingual dense retrieval, but LaBSE is a general pre-trained model for all cross-lingual tasks. These results show the effectiveness of the proposed QuiCK. Our method combines two methods in dense retrieval and cross-lingual tasks, namely distillation and alignment. We further analyze the contribution of each component in Section 5.3.
+
+In addition, we show the results on XOR-Retrieve test set in Table 2, which is copied from
+
+Table 3: Average performance of 20 unseen languages in MKQA test set. “*” denotes the results are copied from the Sentri paper.
+
+| Methods | R@2kt |
| CORA* | 41.1 |
| BM25 + MT* | 42.0 |
| Senti* | 53.3 |
| w/ Bi-Encoder* | 45.3 |
| QuiCK | 53.4 |
| QuiCK w/ LaBSE | 60.3 |
+
+the leaderboard1 on June 15, 2022. As we can see, our method achieves the top position on the leaderboard of XOR-Retrieve.
+
+MKQA. Furthermore, we evaluate the zero-shot performance of our method on the MKQA test set. Following previous works (Sorokin et al., 2022), we directly evaluate the dual-encoder training on XOR-Retieve data and report the performance of unseen languages on MKQA. As shown in Table 3, our method outperforms all baselines and even performs better than Sentri. Note that Sentri uses a shared encoder with large size. The comparison between Sentri and Sentri w/ Bi-Encoder shows that the large encoder has better transfer ability. Finally, the proposed QuiCK w/ LaBSE outperforms all baselines with a clear edge. It shows the better transfer ability of our methods.
+
+# 5.3 Methods Analysis
+
+Ablation Study. Here, we check how each component contributes to the final performance. We construct the ablation experiments on XOR-Retrieve data. We prepare four variants of our method:
+
+Table 4: Ablation results on XOR-Retieve dev set.
+
+| Methods | R@2kt | R@5kt |
| QuiCK | 61.3 | 68.9 |
| w/o Sampling | 59.5 | 67.5 |
| w/o Alignment | 59.9 | 67.1 |
| w/o Generation | 58.8 | 65.9 |
| w/o All | 41.5 | 53.4 |
+
+Table 5: Effect of alignment based on different pretrained languages models.
+
+| Methods | XLM-R | LaBSE |
| R@2kt | R@5kt | R@2kt | R@5kt |
| QuiCK | 61.3 | 68.9 | 68.9 | 74.4 |
| w/o Alignment | 59.9 | 67.1 | 67.9 | 73.8 |
+
+(1) w/o Sampling denotes without the scheduled sampling but keep the threshold $T$ for $c'$ , a.k.a., if $c' \geq T$ , then $c' = 1$ , otherwise $c' = 0$ ; (2) w/o Alignment denotes without $\mathcal{L}_A$ in Eq. (11); (3) w/o Generation denotes without $\mathcal{L}_D'$ and $\mathcal{L}_A$ in Eq. (11); (4) w/o All denotes without the enhanced training, a.k.a., the warm-up dual-encoder.
+
+Table 4 presents all comparison results of the four variants. As we can see, the performance rank of R@5kt can be given as: w/o All < w/o Generation < w/o Alignment < w/o Sampling < QuiCK. These results indicate that all components are essential to improve performance. And we can find the margin between w/o Alignment and w/o Sampling is small, it denotes that the generated queries are noisy and demonstrate the effectiveness of our schedule sampling strategy.
+
+Effect of Alignment. As we mentioned in Section 1, the alignment established in the pre-training stage may be damaged without any constraint in the fine-tuning stage. Here, we construct experiments on both XLM-R and LaBSE to analyze the effectiveness of the proposed alignment training. As shown in Table 5, the proposed alignment training is effective based on the two models. It indicates that the alignment constraint in the fine-tuning stage is effective for models which pretrained with parallel corpus. And we find that the gains of alignment training based on XLM-R are larger than LaBSE, which shows that the alignment constraint is more effective for models which do not pre-trained with parallel corpus.
+
+Cross-Encoder versus Query Generator. Here, we analyze the re-ranking ability of cross-encoder and query generator. Here, we use the warm-up
+
+
+Figure 4: Re-ranking performance of cross-encoder and query generator on XOR-Retrieve dev set with different numbers of candidate passages.
+
+
+Figure 5: The changes of R@2kt during the iteratively training on XOR-Retrieve dev set. Here, "QG" denotes Query Generator and "CE" denotes Cross Encoder.
+
+dual-encoder to retrieve passages, vary the number of candidate passages, and then evaluate the reranked result. As shown in Figure 4, when we use the top-100 candidate passages, the performance of the cross-encoder and generator is almost the same. But as the number of candidate passages increases, especially when it surpasses 500, the gap between the performance of the cross-encoder and query generator gradually becomes larger. It shows low generalization performance of the cross-encoder when there are not enough training samples.
+
+Visualization of the Training Procedure. We visualize the performance changes of R@2kt during the training of both dual-encoder and query generator re-ranker which re-ranks the retrieved top-100 passages. We also incorporate a cross-encoder (initialized with XLM-R Large) to perform distillation and re-ranking for comparison. As shown in Figure 5, the R@2kt of all models gradually increases as the iteration increases. While the training advances closer to convergence, the improvement gradually slows down. In the end, the performance of the dual-encoder is improved by approximately $17\%$ , and the performance of the query generator is
+
+improved by approximately $20\%$ . Finally, comparing the performance of the cross-encoder and the query generator, we can find that there are approximately $6\%$ gaps for both teachers and students. It shows the effectiveness of our method.
+
+# 6 Conclusion
+
+In this paper, we showed that the cross-encoder performs poorly when there are not sufficient training samples which are hard to obtain in the crosslingual setting. Then we proposed a novel method that utilizes the query generator to improve the dual-encoder. We firstly proposed to use a query generator as the teacher. After that, we proposed a novel alignment method for cross-lingual retrieval which does not need any parallel corpus. Extensive experimental results show that the proposed method outperforms the baselines and significantly improves the state-of-the-art performance. Currently, our method depends on training data in all target languages. As future work, we will investigate how to perform the proposed method for zero-shot cross-lingual dense retrieval.
+
+# 7 Limitations
+
+The limitations are summarized as follows.
+
+- The method depends on training data in all target languages. Intuitively, the method can be directly applied to the zero-shot cross-lingual dense retrieval if we only take the passage as input for the query generator, but the query generator performs poorly in the zero-shot setting. As future work, novel pre-training tasks for cross-lingual generation can be considered.
+- The method does not investigate how to effectively train the query generator for the re-ranking task, just directly applies the training method for the cross-encoder re-ranker. We believe the potential of query generators for re-ranking is strong and designing a special re-ranking training method for query generators such as token-level supervision may be interesting for future work.
+- The method requires large GPU sources. The final model approximately costs 12 hours on 8 NVIDIA Tesla A100 GPUs. Although researchers who do not have enough GPU sources can use the "gradient accumulation" technique to reduce GPU memory consumption, they also need to pay more time.
+
+- This work does not consider the inconsistency between different countries (e.g., law and religion), which leads to inconsistent positive passages for synonymous queries in different languages (e.g., the legal age of marriage varies from country to country). Because we find that most of the queries in XOR-Retrieve contain the target country such as "Mika on yleisin kissa lui Suomessa?" (translation: What is the most common cat breed in Finland?).
+
+# References
+
+Akari Asai, Jungo Kasai, Jonathan H. Clark, Kenton Lee, Eunsol Choi, and Hannaneh Hajishirzi. 2021a. XOR QA: cross-lingual open-retrieval question answering. In *NAACL-HLT*, pages 547–564. Association for Computational Linguistics.
+Akari Asai, Xinyan Yu, Jungo Kasai, and Hanna Hajishirzi. 2021b. One question answering model for many languages with cross-lingual dense passage retrieval. In NeurIPS, pages 7547-7560.
+Zewen Chi, Li Dong, Furu Wei, Nan Yang, Saksham Singhal, Wenhui Wang, Xia Song, Xian-Ling Mao, Heyan Huang, and Ming Zhou. 2021. Infoxm: An information-theoretic framework for cross-lingual language model pre-training. In *NAACL-HLT*, pages 3576–3588. Association for Computational Linguistics.
+Kevin Clark, Minh-Thang Luong, Quoc V. Le, and Christopher D. Manning. 2020. ELECTRA: pretraining text encoders as discriminators rather than generators. In ICLR. OpenReview.net.
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettlemoyer, and Veselin Stoyanov. 2020. Unsupervised cross-lingual representation learning at scale. In ACL, pages 8440–8451. Association for Computational Linguistics.
+Zhuyun Dai and Jamie Callan. 2020. Context-aware term weighting for first stage passage retrieval. In SIGIR, pages 1533-1536. ACM.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: pre-training of deep bidirectional transformers for language understanding. In *NAACL-HLT* (1), pages 4171–4186. Association for Computational Linguistics.
+Cicero Nogueira dos Santos, Xiaofei Ma, Ramesh Nallapati, Zhiheng Huang, and Bing Xiang. 2020. Beyond [CLS] through ranking by generation. In EMNLP (1), pages 1722-1727. Association for Computational Linguistics.
+
+Fangxiaoyu Feng, Yinfei Yang, Daniel Cer, Naveen Arivazhagan, and Wei Wang. 2022. Language-agnostic BERT sentence embedding. In ACL (1), pages 878-891. Association for Computational Linguistics.
+Luyu Gao and Jamie Callan. 2021a. Condenser: a pretraining architecture for dense retrieval. In EMNLP (1), pages 981-993. Association for Computational Linguistics.
+Luyu Gao and Jamie Callan. 2021b. Unsupervised corpus aware language model pre-training for dense passage retrieval. CoRR, abs/2108.05540.
+Jiafeng Guo, Yixing Fan, Qingyao Ai, and W. Bruce Croft. 2016. A deep relevance matching model for ad-hoc retrieval. In CIKM, pages 55-64. ACM.
+Kelvin Guu, Kenton Lee, Zora Tung, Panupong Pasupat, and Ming-Wei Chang. 2020. REALM: retrieval-augmented language model pre-training. CoRR, abs/2002.08909.
+Xiaomeng Hu, Shi Yu, Chenyan Xiong, Zhenghao Liu, Zhiyuan Liu, and Ge Yu. 2022. $\mathbf{P}^3$ ranker: Mitigating the gaps between pre-training and ranking fine-tuning with prompt-based learning and prefinetuning. CoRR, abs/2205.01886.
+Kai Hui, Andrew Yates, Klaus Berberich, and Gerard de Melo. 2018. Co-pacrr: A context-aware neural IR model for ad-hoc retrieval. In WSDM, pages 279-287. ACM.
+Samuel Humeau, Kurt Shuster, Marie-Anne Lachaux, and Jason Weston. 2020. Poly-encoders: Architectures and pre-training strategies for fast and accurate multi-sentence scoring. In ICLR. OpenReview.net.
+Gautier Izacard and Edouard Grave. 2021. Distilling knowledge from reader to retriever for question answering. In *ICLR*. OpenReview.net.
+Jeff Johnson, Matthijs Douze, and Hervé Jégou. 2021. Billion-scale similarity search with gpus. IEEE Trans. Big Data, 7(3):535-547.
+Vladimir Karpukhin, Barlas Oguz, Sewon Min, Patrick S. H. Lewis, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. In EMNLP (1), pages 6769-6781. Association for Computational Linguistics.
+Omar Khattab and Matei Zaharia. 2020. Colbert: Efficient and effective passage search via contextualized late interaction over BERT. In SIGIR, pages 39-48. ACM.
+Tom Kwiatkowski, Jennimaria Palomaki, Olivia Redfield, Michael Collins, Ankur P. Parikh, Chris Alberti, Danielle Epstein, Illia Polosukhin, Jacob Devlin, Kenton Lee, Kristina Toutanova, Llion Jones, Matthew Kelcey, Ming-Wei Chang, Andrew M. Dai, Jakob Uszkoreit, Quoc Le, and Slav Petrov. 2019. Natural questions: a benchmark for question answering
+
+research. Trans. Assoc. Comput. Linguistics, 7:452-466.
+Kenton Lee, Ming-Wei Chang, and Kristina Toutanova. 2019. Latent retrieval for weakly supervised open domain question answering. In ACL (1), pages 6086-6096. Association for Computational Linguistics.
+Oleg Lesota, Navid Rekabsaz, Daniel Cohen, Klaus Antonius Grasserbauer, Carsten Eickhoff, and Markus Schedl. 2021. A modern perspective on query likelihood with deep generative retrieval models. In ICTIR, pages 185-195. ACM.
+Canjia Li, Andrew Yates, Sean MacAvaney, Ben He, and Yingfei Sun. 2020. PARADE: passage representation aggregation for document reranking. CoRR, abs/2008.09093.
+Yulong Li, Martin Franz, Md. Arafat Sultan, Bhavani Iyer, Young-Suk Lee, and Avirup Sil. 2021. Learning cross-lingual IR from an english retriever. CoRR, abs/2112.08185.
+Shayne Longpre, Yi Lu, and Joachim Daiber. 2020. MKQA: A linguistically diverse benchmark for multilingual open domain question answering. CoRR, abs/2007.15207.
+Shuqi Lu, Di He, Chenyan Xiong, Guolin Ke, Waleed Malik, Zhicheng Dou, Paul Bennett, Tie-Yan Liu, and Arnold Overwijk. 2021. Less is more: Pretrain a strong siamese encoder for dense text retrieval using a weak decoder. In EMNLP (1), pages 2780-2791. Association for Computational Linguistics.
+Yi Luan, Jacob Eisenstein, Kristina Toutanova, and Michael Collins. 2021. Sparse, dense, and attentional representations for text retrieval. Trans. Assoc. Comput. Linguistics, 9:329-345.
+Niklas Muennighoff. 2022. SGPT: GPT sentence embeddings for semantic search. CoRR, abs/2202.08904.
+Rodrigo Nogueira, Zhiying Jiang, Ronak Pradeep, and Jimmy Lin. 2020. Document ranking with a pretrained sequence-to-sequence model. In EMNLP (Findings), volume EMNLP 2020 of Findings of ACL, pages 708-718. Association for Computational Linguistics.
+Rodrigo Nogueira, Jimmy Lin, and AI Epistemic. 2019. From doc2query to docctttttquery. Online preprint.
+Rodrigo Frassetto Nogueira and Kyunghyun Cho. 2019. Passage re-ranking with BERT. CoRR, abs/1901.04085.
+Yingqi Qu, Yuchen Ding, Jing Liu, Kai Liu, Ruiyang Ren, Wayne Xin Zhao, Daxiang Dong, Hua Wu, and Haifeng Wang. 2021. Rocketqa: An optimized training approach to dense passage retrieval for open-domain question answering. In *NAACL-HLT*, pages 5835-5847. Association for Computational Linguistics.
+
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 21:140:1-140:67.
+Ruiyang Ren, Shangwen Lv, Yingqi Qu, Jing Liu, Wayne Xin Zhao, Qiaoqiao She, Hua Wu, Haifeng Wang, and Ji-Rong Wen. 2021a. PAIR: leveraging passage-centric similarity relation for improving dense passage retrieval. In ACL/IJCNLP (Findings), volume ACL/IJCNLP 2021 of Findings of ACL, pages 2173-2183. Association for Computational Linguistics.
+Ruiyang Ren, Yingqi Qu, Jing Liu, Wayne Xin Zhao, Qiaoqiao She, Hua Wu, Haifeng Wang, and Ji-Rong Wen. 2021b. Rocketqav2: A joint training method for dense passage retrieval and passage re-ranking. In EMNLP (1), pages 2825-2835. Association for Computational Linguistics.
+Stephen E. Robertson and Hugo Zaragoza. 2009. The probabilistic relevance framework: BM25 and beyond. Found. Trends Inf. Retr., 3(4):333-389.
+Devendra Singh Sachan, Mike Lewis, Mandar Joshi, Armen Aghajanyan, Wen-tau Yih, Joelle Pineau, and Luke Zettlemoyer. 2022. Improving passage retrieval with zero-shot question generation. CoRR, abs/2204.07496.
+Nikita Sorokin, Dmitry Abulkhanov, Irina Piotkovskaya, and Valentin Malykh. 2022. Ask me anything in your native language. In *NAACL-HLT*, pages 395–406. Association for Computational Linguistics.
+Hongyin Tang, Xingwu Sun, Beihong Jin, Jingang Wang, Fuzheng Zhang, and Wei Wu. 2021. Improving document representations by generating pseudo query embeddings for dense retrieval. In ACL/IJCNLP (1), pages 5054-5064. Association for Computational Linguistics.
+Aäron van den Oord, Yazhe Li, and Oriol Vinyals. 2018. Representation learning with contrastive predictive coding. CoRR, abs/1807.03748.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In NIPS, pages 5998-6008.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Rémi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander M. Rush. 2020. Transformers: State-of-the-art natural language processing. In EMNLP (Demos), pages 38-45. Association for Computational Linguistics.
+
+Lee Xiong, Chenyan Xiong, Ye Li, Kwok-Fung Tang, Jialin Liu, Paul N. Bennett, Junaid Ahmed, and Arnold Overwijk. 2021. Approximate nearest neighbor negative contrastive learning for dense text retrieval. In ICLR. OpenReview.net.
+Linting Xue, Noah Constant, Adam Roberts, Mihir Kale, Rami Al-Rfou, Aditya Siddhant, Aditya Barua, and Colin Raffel. 2021. mt5: A massively multilingual pre-trained text-to-text transformer. In *NAACL-HLT*, pages 483-498. Association for Computational Linguistics.
+Huiyun Yang, Huadong Chen, Hao Zhou, and Lei Li. 2022. Enhancing cross-lingual transfer by manifold mixup. CoRR, abs/2205.04182.
+Sohee Yang and Minjoon Seo. 2020. Is retriever merely an approximator of reader? CoRR, abs/2010.10999.
+Jingtao Zhan, Jiaxin Mao, Yiqun Liu, Jiafeng Guo, Min Zhang, and Shaoping Ma. 2021. Optimizing dense retrieval model training with hard negatives. In SIGIR, pages 1503-1512. ACM.
+Hang Zhang, Yeyun Gong, Yelong Shen, Jiancheng Lv, Nan Duan, and Weizhu Chen. 2021. Adversarial retriever-ranker for dense text retrieval. CoRR, abs/2110.03611.
+Shunyu Zhang, Yaobo Liang, Ming Gong, Daxin Jiang, and Nan Duan. 2022. Multi-view document representation learning for open-domain dense retrieval. In ACL (1), pages 5990-6000. Association for Computational Linguistics.
+Bo Zheng, Li Dong, Shaohan Huang, Wenhui Wang, Zewen Chi, Saksham Singhal, Wanxiang Che, Ting Liu, Xia Song, and Furu Wei. 2021. Consistency regularization for cross-lingual fine-tuning. In ACL/IJCNLP (1), pages 3403-3417. Association for Computational Linguistics.
+Jiawei Zhou, Xiaoguang Li, Lifeng Shang, Lan Luo, Ke Zhan, Enrui Hu, Xinyu Zhang, Hao Jiang, Zhao Cao, Fan Yu, Xin Jiang, Qun Liu, and Lei Chen. 2022. Hyperlink-induced pre-training for passage retrieval in open-domain question answering. In ACL (1), pages 7135-7146. Association for Computational Linguistics.
+Shengyao Zhuang, Hang Li, and Guido Zuccon. 2021. Deep query likelihood model for information retrieval. In ECIR (2), volume 12657 of Lecture Notes in Computer Science, pages 463-470. Springer.
+
+# Appendix
+
+# A Dataset
+
+XOR-Retieve. XOR-Retieve dataset is a crosslingual retrieval dataset which aims to retrieve relevant passages from the English corpus for non-English queries. XOR-Retieve data contains queries in seven typologically diverse languages: Arabic (Ar), Bengali (Bn), Finnish (Fi), Japanese (Ja), Korean (Ko), Russian (Ru), and Telugu (Te). The statistics are presented in Table 6.
+
+Table 6: Data statistics for XOR-Retieve.
+
+ | Train | Dev | Test |
| Ar | 2,574 | 350 | 137 |
| Bn | 2,582 | 312 | 128 |
| Fi | 2,088 | 360 | 530 |
| Ja | 2,288 | 296 | 449 |
| Ko | 2,469 | 299 | 646 |
| Ru | 1,941 | 366 | 235 |
| Te | 1,308 | 238 | 374 |
| Corpus size | 18,003,200 |
+
+MKQA. MKQA dataset is a translated dataset of 10,000 query-answer pairs from NQ to 26 different languages, and the dataset is only used for evaluation. In our experiments, since we measure the R@2kt score, we filter the samples which do not have span answers. Then, we get 6,620 parallel queries in each language. Finally, we directly evaluate the dual-encoder trained on XOR-Retrieve data and use the same corpus with XOR-Retrieve in the experiments. Note that Arabic (Ar), English (En), Finnish (Fi), Japanese (Ja), Korean (Ko), and Russian (Ru) are seen in the training stage and we only report the performance of the rest 20 languages. As a result, it has a total of 132,400 samples.
+
+# B Efficiency Report
+
+We list the time cost of training and inference in Table 7 which is made with 8 NVIDIA A100 GPUs.
+
+Table 7: Efficiency Report.
+
+| Training | Warm-up | 3h |
| Per Iteration of Dual-Encoder | 1h |
| Per Iteration of Generator | 0.3h |
| Index Refresh | 0.35h |
| Overall | 11.5h |
| Inference | Build Index | 0.35h |
| Query Encoding | 40ns |
| Dense Retrieval | 2ms |
+
+Table 8: Hyper-parameters.
+
+ | Parameters | Value |
| Max Query Length | 32 |
| Max Passage Length | 128 |
| TrainingWarm-upDual-Encoder | Learning Rate | 1e-5 |
| Batch Size | 128 |
| Negative Size | 255 |
| Optimizer | AdamW |
| Scheduler | Linear |
| Warmup Proportion | 0.1 |
| Training Steps on NQ | 18400 |
| Training Steps on XOR | 2000 |
| TrainingWarm-upGeneratoron QG | Learning Rate | 1e-4 |
| Batch Size | 64 |
| Optimizer | AdamW |
| Scheduler | Linear |
| Warmup Proportion | 0.1 |
| Training Steps | 5000 |
| TrainingWarm-upGeneratoron Re-ranking | Learning Rate | 1e-5 |
| Batch Size | 32 |
| Negative Size | 15 |
| Optimizer | AdamW |
| Scheduler | Linear |
| Warmup Proportion | 0.1 |
| Training Steps | 1000 |
| IterativelyTraining ofDual-Encoder | Learning Rate | 1e-5 |
| Batch Size | 64 |
| Candidate Size | 32 |
| Optimizer | AdamW |
| Scheduler | Linear |
| Warmup Proportion | 0.1 |
| Training Steps | 3000 |
| Threshold T in Eq. (8) | 0.3 |
| Coefficient α in Eq. (11) | 0.5 |
| # of iterations | 5 |
| IterativelyTraining ofGenerator | Learning Rate | 1e-5 |
| Batch Size | 32 |
| Negative Size | 15 |
| Optimizer | AdamW |
| Scheduler | Linear |
| Warmup Proportion | 0.1 |
| Training Steps | 500 |
| # of iterations | 5 |
+
+# C Hyper-parameters
+
+We present all hyper-parameters in Table 8.
+
+# D Additional Experiments
+
+# D.1 Parameter Sensitivity
+
+In this section, we tune the parameters of the proposed method to analyze parameter sensitivity. We vary both the threshold $T$ (Eq. (8)) and the coefficient $\alpha$ (Eq. (11)) in the set $\{0.1, 0.3, 0.5, 0.7, 0.9\}$ . We report the tuning results with both R@2kt and R@5kt on the XOR-Retrieve dev set in Figure 6. As we can see, $T = 0.3$ and $\alpha = 0.5$ lead to the optimal R@5kt which is the ordering basis on
+
+
+(a) Threshold $(T)$ .
+
+
+(b) Coefficient $(\alpha)$ .
+Figure 6: Parameter sensitivity.
+
+the leaderboard.
+
+In addition, we find that the optimal R@2kt and R@5kt are led by different thresholds $T$ . Because the two metrics have different sensitivities to data quality, low-quality data is helpful to R@5kt but harmful to R@2kt. As a result, a small threshold $T$ leads to more low-quality alignment training data and further leads to higher R@5kt but lower R@2kt. On the contrary, the optimal R@2kt and R@5kt are led by the same coefficient $\alpha$ .
+
+Overall, our model is relatively stable when varying the two parameters, and consistently better than Sentri and Dr.DECR w/o $\mathrm{KD}_{PC}$ .
+
+# D.2 Effect of The Number of Candidates
+
+Here, we investigate the effect of the number of candidates which is demonstrated to have a significant effect on the final performance. As shown in Figure 7, a large number of candidates leads to better performance. And when the number surpasses 32, the improvement gradually slows down. The results indicate that 32 candidates can better represent the whole corpus.
+
+# D.3 Effect of Model Size
+
+Following Sentri (Sorokin et al., 2022), we employ a shared encoder (i.e., the parameters of the query encoder and the passage encoder are the same) with large size as the dual-encoder and evaluate our method. As shown in Table 9, QuiCK with XLM-R
+
+
+Figure 7: Effect of the number of candidate passages.
+
+Table 9: Effect of model size.
+
+ | XLM-R Base | XLM-R Large |
| R@2kt | R@5kt | R@2kt | R@5kt |
| Ar | 52.8 | 63.8 | 64.4 | 72.2 |
| Bn | 70.1 | 78.0 | 77.0 | 80.9 |
| Fi | 62.2 | 65.3 | 67.0 | 70.1 |
| Ja | 54.8 | 63.5 | 56.4 | 67.2 |
| Ko | 62.8 | 69.8 | 67.4 | 73.3 |
| Ru | 57.8 | 67.1 | 66.7 | 72.2 |
| Te | 70.6 | 74.8 | 79.4 | 84.0 |
| Avg | 61.3 | 68.9 | 68.4 | 74.3 |
+
+Large achieves a significant performance improvement, which further demonstrates the effectiveness of the proposed QuiCK.
+
+# D.4 Effect of Scheduled Sampling
+
+Previously, we demonstrate the effectiveness of the scheduled sampling by ablation study. Here, we present two generated samples to qualitatively analyze the scheduled sampling. As shown in Table 10, for the first case, the generated queries in other languages have the same semantics as the query from the source language. The sample is effective in alignment training and is helpful to achieve better performance. For the second case, the generated query in Finnish is relevant to the query from the source language but not synonymous. The sample is harmful to the model training. These samples indicate that the scheduled sampling is necessary for alignment training. In this way, we can reduce the impact of the cases which do not have the same semantics and further achieve better performance.
+
+# D.5 Effect of Span Answer
+
+In our method, we employ the span answer to encourage the query generator to generate synonymous queries. Here, we conduct experiments to evaluate the effect of the span answer. Specially, we use another template: "generate [language] query: [content]" where we only need to fill two placeholders with the language of the target query and
+
+Table 10: Two generated examples. The span answers are in bold.
+
+Passage: Johanna Maria Magdalena "Magda" Goebbels (née Ritschel; 11 November 1901 - 1 May 1945) was the wife of Nazi Germany's Propaganda Minister Joseph Goebbels. A prominent member of the Nazi Party, she was a close ally, companion and political supporter of Adolf Hitler. Some historians refer to her as the unofficial "First Lady" of Nazi Germany, while others give that title to Emmy Göring.
+
+Source Query (Ja): ヨハンナ・マリア・マケダレナ・デルスは何歳で死去た?
+
+Translation: At what age did Johanna Maria McDalena Goebbels die?
+
+Generated Query (Ru): B KaKOM Bo3pacTe yMepJa MarJa Te66eJIbC?
+
+Translation: At what age did Magda Goebbels die?
+
+Generated Query (Fi): Minä vuonna Magda Goebbels kuoli?
+
+Translation: In what year did Magda Goebbels die?
+
+Passage: Charles V (24 February 1500 – 21 September 1558) was ruler of both the Holy Roman Empire from 1519 and the Spanish Empire (as Charles V of Spain) from 1516, as well as of the lands of the former Duchy of Burgundy from 1506. He stepped down from these and other positions by a series of abdications between 1554 and 1556. Through inheritance, he brought together under his rule extensive territories in western, central, and southern Europe, and the Spanish viceroyalties in the Americas and Asia.
+
+Source Query (Ko): 小生の男はが5歳の男はがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはがはかをむに。
+
+Translation: How long was the reign of Charles V of the Holy Roman Empire?
+
+Generated Query (Ru): CkoJIbKO JeT IIpaBnJI KapJ V?
+
+Translation: How many years did Charles V rule?
+
+Generated Query (Fi): Minä vuonna Charles V hallitsi Rooman valtakuntaa?
+
+Translation: In what year did Charles V rule the Roman Empire?
+
+the passage content. We also incorporate the cross-encoder for comparison. We use the re-rankers to re-rank the retrieved results of the warm-up dual-encoder initialized with XLM-R. Note that introducing the span answer into the cross-encoder makes the re-ranking task easier, because the cross-encoder only needs to check whether the passage contains the span answer. The scores of this cross-encoder almost degenerate into hard labels and it is difficult to effectively train the dual-encoder by distilling knowledge from this cross-encoder.
+
+We show the results in Table 12. Based on these results, we have the following findings. On the one hand, the query generator trained with span answers is better than the query generator without span answers. It shows that taking span answers
+
+Table 11: A generated example with different input templates. The span answer is in bold. Here, "QG" denotes query generator.
+
+Passage: The Higgs boson is an elementary particle in the Standard Model of particle physics, produced by the quantum excitation of the Higgs field, one of the fields in particle physics theory. It is named after physicist Peter Higgs, who in 1964, along with five other scientists, proposed the mechanism which suggested the existence of such a particle. Its existence was confirmed in 2012 by the ATLAS and CMS collaborations based on collisions in the LHC at CERN.
+
+Generated Query by QG w/ span answer (Fi): Kuka on kehittänyt Higgs-boson?
+
+Translation: Who developed the Higgs boson?
+
+Generated Query by QG w/ span answer (Ko): 퍷그수을 썸은 기재한 사료는 턱구일가?
+
+Translation: Who first discovered Higson?
+
+Generated Query by QG w/o span answer (Fi): Milloin Higgs on lóydetty?
+
+Translation: When was Higgs Found?
+
+Generated Query by QG w/o span answer (Ko): KTo 6bJI IepBbIM HCCJIeIOBaTeJIem ΦИЗКИ Higgs?
+
+Translation: Who was Higgs' first physics researcher?
+
+as input leads to better performance on re-ranking tasks for the query generator. On the other hand, both the two query generator is better than the cross-encoder when re-ranking top-1000 retrieved passages, it shows the effectiveness of the query generator in the cross-lingual setting.
+
+In addition, we show queries generated by the two query generators in Table 11. As we can see, for the query generator that does not take the span answer as input, the generated queries can be answered by the passage, but they focus on different segments of the passage and they are not synonymous. On contrary, for the query generator that takes the span answer as input, generated queries can be answered by the passage and they are synonymous. It shows that taking the span answer as input can effectively encourage the generator to generate synonymous queries.
+
+# E Detailed Results
+
+Due to the limited space, we only present average performance for some experiments in Section 5. Here, we present the detailed performance in all languages of these experiments. Firstly, we present the detailed performance of all methods on the MKQA test set in Table 13. Secondly, we present the detailed performance of ablation results in Table 14. Finally, we present the detailed performance for evaluating the effect of alignment in Table 15.
+
+Table 12: Performance comparison of different re-rankers on XOR-Retrieve dev set. The best results are in bold. Here, "QG" denotes query generator.
+
+| Methods | R@2kt | R@5kt |
| Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg | Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg |
| Dual-Encoder | 35.3 | 43.1 | 50.3 | 35.7 | 44.6 | 31.2 | 50.0 | 41.5 | 49.5 | 54.9 | 59.2 | 45.2 | 55.1 | 31.2 | 63.4 | 53.4 |
| Re-ranking top-100 retrieved passages |
| QG w/ Answer | 51.1 | 57.2 | 53.5 | 43.2 | 55.1 | 43.9 | 61.8 | 52.3 | 56.6 | 60.5 | 60.5 | 51.0 | 60.7 | 46.4 | 67.6 | 57.6 |
| QG w/o Answer | 48.9 | 55.6 | 54.1 | 41.9 | 53.3 | 43.5 | 61.8 | 51.3 | 56.6 | 60.9 | 59.9 | 49.8 | 59.3 | 46.8 | 68.1 | 57.3 |
| Cross-Encoder | 49.2 | 53.6 | 57.6 | 41.1 | 54.0 | 41.4 | 63.0 | 51.4 | 55.3 | 59.9 | 62.1 | 49.8 | 60.4 | 47.3 | 66.4 | 57.3 |
| Re-ranking top-1000 retrieved passages |
| QG w/ Answer | 53.7 | 66.1 | 56.7 | 52.3 | 59.3 | 56.1 | 68.9 | 59.0 | 61.2 | 71.1 | 62.1 | 58.1 | 65.6 | 61.6 | 74.4 | 64.9 |
| QG w/o Answer | 52.4 | 62.8 | 56.1 | 49.0 | 58.2 | 55.7 | 64.3 | 56.9 | 59.9 | 70.7 | 62.1 | 57.3 | 64.9 | 59.9 | 73.5 | 64.0 |
| Cross-Encoder | 50.8 | 58.2 | 55.1 | 45.2 | 59.3 | 50.6 | 65.5 | 55.0 | 61.2 | 67.4 | 63.4 | 53.5 | 66.3 | 56.1 | 73.9 | 63.1 |
+
+Table 13: Detailed performance on MKQA test set. “*” denotes that the results are copied from the Sentri paper.
+
+| Methods | Da | De | Es | Fr | He | Hu | It | Km | Ms | Nl |
| CORA* | 44.5 | 44.6 | 45.3 | 44.8 | 27.3 | 39.1 | 44.2 | 22.2 | 44.3 | 47.3 |
| BM25 + MT* | 44.1 | 43.3 | 44.9 | 42.5 | 36.9 | 39.3 | 40.1 | 31.3 | 42.5 | 46.5 |
| Senti* | 57.6 | 56.5 | 55.9 | 55.1 | 47.9 | 51.8 | 54.3 | 43.9 | 56.0 | 56.3 |
| w/ Bi-Encoder* | 50.0 | 47.8 | 48.7 | 47.4 | 37.7 | 43.4 | 41.8 | 37.8 | 49.5 | 47.3 |
| QuiCK | 58.3 | 56.4 | 55.2 | 55.5 | 44.7 | 52.4 | 52.3 | 42.0 | 56.9 | 57.5 |
| QuiCK w/ LaBSE | 63.3 | 61.8 | 62.2 | 62.4 | 56.1 | 58.9 | 60.6 | 53.0 | 64.2 | 63.0 |
| No | P1 | Pt | Sv | Th | Tr | Vi | Zh-cn | Zh-hk | Zh-tw | Avg |
| 48.3 | 44.8 | 40.8 | 43.6 | 45.0 | 34.8 | 33.9 | 33.5 | 41.5 | 41.0 | 41.1 |
| 43.3 | 46.5 | 45.7 | 49.7 | 46.5 | 42.5 | 43.5 | 37.5 | 37.5 | 36.1 | 42.0 |
| 56.5 | 55.8 | 54.8 | 56.9 | 55.3 | 53.0 | 54.4 | 50.2 | 50.7 | 49.4 | 53.3 |
| 49.1 | 47.0 | 47.7 | 50.0 | 46.5 | 45.6 | 47.3 | 42.6 | 41.5 | 41.0 | 45.3 |
| 57.0 | 54.9 | 54.7 | 58.0 | 55.7 | 53.9 | 54.9 | 50.4 | 49.3 | 48.9 | 53.4 |
| 62.8 | 62.0 | 61.5 | 63.3 | 60.5 | 60.6 | 61.8 | 57.3 | 56.3 | 56.0 | 60.3 |
+
+Table 14: Detailed performance for ablation study on XOR-Retrieve dev set.
+
+ | R@2kt | R@5kt |
| Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg | Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg |
| QuiCK | 52.8 | 70.1 | 60.2 | 54.8 | 62.8 | 57.8 | 70.6 | 61.3 | 63.8 | 78.0 | 65.3 | 63.5 | 69.8 | 67.1 | 74.8 | 68.9 |
| w/o Sampling | 53.1 | 68.4 | 60.2 | 50.2 | 61.1 | 55.7 | 68.1 | 59.5 | 63.4 | 78.0 | 64.6 | 60.6 | 68.1 | 63.7 | 74.4 | 67.5 |
| w/o Alignment | 51.8 | 68.1 | 60.8 | 51.0 | 60.4 | 57.4 | 70.2 | 59.9 | 61.5 | 74.7 | 64.6 | 62.7 | 68.8 | 62.4 | 75.2 | 67.1 |
| w/o Generation | 55.0 | 68.1 | 59.6 | 47.3 | 60.7 | 54.9 | 66.4 | 58.8 | 62.8 | 74.0 | 65.0 | 56.4 | 66.3 | 62.0 | 74.8 | 65.9 |
| w/o All | 35.3 | 43.1 | 50.3 | 35.7 | 44.6 | 31.2 | 50.0 | 41.5 | 49.5 | 54.9 | 59.2 | 45.2 | 55.1 | 31.2 | 63.4 | 53.4 |
+
+Table 15: Detailed performance of alignment based on different pre-trained languages models.
+
+ | R@2kt | R@5kt |
| Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg | Ar | Bn | Fi | Ja | Ko | Ru | Te | Avg |
| XLM-R | 52.8 | 70.1 | 60.2 | 54.8 | 62.8 | 57.8 | 70.6 | 61.3 | 63.8 | 78.0 | 65.3 | 63.5 | 69.8 | 67.1 | 74.8 | 68.9 |
| w/o Alignment | 51.8 | 68.1 | 60.8 | 51.0 | 60.4 | 57.4 | 70.2 | 59.9 | 61.5 | 74.7 | 64.6 | 62.7 | 68.8 | 62.4 | 75.2 | 67.1 |
| LaBSE | 67.3 | 78.9 | 65.9 | 59.8 | 66.3 | 63.7 | 80.7 | 68.9 | 72.2 | 83.2 | 69.7 | 68.0 | 70.9 | 71.7 | 84.9 | 74.4 |
| w/o Alignment | 65.7 | 78.3 | 65.0 | 58.9 | 67.0 | 62.9 | 77.3 | 67.9 | 72.5 | 80.9 | 69.7 | 66.8 | 71.9 | 70.5 | 84.5 | 73.8 |
\ No newline at end of file
diff --git a/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/images.zip b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..1aaeed03cf8e535b978bfc6168eb8fa0ac834673
--- /dev/null
+++ b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d0574c040d59a43ffabdd0e2b5560fc1afc83f5fafa2e4647f5c6c054fc760a8
+size 849952
diff --git a/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/layout.json b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..c121256a1ffb5a28e6738e0a349dd74697f50d0f
--- /dev/null
+++ b/empoweringdualencoderwithquerygeneratorforcrosslingualdenseretrieval/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:4b4ebbb31a7b1e20688a261c01b899ce7d9c852ed70d33941954427a95becca4
+size 571093
diff --git a/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_content_list.json b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..eb560dee7062b8ef60f8e261d628c7d7be7e4b32
--- /dev/null
+++ b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:59eb98ac1404c38121b82c4f79b131e88ad4344a2137197442c72e3c4fa7d9e7
+size 122465
diff --git a/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_model.json b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..346d734e15c2bdfb6ecc0856726f581b9e93c314
--- /dev/null
+++ b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e818168e938dee05e9e713d0c8063d52b854812d351d871a7159d188d8e39222
+size 143238
diff --git a/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_origin.pdf b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..90c1a41a263ab8c504aad03fff29550416e4fd5d
--- /dev/null
+++ b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/b43cc895-074f-4398-9079-875b6eea32e9_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:9efa19374ad6becd0d132b889456638ed6ee8ef0c583c09b4adde95bc1f51eab
+size 8364079
diff --git a/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/full.md b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..144697eba98561fccb659ecb76faa3bd3b9a3c8f
--- /dev/null
+++ b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/full.md
@@ -0,0 +1,447 @@
+# Empowering Language Models with Knowledge Graph Reasoning for Question Answering
+
+Ziniu Hu1, Yichong Xu2, Wenhao Yu3, Shuohang Wang2
+Ziyi Yang2, Chenguang Zhu2, Kai-Wei Chang1, Yizhou Sun1
+
+1University of California, Los Angeles
+
+$^{2}$ Microsoft Cognitive Services Research, $^{3}$ University of Notre Dame
+
+# Abstract
+
+Answering open-domain questions requires world knowledge about in-context entities. As pre-trained Language Models (LMs) lack the power to store all required knowledge, external knowledge sources, such as knowledge graphs, are often used to augment LMs. In this work, we propose knOwledge REasOning empowered Language Model (ORELM), which consists of a novel Knowledge Interaction Layer that can be flexibly plugged into existing Transformer-based LMs to interact with a differentiable Knowledge Graph Reasoning module collaboratively. In this way, LM guides KG to walk towards the desired answer, while the retrieved knowledge improves LM. By adopting OReOLM to RoBERTa and T5, we show significant performance gain, achieving state-of-art results in the Closed-Book setting. The performance enhancement is mainly from the KG reasoning's capacity to infer missing relational facts. In addition, OReOLM provides reasoning paths as rationales to interpret the model's decision.
+
+# 1 Introduction
+
+Open-Domain Question Answering (ODQA), one of the most knowledge-intensive NLP tasks, requires QA models to infer out-of-context knowledge to the given single question. Following the pioneering work by Chen et al. (2017), ODQA systems often assume to access an external text corpus (e.g., Wikipedia) as an external knowledge source. Due to the large scale of such textual knowledge sources (e.g., 20GB for Wikipedia), it cannot be encoded in the model parameters. Therefore, most works retrieve relevant passages as knowledge and thus named Open-Book models (Roberts et al., 2020), with an analogy of referring to textbooks during an exam. Another line of Closed-book models (Roberts et al., 2020) assume knowledge could be stored implicitly in parameters of Language Models (LM, e.g. BERT (Devlin et al.,
+
+
+Figure 1: An Illustrative figure of OReOLM. Compared with previous KBQA systems that stack reasoner on top of LM, OReOLM enables interaction between the two.
+
+2019) and T5 (Raffel et al., 2020)). These LMs directly generate answers without retrieving from an external corpus and thus benefit from faster inference speed and simpler training. However, current LMs still miss a large portion of factual knowledge (Pörner et al., 2020; Lewis et al., 2021a), and are not competitive with Open-Book models.
+
+To improve the knowledge coverage of LM, one natural choice is to leverage knowledge stored in Knowledge Graph $(\mathcal{KG},$ e.g. FreeBase (Bollacker et al., 2008) and WikiData (Vrandecic and Krötzsch, 2014)), which explicitly encodes world knowledge via relational triplets between entities. There are several good properties of $\mathcal{KG}$ : 1) a $\mathcal{KG}$ triplet is a more abstract and compressed representation of knowledge than text, and thus $\mathcal{KG}$ could be stored in memory and directly enhance LM without using an additional retrieval model; 2) the structural nature of $\mathcal{KG}$ could support logical reasoning (Ren et al., 2020) and infer missing knowledge through high-order paths (Lao et al., 2011; Das et al., 2018). Taking the question "what cheese is used to make the desert cannoli?" as an example, even if this relational fact is missing in $\mathcal{KG}$ , we could still leverage high-order relationships, e.g., both Ricotta Cheese and Cannoli are specialties in Italy, to infer the answer "Ricotta Cheese."
+
+In light of the good properties of $\kappa \mathcal{G}$ , there are several efforts to build Knowledge Base Question Answering (KBQA) systems. As is illustrated in Figure 1(a), most KBQA models use LM as a parser to map textual questions into a structured form (e.g., SQL query or subgraph), and then based on $\kappa \mathcal{G}$ , the queries could be executed by symbolic reasoning (Berant et al., 2013) or neural reasoning (e.g. Graph Neural Networks) (Sun et al., 2019) to get the answer. Another recent line of research (Verga et al., 2021; Yu et al., 2022b) tries to encode the knowledge graph as the memory into LM parameters. However, for most methods discussed above, LM is not interacting with $\kappa \mathcal{G}$ to correctly understand the question, and the answer is usually restricted to a node or edge in $\kappa \mathcal{G}$ .
+
+In this paper, we propose knOwledge REasOning empowered Language Model (OREOLM), a model architecture that can be applied to Transformer-based LMs to improve Closed-Book ODQA. As is illustrated in Figure 1(b), the key component is the Knowledge Interaction Layers (KIL) inserted amid LM layers, which is like cream filling within two waffles, leading to our model's name OREO. KIL interacts with a $\kappa \mathcal{G}$ reasoning module, in which we maintain different reasoning paths for each entity in the question. We formulate the retrieval and reasoning process as a contextualized random walk over the $\kappa \mathcal{G}$ , starting from the in-context entities. Each KIL is responsible for one reasoning step. It first predicts a relation distribution for every in-context entity, and then the $\kappa \mathcal{G}$ reasoning module traverses the graph following the predicted relation distribution. The reasoning result in each step is summarized as a weighted averaged embedding over the retrieved entities from the traversal.
+
+By stacking $T$ layers of KIL, OREOLM can retrieve entities that are $T$ -hop away from in-context entities and help LM to answer open questions that require out-of-context knowledge or multi-hop reasoning. The whole procedure is fully differentiable, and thus OREOLM learns and infers in an end-to-end manner. We further introduce how to pre-train OREOLM over unlabelled Wikipedia corpus. In addition to the salient entity span masking objective, we introduce two self-supervised objectives to guide OREOLM to learn better entity and relation representations and how to reason over them.
+
+We test OREOLM with RoBERTa and T5 as our
+
+base LMs. By evaluating on several single-hop ODQA datasets in closed-book setting, we show that OREOLM outperforms existing baselines with fewer model parameters. Specifically, OREOLM helps more for questions with missing relations in $\mathcal{KG}$ , and questions that require multi-hop reasoning. We further show that OREOLM can serve as a backbone for open-book setting and achieves comparable performance compared with the state-of-the-art QA systems with dedicated design. In addition, OREOLM has better interpretability as it can generate reasoning paths for the answered question and summarize general relational rules to infer missing relations.
+
+This key contributions are as follows:
+
+- We propose OREOLM to integrate symbolic knowledge graph reasoning with neural LMs. Different from prior works, OREOLM can be seamlessly plugged into existing LMs.
+- We pretrain OREOLM with RoBERTa and T5 to on the Wikipedia corpus. OREOLM can bring significant performance gain on ODQA.
+- OREOLM offers interpretable reasoning paths for answering the question and high-order reasoning rules as rationales.
+
+# 2 Methodology
+
+Preliminary We denote a Knowledge Graph $\mathcal{KG} = (\mathcal{E},\mathcal{R},\mathcal{A} = \{A_r\}_{r\in \mathcal{R}})$ , where each $e\in \mathcal{E}$ and $r\in \mathcal{R}$ is entity node and relation label. $A_{r}\in \{0,1\}^{|\mathcal{E}|\times |\mathcal{E}|}$ is a sparse adjacency matrix indicating whether relation $r$ holds between a pair of entities. The task of knowledge graph reasoning aims at answering a factoid query $(s,r,\ref{eq:1})$ , i.e., which target entity has relation $r$ with the source entity $s$ . If $\mathcal{KG}$ is complete, we could simply get answers by checking the adjacency matrix, i.e., $\{\forall t:A_r[s,t] = 1\}$ . For incomplete $\mathcal{KG}$ where many relational facts are missing, path-based reasoning approaches (Lao et al., 2011; Xiong et al., 2017; Das et al., 2018) have been proposed to answer the one-hop query via finding multi-hop paths. For example, to answer the query $(s,\text{Mother},?)$ , a path $s\xrightarrow{\text{Father}}j\xrightarrow{\text{Wife}}t$ could reach the target answer $t$ . In this paper we try to integrate symbolic $\mathcal{KG}$ reasoning into neural LMs and help it deal with ODQA problems.
+
+Overview of OREOLM We illustrate the overall architecture of OREOLM in Figure 2. All the light blue blocks are our added components to
+
+
+Figure 2: Model architecture of OReoLM. Three key procedures are highlighted in red dotted box: 1) Relation Prediction (Sec. 2.1.1): Knowledge Interaction Layers (KIL) predicts relation action for each entity mention. 2) One-step State Transition (Sec. 2.1.2): Based on the predicted relation, $\kappa G$ re-weights each graph and conduct contextualized random walk to update entity distribution state. 3) Knowledge Integration (Sec. 2.2): An weighted aggregated entity embedding is added into a placeholder token as retrieved knowledge.
+
+support $\kappa \mathcal{G}$ reasoning, while the dark blue Transformer layers are knowledge-injected LM. The key component of OReOLM for conducting $\kappa \mathcal{G}$ reasoning is the Knowledge Interaction Layers (KIL), which are added amid LM layers to enable deeper interaction with the $\kappa \mathcal{G}$ .
+
+Given a question $q =$ "The Bauhaus represented Germany's recovery from which event?", QA model needs to extract knowledge about all $n$ in-context entity mentions $M = \{m_i\}_{i=1}^n$ , e.g., the history of "Germany" at the time when "Bauhaus" is founded, to get the answer $a =$ "World War I". Such open-domain Q&A can be abstracted as $P(a|q, M)$ .
+
+Starting from each mentioned entity $m_{i}$ , we desire the model to learn to walk over the graph to retrieve relevant knowledge and form a $T$ -length reasoning path for answering this question, where $T$ is a hyper-parameter denote the longest reasoning path required to answer the questions. We define each reasoning path starting from the entity mention $m_{i}$ as a chain of entities (states) random variables $\rho_{i} = \{e_{i}^{t}\}_{t=0}^{T}$ , where each mentioned entity is the initial state, i.e., $e_{i}^{0} = m_{i}$ . The union of all paths for this question is defined as $\varrho = \{\rho_{i}\}$ , which contains the reasoning paths from each mentioned entity to answer the question.
+
+OREOLM factorizes $P(a|q,M)$ by incorpora-t
+
+ing possible paths $\varrho$ as a latent variable, yielding:
+
+$$
+\begin{array}{l} \boldsymbol {P} \big (a | q, M \big) = \sum_ {\boldsymbol {\varrho}} \boldsymbol {P} \big (\boldsymbol {\varrho} | q, \{m _ {i} \} _ {i = 1} ^ {n} \big) \cdot \boldsymbol {P} \big (a | q, M, \boldsymbol {\varrho} \big) \\ = \sum_ {\boldsymbol {\varrho}} \left(\prod_ {i = 1} ^ {n} \boldsymbol {P} \left(\rho_ {i} | q, m _ {i}\right)\right) \cdot \boldsymbol {P} \left(a | q, \left\{m _ {i}, \rho_ {i} \right\} _ {i = 1} ^ {n}\right) \\ = \sum_ {\boldsymbol {q}} \left(\prod_ {i = 1} ^ {n} \prod_ {t = 1} ^ {T} \underbrace {\boldsymbol {P} \left(e _ {i} ^ {t} \mid q , e _ {i} ^ {< t}\right)} _ {\mathcal {K G R e a s o n i n g (2 . 1)}}\right) \underbrace {\boldsymbol {P} \left(a \mid q , \left\{e _ {i} ^ {0 : T} \right\} _ {i = 1} ^ {n}\right)} _ {\text {k n o w l e d g e - i n j e c t e d L M (2 . 2)}} \\ \end{array}
+$$
+
+We assume (1) reasoning paths starting from different entities are generated independently; and (2) reasoning paths can be generated autoregressively.
+
+In this way, the QA problem can be decomposed into two entangled steps: 1) $\mathcal{KG}$ Reasoning, which autoregressively walks through the graph to get a path $\rho_{i}$ starting from each entity mention $m_{i}$ ; and 2) knowledge-injected LM, which benefits from the reasoning paths to obtain the out-context knowledge for answer prediction.
+
+The relational path $\rho_{i}$ in $\mathcal{KG}$ Reasoning requires the selection of next entity $e_i^t$ at each step $t$ . We further decompose it into two steps: 1.a) relation prediction, in which LM is involved to predict the next-hop relation based on the current state and context; and 1.b) the non-parametric state transition, which is to predict the next-hop entity based on the $\mathcal{KG}$ and the predicted relation. Formally:
+
+$$
+\underbrace {\boldsymbol {P} \left(e _ {i} ^ {t} \mid q , e _ {i} ^ {< t}\right)} _ {\mathcal {K G} \text {R e a s o n i n g (2 . 1)}} = \sum_ {r} \underbrace {\boldsymbol {P} _ {r e l} \left(r _ {i} ^ {t} \mid q , e _ {i} ^ {< t}\right)} _ {\text {r e l a t i o n p r e d i c t i o n (2 . 1 . 1)}} \cdot \underbrace {\boldsymbol {P} _ {w a l k} \left(e _ {i} ^ {t} \mid r _ {i} ^ {t} , e _ {i} ^ {< t}\right)} _ {\text {c o n t e x t u a l i z e d r a n d o m w a l k (2 . 1 . 2)}}
+$$
+
+We keep track of the entity distribution at each step $t$ via the probability vector $\pi_i^{(t)}\in \mathcal{R}^{|\mathcal{E}|}$ , with $\pi_i^{(t)}[e]$ being the probability of staying at entity $e$ , i.e., $P\big(e_i^t = e|q,e_i^{< t}\big)$ .
+
+We highlight the three procedures in red dotted box in Figure 2. We take the first reasoning step starting from entity mention "Bauhaus" as an example. In the first red box within KIL, we predict which relation action should be taken for entity "Bauhaus", and send the prediction (e.g. "Founded") to $\kappa \mathcal{G}$ . In the second red box, $\kappa \mathcal{G}$ reweights the graph and conducts contextualized random walk to update entity distribution, where "Walter" has the highest probability. Finally, weighted by the entity distribution, an aggregated entity embedding is sent back to KIL and added into a placeholder token as the knowledge, so the later LM layer knows to focus on the retrieved "Walter". We introduce these steps in the following.
+
+Input Initially, we first identify all $N$ entity mentions $\{m_i\}_{i=1}^N$ in the input question $q$ as well as the corresponding $\mathcal{KG}$ entities2. For each mention $m_i$ we add three special tokens as the interface for Knowledge Interaction Layers (KIL) to send instruction and receive knowledge: we add a [S-ENT] token before, and [REL], [T-ENT] tokens after each entity mention $m_i$ . KIL can be flexibly inserted into arbitrary LM intermediate layer. By default, we just insert each KIL every $N$ Transformer-based LM layers, thus the input to the $t$ -th KIL are contextualized embeddings of each token $k$ as $\mathrm{LM}_k^{(t)}$ , including added special tokens.
+
+# 2.1 LM involved $\kappa \mathcal{G}$ Reasoning
+
+We first introduce the reasoning process $P\big(e_i^t |q,e_i^{< t}\big) = \sum_rP\big(r_i^t |q,e_i^{< t}\big)\cdot P\big(e_i^t |r_i^t,e_i^{< t}\big).$
+
+# 2.1.1 Relation Prediction.
+
+For each entity mention $m_{i}$ , we desire to predict which relation action should take $r_i^t$ as instruction to transit state. We define the predicted relation probability vector $\pmb{\gamma}_i^{(t)} = \pmb{P}_{rel}\big(r_i^t |q,e_i^{< t}\big)\in \mathcal{R}^{|\mathcal{R}|}$
+
+representing the relation distribution to guide walking through the graph. Denote the corresponding [REL] token as REL[i] (and similarly for other special tokens). The contextual embedding $\mathbb{L}\mathbb{M}_{\mathbb{R}\mathbb{E}\mathbb{L}[i]}^{(t)}$ encode the relevant information in question $q$ that hints next relation. We maintain a global relation key memory $\mathrm{K}_{rel} \in \mathbb{R}^{| \mathcal{R}| \times d}$ storing each relation's $d$ -dimensional embedding. To calculate similarity, we first get relation query $Q_{\mathsf{REL}[i]}^{(t)}$ by projecting relation token's embedding into the same space of key memory via a projection head Q-Proj followed by a LayerNorm (abbreviated as LN), and then calculate dot-product similarity followed by softmax:
+
+$$
+Q _ {\text {R E L} [ i ]} ^ {(t)} = \mathrm {L N} ^ {(t)} \left(\mathrm {Q - P r o j} ^ {(t)} \left(\mathrm {L M} _ {\text {R E L} [ i ]} ^ {(t)}\right)\right), \tag {1}
+$$
+
+$$
+\boldsymbol {\gamma} _ {i} ^ {(t)} = \boldsymbol {P} _ {r e l} \left(r _ {i} ^ {t} \mid q, e _ {i} ^ {< t}\right) = \operatorname {S o f t m a x} \left(Q _ {\text {R E L} [ i ]} ^ {(t)} \mathrm {K} _ {r e l} ^ {T}\right). \tag {2}
+$$
+
+Note that the relation queries $\mathsf{LM}_{\mathsf{REL}[i]}^{(t)}$ are different for every mention $m_{i}$ and reasoning step $t$ depending on the context, and thus the relation distributions $\gamma_i^{(t)}$ gives contextualized predictions based on the question $q$ . The predicted relations are sent to the knowledge graph reasoning module as instruction to conduct state transition.
+
+# 2.1.2 Contextualized KG Random Walk
+
+Next, we introduce how we conduct state transition $P_{walk}\left(e_i^t|r_i^t,e_i^{< t}\right)$ . One classic transition algorithm is random walk, which is a special case of markov chain, i.e. the transition probability only depends on previous state. Consider a state at entity $s$ , the probability walking to target $t$ is $\frac{1}{\deg(s)}$ if $A[s,t] = 1$ . Based on it, we define the Markov transition matrix for random walk as $M_{rw} = D_A^{-1}A$ where the degree matrix $D_A \in \mathbb{R}^{|\mathcal{E}| \times |\mathcal{E}|}$ is defined as the diagonal matrix with the degrees $\deg(1),\ldots,\deg(|\mathcal{E}|)$ on the diagonal. With random walk Markov matrix $M_{rw}$ we can transit the state distribution as: $\pi^{(t)} = \pi^{(t-1)}M$ . The limitation of random walk is that the transition strategy is not dependent on the question $q$ . We thus propose a Contextualized Random Walk (CRW).
+
+Based on the predicted relation distribution $\gamma_{i}^{(t)}$ , we calculate a different weighted adjacency matrix
+
+$\widetilde{A}_i^{(t)} \in \mathbb{R}^{|\mathcal{E}| \times |\mathcal{E}|}$ by adjusting the edge weight:
+
+$$
+\widetilde {A} _ {i} ^ {(t)} = \sum_ {r \in \mathcal {R}} w _ {r} \cdot \gamma_ {i, r} ^ {(t)} \cdot A _ {r}, \tag {3}
+$$
+
+$$
+M _ {c r w, i} ^ {(t)} = \boldsymbol {D} _ {\widetilde {A} _ {i} ^ {(t)}} ^ {- 1} \widetilde {A} _ {i} ^ {(t)}, \forall i \in [ 1, N ]. \tag {4}
+$$
+
+where $w_{r}$ is a learnable importance weight for relation $r$ that helps solving downstream tasks, and $\gamma_{i,r}^{(t)}$ is the probability corresponding to relation $r$ in $\gamma_{i}^{(t)}$ . With the transition matrix $M_{crw,i}^{(t)}$ , the state transition is defined as $\pi_{i}^{(t)} = \pi_{i}^{(t - 1)}M_{crw,i}^{(t)}$ .
+
+CRW allows each reasoning path $\rho_{i}$ to have its transition matrix. However, as the total number of entity nodes $|\mathcal{E}|$ could be huge (e.g., 5M for WikiData), we cannot afford to update the entire adjacency matrix for every in-batch mention. We thus adopt a scatter-gather pipeline to implement graph walking as shown in Algorithm 1. We first gather the entity and relation probability to each edge, and then scatter the probability to target nodes. This allows us to simultaneously conduct message passing with modified adjacency weight $\widetilde{A}_i^t$ for all entity mention $m_{i}$ in parallel.
+
+Algorithm 1: Pytorch Pseudocode of CRW
+```python
+def ContextualizedRandomWalk( i_init, KG, # initial entity index and Graph w_deg, w(rel, # inv(degree) and relation weights p_ent, p(rel # entity and predicted relation dis- # tribution tensor @ t-th step. ):-> FloatTensor # Get edge list of k-hop subgraph i_src, i(rel, i_tgt = k_hop_subgraph(i_init, KG) # Gather entity and relation probability to edge p_src = (p_ent * w_deg)[(:, i_src] # N x n_edge p_REL = (p(rel * w(rel)[(:, i(rel] # N x n_edge p_edge = 11 normalize(p_src * p(rel, dim=1) # Scatter edge probability to target node p_ent = scatter_add(src=p_edge, idx=i_tgt, dim=1) return p_ent #(t+1)-th step's entity distribution
+```
+
+The complexity is $\#$ of in-batch entities times $\#$ of edges in $T$ -hop subgraph starting from these entities, i.e., $\mathcal{O}(n \times \# \text{edge})$ , and thus this operation is not expensive. Another concern is why not using Graph Neural Networks (GNNs). We provide discussion in Sec. C in Appendix.
+
+# 2.2 Knowledge-Injected LM
+
+After we get the updated entity distribution $\pi_i^{(t)}$ , we want to inject such information back to the LM without harming its overall structure. We maintain a global entity embedding value memory $\mathrm{V}_{ent} \in \mathbb{R}^{|\mathcal{E}| \times d}$ storing entity embeddings. We only consider the entities within the sampled local subgraph in each batch. We thus get an entity
+
+index list $\pmb{I}$ as the query to sparsely retrieve a set of candidate entity embeddings and then aggregate them weighted by entity distribution and embedding table. We then use a Value Projection block to map the aggregated entity embedding into the space of LM, and then directly add the transformed embedding back to the output of T-ENT.
+
+$$
+V _ {i} ^ {(t)} = \operatorname {V - P r o j} ^ {(t)} \left(\boldsymbol {\pi} _ {i} ^ {(t)} \cdot \operatorname {V} _ {e n t} [ I ]\right), \tag {5}
+$$
+
+$$
+\widehat {\mathrm {L M}} _ {\mathrm {T} - \mathrm {E N T} [ i ]} ^ {(t)} = \mathrm {L N} ^ {(t)} \left(\mathrm {L M} _ {\mathrm {T} - \mathrm {E N T} [ i ]} ^ {(t)} + V _ {i} ^ {(t)}\right). \tag {6}
+$$
+
+Then, we just take all $\widehat{\mathsf{LM}}_{\mathrm{T - ENT}}^{(t)}$ as input to next Transformer-based LM layer to learn the interaction between the retrieved knowledge with in-context words via self-attention.
+
+By repeating the KILL for $T$ times, the final representation $\widehat{\mathbb{L}\mathbb{M}}^T$ is conditioned on the reasoning paths $\rho_{i} = e_{i}^{0:T}$ , which reaches entities that are $T$ -hop away from initial entity $m_i$ in the question. Finally, we can predict the answer of open questions $\pmb{P}\left(a|q,\{e_i^{0:T}\}_{i=1}^n\right)$ by taking knowledge-injected representation $\widehat{\mathbb{L}\mathbb{M}}^T$ for span extraction, entity prediction or direct answer generation.
+
+# 2.3 Pre-Train OREOLM to Reason
+
+The design of OReOLM allows end-to-end training given QA datasets. However, due to the small coverage of knowledge facts for existing QA datasets, we need to pretrain OReOLM on a large-scale corpus to get good entity embeddings.
+
+Salient Span Masking One straightforward approach is to use Salient Span Masking (SSM) objective (Guu et al., 2020) masks out entities or noun tokens requiring specific out-of-context knowledge. We mainly mask out entities for guiding OREOLM to reason. Instead of randomly masking entity mentions, we explicitly sample a set of entity IDs and mask every mentions linking to these entities. This could prevent the model copy the entity from the context to fill in the blank. We also follow (Yang et al., 2019) to mask out consecutive token spans. We then calculate the cross-entropy loss on each salient span masked (SSM) token as $\mathcal{L}_{SSM}$ .
+
+# 2.3.1 Weakly Supervised Training of KIL
+
+Ideally, OREOLM can learn all the entity knowledge and how to access the knowledge graph by solely optimizing $\mathcal{L}_{SSM}$ . However, without a good initialization of entity and relation embeddings, KIL makes a random prediction, and the retrieved entities by $\kappa G$ reasoning are likely to be unrelated
+
+
+Figure 3: Pre-training sample w/ golden reasoning path. More real examples are shown in Table 8 in Appendix.
+
+to the question. In this situation, KIL does not receive meaningful gradients to update the parameters, and LM learns to ignore the knowledge. To avoid this cold-start problem and provide entity and relation embedding a good initialization, We utilize the following two external signals as self-supervised guidance.
+
+Entity Linking Loss To initialize the large entity embedding tables in $V_{ent}$ , we use other entities that are not masked as supervision. Similar to Févry et al. (2020), we force the output embedding of [S-ENT] token before the first KIL followed by a projection head E-Proj to be close to its corresponding entity embedding:
+
+$$
+E _ {\mathrm {S} - \mathrm {E N T} [ i ]} = \mathrm {L N} \left(\mathrm {E} - \operatorname {P r o j} \left(\mathrm {L M} _ {\mathrm {S} - \mathrm {E N T} [ i ]} ^ {(1)}\right)\right),
+$$
+
+$$
+\boldsymbol {P} _ {e n t} ^ {(0)} \left(e | m _ {i}, q\right) = \operatorname {S o f t m a x} \left(E _ {\mathrm {S - E N T} [ i ]} \mathrm {V} _ {e n t} [ \boldsymbol {I} ] ^ {T}\right),
+$$
+
+$$
+\mathcal {L} _ {e n t} = \sum_ {m _ {i}} - \log \boldsymbol {P} _ {e n t} ^ {(0)} (e | m _ {i}, q) \cdot \boldsymbol {\pi} _ {i} ^ {0} [ \boldsymbol {I} ].
+$$
+
+Similar to Section 2.2, we only consider entities within the batch, denoted by index $\pmb{I}$ . This contrastive loss guides each entity's embedding $\mathrm{V}_{\text{ent}}[e]$ closer to all its previously mentioned contextualized embedding, and thus memorizes those context as a good initialization for later knowledge integration.
+
+Weakly Supervised Relation Path Loss Entity mentions within each Wikipedia passage are naturally grounded to WikiData $\kappa \mathcal{G}$ . Therefore, after we mask out several entities, we can utilize the $\kappa \mathcal{G}$ to get all reasoning paths from other in-context entities to the masked entities as weakly supervised relation labels.
+
+Formally, we define a Grounded Dependency Graph $\mathcal{DG}$ , which contains all reasoning paths within $T$ -step from other in-context entities to masked entities, and then define $R_{\mathcal{DG}}(m_i,t)$ as
+
+| Name | Number | dimension | #param (M) |
| Number of Entity | 4,947,397 | 128 | 633 |
| Number of Relation | 2,008 | 768 | 1.5 |
| Number of Edges | 45,217,947 | - | 47 |
+
+Table 1: Statistics and parameter of $\mathcal{K}\mathcal{G}$ Memory.
+
+the set of all relations over every edges for entity mention $m_{i}$ at $t$ -th hop. Based on it, we define the weakly supervised relation label $q_{i}^{(t)} \in \mathbb{R}^{| \mathcal{R}|}$ as the probabilistic vector which uniformly distributed on each relation in set. Note that we call uniformly-weighted $q_{i}^{(t)}$ as weakly supervised because 1) some paths lead to multiple entities rather than only the target masked entity; 2) the correct relation is dependent on the context. Therefore, $q_{i}^{(t)}$ only provides all potential candidates for reachability, and more fine-grained signals for reasoning should be learned from unsupervised $\mathcal{L}_{SSM}$ . We adopt a list-wise ranking loss to guide the model to assign a higher score on these relations than others.
+
+$$
+\mathcal {L} _ {r e l} = \sum_ {m _ {i}} \sum_ {t = 1} ^ {T} - \log \boldsymbol {P} _ {r e l} ^ {(t)} (r | m _ {i}, q) \cdot q _ {i} ^ {(t)}.
+$$
+
+Overall, $\mathcal{L}_{ent}$ and $\mathcal{L}_{rel}$ provide OReOLM with good initialization of the large $\kappa G$ memory. Afterward, via optimizing $\mathcal{L}_{SSM}$ , the reasoning paths that provide informative knowledge receive a positive gradient, guiding OReOLM to reason.
+
+# 3 Experiments
+
+The proposed KIL layers can be pugged into most Transformer-based Language Models without hurting its original structure. In this paper, we experiment with both encoder-based LM, i.e. RoBERTa-base $(d = 768, l = 12)$ , and encoder-decoder LM, i.e. T5-base $(d = 768, l = 12)$ and T5-large $(d = 1024, l = 24)$ . For all LMs, add 1 KIL layer or 2 KIL layers to the encoder layers. The statistics of $\mathcal{KG}$ are shown in Table 1. Altogether, it takes about 0.67B parameter for $\mathcal{KG}$ memory, which is affordable to load as model parameter. We pretrain all LMs using the combination of $\mathcal{L}_{SSM}$ , $\mathcal{L}_{ent}$ and $\mathcal{L}_{rel}$ for 200k steps on 8 V100 GPUs, with a batch size of 128 and default optimizer and learning rate in the original paper, taking approximately one week to finish pre-training of T5-large model, and 1-2 days for base model. Implementation details are elaborated in Appendix A.
+
+# 3.1 Evaluate for Closed-Book QA
+
+OREOLM is designed for improving Closed-Book QA, so we first evaluate it in this setting.
+
+| Models | #param | NQ | WQ | TQA | ComplexWQ | HotpotQA |
| T5 (Base) | 0.22B | 25.9 | 27.9 | 29.1 | 11.6 | 22.8 |
| + OReLUML (T=1) | 0.23B + 0.68B | 28.3 | 30.6 | 32.4 | 20.8 | 24.1 |
| + OReLUML (T=2) | 0.24B + 0.68B | 28.9 | 31.2 | 33.7 | 23.7 | 26.3 |
| T5 (Large) | 0.74B | 28.5 | 30.6 | 35.9 | 16.7 | 25.3 |
| + OReLUML (T=1) | 0.75B + 0.68B | 30.6 | 32.8 | 39.1 | 24.5 | 28.2 |
| + OReLUML (T=2) | 0.76B + 0.68B | 31.0 | 34.3 | 40.0 | 27.1 | 31.4 |
| T5-3B (Roberts et al., 2020) | 3B | 30.4 | 33.6 | 43.4 | - | 27.8 |
| T5-11B (Roberts et al., 2020) | 11B | 32.6 | 37.2 | 50.1 | - | 30.2 |
+
+Table 2: Closed-Book Generative QA performance of Encoder-Decoder LM on Single- and Multi-hop Dataset.
+
+Generative QA Task Following the hyperparameters and setting in (Roberts et al., 2020), we directly fine-tune the T5-base and T5-large augmented by our OREOLM on the three single-hop ODQA datasets: Natural Question (NQ) (Kwiatkowski et al., 2019), WebQuestions (WQ) (Berant et al., 2013) and TriviaQA (TQA) (Joshi et al., 2017). To test OREOLM's ability to solve complex questions, we also evaluate on two multi-hop QA datasets, i.e. Complex WQ (Talmor and Berant, 2018) and HotpotQA (Yang et al., 2018). Detailed dataset statistics and experimental setups are in Appendix B.
+
+Experimental results are shown in Table 7. We use Exact Match accuracy as the metric for all the datasets. On the three single-hop ODQA datasets, OREOLM with 2 KILL blocks achieves 3.3 absolute accuracy improvement to T5-base, and 3.4 improvement to T5-large. Compared with T5 model with more model parameters (e.g., T5-3B and T5-11B), our T5-large augmented by OREOLM could outperform T5-3B on NQ and WQ datasets. In addition, OREOLM could use the generated reasoning path to interpret the model's prediction. We show examples in Table 10 in Appendix.
+
+For the two multi-hop QA datasets, the performance improvement brought by OREOLM is more significant, i.e., 7.8 to T5-base and 8.2 to T5-large. Notably, by comparing the T5-3B and T5-11B's performance on HotpotQA (we take results from (Chen et al., 2022)), T5-large augmented by OREOLM achieves 1.2 higher than T5-11B. This shows that OREOLM is indeed very effective for improving Closed-Book QA performance, especially for complex questions.
+
+Entity Prediction Task Encoder-based LM (i.e. RoBERTa) in most cases cannot be directly used for Closed-Book QA, but more serve as reader to extract answer span. However, Verga et al. (2021)
+
+propose a special evaluation setting as Closed-Book Entity Prediction. They add a single [MASK] token after the question, and use its output embedding to classify WikiData entity ID. This restricts that answers must be entities that are covered by WikiData, which they call WikiData-Answerable questions. We follow Verga et al. (2021) to use such reduced version of WebQuestionsSP (WQ-SP) (Yih et al., 2015) and TriviaQA (TQA) as evaluation dataset, and finetune the RoBERTa (base) model augmented by OREOLM to classify entity ID. We mainly compare OREOLM with EaE (Févry et al., 2020) and FILM (Verga et al., 2021), which are two KG memory augmented LM. We also run experiments on KEPLER (Wang et al., 2019), a RoBERTa model pre-trained with knowledge augmented task.
+
+Experimental results are shown in Table 3. Similar to the observation reported by Verga et al. (2021), adding $\kappa \mathcal{G}$ memory for this entity prediction task could significantly improve over vanilla LM, as most of the factual knowledge required to predict entities are stored in $\kappa \mathcal{G}$ . By comparing with FILM (Verga et al., 2021), which is the state-of-the-art model in this setup, OREOLM with reasoning step $(T = 2)$ outperforms FILM by 2.9, with smaller memory consumption.
+
+# 3.2 Analyze $\kappa \mathcal{G}$ Reasoning Module
+
+In our previous studies, we find that using a higher reasoning step, i.e. $T = 2$ , generally performs better than $T = 1$ . We hypothesize that the $\mathcal{K}\mathcal{G}$ we use has many missing one-hop facts, and high-order reasoning helps recover them and empowers the model to answer related questions. To test whether OREOLM indeed can infer missing facts, we use EntityQuestions (EQ) (Sciavolino et al., 2021), which is a synthetic dataset by mapping each WikiData triplet to natural questions. We take RoBERTa-base model augmented by OREOLM trained on NQ as entity predictor and directly test
+
+its transfer performance on EQ dataset without further fine-tuning.
+
+To test whether OREOLM could recover missing relation, we mask all the edges corresponding to each relation separately and make the prediction again. The average results before and after removing edges are shown on the left part of Figure 4. When we remove all the edges to each relation, OREOLM with $T = 1$ drops significantly, while $T = 2$ could still have good accuracy. To understand why OREOLM $(T = 2)$ is less influenced, in the right part of Figure 4, we generate a reasoning path for each relation by averaging the predicted probability score at each reasoning step and pick the relation with the top score. For example, to predict the "Capital" of a country, the model learns to find the living place of the president, or the location of a country's central bank. Both are very reasonable guesses. Many previous works (Xiong et al., 2017) could also learn such rules in an ad-hoc manner and require costly searching or reinforcement learning. In contrast, OREOLM could learn such reasoning capacity for all relations end-to-end during pre-training.
+
+Ablation Studies We conduct several ablation studies to evaluate which model design indeed contributes to the model. As shown in the bottom blocks in Table 3, we first remove the $\kappa \mathcal{G}$ reasoning component and provide RoBERTa base model via concatenated KB triplets and train such a model using $\mathcal{L}_{SSM}$ over the same WikiDataset. Such a model's results are close to the KEPLER results but much lower than other models with explicit knowledge memory. We further investigate the role of pre-training tasks. Without pre-training, the OReOLM only performs slightly better than RoBERTa baseline, due to the cold-start problem of entity and relation embedding. We further show that removing $\mathcal{L}_{ent}$ and $\mathcal{L}_{ent}$ could significantly influence final performance. The current combination is the best choice to train OReOLM to reason.
+
+# 3.3 Evaluate for Open-Book QA
+
+Though OREOLM is designed for Closed-Book QA, the learned model can serve as backbone for OpenBook QA. We take DPR and FiD models as baseline. For DPR retriever, we replace the question encoder to RoBERTa + OREOLM, fixing the passage embedding and only finetune on each downstream QA dataset. For FiD model, we replace the T5 + OREOLM. We also changed the retriever with
+
+| Models | #param (B) | WQ-SP | TQA |
| EaE (Févry et al., 2020) | 0.11 + 0.26 | 62.4 | 24.4 |
| FILM (Verga et al., 2021) | 0.11 + 0.72 | 78.1 | 37.3 |
| KEPLER (Wang et al., 2019) | 0.12 | 48.3 | 24.1 |
| RoBERTa (Base) | 0.12 | 43.5 | 21.3 |
| + OREOLM (T=1) | 0.12 + 0.68 | 80.1 | 39.7 |
| + OREOLM (T=2) | 0.13 + 0.68 | 80.9 | 40.3 |
| Ablation Studies |
| RoBERTa + Concat KB + LSSM | 0.12 | 47.1 | 22.6 |
| + OREOLM (T=2) w/o PT | 0.13 + 0.68 | 46.9 | 22.7 |
| w. LSSM | 0.13 + 0.68 | 51.9 | 26.8 |
| w. LSSM + Lent | 0.13 + 0.68 | 68.4 | 35.7 |
+
+Table 3: Closed-Book Entity Prediction performance of Encoder LM on WikiData-Answerable Dataset.
+
+| Models | #param (B) | NQ | TQA |
| Graph-Retriever (Min et al., 2019) | 0.11 | 34.7 | 55.8 |
| REALM (Guu et al., 2020) | 0.33 + 16 | 40.4 | - |
| DPR (Karpukhin et al., 2020) + BERT | 0.56 + 16 | 41.5 | 56.8 |
| + OREOLM (DPR, T=2) | 0.57 + 17 | 43.7 | 58.5 |
| FiD (Base) = DPR + T5 (Base) | 0.44 + 16 | 48.2 | 65.0 |
| + OREOLM (T5, T=2) | 0.45 + 17 | 49.3 | 67.1 |
| + OREOLM (DPR & T5, T=2) | 0.46 + 17 | 51.1 | 68.4 |
| FiD (Large) = DPR + T5 (Large) | 0.99 + 16 | 51.4 | 67.6 |
| + OREOLM (T5, T=2) | 0.99 + 17 | 52.4 | 68.9 |
| + OREOLM (DPR & T5, T=2) | 1.00 + 17 | 53.2 | 69.5 |
| KG-FiD (Base) (Yu et al., 2022a) | 0.44 + 16 | 49.6 | 66.7 |
| KG-FiD (Large) (Yu et al., 2022a) | 0.99 + 16 | 53.2 | 69.8 |
| EMDR2 (Sachan et al., 2021b) | 0.44 + 16 | 52.5 | 71.4 |
+
+Table 4: Open-Book QA Evaluation.
+
+our tuned DPR. Results in Table 4 show that by augmenting both retriever and generator, OREOLM improves a strong baseline like FiD, for about $3.1\%$ for Base and $1.8\%$ for Large, and it outperforms the very recent KG-FiD model for $1.6\%$ in base setting, and achieve comparative performance in a large setting. Note that though our results is still lower than some recent models (e.g., $\mathrm{EMDR}^2$ ), these methods are dedicated architecture or training framework for Open-Book QA. We may integrate OREOLM with these models to further improve their performance.
+
+# 4 Related Work
+
+Open-Domain Question Answering (ODQA) gives QA model a single question without any context and asks the model to infer out-of-context knowledge. Following the pioneering work by Chen et al. (2017), most ODQA systems assume the model can access an external text corpus (e.g. Wikipedia). Due to the large scale of web corpus (20GB for Wikipedia), it could not be simply encoded in the QA model parameters, and thus most works propose a Retrieval-Reader pipeline, by firstly index the whole corpus and use a retriever model to identify which passage is relevant
+
+
+Figure 4: Testing the reasoning capacity of OReOLM to infer missing relations. On the left, the barplot shows the transfer performance on EQ before and after removing relation edges, OReOLM $(T = 2)$ is less influenced. On the right shows reasoning paths (rules) automatically generated by OReOLM for each missing relation.
+
+$$
+\text {(Q u e r y)} \quad \mathrm {P 3 6 : c a p i t a l} = \underbrace {0 . 3 6 \rightarrow P 3 5 : \text {p r e s i d e n t :}} _ {0. 1 9 \rightarrow P 1 3 0 4: \text {c e n t r a l b a n k}} \underbrace {0 . 4 7 \rightarrow P 5 5 1 : \text {l i v e s i n}} _ {0. 3 2 \rightarrow P 3 9 7: \text {w o r k l o c a t i o n}} (\text {Q u e r y}) \quad \mathrm {P 2 6 : s p o u s e} = \underbrace {0 . 7 4} _ {0. 3 5 \rightarrow P 4 0: \text {c h i l d}} \quad \mathrm {P 2 2 : f a t h e r}
+$$
+
+$$
+\text {(Q u e r y) P 4 0 : l a n g u a g e} =\begin{array}{l}0. 7 1\\\rightarrow\end{array}\text {P 5 5 1 : l i v e s i n}\begin{array}{l}0. 8 5\\\rightarrow\end{array}\text {P 1 7 - 1 : C o u n t r y - 1} \quad \text {(Q u e r y) P 3 6 : l o c a t e d} =\begin{array}{l}0. 1 9\\\rightarrow\end{array}\text {P 4 8 8 : c h a i r p e r s o n}\begin{array}{l}0. 3 3\\\rightarrow\end{array}\text {P 5 5 1 : l i v e s i n}
+$$
+
+to the question; then the retrieved text passage concatenate with question is re-encoded by a seperate reader model (e.g., LM) to predict answer. As the knowledge is outside of model parameter, Roberts et al. (2020) defines these methods as Open-book, with an analogy to referring textbooks during exam. Closed-book QA models (mostly a single LM) try to answer open questions without accessing external knowledge. This setting is much harder as it requires LM to memorize all pertinent knowledge in its parameters, and even recent LMs with much larger model parameters is still not competitive to state-of-the-art Open-book models.
+
+Knowledge-augmented Language Models explicitly incorporate external knowledge (e.g. knowledge graph) into LM (Yu et al., 2022d). Overall, these approaches can be grouped into two categories: The first one is to explicitly inject knowledge representation into language model pre-training, where the representations are precomputed from external sources (Zhang et al., 2019; Liu et al., 2021; Hu et al., 2021). For example, ERNIE (Zhang et al., 2019) encodes the pre-trained TransE (Bordes et al., 2013) embeddings as input. The second one is to implicitly model knowledge information into language model by performing knowledge-related tasks, such as entity category prediction (Yu et al., 2022b) and graph-text alignment (Ke et al., 2021). For example, JAKET (Yu et al., 2022b) jointly pre-trained both the KG representation and language representation by adding entity category and relation type prediction self-supervised tasks.
+
+There also exists several QA works using $\mathcal{KG}$ to help ODQA. For example, Asai et al. (2020) and Min et al. (2019) expand the entity graph following wikipedia hyperlinks or triplets in knowledge base. Ding et al. (2019) extract entities from current context via entity-linking and turn them into a cognitive graph, and a graph neural network is applied on top of it to extract answer. Dhingra et al. (2020) and Lin et al. (2020) construct an entity-mention
+
+bipartite graph and then model the QA reasoning as graph traversal by filtering only the contexts that are relevant to the question. Lin et al. (2019), Feng et al. (2020) and Yasunaga et al. (2021) parse the question into a sub-graph of knowledge base, and apply graph neural networks as reasoner for extracting one of the entities as the answer.
+
+To encode knowledge (significantly smaller than the web corpus) as memory into LM parameter, a line of works try compressed knowledge including QA pairs (Chen et al., 2022; Lewis et al., 2021b; Yu et al., 2022c), entity embedding (Févry et al., 2020) and reasoning cases (Das et al., 2021, 2022). There's also several works utilizing Knowledge Graph $(\mathcal{KG})$ to augment LM. FILM (Verga et al., 2021) turns $\mathcal{KG}$ triplets into memory. Given a question, LM retrieves most relevant triplet as answer. GreaseLM (Zhang et al., 2022) propose to interact LM with $\mathcal{KG}$ via a interaction node.
+
+# 5 Conclusion
+
+We presented OREOLM, a novel model that incorporates symbolic $\kappa \mathcal{G}$ reasoning with existing LMs. We showed that OREOLM can bring significant performance gain to open-domain QA benchmarks, both for closed-book and open-book settings, as well as encoder-only and encoder-decoder models. Additionally, OREOLM produces reasoning paths that helps interpret the model prediction. In future, we'd like to improve OREOLM by training to conduct more reasoning steps, supporting local reasoning, and apply OREOLM to a broader range of knowledge-intensive NLP tasks.
+
+Acknowledgement We sincerely thank anonymous reviewers for their constructive comments to improve this paper. The project was partially supported in part by CISCO, NSF III-1705169, NSF 1937599, NASA, Okawa Foundation Grant, Amazon Research Awards, Cisco research grant, and Pictsart gift. Ziniu is supported by the Amazon Fellowship and Baidu PhD Fellowship.
+
+# 6 Limitations
+
+Limited Reasoning Steps In our experiments, we show that using reasoning step $T = 2$ has better performance to $T = 1$ on one-hop and multi-hop (mostly two) QA datasets. Thus, it's a natural question about whether we could extending reasoning steps more? As previous KG reasoning mostly could support very long path (with LSTM design)
+
+Though we didn't spend much time exploring before the paper submission, we indeed try using $T = 3$ , but currently it didn't get better results. We hypothesize the following reasons: 1) A large portion of our current model's improvement relies on the weakly supervised relation pre-training. To do it, we construct a K-hop (K=2 now) subgraph, and sample dependency graph based on it. The larger $K$ we choose, the more noise is included into the generated relation label, in an exponential increasing speed. Thus, it's harder to get accurate reasoning path ground-truth for high-order $T$ . Another potential reason is that within Transformer model, the representation space in lower and upper layer might be very different, say, encode more syntax and surface knowledge at lower layers, while more semantic knowledge at upper layers. Currently we adopt a MLP projection head, wishing to map integrated knowledge into the same space, but it might have many flaws and need further improvement.
+
+Large Entity Embedding Table requires Pre-Training and GPU resources Our current design has a huge entity embedding table, which should be learned through additional supervision and could not directly fine-tune to downstream tasks. This is restricts our approach's usage.
+
+Require Entity Linking Current model design requires an additional step of entity linking for incoming questions, and then add special tokens as interface. A truly end-to-end model should identify which elements to start conducting reasoning by its own without relying on external models.
+
+Only support relational path-based reasoning. Though there are lots of potential reasoning tasks, such as logical reasoning, commonsense reasoning, physical reasoning, temporal reasoning, etc. Our current model design mainly focus on path-based relational reasoning, and it should not work for other reasoning tasks at current stage.
+
+Unreasonable Assumption of Path In- dependency When we derive equation 1,
+
+we have the assumption that reasoning paths starting from different entities should be independent. This is not always correct, especially for questions that require logical reasoning, say, have conjunction or disjunction operation over each entity state. And thus our current methods might not work for those complex QA with logical dependencies.
+
+# References
+
+Akari Asai, Kazuma Hashimoto, Hannaneh Hajishirzi, Richard Socher, and Caiming Xiong. 2020. Learning to retrieve reasoning paths over wikipedia graph for question answering. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Jonathan Berant, Andrew Chou, Roy Frostig, and Percy Liang. 2013. Semantic parsing on freebase from question-answer pairs. In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, EMNLP 2013, 18-21 October 2013, Grand Hyatt Seattle, Seattle, Washington, USA. A meeting of SIGDAT, a Special Interest Group of the ACL, pages 1533-1544. ACL.
+Kurt D. Bollacker, Colin Evans, Praveen Paritosh, Tim Sturge, and Jamie Taylor. 2008. Freebase: a collaboratively created graph database for structuring human knowledge. In Proceedings of the ACM SIGMOD International Conference on Management of Data, SIGMOD 2008, Vancouver, BC, Canada, June 10-12, 2008, pages 1247-1250. ACM.
+Antoine Bordes, Nicolas Usunier, Alberto García-Durán, Jason Weston, and Oksana Yakhnenko. 2013. Translating embeddings for modeling multi-relational data. In Advances in Neural Information Processing Systems 26: 27th Annual Conference on Neural Information Processing Systems 2013. Proceedings of a meeting held December 5-8, 2013, Lake Tahoe, Nevada, United States, pages 2787-2795.
+Nicola De Cao, Gautier Izacard, Sebastian Riedel, and Fabio Petroni. 2021. Autoregressive entity retrieval. In 9th International Conference on Learning Representations, ICLR 2021, Virtual Event, Austria, May 3-7, 2021. OpenReview.net.
+Danqi Chen, Adam Fisch, Jason Weston, and Antoine Bordes. 2017. Reading wikipedia to answer open-domain questions. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics, ACL 2017, Vancouver, Canada, July 30 - August 4, Volume 1: Long Papers, pages 1870-1879. Association for Computational Linguistics.
+Wenhu Chen, Pat Verga, Michiel de Jong, John Wieting, and William Cohen. 2022. Augmenting pre-trained language models with qa-memory for open-domain question answering. CoRR, abs/2204.04581.
+
+Rajarshi Das, Shehzaad Dhuliawala, Manzil Zaheer, Luke Vilnis, Ishan Durugkar, Akshay Krishnamurthy, Alex Smola, and Andrew McCallum. 2018. Go for a walk and arrive at the answer: Reasoning over paths in knowledge bases using reinforcement learning. In 6th International Conference on Learning Representations, ICLR 2018, Vancouver, BC, Canada, April 30 - May 3, 2018, Conference Track Proceedings. OpenReview.net.
+Rajarshi Das, Ameya Godbole, Ankita Naik, Elliot Tower, Robin Jia, Manzil Zaheer, Hannaneh Hajishirzi, and Andrew McCallum. 2022. Knowledge base question answering by case-based reasoning over subgraphs. CoRR, abs/2202.10610.
+Rajarshi Das, Manzil Zaheer, Dung Thai, Ameya Godbole, Ethan Perez, Jay Yoon Lee, Lizhen Tan, Lazaros Polymenakos, and Andrew McCallum. 2021. Case-based reasoning for natural language queries over knowledge bases. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, EMNLP 2021, Virtual Event / Punta Cana, Dominican Republic, 7-11 November, 2021, pages 9594-9611. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2019, Minneapolis, MN, USA, June 2-7, 2019, Volume 1 (Long and Short Papers), pages 4171-4186. Association for Computational Linguistics.
+Bhuwan Dhingra, Manzil Zaheer, Vidhisha Balachandran, Graham Neubig, Ruslan Salakhutdinov, and William W. Cohen. 2020. Differentiable reasoning over a virtual knowledge base. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Ming Ding, Chang Zhou, Qibin Chen, Hongxia Yang, and Jie Tang. 2019. Cognitive graph for multi-hop reading comprehension at scale. In Proceedings of the 57th Conference of the Association for Computational Linguistics, ACL 2019, Florence, Italy, July 28- August 2, 2019, Volume 1: Long Papers, pages 2694-2703. Association for Computational Linguistics.
+Yanlin Feng, Xinyue Chen, Bill Yuchen Lin, Peifeng Wang, Jun Yan, and Xiang Ren. 2020. Scalable multi-hop relational reasoning for knowledge-aware question answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 1295-1309. Association for Computational Linguistics.
+
+Thibault Févry, Livio Baldini Soares, Nicholas FitzGerald, Eunsol Choi, and Tom Kwiatkowski. 2020. Entities as experts: Sparse memory access with entity supervision. CoRR, abs/2004.07202.
+Kelvin Guu, Kenton Lee, Zora Tung, Panupong Pasupat, and Ming-Wei Chang. 2020. REALM: retrieval-augmented language model pre-training. CoRR, abs/2002.08909.
+Ziniu Hu, Yizhou Sun, and Kai-Wei Chang. 2021. Relation-guided pre-training for open-domain question answering. In Findings of the Association for Computational Linguistics: EMNLP 2021, Virtual Event / Punta Cana, Dominican Republic, 16-20 November, 2021, pages 3431-3448. Association for Computational Linguistics.
+Mandar Joshi, Eunsol Choi, Daniel S. Weld, and Luke Zettlemoyer. 2017. Triviaqa: A large scale distantly supervised challenge dataset for reading comprehension. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics, ACL 2017, Vancouver, Canada, July 30 - August 4, Volume 1: Long Papers, pages 1601-1611. Association for Computational Linguistics.
+Vladimir Karpukhin, Barlas Oguz, Sewon Min, Ledell Wu, Sergey Edunov, Danqi Chen, and Wen-tau Yih. 2020. Dense passage retrieval for open-domain question answering. CoRR, abs/2004.04906.
+Pei Ke, Haozhe Ji, Yu Ran, Xin Cui, Liwei Wang, Linfeng Song, Xiaoyan Zhu, and Minlie Huang. 2021. Jointgt: Graph-text joint representation learning for text generation from knowledge graphs. In *Findings of the Association for Computational Linguistics: ACL/IJCNLP* 2021, Online Event, August 1-6, 2021, volume ACL/IJCNLP 2021 of *Findings of ACL*, pages 2526-2538. Association for Computational Linguistics.
+Tom Kwiatkowski, Jennimaria Palomaki, Olivia Redfield, Michael Collins, Ankur P. Parikh, Chris Alberti, Danielle Epstein, Illia Polosukhin, Jacob Devlin, Kenton Lee, Kristina Toutanova, Llion Jones, Matthew Kelcey, Ming-Wei Chang, Andrew M. Dai, Jakob Uszkoreit, Quoc Le, and Slav Petrov. 2019. Natural questions: a benchmark for question answering research. Trans. Assoc. Comput. Linguistics, 7:452-466.
+Ni Lao, Tom M. Mitchell, and William W. Cohen. 2011. Random walk inference and learning in A large scale knowledge base. In Proceedings of the 2011 Conference on Empirical Methods in Natural Language Processing, EMNLP 2011, 27-31 July 2011, John McIntyre Conference Centre, Edinburgh, UK, A meeting of SIGDAT, a Special Interest Group of the ACL, pages 529-539. ACL.
+Patrick S. H. Lewis, Pontus Stenetorp, and Sebastian Riedel. 2021a. Question and answer test-train overlap in open-domain question answering datasets. In Proceedings of the 16th Conference of the European
+
+Chapter of the Association for Computational Linguistics: Main Volume, EACL 2021, Online, April 19 - 23, 2021, pages 1000-1008. Association for Computational Linguistics.
+Patrick S. H. Lewis, Yuxiang Wu, Linqing Liu, Pasquale Minervini, Heinrich Kuttler, Aleksandra Piktus, Pontus Stenetorp, and Sebastian Riedel. 2021b. PAQ: 65 million probably-asked questions and what you can do with them. CoRR, abs/2102.07033.
+Bill Yuchen Lin, Xinyue Chen, Jamin Chen, and Xiang Ren. 2019. Kagnet: Knowledge-aware graph networks for commonsense reasoning. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 2829-2839. Association for Computational Linguistics.
+Bill Yuchen Lin, Haitian Sun, Bhuwan Dhingra, Manzil Zaheer, Xiang Ren, and William W. Cohen. 2020. Differentiable open-ended commonsense reasoning. CoRR, abs/2010.14439.
+Ye Liu, Yao Wan, Lifang He, Hao Peng, and Philip S. Yu. 2021. KG-BART: knowledge graph-augmented BART for generative commonsense reasoning. In Thirty-Fifth AAAI Conference on Artificial Intelligence, AAAI 2021, Thirty-Third Conference on Innovative Applications of Artificial Intelligence, IAAI 2021, The Eleventh Symposium on Educational Advances in Artificial Intelligence, EAAI 2021, Virtual Event, February 2-9, 2021, pages 6418-6425. AAAI Press.
+Sewon Min, Danqi Chen, Luke Zettlemoyer, and Hannaneh Hajishirzi. 2019. Knowledge guided text retrieval and reading for open domain question answering. CoRR, abs/1911.03868.
+Nina Porner, Ulli Waltinger, and Hinrich Schütze. 2020. E-BERT: efficient-yet-effective entity embeddings for BERT. In Findings of the Association for Computational Linguistics: EMNLP 2020, Online Event, 16-20 November 2020, volume EMNLP 2020 of Findings of ACL, pages 803-818. Association for Computational Linguistics.
+Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 21:140:1-140:67.
+Hongyu Ren, Weihua Hu, and Jure Leskovec. 2020. Query2box: Reasoning over knowledge graphs in vector space using box embeddings. In 8th International Conference on Learning Representations, ICLR 2020, Addis Ababa, Ethiopia, April 26-30, 2020. OpenReview.net.
+Adam Roberts, Colin Raffel, and Noam Shazeer. 2020. How much knowledge can you pack into the parameters of a language model? In Proceedings of the
+
+2020 Conference on Empirical Methods in Natural Language Processing, EMNLP 2020, Online, November 16-20, 2020, pages 5418-5426. Association for Computational Linguistics.
+Devendra Singh Sachan, Mostofa Patwary, Mohammad Shoeybi, Neel Kant, Wei Ping, William L. Hamilton, and Bryan Catanzaro. 2021a. End-to-end training of neural retrievers for open-domain question answering. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing, ACL/IJCNLP 2021, (Volume 1: Long Papers), Virtual Event, August 1-6, 2021, pages 6648-6662. Association for Computational Linguistics.
+Devendra Singh Sachan, Siva Reddy, William L. Hamilton, Chris Dyer, and Dani Yogatama. 2021b. End-to-end training of multi-document reader and retriever for open-domain question answering. In Advances in Neural Information Processing Systems 34: Annual Conference on Neural Information Processing Systems 2021, NeurIPS 2021, December 6-14, 2021, virtual, pages 25968-25981.
+Christopher Sciavolino, Zexuan Zhong, Jinhyuk Lee, and Danqi Chen. 2021. Simple entity-centric questions challenge dense retrievers. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, EMNLP 2021, Virtual Event / Punta Cana, Dominican Republic, 7-11 November, 2021, pages 6138-6148. Association for Computational Linguistics.
+Haitian Sun, Tania Bedrax-Weiss, and William W. Cohen. 2019. Pullnet: Open domain question answering with iterative retrieval on knowledge bases and text. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing, EMNLP-IJCNLP 2019, Hong Kong, China, November 3-7, 2019, pages 2380-2390. Association for Computational Linguistics.
+Alon Talmor and Jonathan Berant. 2018. The web as a knowledge-base for answering complex questions. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2018, New Orleans, Louisiana, USA, June 1-6, 2018, Volume 1 (Long Papers), pages 641-651. Association for Computational Linguistics.
+Pat Verga, Haitian Sun, Livio Baldini Soares, and William W. Cohen. 2021. Adaptable and interpretable neural memory over symbolic knowledge. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2021, Online, June 6-11, 2021, pages 3678-3691. Association for Computational Linguistics.
+
+Denny Vrandecic and Markus Krötzsch. 2014. Wiki-data: a free collaborative knowledgebase. Commun. ACM, 57(10):78-85.
+Xiaozhi Wang, Tianyu Gao, Zhaocheng Zhu, Zhiyuan Liu, Juanzi Li, and Jian Tang. 2019. KEPLER: A unified model for knowledge embedding and pre-trained language representation. CoRR, abs/1911.06136.
+Wenhan Xiong, Thien Hoang, and William Yang Wang. 2017. Deeppath: A reinforcement learning method for knowledge graph reasoning. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, EMNLP 2017, Copenhagen, Denmark, September 9-11, 2017, pages 564-573. Association for Computational Linguistics.
+Zhilin Yang, Zihang Dai, Yiming Yang, Jaime G. Carbonell, Ruslan Salakhutdinov, and Quoc V. Le. 2019. Xlnet: Generalized autoregressive pretraining for language understanding. In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 5754-5764.
+Zhilin Yang, Peng Qi, Saizheng Zhang, Yoshua Bengio, William W. Cohen, Ruslan Salakhutdinov, and Christopher D. Manning. 2018. Hotpotqa: A dataset for diverse, explainable multi-hop question answering. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, Brussels, Belgium, October 31 - November 4, 2018, pages 2369-2380. Association for Computational Linguistics.
+Michihiro Yasunaga, Hongyu Ren, Antoine Bosselut, Percy Liang, and Jure Leskovec. 2021. QA-GNN: reasoning with language models and knowledge graphs for question answering. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, NAACL-HLT 2021, Online, June 6-11, 2021, pages 535-546. Association for Computational Linguistics.
+Wen-tau Yih, Ming-Wei Chang, Xiaodong He, and Jianfeng Gao. 2015. Semantic parsing via staged query graph generation: Question answering with knowledge base. In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics and the 7th International Joint Conference on Natural Language Processing of the Asian Federation of Natural Language Processing, ACL 2015, July 26-31, 2015, Beijing, China, Volume 1: Long Papers, pages 1321-1331. The Association for Computer Linguistics.
+Donghan Yu, Chenguang Zhu, Yuwei Fang, Wenhao Yu, Shuohang Wang, Yichong Xu, Xiang Ren, Yiming Yang, and Michael Zeng. 2022a. Kg-fid: Infusing knowledge graph in fusion-in-decoder for open-domain question answering. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), ACL
+
+2022, Dublin, Ireland, May 22-27, 2022, pages 4961-4974. Association for Computational Linguistics.
+Donghan Yu, Chenguang Zhu, Yiming Yang, and Michael Zeng. 2022b. JAKET: joint pre-training of knowledge graph and language understanding. Conference on Artificial Intelligence, AAAI.
+Wenhao Yu, Dan Iter, Shuohang Wang, Yichong Xu, Mingxuan Ju, Soumya Sanyal, Chenguang Zhu, Michael Zeng, and Meng Jiang. 2022c. Generate rather than retrieve: Large language models are strong context generators. CoRR, abs/2209.10063.
+Wenhao Yu, Chenguang Zhu, Zaitang Li, Zhiting Hu, Qingyun Wang, Heng Ji, and Meng Jiang. 2022d. A survey of knowledge-enhanced text generation. ACM Computing Survey.
+Xikun Zhang, Antoine Bosselut, Michihiro Yasunaga, Hongyu Ren, Percy Liang, Christopher D. Manning, and Jure Leskovec. 2022. Greaselm: Graph reasoning enhanced language models for question answering. CoRR, abs/2201.08860.
+Zhengyan Zhang, Xu Han, Zhiyuan Liu, Xin Jiang, Maosong Sun, and Qun Liu. 2019. ERNIE: enhanced language representation with informative entities. In Proceedings of the 57th Conference of the Association for Computational Linguistics, ACL 2019, Florence, Italy, July 28-August 2, 2019, Volume 1: Long Papers, pages 1441-1451. Association for Computational Linguistics.
+
+# A Implementation Details
+
+Entity Linking durine pre-training We use the 2021 Jan. English dump of Wikidata and Wikipedia. For each wikipedia page, we link all entity mentions with hyperlinks to WikiData entity entry, augment all other mentions with same aliases, tokenize via each LM's tokenizer and split into chunks with maximum token length allowed. We then construct induced k-hop subgraphs connecting entities within each chunk for quickly get grounded computational graph.
+
+For entities, Wikipedia provides hyperlinks with ground-truth entity ID, but it doesn't cover all the entity mentions, mostly hyperlinks only appear when this entity appears for the first time. Therefore, we first collect all entities appeared in hyperlinks as well as their aliases stored in WikiData, and then search any mentions that have any of these alias and link it to the corresponding entity.
+
+Hyperparameters In this work, we don't have too much hyperparamaters to be tuned, as most parameters as well as optimizing setting of LM is fixed. Our random walk part is non-parametric. The only tunable hyperparameter is hidden dimension size. We simply choose one setting, which is 128 for entity embedding, and 768 for relation embedding. The former is because entity is super large (over 5M), so we use a reletively smaller dimension size. Detailed statistics about wikidata memory is in Table 1.
+
+# B Dataset Details
+
+Below shows details for each dataset, and the detailed dataset split is shown in Figure 5
+
+Natural Questions (Kwiatkowski et al., 2019) contains questions from Google search queries, and the answers are text spans in Wikipedia. We report short answer Exact Match (EM) performance. The open version of this dataset is obtained by discarding answers with more than 5 tokens.
+
+WebQuestions (WQ) (Berant et al., 2013) contains questions from Google Suggest API, and the answers are entities in Freebase.
+
+TriviaQA (Joshi et al., 2017) contains trivia questions and answers are text spans from the Web. We report Exact Match (EM) performance. We use its unfiltered version for evaluation.
+
+HotpotQA (Yang et al., 2018) is a multi-hop QA dataset. There are two evaluation settings. In the distractor setting, 10 candidate paragraphs are provided for each question, of which there are two golden paragraphs. In the full-wiki setting, a model is required to extract paragraphs from the entire Wikipedia. We report Exact Match (EM) on full-wiki setting.
+
+Complex WebQuestions (Talmor and Berant, 2018) is a dataset that composite simple one-hot questions in WebQuestionsSP by extending entities or adding constraints, so that each question requires complex reasoning to solve.
+
+WebQuestionsSP (Yih et al., 2015) is annotated dataset from WebQuestions, such taht each question is answerable using Freebase via a SQL query.
+
+# C Discussion with Previous Works
+
+Compare with FILM Though FILM has the advantage of end-to-end training and easily modification of knowledge memory, it simply stacks $\kappa \mathcal{G}$ module on top of LM without interaction, and can only handle one-hop relational query that is answerable by $\kappa \mathcal{G}$ . Our approach, OREOLM, follows the same memory idea by encoding $\kappa \mathcal{G}$ into LM parameter, and we desire LM and $\kappa \mathcal{G}$ reasoning module could interact and collaboratively improve each other.
+
+Notably, OReOLM with $T = 1$ shares a similar design with FILM. The major differences are: 1) they store every triplet as a key-value pair, while we explicitly keep the $\kappa G$ adjacency matrix and conduct a random walk, which has smaller search space and is more controllable. 2) They add the memory on top of LM, and thus the knowledge could not help language understanding, and FILM could mainly help wikipedia-answerable questions. Instead, we insert the KIL layer amid LM layers to encourage interaction, and thus the model could also benefit encoder-decoder model (as shown above).
+
+Compare with Previous Path-Based Reasoning and Retrieval Pre-Training Note that as our definition of entity state $\pi_{i}$ and relation action $\gamma_{i}$ are both continuous probabilistic vector, the whole $\mathcal{KG}$ Reasoning is fully differentiable and thus could be integrated into LM seamlessly and trained end-to-end. This is different from previous path traversal works such as DeepPath (Xiong et al., 2017) and MINERVA (Das et al., 2018), which defines state
+
+| Dataset | Train | Dev | Test |
| Natural Questions | 58880 | 8757, 3610 | |
| Trivia QA | 60413 | 8837 | 11313 |
| Web Questions | 2474 | 361 | 2032 |
| Complex WebQ | 27623 | 3518 | 3531 |
| WebQ-SP (Wiki-answerable) | 1388 | 153 | 841 |
| FreebaseQA (Wiki-answerable) | 12535 | 2464 | 2440 |
+
+Table 5: Dataset Train/Valid/Test splits.
+
+| Models | #param (B) | WQ-SP | TQA |
| RoBERTa (Base) | 0.12 | 47.5 | 40.3 |
| + OREOLM (T=1) | 0.12 + 0.68 | 89.7 | 61.4 |
| + OREOLM (T=2) | 0.13 + 0.68 | 92.4 | 66.8 |
+
+Table 6: Closed-Book Entity Prediction validation performance of Encoder RoBERTa on WikiData-Answerable Dataset.
+
+and action as discrete and could only be trained via reinforcement learning rewards. The reasoner training is also different from passage retrieval pretraining (Guu et al., 2020; Sachan et al., 2021a), as the passage are naturally consisted of discrete tokens, and thus the reader is still required to reencode the question with each passage, and different objectives are required to train retriever and reader separately.
+
+Discussion of Graph Walking-based Reasoning vs Graph Neural Networks Recently, Graph Neural Networks (GNNs) have shown superior performance for structured representation learning. There's also a lot of works trying to use GNNs for Question Answering (Yasunaga et al., 2021; Zhang et al., 2022). The one that has very similar motivation with us is GreaseLM. Therefore, a natural question is, whether could we use GNN instead of the non-parametric random walk module, for ODQA?
+
+To answer this question, let's consider a simplest setup of GNN. We could identify initial entities, connected them via a k-hop subgraph, and encode graph with text (Zhang et al., 2022) or independently (Yu et al., 2022b). When we want to retrieve knowledge from graph to LM, normally we just take the contextualized node embedding as input for knowledge fusion.
+
+In this setup, say the answer is $K$ -hop away from an initial entity, the ground-truth reasoning path is $e_0, r_1, e_1, r_2, \ldots, e_{k-1}, r_k, e_k = a$ . Using
+
+our method, we first predict $r1$ , transit to $e_1$ , and step by step conduct reasoning via walking. However, if we use GNN's final embedding, it requires to pass information from neighbor to itself. Therefore, suppose we have a $K$ -layer GNN, the first step should be identify $r_k$ , and pass information from answer $e_k = a$ to $e_{k-1}$ . This is counter-intuitive as we normally cannot assume to know the answer, nor knowing the last step to reach the answer. In situations where all candidate answers are given, like CommonSenseQA, where GreaseLM mainly works on, this problem is less harmful as it's guaranteed to contain the answer in a restricted small graph. However, in open-domain setup, we need to try best to narrow down the search space by following the forward reasoning instead of the backward manner. Therefore, in this work we adopt walking-based reasoning.
+
+# D Illustration of Pre-Trained Data and Reasoning Paths
+
+The pre-training samples and reasoning paths (generated by T5-large on NQ dataset) is shown from Table 8-11.
+
+| Models | #param | NQ | WQ | TQA | ComplexWQ | HotpotQA |
| T5 (Large) | 0.74B | - | - | - | - | - |
| + OREOLM (T=2) | 0.76B + 0.68B | 33.6 | 38.9 | 42.7 | 29.6 | 35.5 |
+
+Table 7: Closed-Book Generative QA validation performance of T5.
+
+| Title | Masked Text | Ground Truth | Dependency Graph | 2-Hop Graph |
| Poolbeg | the lighthouse was [mask] [s-ent] [mask][rel] [t-ent] completed in 1795. overview, the [s-ent] poolbeg[rel] [t-ent] “peninsula” is home to a number of landmarks including the [s-ent] [mask][rel] [t-ent], the [s-ent] pool [mask] light-house [rel] [t-ent], the [s-ent] light-house [rel] [t-ent], the southern part of [s-ent] [mask][rel] [t-ent] ... | [’connected to land by the’, great south wall’, great south wall’, beg’, dublin port’, main power station,’ structures in’, ‘48’, ‘a process to list the’, after the station’, including 3’, ‘dublin city council’, ‘quarter” on the’] | [berg geobig station
+own nature park, dublin town, duffin town, garryback
+poolbeg [thouse] historic county
+broadway, burlingdon, burlingdon, burlingdon
+pocrac, burlingdon, burlingdon, burlingdon,
+burlingdon, burlingdon, burlingdon,
+burlingdon, burlingdon, burlingdon,
+burlingdon, burlingdon, burlingdon,
+burlingdon, burlingdon, burlingdon,
+burlingdon, burlingdon, burlingdon,
+burlingdon, burlingdon, burlingdon,
+burlingdon, burlingdon, bayeside
+spine archibool | |
| Rylstone | it is situated very near to [s-ent] [mask][rel] [t-ent] and about 6 miles south west[mask] [s-ent] [mask] [kingtong][rel] [t-ent]. the population of the [s-ent] civil parish [rel] [t-ent] as of the 2011 census was 160. [s-ent] rylstone railway station [rel] [t-ent] opened in 1902, closed to passengers in 1930, and closed completely in 1969... | [’craven’, ‘cracoe’, ‘of’, ‘grass’, ‘the inspiration for’, ‘tour de france’, ‘stone’, by will...] | [kettiewegel stabston
+kettiewegel n cline
+grasston n cline
+luydowen n cline
+luydowen n cline
+rystone railway station
+north pocrac | |
| Karpinsk | ologist [s-ent] [mask] [rel] [t-ent] history[mask] the settlement of bo-goslovsk () was founded in either 1759 or in 1769. it remained one of the largest [s-ent] copper[rel] [t-ent] production centers in the [s-ent] urals[rel] [t-ent] [mask] [s-ent] [mask][rel] [t-ent] deposits started to be mined in 1911.... | [’alexander karpinsky’, ‘until 1917’, ‘coal’, ‘erman civilians, who’, ‘and’, ‘years of’, ‘forest laborers, moreover’, ‘in’, ‘the’, ‘framework of the’, ‘dis-stricts’, ‘karpinsk’, ‘insk’...] | [proteinadditive coal mine
+lighter, burlingdon, burlingdon, burlingdon,
+cline, cline
+larval mammals m caribouous sennecm
+copper, copper, copper
+gullhorn, gullhorn
+kazakh, kazakh | |
| 3 (The X-Files) | [s-ent] [mask][rel] [t-ent] . [s-ent] gillian anderson[srl] [t-ent] is absent[mask][mask] episode as she was on leave to give birth to her daughter piper at the time. this episode was the first[mask] not appear. reception. ratings. “3” pre-miered on the [s-ent] fox network[rel] [t-ent] on, and was first broadcast in the [s-ent] united kingdom[rel] [t-ent].... | [’ny had’, ‘episode’, ‘born again’, ‘from the’, in which scully did’, ‘it was’, ‘egall’, ‘metacritic’, ‘as wretched’, ‘fact that’, ‘background noise for a’, ‘heavy-handed attempts at’, ‘glen morgan’, ‘doing an episode on’] | [the airies (season 1)
+the airies (season 2) | |
+
+Table 8: Example of Pre-training data points (Part 1).
+
+| Title | Masked Text | Ground Truth | Dependency Graph | K-Hop Graph |
| Shen Chun-shan | his memoirs, he suffered his second stroke[mask][mask], even after his second stroke, he continued writing; his series of biographies of five go masters [s-ent] [mask][mask][mask][rel] [t-ent], [s-ent] mi-noru kit[mask][rel] [t-ent] ....... | [’ however’, ‘ go seigen’, ‘ ani’, ‘ 2007, he’, ‘ was hos-pital’, ‘ hisinchu’, ‘after surgery’, ‘ scale’, ‘ continuing to im-prove’, ‘ his coma. in’ ...] | | |
| 2007 Florida Gators football team | [s-ent] tim[mask][mask][rel] [t-ent] completed 22 of 27 passes for 281 yards passing and also ran for[mask] yards on 6 carries. [s-ent] [mask] [rel] [t-ent] carried the ball 11 times for 113 yards[mask] two touchdowns and also caught 9 passes for 110[mask] receiving, becoming the first player in school history ....... | [’ tebow’, ‘ 35’, ‘ percy harvin’, ‘ and’, ‘ yards’, ‘ 30-9’, ‘ renewed their bud-ding’, ‘ gamecocks’, ‘gator’, ‘ quarter-back’, ‘ set a career-high’, ‘ of these five rushing’, ‘ ', ‘ percy harvin’, ‘ sinus in-fction’, ‘ ators’, ‘ touchdown’] | | |
| Judgment Day (Awe-some Comics) | [s-ent] alan moore[rel] [t-ent] used “judgment day” to reject the violent, deconstructive clichés of 1990s comics inadvertently caused by his own work on ” [s-ent] watchdogmen[rel] [t-ent] , , ” and " [s-ent] saga of the[mask][mask][rel] [t-ent] ” and uphold the values of classic superhero comics. the series deals with a metacommetary of the notion of ret- cons to super- hero histories as [s-ent] alan moore[rel] [t-ent] [mask] for the characters of [s-ent] [mask][mask][rel] [t-ent] , to replace the shared universe they left when [s-ent] rob liefeld[rel] [t-ent] left image several years earlier. plot. in[mask], mick tombs/ [s-ent] knightsabre[rel] [t-ent] ....... | [’ swamp thing’, ‘ himself creates a new backstory’, ‘ awesome comics’, ‘ 1997’, ‘ riptide’, ‘ knightsabre appears to be’, ‘ and sw’, ‘ badrock’, ‘ supreme’, ‘ by’, ‘ analyzing’, ‘ cyber-netic young’, ‘ it, and it has’, ‘ ue out’, ‘ , administrator for youngblood’] | | |
+
+Table 9: Example of Pre-training data points (Part 2).
+
+| Question | Answer | Reasoning Paths as Rationale |
| southern soul was consid- ered the sound of what in- dependent record label | ['Motown'] | soul music \( \xrightarrow{\text{genre-R}}? \xrightarrow{\text{label}}? \) |
| independent record label \( \xrightarrow{\text{belong}}? \xrightarrow{\text{is a-R}}? \) |
| who is the bad guy in lord of the rings | ['Sauron'] | the lord of the rings (film series) \( \xrightarrow{\text{theme}}? \xrightarrow{\text{characters}}? \) |
| where was the mona lisa kept during ww2 | ['the Ingres Museum', "Château d'Amboise", 'Château de Cham-bord', 'the Loc - Dieu Abbey'] | mona lisa \( \xrightarrow{\text{creator}}? \xrightarrow{\text{tomb}}? \) |
| world war 2 \( \xrightarrow{\text{take place}}? \xrightarrow{\text{located-R}}? \) |
| who have won the world cup the most times | ['Brazil'] | fifa world cup \( \xrightarrow{\text{parts}}? \xrightarrow{\text{land}}? \) |
| who wrote the song the beat goes on | ['Sonny Bono'] | \( \text{song} \xrightarrow{\text{album type-R}}? \xrightarrow{\text{author}}? \) |
| who plays mrs. potato head in toy story | ['Estelle Har- ris'] | toy story \( \xrightarrow{\text{series}}? \xrightarrow{\text{VO}}? \) |
| who plays caroline on the bold and beautiful | ['Linsey Godfrey'] | the bold and the beautiful \( \xrightarrow{\text{in work-R}}? \xrightarrow{\text{actor}}? \) |
| where are the fruits of the spirit found in the bible | ['Epistle to the Gala- tians'] | bible \( \xrightarrow{\text{parts}}? \xrightarrow{\text{parts}}? \) |
| who is the only kaurava who survived the kuruk- shetra war | ['Yuyutsu'] | kaurava \( \xrightarrow{\text{in work}}? \xrightarrow{\text{in work-R}}? \) |
| Kurukshetra War \( \xrightarrow{\text{location}}\text{live in-R} \) |
| what is the deepest depth in the oceans | ['Mariana Trench'] | ocean \( \xrightarrow{\text{in}}? \xrightarrow{\text{lowest point}}? \) |
| where did the french na- tional anthem come from | ['Strasbourg'] | national anthem \( \xrightarrow{\text{is a-R}}? \xrightarrow{\text{released in}}? \) |
+
+Table 10: Example of QA prediction with reasoning path on NQ (part 1).
+
+| Question | Answer | Generated Reasoning Paths as Rationale |
| who sings the song where have all the flowers gone | ['Pete Seeger'] | \( \text{song} \xrightarrow{\text{album type-R}}? \xrightarrow{\text{actor}}? \) |
| who discovered some is-lands in the bahamas in 1492 | ['Christopher Columbus'] | the bahamas \( \xrightarrow{\text{entry}}? \xrightarrow{\text{entry-R}}? \) |
| which type of wave re-quires a medium for trans-mission | ['mechanical waves', 'heat energy', 'Sound'] | wave \( \xrightarrow{\text{belong-R}}? \xrightarrow{\text{belong-R}}? \) |
| land conversion through burning of biomass re-leases which gas | ['traces of methane', 'carbon monoxide', 'hydrogen'] | gas \( \xrightarrow{\text{belong-R}}? \xrightarrow{\text{as-R}}? \) |
| the sum of the kinetic and potential energies of all particles in the system is called the | ['internal en-ergy'] | kinetic energy \( \xrightarrow{\text{belong}}? \xrightarrow{\text{belong-R}}? \)potential energy \( \xrightarrow{\text{belong}}? \xrightarrow{\text{belong-R}}? \) |
| who did seattle beat in the super bowl | ['Denver Broncos'] | super bowl \( \xrightarrow{\text{organizer}}? \xrightarrow{\text{league-R}}? \) |
| what is the name of the girl romeo loved before juliet | ['Rosaline'] | romeo \( \xrightarrow{\text{in work}}? \xrightarrow{\text{in work-R}}? \) |
| who will get relegated from the premier league 2016/17 | [ 'Hull City', 'Sun-derland', 'Middles-brough'] | premier league \( \xrightarrow{\text{league-R}}? \xrightarrow{\text{POB}}? \) |
| actress in the girl with the dragon tattoo swedish | ['Noomi Ra-pace'] | sweden \( \xrightarrow{\text{speaking}}? \xrightarrow{\text{mother tongue-R}}? \) |
+
+Table 11: Example of QA prediction with reasoning path on NQ (part 2).
\ No newline at end of file
diff --git a/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/images.zip b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..df7351ddc4dd62c0c9362406b65ea37c6d302ea9
--- /dev/null
+++ b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:60289dd93ca0d6395aa33ead74e7267a340927f7265475048176fab7b85899ac
+size 1350940
diff --git a/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/layout.json b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..94b58005b2fca5373af19f58b9964fdb2a881f8c
--- /dev/null
+++ b/empoweringlanguagemodelswithknowledgegraphreasoningforopendomainquestionanswering/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d6c6ab2e47fd956a13e6a502153df2b5e7aa7d1d04308b22996b5204931dca74
+size 581493
diff --git a/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_content_list.json b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..e9bb558b34f6b9f72536c856d3cdb9ae3ed4060f
--- /dev/null
+++ b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e54df34f40312bc87c24ca28d4c9974f26fdf36b5c200f2712e2e30dd9845158
+size 103887
diff --git a/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_model.json b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..22146aec5d1a12d0226a1692e5f318f7c2c13c6e
--- /dev/null
+++ b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:215ffc1ef23dc649b92728c472b134e541495ff8add1a2f575bf9d0684ec4041
+size 127277
diff --git a/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_origin.pdf b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..09c6473e7609cdc3f4fa49576bb021d61c574bb7
--- /dev/null
+++ b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/489344fa-d151-4d47-843f-767961ca36b8_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:84ecbc7434064e66c05ee521edb1b8e7f61c0e8941207ee7e349a12628e1ba4c
+size 657939
diff --git a/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/full.md b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..adf345e0875cad7cfd48aef87a8448cac501ec8d
--- /dev/null
+++ b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/full.md
@@ -0,0 +1,385 @@
+# Empowering the Fact-checkers! Automatic Identification of Claim Spans on Twitter
+
+Megha Sundriyal $^{1*}$ , Atharva Kulkarni $^{1*}$ , Vaibhav Pulastya $^{1}$ , Md Shad Akhtar $^{1}$ , Tanmoy Chakraborty $^{2}$
+
+$^{1}$ IIT Delhi, India, $^{2}$ IIT Delhi, India
+
+{meghas, atharvak, vaibhav17271, shad.akhtar}@iiitd.ac.in, tanchak@ee.iitd.ac.in
+
+# Abstract
+
+The widespread diffusion of medical and political claims in the wake of COVID-19 has led to a voluminous rise in misinformation and fake news. The current vogue is to employ manual fact-checkers to efficiently classify and verify such data to combat this avalanche of claim-ridden misinformation. However, the rate of information dissemination is such that it vastly outpaces the fact-checkers' strength. Therefore, to aid manual fact-checkers in eliminating the superfluous content, it becomes imperative to automatically identify and extract the snippets of claim-worthy (mis)information present in a post. In this work, we introduce the novel task of Claim Span Identification (CSI). We propose CURT, a large-scale Twitter corpus with token-level claim spans on more than $7.5k$ tweets. Furthermore, along with the standard token classification baselines, we benchmark our dataset with DABERTa, an adapter-based variation of RoBERTa. The experimental results attest that DABERTa outperforms the baseline systems across several evaluation metrics, improving by about 1.5 points. We also report detailed error analysis to validate the model's performance along with the ablation studies. Lastly, we release our comprehensive span annotation guidelines for public use.
+
+# 1 Introduction
+
+The swift acceleration of Online Social Media (OSM) platforms has led to tremendous democratized content creation and information exchange. Consequently, these platforms serve as ideal breeding grounds for malicious rumormongers and talebearers, abetting a colossal upsurge of misinformation. Such misinformation manifests in many ways, including bogus claims, fabricated information, and rumors. The massive COVID-19 'Infodemic' (Naeem and Bhatti, 2020) is one such malignant byproduct that led to the rampant spread
+
+RT @PirateAtLaw: No no no. Corona beer is the cure not the disease.
+We don't have evidence but we are positive our wine keeps you from getting #COVID19 if you drink enough of it. Better alternative to #DisinfectantInjection don't you think? #winecues.
+@adamseconomics Vaccine is probably made from Chinese ingredients sourced in Wuhan.
+RT @angelicamdc: Mexicans are immune to the coronavirus because we have sana sana colita de rana
+
+Figure 1: Examples of claim tweets and their ground truth claim spans highlighted in boldface text (blue).
+
+of political and social calumny (Ferrara, 2020; Margolin, 2020; Ziems et al., 2020), accompanied by counterfeit pharmaceutical claims (O'Connor and Murphy, 2020). Therefore, finding such claim-ridden posts on OSM platforms, investigating their plausibility, and differentiating the credible claims from the apocryphal ones has risen to be a pertinent research problem in Argument Mining (AM).
+
+'Claim', as coined by Toulmin (2003), is 'an assertion that deserves our attention'. It is the key component of any argument (Daxenberger et al., 2017). Consider the second tweet, 'We don't have evidence...', as given in Figure 1. For the task of claim identification at the coarse level, the entire tweet will be marked as a claim. However, on closer inspection, we find that the text fragments of 'our wine keeps you from getting #COVID19' and 'Better alternative to #DisinfectantInjection' represent the finer argumentative units of claim and form the set of evidence, based on which this tweet is considered a claim. Segregating such argumentative units of misinformed claims from their benign counterparts fosters many benefits. To begin with, it partitions the otherwise independent claims in a single post, enabling us to retrieve a larger number of claims. Secondly, it acts as a precursor to the downstream tasks of claim check-
+
+worthiness and claim verification. Thirdly, it will also bring in the angle of explainability in coarse-grained claim identification. Finally, it will serve the manual fact-checkers and hoax-debunkers1,2 to conveniently strain out the unnecessary shreds of text from further processing. We further elaborate on the necessity of claim span identification and exemplify it in Section 2.
+
+Though the recent literature reflects extensive work done in claim detection (Daxenberger et al., 2017; Chakrabarty et al., 2019; Gupta et al., 2021), limited forays have been made in claim span identification i.e., recognizing the argumentative components of a claim (Wuhrl and Klinger, 2021). In the recent past, commendable work has been done on span-level argument unit recognition pertaining to other computational counterparts under the umbrella of AM, such as hate speech (Mathew et al., 2021), toxic language (Pavlopoulos et al., 2021) etc. Such study, however, has eluded the realm of claims, owing to the lack of quality annotated datasets. This heralds a specialized corpus creation on claim span identification.
+
+To this end, we propose CURT (Claim Unit Recognition in Tweets), a large-scale, claim span annotated Twitter corpus. We also present several baseline models for solving claim span identification as a token classification task and evaluate them on CURT. Furthermore, we introduce claim descriptions, which are generic prompts aimed to assist the model in focusing on the most significant regions of the input text using explicit instructions on what to designate as a 'claim'. They are elucidated later in detail. Finally, we benchmark our dataset with DABERTa (Description Aware RoBERTa), a plug-and-play adapter-based variant of RoBERTa (Liu et al., 2019), endeavored to infuse the Pre-trained Language Model (PLM) with the description information. Empirical results attest that DABERTa outperforms the conventional baselines and generic PLMs for our task consistently across various metrics.
+
+Contributions. Through this work, we make the following tangible contributions:
+
+1. Formulation of a novel problem statement: We propose the novel task of Claim Span Identification that aims to identify argument units of claims in the given text.
+
+2. Claim span identification dataset and extensive annotation guidelines: We posit a large-scale Twitter dataset, the first of its kind, with $7.5k$ claim span annotated tweets, to placate the absence of the annotated dataset for claim span identification. Additionally, we develop comprehensive annotation guidelines for the same.
+3. Claim span identification system: We propose a robust claim span identification framework based on Compositional De-Attention (CoDA) and Interactive Gating Mechanism (IGM).
+4. Extensive evaluation and analysis: We evaluate our model against different baselines to confirm sizable improvements over them. We also report thorough qualitative and quantitative analysis along with the ablation studies.
+
+Reproducibility. We release our dataset and code for DABERTa at https://github.com/LCS2-IIITD/DABERTA-EMNLP-2022. We present detailed dataset annotation guidelines in the Appendix (A.1).
+
+# 2 Why Claim Span Identification?
+
+As stated in Section 1, we hypothesize that claim span identification would aid fact-checkers to quickly segregate claim-ridden content from the rest of the post. Moreover, we suppose that it will be a propitious precursor for claim verification and fact-checking, facilitating better retrieval of relevant evidences. We back our hypothesis with a small experiment of evidence-based document retrieval. We collect 50 random samples from CURT, along with their corresponding ground-truth claim spans. Further, for both the tweets and the claim spans, we extract top- $k$ relevant articles from a knowledge-base leveraging the traditional retrieval system, BM25 (Robertson et al., 1995). We use the recently released publicly available CORD19 corpus (Wang et al., 2020) to retrieve factual documents. Finally, we present retrieved documents to three evaluators and ask them to mark whether or not the retrieved shreds of evidence are relevant to the given input tweet/-span from our dataset. All three annotators label each text-evidence pair independently. Eventually, to obtain the final relevancy score, majority voting is employed. We obtain a high inter-annotator score (Fleiss Kappa) of 0.63 and 0.67 for tweets and spans, respectively.
+
+We compare the performance of tweet-based and span-based retrievals in terms of precision (P) and
+
+| Input | P@5 | P@3 | nDCG@5 | nDCG@3 |
| Tweets | 0.3922 | 0.2745 | 0.2733 | 0.2280 |
| Spans | 0.4407 | 0.3390 | 0.3038 | 0.2521 |
+
+Table 1: nDCG@k and P@k scores for tweet and spans using BM25 retrieval system and CORD19 dataset.
+
+normalized Discounted Cumulative Gain (nDCG) scores and report them in Table 1. For comparison, we consider two different top- $k$ settings ( $k = 3$ and 5). We begin by examining the retrieval performance using $\mathrm{P}@\bar{k}$ , which measures the fraction of relevant documents extracted in the top- $k$ set. Span-based document retrieval consistently improves precision scores when compared to tweets. For nDCG@5, we discover that span-based retrieval outperforms tweet-based retrieval by more than $3\%$ . When we limit the retrieval depth to 3, we see a similar pattern. This, in turn, demonstrates that entire posts contain much extraneous information, frequently impeding the performance of evidence retrieval systems that are a prerequisite for both automated and manual fact-checking. In summary, we reinforce that our hypothesis positively stands true, as span-based document retrieval results in a better score for precision as well as nDCG. This attests to the task's feasibility and importance in the realm of claims.
+
+# 3 Related Work
+
+Claims on Social Media. The prevailing research on claims could be cleft into three categories - claim detection (Levy et al., 2014; Chakrabarty et al., 2019; Gupta et al., 2021), claim cheekworthiness (Jaradat et al., 2018; Wright and Augenstein, 2020), and claim verification (Zhi et al., 2017; Hanselowski et al., 2018; Soleimani et al., 2020). Bender et al. (2011) pioneered the efforts in claim detection by introducing the AAWD corpus. Subsequent studies largely relied on using linguistically motivated features such as sentiment, syntax, context-free grammars, and parse-trees (Rosenthal and McKeown, 2012; Levy et al., 2014; Lippi and Torroni, 2015). Recent works in claim detection have engendered the use of large language models (LMs). Chakrabarty et al. (2019) re-enforced the power of fine-tuning, as their ULMFiT LM, fine-tuned on a large Reddit corpus of about 5M opinionated claims, showed notable improvements in claim detection benchmark. Gupta et al. (2021) proposed a generalized claim detection model for detecting claims independent of its source. They handled structured and unstructured data in con
+
+junction by training a blend of linguistic encoders (POS and dependency trees) and a contextual encoder (BERT) to exploit the input text's semantics and syntax. As LMs account for significant computational overheads, Sundriyal et al. (2021) addressed this quandary and proposed a lighter framework that attempted to fabricate discernible feature spaces. The CheckThat! Lab's CLEF-2020 shared task (Barrón-Cedeno et al., 2020) has garnered the attention of several researchers. Williams et al. (2020) won the task by fine-tuning the RoBERTa (Liu et al., 2019) accentuated by mean pooling and dropout. Nikolov et al. (2020) ranked second with their out-of-the-box RoBERTa vectors supplemented with Twitter meta-data.
+
+Span Identification. Zaidan et al. (2007) introduced the concept of rationales, which highlighted text segments that supported their label's judgment. Trautmann et al. (2020) released AURC-8 dataset with token-level span annotations for the argumentative components of stance along with their corresponding label. Mathew et al. (2021) proposed a quality corpus for explainable hate identification with token-level annotations. The SemEval community has initiated fine-grained span identification concerning other domains of argument mining such as toxic comments (Pavlopoulos et al., 2021) and propaganda techniques (Da San Martino et al., 2020). These shared tasks amassed many solutions constituting transformers (Chhablani et al., 2021), convolutional neural networks (Coope et al., 2020), data augmentation techniques (Rusert, 2021; Plucinski and Klimczak, 2021), and ensemble frameworks (Zhu et al., 2021a; Nguyen et al., 2021). Wuhrl and Klinger (2021) resembled the closest study to ours, wherein they compiled a corpus of around $1.2k$ biomedical tweets with claim phrases.
+
+In summary, existing literature on claims concentrates entirely on sentence-level claim identification and does not investigate on eliciting fine-grained claim spans. In this work, we endeavor to move from coarse-grained claim detection to fine-grained claim span identification. We consolidate a large manually annotated Twitter dataset for claim span identification task and benchmark it with various baselines and a dedicated description-based model.
+
+# 4 Dataset
+
+Over the past few years, several claim detection datasets have been released (Rosenthal and McKeown, 2012; Chakrabarty et al., 2019). However,
+
+| Dataset | Train | Test | Validation |
| Total no. of claims | 6044 | 755 | 756 |
| Avg. length of tweets | 27.40 | 26.93 | 27.29 |
| Avg. length of spans | 10.90 | 10.97 | 10.71 |
| No. of span per tweet | 1.25 | 1.20 | 1.27 |
| No. of single span tweets | 4817 | 629 | 593 |
| No. of multiple span tweets | 1201 | 121 | 161 |
+
+Table 2: Dataset statistics. All the lengths are in tokens.
+
+none of these corpora come with claim-based rationales that quantify a post as a claim. To bridge this gap, we propose CURT (Claim Unit Recognition in Tweets), a large scale Twitter corpus with token-level claim span annotations.
+
+Data Selection. We annotate claim detection Twitter dataset released by Gupta et al. (2021) for our task. However, the guidelines they presented have certain reservations, wherein they do not explicitly account for benedictions, proverbs, warnings, advice, predictions, and indirect questions. As a result, tweets such as 'Dear God, Please put an end to the Coronavirus. Amen' and '@FLOTUS Melania, do you approve of ingesting bleach and shining a bright light in the rectal area as a quick cure for #COVID19? #BeBest' have been mislabeled claims. This prompted us to extend the existing guidelines and introduce a more exclusive and nuanced set of definitions based on claim span identification. We present details of the extended annotation guidelines and guideline development procedure in Appendix (A.1). In total, we annotated 7555 tweets from the Twitter corpus by Gupta et al. (2021) which met our guidelines.
+
+Dataset Statistics and Analysis. We segment CURT into three partitions – training set, validation set, and test set, in the split of 80:10:10. Dataset related statistics are given in Table 2. One important point to note here is that while a claim tweet is typically 27 tokens long, a claim span is only around 10 tokens long. This implies that the claim-ridden tweets have a lot of extraneous information. Arguments can also perhaps comprise several claims that may or may not be related to each other. Around $19\%$ of the claim tweets in our dataset contain multiple claim spans. As a result, in total, we obtain 9458 claim spans from 7555 tweets. We observe that the majority of the tweets contain single claims. Out of 7555 tweets, 6039 include a single claim, demonstrating that the majority of tweets contemplate single assertions at a time.
+
+# 5 Proposed Methodology
+
+In this section, we outline DABERTa and its intricacies. The main aim is to seamlessly coalesce critical domain-specific information into Pre-trained Language Models (PLM). To this end, we introduce Description Infuser Network (DescNet), a plug-and-play adapter module that conditions the LM representations with respect to the handcrafted descriptions. The underlying principle behind this theoretical formalization is to link a claim span to a claim description to guide the model on what to focus on explicitly. As shown in Figure 2, DescNet houses two sub-components, namely, Compositional De-Attention block (CoDA) and Interactive Gating Mechanism (IGM). The particulars of each component are delineated in the following sections.
+
+Claim Descriptions. Before delving into CoDA and IGM, we first examine Claim Descriptions, which are the cornerstone of the proposed model. Claim Descriptions are handcrafted templates that guide the model where to concentrate its focus. The inclusion of claim description encourages the model to focus on the most essential phrases in the input tweet, which may be thought of as guided attention that leads to increased performance. We judiciously curated our claim descriptions in accordance with the annotation guidelines for claims and non-claims offered by Gupta et al. (2021). In Table 3 we list some of the claim descriptions along with the claims that they most align with. It is noteworthy that a claim can align with more than one claim descriptions as well.
+
+Overview of PLMs for Token Classification. To begin with the details of the proposed framework, DABERTa, we present the working of PLMs for the token classification task. PLMs such as BERT (Devlin et al., 2019), DistilBERT (Sanh et al., 2019), and RoBERTa (Liu et al., 2019) are widely used for various downstream NLP tasks owing to their strong contextual language representation capabilities and fine-tuning ease. As the input to these PLMs, each $i^{th}$ input text is first tokenized into a sequence of sub-word embeddings $X_{i} \in \mathbb{R}^{N \times d}$ , where $N$ is the maximum sequence length and $d$ is the feature dimension. Then a positional embedding vector $PE_{pos} \in \mathbb{R}^{N \times d}$ is added to the token embeddings in a pointwise fashion to retain the positional information (Vaswani et al., 2017).
+
+The vector $Z_{i}\in \mathbb{R}^{N\times d}$ , hence obtained, is fed to a stack of transformer encoder blocks. Each
+
+
+Figure 2: A schematic diagram of DABERTa for the claim span identification. $\odot$ represents point-wise multiplication, and $\otimes$ represents matrix multiplication.
+
+| Claim Description | Example |
| Texts in the tweet mentioning statistics, dates or numbers | Another case for more testing for #coronavirus! Blood tests show 14% of people are now immune to coid-19 in one town in Germany https://t.co/MVOq3nc4hn |
| Texts in the tweet that negate a possibly false claim | No! #Bleach won’t cure #COVID19. Disinfectants can’t kill the #coronavirus in your body. In fact, they will hurt you. If you or someone you know has been exposed to bleach, call Poison Control for help (1-800-222-1***). https://t.co/DtIfi77vLz https://t.co/9MxSFOVM0L |
| Texts in the tweet made in sarcasm or humour | @username I think the cure to coronavirus is a 6 pack of corona only. yeah |
| Texts in the tweet containing opinions that have societal implications | @username @username I think it’s a bio weapon made by China so I’m not surprised it has a lot of carriers. |
| Texts in the tweet in the form of conditional statement | if you smoke weed you are immune to coronavirus |
| Texts in the tweet containing a quote from someone | The president said injecting disinfectant into the body can cure the virus. What in the holy hell? And @Lysol issued a statement that people should not ingest Lysol. WTF? #Covid_19 #lysol #DontDrinkLysol |
+
+Table 3: Examples of handcrafted claim descriptions, along with some aligning examples. Claim spans are highlighted in italics.
+
+encoder block is a modular unit consisting of two sub-layers: (i) Multi-Headed Self-Attention, and (ii) Feed-Forward Network. Furthermore, each sub-layer contains a residual connection, followed by dropout and layer normalization. For the task of token classification, the output of the last encoder layer is passed to a CRF layer (Lafferty et al., 2001). This modularity of PLMs enables easy integration of adapter modules in their architecture for making these PLMs task-specific and domain-dependent. We choose RoBERTa (Liu et al., 2019) as our backbone network as it is the best-performing baseline (see Table 4).
+
+Description Infuser Network (DescNet). DescNet is designed to facilitate deep semantic interaction among the input text and claim descriptions, and help underline the key fragments of claims. It consists of precisely engineered components of CoDA and IGM, each devised to augment the pro
+
+cess of claim span identification.
+
+To put formally, consider $D = \{d_{1}, d_{2}, \ldots, d_{m}\}$ as the set of $m$ claim descriptions and $T = \{t_{1}, t_{2}, \ldots, t_{n}\}$ as the corpus of $n$ input texts. The description representations are extracted from pretrained RoBERTa (Liu et al., 2019) and passed through a transformer encoder layer. To begin with, each $i^{th}$ PLM generated vector $Z_{i} \in \mathbb{R}^{N \times d}$ of input text $t_{i}$ interacts with each $j^{th}$ description vector $D_{j} \in \mathbb{R}^{M \times d}$ via the CoDA block. Here the vector $Z_{i}$ forms the query, which is processed against the vector $D_{j}$ acting as the key and value (Equation 1).
+
+$$
+Z _ {i j} ^ {C} = C o D A \left(Z _ {i}, D _ {j}\right) D _ {j} \tag {1}
+$$
+
+All such compositionally manipulated vectors $Z_{ij}^{C}$ , after interacting with each $j^{th}$ description vectors are concatenated and passed through a dropout layer before going through a non-linear transformation for dimensionality reduction (Equation 2). The resultant vector $Z_{i}^{\prime}$ along with the vector $Z_{i}$ is
+
+passed to the IGM module to extract the semantically appropriate features pertinent for fine-grained claim span identification (Equation 3).
+
+$$
+Z _ {i} ^ {\prime} = \operatorname {C o n c a t} \left(Z _ {i 1} ^ {C}, \dots , Z _ {i m} ^ {C}\right) \tag {2}
+$$
+
+$$
+\hat {Z} _ {i} = I G M \left(Z _ {i} ^ {\prime} W, Z _ {i}\right) \tag {3}
+$$
+
+The vector $\hat{Z}_i$ is then passed to a CRF layer.
+
+The traditional narrative on attention mechanism (Bahdanau et al., 2015; Parikh et al., 2016; Seo et al., 2016; Vaswani et al., 2017) is heavily biased on the use of Softmax operator where the attention weights are always bounded between $[0,1]$ . Such a convex weighted addition scheme allows the vectors to only contribute in an additive manner. To counter this bottleneck, Tay et al. (2019) devised a quasi-attention technique that enables learning of additive as well as subtractive attention weights, allowing the input vectors to add to $(+1)$ , not contribute to $(0)$ , and even subtract from $(-1)$ the output vector. They decomposed the original Softmax-based self-attention as pointwise multiplication between two matrices as shown in Equation 4, where $G(\cdot)$ is the negative pointwise $L_{1}$ distance between query $Q$ and key $K$ .
+
+$$
+A _ {q u a s i} = \left(\tanh \left(\frac {Q K ^ {T}}{\sqrt {d _ {k}}}\right) \odot \sigma \left(\frac {G (Q , K)}{\sqrt {d _ {k}}}\right)\right) V \tag {4}
+$$
+
+We adopt this quasi-attention strategy to promote more meaningful interaction between the input text and claim descriptions and generate more precise claim-relevant representations.
+
+Interactive Gating Mechanism (IGM). To further distinguish salient tokens inclusive in claim spans, we posit Interactive Gating Mechanism. To begin with, the vectors $Z_{i}$ and $Z_{i}^{\prime}$ are max pooled to obtain $Z_{ip}, Z_{ip}^{\prime} \in \mathbb{R}^{d}$ . These vectors are passed through a series of gates, the first of them being the conflict gate $C$ , aimed at capturing the semantically conflicting features in $Z_{i}$ and $Z_{i}^{\prime}$ (Equation 6).
+
+$$
+\mu_ {c} = \sigma \left(Z _ {i p} W _ {c 1} + Z _ {i p} ^ {\prime} W _ {c 2} + b _ {c 1}\right) \tag {5}
+$$
+
+$$
+C = \tanh \left(Z _ {i p} \odot \mu_ {c} W _ {c 3} + Z _ {i p} ^ {\prime} \odot \left(1 - \mu_ {c}\right) W _ {c 4} + b _ {c 2}\right) \tag {6}
+$$
+
+The refine gate $R$ , on the other hand, endeavors to capture the semantically similar features between $Z_{ip}$ and $Z_{ip}^{\prime}$ (Equation 8).
+
+$$
+\mu_ {r} = \sigma \left(Z _ {i p} W _ {r 1} + Z _ {i p} ^ {\prime} W _ {r 2} + b _ {r 1}\right) \tag {7}
+$$
+
+$$
+R = \tanh \left(Z _ {i p} \odot \mu_ {r} W _ {r 3} + Z _ {i p} ^ {\prime} \odot \mu_ {r} W _ {r 4} + b _ {r 2}\right) \tag {8}
+$$
+
+To congregate the conflicting and similar semantic representations spawned by the gates $C$ and
+
+$R$ , we employ an adaptive gating scheme to retain maximum differential information from each gate. It is given by Equation 10.
+
+$$
+A = R + \left(1 - \mu_ {r}\right) \odot C \tag {9}
+$$
+
+$$
+\hat {Z} _ {i} = \tanh \left(A W _ {a} + b _ {a}\right) \odot Z _ {i} \tag {10}
+$$
+
+Finally, this vector $\hat{Z}_i$ is passed to a CRF layer for token classification.
+
+# 6 Experiments and Results
+
+Baseline Models. We employ the following baseline systems. $\triangleright$ CNN+CRF: A Convolutional Neural Network (CNN) trained with GloVe (Pennington et al., 2014) and a CRF head on top. $\triangleright$ BiLSTM+CRF (Huang et al., 2015): A sequence labeling model comprising Bidirectional Long Short-Term Memory (BiLSTM) and CRF layer. $\triangleright$ BERT (Devlin et al., 2019): A bidirectional transformer-inspired auto-encoder language model fine-tune for our span identification task. $\triangleright$ DistilBERT (Sanh et al., 2019): A smaller, faster, and lighter version of BERT fine-tune on our dataset for the task at hand. $\triangleright$ SpanBERT (Joshi et al., 2020): An enhanced version of the BERT trained on span prediction objective. $\triangleright$ RoBERTa (Liu et al., 2019): A robustly optimized BERT approach, RoBERTa, is a variant of BERT with improved training methodology. We fine-tune it on our dataset. $\triangleright$ NLRG (Chhablani et al., 2021): A system proposed at SemEval2021 Task 5 on toxic span detection (Pavlopoulos et al., 2021). It is a combination of SpanBERT and RoBERTa where the former model is used for predicting the span start and end, while the latter is used for token classification. $\triangleright$ HITSZ-HLT (Zhu et al., 2021b): The system topped the SemEval-2021 task on toxic span detection. They approached the task as a combination of sequence labeling and span extraction and proposed an ensemble of three BERT-based models.
+
+Evaluation Metrics. In concordance with Pavlopoulos et al. (2021), we evaluate the performance of all the systems, based on token-level precision (P), recall (R), and F1 scores. To further put a lens over how the models fare for different token types, we calculate the micro-level precision, recall, and F1 score for each of the 'B', 'I', and 'O' tokens.3 Lastly, to quantify the number of tokens included in the spans, we also report the Dice Similarity Coefficient (DSC) (Dice, 1945).
+
+| Model Name | F1 | P | R | F1 | Precision | Recall | DSC |
| B | I | O | B | I | O | B | I | 0 |
| CNN+CRF | 0.6635 | 0.6709 | 0.6947 | 0.3877 | 0.6766 | 0.9263 | 0.3952 | 0.6725 | 0.9450 | 0.3953 | 0.7718 | 0.9171 | 0.6964 |
| BiLSTM+CRF | 0.6825 | 0.6928 | 0.7048 | 0.4401 | 0.6717 | 0.9356 | 0.4653 | 0.6703 | 0.9428 | 0.4302 | 0.7459 | 0.9382 | 0.6884 |
| DistilBERT | 0.7645 | 0.7811 | 0.8068 | 0.6677 | 0.8164 | 0.7510 | 0.6560 | 0.7979 | 0.8310 | 0.7227 | 0.8989 | 0.7402 | 0.8277 |
| BERT | 0.7807 | 0.7996 | 0.8154 | 0.6900 | 0.8266 | 0.7699 | 0.6863 | 0.8163 | 0.8403 | 0.7302 | 0.8971 | 0.7634 | 0.8356 |
| SpanBERT | 0.7914 | 0.8093 | 0.8182 | 0.6971 | 0.8299 | 0.7901 | 0.7047 | 0.8384 | 0.8271 | 0.7203 | 0.8724 | 0.8048 | 0.8377 |
| RoBERTa | 0.8020 | 0.8163 | 0.8337 | 0.7221 | 0.8297 | 0.7942 | 0.7165 | 0.8371 | 0.8351 | 0.7624 | 0.8764 | 0.8022 | 0.8399 |
| DistilBERT + CRF | 0.8288 | 0.8581 | 0.8526 | 0.8722 | 0.8148 | 0.7431 | 0.8914 | 0.7852 | 0.8400 | 0.8621 | 0.9181 | 0.7219 | 0.8222 |
| BERT + CRF | 0.8368 | 0.8631 | 0.8556 | 0.8531 | 0.8284 | 0.7666 | 0.8781 | 0.8101 | 0.8375 | 0.8408 | 0.9042 | 0.7597 | 0.8343 |
| SpanBERT + CRF | 0.8390 | 0.8625 | 0.8562 | 0.8507 | 0.8253 | 0.7806 | 0.8742 | 0.8221 | 0.8302 | 0.8394 | 0.8827 | 0.7867 | 0.8316 |
| RoBERTa + CRF | 0.8457 | 0.8706 | 0.8635 | 0.8613 | 0.8340 | 0.7805 | 0.8874 | 0.8301 | 0.8321 | 0.8485 | 0.8972 | 0.7841 | 0.8402 |
| NLRG | 0.7494 | 0.7750 | 0.7832 | 0.6584 | 0.7892 | 0.7398 | 0.6631 | 0.7891 | 0.8119 | 0.6805 | 0.8600 | 0.7486 | 0.8087 |
| HITSZ-HLT | 0.7758 | 0.7966 | 0.8037 | 0.6754 | 0.8201 | 0.7780 | 0.6834 | 0.8230 | 0.8291 | 0.6978 | 0.8743 | 0.7850 | 0.8314 |
| DABERTa | 0.8604 | 0.8814 | 0.8789 | 0.9035 | 0.8354 | 0.7816 | 0.9205 | 0.8242 | 0.8379 | 0.8950 | 0.9044 | 0.7771 | 0.8433 |
| - {IGM} | 0.8539 | 0.8795 | 0.8768 | 0.9121 | 0.8310 | 0.7563 | 0.9258 | 0.8017 | 0.8473 | 0.9051 | 0.9277 | 0.7358 | 0.8401 |
| - {CoDA} + {DPA} | 0.8558 | 0.8788 | 0.8738 | 0.8886 | 0.8319 | 0.7821 | 0.9086 | 0.8184 | 0.8439 | 0.8785 | 0.9032 | 0.7752 | 0.8416 |
+
+Table 4: Experimental results of DABERTa, its variants (last two rows), and baselines. DSC, P, and R denote Dice Similarity Coefficient, Precision, and Recall respectively.
+
+Performance Comparison. We summarize our collated results in Table 4. Evidently, DABERTa outperforms all the baseline systems against majority of the evaluation metrics. We analyze all the systems based on the following questions.
+
+How accurately do the models predict? To gauge how well each model performs for the token classification task, we monitor precision, recall, and F1 scores. As it can be inferred from Table 4, the traditional word embedding-based deep learning models of CNN and BiLSTM give the poorest token classification performance. An appreciable improvement of about $10 - 14\%$ across all three metrics is observed when we move from the classical deep learning architectures to the transformer-based models of DistilBERT, BERT, SpanBERT, and RoBERTa. This underlines the importance of using contextual word embeddings and transformer-based architectures for the task at hand. The addition of the CRF layer further amplifies the performance of these models. SpanBERT also fares better than BERT as it is trained using span prediction objective. We also notice that employing the CRF layer results in a somewhat better balance of precision and recall when compared to using a basic linear layer. The ensemble-based models of NLRG and HITSZ-HLT also give admissible results for our task. Our proposed model, DABERTa, surpasses all the models in terms of the precision, recall, and F1 scores. An improvement of about $1.5\%$ is observed between RoBERTa and DABERTa in terms of these metrics. This justifies the inclusion of claim descriptions that amalgamate domain-specific semantic information into RoBERTa architecture via the deftly crafted adapter module. In summary, we see that
+
+
+Figure 3: A comparative study among DABERTa and baselines. The horizontal bar signifies the ration of number of predicted spans and number of gold spans.
+
+all the models show a good trade-off between precision and recall.
+
+Are the models aggressive or defensive? Observing the precision, recall, and F1 scores for each of the $B'$ , $I'$ , and $O'$ tags, as shown in Table 4, we get an idea of how aggressive or defensive the models are at predicting claim spans. CNN and BiLSTM show considerable resistance in predicting the claim spans, as evidenced by high precision, recall, and F1 scores for the token $O'$ and less for the tokens $B'$ and $I'$ . The BERT-based models show a sizable improvement of about $22\%$ and $15\%$ for predicting tokens $B'$ and $I'$ , respectively, over the traditional deep learning models. The addition of CRF layers further bolsters the predictive power for the token $B'$ . DABERTa offers an improvement of about $4 - 5\%$ over its traditional counterpart for predicting the token $B'$ . Upon close inspection, we observe that the ranges of precision, recall, and F1 scores for predicting the tokens $I'$ and $O'$ vary by not more than $3\%$ . However, the predictive power for the token $B'$ varies vastly by about $25\%$ . Hence, we hypothesize that the inclusion of descriptions makes our model cognizant of the syntactic and semantic constructs of claims.
+
+How the models behave for multiple spans? Figure 3 illustrates how well the models identify
+
+multiple spans. It is observed that the models of CNN and BiLSTM find it challenging to identify multiple spans. The transformer-based models with a linear head tend to predict more claim spans in the tweet than required. This issue is mitigated when the linear head is replaced with a CRF layer. Still, these models can identify roughly only $80\%$ of the time the occurrence of multiple spans. On the other hand, our model, DABERTa, correctly predicts multiple spans almost more than $85\%$ of the time. Moreover, it does not predict more claim spans than required. Thus, the addition of domain-specific claim descriptions appropriately guides DABERTa in identifying the correct occurrence of spans.
+
+Ablation Study. Table 4 also reports the ablation studies. Replacing CoDA with a naïve Dot-Product Attention (DPA), we observe a drop in the performance across almost all the metrics. Amongst all, the performance drop in predicting the token 'B' is the most prominent ( $\sim$ $1.5\%$ across precision, recall, and F1). Thus, we conjecture that the quasiattention mechanism is better able to spot the starting of a claim fragment than DPA. When IGM is removed, the performance for predicting token 'B' slightly improves. However, it leads to a decrease in the predictive power for 'O' token ( $\sim$ $2.5\%$ in F1). Therefore, the combination of CoDA and IGM obtains the most balanced performance.
+
+Hyper-parameter Tuning. We utilize the base version of RoBERTa (Liu et al., 2019) to propose DABERTa. The model is trained end-to-end using the Adam optimizer (Kingma and Ba, 2014), learning rate of $4e - 5$ , and batch size of 32 for 20 epochs with early stopping if the dice score does not improve after 5 epochs. We used the Nvidia Tesla v100 32 GB GPU. The hyper-parameter tuning is done with respect to the validation dataset.
+
+
+Figure 4: Performance of DABERTa when the adapter module is inserted at different layers of RoBERTa.
+
+Figure 4 reflects the effect of integrating the adapter DescNet at different layer of RoBERTa. It is observed that the performance consistently increases as the integration is done at a higher level of RoBERTa layers. This is admissible as studies on probing the PLM layers suggest that different layers encode distinct linguistic properties (Tenney et al., 2019). Furthermore, evidence by Peters et al. (2018) suggests that the lower layers of a language model encode the syntactic information, whereas the higher layers capture the complex semantics. As we strive to employ deep semantic interaction between the PLM representations and the claim descriptions, our results are consistent with their findings.
+
+Error Analysis. In this section, we manually analyze the errors the models are prone to make. Table 5 highlights randomly sampled tweets from our dataset, CURT, along with their gold spans and predictions from DABERTa. In addition, we also consider the predictions from the best-performing baseline, RoBERTa, for a fair comparison. We analyze the errors committed by both the systems and divide them into three different categories: (i) tweets with a single-claim span, (ii) tweets with claim-like premises, and (iii) tweets with claims that can be inferred from the underlying undertone of the tweet but no explicit span can be marked to highlight the claim-specific connotation, e.g., figurative sentences, satire, indirect questions etc. (Note: For simplicity, we refer to such claims as implicit claims.) In the most straightforward situation where the tweets only contain a single claim DABERTa makes more precise predictions than the baseline system as shown in the first example of Table 5. We observe that both the models identify the claim-span correctly; however, RoBERTa identifies some unnecessary spans, which trespasses our objective of equipping the fact-checkers with only relevant information. The second type of error related to spans is the presence of claim-like premises. Claims and premises5 are closely related components of argument mining, and differentiating them is strenuous, even for humans. Example 2 in Table 5, exhibits a post containing claim-premise pair. There are two conclusive claims in the tweet - 'coronavirus was used by the #CCP as a bio weapon' and 'CCP is kicking out black people from hotels even if they don't have COVID'. Even though 'not only to kill people but to encourage racism
+
+ | Model | Tweet |
| 1 | Gold | Gold Truly sobering analysis: US more vulnerable than many countries to #coronavirus owing to combination of high numbers of uninsured, many w/o paid sick leave, and a leadership that has downplayed the challenge while not preparing the country for it. |
| RoBERTa | Gold Truly sobering analysis: US more vulnerable than many countries to #coronavirus owing to combination of high numbers of uninsured, many w/o paid sick leave, and a leadership that has downplayed the challenge while not preparing the country for it. |
| DABERTa | Gold Truly sobering analysis: US more vulnerable than many countries to #coronavirus owing to combination of high numbers of uninsured, many w/o paid sick leave, and a leadership that has downplayed the challenge while not preparing the country for it. |
| 2 | Gold | Whether made on purpose or not #coronavirus was used by the #CCP as a bio weapon, not only to kill people but to encourage racism among their citizens against foreigners. Especially black people, CCP is kicking out black people from hotels even if they dont have covid. |
| RoBERTa | Whether made on purpose or not #coronavirus was used by the #CCP as a bio weapon, not only to kill people but to encourage racism among their citizens against foreigners. Especially black people, CCP is kicking out black people from hotels even if they dont have covid. |
| DABERTa | Whether made on purpose or not #coronavirus was used by the #CCP as a bio weapon, not only to kill people but to encourage racism among their citizens against foreigners. Especially black people, CCP is kicking out black people from hotels even if they dont have covid. |
| 3 | Gold | RT @HealthNews: Can honey, ginger, garlic or turmeric or any other home remedies cure #Covid19? No, here's why. |
| RoBERTa | RT @HealthNews: Can honey, ginger, garlic or turmeric or any other home remedies cure #Covid19? No, here's why. |
| DABERTa | RT @HealthNews: Can honey, ginger, garlic or turmeric or any other home remedies cure #Covid19? No, here's why. |
+
+Table 5: Error analysis of the outputs. Bold text (green) highlights the correct claim span whereas text in italics (red) represents the mistakes committed by our model, DABERTa, and vanilla RoBERTa as baseline.
+
+among their citizens against foreigners' appears to be a claim at first glance, it serves as the premise to support the conclusive part of the arguments brought forward in the tweet. In most cases, we discern that both the systems identify the claim-spans correctly, but they are easily fooled by the premises, hence leaving room for significant improvement in this regard.
+
+Another prominent class of errors is implicit claims. Extracting the claim-spans in implicit claims is arduous. We observe that both the systems strive to understand the linguistic structure of the implicit claims. For instance, in sample 3, the user intends to assert that honey, ginger, garlic, or turmeric do not cure COVID19; however, DABERTa fails to understand the user's intention and yields the wrong span. We perceive similar behavior from the best-performing baseline, RoBERTa, as well. A plausible reason is the skewed nature of the dataset, which is lopsided with a significant bias toward explicit claims. According to our observations, DABERTa outperforms the best-performing baseline system significantly $(\sim 4\%; p < 0.0004)$ . Hence, furnishing us with empirical shreds of evidence that DABERTa can be efficiently used for claim span identification.
+
+# 7 Conclusion
+
+Through this systematic research, we introduced the novel task of Claim Span Identification, which is valuable on various fronts. We conducted an evidence-based document retrieval experiment,
+
+demonstrating that employing claim spans retrieves more relevant evidence than using the entire tweet. Furthermore, as there exists no specialized corpus for claim span identification, we compiled CURT, a large-scale Twitter corpus consisting of around $7.5k$ tweets annotated with token-level claim spans. We showed convincing results using various token classification baselines on our dataset. Moreover, we benchmarked CURT with DABERTa, an adapter-based variant of RoBERTa, that encapsulates critical domain-specific information into the pre-trained model via claim descriptions. Through extensive qualitative, quantitative, and empirical results, we illustrated how DABERTa outperforms the other models on different fronts. Lastly, we also developed an extensive set of annotation guidelines and released them for further research.
+
+# 8 Limitations
+
+Though DABERTa yields the state-of-the-art performance in claim span identification; there are a few cases where it falls short. Even for humans, recognizing claim spans in figurative or metaphorical sentences is arduous; consequently, our suggested model also struggles with them. As a result, our future study will focus on boosting the claim span identification performance, especially for such sentences. Our analysis also bestowed that the high resemblance between claims and premises confuses the model, making it difficult to distinguish between the two. DABERTa shares the said limitation with other baseline systems as well. As a result, this could be another alluring open challenge to work on.
+
+# Acknowledgement
+
+The authors would like to thank the Ramanujan Fellowship, SERB and CAI, IIIT-Delhi for the valuable support.
+
+# References
+
+Ehud Aharoni, Anatoly Polnarov, Tamar Lavee, Daniel Hershcovich, Ran Levy, Rudy Rinott, Dan Gutfreund, and Noam Slonim. 2014. A benchmark dataset for automatic detection of claims and evidence in the context of controversial topics. In Proceedings of the First Workshop on Argumentation Mining, pages 64-68, Baltimore, Maryland. Association for Computational Linguistics.
+Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. 2015. Neural machine translation by jointly learning to align and translate. In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings.
+Alberto Barrón-Cedeno, Tamer Elsayed, Preslav Nakov, Giovanni Da San Martino, Maram Hasanain, Reem Suwaileh, and Fatima Haouari. 2020. Checkthat! at clef 2020: Enabling the automatic identification and verification of claims in social media. In European Conference on Information Retrieval, pages 499-507. Springer, Nature Publishing Group.
+Emily M. Bender, Jonathan T. Morgan, Meghan Oxley, Mark Zachry, Brian Hutchinson, Alex Marin, Bin Zhang, and Mari Ostendorf. 2011. Annotating social acts: Authority claims and alignment moves in Wikipedia talk pages. In Proceedings of the Workshop on Language in Social Media (LSM 2011), pages 48-57, Portland, Oregon. Association for Computational Linguistics.
+Tuhin Chakrabarty, Christopher Hidey, and Kathy McKown. 2019. IMHO fine-tuning improves claim detection. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 558-563, Minneapolis, Minnesota. Association for Computational Linguistics.
+Gunjan Chhablani, Abheesht Sharma, Harshit Pandey, Yash Bhartia, and Shan Suthaharan. 2021. NLRG at SemEval-2021 task 5: Toxic spans detection leveraging BERT-based token classification and span prediction techniques. In Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval2021), pages 233-242, Online. Association for Computational Linguistics.
+Samuel Coope, Tyler Farghly, Daniela Gerz, Ivan Vulic, and Matthew Henderson. 2020. Span-ConveRT: Few-shot span extraction for dialog with pretrained conversational representations. In Proceedings of the 58th
+
+Annual Meeting of the Association for Computational Linguistics, pages 107-121, Online. Association for Computational Linguistics.
+Giovanni Da San Martino, Alberto Barrón-Cedeno, Henning Wachsmuth, Rostislav Petrov, and Preslav Nakov. 2020. SemEval-2020 task 11: Detection of propaganda techniques in news articles. In Proceedings of the Fourteenth Workshop on Semantic Evaluation, pages 1377–1414, Barcelona (online). International Committee for Computational Linguistics.
+Johannes Daxenberger, Steffen Eger, Ivan Habernal, Christian Stab, and Iryna Gurevych. 2017. What is the essence of a claim? cross-domain claim identification. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 2055-2066, Copenhagen, Denmark. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Lee R Dice. 1945. Measures of the amount of ecologic association between species. *Ecology*, 26(3):297-302.
+Emilio Ferrara. 2020. What types of Covid-19 conspiracies are populated by twitter bots? arXiv preprint arXiv:2004.09531.
+Shreya Gupta, Parantak Singh, Megha Sundriyal, Md. Shad Akhtar, and Tanmoy Chakraborty. 2021. LESA: Linguistic encapsulation and semantic amalgamation based generalised claim detection from online content. In Proceedings of the 16th Conference of the European Chapter of the Association for Computational Linguistics: Main Volume, pages 3178-3188, Online. Association for Computational Linguistics.
+Andreas Hanselowski, Hao Zhang, Zile Li, Daniil Sorokin, Benjamin Schiller, Claudia Schulz, and Iryna Gurevych. 2018. UKP-athene: Multi-sentence textual entailment for claim verification. In Proceedings of the First Workshop on Fact Extraction and VERIFICATION (FEVER), pages 103–108, Brussels, Belgium. Association for Computational Linguistics.
+Zhiheng Huang, Wei Xu, and Kai Yu. 2015. Bidirectional lstm-crf models for sequence tagging. arXiv preprint arXiv:1508.01991.
+Israa Jaradat, Pepa Gencheva, Alberto Barrón-Cedeno, Lluis Marquez, and Preslav Nakov. 2018. Claim-Rank: Detecting check-worthy claims in Arabic and English. In Proceedings of the 2018 Conference of the North American Chapter of the Association for
+
+Computational Linguistics: Demonstrations, pages 26-30, New Orleans, Louisiana. Association for Computational Linguistics.
+Mandar Joshi, Danqi Chen, Yinhan Liu, Daniel S. Weld, Luke Zettlemoyer, and Omer Levy. 2020. SpanBERT: Improving pre-training by representing and predicting spans. Transactions of the Association for Computational Linguistics, 8:64-77.
+Diederik P Kingma and Jimmy Ba. 2014. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980.
+Klaus Krippendorff, Yann Mathet, Stephane Bouvry, and Antoine Widlocher. 2016. On the reliability of unitizing textual continua: Further developments. Quality & Quantity, 50(6):2347-2364.
+John D. Lafferty, Andrew McCallum, and Fernando C. N. Pereira. 2001. Conditional random fields: Probabilistic models for segmenting and labeling sequence data. In Proceedings of the Eighteenth International Conference on Machine Learning, ICML '01, page 282-289, San Francisco, CA, USA. Morgan Kaufmann Publishers Inc.
+Ran Levy, Yonatan Bilu, Daniel Hershcovich, Ehud Aharoni, and Noam Slonim. 2014. Context dependent claim detection. In Proceedings of COLING 2014, the 25th International Conference on Computational Linguistics: Technical Papers, pages 1489-1500, Dublin, Ireland. Dublin City University and Association for Computational Linguistics.
+Marco Lippi and Paolo Torroni. 2015. Context-independent claim detection for argument mining. In Proceedings of the 24th International Conference on Artificial Intelligence, IJCAI'15, page 185-191. AAAI Press.
+Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. Roberta: A robustly optimized bert pretraining approach. arXiv preprint arXiv:1907.11692.
+Josh Margolin. 2020. Fbi warns of potential surge in hate crimes against asian americans amid coronavirus. ABC News, 27.
+Binny Mathew, Punyajoy Saha, Seid Muhie Yimam, Chris Biemann, Pawan Goyal, and Animesh Mukherjee. 2021. Hatexplain: A benchmark dataset for explainable hate speech detection. Proceedings of the AAAI Conference on Artificial Intelligence, 35(17):14867-14875.
+Salman Bin Naeem and Rubina Bhatti. 2020. The COVID-19 'infodemic': a new front for information professionals. *Health information and libraries journal*, 37(3):233-239.
+
+Viet Anh Nguyen, Tam Minh Nguyen, Huy Quang Dao, and Quang Huu Pham. 2021. S-NLP at SemEval 2021 task 5: An analysis of dual networks for sequence tagging. In Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval 2021), pages 888-897, Online. Association for Computational Linguistics.
+Alex Nikolov, Giovanni Da San Martino, Ivan Koychev, and Preslav Nakov. 2020. Team alex at clef check—that! 2020: Identifying check-worthy tweets with transformer models. arXiv:2009.02931.
+Cathal O'Connor and Michelle Murphy. 2020. Going viral: doctors must tackle fake news in the COVID-19 pandemic. BMJ, 369.
+Ankur Parikh, Oscar Tackström, Dipanjan Das, and Jakob Uszkoreit. 2016. A decomposable attention model for natural language inference. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 2249-2255, Austin, Texas. Association for Computational Linguistics.
+John Pavlopoulos, Jeffrey Sorensen, Léo Laugier, and Ion Androutsopoulos. 2021. SemEval-2021 task 5: Toxic spans detection. In Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval-2021), pages 59-69, Online. Association for Computational Linguistics.
+Jeffrey Pennington, Richard Socher, and Christopher Manning. 2014. GloVe: Global vectors for word representation. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 1532-1543, Doha, Qatar. Association for Computational Linguistics.
+Matthew E. Peters, Mark Neumann, Luke Zettlemoyer, and Wen-tau Yih. 2018. Dissecting contextual word embeddings: Architecture and representation. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 1499-1509, Brussels, Belgium. Association for Computational Linguistics.
+Kamil Pluciński and Hanna Klimczak. 2021. GHOST at SemEval-2021 task 5: Is explanation all you need? In Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval-2021), pages 852-859, Online. Association for Computational Linguistics.
+Lance A Ramshaw and Mitchell P Marcus. 1999. Text chunking using transformation-based learning. In Natural language processing using very large corpora, pages 157-176. Springer.
+Stephen E Robertson, Steve Walker, Susan Jones, Micheline M Hancock-Beaulieu, Mike Gatford, et al. 1995. Okapi at trec-3. Nist Special Publication Sp, 109:109.
+Sara Rosenthal and Kathleen McKeown. 2012. Detecting opinionated claims in online discussions. In Proceedings of the 2012 IEEE Sixth International
+
+Conference on Semantic Computing, ICSC '12, page 30-37, USA. IEEE Computer Society.
+Jonathan Rusert. 2021. NLP_UIOWA at Semeval-2021 task 5: Transferring toxic sets to tag toxic spans. In Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval-2021), pages 881-887, Online. Association for Computational Linguistics.
+Victor Sanh, Lysandre Debut, Julien Chaumont, and Thomas Wolf. 2019. Distilbert, a distilled version of bert: smaller, faster, cheaper and lighter. arXiv preprint arXiv:1910.01108.
+Minjoon Seo, Aniruddha Kembhavi, Ali Farhadi, and Hannaneh Hajishirzi. 2016. Bidirectional attention flow for machine comprehension. arXiv preprint arXiv:1611.01603.
+Amir Soleimani, Christof Monz, and Marcel Worring. 2020. Bert for evidence retrieval and claim verification. Advances in Information Retrieval, 12036:359.
+Christian Stab and Iryna Gurevych. 2017. Parsing argumentation structures in persuasive essays. Computational Linguistics, 43(3):619-659.
+Megha Sundriyal, Parantak Singh, Md Shad Akhtar, Shubhashis Sengupta, and Tanmoy Chakraborty. 2021. Desyr: Definition and syntactic representation based claim detection on the web. arXiv preprint arXiv:2108.08759.
+Yi Tay, Anh Tuan Luu, Aston Zhang, Shuohang Wang, and Siu Cheung Hui. 2019. Compositional de-attention networks. In Advances in Neural Information Processing Systems, volume 32. Curran Associates, Inc.
+Ian Tenney, Dipanjan Das, and Ellie Pavlick. 2019. BERT rediscovers the classical NLP pipeline. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4593-4601, Florence, Italy. Association for Computational Linguistics.
+Stephen E Toulmin. 2003. The uses of argument. Cambridge university press.
+Dietrich Trautmann, Johannes Daxenberger, Christian Stab, Hinrich Schütze, and Iryna Gurevych. 2020. Fine-grained argument unit recognition and classification. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 9048-9056.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems, volume 30. Curran Associates, Inc.
+Lucy Lu Wang, Kyle Lo, Yoganand Chandrasekhar, Russell Reas, Jiangjiang Yang, Doug Burdick, Darrin Eide, Kathryn Funk, Yannis Katsis, Rodney Michael Kinney, Yunyao Li, Ziyang Liu, William Merrill,
+
+Paul Mooney, Dewey A. Murdick, Devvret Rishi, Jerry Sheehan, Zhihong Shen, Brandon Stilson, Alex D. Wade, Kuansan Wang, Nancy Xin Ru Wang, Christopher Wilhelm, Boya Xie, Douglas M. Raymond, Daniel S. Weld, Oren Etzioni, and Sebastian Kohlmeier. 2020. CORD-19: The COVID-19 open research dataset. In Proceedings of the 1st Workshop on NLP for COVID-19 at ACL 2020, Online. Association for Computational Linguistics.
+Evan Williams, Paul Rodrigues, and Valerie Novak. 2020. Accenture at checkthat! 2020: If you say so: Post-hoc fact-checking of claims using transformer-based models. arXiv: 2009.02431.
+Dustin Wright and Isabelle Augenstein. 2020. Claim check-worthiness detection as positive unlabelled learning. In *Findings of the Association for Computational Linguistics: EMNLP* 2020, pages 476-488, Online. Association for Computational Linguistics.
+Amelie Wuhrl and Roman Klinger. 2021. Claim detection in biomedical Twitter posts. In Proceedings of the 20th Workshop on Biomedical Language Processing, pages 131-142, Online. Association for Computational Linguistics.
+Omar Zaidan, Jason Eisner, and Christine Piatko. 2007. Using "annotator rationales" to improve machine learning for text categorization. In Human Language Technologies 2007: The Conference of the North American Chapter of the Association for Computational Linguistics; Proceedings of the Main Conference, pages 260-267, Rochester, New York. Association for Computational Linguistics.
+Shi Zhi, Yicheng Sun, Jiayi Liu, Chao Zhang, and Jiawei Han. 2017. Claimverif: A real-time claim verification system using the web and fact databases. In Proceedings of the 2017 ACM on Conference on Information and Knowledge Management, CIKM '17, page 2555-2558, New York, NY, USA. Association for Computing Machinery.
+Qinglin Zhu, Zijie Lin, Yice Zhang, Jingyi Sun, Xiang Li, Qihui Lin, Yixue Dang, and Ruifeng Xu. 2021a. HITSZ-HLT at SemEval-2021 task 5: Ensemble sequence labeling and span boundary detection for toxic span detection. In Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval-2021), pages 521-526, Online. Association for Computational Linguistics.
+Qinglin Zhu, Zijie Lin, Yice Zhang, Jingyi Sun, Xiang Li, Qihui Lin, Yixue Dang, and Ruifeng Xu. 2021b. HITSZ-HLT at SemEval-2021 task 5: Ensemble sequence labeling and span boundary detection for toxic span detection. In Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval-2021), pages 521-526, Online. Association for Computational Linguistics.
+Caleb Ziems, Bing He, Sandeep Soni, and Srijan Kumar. 2020. Racism is a virus: Anti-asian hate and counter-hate in social media during the COVID-19 crisis. arXiv preprint arXiv:2005.12423.
+
+# A Appendix
+
+# A.1 Annotations
+
+# A.1.1 Guideline Development
+
+While different frameworks and models of argumentation range in intricacy and claim conceptualization, the claim element is colloquially perceived as a principal component of an argument. Following Stab and Gurevych (2017), we define the claim as 'the argumentative component in which the speaker or writer conveys the central, contentious conclusion of their argument'. Aharoni et al. (2014) proposed a framework in which an argument is often divided into two parts: claim and premise. The premise, which is another crucial component of an argument, encompasses all shreds of evidence obliged to either corroborate or refute the claim. We confine our corpus to claim components only. However, claims and premises are usually indistinguishable and frequently blend together. As a result, distinguishing them can be challenging, especially when authors use claim-like statements as a premise.
+
+Due to the highly subjective nature of claims, it is imperative to devise structured annotation guidelines to annotate a new dataset for the claim span identification task. Therefore, after rigorous analysis and discussion, we established an initial set of annotation guidelines. To acclimate better with the dataset, we progressed through iterations of improvements. In every iteration, 100 random tweets were annotated by three annotators following the initial set of annotation guidelines. The annotators resolved the ambiguous cases mutually. In successive iterations, we further addressed the unsettled tweets that necessitated clarifications in the annotation guidelines. We reconsidered all prior annotations for every change in the guideline to ensure that the annotations emulated the most advanced version of the annotation guidelines. The final sprint of pilot annotation included annotating another set of randomly chosen 100 tweets with the final guidelines. Following Trautmann et al. (2020), we calculated the inter-annotator agreement using the $\alpha_{u}$ agreement measure (Krippendorff et al., 2016). We computed the mean pairwise value per post, where each token can be being classified into two classes, claim, and non-claim. We obtained a more than satisfactory agreement score of 0.87.
+
+Finally, the entire Twitter dataset was annotated by the same annotators that carried out the prefatory pilot annotations.
+
+# A.1.2 General Instructions
+
+- A claim is a statement that says you strongly believe that something is true. The action of showing, using or stating something strongly.
+- We use tweets that are annotated with a binary label using LESA guidelines (Gupta et al., 2021), which indicates whether a tweet is a claim or not.
+- The claim span is that part of a sentence that contains the semantic representation of the claim. Example: @realDonaldTrump A lot of people are saying cocaine cures COVID-19. Claim span: cocaine cures COVID-19.
+- Since our primary goal is to tackle misinformation in OSM, we majorly focus on claims that have some social impact.
+
+# A.1.3 Guidelines and Examples
+
+- In the case of facts, we annotate the fact/ span that may not be known by everyone, for example, scientific facts or legal (law) facts, and doesn't involve any commonsense. However, we do not include universal facts in the claim span.
+
+Example 1: "Water is colorless" is a universally known fact and hence should not be marked as claim span.
+
+Example 2: "Virus always mutate" is a scientific fact that may not be known by everyone. Hence we will annotate this fact as a claim.
+
+- An assertion about future eventualities/predictions will not be included in the claim span. Prediction is an extrapolation based on an assertion and is associated with a confidence level that can never be greater than or equal to $100\%$ . Thus, we will not consider predictions as a part of the claim span.
+
+Example: @realDonaldTrump Uh no actually The virus will never go away Scientists will develop a vaccine for it that should be ready by next June which will allow nearly everyone to be immune to #CoronaVirus This really isn't hard to understand even for a very stable genius.
+
+- A proverb is a simple, concrete, traditional saying that expresses a perceived truth based on common sense or experience which contains wisdom,
+
+truth, morals, and traditional views in a metaphorical, fixed, and memorizable form. The proverbs are not facts. The elements of proverbs should be annotated as claim span.
+
+Example: "Prevention is better than cure" is not a claim.
+
+- If a claim contains statistics or dates, they should be included in the span. But not all numbers are important.
+
+Example 1: "@FernandoSVZLA @AP So far 50 people outside China have it with no deaths. If China was hiding information and it was more lethal, we would see that fairly quickly". Here the claim span is [ 50 people outside China have it with no deaths]
+
+Example 2: “57 round trip to LA thanks coronavirus”. The number is not important here.
+
+- In case there are multiple conclusive independent claims in one tweet, we annotate each one of them separately.
+
+Example: "5 million left Wuhan before the lockdown. If they were really interested in knowing, they'd be testing at least 1 in 100 cases of all viral pneumonia. They're limiting who's being tested so they aren't accused of lying. Oh, and they might be asked to actually do something." Claim span would consist of: [1] "5 million left Wuhan before the lockdown" and [2] "They're limiting who's being tested so they aren't accused of lying"
+
+- Tweets that negate a possibly false claim are also considered to be claims.
+
+Example: "disinfectants are not a cure for coronavirus".
+
+- Tweets 'reporting' something to be true or an instance to have happened or will happen are claims.
+
+- In cases of claims made in the form of a conditional sentence, the premise/context would be included in the span.
+
+Examples: if you've been in the McDonald's play place you're immune to the coronavirus.
+
+- For claims containing humor/sarcasm, only the humorous phrase will be considered as a claim span if it has some social impact. For satire, the complete sentence will be considered.
+
+Example: @TheRickWilson Drinking bleach and/or injecting Disinfectant will cure COVID19.
+
+And cancer, heart disease, OCD, schizophrenia and AIDS. And life. #Covid19 #COVID Claim: Drinking bleach and/or injecting Disinfectant will cure COVID19. And cancer, heart disease, OCD, schizophrenia and AIDS. And life.
+
+- Personal experience will only be part of the claim phrase if they are opinions with societal impacts/implications.
+
+Example: Story about how #HydroxyChloroquine likely help people recover from #Coronavirus. IMO, it was never touted as the cure but as option for treatment doctors should consider and it appears to work in some cases....39 in one place. https://t.co/2hhi6aSVrY
+
+Claim: [it was never touted as the cure but as option for treatment doctors should consider and it appears to work in some cases....39 in one place.]
+
+- A claim can be a sub-part of a question, only if it is not a direct question.
+
+Example: @FLOTUS Melania, do you approve of ingesting bleach and shining a bright light in the rectal area as a quick cure for #COVID19 ? #BeBest"
+
+Claim: [ingesting bleach and shining a bright light in the rectal area as a quick cure for #COVID19]
+
+- Ground/Reasoning to justify a claim will not be a part of the claim phrase.
+
+Example: Covid-19 vaccine development and deployment in China, when available, will be made a global public good, which will be China's contribution to ensuring vaccine accessibility and affordability in developing countries
+
+Claim phrase: [Covid-19 vaccine development and deployment in China, when available, will be made a global public good]
+
+- Mocking/attacking a group or individual is not a part of the claim phrase.
+
+Example: Because #coronavirus has tremendous chances of getting cured but your anti-national agenda is worse than death
+
+Claim: [coronavirus has tremendous chances of getting cured]
+
+- Claim phrases do not include the predicate part that does not contribute to it being a claim.
+
+Example: I firmly believe that [if they found a way to bottle the @andersoncooper giggle, it would cure the corona virus]
+
+# A.2 Data Preprocessing
+
+We employ $NLTK^8$ tockenize the tweets. Each token in the tweet is BIO (Begin-Inside-Outside) encoded to generate the labels (Ramshaw and Marcus, 1999). Tag 'B' indicates that the token is at the start of a span, tag 'T' indicates that the token is within the span, while tag 'O' denotes that the token is outside the span. As RoBERTa tokenizes each word into subwords (Liu et al., 2019), each subword is given the BIO tag as per their parent word. We eliminate tokens made of non-ASCII and special characters, as well as remove the URLs provided in the tweets. Finally, we split hashtag terms by underscore delimiter and over non-consecutive uppercase character. For instance, #WuhanLab splits into 'Wuhan' and 'Lab'.
\ No newline at end of file
diff --git a/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/images.zip b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..67b9b53a4dd1415baa404472b638100108fd3d71
--- /dev/null
+++ b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0b95c118a7edbd177cefc6bd3b01a46cea6d2f790f10b211ad7669a66bef05e2
+size 643186
diff --git a/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/layout.json b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..c18079f8e9e18fadfe82790eb1f85b2f9800cf82
--- /dev/null
+++ b/empoweringthefactcheckersautomaticidentificationofclaimspansontwitter/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:5d5822be705879b34fb9ff8bc9186df1ef25add2f2c1345c0a48ca338e39c129
+size 463514
diff --git a/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_content_list.json b/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..301cb05767b223169837e26b896fe67351d4fcd6
--- /dev/null
+++ b/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fc8938305dc3e72bc37170b1d35f55fedde9ed0ccb36f0c04d9190efe85e0738
+size 98995
diff --git a/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_model.json b/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..e0a75ecf7ebc3abf9732e0b994a9da4dcd8c2a9d
--- /dev/null
+++ b/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:63fe3a1cecd29c4242a014758cd4bdf6a294e955ea99c112ebd1e17f5897e8fc
+size 113566
diff --git a/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_origin.pdf b/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..06a390dbbd335db56091e69aceb186a5d038cbf2
--- /dev/null
+++ b/endtoendneuraldiscoursedeixisresolutionindialogue/5fcf3643-676e-4b6a-b677-fe96165bedb2_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e2f4b3083e07ee703b228fd3fe928b351b15ff8ed33adb7e4fa73a223e13be41
+size 337168
diff --git a/endtoendneuraldiscoursedeixisresolutionindialogue/full.md b/endtoendneuraldiscoursedeixisresolutionindialogue/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..bd1419cc52b29f356706c82a5f21a0e2805b343d
--- /dev/null
+++ b/endtoendneuraldiscoursedeixisresolutionindialogue/full.md
@@ -0,0 +1,383 @@
+# End-to-End Neural Discourse Deixis Resolution in Dialogue
+
+Shengjie Li and Vincent Ng
+
+Human Language Technology Research Institute
+
+University of Texas at Dallas
+
+Richardson, TX 75083-0688
+
+{sx1180006,vince}@hlt.utdallas.edu
+
+# Abstract
+
+We adapt Lee et al.'s (2018) span-based entity coreference model to the task of end-to-end discourse deixis resolution in dialogue, specifically by proposing extensions to their model that exploit task-specific characteristics. The resulting model, dd-utt, achieves state-of-the-art results on the four datasets in the CODICRAC 2021 shared task.
+
+# 1 Introduction
+
+Discourse deixis (DD) resolution, also known as abstract anaphora resolution, is an under-investigated task that involves resolving a deictic anaphor to its antecedent. A *deixis* is a reference to a discourse entity such as a proposition, a description, an event, or a speech act (Webber, 1991). DD resolution is arguably more challenging than the extensively-investigated entity coreference resolution task. Recall that in entity coreference, the goal is to cluster the entity mentions in narrative text or dialogue, which are composed of pronouns, names, and nominals, so that the mentions in each cluster refer to the same real-world entity. Lexical overlap is a strong indicator of entity coreference, both among names (e.g., “President Biden”, “Joe Biden”) and in the resolution of nominals (e.g., linking “the president” to “President Biden”). DD resolution, on the other hand, can be viewed as a generalized case of event coreference involving the clustering of deictic anaphors, which can be pronouns or nominals, and clauses, such that the mentions in each cluster refer to the same real-world proposition/event/speech act, etc. The first example in Figure 1 is an example of DD resolution in which the deictic anaphor “the move” refers to Salomon’s act of issuing warrants on shares described in the preceding sentence. DD resolution is potentially more challenging than entity coreference resolution because (1) DD resolution involves understanding clause semantics since antecedents are clauses, and clause semantics
+
+Salomon Brothers International Ltd. announced it will issue warrants on shares of Hong Kong Telecommunications Ltd. The move closely follows a similar offer by Salomon of warrants for shares of Hongkong & Shanghai Banking Corp.
+
+A: Would you donate to Save the Children?
+
+B: Yes, I will do $10 to both.
+
+B: I am of a tight budget, but I do make room for good causes.
+
+A: Thank you very much.
+
+A: The children will appreciate it.
+
+Figure 1: Examples of discourse deixis resolution. In each example, the deictic anaphor is italicized and the antecedent is boldfaced.
+
+are arguably harder to encode than noun phrase semantics; and (2) string matching plays little role in DD resolution, unlike in entity coreference.
+
+In this paper, we focus on end-to-end DD resolution in dialogue. The second example in Figure 1 shows a dialogue between A and B in which the deictic anaphor "it" refers to the utterance by B in which s/he said s/he would donate $10. While the deictic anaphors in dialogue are also composed of pronouns and nominals, the proportion of pronominal deictic anaphors in dialogue is much higher than that in narrative text. For instance, while 76% of the deictic anaphors in two text corpora (ARRAU RST and GNOME) are pronominal, the corresponding percentage rises to 93% when estimated based on seven dialogue corpora (TRAINS91, TRAINS93, PEAR, and the four CODI-CRAC 2021 development sets). In fact, the three pronouns "that", "this", and "it" alone comprise 89% of the deictic anaphors in these dialogue corpora. The higher proportion of pronominal deictic anaphors potentially makes DD resolution in dialogue more challenging than those in text: since a pronoun is semantically empty, the successful resolution of a pronominal deictic anaphor depends entirely on proper understanding of its context. In addition, it also makes DD recognition more challenging in dialogue. For instance, while the head of a non-pronominal phrase can often be exploited to determine whether it is a deictic anaphor (e.g., "the
+
+man” cannot be a deictic anaphor, but “the move” can), such cues are absent in pronouns.
+
+Since DD resolution can be cast as a generalized case of event coreference, a natural question is: how successful would a state-of-the-art entity coreference model be when applied to DD resolution? Recently, Kobayashi et al. (2021) have applied Xu and Choi's (2020) re-implementation of Lee et al.'s span-based entity coreference model to resolve the deictic anaphors in the DD track of the CODI-CRAC 2021 shared task after augmenting it with a type prediction model (see Section 4). Not only did they achieve the highest score on each dataset, but they beat the second-best system (Anikina et al., 2021), which is a non-span-based neural approach combined with hand-crafted rules, by a large margin. These results suggest that a span-based approach to DD resolution holds promise.
+
+Our contributions in this paper are three-fold. First, we investigate whether task-specific observations can be exploited to extend a span-based model originally developed for entity coreference to improve its performance for end-to-end DD resolution in dialogue. Second, our extensions are effective in improving model performance, allowing our model to achieve state-of-the-art results on the CODI-CRAC 2021 shared task datasets. Finally, we present an empirical analysis of our model, which, to our knowledge, is the first analysis of a state-of-the-art span-based DD resolver.
+
+# 2 Related Work
+
+Broadly, existing approaches to DD resolution can be divided into three categories, as described below.
+
+Rule-based approaches. Early systems that resolve deictic expressions are rule-based (Eckert and Strube, 2000; Byron, 2002; Navarretta, 2000). Specifically, they use predefined rules to extract anaphoric mentions, and select antecedent for each extracted anaphor based on the dialogue act types of each candidate antecedent.
+
+Non-neural learning-based approaches. Early non-neural learning-based approaches to DD resolution use hand-crafted feature vectors to represent mentions (Strube and Müller, 2003; Müller, 2008). A classifier is then trained to determine whether a pair of mentions is a valid antecedent-anaphor pair.
+
+Deep learning-based approaches. Deep learning has been applied to DD resolution. For instance, Marasović et al. (2017) and Anikina et al. (2021) use a Siamese neural network, which takes
+
+as input the embeddings of two sentences, one containing a deictic anaphor and the other a candidate antecedent, to score each candidate antecedent and subsequently rank the candidate antecedents based on these scores. In addition, motivated by the recent successes of Transformer-based approaches to entity coreference (e.g., Kantor and Globerson (2019)), Kobayashi et al. (2021) have recently proposed a Transformer-based approach to DD resolution, which is an end-to-end coreference system based on SpanBERT (Joshi et al., 2019, 2020). Their model jointly learns mention extraction and DD resolution and has achieved state-of-the-art results in the CODI-CRAC 2021 shared task.
+
+# 3 Corpora
+
+We use the DD-annotated corpora provided as part of the CODI-CRAC 2021 shared task. For training, we use the official training corpus from the shared task (Khosla et al., 2021), ARRAU (Poesio and Artstein, 2008), which consists of three conversational sub-corpora (TRAINS-93, TRAINS-91, PEAR) and two non-dialogue sub-corpora (GNOME, RST). For validation and evaluation, we use the official development sets and test sets from the shared task. The shared task corpus is composed of four well-known conversational datasets: AMI (McCowan et al., 2005), LIGHT (Urbanek et al., 2019), Persuasion (Wang et al., 2019), and Switchboard (Godfrey et al., 1992). Statistics on these corpora are provided in Table 1.
+
+# 4 Baseline Systems
+
+We employ three baseline systems.
+
+The first baseline, coref-hoi, is Xu and Choi's (2020) re-implementation of Lee et al.'s (2018) widely-used end-to-end entity coreference model. The model ranks all text spans of up to a predefined length based on how likely they correspond to entity mentions. For each top-ranked span $x$ , the model learns a distribution $P(y)$ over its antecedents $y \in \mathcal{V}(x)$ , where $\mathcal{V}(x)$ includes a dummy antecedent $\epsilon$ and every preceding span:
+
+$$
+P (y) = \frac {e ^ {s (x , y)}}{\sum_ {y ^ {\prime} \in \mathcal {Y} (x)} e ^ {s (x , y ^ {\prime})}}
+$$
+
+where $s(x,y)$ is a pairwise score that incorporates two types of scores: (1) $s_m(\cdot)$ , which indicates how likely a span is a mention, and (2) $s_c(\cdot)$ and $s_a(\cdot)$ , which indicate how likely two spans refer
+
+ | | Total #docs | Total #sents | Total #turns | Avg. #sents | Avg. #toks per sent | Avg. #turns | Avg. #ana | Avg. #ante | Avg. #speakers per doc |
| ARRAU | train | 552 | 22406 | - | 40.6 | 15.5 | - | 2.9 | 4.8 | - |
| LIGHT | dev | 20 | 908 | 280 | 45.4 | 12.7 | 14.0 | 3.1 | 4.2 | 2.0 |
| test | 21 | 923 | 294 | 44.0 | 12.8 | 14.0 | 3.8 | 4.6 | 2.0 |
| AMI | dev | 7 | 4139 | 2828 | 591.3 | 8.2 | 404.0 | 32.9 | 42.0 | 4.0 |
| test | 3 | 1967 | 1463 | 655.7 | 9.3 | 487.7 | 39.3 | 47.3 | 4.0 |
| Pers. | dev | 21 | 812 | 431 | 38.7 | 11.3 | 20.5 | 4.5 | 4.5 | 2.0 |
| test | 28 | 1139 | 569 | 40.7 | 11.1 | 20.3 | 4.4 | 4.8 | 2.0 |
| Swbd. | dev | 11 | 1342 | 715 | 122.0 | 11.2 | 65.0 | 11.5 | 15.9 | 2.0 |
| test | 22 | 3652 | 1996 | 166.0 | 9.6 | 90.7 | 12.0 | 14.7 | 2.0 |
+
+Table 1: Statistics on the datasets.
+
+to the same entity $^1$ ( $s_a(x, \epsilon) = 0$ for dummy antecedents):
+
+$$
+s (x, y) = s _ {m} (x) + s _ {m} (y) + s _ {c} (x, y) + s _ {a} (x, y) \tag {1}
+$$
+
+$$
+s _ {m} (x) = \operatorname {F F N N} _ {m} \left(g _ {x}\right) \tag {2}
+$$
+
+$$
+s _ {c} (x, y) = g _ {x} ^ {\top} W _ {c} g _ {y} \tag {3}
+$$
+
+$$
+s _ {a} (x, y) = \operatorname {F F N N} _ {c} \left(g _ {x}, g _ {y}, g _ {x} \circ g _ {y}, \phi (x, y)\right) \tag {4}
+$$
+
+where $g_{x}$ and $g_{y}$ are the vector representations of $x$ and $y$ , $W_{c}$ is a learned weight matrix for bilinear scoring, $\mathrm{FFNN}(\cdot)$ is a feedforward neural network, and $\phi(\cdot)$ encodes features. Two features are used, one encoding speaker information and the other the segment distance between two spans.
+
+The second baseline, UTD_NLP $^2$ , is the top-performing system in the DD track of the CODICRAC 2021 shared task (Kobayashi et al., 2021). It extends coref-hoi with a set of modifications. Two of the most important modifications are: (1) the addition of a sentence distance feature to $\phi(\cdot)$ , and (2) the incorporation into coref-hoi a type prediction model, which predicts the type of a span. The possible types of a span $i$ are: ANTECEDENT (if $i$ corresponds to an antecedent), ANAPHOR (if $i$ corresponds to an anaphor), and NULL (if it is neither an antecedent nor an anaphor). The types predicted by the model are then used by coref-hoi as follows: only spans predicted as ANAPHOR can be resolved, and they can only be resolved to spans predicted as ANTECEDENT. Details of how the type prediction model is trained can be found in Kobayashi et al. (2021).
+
+The third baseline, coref-hoi-utt, is essentially the first baseline except that we restrict the candidate antecedents to be utterances. This restriction is motivated by the observation that the
+
+antecedents of the deictic anaphors in the CODI-CRAC 2021 datasets are all utterances. To see what an utterance is, consider again the second example in Figure 1. Each line in this dialogue is an utterance. As can be seen, an utterance roughly corresponds to a sentence, although it can also be a text fragment or simply an interjection (e.g., "uhhh"). While by definition the antecedent of a deictic anaphor can be any clause, the human annotators of the DD track of the CODI-CRAC 2021 shared task decided to restrict the unit of annotation to utterances because (1) based on previous experience it was difficult to achieve high inter-annotator agreement when clauses are used as the annotation unit (Poesio and Artstein, 2008); and (2) unlike the sentences in narrative text, which can be composed of multiple clauses and therefore can be long, the utterances in these datasets are relatively short and can reliably be used as annotation units. From a modeling perspective, restricting candidate antecedents also has advantages. First, it substantially reduces the number of candidate antecedents and therefore memory usage, allowing our full model to fit into memory. Second, it allows us to focus on resolution rather than recognition of deictic anaphors, as the recognition of clausal antecedents remains a challenging task, especially since existing datasets for DD resolution are relatively small compared to those available for entity coreference (e.g., OntoNotes (Hovy et al., 2006)).
+
+# 5 Model
+
+Next, we describe our resolver, dd-utt, which augments coref-hoi-utt with 10 extensions.
+
+E1. Modeling recency. Unlike in entity coreference, where two coreferent names (e.g., "Joe Biden", "President Biden") can be far apart from
+
+each other in the corresponding document (because names are non-anaphoric), the distance between a deictic anaphor and its antecedent is comparatively smaller. To model recency, we restrict the set of candidate antecedents of an anaphor to be the utterance containing the anaphor as well as the preceding 10 utterances, the choice of which is based on our observation of the development data, where the 10 closest utterances already cover $96 - 99\%$ of the antecedent-anaphor pairs.
+
+E2. Modeling distance. While the previous extension allows us to restrict our attention to candidate antecedents that are close to the anaphor, it does not model the fact that the likelihood of being the correct antecedent tends to increase as its distance from the anaphor decreases. To model this relationship, we subtract the term $\gamma_{1}Dist(x,y)$ from $s(x,y)$ (see Equation (1)), where $Dist(x,y)$ is the utterance distance between anaphor $x$ and candidate antecedent $y$ and $\gamma_{1}$ is a tunable parameter that controls the importance of utterance distance in the resolution process. Since $s(x,y)$ is used to rank candidate antecedents, modeling utterance distance by updating $s(x,y)$ will allow distance to have a direct impact on DD resolution.
+
+E3. Modeling candidate antecedent length. Some utterances are pragmatic in nature and do not convey any important information. Therefore, they cannot serve as antecedents of deictic anaphors. Examples include "Umm", "Ahhh... okay", "that's right", and "I agree". Ideally, the model can identify such utterances and prevent them from being selected as antecedents. We hypothesize that we could help the model by modeling such utterances. To do so, we observe that such utterances tend to be short and model them by penalizing shorter utterances. Specifically, we subtract the term $\gamma_{2}\frac{1}{Length(y)}$ from $s(x,y)$ , where $Length(y)$ is the number of words in candidate antecedent $y$ and $\gamma_{2}$ is a tunable parameter that controls the importance of candidate antecedent length in resolution.
+
+E4. Extracting candidate anaphors. As mentioned before, the deictic anaphors in dialogue are largely composed of pronouns. Specifically, in our development sets, the three pronouns "that", "this", and 'it' alone account for $74 - 88\%$ of the anaphors. Consequently, we extract candidate deictic anaphors as follows: instead of allowing each span of length $n$ or less to be a candidate anaphor, we only allow a span to be a candidate anaphor if
+
+its underlying word/phrase has appeared at least once in the training set as a deictic anaphor.
+
+E5. Predicting anaphors. Now that we have the candidate anaphors, our next extension involves predicting which of them are indeed deictic anaphors. To do so, we retrain the type prediction model in UTD_NLP, which is a FFNN that takes as input the (contextualized) span representation $g_{i}$ of candidate anaphor $i$ and outputs a vector $o t_{i}$ of dimension 2 in which the first element denotes the likelihood that $i$ is a deictic anaphor and the second element denotes the likelihood that $i$ is not a deictic anaphor. $i$ is predicted as a deictic anaphor if and only if the value of the first element of $o t_{i}$ is bigger than its second value:
+
+$$
+o t _ {i} = \mathrm {F F N N} (g _ {i})
+$$
+
+$$
+t_{i} = \operatorname *{arg max}_{\substack{x\in \{\mathrm{A},\mathrm{NA}\}}}ot_{i}(x)
+$$
+
+where A (ANAPHOR) and NA (NON-ANAPHOR) are the two possible types. Following UTD_NLP, this type prediction model is jointly trained with the resolution model. Specifically, we compute the cross-entropy loss using $o t_{i}$ , multiply it by a type loss coefficient $\lambda$ , and add it to the loss function of coref-hoi-utt. $\lambda$ is a tunable parameter that controls the importance of type prediction relative to DD resolution.
+
+E6. Modeling the relationship between anaphor recognition and resolution. In principle, the model should resolve a candidate anaphor to a non-dummy candidate antecedent if it is predicted to be a deictic anaphor by the type prediction model. However, type prediction is not perfect, and enforcing this consistency constraint, which we will refer to as C1, will allow errors in type prediction to be propagated to DD resolution. For example, if a non-deictic anaphor is misclassified by the type prediction model, then it will be (incorrectly) resolved to a non-dummy antecedent. To alleviate error propagation, we instead enforce C1 in a soft manner. To do so, we define a penalty function $p_1$ , which imposes a penalty on span $i$ if C1 is violated (i.e., a deictic anaphor is resolved to the dummy antecedent), as shown below:
+
+$$
+p _ {1} (i) = \left\{ \begin{array}{l l} 0 & \operatorname * {a r g m a x} _ {y _ {i s} \in \mathcal {Y}} t _ {i} = \mathrm {N A} \\ o t _ {i} (\mathrm {A}) - o t _ {i} (\mathrm {N A}) & \text {o t h e r w i s e} \end{array} \right.
+$$
+
+Intuitively, $p_1$ estimates the minimum amount to be adjusted so that span $i$ 's type is not ANAPHOR.
+
+We incorporate $p_1$ into the model as a penalty term in $s$ (Equation (1)). Specifically, we redefine $s(i,j)$ when $j = \epsilon$ , as shown below:
+
+$$
+s (i, \epsilon) = s (i, \epsilon) - [ \gamma_ {3} p _ {1} (i) ]
+$$
+
+where $\gamma_{3}$ is a positive constant that controls the hardness of C1. The smaller $\gamma_{3}$ is, the softer C1 is. Intuitively, if C1 is violated, $s(i,\epsilon)$ will be lowered by the penalty term, and the dummy antecedent will less likely be selected as the antecedent of $i$ .
+
+E7. Modeling the relationship between non-anaphor recognition and resolution. Another consistency constraint that should be enforced is that the model should resolve a candidate anaphor to the dummy antecedent if it is predicted as a nondeictic anaphor by the type prediction model. As in Extension E6, we will enforce this constraint, which we will refer to as C2, in a soft manner by defining a penalty function $p_2$ , as shown below:
+
+$$
+p _ {2} (i) = \left\{ \begin{array}{l l} o t _ {i} (\mathrm {N A}) - o t _ {i} (\mathrm {A}) & \underset {y _ {i s} \in \mathcal {Y}} {\arg \max t _ {i}} = \mathrm {N A} \\ 0 & \text {o t h e r w i s e} \end{array} \right.
+$$
+
+Then we redefine $s(i,j)$ when $j \neq \epsilon$ as follows:
+
+$$
+s (i, j) = s (i, j) - [ \gamma_ {4} p _ {1} (i) ]
+$$
+
+where $\gamma_4$ is a positive constant that controls the hardness of C2. Intuitively, if C2 is violated, $s(i,j)$ will be lowered by the penalty term, and $j$ will less likely be selected as the antecedent of $i$ .
+
+E8. Encoding candidate anaphor context. Examining Equation (1), we see that $s(x, y)$ is computed based on the span representations of $x$ and $y$ . While these span representations are contextualized, the contextual information they encode is arguably limited. As noted before, most of the deictic anaphors in dialogue are pronouns, which are semantically empty. As a result, we hypothesize that we could improve the resolution of these deictic anaphors if we explicitly modeled their contexts. Specifically, we represent the context of a candidate anaphor using the embedding of the utterance in which it appears and add the resulting embedding as features to both the bilinear score $s_c(x, y)$ and the concatenation-based score $s_a(x, y)$ :
+
+$$
+\begin{array}{l} s _ {c} (x, y) = g _ {x} ^ {\top} W _ {c} g _ {y} + g _ {s} ^ {\top} W _ {s} g _ {y} \\ s _ {a} (x, y) = \mathbb {F F N N} _ {c} (g _ {x}, g _ {y}, g _ {x} \circ g _ {y}, g _ {s}, \phi (x, y)) \\ \end{array}
+$$
+
+where $W_{c}$ and $W_{s}$ are learned weight matrices, $g_{s}$ is the embedding of the utterance $s$ in which candidate anaphor $x$ appears, and $\phi(x, y)$ encodes the relationship between $x$ and $y$ as features.
+
+# Filling words
+
+yeah, okay, ok, uh, right, so, hmm, well, um, oh, mm, yep, hi, ah, whoops, alright, shhhh, yes, ay, hello, aww, alas, ye, aye, uh-huh, huh, wow, www, no, and, but, again, wonderful, exactly, absolutely, actually, sure thanks, awesome, gosh, ooops
+
+# Reporting verbs
+
+command, mention, demand, request, reveal, believe, guarantee, guess, insist, complain, doubt, estimate, warn, learn, realise, persuade, propose, announce, advise, imagine, boast, suggest, remember, claim, describe, see, understand, discover, answer, wonder, recommend, beg, prefer, suppose, comment, think, argue, consider, swear, ask, agree, explain, report, know, tell, decide, discuss, repeat, invite, reply, expect, forget, add, fear, hope, say, feel, observe, remark, confirm, threaten, teach, forbid, admit, promise, deny, state, mean, instruct
+
+Table 2: Lists of filtered words.
+
+E9. Encoding the relationship between candidate anaphors and antecedents. As noted in Extension E8, $\phi(x,y)$ encodes the relationship between candidate anaphor $x$ and candidate antecedent $y$ . In UTD_NLP, $\phi(x,y)$ is composed of three features, including two features from coref-hoi-utt (i.e., the speaker id and the segment distance between $x$ and $y$ ) and one feature that encodes the utterance distance between them. Similar to the previous extension, we hypothesize that we could better encode the relationship between $x$ and $y$ using additional features. Specifically, we incorporate an additional feature into $\phi(x,y)$ that encodes the utterance distance between $x$ and $y$ . Unlike the one used in UTD_NLP, this feature aims to more accurately capture proximity by ignoring unimportant sentences (i.e., those that contain only interjections, filling words, reporting verbs, and punctuation) when computing utterance distance. The complete list of filling words and reporting verbs that we filter can be found in Table 2.
+
+E10. Encoding candidate antecedents. In coref-hoi-utt, a candidate antecedent is simply encoded using its span representation. We hypothesize that we could better encode a candidate antecedent using additional features. Specifically, we employ seven features to encode a candidate antecedent $y$ and incorporate them into $\phi(x, y)$ : (1) the number of words in $y$ ; (2) the number of nouns in $y$ ; (3) the number of verbs in $y$ ; (4) the number of adjectives in $y$ ; (5) the number of content word overlaps between $y$ and the portion of the utterance containing the anaphor that precedes the anaphor; (6) whether $y$ is the longest among the candidate antecedents; and (7) whether $y$ has the largest number
+
+of content word overlap (as computed in Feature 5) among the candidate antecedents. Like Extension E3, some features implicitly encode the length of a candidate antecedent. Despite this redundancy, we believe the redundant information could be exploited by the model differently and may therefore have varying degrees of impact on it.
+
+# 6 Evaluation
+
+# 6.1 Experimental Setup
+
+Evaluation metrics. We obtain the results of DD resolution using the Universal Anaphora Scorer (Yu et al., 2022b). Since DD resolution is viewed as a generalized case of event coreference, the scorer reports performance in terms of CoNLL score, which is the unweighted average of the F-scores of three coreference scoring metrics, namely MUC (Vilain et al., 1995), $\mathbf{B}^3$ (Bagga and Baldwin, 1998), and $\mathrm{CEAF}_e$ (Luo, 2005). In addition, we report the results of deictic anaphor recognition. We express recognition results in terms of Precision (P), Recall (R) and F-score, considering an anaphor correctly recognized if it has an exact match with a gold anaphor in terms of boundary.
+
+Model training and parameter tuning. For coref-hoi and coref-hoi-utt, we use $\mathrm{SpanBERTLarge}$ as the encoder and reuse the hyperparameters from Xu and Choi (2020) with the only exception of the maximum span width: for coref-hoi, we increase the maximum span width from 30 to 45 in order to cover more than $97\%$ of the antecedent spans; for coref-hoi-utt we use 15 as the maximum span width, which covers more than $99\%$ of the anaphor spans in the training sets. For UTD_NLP, we simply take the outputs produced by the model on the test sets and report the results obtained by running the scorer on the outputs. For dd-utt, we use $\mathrm{SpanBERTLarge}$ as the encoder. Since we do not rely on span enumerate to generate candidate spans, the maximum span width can be set to any arbitrary number that is large enough to cover all candidate antecedents and anaphors. In our case, we use 300 as our maximum span width. We tune the parameters (i.e., $\lambda$ , $\gamma_1$ , $\gamma_2$ , $\gamma_3$ , $\gamma_4$ ) using grid search to maximize CoNLL score on development data. For the type loss coefficient, we search out
+
+of $\{0.2, 0.5, 1, 200, 500, 800, 1200, 1600\}$ , and for $\gamma$ , we search out of $\{1, 5, 10\}$ . We reuse other hyperparameters from Xu and Choi (2020).
+
+All models are trained for 30 epochs with a dropout rate of 0.3 and early stopping. We use $1 \times 10^{-5}$ as our BERT learning rate and $3 \times 10^{-4}$ as our task learning rate. Each experiment is run using a random seed of 11 and takes less than three hours to train on an NVIDIA RTX A6000 48GB.
+
+Train-dev partition. Since we have four test sets, we use ARRAU and all dev sets other than the one to be evaluated on for model training and the remaining dev set for parameter tuning. For example, when evaluating on $\mathrm{AMI}_{\mathrm{test}}$ , we train models on ARRAU, $\mathrm{LIGHT}_{\mathrm{dev}}$ , $\mathrm{Persuasion}_{\mathrm{dev}}$ and Switchboard $_{\mathrm{dev}}$ and use $\mathrm{AMI}_{\mathrm{dev}}$ for tuning.
+
+# 6.2 Results
+
+Recall that our goal is to perform end-to-end DD resolution, which corresponds to the Predicted evaluation setting in the CODI-CRAC shared task.
+
+Overall performance. Recognition results (expressed in F-score) and resolution results (expressed in CoNLL score) of the three baselines and our model on the four test sets are shown in Table 3, where the Avg. columns report the macroaverages of the corresponding results on the four test sets, and the parameter settings that enable our model to achieve the highest CoNLL scores on the development sets are shown in Table 4. Since coref-hoi and coref-hoi-utt do not explicitly identify deictic anaphors, we assume that all but the first mentions in each output cluster are anaphors when computing recognition precision; and while UTD_NLP (the top-performing system in the shared task) does recognize anaphors, we still make the same assumption when computing its recognition precision since the anaphors are not explicitly marked in the output (recall that we computed results of UTD_NLP based on its outputs).
+
+We test the statistical significance among the four models using two-tailed Approximate Randomization (Noreen, 1989). For recognition, the models are statistically indistinguishable from each other w.r.t. their Avg. score $(p < 0.05)$ . For resolution, dd-utt is highly significantly better than the baselines w.r.t. Avg. $(p < 0.001)$ , while the three baselines are statistically indistinguishable from each other. These results suggest that (1) dd-utt's superior resolution performance stems from better antecedent selection, not better anaphor
+
+ | Resolution | Recognition |
| LIGHT | AMI | Pers. | Swbd. | Avg. | LIGHT | AMI | Pers. | Swbd. | Avg. |
| UTD_NLP | 42.7 | 35.4 | 39.6 | 35.4 | 38.3 | 70.1 | 61.0 | 69.9 | 68.1 | 67.3 |
| coref-hoi | 42.7 | 30.7 | 49.7 | 35.4 | 39.6 | 70.9 | 49.3 | 67.8 | 61.9 | 62.5 |
| coref-hoi-utt | 42.3 | 35.0 | 53.3 | 34.1 | 41.2 | 70.3 | 52.4 | 71.0 | 60.6 | 63.6 |
| dd-utt | 48.2 | 43.5 | 54.9 | 47.2 | 48.5 | 71.3 | 56.9 | 71.4 | 65.2 | 66.2 |
+
+Table 3: Resolution and recognition results on the four test sets.
+
+ | LIGHT | AMI | Pers. | Swbd. |
| Type loss coefficient λ | 800 | 800 | 800 | 800 |
| γ1 | 1 | 1 | 1 | 1 |
| γ2 | 1 | 1 | 1 | 1 |
| γ3 | 5 | 10 | 10 | 5 |
| γ4 | 5 | 5 | 5 | 5 |
+
+Table 4: Parameter values enabling dd-utt to achieve the best CoNLL score on each development set.
+
+recognition; and (2) the restriction of candidate antecedents to utterances in coref-hoi-utt does not enable the resolver to yield significantly better resolution results than coref-hoi.
+
+Per-anaphor results. Next, we show the recognition and resolution results of the four models on the most frequently occurring deictic anaphors in Table 5 after micro-averaging them over the four test sets. Not surprisingly, "that" is the most frequent deictic anaphor on the test sets, appearing as an anaphor 402 times on the test sets and contributing to $68.8\%$ of the anaphors. This is followed by "it" $(16.3\%)$ and "this" $(4.3\%)$ . Only $8.9\%$ of the anaphors are not among the top four anaphors.
+
+Consider first the recognition results. As can be seen, "that" has the highest recognition F-score among the top anaphors. This is perhaps not surprising given the comparatively larger number of "that" examples the models are trained on. While "it" occurs more frequently than "this" as a deictic anaphor, its recognition performance is lower than that of "this". This is not surprising either: "this", when used as a pronoun, is more likely to be deictic than "it", although both of them can serve as a coreference anaphor and a bridging anaphor. In other words, it is comparatively more difficult to determine whether a particular occurrence of "it" is deictic. Overall, UTD_NLP recognizes more anaphors than the other models.
+
+Next, consider the resolution results. To obtain the CoNLL scores for a given anaphor, we retain all and only those clusters containing the anaphor in both the gold partition and the system partition and apply the official scorer to them. Generally, the
+
+more frequently occurring an anaphor is, the better its resolution performance is. Interestingly, for the "Others" category, dd-utt achieves the highest resolution results despite having the lowest recognition performance. In contrast, while UTD_NLP achieves the best recognition performance on average, its resolution results are among the worst.
+
+Per-distance results. To better understand how resolution results vary with the utterance distance between a deictic anaphor and its antecedent, we show in Table 6 the number of correct and incorrect links predicted by the four models for each utterance distance on the test sets. For comparison purposes, we show at the top of the table the distribution of gold links over utterance distances. Note that a distance of 0 implies that the anaphor refers to the utterance in which it appears.
+
+A few points deserve mention. First, the distribution of gold links is consistent with our intuition: a deictic anaphor most likely has the immediately preceding utterance (i.e., distance $= 1$ ) as its referent. In addition, the number of links drops as distance increases, and more than $90\%$ of the antecedents are at most four utterances away from their anaphors. Second, although UTD_NLP recognizes more anaphors than the other models, it is the most conservative w.r.t. link identification, predicting the smallest number of correct and incorrect links for almost all of the utterance distances. Third, dd-utt is better than the other models at (1) identifying short-distance anaphoric dependencies, particularly when distance $\leq 1$ , and (2) positing fewer erroneous long-distance anaphoric dependencies. These results provide suggestive evidence of dd-utt's success at modeling recency and distance explicitly. Finally, these results suggest that resolution difficulty increases with distance: except for UTD_NLP, none of the models can successfully recognize a link when distance $>5$ .
+
+Ablation results. To evaluate the contribution of each extension presented in Section 5 to dd-utt's resolution performance, we show in Table 7 ablation results, which we obtain by removing one
+
+| anaphor | count | Resolution | Recognition |
| UTD_NLP | coref-hoi | coref-hoi-utt | dd-utt | UTD_NLP | coref-hoi | coref-hoi-utt | dd-utt |
| that | 402 | 48.7 | 49.1 | 50.4 | 60.7 | 79.1 | 72.7 | 72.9 | 76.8 |
| it | 95 | 21.8 | 27.5 | 28.5 | 37.0 | 36.5 | 36.4 | 37.0 | 35.5 |
| this | 25 | 20.7 | 25.1 | 26.9 | 25.8 | 51.7 | 49.2 | 49.3 | 56.5 |
| which | 10 | 4.5 | 8.2 | 14.9 | 14.4 | 33.3 | 28.6 | 42.1 | 35.3 |
| Others | 52 | 33.0 | 39.6 | 41.2 | 48.5 | 33.8 | 28.1 | 40.0 | 10.3 |
+
+Table 5: Per-anaphor recognition and resolution results on the test sets.
+
+ | 0 | 1 | 2 | 3 | 4 | 5 | >5 |
| Distribution of gold links over utterance distances |
| Gold | 90 | 209 | 97 | 46 | 21 | 8 | 19 |
| Distribution of correctly predicted links |
| UTD_NLP | 28 | 64 | 23 | 9 | 4 | 2 | 1 |
| coref-hoi | 22 | 108 | 42 | 13 | 5 | 3 | 0 |
| coref-hoi-utt | 23 | 118 | 49 | 11 | 6 | 2 | 0 |
| dd-utt | 40 | 142 | 45 | 17 | 5 | 3 | 0 |
| Distribution of incorrectly predicted links |
| UTD_NLP | 16 | 56 | 31 | 24 | 9 | 6 | 52 |
| coref-hoi | 83 | 148 | 55 | 33 | 22 | 13 | 58 |
| coref-hoi-utt | 64 | 123 | 66 | 36 | 21 | 10 | 48 |
| dd-utt | 43 | 131 | 57 | 24 | 6 | 7 | 7 |
+
+extension at a time from dd-utt and retraining it. For ease of comparison, we show in the first row of the table the CoNLL scores of dd-utt.
+
+A few points deserve mention. First, when E1 (Modeling recency) is ablated, we use as candidate antecedents the 10 highest-scoring candidate antecedents for each candidate anaphor according to $s_c(x,y)$ (Equation (3)). Second, when one of E2, E3, E6, and E7 is ablated, we set the corresponding $\lambda$ to zero. Third, when E4 is ablated, candidate anaphors are extracted in the same way as in coref-hoi and coref-hoi-utt, where the top spans learned by the model will serve as candidate anaphors. Fourth, when E5 is ablated, E6 and E7 will also be ablated because the penalty functions $p_1$ and $p_2$ need to be computed based on the output of the type prediction model in E5.
+
+We use two-tailed Approximate Randomization to determine which of these ablated models is statistically different from dd-utt w.r.t. the Avg. score. Results show that except for the model in which E1 is ablated, all of the ablated models are statistically indistinguishable from dd-utt $(p < 0.05)$ . Note that these results do not imply that nine of the extensions fail to contribute positively to dd-utt's resolution performance: it only means that none of them is useful in the presence of other extensions
+
+Table 6: Distribution of links over the utterance distances between the anaphor and the antecedents.
+
+ | LIGHT | AMI | Pers. | Swbd. | Avg. |
| dd-utt | 48.2 | 43.5 | 54.9 | 47.2 | 48.5 |
| - E1 | 47.1 | 36.4 | 53.6 | 46.2 | 45.8 |
| - E2 | 47.4 | 40.0 | 56.5 | 48.9 | 48.2 |
| - E3 | 45.3 | 44.6 | 53.7 | 49.0 | 48.1 |
| - E4 | 46.4 | 42.8 | 56.7 | 45.6 | 47.9 |
| - E5 | 43.6 | 43.9 | 50.2 | 47.4 | 46.3 |
| - E6 | 46.1 | 43.1 | 50.8 | 47.2 | 46.8 |
| - E7 | 48.6 | 43.6 | 56.0 | 49.4 | 49.4 |
| - E8 | 43.3 | 39.4 | 52.5 | 50.1 | 46.3 |
| - E9 | 44.6 | 43.2 | 52.1 | 47.7 | 46.9 |
| - E10 | 47.3 | 39.3 | 57.5 | 49.7 | 48.5 |
+
+Table 7: Resolution results of ablated models.
+
+w.r.t. Avg. We speculate that (1) some of these extensions model overlapping phenomena (e.g., both E2 and E9 model utterance distance); (2) when the model is retrained, the learner manages to adjust the network weights so as to make up for the potential loss incurred by ablating an extension; and (3) large fluctuations in performance can be observed on individual datasets in some of the experiments, but they may just disappear after averaging. Experiments are needed to determine the reason.
+
+# 6.3 Error Analysis
+
+Below we analyze the errors made by dd-utt.
+
+DD anaphora recognition precision errors. A common type of recognition precision errors involves misclassifying a coreference anaphor as a deictic anaphor. Consider the first example in Figure 2, in which the pronoun "that" is a coreference anaphor with "voice recognition" as its antecedent but is misclassified as a deictic anaphor with the whole sentence as its antecedent. This type of error occurs because virtually all of the frequently occurring deictic anaphors, including "that", "it", "this", and "which", appear as a coreference anaphor in some contexts and as a deictic anaphor in other contexts, and distinguishing between the two different uses of these anaphors could be challenging.
+
+DD anaphor recognition recall errors. Consider the second example in Figure 2, in which
+
+A: The design should minimize R_S_I and be easy to locate and we were still slightly ambivalent as to whether to use voice recognition there, though that did seem to be the favored strategy, but there was also, on the sideline, the thought of maybe having a beeper function.
+
+A: Sounds like a blessed organization.
+
+B: Yes, it does.
+
+A: Did you know they've won over 7 different awards for their charitable work?
+
+A: As a former foster kid, it makes me happy to see this place bring such awareness to the issues and needs of our young.
+
+B: I am not surprised to hear that at all.
+
+Figure 2: Examples illustrating the three majors types of errors made by dd-utt.
+
+“it” is a deictic anaphor that refers to the boldfaced utterance, but dd-utt fails to identify this and many other occurrences of “it” as deictic, probably because “it” is more likely to be a coreference anaphor than a deictic anaphor: in the dev sets, $80\%$ of the occurrences of “it” are coreference anaphors while only $5\%$ are deictic anaphors.
+
+DD resolution precision errors. A major source of DD resolution precision errors can be attributed to the model's failure in properly understanding the context in which a deictic anaphor appears. Consider the third example in Figure 2, in which "that" is a deictic anaphor that refers to the boldfaced utterance. While dd-utt correctly identifies "that" as a deictic anaphor, it erroneously posits the italicized utterance as its antecedent. This example is interesting in that without looking at the boldfaced utterance, the italicized utterance is a plausible antecedent for "that" because "I am not surprised to hear that at all" can be used as a response to almost every statement. However, when both the boldfaced utterance and the italicized utterance are taken into consideration, it is clear that the boldfaced utterance is the correct antecedent for "that" because winning over seven awards for some charitable work is certainly more surprising than seeing a place bring awareness to the needs of the young. Correctly resolving this anaphor, however, requires modeling the emotional implication of its context.
+
+# 6.4 Further Analysis
+
+Next, we analyze the deictic anaphors correctly resolved by dd-utt but erroneously resolved by the baseline resolvers.
+
+The example shown in Figure 3 is one such case. In this example, dd-utt successfully extracts the anaphor "that" and resolves it to the correct antecedent "Losing one decimal place, that is okay". UTD_NLP fails to extract "that" as a deic
+
+A: You want your rating to be a two?
+
+A: Is that what you're saying?
+
+B: Yeah, I just got it the other way.
+
+B: Uh in Yep, I just got
+
+A: Okay.
+
+A: So, I'll work out the average for that again at the end.
+
+A: It's very slightly altered. Okay, and we're just waiting for your rating.
+
+B: two point five
+
+C: Its just two point five for that one.
+
+A: Two point five, okay.
+
+D: Yeah.
+
+A: Losing one decimal place, that is okay.
+
+Figure 3: Example in which the correct antecedent is identified by dd-utt but not by the baseline resolvers.
+
+tic anaphor. While coref-hoi correctly extracts the anaphor, it incorrectly selects "You want your rating to be a two?" as the antecedent. From a cursory look at this example one could infer that this candidate antecedent is highly unlikely to be the correct antecedent since it is 10 utterances away from the anaphor. As for coref-hoi-utt, the resolver successfully extracts the anaphor but incorrectly selects "Its just two point five for that one" as the antecedent, which, like the antecedent chosen by coref-hoi, is farther away from the anaphor than the correct antecedent is. We speculate that coref-hoi and coref-hoi-utt fail to identify the correct antecedent because they do not explicitly model distance and therefore may not have an idea about how far a candidate antecedent is from the anaphor under consideration. The additional features that dd-utt has access to, including the features that encode sentence distance as well as those that capture contextual information, may have helped dd-utt choose the correct antecedent, but additional analysis is needed to determine the reason.
+
+# 7 Conclusion
+
+We presented an end-to-end discourse deixis resolution model that augments Lee et al.'s (2018) span-based entity coreference model with 10 extensions. The resulting model achieved state-of-the-art results on the CODI-CRAC 2021 datasets. We employed a variant of this model in our recent participation in the discourse deixis track of the CODI-CRAC 2022 shared task (Yu et al., 2022a) and achieved the best results (see Li et al. (2022) for details). To facilitate replicability, we make our source code publicly available.
+
+# Limitations
+
+Below we discuss several limitations of our work.
+
+Generalization to corpora with clausal antecedents. As mentioned in the introduction, the general discourse deixis resolution task involves resolving a deictic anaphor to a clausal antecedent. The fact that our resolver can only resolve anaphors to utterances raises the question of whether it can be applied to resolve deictic anaphors in texts where antecedents can be clauses. To apply our resolver to such datasets, all we need to do is to expand the set of candidate antecedents of an anaphor to include those clauses that precede it. While corpora annotated with clausal antecedents exist (e.g., TRAINS-91 and TRAINS-93), we note that the decision made by the CODI-CRAC 2021 shared task organizers to use utterances as the unit of annotation has to do with annotation quality, as the inter-annotator agreement on the selection of clausal antecedents tends to be low (Poesio and Artstein, 2008),
+
+Discourse deixis resolution in dialogue vs. narrative text. Whether our model will generalize well to non-dialogue datasets (e.g., narrative text) is unclear. Given the differences between dialogue and non-dialogue datasets (e.g., the percentage of pronominal anaphors), we speculate that the performance of our resolver will take a hit when applied to resolving deictic anaphors in narrative text.
+
+Size of training data. We believe that the performance of our resolver is currently limited in part by the small amount of data on which it was trained. The annotated corpora available for training a discourse deictic resolver is much smaller than those available for training an entity coreference resolver (e.g., OntoNotes (Hovy et al., 2006)).
+
+Data biases. Generally, our work should not cause any significant risks. However, language varieties not present in training data can potentially amplify existing inequalities and contribute to misunderstandings.
+
+# Acknowledgments
+
+We thank the three anonymous reviewers for their insightful comments on an earlier draft of the paper. This work was supported in part by NSF Grant IIS-1528037. Any opinions, findings, conclusions or recommendations expressed in this paper are those of the authors and do not necessarily reflect
+
+the views or official policies, either expressed or implied, of the NSF.
+
+# References
+
+Tatiana Anikina, Cennet Oguz, Natalia Skachkova, Siyu Tao, Sharmila Upadhyaya, and Ivana Kruijff-Korbayova. 2021. Anaphora resolution in dialogue: Description of the DFKI-TalkingRobots system for the CODI-CRAC 2021 shared-task. In Proceedings of the CODI-CRAC 2021 Shared Task on Anaphora, Bridging, and Discourse Deixis in Dialogue, pages 32-42, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Amit Bagga and Breck Baldwin. 1998. Algorithms for scoring coreference chains. In Proceedings of the LREC Workshop on Linguistics Coreference, pages 563-566.
+Donna K. Byron. 2002. Resolving pronominal reference to abstract entities. In Proceedings of the 40th Annual Meeting of the Association for Computational Linguistics, pages 80-87, Philadelphia, Pennsylvania, USA. Association for Computational Linguistics.
+Miriam Eckert and Michael Strube. 2000. Dialogue acts, synchronizing units, and anaphora resolution. Journal of Semantics, 17:51-89.
+John J. Godfrey, Edward C. Holliman, and Jane McDaniel. 1992. Switchboard: telephone speech corpus for research and development. In Proceedings of the 1992 IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP-92), volume 1, pages 517-520.
+Eduard Hovy, Mitchell Marcus, Martha Palmer, Lance Ramshaw, and Ralph Weischedel. 2006. OntoNotes: The $90\%$ solution. In Proceedings of the Human Language Technology Conference of the NAACL, Companion Volume: Short Papers, pages 57-60, New York City, USA. Association for Computational Linguistics.
+Mandar Joshi, Danqi Chen, Yinhan Liu, Daniel S. Weld, Luke Zettlemoyer, and Omer Levy. 2020. SpanBERT: Improving pre-training by representing and predicting spans. Transactions of the Association for Computational Linguistics, 8:64-77.
+Mandar Joshi, Omer Levy, Luke Zettlemoyer, and Daniel Weld. 2019. BERT for coreference resolution: Baselines and analysis. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 5803-5808, Hong Kong, China. Association for Computational Linguistics.
+Ben Kantor and Amir Globerson. 2019. Coreference resolution with entity equalization. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 673-677, Florence, Italy. Association for Computational Linguistics.
+
+Sopan Khosla, Juntao Yu, Ramesh Manuvinakurike, Vincent Ng, Massimo Poesio, Michael Strube, and Carolyn Rose. 2021. The CODI-CRAC 2021 shared task on anaphora, bridging, and discourse deixis in dialogue. In Proceedings of the CODI-CRAC 2021 Shared Task on Anaphora, Bridging, and Discourse Deixis in Dialogue, pages 1-15, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Hideo Kobayashi, Shengjie Li, and Vincent Ng. 2021. Neural anaphora resolution in dialogue. In Proceedings of the CODI-CRAC 2021 Shared Task on Anaphora, Bridging, and Discourse Deixis in Dialogue, pages 16-31, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Kenton Lee, Luheng He, and Luke Zettlemoyer. 2018. Higher-order coreference resolution with coarse-to-fine inference. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 687-692, New Orleans, Louisiana. Association for Computational Linguistics.
+Shengjie Li, Hideo Kobayashi, and Vincent Ng. 2021. The CODI-CRAC 2021 shared task on anaphora, bridging, and discourse deixis resolution in dialogue: A cross-team analysis. In Proceedings of the CODI-CRAC 2021 Shared Task on Anaphora, Bridging, and Discourse Deixis in Dialogue, pages 71-95, Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Shengjie Li, Hideo Kobayashi, and Vincent Ng. 2022. Neural anaphora resolution in dialogue revisited. In Proceedings of the CODI-CRAC 2022 Shared Task on Anaphora, Bridging, and Discourse Deixis in Dialogue, pages 32-47, Gyeongju, Republic of Korea. Association for Computational Linguistics.
+Xiaoqiang Luo. 2005. On coreference resolution performance metrics. In Proceedings of Human Language Technology Conference and Conference on Empirical Methods in Natural Language Processing, pages 25-32, Vancouver, British Columbia, Canada. Association for Computational Linguistics.
+Ana Marasović, Leo Born, Juri Opitz, and Anette Frank. 2017. A mention-ranking model for abstract anaphora resolution. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 221-232, Copenhagen, Denmark. Association for Computational Linguistics.
+Iain McCowan, Jean Carletta, Wessel Kraaij, Simone Ashby, Sebastien Bourban, Mike Flynn, Mael Guillemot, Thomas Hain, Jaroslav Kadlec, Vasilis Karaiskos, Melissa Kronenthal, Guillaume Lathoud, Mike Lincoln, Agnes Lisowska, Wilfried Post, Dennis Reidsma, and Pierre D. Wellner. 2005. The AM meeting corpus. The AMI Project Consortium, www.amiproject.org.
+
+Christoph Müller. 2008. Fully Automatic Resolution of "it", "this", and "that" in Unrestricted Multi-Party Dialog. Ph.D. thesis, Universität Tübingen, Tübingen, Germany.
+Costanza Navarretta. 2000. Abstract anaphora resolution in Danish. In 1st SIGdial Workshop on Discourse and Dialogue, pages 56-65, Hong Kong, China. Association for Computational Linguistics.
+Eric W. Noreen. 1989. Computer-Intensive Methods for Testing Hypotheses: An Introduction. John Wiley & Sons Inc.
+Massimo Poesio and Ron Artstein. 2008. Anaphoric annotation in the ARRAU corpus. In Proceedings of the Sixth International Conference on Language Resources and Evaluation (LREC'08), Marrakech, Morocco. European Language Resources Association (ELRA).
+Michael Strube and Christoph Müller. 2003. A machine learning approach to pronoun resolution in spoken dialogue. In Proceedings of the 41st Annual Meeting of the Association for Computational Linguistics, pages 168-175, Sapporo, Japan. Association for Computational Linguistics.
+Jack Urbanek, Angela Fan, Siddharth Karamcheti, Saachi Jain, Samuel Humeau, Emily Dinan, Tim Rocktäschel, Douwe Kiela, Arthur Szlam, and Jason Weston. 2019. Learning to speak and act in a fantasy text adventure game. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 673-683, Hong Kong, China. Association for Computational Linguistics.
+Marc Vilain, John Burger, John Aberdeen, Dennis Connolly, and Lynette Hirschman. 1995. A model-theoretic coreference scoring scheme. In Sixth Message Understanding Conference (MUC-6): Proceedings of a Conference Held in Columbia, Maryland, November 6-8, 1995.
+Xuewei Wang, Weiyan Shi, Richard Kim, Yoojung Oh, Sijia Yang, Jingwen Zhang, and Zhou Yu. 2019. Persuasion for good: Towards a personalized persuasive dialogue system for social good. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 5635-5649, Florence, Italy. Association for Computational Linguistics.
+Bonnie Lynn Webber. 1991. Structure and ostension in the interpretation of discourse deixis. *Language and Cognitive Processes*, 6(2):107—135.
+Liyan Xu and Jinho D. Choi. 2020. Revealing the myth of higher-order inference in coreference resolution. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 8527-8533, Online. Association for Computational Linguistics.
+
+Juntao Yu, Sopan Khosla, Ramesh Manuvinakurike, Lori Levin, Vincent Ng, Massimo Poesio, Michael Strube, and Carolyn Rose. 2022a. The CODI-CRAC 2022 shared task on anaphora, bridging, and discourse deixis in dialogue. In Proceedings of the CODI-CRAC 2022 Shared Task on Anaphora, Bridging, and Discourse Deixis in Dialogue, pages 1-14, Gyeongju, Republic of Korea. Association for Computational Linguistics.
+
+Juntao Yu, Sopan Khosla, Nafise Sadat Moosavi, Silviu Paun, Sameer Pradhan, and Massimo Poesio. 2022b. The universal anaphora scorer. In Proceedings of the Thirteenth Language Resources and Evaluation Conference, pages 4873-4883, Marseille, France. European Language Resources Association.
+
+# A Detailed Experimental Results
+
+We report the resolution results of the four resolvers (UTD_NLP, coref-hoi, coref-hoi-utt, and dd-utt) on the CODI-CRAC 2021 shared task test sets in terms of MUC, $\mathbf{B}^3$ , and $\mathrm{CEAF}_e$ scores in Table 8 and their mention extraction results in terms of recall (R), precision (P), and F-score (F) in Table 9.
+
+Consider first the resolution results in Table 8. As can be seen, not only does dd-utt achieve the best CoNLL scores on all four datasets, but it does so via achieving the best MUC, $\mathbf{B}^3$ , and $\mathrm{CEAF}_e$ F-scores. In terms of MUC F-score, the performance difference between dd-utt and the second best resolver on each dataset is substantial (2.2%–14.9% points). These results suggest that better link identification, which is what the MUC F-score reveals, is the primary reason for the superior performance of dd-utt. Moreover, Persuasion appears to be the easiest of the four datasets, as this is the dataset on which three of the four resolvers achieved the highest CoNLL scores. Note that Persuasion is also the dataset on which the differences in CoNLL score between dd-utt and the other resolvers are the smallest. These results seem to suggest that the performance gap between dd-utt and the other resolvers tends to widen as the difficulty of a dataset increases.
+
+Next, consider the anaphor extraction results in Table 9. In terms of F-score, dd-utt lags behind UTD_NLP on two datasets, AMI and Switchboard. Nevertheless, the anaphor extraction precision achieved by dd-utt is often one of the highest in each dataset.
+
+ | MUC | B3 | CEAFe | CoNLL |
| P | R | F | P | R | F | P | R | F |
| LIGHT |
| UTD_NLP | 44.6 | 31.3 | 36.8 | 56.2 | 37.0 | 44.6 | 55.3 | 40.5 | 46.7 | 42.7 |
| coref-hoi | 37.2 | 36.3 | 36.7 | 48.9 | 42.0 | 45.2 | 58.2 | 38.5 | 46.3 | 42.7 |
| coref-hoi-utt | 36.5 | 38.8 | 37.6 | 46.7 | 42.3 | 44.4 | 55.3 | 38.0 | 45.0 | 42.3 |
| dd-utt | 52.4 | 41.3 | 46.2 | 62.0 | 41.6 | 49.8 | 69.0 | 37.6 | 48.7 | 48.2 |
| AMI |
| UTD_NLP | 45.5 | 21.2 | 28.9 | 52.4 | 29.5 | 37.8 | 44.9 | 35.1 | 39.4 | 35.4 |
| coref-hoi | 21.7 | 30.5 | 25.4 | 28.7 | 36.3 | 32.1 | 39.0 | 31.0 | 34.6 | 30.7 |
| coref-hoi-utt | 25.5 | 33.1 | 28.8 | 34.6 | 39.0 | 36.7 | 43.4 | 36.1 | 39.4 | 35.0 |
| dd-utt | 41.2 | 39.8 | 40.5 | 48.9 | 42.8 | 45.6 | 54.4 | 37.5 | 44.4 | 43.5 |
| Persuasion |
| UTD_NLP | 45.5 | 20.3 | 28.1 | 65.0 | 30.2 | 41.2 | 61.0 | 41.8 | 49.6 | 39.6 |
| coref-hoi | 48.6 | 42.3 | 45.2 | 57.5 | 45.9 | 51.1 | 66.2 | 44.0 | 52.9 | 49.7 |
| coref-hoi-utt | 50.0 | 49.6 | 49.8 | 56.8 | 51.7 | 54.1 | 64.4 | 49.4 | 55.9 | 53.3 |
| dd-utt | 56.7 | 48.0 | 52.0 | 63.8 | 49.9 | 56.0 | 72.1 | 46.9 | 56.8 | 54.9 |
| Switchboard |
| UTD_NLP | 35.2 | 21.3 | 26.5 | 52.3 | 30.4 | 38.5 | 50.5 | 34.9 | 41.3 | 35.4 |
| coref-hoi | 31.5 | 30.4 | 31.0 | 40.9 | 34.0 | 37.1 | 51.4 | 30.2 | 38.0 | 35.4 |
| coref-hoi-utt | 30.6 | 29.3 | 29.9 | 39.5 | 32.7 | 35.8 | 49.5 | 29.2 | 36.7 | 34.1 |
| dd-utt | 46.3 | 43.4 | 44.8 | 54.9 | 44.5 | 49.2 | 63.4 | 38.3 | 47.7 | 47.2 |
+
+Table 8: Resolution results on the test sets.
+
+ | LIGHT | AMI | Persuasion | Switchboard |
| P | R | F | P | R | F | P | R | F | P | R | F |
| Overall | UTD_NLP | 65.2 | 46.9 | 54.6 | 60.2 | 39.1 | 47.4 | 72.3 | 41.6 | 52.8 | 64.4 | 42.2 | 51.0 |
| coref-hoi | 62.9 | 49.5 | 55.4 | 40.5 | 42.7 | 41.5 | 68.6 | 52.0 | 59.2 | 55.3 | 41.2 | 47.2 |
| coref-hoi-utt | 59.3 | 50.0 | 54.2 | 43.9 | 45.2 | 44.5 | 66.2 | 57.6 | 61.6 | 53.3 | 39.6 | 45.5 |
| dd-utt | 72.6 | 46.9 | 57.0 | 57.8 | 46.6 | 51.6 | 73.9 | 54.7 | 62.8 | 66.9 | 49.6 | 57.0 |
| Anaphor | UTD_NLP | 71.4 | 68.8 | 70.1 | 58.0 | 64.4 | 61.0 | 76.7 | 64.2 | 69.9 | 65.7 | 70.7 | 68.1 |
| coref-hoi | 71.8 | 70.0 | 70.9 | 42.2 | 59.3 | 49.3 | 72.9 | 63.4 | 67.8 | 63.0 | 60.8 | 61.9 |
| coref-hoi-utt | 68.2 | 72.5 | 70.3 | 46.4 | 60.2 | 52.4 | 71.3 | 70.7 | 71.0 | 61.9 | 59.3 | 60.6 |
| dd-utt | 81.0 | 63.8 | 71.3 | 57.9 | 55.9 | 56.9 | 77.9 | 65.9 | 71.4 | 67.5 | 63.1 | 65.2 |
| Antecedent | UTD_NLP | 50.8 | 27.7 | 35.8 | 66.0 | 20.5 | 31.3 | 59.6 | 21.2 | 31.3 | 60.8 | 21.5 | 31.7 |
| coref-hoi | 52.7 | 34.8 | 41.9 | 38.3 | 30.4 | 33.9 | 63.9 | 42.5 | 51.0 | 46.3 | 27.2 | 34.3 |
| coref-hoi-utt | 49.4 | 33.9 | 40.2 | 41.0 | 34.2 | 37.3 | 60.7 | 46.6 | 52.7 | 43.3 | 25.5 | 32.1 |
| dd-utt | 63.9 | 34.8 | 45.1 | 57.7 | 39.8 | 47.1 | 69.5 | 45.2 | 54.8 | 66.2 | 40.0 | 49.8 |
+
+Table 9: Mention extraction results on the test sets.
\ No newline at end of file
diff --git a/endtoendneuraldiscoursedeixisresolutionindialogue/images.zip b/endtoendneuraldiscoursedeixisresolutionindialogue/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..f1f5befc9f2d45f82d6f759b1b80537fbcecb059
--- /dev/null
+++ b/endtoendneuraldiscoursedeixisresolutionindialogue/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c2a021842dc5cb1bec949bb8e08c23cda5a3d9dc5e615dc592390501a6fc5d81
+size 481543
diff --git a/endtoendneuraldiscoursedeixisresolutionindialogue/layout.json b/endtoendneuraldiscoursedeixisresolutionindialogue/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..df47142fa0cff4daa1849993ef374573618dd181
--- /dev/null
+++ b/endtoendneuraldiscoursedeixisresolutionindialogue/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e3647156fd024c339bcb5f4f24f86be80697c2a2e02fbe3aa3383e8691835acb
+size 449045
diff --git a/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_content_list.json b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..3ba68f1dd17220154e7a0bec4475047f1d008392
--- /dev/null
+++ b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:be076bff3647ba6148cbab881f653a8abe39c7e03b708beac3baaa1acf1f9145
+size 75691
diff --git a/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_model.json b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..624af6a2c422fad8e7c3eb1be773bbbeaef4f9b1
--- /dev/null
+++ b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:492da033498328d2094962309ead8708222ecb01bd9af6128065df5abb08c251
+size 93328
diff --git a/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_origin.pdf b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..2815da12cf0291eb3991aa2688bda4e12662cd1d
--- /dev/null
+++ b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/1f8733bd-79a4-4d9d-93bf-b2fbbe6cc266_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a53cc4ea433430711bc8ceabc13b2e7073df3a6869a4ddfec63429f6911393fc
+size 9255972
diff --git a/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/full.md b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..c6752f570bdf772ed18ea13e5d7fd6fba67f98f8
--- /dev/null
+++ b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/full.md
@@ -0,0 +1,302 @@
+# End-to-End Unsupervised Vision-and-Language Pre-training with Referring Expression Matching
+
+Chi Chen $^{1,2,5}$ , Peng Li $^{*3}$ , Maosong Sun $^{1,2,5}$ , Yang Liu $^{*1,2,3,4,5,6}$
+
+$^{1}$ Dept. of Comp. Sci. & Tech., Institute for AI, Tsinghua University, Beijing, China
+
+$^{2}$ Beijing National Research Center for Information Science and Technology
+
+$^{3}$ Institute for AI Industry Research, Tsinghua University, Beijing, China
+
+4Beijing Academy of Artificial Intelligence, Beijing, China
+
+$^{5}$ International Innovation Center of Tsinghua University, Shanghai, China
+
+$^{6}$ Quan Cheng Laboratory
+
+# Abstract
+
+Recently there has been an emerging interest in unsupervised vision-and-language pre-training (VLP) that learns multimodal representations without parallel image-caption data. These pioneering works significantly reduce the cost of VLP on data collection and achieve promising results compared to supervised VLP. However, existing unsupervised VLP methods take as input pre-extracted region-based visual features from external object detectors, which both limits flexibility and reduces computational efficiency. In this paper, we explore end-to-end unsupervised VLP with a vision encoder to directly encode images. The vision encoder is pre-trained on image-only data and jointly optimized during multimodal pre-training. To further enhance the learned cross-modal features, we propose a novel pre-training task that predicts which patches contain an object referred to in natural language from the encoded visual features. Extensive experiments on four vision-and-language tasks show that our approach outperforms previous unsupervised VLP methods and obtains new state-of-the-art results1.
+
+# 1 Introduction
+
+Vision-and-language pre-training (VLP) (Lu et al., 2019; Li et al., 2019; Chen et al., 2020; Kim et al., 2021; Li et al., 2021c; Zhang et al., 2021; Radford et al., 2021; Ramesh et al., 2021) has achieved great success on a wide range of vision-and-language tasks, e.g., visual question answering (Zhang et al., 2021), image-text retrieval (Radford et al., 2021) and text-to-image generation (Ramesh et al., 2021). The major challenge for VLP is how to bridge the gap between the representations of vision and language modalities, which is typically ad
+
+dressed by training on large-scale parallel image-text datasets (Lin et al., 2014; Krishna et al., 2017; Sharma et al., 2018; Ordonez et al., 2011) with specially designed pre-training tasks. However, these datasets require either extensive human annotations or massive data cleaning efforts, making them difficult to collect, especially when compared to the large amount of unimodal data.
+
+To alleviate this problem, there has recently emerged some works exploring unsupervised vision-and-language pre-training (UVLP), where only non-parallel image and text data is leveraged (Li et al., 2021b; Zhou et al., 2022). Specifically, Li et al. (2021b) propose to use image region features and their detected object tags produced by an object detector as pesudo-parallel pairs to bridge the gap between the two modalities. Zhou et al. (2022) further enrich the training data with retrieved text pieces based on object tags and pre-train their model with multi-granular alignment tasks. These works achieve competitive results compared to several supervised VLP models, demonstrating the potential of UVLP.
+
+However, current research on UVLP adopts a two-step training strategy that first extracts region-based image features with an external object detector and then builds a multimodal model based on the region features. This is considered to have several limitations for VLP. First, region features may be sub-optimal for VLP because they are designed for object detection tasks rather than general cross-modal understanding and are fixed in the pre-training process (Xu et al., 2021; Huang et al., 2021). Second, the process of extracting region features is time-consuming, which significantly reduces the inference efficiency (Kim et al., 2021). Finally, this two-step training strategy hinders the use of vision pre-trained models (V-PTMs) such as ViT (Dosovitskiy et al., 2020) and Swin Transformer (Liu et al., 2021c), which are not off
+
+the-shelf object detectors but achieve promising performance on general vision tasks. Therefore, how to perform UVLP in an end-to-end manner, i.e., using raw images instead of region features, is still a valuable open question.
+
+To explore the question, we propose an end-to-end UVLP framework named E2E-UVLP. The framework consists of a vision encoder and a pretrained language model (PLM), both of which are pre-trained on unimodal data and they are connected by a linear projection layer. Taking image patches as input, our framework is capable of leveraging a wide range of V-PTMs. Without using object tags in inference, the computational cost introduced by external object detectors is eliminated. Inspired by previous works (Li et al., 2021b; Zhou et al., 2022; Liu et al., 2021b; Li et al., 2020), we derive a masked tag prediction (MTP) pre-training task which predicts the masked object tags given a raw image and the other object tags detected from it. Combining MTP with the widely used masked language modeling (MLM) task (Devlin et al., 2018), we successfully make E2E-UVLP achieve comparable or better results than existing UVLP methods, justifying end-to-end UVLP is feasible.
+
+Although the MTP task is effective, further investigation reveals that the obtained model is less effective when dealing with complex attributes of objects, e.g., locating objects or determining the relationship between objects in an image. We argue it is due to two pitfalls of the MTP objective: (1) Discrepancy between training and inference: An object is referred to by its tag and numerically encoded position in training, while referred to only in natural language in inference. Similar discrepancies have been shown to hurt performance significantly in PLM studies (Brown et al., 2020; Liu et al., 2021a). (2) Natural language expression insensitivity: As both the tag and the position of an object have been given in training, the model does not need to locate or distinguish objects by itself, not to say grounding natural language expressions on visual concepts. To alleviate the problems, we propose a novel pre-training task named referring expression matching (REM). Given an image split into patches and an object tag, we convert the tag into a referring expression heuristically (e.g., "man on the right") and predict which patches contain the referred object. By using the synthetic referring expressions in training, the discrepancy has been reduced. Moreover, thanks to the promising language processing
+
+ability of PLMs, the obtained model generalizes well from the limited heuristically selected expressions to unseen ones in training, resulting in better downstream task performance.
+
+In summary, our contributions are three-fold:
+
+- A novel framework E2E-UVLP is proposed to perform end-to-end unsupervised vision-and-language pre-training without using costly and sub-optimal region features relied heavily by previous works.
+- A referring expression matching pre-training task is proposed to reduce training-inference discrepancy and improve generalization to richer natural language expressions.
+- Extensive experiments on four representative vision-and-language tasks show the superiority of our proposed framework over strong unsupervised baselines.
+
+# 2 Method
+
+# 2.1 Model Architecture
+
+As shown in Figure 1, our proposed E2E-UVLP consists of a vision encoder and a pre-trained language model acting as a multimodal encoder. The vision encoder can be a vision pre-trained model such as ViT (Dosovitskiy et al., 2020) and Swin Transformer (Liu et al., 2021c). Each image $I$ is encoded by the vision encoder into a sequence of patch features. These patch features are then linearly projected and added with corresponding modal-type embeddings to form the vision representations $V = \{\mathbf{v}_1,\dots ,\mathbf{v}_N\}$ where $N$ is the number of patches. For text input $L$ , it is tokenized into a sequence of word tokens. Each token's representation $\mathbf{t}_i$ is the sum of its word embeddings, its position or location embeddings (depending on the type of text input), and its modal-type embeddings. The resulting text representations $T = \{\mathbf{t}_1,\dots ,\mathbf{t}_M\}$ are then concatenated with $V$ and fed into the multimodal encoder to get multimodal representations. We use BERT (Devlin et al., 2018) to initialize the multimodal encoder and word embeddings. Finally, the multimodal representations are used for different kinds of pre-training and fine-tuning tasks.
+
+# 2.2 Pesudo-Parallel Data Synthesis
+
+Since there is no parallel image-text data available in unsupervised vision-and-language pretraining (UVLP), it is important to find other ways
+
+
+Figure 1: Overview of our proposed E2E-UVLP framework. The model learns cross-modal representations from non-parallel text and image data in an end-to-end fashion (Section 2.1). To bridge the gap between the two modalities, we generate pseudo-parallel text $L_{\mathrm{tag}}$ and $L_{\mathrm{exp}}$ for each image $I$ (Section 2.2). On the right side, we illustrate how to conduct pre-training tasks using different types of data (Section 2.3).
+
+to bridge the gap between the two modalities. Inspired by Li et al. (2021b), we use detected object tags of each image to synthesize pseudo-parallel image-text data, which are used in the pre-training tasks for E2E-UVLP. Specifically, for each image $I$ , we use an external object detector to generate its object proposals $\{(o_i,b_i)\}_{i = 1}^K$ , where $o_i$ is the object tag and $b_{i}\in \mathcal{R}^{4}$ denotes the bounding box location. We derive two kinds of pseudo-parallel image-text data for each image and its corresponding object proposals.
+
+Image-Tag Pair Because $\{o_i\}_{i = 1}^K$ are essentially a bag of text words that describe the objects detected in the image, they can be viewed as text data weakly aligned with the image. We concatenate the object tags to form a text input $L_{\mathrm{tag}} = o_1,\ldots ,o_K$ and compute the location embeddings for $o_i$ as a linear projection of $b_{i}$ . Each token in the tokenized $L_{\mathrm{tag}}$ is embedded as the sum of its word embeddings and location embeddings. The reason for using location embeddings instead of position embeddings as for natural text is to distinguish between objects of the same category in the same image. We
+
+name this kind of synthetic data $(I,L_{\mathrm{tag}})\in \mathcal{D}_{\mathrm{tag}}$ as image-tag paired data.
+
+Image-Expression Pair The text input in image-tag paired data differs from natural text in two ways. First, it is composed of only noun words and does not conform to the grammar of natural language. Second, the location annotations do not exist in real text. We will discuss later the limitations of models trained on such data in Section 2.3. Here we describe another kind of synthetic peso-parallel data called image-expression paired data, which is more similar to real text. The idea is to generate a referring expression for one object in the image that can distinguish it from other objects (e.g., "smaller white sheep on the right" in Figure 2).
+
+Specifically, for an image $I$ and its detected object proposals $\{(o_i,b_i)\}_{i = 1}^K$ , we first use nonmaximum suppression (NMS) to remove the redundant proposals with high overlap and filter out proposals with low prediction confidence. Then we randomly select one object $(o_k,b_k)$ and find all proposals of the same category $\{(o_i,b_i)\}_{i = 1\dots K}^{o_i = o_k}$ . Based on these object proposals, we identify a
+
+
+Figure 2: An illustration of the process of synthesizing referring expressions. We randomly select one target object and heuristically generate discriminative descriptions based on the bounding boxes of all objects of the same class.
+
+group of cues that can discriminate the target object $(o_k, b_k)$ from other objects and heuristically convert them into a referring expression. Inspired by Kazakos et al. (2021), we consider attributes generated from the object detectors for these objects, as well as the the relative size and position between the target object and other objects of the same object class. For the first example in Figure 2, as the area of the bounding box of the right object is smaller than that of the left one, we add a size description "smaller" to the expression. The final referring expression $L_{\mathrm{exp}}$ is the combination of size, attribute, object and position descriptions, guaranteed to refer to the target object in the image. $L_{\mathrm{exp}}$ and $I$ together form the image-expression paired data $(I, L_{\mathrm{exp}}) \in \mathcal{D}_{\mathrm{exp}}$ .
+
+# 2.3 Pre-training Tasks
+
+In this section, we introduce the pre-training tasks that enable our proposed E2E-UVLP to learn effective multimodal representations using only non-parallel image and text data without region features.
+
+Masked Tag Prediction (MTP) This task aims to learn the alignment of the object concepts in two modalities using the image-tag paired data. Inspired by Li et al. (2021b), we randomly mask out the tags in $L_{\mathrm{tag}}$ and predict the masked tags conditioned on the raw image and other tags. Note that region features are conditioned on instead of the raw image in (Li et al., 2021b).
+
+Specifically, the objective for MTP is computed
+
+as follows:
+
+$$
+\mathcal {L} _ {\mathrm {M T P}} = - \mathbb {E} _ {(I, L _ {\mathrm {t a g}}) \sim \mathcal {D} _ {\mathrm {t a g}}} \log P (T _ {\mathbf {m}} \mid T _ {\backslash \mathbf {m}}, V), \tag {1}
+$$
+
+where $T_{\mathbf{m}}$ and $T_{\backslash \mathbf{m}}$ denote the masked tags and observed tags, respectively. For the masked tags, we keep the original bounding box locations and replace only the object tags with the special mask tokens. Different from previous works, we do not apply masked vision modeling (MVM) for the image-tag paired data, as it has been shown to cause performance degradation for end-to-end VLP (Dou et al., 2022). We also study object-guided masked vision modeling (Liu et al., 2021b), which aims to predict region features from grid image features, and observe no improvement compared to using MTP alone. We assume this is because $L_{\mathrm{tag}}$ already carries the object information, thus making such a task trivial.
+
+Although MTP is effective, we find that the models trained with it are less effective in dealing with complex attributes of objects. For example in Figure 3, the model pre-trained with MTP provides an incorrect answer probably because it fails to focus on the correct patches of the object required in the question. We assume that this is due to two pitfalls of the MTP objective: (1) Discrepancy between training and inference. During pre-training, the text input $L_{\mathrm{tag}}$ is composed of objects with their tags and bounding box locations, unlike natural language sentences used in inference, which use positional encoding. In PLM studies, similar discrepancies have been shown to significantly impair performance (Brown et al., 2020; Liu et al.,
+
+
+MTP: lettuce
+Figure 3: Comparison between VQA models fine-tuned from pre-trained models with different pre-training tasks. We visualize the most relevant patches for the keyword "food" in the given question. The model pretrained with only MTP fails to identify the corresponding patches, which leads to a wrong answer.
+
+
+Q: what food is to the left of the carrots?
+MTP+REM: broccoli
+
+2021a). (2) Natural language expression insensitivity. When trained with MTP, the model only needs to predict the tags of masked objects at given locations, rather than identifying target objects corresponding to natural language expressions from raw images. This problem is more pronounced in end-to-end UVLP because the images are encoded without using any object information.
+
+Referring Expression Matching (REM) To alleviate the deficiencies of MTP, we design this novel pre-training task based on the image-expression paired data described in Section 2.2. The task of REM is to predict the position of the object referred to by the synthetic referring expression $L_{\mathrm{exp}}$ . We use the bounding box of the referred object as ground truth and convert it to a binary mask $R \in \{0,1\}^N$ of the same size as the patch features, where the values corresponding to the inside of the bounding box are set to 1 and the others are set to 0. Then, given the model's prediction $\hat{R} = f(I,L_{\mathrm{exp}}) \in [0,1]^N$ , we define the REM objective as
+
+$$
+\mathcal {L} _ {\mathrm {R E M}} = \mathbb {E} _ {(I, L _ {e x p}) \sim \mathcal {D} _ {e x p}} \mathrm {D L} (R, \hat {R}) + \mathrm {B C E} (R, \hat {R}), \tag {2}
+$$
+
+where DL is the soft dice loss
+
+$$
+\mathrm {D L} (R, \hat {R}) = 1 - \frac {2 \sum_ {i = 1} ^ {N} r ^ {i} \cdot \hat {r} ^ {i}}{\sum_ {i = 1} ^ {N} r ^ {i} + \sum_ {i = 1} ^ {N} \hat {r} ^ {i}}, \tag {3}
+$$
+
+and BCE is the binary cross entropy loss
+
+$$
+\begin{array}{l} \operatorname {B C E} (R, \hat {R}) = - \sum_ {i = 1} ^ {N} \left((1 - r ^ {i}) \log \left(1 - \hat {r} ^ {i}\right) \right. \tag {4} \\ \left. + r ^ {i} \log \left(\hat {r} ^ {i}\right)\right). \\ \end{array}
+$$
+
+We use these two losses because they have been proven to be effective in image segmentation (Isensee et al., 2018), which aims to classify each pixel in an image into a certain object class.
+
+We assume that using REM as a pre-training task can complement MTP in two ways. First, it will alleviate the discrepancy between training and inference as the model observes the text input in the form of natural language. Second, it explicitly enforces the model to localize the referred object from patch features, which strengthens the alignment between the learned visual concepts and the related linguistic expressions. As shown in Figure 3, the model pre-trained with MTP and REM successfully locates the corresponding image patches and gives the correct answer.
+
+Masked Language Modeling (MLM) We also apply MLM on the text-only input to predict the masked tokens based on the surrounding text context. Given text input $L$ from the text-only corpus $\mathcal{D}_L$ , we formulate the MLM objective as
+
+$$
+\mathcal {L} _ {\mathrm {M L M}} = - \mathbb {E} _ {L \sim \mathcal {D} _ {L}} \log P (T _ {\mathbf {m}} \mid T _ {\backslash \mathbf {m}}). \tag {5}
+$$
+
+Note that no aligned images are observed in the computation of the MLM.
+
+# 3 Experiments
+
+# 3.1 Datasets
+
+Following previous UVLP works (Li et al., 2021b; Zhou et al., 2022), we take images and captions from Conceptual Captions (CC) (Sharma et al., 2018) without the alignment information to construct the unsupervised image and text datasets. We also try a more realistic setting to use images from CC and sentences from BookCorpus (Zhu et al., 2015) where images and text are collected separately from different domains. Similar to (Li et al., 2021b), we downsample the BookCorpus dataset to ensure the number of sentences in each training epoch is the same as the number of images.
+
+# 3.2 Baselines
+
+We compare our E2E-UVLP with both supervised and unsupervised vision-language pre-trained models. For supervised vision-language pre-trained models, we compare with models using different kinds of image features including region features (VisualBERT (Li et al., 2019), UNITER (Chen et al., 2020) and VinVL (Zhang et al., 2021)), grid features (E2E-VLP (Xu et al., 2021) and
+
+| Model | Visual Embed | VQA2 Test-Dev | NLVR2 Test-P | VE Test | R@1 | Flickr30k R@5 | R@10 |
| Supervised (w/ Paired Image-Text Data) |
| VisualBERT (Li et al., 2019) | Region | 70.9 | 73.9 | - | 61.2 | 86.3 | 91.9 |
| UNITER (Chen et al., 2020) | Region | 72.7 | 77.9 | 78.3 | 72.5 | 92.4 | 96.1 |
| VinVL (Zhang et al., 2021) | Region | 76.0 | 83.1 | - | - | - | - |
| E2E-VLP (Xu et al., 2021) | Grid | 72.4 | 75.2 | - | - | - | - |
| SOHO (Huang et al., 2021) | Grid | 73.3 | 77.3 | - | 72.5 | 92.7 | 96.1 |
| ViLT (Kim et al., 2021) | Patch | 71.3 | 76.1 | - | 66.4 | 88.7 | 93.8 |
| Visual Parsing (Xue et al., 2021) | Patch | 74.0 | 78.1 | - | 73.5 | 93.1 | 96.4 |
| ALBEF (Li et al., 2021a) | Patch | 74.5 | 80.5 | 80.3 | 82.8 | 96.7 | 98.4 |
| METER-CLIP-ViTBASE (Dou et al., 2022) | Patch | 77.7 | 83.0 | 81.2 | 82.2 | 96.3 | 98.3 |
| Unsupervised (w/o Paired Image-Text Data) |
| U-VisualBERT (Li et al., 2021b) | Region | 70.7 | 71.0 | - | 55.4 | 82.9 | 89.8 |
| U-VisualBERTVinVL (Zhou et al., 2022) | Region | 71.8 | 53.2 | 76.8 | - | - | - |
| μ-VLA (Zhou et al., 2022) | Region | 72.1 | 73.4 | 77.3 | - | - | - |
| E2E-UVLP | Patch | 73.3 | 74.6 | 78.2 | 66.4 | 89.7 | 94.1 |
+
+Table 1: Evaluation results on four V+L downstream tasks. All unsupervised models are pre-trained on non-parallel images and text from CC. Our proposed E2E-UVLP outperforms previous UVLP methods, and achieves comparable performance to some supervised VLP models.
+
+| Method | Visual Embed | VQA2 Test-Dev | NLVR2 Test-P | VE Test | Flickr30k |
| R@1 | R@5 | R@10 |
| U-VisualBERT | Region | 70.5 | 71.2 | - | 54.4 | 82.2 | 89.2 |
| μ-VLA | Region | 71.2 | 67.1 | 77.1 | - | - | - |
| E2E-UVLP | Patch | 73.5 | 73.7 | 77.9 | 65.6 | 90.3 | 94.7 |
+
+Table 2: Experimental results of pre-training with images from CC and text from BookCorpus.
+
+SOHO (Huang et al., 2021)) and patch features (ViLT (Kim et al., 2021), Visual Parsing (Xue et al., 2021), ALBEF (Li et al., 2021a) and METER-CLIP-ViTBASE(Dou et al., 2022)). Note that in addition to the CC dataset we use for pre-training, these models typically use other parallel data sources such as MSCOCO (Lin et al., 2014), VG (Krishna et al., 2017) and SBU (Ordonez et al., 2011).
+
+For unsupervised vision-language pre-trained models, we compare with U-VisualBERT (Li et al., 2021b), U-VisualBERT $_{\mathrm{VinVL}}$ which is a version of U-VisualBERT with VinVL object features re-implemented by Zhou et al. (2022), and $\mu$ -VLA (Zhou et al., 2022). All of these models use region-based image features.
+
+# 3.3 Implementation Details
+
+For the model architecture of E2E-UVLP, we use a 12-layer Swin-Transformer as the image encoder and a 12-layer Transformer acting as the multimodal encoder, which are initialized with pretrained weights of Swin-B/32 and BERT-base, respectively. We utilize the widely-used object detector BUTD (Anderson et al., 2018) to extract object proposals for the images as in other region-based
+
+VLP methods. We resize each image to the size of $384 \times 384$ with center-cropping for both pretraining and fine-tuning.
+
+For the pre-training of E2E-UVLP, we set the total training iterations to 100k with a batch size of 512. We use AdamW with a peak learning rate of $3 \times 10^{-5}$ . The learning rate is warmed-up to the peak value in the first $10\%$ of the iterations, and then linearly decayed to 0. All the pre-training experiments are conducted on 16 NVIDIA V100s with 32GB memory per GPU.
+
+We evaluate our model on four typical downstream tasks: Visual Question Answering (VQA) (Goyal et al., 2017), Natural Language for Visual Reasoning (NLVR2) (Suhr et al., 2018), Visual Entailment (VE) (Xie et al., 2019) and Image Retrieval on Flickr30k (Flickr30k) (Plummer et al., 2015). For details of the downstream tasks, please refer to the appendix.
+
+# 3.4 Results
+
+Table 1 shows the main results of E2E-UVLP on four downstream tasks. For each model, we list the type of image features used for pre-training. From the table we can see that E2E-UVLP con
+
+
+black paw at the bottom left
+
+
+larger blue umbrella at the bottom left
+
+
+white window on the left
+
+
+sitting man on the left
+
+
+gold book at the bottom right
+
+
+smaller white sign at the bottom right
+
+
+Figure 4: Examples of the synthetic image-expression paired data. We mark the objects referred to with red bounding boxes. The generated expressions are able to distinguish the target object from other objects in the image by heuristically adding size and position descriptions to the detected object tags and attributes.
+
+
+white cloud on the right
+the biggest walking manat the bottom right
+
+sistently outperforms previous UVLP methods on all downstream tasks, which demonstrates that our end-to-end approach can learn a better cross-modal representation than the approaches using region features. When compared to supervised VLP models, our model achieves competitive results. Specifically, our model achieves a VQA score of $73.3\%$ on the test-dev split, which is even higher than the performance of some supervised models. Finally, note that in the supervised VLP, the best model using region features (VinVL) performs better than the models using other types of image features, while in the unsupervised setting our approach using patch features outperforms the methods based on the same region features of VinVL. We attribute this to the use of the pre-training task that is more suitable for patch features in unsupervised VLP, i.e., REM (Section 2.3).
+
+We also investigate pre-training using images from CC and text from BookCorpus, and the results are shown in Table 2. Previous works suggest that experimental results in this setting decline notably compared to pre-training with the in-domain CC captions (Li et al., 2021b; Zhou et al., 2022). In our experiments, however, we observe comparable or only slightly degraded performance on three of the four downstream tasks. On the VQA task, the model trained on BookCorpus is even slightly better than the model trained on CC by $0.2\%$ . These
+
+| Pre-training Tasks | VQAl2 Test-Dev | NLVR2 Test-P |
| None | 70.1 | 51.2 |
| MLM | 69.9 | 50.3 |
| MTP | 71.7 | 67.4 |
| REM | 70.7 | 70.4 |
| MTP + REM | 72.8 | 72.8 |
| MLM + MTP | 72.6 | 74.1 |
| MLM + REM | 73.2 | 74.5 |
| MTP + MLM + REM | 73.6 | 74.6 |
+
+Table 3: Ablation study of different pre-training tasks. All models are pre-trained with non-parallel images and text from MSCOCO.
+
+results demonstrate that our model is robust to the sources of text and image data, which makes it more practical in realistic scenarios.
+
+# 3.5 Ablation Study
+
+In this section, we conduct an ablation study on the pre-training tasks. To save experimental cost, we pre-train the models with non-parallel images and text from MSCOCO and only report results on the VQA and NLVR2 tasks. Table 3 shows the results. We use "None" to represent the results of training directly on the downstream tasks without pre-training. From the table, we can see that: (1) Cross-modal inputs (MTP/REM) and MLM are two key factors for the success of E2E-UVLP, as removing either of them will bring a significant
+
+performance degradation. Specifically, the combination of MTP and MLM can achieve decent results for E2E-UVLP, which illustrates the feasibility of end-to-end pre-training. (2) It is better to use both MTP and REM for pre-training than to use only one of them.. This verifies our assumption in Section 2.3 that REM can complement MTP and facilitate the model to learn better cross-modal representations. (3) Replacing MTP with REM can improve the performance on both of the downstream tasks, indicating that REM is possibly a more effective pre-training task for UVLP.
+
+# 3.6 Visualization
+
+In Figure 4, we provide some examples of the generated image-expression pairs as described in Section 2.2. As we can see, the generated referring expressions are able to distinguish the target object from other objects in the image by heuristically adding discriminative size and position descriptions. For example, in the second image, there are two umbrellas both with the attribute of the color blue. Since the target object has a larger bounding box, a size description "larger" is added. Similarly, by taking into account the relative positions of the two bounding boxes, a position description of "at the bottom left" is added. The resulting expression will be able to distinguish between the two objects.
+
+# 4 Related Work
+
+Vision-and-Language Pre-training Current research on visual-and-language pre-training (VLP) can be generally divided into two categories: the two-step training strategy and the end-to-end training strategy. Most works (Lu et al., 2019; Li et al., 2019; Chen et al., 2020; Zhang et al., 2021) fall into the first category where they first use external object detectors such as BUTD (Anderson et al., 2018) to extract region features for the images and then use them together with text embeddings to generate multimodal representations. However, the region features may be sub-optimal for VLP because they are designed for object detection tasks and are fixed during the pre-training process (Xu et al., 2021; Huang et al., 2021). Recently, some works integrate the encoding of images into the pretraining process, taking the raw images as input to learn the vision-and-language representations in an end-to-end fashion. These approach can be further categorized into the ones using grid features encoded with CNNs such as E2E-VLP (Xu et al.,
+
+2021) and SOHO (Huang et al., 2021), and the ones using patch features encoded with ViTs such as ViLT (Kim et al., 2021), Visual Parsing (Xue et al., 2021) and ALBEF (Li et al., 2021a). In this work, we apply a similar end-to-end approach to unsupervised visual-and-language pre-training with image patch features.
+
+All of these works on VLP require access to large-scale parallel image-text datasets (Lin et al., 2014; Krishna et al., 2017; Sharma et al., 2018; Ordonez et al., 2011), which are difficult to collect due to the large amount of annotations or data cleaning efforts required. To alleviate this problem, some recent works explore unsupervised vision-and-language pre-training has emerged, in which only non-parallel image and text data are utilized. Our work also belongs to this category.
+
+Unsupervised Vision-and-Language Pretraining Li et al. (2021b) first propose the idea of unsupervised vision-and-language pre-training (UVLP) without using paired image-text data. Their model, U-VisualBERT, is alternately pre-trained on both image-only and text-only data. In addition, they utilize object tags as anchor points for cross-modal alignment to compensate for the absence of aligned data and achieve similar performance to supervised models. Zhou et al. (2022) suggest that using tags alone is not sufficient and propose pre-training tasks for multi-granular alignment learning with a retrieved weakly aligned image-text corpus for UVLP.
+
+The most important difference between our work and previous UVLP works is that we use an end-to-end training approach to implement UVLP, which is the first to the best of our knowledge. Besides, we identify the limitations of models trained with tags and propose a novel pre-training task, REM, to address these deficiencies. As a result, our approach significantly outperforms previous region-based UVLP works on all downstream tasks.
+
+Referring Expression Comprehension and Generation The task of REM is inspired by the research lines of referring expression generation (REG) and comprehension (REC). REG is generally treat as a special case of image captioning to generate referring expressions from visual features with RNNs (Liu et al., 2017; Zarrieß and Schlangen, 2018), while Kazakos et al. (2021) generate synthetic referring expressions heuristically from object annotations. We apply a similar generation
+
+strategy but on the detected object proposals. The task of REC is to localize an object from candidate objects given a referring expression (Mao et al., 2016; Liu et al., 2019), while our proposed REM directly predicts the referred object from patch features without object candidates.
+
+# 5 Conclusion
+
+We propose a novel framework that performs end-to-end unsupervised vision-and-language pretraining without using costly and sub-optimal region features. To reduce the training-inference discrepancy, we propose a new pre-training task that predicts the locations of objects with synthetic referring expressions that are more similar to real text. Experiments show that our approach consistently outperforms existing unsupervised vision-and-language pre-training methods, and achieves competitive results compared to supervised vision-and-language pre-trained models.
+
+# Limitations
+
+Although our approach eliminates the dependence on object detection during inference, it still requires object proposals for pre-training, which would damage the efficiency of pre-training. In addition, our method is limited by the finite number of object tags and the lack of diversity of heuristically generated referring expressions. We hope to address this limitation by jointly training a generator with unsupervised vision-language pre-training that automatically generates referring expressions or other type of psudo-parallel text for the images.
+
+# Acknowledgments
+
+This work was supported by the National Natural Science Foundation of China (No. 61925601), the National Social Science Fund of China (No. 62236011), Beijing Academy of Artificial Intelligence (BAAI), and a grant from the Guoqiang Institute, Tsinghua University. We thank all anonymous reviewers for their valuable comments and suggestions on this work. We also thank Xinyu Ma for his help in the experiments.
+
+# References
+
+Peter Anderson, Xiaodong He, Chris Buehler, Damien Teney, Mark Johnson, Stephen Gould, and Lei Zhang. 2018. Bottom-up and top-down attention for image
+
+captioning and visual question answering. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 6077-6086.
+Samuel R Bowman, Gabor Angeli, Christopher Potts, and Christopher D Manning. 2015. A large annotated corpus for learning natural language inference. arXiv preprint arXiv:1508.05326.
+Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel Ziegler, Jeffrey Wu, Clemens Winter, Chris Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners. In Advances in Neural Information Processing Systems, volume 33, pages 1877-1901. Curran Associates, Inc.
+Yen-Chun Chen, Linjie Li, Licheng Yu, Ahmed El Kholy, Faisal Ahmed, Zhe Gan, Yu Cheng, and Jingjing Liu. 2020. UNITER: Universal image-text representation learning. In ECCV.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. BERT: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint arXiv:1810.04805.
+Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, et al. 2020. An image is worth 16x16 words: Transformers for image recognition at scale. arXiv preprint arXiv:2010.11929.
+Zi-Yi Dou, Yichong Xu, Zhe Gan, Jianfeng Wang, Shuohang Wang, Lijuan Wang, Chenguang Zhu, Pengchuan Zhang, Lu Yuan, Nanyun Peng, et al. 2022. An empirical study of training end-to-end vision-and-language transformers. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 18166-18176.
+Yash Goyal, Tejas Khot, Douglas Summers-Stay, Dhruv Batra, and Devi Parikh. 2017. Making the V in VQA matter: Elevating the role of image understanding in Visual Question Answering. In Conference on Computer Vision and Pattern Recognition (CVPR).
+Zhicheng Huang, Zhaoyang Zeng, Yupan Huang, Bei Liu, Dongmei Fu, and Jianlong Fu. 2021. Seeing out of the box: End-to-end pre-training for vision-language representation learning. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 12976-12985.
+Fabian Isensee, Jens Petersen, Andre Klein, David Zimmerer, Paul F Jaeger, Simon Kohl, Jakob Wasserthal,
+
+Gregor Koehler, Tobias Norajitra, Sebastian Wirkert, et al. 2018. nnU-Net: Self-adapting framework for U-Net-based medical image segmentation. arXiv preprint arXiv:1809.10486.
+Ioannis Kazakos, Carles Ventura, Miriam Bellver, Carina Silberer, and Xavier Giro-i Nieto. 2021. SynthRef: Generation of synthetic referring expressions for object segmentation. arXiv preprint arXiv:2106.04403.
+Wonjae Kim, Bokyung Son, and Ildoo Kim. 2021. ViLT: Vision-and-language transformer without convolution or region supervision. In International Conference on Machine Learning, pages 5583-5594. PMLR.
+Ranjay Krishna, Yuke Zhu, Oliver Groth, Justin Johnson, Kenji Hata, Joshua Kravitz, Stephanie Chen, Yannis Kalantidis, Li-Jia Li, David A Shamma, et al. 2017. Visual Genome: Connecting language and vision using crowdsourced dense image annotations. International journal of computer vision, 123(1):32-73.
+Junnan Li, Ramprasaath Selvaraju, Akhilesh Gotmare, Shafiq Joty, Caiming Xiong, and Steven Chu Hong Hoi. 2021a. Align before fuse: Vision and language representation learning with momentum distillation. Advances in neural information processing systems, 34:9694-9705.
+Lianian Harold Li, Mark Yatskar, Da Yin, Cho-Jui Hsieh, and Kai-Wei Chang. 2019. VisualBERT: A simple and performant baseline for vision and language. arXiv preprint arXiv:1908.03557.
+Lianian Harold Li, Haoxuan You, Zhecan Wang, Alireza Zareian, Shih-Fu Chang, and Kai-Wei Chang. 2021b. Unsupervised vision-and-language pre-training without parallel images and captions. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 5339-5350.
+Wei Li, Can Gao, Guocheng Niu, Xinyan Xiao, Hao Liu, Jiachen Liu, Hua Wu, and Haifeng Wang. 2021c. UNIMO: Towards unified-modal understanding and generation via cross-modal contrastive learning. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2592-2607.
+Xiujun Li, Xi Yin, Chunyuan Li, Pengchuan Zhang, Xiaowei Hu, Lei Zhang, Lijuan Wang, Houdong Hu, Li Dong, Furu Wei, Yejin Choi, and Jianfeng Gao. 2020. Oscar: Object-semantics aligned pre-training for vision-language tasks. In Proceedings of ECCV 2020, pages 121-137, Cham. Springer International Publishing.
+Tsung-Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dollar,
+
+and C Lawrence Zitnick. 2014. Microsoft COCO: Common objects in context. In European conference on computer vision, pages 740-755. Springer.
+Jingyu Liu, Liang Wang, and Ming-Hsuan Yang. 2017. Referring expression generation and comprehension via attributes. In Proceedings of the IEEE International Conference on Computer Vision, pages 4856-4864.
+Pengfei Liu, Weizhe Yuan, Jinlan Fu, Zhengbao Jiang, Hiroaki Hayashi, and Graham Neubig. 2021a. Pretrain, prompt, and predict: A systematic survey of prompting methods in natural language processing. CoRR, abs/2107.13586.
+Xihui Liu, Zihao Wang, Jing Shao, Xiaogang Wang, and Hongsheng Li. 2019. Improving referring expression grounding with cross-modal attention-guided erasing. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 1950-1959.
+Yongfei Liu, Chenfei Wu, Shao-yen Tseng, Vasudev Lal, Xuming He, and Nan Duan. 2021b. KD-VLP: Improving end-to-end vision-and-language pretraining with object knowledge distillation. arXiv preprint arXiv:2109.10504.
+Ze Liu, Yutong Lin, Yue Cao, Han Hu, Yixuan Wei, Zheng Zhang, Stephen Lin, and Baining Guo. 2021c. Swin Transformer: Hierarchical vision Transformer using shifted windows. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pages 10012-10022.
+Jiasen Lu, Dhruv Batra, Devi Parikh, and Stefan Lee. 2019. ViLBERT: Pretraining task-agnostic visiolinguistic representations for vision-and-language tasks. Advances in neural information processing systems, 32.
+Junhua Mao, Jonathan Huang, Alexander Toshev, Oana Camburu, Alan L Yuille, and Kevin Murphy. 2016. Generation and comprehension of unambiguous object descriptions. In Proceedings of the IEEE conference on computer vision and pattern recognition, pages 11-20.
+Vicente Ordonez, Girish Kulkarni, and Tamara Berg. 2011. Im2Text: Describing images using 1 million captioned photographs. Advances in neural information processing systems, 24.
+Bryan A Plummer, Liwei Wang, Chris M Cervantes, Juan C Caicedo, Julia Hockenmaier, and Svetlana Lazebnik. 2015. Flickr30k entities: Collecting region-to-phrase correspondences for richer imageto-sentence models. In Proceedings of the IEEE international conference on computer vision, pages 2641-2649.
+Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark,
+
+Gretchen Krueger, and Ilya Sutskever. 2021. Learning transferable visual models from natural language supervision. In Proceedings of the 38th International Conference on Machine Learning, volume 139 of Proceedings of Machine Learning Research, pages 8748-8763. PMLR.
+Aditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray, Chelsea Voss, Alec Radford, Mark Chen, and Ilya Sutskever. 2021. Zero-shot text-to-image generation. In Proceedings of the 38th International Conference on Machine Learning, volume 139 of Proceedings of Machine Learning Research, pages 8821-8831. PMLR.
+Piyush Sharma, Nan Ding, Sebastian Goodman, and Radu Soricut. 2018. Conceptual Captions: A cleaned, hypernymed, image alt-text dataset for automatic image captioning. In Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 2556-2565.
+Alane Suhr, Stephanie Zhou, Ally Zhang, Iris Zhang, Huajun Bai, and Yoav Artzi. 2018. A corpus for reasoning about natural language grounded in photographs. arXiv preprint arXiv:1811.00491.
+Ning Xie, Farley Lai, Derek Doran, and Asim Kadav. 2019. Visual entailment: A novel task for fine-grained image understanding. arXiv preprint arXiv:1901.06706.
+Haiyang Xu, Ming Yan, Chenliang Li, Bin Bi, Songfang Huang, Wenming Xiao, and Fei Huang. 2021. E2E-VLP: End-to-end vision-language pre-training enhanced by visual learning. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 503-513.
+Hongwei Xue, Yupan Huang, Bei Liu, Houwen Peng, Jianlong Fu, Houqiang Li, and Jiebo Luo. 2021. Probing inter-modality: Visual parsing with self-attention for vision-and-language pre-training. Advances in Neural Information Processing Systems, 34:4514-4528.
+Zhou Yu, Jun Yu, Yuhao Cui, Dacheng Tao, and Qi Tian. 2019. Deep modular co-attention networks for visual question answering. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 6281-6290.
+Sina Zarrieß and David Schlangen. 2018. Decoding strategies for neural referring expression generation. In Proceedings of the 11th International Conference on Natural Language Generation, pages 503-512.
+Pengchuan Zhang, Xiujun Li, Xiaowei Hu, Jianwei Yang, Lei Zhang, Lijuan Wang, Yejin Choi, and Jianfeng Gao. 2021. VinVL: Revisiting visual representations in vision-language models. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pages 5579-5588.
+
+Mingyang Zhou, Licheng Yu, Amanpreet Singh, Mengjiao Wang, Zhou Yu, and Ning Zhang. 2022. Unsupervised vision-and-language pre-training via retrieval-based multi-granular alignment. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 16485-16494.
+Yukun Zhu, Ryan Kiros, Rich Zemel, Ruslan Salakhutdinov, Raquel Urtasun, Antonio Torralba, and Sanja Fidler. 2015. Aligning books and movies: Towards story-like visual explanations by watching movies and reading books. In Proceedings of the IEEE international conference on computer vision, pages 19-27.
+
+# A Details of Downstream Tasks
+
+Most of our settings on downstream tasks follow the setup of ViLT (Kim et al., 2021) with small adjustments, as detailed below.
+
+VQA The VQA task involves answering the question according to the given image, which requires an understanding of both vision and language. Following Kim et al. (2021), we fine-tune the model on the train and validation sets, and 1,000 validation image-question pairs are reserved for internal validation. We use the 3, 129 most frequent answers as answer candidates following Yu et al. (2019). We set the batch size to 256 and the peak learning rate to $5 \times 10^{-5}$ . The model is fine-tuned for 10 epochs.
+
+NLVR2 The task of NLVR2 is to determine whether a natural language description is true given a pair of images. Following Kim et al. (2021), we reformulate the input to two image-caption pairs, concatenating the two representations as the input of a classification head. Following Li et al. (2021b), we perform task-specific pre-training before fine-tuning using mask-and-predict objective for 10 epochs. The batch size is 256 and the peak learning rate is $1 \times 10^{-5}$ . During fine-tuning, we use a batch size of 128 and set the peak learning rate to $1 \times 10^{-5}$ . The model is fine-tuned for 10 epochs.
+
+VE The VE task is derived from Flickr30K (Plummer et al., 2015) images and Stanford Natural Language Inference (SNLI) (Bowman et al., 2015) dataset. Given an image premise P and text hypothesis H, the task aims to determine whether P implies H. This task is a 3-way classification problem to output entailment, neutral, or contradiction based on the relation inferred from the input image-text pair. The batch size is set as 256 and we set the peak learning rate as $7 \times 10^{-5}$ to train for 5 epochs.
+
+Image Retrieval Given a caption, the image retrieval task is to find the corresponding image from a collection of images. Following UNITER (Chen et al., 2020), we sample 31 negative image-text pairs along with a positive sample to construct a mini-batch for each GPU. The model is fine-tuned for 10 epochs with a peak learning rate of $5 \times 10^{-5}$ .
\ No newline at end of file
diff --git a/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/images.zip b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..761272eefaf7574d7856f09072e56cf417639e2c
--- /dev/null
+++ b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:86c46cd2897100c4ee39ee08bae09e78fa890a617305eff83205ee5dfa2823b2
+size 466658
diff --git a/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/layout.json b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..386af5d8cd670004e6c0b839e58701389b412d95
--- /dev/null
+++ b/endtoendunsupervisedvisionandlanguagepretrainingwithreferringexpressionmatching/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:fd4bf921bddc217110066eee8c11c57f87ba67ac306b92ec1616b9860183d1e2
+size 344948
diff --git a/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_content_list.json b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..ebe902be67ec2496fd535f035d508a7bb24d82cf
--- /dev/null
+++ b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:adefdd5c46b08ce868395d50128310433680a15b0f79380ca48500cb6bc1e7c4
+size 78715
diff --git a/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_model.json b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..3be4d115e9ebe7dc82dc519eaaa52079106bb998
--- /dev/null
+++ b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c1289619d5cadcb20c0a38a5644fc0c08e8215841e15b65247231b42991d0f26
+size 96234
diff --git a/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_origin.pdf b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..9ff2b6d37027ac355aef11fd692fe18518891619
--- /dev/null
+++ b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/8f5682d2-6f51-4a7f-bc3a-a24408b8cae7_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:a6b9dbbc91517f490041d2fe40492bd88e66d152cb6dbd16f58c25c3d46dc839
+size 441379
diff --git a/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/full.md b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..06ebe8e730ada5bdd4f610ae7837d20f517cf178
--- /dev/null
+++ b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/full.md
@@ -0,0 +1,294 @@
+# English Contrastive Learning Can Learn Universal Cross-lingual Sentence Embeddings
+
+Yau-Shian Wang Ashley Wu Graham Neubig
+
+Carnegie Mellon University
+
+king6101@gmail.com wangchew@andrew.cmu.edu
+
+gneubig@cs.cmu.edu
+
+# Abstract
+
+Universal cross-lingual sentence embeddings map semantically similar cross-lingual sentences into a shared embedding space. Aligning cross-lingual sentence embeddings usually requires supervised cross-lingual parallel sentences. In this work, we propose mSimCSE, which extends SimCSE (Gao et al., 2021) to multilingual settings and reveal that contrastive learning on English data can surprisingly learn high-quality universal cross-lingual sentence embeddings without any parallel data. In unsupervised and weakly supervised settings, mSimCSE significantly improves previous sentence embedding methods on cross-lingual retrieval and multilingual STS tasks. The performance of unsupervised mSimCSE is comparable to fully supervised methods in retrieving low-resource languages and multilingual STS. The performance can be further enhanced when cross-lingual NLI data is available.
+
+# 1 Introduction
+
+Universal cross-lingual sentence embeddings map the sentences from multiple languages into a shared embedding space, where semantically similar sentences across languages are close to each other. These embeddings have a wide spectrum of applications such as multi-lingual document retrieval (Artetxe and Schwenk, 2019a; Lin et al., 2020), multi-lingual question answering (Asai et al., 2021a,b; Kumar et al., 2022), unsupervised machine translation (Tran et al., 2020), and zero-shot transfer learning (Phang et al., 2020).
+
+As shown in Figure 1 (a), without finetuning on downstream tasks, the embedding space of pretrained multilingual language models such as mBERT (Devlin et al., 2019) or XLM-R (Conneau et al., 2020) separate the embeddings of each language into different clusters. To align cross-lingual
+
+
+(a) XLM-R without finetuning.
+
+
+(b) XLM-R fintuned on English NLI data.
+Figure 1: We visualize the sentence embeddings on XNLI corpus, where blue dots and green dots denote the sentences from English and Swahili respectively. Here, red dots, black dots, and purple dots denote the parallel sentences from different languages. In (a), the sentence embeddings from different languages are clearly separated into two clusters. In (b), after English NLI training, the embedding space becomes indistinguishable for different languages, and the parallel sentences are aligned to each other.
+
+sentence embeddings, previous work (Artetxe and Schwenk, 2019a; Chidambaram et al., 2019; Feng et al., 2020) finetunes multilingual language models with billions of parallel data. However, it is non-trivial to obtain numerous parallel data for all languages. One potential direction to alleviate the need for parallel data is to enhance cross-lingual transfer of sentence embeddings.
+
+Pre-trained multilingual language models (Pires et al., 2019; Phang et al., 2020) have shown impressive performance on cross-lingual zero-shot transfer (Pires et al., 2019) that a model finetuned on a source language can generalize to target languages. This implies the representations finetuned on downstream tasks are universal across various languages. In this work, we explore various cross-lingual transfer settings on sentence retrieval tasks, especially in the setting of using English data only.
+
+We propose multilingual-SimCSE (mSimCSE) which extends SimCSE (Gao et al., 2021), a famous sentence embedding method on English, to multilingual for cross-lingual transfer. SimCSE is
+
+a contrastive learning (Chopra et al., 2005; Hadsell et al., 2006; Chen et al., 2020a) method that pulls closer semantically similar sentences (i.e. positive sentence pairs) in embeddings space. As done in SimCSE, we obtain positive training pairs by either natural language inference (NLI) (Conneau et al., 2017; Reimers and Gurevych, 2019) supervision or unsupervised data augmentation using dropout. We also investigate model performance when a small amount of parallel data or cross-lingual NLI data are available.
+
+In our experiments, as shown in Figure 1 (b), we are surprised to find that contrastive learning on pure English data seems to be able to align cross-language representations. Sentences that are semantically similar across languages are clearly closer together. Compared with previous unsupervised or weakly supervised methods, our unsupervised method significantly improves the performance on cross-lingual STS and sentence retrieval tasks. In retrieving low-resource languages and STS tasks, our method is even on par with fully supervised methods trained on billions of parallel data. Our results show that using contrastive learning to learn sentence relationships is more efficient than using massively parallel data for learning universal sentence embeddings. To the best of our knowledge, we are the first to demonstrate that using only English data can effectively learn universal sentence embeddings.
+
+# 2 Related Work
+
+# 2.1 Cross-lingual Zero-shot Transfer Learning
+
+Due to the similarities between different languages, such as words, grammar, and semantics, multilingual models (Devlin et al., 2019; Conneau and Lample, 2019; Conneau et al., 2020; Wei et al., 2021; Chi et al., 2022) have been shown to generalize to unseen languages in a wide range of tasks. In machine translation, multilingual models exhibit the ability to perform zero-shot transfer in that they can translate on unseen language pairs (Zoph et al., 2016; Johnson et al., 2017). With the help of self-supervised learning, model can better acquire language-invariant representation, thus improving zero-shot machine translation (Siddhant et al., 2020; Liu et al., 2020).
+
+To learn language-invariant representations cross-lingual tasks, previous work apply adversarial networks (Keung et al., 2019; Chen et al., 2019)
+
+or align representations via parallel corpus (Cao et al., 2020). Pires et al. (2019) revealed that mBERT is good at zero-shot cross-lingual transfer that tintuning on a specific monolingual task can generalize to other languages. More recently, X-Mixup (Yang et al., 2022) performs manifold mixup of source and target languages to learn general representations. Our method is the most relevant to the work which enhances cross-lingual transfer by using English downstream tasks to fine-tune multilingual language models (Phang et al., 2020) in that both methods leverage English NLI supervision. Our method differs from theirs in that we apply contrastive learning for representation learning and we only focus on sentence embeddings.
+
+# 2.2 English Sentence Embeddings
+
+Sentence embeddings aim to map sentences into a shared embedding space in which sentences with similar meanings can be close to each other. Previous work learns sentence embeddings by predicting the surrounding sentences of an input sentence, in either generative (Kiros et al., 2015) or discriminative (Logeswaran and Lee, 2018) manners. Recently, with the success of contrastive learning on learning visual representations (Chen et al., 2020b), more and more work explores contrastive learning on sentence embeddings. The training signal of contrastive learning can be obtained by data augmentation (Fang et al., 2020; Yan et al., 2021; Meng et al., 2021; Carlsson et al., 2021) or self-guided architecture (Kim et al., 2021; Carlsson et al., 2021). Among these, SimCSE (Gao et al., 2021) is the most famous one, which adopts either NLI supervision to define relevant sentences or unsupervised dropout as data augmentation, and improves state-of-the-art results. We choose to extend SimCSE to multilingual due to its impressive performance and simplicity.
+
+# 2.3 Cross-lingual Sentence Embeddings
+
+Universal cross-lingual sentence embeddings align semantically similar cross-lingual sentences into a shared embeddings space. To learn cross-lingual embeddings, previous work uses large amounts of parallel data to train neural networks to bring the embeddings of parallel sentences closer. LASER (Artetxe and Schwenk, 2019b) trains Bi-LSTM with parallel sentences of 93 languages to encourage consistency between the cross-lingual sentence embeddings. MUSE (Yang et al.,
+
+
+(a)Unsupervised mSimCSE
+
+
+(b)Supervised mSimCSE
+
+
+(c)NLI supervised mSimCSE
+
+
+Figure 2: Overview of our method. In (a) unsupervised mSimCSE, sentence 1 is from English Wikipedia. It uses different dropout masks at each encoder inference as data augmentation. In (b) supervised SimCSE, we use parallel sentences as a positive training pair. In (c) NLI supervised mSimCSE, for the model only leverages English data, languages A, B, and C are all English. For mSimCSE that uses cross-lingual NLI supervision, languages A, B, and C are randomly sampled from a language pool. We use entailment and contradiction relationships between sentences to construct positive and hard negative training pairs.
+
+2020) learns universal sentence embedding for 16 languages via translation based bridge tasks including multifeature question-answer prediction, translation ranking, and NLI. LaBSE (Feng et al., 2020) leverages dual-encoder framework to fine-tune mBERT on 6 billion parallel sentence pairs over 109 languages. Reimers and Gurevych (2020) extend the monolingual sentence embedding to multilingual by teacher-student training, in which a target language student model mimics source language embeddings from the teacher model. Sentence piece encoder (SP) (Wieting et al., 2021) simply learns sentence piece embeddings using parallel data and outperforms BERT-base models.
+
+It is also possible to learn cross-lingual sentence embeddings in weakly supervised or even unsupervised manners. CRISS (Tran et al., 2020) uses the representations of mBART encoder as initial sentence embeddings, which are used to mine parallel texts from monolingual corpora. They iteratively extract bittexts and use the bittexts to update the model in a self-training loop. Notice that our method can be easily combined with CRISS by using mSimCSE as the initial model. Our method is closely related to DuEAM (Goswami et al., 2021), a dual-encoder model that leverages word mover distance and cross-lingual parallel NLI sentences to construct positive training pairs. The main differences are that we use contrastive learning, which is more effective than dual encoder, and that our method is more simple that only requires English
+
+data.
+
+# 3 Method
+
+# 3.1 SimCSE
+
+SimCSE (Gao et al., 2021) apply batch contrastive learning (Chen et al., 2020b) to learn sentence embeddings on English data. Batch contrastive learning puts positive training pairs and negative training pairs into a same batch, increasing the difficulty of a contrastive task.
+
+Specifically, a positive training pair means the sentences in the pair are semantically similar and their embeddings should be pulled closer, while a negative training pair means the sentences are semantically different. Given a batch of positive training pairs $B = \{(x_{i}, x_{i}^{+})\}_{i=1}^{N}$ , SimCSE calculates the batch constrastive loss for i-th pair as:
+
+$$
+\mathcal {L} _ {i} = - \log \frac {e ^ {\operatorname {s i m} \left(h _ {i} , h _ {i} ^ {+}\right)}}{\sum_ {j = 1} ^ {N} e ^ {\operatorname {s i m} \left(h _ {i} , h _ {j} ^ {+}\right)}}. \tag {1}
+$$
+
+Here, $N$ denotes the batch size, $(x_{i},x_{i}^{+})$ denotes two semantically similar sentences, and $h_i = E(x_i)$ is the sentence embedding from encoder $E$ . The key to using this loss is how to define the semantically similar pairs, which we elaborate on in the following section.
+
+# 3.2 Multilingual SimCSE
+
+In this section, we elaborate on how we extend SimCSE to multilingual and illustrate our proposed
+
+mSimCSE in Figure 2. We explore four different multilingual training strategies, including the unsupervised strategy, the English NLI supervised strategy, the parallel NLI supervised strategy, and the fully supervised strategy. The difference between different strategies is how to define a positive training pair. Here, both unsupervised and English NLI supervised strategies can be recognized as an "unsupervised" setting for multilingual training because both of them only use English data and do not use any parallel data.
+
+Unsupervised mSimCSE In unsupervised SimCSE, $x_{i}$ and $x_{i}^{+}$ are the same sentence. As $x_{i}$ and $x_{i}^{+}$ are encoded by the same encoder but with different dropout, the dropout can be viewed as a light-weight data augmentation method. We use the wikipedia data from the original SimCSE repository to train our model.
+
+English NLI supervised mSimCSE In the English NLI supervised strategy, we use English natural language inference (NLI) (Conneau et al., 2017; Reimers and Gurevych, 2019) datasets to construct positive and hard negative training pairs. Specifically, if two sentences are labeled as "entailment" relationship, they are viewed as a positive pair $(x_{i}, x_{i}^{+})$ . For each $x_{i}$ , we also include a hard negative example $x_{i}^{-}$ in the same training batch, where $x_{i}$ and $x_{i}^{-}$ are labeled as "contradiction" relationship.
+
+Cross-lingual NLI supervised mSimCSE The English NLI supervision can be easily extended to the multilingual strategy by constructing a positive training pair from different languages. We use XNLI (Conneau et al., 2018), which translates English NLI to multiple languages. Similar to the English NLI strategy, the cross-lingual sentence pairs with "entailment" and "contradiction" relationship are viewed as positive and negative pairs respectively, but as shown in Figure 2, the language of $x_{i}$ , $x_{i}^{+}$ and $x_{i}^{-}$ are randomly sampled. They can come from either different languages or the same language.
+
+Supervised mSimCSE In supervised mSimCSE, we simply define a positive training pair as the parallel sentences from different languages. This strategy is the same as previous supervised methods, but we use relatively few parallel sentences. Note that different strategies can be easily combined by mixing training pairs from different strategies.
+
+# 4 Experiments
+
+# 4.1 Experimental Setup
+
+Training Details We adapt SimCSE codebase ${}^{2}$ to a multi-lingual setting. We keep all other hyperparameters same as the original SimCSE, and fix learning rate to be ${1e} - 5$ ,training epoch to be 1,and batch size to be 128 for all experiments. We use our method to finetune XLM-Roberta-large (XLM-R) (Conneau et al., 2020). We examine the performance of different hyperparameters in Appendix A
+
+Training Data for Different mSimCSE Strategies In unsupervised mSimCSE and English NLI supervised mSimCSE, we use the pre-processed English Wikipedia and English NLI training tuples downloaded from the SimCSE codebase respectively. In all the tables in this paper, the subscripts of $mSimCSE$ denote the languages that we use to train our model. In cross-lingual NLI supervision, $mSimCSE_{en,fr}$ denotes we use English and translated French NLI data to train our model and $mSimCSE_{all}$ means that we use all the languages in XNLI (Conneau et al., 2018) dataset.
+
+In supervised finetuning, $mSimCSE_{sw}$ denotes that we use the translation pairs of English and Swahili. For each language, we randomly select 100k parallel sentences from ParaCrawl project via the OPUS corpus collection. In supervised finetuning, " $mSimCSE_{sw} + \text{NLI}"$ denotes that we mix English NLI sentence pairs with English-Swahili translation pairs. Note that because parallel sentences don't have hard negative sentences, to mix them with NLI data, we also remove hard negative sentences of NLI in " $mSimCSE_{sw} + \text{NLI}"$ .
+
+# 4.2 Baselines
+
+First, we compare our method to unsupervised pretrained language models including XLM-R and M-BERT without finetuning to show that unsupervised contrastive learning can learn more generalized cross-lingual sentence embeddings. In some tasks, we also compare our method with more competitive language models in Xtreme (Hu et al., 2020) benchmark, such as XLM-E (Chi et al., 2022), HICTL (Wei et al., 2021) and INFOXLM (Chi et al., 2021). CRISS (Tran et al., 2020) is an unsupervised sentence retrieval method, which mines
+
+$^{2}$ https://github.com/princeton-nlp/SimCSE
+3http://paracrawl.eu
+4https://opus.nlpl.eu/
+
+| Models | BUCC | Tatoeba-14 | Tatoeba-36 |
| Unsupervised |
| XLM-R | 66.0 | 57.6 | 53.4 |
| INFOXLM | - | 77.8 | 67.3 |
| DuEAM | 77.2 | - | - |
| XLM-E | - | 72.3 | 62.3 |
| HiCTL | 68.4 | - | 59.7 |
| mSimCSEen | 87.5 | 82.0 | 78.0 |
| English NLI supervised |
| (Phang et al., 2020) | 71.9 | - | 81.2 |
| mSimCSEen | 93.6 | 89.9 | 87.7 |
| Cross-lingual NLI supervised |
| mSimCSEen,fr | 94.2 | 90.8 | 88.8 |
| mSimCSEen,fr,sw | 94.3 | 93.3 | 90.3 |
| mSimCSEall | 95.2 | 93.2 | 91.4 |
| DuEAM | 81.7 | - | - |
| Fully Supervised |
| LASER | 92.9 | 95.3 | 84.4 |
| LaBSE | 93.5 | 95.3 | 95.0 |
| mSimCSEsw | 86.8 | 87.7 | 86.3 |
| mSimCSEfr | 87.1 | 87.9 | 85.9 |
| mSimCSEsw,fr | 88.8 | 90.2 | 88.3 |
| mSimCSEsw,fr+NLI | 93.6 | 91.9 | 90.0 |
+
+Table 1: Results of sentence retrieval task on Xtreme benchmark. We report F1-scores for BUCC and accuracy for Tatoeba.
+
+parallel sentences from multiple monolingual corpora using self-training.
+
+Our main baselines are other methods which also leverage NLI supervision. Phang et al. (2020) finetune multilingual language models on various English tasks, including English NLI task. DuEAM (Goswami et al., 2021) also leverages multilingual NLI supervision to learn universal sentence embeddings.
+
+We also compare our method with fully supervised methods that leverages parallel sentences, including LASER (Artetxe and Schwenk, 2019b), LaBSE (Feng et al., 2020), and SP (Wieting et al., 2021). Note that among all the methods, $mSimCSE_{en}$ is the only method that only uses English data.
+
+# 4.3 Sentence Retrieval
+
+Following the previous work of cross-lingual sentence embedding learning (Goswami et al., 2021), we evaluate our model on multi-lingual sentence retrieval, including Tatoeba (Artetxe and Schwenk, 2019b) and BUCC (Zweigenbaum et al., 2018). Tatoeba requires models to match parallel sentences from source and target language sentence pools. BUCC is a bitext mining task, in which a model needs to rank all the possible sentence pairs, and predicts sentence pairs whose scores are above an optimized threshold.
+
+In Table 1, we follow the setting in Xtreme
+
+benchmark to evaluate model performance on sentence retrieval task. In unsupervised setting, mSim-CSE trained on English Wikipedia improves the performance by a large margin. This implies that contrastive training can effectively pull closer crosslingual semantically similar sentences.
+
+With English NLI supervision, it significantly improves the performance against unsupervised methods and DuEAM. It even beats fully-supervised methods that leverages parallel sentences on BUCC task. This implies that with an objective that learns more difficult semantic relationship between sentences, model can learn better universal cross-lingual sentence embeddings.
+
+By comparing cross-lingual NLI supervised mSimCSE with English NLI supervised mSimCSE, we observe that the model performance can be further improved using translated NLI pairs from other languages. In general, including more languages can improve the performance. Comparing with DuEAM which also leverages parallel NLI supervision, contrastive learning can learn universal sentence embedding more effectively. In the BUCC dataset, the performance of $mSimCSE_{all}$ is better than fully supervised methods, such as LaBSE, which is trained on 6 billion parallel data. Note that $mSimCSE_{all}$ uses far less parallel data than LaBSE, which demonstrates the effectiveness of our method.
+
+In the fully supervised setting, comparing
+
+| Models | hi | fr | de | af | te | tl | ga | ka | am | sw |
| Unsupervised |
| CRISS | 92.2 | 92.7 | 98.0 | - | - | - | - | - | - | - |
| DuEAM | 83.5 | - | 93.4 | 79.9 | 78.6 | 56.8 | 35.0 | 70.7 | 46.4 | - |
| mSimCSEen | 86.9 | 87.2 | 94.1 | 76.0 | 78.8 | 49.7 | 39.2 | 75.2 | 48.8 | 29.4 |
| English NLI supervised |
| mSimCSEen | 94.4 | 93.9 | 98.6 | 85.6 | 92.9 | 70.0 | 54.8 | 89.2 | 79.5 | 42.1 |
| Cross-lingual NLI supervised |
| DuEAM | 92.9 | - | 96.0 | 84.8 | 90.6 | 60.6 | 42.0 | 76.4 | 56.0 | - |
| mSimCSEen,fr | 95.1 | 94.4 | 98.8 | 88.9 | 94.2 | 73.4 | 59.4 | 91.3 | 79.5 | 44.5 |
| mSimCSEen,fr,sw | 95.7 | 94.2 | 98.4 | 87.9 | 94.4 | 75.6 | 62.1 | 90.5 | 82.7 | 75.5 |
| mSimCSEall | 96.2 | 94.8 | 98.8 | 90.6 | 96.2 | 80.9 | 65.1 | 92.4 | 82.4 | 67.8 |
| Fully supervised |
| LASER | 94.7 | 95.7 | 99.0 | 89.4 | 79.7 | - | 5.2 | 35.9 | 42.0 | 42.4 |
| mSimCSEsw | 94.3 | 91.6 | 97.6 | 85.2 | 88.5 | 76.3 | 60.8 | 85.5 | 65.2 | 47.6 |
| mSimCSEfr | 94.1 | 92.6 | 97.3 | 84.6 | 89.3 | 70.8 | 54.6 | 86.3 | 63.4 | 43.6 |
| mSimCSEsw,fr | 95.1 | 93.8 | 97.8 | 86.1 | 91.2 | 75.8 | 59.6 | 88.9 | 74.4 | 51.5 |
| mSimCSEsw,fr+NLI | 95.8 | 94.7 | 98.6 | 89.8 | 95.7 | 77.8 | 63.9 | 91.7 | 81.0 | 57.1 |
+
+$mSimCSE_{sw,fr}$ with and without NLI supervision, we find that if the translation pairs are rare, adding English NLI supervision can significantly improve the performance. Also, compared with the mSimCSE that only uses English NLI supervision, adding a few extra parallel data can slightly improve the performance.
+
+Following DuEAM, in Table 2, we select some high-resource languages including Hindi (hin), French (fra), German (deu), Afrikaans (afr) and Swahili (swh), and low-resource languages including Telugu (tel), Tagalog (tgl), Irish (gle), Georgian (kat), and Amharic (amh) from Tatoeba dataset to further analyze the model performance. In high-resource languages, fully-supervised achieves better performance because large amounts of parallel sentence pairs are available in these languages. On the other hand, in low-resource languages, due to the lack of training pairs, supervised method can not generalize well on these languages while mSim-CSE can generalize better.
+
+Finally, we evaluate whether including cross-lingual NLI supervision in a target language can improve the performance. In Table 2, compared with using only English NLI supervision, $mSimCSE_{en,fr,sw}$ in the cross-lingual NLI setting which includes Swahili in training significantly improves the performance in Swahili. Its performance gain is greater than fully supervised "mSimCSE $_{sw,fr}+$ NLI", which leverages parallel sentences.
+
+Table 2: Accuracy of Tatoeba multilingual retrieval task.
+
+| Models | ar-ar | ar-en | es-es | es-en | tr-en |
| Unsupervised |
| XLM-R | 53.5 | 26.2 | 68.1 | 10.7 | 10.5 |
| mBERT | 55.2 | 28.3 | 68.0 | 23.6 | 17.3 |
| mSimCSEen | 72.3 | 48.4 | 83.7 | 57.6 | 53.4 |
| English NLI supervised |
| mSimCSEen | 81.6 | 71.5 | 87.5 | 79.6 | 71.1 |
| Cross-lingual NLI supervised |
| DuEAM | 69.7 | 54.3 | 78.6 | 56.5 | 58.4 |
| mSimCSEall | 79.4 | 72.1 | 85.3 | 77.8 | 74.2 |
| Fully Supervised |
| LASER | 79.7 | - | 57.9 | - | 72.0 |
| LaBSE | 80.8 | - | 65.5 | - | 72.0 |
| SP | 76.7 | 78.4 | 85.6 | 77.9 | 79.5 |
| mSimCSEsw,fr+NLI | 77.7 | 72.4 | 86.3 | 79.7 | 72.5 |
+
+Table 3: Spearman rank correlation $(\rho)$ results for SemEval 2017 STS shared task. The results of supervised baselines and DuEAM are taken from (Goswami et al., 2021).
+
+# 4.4 Cross-lingual STS
+
+Cross-lingual STS (Cer et al., 2017) evaluates whether a model predicted semantic similarity between two sentences are correlated to human judgement. The two sentences can come from either the same language or different languages. Given a sentence pair, we compute the cosine similarity of sentence embeddings as a model prediction.
+
+The results of multi-lingual STS benchmark are shown in Table 3. For unsupervised XLM-R and mBERT without finetuning, we try several pooling methods and find that averaging over the first and the last layers yields the best results on STS. The poor results of pre-trained language models mean that the sentence embeddings of pre-trained language models do not capture the semantics in the cosine similarity space well. With unsupervised mSimCSE pre-training, it enhances the semantics of monolingual STS tasks, i.e. "ar-ar" and "es-es".
+
+For the tasks that require cross-lingual alignment, including "ar-en", "en-es", and "tr-en", the gap between unsupervised baselines and English NLI supervised baselines is still large.
+
+Comparing with the methods that utilize either parallel NLI supervision or supervised parallel data, the English NLI training achieves the best results on ar-ar, es-es, and es-en pairs. This implies that mSimCSE can effectively transfer semantic knowledge learned from English NLI supervision to other languages. We find that using parallel data can only improve the results of bilingual pairs, and reduces the performance of monolingual pairs.
+
+# 4.5 Unsupervised Classification
+
+We conduct unsupervised classification to evaluate whether the model can cluster semantically similar documents together on the languages other than English. We use Tnews dataset in CLUE benchmark $^{5}$ to evaluate the performance of our model. Tnews is a Chinese news classification dataset, which contains 15 news categories. We first conduct k-means clustering on sentence embedding, in which cluster number $k$ is set to be the same as the number of news categories. Then, we evaluate the mean accuracy of each cluster that measures what percentages of documents in each cluster are from the same human-labeled category.
+
+Compared with unsupervised pre-trained language models, mSimCSE significantly improves the purity scores. This is expected because without fine-tuning, the embeddings from pre-trained language models cannot capture relative distances between instances. Similar to the observation in the previous section, English NLI supervision can greatly enhance the performance, closing the gap between the fully supervised fine-tuned BERT.
+
+# 4.6 Zero-shot Cross-lingual Transfer of Sentence Classification
+
+To evaluate the cross-lingual zero-shot transfer of pre-trained sentence embedding, we evaluate our model on PAXS-X (Yang et al., 2019) sentence classification task. PAXS-X requires a model to determine whether two sentences are paraphrases. In Table 5, compared with XLM-R and XLM-E (Chi et al., 2022), mSimCSE without using NLI data improves the performance, which demonstrates that mSimCSE is an effective approach for zero-shot cross-lingual transfer. In this task, using English
+
+| Models | Purity |
| Unsupervised |
| Random | 6.7 |
| mBERT | 15.2 |
| XLM-R | 13.7 |
| mSimCSEen | 30.3 |
| English NLI supervision |
| mSimCSEen | 40.3 |
| Cross-lingual NLI supervision |
| mSimCSEall | 41.6 |
| Supervised Classification Model |
| BERT | 56.6 |
+
+NLI supervision does not improve performance.
+
+Table 4: Accuracy of unsupervised clustering on Tnews classification dataset. In supervised fintuning, the model is finetuned on classification training set.
+
+| Models | Accuracy |
| Unsupervised |
| mBERT | 81.9 |
| XLM-R | 86.4 |
| XLM-E | 87.1 |
| mSimCSEen | 88.1 |
| English NLI supervised |
| (Phang et al., 2020) | 87.9 |
| mSimCSEen | 88.2 |
+
+# 5 Analysis
+
+# 5.1 The Effect of Parallel Sentences Number
+
+Table 5: Accuracy on PAWS-X dataset.
+
+| Parallel data | BUCC | Tatoeba14 | Tatoeba36 |
| 0 | 91.4 | 90.4 | 88.0 |
| 10k | 92.6 | 90.6 | 88.5 |
| 100k | 93.5 | 90.8 | 88.6 |
| 1M | 94.4 | 90.6 | 88.5 |
| 5M | 94.5 | 90.7 | 88.2 |
+
+Table 6: The effect of parallel English-French sentences number.
+
+As parallel data is easy to obtain for most languages (Artetxe et al., 2020), we investigate the effect of the number of parallel sentences. We mix parallel English-French sentences with the English NLI data and gradually increase the number of parallel sentences. Here, 0 parallel sentence means we only use English NLI data without using hard negative examples, so the results are different from the results in Table 1.
+
+The BUCC dataset has only four high-resource languages, of which French is one of them. With more parallel data, the consistent improvement on BUCC dataset implies that using more English-
+
+French translation pairs can improve the performance on the English-French mining task, thus improving the results of BUCC. On the other hand, the Tatoeba dataset includes much more languages, which evaluates a model's generalization. We observe that using more parallel data does not influence the performance on Tatoeba, which implies that using translation data on a single language pair does not generalize well to other languages. The results suggest that using large amounts of parallel data may not be the most efficient way to learn universal sentence embeddings while learning sentence relationships is a more promising direction.
+
+# 5.2 Can Contrastive Learning Removes Language Identity?
+
+| Models | en,de,fr,hi | en,tr,ar,bg |
| XLM-R | 99.2 | 99.8 |
| mSimCSEen | 91.1 | 95.3 |
+
+Table 7: Accuracy of language classifier.
+
+Masked language modeling requires a model to capture the language identity to predict correct tokens for a specific language. On the other hand, English contrastive loss only learns the relationship between sentences, which does not seem to require language identity. We speculate that the contrastive loss can thus remove the language identity in sentence embeddings and enhance the general shared cross-lingual semantics.
+
+To verify this, in Table 7, we train two language classifiers on en,de,fr,hi and en,tr,ar,bg respectively. The language classifier needs to predict the correct language of the input sentence embeddings. We use the sentences from XNLI as our training and testing data. With contrastive learning, the accuracy of language classifier decreases, which implies the embeddings are more language-invariant, which more or less verifies our assumption. However, the accuracy is still very high because the language classifier can still predict the language of a text by language-specific features such as grammar and characters.
+
+# 6 Discussion
+
+Our experimental results demonstrate that in both unsupervised and English NLI supervised settings, using English data alone can surprisingly align cross-lingual sentence embeddings. By comparing unsupervised results with NLI supervised results,
+
+we observe that learning more meaningful sentence relationships can further enhance the alignment. In our analysis, we find that infinitely increasing parallel training data is not the most efficient manner to learn universal sentence embeddings; instead, our results suggest that designing a more challenging contrastive task or more effective sentence embedding learning method on English data may be a more efficient direction. Also, contrastive learning may be a promising direction for improving the zero-shot transfer of pre-trained multilingual language models.
+
+We attribute the alignment to language-invariant contrastive training. Because multilingual language models have shown good performance on zero-shot transfer, we speculate that multilingual language models encode texts into two disentangled embeddings, a language-specific embedding and a general language agnostic embedding. Because English contrastive task doesn't require mlms to capture language identity, it only pulls closer language-agnostic sentence embeddings while weakening language-specific embedding. This property can be verified in Figure 1 and Table 7. However, it still requires more investigation to fully understand why contrastive learning on English data can achieve cross-lingual transfer.
+
+# 7 Conclusion
+
+In this work, we demonstrate that using only English data can effectively learn universal sentence embeddings. We propose four different strategies to extend SimCSE to multilingual, including unsupervised, English NLI supervised, cross-lingual NLI supervised, and supervised strategies. We surprisingly find that the English NLI supervised strategy can achieve performance on par with previous supervised methods that leverage large amounts of parallel data. Our work provides a new perspective on learning universal sentence embeddings and cross-lingual transfer that using contrastive learning to learn sentence semantic relationships on monolingual corpora may be a promising direction.
+
+# 8 Limitations
+
+In the previous sections, we attribute why models trained on English data can learn cross-lingual sentence embeddings to language-invariant contrastive task. We speculate that multilingual language models have already implicitly learned such universal
+
+representations, but they also learn some language-specific representations. Contrastive learning enhances the language-invariant representations, diminishing the language-specific representations without distorting the semantics embedded in the representations. However, this speculation still requires more evidence to support it. Also, it is important to understand to which the zero-shot transfer happens, such as which languages are easier to transfer, and what is the properties of these languages. For the properties of these languages, by observing the experimental results in Table 2, we have two speculations, one is their similarity between English, and another one is the number of the monolingual pre-training data for these languages, but again these speculations also require more analysis to verify. By understanding the reason for this phenomenon, it is possible to achieve better zero-shot transfer and learn more "universal" sentence embeddings.
+
+# References
+
+Mikel Artetxe, Sebastian Ruder, Dani Yogatama, Gorka Labaka, and Eneko Agirre. 2020. A call for more rigor in unsupervised cross-lingual learning. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7375-7388, Online. Association for Computational Linguistics.
+Mikel Artetxe and Holger Schwenk. 2019a. Massively multilingual sentence embeddings for zero-shot cross-lingual transfer and beyond. Transactions of the Association for Computational Linguistics, 7:597-610.
+Mikel Artetxe and Holger Schwenk. 2019b. Massively multilingual sentence embeddings for zero-shot cross-lingual transfer and beyond. Transactions of the Association for Computational Linguistics, 7:597-610.
+Akari Asai, Jungo Kasai, Jonathan Clark, Kenton Lee, Eunsol Choi, and Hannaneh Hajishirzi. 2021a. XOR QA: Cross-lingual open-retrieval question answering. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 547-564, Online. Association for Computational Linguistics.
+Akari Asai, Xinyan Yu, Jungo Kasai, and Hanna Hajishirzi. 2021b. One question answering model for many languages with cross-lingual dense passage retrieval. In Advances in Neural Information Processing Systems, volume 34, pages 7547-7560. Curran Associates, Inc.
+
+Steven Cao, Nikita Kitaev, and Dan Klein. 2020. Multilingual alignment of contextual word representations. In International Conference on Learning Representations.
+Fredrik Carlsson, Amaru Cuba Gyllensten, Evangelia Gogoulou, Erik Ylipää Hellqvist, and Magnus Sahlgren. 2021. Semantic re-tuning with contrastive tension. In International Conference on Learning Representations.
+Daniel Cer, Mona Diab, Eneko Agirre, Inigo Lopez-Gazpio, and Lucia Specia. 2017. Semeval-2017 task 1: Semantic textual similarity-multilingual and cross-lingual focused evaluation. arXiv preprint arXiv:1708.00055.
+Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. 2020a. A simple framework for contrastive learning of visual representations. arXiv preprint arXiv:2002.05709.
+Ting Chen, Simon Kornblith, Mohammad Norouzi, and Geoffrey Hinton. 2020b. A simple framework for contrastive learning of visual representations.
+Xilun Chen, Ahmed Hassan Awadallah, Hany Hassan, Wei Wang, and Claire Cardie. 2019. Multi-source cross-lingual model transfer: Learning what to share. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3098–3112, Florence, Italy. Association for Computational Linguistics.
+Zewen Chi, Li Dong, Furu Wei, Nan Yang, Saksham Singhal, Wenhui Wang, Xia Song, Xian-Ling Mao, Heyan Huang, and Ming Zhou. 2021. InfoXLM: An information-theoretic framework for cross-lingual language model pre-training. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 3576-3588, Online. Association for Computational Linguistics.
+Zewen Chi, Shaohan Huang, Li Dong, Shuming Ma, Bo Zheng, Saksham Singhal, Payal Bajaj, Xia Song, Xian-Ling Mao, Heyan Huang, and Furu Wei. 2022. XLM-E: Cross-lingual language model pre-training via ELECTRA. In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 6170–6182, Dublin, Ireland. Association for Computational Linguistics.
+Muthu Chidambaram, Yinfei Yang, Daniel Cer, Steve Yuan, Yunhsuan Sung, Brian Strope, and Ray Kurzweil. 2019. Learning cross-lingual sentence representations via a multi-task dual-encoder model. In Proceedings of the 4th Workshop on Representation Learning for NLP (RepL4NLP-2019), pages 250–259, Florence, Italy. Association for Computational Linguistics.
+S. Chopra, R. Hadsell, and Y. LeCun. 2005. Learning a similarity metric discriminatively, with application
+
+to face verification. In 2005 IEEE Computer Society Conference on Computer Vision and Pattern Recognition (CVPR'05), volume 1, pages 539-546 vol. 1.
+Alexis Conneau, Kartikay Khandelwal, Naman Goyal, Vishrav Chaudhary, Guillaume Wenzek, Francisco Guzmán, Edouard Grave, Myle Ott, Luke Zettle-moyer, and Veselin Stoyanov. 2020. Unsupervised cross-lingual representation learning at scale. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 8440-8451, Online. Association for Computational Linguistics.
+Alexis Conneau, Douwe Kiela, Holger Schwenk, Loic Barrault, and Antoine Bordes. 2017. Supervised learning of universal sentence representations from natural language inference data. In Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 670-680, Copenhagen, Denmark. Association for Computational Linguistics.
+Alexis Conneau and Guillaume Lample. 2019. Crosslingual language model pretraining. Advances in neural information processing systems, 32.
+Alexis Conneau, Rudy Rinott, Guillaume Lample, Adina Williams, Samuel R. Bowman, Holger Schwenk, and Veselin Stoyanov. 2018. Xnli: Evaluating crosslingual sentence representations. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing. Association for Computational Linguistics.
+Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 4171-4186, Minneapolis, Minnesota. Association for Computational Linguistics.
+Hongchao Fang, Sicheng Wang, Meng Zhou, Jiayuan Ding, and Pengtao Xie. 2020. Cert: Contrastive self-supervised learning for language understanding.
+Fangxiaoyu Feng, Yinfei Yang, Daniel Cer, Naveen Arivazhagan, and Wei Wang. 2020. Language-agnostic bert sentence embedding.
+Tianyu Gao, Xingcheng Yao, and Danqi Chen. 2021. SimCSE: Simple contrastive learning of sentence embeddings. In Empirical Methods in Natural Language Processing (EMNLP).
+Koustava Goswami, Sourav Dutta, Haytham Assem, Theodorus Fransen, and John Philip McCrae. 2021. Cross-lingual sentence embedding using multi-task learning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 9099–9113.
+
+Raia Hadsell, Sumit Chopra, and Yann LeCun. 2006. Dimensionality reduction by learning an invariant mapping. In Proceedings of the 2006 IEEE Computer Society Conference on Computer Vision and Pattern Recognition - Volume 2, CVPR '06, page 1735-1742, USA. IEEE Computer Society.
+Junjie Hu, Sebastian Ruder, Aditya Siddhant, Graham Neubig, Orhan First, and Melvin Johnson. 2020. Xtreme: A massively multilingual multi-task benchmark for evaluating cross-lingual generalization. CoRR, abs/2003.11080.
+Melvin Johnson, Mike Schuster, Quoc V Le, Maxim Krikun, Yonghui Wu, Zhifeng Chen, Nikhil Thorat, Fernanda Viégas, Martin Wattenberg, Greg Corrado, et al. 2017. Google's multilingual neural machine translation system: Enabling zero-shot translation. Transactions of the Association for Computational Linguistics, 5:339-351.
+Phillip Keung, Yichao Lu, and Vikas Bhardwaj. 2019. Adversarial learning with contextual embeddings for zero-resource cross-lingual classification and NER. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 1355–1360, Hong Kong, China. Association for Computational Linguistics.
+Taeuk Kim, Kang Min Yoo, and Sang-goo Lee. 2021. Self-guided contrastive learning for BERT sentence representations. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 2528-2540, Online. Association for Computational Linguistics.
+Ryan Kiros, Yukun Zhu, Russ R Salakhutdinov, Richard Zemel, Raquel Urtasun, Antonio Torralba, and Sanja Fidler. 2015. Skip-thought vectors. In Advances in Neural Information Processing Systems, volume 28. Curran Associates, Inc.
+Gokul Karthik Kumar, Abhishek Singh Gehlot, Sahal Shaji Mullappilly, and Karthik Nandakumar. 2022. Mucot: Multilingual contrastive training for question-answering in low-resource languages. arXiv preprint arXiv:2204.05814.
+Jimmy Lin, Rodrigo Nogueira, and Andrew Yates. 2020. Pretrained transformers for text ranking: Bert and beyond.
+Yinhan Liu, Jiatao Gu, Naman Goyal, Xian Li, Sergey Edunov, Marjan Ghazvininejad, Mike Lewis, and Luke Zettlemoyer. 2020. Multilingual denoising pretraining for neural machine translation. Transactions of the Association for Computational Linguistics, 8:726-742.
+Lajanugen Logeswaran and Honglak Lee. 2018. An efficient framework for learning sentence representations. In International Conference on Learning Representations.
+
+Yu Meng, Chenyan Xiong, Payal Bajaj, saurbh tiwary, Paul Bennett, Jiawei Han, and XIA SONG. 2021. Coco-lm: Correcting and contrasting text sequences for language model pretraining. In Advances in Neural Information Processing Systems, volume 34, pages 23102-23114. Curran Associates, Inc.
+Jason Phang, Iacer Calixto, Phu Mon Htut, Yada Pruk-sachatkun, Haokun Liu, Clara Vania, Katharina Kann, and Samuel R. Bowman. 2020. English intermediate-task training improves zero-shot cross-lingual transfer too. In Proceedings of the 1st Conference of the Asia-Pacific Chapter of the Association for Computational Linguistics and the 10th International Joint Conference on Natural Language Processing, pages 557-575, Suzhou, China. Association for Computational Linguistics.
+Telmo Pires, Eva Schlinger, and Dan Garrette. 2019. How multilingual is multilingual BERT? In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 4996-5001, Florence, Italy. Association for Computational Linguistics.
+Nils Reimers and Iryna Gurevych. 2019. SentenceBERT: Sentence embeddings using Siamese BERTnetworks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3982-3992, Hong Kong, China. Association for Computational Linguistics.
+Nils Reimers and Iryna Gurevych. 2020. Making monolingual sentence embeddings multilingual using knowledge distillation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4512-4525, Online. Association for Computational Linguistics.
+Aditya Siddhant, Ankur Bapna, Yuan Cao, Orhan First, Mia Chen, Sneha Kudugunta, Naveen Arivazhagan, and Yonghui Wu. 2020. Leveraging monolingual data with self-supervision for multilingual neural machine translation. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 2827-2835, Online. Association for Computational Linguistics.
+Chau Tran, Yuqing Tang, Xian Li, and Jiatao Gu. 2020. Cross-lingual retrieval for iterative self-supervised training. In Advances in Neural Information Processing Systems, volume 33, pages 2207-2219. Curran Associates, Inc.
+Xiangpeng Wei, Rongxiang Weng, Yue Hu, Luxi Xing, Heng Yu, and Weihua Luo. 2021. On learning universal representations across languages. In International Conference on Learning Representations.
+John Wieting, Kevin Gimpel, Graham Neubig, and Taylor Berg-Kirkpatrick. 2021. Paraphrastic representations at scale. arXiv preprint arXiv:2104.15114.
+
+Yuanmeng Yan, Rumei Li, Sirui Wang, Fuzheng Zhang, Wei Wu, and Weiran Xu. 2021. ConSERT: A contrastive framework for self-supervised sentence representation transfer. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 5065-5075, Online. Association for Computational Linguistics.
+Huiyun Yang, Huadong Chen, Hao Zhou, and Lei Li. 2022. Enhancing cross-lingual transfer by manifold mixup. In International Conference on Learning Representations.
+Yinfei Yang, Daniel Cer, Amin Ahmad, Mandy Guo, Jax Law, Noah Constant, Gustavo Hernandez Abrego, Steve Yuan, Chris Tar, Yun-hsuan Sung, Brian Strope, and Ray Kurzweil. 2020. Multilingual universal sentence encoder for semantic retrieval. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics: System Demonstrations, pages 87-94, Online. Association for Computational Linguistics.
+Yinfei Yang, Yuan Zhang, Chris Tar, and Jason Baldridge. 2019. PAWS-X: A cross-lingual adversarial dataset for paraphrase identification. In Proceedings of EMNLP 2019, pages 3685–3690.
+Barret Zoph, Deniz Yuret, Jonathan May, and Kevin Knight. 2016. Transfer learning for low-resource neural machine translation. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 1568-1575, Austin, Texas. Association for Computational Linguistics.
+Pierre Zweigenbaum, Serge Sharoff, and Reinhard Rapp. 2018. Overview of the third bucc shared task: Spotting parallel sentences in comparable corpora. In Proceedings of 11th Workshop on Building and Us ing Comparable Corpora, pages 39-42.
+
+| epoch | bs | lr | BUCC | Tatoeba-14 | Tatoeba-36 |
| 1 | 128 | 1e-5 | 93.6 | 89.9 | 87.7 |
| 2 | 128 | 1e-5 | 94.4 | 90.0 | 87.8 |
| 3 | 128 | 1e-5 | 93.5 | 90.0 | 87.4 |
| 1 | 256 | 1e-5 | 93.3 | 90.0 | 87.9 |
| 1 | 128 | 2e-5 | 93.7 | 90.0 | 87.4 |
+
+Table 8: Performance of different Hyperparameters. Epoch denotes training epoch number, bs denotes the batch size, and lr denotes learning rate.
+
+# A Hyperparameters
+
+In Table 8, we show how different hyperparameters influence the model performance. We choose $mSimCSE_{en}$ trained on English NLI data as the model under examination. We find that the performance of different hyperparameters is very close, which implies that our method is stable and not sensitive to hyperparameters. Increasing the number of training epochs to 2 can improve the performance on BUCC.
\ No newline at end of file
diff --git a/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/images.zip b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..9e73e19c7f2050bdd17e3d099af259db5128c037
--- /dev/null
+++ b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:e666e905425aa1ddeea68cee5cd6bd24ab617114371715d0da0338dd7892dad6
+size 355311
diff --git a/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/layout.json b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..9a69c24b004c1f07b8bece9ee6859de8f121427a
--- /dev/null
+++ b/englishcontrastivelearningcanlearnuniversalcrosslingualsentenceembeddings/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:0c2c1b123042754d3e1f8e911781ce7b94600ef1caa9f0463724bce3436b8323
+size 326631
diff --git a/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_content_list.json b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..03f16064f5568932385fb4c65083c3b9f323b188
--- /dev/null
+++ b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:ef7e0d374fd77ca3ace26d73c8ef5bddf703e508921096c4ad9e03065bf318ef
+size 74783
diff --git a/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_model.json b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..88fe686cc0bd90e7fc21779b67cede7849932590
--- /dev/null
+++ b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:f641296db0ee6b71d8f38e8ee776f6c70ebe84ec3faafe0b8cbe045be6ced47d
+size 87392
diff --git a/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_origin.pdf b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..1c01463154a0c2847f74684d2276ebd23d4207cf
--- /dev/null
+++ b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/3925f9ab-3130-40ed-8884-7bd033ad2734_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:c4781136fae9d9de364e78f9100bdc590631c2a318bb6ba72736e8bb3a7813ce
+size 878801
diff --git a/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/full.md b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..bf04ff7904d5668186e51615c208fc3a916c9974
--- /dev/null
+++ b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/full.md
@@ -0,0 +1,339 @@
+# Enhancing Joint Multiple Intent Detection and Slot Filling with Global Intent-Slot Co-occurrence
+
+Mengxiao Song, Bowen Yu, Quangang Li*, Yubin Wang, Tingwen Liu, Hongbo Xu
+
+Institute of Information Engineering, Chinese Academy of Sciences. Beijing, China
+School of Cyber Security, University of Chinese Academy of Sciences. Beijing, China
+
+{songmengxiao,yubowen,liquangang}@iie.ac.cn
+
+{wangyubin, liutingwen, hbxu} @ iie.ac.cn
+
+# Abstract
+
+Multi-intent detection and slot filling joint model attracts more and more attention since it can handle multi-intent utterances, which is closer to complex real-world scenarios. Most existing joint models rely entirely on the training procedure to obtain the implicit correlation between intents and slots. However, they ignore the fact that leveraging the rich global knowledge in the corpus can determine the intuitive and explicit correlation between intents and slots. In this paper, we aim to make full use of the statistical co-occurrence frequency between intents and slots as prior knowledge to enhance joint multiple intent detection and slot filling. To be specific, an intent-slot co-occurrence graph is constructed based on the entire training corpus to globally discover correlation between intents and slots. Based on the global intent-slot co-occurrence, we propose a novel graph neural network to model the interaction between the two subtasks. Experimental results on two public multi-intent datasets demonstrate that our approach outperforms the state-of-the-art models.
+
+# 1 Introduction
+
+Spoken language understanding (SLU) aims to enable the machine to understand user's utterance, which contains two typical subtasks: intent detection and slot filling (Tur and De Mori, 2011). Intent detection obtains the user's intent from the input utterance and slot filling recognizes entities carrying detailed information of the intent. Gangadharaiah and Narayanaswamy (2019) found that complex scenarios of real-world may often include multiple intents in an utterance. Take an example in Figure 1, the utterance indicates two intents: "GetWeather" and "BookRestaurant". Jeong and Lee (2008) suggested that solving the two subtasks jointly makes better performance because of the correlation between in
+
+
+Figure 1: An example of joint multiple intent detection and slot filling for an utterance.
+
+tents and slots (e.g. "BookRestaurant" and B-restaurant_type). Therefore, researchers in recent years (Gangadharaiah and Narayanaswamy, 2019; Qin et al., 2020, 2021b) pay more attention to joint multiple intent detection and slot filling.
+
+Gangadharaiah and Narayanaswamy (2019) first tried to explore the joint model for multiple intent detection and slot filling based on attention with a slot-gated mechanism to model dependencies between intents and slots. Qin et al. (2020) proposed an adaptive graph-interactive framework (AGIF) where the core is an adaptive intent-slot interaction multilayer graph attention network. It makes it possible for each token to capture different relevant intent information, thus enabling fine-grained integration of multiple intents. On the basis of AGIF, Qin et al. (2021b) proposed a global-locally graph-interaction network (GL-GIN), which builds a local slot-aware graph and a global intent-slot graph for each utterance to model slot dependency and intent-slot interaction. Nevertheless, these works rely entirely on model training to obtain implicit intent-slot correlation for interaction between the two subtasks. And existing works often construct graphs for each individual utterance, which neglects global statistical knowledge from the entire corpus. The simplified example is illustrated in Figure 2(a).
+
+To overcome the above limitations, inspired by the success of leveraging global knowledge from training sets to help model optimization in multi-label classification (Zhang et al., 2018; Chen et al., 2019; Ma et al., 2021), we decide to explicitly leverage the intent-slot correlation summarized from the
+
+
+(a) The Simplified graph structure of existing works
+
+
+(b) The Simplified graph structure of ours
+
+
+(c) Intent-to-slot co-occurrence frequency on the MixATIS dataset
+Slot Labels
+Figure 2: Graph structure comparison. (a): The simplified graph structure of existing works. (b): The simplified graph structure our global intent-slot co-occurrence graph. (c): The visualization of the intent-to-slot co-occurrence frequency counted on the MixATIS training set. Darker color represents higher co-occurrence frequency.
+
+entire training corpus. By counting co-occurrence numbers between intents and slots in utterances and calculating the frequency, we visualize the statistical results on the MixATIS (which is a public multi-intent utterance dataset) in Figure 2(c). We can clearly see that there are significant differences in co-occurrence frequency between different intents and slots. Based on the observation, we propose to regard the co-occurrence frequency as prior knowledge for guiding the model to mine the correlation between intents and slots.
+
+Methodologically, we devise an intent-slot graph with intent and slot labels as vertices, and the statistical co-occurrence frequency between intents and slots across the entire training corpus is formulated as weighted edges. Figure 2(b) shows the simplified example of our graph. The weight between each intent and each slot can be regarded as the correlation degree of them. Then, we apply the graph convolutional network (GCN) to the intent-slot graph to propagate information and update vertices embeddings. In this way, integrated global knowledge from the corpus is capable of helping the model capture explicit correlation between intents and slots, thereby facilitating interactions between the two subtasks to boost performance. Moreover, we explore several attention and fusion mechanisms to extract label-related information from each utterance and the global training corpus, for the purpose of incorporating semantic information of tokens that play an important role in judging slots and intents, while reducing noise
+
+from irrelevant tokens.
+
+We conduct experiments on two public multi- intent utterance datasets. Experimental results show that our approach significantly outperforms the previous state-of-the-art model in the overall accuracy of utterances. And extensive experimental analyses justify that our approach can make better use of the global intent-slot co-occurrence to help the model capture more accurate correlations between intents and slots, so that enhance joint multiple intent detection and slot filling. The source code for this paper can be obtained from https://github.com/smxiao/GISCO.
+
+# 2 Methodology
+
+Problem Definition Given input utterance $\boldsymbol{U} = [u_1, u_2, \dots, u_n]$ , where $n$ is the length of the utterance. Joint multiple intent detection and slot filling contains two subtasks: (1) multiple intent detection can be seen as a multi-label classification task that predicts the multiple intents $O^I = [o_1^I, \dots, o_m^I]$ of the input utterance, where $m$ indicates the number of output intent labels; (2) slot filling can be defined as a sequence labeling task that predicts the slot label for each token of the input utterance and output a slot label sequence $O^S = [o_1^S, \dots, o_n^S]$ .
+
+As shown in Figure 3, our approach is composed of four major components: (1) an utterance encoder; (2) intent and slot label embedder; (3) intent-slot co-occurrence graph network; (4) multi-intent detection and slot filling decoders. And we use a joint training scheme to optimize multiple intent
+
+
+Figure 3: The architecture of our proposed approach. Better viewed in color.
+
+detection and slot filling simultaneously. Next, we will describe each component in detail.
+
+# 2.1 Utterance Encoder
+
+Following Qin et al. (2020) and Qin et al. (2021b), we leverage task-shared and task-specific encoders to obtain the representation of utterance.
+
+Task-shared Utterance Encoder For the input utterance $U$ , we first utilize a self-attentive encoder to obtain the shared utterance representation of two subtasks. Concretely, we first use a Bi-LSTM (Hochreiter and Schmidhuber, 1997) to obtain content representation $\mathbf{C}_1$ with timing information of the input utterance. Then, we employ a self-attention mechanism (Vaswani et al., 2017) over the embedding of the input utterance to capture the context-aware features $\mathbf{C}_2$ . After that, we concatenate the output of Bi-LSTM and self-attention as the task-shared utterance representation $\mathbf{E} = \mathbf{C}_1 \oplus \mathbf{C}_2$ .
+
+Task-specific Utterance Encoder We utilize two different Bi-LSTMs to capture intent-aware and slot-aware contexts as task-specific features for intent detection and slot filling respectively. More specifically, we feed the task-shared utterance representation $\mathbf{E} = [\mathbf{e}_1,\mathbf{e}_2,\dots,\mathbf{e}_n]$ into an intent-aware Bi-LSTM, and apply $\mathbf{e}_t^I = \mathrm{BiLSTM}(\mathbf{e}_t,\mathbf{e}_{t - 1}^I,\mathbf{e}_{t + 1}^I)$ repeatedly to obtain the task-specific representation $\mathbf{E}_I = [\mathbf{e}_1^I,\mathbf{e}_2^I,\dots,\mathbf{e}_n^I]$ . The slot-aware Bi-LSTM is modeled similarly and outputs $\mathbf{E}_S$ .
+
+# 2.2 Intent and Slot Label Embedder
+
+In this subsection, we describe how to represent intent and slot labels. We devise an intra-utterance attention mechanism and an intra-corpus attention mechanism to collect label features from the input utterance and the training corpus, which are merged together with an adaptive fusion mechanism.
+
+Intra-utterance Attention Mechanism Our motivation comes from the observation that each word in one utterance has a different effect on different labels (Xiao et al., 2019), so we consider extracting label-related semantic components from utterance to represent intent and slot labels. Concretely, we first compute the label-word attention score (Lin et al., 2017). Then, we can capture label-related contextual information from utterance as the representation of the label with the attention score. The process is calculated as follows:
+
+$$
+\mathbf {B} _ {\delta} = \mathrm {S o f t m a x} (\mathbf {W} _ {2} ^ {\delta} \mathrm {t a n h} (\mathbf {E} _ {\delta} \mathbf {W} _ {1} ^ {\delta}) ^ {\mathrm {T}}) \mathbf {E} _ {\delta}, (1)
+$$
+
+where $\mathbf{W}_1^\delta \in \mathbb{R}^{d\times d_1}$ and $\mathbf{W}_2^\delta \in \mathbb{R}^{\lvert\delta\rvert\times d_1}$ are the parameters to be trained, $\delta \in \{I,S\}$ ( $I$ denotes intent label and $S$ denotes slot label), $|\delta|$ is the number of pre-dedefined labels. $\mathbf{B}_I$ and $\mathbf{B}_S$ are the obtained intent label representation and slot label representation from utterance, respectively.
+
+Intra-corpus Attention Mechanism While the intra-utterance attention mechanism dynamically collects utterance-specific label features from each input utterance, we argue that it ignores the shared features among all the utterances in the training corpus. Thus, we also devise an intra-corpus at
+
+tention mechanism as a supplement. Specifically, we first randomly initialize the intent and slot label matrices $\mathbf{M}_{\delta} \in \mathbb{R}^{|\delta| \times d}$ ( $\delta \in \{I, S\}$ ), respectively. Then we update $\mathbf{M}_{\delta}$ according to its relevance with each utterance in the training corpus as follows:
+
+$$
+\mathbf {M} _ {\delta} = \left(\mathbf {M} _ {\delta} \mathbf {E} _ {\delta} ^ {\mathrm {T}}\right) \mathbf {E} _ {\delta}, \tag {2}
+$$
+
+where the relevance is calculated by the simple dot product operation. So that, after seeing all the instances in the training corpus, $\mathbf{M}_{\delta}$ is desired to capture the shared label-specific utterance features. After training, $\mathbf{M}_{\delta}$ is fixed during inference, while $\mathbf{B}_{\delta}$ is dynamically generated for each test utterance. This is the most significant difference between them.
+
+Adaptive Fusion Mechanism We utilize an adaptive attention fusion strategy to fully and appropriately fuse $\mathbf{B}_{\delta}$ and $\mathbf{M}_{\delta}$ . The fusion strategy adaptively extracts a reasonable proportion of information from the two parts to generate the fused label representation. To be specific, we apply fully connected layer to get the proportion of each type of representation in the fusion operation:
+
+$$
+\boldsymbol {\alpha} _ {\delta} = \frac {\sigma \left(\mathbf {B} _ {\delta} \mathbf {W} _ {3} ^ {\delta}\right)}{\sigma \left(\mathbf {B} _ {\delta} \mathbf {W} _ {3} ^ {\delta}\right) + \sigma \left(\mathbf {M} _ {\delta} \mathbf {W} _ {4} ^ {\delta}\right)}, \tag {3}
+$$
+
+where $\mathbf{W}_3^\delta, \mathbf{W}_4^\delta \in \mathbb{R}^d$ are the parameters to be trained, and $\sigma$ denotes the Sigmoid function. Once having the fusion weights, we can get the fused label representation as follows:
+
+$$
+\mathbf {H} _ {\delta} = \boldsymbol {\alpha} _ {\delta} \mathbf {B} _ {\delta} + (\mathbf {1} - \boldsymbol {\alpha} _ {\delta}) \mathbf {M} _ {\delta}. \tag {4}
+$$
+
+Therefore, the intent labels and slot labels can be embedded into representations $\mathbf{H}_I$ and $\mathbf{H}_S$ .
+
+# 2.3 Intent-Slot Co-occurrence Graph
+
+Graph Construction We construct the intent-slot co-occurrence graph $\mathcal{G} = (\mathcal{V},\mathcal{E})$ where vertices refer to intent and slot labels, and edges refer to the statistical co-occurrence frequency between intents and slots counted from the training corpus.
+
+Vertex There are two kinds of vertices in the graph: one is the intent label vertex; the other is slot label vertex. The number of vertices is $|I| + |S|$ . The initial embeddings of vertices in the graph are produced by $\mathbf{H}_g = [\mathbf{H}_I, \mathbf{H}_S]$ .
+
+Edge We define the adjacent matrix of the graph based on the co-occurrence frequency between intents and slots on the training set:
+
+$$
+\mathbf {A} _ {i j} = \left\{ \begin{array}{c c} \frac {\operatorname {C o u n t} ((i , j))}{\operatorname {C o u n t} (i)}, & i f i a n d j c o - e x i s t, \\ 0, & o t h e r w i s e, \end{array} \right. \tag {5}
+$$
+
+where $i$ and $j$ are different types of vertices, i.e. if $i$ is an intent vertex then $j$ is a slot vertex, Count(·) denotes the cumulative number of occurrence, and particularly $\mathbf{A}_{ii} = 1$ for self-loop. The shape of $\mathbf{A}$ is $(|I| + |S|)\times (|I| + |S|)$ . Then the adjacent matrix $\mathbf{A}$ is normalized by the method in Kipf and Welling (2016) as follows:
+
+$$
+\hat {\mathbf {A}} = \mathbf {D} ^ {- \frac {1}{2}} \mathbf {A D} ^ {- \frac {1}{2}}, \tag {6}
+$$
+
+in which $\mathbf{D}$ is a diagonal degree matrix with entries $\mathbf{D}_{ij} = \sum_{j}\mathbf{A}_{ij}$ .
+
+Graph Network The graph convolutional network (GCN) (Kipf and Welling, 2016) is a convolutional neural network working on a graph, which updates vertex embedding by propagating information between neighboring vertices via adjacent edges. K-layers GCN can aggregate information from K-hops neighbors. Noted that, one layer of GCN is enough for our graph because we only consider the information interaction between intent label and slot label, and they are one-hop neighbors to each other, otherwise irrelevant information may be aggregated. Hence, the interaction between intent and slot labels can be formulated as:
+
+$$
+\mathbf {H} _ {g} ^ {\prime} = \hat {\mathbf {A}} \mathbf {H} _ {g} \mathbf {W} _ {g}, \tag {7}
+$$
+
+where $\mathbf{W}_g$ is a transformation matrix to be learned. Then the $\mathbf{H}_g^{\prime}$ is split into $\mathbf{H}_I^g$ and $\mathbf{H}_S^g$ which are the updated intent and slot label representations, respectively.
+
+# 2.4 Intent and Slot Decoders
+
+Multiple Intent Detection Decoder First, we simply calculate the dot product of intent label representation and utterance representation to obtain their similarity for intent detection. Then, a multilayer perception is applied to get the predicted probability of each intent label. The process is defined as follows:
+
+$$
+\mathbf {I} = \sigma (f ((\mathbf {H} _ {I} ^ {g} \mathbf {E} _ {I}) \mathbf {W} _ {6} ^ {I}) \mathbf {W} _ {5} ^ {I}), \tag {8}
+$$
+
+where $\sigma$ and $f$ denotes the Sigmoid and LeakyReLU activation function respectively.
+
+The above formula is designed for token-level intent detection. To get final sentence-level intent labels, we apply the same voting mechanism as Qin et al. (2021b) to output intents $O^{I}$ contained in the input utterance:
+
+$$
+\boldsymbol {O} ^ {I} = \left[ \boldsymbol {o} _ {k} ^ {I} \right| \left(\sum_ {t = 1} ^ {n} \mathbb {1} \left[ \mathbf {I} _ {t, k} > 0. 5 \right]\right) > \frac {n}{2} ], \tag {9}
+$$
+
+where $\mathbf{I}_{t,k}$ denotes the prediction probability of token $t$ for the intent $o_k$ .
+
+Slot Filling Decoder Inspired by Qin et al. (2021a), in order to make better use of intent information to guide slot filling, we further fuse intent and slot information implicitly via a feed-forward network for slot label prediction. We firstly leverage the attention mechanism to obtain the corresponding intent and slot information from utterance:
+
+$$
+\mathbf {E} _ {\delta} ^ {\prime} = \left(\mathbf {E} _ {\delta} \mathbf {H} _ {\delta} ^ {g \mathrm {T}}\right) \mathbf {H} _ {\delta} ^ {g} + \mathbf {E} _ {\delta}. \tag {10}
+$$
+
+Next, the intent and slot information are combined by concatenation $\mathbf{E}_{IS} = \mathbf{E}_I' \oplus \mathbf{E}_S'$ . And we leverage word neighbour features for each token as Zhang and Wang (2016):
+
+$$
+\hat {\mathbf {e}} _ {I S} ^ {t} = \mathbf {e} _ {I S} ^ {t - 1} \oplus \mathbf {e} _ {I S} ^ {t} \oplus \mathbf {e} _ {I S} ^ {t + 1}. \tag {11}
+$$
+
+Then, we integrate the intent information and context features $\tilde{\mathbf{E}}_{IS} = [\hat{\mathbf{e}}_{IS}^{1},\dots,\hat{\mathbf{e}}_{IS}^{n}]$ into the slot information by a feed-forward layer, and we add it to $\mathbf{E}_S^{\prime}$ to obtain the enhanced slot information:
+
+$$
+\mathbf {S} _ {u} = \operatorname {R e L U} \left(\hat {\mathbf {E}} _ {I S} \mathbf {W} _ {5} ^ {S}\right) \mathbf {W} _ {6} ^ {S} + \mathbf {E} _ {S} ^ {\prime}, \tag {12}
+$$
+
+After that, we apply a multi-layer perception to predict the corresponding slot label for each token:
+
+$$
+\mathbf {S} = \operatorname {S o f t m a x} \left(f \left(\mathbf {S} _ {u} \mathbf {W} _ {8} ^ {S}\right) \mathbf {W} _ {7} ^ {S}\right), \tag {13}
+$$
+
+where $f$ is the LeakyReLU activation function. Finally, the output $O^{S} = \arg\max(\mathbf{S})$ is the result of slot filling.
+
+# 2.5 Joint Training
+
+We apply the joint training to learn parameters. The loss function of multi-intent detection is defined as:
+
+$$
+C E (\hat {y}, y) = \hat {y} \log (y) + (1 - \hat {y}) \log (1 - y), \tag {14}
+$$
+
+$$
+\mathcal {L} _ {I} \triangleq - \sum_ {k = 1} ^ {n} \sum_ {j = 1} ^ {N _ {I}} C E \left(\hat {o _ {k}} ^ {(j, I)}, o _ {k} ^ {(j, I)}\right), \tag {15}
+$$
+
+where $\hat{o_k}^{(j,I)}$ is the gold intent label. Similarly, the loss function of slot filling is formulated as:
+
+$$
+\mathcal {L} _ {S} \triangleq - \sum_ {k = 1} ^ {n} \sum_ {j = 1} ^ {N _ {S}} \hat {o _ {k}} ^ {(j, S)}, o _ {k} ^ {(j, S)}, \tag {16}
+$$
+
+where $\hat{o_k}^{(j,S)}$ is gold slot label. So that, the final joint training objective is as follows:
+
+$$
+\mathcal {L} = \lambda \mathcal {L} _ {I} + (1 - \lambda) \mathcal {L} _ {S}, \tag {17}
+$$
+
+in which $\lambda$ is hyper-parameter.
+
+# 3 Experiments
+
+# 3.1 Datasets
+
+We conduct experiments on two public multi-intent utterance datasets: MixATIS (Hemphill et al., 1990; Qin et al., 2021b) and MixSNIPS (Coucke et al., 2018; Qin et al., 2021b). There are 13,162, 756, 828 utterances for training, validation and testing on the MixATIS dataset, respectively. MixSNIPS includes 39,776, 2,198, 2,199 utterances for training, validation and testing, respectively.
+
+# 3.2 Experimental Settings
+
+In our experiments, the word embedding is randomly initialized with 128-dimensional word vectors. The dimension of the BiLSTM hidden units is 256. The dimension of the label representation is 384. For the hyper-parameter $\lambda$ in the loss function of joint training, it is set 0.8 and 0.7 for the MixATIS and MixSNIPS respectively. We set the train batch size to 16. The whole model is trained via AdamW (Loshchilov and Hutter, 2017) with the learning rate being 1e-3, and the weight decay is set 1e-6 and 5e-4 for the MixATIS and MixSNIPS respectively. All experiments are conducted in Tesla T4.
+
+# 3.3 Baselines
+
+We compare our model with the following baselines: (1) Attention BiRNN (Liu and Lane, 2016): It introduces attention mechanism into the bidirectional RNN network for joint intent detection and slot filling. (2) Slot-Gated Attention (Goo et al., 2018): It proposes a slot-gated mechanism to learn dependencies between intents and slots. (3) Bi-Model (Wang et al., 2018): It considers intent detection and slot filling interacting bidirectionally. (4) SF-ID Network (Niu et al., 2019): It utilizes an iterative mechanism to enhance the correlation between intents and slots. (5) Stack-Propagation (Qin et al., 2019): It proposes a joint model with stack-propagation which performs the token-level intent detection to guide slot filling. (6) Joint Multiple ID-SF (Gangadharaiah and Narayanaswamy, 2019): It applies the slot-gated mechanism to joint multiple intent detection and slot filling. (7) AGIF (Qin et al., 2020): It utilizes an adaptive graph interactive framework which can capture the multi-intent information for slot filling. (8) GL-GIN (Qin et al., 2021b): It proposes a global-local graph interaction network which is the recent state-of-the-art for the joint task.
+
+| Model | Overall(acc) |
| MixATIS | MixSNIPS |
| Attention BiRNN | 39.1 | 59.5 |
| Slot-Gated | 35.5 | 55.4 |
| Bi-Model | 34.4 | 63.4 |
| SF-ID Network | 34.9 | 59.9 |
| Stack-Propagation | 40.1 | 72.9 |
| Joint Multiple ID-SF | 36.1 | 62.9 |
| AGIF | 40.8 | 74.2 |
| GL-GIN | 43.5 | 75.4 |
| Ours | 48.2 | 75.9 |
+
+Table 1: Main results on the MixATIS and the MixS-NIPS datasets, bold marks highest number among all models. The experimental results of all baseline models are directly cited from Qin et al. (2021b).
+
+# 3.4 Main Results
+
+Following Goo et al. (2018) and Qin et al. (2021b), we evaluate the performance using the sentence-level overall accuracy (Overall Acc): the prediction of an utterance is correct only when its intents and slots are all correctly predicted.
+
+Table 1 shows experiment results of different models on the two multi-intent datasets. We can see that our approach achieves $4.7\%$ and $0.5\%$ improvements in overall accuracy compared with the best baseline GL-GIN on the MixATIS and MixS-NIPS datasets, respectively. One interesting finding is that, our approach achieves comparable results compared with the best baseline on the slot F1 score and intent accuracy which are metrics used to evaluate the two subtasks. Slot F1 score and intent accuracy results are in Appendix A.
+
+We attribute the above gains to our model use of the global statistic result over the entire corpus to provide more information than independent utterance. In this way, taking the intent-slot co-occurrence frequency as prior knowledge can help the neural network capture the more explicit and high-confidence correspondence between intents and slots. In the case that intents (slots) prediction is correct, our approach can better guide the prediction of slots (intent), so that our model can accurately predict all intents and slots of an utterance, thus improving the overall accuracy.
+
+In particular, it is obvious that the improvement on the MixATIS is significant. We intuitively suspect that this is due to the characteristic of the MixATIS dataset: it is collected from an airline travel information system, which has very simi
+
+lar intent labels and slot labels (e.g. "Flight" vs. "Aircraft"; "B-airline_code" vs. "B-aircraft_code"). Therefore, the global intent-slot co-occurrence knowledge is more beneficial to distinguishing similar intents and slots. In contrast, the performance improves slightly on the MixSNIPS. We guess that, for this dataset with few label types and obvious label semantic differences (e.g. "GetWeather" vs. "PlayMusic"), the previous works are also capable of making the model capture partial correlations between intents and slots. Whereas, through leveraging well-informed global statistical knowledge, our method can further help the model to distinguish the correlations between those few labels whose semantic are similar.
+
+# 3.5 Analysis
+
+# 3.5.1 Ablation Test
+
+To study the effectiveness of each component in our model, we perform ablation experiments on MixATIS and MixSNIPS datasets.
+
+Effectiveness of the Intent-Slot Co-occurrence Graph Module We remove the global intent-slot co-occurrence in the graph module. That is, all intent vertices and slot vertices are connected to each other with unweighted edges, which is named as w/o Intent-Slot Co-occurrence in Table 2. We can observe that overall accuracy drops significantly by $9.2\%$ and $3.4\%$ on MixATIS and MixSNIPS datasets, respectively. This demonstrates that the intent-slot co-occurrence is a very necessary component which captures the correspondence between intent and slot and enhance the joint of two subtasks effectively.
+
+Effectiveness of Attention and Fusion Mechanisms for Label Representation In order to justify the effectiveness of using intra-utterance attention and intra-corpus attention mechanisms together, we use only one of them for intent and slot label representation, which are referred to w/o Intra-corpus Attention and w/o Intra-utterance Self-Attention in Table 2. We can observe that only using intra-utterance attention for the representation of labels, results in overall accuracy decreases of $7.0\%$ and $8.6\%$ on the two datasets respectively. And only using intra-corpus attention leads to $5.1\%$ and $4.4\%$ overall accuracy drops. Because of intra-utterance leveraging independent utterance context to represent the label, but it overlooks common features of all utterances or tokens with the same intent
+
+| Model | Overall(Acc) |
| MixATIS | MixSNIPS |
| Ours | 48.2 | 75.9 |
| w/o Intent-slot Co-occurrence | 39.0 | 72.5 |
| w/o Adaptive Fusion | 47.3 | 75.2 |
| w/o Intra-Corpus Attention | 41.2 | 67.3 |
| w/o Intra-Utterance Attention | 43.1 | 71.5 |
+
+Table 2: Ablation test results on the MixATIS and the MixSNIPS datasets.
+
+or slot label in the training corpus. While intracorpus attention makes up for the defect but ignores the specific context of each utterance. Hence, coupling with them is rational and necessary.
+
+Moreover, we verify the effectiveness of the adaptive fusion mechanism through replacing it with simply adding the two attention mechanisms outputs together, which is named as w/o Adaptive Fusion Mechanism in Table 2. We can see that removing the component hurts the results by $0.9\%$ and $0.7\%$ overall accuracy on the two datasets. It justifies adaptive fusion mechanism can indeed help fusing intent (slot) label represent by extracting proper amount of information from independent utterance context and shared label-related features among all utterances in the entire training corpus.
+
+# 3.5.2 Speedup
+
+We compare the inference speed of our approach with GL-GIN which is the recent fastest baseline. Specifically, we run the model on the MixATIS test set in an epoch, and the batch size is set to 16. The inference latency of our model and the GL-GIN is 1.7 seconds and 4.6 seconds respectively. So our approach implements the $\times 2.7$ speedup compared with GL-GIN, which demonstrates that our approach is efficient. The possible reason for this fact that GL-GIN requires the predict results of intent detection to construct the graph on each utterance for slot filling, whereas our approach decodes the two subtasks in parallel.
+
+# 3.5.3 Low-Resource Setting
+
+We test our approach and the best baseline GLGIN by varying the ratio of training set from \{10, 30, 50, 70, 100\} on the MixATIS dataset to compare the overall accuracy of them in low-resource scenarios. The comparison results are shown in Figure 4. We can clearly observe that our approach outperforms the baseline on all five proportions of the MixATIS training set. This demonstrates that
+
+
+Figure 4: Low-Resource setting experiments results of our approach and GL-GIN on the MixATIS dataset. Better viewed in color.
+
+the global intent-slot co-occurrence from the entire training corpus is beneficial to boosting the model performance. In addition, it is worth noting that, when the ratio of training set exceeds $70\%$ , the strength of our approach in the overall accuracy is significant. We attribute this to the fact that the richer corpus is more helpful to statistic to determine more accurate correlation between intents and slots, so that the more effective global intent-slot co-occurrence graph structure can be constructed.
+
+# 3.5.4 Case Study
+
+To further understand how the intent-slot co-occurrence graph works, we provide two cases from the MixATIS and MixSNIPS datasets and show the output results of our approach and of the best baseline GL-GIN. From Figure 5(a), we can see that our model predicts the slot label "B-aircraft_code" of token "j31" correctly, while GL-GIN predicts it as "O" incorrectly. Based on the statistical result of intent-slot co-occurrence frequency on the entire training corpus as prior knowledge, it can be learned that there is strong correlation between the intent "Quantity" and the slot "B-aircraft_code". It helps our model predict the token "j31" as a slot "B-aircraft_code" that carries detailed information of the utterance rather than the label "O". A similar phenomenon can be found in the case from the MixSNIPS dataset as shown in Figure 5(b). The slot label "B-artist" and "B-entity_name" are sometimes indistinguishable, which can confuses the model and leads to false predictions. However, the statistical co-occurrence fre
+
+
+Figure 5: Case study between our model and GL-GIN on the MixATIS dataset (a) and the MixSNIPS dataset (b). The green slot is correct while the red one is wrong.
+
+quency of the intent "AddTo Playlist" and the slot "B-entity_name" is greater than that of "AddTo Playlist" and "B-artist", which can guide our model correctly predict the slot label of token "born" and "free" as "B-entity_name" and "I-entity_name" respectively.
+
+# 4 Related Work
+
+The study of joint model for intent detection and slot filling has been central to spoken language understanding in recent years. Because of strong dependency between intent categories and slot labels, jointly solving the two tasks is not only more effective through guiding each other, but also usually requires only one model to be trained and finetuned, which reduces the impact of cascading error compared with pipeline models to some extent. Jeong and Lee (2008) proposed the first joint model named triangular chain conditional random fields for slot filling and intent detection, and the model outperforms the most advanced pipeline methods at that time. Guo et al. (2014) applied neural network on utterance parsing tree to solve the joint task. Liu and Lane (2016) explored the strategy of integrating explicit alignment information for slot filling, and further applies attention mechanism to a recurrent neural network (RNN). Goo et al. (2018) introduced the slot-gated mechanism which was the first attempt to explicitly guide slot filling with intent information. Wang et al. (2018) adopt a bidirectional interaction attention module, which means that the interaction is not only from intent to slot, but also from slot to intent oppositely. Zhang et al. (2020) first attempted to use graph neural network to solve the problem of non-parallelization of RNN and inability to capture the remote dependency. Qin et al. (2021a) considered
+
+the cross-impact between intent detection and slot filling and proposes a co-interactive transformer for the joint task.
+
+However, the above joint models can mainly deal with single intent utterance, and cannot handle complex cases with multiple intents. Based on the observation that $52\%$ of utterances in an Amazon internal dataset contain more than one intent, Gangadharajaiah and Narayanaswamy (2019) first focused on multiple intent scenario. It utilizes attention with slot-gated mechanism to construct a joint framework for multiple intent detection and slot filling. But their model predicts the slot for each token guided with same intent information. For more fine-grained integration of intent information, Qin et al. (2020) applied multi-layer graph attention network for adaptive interaction from intent to slot. Further, aiming at the issue of slow inference speed of existing autoregressive models, Qin et al. (2021b) proposed the first non-autoregressive model for multiple intent detection and slot filling, which is a global-local graph framework to model slot dependency locally and propagate information from multiple intents to slots globally.
+
+In our work, as far as we know, we are the first to consider leveraging the global intent-slot co-occurrence across the entire training corpus to enhance the joint of the two subtasks. Because taking full advantage of the well-informed co-occurrence information between intents and slots from the entire corpus can help model determine more intuitive and accurate correlation between them than constructing a graph for each independent utterance in previous studies.
+
+# 5 Conclusions
+
+In this paper, we present a new perspective of integrating global intent-slot co-occurrence across
+
+the entire corpus to enhance joint multiple intent detection and slot filling. Specifically, we construct a global intent-slot co-occurrence graph to discover correlation between intents and slots. Then, we combine it with a GCN-based model to guide the information propagation and achieve interaction for the joint task. Besides, we explore several attention mechanisms for dynamically extracting related information from independent utterance context and capturing shared label-specific features among all utterances in the training corpus, then fuse them adaptively to represent intent and slot label. Experimental analyses on two public multi-intent datasets justify that our approach is effective and efficient.
+
+# Limitations
+
+The performance of our approach will be limited in the case of insufficient corpus resources. Because our approach requires rich corpus to statistic the intent-slot co-occurrence to discover accurate correlation between intents and slots, and only in this way can an effective graph structure be determined. Besides, if there is too much noise in the training corpus, accurate graph structure cannot be built.
+
+# Acknowledgements
+
+We would like to thank the anonymous reviewers for their insightful comments and suggestions. This work is supported by the National Key Research and Development Program of China (Grant No.2021YFB3100600), the Strategic Priority Research Program of Chinese Academy of Sciences (Grant No.XDC02040400), the Youth Innovation Promotion Association of CAS (Grant No.2021153).
+
+# References
+
+Zhao-Min Chen, Xiu-Shen Wei, Peng Wang, and Yanwen Guo. 2019. Multi-label image recognition with graph convolutional networks. In Proceedings of the IEEE/CVF conference on computer vision and pattern recognition, pages 5177-5186.
+Alice Coucke, Alaa Saade, Adrien Ball, Théodore Bluche, Alexandre Caulier, David Leroy, Clément Doumouro, Thibault Gisselbrecht, Francesco Caltagirone, Thibaut Lavril, et al. 2018. Snips voice platform: an embedded spoken language understanding system for private-by-design voice interfaces. arXiv preprint arXiv:1805.10190.
+
+Rashmi Gangadharaiah Narayanaswamy. 2019.
+
+and Balakrishnan Joint multiple intent
+
+detection and slot labeling for goal-oriented dialog. In Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers), pages 564-569.
+Chih-Wen Goo, Guang Gao, Yun-Kai Hsu, Chih-Li Huo, Tsung-Chieh Chen, Keng-Wei Hsu, and Yun-Nung Chen. 2018. Slot-gated modeling for joint slot filling and intent prediction. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 2 (Short Papers), pages 753-757.
+Daniel Guo, Gokhan Tur, Wen-tau Yih, and Geoffrey Zweig. 2014. Joint semantic utterance classification and slot filling with recursive neural networks. In 2014 IEEE Spoken Language Technology Workshop (SLT), pages 554-559. IEEE.
+Charles T Hemphill, John J Godfrey, and George R Doddington. 1990. The atis spoken language systems pilot corpus. In Speech and Natural Language: Proceedings of a Workshop Held at Hidden Valley, Pennsylvania, June 24-27, 1990.
+Sepp Hochreiter and Jürgen Schmidhuber. 1997. Long short-term memory. *Neural computation*, 9(8):1735-1780.
+Minwoo Jeong and Gary Geunbae Lee. 2008. Triangular-chain conditional random fields. IEEE Transactions on Audio, Speech, and Language Processing, 16(7):1287-1302.
+Thomas N Kipf and Max Welling. 2016. Semi-supervised classification with graph convolutional networks. arXiv preprint arXiv:1609.02907.
+Zhouhan Lin, Minwei Feng, Cicero Nogueira dos Santos, Mo Yu, Bing Xiang, Bowen Zhou, and Yoshua Bengio. 2017. A structured self-attentive sentence embedding. arXiv preprint arXiv:1703.03130.
+Bing Liu and Ian Lane. 2016. Attention-based recurrent neural network models for joint intent detection and slot filling. arXiv preprint arXiv:1609.01454.
+Ilya Loshchilov and Frank Hutter. 2017. Decoupled weight decay regularization. arXiv preprint arXiv:1711.05101.
+Qianwen Ma, Chunyuan Yuan, Wei Zhou, and Songlin Hu. 2021. Label-specific dual graph neural network for multi-label text classification. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 3855-3864.
+Peiqing Niu, Zhongfu Chen, Meina Song, et al. 2019. A novel bi-directional interrelated model for joint intent detection and slot filling. arXiv preprint arXiv:1907.00390.
+
+Libo Qin, Wanxiang Che, Yangming Li, Haoyang Wen, and Ting Liu. 2019. A stack-propagation framework with token-level intent detection for spoken language understanding. arXiv preprint arXiv:1909.02188.
+Libo Qin, Tailu Liu, Wanxiang Che, Bingbing Kang, Sendong Zhao, and Ting Liu. 2021a. A co-interactive transformer for joint slot filling and intent detection. In ICASSP 2021-2021 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), pages 8193-8197. IEEE.
+Libo Qin, Fuxuan Wei, Tianbao Xie, Xiao Xu, Wanxiang Che, and Ting Liu. 2021b. Gl-gin: Fast and accurate non-autoregressive model for joint multiple intent detection and slot filling. arXiv preprint arXiv:2106.01925.
+Libo Qin, Xiao Xu, Wanxiang Che, and Ting Liu. 2020. Agif: An adaptive graph-interactive framework for joint multiple intent detection and slot filling. arXiv preprint arXiv:2004.10087.
+Gokhan Tur and Renato De Mori. 2011. Spoken language understanding: Systems for extracting semantic information from speech. John Wiley & Sons.
+Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. Advances in neural information processing systems, 30.
+Yu Wang, Yilin Shen, and Hongxia Jin. 2018. A bi-model based rnn semantic frame parsing model for intent detection and slot filling. arXiv preprint arXiv:1812.10235.
+Lin Xiao, Xin Huang, Boli Chen, and Liping Jing. 2019. Label-specific document representation for multi-label text classification. In Proceedings of the 2019 conference on empirical methods in natural language processing and the 9th international joint conference on natural language processing (EMNLP-IJCNLP), pages 466-475.
+Linhao Zhang, Dehong Ma, Xiaodong Zhang, Xiaohui Yan, and Houfeng Wang. 2020. Graph LSTM with context-gated mechanism for spoken language understanding. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 34, pages 9539-9546.
+Wenjie Zhang, Junchi Yan, Xiangfeng Wang, and Hongyuan Zha. 2018. Deep extreme multi-label learning. In Proceedings of the 2018 ACM on international conference on multimedia retrieval, pages 100-107.
+Xiaodong Zhang and Houfeng Wang. 2016. A joint model of intent determination and slot filling for spoken language understanding. In *IJCAI*, volume 16, pages 2993-2999.
+
+| Model | MixATIS | MixSNIPS |
| Slot(F1) | Intent(Acc) | Overall(Acc) | Slot(F1) | Intent(Acc) | Overall(Acc) |
| Attention BiRNN | 86.4 | 74.6 | 39.1 | 89.4 | 95.4 | 59.5 |
| Slot-Gated | 87.7 | 63.9 | 35.5 | 87.9 | 94.6 | 55.4 |
| Bi-Model | 83.9 | 70.3 | 34.4 | 90.7 | 95.6 | 63.4 |
| SF-ID Network | 87.4 | 66.2 | 34.9 | 90.6 | 95.0 | 59.9 |
| Stack-Propagation | 87.8 | 72.1 | 40.1 | 94.2 | 96.0 | 72.9 |
| Joint Mutiple ID-SF | 84.6 | 73.4 | 36.1 | 90.6 | 95.1 | 62.9 |
| AGIF | 86.7 | 74.4 | 40.8 | 94.2 | 95.1 | 74.2 |
| GL-GIN | 88.3 | 76.3 | 43.5 | 94.9 | 95.6 | 75.4 |
| Ours | 88.5 | 75.0 | 48.2 | 95.0 | 95.5 | 75.9 |
+
+Table 3: Slot F1 score and intent accuracy results on MixATIS and MixSNIPS datasets, bold marks highest number among all models. The experimental results of all baseline models are directly cited from Qin et al. (2021b).
+
+| Model | MixATIS | MixSNIPS |
| Slot(F1) | Intent(Acc) | Overall(Acc) | Slot(F1) | Intent(Acc) | Overall(Acc) |
| Ours | 88.5 | 75.0 | 48.2 | 95.0 | 95.5 | 75.9 |
| w/o Intent-slot Co-occurrence | 83.9 | 72.7 | 39.0 | 93.9 | 94.6 | 72.5 |
| w/o Adaptive Fusion Mechanism | 88.3 | 72.9 | 47.3 | 94.4 | 95.5 | 75.2 |
| w/o Label-Utterance Attention | 85.6 | 74.2 | 41.2 | 92.4 | 95.0 | 67.3 |
| w/o Utterance Self-Attention | 86.0 | 75.4 | 43.1 | 93.4 | 95.5 | 71.5 |
+
+Table 4: Slot F1 score and intent accuracy ablation study results on MixATIS and MixSNIPS datasets.
+
+# A Additional Results
+
+The experimental results in Table 3 show the performance of our approach compared with baselines on additional metrics for evaluating the two subtasks: F1 score of slot filling (Slot F1) and accuracy of intent detection (Intent Acc). We can see that our approach achieves comparable results compared with the best baseline on the slot F1 score and intent accuracy. It is worth noting that our approach makes significant improvements on the overall accuracy. Because the global intent-slot co-occurrence across the entire training corpus help the model enhance the joint of the two subtasks. That is to say, in the case that intents (slots) prediction is correct, our approach can better guide the prediction of slots (intent), so that our model can accurately predict all intents and slots of an utterance, hence improving the overall accuracy. Besides, Table 4 shows additional ablation study results of our approach on the slot F1 score and intent accuracy.
\ No newline at end of file
diff --git a/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/images.zip b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..40500fb7c356d9350b7eef8ec80f688af85c1572
--- /dev/null
+++ b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:2d89f5c5b8e2670a7126f9e9aff308f6672180ee1590460d724d74da6735d9bc
+size 469603
diff --git a/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/layout.json b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..4adfca11c099ecdc95bcf70ab73c09ff6fe160c9
--- /dev/null
+++ b/enhancingjointmultipleintentdetectionandslotfillingwithglobalintentslotcooccurrence/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:31ad92417fe4bd8e27e4fd1d8d376eb1d7bf56a22ca27ccdd347914e31882839
+size 340557
diff --git a/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_content_list.json b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_content_list.json
new file mode 100644
index 0000000000000000000000000000000000000000..4315ba9ca6bfd5fb7dbddf958acf2209e3046983
--- /dev/null
+++ b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_content_list.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:dcec31c5bf8199236abb6847d41506290500e31487721514e92a8c98c2607c89
+size 104559
diff --git a/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_model.json b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_model.json
new file mode 100644
index 0000000000000000000000000000000000000000..fc4a74768b34aa4063caa7a2163c85afacc61d0e
--- /dev/null
+++ b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_model.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:abeddc77c091c0cc021ee3111a8a40aaa07a25b01fe429a3cb44ca9d42334b13
+size 127392
diff --git a/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_origin.pdf b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_origin.pdf
new file mode 100644
index 0000000000000000000000000000000000000000..c3bed94e1806943588a537d52d5ea69ad9e6b43b
--- /dev/null
+++ b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/5db37ebf-e3df-4100-8ad8-a698414853ee_origin.pdf
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:6b0edb93f682255dafd2378848749d8e6014bd8020830fb26e063ae8228e273e
+size 885107
diff --git a/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/full.md b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/full.md
new file mode 100644
index 0000000000000000000000000000000000000000..a4ce839f7099e317d93a91850bcb783eca58fdf1
--- /dev/null
+++ b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/full.md
@@ -0,0 +1,388 @@
+# EUR-Lex-Sum: A Multi- and Cross-lingual Dataset for Long-form Summarization in the Legal Domain
+
+Dennis Aumiller*, Ashish Chouhan*†‡ and Michael Gertz†
+
+† Institute of Computer Science, Heidelberg University
+
+‡ School of Information, Media and Design, SRH Hochschule Heidelberg {aumiller, chouhan, gertz}@informatik.uni-heidelberg.de
+
+# Abstract
+
+Existing summarization datasets come with two main drawbacks: (1) They tend to focus on overly exposed domains, such as news articles or wiki-like texts, and (2) are primarily monolingual, with few multilingual datasets. In this work, we propose a novel dataset, called EUR-Lex-Sum, based on manually curated document summaries of legal acts from the European Union law platform (EUR-Lex). Documents and their respective summaries exist as cross-lingual paragraph-aligned data in several of the 24 official European languages, enabling access to various cross-lingual and lower-resourced summarization setups. We obtain up to 1,500 document/summary pairs per language, including a subset of 375 cross-lingually aligned legal acts with texts available in all 24 languages.
+
+In this work, the data acquisition process is detailed and key characteristics of the resource are compared to existing summarization resources. In particular, we illustrate challenging sub-problems and open questions on the dataset that could help the facilitation of future research in the direction of domain-specific cross-lingual summarization. Limited by the extreme length and language diversity of samples, we further conduct experiments with suitable extractive monolingual and cross-lingual baselines for future work.
+
+Code for the extraction as well as access to our data and baselines is available online at: https://github.com/achouhan93/eur-lex-sum.
+
+# 1 Introduction
+
+Despite a long history in the field of text summarization (Luhn, 1958), current systems in the area are still mainly targeted towards a few select domains. This stems in part from the homogeneity of existing summarization datasets and extraction processes: frequently, these are either collected
+
+from news articles (Over and Yen, 2004; Sandhaus, 2008; Hermann et al., 2015; Narayan et al., 2018; Grusky et al., 2018; Hasan et al., 2021) or wiki-style knowledge bases (Ladhak et al., 2020; Frefel, 2020), where alignment with supposed "summaries" is particularly straightforward. Domain outliers do exist, e.g., for scientific literature (Cachola et al., 2020) or the legal domain (Gebendorfer and Elnaggar, 2018; Kornilova and Eidelman, 2019; Manor and Li, 2019; Bhattacharya et al., 2019), but are primarily restricted to the English language or do not contain finer-grained alignments between cross-lingual documents.
+
+Reasons for the usage of mentioned predominant domains are manifold: Data is reasonably accessible throughout the internet, can be automatically extracted, and the structure naturally lends itself to the extraction of excerpts that can be seen as a form of summarization. For news articles, short snippets (or headlines) describing the gist of main article texts are quite common. Wikipedia has an introductionary paragraph that has been framed as a "summary" of the remaining article (Frefel, 2020), whereas others utilize scholarly abstracts (or variants thereof) as extreme summaries of academic texts (Cachola et al., 2020).
+
+For a variety of reasons, using these datasets as a training resource for summarization systems introduces (unwanted) biases. Examples include extreme lead bias (Zhu et al., 2021), focus on extremely short input/output texts (Narayan et al., 2018), or high overlap in the document contents (Nallapati et al., 2016). Models trained in such a fashion also tend to score quite well on zero-shot evaluation of datasets from similar domains, however, poorly generalize beyond immediate indomain samples that follow a different content distribution or longer expected summary length.
+
+Simultaneously, high-quality multilingual and cross-lingual data for training summarization systems is scarce, particularly for datasets including
+
+more than two languages. Existing resources are often constructed in similar fashion to their monolingual counterparts (Scialom et al., 2020; Varab and Schluter, 2021) and subsequently share the same shortcomings of low data quality.
+
+Our main contribution in this work is the construction of a novel multi- and cross-lingual corpus of reference texts and human-written summaries that extract texts from legal acts of the European Union (EU). Aside from a varying number of training samples per language, we provide a paragraph-aligned validation and test set across all 24 official languages of the European Uninon1, which further enables cross-lingual evaluation settings.
+
+# 2 Related Work
+
+Influencing works can generally be categorized into works about EU data, or more broadly about summarization in the legal domain. Aside from that, we also compare our research to other existing multi- and cross-lingual works for text summarization.
+
+# 2.1 The EU as a Data Source
+
+Data generated by the European Union has been utilized extensively in other sub-fields of Natural Language Processing. The most prominent example is probably the Europarl corpus (Koehn, 2005), consisting of sentence-aligned translated texts generated from transcripts of the European Parliament proceedings, frequently used in Machine Translation systems due to its size and language coverage. In similar fashion to parliament transcripts, the European Union has its dedicated web platform for legal acts, case law and treaties, called EURLex (Bernet and Berteloot, $2006)^{2}$ , which we will refer to as the EUR-Lex platform. Data from the EUR-Lex platform has previously been utilized as a resource for extreme multi-label classification (Loza Mencía and Furnkranz, 2010), most recently including an updated version by Chalkidis et al. (2019a,b). In particular, the MultiEURLEX dataset (Chalkidis et al., 2021) extends the monolingual resource to a multilingual one, however, does not move beyond the classification of EuroVoc labels. To our knowledge, document summaries of legal acts from the platform have recently been
+
+used as a monolingual English training resource for summarization systems (Klaus et al., 2022).
+
+# 2.2 Processing of Long Legal Texts
+
+Recently, using sparse attention, transformer-based models have been proposed to handle longer documents (Beltagy et al., 2020; Zaheer et al., 2020a). However, the content structure is not explicitly considered in current models. Yang et al. (2020) proposed a hierarchical Transformer model, SMITH, that incrementally encodes increasingly larger text blocks. Given the lengthy nature of legal texts, (Aumiller et al., 2021) investigate methods to separate content into topically coherent segments, which can benefit the processing of unstructured and heterogeneous documents in long-form processing settings with limited context. From a data perspective, Kornilova and Eidelman (2019) propose BillSum, a resource based on US and California bill texts, spanning between approximately 5,000 to 20,000 characters in length. For the aforementioned English summarization corpus based on the EUR-Lex platform, Klaus et al. (2022) utilize an automatically aligned text corpus for fine-tuning BERT-like Transformer models on an extractive summarization objective. Their best-performing approach is a hybrid solution that prefaces the Transformer system with a TextRank-based pre-filtering step.
+
+# 2.3 Datasets for Multi- or Cross-lingual Summarization
+
+For Cross-lingual Summarization (XLS), Wang et al. (2022b) provide an extensive survey on the currently available methods, datasets, and prospects. Resources for XLS can be divided into two primary categories: synthetic datasets and web-native multilingual resources. For the former, samples are created by directly translating summaries from a given source language to a separate target language. Examples include English-Chinese (and vice versa) by Zhu et al. (2019), and an English-German resource (Bai et al., 2021). Both works utilize news articles for data and neural MT systems for the translation. In contrast, there also exist web-native multilingual datasets, where both references and summaries were obtained primarily from parallel website data. Global Voices (Nguyen and Daumé III, 2019), XWikis (Perez-Beltrachini and Lapata, 2021), Spektrum (Fatima and Strube, 2021), and CLIDSUM (Wang et al., 2022a) represent instances of datasets for the news, encyclopedic, and dialogue domain, with differing numbers
+
+of supported languages.
+
+We have previously mentioned some of the multilingual summarization resource where multiple languages are covered. MLSUM (Scialom et al., 2020) is based on news articles in six languages, however, without cross-lingual alignments. Similarly without alignments, but larger in scale, is MassiveSum (Varab and Schluter, 2021). XL-Sum Hasan et al. (2021) does provide document-aligned news article, in 44 distinct languages, extracted data from translated articles published by the BBC. In particular, their work also provides translations in several lower-resourced Asian languages. WikiLingua (Ladhak et al., 2020) borders the multi- and cross-lingual domain; some weak alignments exist, but only for English references, and not between languages themselves.
+
+# 3 The EUR-Lex-Sum Dataset
+
+We present a novel dataset based on available multilingual document summaries from the EUR-Lex platform. The final dataset, which we title "EUR-Lex-Sum", consists of up to 1,500 document/summary pairs per language. For comparable validation and test splits, we identified a subset of 375 cross-lingually aligned legal acts that are available in all 24 languages. In this section, the data acquisition process is detailed, followed by a brief exploratory analysis of the documents and their content. Finally, key intrinsic characteristics of the resource are compared with relation to existing summarization resources. In short, we find that the combination of human-written summaries coupled with comparatively long source and summary texts makes this dataset a suitable resource for evaluating a less common summarization setting, especially for long-form tasks.
+
+# 3.1 Dataset Creation
+
+The EUR-Lex platform provides access to various legal documents published by organs within the European Union. In particular, we focus on currently enforced EU legislation (legal acts) for the 20 domains from the EUR-Lex platform.3 From the mentioned link, direct access to lists of published legal acts associated with a particular domain is available, which forms the starting point for our later crawling step. Notably, each of these
+
+domains also provides a diverse set of specific keywords, topics and regulations, which even within the dataset provide a high level of diversity.
+
+A legal act is uniquely identified by the so-called Celex ID, composed of codes for the respective sector, year and document type. The ID is consistent across all 24 languages, which makes it possible to align articles on a document level. Across all 20 domains, the website reports a total of 26,468 legal acts spanning from 1952 until 2022. However, as there is a probability of a particular legal act being assigned to multiple domains, approximately 22,000 unique legal acts can be extracted from the platform. We do not consider EU case law and treaties, which are also available through the EUR-Lex platform, but in other document formats.
+
+# 3.1.1 Crawling
+
+The web page of a particular legal act contains the following page content relevant for a summarization setting: 1. The published text of the particular legal act in various file formats, 2. metadata information about the legal acts, such as published year, associated treaties, etc., 3. links to the content pages in other official languages, and 4. if available, a link to an associated summary document.
+
+This work contributes to preparing a dataset with the legal act content and their respective summaries in different languages. Therefore, crawling over the entirety of published legal acts gives access to all relevant information needed to extract source and summary text pairs. Since a single legal act requires 50 individual web requests to extract files across all languages, we have a total of around 5.5 million access requests, distributed across the span of a month between May and June 2022. We dump the content of all accessed acts in a local Elastic-search instance, and separately mark documents without existing associated summaries. This allows the resource to be continually updated in the future without re-crawling documents that do not have available summaries.
+
+# 3.1.2 Filtering
+
+For further processing, we filter the documents available through our offline storage. First, some article texts may only be available as scanned (PDF) documents, which compromises text quality and is therefore discarded. For the most consistent representation, we choose to limit ourselves to articles present in an HTML document, with further advantages explained in Section 4.1. Availability of
+
+HTML documents generally correlates with the publishing year, see Section 4.2, presumably due to the emergence of the world wide web during the 1990s. Similarly, a document is not required to have an associated summary, limiting sample pairs' availability. A full distribution of available HTML sample pairs can be found in Figure 4. We could not identify any particular reasoning behind what documents do have summaries and which do not.
+
+More problematic is the fact that between $20 - 30\%$ of the available summaries (depending on the language) are associated with several source documents, essentially turning this into a multi-document summarization setting. Since this work focuses exclusively on single document summarization, we pair the summary with the longest associated reference document to maximize availability. Table 1 details the impact of considering only the longest document in terms of $n$ -gram novelty; we observe a consistent increase of novel $n$ -grams by about 5 percentage points over the subset of single-reference documents. While the concatenation of all relevant reference documents would eliminate any difference in $n$ -gram overlap between the summary and reference texts, having a single reference document conserves the correct processing of lead biases over alternatives that aggregate several texts. Further, concatenation leads to ambiguous text orderings, which may change summarization outcomes based on different aggregation strategies. However, the subset of these multi-document samples could be a challenging problem based on our available corpus that may be explored in a separate context for future work.
+
+Finally, we filter out all document pairs where the reference text is shorter than the input document. This occurs only for multi-document summary pairs, where sometimes several short acts are aggregated into a single summary.
+
+After filtering out invalid samples, between 391 (Irish) to 1,505 (French) documents remain; the full list of samples broken down by language can be found in the Appendix in Table 5. Across all languages, we manage to extract 31,987 pairs.
+
+# 3.1.3 Data Split
+
+To ensure a suitable (and comparable) validation and test split across different languages, all documents having sample pairs available in 24 languages (375 total) are taken out of the available respective subsets. Of the 375 documents, 187 samples are randomly selected into the validation
+
+| Subset | n-gram novelty |
| 1-gram | 2-gram | 3-gram | 4-gram |
| All samples | 42.25 | 64.07 | 77.34 | 83.73 |
| Single-ref subset | 41.74 | 63.52 | 76.87 | 83.33 |
| Longest | 46.77 | 68.83 | 81.44 | 87.18 |
| Concatenated | 41.03 | 63.06 | 76.38 | 82.77 |
+
+Table 1: Comparison of $n$ -gram novelties for the English subset, differentiating by the number of reference documents. Longest considers the subset of multi-reference documents with only the longest document as a reference; Concatenated uses the concatenation of all associated references.
+
+set, and the remaining 188 are taken as the corresponding test set. All other documents are assigned to the language-dependent training sets. No guarantee for cross-lingual availability is provided for the training set, however, most documents do appear in several of the languages. In particular, We will use these filtered data splits for future experiments in this paper unless explicitly mentioned otherwise.
+
+# 4 Exploratory Analysis
+
+An exploratory analysis of the dataset is conducted to confirm the resource's viability for automatic summarization and overall data quality. Aside from a qualitative view of the resource and an analysis of the temporal distribution of our samples, we provide a comprehensive look at intrinsic metrics commonly used for summarization datasets.
+
+# 4.1 Data Quality
+
+Documents of the EU are generally held to a high standard, and the legal acts are no exception. This also extends to the summaries, which follow a particular set of guidelines for their creation process. In particular, guidelines for drafting summary texts are detailed in Technical Annex I, which specify several key instructions for generating human-written summaries of an underlying legal act. Most prominently, they recommend a target length for key point summaries between 500-700 words and formulate a template structure for the overall text outline. An example of a typical summary structure can be seen in Figure 1. Aside from the key points, this includes, e.g., references to the main documents or specific act-related key phrases. We want to highlight that the generation guidelines changed
+
+# EU-Canada air transport agreement
+
+# SUMMARY OF:
+
+Agreement on Air Transport between Canada and the EU
+
+Decision (EU) 2019/702 — conclusion of the Air Transport Agreement between the European Community and its Member States, of the one part, and Canada, of the other part
+
+Decision 2010/417/EC — on the signing and provisional application of the Agreement on Air Transport between the EU and Canada
+
+# WHAT IS THE AIM OF THE AGREEMENT AND THE DECISIONS?
+
+- Decision 2010/417/EC authorises the signing and provisional application of the agreement by the EU.
+- Decision (EU) 2019/702 concludes the agreement on behalf of the EU.
+
+# KEY POINTS
+
+The agreement provides for an exchange of air traffic rights between the parties. Thanks to those traffic rights, the air carriers of the parties will be able to:
+
+fly across the territory of the other party without landing;
+
+make stops in the territory of the other party for non-traffic purposes;
+
+The agreement also covers:
+
+the designation of airlines;
+the authorisation of airlines and the revocation of the authorisations that may be granted to them;
+- civil aviation safety — including the mutual recognition of certificates and licences issued by either party for the purpose of the provision of air services under the agreement:
+- civil aviation security — including working towards mutual recognition of each other's security standards and with a view to one-stop security;
+- customs duties, taxes and charges exemptions — reciprocal agreement to exempt airlines of the other party of all import restrictions, property taxes and capital levies, customs duties, excise taxes, and similar fees and charges for items used in international air transport;
+non-discrimination as regards charges for airports and aviation facilities and services;
+- An improved commercial framework — including the removal of restrictions on capacity, the free establishment of tariffs by the airlines, as well as provisions on code-sharing* and aircraft lease among others;
+
+# FROM WHEN DO THE AGREEMENT AND THE DECISIONS ENTER INTO FORCE?
+
+The agreement is not yet in force.
+- Decision 2010/417/EC entered into force on 30 November 2009.
+Decision (EU) 2019/702 entered into force on 15 April 2019.
+
+# BACKGROUND
+
+International aviation: Canada (European Commission).
+
+# KEY TERMS
+
+Code-sharing: an arrangement where two or more airlines share the same flight, which is operated by one of the airlines.
+
+# MAIN DOCUMENTS
+
+Agreement on Air Transport between Canada and the European Community and its Member States (OJ L 207, 6.8.2010, pp. 32-59)
+
+Council Decision (EU) 2019/702 of 15 April 2019 on the conclusion, on behalf of the Union, of the Air Transport Agreement between the European Community and its Member States, of the one part, and Canada, of the other part (O.J.L 120, 8.5.2019, pp. 1-2)
+
+Decision 2010/417/EC of the Council and the Representatives of the Governments of the Member States of the European Union, meeting within the Council of 30 November 2009 on the signing and provisional application of the Agreement on Air Transport between the European Community and its Member States, of the one part, and Canada, of the other part (OJ L 207, 6.8.2010, pp. 30-31)
+
+Figure 1: Summary of legal act with Celex ID 32019D0702. Visible are several distinct sections, with the majority of the document describing key points of the underlying legal acts. This particular summary aggregates content from several legal acts, of which we consider the longest one as the reference document.
+
+over time. Since we do not have access to previous versions of the guidelines, we manually probed comparisons between older and newer documents, which exposed a highly structural similarity despite changes in guidelines.
+
+The published documents and summaries offer further peculiarities in both their content structure as well as the creation process: First, the multilingual versions of both documents and summaries are always translated from the original English legal act (or English summary thereof), which ensures strict content similarity of the same text across all available languages. Second, due to their HTML representation, it is possible to extract paragraph-aligned texts between language-specific versions. This is a well-known property of EU-level data, most notably exploited in the Europarl
+
+
+Figure 2: Distribution of the publishing year of unique legal acts included in the final dataset. Availability of documents increases after 1990.
+
+corpus (Koehn, 2005) for automatic alignments of machine translation training data. We similarly maintain this structure during the extraction process to use it at later stages, e.g., for more informed evaluation setups or cross-lingual pre-training.
+
+# 4.2 Temporal Distribution
+
+Figure 2 displays the distribution of filtered documents by the year of publication. The amount of available samples increases after 1990, which likely coincides with more member states joining, as well as a shift to digital archiving (compared to OCR scans of PDF documents, which are excluded from our corpus). Compared to other European resources, such as Multi-EURLex (Chalkidis et al., 2021), a lesser topical shift is expected in our resource, simply due to a more limited time frame. Notably, we also include the distribution by dataset split and observe an even stronger bias towards more recent legal acts for validation and test sets. This is a natural consequence of the requirement for validation and test sets that legal acts be present in all 24 languages, which includes more recently added official language, such as Croatian (added in 2013) or Irish (added in 2022). We also want to mention that amendments to both reference and summary texts might be added (or revised) several years after their original publication, which is not reflected in our analysis.
+
+# 4.3 Document Structure
+
+An example of the content structure of a document summary is provided in Figure 1. The formatted text reveals significant sections of the summary,
+
+
+(a) Reference tokens
+
+
+(b) Summary tokens
+Figure 3: Histogram of the English training set, comparing article token lengths. Displayed are the distribution for references (left), summaries (center), and compression ratios (right). Vertical lines show median length (continuous orange), mean length (dashed black), and standard deviation (dotted black lines). The latter exceeds display limits for reference length and compression ratio. Ranges are limited to the 95th length percentile for legibility.
+
+
+(c) Token compression ratio
+
+where the majority is taken up by free text describing the key goals and highlights of the sub-points within a longer legal act. It further describes which legal act (or several acts) are associated with the summary. As previously described, we limit ourselves to the longest associated legal act for a summary associated with several acts.
+
+While we provide raw text for the extracted legal act document in the proposed resource, example document in Figure 1 reveals a potential use case of semi-structured visual information from HTML tags (e.g., headline descriptors or bullet lists), which could be used for a fine-grained distinction between different content parts. In our preliminary experiments, we found that the used HTML tags for content elements can vary significantly between different legal acts (e.g., using modified div containers instead of H3 for subheadings) and therefore keep the inclusion of such features for future work.
+
+# 4.4 Summarization-related Dataset Metrics
+
+We adopt metrics from prior work to automatically analyze summarization datasets (Grusky et al., 2018; Zhong et al., 2019; Bommasani and Cardie, 2020). Our corpus reveals a high degree of abstractivity, which is surprising given the enormous length of input texts.
+
+# 4.4.1 Length Distribution
+
+Based on the fact mentioned in Section 4.1 that documents are created as translations from the English original, we focus more on the distribution of legal acts and their summary lengths in English as a representative language. A more exhaustive overview can be found in the Appendix in Table 5, which gives more insight into language-specific
+
+length variations due to document availability, or simply morphological/syntactic differences, e.g., compound words.
+
+Histogram plots in Figure 3 show a Zipfian distribution for reference text lengths, with a mean of around 12,000 tokens; however, we also observe an exceptionally large standard deviation due to extreme outliers, mentioned in Table 2. In contrast, summary lengths exhibit closer to a normal distribution, which matches the guideline document's suggested length of 500-700 words. The observed mean is slightly higher at around 800 tokens, which can be attributed to document overhead not counting towards the actual summarizing content, such as referenced documents and separately highlighted key concepts. However, we also observe extreme outliers for summary texts (cf. Table 2).
+
+# 4.4.2 Compression Ratio
+
+We follow the definition of an unrestricted compression ratio (Grusky et al., 2018), dividing the (token) length of an article by the associated summary (token) length. This carries the same semantic value as inverse definitions of compression ratio, such as used by Bommasani and Cardie (2020). When looking at the token-level compression ratio displayed in Figure 3, a comparatively high mean is observed, despite extremely long summary documents. Comparing compression ratios reported by (Zhong et al., 2019) for news-based datasets indicates that EUR-Lex-Sum has a mean compression ratios similar to the CNN/DailyMail (Hermann et al., 2015) and NYT (Sandhaus, 2008) corpora.
+
+# 4.4.3 $n$ -gram Novelty
+
+To provide insight into the abstractiveness of gold summaries, we follow Narayan et al. (2018) in an-
+
+ | Reference tokens | Summary tokens | Comp. Ratio | % novel n-grams in summary |
| Min | Max | Min | Max | 1-gram | 2-gram | 3-gram | 4-gram |
| Train | 385 | 1,087,217 | 173 | 3021 | 16 ± 62 | 44.10 | 65.97 | 78.85 | 84.96 |
| Val. | 1,143 | 199,405 | 354 | 5136 | 18 ± 17 | 36.65 | 58.23 | 72.74 | 79.96 |
| Test | 1,544 | 403,319 | 369 | 2987 | 18 ± 20 | 36.78 | 58.46 | 72.83 | 80.07 |
+
+Table 2: Complementary dataset properties (min and max token lengths of both reference texts and summaries), as well as compression ratio, across subsets. We further report novelty $n$ -gram shares in the gold summary. Values are computed on the English subset splits.
+
+alyzing the fraction of $n$ -grams not present in the original reference article. This metric is similar to content coverage metrics used by Grusky et al. (2018) or Zhong et al. (2019). When comparing novelty $n$ -grams reported in Table 2, it should be noted that this slightly overestimates the real value. This can be attributed to our use of whitespace tokenization, which may cause more $n$ -grams due to decreased tokenization accuracy; we further discuss the tokenization choice in Section 5.
+
+# 5 Experiments
+
+As a reference for future work building on top of this dataset, we provide a set of suitable baselines and discuss limitations of methods and data. Notably, there are considerable challenges in constructing baseline runs with popular algorithms on this dataset if trying to cover all languages.
+
+Primarily, even summary lengths exceed input limitations of popular abstractive neural models based on transformer architectures; these systems are generally limited to 512 (subword) tokens (Lewis et al., 2020; Xue et al., 2021), and even length-focused alternatives generally boast only up to 4096 tokens (Beltagy et al., 2020; Zaheer et al., 2020b), which is well below the median length of reference texts and prevents us from training systems without further (manual) alignments provided on chunks of the input text.
+
+Less obvious, but no less problematic is the availability of tokenizers or sentence splitting methods in popular NLP libraries, affecting several languages in our corpus (for a more in-depth list of supported languages by library, see Appendix Table 5). This inherently prevents fair sentence-level evaluation (or extraction), as system performance is not guaranteed for underrepresented languages. Aside from a set of extractive baselines, we further evaluate a cross-lingual scenario in which summaries for the English reference text are generated and then translated into the target languages. The
+
+hypothesis is that this provides insight into limitations of existing XLS systems discussed in Section 2.3 and also represents more realistic deployment scenarios where XLS systems can be utilized as supportive summarizers for monolingual input texts.
+
+# 5.1 Zero-shot Extractive Baselines
+
+One popular traditional algorithm for generating extractive summaries is LexRank (Erkan and Radev, 2004). We utilize a modified variant of LexRank that uses multilingual embeddings generated by sentence-transformers (Reimers and Gurevych, 2019, 2020) to compute centrality. Given the previously mentioned limitations of sentencizing input texts, we chunk the text based on existing paragraph separators (refer to Figure 1), and treat those segments as inputs to our baseline setup. Notably, this method does not require any form of fine-tuning or language adoption and works as a zero-shot domain transferred extractive model, which makes it preferable over methods such as SummaRuNNer (Nallapati et al., 2017) or extractive BERT summarizers, which require training on (automatically extracted) alignments.
+
+To determine the output summary length, we calculate the average paragraph-level compression ratio on the language's training set, and then multiply this value with the reference document's number of paragraphs to obtain a target length.
+
+For evaluation, we rely on ROUGE scores (Lin, 2004) with disabled stemming to conserve comparability between languages. We acknowledge that this is not a comprehensive measure and has distinctive shortcomings, but works fairly well at the paragraph level, as such units generally preserve both factual consistency and fluency.
+
+Due to the paragraph-level consistency of generated summaries, this is a fairly strong baseline. Importantly, ROUGE scores remain consistent for lan
+
+ | Validation | Test |
| R-1 | R-2 | R-L | R-1 | R-2 | R-L |
| English | 25.99 | 13.34 | 13.30 | 26.68 | 13.65 | 13.58 |
| French | 32.18 | 18.03 | 15.15 | 32.35 | 18.00 | 15.16 |
| German | 26.00 | 13.12 | 12.24 | 26.72 | 13.75 | 12.56 |
| Spanish | 27.04 | 16.43 | 14.75 | 28.34 | 17.12 | 15.23 |
| Italian | 27.29 | 14.01 | 12.63 | 28.57 | 14.24 | 12.90 |
| Portuguese | 30.12 | 17.17 | 15.08 | 30.67 | 17.20 | 15.20 |
| Dutch | 29.07 | 14.92 | 14.66 | 29.62 | 14.76 | 14.73 |
| Danish | 28.78 | 13.90 | 13.14 | 29.22 | 13.86 | 13.19 |
| Greek | 24.42 | 9.77 | 15.46 | 24.79 | 9.45 | 15.46 |
| Finnish | 26.40 | 11.88 | 11.87 | 26.49 | 11.68 | 11.80 |
| Swedish | 30.25 | 15.40 | 14.27 | 30.67 | 15.47 | 14.35 |
| Romanian | 35.69 | 16.08 | 14.90 | 34.75 | 15.16 | 14.59 |
| Hungarian | 33.71 | 19.53 | 15.49 | 34.55 | 19.69 | 15.64 |
| Czech | 30.96 | 16.65 | 14.16 | 31.86 | 16.76 | 14.32 |
| Polish | 28.47 | 14.42 | 12.68 | 28.88 | 14.42 | 12.73 |
| Bulgarian | 26.36 | 9.15 | 16.54 | 25.58 | 8.40 | 16.13 |
| Latvian | 31.24 | 15.55 | 12.99 | 31.73 | 15.77 | 13.15 |
| Slovene | 26.75 | 12.25 | 11.64 | 27.19 | 12.34 | 11.79 |
| Estonian | 26.33 | 11.64 | 11.84 | 26.39 | 11.41 | 11.66 |
| Lithuanian | 26.79 | 12.43 | 11.44 | 26.76 | 12.45 | 11.59 |
| Slovak | 30.30 | 15.04 | 13.14 | 30.65 | 14.94 | 13.14 |
| Maltese | 29.71 | 14.55 | 12.73 | 30.51 | 14.62 | 12.86 |
| Croatian | 33.50 | 13.46 | 13.50 | 32.64 | 12.76 | 13.29 |
| Irish | 43.66 | 18.72 | 15.86 | 41.93 | 17.16 | 15.25 |
+
+guages between the validation and test set, although we do observe some languages with outlier performance: For Greek text, the model likely struggles with the representation of non-arabic subwords, but still performs decently well at the ROUGE-L level. Otherwise, Irish has unexpectedly high ROUGE scores, which we were unable to explain. This is especially surprising given the fact that the language is not even one officially supported by the multilingual embedding model used for this experiment.
+
+# 5.2 Cross-lingual Baselines
+
+As a baseline for XLS, we provide a simple two-step translate-then-summarize pipeline (Wang et al., 2022b). To generate summaries on longer contexts, we utilize a model based on the Longformer Encoder Decoder (LED) architecture (Beltagy et al., 2020), precisely a checkpoint previously fine-tuned on the English BillSum corpus (Kornilova and Eidelman, 2019). Translation from English to target languages is done with
+
+Table 3: Extractive summarization baseline with modified LexRank. We report ROUGE F1 scores for both the validation and test splits.
+
+ | Validation | Test |
| R-1 | R-2 | R-L | R-1 | R-2 | R-L |
| LED | 31.67 | 13.00 | 16.17 | 31.14 | 13.01 | 16.20 |
| LexRank-EN | 39.42 | 20.03 | 18.53 | 39.44 | 20.02 | 18.73 |
| LexRank-ES | 27.04 | 16.43 | 14.75 | 28.34 | 17.12 | 15.23 |
| Oracle | 52.84 | 39.79 | 43.87 | 54.55 | 41.01 | 45.06 |
+
+Table 4: Cross-lingual summarization setup for English-Spanish. We report ROUGE F1 scores for both the validation and test splits on the Spanish subset.
+
+OPUS-MT (Tiedemann and Thottingal, 2020). To deal with long documents exceeding the particular model's window size, we greedily chunk text if necessary. To represent an upper limit of performance, we compare a translate-then-summarize setup from English to Spanish, which can be regarded as one of the language pairs with the highest MT performance, due to data availability and linguistic similarity of the source and target language.
+
+As baselines, we provide translations of the English gold summaries into the target language (again with the Opus MT model), as well as a translation of the extractive LexRank summary from the previous experiment. Results seen in Table 4 are surprising: While the abstractive model seems to improve over the purely Spanish-based LexRank summary (LexRank-ES) by a significant margin, it turns out that translating the English LexRank baseline drastically improves results in terms of ROUGE scores. We assume that this is related to truncation and re-phrasing happening during the translation step.
+
+# 5.3 Open Problems
+
+The most obvious problem for this dataset is the extreme length, and also length disparity between documents. This is especially apparent when comparing the length to average samples in CNN/DailyMail (Hermann et al., 2015), where the mean article length is about 16 times shorter; this makes content selection significantly more challenging.
+
+Secondly, incorporating hierarchical information about the reference text could greatly improve context relevance in such extensive settings. However, this is not only restricted to the reference document, but could also be considered for the (hierarchical) construction of long-form summary texts. Given that previous datasets do not come with such long output samples, this has to our knowledge not been previously tackled in the literature.
+
+Ultimately, the question of equal coverage for
+
+lesser-resourced languages is also not fully answered. While we attempt to treat languages in our dataset equally, this comes with its particular set of challenges and performance hits in highly available languages.
+
+# 6 Conclusion and Future Work
+
+Throughout this work, we have detailed the creation of a new multilingual corpus for text summarization, based on legal acts from the European Union. We further provided a more detailed analysis of the underlying data and sample quality and hypothesized potential applications to open problems in the community, such as long-form summarization or cross-lingual application scenarios. Our dataset is publicly available on the web, and comes with a set of monolingual extractive baselines that provide suitable reference points for any future work in this direction.
+
+In particular, we intend to focus on exploiting the structure of summaries for a more guided generation of output texts. Especially for extremely long legal texts, template structures could be utilized. On a more general level, we expect that progress in long-form models is required to achieve remotely sensible results on extreme-length generative tasks. Alternative approaches in the meantime could include aspect-driven methods for building summaries in an iterative fashion.
+
+Finally, on top of the static snapshot presented in this work, we are also working towards a continually updated data repository of this resource, which would then include newly added texts (or summaries) for EU texts.
+
+# 7 Limitations
+
+While our work considers comparatively high-quality data samples, there still remain some assumptions about the underlying text sources, which lead to some of the following limitations:
+
+1. Documents themselves (both sources and summaries) may link to external articles or related regulations for further information. Some of the linked documents might indeed contain relevant contextual information, but are as such not considered in our version.
+
+2. On a similar note, we mentioned that some summaries aggregate content from several legal acts, as outlined in Section 3.1.2; this is
+
+not considered in full at the current stage and might cause limitations.
+
+3. Legal acts may exist in several iterations, drafted up at different points in time. To the best of our knowledge, we extracted the most recent version and its associated summary.
+4. For evaluation of generated summarization quality, we provide $n$ -gram-based ROUGE scores, which have previously been argued to poorly reflect particular aspects, e.g., factual consistency or fluency. Given this, baseline performance should be taken in clear context for future work.
+
+# Broader Impact & Ethical Issues
+
+With the release of our data as a public resource, we want to touch on the potential ethical implications of this release: As our data is already available (though much more inaccessible) through the EURLex platform, we do not see any ethical concerns in a repurposed and bundled release of this dataset from such a standpoint. To our knowledge, human-written reference and summary texts, as well as the accompanying translations into the European languages, have undergone review within instances of the European Union, leading to no clear concerns in data quality, especially with respect to potential privacy violations or harmful text content.
+
+However, we acknowledge that this resource reinforces a certain availability bias towards European languages, which needs to be acknowledged by follow-up work. On the other hand, we believe that the release of resources including underrepresented languages, for example, Irish and Maltese, outweighs this concern and fosters future research in a more multilingual way.
+
+# Acknowledgements
+
+We want to especially thank Reviewer 1 for their constructive feedback and suggestion of further experiments in their review.
+
+# References
+
+Dennis Aumiller, Satya Almasian, Sebastian Lackner, and Michael Gertz. 2021. Structural text segmentation of legal documents. In ICAIL '21: Eighteenth International Conference for Artificial Intelligence and Law, São Paulo Brazil, June 21 - 25, 2021, pages 2-11. ACM.
+
+Yu Bai, Yang Gao, and Heyan Huang. 2021. Crosslingual abstractive summarization with limited parallel resources. In Proceedings of the 59th Annual Meeting of the Association for Computational Linguistics and the 11th International Joint Conference on Natural Language Processing (Volume 1: Long Papers), pages 6910-6924, Online. Association for Computational Linguistics.
+Iz Beltagy, Matthew E Peters, and Arman Cohan. 2020. Longformer: The long-document transformer. arXiv preprint arXiv:2004.05150.
+Hélène Bernet and Pascale Berteloot. 2006. Eur-lex: A multilingual on-line website for european union law. International Review of Law Computers & Technology, 20(3):337-339.
+Paheli Bhattacharya, Kaustubh Hiware, Subham Rajgaria, Nilay Pochhi, Kripabandhu Ghosh, and Saptarshi Ghosh. 2019. A comparative study of summarization algorithms applied to legal case judgments. In Advances in Information Retrieval - 41st European Conference on IR Research, ECIR 2019, Cologne, Germany, April 14-18, 2019, Proceedings, Part I, volume 11437 of Lecture Notes in Computer Science, pages 413-428. Springer.
+Steven Bird, Ewan Klein, and Edward Loper. 2009. Natural Language Processing with Python: Analyzing Text with the Natural Language Toolkit. O'Reilly Media, Inc.
+Rishi Bommasani and Claire Cardie. 2020. Intrinsic evaluation of summarization datasets. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 8075-8096, Online. Association for Computational Linguistics.
+Isabel Cachola, Kyle Lo, Arman Cohan, and Daniel Weld. 2020. TLDR: Extreme summarization of scientific documents. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 4766-4777, Online. Association for Computational Linguistics.
+Ilias Chalkidis, Emmanouil Fergadiotis, Prodromos Malakasiotis, Nikolaos Aletras, and Ion Androutopoulos. 2019a. Extreme multi-label legal text classification: A case study in EU legislation. In Proceedings of the Natural Legal Language Processing Workshop 2019, pages 78-87, Minneapolis, Minnesota. Association for Computational Linguistics.
+Ilias Chalkidis, Emmanouil Fergadiotis, Prodromos Malakasiotis, and Ion Androutsopoulos. 2019b. Large-scale multi-label text classification on EU legislation. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 6314-6322, Florence, Italy. Association for Computational Linguistics.
+Ilias Chalkidis, Manos Fergadiotis, and Ion Androutopoulos. 2021. MultiEURLEX - a multi-lingual
+
+and multi-label legal document classification dataset for zero-shot cross-lingual transfer. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 6974-6996, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Günes Erkan and Dragomir R. Radev. 2004. Lexrank: Graph-based lexical centrality as salience in text summarization. Journal of Artificial Intelligence Research, 22:457-479.
+Mehwish Fatima and Michael Strube. 2021. A novel Wikipedia based dataset for monolingual and crosslingual summarization. In Proceedings of the Third Workshop on New Frontiers in Summarization, pages 39-50, Online and in Dominican Republic. Association for Computational Linguistics.
+Dominik Frefel. 2020. Summarization corpora of Wikipedia articles. In Proceedings of the 12th Language Resources and Evaluation Conference, pages 6651-6655, Marseille, France. European Language Resources Association.
+Christoph Gebendorfer and Ahmed Elnaggar. 2018. Legal jrc-acquis sum - text summarization corpus. In Technical University of Munich. (Date accessed: 21.06.2022).
+Max Grusky, Mor Naaman, and Yoav Artzi. 2018. Newsroom: A dataset of 1.3 million summaries with diverse extractive strategies. In Proceedings of the 2018 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long Papers), pages 708-719, New Orleans, Louisiana. Association for Computational Linguistics.
+Tahmid Hasan, Abhik Bhattacharjee, Md. Saiful Islam, Kazi Mubasshir, Yuan-Fang Li, Yong-Bin Kang, M. Sohel Rahman, and Rifat Shahriyar. 2021. XLsum: Large-scale multilingual abstractive summarization for 44 languages. In Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 4693-4703, Online. Association for Computational Linguistics.
+Karl Moritz Hermann, Tomás Kocisky, Edward Grefenstette, Lasse Espeholt, Will Kay, Mustafa Suleyman, and Phil Blunsom. 2015. Teaching machines to read and comprehend. In Advances in Neural Information Processing Systems 28: Annual Conference on Neural Information Processing Systems 2015, December 7-12, 2015, Montreal, Quebec, Canada, pages 1693-1701.
+Matthew Honnibal, Ines Montani, Sofie Van Landeghem, and Adriane Boyd. 2020. spaCy: Industrial-strength Natural Language Processing in Python.
+Svea Klaus, Ria Van Hecke, Kaweh Djafari Naini, Ismail Sengor Altingovde, Juan Bernabe-Moreno, and Enrique Herrera-Viedma. 2022. Summarizing legal
+
+regulatory documents using transformers. In SIGIR '22: The 45th International ACM SIGIR Conference on Research and Development in Information Retrieval, Madrid, Spain, July 11 - 15, 2022, pages 2426-2430. ACM.
+Philipp Koehn. 2005. Europarl: A parallel corpus for statistical machine translation. In Proceedings of Machine Translation Summit X: Papers, pages 79-86, Phuket, Thailand.
+Anastassia Kornilova and Vladimir Eidelman. 2019. *BillSum: A corpus for automatic summarization of US legislation*. In *Proceedings of the 2nd Workshop on New Frontiers in Summarization*, pages 48-56, Hong Kong, China. Association for Computational Linguistics.
+Faisal Ladhak, Esin Durmus, Claire Cardie, and Kathleen McKeown. 2020. WikiLingua: A new benchmark dataset for cross-lingual abstractive summarization. In Findings of the Association for Computational Linguistics: EMNLP 2020, pages 4034-4048, Online. Association for Computational Linguistics.
+Mike Lewis, Yinhan Liu, Naman Goyal, Marjan Ghazvininejad, Abdelrahman Mohamed, Omer Levy, Veselin Stoyanov, and Luke Zettlemoyer. 2020. BART: Denoising sequence-to-sequence pretraining for natural language generation, translation, and comprehension. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7871-7880, Online. Association for Computational Linguistics.
+Chin-Yew Lin. 2004. ROUGE: A package for automatic evaluation of summaries. In Text Summarization Branches Out, pages 74-81, Barcelona, Spain. Association for Computational Linguistics.
+Enaldo Loza Mencia and Johannes Furnkranz. 2010. Efficient multilabel classification algorithms for large-scale problems in the legal domain. In Enrico Francesconi, Simonetta Montemagni, Wim Peters, and Daniela Tiscornia, editors, Semantic Processing of Legal Texts – Where the Language of Law Meets the Law of Language, 1 edition, volume 6036 of Lecture Notes in Artificial Intelligence, pages 192–215. Springer-Verlag.
+Hans Peter Luhn. 1958. The automatic creation of literature abstracts. IBM Journal of Research and Development, 2(2):159-165.
+Laura Manor and Junyi Jessy Li. 2019. Plain English summarization of contracts. In Proceedings of the Natural Legal Language Processing Workshop 2019, pages 1-11, Minneapolis, Minnesota. Association for Computational Linguistics.
+Ramesh Nallapati, Feifei Zhai, and Bowen Zhou. 2017. Summarunner: A recurrent neural network based sequence model for extractive summarization of documents. In Proceedings of the Thirty-First AAAI
+
+Conference on Artificial Intelligence, February 4-9, 2017, San Francisco, California, USA, pages 3075-3081. AAAI Press.
+Ramesh Nallapati, Bowen Zhou, Cicero dos Santos, Caglar Gulçehre, and Bing Xiang. 2016. Abstractive text summarization using sequence-to-sequence RNNs and beyond. In Proceedings of The 20th SIGNLL Conference on Computational Natural Language Learning, pages 280-290, Berlin, Germany. Association for Computational Linguistics.
+Shashi Narayan, Shay B. Cohen, and Mirella Lapata. 2018. Don't give me the details, just the summary! topic-aware convolutional neural networks for extreme summarization. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 1797-1807, Brussels, Belgium. Association for Computational Linguistics.
+Khanh Nguyen and Hal Daume III. 2019. Global Voices: Crossing borders in automatic news summarization. In Proceedings of the 2nd Workshop on New Frontiers in Summarization, pages 90-97, Hong Kong, China. Association for Computational Linguistics.
+Paul Over and James Yen. 2004. An Introduction to DUC 2004 Intrinsic Evaluation of Generic New Text Summarization Systems.
+Laura Perez-Beltrachini and Mirella Lapata. 2021. Models and datasets for cross-lingual summarisation. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 9408–9423, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Nils Reimers and Iryna Gurevych. 2019. SentenceBERT: Sentence embeddings using Siamese BERTnetworks. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3982-3992, Hong Kong, China. Association for Computational Linguistics.
+Nils Reimers and Iryna Gurevych. 2020. Making monolingual sentence embeddings multilingual using knowledge distillation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 4512-4525, Online. Association for Computational Linguistics.
+Evan Sandhaus. 2008. The New York Times Annotated Corpus, LDC2008T19.
+Thomas Scialom, Paul-Alexis Dray, Sylvain Lamprier, Benjamin Piwowarski, and Jacopo Staiano. 2020. MLSUM: The multilingual summarization corpus. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 8051-8067, Online. Association for Computational Linguistics.
+
+Jörg Tiedemann and Santhosh Thottingal. 2020. OPUS-MT — Building open translation services for the World. In Proceedings of the 22nd Annual Conference of the European Association for Machine Translation (EAMT), Lisbon, Portugal.
+Daniel Varab and Natalie Schluter. 2021. MassiveSumm: a very large-scale, very multilingual, news summarisation dataset. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 10150-10161, Online and Punta Cana, Dominican Republic. Association for Computational Linguistics.
+Jiaan Wang, Fandong Meng, Ziyao Lu, Duo Zheng, Zhixu Li, Jianfeng Qu, and Jie Zhou. 2022a. Clidsum: A benchmark dataset for cross-lingual dialogue summarization. arXiv preprint arXiv:2202.05599.
+Jiaan Wang, Fandong Meng, Duo Zheng, Yunlong Liang, Zhixu Li, Jianfeng Qu, and Jie Zhou. 2022b. A survey on cross-lingual summarization. arXiv preprint arXiv:2203.12515.
+Thomas Wolf, Lysandre Debut, Victor Sanh, Julien Chaumont, Clement Delangue, Anthony Moi, Pierric Cistac, Tim Rault, Remi Louf, Morgan Funtowicz, Joe Davison, Sam Shleifer, Patrick von Platen, Clara Ma, Yacine Jernite, Julien Plu, Canwen Xu, Teven Le Scao, Sylvain Gugger, Mariama Drame, Quentin Lhoest, and Alexander Rush. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations, pages 38-45, Online. Association for Computational Linguistics.
+Linting Xue, Noah Constant, Adam Roberts, Mihir Kale, Rami Al-Rfou, Aditya Siddhant, Aditya Barua, and Colin Raffel. 2021. mT5: A massively multilingual pre-trained text-to-text transformer. In Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 483-498, Online. Association for Computational Linguistics.
+Liu Yang, Mingyang Zhang, Cheng Li, Michael Bendersky, and Marc Najork. 2020. Beyond 512 tokens: Siamese multi-depth transformer-based hierarchical encoder for long-form document matching. In Proceedings of the 29th ACM International Conference on Information and Knowledge Management, CIKM '20, page 1725-1734, New York, NY, USA. Association for Computing Machinery.
+Manzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie, Chris Alberti, Santiago Ontañón, Philip Pham, Anirudh Ravula, Qifan Wang, Li Yang, and Amr Ahmed. 2020a. Big bird: Transformers for longer sequences. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+
+Manzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie, Chris Alberti, Santiago Ontanón, Philip Pham, Anirudh Ravula, Qifan Wang, Li Yang, and Amr Ahmed. 2020b. Big bird: Transformers for longer sequences. In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual.
+Ming Zhong, Danqing Wang, Pengfei Liu, Xipeng Qiu, and Xuanjing Huang. 2019. A closer look at data bias in neural extractive summarization models. In Proceedings of the 2nd Workshop on New Frontiers in Summarization, pages 80-89, Hong Kong, China. Association for Computational Linguistics.
+Chenguang Zhu, Ziyi Yang, Robert Gmyr, Michael Zeng, and Xuedong Huang. 2021. Leveraging lead bias for zero-shot abstractive news summarization. In SIGIR '21: The 44th International ACM SIGIR Conference on Research and Development in Information Retrieval, Virtual Event, Canada, July 11-15, 2021, pages 1462-1471. ACM.
+Junnan Zhu, Qian Wang, Yining Wang, Yu Zhou, Jiajun Zhang, Shaonan Wang, and Chengqing Zong. 2019. NCLS: Neural cross-lingual summarization. In Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), pages 3054–3064, Hong Kong, China. Association for Computational Linguistics.
+
+# A Language-specific Distributions
+
+Figure 4 displays available articles before filtering. Notably, the documents need not be subsets of one another, meaning the French document IDs might differ from English ones. Table 5 further compares the availability of language-specific articles before and after filtering, to provide an insight into the number of removed documents. The same table also provides a more concise overview of supported languages in popular frameworks, as well as an extension of statistics reported in Table 2 for the language-specific training sets. To illustrate crosslingual presence of Celex IDs, we plot the inverse availability distribution (sample is available in at least $k$ languages) in Figure 5. Around $84\%$ of the samples are available in 20 or more languages.
+
+# B Implementation Details for Baselines
+
+For extractive monolingual models, we use the checkpoint "paraphrase-multilingual-mpnet-base-v2", without any further fine-tuning, using version
+
+| Language | No. articles before after | Availability S-T spacy ntlk | Article token length Reference | Comp. ratio | n-gram novelty 1-gram | 2-gram |
| Reference | Summary |
| English (en) | 1,974 | 1,504 | ✓ | ✓ | ✓ | 12206 ± 42429 | 799 ± 349 | 16 ± 62 | 44.10 | 65.97 |
| French (fr) | 1,969 | 1,505 | ✓ | ✓ | ✓ | 13192 ± 43950 | 892 ± 395 | 16 ± 63 | 45.07 | 64.13 |
| German (de) | 1,966 | 1,490 | ✓ | ✓ | ✓ | 11144 ± 41061 | 748 ± 330 | 16 ± 68 | 44.85 | 66.95 |
| Spanish (es) | 1,964 | 1,487 | ✓ | ✓ | ✓ | 13581 ± 44574 | 932 ± 420 | 15 ± 57 | 44.76 | 61.51 |
| Italian (it) | 1,867 | 1,403 | ✓ | ✓ | ✓ | 13152 ± 44641 | 845 ± 370 | 16 ± 67 | 44.77 | 67.00 |
| Portuguese (pt) | 1,845 | 1,376 | ✓ | ✓ | ✓ | 12629 ± 29921 | 896 ± 391 | 14 ± 38 | 43.84 | 64.00 |
| Dutch (nl) | 1,844 | 1,376 | ✓ | ✓ | ✓ | 13233 ± 44638 | 834 ± 362 | 17 ± 69 | 44.41 | 65.86 |
| Danish (da) | 1,843 | 1,377 | ✓ | ✓ | ✓ | 11947 ± 43155 | 717 ± 308 | 18 ± 71 | 46.96 | 68.27 |
| Greek (el) | 1,837 | 1,366 | ✓ | ✓ | ✓ | 13609 ± 45411 | 863 ± 369 | 17 ± 64 | 44.86 | 66.70 |
| Finnish (fi) | 1,825 | 1,366 | ✓ | ✓ | ✓ | 9792 ± 41021 | 575 ± 247 | 18 ± 93 | 53.41 | 77.26 |
| Swedish (sv) | 1,822 | 1,362 | ✓ | ✓ | ✓ | 10796 ± 26923 | 718 ± 305 | 15 ± 40 | 46.74 | 69.62 |
| Romanian (ro) | 1,817 | 1,353 | ✓ | ✓ | ✘ | 13646 ± 45644 | 826 ± 356 | 17 ± 67 | 45.42 | 67.80 |
| Hungarian (hu) | 1,813 | 1,336 | ✓ | ✘ | ✘ | 12230 ± 46764 | 702 ± 298 | 19 ± 84 | 53.23 | 75.68 |
| Czech (cs) | 1,812 | 1,359 | ✓ | ? | ✓ | 12469 ± 46640 | 715 ± 307 | 18 ± 77 | 46.75 | 71.89 |
| Polish (pl) | 1,811 | 1,353 | ✓ | ✓ | ✓ | 11560 ± 33296 | 739 ± 324 | 16 ± 48 | 46.69 | 71.01 |
| Bulgarian (bg) | 1,792 | 1,332 | ✓ | ✘ | ✘ | 13397 ± 45578 | 819 ± 350 | 17 ± 69 | 47.00 | 68.44 |
| Latvian (lv) | 1,790 | 1,334 | ✓ | ? | ✘ | 11841 ± 46552 | 670 ± 289 | 19 ± 83 | 50.23 | 74.55 |
| Slovene (sl) | 1,789 | 1,332 | ✓ | ✘ | ✓ | 11357 ± 32842 | 712 ± 305 | 16 ± 48 | 47.28 | 71.57 |
| Estonian (et) | 1,788 | 1,332 | ✓ | ✘ | ✓ | 10778 ± 45157 | 581 ± 249 | 20 ± 94 | 52.20 | 77.46 |
| Lithuanian (lt) | 1,788 | 1,335 | ✓ | ? | ✓ | 11943 ± 46673 | 669 ± 290 | 19 ± 88 | 47.79 | 74.00 |
| Slovak (sk) | 1,788 | 1,325 | ✓ | ? | ✘ | 11600 ± 32968 | 729 ± 319 | 16 ± 47 | 48.20 | 73.42 |
| Maltese (mt) | 1,770 | 1,315 | ✘ | ✘ | ✘ | 12711 ± 48156 | 685 ± 299 | 20 ± 85 | 54.77 | 81.43 |
| Croatian (hr) | 1,762 | 1,278 | ✓ | ? | ✘ | 10051 ± 19390 | 712 ± 307 | 14 ± 28 | 48.62 | 72.61 |
| Irish (ga) | 427 | 391 | ✘ | ? | ✘ | 28152 ± 63360 | 948 ± 385 | 46 ± 137 | 45.89 | 70.38 |
+
+Table 5: Supplementary statistics of the EUR-Lex-Sum corpus across languages. We list the total number of available articles (before and after filtering), and whether a particular language is supported by sentence-transformers multilingual models ("S-T"), or has available language-specific models in spaCy (Honnibal et al., 2020) or nltk (Bird et al., 2009), respectively. "?" indicates potential support through general-purpose models with uncertain segmentation quality. We also provide abridged statistics along the lines of Figure 3 and Table 2 for the training partition of all languages.
+
+
+Figure 4: The number of all crawled document/summary pairs across the 24 official EU languages before filtering. Irish exhibits a greatly limited availability due to its recent addition as an official language.
+
+
+Figure 5: Celex IDs present in at least $k$ languages.
+
+2.1.0 of sentence-transformers. We do use a slightly modified version of their LexRank implementation to avoid a bug preventing the power method from converging due to "negative likelihoods". This can be fixed by normalizing similarity scores to strictly positive values.
+
+The abstractive LEDBill model8 was used through the pipeline feature available in Huggingface Transformers (Wolf et al., 2020), version 4.18. We use greedy decoding for text generation and chunk text into blocks of approximately 4096 tokens, where we then concatenate the output summaries of consecutive sections. A similar setup was used for translation, where we use the Opus MT models for respective language pairs (HelsinkiNLP/opus-mt----) (Tiedemann and Thottingal, 2020), although the context size used for chunking is 500 subword tokens (to account for model-specific padding). We refer to the model card for configuration
+
+hyperparameters of LEDBill and Opus $\mathrm{MT^{10}}$ . Parameter counts for all three neural models can be found in Table 6.
+
+For the computation of ROUGE scores, we utilize the implementation by Google Research11, with stemming disabled.
+
+For GPU inference, we use a machine with a single Nvidia Titan RTX with 24 GB GPU VRAM and 64 GB RAM. Obtaining results for the LexRank baselines on both the test and validation set takes less than 2.5 minutes on average for the validation and test samples (375 total generated summaries). In comparison, the generation with LEDBill takes approximately 12 hours per 375 validation/test samples. Computationally speaking, translations lie somewhere in between the previous settings, taking around 20 minutes to compute.
+
+| Model | Parameters |
| S-T | 278MM |
| LEDBill | 162MM |
| Opus MT | 78MM |
+
+Table 6: Approximate parameter count for utilized neural systems. "S-T" represents the sentence-transformers model used for computing sentence embeddings in the modified LexRank baseline.
\ No newline at end of file
diff --git a/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/images.zip b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/images.zip
new file mode 100644
index 0000000000000000000000000000000000000000..cf96b16ba21425b4115edea76ffc76e412d09516
--- /dev/null
+++ b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/images.zip
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:8f69f6315b3687587ffd0ddcb83f116fa64f2ebe70ded45f0109458a009eac7a
+size 616873
diff --git a/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/layout.json b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/layout.json
new file mode 100644
index 0000000000000000000000000000000000000000..53497b94db3635b50bddbd7a9f37d17ab74d5b3a
--- /dev/null
+++ b/eurlexsumamultiandcrosslingualdatasetforlongformsummarizationinthelegaldomain/layout.json
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:da2c35e7ac645e45365a175410fd1172ffbb1770abccbae9f75fae517b46c047
+size 404117