1 Introduction to Computational Linguistics Eleni Miltsakaki AUTH Spring 2006-Lecture 2.

Slides:



Advertisements
Similar presentations
The Structure of Sentences Asian 401
Advertisements

Introduction to Natural Language Processing A.k.a., “Computational Linguistics”
Syntactic analysis using Context Free Grammars. Analysis of language Morphological analysis – Chairs, Part Of Speech (POS) tagging – The/DT man/NN left/VBD.
Syntax Constituency, Phrase structure rules LING 400 Winter 2010.
Grammars, constituency and order A grammar describes the legal strings of a language in terms of constituency and order. For example, a grammar for a fragment.
Grammars, Languages and Parse Trees. Language Let V be an alphabet or vocabulary V* is set of all strings over V A language L is a subset of V*, i.e.,
1 Introduction to Linguistics II Ling 2-121C, group b Lecture 4 Eleni Miltsakaki AUTH Spring 2006.
Statistical NLP: Lecture 3
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?
GRAMMAR & PARSING (Syntactic Analysis) NLP- WEEK 4.
LING NLP 1 Introduction to Computational Linguistics Martha Palmer April 19, 2006.
Natural Language Processing - Feature Structures - Feature Structures and Unification.
1 Words and the Lexicon September 10th 2009 Lecture #3.
1 Introduction to Computational Linguistics Eleni Miltsakaki AUTH Spring 2006-Lecture 4.
Syntax Phrase and Clause in Present-Day English. The X’ phrase system Any X phrase in PDE consists of: – an optional specifier – X’ (X-bar) which is the.
1 Introduction to Computational Linguistics Eleni Miltsakaki AUTH Fall 2005-Lecture 2.
1 CONTEXT-FREE GRAMMARS. NLE 2 Syntactic analysis (Parsing) S NPVP ATNNSVBD NP AT NNthechildrenate thecake.
1 CSC 594 Topics in AI – Applied Natural Language Processing Fall 2009/ Outline of English Syntax.
Artificial Intelligence 2004 Natural Language Processing - Syntax and Parsing - Language Syntax Parsing.
The students will be able to know:
Constituency Tests Phrase Structure Rules
THE PARTS OF SYNTAX Don’t worry, it’s just a phrase ELL113 Week 4.
11 CS 388: Natural Language Processing: Syntactic Parsing Raymond J. Mooney University of Texas at Austin.
Constituents  Sentence has internal structure  The structures are represented in our mind  Words in a sentence are grouped into units, and these units.
Context Free Grammars Reading: Chap 12-13, Jurafsky & Martin This slide set was adapted from J. Martin, U. Colorado Instructor: Paul Tarau, based on Rada.
PARSING David Kauchak CS457 – Fall 2011 some slides adapted from Ray Mooney.
1 LIN 1310B Introduction to Linguistics Prof: Nikolay Slavkov TA: Qinghua Tang CLASS 14, Feb 27, 2007.
CIS 8590 – Fall 2008 NLP 1 Introduction to Natural Language Processing (aka, Computational Linguistics) Slides by me, Martha Palmer, Eleni Miltsakaki,
Introduction to English Syntax Level 1 Course Ron Kuzar Department of English Language and Literature University of Haifa Chapter 2 Sentences: From Lexicon.
Chapter 4 Syntax Part II.
Introduction to Linguistics
ASPECTS OF LINGUISTIC COMPETENCE 4 SEPT 09, 2013 – DAY 6 Brain & Language LING NSCI Harry Howard Tulane University.
Dr. Monira Al-Mohizea MORPHOLOGY & SYNTAX WEEK 12.
CS : Language Technology for the Web/Natural Language Processing Pushpak Bhattacharyya CSE Dept., IIT Bombay Constituent Parsing and Algorithms (with.
NLP. Introduction to NLP Is language more than just a “bag of words”? Grammatical rules apply to categories and groups of words, not individual words.
King Abdulaziz University Department of European Languages & Literature Syntax (LANE-334) Chapter 3 Functions Dr. Abdulrahman Alqurashi Dr. Abdulrahman.
By: Hannah Gettings.  Definition of pronoun: a word used in place of a noun.  Example: She gave him the book. *say for example the names of the people.
Context Free Grammars Reading: Chap 9, Jurafsky & Martin This slide set was adapted from J. Martin, U. Colorado Instructor: Rada Mihalcea.
11 Chapter 14 Part 1 Statistical Parsing Based on slides by Ray Mooney.
第一章 语法层次和基本句子结构 内容提要: ◆语法在语言系统中的地位语法在语言系统中的地位 ◆语法的五个层次:词素、词、词组、分句、 句子语法的五个层次:词素、词、词组、分句、 句子 ◆分句结构和基本句型分句结构和基本句型.
Notes on Pinker ch.7 Grammar, parsing, meaning. What is a grammar? A grammar is a code or function that is a database specifying what kind of sounds correspond.
Syntax Why is the structure of language (syntax) important? How do we represent syntax? What does an example grammar for English look like? What strategies.
For Wednesday Read chapter 23 Homework: –Chapter 22, exercises 1,4, 7, and 14.
Parsing with Context-Free Grammars for ASR Julia Hirschberg CS 4706 Slides with contributions from Owen Rambow, Kathy McKeown, Dan Jurafsky and James Martin.
CPE 480 Natural Language Processing Lecture 4: Syntax Adapted from Owen Rambow’s slides for CSc Fall 2006.
Rules, Movement, Ambiguity
Natural Language - General
PARSING 2 David Kauchak CS159 – Spring 2011 some slides adapted from Ray Mooney.
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
CPSC 422, Lecture 27Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 27 Nov, 16, 2015.
◦ Process of describing the structure of phrases and sentences Chapter 8 - Phrases and sentences: grammar1.
1 Introduction to Computational Linguistics Eleni Miltsakaki AUTH Fall 2005-Lecture 3.
TYPES OF PHRASES REPRESENTING THE INTERNAL STRUCTURE OF PHRASES 12/5/2016.
CSA3050: NLP Algorithms Sentence Grammar NLP Algorithms.
Basic Syntactic Structures of English CSCI-GA.2590 – Lecture 2B Ralph Grishman NYU.
NATURAL LANGUAGE PROCESSING
Language Structure Lecture 1: Introduction & Overview Helena Frännhag Spring 2013.
PARTS OF A SENTENCE. The subject of an English sentence is the person or thing that performs the action, or that the sentence makes a statement about.
King Faisal University جامعة الملك فيصل Deanship of E-Learning and Distance Education عمادة التعلم الإلكتروني والتعليم عن بعد [ ] 1 King Faisal University.
Beginning Syntax Linda Thomas
Statistical NLP: Lecture 3
BBI 3212 ENGLISH SYNTAX AND MORPHOLOGY
Syntax Word order, constituency
Intensive verb Syifa Khoirunnisa.
Part I: Basics and Constituency
Syntax.
BBI 3212 ENGLISH SYNTAX AND MORPHOLOGY
Natural Language - General
Presentation transcript:

1 Introduction to Computational Linguistics Eleni Miltsakaki AUTH Spring 2006-Lecture 2

2 Outline of English syntax Words Phrases Simple Sentences

3 Review What is computational linguistics? What is the subject matter of theoretical computational linguistics? What is the subject matter of applied computational linguistics? Why is language hard for the computer?

4 Review Give examples of –Syntactic ambiguity –Semantic ambiguity –Phonological ambiguity

5 Words Two basic ways to form words –Inflectional (e.g. English verbs) Open + ed = opened Open + ing = opening –Derivational (e.g. adverbs from adjectives, nouns from adjectives) Happy  happily Happy  happiness (nouns from adjectives)

6 Basic classes of words Classes of words aka parts of speech (POS) –Nouns –Verbs –Adjectives –Adverbs The above classes of word belong to the type open class words We also have closed class words –Articles, pronouns, prepositions, particles, quantifiers, conjunctions

7 Basic phrases A word from an open class can be used to form the basis of a phrase The basis of a phrase is called the head

8 Examples of phrases Noun phrases –The manager of the institute –Her worry to pass the exams –Several students from the English Department Adjective phrases –easy to understand –mad as a dog –glad that he passed the exam

9 Examples of phrases Adverb phrases –fast like the wind –outside the building Verb phrases –ate her sandwich –went to the doctor –believed what I told him

10 “Complements” Notice that to be meaningful the verb “go”, for example requires a phrase for “location” –*John went –John went home Such phrases “complete” the meaning of the verb (or other type of head) and are called complements

11 Inside the noun phrase NPs are used to refer to things: objects, places, concepts, events, qualities, etc NPs may consist of: –A single pronoun (he, she, etc) –A name or proper noun (John, Athens, etc) –A specifier and a noun –A qualifier and a noun –A specifier and a qualifier and a noun (e.g., the first three winners)

12 Specifiers Specifiers indicate how many objects are described and also how these objects relate to the speaker Basis types of specifiers –Ordinals (e.g., first, second) –Cardinals (e.g., one, two) –Determiners (see next slide)

13 Determiners Basic types of determiners –Articles (the, a, an) –Demonstratives (this, that, these, those) –Possessives (‘s, her, my, whose, etc) –Wh-determiners (which, what –in questions) –Quantifying determiners (some, every, most, no, any etc)

14 Qualifiers Basic types of qualifiers –Adjectives Happy cat Angry feelings –Noun modifiers Cook book University hospitals

15 Inside the verb phrase A simple VP –Adverbial modifier + head verb + complements Types of verbs –Auxiliary (be, do, have) –Modal (will, can, could) –Main (eat, work, think)

16 Types of verb complements Intransitive verbs do not required complements Transitive verbs require an object as a complement (e.g. find a key) Transitive verbs allow passive forms (e.g. a key was found) Ditransitive verbs require one direct and on indirect object (e.g. give Mary a book)

17 Other verb complements Clausal complements –Some verbs require clausal complements Mary knows that John left Prepositional phrase complements –Some verbs requires specific PP complements Mary gave the book to John –Others require any PP complement John put the book on the shelf/in the room/under the table

18 Adjective phrases Simple –Angry, easy, etc Complex –Pleased with the prize –Angry at the committee –Willing to read the book Complex AdjP normally do not precede nouns, they are used as complements of verbs such as be or seem

19 Adverbial phrases Indicators of –Degree –Location –Manner –The time of something (now, yesterday, etc) –Frequency –Duration Location in the sentence –Initial –Medial –Final

20 The famous argument-adjunct problem Sometimes it’s hard to say if an adverbial is a verb complement (i.e. it’s an argument of the verb) or simply a modification of the verb phrase (i.e. an adjunct) Consider –Mary put the book on the shelf –*Mary put –Mary painted the room with a brush –Mary painted the room

21 Grammars and parsing What is syntactic parsing –Determining the syntactic structure of a sentence Basic steps –Identify sentence boundaries –Identify what part of speech is each word –Identify syntactic relations

22 Tree representation John ate the pizza (S (NP (N John)) (VP (V ate) (NP (Det the) (N cat))))

23 Some basic tree terminology Nodes Links Root Leaves Parent node Child node Ancestor The notion of “domination”

24 How to construct a tree To construct a tree of an English sentence you need to know which structure are legal in English Rewrite rules –Describe what tree structures are allowed in the language

25 Rewrite rules for English NP==> N NP==> Det NP VP==> V VP ==> V NP S ==> NP VP S ==> NP VP ==> N VP ==> John VP ==> John V NP ==> John ate NP ==> John ate Det N ==> John ate the N ==> John ate the pizza

26 What makes a good grammar? Generality –The range of sentences covered by the rules Selectivity –The range of sentences that can be identified as ungrammatical Understandability –How simple the grammar is

27 Hint for making rules general Pay attention to constituents Diagnostic of constituency –Conjunction Compare –I ate a hamburger and a hot dog –I will eat the hamburger and throw away the hot dog –I ate a hamburger and John ate a hot dog –*I ate a hamburger and on the stove –*I ate a cold hot dog and well burned –*I ate the hot dog

28 How the conjunction test can help Compare –I looked up John’s number –I looked up John’s chimney –*I looked up John’s number and in his cupboards –I looked up John’s chimney and in his cupboards

29 Parsing strategies Top-down –A top down parser starts with S and attempts to rewrite it into a sequence of terminal symbols that matches the words in the input sentence Bottom-up –You take a sequence of symbols and match it to the right hand side of the rule, i.e. start with Det N and match it to get the NP Bottom-up chart parsing –To avoid unnecessary repetition of the matching process you use a data structure called chart that allows you to record partial results We’ll see examples in J. Allen’s Natural Language Understanding, Chapter 3

30 What is generative capacity? The range of languages that a formalism can describe Formal languages allow a precise (mathematic) characterization Natural languages CANNOT be characterized precisely enough to define generative capacity