MoverScore: Text Generation Evaluating with Contextualized Embeddings and Earth Mover Distance

A robust evaluation metric has a profound impact on the development of text generation systems. A desirable metric compares system output against references based on their semantics rather than surface forms. In this paper we investigate strategies to encode system and reference texts to devise a metric that shows a high correlation with human judgment of text quality. We validate our new metric, namely MoverScore, on a number of text generation tasks including summarization, machine translation, image captioning, and data-to-text generation, where the outputs are produced by a variety of neural and non-neural systems. Our findings suggest that metrics combining contextualized representations with a distance measure perform the best. Such metrics also demonstrate strong generalization capability across tasks. For ease-of-use we make our metrics available as web service.


Introduction
The choice of evaluation metric has a significant impact on the assessed quality of natural language outputs generated by a system. A desirable metric assigns a single, real-valued score to the system output by comparing it with one or more reference texts for content matching. Many natural language generation (NLG) tasks can benefit from robust and unbiased evaluation, including textto-text (machine translation and summarization), data-to-text (response generation), and image-totext (captioning) (Gatt and Krahmer, 2018). Without proper evaluation, it can be difficult to judge on system competitiveness, hindering the development of advanced algorithms for text generation.
It is an increasingly pressing priority to develop better evaluation metrics given the recent advances in neural text generation. Neural models provide the flexibility to copy content from source text as well as generating unseen words (See et al., 2017). This aspect is hardly covered by existing metrics. With greater flexibility comes increased demand for unbiased evaluation. Diversity-promoting objectives make it possible to generate diverse natural language descriptions (Li et al., 2016;Wiseman et al., 2018). But standard evaluation metrics including BLEU (Papineni et al., 2002) and ROUGE (Lin, 2004) compute the scores based primarily on n-gram co-occurrence statistics, which are originally proposed for diagnostic evaluation of systems but not capable of evaluating text quality (Reiter, 2018), as they are not designed to measure if, and to what extent, the system and reference texts with distinct surface forms have conveyed the same meaning. Recent effort on the applicability of these metrics reveals that while compelling text generation system ascend on standard metrics, the text quality of system output is still hard to be improved (Böhm et al., 2019).
Our goal in this paper is to devise an automated evaluation metric assigning a single holistic score to any system-generated text by comparing it against human references for content matching. We posit that it is crucial to provide a holistic measure attaining high correlation with human judgments so that various neural and non-neural text generation systems can be compared directly. Intuitively, the metric assigns a perfect score to the system text if it conveys the same meaning as the reference text. Any deviation from the reference content can then lead to a reduced score, e.g., the system text contains more (or less) content than the reference, or the system produces ill-formed text that fails to deliver the intended meaning.
We investigate the effectiveness of a spectrum of distributional semantic representations to encode system and reference texts, allowing them to be compared for semantic similarity across multiple natural language generation tasks. Our new metric quantifies the semantic distance between system and reference texts by harnessing the power of contextualized representations (Peters et al., 2018;Devlin et al., 2018) and a powerful distance metric (Rubner et al., 2000) for better content matching. Our contributions can be summarized as follows: • We formulate the problem of evaluating generation systems as measuring the semantic distance between system and reference texts, assuming powerful continuous representations can encode any type of semantic and syntactic deviations.
• We investigate the effectiveness of existing contextualized representations and Earth Mover's Distance (Rubner et al., 2000) for comparing system predictions and reference texts, leading to our new automated evaluation metric that achieves high correlation with human judgments of text quality.
• Our metric outperforms or performs comparably to strong baselines on four text generation tasks including summarization, machine translation, image captioning, and data-to-text generation, suggesting this is a promising direction moving forward.

Related Work
It is of fundamental importance to design evaluation metrics that can be applied to natural language generation tasks of similar nature, including summarization, machine translation, data-to-text generation, image captioning, and many others. All these tasks involve generating texts of sentence or paragraph length. The system texts are then compared with one or more reference texts of similar length for semantic matching, whose scores indicate how well the systems perform on each task. In the past decades, however, evaluation of these natural language generation tasks has largely been carried out independently within each area.
Summarization A dominant metric for summarization evaluation is ROUGE (Lin, 2004), which measures the degree of lexical overlap between a system summary and a set of reference summaries. Its variants consider overlap of unigrams (-1), bigrams (-2), unigrams and skip bigrams with a maximum gap of 4 words (-SU4), longest common subsequences (-L) and its weighted version (-W-1.2), among others. Metrics such as Pyramid (Nenkova and Passonneau, 2004) and BE (Hovy et al., 2006;Tratz and Hovy, 2008) further compute matches of content units, e.g., (head-word, modifier) tuples, that often need to be manually extracted from reference summaries. These metrics achieve good correlations with human judgments in the past. However, they are not general enough to account for the relatedness between abstractive summaries and their references, as a system abstract can convey the same meaning using different surface forms. Furthermore, large-scale summarization datasets such as CNN/Daily Mail (Hermann et al., 2015) and Newsroom (Grusky et al., 2018) use a single reference summary, making it harder to obtain unbiased results when only lexical overlap is considered during summary evaluation.
Machine Translation A number of metrics are commonly used in MT evaluation. Most of these metrics compare system and reference translations based on surface forms such as word/character n-gram overlaps and edit distance, but not the meanings they convey. BLEU (Papineni et al., 2002) is a precision metric measuring how well a system translation overlaps with human reference translations using n-gram co-occurrence statistics.
Other metrics include SentBLEU, NIST, chrF, TER, WER, PER, CDER, and METEOR (Lavie and Agarwal, 2007) that are used and described in the WMT metrics shared task (Bojar et al., 2017;Ma et al., 2018). RUSE (Shimanaka et al., 2018) is a recent effort to improve MT evaluation by training sentence embeddings on large-scale data obtained in other tasks. Additionally, preprocessing reference texts is crucial in MT evaluation, e.g., normalization, tokenization, compound splitting, etc. If not handled properly, different preprocessing strategies can lead to inconsistent results using word-based metrics (Post, 2018).
Data-to-text Generation BLEU can be poorly suited to evaluating data-to-text systems such as dialogue response generation and image captioning. These systems are designed to generate texts with lexical and syntactic variation, communicating the same information in many different ways. BLEU and similar metrics tend to reward systems that use the same wording as reference texts, causing repetitive word usage that is deemed undesirable to humans (Liu et al., 2016). In a similar vein, evaluating the quality of image captions can be challenging. CIDEr (Vedantam et al., 2015) uses tf-idf weighted n-grams for similarity estimation; and SPICE (Anderson et al., 2016) incorporates synonym matching over scene graphs. Novikova et al. (2017) examine a large number of word-and grammar-based metrics and demonstrate that they only weakly reflect human judgments of system outputs generated by data-driven, end-to-end natural language generation systems.

Metrics based on Continuous Representations
Moving beyond traditional metrics, we envision a new generation of automated evaluation metrics comparing system and reference texts based on semantics rather than surface forms to achieve better correlation with human judgments. A number of previous studies exploit static word embeddings (Ng and Abrecht, 2015;Lo, 2017) and trained classifers (Peyrard et al., 2017;Shimanaka et al., 2018) to improve semantic similarity estimation, replacing lexical overlaps. In contemporaneous work, Zhang et al. (2019) describe a method comparing system and reference texts for semantic similarity leveraging the BERT representations (Devlin et al., 2018), which can be viewed as a special case of our metrics and will be discussed in more depth later. More recently, Clark et al. (2019) present a semantic metric relying on sentence mover's similarity and the ELMo representations (Peters et al., 2018) and apply them to summarization and essay scoring. Mathur et al. (2019) introduce unsupervised and supervised metrics based on the BERT representations to improve MT evaluation, while Peyrard (2019a) provides a composite score combining redundancy, relevance and informativeness to improve summary evaluation.
In this paper, we seek to accurately measure the (dis)similarity between system and reference texts drawing inspiration from contextualized representations and Word Mover's Distance (WMD; Kusner et al., 2015). WMD finds the "traveling distance" of moving from the word frequency distribution of the system text to that of the reference, which is essential to capture the (dis)similarity between two texts. Our metrics differ from the contemporaneous work in several facets: (i) we explore the granularity of embeddings, leading to two variants of our metric, word mover and sentence mover; (ii) we investigate the effectiveness of diverse pretrained embeddings and finetuning tasks; (iii) we study the approach to consolidate layer-wise information within contextualized embeddings; (iii) our metrics demonstrate strong generalization capability across four tasks, oftentimes outperforming the supervised ones. We now de-scribe our method in detail.

Our MoverScore Meric
We have motivated the need for better metrics capable of evaluating disparate NLG tasks. We now describe our metric, namely MoverScore, built upon a combination of (i) contextualized representations of system and reference texts and (ii) a distance between these representations measuring the semantic distance between system outputs and references. It is particularly important for a metric to not only capture the amount of shared content between two texts, i.e., intersect(A,B), as is the case with many semantic textual similarity measures (Peters et al., 2018;Devlin et al., 2018); but also to accurately reflect to what extent the system text has deviated from the reference, i.e., union(A,B)intersect(A,B), which is the intuition behind using a distance metric.

Measuring Semantic Distance
Let x = (x 1 , . . . , x m ) be a sentence viewed as a sequence of words. We denote by x n the sequence of n-grams of x (i.e., x 1 = x is the sequence of words and x 2 is the sequence of bigrams). Furthermore, let f x n ∈ R |x n | + be a vector of weights, one weight for each n-gram of x n . We can assume f T x n 1 = 1, making f x n a distribution over n-grams. Intuitively, the effect of some n-grams like those including function words can be downplayed by giving them lower weights, e.g., using Inverse Document Frequency (IDF).
Word Mover's Distance (WMD) (Kusner et al., 2015), a special case of Earth Mover's Distance (Rubner et al., 2000), measures semantic distance between texts by aligning semantically similar words and finding the amount of flow traveling between these words. It was shown useful for text classification and textual similarity tasks (Kusner et al., 2015). Here, we formulate a generalization operating on n-grams. Let x and y be two sentences viewed as sequences of ngrams: x n and y n . If we have a distance metric d between n-grams, then we can define the transportation cost matrix C such that C ij = d(x n i , y n j ) is the distance between the i-th n-gram of x and the j-th n-gram of y. The WMD between the two sequences of n-grams x n and y n with associated n-gram weights f x n and f y n is then given by: where F is the transportation flow matrix with F ij denoting the amount of flow traveling from the ith n-gram x n i in x n to the j-th n-gram y n j in y n . Here, C, F denotes the sum of all matrix entries of the matrix C F , where denotes elementwise multiplication. Then WMD(x n , y n ) is the minimal transportation cost between x n and y n where n-grams are weighted by f x n and f y n .
In practice, we compute the Euclidean distance between the embedding representations of n-grams: d(x n i , y n j ) = ||E(x n i ) − E(y n j )|| 2 where E is the embedding function which maps an ngram to its vector representation. Usually, static word embeddings like word2vec are used to compute E but these cannot capture word order or compositionality. Alternatively, we investigate contextualized embeddings like ELMo and BERT because they encode information about the whole sentence into each word vector.
We compute the n-gram embeddings as the weighted sum over its word embeddings. Formally, if x n i = (x i , . . . , x i+n−1 ) is the i-th n-gram from sentence x, its embedding is given by: where idf(x k ) is the IDF of word x k computed from all sentences in the corpus and E(x k ) is its word vector. Furthermore, the weight associated to the n-gram x n i is given by: where Z is a normalizing constant s.t. f T x n 1 = 1, In the limiting case where n is larger than the sentence's size, x n contains only one n-gram: the whole sentence. Then WMD(x n , y n ) reduces to computing the distance between the two sentence embeddings, namely Sentence Mover's Distance (SMD), denoted as: where l x and l y are the size of sentences.

Hard and Soft Alignments
In contemporaneous work, BERTScore (Zhang et al., 2019) also models the semantic distance between system and reference texts for evaluating text generation systems. As shown in Figure 1, BERTScore (precision/recall) can be intuitively viewed as hard alignments (one-to-one) for words in a sentence pair, where each word in one sequence travels to the most semantically similar word in the other sequence. In contrast, MoverScore goes beyond BERTScore as it relies on soft alignments (manyto-one) and allows to map semantically related words in one sequence to the respective word in the other sequence by solving a constrained optimization problem: finding the minimum effort to transform between two texts. The formulation of Word Mover's Distance provides an important possibility to bias the metric towards precision or recall by using an asymmetric transportation cost matrix, which bridges a gap between MoverScore and BERTScore: Proposition 1 BERTScore (precision/recall) can be represented as a (non-optimized) Mover Distance C, F , where C is a transportation cost matrix based on BERT and F is a uniform transportation flow matrix. 2

Contextualized Representations
The task formulation naturally lends itself to deep contextualized representations for inducing word vectors E(x i ). Despite the recent success of multilayer attentive neural architectures (Devlin et al., 2018;Peters et al., 2018), consolidating layer-wise information remains an open problem as different layers capture information at disparate scales and task-specific layer selection methods may be limited (Liu et al., 2018(Liu et al., , 2019. Tenney et al. (2019) found that a scalar mix of output layers trained from task-dependent supervisions would be effective in a deep transformer-based model. Instead, we investigate aggregation functions to consolidate layer-wise information, forming stationary representations of words without supervision.
Consider a sentence x passed through contextualized encoders such as ELMo and BERT with L layers. Each layer of the encoders produces a vec-567 tor representation for each word x i in x. We denote by z i,l ∈ R d the representation given by layer l, a d-dimensional vector. Overall, x i receives L different vectors (z i,1 , . . . , z i,L ). An aggregation φ maps these L vectors to one final vector: where E(x i ) is the aggregated representation of the word x i . We study two alternatives for φ: (i) the concatenation of power means (Rücklé et al., 2018) as a generalized pooling mechanism, and (ii) a routing mechanism for aggregation (Zhao et al., , 2019. We relegate the routing method to appendix, as it does not yield better results than power means. Power Means Power means is an effective generalization of pooling techniques for aggregating information. It computes a non-linear average of a set of values with an exponent p (Eq. (4)). Following Rücklé et al. (2018), we exploit power means to aggregate vector representations (z i,l ) L l=1 pertaining to the i-th word from all layers of a deep neural architecture.
where exponentiation is applied elementwise. This generalized form can induce common named means such as arithmetic mean (p = 1) and geometric mean (p = 0). In extreme cases, a power mean reduces to the minimum value of the set when p = −∞, and the maximum value when p = +∞. The concatenation of p-mean vectors we use in this paper is denoted by: where ⊕ is vector concatenation; {p 1 , . . . , p K } are exponent values, and we use K = 3 with p = 1, ±∞ in this work.

Summary of MoverScore Variations
We investigate our MoverScore along four dimensions: (i) the granularity of embeddings, i.e., the size of n for n-grams, (ii) the choice of pretrained embedding mechanism, (iii) the fine-tuning task used for BERT 3 (iv) the aggregation technique (pmeans or routing) when applicable.
Granularity We used n = 1 and n = 2 as well as full sentences (n = size of the sentence).
Embedding Mechanism We obtained word embeddings from three different methods: static embedding with word2vec as well as contextualized embedding with ELMo and BERT. If n > 1, ngram embeddings are calculated by Eq. (1). Note that they represent sentence embeddings when n = size of the sentence.
Fine-tuning Tasks Natural Language Inference (NLI) and paraphrasing pose high demands in understanding sentence meaning. This motivated us to fine-tune BERT representations on two NLI datasets, MultiNLI and QANLI, and one Paraphrase dataset, QQP-the largest datasets in GLUE (Wang et al., 2018). We fine-tune BERT on each of these, yielding different contextualized embeddings for our general evaluation metrics.
Aggregation For ELMo, we aggregate word representations given by all three ELMo layers, using p-means or routing (see the appendix). Word representations in BERT are aggregated from the last five layers, using p-means or routing since the representations in the initial layers are less suited for use in downstream tasks (Liu et al., 2019).

Empirical Evaluation
In this section, we measure the quality of different metrics on four tasks: machine translation, text summarization, image captioning and dialogue generation. Our major focus is to study the correlation between different metrics and human judgment. We employ two text encoders to embed n-grams: BERT base , which uses a 12-layer transformer, and ELMO original , which uses a 3-layer BiLSTM. We use Pearson's r and Spearman's ρ to measure the correlation. We consider two variants of MoverScore: word mover and sentence mover, described below.
Word Mover We denote our word mover notation containing four ingredients as: WMD-Granularity+Embedding+Finetune+Aggregation.
For example, WMD-1+BERT+MNLI+PMEANS represents the semantic metric using word mover distance where unigram-based word embeddings fine-tuned on MNLI are aggregated by p-means.
Sentence Mover We denote our sentence mover notation with three ingredients as: SMD+Embedding+Finetune+Aggregation. For example, SMD+W2V represents the semantic metric using sentence mover distance where two sentence embeddings are computed as the weighted sum over their word2vec embeddings by Eq. (1).
Baselines We select multiple strong baselines for each task for comparison: SentBLEU, ME-TEOR++ (Guo et al., 2018), and a supervised metric RUSE for machine translation; ROUGE-1 and ROUGE-2 and a supervised metric S 3 best (Peyrard et al., 2017) for text summarization; BLEU and METEOR for dialogue response generation, CIDEr, SPICE, METEOR and a supervised metric LEIC (Cui et al., 2018) for image captioning. We also report BERTScore (Zhang et al., 2019) for all tasks (see §2). Due to the page limit, we only compare with the strongest baselines, the rest can be found in the appendix.

Machine Translation
Data We obtain the source language sentences, their system and reference translations from the WMT 2017 news translation shared task (Bojar et al., 2017). We consider 7 language pairs: from German (de), Chinese (zh), Czech (cs), Latvian (lv), Finnish (fi), Russian (ru), and Turkish (tr), resp. to English. Each language pair has approximately 3,000 sentences, and each sentence has one reference translation and multiple system translations generated by participating systems. For each system translation, at least 15 human assessments are independently rated for quality.
Results Table 1: In all language pairs, the best correlation is achieved by our word mover metrics that use a BERT pretrained on MNLI as the embedding generator and PMeans to aggregate the embeddings from different BERT layers, i.e., WMD-1/2+BERT+MNLI+PMeans. Note that our unsupervised word mover metrics even outperforms RUSE, a supervised metric. We also find that our word mover metrics outperforms the sentence mover. We conjecture that important information is lost in such a sentence representation while transforming the whole sequence of word vectors into one sentence embedding by Eq. (1).

Text Summarization
We use two summarization datasets from the Text Analysis Conference (TAC) 4 : TAC-2008 and TAC-2009, which contain 48 and 44 clusters, respectively. Each cluster includes 10 news articles (on the same topic), four reference summaries, and 57 (in TAC-2008) or 55 (in TAC-2009) system summaries generated by the participating systems. Each summary (either reference or system) has fewer than 100 words, and receives two human judgment scores: the Pyramid score (Nenkova and Passonneau, 2004) and the Responsiveness score. Pyramid measures how many important semantic content units in the reference summaries are covered by the system summary, while Responsiveness measures how well a summary responds to the overall quality combining both content and linguistic quality.
Results Tables 2: We observe that lexical metrics like ROUGE correlate above-moderate on TAC 2008 and 2009 datasets. In contrast, these metrics perform poorly on other tasks like Dialogue Generation (Novikova et al., 2017) and Image Captioning (Anderson et al., 2016). Apparently, strict matches on surface forms seems reasonable for extractive summarization datasets. However, we still see that our word mover metrics, i.e., WMD-1+BERT+MNLI+PMeans, perform better than or come close to even the supervised metric S 3 best .

Data-to-text Generation
We use two task-oriented dialogue datasets: BAGEL (Mairesse et al., 2010) and SFHOTEL (Wen et al., 2015), which contains 202 and 398 instances of Meaning Representation (MR). Each MR instance includes multiple references, and roughly two system utterances generated by different neural systems. Each system utterance receives three human judgment scores: informativeness, naturalness and quality score (Novikova et al., 2017). Informativeness measures how much information a system utterance provides with respect to an MR. Naturalness measures how likely a system utterance is generated by native speakers. Quality measures how well a system utterance captures fluency and grammar.
Results Tables 3: Interestingly, no metric produces an even moderate correlation with human judgments, including our own. We speculate that current contextualizers are poor at representing named entities like hotels and place names as well as numbers appearing in system and reference texts. However, best correlation is still achieved by our word mover metrics combining contextualized representations.

Image Captioning
We use a popular image captioning dataset: MS-COCO (Lin et al., 2014), which contains 5,000 images. Each image includes roughly five reference captions, and 12 system captions generated by the participating systems from 2015 COCO Captioning Challenge. For the system-level human correlation, each system receives five human judgment scores: M1, M2, M3, M4, M5 (Anderson et al., 2016). The M1 and M2 scores measure overall quality of the captions while M3, M4 and M5 scores measure correctness, detailedness and saliency of the captions. Following Cui et al. (2018), we compare the Pearson correlation with two system-level scores: M1 and M2, since we focus on studying metrics for the overall quality of the captions, leaving metrics understanding captions in different aspects (correctness, detailedness and saliency) to future work. Table 4: Word mover metrics outperform all baselines except for the supervised metric LEIC, which uses more information by considering both images and texts.

Further Analysis
Hard and Soft Alignments BERTScore is the harmonic mean of BERTScore-Precision and BERTScore-Recall, where both two can be decomposed as a combination of "Hard Mover Distance" (HMD) and BERT (see Prop. 1).
We use the representations in the 9-th BERT layer for fair comparison of BERTScore and MoverScore and show results on the machine translation task in Table 5. MoverScore outperforms both asymmetric HMD factors, while if they are combined via harmonic mean, BERTScore is on par with MoverScore. We conjecture that BERT softens hard alignments of BERTScore as contextualized embeddings encode information about the whole sentence into each word vector. We also observe that WMD-BIGRAMS slightly outperforms WMD-UNIGRAMS on 3 out of 4 language pairs.     Distribution of Scores In Figure 2, we take a closer look at sentence-level correlation in MT. Results reveal that the lexical metric SENTBLEU can correctly assign lower scores to system translations of low quality, while it struggles in judging system translations of high quality by assigning them lower scores. Our finding agrees with the observations found in Chaganty et al.

Machine Translation (zh−en) Machine Translation (zh−en)
Machine Translation (zh-en) Figure 3: Correlation in similar language (de-en) and distant language (zh-en) pair, where bordered area shows correlations between human assessment and metrics, the rest shows inter-correlations across metrics and DA is direct assessment rated by language experts. they strongly disagree on high-scoring system outputs. Importantly, we observe that our word mover metric combining BERT can clearly distinguish texts of two polar qualities.
Correlation Analysis In Figure 3, we observe existing metrics for MT evaluation attaining medium correlations (0.4-0.5) with human judgments but high inter-correlations between themselves. In contrast, our metrics can attain high correlations (0.6-0.7) with human judgments, performing robust across different language pairs. We believe that our improvements come from clearly distinguishing translations that fall on two extremes. pares Pearson correlations with our word mover metrics combining BERT fine-tuned on three different tasks. We observe that fine-tuning on closely related tasks improves correlations, especially fine-tuning on MNLI leads to an impressive improvement by 1.8 points on average.

Discussions
We showed that our metric combining contextualized embeddings and Earth Mover's Distance outperforms strong unsupervised metrics on 3 out of 4 tasks, i.e., METEOR++ on machine translation by 5.7 points, SPICE on image captioning by 3.0 points, and METEOR on dialogue response generation by 2.2 points. The best correlation we achieved is combining contextualized word embeddings and WMD, which even rivals or exceeds SOTA task-dependent supervised metrics across different tasks. Especially in machine translation, our word mover metric pushes correlations in machine translation to 74.3 on average (5.8 points over the SOTA supervised metric and 2.4 points over contemporaneous BERTScore). The major improvements come from contextualized BERT embeddings rather than word2vec and ELMo, and from fine-tuning BERT on large NLI datasets. However, we also observed that soft alignments (MoverScore) marginally outperforms hard alignments (BERTScore). Regarding the effect of ngrams in word mover metrics, unigrams slightly outperforms bigrams on average. For the effect of aggregation functions, we suggested effective techniques for layer-wise consolidations, namely p-means and routing, both of which are close to the performance of the best layer and on par with each other (see the appendix).

Conclusion
We investigated new unsupervised evaluation metrics for text generation systems combining contextualized embeddings with Earth Mover's Distance. We experimented with two variants of our metric, sentence mover and word mover. The latter has demonstrated strong generalization ability across four text generation tasks, oftentimes even outperforming supervised metrics. Our metric provides a promising direction towards a holistic metric for text generation and a direction towards more 'human-like ' (Eger et al., 2019) evaluation of text generation systems.
In future work, we plan to avoid the need for costly human references in the evaluation of text generation systems, and instead base evaluation scores on source texts and system predictions only, which would allow for 'next-level', unsupervised (in a double sense) and unlimited evaluation (Louis and Nenkova, 2013;Böhm et al., 2019). In this section, we prove Prop. 1 in the paper about viewing BERTScore (precision/recall) as a (nonoptimized) Mover Distance. As a reminder, the WMD formulation is: where F 1 = f n x and F 1 = f n y . Here, f n x and f n y denote vectors of weights for each n-gram of x n and y n .
BERTScore is defined as: Then, R BERT can be formulated in a "quasi" WMD form: where Z = y 1 i ∈y 1 idf(y 1 i ) and M is the size of n-grams in x 1 . Similarly, we can have P BERT in a quasi WMD form (omitted). Then, F BERT can be formulated as harmonic-mean of two WMD forms of P BERT and R BERT .

A.2 Routing
In this section, we study the aggregation function φ with a routing scheme, which has achieved good results in other NLP tasks (Zhao et al., , 2019. Specifically, we introduce a nonparametric clustering with Kernel Density Estimation (KDE) for routing since KDE bridges a family of kernel functions with underlying empirical distributions, which often leads to computational efficiency , defined as:

576
where d(·) is a distance function, γ ij denotes the underlying closeness between the aggregated vector v j and vector z i in the i-th layer, and k is a kernel function. Some instantiations of k(·) (Wand and Jones, 1994) are: One typical solution for KDE clustering to minimize f (z) is taking Mean Shift (Comaniciu and Meer, 2002), defined as: Intuitively, v j can be explained as a final aggregated vector from L contextualized layers. Then, we adopt SGD to update γ τ +1 ij : where α is a hyperparameter to control step size. The routing process is summarized in Algorithm 1.
Algorithm 1 Aggregation by Routing 1: procedure ROUTING(zij, ) 2: Initialize ∀i, j : γij = 0 3: while true do 4: foreach representation i and j in layer and + 1 do γij ← softmax (γij) 5: foreach representation j in layer + 1 do 6: vj ← i γijk (vj, zi)zi/ i k (vi, zi) 7: foreach representation i and j in layer and + 1 do γij ← γij + α · k(vj, zi) 8: loss ← log( i,j γijk(vj, zi)) 9: if |loss − preloss| < then 10: break 11: else 12: preloss ← loss 13: return vj Best Layer and Layer-wise Consolidation Table 6 compares our word mover based metric combining BERT representations on different layers with stronger BERT representations consolidated from these layers (using p-means and routing). We often see that which layer has best performance is taskdependent, and our word mover based metrics (WMD) with p-means or routing schema come close to the oracle performance obtained from the best layers.
Experiments Table 7, 8 and 9 show correlations between metrics (all baseline metrics and word mover based metrics) and human judgments on machine translation, text summarization and dialogue response generation, respectively. We find that word mover based metrics combining BERT fine-tuned on MNLI have highest correlations with humans, outperforming all of the unsupervised metrics and even supervised metrics like RUSE and S 3 f ull . Routing and p-means perform roughly equally well.  Table 6: Absolute Pearson correlations with segment-level human judgments on WMT17 to-English translations.    Table 9: Spearman correlation with utterance-level human judgments for BAGEL and SFHOTEL datasets.