Presentation is loading. Please wait.

Presentation is loading. Please wait.

CPSC 422, Lecture 34Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 34 Apr, 10, 2015 Slide source: from Pedro Domingos UW & Markov.

Similar presentations


Presentation on theme: "CPSC 422, Lecture 34Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 34 Apr, 10, 2015 Slide source: from Pedro Domingos UW & Markov."— Presentation transcript:

1 CPSC 422, Lecture 34Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 34 Apr, 10, 2015 Slide source: from Pedro Domingos UW & Markov Logic: An Interface Layer for Artificial Intelligence Pedro Domingos and Daniel Lowd University of Washington, Seattle

2 CPSC 422, Lecture 342 Lecture Overview Finish Inference in MLN Probability of a formula, Conditional Probability Markov Logic: applications (422) Highlights from IUI conference Watson…. TA evaluation / Teaching Evaluations Final Exam (office hours, samples)

3 Markov Logic: Definition A Markov Logic Network (MLN) is a set of pairs (F, w) where F is a formula in first-order logic w is a real number Together with a set C of constants, It defines a Markov network with One binary node for each grounding of each predicate in the MLN One feature/factor for each grounding of each formula F in the MLN, with the corresponding weight w CPSC 422, Lecture 343 Grounding: substituting vars with constants

4 MLN features Cancer(A) Smokes(A)Friends(A,A) Friends(B,A) Smokes(B) Friends(A,B) Cancer(B) Friends(B,B) Two constants: Anna (A) and Bob (B) CPSC 422, Lecture 344

5 Computing Cond. Probabilities Let’s look at the simplest case P(ground literal | conjuction of ground literals, M L,C ) CPSC 422, Lecture 345 P(Cancer(B)| Smokes(A), Friends(A, B), Friends(B, A) ) To answer this query do you need to create (ground) the whole network? Cancer(A) Smokes(A) Friends(A,A) Friends(B,A) Smokes(B) Friends(A,B) Cancer(B) Friends(B,B)

6 Computing Cond. Probabilities Let’s look at the simplest case P(ground literal | conjuction of ground literals, M L,C ) CPSC 422, Lecture 346 P(Cancer(B)| Smokes(A), Friends(A, B), Friends(B, A) ) You do not need to create (ground) the part of the Markov Network from which the query is independent given the evidence

7 Computing Cond. Probabilities CPSC 422, Lecture 347 P(Cancer(B)| Smokes(A), Friends(A, B), Friends(B, A) ) You can then perform Gibbs Sampling in this Sub Network The sub network is determined by the formulas (the logical structure of the problem)

8 CPSC 422, Lecture 348 Lecture Overview Finish Inference in MLN Probability of a formula, Conditional Probability Markov Logic: applications (422) Highlights from IUI conference Watson…. TA evaluation / Teaching Evaluations Final Exam (office hours, samples)

9 9 Entity Resolution CPSC 422, Lecture 34 Determining which observations correspond to the same real-world objects (e.g., database records, noun phrases, video regions, etc) Crucial importance in many areas (e.g., data cleaning, NLP, Vision)

10 10 Entity Resolution: Example AUTHOR: H. POON & P. DOMINGOS TITLE: UNSUPERVISED SEMANTIC PARSING VENUE: EMNLP-09 AUTHOR: Hoifung Poon and Pedro Domings TITLE: Unsupervised semantic parsing VENUE: Proceedings of the 2009 Conference on Empirical Methods in Natural Language Processing AUTHOR: Poon, Hoifung and Domings, Pedro TITLE: Unsupervised ontology induction from text VENUE: Proceedings of the Forty-Eighth Annual Meeting of the Association for Computational Linguistics AUTHOR: H. Poon, P. Domings TITLE: Unsupervised ontology induction VENUE: ACL-10 SAME? CPSC 422, Lecture 34

11 11 Problem: Given citation database, find duplicate records Each citation has author, title, and venue fields We have 10 relations Author(bib,author) Title(bib,title) Venue(bib,venue) HasWord(author, word) HasWord(title, word) HasWord(venue, word) SameAuthor (author, author) SameTitle(title, title) SameVenue(venue, venue) SameBib(bib, bib) Entity Resolution (relations) CPSC 422, Lecture 34 indicate which words are present in each field; represent field equality; represents citation equality; relate citations to their fields

12 12 Predict citation equality based on words in the fields Title(b1, t1) ∧ Title(b2, t2) ∧ HasWord(t1,+word) ∧ HasWord(t2,+word) ⇒ SameBib(b1, b2) (NOTE: +word is a shortcut notation, you actually have a rule for each word e.g., Title(b1, t1) ∧ Title(b2, t2) ∧ HasWord(t1,”bayesian”) ∧ HasWord(t2,”bayesian” ) ⇒ SameBib(b1, b2) ) Same 1000s of rules for author Same 1000s of rules for venue Entity Resolution (formulas) CPSC 422, Lecture 34

13 13 Transitive closure SameBib(b1,b2) ∧ SameBib(b2,b3) ⇒ SameBib(b1,b3) SameAuthor(a1,a2) ∧ SameAuthor(a2,a3) ⇒ SameAuthor(a1,a3) Same rule for title Same rule for venue Entity Resolution (formulas) CPSC 422, Lecture 34 Link fields equivalence to citation equivalence – e.g., if two citations are the same, their authors should be the same Author(b1, a1) ∧ Author(b2, a2) ∧ SameBib(b1, b2) ⇒ SameAuthor(a1, a2) …and that citations with the same author are more likely to be the same Author(b1, a1) ∧ Author(b2, a2) ∧ SameAuthor(a1, a2) ⇒ SameBib(b1, b2) Same rules for title Same rules for venue

14 Benefits of MLN model CPSC 422, Lecture 3414 Standard non-MLN approach: build a classifier that given two citations tells you if they are the same or not, and then apply transitive closure New MLN approach: performs collective entity resolution, where resolving one pair of entities helps to resolve pairs of related entities e.g., inferring that a pair of citations are equivalent can provide evidence that the names AAAI-06 and 21st Natl. Conf. on AI refer to the same venue, even though they are superficially very different. This equivalence can then aid in resolving other entities.

15 15 Other MLN applications CPSC 422, Lecture 34 Information Extraction Co-reference Resolution (see lecture 1!) Robot Mapping (infer the map of an indoor environment from laser range data) Link-based Clustering (uses relationships among the objects in determining similarity) Ontologies extraction from Text …..

16 16 Summary of tutorial on MLN for NLP at NA-ACL (2010) We need to unify logical and statistical NLP Markov logic provides a language for this Syntax: Weighted first-order formulas Semantics: Feature templates of Markov nets Inference: Satisfiability, MCMC, lifted BP, etc. Learning: Pseudo-likelihood, VP, PSCG, ILP, etc. Growing set of NLP applications Open-source software: Alchemy Book: Domingos & Lowd, Markov Logic, Morgan & Claypool, 2009. alchemy.cs.washington.edu CPSC 422, Lecture 34

17 422 big picture Query Planning DeterministicStochastic Value Iteration Approx. Inference Full Resolution SAT Logics Belief Nets Markov Decision Processes and Partially Observable MDP Markov Chains and HMMs First Order Logics Description Logics/ Ontologies Temporal rep. Applications of AI More sophisticated reasoning Undirected Graphical Models Conditional Random Fields Reinforcement Learning Representation Reasoning Technique Prob relational models Prob CFG Markov Logics Hybrid CPSC 422, Lecture 34Slide 17

18 422 big picture Query Planning DeterministicStochastic Value Iteration Approx. Inference Full Resolution SAT Logics Belief Nets Markov Decision Processes and Partially Observable MDP Markov Chains and HMMs First Order Logics Ontologies Temporal rep. Applications of AI Approx. : Gibbs Undirected Graphical Models Conditional Random Fields Reinforcement Learning Representation Reasoning Technique Prob CFG Prob Relational Models Markov Logics Hybrid: Det +Sto Forward, Viterbi…. Approx. : Particle Filtering CPSC 422, Lecture 34Slide 18

19 CPSC 422, Lecture 3419 Lecture Overview Finish Inference in MLN Probability of a formula, Conditional Probability Markov Logic: applications (422) Highlights from IUI conference Watson…. TA evaluation / Teaching Evaluations Final Exam (office hours, samples)

20 CPSC 422, Lecture 34Slide 20 AI and HCI meet Keynote Speaker: Prof. Dan Weld, University of Washington Intelligent Control of Crowdsourcing Crowd-sourcing labor markets (e.g., Amazon Mechanical Turk) are booming, …… use of partially-observable Markov decision Processes (POMDPs) to control voting on binary-choice questions and iterative improvement workflows.

21 Some papers from IUI Unsupervised Modeling of Users' Interests from their Facebook Profiles and Activities (Page 191) Preeti Bhargava (University of Maryland) Oliver Brdiczka (Vectra Networks, Inc.) Michael Roberts (Palo Alto Research Center) named entity recognition, document categorization, sentiment analysis, semantic relatedness and social tagging Semantic Textual Similarity (STS) system [13] for computing the SR scores. STS is based on LSA along with WordNet knowledge and is trained on LDC Gigawords and Stanford Webbase corpora CPSC 422, Lecture 34Slide 21

22 Some papers from IUI BayesHeart: A Probabilistic Approach for Robust, Low- Latency Heart Rate Monitoring on Camera Phones Xiangmin Fan (University of Pittsburgh) Jingtao Wang (University of Pittsburgh) BayesHeart is based on an adaptive hidden Markov model, requires minimal training data and is user-independent. Two models, one with 2 states and one with 4 states, work in combination…. CPSC 422, Lecture 34Slide 22

23 Watson : analyzes natural language questions and content well enough and fast enough to compete and win against champion players at Jeopardy!Jeopardy! CPSC 422, Lecture 34Slide 23 Source: IBM “This Drug has been shown to relieve the symptoms of ADD with relatively few side effects." 1000s of algorithms and KBs, 3 secs

24 AI techniques in 422 / Watson Parsing (PCFGs) Shallow parsing (NP segmentation with CRFs) Entity and relation Detection (NER with CRFs) Logical Form Generation and Matching Logical Temporal and Spatial Reasoning Leveraging many databases, taxonomies, and ontologies Confidence…. Probabilities (Bnets to rank) Strategy for playing Jeopardy…statistical models of players and games, game-theoretic analyses ….. and application of reinforcement-learning CPSC 422, Lecture 34Slide 24

25 From silly project to $1 billion investment 2005-6 “IT’S a silly project to work on, it’s too gimmicky, it’s not a real computer-science test, and we probably can’t do it anyway.” These were reportedly the first reactions of the team of IBM researchers challenged to build a computer system capable of winning “Jeopardy! CPSC 422, Lecture 34 Slide 25 On January 9 th 2014, with much fanfare, the computing giant announced plans to invest $1 billion in a new division, IBM Watson Group. By the end of the year, the division expects to have a staff of 2,000 plus an army of external app developers …..Mike Rhodin, who will run the new division, calls it “one of the most significant innovations in the history of our company.” Ginni Rometty, IBM’s boss since early 2012, has reportedly predicted that it will be a $10 billion a year business within a decade. ………after 8-9 years…

26 DeepQA components Each of the scorers implemented in Watson, how they work, how they interact, and their independent impact on Watson’s performance deserves its own research paper. At this point no one algorithm dominates. Important and lasting contribution of this work DeepQA’s facility for absorbing these algorithms Tools for exploring their interactions and effects CPSC 422, Lecture 34Slide 26

27 And interactive, collaborative question-answering / problem solving More complex questions in the future… Or something like: “Should Europe reduce its energy dependency from Russia and what would it take?” CPSC 422, Lecture 34 Slide 27

28 AI applications……. DeepQA Robotics Search Engines Games Tutoring Systems Medicine / Finance / ….. ……. CPSC 422, Lecture 34Slide 28 Most companies are investing in AI and/or developing/adopting AI technologies

29 CPSC 422, Lecture 3429 Lecture Overview Finish Inference in MLN Probability of a formula, Conditional Probability Markov Logic: applications (422) Highlights from IUI conference Watson…. TA evaluation / Teaching Evaluations Final Exam (office hours, samples)

30 CPSC 422, Lecture 34Slide 30 TA evaluation Issam Laradji issamou@cs.ubc.ca Also if you have not done it yet, fill out the teaching evaluations https://eval.olt.ubc.ca/science. login to the site using your CWL

31 CPSC 422, Lecture 34Slide 31 Learning Goals (look at the end of the slides for each lecture) Revise all the clicker questions, practice exercises, assignments and midterm Will post more practice material today Office Hours – usual ones Me Mon 1-2, Issam Fri 11-12 – if high demand we will add a few more. Can bring letter sized sheet of paper with anything written on it (double sided) Final Exam, Sat, Apr 18, we will start at 12:00PM Location: DMP 110 How to prepare….

32 32 Example: Coreference Resolution Barack Obama, the 44 th President of the United States, is the first African American to hold the office. …… CPSC 422, Lecture 34

33 33 Example: Coreference Resolution Head(A,“Obama”) MentionOf(A,Obama) Head(A,“President”) MentionOf(B,Obama) Apposition(A,B) Head(B,“Obama”) Head(B,“President”) Two mention constants: A and B Apposition(B,A) In general, they represent feature templates for Markov Networks CPSC 422, Lecture 34

34 34 Can also resolve fields: HasToken(token,field,record) SameField(field,record,record) SameRecord(record,record) HasToken(+t,+f,r) ^ HasToken(+t,+f,r’) => SameField(f,r,r’) SameField(f,r,r’) SameRecord(r,r’) SameRecord(r,r’) ^ SameRecord(r’,r”) => SameRecord(r,r”) SameField(f,r,r’) ^ SameField(f,r’,r”) => SameField(f,r,r”) More: P. Singla & P. Domingos, “Entity Resolution with Markov Logic”, in Proc. ICDM-2006. Entity Resolution CPSC 422, Lecture 34

35 35 UNSUPERVISED SEMANTIC PARSING. H. POON & P. DOMINGOS. EMNLP-2009. Unsupervised Semantic Parsing, Hoifung Poon and Pedro Domingos. Proceedings of the 2009 Conference on Empirical Methods in Natural Language Processing. Singapore: ACL. Information Extraction CPSC 422, Lecture 34

36 36 UNSUPERVISED SEMANTIC PARSING. H. POON & P. DOMINGOS. EMNLP-2009. Unsupervised Semantic Parsing, Hoifung Poon and Pedro Domingos. Proceedings of the 2009 Conference on Empirical Methods in Natural Language Processing. Singapore: ACL. Information Extraction AuthorTitleVenue SAME? CPSC 422, Lecture 34

37 37 Information Extraction Problem: Extract database from text or semi-structured sources Example: Extract database of publications from citation list(s) (the “CiteSeer problem”) Two steps: –Segmentation: Use HMM to assign tokens to fields –Entity resolution: Use logistic regression and transitivity CPSC 422, Lecture 34

38 38 Token(token, position, citation) InField(position, field!, citation) SameField(field, citation, citation) SameCit(citation, citation) Token(+t,i,c) => InField(i,+f,c) InField(i,+f,c) ^ InField(i+1,+f,c) Token(+t,i,c) ^ InField(i,+f,c) ^ Token(+t,i’,c’) ^ InField(i’,+f,c’) => SameField(+f,c,c’) SameField(+f,c,c’) SameCit(c,c’) SameField(f,c,c’) ^ SameField(f,c’,c”) => SameField(f,c,c”) SameCit(c,c’) ^ SameCit(c’,c”) => SameCit(c,c”) Information Extraction CPSC 422, Lecture 34

39 39 Token(token, position, citation) InField(position, field!, citation) SameField(field, citation, citation) SameCit(citation, citation) Token(+t,i,c) => InField(i,+f,c) InField(i,+f,c) ^ !Token(“.”,i,c) ^ InField(i+1,+f,c) Token(+t,i,c) ^ InField(i,+f,c) ^ Token(+t,i’,c’) ^ InField(i’,+f,c’) => SameField(+f,c,c’) SameField(+f,c,c’) SameCit(c,c’) SameField(f,c,c’) ^ SameField(f,c’,c”) => SameField(f,c,c”) SameCit(c,c’) ^ SameCit(c’,c”) => SameCit(c,c”) More: H. Poon & P. Domingos, “Joint Inference in Information Extraction”, in Proc. AAAI-2007. Information Extraction CPSC 422, Lecture 34

40 Inference in MLN MLN acts as a template for a Markov Network We can always answer prob. queries using standard Markov network inference methods on the instantiated network However, due to the size and complexity of the resulting network, this is often infeasible. Instead, we combine probabilistic methods with ideas from logical inference, including satisfiability and resolution. This leads to efficient methods that take full advantage of the logical structure. CPSC 422, Lecture 3440

41 MAP Inference Reduces to finding the pw that maximizes the sum of weights of satisfied clauses Use weighted SAT solver (e.g., MaxWalkSAT [Kautz et al., 1997] ) CPSC 422, Lecture 34 41 Find most likely state of world Probabilistic problem solved by logical inference method

42 Computing Probabilities P(Formula,M L,C ) = ? Brute force: Sum probs. of possible worlds where formula holds MCMC: Sample worlds, check formula holds CPSC 422, Lecture 34 42


Download ppt "CPSC 422, Lecture 34Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 34 Apr, 10, 2015 Slide source: from Pedro Domingos UW & Markov."

Similar presentations


Ads by Google