Natural Language Processing Lecture 6 : Revision.

Slides:



Advertisements
Similar presentations
Tree Diagrams / Labelling Phrases
Advertisements

The Structure of Sentences Asian 401
Intro to NLP - J. Eisner1 Modeling Grammaticality [mostly a blackboard lecture]
C O N T E X T - F R E E LANGUAGES ( use a grammar to describe a language) 1.
Chapter 4 Syntax.
Syntax: The Sentence Patterns of Language
Statistical NLP: Lecture 3
Chapter Chapter Summary Languages and Grammars Finite-State Machines with Output Finite-State Machines with No Output Language Recognition Turing.
SYNTAX Introduction to Linguistics. BASIC IDEAS What is a sentence? A string of random words? If it is a sentence, does it have to be meaningful?
The study of how words combine to form grammatical sentences.
1 Words and the Lexicon September 10th 2009 Lecture #3.
Syntax: The Sentence Patterns of Language Deny A. Kwary Airlangga University.
Matakuliah: G0922/Introduction to Linguistics Tahun: 2008 Session 11 Syntax 2.
1 Introduction to Computational Linguistics Eleni Miltsakaki AUTH Fall 2005-Lecture 2.
Syntax: The analysis of sentence structure
1 CSC 594 Topics in AI – Applied Natural Language Processing Fall 2009/ Outline of English Syntax.
Chapter 3: Formal Translation Models
LI 2013 NATHALIE F. MARTIN S YNTAX. Table of Content I. Grammatical vs. Ungrammatical Grammatical vs. Ungrammatical II. The Sentence The Sentence III.
Lect. 11Phrase structure rules Learning objectives: To define phrase structure rules To learn the forms of phrase structure rules To compose new sentences.
Linguistics II Syntax. Rules of how words go together to form sentences What types of words go together How the presence of some words predetermines others.
Context-Free Grammar CSCI-GA.2590 – Lecture 3 Ralph Grishman NYU.
Dr. Ansa Hameed Syntax (4).
Syntax The analysis of sentence structure
Syntax: The analysis of sentence structure
Syntax Nuha AlWadaani.
Phonetics, Phonology, Morphology and Syntax
THE PARTS OF SYNTAX Don’t worry, it’s just a phrase ELL113 Week 4.
LI 2013 NATHALIE F. MARTIN S YNTAX. Grammatical vs Ungrammatical.
Introduction to Linguistics
Languages & Strings String Operations Language Definitions.
IV. SYNTAX. 1.1 What is syntax? Syntax is the study of how sentences are structured, or in other words, it tries to state what words can be combined with.
Lecture # 3 Chapter #3: Lexical Analysis. Role of Lexical Analyzer It is the first phase of compiler Its main task is to read the input characters and.
SYNTAX Lecture -1 SMRITI SINGH.
A sentence (S) is composed of a noun phrase (NP) and a verb phrase (VP). A noun phrase may be composed of a determiner (D/DET) and a noun (N). A noun phrase.
Today Phrase structure rules, trees Constituents Recursion Conjunction
Linguistic Essentials
Parsing with Context-Free Grammars for ASR Julia Hirschberg CS 4706 Slides with contributions from Owen Rambow, Kathy McKeown, Dan Jurafsky and James Martin.
Review of basic concepts.  The knowledge of sentences and their structure.  Syntactic rules include: ◦ The grammaticality of sentences ◦ Word order.
CPE 480 Natural Language Processing Lecture 4: Syntax Adapted from Owen Rambow’s slides for CSc Fall 2006.
Rules, Movement, Ambiguity
CSA2050 Introduction to Computational Linguistics Parsing I.
1 Context Free Grammars October Syntactic Grammaticality Doesn’t depend on Having heard the sentence before The sentence being true –I saw a unicorn.
Natural Language Processing
Natural Language Processing
Making it stick together…
Com Functional Programming Lexical Analysis Marian Gheorghe Lecture 15 Module homepage Mole & ©University of Sheffieldcom2010.
Natural Language Processing Lecture 4 : Regular Expressions and Automata.
CPSC 422, Lecture 27Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 27 Nov, 16, 2015.
SYNTAX.
◦ Process of describing the structure of phrases and sentences Chapter 8 - Phrases and sentences: grammar1.
Finite State Machines 1.Finite state machines with output 2.Finite state machines with no output 3.DFA 4.NDFA.
1 Chapter 4 Syntax Part III. 2 The infinity of language pp The number of sentences in a language is infinite. 2. The length of sentences is.
TYPES OF PHRASES REPRESENTING THE INTERNAL STRUCTURE OF PHRASES 12/5/2016.
CSA3050: NLP Algorithms Sentence Grammar NLP Algorithms.
1.2 Three Basic Concepts Languages start variables Grammars Let us see a grammar for English. Typically, we are told “a sentence can Consist.
NATURAL LANGUAGE PROCESSING
SYNTAX.
King Faisal University جامعة الملك فيصل Deanship of E-Learning and Distance Education عمادة التعلم الإلكتروني والتعليم عن بعد [ ] 1 King Faisal University.
BCT 2083 DISCRETE STRUCTURE AND APPLICATIONS
Statistical NLP: Lecture 3
BBI 3212 ENGLISH SYNTAX AND MORPHOLOGY
SYNTAX.
Chapter Eight Syntax.
BBI 3212 ENGLISH SYNTAX AND MORPHOLOGY
Chapter Eight Syntax.
Introduction to Linguistics
Linguistic Essentials
Compiler Construction
Recap Lecture 4 Regular expression of EVEN-EVEN language, Difference between a* + b* and (a+b)*, Equivalent regular expressions; sum, product and closure.
Statistical NLP Winter 2009
Presentation transcript:

Natural Language Processing Lecture 6 : Revision

10/11/2015 NLP 2Revision 1. What is the part of speech? Give 4 examples Each part of speech explains what the word is, and how the word is used. In fact, the same word can be a noun in one sentence and a verb or adjective in the next. Example : noun, verb, preposition, pronoun 2. Complete the following sentences A closed class is a class that contains a relatively fixed set of words; An open class is a class that contains a constantly changing set of words Transitive verb: a verb that take a direct object complement. Intransitive verb: a verb that do not take a direct object. 3. Give 3 examples for closed classes Articles: a, an, the Conjunctions: and, but, or,... Demonstratives: this, that, these,...

10/11/2015 NLP 3Revision 4. Give the definition of the Tagging Tagging :The process of assigning a part-of-speech to each word in a corpus 5. Describe the three tagging methodologies Rule-Based Tagging : use a linguistic rules Stochastic Tagging : Based on probability of certain tag occurring given various possibilities. Requires a training corpus Transformation-Based Tagging : Combination of Rule-based and stochastic tagging methodologies

10/11/2015 NLP 4Revision 6. What is the role of the regular expressions? A regular expression is a formula in a special language that is used for specifying the regular languages. 7. What is the definition of : String : is a sequence of letters Defined over an alphabet Language : is a set of strings 8. What does specify the following regular expressions? /[3-9]*[A-Z]/ : zero or more digit followed by a capital letter \D : /[^0-9]/ : any non digit \w : : /[A-Za-z0-9 ]/ : any alphanumeric or space

10/11/2015 NLP 5Revision 9. Give the role of the Finite State Automata FSA recognize the regular languages represented by regular expressions 10. FSA is a 5-tuple consisting of : Q: set of states  : an alphabet of symbols q0: A start state F: a set of final states in Q  (q,i): a transition function mapping Q x  to Q

10/11/2015 NLP 6Revision 11. Give 3 words accepted by the following FSA abba, baba, aaaaba, baaaabbaba,

10/11/2015 NLP 7Revision 12. What is the syntax? Syntax is the study of the rules governing the way words are combined to form sentences in a language. 13. What is the role of : Syntactic analysis : is concerned with the construction of sentences. Syntactic structure : indicates how the words are related to each other. Lexicon : indicates syntactic category of words. Grammar (typically Context Free Grammar) : specifies legitimate concatenations of constituents(set of rules)

10/11/2015 NLP 8Revision 15. Describe the 4 types of grammar

10/11/2015 NLP 9Revision 16. Complete the sentences : Groups of words that belong together are called constituents The component that determines the properties of the constituent is the head, and the constituent can be referred to as a phrase. 17. Draw a labeled tree diagram for the following English phrases. a. The ancient pyramids b. in the early evening c. Drove a car

10/11/2015 NLP 10 Revision The NDet ancient Adj pyramids NP PP P NP The NDet early Adj evening in

10/11/2015 NLP 11 Revision Drove NPV a car VP Det N

10/11/2015 NLP 12Revision 18. Rewrite the following sentences with Phrase Structure Rules. The cat sits on a mat Peter told the truth.

10/11/2015 NLP 13Revision VPP on NPP a DetN matThe N sits S NPVP Det cat The cat sits on a mat

10/11/2015 NLP 14Revision V NP the DetN truth Peter told S NVP Peter told the truth

10/11/2015 NLP 15Revision 19. Draw the trees for the following sentences: The boy saw the man with the telescope The children put the toy in the box

10/11/2015 NLP 16Revision VPP with NPP the DetN telescopeThe N saw S NPVP Det boy NP the DetN man The boy saw the man with the telescope

10/11/2015 NLP 17Revision VPP in NPP the DetN boxThe N put S NPVP Det children NP the DetN toy The children put the toy in the box

Exercises 1.Build a non-deterministic finite automata that recognizes words in the alphabet {a, b} that end with bab.

2. Give the transitions tables a a a a a b b b a,b ba

b 3. Write the transitions table of the following automata. What is the recognized language? 10 ABA CBB CCC The recognized language is : 1*0+1(0 |1 )*

4. Determine the language for each regular expression : L(001) = {001} the word 001 L(0|10*) = {0,1,10,100,1000, , } 0 or all words that contain 1 followed by 0 or more L(0*10*) = { 1,01,10,100,001,010,00001, , } All words that contain 1

L(  )* = { w| w is a string of even length} all words over  L((0(0|1))*) = {ε,0,01,001,0001,0101 } all words that begin with 0 or ε L((0|ε)(1| ε)) = {01,0,1, ε } L ((0|ε|b)(1| a)) = {01,0a,1,a,b1,ba }