Classification-Aware Neural Topic Model Combined with Interpretable Analysis - for Conflict Classification (2023)

Abstract: A large number of conflict events are affecting the world all the time. In order to analyse such conflict events effectively, this paper presents a Classification-Aware Neural Topic Model (CANTM-IA) for Conflict Information Classification and Topic Discovery. The model provides a reliable interpretation of classification results and discovered topics by introducing interpretability analysis. At the same time, interpretation is introduced into the model architecture to improve the classification performance of the model and to allow interpretation to focus further on the details of the data. Finally, the model architecture is optimised to reduce the complexity of the model.

## introduction hundreds of conflicts break out every day around the world, many of which have a major impact on the world's political and economic situation. a recent example is ukraine crisis, which has caused energy scarcity in europe, a reduction in world food production and many other repercussions. for governments and institutions such as the ifpri, the impact of conflict events can be greatly reduced if they are classified, analysed and responded to in the shortest possible time. our goal is to develop a deep learning model suitable for the classification of conflict information. this model should be able to classify conflict categories and discover category-related topics. most importantly, the model must have high reliability as the consequences of conflicting information are often very serious. we therefore want to combine text classification, topic modelling and interpretable analysis to solve the problem. text classification assigns category labels to different texts for the purpose of distinguishing textual information. recurrent neural networks (rnns), convolutional neural networks (cnns) and graph neural networks (gnns) have all been applied to text classification tasks @xcite @xcite @xcite @xcite . more recently, @xcite provides a fine-tuned bert-based pre-training model @xcite ) for text classification tasks generic solution with new state-of-the-art results on eight extensively studied text classification datasets. the topic model is designed to automatically find a range of topics and topic words from a collection of documents. one of the most classic topic models is latent dirichlet allocation (lda) @xcite , which is an unsupervised, nonhierarchical model. many subsequent research has been based on lda, such as the hierarchical latent dirichlet allocation (hlda) proposed by @xcite . in 2016, @xcite proposed a generative neural variational document model (nvdm), which models the likelihood of documents using a variational auto-encoder (vae) @xcite . in order to purposefully uncover topic words related to the target (e.g. sentiment), many researchers have also proposed alternative approaches. for example, @xcite added topic consistency to the training as part of the loss as well, thus making the latent variables dependent on the topic target as well. neural network-based deep learning can be described as a black box, and humans are not yet able to fully explain or peer into the entire deep learning process. so the question arises whether humans can be trusted with the decision-making mechanisms of such data-driven ai systems. the lack of interpretability leads to a reduction in the reliability of deep learning, hence the importance of interpretable analysis. in an earlier study, @xcite hoped to find parts of the training data/training points that could be used as a basis for interpretation by introducing the influence func-tion. some researchers, on the other hand, have tried to find explanations for the prediction results from the test data itself. such explanations can be found by perturbing the data @xcite , extracting attention weights @xcite or calculating the saliency scores of the input sequences @xcite , etc. @xcite ; @xcite used a combination of generators and encoders to extract rationales. ## preliminary works text classification and topic modelling have been important areas of research in natural language processing. these two areas are extremely interrelated, but few studies have effectively integrated them into a unified system. one successful example is the cantm model proposed by @xcite on topic modelling of online text messages during the covid-19 epidemic, which is able to effectively identify disinformation related to covid-19 and simultaneously classify the information, helping to address issues such as citizens' distrust of government and healthcare. the architecture of cantm is shown in figure 1 . the model is divided into three parts, bert embedding, the classifier-regularised vae (m1) and the classifier-aware vae (m2), where the vae architectures are used as topic models. the model first uses a bert pre-trained model to extract segment embeddings h from the input text sequence x. in the encoder part of m1, h is transformed into the parameters µ and σ of the gaussian distribution via the linear layers linear µ and linear σ respectively. the aim of the m1 encoder is to generate the latent variable z, which can be considered as hidden topics. the m1 decoder part uses the latent variable z as input to reconstruct the bag of words of the input text. the m1 classifier also uses the latent variable z as input, and generates classification probabilities after passing through a fully connected layer containing a softmax activation function. note that since the classifier uses hidden topics as the basis for classification, it has not seen real data, which can reduce the overfitting of the model. the architecture of m2 is similar to m1, except that it takes the classification probabilities ŷ output from m1 as input as well, in order to generate hidden topics z s guided by the classification information. furthermore, the m2 classifier is not used to output the final classification, but only to compute joint loss during training. the joint loss function of cantm is a combination of the loss functions of its subcomponents and is calculated as cantm has good classification and topic discovery capabilities, but it is not fully suitable for conflict information. firstly, it does not introduce interpretability analysis to demonstrate the reliability of the model. secondly, the topics discovered by cantm are to some extent disturbed by a large number of neutral words present in the input text, thus making the relevance of the discovered topic words to the category information reduced. moreover, the cantm architecture has redundant parts, which affects its computational efficiency. ## methodology our model is based on an improvement of cantm, which we call classification-aware neural topic model combined with interpretable analysis (cantm-ia). cantm is used as the base model because it combines text classification and topic modelling, which aligns with our goals. secondly, the stacked vae architecture of cantm effectively allows us to discover the hidden topics of the target categories. in addition, topics can also be seen as an interpretation of the classification model, which facilitates our interpretability analysis and improvement of the model in conjunction with rationale. we introduced interpretability analysis specifically by calculating the attention weights of the last layer in the bert pre-trained model corresponding to the cls labels and averaging them into the saliency score of the corresponding word piece. the magnitude of the saliency score is used as a visual representation of the importance of different parts of the original sample, and the parts with high saliency scores are used as the rationales of the sample. bert parameters are frozen during training and only the last transformer encoding layer weights are unlocked for fine-tuning. afterwards, we use the saliency scores of the rationales instead of the bag of words of the entire input sequence as the reconstruction target in the vae architecture. this has several advantages. first, using rationales (the part of the input sequence with high contribution) as the reconstruction target allows the topic model to focus more on the important information of the input sequence, which can reduce the interference of category-irrelevant words by the topic words and indirectly improve the classification performance of the model. second, since the decoder uses rationales to guide the discovery of hidden topics and the classifier uses hidden topics for classification, it can be argued that these rationales explain both the hidden topics and the classification results. in addition, there is a redundant structure in the m2 decoder part of the cantm model. as shown in figure 1 , m, as the variable that combines the input h with the classification result ŷ, already introduces classification information for the rest of m2. that is, the process of generating the variable z s has been guided by the classification information, which generates the class-aware topics. therefore, there is no need to reintroduce the classification result ŷ in the decoder part of m2, and the purpose can be achieved by directly reconstructing the target using z s as the hidden topic variable. combining the above optimisation methods, the modified cantm-ia model is shown in figure 2 . ## conclusion we proposed a classification-aware neural topic model (cantm-ia) for conflict information classification and topic discovery in this paper. the classification results and topic models of cantm-ia can be reliably interpreted using rationales. also, rationales are introduced into the topic model to improve model performance. finally, the model architecture has been optimised. compared to the baseline systems, cantm-ia has improved predictive performance, reliability and efficiency. our future work will be to adapt the model to other types of data and to refine the way in which interpretable analysis is introduced.