Original: R UL E: N EURAL -S YMBOLIC K NOWLEDGE G RAPH R EASONING WITH R ULE E MBEDDING
Revised: R UL E: N EURAL -S YMBOLIC K NOWLEDGE G RAPH R EASONING WITH R ULE E MBEDDING

Original: Anonymous authors
Revised: Anonymous authors

Original: Paper under double-blind review
Revised: Paper under double-blind review

Original: A BSTRACT
Revised: A BSTRACT

Original: Knowledge graph (KG) reasoning is an important problem for knowledge graphs.
Revised: Knowledge graph (KG) reasoning is an important problem for knowledge graphs.

Original: It predicts missing links by reasoning on existing facts.
Revised: It predicts missing links by reasoning on existing facts.

Original: Knowledge graph embedding (KGE) is one of the most popular methods to address this problem.
Revised: Knowledge graph embedding (KGE) is one of the most popular methods to address this problem.

Original: It embeds entities and relations into low-dimensional vectors and uses the learned entity/relation embeddings to predict missing facts.
Revised: It embeds entities and relations into low-dimensional vectors and uses the learned entity/relation embeddings to predict missing facts.

Original: However, KGE only uses zeroth-order (propositional) logic to encode existing triplets (e.g., “Alice is Bob’s wife.”); it is unable to leverage first-order (predicate) logic to represent generally applicable logical rules (e.g., “ ∀ x, y : x is y ’s wife → y is x ’s husband”).
Revised: However, KGE only uses zeroth-order (propositional) logic to encode existing triplets (e.g., “Alice is Bob’s wife.”); it is unable to leverage first-order (predicate) logic to represent generally applicable logical rules (e.g., “ ∀ x, y : x is y ’s wife → y is x ’s husband”).

Original: On the other hand, traditional rule-based KG reasoning methods usually rely on hard logical rule inference, making it brittle and hardly competitive with KGE.
Revised: On the other hand, traditional rule-based KG reasoning methods usually rely on hard logical rule inference, making it brittle and hardly competitive with KGE.

Original: In this paper, we propose RulE, a novel and principled framework to represent and model logical rules and triplets.
Revised: In this paper, we propose RulE, a novel and principled framework to represent and model logical rules and triplets.

Original: RulE jointly represents entities, relations and logical rules in a unified embedding space.
Revised: RulE jointly represents entities, relations and logical rules in a unified embedding space.

Original: By learning an embedding for each logical rule, RulE can perform logical rule inference in a soft way and give a confidence score to each grounded rule, similar to how KGE gives each triplet a confidence score.
Revised: By learning an embedding for each logical rule, RulE can perform logical rule inference in a soft way and give a confidence score to each grounded rule, similar to how KGE gives each triplet a confidence score.

Original: Compared to KGE alone, RulE allows injecting prior logical rule information into the embedding space, which improves the generalization of knowledge graph embedding.
Revised: Compared to KGE alone, RulE allows injecting prior logical rule information into the embedding space, which improves the generalization of knowledge graph embedding.

Original: Besides, the learned confidence scores of rules improve the logical rule inference process by softly controlling the contribution of each rule, which alleviates the brittleness of logic.
Revised: Besides, the learned confidence scores of rules improve the logical rule inference process by softly controlling the contribution of each rule, which alleviates the brittleness of logic.

Original: We evaluate our method with link prediction tasks.
Revised: We evaluate our method with link prediction tasks.

Original: Experimental results on multiple benchmark KGs demonstrate the effectiveness of RulE. 
Revised: Experimental results on multiple benchmark KGs demonstrate the effectiveness of RulE. https://github.com/XiaojuanTang/RulE

Original:  I NTRODUCTION
Revised:  I NTRODUCTION

Original: Knowledge graphs (KGs) usually store millions of real-world facts and are used in a variety of applications, such as recommender systems (Wang et al., 2018), question answering (Bordes et al., 2014) and information retrieval (Xiong et al., 2017).
Revised: Knowledge graphs (KGs) usually store millions of real-world facts and are used in a variety of applications, such as recommender systems (Wang et al., 2018), question answering (Bordes et al., 2014) and information retrieval (Xiong et al., 2017).

Original: Examples of knowledge graphs include Freebase (Bollacker et al., 2008), WordNet(Miller, 1995) and YAGO (Suchanek et al., 2007).
Revised: Examples of knowledge graphs include Freebase (Bollacker et al., 2008), WordNet(Miller, 1995) and YAGO (Suchanek et al., 2007).

Original: They represent entities as nodes and relations among the entities as edges.
Revised: They represent entities as nodes and relations among the entities as edges.

Original: Each edge encodes a fact in the form of a triplet ( head entity , relation , tail entity ) .
Revised: Each edge encodes a fact in the form of a triplet ( head entity , relation , tail entity ) .

Original: However, KGs are usually highly incomplete due to the limitedness of human knowledge and web corpora, as well as imperfect extraction algorithms.
Revised: However, KGs are usually highly incomplete due to the limitedness of human knowledge and web corpora, as well as imperfect extraction algorithms.

Original: Knowledge graph reasoning, which predicts missing facts by reasoning on existing facts, has thus become a popular research area in Artificial Intelligence.
Revised: Knowledge graph reasoning, which predicts missing facts by reasoning on existing facts, has thus become a popular research area in Artificial Intelligence.

Original: There are two prominent lines of work in this area: knowledge graph embedding (KGE), which embeds all entities and relations into vectors, and rule-based KG reasoning, which uses logical rules to infer new facts.
Revised: There are two prominent lines of work in this area: knowledge graph embedding (KGE), which embeds all entities and relations into vectors, and rule-based KG reasoning, which uses logical rules to infer new facts.

Original: Knowledge graph embedding (KGE) methods such as TransE (Bordes et al., 2013), ComplEx (Trouillon et al., 2016) and RotatE (Sun et al., 2019) have received significant attention due to their effectiveness and scalability.
Revised: Knowledge graph embedding (KGE) methods such as TransE (Bordes et al., 2013), ComplEx (Trouillon et al., 2016) and RotatE (Sun et al., 2019) have received significant attention due to their effectiveness and scalability.

Original: They embed entities and relations into low-dimensional vectors or matrices, preserving the inherent structure and latent semantic information.
Revised: They embed entities and relations into low-dimensional vectors or matrices, preserving the inherent structure and latent semantic information.

Original: By computing the score of each triplet in the continuous space, KGE effectively estimates the plausibility of unobserved triplets so that reasoning of missing facts becomes feasible.
Revised: By computing the score of each triplet in the continuous space, KGE effectively estimates the plausibility of unobserved triplets so that reasoning of missing facts becomes feasible.

Original: However, KGE only uses zeroth-order (propositional) logic to encode existing facts (e.g., “Alice is Bob’s wife.”).
Revised: However, KGE only uses zeroth-order (propositional) logic to encode existing facts (e.g., “Alice is Bob’s wife.”).

Original: It cannot leverage firstorder (predicate) logic, which uses the universal quantifier to represent generally applicable logicalrules. For instance, “ ∀ x, y : x is y ’s wife → y is x ’s husband” encodes one logical rule. Those rules are not specific to particular entities (e.g., Alice and Bob) but are generally applicable to all entities. 𝑒 ! ,𝑟 ! ,𝑒 " 𝑒 # ,𝑟 " ,𝑒 $ 𝑒 % ,𝑟 # ,𝑒 & … (𝑅 ! :
Revised: It cannot leverage firstorder (predicate) logic, which uses the universal quantifier to represent generally applicable logical 𝑒 ! ,𝑟 ! ,𝑒 " 𝑒 # ,𝑟 " ,𝑒 $ 𝑒 % ,𝑟 # ,𝑒 & … (𝑅 ! :

Original: r " ∧ 𝑟 # ⇒ 𝑟 ! )
Revised: r " ∧ 𝑟 # ⇒ 𝑟 ! )

Original: (𝑅 " :𝑟 $ ∧ r % ⇒ 𝑟 & ) (𝑅 # : r ’ ∧ r ( ∧ 𝑟 ) ⇒ 𝑟 !
Revised: (𝑅 " :𝑟 $ ∧ r % ⇒ 𝑟 & ) (𝑅 # : r ’ ∧ r ( ∧ 𝑟 ) ⇒ 𝑟 !

Original: Triplets
Revised: Triplets

Original: Logical rules e !
Revised: Logical rules e !

Original: 𝑒 " 𝑟 !
Revised: 𝑒 " 𝑟 !

Original: 𝑟 " 𝑟 # 𝑅 !
Revised: 𝑟 " 𝑟 # 𝑅 !

Original: Jointly training 
Revised: Jointly training rules.

Revised: For instance, “ ∀ x, y : x is y ’s wife → y is x ’s husband” encodes one logical rule.

Revised: Those rules are not specific to particular entities (e.g., Alice and Bob) but are generally applicable to all entities.

Original: Another limitation of current KGE is that it can only be applied to transductive scenarios, which means it is unable to answer queries ( h , r , t ) s if t is not contained in KG during the training.
Revised: Another limitation of current KGE is that it can only be applied to transductive scenarios, which means it is unable to answer queries ( h , r , t ) s if t is not contained in KG during the training.

Original: The other line of work, rule-based KG reasoning, in contrast, can be applied to both inductive and transductive settings, because rules are generally applicable to even unseen entities.
Revised: The other line of work, rule-based KG reasoning, in contrast, can be applied to both inductive and transductive settings, because rules are generally applicable to even unseen entities.

Original: Furthermore, unlike embedding-based methods, logical rules can achieve interpretable reasoning.
Revised: Furthermore, unlike embedding-based methods, logical rules can achieve interpretable reasoning.

Original: However, the brittleness of logical rules greatly harms prediction performance.
Revised: However, the brittleness of logical rules greatly harms prediction performance.

Original: Consider the logical rule ( x, work in , y )
Revised: Consider the logical rule ( x, work in , y )

Original: → ( x, live in , y ) as an example.
Revised: → ( x, live in , y ) as an example.

Original: It is mostly correct.
Revised: It is mostly correct.

Original: Yet, if somebody works in New
Revised: Yet, if somebody works in New

Original: York but lives in New Jersey, the rule will surely infer the wrong fact that he/she lives in New York.
Revised: York but lives in New Jersey, the rule will surely infer the wrong fact that he/she lives in New York.

Original: Considering that the aforementioned two lines of work can complement each other, addressing each other’s weaknesses with their own forte, it becomes imperative to study how to robustly integrate logical rules with KGE methods.
Revised: Considering that the aforementioned two lines of work can complement each other, addressing each other’s weaknesses with their own forte, it becomes imperative to study how to robustly integrate logical rules with KGE methods.

Original: If we view this integration against a broader backdrop, embeddingbased reasoning can be seen as a type of neural method, while rule-based reasoning can be seen as a type of symbolic method.
Revised: If we view this integration against a broader backdrop, embeddingbased reasoning can be seen as a type of neural method, while rule-based reasoning can be seen as a type of symbolic method.

Original: Neural-symbolic synthesis has also been a focus of Artificial Intelligence research in recent years (Parisotto et al., 2017;
Revised: Neural-symbolic synthesis has also been a focus of Artificial Intelligence research in recent years (Parisotto et al., 2017;

Original: Yi et al., 2018; Manhaeve et al., 2018;
Revised: Yi et al., 2018; Manhaeve et al., 2018;

Original: Xu et al., 2018; Hitzler, 2022).
Revised: Xu et al., 2018; Hitzler, 2022).

Original: Specifically, most of the existing work combining logical rules and KGE either uses logical rules to infer new facts as additional training data for KGE or directly converts some rules into regularization terms for specific KGE models (Guo et al., 2016;
Revised: Specifically, most of the existing work combining logical rules and KGE either uses logical rules to infer new facts as additional training data for KGE or directly converts some rules into regularization terms for specific KGE models (Guo et al., 2016;

Original: Rockt ¨ aschel et al., 2015; Demeester et al., 2016).
Revised: Rockt ¨ aschel et al., 2015; Demeester et al., 2016).

Original: For example, KALE (Guo et al., 2016) and RUGE (Guo et al., 2018) apply t-norm fuzzy logic to grounded rules to give a truth score for each inferred triplet and generate additional triplets for KGE training.
Revised: For example, KALE (Guo et al., 2016) and RUGE (Guo et al., 2018) apply t-norm fuzzy logic to grounded rules to give a truth score for each inferred triplet and generate additional triplets for KGE training.

Original: On the other hand, some other efforts do not ground rules to infer new triplets for training but rather inject logical rules via regularization terms on entity/relation embeddings during KGE training (Ding et al., 2018; Guo et al., 2020).
Revised: On the other hand, some other efforts do not ground rules to infer new triplets for training but rather inject logical rules via regularization terms on entity/relation embeddings during KGE training (Ding et al., 2018; Guo et al., 2020).

Original: They leverage logical rules merely to enhance KGE training without actually using logical rules to perform reasoning.
Revised: They leverage logical rules merely to enhance KGE training without actually using logical rules to perform reasoning.

Original: In other words, they are still restricted to the transductive setting and might lose the important information contained in explicit rules, leading to empirically worse performance than state-of-the-art methods.
Revised: In other words, they are still restricted to the transductive setting and might lose the important information contained in explicit rules, leading to empirically worse performance than state-of-the-art methods.

Original: To address the aforementioned limitations, we propose RulE , a novel and principled framework to combine KGE and logical rules in a unified scheme.
Revised: To address the aforementioned limitations, we propose RulE , a novel and principled framework to combine KGE and logical rules in a unified scheme.

Original: RulE stands for Rule Embedding.
Revised: RulE stands for Rule Embedding.

Original: We choose it as our method’s name to highlight that we are the first to jointly represent every entity, relation and logical rule in a unified embedding, as illustrated in Figure 1.
Revised: We choose it as our method’s name to highlight that we are the first to jointly represent every entity, relation and logical rule in a unified embedding, as illustrated in Figure 1.

Original: Given a KG and a set of logical rules, RulE assigns an embedding vector to each entity, relation, and logical rule, and defines respective mathematical operators between entities and relations as well as between relations and logical rules.
Revised: Given a KG and a set of logical rules, RulE assigns an embedding vector to each entity, relation, and logical rule, and defines respective mathematical operators between entities and relations as well as between relations and logical rules.

Original: By jointly optimizing embeddings in the same space, RulE allows injecting prior logical rule information into the embedding space, which improves the generalization of KGE.
Revised: By jointly optimizing embeddings in the same space, RulE allows injecting prior logical rule information into the embedding space, which improves the generalization of KGE.

Original: Additionally, by learning an embedding for each logical rule, RulE is able to perform logical rule inference in a soft way as well as give a confidence score to each grounded rule, similar to how KGE gives each triplet a confidence score.
Revised: Additionally, by learning an embedding for each logical rule, RulE is able to perform logical rule inference in a soft way as well as give a confidence score to each grounded rule, similar to how KGE gives each triplet a confidence score.

Original: The learned confidence scores can further improve the rule-based reasoning process by softly controlling the contribution of each rule, which alleviates the brittleness of logic.
Revised: The learned confidence scores can further improve the rule-based reasoning process by softly controlling the contribution of each rule, which alleviates the brittleness of logic.

Original: We evaluate RulE on link prediction tasks and show superior performance.
Revised: We evaluate RulE on link prediction tasks and show superior performance.

Original: It performs competitively with strong baselines on knowledge graph completion benchmarks WN18RR
Revised: It performs competitively with strong baselines on knowledge graph completion benchmarks WN18RR

Original: (Dettmers et al., 2018) and FB15K-237 (Toutanova & Chen, 2015), and obtains state-of-the-art performance on Kinship and
Revised: (Dettmers et al., 2018) and FB15K-237 (Toutanova & Chen, 2015), and obtains state-of-the-art performance on Kinship and

Original: UMLS (Kok & Domingos, 2007), two benchmark KGs for statistical relational learning.
Revised: UMLS (Kok & Domingos, 2007), two benchmark KGs for statistical relational learning.

Original: To summarize, our main contributions in this work are the following.
Revised: To summarize, our main contributions in this work are the following.

Original: (1) We design a novel paradigm of neural-symbolic KG reasoning models to combine logical rules with KG embedding.
Revised: (1) We design a novel paradigm of neural-symbolic KG reasoning models to combine logical rules with KG embedding.

Original: To our best knowledge, this is the first attempt to embed entities, relations and logical rules into a unified space to perform KG reasoning.
Revised: To our best knowledge, this is the first attempt to embed entities, relations and logical rules into a unified space to perform KG reasoning.

Original: (2) Our framework is quite generic and flexible.
Revised: (2) Our framework is quite generic and flexible.

Original: It can adopt any KGE method, such as RotatE and TransE, and can use flexible ways to model the relationship between the embeddings of logical rules and their participating relations.
Revised: It can adopt any KGE method, such as RotatE and TransE, and can use flexible ways to model the relationship between the embeddings of logical rules and their participating relations.

Original: (3) We empirically evaluate RulE on several benchmark KGs, showing superior performance to prior works.
Revised: (3) We empirically evaluate RulE on several benchmark KGs, showing superior performance to prior works.

Original:  R ELATED WORK
Revised:  R ELATED WORK

Original: A popular approach for knowledge graph reasoning is knowledge graph embedding (KGE), which embeds entities and relations into a continuous space and uses a scoring function to compute a score for each triplet based on the entity and relation embeddings (Bordes et al., 2013;
Revised: A popular approach for knowledge graph reasoning is knowledge graph embedding (KGE), which embeds entities and relations into a continuous space and uses a scoring function to compute a score for each triplet based on the entity and relation embeddings (Bordes et al., 2013;

Original: Yang et al., 2014;
Revised: Yang et al., 2014;

Original: Trouillon et al., 2016;
Revised: Trouillon et al., 2016;

Original: Cai & Wang, 2017; Sun et al., 2019; Balaˇzevi´c et al., 2019; Vashishth et al., 2019; Zhang et al.,  2020).
Revised: Cai & Wang, 2017; Sun et al., 2019; Balaˇzevi´c et al., 2019; Vashishth et al., 2019; Zhang et al., 2020; Abboud et al., 2020).

Original: Much prior work in this regard views a relation as some operation or mapping function between entities.
Revised: Much prior work in this regard views a relation as some operation or mapping function between entities.

Original: Most notably, TransE (Bordes et al., 2013) defines a relation as a translation operation between some head entity and tail entity.
Revised: Most notably, TransE (Bordes et al., 2013) defines a relation as a translation operation between some head entity and tail entity.

Original: It is effective in modelling inverse and composition rules.
Revised: It is effective in modelling inverse and composition rules.

Original: DistMult (Yang et al., 2014) uses a bilinear mapping function to model symmetric patterns.
Revised: DistMult (Yang et al., 2014) uses a bilinear mapping function to model symmetric patterns.

Original: RotatE (Sun et al., 2019) uses rotation operation in complex space to capture symmetry/antisymmetry, inversion and composition rules.
Revised: RotatE (Sun et al., 2019) uses rotation operation in complex space to capture symmetry/antisymmetry, inversion and composition rules.

Original:  Still, the relations well modelled by prior work are quite simple, and embeddings are learned solely based on triplets (zeroth-order logic) contained in the given KG.
Revised: [BoxE (Abboud et al., 2020) models relations as boxes and entities as points to capture symmetry/anti-symmetry, inversion, hierarchy and intersection patterns but not composition rules] Still, the relations well modelled by prior work are quite simple, and embeddings are learned solely based on triplets (zeroth-order logic) contained in the given KG.

Original: In contrast, our approach is able to embody more complex firstorder logical rules in the embedding space by jointly modeling entities, relations and logical rules in a unified framework.
Revised: In contrast, our approach is able to embody more complex first-order logical rules in the embedding space by jointly modeling entities, relations and logical rules in a unified framework.

Original: Besides embedding-based methods, logical rules have been widely applied in knowledge graph reasoning as well because of their interpretability and generalizability.
Revised: Besides embedding-based methods, logical rules have been widely applied in knowledge graph reasoning as well because of their interpretability and generalizability.

Original: As one of the early efforts,
Revised: As one of the early efforts,

Original: Quinlan (1990) uses Inductive Logic Programming (ILP) to derive logical rules (hypothesis) from all the training samples in a KG.
Revised: Quinlan (1990) uses Inductive Logic Programming (ILP) to derive logical rules (hypothesis) from all the training samples in a KG.

Original: Some later work leverages Markov Logic Networks (MLNs) to define the joint distribution over given (observed) and hidden variables (missing facts) (Kok & Domingos, 2005; Brocheler et al., 2012; Beltagy & Mooney, 2014).
Revised: Some later work leverages Markov Logic Networks (MLNs) to define the joint distribution over given (observed) and hidden variables (missing facts) (Kok & Domingos, 2005; Brocheler et al., 2012; Beltagy & Mooney, 2014).

Original: Using maximum likelihood estimation,
Revised: Using maximum likelihood estimation,

Original: MLNs learn the weights of logical rules, which can be further used to infer missing facts (hidden variables) in the probabilistic graph framework.
Revised: MLNs learn the weights of logical rules, which can be further used to infer missing facts (hidden variables) in the probabilistic graph framework.

Original: However, this approach requires enumerating all possible facts and thus is not tractable.
Revised: However, this approach requires enumerating all possible facts and thus is not tractable.

Original: AMIE (Gal ´ arraga et al., 2013) and AMIE+ (Gal ´ arraga et al., 2015) first enumerate possible rules and then learn a scalar weight for each rule to encode the quality.
Revised: AMIE (Gal ´ arraga et al., 2013) and AMIE+ (Gal ´ arraga et al., 2015) first enumerate possible rules and then learn a scalar weight for each rule to encode the quality.

Original: Neural-LP
Revised: Neural-LP

Original: (Yang et al., 2017) and
Revised: (Yang et al., 2017) and

Original: DRUM (Sadeghian et al., 2019) mine rules by simultaneously learning logic rules and their weights based on TensorLog (Cohen et al., 2017).
Revised: DRUM (Sadeghian et al., 2019) mine rules by simultaneously learning logic rules and their weights based on TensorLog (Cohen et al., 2017).

Original: RNNLogic (Qu et al., 2020) simultaneously trains a rule generator as well as a reasoning predictor to generate highquality logical rules.
Revised: RNNLogic (Qu et al., 2020) simultaneously trains a rule generator as well as a reasoning predictor to generate highquality logical rules.

Original: Except for RNNLogic, the above methods solely use the learned logical rules for reasoning, which suffer from brittleness and are hardly competitive with embedding-based reasoning in most benchmarks.
Revised: Except for RNNLogic, the above methods solely use the learned logical rules for reasoning, which suffer from brittleness and are hardly competitive with embedding-based reasoning in most benchmarks.

Original: Although RNNLogic considers the effect of KGE during inference, it only linearly combines the rule inference score and KGE score as the final prediction score, and pretrains KGE separately from logical rule learning without jointly modeling KGE and logical rules in the same space.
Revised: Although RNNLogic considers the effect of KGE during inference, it only linearly combines the rule inference score and KGE score as the final prediction score, and pretrains KGE separately from logical rule learning without jointly modeling KGE and logical rules in the same space.

Original: In contrast, our RulE assigns an embedding to each logical rule and trains KGE together with rule embedding, so that they are modelled in the same embedding space to complement each other.
Revised: In contrast, our RulE assigns an embedding to each logical rule and trains KGE together with rule embedding, so that they are modelled in the same embedding space to complement each other.

Original: In addition, during rule inference, RulE further employs the learned confidence scores of rules as soft multi-hot encoding of the activated rules instead of hard multi-hot encoding of RNNLogic to further promote rule-based reasoning.
Revised: In addition, during rule inference, RulE further employs the learned confidence scores of rules as soft multi-hot encoding of the activated rules instead of hard multi-hot encoding of RNNLogic to further promote rule-based reasoning.

Original: Moreover, some recent work tries to incorporate logical rules into KGE models to improve the generalization and performance of KGE reasoning.
Revised: Moreover, some recent work tries to incorporate logical rules into KGE models to improve the generalization and performance of KGE reasoning.

Original: KALE (Guo et al., 2016) applies t-norm fuzzy logic to grounded rules to give a truth score to each inferred triplet and generate additional triplets for KGE training.
Revised: KALE (Guo et al., 2016) applies t-norm fuzzy logic to grounded rules to give a truth score to each inferred triplet and generate additional triplets for KGE training.

Original: RUGE (Guo et al., 2018) additionally focuses on soft rules and uses logical rules to enhance KGE in an iterative manner.
Revised: RUGE (Guo et al., 2018) additionally focuses on soft rules and uses logical rules to enhance KGE in an iterative manner.

Original: These models both use logical rules to infer new facts as additional training data for KGE.
Revised: These models both use logical rules to infer new facts as additional training data for KGE.

Original: Besides the above ones, several other prior work injects rules via regularization terms for KGE during training.
Revised: Besides the above ones, several other prior work injects rules via regularization terms for KGE during training.

Original: Notably, Wang et al.
Revised: Notably, Wang et al.

Original: (2015) formulates inference as an integer linear programming (ILP) problem with the objective function generated from embedding models and the constraints translated from rules.
Revised: (2015) formulates inference as an integer linear programming (ILP) problem with the objective function generated from embedding models and the constraints translated from rules.

Original: Ding et al.
Revised: Ding et al.

Original: (2018) impose nonnegativity constraints on entity representations by restricting each element of entity embedding to [0 , 1] , and inject subrelation rules (e.g., r p → r q ) over relation representations, regularizing the score computed by KGE of the latter to be higher than that of the former.
Revised: (2018) impose nonnegativity constraints on entity representations by restricting each element of entity embedding to [0 , 1] , and inject subrelation rules (e.g., r p → r q ) over relation representations, regularizing the score computed by KGE of the latter to be higher than that of the former.

Original: Based on Ding et al.
Revised: Based on Ding et al.

Original: (2018), Guo et al.
Revised: (2018), Guo et al.

Original: (2020) go beyond simple rules (i.e., subrelation) and can handle more complex logical rules encoded by Horn clauses.
Revised: (2020) go beyond simple rules (i.e., subrelation) and can handle more complex logical rules encoded by Horn clauses.

Original: In summary, these methods leverage logical rules only to enhance KGE training and do not really perform reasoning with logical rules.
Revised: In summary, these methods leverage logical rules only to enhance KGE training and do not really perform reasoning with logical rules.

Revised: [Besides, there are some other works that adopt graph neural networks framework.

Revised: They usually aggregate local neighbor information to perform link prediction (Schlichtkrull et al., 2018;

Revised: Teru et al., 2020; Zhu et al., 2021).

Revised: Although they probably achieve better performance than our method in FB15kand WN18RR, it does not explicitly apply logic rules and lack explainability.

Revised: However, our method is more applicable paradigm such that we can exploit human domain knowledge.]

Original: In our approach, we simultaneously train KG embedding and rule embedding, and combine them together to infer missing facts, which mutually enhance each other.
Revised: It simultaneously train KG embedding and rule embedding, and combine them together to infer missing facts, which mutually enhance each other.

Original:  P RELIMINARIES
Revised:  P RELIMINARIES

Original: A KG consists of a set of triplets or atoms K = { ( h , r , t ) | h , t ∈ E ,
Revised: A KG consists of a set of triplets or atoms K = { ( h , r , t ) | h , t ∈ E ,

Original: r ∈ R} ⊆
Revised: r ∈ R} ⊆

Original: E × R × E , where E denotes the set of entities and R the set of relations.
Revised: E × R × E , where E denotes the set of entities and R the set of relations.

Original: For a testing triplet ( h , r , t ) , we define a query as q =
Revised: For a testing triplet ( h , r , t ) , we define a query as q =

Original: ( h , r , ? ) .
Revised: ( h , r , ? ) .

Original: The knowledge graph reasoning (link prediction) task is to infer the missing entity t based on the existing facts (and rules).
Revised: The knowledge graph reasoning (link prediction) task is to infer the missing entity t based on the existing facts (and rules).

Original: 3. E MBEDDING - BASED REASONING
Revised: 3. E MBEDDING - BASED REASONING

Original: Knowledge graph embedding (KGE) represents entities and relations in a continuous space called embeddings .
Revised: Knowledge graph embedding (KGE) represents entities and relations in a continuous space called embeddings .

Original: It calculates a score for each triplet based on these embeddings via a scoring function.
Revised: It calculates a score for each triplet based on these embeddings via a scoring function.

Original: The embeddings are trained so that facts observed in the KG have higher scores than those not observed.
Revised: The embeddings are trained so that facts observed in the KG have higher scores than those not observed.

Original: The learning goal here is to maximize the scores of positive facts (existing facts) and minimize those of generated negative samples.
Revised: The learning goal here is to maximize the scores of positive facts (existing facts) and minimize those of generated negative samples.

Original: RotatE (Sun et al., 2019) is a representative KGE method with competitive performance on common benchmark datasets.
Revised: RotatE (Sun et al., 2019) is a representative KGE method with competitive performance on common benchmark datasets.

Original: It maps entities in a complex space and defines relations as element-wise rotations in a two-dimensional complex plane.
Revised: It maps entities in a complex space and defines relations as element-wise rotations in a two-dimensional complex plane.

Original: Each entity and each relation is associated with a complex vector, i.e., h ( c ) , r ( c ) , t ( c ) ∈ C k , where the modulus of each element in r ( c ) equals to(multiplying a complex number with a unitary complex number is equivalent to a 2D rotation).
Revised: Each entity and each relation is associated with a complex vector, i.e., h ( c ) , r ( c ) , t ( c ) ∈ C k , where the modulus of each element in r ( c ) equals to(multiplying a complex number with a unitary complex number is equivalent to a 2D rotation).

Original: The k -dimensional complex vector h c can be expressed in the form h ( c ) =
Revised: The k -dimensional complex vector h c can be expressed in the form h ( c ) =

Original: h a + h b i , where h a and h b are k -dimensional real vectors.
Revised: h a + h b i , where h a and h b are k -dimensional real vectors.

Original: Based on it, RotateE represents each head entity as a 2 k -dimensional real vector h :
Revised: Based on it, RotateE represents each head entity as a 2 k -dimensional real vector h :

Original: =
Revised: =

Original: [ h a , h b ] ∈ R 2 k , where h a are the real parts and h b are the imaginary parts (the same for the tail embedding t ).
Revised: [ h a , h b ] ∈ R 2 k , where h a are the real parts and h b are the imaginary parts (the same for the tail embedding t ).

Original: Additionally, as rotations are associated with unitary complex numbers (i.e., |
Revised: Additionally, as rotations are associated with unitary complex numbers (i.e., |

Original: [ r ( c ) ]
Revised: [ r ( c ) ]

Original: j | = 1 , j = 1 , 2 , . . .
Revised: j | = 1 , j = 1 , 2 , . . .

Original: , k ), RotateE only parameterizes relation embeddings with k -dimensional real vectors (angles) r .
Revised: , k ), RotateE only parameterizes relation embeddings with k -dimensional real vectors (angles) r .

Original: Here the real parts are cos ( r ) and imaginary parts are sin ( r ) , where both sin and cos are element-wise operations.
Revised: Here the real parts are cos ( r ) and imaginary parts are sin ( r ) , where both sin and cos are element-wise operations.

Original: If a triplet ( h , r , t ) holds, it is expected that t ( c ) ≈ h ( c ) ◦ r ( c ) in the complex space, where ◦ denotes the Hadamard (element-wise) product.
Revised: If a triplet ( h , r , t ) holds, it is expected that t ( c ) ≈ h ( c ) ◦ r ( c ) in the complex space, where ◦ denotes the Hadamard (element-wise) product.

Original: This is equivalent to t ≈ Concat (cid:0) h a ◦ cos ( r ) − h b ◦ sin ( r ) , h a ◦ sin ( r ) + h b ◦ cos ( r ) (cid:1) in the real space, where (cid:0) h a ◦ cos ( r ) − h b ◦ sin ( r ) (cid:1) is the real part of t and (cid:0) h a ◦ sin ( r ) + h b ◦ cos ( r ) (cid:1) is the imaginary part.
Revised: This is equivalent to t ≈ Concat (cid:0) h a ◦ cos ( r ) − h b ◦ sin ( r ) , h a ◦ sin ( r ) + h b ◦ cos ( r ) (cid:1) in the real space, where (cid:0) h a ◦ cos ( r ) − h b ◦ sin ( r ) (cid:1) is the real part of t and (cid:0) h a ◦ sin ( r ) + h b ◦ cos ( r ) (cid:1) is the imaginary part.

Original: The distance function of RotatE is defined as:
Revised: The distance function of RotatE is defined as:

Original: [Equation]
Revised: [Equation]

Original: By defining relations as rotations in complex space, RotatE can model symmetry/antisymmetry, inversion and composition rules simultaneously.
Revised: By defining relations as rotations in complex space, RotatE can model symmetry/antisymmetry, inversion and composition rules simultaneously.

Original: 3. R ULE - BASED REASONING
Revised: 3. R ULE - BASED REASONING

Original: Logical rules are usually expressed as first-order logic formulae,
Revised: Logical rules are usually expressed as first-order logic formulae,

Original: e.g., ∀ x, y, z : ( x, r 1 , y ) ∧
Revised: e.g., ∀ x, y, z : ( x, r 1 , y ) ∧

Original: ( y, r 2 , z ) → ( x, r 3 , z ) , or r 1 ( x, y )
Revised: ( y, r 2 , z ) → ( x, r 3 , z ) , or r 1 ( x, y )

Original: ∧ r 2 ( y, z ) →
Revised: ∧ r 2 ( y, z ) →

Original: r 3 ( x, z ) for brevity.
Revised: r 3 ( x, z ) for brevity.

Original: The left side of the implication “ → ” is called rule body or premise, and the right-hand side is rule head or conclusion.

Original: Logical rules are often restricted to be closed , forming chains .

Original: For a chain rule, successive relations share intermediate entities (e.g., y ), and the conclusion’s and premise’s head/tail entity are the same.

Original: The length of a rule is the number of atoms (relations) that exist in its rule body.

Original: One example of a length-2 rule is:

Original: [Equation]

Original: of which live in ( · ) ∧ city of ( · ) is the rule body and nationality ( · ) is the rule head.

Original: A grounding of a rule is obtained by substituting all variables x, y, z with specific entities.

Original: For example, if we replace e ! ,𝑟 ! ,𝑒 " 𝑒 # ,𝑟 " ,𝑒 $ 𝑒 % ,𝑟 # ,𝑒 & …
Revised: The left-hand side of the e ! ,𝑟 ! ,𝑒 " 𝑒 # ,𝑟 " ,𝑒 $ 𝑒 % ,𝑟 # ,𝑒 & …

Original: Triples existing in KG (𝑅 ! : 𝑟 !
Revised: Triples existing in KG (𝑅 ! : 𝑟 !

Original: ∧𝑟 " ⇒ 𝑟 # ) (𝑅 " : 𝑟 $ ∧r % ∧𝑟 & ⇒ 𝑟 ’ )
Revised: ∧𝑟 " ⇒ 𝑟 # ) (𝑅 " : 𝑟 $ ∧r % ∧𝑟 & ⇒ 𝑟 ’ )

Original: (𝑅 # : 𝑟 ’ ∧r ( ⇒ 𝑟 # ) …
Revised: (𝑅 # : 𝑟 ’ ∧r ( ⇒ 𝑟 # ) …

Original: Logic rules
Revised: Logic rules

Original: Initialized embedding 𝑓triple 𝑒 ! ,𝑟 !
Revised: Initialized embedding 𝑓triple 𝑒 ! ,𝑟 !

Original: [Figure]

Original:  " 𝑓triple 𝑒 # , [Figure] [Figure] 𝑓triple 𝑒 % ,
Revised: ≈𝑒 " 𝑓triple 𝑒 # ,𝑟 " ≈𝑒 $ 𝑓triple 𝑒 % ,𝑟 # ≈𝑒

Original: [Figure]
Revised: [Figure]

Original: Triple [Figure] ! ,𝑟 " ,𝑅 [Figure]
Revised: Triple loss 𝑓rule 𝑟 ! ,𝑟 " ,𝑅 !

Original: ≈𝑟 # 𝑓rule 𝑟 $ ,𝑟 % ,𝑟 & ,𝑅 " [Figure] [Figure] Rule
Revised: ≈𝑟 # 𝑓rule 𝑟 $ ,𝑟 % ,𝑟 & ,𝑅 " ≈𝑟 ’ 𝑓rule 𝑟 ’ ,𝑟 ( ,𝑅 #

Original: [Figure]
Revised: [Figure]

Original: Pre

Original: [Figure]
Revised: [Figure]

Revised: Rule loss

Original: training
Revised: Pre-training

Original: Jointly training
Revised: Jointly training

Original: Optimized embedding
Revised: Optimized embedding

Original: Activated [Figure] confidence [Figure]
Revised: Activated rule confidence 𝑤 !

Original:  # 𝑝
Revised: 𝑤 # 𝑝

Original: KGE score
Revised: KGE score

Original: Final score
Revised: Final score

Original: Grounding
Revised: Grounding

Original: Inference
Revised: Inference

Original: Grounding [Figure] score 𝑒 ) 𝑒 ! 𝑟 !
Revised: Grounding rule score 𝑒 ) 𝑒 ! 𝑟 !

Original: 𝑟 * 𝑅 !
Revised: 𝑟 * 𝑅 !

Original: 𝑅 + … … … 𝑒 ) 𝑒 !
Revised: 𝑅 + … … … 𝑒 ) 𝑒 !

Original: 𝑟 !
Revised: 𝑟 !

Original: 𝑟 * 𝑅 !
Revised: 𝑟 * 𝑅 !

Original: 𝑅 + … … …
Revised: 𝑅 + … … …

Original: Weightedsum
Revised: Weightedsum

Original: MLP 𝑟 $ 𝑟 % 𝑟 & 𝑟 !
Revised: MLP 𝑟 $ 𝑟 % 𝑟 & 𝑟 !

Original: Rule grounding 𝑟 ’ 𝑟 ( 𝑟 " 𝑟 # 𝑝 𝑒 & 𝑒 % … 𝑅 !
Revised: Rule grounding 𝑟 ’ 𝑟 ( 𝑟 " 𝑟 # 𝑝 𝑒 & 𝑒 % … 𝑅 !

Original: (-) 𝑅 #(-) 𝑅 +(-) 𝑅 "(-)
Revised: (-) 𝑅 #(-) 𝑅 +(-) 𝑅 "(-)

Original: -stage embeddings with w which is further used to output a grounding rule score.
Revised: -stage embeddings with w which is further used to output a grounding rule score.

Original: 3) Finally, RulE integrates the KGE score obtained from the pre-training stage and the grounding rule score for inference .
Revised: 3) Finally, RulE integrates the KGE score obtained from the pre-training stage and the grounding rule score for inference .

Revised: implication “ → ” is called rule body or premise, and the right-hand side is rule head or conclusion.

Revised: Logical rules are often restricted to be closed , forming chains .

Revised: For a chain rule, successive relations share intermediate entities (e.g., y ), and the conclusion’s and premise’s head/tail entity are the same.

Revised: The length of a rule is the number of atoms (relations) that exist in its rule body.

Original: x
Revised: One example of a length-2 rule is: [Equation] of which live in ( · ) ∧ city of ( · ) is the rule body and nationality ( · ) is the rule head. A grounding of a rule is obtained by substituting all variables x, y, z with specific entities.

Original: , y, z with Bill Gates, Seattle, US respectively, we get a grounding:
Revised: For example, if we replace x, y, z with Bill Gates, Seattle, US respectively, we get a grounding:

Original: [Equation]
Revised: [Equation]

Original: If all triplets in the rule body of a grounding exist in the KG, we get a support of this rule.
Revised: If all triplets in the rule body of a grounding exist in the KG, we get a support of this rule.

Original: Those rules that have nonzero support are called activated rules.
Revised: Those rules that have nonzero support are called activated rules.

Original: When inferring a query ( h , r , ?) , rulebased reasoning enumerates relation paths between head h and each candidate tail, and uses activated logic rules to infer the answer.
Revised: When inferring a query ( h , r , ?) , rulebased reasoning enumerates relation paths between head h and each candidate tail, and uses activated logic rules to infer the answer.

Original: For example, if we want to infer nationality ( Bill Gates , ?) , given the logical rule (2) as well as the existing triplets live in ( Bill Gates , Seattle ) and city of ( Seattle , US ) , the answer US can be inferred by traversing the KG.
Revised: For example, if we want to infer nationality ( Bill Gates , ?) , given the logical rule (2) as well as the existing triplets live in ( Bill Gates , Seattle ) and city of ( Seattle , US ) , the answer US can be inferred by traversing the KG.

Original:  M ETHOD
Revised:  M ETHOD

Original: This section introduces our proposed model RulE. RulE uses a novel paradigm to combine KG embedding with logical rules by learning rule embeddings.
Revised: This section introduces our proposed model RulE. RulE uses a novel paradigm to combine KG embedding with logical rules by learning rule embeddings.

Original: As illustrated in Figure 2, RulE consists of three key components.
Revised: As illustrated in Figure 2, RulE consists of three key components.

Original: Consider a KG containing triplets and a set of logical rules extracted from the same or some other (external) knowledge source.
Revised: Consider a KG containing triplets and a set of logical rules extracted from the same or some other (external) knowledge source.

Original: 1) Pretraining.
Revised: 1) Pretraining.

Original: We model the relationship between entities and relations as well as the relationship between relations and logical rules to jointly train entity embedding, relation embedding and rule embedding in a continuous space, as illustrated in Figure 1. 2) Grounding .
Revised: We model the relationship between entities and relations as well as the relationship between relations and logical rules to jointly train entity embedding, relation embedding and rule embedding in a continuous space, as illustrated in Figure 1. 2) Grounding .

Original: With the rule and relation embeddings, we calculate a confidence score for each rule which is used as the weight of activated rules to output a grounding rule score 3) Inference .
Revised: With the rule and relation embeddings, we calculate a confidence score for each rule which is used as the weight of activated rules to output a grounding rule score 3) Inference .

Original: Finally, we integrate the KGE score obtained from the pre-training stage and the grounding rule score obtainable from the grounding stage to reason unknown triplets.
Revised: Finally, we integrate the KGE score obtained from the pre-training stage and the grounding rule score obtainable from the grounding stage to reason unknown triplets.

Original: 4. P RE - TRAINING
Revised: 4. P RE - TRAINING

Original: Given a triplet ( h , r , t ) ∈ K and a rule R ∈ L , we use h , r , t , R ∈ R 2 k to represent their embeddings, respectively, where k is the dimension of the complex space (following RotatE).
Revised: Given a triplet ( h , r , t ) ∈ K and a rule R ∈ L , we use h , r , t , R ∈ R 2 k to represent their embeddings, respectively, where k is the dimension of the complex space (following RotatE).

Original: Similar to KGE, which encodes the plausibility of each triplet with a scoring function, RulE additionally defines a scoring function for logical rules.
Revised: Similar to KGE, which encodes the plausibility of each triplet with a scoring function, RulE additionally defines a scoring function for logical rules.

Original: Based on the two scoring functions, it jointly learns entity, relation and rule embeddings in a same space by maximizing the plausibility of existing triplets K (zerothorder logic) and logical rules L (first-order logic).
Revised: Based on the two scoring functions, it jointly learns entity, relation and rule embeddings in a same space by maximizing the plausibility of existing triplets K (zerothorder logic) and logical rules L (first-order logic).

Original: The following describes in detail how to model the triplets and logical rules together.
Revised: The following describes in detail how to model the triplets and logical rules together.

Original: Modeling the relationship between entities and relations To model triplets, we take RotatE (Sun et al., 2019) due to its simplicity and competitive performance.
Revised: Modeling the relationship between entities and relations To model triplets, we take RotatE (Sun et al., 2019) due to its simplicity and competitive performance.

Original: Specifically, given a triplet ( h , r , t ) , its score is formulated as:
Revised: Specifically, given a triplet ( h , r , t ) , its score is formulated as:

Original: [Equation]
Revised: [Equation]

Original: ) where γ t is a fixed triplet margin and d ( h , r , t ) is defined in Eq.
Revised: where γ t is a fixed triplet margin and d ( h , r , t ) is defined in Eq.

Original: A triplet with a small distance will have a higher score, indicating its higher probability to be true.
Revised: A triplet with a small distance will have a higher score, indicating its higher probability to be true.

Original: Note that our model is not restricted to RotatE. The distance function can also be replaced with other KGE models, such as
Revised: Note that our model is not restricted to RotatE. The distance function can also be replaced with other KGE models, such as

Original: TransE (Bordes et al., 2013) and ComplEx (Trouillon et al., 2016).
Revised: TransE (Bordes et al., 2013) and ComplEx (Trouillon et al., 2016).

Original: Based on the scoring function, we define the loss function with negative sampling as:
Revised: Based on the scoring function, we define the loss function with negative sampling as:

Original: [Equation]
Revised: [Equation]

Original: where σ ( x ) = 1 / (1 + exp( − x )) denotes the sigmoid function and N is the set of negative samples constructed by replacing either the head entity or the tail entity with a random entity (but not both at the same time).
Revised: where σ ( x ) = 1 / (1 + exp( − x )) denotes the sigmoid function and N is the set of negative samples constructed by replacing either the head entity or the tail entity with a random entity (but not both at the same time).

Original: Following RotatE (Sun et al., 2019), we use a self-adversarial negative sampling approach to sample negative triplets from the current embedding model.
Revised: Following RotatE (Sun et al., 2019), we use a self-adversarial negative sampling approach to sample negative triplets from the current embedding model.

Original: Modeling the relationship between relations and logical rules
Revised: Modeling the relationship between relations and logical rules

Original: A universal first-order logical rule is some rule that universally holds for all entities.
Revised: A universal first-order logical rule is some rule that universally holds for all entities.

Original: Therefore, we cannot relate such a rule with specific entities.
Revised: Therefore, we cannot relate such a rule with specific entities.

Original: Instead, it is a higher-level concept related to the relations of which it is composed.
Revised: Instead, it is a higher-level concept related to the relations of which it is composed.

Original: Motivated by RotatE, a natural idea is to model the relationship between relations and logical rule as element-wise rotations from the rule body to the rule head, i.e., for a logical rule
Revised: Motivated by RotatE, a natural idea is to model the relationship between relations and logical rule as element-wise rotations from the rule body to the rule head, i.e., for a logical rule

Original: R : r 1 ∧ r 2 ∧ ...
Revised: R : r 1 ∧ r 2 ∧ ...

Original: ∧
Revised: ∧

Original: r l → r l +1 , we expect that r ( c ) l +

Revised: r l → r l +1 , we expect that r ( c ) l +

Original: ≈
Revised: ≈

Original: ( r ( c ) 1 ◦ r ( c ) 2 ◦ ... ◦
Revised: ( r ( c ) 1 ◦ r ( c ) 2 ◦ ... ◦

Original: r ( c ) l ) ◦ R ( c ) , where { r ( c ) i } li = and R ( c ) are in the k -dimensional complex space.
Revised: r ( c ) l ) ◦ R ( c ) , where { r ( c ) i } li = and R ( c ) are in the k -dimensional complex space.

Original: However, 2D rotations are commutative—they cannot model the non-commutative property of composition rules, which is crucial for correctly expressing the relation order of a rule.
Revised: However, 2D rotations are commutative—they cannot model the non-commutative property of composition rules, which is crucial for correctly expressing the relation order of a rule.

Original: Take sister of ( x, y ) ∧ mother of ( y, z ) → aunt of ( x, z ) as an example.
Revised: Take sister of ( x, y ) ∧ mother of ( y, z ) → aunt of ( x, z ) as an example.

Original: If we permute the relations in rule body, e.g., change (sister of ∧ mother of) to (mother of ∧ sister of), the rule is no longer correct.
Revised: If we permute the relations in rule body, e.g., change (sister of ∧ mother of) to (mother of ∧ sister of), the rule is no longer correct.

Original: However, the above model will output the same score since ( r ( c ) 1 ◦ r ( c ) 2 ) =
Revised: However, the above model will output the same score since ( r ( c ) 1 ◦ r ( c ) 2 ) =

Original: ( r ( c ) 2 ◦ r ( c ) 1 ) .
Revised: ( r ( c ) 2 ◦ r ( c ) 1 ) .

Original: Therefore, to respect the relation order of logical rules, we propose to use RNN (Graves, 2012).
Revised: Therefore, to respect the relation order of logical rules, we propose to use RNN (Graves, 2012).

Original: Given the sequence of all relations in a rule body, e.g., [ r 1 , r 2 , .
Revised: Given the sequence of all relations in a rule body, e.g., [ r 1 , r 2 , .

Original: .., r l ] , we use RNN to generate the rule head r l +1 .
Revised: .., r l ] , we use RNN to generate the rule head r l +1 .

Original: Specifically, we first concatenate each relation embedding r i in the rule body with the rule embedding R .
Revised: Specifically, we first concatenate each relation embedding r i in the rule body with the rule embedding R .

Original: We further pass the concatenated embedding to an RNN, whose output is expected to be close to the rule head embedding r l +1 .
Revised: We further pass the concatenated embedding to an RNN, whose output is expected to be close to the rule head embedding r l +1 .

Original: Given so, the distance function is formulated as:
Revised: Given so, the distance function is formulated as:

Original: [Equation]
Revised: [Equation]

Original: We also employ negative sampling, the same as when modeling triplets.
Revised: We also employ negative sampling, the same as when modeling triplets.

Original: At this time, it replaces a relation (either in rule body or rule head) with a random relation.
Revised: At this time, it replaces a relation (either in rule body or rule head) with a random relation.

Original: The loss function for logical rules is defined as:
Revised: The loss function for logical rules is defined as:

Original: [Equation]
Revised: [Equation]

Original: where γ r is a fixed rule margin and M is the set of negative rule samples.
Revised: where γ r is a fixed rule margin and M is the set of negative rule samples.

Original: Jointly training Given a KG containing a set of triplets K and logical rules L , we jointly optimize the entity, relation, and rule embeddings with the loss:
Revised: Jointly training Given a KG containing a set of triplets K and logical rules L , we jointly optimize the entity, relation, and rule embeddings with the loss:

Original: [Equation]
Revised: [Equation]

Original: where α is a positive hyperparameter weighting the importance of rules.
Revised: where α is a positive hyperparameter weighting the importance of rules.

Original: 4. G ROUNDING
Revised: 4. G ROUNDING

Original: During grounding, we use the parameters optimized by the pre-training process to compute the confidence score of each rule.
Revised: During grounding, we use the parameters optimized by the pre-training process to compute the confidence score of each rule.

Original: Similar to how KGE gives a triplet the score, the confidence score of a logical rule R i : r i 1 ∧ r i 2 ∧ ...
Revised: Similar to how KGE gives a triplet the score, the confidence score of a logical rule R i : r i 1 ∧ r i 2 ∧ ...

Original: ∧ r i l → r i l +1 is calculated by:
Revised: ∧ r i l → r i l +1 is calculated by:

Original: [Equation]
Revised: [Equation]

Original: where d ( R i , r i 1 , r i 2 , ..., r i l +1 ) is defined in Eq.
Revised: where d ( R i , r i 1 , r i 2 , ..., r i l +1 ) is defined in Eq.

Original: Each logical rule is further associated with a grounding-stage rule embedding R ( g ) ∈
Revised: Each logical rule is further associated with a grounding-stage rule embedding R ( g ) ∈

Original: R p .
Revised: R p .

Original: Note that this embedding is trained separately from the rule embedding R in the pre-training stage, and is only used for the grounding stage rule-based reasoning.
Revised: Note that this embedding is trained separately from the rule embedding R in the pre-training stage, and is only used for the grounding stage rule-based reasoning.

Original: Specifically, when answering a query ( h , r , ? ) , we apply logical rules to find different grounding paths on the KG, yielding different candidate answers.
Revised: Specifically, when answering a query ( h , r , ? ) , we apply logical rules to find different grounding paths on the KG, yielding different candidate answers.

Original: For each candidate answer t ′ , we sum over the grounding-stage embeddings of those activated rules, each weighted by its rule confidence score w i and the number of paths activating this rule (# supports).
Revised: For each candidate answer t ′ , we sum over the grounding-stage embeddings of those activated rules, each weighted by its rule confidence score w i and the number of paths activating this rule (# supports).

Original: Finally, we apply an
Revised: Finally, we apply an

Original: MLP to calculate the grounding rule score:
Revised: MLP to calculate the grounding rule score:

Original: [Equation]
Revised: [Equation]

Original: where LN is the layer normalization operation, L ′ is the set of activated rules for ( h , r , t ′ ) , and
Revised: where LN is the layer normalization operation, L ′ is the set of activated rules for ( h , r , t ′ ) , and

Original: P ( h , R i , t ′ ) is the set of supports of the rule R i which starts from h and ends at t ′ .
Revised: P ( h , R i , t ′ ) is the set of supports of the rule R i which starts from h and ends at t ′ .

Original: More implementation details of the grounding process are included in Appendix A. Once we have the grounding rule score for each candidate answer, we further use a softmax function to compute the probability of the true answer.
Revised: More implementation details of the grounding process are included in Appendix A. Once we have the grounding rule score for each candidate answer, we further use a softmax function to compute the probability of the true answer.

Original: Finally, we train the MLP and grounding-stage rule embeddings by maximizing the log likelihood of the true answers in the training triplets.
Revised: Finally, we train the MLP and grounding-stage rule embeddings by maximizing the log likelihood of the true answers in the training triplets.

Original: 4. I NFERENCE
Revised: 4. I NFERENCE

Original: After pre-training and grounding, we predict any missing fact jointly with the KGE score (Eq.
Revised: After pre-training and grounding, we predict any missing fact jointly with the KGE score (Eq.

Original: and the grounding rule score (Eq.
Revised: and the grounding rule score (Eq.

Original: Specifically, for a query ( h , r , ? ) , we substitute the tail entity with all candidate entities ( h , r , t ′ ) and compute their KGE scores s t ( h , r , t ′ ) .
Revised: Specifically, for a query ( h , r , ? ) , we substitute the tail entity with all candidate entities ( h , r , t ′ ) and compute their KGE scores s t ( h , r , t ′ ) .

Original: In addition, we perform a BFS search from h to find all candidates whose paths from h can activate a rule with the rule head grounded by ( h , r , t ′ ) .
Revised: In addition, we perform a BFS search from h to find all candidates whose paths from h can activate a rule with the rule head grounded by ( h , r , t ′ ) .

Original: For these candidates, we compute their grounding rule scores defined in Eq.
Revised: For these candidates, we compute their grounding rule scores defined in Eq.

Original: (10) (those activating no rules have zero grounding rule scores).
Revised: (10) (those activating no rules have zero grounding rule scores).

Original: Then the final scores of all candidate answers are computed by a weighted sum of s t ( h , r , t ′ ) and s g ( h , r , t ′ ) :
Revised: Then the final scores of all candidate answers are computed by a weighted sum of s t ( h , r , t ′ ) and s g ( h , r , t ′ ) :

Original: [Equation]
Revised: [Equation]

Original: 11) β is a hyperparameter balancing the importance of embedding-based and rule-based reasoning.
Revised: (11) β is a hyperparameter balancing the importance of embedding-based and rule-based reasoning.

Original:  E XPERIMENTS
Revised:  E XPERIMENTS

Original: In this section, we experimentally evaluate RulE on several benchmark KGs and demonstrate the effectiveness of RulE on knowledge graph reasoning tasks.
Revised: In this section, we experimentally evaluate RulE on several benchmark KGs and demonstrate the effectiveness of RulE on knowledge graph reasoning tasks.

Original: 5. E XPERIMENT SETTINGS
Revised: 5. E XPERIMENT SETTINGS

Original: Datasets.
Revised: Datasets.

Original: We choose four datasets for evaluation:
Revised: We choose four datasets for evaluation:

Original: FB15k-237 (Toutanova & Chen, 2015),
Revised: FB15k-237 (Toutanova & Chen, 2015),

Original: WN18RR (Dettmers et al., 2018), UMLS and Kinship (Kok & Domingos, 2007).
Revised: WN18RR (Dettmers et al., 2018), UMLS and Kinship (Kok & Domingos, 2007).

Original: FB15k-237 and
Revised: FB15k-237 and

Original: WN18RR are subsets of two large-scale knowledge graphs, FreeBase (Bollacker et al., 2008) and
Revised: WN18RR are subsets of two large-scale knowledge graphs, FreeBase (Bollacker et al., 2008) and

Original: WordNet (Miller, 1995).
Revised: WordNet (Miller, 1995).

Original: UMLS and Kinship are two benchmark datasets for statistical relational learning.
Revised: UMLS and Kinship are two benchmark datasets for statistical relational learning.

Original: To ensure a fair comparison, we use the same splits as RNNLogic (Qu et al., 2020).
Revised: To ensure a fair comparison, we use the same splits as RNNLogic (Qu et al., 2020).

Original: More details of dataset statistics are summarized in Appendix C. 
Revised: More details of dataset statistics are summarized in Appendix C. [Table] [Table]

Original: Baselines.
Revised: Baselines.

Original: We compare with a comprehensive suite of baselines.
Revised: We compare with a comprehensive suite of baselines.

Original: (1) Embedding-based models : we include TransE (Bordes et al., 2013), ComplEx (Trouillon et al., 2016), RotatE (Sun et al., 2019) and TuckER (Balaˇzevi´c et al., 2019).
Revised: (1) Embedding-based models : we include TransE (Bordes et al., 2013), ComplEx (Trouillon et al., 2016), RotatE (Sun et al., 2019) and TuckER (Balaˇzevi´c et al., 2019).

Original: (2) Rule-based models : we consider popular rule-mining models
Revised: (2) Rule-based models : we consider popular rule-mining models

Original: Neural-LP
Revised: Neural-LP

Original: (Yang et al., 2017), DRUM (Sadeghian et al., 2019), and two RNNLogic+ variants (Qu et al., 2020).
Revised: (Yang et al., 2017), DRUM (Sadeghian et al., 2019), and two RNNLogic+ variants (Qu et al., 2020).

Original: RNNLogic+ ( rule. ) is a pure rule-based reasoning method while RNNLogic+ ( emb.+rule. )
Revised: RNNLogic+ ( rule. ) is a pure rule-based reasoning method while RNNLogic+ ( emb.+rule. )

Original: uses both logical rules and knowledge graph embeddings.
Revised: uses both logical rules and knowledge graph embeddings.

Original: See more introductions to
Revised: See more introductions to

Original: [Table]

Original: [Table]

Original: ∗

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: RNNLogic

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: RNNLogic+

Original: [Table]

Original: +rule. )

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: RulE (

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: RulE ( rule. ) 0.

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: RulE (

Original: [Table]

Original: .+rule. )

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table]

Original: [Table] [Table] [Table] RNNLogic in Appendix B. Besides, we also compare with two early works: MLN (Richardson &
Revised: RNNLogic in Appendix B. Besides, we also compare with two early works: MLN (Richardson &

Original: Domingos, 2006) and PathRank (Lao & Cohen, 2010).
Revised: Domingos, 2006) and PathRank (Lao & Cohen, 2010).

Original: (3) RulE :
Revised: (3) RulE :

Original: For our model RulE, we present results of embedding-based reasoning, rule-based reasoning and joint reasoning.
Revised: For our model RulE, we present results of embedding-based reasoning, rule-based reasoning and joint reasoning.

Original: The first one only uses KGE scores obtained from the pre-training stage to reason unknown triplets, denoted as ( emb. ).
Revised: The first one only uses KGE scores obtained from the pre-training stage to reason unknown triplets, denoted as ( emb. ).

Original: The second one uses the grounding score calculated from the grounding stage to infer missing facts, and we denote it as ( rule. ).
Revised: The second one uses the grounding score calculated from the grounding stage to infer missing facts, and we denote it as ( rule. ).

Original: The last combines both of them, denoted ( emb.+rule. ).
Revised: The last combines both of them, denoted ( emb.+rule. ).

Original: By default, we use the same rules mined by RNNLogic+.
Revised: By default, we use the same rules mined by RNNLogic+.

Original: Evaluation protocols.
Revised: Evaluation protocols.

Original: For each test triplet ( h , r , t ) , we substitute the tail entity with all entities, calculate a score for each candidate, and sort all candidates in descending order to get the rank of the true tail entity.
Revised: For each test triplet ( h , r , t ) , we substitute the tail entity with all entities, calculate a score for each candidate, and sort all candidates in descending order to get the rank of the true tail entity.

Original: During ranking, we use the filtered setting (Bordes et al., 2013) by removing corrupted triplets that already exist in either the training, validation or test set.
Revised: During ranking, we use the filtered setting (Bordes et al., 2013) by removing corrupted triplets that already exist in either the training, validation or test set.

Original: We report the standard evaluation metrics for these datasets, Mean Reciprocal Rank (MRR) and  at N (H@N). 
Revised: We report the standard evaluation metrics for these datasets, Mean Reciprocal Rank (MRR) and Hits at N (H@N). [Table]

Original: Hyperparameter settings.
Revised: Hyperparameter settings.

Original: By default, we use RotatE (Sun et al., 2019) as our KGE model.
Revised: By default, we use RotatE (Sun et al., 2019) as our KGE model.

Original: We optimize our model parameters with Adam (Kingma & Ba, 2014) and tune the hyperparameters by grid search on the validation dataset.
Revised: We optimize our model parameters with Adam (Kingma & Ba, 2014) and tune the hyperparameters by grid search on the validation dataset.

Original: See more details in Appendix C.
Revised: See more details in Appendix C.

Original: [Table]

Original: 5. R ESULTS
Revised: 5. R ESULTS

Original: As shown in Table 1 and
Revised: As shown in Table 1 and

Original: [Table]
Revised: [Table]

Original: RulE outperforms all baselines on UMLS, Kinship
Revised: RulE outperforms all baselines on UMLS, Kinship

Original: [Table]
Revised: [Table]

Original: and WN18RR.
Revised: and WN18RR.

Original: It is competitive on FB15k-237 as well.
Revised: It is competitive on FB15k-237 as well.

Original: Especially for UMLS and Kinship, we obtain 1.9% and 2.6% higher absolute MRR than the best baselines, respectively.
Revised: Especially for UMLS and Kinship, we obtain 1.9% and 2.6% higher absolute MRR than the best baselines, respectively.

Original: A detailed analysis follows.
Revised: A detailed analysis follows.

Original: Embedding logical rules helps KGE.
Revised: Embedding logical rules helps KGE.

Original: We first compare RulE ( emb. ) with RotatE. Compared to
Revised: We first compare RulE ( emb. ) with RotatE. Compared to

Original: RotatE, RulE ( emb. ) only adds an additional rule embedding loss to the KGE training and still uses
Revised: RotatE, RulE ( emb. ) only adds an additional rule embedding loss to the KGE training and still uses

Original: KGE scores only for prediction.
Revised: KGE scores only for prediction.

Original: As presented in Table 1 and Table 2, RulE ( emb. ) achieves higher performance than RotatE, indicating that embedding entities, relations and logical rules in the same space are beneficial for learning more compact representations for KG.
Revised: As presented in Table 1 and Table 2, RulE ( emb. ) achieves higher performance than RotatE, indicating that embedding entities, relations and logical rules in the same space are beneficial for learning more compact representations for KG.

Original: Specifically, on UMLS and
Revised: Specifically, on UMLS and

Original: Kinship, RulE ( emb. ) outperforms RotatE with 5.7% and 2.3% improvement in MRR, which is more significant than on FB15k-237 and WN18RR.
Revised: Kinship, RulE ( emb. ) outperforms RotatE with 5.7% and 2.3% improvement in MRR, which is more significant than on FB15k-237 and WN18RR.

Original: The reason is probably that UMLS and Kinship contain more rule-sensitive facts while WN18RR and FB15k-237 consist of more general facts (like the publication year of an album, which is hard to infer via rules).
Revised: The reason is probably that UMLS and Kinship contain more rule-sensitive facts while WN18RR and FB15k-237 consist of more general facts (like the publication year of an album, which is hard to infer via rules).

Original: This phenomenon is observed in previous works too (Qu et al., 2020).
Revised: This phenomenon is observed in previous works too (Qu et al., 2020).

Original: In Table 3, we further experiment with variants of RulE ( emb. ) using TransE and ComplEx as the KGE models.
Revised: In Table 3, we further experiment with variants of RulE ( emb. ) using TransE and ComplEx as the KGE models.

Original: They both obtain superior performance to the corresponding KGE models.
Revised: They both obtain superior performance to the corresponding KGE models.

Original: More results are shown in Appendix E.1.
Revised: More results are shown in Appendix E.1.

Original: Rule confidence improves rule-based reasoning.
Revised: Rule confidence improves rule-based reasoning.

Original: One significant difference between RulE ( rule. ) and RNNLogic+ ( rule. ) is that the former weights the grounding-stage rule embeddings (Eq.
Revised: One significant difference between RulE ( rule. ) and RNNLogic+ ( rule. ) is that the former weights the grounding-stage rule embeddings (Eq.

Original: (9) when performing rule-based reasoning, while the latter only uses hard 1/0 to select activated rules.
Revised: (9) when performing rule-based reasoning, while the latter only uses hard 1/0 to select activated rules.

Original: RulE ( rule. ) achieves better performance than RNNLogic+ ( rule. ).
Revised: RulE ( rule. ) achieves better performance than RNNLogic+ ( rule. ).

Original: This demonstrates that the confidence scores of logical rules, which are learned through jointly embedding KG and logical rules, help rule-based reasoning.
Revised: This demonstrates that the confidence scores of logical rules, which are learned through jointly embedding KG and logical rules, help rule-based reasoning.

Original: See Appendix E.2 for more discussion.
Revised: See Appendix E.2 for more discussion.

Original: Comparison with other joint reasoning and rule-enhanced KGE models.
Revised: Comparison with other joint reasoning and rule-enhanced KGE models.

Original: Compared with
Revised: Compared with

Original: RNNLogic+ ( emb.+rule. ), RulE ( emb.+rule. ) achieves better results on all datasets, demonstrating the benefits of pretraining KGE with rule embeddings together.
Revised: RNNLogic+ ( emb.+rule. ), RulE ( emb.+rule. ) achieves better results on all datasets, demonstrating the benefits of pretraining KGE with rule embeddings together.

Original: We further compare RulE ( emb. ) with KALE (Guo et al., 2016), RUGE (Guo et al., 2018) and ComplEx-NNE+AER (Ding et al., 2018) in Table 3.
Revised: We further compare RulE ( emb. ) with KALE (Guo et al., 2016), RUGE (Guo et al., 2018) and ComplEx-NNE+AER (Ding et al., 2018) in Table 3.

Original: These models inject logical rules to enhance KGE training.
Revised: These models inject logical rules to enhance KGE training.

Original: KALE is based on
Revised: KALE is based on

Original: TransE, whereas RUGE and ComplEx-NNE+AER use ComplEx.
Revised: TransE, whereas RUGE and ComplEx-NNE+AER use ComplEx.

Original: For a fair comparison, we replace
Revised: For a fair comparison, we replace

Original: RotatE in RulE with TransE and ComplEx, respectively.
Revised: RotatE in RulE with TransE and ComplEx, respectively.

Original: As these baselines only have code for old datasets, we compare all models on FB15k and WN18.
Revised: As these baselines only have code for old datasets, we compare all models on FB15k and WN18.

Original: From Table 3, we can see that RulE ( emb.
Revised: From Table 3, we can see that RulE ( emb.

Original: TransE ) yields more accurate results than KALE.
Revised: TransE ) yields more accurate results than KALE.

Original: For RulE ( emb. ComplEx ), although it does not outperform ComplEx-NNE+AER (probably because it additional injects the regularization terms on entities but RulE does not), compared to RUGE, RulE ( emb.
Revised: For RulE ( emb. ComplEx ), although it does not outperform ComplEx-NNE+AER (probably because it additional injects the regularization terms on entities but RulE does not), compared to RUGE, RulE ( emb.

Original: ComplEx ) also obtains 2% improvement in MRR on FB15k as well as comparable results on WN18.
Revised: ComplEx ) also obtains 2% improvement in MRR on FB15k as well as comparable results on WN18.

Original:  D ISCUSSION AND C ONCLUSION
Revised:  D ISCUSSION AND C ONCLUSION

Original: We propose a novel and principled framework RulE to jointly represent entities, relations and logical rules in a unified embedding space.
Revised: We propose a novel and principled framework RulE to jointly represent entities, relations and logical rules in a unified embedding space.

Original: It improves the generalization capability of KGE and improves logical rule reasoning through absorbing the best of both.
Revised: It improves the generalization capability of KGE and improves logical rule reasoning through absorbing the best of both.

Original: However, similar to prior work using logical rules, RulE needs to enumerate all paths between entity pairs, making it difficult to scale.
Revised: However, similar to prior work using logical rules, RulE needs to enumerate all paths between entity pairs, making it difficult to scale.

Original: In the future, we plan to explore more efficient and effective algorithms, e.g., replace logical rules completely with rule embeddings during inference, and consider more complex rules.
Revised: In the future, we plan to explore more efficient and effective algorithms, e.g., replace logical rules completely with rule embeddings during inference, and consider more complex rules.

Original: A M ORE DETAILS OF IMPLEMENTING THE GROUNDING PROCESS
Revised: A M ORE DETAILS OF IMPLEMENTING THE GROUNDING PROCESS

Original: This section introduces how to implement the grounding process.
Revised: This section introduces how to implement the grounding process.

Original: It is slightly different from our proposed framework but can empirically achieve better results.
Revised: It is slightly different from our proposed framework but can empirically achieve better results.

Original: Recall that R and r are the embeddings of logical rules and relations, respectively, whose dimensions are k .
Revised: Recall that R and r are the embeddings of logical rules and relations, respectively, whose dimensions are k .

Original: In practice, we do not need to restrict the dimension of R as k .
Revised: In practice, we do not need to restrict the dimension of R as k .

Original: With the relation embeddings and rule embeddings optimized in the pre-training process, we can compute the confidence score of each rule.
Revised: With the relation embeddings and rule embeddings optimized in the pre-training process, we can compute the confidence score of each rule.

Original: Specifically, given a logical rule R i : r i 1 ∧ r i 2 ∧ ...
Revised: Specifically, given a logical rule R i : r i 1 ∧ r i 2 ∧ ...

Original: ∧ r i l → r i l +1 , the learned RNN outputs a derived embedding:
Revised: ∧ r i l → r i l +1 , the learned RNN outputs a derived embedding:

Original: [Equation]
Revised: [Equation]

Original: where the dimension of r ′ i
Revised: where the dimension of r ′ i

Original: l +1 is k , the same as the rule head embedding r i l +1 .
Revised: l +1 is k , the same as the rule head embedding r i l +1 .

Original: The distance between r ′ i l +1 and r i l +1 measures the uncertainty of the logical rule, thus the confidence function of R i is formulated as:
Revised: The distance between r ′ i l +1 and r i l +1 measures the uncertainty of the logical rule, thus the confidence function of R i is formulated as:

Original: [Equation]
Revised: [Equation]

Original: (13) where γ r is the fixed rule margin defined in the pre-training process, and
Revised: (13) where γ r is the fixed rule margin defined in the pre-training process, and

Original: c i is a k -dimensional vector.
Revised: c i is a k -dimensional vector.

Original: Each element of c i represents a way of weighting the rule R i .
Revised: Each element of c i represents a way of weighting the rule R i .

Original: Instead of the scalar w i defined in Eq.
Revised: Instead of the scalar w i defined in Eq.

Original: (9), we use a more fine-grained way to represent the confidence of each logical rule.
Revised: (9), we use a more fine-grained way to represent the confidence of each logical rule.

Original: When answering a query ( h , r , ? ) , we ground logical rules on the KG and yield different candidate answers.
Revised: When answering a query ( h , r , ? ) , we ground logical rules on the KG and yield different candidate answers.

Original: For each candidate answer t ′ , we can define the following function:
Revised: For each candidate answer t ′ , we can define the following function:

Original: [Equation]
Revised: [Equation]

Original: where LN is the layer normalization operation, L ′ is the set of logical rules activated by ( h , r , t ′ ) ,
Revised: where LN is the layer normalization operation, L ′ is the set of logical rules activated by ( h , r , t ′ ) ,

Original: R ( g ) i is the grounding-stage rule embedding of R i and P ( h , R i , t ′ ) is the set of supports of the rule
Revised: R ( g ) i is the grounding-stage rule embedding of R i and P ( h , R i , t ′ ) is the set of supports of the rule

Original: R i which starts from h and ends at t ′ .
Revised: R i which starts from h and ends at t ′ .

Original: Eq.
Revised: Eq.

Original: (14) encodes a way to activate the grounding-stage rule embedding with rule confidence.
Revised: (14) encodes a way to activate the grounding-stage rule embedding with rule confidence.

Original: There are k ways in total; thus, we can aggregate them to calculate the grounding score, i.e.,
Revised: There are k ways in total; thus, we can aggregate them to calculate the grounding score, i.e.,

Original: [Equation]
Revised: [Equation]

Original: Here, AGG is an aggregator, which can aggregate all v j ( h , r , t ′ ) by sum, mean, max or min.
Revised: Here, AGG is an aggregator, which can aggregate all v j ( h , r , t ′ ) by sum, mean, max or min.

Original: In experiments, we adopt the sum in WN18RR and FB15k-237 as well as the mean in UMLS and
Revised: In experiments, we adopt the sum in WN18RR and FB15k-237 as well as the mean in UMLS and

Original: Kinship.
Revised: Kinship.

Original: Once we have the grounding rule score s agg ( h , r , t ′ ) for each candidate answer, we further compute the probability of the true answer by a softmax function.
Revised: Once we have the grounding rule score s agg ( h , r , t ′ ) for each candidate answer, we further compute the probability of the true answer by a softmax function.

Original: Finally, we optimize the MLP and grounding-stage rule embedding by maximizing the log likelihood of the true answers based on these training triplets.
Revised: Finally, we optimize the MLP and grounding-stage rule embedding by maximizing the log likelihood of the true answers based on these training triplets.

Original: In fact, if we aggregate v j by sum and remove the layer normalization operation, Eq.
Revised: In fact, if we aggregate v j by sum and remove the layer normalization operation, Eq.

Original: (15) can be reduce to Eq.
Revised: (15) can be reduce to Eq.

Original: The proof is shown as follows:
Revised: The proof is shown as follows:

Original: Proof: We remove the layer normalization and rewrite Eq.
Revised: Proof: We remove the layer normalization and rewrite Eq.

Original: (14) and Eq.
Revised: (14) and Eq.

Original: [Equation]
Revised: [Equation]

Original: By aggregating v j by sum and combining Eq.
Revised: By aggregating v j by sum and combining Eq.

Original: (14) and Eq.
Revised: (14) and Eq.

Original: (15), we obtain:
Revised: (15), we obtain:

Original: [Equation]
Revised: [Equation]

Original: Based on Eq.
Revised: Based on Eq.

Original: [Equation]
Revised: [Equation]

Original: we imply that:
Revised: we imply that:

Original: [Equation]
Revised: [Equation]

Original: Thus we continue to simplify Eq.
Revised: Thus we continue to simplify Eq.

Original: [Equation]
Revised: [Equation]

Original: This completes the proof.
Revised: This completes the proof.

Original: B I NTRODUCTION OF RNNL OGIC +
Revised: B I NTRODUCTION OF RNNL OGIC +

Original: RNNLogic (Qu et al., 2020) aims to learn logical rules from knowledge graphs, which simultaneously trains a rule generator as well as a reasoning predictor.
Revised: RNNLogic (Qu et al., 2020) aims to learn logical rules from knowledge graphs, which simultaneously trains a rule generator as well as a reasoning predictor.

Original: The former is used to generate rules while the latter learns the confidence of generated rules.
Revised: The former is used to generate rules while the latter learns the confidence of generated rules.

Original: RulE applies pre-defined logical rules to perform knowledge graph reasoning.
Revised: RulE applies pre-defined logical rules to perform knowledge graph reasoning.

Original: To compare with it, we only focus on the reasoning predictor
Revised: To compare with it, we only focus on the reasoning predictor

Original: RNNLogic+, which is also a more powerful model than RNNLogic for exploiting logical rules.
Revised: RNNLogic+, which is also a more powerful model than RNNLogic for exploiting logical rules.

Original: Its details are described in this section.
Revised: Its details are described in this section.

Original: Given a KG containing a set of triplets and logical rules, RNNlogic+ associates each logical rule with a grounding-stage rule embedding R ( g ) (following the grounding process of RulE), for a query ( h , r , ? ) , it grounds logical rules into the KG, finding different candidate answers.
Revised: Given a KG containing a set of triplets and logical rules, RNNlogic+ associates each logical rule with a grounding-stage rule embedding R ( g ) (following the grounding process of RulE), for a query ( h , r , ? ) , it grounds logical rules into the KG, finding different candidate answers.

Original: For each candidate answer t ′ , RNNLogic+ aggregates all the rule embeddings of those activated rules, each weighted by the number of paths activating this rule (# supports).
Revised: For each candidate answer t ′ , RNNLogic+ aggregates all the rule embeddings of those activated rules, each weighted by the number of paths activating this rule (# supports).

Original: This is a different point from RulE that RulE additionally employs the confidence scores of rules as soft multi-hot encoding instead of the hard multi-hot encoding of RNNLogic.
Revised: This is a different point from RulE that RulE additionally employs the confidence scores of rules as soft multi-hot encoding instead of the hard multi-hot encoding of RNNLogic.

Original: Then an MLP is further used to project the aggregated embedding to the grounding rule score:
Revised: Then an MLP is further used to project the aggregated embedding to the grounding rule score:

Original: [Equation] [Equation]
Revised: [Equation] [Equation]

Original: where LN is the layer normalization operation, AGG is the PNA aggregator (Corso et al., 2020), L ′ is the set of activated rules for ( h , r , t ′ ) , and P ( h , R i , t ′ ) is the set of supports of the rule R i which starts from h and ends at t ′ .
Revised: where LN is the layer normalization operation, AGG is the PNA aggregator (Corso et al., 2020), L ′ is the set of activated rules for ( h , r , t ′ ) , and P ( h , R i , t ′ ) is the set of supports of the rule R i which starts from h and ends at t ′ .

Original: Once RNNLogic+ has the score of each candidate answer, it can use a softmax function to compute the probability of the true answer.
Revised: Once RNNLogic+ has the score of each candidate answer, it can use a softmax function to compute the probability of the true answer.

Original: Finally, it trains the MLP and rule embeddings by maximizing the log likelihood of the true answers based on training triplets.
Revised: Finally, it trains the MLP and rule embeddings by maximizing the log likelihood of the true answers based on training triplets.

Original: During inference, there are two variants of models:
Revised: During inference, there are two variants of models:

Original: • RNNLogic+ ( rule. ):
Revised: • RNNLogic+ ( rule. ):

Original: This variant only uses the logical rules for knowledge graph reasoning.
Revised: This variant only uses the logical rules for knowledge graph reasoning.

Original: Specifically, we calculate the score of each candidate answer only defined in Eq.
Revised: Specifically, we calculate the score of each candidate answer only defined in Eq.

Original: 21 (i.e., s r ( h , r , t ′ ) ).
Revised: 21 (i.e., s r ( h , r , t ′ ) ).

Original: • RNNLogic+ ( emb.+rule. ):
Revised: • RNNLogic+ ( emb.+rule. ):

Original: It uses RotatE (Sun et al., 2019) to pretrain knowledge graph embeddings models, which is another difference from RulE that RulE jointly models KGE and logical rules in the same space to learn entity, relation and logical rule embeddings.
Revised: It uses RotatE (Sun et al., 2019) to pretrain knowledge graph embeddings models, which is another difference from RulE that RulE jointly models KGE and logical rules in the same space to learn entity, relation and logical rule embeddings.

Original: In the inference process, the same as RulE, it linearly combines the grounding rule score and KGE score as the final prediction score,
Revised: In the inference process, the same as RulE, it linearly combines the grounding rule score and KGE score as the final prediction score,

Original: i
Revised: i

Original: [Table]
Revised: [Table]

Original: e.,
Revised: e.,

Original: [Equation]
Revised: [Equation]

Original: where KGE ( h , r , t ′ ) is the KGE score calculated with entity and relation embeddings optimized by RotatE and α is a positive hyperparameter weighting the importance of the knowledge graph embedding score.
Revised: where KGE ( h , r , t ′ ) is the KGE score calculated with entity and relation embeddings optimized by RotatE and α is a positive hyperparameter weighting the importance of the knowledge graph embedding score.

Original: C E XPERIMENT SETUP C. D ATA STATISTICS
Revised: C E XPERIMENT SETUP C. D ATA STATISTICS

Revised: [We use the same splits as RNNLogic and mine logic rules by RNNLogic.

Revised: Each relation has about 100 or 200 logic rules, and the length of rules is no more than 3.

Original: The statistics of datasets are shown in Table 4.
Revised: More statistics of datasets are shown in Table [Table]

Original: [Table]
Revised: [Table]

Original: C. D ATA PROCESS
Revised: C. D ATA PROCESS

Original: Most rules mined by rule mining systems are not chain rules.
Revised: Most rules mined by rule mining systems are not chain rules.

Original: They usually need to be transformed into chain rules by inversing some relations.
Revised: They usually need to be transformed into chain rules by inversing some relations.

Original: Considering r 1 ( x, y )
Revised: Considering r 1 ( x, y )

Original: ∧ r 2 ( x, z ) → r 3 ( y, z ) as an example, with replacing r 1 ( x, y ) with r − 1 1 ( y, x ) , the rule can be converted into chain rule r 1 ( y, x ) − 1 ∧ r 2 ( x, z ) → r 3 ( y, z ) .
Revised: ∧ r 2 ( x, z ) → r 3 ( y, z ) as an example, with replacing r 1 ( x, y ) with r − 1 1 ( y, x ) , the rule can be converted into chain rule r 1 ( y, x ) − 1 ∧ r 2 ( x, z ) → r 3 ( y, z ) .

Original: Based on the above, for data processing, we need to add a inverse version triplet ( t , r − 1 , h ) for each triplet ( h , r , t ) , representing the inverse relationship r − 1 between entity t and entity h.
Revised: Based on the above, for data processing, we need to add a inverse version triplet ( t , r − 1 , h ) for each triplet ( h , r , t ) , representing the inverse relationship r − 1 between entity t and entity h.

Original: C. H YPERPARAMETERS SETTING
Revised: C. H YPERPARAMETERS SETTING

Original: For the pre-training of RulE, the ranges of the hyperparameters for the grid search are: embedding dimension k ∈ { 100 , 200 , 500 , 1000 } , learning rate lr ∈ { 0 . 00001 , 0 . 00005 , 0 . 0001 } , batch size of triplets and rules b ∈ { 256 , 512 , 1024 } , negative sample size b n ∈ { 128 , 256 , 512 } , self-adversarial sampling temperature α ∈ { 0 . 5 , 1 . 0 } and fixed margin γ t , γ r ∈ { 6 , 12 , 24 , 32 } .
Revised: For the pre-training of RulE, the ranges of the hyperparameters for the grid search are: embedding dimension k ∈ { 100 , 200 , 500 , 1000 } , learning rate lr ∈ { 0 . 00001 , 0 . 00005 , 0 . 0001 } , batch size of triplets and rules b ∈ { 256 , 512 , 1024 } , negative sample size b n ∈ { 128 , 256 , 512 } , self-adversarial sampling temperature α ∈ { 0 . 5 , 1 . 0 } and fixed margin γ t , γ r ∈ { 6 , 12 , 24 , 32 } .

Original: During the grounding process.
Revised: During the grounding process.

Original: We tune the learning rate lr g ∈ { 0 . 0005 , 0 .
Revised: We tune the learning rate lr g ∈ { 0 . 0005 , 0 .

Original: 001 , 0 . 05 } , the dimension of grounding-state rule embedding p ∈ { 100 , 200 , 500 } .
Revised: 001 , 0 . 05 } , the dimension of grounding-state rule embedding p ∈ { 100 , 200 , 500 } .

Original: For inference, we combine embedding-based reasoning and rule-based reasoning with the hyperparameter α ∈ { 0 . 5 , 1 . 0 , 3 . 0 , 5 . 0 } .
Revised: For inference, we combine embedding-based reasoning and rule-based reasoning with the hyperparameter α ∈ { 0 . 5 , 1 . 0 , 3 . 0 , 5 . 0 } .

Original: D A VARIANT OF MODELING RULES
Revised: D A VARIANT OF MODELING RULES

Original: Besides using RNN (Graves, 2012) to model logical rules, we propose another variant to model the relationship between logical rules and relations, which is called ADD .
Revised: Besides using RNN (Graves, 2012) to model logical rules, we propose another variant to model the relationship between logical rules and relations, which is called ADD .

Original: Recall that we are given the sequence of all relations in the rule body, e.g., [ r 1 , r 2 , . . .
Revised: Recall that we are given the sequence of all relations in the rule body, e.g., [ r 1 , r 2 , . . .

Original: , r l ] , ADD aims to generate the rule head.
Revised: , r l ] , ADD aims to generate the rule head.

Original: To respect the relation order of logical rules, we associate each rule with a rule embedding,
Revised: To respect the relation order of logical rules, we associate each rule with a rule embedding,

Original: R =
Revised: R =

Original: [ R 1 , R 2 , ..., R l ] , R ∈ R kl , where k is the dimension of relation embedding and l is the length of the logical rule.
Revised: [ R 1 , R 2 , ..., R l ] , R ∈ R kl , where k is the dimension of relation embedding and l is the length of the logical rule.

Original: Based on these definitions, we can formulate the distance between the rule body and rule head as:
Revised: Based on these definitions, we can formulate the distance between the rule body and rule head as:

Original: [Equation]
Revised: [Equation]

Original: where ◦ is an element-wise product.
Revised: where ◦ is an element-wise product.

Original: Then we use Eq.
Revised: Then we use Eq.

Original: (7) to further define loss function of logical rules.
Revised: (7) to further define loss function of logical rules.

Original: E A BLATION STUDY E. E MBEDDING LOGICAL RULES BASED ON T RANS E
Revised: E A BLATION STUDY E. E MBEDDING LOGICAL RULES BASED ON T RANS E

Original: We first compare RulE ( emb. ) with KGE models.
Revised: We first compare RulE ( emb. ) with KGE models.

Original: As shown in Table 3, the two variants using
Revised: As shown in Table 3, the two variants using

Original: TransE (Bordes et al., 2013) and ComplEx (Trouillon et al., 2016) as KGE models are called RulE ( emb. TransE ) and RulE ( emb.
Revised: TransE (Bordes et al., 2013) and ComplEx (Trouillon et al., 2016) as KGE models are called RulE ( emb. TransE ) and RulE ( emb.

Original: ComplEx. )
Revised: ComplEx. )

Original: respectively.
Revised: respectively.

Original: They both obtain superior performance to the pure corresponding KGE models.
Revised: They both obtain superior performance to the pure corresponding KGE models.

Original: We also further compare with other rule-enhance KGE models.
Revised: We also further compare with other rule-enhance KGE models.

Original: In experiment setup, RulE ( emb. TransE ) uses the same logical rules as KALE (Guo et al., 2016);
Revised: In experiment setup, RulE ( emb. TransE ) uses the same logical rules as KALE (Guo et al., 2016);

Original: RulE ( emb.
Revised: RulE ( emb.

Original: ComplEx ) uses the same logical rules as ComplEx-NNE-AER (Ding et al., 2018).
Revised: ComplEx ) uses the same logical rules as ComplEx-NNE-AER (Ding et al., 2018).

Original: From the comparison, RulE ( emb. TransE ) and RulE ( emb.
Revised: From the comparison, RulE ( emb. TransE ) and RulE ( emb.

Original: ComplEx ) both achieve better performance than KALE and RUGE, respectively.
Revised: ComplEx ) both achieve better performance than KALE and RUGE, respectively.

Original: From Table 5, we also see that RulE ( emb.
Revised: From Table 5, we also see that RulE ( emb.

Original: ComplEx ) is slightly worse than ComplEx-NNE-AER.
Revised: ComplEx ) is slightly worse than ComplEx-NNE-AER.

Original: The reason is probably that ComplEx-NNEAER additionally injects the regularization terms on entity representations but RulE does not, and
Revised: The reason is probably that ComplEx-NNEAER additionally injects the regularization terms on entity representations but RulE does not, and

Original: ComplEx-NNE-AER is based on origin ComplEx, which performs better than ComplEx we use.
Revised: ComplEx-NNE-AER is based on origin ComplEx, which performs better than ComplEx we use.

Original: We further study the effect made by logical rules on embedding-based models with more datasets (i.e., UMLS and Kinship).
Revised: We further study the effect made by logical rules on embedding-based models with more datasets (i.e., UMLS and Kinship).

Original: We rerun KALE (Guo et al., 2016) on UMLS and Kinship datasets.
Revised: We rerun KALE (Guo et al., 2016) on UMLS and Kinship datasets.

Original: They both use the same splits and logical rules as RulE. However, KALE uses pairwise ranking loss function while TransE and RulE use logistic loss function.
Revised: They both use the same splits and logical rules as RulE. However, KALE uses pairwise ranking loss function while TransE and RulE use logistic loss function.

Original: Many experiments indicate that logistic loss usually performs better than pairwise ranking loss.
Revised: Many experiments indicate that logistic loss usually performs better than pairwise ranking loss.

Original: Thus the results of KALE are worse than
Revised: Thus the results of KALE are worse than

Original: TransE in Table 5.
Revised: TransE in Table 5.

Original: It is not easy to refactor due to their old coding.
Revised: It is not easy to refactor due to their old coding.

Original: So we focus more on TransE,
Revised: So we focus more on TransE,

Original: RulE ( emb.
Revised: RulE ( emb.

Original: TransE RNN )and RulE ( emb.
Revised: TransE RNN )and RulE ( emb.

Original: TransE ADD ).
Revised: TransE ADD ).

Original: From the results shown in Table 5, we can see that whatever RNN or ADD, RulE ( emb. ) achieves better results than TransE. Especially for ADD, RulE ( emb.
Revised: From the results shown in Table 5, we can see that whatever RNN or ADD, RulE ( emb. ) achieves better results than TransE. Especially for ADD, RulE ( emb.

Original: TransE ADD ) obtained 13.9% and 14.2% MRR improvements on UMLS and
Revised: TransE ADD ) obtained 13.9% and 14.2% MRR improvements on UMLS and

Original: Kinship respectively.
Revised: Kinship respectively.

Original: [Table]
Revised: [Table]

Original: [Table] 
Revised: [Table] H@ H@ H@

Original: H
Revised: MRR H@ H@ H@

Original: [Table]
Revised: [Table]

Original: RulE ( w/o confidence ) 0.
Revised: [Table] [Table]

Revised: [Table]

Original: RulE ( with confidence ) 0.
Revised: RulE ( with confidence ) 0.

Original: E. R ULE CONFIDENCE IMPROVE RULE - BASED REASONING
Revised: E. R ULE CONFIDENCE IMPROVE RULE - BASED REASONING

Original: To fully verify our conclusion that rule confidence can promote rule-based reasoning, we focus on the grounding stage and remove the rule confidence, (i.e. assignment each w i with 1 on Eq.
Revised: To fully verify our conclusion that rule confidence can promote rule-based reasoning, we focus on the grounding stage and remove the rule confidence, (i.e. assignment each w i with 1 on Eq.

Original: (9)), which denoted it as RulE ( w/o confidence ).
Revised: (9)), which denoted it as RulE ( w/o confidence ).

Original: Both RulE ( w/o confidence ) and RulE ( with confidence ) use the same hyperparameters and tune them based on the validation sets.
Revised: Both RulE ( w/o confidence ) and RulE ( with confidence ) use the same hyperparameters and tune them based on the validation sets.

Original: From Table 6, we can see that RulE ( with confidence ) produce more accurate results than RulE ( w/o confidence), which demonstrates our the effectiveness of soft multi-hot encoding for grounding-stage rule embeddings.
Revised: From Table 6, we can see that RulE ( with confidence ) produce more accurate results than RulE ( w/o confidence), which demonstrates our the effectiveness of soft multi-hot encoding for grounding-stage rule embeddings.