Presentation is loading. Please wait.

Presentation is loading. Please wait.

LING 581: Advanced Computational Linguistics

Similar presentations


Presentation on theme: "LING 581: Advanced Computational Linguistics"— Presentation transcript:

1 LING 581: Advanced Computational Linguistics
Lecture Notes May 1st

2 Last time how do we define every?
(Montague-style) λP1.[λP2.[∀X (P1(X) -> P2(X))]] (Barwise & Cooper-style) {X: P1(X)} ⊆ {X: P2(X)} Prolog versions (with threshold=2): (Montague-style) lambda(P1,lambda(P2,(\+ (call(P1,X),\+ call(P2,X)), call(P1,Y), call(P1,Z), Y \== Z))) (Barwise & Cooper-style) lambda(P1,lambda(P2,(setof(X,call(P1,X),L1), setof(Y,call(P2,Y),L2), subset(L1,L2), length(L1,N), N>1)))

3 Modify psg2.pl

4 psg3.pl (Montague-style) atLeast(P1,X,2)
lambda(P1,lambda(P2,(\+ (call(P1,X),\+ call(P2,X)), call(P1,Y), call(P1,Z), Y \== Z)))

5 psg3.pl Prolog code; not a grammar rule

6 psg3.pl

7 psg3.pl

8 psg3.pl Let's check it out…

9 psg3.pl psg3.pl psg2.pl Took out the findall; moved it into the S rule

10 psg3.pl

11 psg3.pl

12 psg3.pl

13 Quantifiers Part 3: Coordination Extend the grammars to handle
Every man and every woman likes James cf. Every man likes James and every woman likes James [NP[NP Every man] and [NP every woman]] likes James rewrite: likes(sophia, james) as: likes(james, sophia)

14 Quantifiers Part 3: Coordination Every man and every woman likes James
[NP[NP Every man] and [NP every woman]] likes James

15 Quantifiers Part 3: Coordination Every man and every woman likes James
[NP[NP Every man] and [NP every woman]] likes James

16 Other Quantifiers Other quantifiers can also be expressed using set relations between two predicates: Example: no: {X: P1(X)} ∩ {Y: P2(Y)} = ∅ ∩ = set intersection ∅ = empty set no man smokes {X: man(X)} ∩ {Y: smokes(Y)} = ∅ should evaluate to true for all possible worlds where there is no overlap between men and smokers men smokers

17 Other Quantifiers Other quantifiers can also be expressed using set relations between two predicates: Example: some: {X: P1(X)} ∩ {Y: P2(Y)} ≠ ∅ ∩ = set intersection ∅ = empty set some men smoke {X: man(X)} ∩ {Y: smokes(Y)} ≠ ∅ men smokers

18 Names as Generalized Quantifiers
we’ve mentioned that names directly refer here is another idea… Conjunction X and Y both X and Y have to be of the same type in particular, semantically... we want them to have the same semantic type what is the semantic type of every baby? Example every baby and John likes ice cream [NP[NP every baby] and [NP John]] likes ice cream every baby likes ice cream {X: baby(X)} ⊆ {Y: likes(Y,ice_cream)} John likes ice cream ??? ⊆ {Y: likes(Y,ice_cream)} John ∈ {Y: likes(Y,ice_cream)} want everything to be a set (to be consistent) i.e. want to state something like ({X: baby(X)} ∪{X: john(X)}) ⊆ {Y: likes(Y,ice_cream)} note: set union (∪) is the translation of “and”

19 Downwards and Upwards Entailment (DE & UE)
Quantifier every has semantics {X: P1(X)} ⊆ {Y: P2(Y)} e.g. every woman likes ice cream {X: woman(X)} ⊆ {Y:likes(Y,ice_cream)} Every is DE for P1 and UE for P2 Examples: (25) a. Every dog barks b. Every Keeshond barks (valid) c. Every animal barks (invalid) semantically, “Keeshond” is a sub-property or subset with respect to the set “dog” animal dog Keeshond animal dog Keeshond

20 Downwards and Upwards Entailment (DE & UE)
Quantifier every has semantics {X: P1(X)} ⊆ {Y: P2(Y)} e.g. every woman likes ice cream {X: woman(X)} ⊆ {Y:likes(Y,ice_cream)} Every is DE for P1 and UE for P2 Examples: (25) a. Every dog barks d. Every dog barks loudly (invalid) c. Every dog makes noise (valid) semantically, “barks loudly” is a subset with respect to the set “barks”, which (in turn) is a subset of the set “makes noise” make noise barks barks loudly make noise barks loud

21 Downwards and Upwards Entailment (DE & UE)
Contrast every with some: every man smokes every person smokes every man in the state smokes some is upwards entailing (UE) in P1: some man smokes some person smokes some man in the state smokes


Download ppt "LING 581: Advanced Computational Linguistics"

Similar presentations


Ads by Google