Latent Variable Dialogue Models and their Diversity
Paper · 2017 · Kris Cao and Stephen Clark
Summary
A person can respond to the same remark in several reasonable ways. They might acknowledge it, ask a question, or pick up on a detail. An automatic reply system has to learn that range from examples, yet its most probable answer can be a short phrase that fits almost any conversation. Cao and Clark study this problem in open-domain dialogue systems. Their system, DIAL-LV, gives the reply generator a hidden vector in addition to the prompt. Varying that vector changes the conditions under which the whole reply is written. The generator then searches for a likely sentence under those conditions.
The hidden vector, called a latent variable, has a different job in training and in use. During training, the system reads both the prompt and the observed reply to infer a distribution over vectors that might help explain the reply. The training objective rewards successful prediction of the reply while keeping that inferred distribution close to a standard Gaussian. At generation time, there is only a prompt. The system draws a vector from the Gaussian and keeps it fixed as it writes the response. Drawing another vector gives the decoder a different starting state for the same prompt.
The authors train on OpenSubtitles and compare DIAL-LV with versions of a conventional encoder–decoder that use different ways of choosing a reply. On the main prompt set, unique replies account for 76% of DIAL-LV’s output, compared with 35% under ordinary maximum-likelihood decoding, 62% with a penalty on generally probable openings, and 78% under temperature-controlled word sampling. DIAL-LV has the lowest fitted Zipf parameter, the paper’s measure of vocabulary diversity, though its score of 1.39 is close to the maximum-likelihood baseline’s 1.43. In a separate human evaluation, DIAL-LV and the sampling baseline produce similar average numbers of acceptable replies. The counts for DIAL-LV vary less, suggesting more consistent acceptability in that test.
The authors also vary how far the hidden vector lies from the center of the Gaussian. Moving away from the center generally yields fewer repeated replies and sentences that the conventional encoder–decoder assigns lower probabilities. At the largest tested radius, the sentences remain varied by the unique-reply measure while the vocabulary measure deteriorates. The experiments show how sentence variety, word variety, and human acceptability can move independently. They motivate a question the paper leaves open: how to find replies that are less predictable while still working as conversational responses.
Deep dive: Latent Variable Dialogue Models and their Diversity
Cao and Clark test whether sampling a hidden vector can produce varied replies to the same dialogue prompt while keeping them coherent. · about 32 minutes to read
The problem and its context
A prompt can have several good continuations
In the one-shot task Cao and Clark study, the system receives an utterance and writes the next utterance. The input can give a strong indication of the topic without settling what the other speaker will say. An offer to look into something and follow up by email, for example, could elicit agreement, a request for a particular detail, or a suggestion about when to follow up. A corpus records whichever continuation happened on that occasion. The generation task asks for a plausible continuation given the information in the prompt, with room for several kinds of reply.
Some of that variation comes from differences between speakers. The authors discuss earlier work that learned representations of personas so that a reply could depend on who was speaking. Questions about a speaker’s identity or background make the motivation particularly clear. The paper points to another source of variation within a speaker’s own behavior. A person could answer the same question in different ways on different occasions, even when the facts about that person stay fixed. A representation of the speaker addresses part of the uncertainty and leaves the choice of how to respond on this occasion open.
The authors place their work in a period when neural sequence-to-sequence systems were a common approach to text generation for open-domain conversation. An encoder reads the source utterance into a vector. A decoder predicts the response from that vector, using the words already written to help predict the next one. The architecture gives the generator a way to use both the input and the developing sentence. Because the encoder assigns a fixed representation to a given input, the decoder’s probability distribution must accommodate the different replies that could follow from that same representation.
This is easiest to understand by separating the probability calculation from the decision about what to say. The system learns to score candidate replies. At generation time, a decoding procedure uses those scores to find an output. A deterministic procedure can keep returning the same reply even if the probability distribution assigns substantial weight to other continuations. The diversity visible in a set of generated sentences therefore depends on how the system is used as well as on what it learned from its training examples.
Why the safest answer can dominate
The paper describes earlier encoder–decoders that learned by minimizing the negative log-likelihood of recorded replies. That objective penalizes the system for assigning low probabilities to the responses it observes. A common way to use such a system was to search for a reply with high conditional probability given the input. Beam search makes that search manageable by retaining a limited set of partial sentences as generation proceeds. Each partial sentence can be extended, and the search keeps the higher-scoring continuations. A wider beam gives the procedure more room to explore competing prefixes under the same scoring rule.
The scoring rule makes generic replies competitive. A brief expression of uncertainty occurs naturally in many settings, so the system can learn to give it a good score across inputs with very different meanings. A response that engages with the particular subject has to choose more specific words and may compete with several other similarly appropriate responses. Those alternatives divide the probability assigned to specific continuations. Under a rule that rewards the probability of an individual sentence, a widely applicable phrase can rise above all of them. The output can be grammatical and still give the impression that little of the prompt mattered.
The authors also point to the tendency for shorter replies to have higher likelihoods. A complete reply receives its probability through a sequence of conditional word choices. Extending the reply introduces further choices, each of which contributes a factor to the probability. The tendency towards short responses can become more visible when the search has a wider beam. Better exploration under the same objective can make it easier to find the short phrases the generator already favors. Improving the search and improving the objective address different parts of the problem.
Earlier work on a diversity-promoting objective for neural conversation changed the way complete replies were ranked. Cao and Clark describe its use of maximum mutual information and a length boost. The intuition behind the language-model penalty they later use as a baseline is that some word sequences are predictable even before the prompt is known. Penalizing that general predictability can give an input-specific response a better chance. This intervention acts at the point where a trained generator chooses among its possible outputs.
Another option is to sample words from the decoder. The same prompt can then produce a different sequence on another run. Each sampled word becomes part of the context for the remaining choices. This creates opportunities to reach a coherent reply that maximum-likelihood decoding would overlook. It also creates opportunities for an unfortunate choice early in the sentence to leave the decoder continuing a difficult or incoherent prefix. A sampler can vary the answer without imposing a decision about the answer as a whole before any words are written.
A random choice that lasts for the whole reply
Cao and Clark connect their approach to earlier work on hierarchical dialogue generation with latent variables. The shared idea is to draw a latent variable and condition the reply on the draw. A latent variable is part of the probability specification even though the dataset supplies no observation of its value. The authors apply the idea to a single response. Their question is what variation the resulting system expresses in words and sentences, and how acceptable those sentences are to human readers.
The location of randomness matters here. With word sampling, uncertainty enters each time the decoder picks a word. With a latent draw and deterministic decoding, a random choice is made before the sentence begins. The decoder can take account of the resulting state while scoring all continuations. This gives it a way to agree with its own earlier choices over the span of a response. It creates the possibility of variation in a reply’s general direction, although the vector has no prescribed interpretation such as topic, speech act, or intended level of detail.
The distinction motivates the evaluation. A system can use different sentences built from a narrow stock of words. Another system can introduce uncommon words while producing responses that people find hard to follow. Exact repetition, vocabulary use, and appropriateness capture different features of generated output. Cao and Clark measure each of them and use the familiar maximum-likelihood decoder to ask where the various procedures place their responses in its probability distribution.
The method, step by step
From a prompt to a distribution over replies
Consider a prompt that announces an urgent problem. A reply might show alarm, ask what can be done, or propose an action. In DIAL-LV, the prompt always supplies the same encoded representation when its wording is fixed. An extra vector changes from one run to another. The decoder sees both pieces of information when it starts, so its preferred continuation can change even though the prompt stays the same. The vector is continuous: the authors draw its coordinates from a probability distribution over real values.
The proposal starts with a standard Gaussian prior for that vector. A prior is the distribution available before seeing the reply. In this design it is also independent of the prompt.
P(z) = 𝒩(0, Iₙ)
Here P(z) is the prior density of the latent vector z. The symbol 𝒩 denotes a Gaussian distribution, 0 denotes its zero mean vector, and Iₙ is the identity covariance matrix for a vector with n coordinates. Each coordinate has standard Gaussian scale, and the prior specifies no covariance between distinct coordinates. The dialogue input will enter separately when the decoder evaluates a reply.
The paper defines the overall conditional probability of a reply by integrating across possible latent vectors.
P(Y | X) = ∫ P(Y | z, X) P(z) dz
Here X is the input utterance and Y is the response. P(Y | X) is the probability of that response given the input. The vertical bar means that the variables after it are supplied as conditioning information. P(Y | z, X) is the decoder’s probability of Y when given both z and X. P(z) is the prior density, and the integral with dz ranges over the continuous latent space. Each possible vector contributes the probability it gives the response, weighted by its density under the prior.
The integral describes what the system assigns to a reply after accounting for every possible vector. The generation procedure uses a draw and a conditional search. Once it has drawn a vector, it tries to find a high-probability response for that particular combination of input and vector. If a reply scores well across many parts of the latent space, it may have a high probability in the integral. A reply supported more strongly by a particular draw may win the corresponding conditional search even if its overall probability is lower. That distinction gives the generator a route out of the most common replies.
The encoder–decoder supplies the mechanics for turning this construction into sentences. During training the authors can inspect the response as well as the prompt. During generation the prior supplies the vector in place of an inference based on the response. The prompt encoder and the decoder take part in both stages.
How DIAL-LV learns from replies and generates responses
The steps in order.
Inferring a vector from a training example
The probability specification has an associated posterior, the distribution of the latent vector after observing the prompt and reply. An exact calculation would have to determine which vectors explain the recorded response and normalize the result across the latent space. The paper uses a variational autoencoder approach. It introduces a learned distribution that can approximate this posterior and that can also be sampled conveniently. The approximation is specific to the example: it can assign different centers and spreads to different replies even when the input is the same.
The prompt and reply go through separate bidirectional recurrent neural networks. Each network reads a sequence of word embeddings, which represent words as vectors. The recurrent calculation passes a state from one position to the next. Reading in both directions gives each encoder terminal states summarizing the sequence from opposite ends. The authors concatenate those terminal states and apply a nonlinear layer. The resulting prompt and reply representations are called hₓ and hᵧ.
The recurrent cell is a gated recurrent unit, or GRU, from the encoder–decoder work of Cho and colleagues. The gates regulate how the state is updated as the network processes the sequence. Cao and Clark describe the GRU as a choice that balances expressive capacity with computational cost. A GRU also serves as the recurrent decoder. Though the input and response encoders use the same kind of cell, they are separate networks, and only the prompt’s encoding is available when the system has to compose a new reply.
The inferred distribution is a Gaussian. Its covariance matrix is diagonal, so the network predicts a variance for each coordinate while leaving the off-diagonal covariances at zero. It calculates the mean from the joined prompt and response vectors.
μ = Wµ [hₓ hᵧ] + bµ
Here μ is the vector of means in the approximate posterior. The notation [hₓ hᵧ] means that the prompt representation hₓ and the reply representation hᵧ are concatenated. Wµ is a learned weight matrix that maps the concatenation into the space of posterior means, and bµ is a learned bias vector. The subscript µ identifies the parameters for the mean calculation.
A separate transformation predicts the logarithms of the variances.
log(Σ) = diag(WΣ [hₓ hᵧ] + bΣ)
Here Σ is the diagonal covariance matrix. The notation log(Σ) describes the diagonal entries in log-variance form. The function diag places the values from its input vector on the diagonal. WΣ and bΣ are the learned weight matrix and bias vector for this calculation, and [hₓ hᵧ] is the concatenation of the prompt and reply representations. Working with logarithms lets the network output unrestricted real values while retaining positive variances when those values are exponentiated.
The two transformations give the training procedure a way to place probability mass around vectors useful for predicting each observed reply. The mean determines where the distribution is centered. The variances determine how much the sampled coordinates fluctuate around that center. These quantities are inferred from text. There is no target vector in the data to match, and there is no instruction that any particular coordinate should represent a particular kind of conversational difference.
The authors take a single sample from the inferred Gaussian for a training example. They use the reparameterization trick, which expresses the draw as standard Gaussian noise transformed by the predicted mean and scale. In effect, the random draw supplies a noise vector and the inference network determines how to shift it and stretch it. Written this way, the training procedure can calculate how a change to the inferred mean or spread affects the reconstruction of the reply while holding the draw of the underlying noise fixed for that calculation.
Giving the decoder two kinds of information
The sample z is concatenated with the prompt representation hₓ. That combined vector initializes the decoder GRU’s hidden state. The response encoder’s representation is used to infer z, so any information it contributes to this starting state passes through the latent draw. The prompt has a direct route to the decoder as well. The decoder can therefore use one source of information that is present for every reply to the input and another that can vary between replies.
The training decoder assigns probabilities to the words of the recorded response. Its reconstruction objective favors settings that make this response likely under the sampled vector and prompt. Here reconstruction means predicting the particular observed reply that was used for inference. It gives the latent variable a reason to be informative: a useful vector can improve the system’s prediction of which words followed this prompt on the observed occasion.
There is a practical constraint on how the system can exploit that information. At generation time, the unseen response cannot supply an inferred distribution. The only latent draws available then come from the standard Gaussian. If training freely placed useful response vectors in regions rarely reached by that Gaussian, the decoder might learn to predict well from inferred training samples and receive unfamiliar states when generating. The variational training objective addresses this gap by pulling the approximate posterior towards the prior.
What the objective rewards
The paper gives an evidence lower bound, or ELBO, for the conditional log-likelihood. It is a quantity the authors can optimize in place of directly calculating the log of the integrated response probability.
log P(Y | X) ≥ −KL(Q(z | X, Y) ‖ P(z)) + E[z ∼ Q] log P(Y | z, X)
Here log P(Y | X) is the conditional log-likelihood of response Y for prompt X. The sign ≥ means the expression on the right is a lower bound. Q(z | X, Y) is the approximate posterior over z for the observed example, and P(z) is the prior. KL is the Kullback–Leibler divergence, which measures a discrepancy between probability distributions, with ‖ separating the distributions in the order used by the divergence. The minus sign makes increasing that discrepancy reduce the objective. E[z ∼ Q] denotes the expectation over draws of z from Q, and log P(Y | z, X) is the log-probability of the observed reply conditional on the draw and the prompt. The plus sign combines the reconstruction reward with the negative divergence term.
The reconstruction term favors assigning high probability to the words the other speaker actually used. The divergence term favors keeping the inferred Gaussian compatible with the sampling distribution available in use. The authors’ training procedure uses one draw to estimate the reconstruction contribution. The negative conditional log-likelihood used for the decoder is the loss corresponding to the log-probability reward in the bound.
A predictable difficulty arises if the reconstruction can succeed using the prompt and the decoder’s own access to preceding words. A powerful recurrent decoder can learn to do much of the predictive work directly. The divergence term then gives the inference network a straightforward way to improve the objective: move its distribution close to the prior for every training pair. When the divergence goes to 0, the approximate posterior supplies no example-specific departure from the prior. The architecture still contains z, but the response can become effectively insensitive to its value.
The authors encountered this difficulty and draw on work on generating sentences from a continuous space to address it. They anneal the divergence term, gradually increasing its weight during training. Early on, the network has more freedom to use z to improve its prediction of the reply. The penalty grows as training continues, increasing the incentive to keep the inferred vectors compatible with the prior. The procedure gives the latent route an opportunity to become useful before the full pressure to match the prior takes effect.
They also apply word dropout to the decoder’s input, setting the dropout rate to zero.5. During training, dropout removes some of the information normally supplied by preceding words, giving the decoder a reason to draw on the starting state. The authors also use decoder word dropout at 0.5 for the conventional encoder–decoder, where they describe it as a measure against overfitting. Its presence in both systems matters when reading the comparisons, since the latent system is being compared with an encoder–decoder that also received this form of regularization.
Training choices and generation
The authors train on OpenSubtitles. They draw a random sample of 100K files, remove duplicate files to leave approximately 95K, and cap sentence length at 50. They describe the resulting corpus as around 731M tokens. The vocabulary consists of words occurring at least 1,000 times across the corpus, yielding roughly 30K words. The authors approximate the full softmax using a two-level hierarchy whose word clusters are formed by random assignment. The softmax supplies probabilities over possible next words, and the hierarchy is a way to reduce the work of computing those probabilities during training.
The implementation uses Keras on Theano. Training runs for 3 epochs using Adadelta with its default optimizer settings. The supplement gives 512 as the word-embedding and encoder hidden-state size, 64 as the dimensionality of the latent vector, and 574 as the decoder hidden-state size for both DIAL-LV and the conventional encoder–decoder. The authors say the shared decoder size is intended to make their capacities comparable. They use tanh nonlinearities and report that an epoch takes roughly 4 days on a Titan Black.
Generation begins by encoding the input utterance and drawing a latent vector from the standard Gaussian. The decoder gets the combined representation and searches for a likely sentence given that state. Holding the vector fixed makes the choice deterministic for a fixed prompt and draw under the described decoding procedure. A fresh draw can make another sequence preferable. The random choice consequently operates at the level of the decoder’s initial conditions, and the decoder still evaluates words in the context of the sentence it is constructing.
The paper uses the conventional encoder–decoder to build a comparison in which the randomness comes from drawing words. Direct sampling proved difficult to use because the resulting output could be incoherent. The authors sharpen the word distribution with a temperature transformation before sampling.
pᵥ ↦ pᵥ^(1/τ)
Here pᵥ is the decoder probability of a particular vocabulary word v before the transformation. The arrow ↦ means that this probability is replaced by an unnormalized weight. The exponent is the reciprocal of the positive temperature τ. The resulting weights are normalized over possible words to produce a sampling distribution. With the temperature at 1 the transformation leaves the relative weights alone. A temperature below 1 gives more relative weight to words the decoder already favors. The comparison uses τ = 0.35, which the authors judged a workable balance between randomness and coherence.
The transformation affects every word choice in the sampling baseline. When a word is drawn, it enters the decoder’s history and helps determine the distribution for the next word. DIAL-LV can also generate several replies for one prompt, but the change begins with the latent draw before the first word. In both cases the decoder supplies conditional word probabilities. The difference lies in which probabilities are used to make a deterministic decision and where the procedure draws from a distribution.
Experiments and results
The prompts and the comparisons
The evaluation uses subtitle utterances outside the training files and questions drawn from a list of conversation starters. The paper describes 150 subtitle lines chosen because they make sense in isolation and 50 conversation-starter questions. The human evaluation refers to a pool of 200 prompts. The first description of the pool also calls it a list of 50 prompts, which conflicts with its own breakdown and with the later account. The clearly specified human-evaluation subset consists of 50 prompts randomly selected from the pool. The main statistics describe the output from the evaluation prompts as a group, with no separate results for the subtitle lines and conversation starters.
The two sources give the authors inputs with different conversational shapes. A subtitle line can present a piece of a situation without explicitly asking anything. A conversation starter typically invites a response on a topic. Choosing lines that make sense independently fits the one-shot setup, since the generator receives the current utterance. A reply still has to infer what kind of continuation might be appropriate from whatever the chosen line conveys on its own.
DIAL-LV is compared with the following generation procedures:
- DIAL-MLE applies conventional maximum-likelihood decoding to the encoder–decoder. It provides the reference for what happens when the generator searches for a highly probable reply under its ordinary scoring rule.
- DIAL-MMI uses the same encoder–decoder with the anti-language-model objective described by Li and colleagues. The authors use a penalty weight of 0.45 on the first 6 words, with no length normalization.
- DIAL-SAMP draws words from the encoder–decoder’s sharpened distribution at a temperature of 0.35. It provides a stochastic comparison in which word selection is the source of randomness.
The paper specifies a beam width of 2 for the DIAL-MLE and DIAL-MMI comparisons. This means that the search retains a limited set of candidates while trying to maximize each respective objective. The comparison between those baselines chiefly concerns the decoding score. DIAL-SAMP changes how words are selected, and DIAL-LV changes the architecture and where the random choice enters.
A qualitative display also gives 3 random responses for each of 3 randomly chosen prompts, comparing DIAL-LV with unsharpened word sampling at τ = 1.0. For example, a prompt about an infection spreading elicits a reply about someone having died from the latent system. A separate prompt offers to look into a matter and follow up by email, and one sampled output changes direction into an incongruous use of the word hotel. The display illustrates the problems that motivated the temperature adjustment. The quantitative comparison uses the sharpened sampler, which gives a more demanding test of the latent approach.
Measuring words, sentences, and probability
The authors distinguish vocabulary diversity from sentence diversity. Earlier work used the type–token ratio, the number of distinct word types relative to the number of word occurrences. That measure is sensitive to how much text is generated. Common words recur frequently, and adding more text changes the balance between repeated words and newly observed ones. Generators that favor different reply lengths can consequently receive different ratios even when the ratios provide a poor basis for comparing their word use.
The paper instead fits a distribution inspired by Zipf’s law to the generated replies. The fit describes how word frequency falls as one moves from frequent to less frequent words. A smaller fitted parameter is interpreted as greater lexical diversity: the distribution is less concentrated at the top of the ranking. This is a property of a body of generated text. It gives an aggregate picture of vocabulary use and leaves open whether a particular unusual word was appropriate in the sentence that contained it.
Fitted Zipf parameter for generated replies on the evaluation prompt set
DIAL-LV has the lowest fitted parameter, with DIAL-MLE close behind.
The numbers
| System or setting | Zipf parameter |
|---|---|
| DIAL-MMI | 1.60 |
| DIAL-SAMP | 1.53 |
| DIAL-MLE | 1.43 |
| DIAL-LV (this paper) | 1.39 |
On the main evaluation prompt set, DIAL-LV’s fitted parameter is 1.39. DIAL-MLE scores 1.43, DIAL-SAMP scores 1.53, and DIAL-MMI scores 1.60. The authors emphasize the closeness of the latent and maximum-likelihood systems on this measure. The stronger distinction between them appears when whole replies are counted. Under the fitted lexical measure, the latent system also does better than the direct sampler at the temperature used for the main comparison.
For whole responses, the paper counts the percentage of unique replies. The measure treats an exact repeat as a repeat and a different string as a distinct reply. It is a deliberately coarse way to detect whether the system keeps falling back on the same output. Replies with different wording can still perform the same conversational function. Conversely, a few familiar words can be arranged into a large set of genuinely distinct responses. The vocabulary and sentence measures give different views of these possibilities.
Percentage of unique generated replies on the evaluation prompt set
DIAL-LV produces substantially fewer repeated replies than maximum-likelihood decoding and comes close to word sampling.
The numbers
| System or setting | Unique replies % |
|---|---|
| DIAL-MLE | 35 |
| DIAL-MMI | 62 |
| DIAL-SAMP | 78 |
| DIAL-LV (this paper) | 76 |
Unique replies account for 76% of the latent system’s output in the main evaluation, 35% for DIAL-MLE, 62% for DIAL-MMI, and 78% for DIAL-SAMP. The contrast with DIAL-MLE shows up even though their vocabulary fits are close. The same experiment places the latent system near the word sampler in sentence diversity, with the sampler slightly ahead on exact uniqueness for this prompt set. The ordering is different for the Zipf parameter. It is possible to repeat relatively few sentences while using a vocabulary distribution that is more heavily concentrated among frequent words.
The conventional encoder–decoder also scores the generated replies from each system. The paper reports these scores as negative log-likelihood, abbreviated NLL. Smaller NLL means the conventional encoder–decoder assigns the reply higher probability for its input. The comparison uses the same scorer across generation procedures. The NLL for DIAL-LV’s output therefore refers to the probability assigned by the conventional system, not to the value of the variational training objective or to a likelihood computed by integrating DIAL-LV’s latent space.
In the main comparison, the conventional scorer assigns NLL of 12.15 to DIAL-MLE’s output, 15.12 to DIAL-MMI’s, 15.54 to DIAL-LV’s, and 16.66 to DIAL-SAMP’s. DIAL-MLE explicitly searches for a reply that scores well by that system’s probability calculation. The other procedures tend to return sentences the scorer considers less probable. The result locates their output relative to the conventional response distribution. Assessing how well those replies work in conversation requires information beyond that ranking.
What people judged acceptable
The human evaluation puts the latent system and the temperature-controlled sampler side by side. The authors randomly select 50 prompts from the pool described as having 200. Each system generates 5 random replies for each selected prompt. Annotators count how many replies are appropriate, taking grammaticality, coherence, and relevance into account. The paper reports using 50 annotators in total, with 25 assigned to each system. The outcome is a count of acceptable replies for the prompt under the stated criteria, rather than a ranking of individual sentences by preference.
The reported mean count for DIAL-LV is 1.183, with a standard deviation of 0.402. The corresponding mean for DIAL-SAMP is 1.196, with a standard deviation of 0.577. The averages are close, with the sampling baseline slightly higher on that statistic. The smaller spread for DIAL-LV is the basis for the authors’ claim about consistency. Counts of acceptable responses fluctuated less in the reported evaluation of latent generation. The distinction matters because an improvement in the stability of a count and an increase in its average are different outcomes.
The paper also scores the output from this evaluation automatically. On the human-evaluation subset, DIAL-LV has NLL of 15.51 under the conventional encoder–decoder, a Zipf parameter of 1.32, and 76.4% unique replies. DIAL-SAMP has NLL of 16.91, a Zipf parameter of 1.56, and 73.6% unique replies. Here the latent system has more distinct strings as well as the lower fitted vocabulary parameter. The unique-reply ordering between the two systems differs from that of the main evaluation, where the sampler has the higher percentage.
These observations support a qualified account of the gain. In this human-evaluation run, the latent system sustains greater diversity on both automatic measures while producing a similar mean count of acceptable replies. It also occupies a region that is more probable according to the reference encoder–decoder than the region reached by word sampling. Probability under that scorer and average acceptability happen to tell different stories about these sets of replies. The annotators’ combined judgment gives a means of checking whether the extra diversity comes with an obvious decline in usable output.
There is a further distinction between these measurements that matters for interpretation. The diversity statistics concern the generated sets, and the human result concerns how many outputs in the sets were accepted. The paper reports no separate diversity score calculated only over the accepted responses. The findings show that the output can be more varied overall while the number of acceptable replies remains similar. They provide less detail about which kinds of variation occurred specifically among the replies the annotators approved.
What the ablations show
The paper uses controlled decoding comparisons and a latent-radius intervention; it gives no component-by-component ablation of the training recipe.
Changing the decoder’s choices
The DIAL-MLE and DIAL-MMI comparison changes the rule that scores replies while using the same underlying conventional encoder–decoder. Penalizing an opening that is easy to predict without the input raises exact sentence uniqueness on the main prompt set and shifts the output towards higher NLL under the conventional scorer. The lexical fit moves in the other direction. The comparison shows that an intervention can sharply change how often complete responses recur while leaving the output more concentrated in the vocabulary measure. It also gives the latent system a meaningful comparison with a generator designed to address generic replies through its scoring objective.
DIAL-SAMP again uses the conventional encoder–decoder and introduces randomness into selection. It obtains the highest unique-reply percentage in the main comparison. The authors suggest that its lexical score can be understood in terms of local decisions. The sharpened distribution puts considerable weight on words that already look plausible at the current position. Sampling from those distributions can produce many different combinations while continuing to favor a relatively familiar stock of words. The explanation is tentative. The authors raise the possibility of sampling while maintaining a beam of hypotheses, but the reported experiments give no comparison of that procedure with the sampler they evaluated.
A direct comparison between DIAL-LV and DIAL-MLE changes the availability of a latent vector, the training objective, and the generation procedure. It measures what the resulting system does when those changes are put together. Matching the decoder hidden-state size gives the systems comparable capacity on that dimension. Word dropout appears in both training procedures. The difference in sentence repetition is evidence about the full latent approach under this design. The experiment leaves open the individual contributions of the inference network, divergence annealing, dropout, and decoding.
Holding the radius fixed and varying the direction
The radius experiment keeps the trained DIAL-LV system in place and intervenes on the vector it is given. A radius is the distance from the origin of latent space. A shell at a fixed radius contains vectors of that length pointing in different directions. The authors draw from the standard Gaussian and rescale the samples to the chosen radius. This preserves the randomly drawn direction while imposing a common distance from the center. They take 5 samples per prompt at each radius in the evaluation.
The tested radii are 0, 4, 8, 12, and 16. At radius 0, all directions lead to the same latent vector. A fixed input then has a fixed generation state, so the procedure is deterministic even across repeated draws. The decoder still receives an input representation, and distinct prompts can produce distinct replies. The measured uniqueness at radius 0 reflects the outputs across the set of prompts, with the same latent vector used whenever a response is generated.
Unique replies on the evaluation prompt set by DIAL-LV latent radius
Uniqueness rises away from the center and levels off near the outer tested shells.
The numbers
| System or setting | Unique replies % |
|---|---|
| Radius 0 | 7 |
| Radius 4 | 42.1 |
| Radius 8 | 63.1 |
| Radius 12 (this paper) | 67.7 |
| Radius 16 | 67.1 |
At radius 0, unique replies account for 7% of output. At radius 4, the percentage is 42.1, and at radius 8 it is 63.1. The observed high point is 67.7% at radius 12, followed by 67.1% at radius 16. Moving away from the origin creates an opportunity for directional differences in z to affect the sentence. The increase in uniqueness is direct evidence that the trained decoder responds to variation in that vector. The leveling off in the outer shells also shows that greater distance eventually gives little additional variety by this particular measure.
The radius experiment helps interpret the main comparisons because it preserves the learned weights and the response-generation procedure. Giving this particular trained decoder the zero vector is a probe of how it behaves when all variation from its latent draw is removed at inference. It retains the prompt encoding, and its training still incorporated the latent inference procedure. Its behavior at the origin is therefore an observation about this trained generator. The separate DIAL-MLE baseline answers the broader comparison with a conventional encoder–decoder trained for its own task.
How lexical diversity and probability move
The conventional encoder–decoder assigns steadily higher NLL to shell outputs as radius increases. For radius 0 the NLL is 13.12, followed by 14.02 at radius 4, 15.72 at radius 8, 17.65 at radius 12, and 18.16 at radius 16. Those numbers describe the generated responses under the conventional reference scorer. The intervention changes where in latent space DIAL-LV draws its initial state, and the reference scorer supplies evidence about how predictable the resulting sentences are.
The prior gives the center a special role because a standard Gaussian has its highest point density there. In a space with many dimensions, point density and the probability of falling near a particular radius are different quantities. Shells at some distance from the center have room for many directions. Radius 0 is a useful control because it removes variation in the input to the decoder from z, while ordinary sampling from the prior generally supplies a non-zero vector. Fixing radii allows the authors to compare generation across distances without assuming that ordinary draws would represent those distances equally often.
The fitted Zipf parameters have a different pattern. They are 1.49 at radius 0, 1.62 at radius 4, 1.59 at radius 8, 1.56 at radius 12, and 1.78 at radius 16. The outermost shell gives the highest NLL and the weakest lexical diversity on this measure while still producing many distinct replies. The authors suggest that its generator uses a limited vocabulary in many different combinations. That reading is consistent with the two diversity measures: whole sequences can change considerably when a relatively narrow set of words is rearranged.
The paper uses the shell results and baseline comparisons to motivate a tentative account of reply probability. Ordinary likelihood decoding favors outputs near the most predictable choices under the conventional encoder–decoder. Changing the objective, sampling words, and drawing latent vectors all yield responses that the conventional system often regards as less probable. Some movement toward lower probability can reduce the dominance of generic replies. Going sufficiently far may produce incoherent output, as the examples of unsharpened sampling illustrate. The authors suggest looking for a region where the output is varied enough to be engaging and probable enough to be coherent.
That region remains a hypothesis about how the measurements relate. The radius results show a regular change in reference NLL, while exact uniqueness and the lexical fit respond differently. The people who evaluated DIAL-LV and DIAL-SAMP give evidence about those generation procedures under the conditions of their test. A human evaluation across the shells would be needed to determine whether particular radii are associated with a better balance of coherence, relevance, and variety.
Limitations
Limits the authors recognize
The authors present the relationship among probability, interestingness, and grammaticality as preliminary. The conventional encoder–decoder can put a high probability on an uninformative reply. Lower probability can make room for more specific or less predictable answers, while the sampling examples show how incoherence can appear when a procedure allows very unlikely continuations. The paper relates this finding to earlier work on automatic dialogue evaluation. A likelihood-based measure such as perplexity evaluates predictive probabilities and supplies limited information about whether a generated reply makes for good conversation.
The authors also point out that the latent system can be combined with a mutual-information objective or temperature-based sampling. These combinations would change the decoding procedure after the vector had been drawn. They leave those combinations out of the comparative experiments so they can investigate the latent system’s contribution. The discussion mentions possible further diversity from combining the approaches, with no reported controlled comparison that measures the gain or its effect on acceptability.
The architectural motivation leaves a training difficulty of its own. A powerful decoder can ignore the latent variable, which is why the authors use annealing and word dropout. Their results show that the trained decoder changes its output as the latent input varies. The paper supplies no separate runs that establish which of the training measures matters more or how the effect depends on the schedule. Its analysis centers on the behavior of the resulting generator.
Limits of the evaluation design
The input is a single utterance selected to stand on its own. This supports a focused test of immediate response generation. Questions about following a long exchange, maintaining shared references, or preserving a consistent speaker identity remain outside the experiment. The earlier work on personas establishes the motivation for distinguishing speakers, but the authors’ latent draws have no supervised assignment to speakers or their attributes. The dialogue examples are also separate generated replies, so there is no test of what happens after another person reacts to them.
The prompt sources matter as well. Subtitle utterances provide lines from scripted exchanges, and conversation starters provide questions chosen to invite an answer. The reported comparisons pool across prompt types. They leave open whether the latent system’s gain in uniqueness is concentrated in particular inputs, and whether some categories benefit more from sampling words or penalizing generic openings. The inconsistency in the paper’s first description of the prompt count makes the account of the pool less precise than the later description of the human subset.
The automatic diversity measures provide little evidence about distinctions in meaning between replies. Exact uniqueness can increase with changes in word order, small wording changes, or extra material. The Zipf parameter summarizes the frequency distribution of words without distinguishing an apt specific term from an unexpected but irrelevant one. Neither measurement identifies whether several responses realize genuinely different conversational intentions. The radius intervention establishes that z can affect the output, with the functions of individual coordinates and directions remaining undetermined.
The human evaluation covers the latent system and the sharpened sampler. It leaves the maximum-likelihood and mutual-information baselines without corresponding acceptability counts from that experiment. The combined judgment also leaves grammaticality, coherence, and relevance without separate reported scores. Similar average counts could arise from similar behavior on all three criteria or from different patterns of strengths and weaknesses. The reported standard deviations describe consistency under the evaluation, and the paper gives no significance test or uncertainty interval for their difference.
The score called NLL is tied to a particular conventional encoder–decoder trained for this study. It provides a common reference for locating output under that generator’s conditional probabilities. The score alone cannot establish that the output is an unlikely human response or that people find it interesting. Likewise, the high uniqueness at some radii provides no direct estimate of perceived appropriateness for those shells. The most specific result the evaluation supports is that this latent generator broadens its output while retaining a similar average acceptable-reply count to the sharpened sampler on the selected prompts.
What came after
Choosing a strategy before choosing words
Later work on negotiation dialogue cites Cao and Clark in a setting where the purpose of separating response decisions from wording is particularly visible. The title of Decoupling Strategy and Generation in Negotiation Dialogues identifies the separation it studies: the choice of strategy and the generation of the language that expresses it. In a negotiation, several fluent replies can pursue different objectives, and several phrasings can express a similar move. The distinction connects to Cao and Clark’s decision to give the decoder a sentence-level input that can vary even when the words of the prompt stay fixed. In Cao and Clark’s study, that input is an unlabeled Gaussian vector. The connection is at the level of the generation decision, with no basis for identifying its coordinates with negotiation strategies.
Latent choices as actions
Rethinking Action Spaces for Reinforcement Learning in End-to-end Dialog Agents takes up latent variables in the context of reinforcement learning. Its stated subject is the action space of a dialogue agent, meaning the set of choices available to it as it learns how to act. Cao and Clark use the latent space to draw different conditions for producing a sentence. The later title places the corresponding level of choice in a decision problem: the representation of a potential reply affects what the learning procedure can choose and optimize. This extends the question from how to generate alternatives for a fixed prompt to what form a reply decision can take inside an agent.
Similarity between sentences
Leveraging Sentence Similarity for Natural Language Generation cites the paper in work concerned with using similarity between sentences in generation. That focus connects to a distinction visible in Cao and Clark’s evaluation. Their unique-reply percentage recognizes exact repeats, while their vocabulary statistic describes how words are distributed across outputs. Sentence similarity concerns a different relationship, since replies can resemble one another even when their wording differs. The citation establishes a connection to this later line of work. Whether that work adopts the Gaussian prior, conditional search, or any other specific part of DIAL-LV remains unspecified.
Cite
Cite as Kris Cao and Stephen Clark. 2017. Latent Variable Dialogue Models and their Diversity. Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers.
@inproceedings{cao2017latent,
title = {{Latent Variable Dialogue Models and their Diversity}},
author = {Kris Cao and Stephen Clark},
booktitle = {Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 2, Short Papers},
year = {2017},
url = {https://aclanthology.org/E17-2029/}
}This page in Markdown https://md.research.elamur.ai/free/en/papers/cao-2017-latent-variable-dialogue-models-their/