Presentation is loading. Please wait.

Presentation is loading. Please wait.

CS 182 Sections 103 - 104 slides created by Eva Mok modified by jgm April 13, 2005.

Similar presentations


Presentation on theme: "CS 182 Sections 103 - 104 slides created by Eva Mok modified by jgm April 13, 2005."— Presentation transcript:

1 CS 182 Sections 103 - 104 slides created by Eva Mok (emok@icsi.berkeley.edu)emok@icsi.berkeley.edu modified by jgm April 13, 2005

2 Announcements a8 out, due Monday April 19 th, 11:59pm BBS articles are assigned for the final paper: –Arbib, Michael A. (2002). The mirror system, imitation, and the evolution of language. –Hurford, James R. (2003). The neural basis of predicate- argument structure. –Grush, Rick (2004). The emulation theory of representation: motor control, imagery, and perception. Skim through them and let us know, as part of a8, which article you plan to use.

3 Schedule Last Week –Inference in Bayes Net –Metaphor understanding using KARMA This Week –Formal Grammar and Parsing –Construction Grammar, ECG Next Week –Psychological model of sentence processing –Grammar Learning

4 Quiz 1.How are the source and target domains represented in KARMA? 2.How does the source domain information enter KARMA? How should it? 3.What does SHRUTI buy us? 4.How are bindings propagated in a structured connectionist framework?

5 Quiz 1.How are the source and target domains represented in KARMA? 2.How does the source domain information enter KARMA? How should it? 3.What does SHRUTI buy us? 4.How are bindings propagated in a structured connectionist framework?

6 KARMA DBN to represent target domain knowledge Metaphor maps link target and source domain X-schema to represent source domain knowledge

7 DBNs Explicit causal relations + full joint table  Bayes Nets Sequence of full joint states over time  HMM HMM + BN  DBNs DBNs are a generalization of HMMs which capture sparse causal relationships of full joint

8 Dynamic Bayes Nets

9 Metaphor Maps 1.map entities and objects between embodied and abstract domains 2.invariantly map the aspect of the embodied domain event onto the target domain by setting the evidence for the status variable based on controller state (event structure metaphor) 3.project x-schema parameters onto the target domain

10 Where does the domain knowledge come from? Both domains are structured by frames Frames have: –List of roles (participants, frame elements) –Relations between roles –Scenario structure

11 DBN for the target domain T0T1 Economic State Goal Policy Outcome Difficulty [Liberalization, Protectionism] [free trade, protection ] [success, failure] [present, absent] [recession,nogrowth,lowgrowth,higrowth]

12 Let’s try a different domain I didn’t quite catch what he was saying His slides are packed with information He sent the audience a clear message 9/11 Commission Public Hearing, Monday, March 31, 2003 When we can get a good flow of information from the streets of our cities across to, whether it is an investigating magistrate in France or an intelligence operative in the Middle East, and begin to assemble that kind of information and analyze it and repackage it and send it back out to users, whether it's a policeman on the beat or a judge in Italy or a Special Forces Team in Afghanistan, then we will be getting close to the kind of capability we need to deal with this kind of problem. That's going to take a couple, a few years.

13 Target domain belief net (T-1) Metaphor Map (conduit metaphor) Ideas are objects Words are containers Senders are speakers Receivers are addressees send is talk receive is hear Target domain belief net (T) (communication frame) speakeraddresseeactionoutcome degree of understanding Source domain f-structs (transfer) X-Schema representation senderreceivermeansforcerate transfer sendreceive pack

14 Quiz 1.How are the source and target domains represented in KARMA? 2.How does the source domain information enter KARMA? How should it? 3.What does SHRUTI buy us? 4.How are bindings propagated in a structured connectionist framework?

15 How do the source domain f-structs get parameterized? In the KARMA system, they are hand-coded. In general, you need analysis of sentences: –syntax –semantics Syntax captures: constraints on word order constituency (units of words) grammatical relations (e.g. subject, object) subcategorization & dependency (e.g. transitive, intransitive, subject-verb agreement)

16 Quiz 1.How are the source and target domains represented in KARMA? 2.How does the source domain information enter KARMA? How should it? 3.What does SHRUTI buy us? 4.How are bindings propagated in a structured connectionist framework?

17 SHRUTI A connectionist model of reflexive processing Reflexive reasoning automatic, extremely fast (~300ms), ubiquitous computation of coherent explanations and predictions gradual learning of causal structure episodic memory understanding language Reflective reasoning conscious deliberation, slow overt consideration of alternatives external props (pencil + paper) solving logic puzzles doing cryptarithmetic planning a vacation

18 SHRUTI synchronous activity without using global clock An episode of reflexive processing is a transient propagation of rhythmic activity An “entity” is a phase in the above rhythmic activity. Bindings are synchronous firings of role and entity cells Rules are interconnection patterns mediated by coincidence detector circuits that allow selective propagation of activity Long-term memories are coincidence and coincidence-failure detector circuits An affirmative answer / explanation corresponds to reverberatory activity around closed loops

19 focal cluster provides locus of coordination, control and decision making enforce sequencing and concurrency initiate information seeking actions initiate evaluation of conditions initiate conditional actions link to other schemas, knowledge structures

20 Quiz 1.How are the source and target domains represented in KARMA? 2.How does the source domain information enter KARMA? How should it? 3.What does SHRUTI buy us? 4.How are bindings propagated in a structured connectionist framework?

21 dynamic binding example asserting that get(father, cup) father fires in phase with agent role cup fires in phase with patient role + - ? agtpat +e+v?e?v +? get cup my-father type entity predicate

22 Active Schemas in SHRUTI active schemas require control and coordination, dynamic role binding and parameter setting schemas are interconnected networks of focal clusters bindings are encoded and propagated using temporal synchrony scalar parameters are encoded using rate-encoding

23

24 Review: Probability Random Variables –Boolean/Discrete True/false Cloudy/rainy/sunny –Continuous [0,1] (i.e. 0.0 <= x <= 1.0)

25 Priors/Unconditional Probability Probability Distribution –In absence of any other info –Sums to 1 –E.g. P(Sunny=T) =.8 (thus, P(Sunny=F) =.2) This is a simple probability distribution Joint Probability –P(Sunny, Umbrella, Bike) Table 2 3 in size –Full Joint is a joint of all variables in model Probability Density Function –Continuous variables E.g. Uniform, Gaussian, Poisson…

26 Conditional Probability P(Y | X) is probability of Y given that all we know is the value of X –E.g. P(cavity=T | toothache=T) =.8 thus P( cavity=F | toothache=T) =.2 Product Rule –P(Y | X) = P(X Y) / P(X)(normalizer to add up to 1 ) YX

27 Inference ToothacheCavityCatchProb False.576 False True.144 FalseTrueFalse.008 FalseTrue.072 TrueFalse.064 TrueFalseTrue.016 True False.012 True.108 P(Toothache=T)? P(Toothache=T, Cavity=T)? P(Toothache=T | Cavity=T)?

28 Independence Rainy Cloudy Sunny Windy

29 Bayes Nets BEP(A| … ) TTFFTTFF TFTFTFTF 0.95 0.94 0.29 0.001 BurglaryEarthquake Alarm MaryCallsJohnCalls P(B) 0.001 P(E) 0.002 AP(J|…) TFTF 0.90 0.05 AP(M|…) TFTF 0.70 0.01

30 Graphical Models P(Y | X) = P(X | Y) P(Y) P(X) What is P(Y=F|X=T)? What is P(X=T|Y=F)? What does it mean to have evidence? X Y Sneezing Cold P(X=T) =.3 P(Y=T|X=T) =.7 P(Y=T|X=F) =.2

31 Independence XYZXYZ X Y ZX Y Z X Y ZX Y Z X independent of Z?X conditionally independent of Z given Y? X independent of Z?X conditionally independent of Z given Y? No No No Yes Yes Yes Or below

32 Markov Blanket X X is independent of everything else given: Parents, Children, Parents of Children

33 Reference: Joints Representation of entire network P(X 1 =x 1  X 2 =x 2 ... X n =x n ) = P(x 1,..., x n ) =  i=1..n P(x i |parents(X i )) How? Chain Rule –P(x 1,..., x n ) = P(x 1 |x 2,..., x n ) P(x 2,..., x n ) =... =  i=1..n P(x i |x i-1,..., x 1 ) –Now use conditional independences to simplify

34 Reference: Joint, cont. P(x 1,..., x 6 ) = P(x 1 ) * P(x 2 |x 1 ) * P(x 3 |x 2, x 1 ) * P(x 4 |x 3, x 2, x 1 ) * P(x 5 |x 4, x 3, x 2, x 1 ) * P(x 6 |x 5, x 4, x 3, x 2, x 1 ) X2X2 X1X1 X3X3 X4X4 X6X6 X5X5

35 Reference: Joint, cont. P(x 1,..., x 6 ) = P(x 1 ) * P(x 2 |x 1 ) * P(x 3 |x 2, x 1 ) * P(x 4 |x 3, x 2, x 1 ) * P(x 5 |x 4, x 3, x 2, x 1 ) * P(x 6 |x 5, x 4, x 3, x 2, x 1 ) X2X2 X1X1 X3X3 X4X4 X6X6 X5X5

36 Reference: Inference General case –Variable Eliminate –P(Q | E) when you have P(R, Q, E) –P(Q | E) = ∑ R P(R, Q, E) / ∑ R,Q P(R, Q, E) ∑ R P(R, Q, E) = P(Q, E) ∑ Q P(Q, E) = P(E) P(Q, E) / P(E) = P(Q | E)

37 Inference ToothacheCavityCatchProb False.576 False True.144 FalseTrueFalse.008 FalseTrue.072 TrueFalse.064 TrueFalseTrue.016 True False.012 True.108 P(Toothache=T, Cavity=T)?

38 Inference ToothacheCavityProb False.72 FalseTrue0.08 TrueFalse0.08 True 0.12

39 Reference: Inference, cont. Q = {X 1 }, E = {X 6 } R = X \ Q,E P(x 1,..., x 6 ) = P(x 1 ) * P(x 2 |x 1 ) * P(x 3 |x 1 ) * P(x 4 |x 2 ) * P(x 5 |x 3 ) * P(x 6 |x 5, x 2 ) X2X2 X1X1 X3X3 X4X4 X6X6 X5X5 P(x 1, x 6 )= ∑ x2 ∑ x3 ∑ x4 ∑ x5 P(x 1 ) P(x 2 |x 1 ) P(x 3 |x 1 ) P(x 4 |x 2 ) P(x 5 |x 3 ) P(x 6 |x 5, x 2 ) = P(x 1 ) ∑ x2 P(x 2 |x 1 ) ∑ x3 P(x 3 |x 1 ) ∑ x4 P(x 4 |x 2 ) ∑ x5 P(x 5 |x 3 ) P(x 6 |x 5, x 2 ) = P(x 1 ) ∑ x2 P(x 2 |x 1 ) ∑ x3 P(x 3 |x 1 ) ∑ x4 P(x 4 |x 2 ) m 5 (x 2, x 3 ) = P(x 1 ) ∑ x2 P(x 2 |x 1 ) ∑ x3 P(x 3 |x 1 ) m 5 (x 2, x 3 ) ∑ x4 P(x 4 |x 2 )=...

40 Approximation Methods Simple –no evidence Rejection –just forget about the invalids Likelihood Weighting –only valid, but not necessarily useful MCMC –Best: only valid, useful, in proportion

41 Stochastic Simulation Rain Sprinkler Cloudy WetGrass 1. Repeat N times: 1.1. Guess Cloudy at random 1.2. For each guess of Cloudy, guess Sprinkler and Rain, then WetGrass 2. Compute the ratio of the # runs where WetGrass and Cloudy are True over the # runs where Cloudy is True P(WetGrass|Cloudy)? P(WetGrass|Cloudy) = P(WetGrass  Cloudy) / P(Cloudy)


Download ppt "CS 182 Sections 103 - 104 slides created by Eva Mok modified by jgm April 13, 2005."

Similar presentations


Ads by Google