more calculus lexical semantics
play

More -Calculus Lexical Semantics LING 571 Deep Processing - PowerPoint PPT Presentation

More -Calculus Lexical Semantics LING 571 Deep Processing Techniques for NLP October 30, 2019 Shane Steinert-Threlkeld 1 Announcements HW5: readme: be detailed! What problems you ran into (e.g. agreement), how you solved


  1. More λ -Calculus 
 Lexical Semantics LING 571 — Deep Processing Techniques for NLP October 30, 2019 Shane Steinert-Threlkeld 1

  2. Announcements ● HW5: ● readme: be detailed! ● What problems you ran into (e.g. agreement), how you solved them, and exhibit of the solution ● HSPG-style subcategorization extra credit: yes, but with max 100 points ● We will drop your lowest score when calculating final grades. But you still need to do all the assignments! 2

  3. Ambiguity of the Week ● Derivative of an alleged Groucho Marx-ism: ● In the US, a woman gives birth every fifteen minutes. ● We must find her and put a stop to it. ● Thank you scope ambiguity! (Not the same as attachment ambiguity.) 3

  4. Roadmap ● More Lambdas ● Learning Semantic Parsers ● Lexical Semantics ● Motivation & Definitions ● Word Senses ● Tasks: ● Word sense disambiguation ● Word sense similarity ● Distributional Similarity 4

  5. Creating Attachments “Every flight arrived” → ‘ Every’ { λ P . λ Q . ∀ x P ( x ) ⇒ Q ( x ) } Det → ‘ flight’ { λ x . Flight ( x ) } Noun → ‘ arrived’ { λ y . ∃ e Arrived ( e ) ∧ ArrivedThing ( e , y )} Verb → Verb { Verb.sem } VP → Noun { Noun.sem } Nom → NP VP { NP.sem ( VP.sem ) } S → Det Nom { Det.sem ( Nom.sem ) } NP 5

  6. ��������� ������� ������������������� ������������� � ����� �������������� ���������������� � �������� ������� ��� � �� �� ��� ���� � ����� ������ ������� 6

  7. ���������������� � �������� ������� ��� ��������������� � ����� �������������� ������������� � ����� ������������� � ����� ����������������� �������������� ��������� ������� ��������� ������� ���������������� � �������� ������� ��� NP → Det.sem ( NP.sem ) λ P. λ Q. ∀ xP(x) ⇒ Q ( x )( λ y . Flight ( y )) � � ⇒ Q ( x ) λ Q . ∀ x λ y.Flight(y)(x) λ Q . ∀ xFlight(x) ⇒ Q ( x ) �� �� �� �� ��� ��� ���� ���� � � ����� ����� ������ ������ ������� ������� 7

  8. ��������� ������� ��������������� � ����� ������������� � ����� �������������� ���������������� � �������� ������� ��� ���������������� � �������� ������� ��� � �� �� ��� ���� � ����� ������ ������� 8

  9. ��������� ������� ��������������� � ����� ������������� � ����� �������������� ���������������� � �������� ������� ��� ���������������� � �������� ������� ��� � �� �� ��� ���� � ����� ������ ������� 9

  10. ������������� � ����� ���������������� � �������� ������� ��� ��������������� � ����� ��������������� � ����� ��������� ������� ������������� � ����� ���������������� � �������� ������� ��� �������������� �������������� ������������ � ������������ � �������� ������� ��� ���������������� � �������� ������� ��� ���������������� � �������� ������� ��� � � �� �� �� �� ��� ��� ���� ���� � � λ Q. ∀ xFlight(x) ⇒ Q ( x )( λ z. ∃ eArrived ( e ) ∧ ArrivedThing ( e, z )) ∀ xFlight(x) ⇒ λ z. ∃ eArrived ( e ) ∧ ArrivedThing ( e, z )( x ) ����� ����� ������ ������ ������� ������� ∀ xFlight(x) ⇒ ∃ eArrived ( e ) ∧ ArrivedThing ( e, x ) 10

  11. ������������ � ������������ � �������� ������� ��� ��������������� � ����� ������������� � ����� �������������� ���������������� � �������� ������� ��� ���������������� � �������� ������� ��� � �� �� ��� ���� � ����� ������ ������� 11

  12. More λ -Calculus 12

  13. Target Representations 13

  14. Common Nouns ● λ x . Restaurant ( x ) → ‘restaurant ’ ● Somewhat similar to the NNP construction ● λ var.Predicate(var) ● But common nouns represent relations , rather than constants ● Meaning of the noun encoded in the predicate ● Relate the concept of the noun to a particular instance of variable 14

  15. Negation ● “No vegetarian restaurant serves meat.” ● ¬( ∃ x VegetarianRestaurant ( x ) ∧ Serves ( x , Meat )) ● “All vegetarian restaurants do not serve meat.” ● ∀ x VegetarianRestaurant ( x ) ⇒ ¬ Serves ( x , Meat ) ● These are semantically equivalent! ● ¬[IF P, THEN Q] ⇔ P AND NOT Q ● For NLTK, use the hyphen/minus character: ‘-‘ 15

  16. ‘John booked a flight’ ● Target representation: ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) 16

  17. � ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) � �� �� S → NP VP { NP.sem ( VP.sem )} ��� ���� 17

  18. ��������� ������� � ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) � �� �� S → NP VP { NP.sem ( VP.sem )} ��� ���� 18

  19. � ��������� ������� ������������ ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) � �� �� S → NP VP { NP.sem ( VP.sem )} NNP → ‘ John’ { λ X.X ( John )} ��� NP → NNP { NNP.sem } VP → Verb NP { Verb.sem ( NP.sem )} ���� 19

  20. � ������������� ������� ��� ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) � �� �� S → NP VP { NP.sem ( VP.sem )} NNP → ‘ John’ { λ X.X ( John )} ��� NP → NNP { NNP.sem } VP → Verb NP { Verb.sem ( NP.sem )} ���� 20

  21. � �� ������������ ��� ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) � �� �� S → NP VP { NP.sem ( VP.sem )} NNP → ‘ John’ { λ X.X ( John )} ��� NP → NNP { NNP.sem } VP → Verb NP { Verb.sem ( NP.sem )} ���� 21

  22. ����������������� ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) �� ��� �� NP → Det NN { Det.sem ( NN.sem )} � ������ 22

  23. ������������ ����������������� ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) �� ��� �� NP → Det NN { Det.sem ( NN.sem )} NN → ‘flight’ { λ x . Flight ( x )} � ������ 23

  24. ������������ ����������������� ‘John booked a flight’ ● ∃ x Flight ( x ) ∧ ( ∃ eBooked (e) ∧ Booker ( e, John ) ∧ BookedThing ( e, x )) �� ��� �� NP → Det NN { Det.sem ( NN.sem )} NN → ‘flight’ { λ x . Flight ( x )} � ������ Det → ‘a’ { λ P. λ Q. ∃ x P ( x ) ∧ Q ( x ) } 24

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend