Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
A Review of Relational Machine Learning for Knowledge Graphs CVML Reading Group Xiao Lin M. Nickel, K. Murphy, V. Tresp, E. Gabrilovich. “A Review of Relational Machine Learning for Knowledge Graphs. ” arXiv 2015. 2 • VQA • Knowledge base • MRF vs embeddings 3 • The relational learning problem • Neural embedding models 4 “Leonard Nimoy was an actor who played the character Spock in the science-fiction movie Star Trek” 5 “Leonard Nimoy was an actor who played the character Spock in the science-fiction movie Star Trek” subject Leonard Nimoy Leonard Nimoy Leonard Nimoy Spock Star Trek predicate profession starred in played character in genre object Actor Star Trek Spock Star Trek Science-fiction “SPO triples” 6 Knowledge Graphs “Leonard Nimoy was an actor who played the character Spock in the science-fiction movie Star Trek” Leonard Nimoy Leonard Nimoy Leonard Nimoy Spock Star Trek profession starred in played character in genre Actor Star Trek Spock Star Trek Science-fiction 7 Knowledge Graphs “Leonard Nimoy was an actor who played the character Spock in the science-fiction movie Star Trek” Actor Spock Science-fiction profession played character in starred in Leonard Nimoy genre Star Trek 8 Knowledge Graphs a.k.a. Relational data a.k.a. Linked data Actor Spock Science-fiction profession played character in starred in genre Leonard Nimoy Star Trek 9 Knowledge Graphs a.k.a. a.k.a. a.k.a. a.k.a. a.k.a. a.k.a. Semantic network (1960s) Knowledge base (1970s) (2000s) Semantic web (2010s) Big data Knowledge graph (2012) Artificial Intelligence Actor Spock Science-fiction profession played character in starred in genre Leonard Nimoy Star Trek 10 Query Knowledge Graphs Was Leonard Nimoy in Star Trek? Actor Spock Science-fiction Leonard Nimoy starred in Star Trek profession played character in starred in genre Leonard Nimoy Star Trek 11 Query Knowledge Graphs Was Leonard Nimoy in Star Trek? Actor Spock Science-fiction Leonard Nimoy starred in Star Trek True profession played character in starred in genre Leonard Nimoy Star Trek 12 Query Knowledge Graphs Which character did Leonard Nimoy play in Star Trek? Leonard Nimoy played (_X_) ∧ (_X_) character in Star Trek Actor Spock Science-fiction profession played character in starred in genre Leonard Nimoy Star Trek 13 Query Knowledge Graphs Which character did Leonard Nimoy play in Star Trek? Leonard Nimoy played (Spock) ∧ True (Spock) character in Star Trek Actor Spock Science-fiction profession played character in starred in genre Leonard Nimoy Star Trek True 14 Query Knowledge Graphs Which character did Leonard Nimoy play in Star Trek? Leonard Nimoy played (Spock) ∧ True (Spock) character in Star Trek Actor Spock Science-fiction profession played character in starred in genre Leonard Nimoy Star Trek True 15 Query Knowledge Graphs Was Leonard Nimoy in Star Trek? Actor Spock Science-fiction Leonard Nimoy starred in Star Trek profession played character in genre Leonard Nimoy Star Trek 16 Relational Machine Learning • Goal: Infer relationships between objects and answer queries Database of (partially) annotated relations 17 Relational Machine Learning • Goal: Infer relationships between objects and answer queries Database of (partially) annotated relations Learn rules or models * ℱ ( * , ) = 0/1 18 Relational Machine Learning • Goal: Infer relationships between objects and answer queries Database of (partially) annotated relations Learn rules or models * ℱ ( Answer queries on unseen relations * , ) = 0/1 19 Relational Machine Learning • Goal: Infer relationships between objects and answer queries Database of (partially) annotated relations WordNet Wikipedia Freebase YAGO NELL ReVerb Knowledge Vault Web …. Learn rules or models ILP MLN Random walk Word2Vec Tensor factorization Neural embeddings … Answer queries on unseen relations (S,P,O) exist=1 or not=0 (?,P,O) (S,P,?) (S,P1,?) ∧ (?,P2,O) 20 Relational Machine Learning • Applications • Bioinformatics Given that: Some DNA produces some protein Some protein has some function Some protein interacts some other protein What does this protein do? 21 Relational Machine Learning • Applications • Bioinformatics • Question Answering (QA) “Find a table for 4 tonight in Chicago.” “Read my latest emails” “How’s the weather tomorrow?” “Why did the chickens cross the road?” 22 Relational Machine Learning • Applications • Bioinformatics • Question Answering (QA) • Search 23 Relational Machine Learning • Applications • Bioinformatics • Question Answering (QA) • Search 24 Relational Machine Learning • Applications • • • • Bioinformatics Question Answering (QA) Search Visualization Reviews for La Baguette Bakery, Stanford, CA [Wang et al. 2012] 25 Relational Machine Learning • Applications • • • • • • • Bioinformatics Question Answering (QA) Search Visualization Social networks Recommendation Controversial stuff http://arstechnica.co.uk/security/2016/02/the-nsas-skynetprogram-may-be-killing-thousands-of-innocent-people/ 26 Relational Machine Learning What I really do 27 Relational Machine Learning • Goal: Infer relationships between objects and answer queries Database of (partially) annotated relations Learn rules or models * ℱ ( Answer queries on unseen relations * , ) = 0/1 28 Relational Machine Learning • Goal: Infer relationships between objects and answer queries Database of (partially) annotated relations WordNet Wikipedia Freebase YAGO NELL ReVerb Knowledge Vault Web …. Learn rules or models ILP MLN Random walk Word2Vec Tensor factorization Neural embeddings … Answer queries on unseen relations (S,P,O) exist=1 or not=0 (S,?,O) (S,P,?) (S,P1,?) ∧ (?,P2,O) 29 Relational Machine Learning • Challenges Database of (partially) annotated relations • Quantity • Collaborative • Automatic IE • Negative examples • Locally closed world • Noise • Grounding • Barrack Obama • /m/03gh4 • Bias 30 Relational Machine Learning • Challenges Database of (partially) annotated relations • Quantity • Collaborative • Automatic IE • Negative examples • Locally closed world • Noise • Grounding Learn rules or models • • • • Accuracy Efficiency Scalability Interpretability • Barrack Obama • /m/03gh4 • Bias 31 Relational Machine Learning • Challenges Database of (partially) annotated relations • Quantity • Collaborative • Automatic IE • Negative examples • Locally closed world • Noise • Grounding Learn rules or models • • • • Accuracy Efficiency Scalability Interpretability Answer queries on unseen relations • Fast inference • Scale to complex queries • Conjunctions • Barrack Obama • /m/03gh4 • Bias 32 Relational Machine Learning Models • Symbolic vs. Connectionist 33 Relational Machine Learning Models • Symbolic vs. Connectionist • MRF vs. Embedding • MRF (Markov Logic Nets) Unobserved relations are jointly inferred Learn a set of rules (factors) and weights (MCMC) Infer all unobserved relations jointly by maximizing probability -------------------This is not an MRF---------------------Actor Spock Science-fiction profession played character in genre Leonard Nimoy Star Trek -------------------This is not an MRF---------------------𝒓: ∀𝒙∀𝒚∀𝒛 𝑷𝒍𝒂𝒚𝒆𝒅_𝒊𝒏(𝒙, 𝒚) ∧ 𝑪𝒉𝒂𝒓𝒂𝒄𝒕𝒆𝒓_𝒊𝒏(𝒚, 𝒛) → 𝑺𝒕𝒂𝒓𝒓𝒆𝒅_𝒊𝒏(𝒙, 𝒚) Satisfied 𝑥𝑟 times Weight=𝜃𝑟 𝑆𝑤𝑜𝑟𝑙𝑑 = 𝜃𝑟 𝑥𝑟 𝑟∈𝑅𝑢𝑙𝑒𝑠 34 Relational Machine Learning Models • Symbolic vs. Connectionist • MRF vs. Embedding • MRF • Embedding (RESCAL) Unobserved relations are independent given SPO embeddings Learn SPO embeddings (matrix/tensor factorization, neural nets) Predict relations Actor Spock Science-fiction profession played character in genre Leonard Nimoy Star Trek SPO Embeddings 𝑆𝑐𝑜𝑟𝑒 𝑆, 𝑃, 𝑂 = 𝑒𝑆 ⊗ 𝑒𝑂 𝑒𝑃 = 𝑒𝑆𝑇 𝐴𝑃 𝑒𝑂 35 -1 Cat Cat ≠Dog 1 Dog 1 -1 Cat -1 1 Dog -1 36 Relational Machine Learning Models • Symbolic vs. Connectionist • MRF vs. Embedding • (S,P,O)=0/1 classification performance [Nickel et al. 2015] 37 Relational Machine Learning Models • Symbolic vs. Connectionist • MRF vs. Embedding • Graph mining Predict relations using graph features, usually independently given graph features In degree, out degree Common ancestor Random walk S->O paths … Actor Spock Science-fiction profession played character in genre Leonard Nimoy Star Trek 𝑆𝑐𝑜𝑟𝑒 𝑆, 𝑃, 𝑂 = 𝑤𝑃 𝜙𝑆𝑃𝑂 38 Neural Embedding Models • Predicting a score based on Subject, Object, Predicate embeddings 39 Neural Embedding Models • Predicting a score based on Subject, Object, Predicate embeddings S LookupTable O P LookupTable 𝑒𝑆 𝑒𝑂 𝑒𝑃 40 Neural Embedding Models • Predicting a score based on Subject, Object, Predicate embeddings S LookupTable O P LookupTable 𝑒𝑆 𝑒𝑂 Something that allows backprop 𝑆𝑐𝑜𝑟𝑒(𝑆, 𝑃, 𝑂) 𝑒𝑃 41 Neural Embedding Models • Predicting a score based on Subject, Object, Predicate embeddings P S LookupTable O 𝑒𝑆 𝑒𝑂 Something that allows backprop 𝑆𝑐𝑜𝑟𝑒𝑃 (𝑆, 𝑂) 42 Neural Embedding Models • Predicting a score based on Subject, Object, Predicate embeddings E-MLP 𝑒𝑆 Linear Linear 𝑆𝑐𝑜𝑟𝑒𝑃 (𝑆, 𝑂) Linear Linear 𝑆𝑐𝑜𝑟𝑒 (𝑆, 𝑃, 𝑂) 𝑒𝑂 ER-MLP [Dong et al. 2014] 𝑒𝑆 𝑒𝑂 𝑒𝑃 43 Neural Embedding Models • Predicting a score based on Subject, Object, Predicate embeddings Structured Embedding (SE) [Bordes et al. 2011] 𝑒𝑆 𝑒𝑂 𝑒𝑆 TransE Linear Linear -L1 distance 𝑆𝑐𝑜𝑟𝑒𝑃 (𝑆, 𝑂) -L2 distance 𝑆𝑐𝑜𝑟𝑒(𝑆, 𝑃, 𝑂) CAddTable 𝑒𝑂 [Bordes et al. 2013] 𝑒𝑃 𝑒𝑆 TransR Linear CAddTable 𝑒𝑂 [Lin et al. 2015] 𝑒𝑃 Linear -L2 distance 𝑆𝑐𝑜𝑟𝑒(𝑆, 𝑃, 𝑂) 44 Neural Embedding Models • Predicting a score based on Subject, Object, Predicate embeddings RESCAL [Nickel et al. 2011] NTN [Socher et al. 2013] HolE [Nickel et al. 2015] 𝑒𝑆 𝑒𝑆𝑇 𝐴𝑃 𝑒𝑂 𝑆𝑐𝑜𝑟𝑒𝑃 (𝑆, 𝑂) 𝑒𝑂 𝑒𝑆 𝑒𝑂 𝑒𝑆 𝑒𝑂 𝑒𝑃 𝑒𝑆𝑇 𝒜𝑃 𝑒𝑂 Linear 𝑒𝑃𝑇 (𝑒𝑆 ∗ 𝑒𝑂 ) 𝑆𝑐𝑜𝑟𝑒𝑃 (𝑆, 𝑂) 𝑆𝑐𝑜𝑟𝑒(𝑆, 𝑃, 𝑂) 45 Neural Embedding Models • WordNet (WN18) • • • • Words 40943 S&O (words) 18 Predicates (relations) 151442 triples Search Engine Has_instance Direct hypernym Trademark Google Yahoo Ask Jeeves 46 Neural Embedding Models • WordNet (WN18) • • • • • Freebase (FB15k) • • • • Words 40943 S&O (words) 18 Predicates (relations) 151442 triples General facts 14951 S&O (words) 1345 Predicates (relations) 592213 triples Opus 13 Composition type Also_known_as Piano sonata Notable_for Pathétique Notable_for /type/object/key Top_equivalent_webpage Pianosonates http://imslp.org/wiki/index.html?curid=1410 47 Neural Embedding Models • WordNet (WN18) • • • • Words 40943 S&O (words) 18 Predicates (relations) 151442 triples • Freebase (FB15k) • • • • General facts 14951 S&O (words) 1345 Predicates (relations) 592213 triples • (?,P,O) => S from all possible {S} 48 Neural Embedding Models • WordNet (WN18) • • • • Words 40943 S&O (words) 18 Predicates (relations) 151442 triples • Freebase (FB15k) • • • • General facts 14951 S&O (words) 1345 Predicates (relations) 592213 triples • (?,P,O) => S from all possible {S} • Locally Closed World Assumption (LCWA) • Multiple S • Raw • Filter: remove other true S’ 49 Neural Embedding Models • WordNet (WN18) • • • • • Freebase (FB15k) • • • • Words 40943 S&O (words) 18 Predicates (relations) 151442 triples General facts 14951 S&O (words) 1345 Predicates (relations) 592213 triples • Accuracy @1,3,10 • Mean Reciprocal Rank (MRR) 1 𝑀𝑅𝑅 = 𝑁 𝑛 𝑖=1 1 𝑅𝑎𝑛𝑘 50 Neural Embedding Models • [Nickel et al. 2015] • WordNet Method ER-MLP TransE TransR RESCAL HolE MRR Filtered Raw Accuracy @x (filtered?) 1 3 10 0.712 0.495 0.605 0.528 0.351 0.427 62.6 11.3 33.5 77.5 88.8 87.6 86.3 94.3 94.3 0.890 0.938 0.603 0.616 84.2 93.0 90.4 94.5 92.8 94.9 51 Neural Embedding Models • [Nickel et al. 2015] • Freebase Method ER-MLP TransE TransR RESCAL HolE MRR Filtered Raw Accuracy @x (filtered?) 1 3 10 0.288 0.463 0.346 0.155 0.222 0.198 17.3 29.7 21.8 31.7 57.8 40.4 50.1 74.9 58.2 0.354 0.524 0.189 0.232 23.5 40.2 40.9 61.3 58.7 73.9 52 Neural Embedding Models • [Nickel et al. 2015] • Freebase Method ER-MLP TransE TransR RESCAL HolE MRR Filtered Raw Accuracy @x (filtered?) 1 3 10 0.288 0.463 0.346 0.155 0.222 0.198 17.3 29.7 21.8 31.7 57.8 40.4 50.1 74.9 58.2 0.354 0.524 0.189 0.232 23.5 40.2 40.9 61.3 58.7 73.9 53 Neural Embedding Models • Qualitative: Word2Vec visualizations (again) [Mikolov et al. 2013] 54 Big Knowledge Graphs • Confident predictions [Dong et al. 2014] • Prob(SPO)>0.9 55 Big Knowledge Graphs • Confident predictions • Google Knowledge Vault [Dong et al. 2014] • Web information extraction • Neural embedding • Path ranking 56 Knowledge base and VQA • Incorporating entity and relation embeddings • Improving VQA model • When entities and relations become compositional 57