Neural News Recommendation with Negative Feedback

News recommendation is important for online news services. Precise user interest modeling is critical for personalized news recommendation. Existing news recommendation methods usually rely on the implicit feedback of users like news clicks to model user interest. However, news click may not necessarily reflect user interests because users may click a news due to the attraction of its title but feel disappointed at its content. The dwell time of news reading is an important clue for user interest modeling, since short reading dwell time usually indicates low and even negative interest. Thus, incorporating the negative feedback inferred from the dwell time of news reading can improve the quality of user modeling. In this paper, we propose a neural news recommendation approach which can incorporate the implicit negative user feedback. We propose to distinguish positive and negative news clicks according to their reading dwell time, and respectively learn user representations from positive and negative news clicks via a combination of Transformer and additive attention network. In addition, we propose to compute a positive click score and a negative click score based on the relevance between candidate news representations and the user representations learned from the positive and negative news clicks. The final click score is a combination of positive and negative click scores. Besides, we propose an interactive news modeling method to consider the relatedness between title and body in news modeling. Extensive experiments on real-world dataset validate that our approach can achieve more accurate user interest modeling for news recommendation.

Introduction
Online news services such as Google News 1 and Microsoft News 2 can collect news from various sources and display them to users in a unified view [6,32]. However, a large number of news articles are generated every day and it is overwhelming for users to find their interested news [19]. Thus, personalized news recommendation is critical for these news services to target user interests and alleviate information overload [29].
Accurate user interest modeling is a core problem in news recommendation. Existing news recommendation methods usually learn representations of users from their historical news click behaviors [19,26,28,31]. For example, Okura et al. [19] proposed to learn user representations from the clicked news via a gated recurrent unit (GRU) network. Wang et al. [26] proposed to learn user representations from clicked news with a candidate-aware attention network that evaluates the relevance between clicked news and candidate news. In fact, users usually click news due to their interests in the news titles. However, news titles are usually short and the information they condensed is very limited and even misleading. Users may be disappointed after reading the content of their clicked news. Thus, news click behaviors do not necessarily indicate user interest, and modeling users solely based on news clicks may not be accurate enough.
Besides news clicks, users also provide other implicit feedback like the dwell time of news reading, which is an important indication of user interest. As shown in Fig. 1, the user clicks two news articles and respectively reads them for 3 and 220 seconds before closing the news webpages. We can infer that this user may not be interested in the first news because she reads the body of this news for only 3 seconds before her leaving. Thus, a short dwell time of news reading can be regarded as a kind of implicit negative user feedback, which can help model user interest more accurately. In addition, since users usually decide which news to click according to news titles and read news bodies for detailed information, incorporating both news title and body is useful for news and user interest modeling. Moreover, the title and body of the same news usually have some inherent relatedness in describing news content. For example, in Fig. 1 the title of the second news indicates that this news is about NFL games, and the body introduces the details of these events. Capturing the relations between news title and body may help better understand news content and facilitate subsequent user interest modeling.
In this paper, we propose a neural news recommendation approach with negative feedback (NRNF). We propose to distinguish positive and negative news click behaviors according to the reading dwell time, and learn separate user representations from the positive and negative news clicks with a Transformer to capture behavior relations and an additive attention network to select important news for user modeling. In addition, we propose to respectively compute a positive click score and a negative click score based on the relevance between candidate news representation and the user representations learned from positive and negative news clicks. Besides, we propose an interactive news modeling method to incorporate both news title and body by using an interactive attention network to model their relatedness. Massive experiments conducted on real-world dataset demonstrate that our approach can effectively improve the performance of user modeling by incorporating implicit negative user feedback.

Related Work
News recommendation is an important task in the data mining field, and has gained increasing attention in recent years [34]. Learning accurate representations of users is critical for news recommendation. Many existing news recommendation methods rely on manual feature engineering to build user representations [18,3,23,13,7,2,21,4,36]. For example, Li et al. [16] proposed to represent users using their demographics, geographic information and behavioral categories which summarize the consumption history on Yahoo!. Garcin et al. [8] proposed to model users by aggregating the LDA features of all clicked news into a user vector by averaging. Lian et al. [17] proposed to build user representations from various handcrafted features like user ID, demographics, locations and the feature collection of clicked news. However, these methods rely on manual feature engineering, which needs massive domain knowledge to craft. In addition, handcrafted features are usually not optimal for representing user interest.
In recent years, several news recommendation methods based on deep learning techniques are proposed [19,14,26,29,1,27,30,31,9,11]. For example, Okura et al. [19] proposed to learn representations of users from the representations of their browsed news using a GRU network. Wang et al. [26] proposed to learn user representations from clicked news based on their relevance to the candidate news. Zhu et al. [35] proposed to generate user representations using a combination of a CNN network and an attention-based LSTM network. Wu et al. [31] proposed to use multi-head self-attention network to learn user representations by capturing the interactions between clicked news. These methods only rely on news click behaviors to learn user representations, which may be insufficient because news clicks may not exactly reflect user preferences. Different from these methods, our approach can learn representations of users by incorporating the implicit negative feedback of users inferred from their reading dwell times, which can provide useful clues to calibrate the user interest inferred from news click behaviors.

Our Approach
In this section, we introduce the details of our neural news recommendation approach with negative feedback (NRNF). The architecture of NRNF is illustrated in Fig. 2. We will introduce each core technique in our method, including user modeling, click prediction, news modeling, and model training, in the following sections.

User Modeling with Negative Feedback
In this section, we introduce how to model user interests from their clicked news by considering negative feedback. Usually, the interests of users on the news they read carefully are very different from those they closed quickly after having a glance at the body. For example, as shown in Fig. 1, we can infer that the user may be indeed interested in the second news since she reads this news for about 220 seconds. However, she is probably not interested in or unsatisfied with the first news since she reads this news only for 3 seconds after click. Thus, incorporating short reading dwell time as the implicit negative feedback of users has the potential to enhance the modeling of user interest.
To characterize the differences of news in representing the real user interests, we use their reading dwell times t to distinguish positive news clicks from the negative ones. We regard the clicked news with t < T as negative news clicks and those with t ≥ T as positive news clicks, where T is a time threshold. Since simply aggregating all news together will ignore the differences of positive and negative news, in the user encoder module we propose to use a multiview learning framework to incorporate positive and negative news clicks as different views of users. Their details are introduced as follows.
The positive news click view is used to learn a positive user embedding from positive clicked news. We denote the P positive clicked news of a user as [D 1 , D 2 , ..., D P ]. We first use a news encoder to obtain their representations, which are denoted as R p = [r 1 , r 2 , ..., r P ]. Then, we use a positive feedback encoder to learn a unified user embedding from these news representations. It uses a similar architecture with the user encoder used by Wu et al. [31]. Since different clicked news usually have some interactions with each other, we use a news-level Transformer [25] to capture the interactions among them 3 , and the output sequence is computed as: where the three parameters in T ransf ormer(·) respectively denote the input query, key and value. In addition, since different clicked news have different importance in modeling user interests, we use an additive attention [33] network to select important news to learn more informative user representations. The final positive user embedding u p learned from this view is computed as: where q p is a query parameter vector, D p is regarded as the key and value. It summarizes user interests inferred from the positive user feedback. The negative news click view is used to learn representations of users from their negative clicked news. Similar to positive news, we use a combination of Transformer and additive attention network to learn the negative user embedding from the representations of the negative clicked news. We denote the negative user embedding learned from this view as u n , which condenses the information of negative user interest inferred from the negative clicked news.

Click Prediction
In this section, we introduce the details of click prediction in our approach. Usually, if a candidate news is similar to the news that a user reads carefully, it may have a high probability to be clicked by this user. However, if it is very similar to the news that are previously closed by a user very quickly, it will probably not be clicked by this user. Motivated by the observations above, we propose to calculate a positive click scoreŷ p and a negative click scorê y n respectively based on the relevance of candidate news to the positive and negative user interest. We denote the embedding of a candidate news D c as r c . Following [19],ŷ p andŷ n are respectively computed by the inner product of the candidate news embedding and the user embeddings learned from the positive and negative views, which are formulated as: The final click probability scoreŷ is a weighted summation of the positive scoreŷ p and the negative scoreŷ n , which is formulated as: where w p and w n are learnable parameters. A positive parameter means that the relevance between candidate news and the corresponding user embedding has a positive correlation with the final click score, and this correlation is negative if the parameter is negative.

News Modeling
In this section, we introduce the architectures of the news encoder in our approach for news modeling. It is used to learn representations of news from their titles and bodies. Since news titles and bodies usually have very different characteristics, simply concatenating title and body together may not be optimal. Thus, in this module we use a multi-view learning framework to incorporate the information of title and body as different views of news. In addition, since there is usually inherent relatedness between news title and body, we propose to use an interactive attention network to capture their relations and form the unified news embedding. The details of each module in the news encoder are introduced as follows.
The first module in the news encoder is a title transformer, which is used to capture the contexts of words in a news title. We first use a word and position embedding layer to convert the sequence of words in a news title into a sequence of low-dimensional word embeddings with their position information. Denote a news title with T words as [w t 1 , w t 2 , ..., w t T ]. It is converted into an embedding sequence E t = [e t 1 , e t 2 , ..., e t T ]. Then, we use a Transformer to learn the contextual representation of each word, which is computed as follows: The second module in the news encoder is a body transformer, which aims to capture the contexts of words in a news body. Similar to news title, we also use a word and position embedding layer to obtain the embeddings of the M words in a news body, which are denoted as It's not with salt Interactive Attention News Embedding Fig. 3 The architecture of the news encoder.
we use a Transformer to capture the contexts of words, and its output H b is computed as The third module is an interactive attention network, which is used to capture the relations between news title and body when forming the unified news embedding. We first use two additive attention network to respectively attend to the important words in news title and body to form the title and body representations(denoted as r t and r b ), which are formulated as where q t and q b are learnable query vectors. Then, we use the title representation as the query of the body attention network to select words in news body according to their relevance to the content of news title, and the output title-aware body representation c b is computed as follows: We learn a body-aware title representation c t in a similar way by using the body representation as the title attention query, which is formulated as: We finally aggregate all title and body representations into a unified news representation r, i.e., r = r t + r b + c t + c b .

Model Training
Following [12,28], we use negative sampling techniques to construct labeled data from the raw news impression logs for model training. For each news clicked by a user, we randomly sample Q news that are displayed in the same impression but not clicked by this user. We denote the click probability scores of the clicked news sample asŷ + and the Q unclicked news samples as . we re-formulate the news click prediction problem as a pseudo Q+1-way classification task to jointly predict these scores. We normalize these scores via the softmax function to compute the posterior click probability of the clicked news, which is formulated as follows: .
The final loss function we used is the negative log-likelihood of all clicked news samples, which is formulated as: where S is the set of clicked news samples for training.

Datasets and Experimental Settings
Our experiments were conducted on a real-world news recommendation dataset collected from MSN News 4 logs from Oct. 31, 2018 to Jan. 29, 2019. The detailed statistics are shown in Table 1. We sorted all sessions by time, and we used the first 80% of sessions for training, the next 10% for validation and the rest 10% for test. In our experiments, the word embeddings were 300-dimensional and initialized by Glove [20] The Transformers had 8 attention heads, whose output dimension was 32. The maximum lengths of title and body were respectively set to 30 and 200, respectively. The numbers of positive and negative clicked news were respectively limited to 50 and 20. Following [12], the negative sampling ratio Q was set to 4. The threshold T was set to 10 seconds. Adam [15] was used as the optimizer, and the batch size was 30. To mitigate overfitting, we applied dropout [24] techniques to the word embeddings and Transformer networks, and the dropout ratio was set to 0.2. These hyperparameters were tuned on the validation set. We independently repeated each experiment 10 times and reported the average results in terms of AUC, MRR, nDCG@5 and nDCG@10.

Performance Evaluation
We evaluate the performance of our approach by comparing it with many baseline methods, including: -LibFM [22], a factorization machine based method for recommendation.
We extracted the TF-IDF features from the titles and bodies of news clicked by users to build their representations. -DSSM [12], deep structured semantic model. We regarded the concatenation of the news clicked by a user as the query and candidate news as documents, and we used the same feature with LibFM for news and user representation.  -NRNF, our news recommendation approach with negative feedback.
For fair comparison, in GRU, DKN, DAN and NRMS we used the concatenation of news title and news body to learn news representations. The results of these methods are summarized in Table 2.
From Table 2, we have several observations. First, compared with baseline methods that use handcrafted features to represent news and users (e.g., LibFM, DSSM and DeepFM ), the models using neural networks for learning news and user representations (e.g., EBNR, NAML and NRNF ) achieve better recommendation performance. This is probably because neural networks can learn more informative news and user representations than hand-crafted features. Second, compared with other neural news recommender like DAN, NAML and NRMS, NRNF and its variant NRNF-basic achieve better performance. This is because the latter methods can capture the relatedness between news title and body to enhance news modeling, while other methods cannot. Third, NRNF outperforms other baseline methods, and further hypothesis tests show that the improvement is significant. This is probably because incorporating the implicit negative user feedback can help learn more accurate user interest representations.

Effectiveness of Different News Information
Next, we explore the influence of incorporating different news information for news modeling. We compare the performance of our approach with its variants with different combinations of news information, and the results are shown in Fig. 4. From Fig. 4, we have several observations. First, both news title and body are useful for news recommendation. This is because users usually decide which news to click based on its title, and read news body for detailed information. Thus, both news title and body can provide important information for news recommendation. Second, news body is more useful than news title in representing news. This is intuitive because news body usually contains the details of news, which can provide richer information than news title. Besides, combining both title and body of news can further improve the performance of our approach. These results validate the effectiveness of the multi-view learning framework in our approach.

Effectiveness of Attention Network
Then, we explore the influence of different attention networks on the performance of our approach. The results are shown in Fig. 5. From Fig. 5, we find that word-level attention networks are very useful for our approach. This is because different words in news titles and bodies usually have different importance in representing news. Thus, selecting important words can help learn more informative news representations. In addition, news-level attention network is also important. This is because different news usually have different informativeness in representing the preferences of users, and selecting informative news can benefit user representation learning. Besides, the interactive attention network can also boost the performance. This may be because it can help capture the relations between news title and body to enhance news modeling. Moreover, combining all these kinds of attention networks can further improve the performance of our approach. These results verify the effectiveness of each kind of attention mechanism in our approach.

Influence of Hyperparameters
In this section, we study the influence of an important hyperparameter on our approach, i.e., the dwell time threshold T . We compare the performance of our approach w.r.t different values of T . The results are illustrated in Fig. 6. We find the performance of our approach improves when the threshold T increases. This is probably because when T is too small, many negative news clicks cannot be distinguished from the positive ones, and the modeling of user interest is not accurate enough. In addition, the performance of our approach  declines when T goes too large. This is also intuitive because when T is too large, many positive news clicks will be mistakenly regarded as negative ones and the errors will be encoded into the negative user embedding, which leads to the sub-optimal performance. Therefore, a moderate selection of T , e.g., 10 seconds may be more appropriate for our approach, which is also consistent with our news browsing experiences.

Parameter Analysis
In this section, we conducted several studies on the results of other two key parameters learned by our model, i.e., w p and w n . The results in 10 independent experiments are illustrated in Fig. 7. According to these results, we find w p is consistently positive. It is intuitive because the news read by users carefully can usually represent the preferences of users. Thus, the similarities between the candidate news and the positive clicked news should have a positive impact on the click probability. In addition, we find w n is consistently negative. This may be because if a user reads a news article very quickly, we can infer that he/she is probably not interested in this news. Thus, the click probability should have a negative correlation with the similarities between candidate news and negative clicked news.

Qualitative Analysis of Negative News
In this section, we will conduct several qualitative analysis on the characteristics of the negative clicked news. First, we want to compare the topic distributions of positive and negative news, and the results are shown in Fig. 8. According to Fig. 8, we find the ratios of negative news in different topic categories have some differences. For example, it is interesting that the ratio of negative news is the highest in the "video" category. This may be because many users are attracted by the titles of the news in this category, but they are not interested in the content of these news. Thus, incorporating the informa- tion of negative feedback may also implicitly encode topical information into user representations, which is useful for more accurate news recommendation.
In addition, we aim to discover some common patterns of negative news, e.g., the contents and writing styles of their titles. We calculate the ratio of negative feedback (NF) for each news 5 , and the titles of the top 10 news with the highest NF ratios are listed in Table 3. From Table 3, we find many news with top NF ratios are clickbaits, and they have very similar writing styles, i.e., describing something in a sensationalized way but no details are provided. Thus, many users may be attracted by the news titles and click these news. However, after taking a glance at the news body, many users may be disappointed and close these news quickly. Thus, it is harmful for news platforms to improve user experiences if clickbaits are frequently recommended to users. Fortunately, our approach may have the potential to avoid recommending too many clickbaits to user by incorporating the negative feedback of users, which can improve the reading experiences of users.

Case Study
In this section, we conducted several case studies to show the effectiveness of our approach. First, we want to visually explore the effectiveness of incorporating the negative feedback of users. The clicked news and candidate news of a randomly selected user are listed in Table 4. We calculate the click probability score respectively using our approach and its variant without negative feedback. According to Table 4, the second candidate news is assigned the highest click score when negative feedback is not considered. This is probably because it is very similar to the second and third clicked news, since all of them are about Oscars. However, we can infer that this user is probably not very interested in this topic since she closes the second and third clicked news very quickly. Thus, it may be ineffective to recommend Oscars related news to this user. Fortunately, our approach can assign the second candidate news a low click score. This is because our approach can take the implicit negative user feedback into consideration, which is beneficial for modeling user preferences more accurately.

Conclusion
In this paper, we propose a neural news recommendation approach that can consider the implicit negative feedback of users. We propose to distinguish positive and negative news clicks according to users' reading dwell time, and we propose to respectively learn two different embeddings of a user from her positive and negative news clicks. In addition, we propose to compute a unified news click score based on a combination of the relevance scores between candidate news and these two user embeddings. Besides, we propose an interactive news modeling method that can learn unified news representations from title and body with full consideration of their relatedness. Extensive experiments on real-world dataset show that incorporating negative user feedback can effectively improve the performance of user modeling for news recommendation.


An Edge-Enhanced Hierarchical Graph-to-Tree Network for Math Word Problem Solving

Math word problem solving has attracted considerable research interest in recent years. Previous works have shown the effectiveness of utilizing graph neural networks to capture the relationships in the problem. However, these works did not carefully take the edge label information and the long-range word relationship across sentences into consideration. In addition, during generation, they focus on the most relevant areas of the currently generated word, while neglecting the rest of the problem. In this paper, we propose a novel EdgeEnhanced Hierarchical Graph-to-Tree model (EEH-G2T), in which the math word problems are represented as edge-labeled graphs. Specifically, an edge-enhanced hierarchical graph encoder is used to incorporate edge label information. This encoder updates the graph nodes hierarchically in two steps: sentence-level aggregation and problem-level aggregation. Furthermore, a tree-structured decoder with a split attention mechanism is applied to guide the model to pay attention to different parts of the input problem. Experimental results on the MAWPS and Math23K dataset showed that our EEH-G2T can effectively improve performance compared with state-of-the-art methods. 1

Introduction
Math word problem solving is an important natural language processing (NLP) task that has recently been attracting increasing research interests. Math word problems are narrative text that describe a scene with several math variables and ask a question about an unknown quantity. A simple example is illustrated in Figure 1. Based on the given problem, the target is to infer the difference between the number of boxes of apples and pears.  (Zhang et al., 2020b) and EEH-G2T.
Previous works Huang et al., 2018;Wang et al., 2019) used sequenceto-sequence (seq2seq) methods with an attention mechanism (Bahdanau et al., 2014) to generate math expression sequences from math word problems. To capture the structural information of math expressions, many works (Liu et al., 2019;Xie and Sun, 2019;Zhang et al., 2020a) treat math expressions as binary trees and propose several sequence-to-tree (seq2tree) frameworks. These tasks are designed to obtain the pre-order sequence of the expression tree, and they generate the current node based on its parent node and sibling node at each time step. Some works that represent problems as graphs also show better performance. Graph2Tree (Zhang et al., 2020b) connects each number in the problem with its nearby nouns to enrich the quantity representations. KA-S2T (Wu et al., 2020) connects words with its category in the external knowledge base to capture common sense information.
Although these methods report promising results, several challenges still remain. 1) Long-range word relationships across sentences should be taken into consideration. As shown in Figure 1, the word "pear" in the second sentence should be associated to the word "pear" in the last sentence. Without long-range relationships, it is difficult for the model to connect these two words that are 15 steps apart. 2) Previous methods did not carefully take the edge label information into consideration. In figure 1, the label on the edge between "kilograms" and "pear" is nmod (noun compound modifier), while the label "category" on the edge between "apples" and "pears" means they belong to the same category in the external knowledge base. Such edge labels can also provide rich syntactic and semantic information. 3) When generating expressions, previous methods tend to focus on the areas in the problem that are most relevant to the currently generated words, and ignore the semantic clues provided by the rest of the problem. As shown in Figure 2, to generate "360" instead of "240" at time step 3, the model needs to pay attention to the entire problem to obtain important clues that the current sub-expression "/360 24" is the number of apple boxes and 360 is the weight of the apples. However, previous methods focused on the problem areas that are most relevant to the currently generated word (i.e., the number 360 itself), without noticing the rest of the problem.
To tackle these challenges, we propose a novel Edge-Enhanced Hierarchical Graph-to-Tree framework (EEH-G2T) for math word problem solving. EEH-G2T represents each math word problem as a graph in which the nodes are connected by labeled edges. To obtain the edge-aware problem representations, we propose an edgeenhanced hierarchical graph encoder that explicitly incorporates edge label information. In addition, the hierarchical encoder updates the nodes in two steps: sentence-level aggregation and problemlevel aggregation. This hierarchical structure can first capture the local relations between words within the sentence and then capture the long-range dependencies between words across sentences. Further, we use a split attention mechanism to guide the decoder to pay attention to different parts of the entire input problem, not just the most relevant part of the currently generated word.
The main contributions of this paper can be summarized as follows: • We propose an edge-enhanced hierarchical graph encoder to incorporate edge label information. Additionally, the encoder updates the graph nodes in two steps, namely sentencelevel aggregation and problem-level aggregation.
• We propose a split attention mechanism to guide the decoder to pay attention to different parts of the entire input problem during the generation.
• We conducted experiments on two commonly used math word problem solving datasets, MAWPS and Math23K. Experimental results prove that our approach can effectively improve the performance compared with stateof-the-art methods.

Problem Formulation
In this work, we focus on generating math expressions for the given math word problems. We denote the text of a math word problem as a sequence of words and number symbols. X=(x 1 , x 2 , . . . , x m ) is a math word problem with m words. Our model aims to generate a math expression Y= (y 1 , y 2 , . . . , y T ). Here, Y is a pre-order traversal  Figure 3: The procedure for construction of a edge-labeled graph is described here. For brevity, we omit some self-node edges and the labels of some neighbor edges and dependency edges. Given a math word problem, we first use the Stanford Corenlp toolkit to parse it into a dependency tree, and extract the relationships between nouns from the external knowledge bases. Based on these, we construct the edge-labeled graph, as shown in the bottom part of the figure ( See Section 2.2 for more details).
sequence of a math expression tree, which can be executed to generate the answer to problem X.
Formally, math word problem X can be represented by a graph G = (V, E), where V and E are the set of nodes x i and the set of edges e ij . Here, each node in the graph is associated with a word x i in the problem. e ij ∈ E denotes that there is an edge between the node pair (x i , x j ). L(e ij ) denotes the label of edge e ij (e.g., self-node, category, neighbor), see section 2.2 for more details.

Graph Construction
This section introduces how to construct an edgelabeled graph that contains both the local relations between nodes within a sentence and the longrange relations between nodes across sentences. Our model extracts these relations from the problem's dependency tree and external knowledge base. We use the Stanford Corenlp toolkit 2  to parse each math word problem into a dependency tree. The toolkit analyzes the grammatical structure of a sentence and establishes relationships between "head" words and words which modify those heads. In addition, inspired by , we collected word category information from external knowledge bases. An illustrative example is shown in Figure  3. Specifically, given a math word problem X, its dependency tree, and word category information, our model constructs a graph according to the following steps.
• Self node & Neighbor: We define each word x i in the problem X as a node. Each word node x i is connected to its adjacent word nodes (x i−1 , x i+1 ) in the problem. These edges are labeled as "neighbor". Also, to incorporate the node's own information into the problem representations, we connect each node to itself and label the edge as "self node".
• Dependency (edges within sentences): The dependency tree is a structured representation that contains various grammatical relationships between word pairs. Following Zhang et al. (2020b), we prune the output dependency tree to remove unimportant components, that is, remove edges connected to conjunctions, prepositions or punctuation. Based on the dependency tree, we establish relationships between nodes within the sentence, and keep the edge labels (e.g., nmod, nummod, appos). For example, "360" and "kilograms" are connected by the edge "nummod" in Figure 3.
• Same & Category (edges across sentences): To further capture the connection across sentences, if the same word exists in two sentences and it is a noun, then we connect these two nodes and label the edge as "same". If two words belong to the same category in the external knowledge base, we also add a connection for their nodes and label the edge as "category". For example, "apples" and "pears" are connected by the edge "category" in Figure 3.

Graph Initialization
To initialize the node representations of the graph, we use a BiLSTM (Hochreiter and Schmidhuber, 1997) to encode the words in the math word problem X=(x 1 , x 2 , . . . , x m ). Here, H 0 = (h 0 1 , h 0 2 , . . . , h 0 m ) ∈ R m * d is the initial node representations of its graph G, where m is the number of nodes and d is the dimension of the node representation. The representation h 0 i of node x i is calculated as follows: where Embed(·) is an embedding layer. For each edge e ij , we initialize the edge representation e 0 ij based on the edge embedding and its neighbor node representations h 0 i , h 0 j : where W e is a weight matrix and [:] is the concatenation operation.

Edge-Enhanced Hierarchical Graph Encoder
After initializing the graph, EEH-G2T uses an edgeenhanced hierarchical graph encoder to obtain the edge-aware problem representations. It hierarchically updates the nodes in two steps: sentence-level aggregation and problem-level aggregation. We divide math word problems into short sentences based on commas and periods. For example, the problem in Figure 1 has four sentences. Sentence-level Aggregation.
To capture the local relations between words, EEH-G2T first recursively aggregate the node representation with its related nodes within the sentence. Let A denote the local relationship matrix, where A ij ∈ {0, 1} denotes whether there is an edge between x i and x j . Formally, A ij = 1 if e ij ∈ E and x i , x j in the same sentence, otherwise A ij = 0. The initial node representations H 0 = (h 0 1 , h 0 2 , . . . , h 0 m ) are aggregated with a two-layer graph convolutional network (GCN) (Kipf and Welling, 2017). The aggregation functions are as follows: Here, W g is a weight matrix and σ is a relu activate function. After sentence-level aggregation, we obtain the node representations H 1 = (h 1 1 , h 1 2 , . . . , h 1 m ). Problem-level Aggregation.
Then, EEH-G2T use an attentive problem-level aggregation to capture long-range dependencies across sentences. Inspired by GAT (Veličković et al., 2018), we use the multi-head attention in GAT with M independent attention mechanisms: Here, w T a , W a , W b , W c , W j are weight vector and matrices. σ is a LeakyRelu activate function (Xu et al., 2015). || is the concatenation operation. α ij is the normalized attention weight of the node x j for node x i via the softmax function. After problem-level aggregation, we obtain the final problem representations H = (h 1 , h 2 , . . . , h m ).

Tree-structured Decoder
The structure of the decoder is similar to other stateof-the-art Seq2Tree models (Xie and Sun, 2019;Zhang et al., 2020b;. The decoder is an attention-based Gated Recurrent Unit (GRU) (Chung et al., 2014) whose goal is to generate preorder traversal of expression trees. The hidden state s t is updated as follows: s t+1 = BiLSTM([Embed(y t ) : c t : r t ], s t ).
(5) At time step 1, we use the last problem representations h m to initialize the decoder hidden state s 1 . Here, Embed(y t ) denotes the embedding of the last generated word y t ; c t denotes the context state of the problem representations, and r t denotes the context state of the currently generated expression. Split Attention Mechanism. Figure 4 shows the input of our proposed split attention mechanism, which is the final problem representations of the graph encoder. EEH-G2T first uses an attention mechanism to compute the overall attention vectorα on the problem representations. Then, EEH-G2T divides the input math word problem into K parts, conducts attention operations on each part, and obtains K split attention vectors (α 1 , α 2 , . . . , α K ). The size of each split attention vector is R (m/K) . In Figure  1, when the decoder generates y 3 =360, EEH-G2T notices that the word most relevant to the current decoder state is "360" in the first sentence. At the same time, EEH-G2T obtains crucial semantic clues from the other parts, that is, the problem asks how many pear boxes are less than the apple boxes. Based on K attention vectors, the problem context state c t is calculated as follows: where W s , W h are the weight matrices. α k ti denotes the attention distribution on the k-th part of the problem representations at time step t. Expression Aggregation Mechanism.
Following , we use a state aggregation mechanism to compute the expression context state r t : σ is a sigmoid function and W r is a weight matrix. At time step 1, we use the decoder state s 1 to initialize expression context state r 1 . For each node in the currently generated expression tree, r t,p , r t,l and r t,r represent the expression context state of the parent node, left child node, and right child node of the current node. If the current node does not have parent or child node at this time step, we pad it with a PAD vector. Finally, we use a copying mechanism (Gulcehre et al., 2016) so that the model either generate a word from the vocabulary or copy a word from the input problem X. At time step t, based on the decoder state s t , the problem context state c t and the expression context state r t , EEH-G2T calculates a copy gate value g t ∈ (0, 1) to determine whether the word y t is generated or copied: , P(y t |y <t ,X) = g t P c (y t )+(1−g t )P g (y t ).
(8) W s , W c , W r and W g are weight matrices.α ti is the overall attention vector in the split attention mechanism. The probability distribution P(y t |y <t ,X) of generating y t is calculated over the copy distribution P c (y t ) and generate distribution P g (y t ).

Training
We train the model with the cross-entropy loss, defined as: log P(y t |y <t ,X).
During the inference, we use beam search to generate final expression. At time step t, if y t is an operator, the current node is an internal node, and the model continues to generate its child nodes. If y t is a number, it represents a leaf node with no child node. Once the children of all the internal nodes have been generated, the generated expression sequence Y= {y 1 , y 2 , . . . , y T } is transformed into an expression tree, and the decoding process is terminated.

Datasets
We evaluated our model on two commonly used math word problem datasets, MAWPS (Koncel-Kedziorski et al., 2016) with 2,373 problems and Math23K  with 23,162 problems. We adopt the data preprocessing provided by . Following previous studies (Xie and Sun, 2019;Li et al., 2020;, we use the same data split for the train/dev/test set. The Stanford CoreNLP toolkit is used for dependency parsing. Hownet (Dong et al., 2010) and Cilin (Mei, 1985) are used as external knowledge bases. We choose words that appear more than 5 times in the training set or appear as edge labels to build a vocabulary, and replace words that are not in the vocabulary with a UNK token. We use answer accuracy as the evaluation metric.

Implementation Details
We used Pytorch for our implementation 3 . We used 300-dimensional Glove word embeddings (Pennington et al., 2014). The hidden size is 512. The batch size is 64. The number of heads M in problem-level aggregation is 8. The number K of split attention vectors is 2. We set the learning rate of the Adam optimizer (Kingma and Ba, 2014) to 0.001, and the dropout is 0.5.
During training, it took 120 epochs to train the model. During decoding, we used a beam search with a beam size of 5. We used the same parameter settings for both Math23K and MAWPS datasets. The hyper-parameters are tuned on the valid set.

Baselines
We compare the performance of our model with the following baselines: DNS ) is a seq2seq model that consists of a two-layer GRU encoder and a two-layer LSTM decoder. Math-EN (Wang et al., 2018) is a seq2seq model with a bidirectional LSTM encoder and an attention mechanism. Recu-RNN (Wang et al., 2019) uses recursive neural networks on the predicted tree structure templates. Tree-Dec (Liu et al., 2019) is a seq2tree model with a tree-structured decoder, which generates each node based on its parent and sibling node. GTS (Xie and Sun, 2019) is a seq2tree model that generates expression trees in a goal-driven manner. It generates each node based on its parent node and its left sibling subtree embedding. KA-S2T  is a graphto-tree model with commonsense knowledge from the external knowledge base. It uses a state aggregation mechanism to recursively aggregate neighbors of each node in the expression tree. Graph2Tree (Zhang et al., 2020b) is a graph-totree model that leverages the nouns nearby the numbers to enrich the quantity representations in the problem.  Table 2: Ablation analysis of edge-enhanced hierarchical graph encoder and split attention mechanism used in EEH-G2T.

Results Analysis
can observe that: 1) Two graph-to-tree model, KA-S2T and Graph2Tree, performed significantly better than the Seq2Tree model GTS, showing that the graph structure in the encoder is effective in enriching the problem representations. 2) Our proposed EEH-G2T outperformed all the other baselines, which proved the effectiveness of using an edge-enhanced hierarchical graph encoder and split attention mechanism.

Ablation Study
Effect of Hierarchical Graph Encoder. As shown in Table 2, we estimate the effectiveness of the proposed hierarchical graph encoder. From the results, both sentence-level aggregation and problem-level aggregation improve the performance. Removing the sentence-level aggregation reduces answer accuracy by 1.1%, and removing the problem-level aggregation reduces answer accuracy by 0.7%. When we remove the both aggregation mechanisms and use the initial node representations as the final problem representations, the answer accuracy decreases by 2.0%. We believe that the superior performance of the hierarchical graph encoder is because it captures both the local relations between words   within a sentence and the long-range relations between words across sentences.

Effect of Edge Label Information and Split Attention Mechanism.
To prove the effectiveness of edge label information and split attention mechanism in the proposed EEH-G2T, we conduct ablation experiments on the Math23K dataset as shown in Table 2. We observe a slight accuracy drop by 0.4% after removing the edge label information, demonstrating that edge labels provides syntactic and semantic information to enrich the problem representations. Moreover, removing the split attention mechanism leads to a drop by 0.8%, which verifies the effectiveness of using a split attention mechanism. Effect of Different Edge Categories. Table 3 shows the performance when removing one edge category at a time. We can see that all the edge categories have positive effects on the model performance. The performance of the model without "self node" edges drops the most, because "self node" allows the model to keep the information of the node itself. Additionally, removing "category" and "neighbor node" edges will slightly reduce model performance. Without "dependency" and "same word" edges, model accuracy will drop to 76.9 % and 76.0%.

Split Number in Split Attention Mechanism.
To explore the impact of the number K of split vectors, we conduct the parameter experiment on Problem 1: In a library, science books account for 20\% of the collection, story books account for 1/3 of the collection, and there are 500 fewer science books than story books. How many total books are there in the library?
Graph2Tree: / 500 -20% (1/3) EEH-G2T: / 500 -(1/3) 20% Problem 2: Alan produced 648 machine parts in 8 hours , Ben produced 72 machine parts in 4 hours. How many more parts does Alan produce per hour than Ben? the Math23K valid set by varying the split number K from 0 to 5. As shown in Table 4, when the number K increases from 0 to 2, noticeable improvements are remarked on answer accuracy. These result once again confirms the effectiveness of the split attention mechanism because it allows the model to pay attention to different parts of the input problem. The performance starts to drop since K ≥ 3. This is probably because more splits means that the problem is split into more parts, so that the model can obtain more information. However, too many splits may break the problem into small fragments, leading to noise. We set the number K of split vectors to 2 in other experiments. Figure 5 lists two examples generated by Graph2Tree and our EEH-G2T model. In Problem 1, Graph2Tree missed the information that there are fewer science books than story books, and incorrectly generated "-20% (1/3)". With split attention mechanism, EEH-G2T can better capture this information from the enatire problem. In Problem 2, Graph2Tree incorrectly uses Ben's production speed to subtract Alan's production speed. With hierarchical graph encoder, EEH-G2T can build long-range relations across sentences and therefore generate correct results.

Related Work
Math Word Problem Solving: Solving math word problems has long been a very popular task and various methods have been proposed in the past few years (Ling et al., 2017;Wang et al., 2017Wang et al., , 2018. Previous methods usually treated the math word problem as a sequence, and use the same linear encoder to encode math word problems (Liu et al., 2019;Xie and Sun, 2019). Recently, many works that treat math word problems as graphs have shown better performance. Zhang et al. (2020b) connects each number in the problem with nearby nouns to enrich the problem representations.  connects words that belong to the same category in the external knowledge base to capture common sense information. Li et al. (2020) construct an input graph from both the math problem and its corresponding dependency tree to incorporate structural information. However, these methods only capture the local neighbor information of nodes as additional features to enrich the problem representations and ignore the long-range relations across sentences.
In this paper, we propose an edge-enhanced hierarchical graph encoder that captures both the local relations between words within a sentence and the long-range relations between words across sentences. To further guide the decoder to pay attention to different parts of the entire input problem, we propose a split attention mechanism. Graph Neural Networks: Many works on graph neural networks (GNNs) have been applied to a variety of tasks in recent years, such as node classification (Veličković et al., 2018;Klicpera et al., 2019), relation extraction Sahu et al., 2019), and code summarization (Zügner et al., 2021;Liu et al., 2021). Sahu et al.
(2019) proposed a labeled edge graph convolutional neural network model on a document-level graph for inter-sentence relation extraction. (Cui et al., 2020) simultaneously exploits syntactic structure and typed dependency labels to improve neural event detection. Inspired by such works, we also leverage edge label information to enrich the problem representations.

Conclusion
In this study, we proposed a novel edge-enhanced hierarchical graph-to-tree model called EEH-G2T for the math word problem solving task. We used an edge-enhanced hierarchical graph encoder that updates the graph nodes in two steps, namely sentence-level aggregation and problem-level aggregation. Additionally, edge label information was incorporated into the model to enrich the problem representations. We proposed a split attention mechanism to guide the decoder to pay attention to different parts of the entire input problem during generation. Experimental results confirmed that the proposed model, EEH-G2T, outperformed other state-of-the-art models.


Modeling Global Semantics for Question Answering over Knowledge Bases

Semantic parsing, as an important approach to question answering over knowledge bases (KBQA), transforms a question into the complete query graph for further generating the correct logical query. Existing semantic parsing approaches mainly focus on relations matching with paying less attention to the underlying internal structure of questions (e.g., the dependencies and relations between all entities in a question) to select the query graph. In this paper, we present a relational graph convolutional network (RGCN)-based model gRGCN for semantic parsing in KBQA. gRGCN extracts the global semantics of questions and their corresponding query graphs, including structure semantics via RGCN and relational semantics (label representation of relations between entities) via a hierarchical relation attention mechanism. Experiments evaluated on benchmarks show that our model outperforms off-the-shelf models.

Introduction
Semantic parsing [BC+13; YC+15] constructs a semantic parsing tree or equivalent query structure (called query graph [LL+18]) that represents the semantics of questions. Semantic parsing based approaches effectively transform questions into logical queries where the reliability of logical querying can ensure the correctness of answering questions. The success of semantics parsing lies in representing the semantics of questions in a syntactic way so that it can better capture the intention of users [HZZ18].
Most existing semantic parsing approaches in question answering over knowledge bases (KBQA) focus on capturing the semantics of questions and query graphs. Some "common" relations occurring in both questions and query graphs are taken as core relations for measuring similarity together with some manual features [YC+15;BD+16]. Another approach to detecting individual relation is presented in [YY+17] to improve the performance of matching questions with query graphs where each relation is represented by integrating its word-level and relation-level representations. [LL+18] extends [YY+17] by improving the representation of questions with answering more complex questions. [SG18] enriches the semantics of all entities via all relations during the learning process by Gated Graph Neural Network [LT+18] (GGNN).
However, the state-of-the-art semantic parsing approaches utilize relational semantics of query graphs with pay little attention to the structure semantics of a question. The structure semantics is an important part of the whole semantics of questions (e.g., Figure 1), especially in complex questions where the complexity of a question often relies on its complicated structure. As a result, existing works only consider relational semantics cannot always perform complex questions better. So it is necessary to pay more attention to the structure semantics of questions together with relational semantics when semantic parsing in KBQA. However, to model multirelational directed graphs with edge features remains an open problem. Therefore, it is not trivial to combine the two semantics of a question. In this paper, based on a RGCN [SK+18], we propose a novel model gRGCN for global semantic parsing of KBQA. In gRGCN, we apply RGCN to extract structure semantics of query graphs by utilizing its capability of learning the better task-specific embeddings of multi-relational graphs. gRGCN focuses on extracting global semantics of both query graphs and relations. The main contributions are summarized as: • We propose a global semantic fusion method for structure semantics of query graphs extracted in RGCN integrated with relational semantics via enhanced finegrained relations (word-level and relation-level representation) learning. • We introduce a hierarchical attention mechanism to represent word-level relations, which can discover latent implicit meaning and remove ambiguity in words. • We introduce a syntactic-sequence-combined representation to encode questions and relation-attention-based RGCN layer to strengthen structure semantics.
In this section, we introduce our gRGCN model for global semantic parsing in KBQA, and the overview framework is shown in Figure 2. Our gRGCN model consists of three modules, namely, question representation encoder, structure semantics extractor, and relational semantics extractor.
• Question Representation Encoder transforms all questions input into their syntactic dependency tree as input of RGCN and then encodes the representations of all questions in RGCN with combining the sequence of words. The module is used to provide the condition of calculating the similarity of a question with its candidate query graphs together with the fused semantics of structure semantics and relational semantics.
• Structure Semantics Extractor embeds query graphs as a whole into a semantic space. The module is used to mainly extract the semantics of the whole structure of query graphs. In this module, we present a relationattention-based RGCN layer for extracting global semantics to be fused with relational semantics extracted in the last module.
• Relational Semantics Extractor embeds relations into a semantic space. The module is used to mainly extract the semantics of relations of query graphs left in the global semantics extractor. In this module, we present a hierarchical relational attention mechanism to reduce the noise of word-level relations via WordNet [M95].

Our Approach
In this section, we introduce our approach in the followings.

Query Graph Generation
We convert a question to query graphs further transformed into SPARQL queries for answering on KB. A query graph G is a directed graph with labeled nodes and typed directed edges. All vertexes of G are divided into three categories: question variable (?q), intermediate variables(v), and KB entities. A ?q-node represents the answer to a question. A vnode is either an unknown entity or an unknown value. An edge represents a relation between two vertexes. In this paper, we improve the candidate graph generation method based on an heuristic algorithm [SK+18] by further considering five kinds of semantic constraints: entity, type, temporal(explicit and inexplicit time), order, and compare.

Question Representation Encoding
This module encodes the syntactic structure of a question via RGCN with combining with the sequence of all words occurring in the question to a final vector as the representations of the question.
Given a question q = (w 1 , . . . , w n ), the syntactic dependency tree (a graph structure) of q, denoted as G q , is of form (V q , E q ) where V q = {w 1 , . . . , w n } (a vertex set) is a set of words and E q ⊆ V q × V q (a edge set) is a set of dependencyrelation over {w 1 , . . . , w n }. Edges are classified into two classes: self-loop and Head to dependent.
Let W glove ∈ R |V |×d be the word embedding matrix where each row vector represents the embedding of a word, d is the dimension of embedding. For each vertex w i ∈ V q , − → h wi is assigned to the corresponding vertex w i as its embedding in V q (i = 1, 2, . . . , n).
Firstly, we initialize the embedding of V q via its all vertexes' embedding and compute the average of word embeddings as − → E avg . Secondly, given the intial embedding of wn }, we apply RGCN encoder to generate its hidden representation. In RGCN, the forward-pass update of each vertex w i in V q is formalized in the following: Here l is a layer, N r wi is the set of all r-neighbors of w i in G q . Note that W 0 and W v are weighted matrixes to be learned.
To access both sequence and syntactic information, we concatenate the word embedding of q and the output of RGCN layers to calculate the final result. The attention weight of the j-th token (i.e., a j ) is calculated based on the following formula: let M is a weight matrix, Finally, we present a fully-connected layer and the ReLU non-linearity to obtain the final representation h q of question q in the following equation:

Structure Semantics Extracting
This module computes the representation of the structure of a query graph. We first formalize query graphs.
Let V e be a set of entites and V r be a set of relations. A query graph G on V e and V r is a quad of (N G , R G , λ, δ) where N G is the set of vertexes, R G is the set of edges, λ : N G → V e assigns each vertex to an entity, and δ : R G → V r assigns each edge to a relation.
Firstly, we initialize hidden states vi for node v i by calculating them in relation-attention-based RGCN layer in the following way: Here l is a layer, N r vi is the set of all r-neighbors of v i in G. Note that W 0 and W v are weighted matrixes to be learned. a r is the attention weight of the edge r to give high weight to relations more relevant to the question in query graphs : Finally, we obtain − → h structure as the structure semantic representation of G by taking the representation of answer node.

Relational Semantics Extracting
To utilize relational semantics both questions and query graphs, we compute the representation of all relations in word-level and relation-level.
Firstly, we define a relational embedding matrix as follows: Given a query graph G = (N G , R G , λ, δ) on V e and V r , we define relation-level relations (e.g. "posistion held") in G, denoted by R whole , as a sequence of vectors as follows: let λ(R G ) = {r 1 , . . . , r n }, R whole 1:n We define word-level relation R word , as a sequence of vectors by applying W glove ∈ R |V |×d to map each word w ij in r i to its word embedding − → w ij as follows: R word occurring in r i (e.g."posistion", "held").
There is some unavoidable noise of fine-grained relations. For instance, for relation type "be subject to," its word-level word may lose the global relation information, as "subject" may have different meanings shown in Figure 4.
To reduce noise, we introduce an external linguistic knowledge WordNet [M95], where a word possibly has multiple senses, and a sense consists of several lemmas.
The vector of sense − → w ijk is defined as follows: The vector of word w ij is defined as follows: Then, we obtain the fine-grained relations embedding of G, denoted by R fine . Based on fine-grained word embedding of a relation r i , we define a vector as follows: We employ max pooling over the R fine to get the final relational semantics − → h relational . Finally, we present a linear combination to fuse structure and relational semantics via ReLU as the global semantics: In this section, we evaluate our approach on the following experiments: an overall contrast experiment with baselines and ablation study experiments of our three different modules.

Experiments Setup
Knowledge Bases We select two representive KBs: • Wikidata: A collaborative KB developed by [VK14] contains more than 40 million entities and 350 million relation instances. We use the full Wikidata dump 1 and host it with Virtuoso engine 2 . • FB2M: The KB collected by [BU+15], as a subset of Freebase, consists of 2 million entities and 10 million triple facts. FB2M is a famous KB for creating many QA datasets particularly simple question datasets.

QA Datasets
We select four popular datasets as follows: • ComplexQuestion (CompQ): The dataset consisting of 2,100 complex questions is developed by [BD+16] to provide questions with structure and expression diversity. To support answering over Wikidata [VK14], we slightly revise it by mapping answers to Wikidata answer IDs instead of Freebase IDs since Freebase was discontinued and is no longer up-to-date, including unavailability of APIs and new dumps [SG18]. • WebQSP-WD (WebQSPS): The dataset collected by [SG18] contains 712 real complex questions (in total 3913). WebQSPS is a corrected version of the common benchmark WebQSP [BC+13] data set for supporting Wikidata. • QALD-7: The small dataset consisting of 42 complex questions and 58 simple questions collected by [UN+17] to be mainly used to test KBQA models. QALD-7 is specially designed for the KBQA task over Wikidata. • SimpleQuestion (SimpQ): The dataset developed by [BU+15], as a popular benchmark of KBQA, contains over 100K questions w.r.t. FB2M. To evaluate the generalization ability of our model, we additionally use SimpQ in our complementary experiment.
Implementation Details In training, we adopt hinge loss which are applied in [LL+18;SG18]. Formally, let q be a question and C be the query graph set of q where C contains all positive graph g + and negative graph g − of q. L = max g∈C (0, (λ − cos( q, g + ) + cos( q, g − ))).
In our experiments, We use S-MART [YC15] as our entity linking tool, GloVe [PSM14] word vectors with dimensions of 100 is employed to initializing word embeddings and Adam optimizer [KB15] is applied to train the model with a batch size of 64 at each epoch. Moreover, we design a multiple-layer RGCN with a fully-connected layer with dropout=0.2 to calculate the representation of questions and the structure of query graphs (three-layer for questions and two layers for graphs). Finally, SpaCy 3 is used to parse syntactic dependency, and Deep Graph Library (DGL 4 ) is used to transfer query graphs into DGL graph objects.

Baselines
We introduce four popular models and one variation of gRGCN as baselines as follows: • STAGG (2015) [YC+15]: The model scores query graphs by some manual features and the representation of the core relation. It's a re-implemented by [SG18]. HZZ18]. Since their codes are not accessible, we will discuss them in the related works.

Overall Results of Our Approach
For evaluating our approach on complex questions, we select Wikidata as KB, CompQ, WebQSPS, and QALD-7 as datasets and precision, recall, and F1-score as metrics.
The experimental results are shown in Table 1, where we take the average results of all questions in a dataset as the final result. Note that our results are different from those original results released in baselines over Freebase.
By Table 1, we show that gRGCN outperforms all datasets and all metrics.

Robustness of Our Approach
Simple questions still contain a little structural information, such as the linear order of the subject entity and the object entity. We complementary evaluate our approach to simple questions to analyze its robustness. This experiment selects FB2M as KB, SimpQ as dataset, and six popular baselines. By the experimental results shown in Table 2, our approach

Ablation Study
In this subsection, we will pay attention to analyze the effectiveness of the proposed question representation and the proposed query graph representation in our model. For the ablation study, we use the F1 score as our metrics and perform experiments on CompQ, WebQSPS, and QALD-7 w.r.t. complex questions. Question Representation To analyze the effectiveness of our proposed question representation encoder, this experiment compares gRGCN to gRGCN with substituting the question encoder in each baseline for our encoder.
The results are shown in Table 3, where the column of QR of Baselines is gRGCN equipping with the corresponding question encoder and gRGCN − denote a variant of gRGCN without concatenating question sequences. We use gRGCN − to analyze the effectiveness of our proposed question encoder further, only considering those information of questions also considered in baselines fairly. (2018) with a 1.3%, 6.9%, and 1.1% improvement on three datasets. • Thirdly, the question sequence is useful to improve the performance question presentation. Specifically, gRGCN betters gRGCN − with a 1.0%, 5.4%, and 1.0% improvement on three datasets. Graph Representation To analyze the effectiveness of our proposed graph representation encoder, we consider two types of relations: fine-grained relation (f-g) and wordnet, two types of structures: attention and non-attention (non-att). Note that gRGCN considers all relations and structures.
The experimental results on the three datasets are shown in Table 4, where there are 18 cases, including 6 cases without structure. • Firstly, the structure of query graphs is verified to improve the performance of graph presentation without considering structure. Specifically, non-attention achieve 24.4%, 18.8%, 10.3% improvement on three datasets, and even when further considering wordnetrelation, it still performs with a 19.4%, 8.3%, 8.4% improvement. • Secondly, the wordnet-relation of query graphs is verified to improve the performance graph presentation without considering the wordnet-relation. Specifically, wordnet-relation performs with a 3.5%, 12.4%, 10.7% improvement on three datasets, and even when further considering attention-structure, it still performs with a 3.5%, 12.3%, 3.3% improvement. • Thirdly, the attention-structure of query graphs is verified to improve the performance graph presentation without considering the attention-structure. Specifically, attention-structure performs with a 24.4%, 18.8%, 10.3% improvement on three datasets, and even when further considering wordnet-relation, it still performs with a 19.4%, 8.3%, 8.4% improvement. Therefore, we can conclude that the structure presented in our graph representation as a global semantics is useful to improve the performance question presentation as well as wordnet-relation.

Error Analysis
We randomly analyze the major causes of errors on 100 questions, which returned incorrect answers.
Semantic ambiguity and complexity (42%): Due to the limitation of semantic graph generation, we can't generate graph space for some question since their complexity and semantic ambiguity.
Correct graphs scored low (16%): This type of error occurred when the model failed to extract the global semantics of questions and graphs. Although the correct graphs existed in the candidate set, we failed to select it.
Entity linking error (9%): This error occurred due to the failure to extract the appropriate entities from the given question. And subsequently, we generate incorrect semantic graphs. We could correct questions by replacing the wrong entities.
Dateset and KB error (33%): This error occurred since the incompatibility between wikidata and Freebase ID in datasets or the defects of datasets. The test datasets contain many open question whose answers may be partially or completely unstored in Wikidata.

Related Works
The most popular approaches proposed for the KBQA task can be roughly classified into two categories: semantic parsing and information retrieval. Recently, neural networks (NN) based approaches have shown great performance on KBQA. Different from [CX+17] and [AY+17] tried to extract questions intention by a large number of templates automatically learned from KB and QA corpora, SP+NN employed neural network to encode the semantics of questions and query graphs, and then select the correct query graphs of given questions in the candidate set for querying later [BD+16; LL+18; HZZ18]. [LL+18] encoded multiple relations into a uniform query graph to capture the fined-grained relations. [SG18] used GGNN to enrich the semantics of all entities with tackling the limited complex questions. Differently, our approach integrates both structure and enhanced relational semantics of query graphs.
[HZZ18] [DH+19] pay more attention to query graph generation and use an SVM rank classifier and a combinational function to rank candidate graphs respectively, which is not an encode-and-compare framework as our model. [CSH18] uses an end-to-end query graph generation process via an RNN model, and it aims to search the best action sequence. However, we are focus on learning global semantics of the query graph. Information Retrieval Information retrieval (IR) based approaches retrieve the candidate entities (as answers) from KB using semantic relation extraction [XR+16; DW+15; WH+19; YR+16; SD+18; LWJ19].Those approaches map answers and questions into the same embedding space, where we could retrieve the answers independent of any grammar, lexicon, or other semantic structure. Our approach belongs to the SP-based method and encoded semantic information of question into a query graph for querying on KB.

Conclusions
In this paper, we propose an RGCN-based model for semantic parsing of KBQA with extracting global semantics to maximize the performance of question learning. Our approach pays more attention to structure semantics of query graphs extracted by RGCN and enhanced relational semantics in KBQA. In this sense, our approach provides a new way to capture the intention of questions better. In this paper, we generalize our model to support complex questions, such as comparing questions. In future work, we are interested in extending our model for more complex practical questions.


DL-MRI: A Unified Framework of Deep Learning-Based MRI Super Resolution

Magnetic resonance imaging (MRI) is widely used in the detection and diagnosis of diseases. High-resolution MR images will help doctors to locate lesions and diagnose diseases. However, the acquisition of high-resolution MR images requires high magnetic field intensity and long scanning time, which will bring discomfort to patients and easily introduce motion artifacts, resulting in image quality degradation. Therefore, the resolution of hardware imaging has reached its limit. Based on this situation, a unified framework based on deep learning super resolution is proposed to transfer state-of-the-art deep learning methods of natural images to MRI super resolution. Compared with the traditional image super-resolution method, the deep learning super-resolution method has stronger feature extraction and characterization ability, can learn prior knowledge from a large number of sample data, and has a more stable and excellent image reconstruction effect. We propose a unified framework of deep learning -based MRI super resolution, which has five current deep learning methods with the best super-resolution effect. In addition, a high-low resolution MR image dataset with the scales of ×2, ×3, and ×4 was constructed, covering 4 parts of the skull, knee, breast, and head and neck. Experimental results show that the proposed unified framework of deep learning super resolution has a better reconstruction effect on the data than traditional methods and provides a standard dataset and experimental benchmark for the application of deep learning super resolution in MR images.

Introduction
MRI [1] is a type of tomography, which uses magnetic resonance to obtain electromagnetic signals from the human organ tissue and reconstruct human information about the structure of human organs. MRI has been used in imaging diagnosis of various systems throughout the body, including craniocerebral [2], spinal cord [3], large heart blood vessels [4], joint bones [5], and soft tissues and pelvis [6]. Highresolution MR images have richer structural details, which is helpful for doctors to locate the lesions and diagnose the disease. e acquisition of MR high-resolution image needs to increase the magnetic field intensity and pulse radiation time, high intensity magnetic field, and ultra-long pulse radiation not only bring bad experience to patients but also produce image artifacts due to patients' movement, thus affecting the quality of imaging. erefore, the software method for MR image super resolution has great significance, and it can improve the MR image resolution without causing harm to the human body.
Super resolution is to restore high-frequency detail from low-resolution image to improve image resolution. e simplest method is to use interpolation to improve the image resolution, such as bicubic interpolation [7] and nearest neighbor interpolation [8]. However, the interpolation method is not in essence to increase the image information, so it cannot recover the image high-frequency information. Subsequently, people put forward the super-resolution method based on spatial domain constraints because this algorithm has wide applicability and strong prior constraint capability. In this respect, algorithms include reverse iterative projection method [9][10][11], statistical method based on maximum posterior probability [12][13][14], nonuniform sample interpolation method [15,16], and convex set projection method [17]. ese algorithms make full use of spatial correlation of data, introduce fuzzy, point diffusion, and other degradation parameters into image degradation model, and cover global motion and local motion. However, when dealing with the super resolution of multiframe images, the quality of reconstructed images declines rapidly as the super-resolution ratio increases or the number of available input images decreases. Under such circumstances, the reconstructed results will appear too smooth and lack important high-frequency details. e learn-based super-resolution method is different from the image priori knowledge acquired under various assumptions. It directly learns the image priori knowledge from a large number of samples. e learning-based image super-resolution methods mainly include dictionary learning [18] and deep learning [19]. In dictionary learning, a high-resolution image block can utilize a high-resolution dictionary sparse representation, and the sparse coefficient can be obtained from the sparse representation of the lowresolution dictionary of the corresponding low-resolution image block. However, the super-resolution method based on sparse representation needs to solve the sparse representation of the super-complete dictionary. When the dictionary size or reconstructed image size is large, the computational time complexity is still very high, which still has a considerable gap with the real-time application. e super-resolution method based on deep learning has been validated in natural images. e network used by NISR mainly includes three categories: feedforward deep networks, feedback deep networks, and generative adversarial networks. DBPN [20] belongs to the feedforward deep network, which provides an error feedback and interdependent modules, which represent image degradation and high-resolution, making characteristics of the sampling phase are connected to improve the SR result. RDN [21] belongs to the feedback deep network. It proposes a residual dense block (RDB) and uses the densely connected convolutional layer to extract rich local features. SRFBN [22] belongs to the feedback deep network. is type of model implements this feedback method by using hidden states in constrained RNNs. EDSR [23] also belongs to the feedback deep network. Compared with SRResNet in structure, EDSR removes the batch normalization (BN) operation. SRGAN [24] is a generative adversarial network. It takes the residual network as the main network of feature extraction and adds the perceptive loss function. Alternate training generates network and discriminant network. e three major types of representative networks have made good contributions to super-resolution reconstruction of natural images.
At present, some deep learning methods are also applied to MR image super resolution. Chen et al. [25] apply DenseNet to brain MRI image super resolution, Chen et al. [26] propose a novel 3D CNN architecture, namely, mDCSRN, which provides appealing sharp SR images with rich texture details that are highly comparable with the referenced HR images.
We compared and analyzed bicubic, RDN, EDSR, SRGAN, DBPN, and SRFBN, algorithms on the constructed MR image dataset, covering traditional super-resolution learning and a batch of deep learning networks with excellent super-resolution performance. As can be seen from the experimental results, the super-resolution effect of the deep learning network on the MR image performs well, and the super-resolution effect of different parts of the same algorithm fluctuates greatly.
Our contributions include the following three points: (1) We proposed a unified framework of deep learning-based MRI super resolution and carried out an experimental analysis of the traditional super-resolution methods and deep learning super-resolution methods on the MRI dataset. (2) We build a dataset for super resolution of MR images, including 4300 high-low resolution pairs. It involves the skull, breasts, knees, and head and neck. (3) We performed statistical analysis on the difficulty of MR images in different parts and provided suggestions for MR images in different parts.

Image Degradation.
Because of tissue and organ movement in the process of imaging, the existence of the noise and artifacts makes image or part of the image blur, or resolution is not enough, so by the imaging model [27,28], the low-resolution image is the high-resolution image by ideal after deformation, fuzzy, blood sampling, such as noise adding income after operation, and process of image degradation process. Figure 1 shows the degradation process of high-resolution images. X is an undergraded high-resolution image matrix with an ideal band limit not lower than Nyquist sampling frequency. Let x be the column vector of X. After the degradation process of x, such as deformation matrix M k , fuzzy matrix B k , and mass reduction sampling matrix D k , noise matrix n k is added to obtain the lowresolution image y k . e mathematical model formula of image degradation is shown in Figure 1: Formula (1) can also be expressed as where H represents the image degradation matrix, Y represents low-resolution images, and X represents ground truth high-resolution images. e purpose of image super resolution is to find the inverse of the degenerate matrix H.

A Unified Framework of Deep Learning-Based MRI Super
Resolution. We propose a unified framework of deep learning-based MRI super resolution. e aim of this framework is to apply the deep learning network for natural image super resolution to MR images. We have integrated five state-of-the-art deep learning networks, respectively, Deep Backprojection Networks For Super Resolution (DBPN), Residual Dense Network (RDN), Feedback Network for Image Super Resolution (SRFBN), Photo-Realistic Single Image Super-Resolution Using a Generative Adversarial Network (SRGAN), and Enhanced Deep Residual Networks for Single Image Super Resolution (EDSR). e unified framework of deep learning-based MRI super resolution is shown in Figure 2.
DBPN: the structure of DBPN is shown in Figure 2(a). It consists of initial feature extraction, projection, and reconstruction.conv(f, n) represents the convolution layer, n represents the number of filters, and f represents the filter size.
Initial feature extraction: we use 3 * 3 convolution to extract features from low-resolution images. en, we use 1 * 1 convolution to achieve feature reduction. n 0 is the number of filters used in the initial LR feature extraction phase. n R is the number of filters used in each projection unit.
Backprojection stages: from Figure 2(A), the main component of the DBPN structure is the projection unit. As part of training the SR system, it maps LR features to HR features, or maps HR features to LR features in two opposite mapping relationships. e two mapping relationships are Residual : Residualup sampling : Output feature map : e above formula * represents a convolution operation, ↑s stands for up sampling operation, ↓s stands for down sampling operation, and p t , g t , q t is the (de) convolutional layer of the stage t, which learns the mapping of low-resolution feature maps to high-resolution feature maps.
Reconstruction: the feature diagrams obtained by each reflection unit are connected to form [H 1 , H 2 , . . . , H t ]. And, the combined features are transformed into reconstructed images by 3 * 3 convolution.
RDN: it can be seen from (B) Figure 2 that RDN network is composed of SFENet, RDBs, DFF, and UPNet. SFENet is composed of two convolutional layers for extracting shallow features. RDBs module is composed of the residual block and the dense block. is operation facilitates the training of RDB modules with larger growth rates. DFF module consists of global feature fusion and global residual learning, which realizes the global extraction of the characteristics of each layer. UPNet implements image upsampling.
SRFBN: we can see from (C) in Figure 2 that the network is mainly an improvement of a feedback mechanism based on the DRCN large framework, which is equivalent to turning the weight-sharing layer in DRCN into a weightsharing module and add a skip connection. It consists of three parts: feature extraction, weight-sharing module, and learning strategy.
(1) Feature extraction: this network is mainly for shallow feature extraction, that is, shallow feature extraction , and the corresponding intermediate supervision output e truth value of the intermediate supervision will be selected according to the difficulty of the task, such as a single bicubic downsampling degradation, and all truth values are the same; for BD (bicubic + blur) degradation, the first two intermediate supervised outputs use truth values with Gaussian blur, and the subsequent intermediate supervises use truth values without Gaussian blur.
SRGAN: it can be seen from Figure 2(D) that SRGAN is composed of the generator, discriminator, and loss function. e generator is composed of multiple residual blocks in the generated network part (SRResNet). Each residual block is composed of two 3 × 3 convolution layers, the batch normalization layer (BN), PReLU as the activation functions are the latter items of the convolution layer, and two subpixel convolution layers. e discriminator consists of 8 convolutional layers in the discriminating network part, and LeakyReLU is selected as the activation function. e role of the discriminator is to determine the difference between the high-resolution image output by the generator and the real high-resolution image. e loss function in SRGAN is more special than other networks. It uses two loss functions: G loss and D loss. G loss and D loss can be expressed as It can be seen from the above formula that l SR X is content loss and 10 − 3 l SR Gen is against loss. e losses of the two are EDSR: it can be seen from (E) in Figure 2 that it is similar to SRResnet, but the structure lacks a ReLU layer and a batchnorm layer, mainly, because the batch normalization layer normalizes the function. erefore, by normalizing the functions, the scope flexibility of the network can be eliminated. Because the structure adopted by this method is too deep, the instability of the training process can easily cause numerical instability. To solve this problem, the model uses residual scaling to deal with it, by which the last convolutional layer output of the residual module is multiplied by 0.1.

Dataset for Training.
We collected the MR image data of the four body parts of the head and neck, breast, bones, and skull on the open source website and used the bicubic downsampling method to construct high-low resolution MR image pairs of different scales, including ×2, ×3, and ×4, and divided the training set, validation set, and test set according to 7 : 2 : 1.

Collection and Quality Filtering of Raw Datasets.
Our data comes from open source MR image data, including NYU fastMRI Dataset [29], IXI Dataset [30], TCIA MRI Dataset [31], and mridata.org [32]. Because different datasets include different parts, some data contain only one human body part. For example, NYU fastMRI dataset contains the skull and knee, IXI dataset contains the skull only, and TCIA MRI dataset contains the breast, skull, head and neck, and bladder. erefore, this dataset is mainly based on the MRI image data downloaded from TCIA. e skull data also comes from NYU fastMRI dataset and IXI dataset; the knee parts are from mridata.org and NYU fastMRI dataset.  MR image data is stored in DICOM format, which is an international standard for medical images. We used Python's third-party library pydicom to parse the obtained raw MR data. us, MR images of various organs are acquired. e MR image information of each part is shown in Table 1.
To reduce the impact caused by the signal-to-noise ratio, contrast, motion artifacts, and chemical artifacts of the image and in addition to considering the cost borne by the MRI equipment, we collect and use the mainstream magnetic field strength. Because we acquire data of different parts, according to different imaging standards of medical target organs, we obtain original images with different resolutions.
As shown in Table 1, we obtained a large amount of raw MR image data, but not all data are suitable for MR image super resolution. Unqualified data will reduce the effect of image super resolution. erefore, we conducted a quality assessment of the data obtained for each organ and proposed data that did not meet the requirements. We screened MR images using both manual and machine methods.
Firstly, according to the advice of professional doctors, we manually removed the MR image data with obvious quality problems. Secondly, the performance of deep learning algorithm is positively correlated with the quality and quantity of data. However, more samples do not mean better performance. Poor quality data will not help the deep learning training, but will reduce the quality of reconstructed images. In this paper, we used a method based on gray consistency and gradient combined to evaluate MR image quality. e number of filtered images is shown in Table 1.
e filtered data will be used as the training data of deep learning.

Training Set Generation.
Various types of deep learning networks need to be based on prior knowledge which is a pair of high-low resolution MR images. We adopt the downsampling method based on the bicubic method. Downsampling based on cubic interpolation first requires the construction of a bicubic function. Its expression is Secondly, to treat the interpolated image points, take the nearby 4 × 4 area. Interpolate as follows.
irdly, the image obtained by upsampling is processed by downsampling, and the corresponding downsampling is e HR is the original image. g(x, y) is the LR image obtained by downsampling.
In order to simulate the real MR image acquisition process, we sampled HR images down and added Gaussian noise to obtain corresponding LR images. e downsampling method based on LR plus noise is to add the original image without noise and add 5% Gaussian noise to the LR image obtained after downsampling: Among them, 5%GN represents 5% of Gaussian noise. LR s + 5%GN represents low-resolution images of s size corresponding to this method.
We use the method of direct downsampling of the original image based on cubic interpolation to generate MR-SR high-low resolution pairs as input to the deep learning network. We mainly use the bicubic downsampling to implement the HR-> LR process. e downsampling scales of the dataset are ×2, ×3, and ×4. e generated multiscale MR image training set is shown in Figure 3.

Experimental Setup.
During the training process, the hardware configuration we used is Core i9-9900K processor and dual-pass 1080ti graphics card, 32G memory. e software configuration is super-resolution network training using pytorch framework. We set the parameters of the 5 types of networks and iterate 200 rounds. Set the learning rate to 0.01, and its network parameter setting table is shown in Table 2. We found that the learning rates of the five models were fine-tuned within a certain range, and they all reached convergence before 200 rounds of training iterations. After 200 rounds of training, the losses of the five models hardly changed. For better comparative analysis, we set the same number of iterations.

Evaluation Index.
In this paper, PSNR and SSIM are used to comprehensively measure the effect of MR image super-resolution reconstruction.
PSNR: this evaluation standard is the most commonly used. e higher the PSNR, the better the reconstructed image quality. e calculation formula is as follows: where X stands for the high-resolution image, Y represents the reconstructed image, M and N, respectively, represent the height and width of the image, and L represents the largest gray value in the gray level, where L � 255. SSIM: this evaluation indicates the degree of structural similarity between the reconstructed image and the original image.
e larger the value, the more similar the reconstructed image and the original image and the better the reconstruction effect. e calculation formula is    where l(X, Y) stands for the brightness contrast operator, c(X, Y) stands for the contrast operator, s(X, Y)stands for the structure contrast operator, and α, β, c > 0 is used to adjust the weights of the three operators. e calculation formulas are as follows. Brightness contrast operator: Contrast operator: Structure contrast operator: where μ represents the average value of the image, that is, the average brightness of the image, σ represents the standard deviation of the signal and estimates the contrast of the signal, C represents the normalization factor that overcomes zero, and K is a constant. e mean μ and variance σ are calculated as

Experimental Result and Analysis.
After training of various deep network models, the results obtained by each model in our MR dataset have obvious manifestations. As can be seen from Figure 4 and Table 3, the SRGAN algorithm is richer in visual texture. e SRFBN algorithm is better at the PSNR and SSIM indicators. We can draw this conclusion. First of all, for the same network, the SR effect of different organ parts is significantly different, which is mainly caused by the original resolution of each organ, the magnetic field intensity during the acquisition process, and the proportion of free water and bound water in the organ. Secondly, we can customize a network specifically adapted to this organ for different parts. For example, in Table 3  Journal of Healthcare Engineering obviously has a better PSNR/SSIM of 38.05/0.9565 in the skull organs than other networks, indicating that different target organs can be customized to design super-resolution networks.
We can see from the table that the PSNR/SSIM index between the traditional bicubic algorithm and the deep network is particularly different, which is basically between 3.61-12.59/0.1896-0.2951, which also shows that the deep network has better image super-resolution reconstruction effect on MR image super resolution. It can be seen through experiments that directly applying deep learning networks can also achieve certain effects, indicating that deep networks have a certain role in MR image super resolution and are better than traditional methods. However, there is still a gap with the super-resolution effect of natural images. e main reason is that the natural image and MR image have different imaging mechanisms. erefore, it is necessary to combine the characteristics of MR images of different human parts to design a more targeted deep super-resolution network of MR images.
We made statistics on the number of parameters and calculation amount of the five deep learning methods, as shown in Table 4.
It can be seen from Table 4 that the model parameters and calculation amount of different networks differ greatly. Combined with the super-resolution performance of the five methods in Table 3, the SRFBN method not only has better super resolution effect but also has the least model size and calculation amount, which is more suitable for practical application.

Conclusion
We propose a unified framework of deep learning-based MRI super resolution. We have integrated five state-of-theart deep learning networks. Moreover, the deep learning method is experimentally verified on the self-built MR image dataset which covers the skull, knee, breast, and head and neck. rough data quality screening and analog imaging degradation, MR image dataset with certain scale and standard for image super resolution is formed. Compared with the traditional method, the deep learning method has better reconstruction performance on the data set. e reason of the difference of the super resolution of different organs is revealed from the structure level of each organ. We hope that our paper can provide data support for the application of deep learning networks in MR super resolution and inspire future research on MR image super resolution.
Data Availability e two popular MRI datasets in this paper, fastMRI Dataset and IXI Dataset can be freely downloaded from https:// fastmri.org/and http://www.brain-development.org/.

Conflicts of Interest
e authors declare that they have no conflicts of interest.