+ All Categories
Home > Documents > עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

Date post: 13-Jan-2016
Category:
Upload: portia
View: 56 times
Download: 0 times
Share this document with a friend
Description:
עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics. עידו דגן המחלקה למדעי המחשב אוניברסיטת בר אילן. Feature structures in the grammar. CF grammar rules can be augmented with feature structures and with unification operations to express constraints on the constituents of a rule - PowerPoint PPT Presentation
36
88-680 1 Text Books Text Books ררררר- ררררר רררר רררררר ררר רררUnification (cont.) Semantics רררר ררר רררררר ררררר ררררר רררררררררר רר רררר
Transcript
Page 1: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 1

Text Books 

Text Books 

עיבוד שפות טבעיות - שיעור אחד עשר

Unification (cont.)Semantics

עידו דגן

המחלקה למדעי המחשב

אוניברסיטת בר אילן

Page 2: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 2

Text Books 

Text Books 

Feature structures in the grammar

• CF grammar rules can be augmented with feature structures and with unification operations to express constraints on the constituents of a rule

• An example notation (the PATR-II formalism):β 0 β 1... β n {set of constraints}– Where the constraints have one of the following two

forms:• < βi feature path> =(unify) atomic value

• < βi feature path> =(unify) < βj feature path>

– e.g.S NP VP<NP NUMBER> = <VP NUMBER>

Page 3: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 3

Text Books 

Text Books 

Feature structures in the grammar

• S NP VP{NP AGREEMENT} = {VP AGREEMENT}– This flight serves breakfast– These flights serve breakfast

• S Aux NP VP{Aux AGREEMENT} = {NP AGREEMENT}– Does this flight serve breakfast?– Do these flights serve breakfast?

Page 4: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 4

Text Books 

Text Books 

Feature structures in the grammar

• NP Det Nominal<Det AGREEMENT> = <Nominal AGREEMENT><NP AGREEMENT> = <Nominal AGREEMENT>– this flight vs. these flights

Page 5: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 5

Text Books 

Text Books 

Feature structures in the grammar

• Lexical constituents receive their agreement features directly from the lexicon– Aux does

<Aux AGREEMENT NUMBER> = sg<Aux AGREEMENT PERSON> = 3

– Det this<Aux AGREEMENT NUMBER> = sg

– Det these<Aux AGREEMENT NUMBER> = pl

Page 6: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 6

Text Books 

Text Books 

Feature structures in the grammar

• Verb serve<Verb AGREEMENT NUMBER> = pl

• Verb serves<Verb AGREEMENT NUMBER> = sg<Verb AGREEMENT PERSON> = 3

• Non-lexical constituents(e.g. VPs) receive agreement values from their constituents

• VP Verb NP<VP AGREEMENT> = <Verb AGREEMENT>

Page 7: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 7

Text Books 

Text Books 

Feature structures in the grammar

• Agreement (NP and Nominal)– Noun flight

<Noun AGREEMENT NUMBER> = sg– Noun flights

<Noun AGREEMENT NUMBER> = pl– Nominal Noun

<Nominal AGREEMENT> = <Noun AGREEMENT>

Page 8: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 8

Text Books 

Text Books 

Feature structures in the grammar• For most grammatical categories, the features are

copied from one child to the parent• The child that provides the features is called the head

of the phrase (the features are the head features)– VP Verb NP

<VP AGREEMENT> = <Verb AGREEMENT>– NP Det Nominal

<Det AGREEMENT> = <Nominal AGREEMENT><NP AGREEMENT> = <Nominal AGREEMENT>

– Nominal Noun<Nominal AGREEMENT> = <Noun AGREEMENT>

Page 9: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 9

Text Books 

Text Books 

Subcategorization

• VP Verb {VP SUBCAT} = INTRANS

• VP Verb NP {VP SUBCAT} = TRANS

• VP Verb NP NP {VP SUBCAT} = DITRANS

Page 10: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 10

Text Books 

Text Books 

Page 11: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 11

Text Books 

Text Books 

Semantics

Page 12: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 12

Text Books 

Text Books 

Representing Meaning

• Up to now, we have not focussed at all on what things mean.

• How does one represent meaning?

• meaning representations:representations that bridge that gap from linguistic forms to knowledge of the world.

Page 13: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 13

Text Books 

Text Books 

Meaning Representations

• What can serve as a meaning representation...

• Anything that serves the core practical purposes of a program that is doing semantic processing: – Answering questions– Determining truth– Making inferences

Page 14: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 14

Text Books 

Text Books 

semantic analysis

הפעולה של השמת מבני משמעות לרכיבים • semanticלשוניים נקראת ניתוח סמנטי

analysis

Page 15: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 15

Text Books 

Text Books 

The architectureSentence

Parsing

Parse Tree

Semantic Analysis

Semantic Representation

Syntactic Structure

Page 16: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 16

Text Books 

Text Books 

Applications

• Ideally, applications would interact with the semantic representation of texts.

• Need a representation which is unambiguous, even though the text is ambiguous.

Page 17: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 17

Text Books 

Text Books 

Problem of Ambiguity

אין התאמה חח“ע בין משפט ובין הייצוג •הסמנטי שלו (רב משמעות) וגם לא להפך:

Page 18: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 18

Text Books 

Text Books 

Canonical Form

• Inputs that mean the same thing should have the same meaning representation!

ייצוג משמעות אחיד לקלטים שונים נקרא •canonical form

מאפשר פישוט של תהליך ההסקה, אם •המערכת צריכה להתמודד רק עם ייצוג

יחיד.

Page 19: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 19

Text Books 

Text Books 

Canonical Form

• John gave a car to Mary

• Mary was given a car by John

• give(John, Mary, a car)

• ∃x y : give(x) ∃ ∧ agent(x, John) ∧ recipient(x,Mary) ∧ object(x,y) ∧ car(y)

Page 20: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 20

Text Books 

Text Books 

Example

• Every bird lives on a tree

• Quantifier and word sense ambiguities.

• ∀x bird(x) y : tree∃ 1(y) ∧ live_ on(x,y)

• ∃y tree1(y): x bird(x) ∀ live_on(x,y)

Page 21: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 21

Text Books 

Text Books 

FOPC – First Order Predicate Logic

• Meaning Structure of Language • Choice of FOPC isn't completely arbitrary or

driven by the needs of applications... • Human languages:

– display a basic predicate-argument structure– make use of variables – make use of quantifers – display a partially compositional semantics

Page 22: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 22

Text Books 

Text Books 

Predicate Argument Structure

בכל השפות המדוברות מבנה הפרדיקט-ארגומנטים •הוא הגרעין והיסוד של המשמעות בשפה.

ההנחה הגסה הראשונה היא, אם כן, שבמשפט קיים •יחס כלשהו בין המושגים המובעים במילים שבו

וברכיביו השונים.אותו יחס הוא הבסיס לייצוג הסמנטי שיש למשפט.•אחד התפקידים החשובים של התחביר הוא לתת •

מסגרת שתאפשר בנייה של אותו ייצוג, והייצוג צריך שיהיה לו קשר הדוק עם אותו מבנה תחבירי.

Page 23: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 23

Text Books 

Text Books 

Predicate Argument Structure

• Predicate-like elements: – Verbs, VPs, prepositions, adjectives, some

nouns.

• Argument-like elements: – Nouns, Nominals, NPs, etc

Page 24: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 24

Text Books 

Text Books 

Example

• “John gave Mary the book”

• Giving(John, Mary, book)

• ∃x,y: Giving(x) Giver(John,x) ∧ ∧Givee(Mary,x) Given(y,x) ∧ ∧ Book(y)

Page 25: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 25

Text Books 

Text Books 

Semantic Analysis

• Syntax driven semantics:– Most methods rely in some way on a prior or

concurrent syntactic analysis (parse).

• Compositional Semantics:– at the core of most methods is the principle of

compositionality which states that the meaning of the whole is based on the meaning of parts.

– What are the parts?

Words and syntactic constructs

Page 26: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 26

Text Books 

Text Books 

Augmented CF Rules

• Verb serves{x y e IsA(e, serving) ∃ ∧ server(e,y) ∧ served(e,x) }

• S NP VP {VP.sem(NP.sem) }

• VP Verb NP {Verb.sem(NP.sem)}

• MassNoun Meat {Meat}• ProperNoun AyCaramba {AyCaramba}

Page 27: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 27

Text Books 

Text Books 

Page 28: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 28

Text Books 

Text Books 

Page 29: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 29

Text Books 

Text Books 

Determiners

Page 30: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 30

Text Books 

Text Books 

Issues

• How to represent tense and aspect?

• Idioms (are not compositional)!

• Pragmatics (extra-syntactic)!

• Inference

• And much more…

Page 31: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 31

Text Books 

Text Books 

Ambiguity Resolution

• Still have problem of ambiguity resolution:– Word sense disambiguation– Attachment ambiguity resolution

Page 32: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 32

Text Books 

Text Books 

WSD

• Problem: many words have different meanings or senses, i.e., there is ambiguity about how they are to be specifically interpreted (e.g., differentiate).

• Task: to determine which of the senses of an ambiguous word is invoked in a particular use of the word by looking at the context of its use.

Page 33: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 33

Text Books 

Text Books 

Word Senses

• Bank – The rising ground bordering a lake, river, or sea – An establishment for the custody, loan exchange, or issue of money,

for the extension of credit, and for facilitating the transmission of funds

• Title – Name/heading of a book, statue, work of art or music, etc.– Material at the start of a film – The right of legal ownership (of land) – The document that is evidence of the right – An appellation of respect attached to a person’s name – A written work (synecdoche: part stands for the whole)

Page 34: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 34

Text Books 

Text Books 

Solution

• look at the words around an ambiguous word in a large context window. Each word contributes potentially useful information about which sense of the ambiguous word is likely to be used with it.

• Apply a supervised learning mechanism

Page 35: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 35

Text Books 

Text Books 

WordNet

• on-line lexical reference system, linguistically motivated

• nouns, verbs, adjectives, adverbs are organized into synonym sets (lexical concepts),

• contains a taxonomy of about 100,000 words

Page 36: עיבוד שפות טבעיות - שיעור אחד עשר Unification (cont.) Semantics

88-680 36

Text Books 

Text Books 

WordNet

• semantic relationships represented– Synonymy: similarity of work meaning, concepts

as sets of words– Antonymy: dichotomy in meaning of words, used

for organizing adjectives and adverbs– Hyponymy: IS-A relationships Superconcept to

Subconcepts– Meronymy: Part-Of relationships between

concepts– Morphological Relationships: used to reduce

word forms


Recommended