Semantic Space Grounded Weighted Decoding for Multi-Attribute Controllable Dialogue Generation (2023)

Abstract: Controlling chatbot utterance generation with multiple attributes such as personalities, emotions and dialogue acts is a practically useful but under-studied problem. We propose a novel framework called DASC that possesses strong controllability with a weighted decoding paradigm, while improving generation quality with the grounding in an attribute semantics space. Generation with multiple attributes is then intuitively implemented with an interpolation of multiple attribute embeddings, which results in substantial reduction in the model sizes. Experiments show that DASC can achieve high control accuracy in generation task with the simultaneous control of 3 aspects while also producing interesting and reasonably sensible responses, even in an out-of-distribution robustness test.

## introduction personalized dialogue systems are promising nlp applications for human-computer interaction and emotional companionship. we would expect such systems to have personalities, exhibit emotions, take dialogue acts and even adopt sophisticated strategies @xcite , which necessitates the research efforts on controllable text generation. despite recent progress in this field @xcite @xcite , they mainly tackle single-attribute control, overlooking the fact that human interaction can usually convey multiple attributes simultaneously. therefore, we explore a novel task of multi-attribute controllable dialogue generation, which can significantly ameliorate the expressiveness, human-likeness, and explainability of chat-bots. however, the numerous combinations of attributes can make the available data for each setting scarce, which poses a great challenge for this task. among previous works, weighted decoding methods has achieved great success in singleattribute control tasks @xcite . weighted decoding methods learn a tokenlevel attribute classifier, which predicts the probability of the text conveying the desired attribute given the generation of each token in the vocabulary. then the predicted probabilities are used to re-weigh the token generation during decoding to induce the attribute. despite success in singleattribute control, they have certain limitations when extended to the multi-attribute case by multiplying several attribute predictions from multiple classifiers. extra parameters proportional to the large vocabulary size |v | will be introduced, which can grow several times further due to the number of attributes. the consequent large number of parameters will not only make the model inefficient, but also harm the generation quality. the model can be prone to overfit since the data for each attribute combination are usually small, which increases the risk of degeneration @xcite . to overcome these limitations, we propose dialog attribute space controller (dasc). we establish an attribute semantic space where each token in the vocabulary is projected to the space through attribute token embedding shared across attributes. the language models' hidden states are also converted to attribute context embedding in the space through attribute-specific layers. the attribute space will be trained to make the tokens suitable to convey the desired attribute close to the current context embedding. we can then assign higher weights for the those tokens during decoding. we will show that dasc can inherit the strong controllability of weighted decoding, while also achieving a natural solution of multi-attribute control with the interpolation of multiple attribute embeddings in the space. moreover, the shared attribute token embedding also alleviates over-parameterization, and improves the robustness of the model. figure 1 : an example of multi-attribute controllable dialogue generation. the baseline system doesn't attempt any control and produced a dull response, while a previous method of attribute control generated a repetitive and illogical text. dasc successfully gives a response that is both fluent and correctly attributed. we experiment on an attribute-rich open-domain dialogue dataset @xcite for the simultaneous control of 3 attribute aspects: gender style (male, female, neutral), emotion (8 classes), and a simple division of dialogue act (question vs nonquestion). as exemplified in figure 1 , compared to previous methods, dasc achieves strong controllability while avoiding low-quality generations in the compositional controlling task. visualization of the attribute token embeddings (in figure 3 ) exhibits specific patterns that benefit the controlling, compared to the general lm token embeddings. we further conducted a robustness test in a outof-distribution setting and validated that dasc's controllability generalizes. our contributions are as follows: 1) we propose semantic space grounded weighted decoding for controllable dialogue generation, which can intuitively solve the multi-attribute control task with the interpolation of embeddings in the space; 2) dasc uses smaller number of parameters than other weighted decoding alternatives while achieving better performance with the design of shared attribute embeddings; 3) dasc can achieve high accuracy on the simultaneous control of 3 aspects while also preserving competitive generation quality in both conventional test settings and out-of-distribution robustness tests. ## method in this section, we will first define our task and weighted decoding method for controllable gener-ation as background. then we will introduce the proposed dasc framework. ## experiments in this section, we will conduct experiments to examine the following hypotheses: (1) dasc can achieve strong controllability while also preserving good generation quality in multi-attribute controllable generation; (2) dasc's performance benefits from the meaningful representations in the attribute semantic space, and reduction in parameters; (3) dasc can also be flexibly extended for other control tasks like the composition of multiple emotions or adopting certain strategies for emotional support. ## conclusion in this paper, we propose dasc, a novel framework for multi-attribute controllable dialogue generation. it is established on the weighted decoding paradigm for strong controllability and further grounds it in an attribute semantic space, which enables the simultaneous control of multiple attributes with the interpolation of multiple attribute embeddings. experiments show that dasc can achieve strong controllability for multi-attribute generation while also preserving high quality in out-of-distribution scenarios. dasc is highly efficient given its much fewer number of parameters than alternatives and llms, making it an promising choice for deployment.