Evaluating the Evaluation of Diversity in Natural Language Generation (2021)

Abstract: Despite growing interest in natural language generation (NLG) models that produce diverse outputs, there is currently no principled method for evaluating the diversity of an NLG system. In this work, we propose a framework for evaluating diversity metrics . The framework measures the correlation between a proposed diversity metric and a diversity parameter , a single parameter that controls some aspect of diversity in generated text. For example, a diversity parameter might be a binary variable used to instruct crowdsourcing workers to generate text with either low or high content diversity. We demonstrate the utility of our framework by: (a) establishing best practices for eliciting diversity judgments from humans, (b) showing that humans substantially outperform automatic metrics in estimating content diversity, and (c) demonstrating that existing methods for controlling diversity by tuning a “decoding parameter” mostly affect form but not meaning. Our framework can advance the understanding of different diversity metrics, an essential step on the road towards better NLG systems.

## introduction an important desideratum of natural language generation (nlg) systems is to produce outputs that are not only correct, but also diverse. for example, a dialog system @xcite should permit many responses for the prompt "how are you today?". similarly, we expect diverse responses in tasks such as story generation @xcite , question generation @xcite and question answering @xcite . despite growing effort to produce more diverse models @xcite @xcite , there is no standard evaluation metric for measuring diversity. thus, different papers evaluate diversity differently (if at • nothing, really. ## background: diversity evaluation recently, interest in diversity has increased @xcite , resulting in multiple proposals for its evaluation. we describe recent approaches, highlighting the need for a standard way to evaluate metrics. perplexity is the standard metric in language modeling, measuring the proximity of a language model (lm), p lm , to the true distribution, p ref , by approximating the cross-entropy h(p ref , p lm ) with held-out data from p ref . thus, perplexity captures to some extent diversity. for example, a dialog model that puts all probability mass on the output "i don't know" for any given context will obtain infinite perplexity once it encounters any other response. this property makes perplexity popular in lm-based nlg models, and often it is the only reported measure for diversity @xcite @xcite . however, perplexity does not purely measure diversity, and high perplexity does not entail low diversity. for example, a lm with a uniform distribution over the vocabulary for each decoded token has high diversity, but its perplexity will be extremely high, due to its low quality. moreover, perplexity evaluates a lm, while the diversity of a nlg system is also strongly affected by the decoding procedure. for example, top-k and nucleus sampling are popular decoding schemes that tradeoff quality and diversity by ignoring some of the lm probability mass @xcite . last, some nlg models, such as generative adversarial networks (gans) @xcite are not language models. while one can approximate perplexity for such models @xcite , ideally, a metric should not be tied to a model. ## evaluating diversity metrics we now describe our framework for evaluating diversity metrics. diversity has many facets: for in- diversity parameter d "how are you today?" c tester / g d (c) diversity metric m div (s c,d ) test score ρ(m div , d) "very good!" "fine thank you." "couldn't be better." figure 2: an overview of our diversity metrics evaluation framework. the tester (machine or human) generates a response set (s c,d ) given a diversity parameter (d) and a context (c). the test score of a metric mdiv is the correlation between the metric score for s c,d and d. to evaluate m div (•), we assume access to some deterministic diversity parameter d that controls an aspect of diversity in s c . we test the relation between m div and the parameter d. by varying d and measuring m div , we can compute the correlation ρ between m div and an aspect of diversity represented by d. because our goal is to have metrics that rank the diversity of generated texts, we use spearman's ρ rank correlation as our test score. figure 2 illustrates the flow of a test in our framework. in practice, to control the diversity level of s c using d, we use a tester: a generative model that takes a context c and a diversity parameter d as input, and outputs a response set s c,d . we stress that the tester can be either a neural model or a human. a good tester should reliably represent the diversity level quantified by d. as a hypothetical example, c can be a movie name and d represent sentiment diversity, that is, the number of different sentiments in a collection of reviews s c . a human tester can observe c and d, and produce reviews accordingly (such data can be easily mined from imdb). a collection of such (d, s c,d ) makes a test, in which the correlation between m div (s c,d ) and d measures the sensitivity of m div to sentiment diversity. we now describe two tests that instantiate this framework, roughly corresponding to the two main aspects of diversity: form diversity and content diversity. ## human diversity score one of the core questions we tackle is: can humans evaluate diversity reliably? although a few papers @xcite @xcite asked humans to evaluate diversity, to the best of our knowledge no work thoroughly investigated this question. the importance of this question is clear when comparing to quality evaluation. there, human judgment is the gold standard, and automatic quality metrics are established by showing high correlation with human score. thus, understanding if humans can judge diversity is important for improving diversity metrics. we use crowdsourcing workers foot_1 to compute a human diversity score: we show workers a context followed by a set of responses, and ask them to rate the diversity of the set. to establish best practices, we experiment with multiple variations of hds (detailed in §6.2), asking humans to rate the diversity of a response set, and evaluating each practice with our framework. we focus on the following questions: • should humans rate diversity of a set or similarity between pairs in the set, from which diversity can be inferred? (tl;dr: diversity) • can humans evaluate different aspects of diversity well? (tl;dr: not effectively) • should humans rate the absolute diversity score of a set of sentences or rank whether one set is more diverse than another? here, we did not reach a conclusive result, and describe this experiment in the appendix c. as a preliminary step, we conducted pilot experiments among a group of nlp graduate students. the main insights were: (a) humans are biased by quality: if a generated set has high diversity but low quality, humans will rate diversity low. to neutralize this, we explicitly ask workers to evaluate the quality of one of the responses in the set s c , and then instruct them to ignore quality in diversity questions; (b) to make sure a worker reads the context c, we ask them to generate a sentence s before they rate diversity; (c) it is difficult for workers to evaluate the diversity of a set with more than 10 responses. our crowdsourcing tasks are provided in appendix a. ## diversity to similarity reduction we expand the idea from @xcite and suggest a method to construct a diversity metric from any 2-sentence similarity metric. given m sim (s 1 , s 2 ) ∈ r, a symmetric similarity metric that gets a pair of input sentences (s 1 , s 2 ) and returns a similarity score, we can define a diversity metric mdiv as the negation of the mean similarity score across all (unordered) pairs of s c : this reduction allows us to easily define new diversity metrics based on past work on sentence similarity @xcite @xcite . in §6 we show that both n-gram-based similarity metrics and neural semantic similarity metrics provide useful diversity metrics. we apply our evaluation procedure on three different english nlg tasks that require diversity. contexts c are 3-words prompts, extracted from the cornell movie-dialogs corpus (danescu-niculescu-mizil and lee, 2011) by taking the first three words from each original context. the response sets s c are completions of the prompts, generated by our testers. this context provides minimal constraints, making this a "highentropy" generation task. samples of the contexts extracted for each task, along with generated response sets, are presented in appendix b. we intentionally avoid nlg tasks where diversity is not necessarily desired, such as summarization and machine translation. ## aspects of diversity in this work, we focused on the two primary aspects of diversity: content diversity (what to say?) and form diversity (how to say it?). in figure 1 , both sets are diverse, but set b is only form diverse, as all answers deliver the same massage, whereas set a is diverse in both form and content. furthermore, we can observe aspects of diversity as having a tree-like structure, where both content and form diversity can be divided to subaspects: content diversity (e.g. answering the question "how are you today?") can be expressed by using different sentiment ("i'm doing good." vs. "i'm so glad you asked! i'm really doing good."), different relevance ("i'm fine" vs. "did you watch the game last night?"), and more. form diversity can be divided into sub-aspects as well: syntactic diversity ("someone took it from me." vs. "it was taken from me.") or lexical diversity ("i feel fine." vs. "i feel very well."). even those sub-aspects can be further divided. for example, a sub-aspect of lexical diversity is register diversity ("how are you?" vs. "sup bro?"). another observation is that different aspects are not orthogonal, that is, changing one aspect may lead to changes in other aspects. specifically, we observe that while it is relatively easy to produce high form diversity with low content diversity (set b in figure 1 ), it is almost impossible to diversify content without changing form. this observation was important during the design of contest. ## conclusions this work presents a framework for evaluating diversity metrics as a step toward standardized evaluation. we limit the scope of this work to differ-ences between form and content diversity, which are key towards understanding different aspects of diversity. future work can explore other aspects of diversity, e.g. testing sentiment diversity, as proposed in §3. we urge researchers to use this framework as a platform for developing new diversity metrics and establishing their efficiency.