Constraints Driven Learning for Natural Language Understanding
Understanding Natural Language
description
Transcript of Understanding Natural Language
![Page 1: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/1.jpg)
1
Understanding Natural Language14 14.0 The Natural Language
UnderstandingProblem
14.1 Deconstructing Language: A SymbolicAnalysis
14.2 Syntax
14.3 Syntax and Knowledgewith ATN parsers
14.4 Stochastic Tools forLanguage Analysis
14.5 Natural LanguageApplications
14.6 Epilogue and References
14.7 Exercises
Additional source used in preparing the slides:Patrick H. Winston’s AI textbook, Addison Wesley, 1993.
![Page 2: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/2.jpg)
2
Alternative to CSGs
• Retain simple structure of CFGs
• Augment them with procedures that perform the necessary contextual tests
• Attach features to terminals and nonterminals:augmented transition networks
![Page 3: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/3.jpg)
3
Parsing with ATNs
• Attach procedures to the arcs of the network.
• The parser will execute those procedures while traversing the arcs.
• The procedures: Perform tests
Construct a parse tree
• Both terminals and nonterminals are represented as identifiers with attached features.
![Page 4: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/4.jpg)
4
Frames for three nonterminals
Sentence
Noun phrase:
Verb phrase:
Verb phrase
Verb:
Number:
Object:
Noun phrase
Determiner:
Noun:
Number:
![Page 5: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/5.jpg)
5
Dictionary entries - 1
PART_OF_SPEECH: verb
ROOT: like
NUMBER: plural
like
PART_OF_SPEECH: verb
ROOT: like
NUMBER: singular
PART_OF_SPEECH: verb
ROOT: bite
NUMBER: plural
PART_OF_SPEECH: verb
ROOT: bite
NUMBER: singular
bite bites
likes
![Page 6: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/6.jpg)
6
Dictionary entries - 2
PART_OF_SPEECH: noun
ROOT: man
NUMBER: plural
men
PART_OF_SPEECH: noun
ROOT: man
NUMBER: singular
PART_OF_SPEECH: noun
ROOT: dog
NUMBER: plural
PART_OF_SPEECH: noun
ROOT: dog
NUMBER: singular
dogs dog
man
![Page 7: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/7.jpg)
7
Dictionary entries - 3
PART_OF_SPEECH: article
ROOT: a
NUMBER: singular
a
PART_OF_SPEECH: article
ROOT: the
NUMBER: plural or singular
the
![Page 8: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/8.jpg)
8
Sentence
function sentence-1; begin NOUN_PHRASE := structure returned by
noun_phrase network; SENTENCE.SUBJECT := NOUN_PHRASE; end.
init final
noun_phrase verb_phrase
1 2
![Page 9: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/9.jpg)
9
Sentence
function sentence-2; begin VERB_PHRASE := structure returned by verb_phrase network; if NOUN_PHRASE.NUMBER = VERB_PHRASE.number then begin SENTENCE.VERB_PHRASE := VERB_PHRASE; return SENTENCE end else fail end.
init final
noun_phrase verb_phrase
1 2
![Page 10: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/10.jpg)
10
Noun_phrase
function noun_phrase-1; begin ARTICLE := definition frame for next word of input; if ARTICLE.PART_OF_SPEECH = article then NOUN_PHRASE.DETERMINER := ARTICLE else fail end.
init final
article noun
1 2
3
noun
![Page 11: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/11.jpg)
11
Noun_phrase
function noun_phrase-2; begin NOUN := definition frame for next word of input; if NOUN.PART_OF_SPEECH = noun and NOUN.NUMBER agrees with NOUN_PHRASE.DETERMINER.NUMBER then begin NOUN_PHRASE.NOUN := NOUN NOUN_PHRASE.NUMBER := NOUN.NUMBER return NOUN_PHRASE end else fail end.
init final
article noun
1 2
3
noun
![Page 12: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/12.jpg)
12
Noun_phrase
function noun_phrase-3; begin NOUN := definition frame for next word of input; if NOUN.PART_OF_SPEECH = noun then begin NOUN_PHRASE.DETERMINER := unspecified NOUN_PHRASE.NOUN := NOUN NOUN_PHRASE.NUMBER := NOUN.NUMBER end else fail end.
init final
article noun
1 2
3
noun
![Page 13: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/13.jpg)
13
Verb_phrase
function verb_phrase-1; begin VERB := definition frame for next word of input; if VERB.PART_OF_SPEECH = verb then begin VERB_PHRASE.VERB := VERB; VERB_PHRASE.NUMBER := VERB.NUMBER end; end.
init final
verb noun_phrase
1 2
3
verb
![Page 14: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/14.jpg)
14
Verb_phrase
function verb_phrase-2; begin NOUN_PHRASE := structure returned by noun_phrase network; VERB.PHRASE.OBJECT := NOUN_PHRASE; return VERB_PHRASE end.
init final
verb noun_phrase
1 2
3
verb
![Page 15: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/15.jpg)
15
Verb_phrase
function verb_phrase-3; begin VERB := definition frame for next word of input; if VERB.PART_OF_SPEECH = verb then begin VERB_PHRASE.VERB := VERB; VERB_PHRASE.NUMBER := VERB.NUMBER VERB_PHRASE.OBJECT := unspecified; return VERB_PHRASE end; end.
init final
verb noun_phrase
1 2
3
verb
![Page 16: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/16.jpg)
16
“The dog likes a man.”
![Page 17: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/17.jpg)
17
Knowledge base for the “dogs world.”
![Page 18: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/18.jpg)
18
Case frames for two verbs
![Page 19: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/19.jpg)
19
Semantic representation
![Page 20: Understanding Natural Language](https://reader034.fdocuments.us/reader034/viewer/2022051019/56814f1f550346895dbcb01f/html5/thumbnails/20.jpg)
20
Concluding remarks
• The parse tree can be converted to a conceptual graph that represents the meaning of the sentence.
• Simpler approaches use templates and plug in words as they are recognized.
• Applications include: Story understanding and question answering
Front End to a database
Information extraction and summarization on the web