You are on page 1of 44

Natural Language Processing

CSE4022

Lecture-15: Lexical Syntax - Module 4


Word Classes, POS

Dr. Durgesh Kumar


Assistant Professor, SCOPE, VIT Vellore
Table of contents

1 Word Types

2 Hidden Markov Model (HMM)

September 20, 2022September 20, 2022 1/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Eight Parts-of-speech in English

1 Noun 5 Adverb
2 Verb 6 Conjunction
3 Pronoun 7 Particle
4 Preposition 8 Article

September 20, 2022September 20, 2022 2/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Eight parts-of-speech in English

1 Noun: A noun is the name of a person, place, thing, or idea. e.g.


New Delhi, Vellore, VIT, India

September 20, 2022September 20, 2022 3/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Eight parts-of-speech in English

1 Noun: A noun is the name of a person, place, thing, or idea. e.g.


New Delhi, Vellore, VIT, India
2 Pronoun: A pronoun is a word used in place of a noun. e.g.: I, you,
he, she, it, they, etc.

September 20, 2022September 20, 2022 3/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Eight parts-of-speech in English

1 Noun: A noun is the name of a person, place, thing, or idea. e.g.


New Delhi, Vellore, VIT, India
2 Pronoun: A pronoun is a word used in place of a noun. e.g.: I, you,
he, she, it, they, etc.
3 Verb: A verb expresses action or being. e.g: read, write, go, went,
jump.

September 20, 2022September 20, 2022 3/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Eight parts-of-speech in English

1 Noun: A noun is the name of a person, place, thing, or idea. e.g.


New Delhi, Vellore, VIT, India
2 Pronoun: A pronoun is a word used in place of a noun. e.g.: I, you,
he, she, it, they, etc.
3 Verb: A verb expresses action or being. e.g: read, write, go, went,
jump.
4 Adjective: An adjective modifies or describes a noun or pronoun. e.g
beautiful, handsome, smart, helpful, etc.

September 20, 2022September 20, 2022 3/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Eight parts-of-speech in English

1 Noun: A noun is the name of a person, place, thing, or idea. e.g.


New Delhi, Vellore, VIT, India
2 Pronoun: A pronoun is a word used in place of a noun. e.g.: I, you,
he, she, it, they, etc.
3 Verb: A verb expresses action or being. e.g: read, write, go, went,
jump.
4 Adjective: An adjective modifies or describes a noun or pronoun. e.g
beautiful, handsome, smart, helpful, etc.
5 Adverb: An adverb modifies or describes a verb, an adjective, or
another adverb.e.g. loudly, quickly

September 20, 2022September 20, 2022 3/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Eight parts-of-speech in English

6 Preposition: A preposition is a word placed before a noun or


pronoun to form a phrase modifying another word in the sentence.
e.g. at, in, to, from
7 Conjunction: A conjunction joins words, phrases, or clauses. e.g.
And, As, Because, But, For, Just as, Or, Neither, Nor, Not only, So„
Whether, Yet
8 Interjection: An interjection is a word used to express emotion. e.g.:
Nice! You got a Monster Kill in your first game! Sweet! I got a
PS4 for my birthday!. examples
9 Determiner or Article: A grammatical marker of definiteness (the) or
indefiniteness (a, an). These are not always considered POS but are
often included in POS tagging libraries.
September 20, 2022September 20, 2022 4/
Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Noun

September 20, 2022September 20, 2022 5/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Pronoun

September 20, 2022September 20, 2022 6/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Pronoun

September 20, 2022September 20, 2022 7/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Preposition

September 20, 2022September 20, 2022 8/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Preposition

September 20, 2022September 20, 2022 9/


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Preposition

September 20, 2022September 20, 2022 10 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Adjective

September 20, 2022September 20, 2022 11 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Adjective

September 20, 2022September 20, 2022 12 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Adverb

September 20, 2022September 20, 2022 13 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Adverb

September 20, 2022September 20, 2022 14 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
POS, word classes, Morphological classes or
lexical tags

1 45 for Penn Treebank (Marcus et al. 1993)


2 87 for Brown corpus (Francis 1979; Francis and Kucera, 1982)
3 146 for C7 tagsets (Garside et al. 1997)

September 20, 2022September 20, 2022 15 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Example of Tags from Penn TreeBank

September 20, 2022September 20, 2022 16 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
English Word classes

Part-of-speech can be divided into two broad categories:


1 closed class types - such as prepositions. Fixed membership. New
prepositions are rarely coined.
2 open class types – such as noun, verb. New nouns and verbs are
coined or borrowed from other language. e.g. to fax (Verb) =⇒
futon (Noun), Google (Verb), Googled, Googling.
September 20, 2022September 20, 2022 17 /
Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open class vs Closed class

Closed class
Prepositions, Determiners, Pronouns, Open class
Conjunctions, Auxiliary Verbs,
Noun, Verb, Adjective, Adverbs
Particles, Numerical
News nouns and Verbs are coined or
It has fixed membership. New
borrowed from other language.
Prepositions are rarely coined.
Any given speaker or corpus will have
All speakers of a language, large
different open class words.
corpora will likely share same set of
closed class words.

September 20, 2022September 20, 2022 18 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Closed Class words - Function Words

Function Words
Closed class words are also known as function words.

Function words are grammatical words like of, it, and, or you.

Function word tend to be short, occur frequently, and play important role in
grammar.

September 20, 2022September 20, 2022 19 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Closed class

1 Preposition: on, under, over, near, by, at, from, to, with
2 determiners: a, an, the.
3 pronouns: she, who, I, others.
4 Conjunctions: and, but, or, as, if, when.
5 auxiliary verbs: can, may, should, are.
6 particles: up, down, on, off, in, out, at, by.
7 numerals: one, two, three, first, second, third.

September 20, 2022September 20, 2022 20 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Closed class - Preposition and Particle

1 Preposition: occur before noun phrases, indicate spatial ( by the


house), temporal (before then) or metaphorical relations( on time,
beside herself). e.g.
Hamlet was written by Shakespeare.

September 20, 2022September 20, 2022 21 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Closed class - Preposition and Particle

1 Preposition: occur before noun phrases, indicate spatial ( by the


house), temporal (before then) or metaphorical relations( on time,
beside herself). e.g.
Hamlet was written by Shakespeare.
Nice __ meet you.

September 20, 2022September 20, 2022 21 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Closed class - Preposition and Particle

1 Preposition: occur before noun phrases, indicate spatial ( by the


house), temporal (before then) or metaphorical relations( on time,
beside herself). e.g.
Hamlet was written by Shakespeare.
Nice __ meet you. =⇒ to
I have two color pens. What __ you?

September 20, 2022September 20, 2022 21 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Closed class - Preposition and Particle

1 Preposition: occur before noun phrases, indicate spatial ( by the


house), temporal (before then) or metaphorical relations( on time,
beside herself). e.g.
Hamlet was written by Shakespeare.
Nice __ meet you. =⇒ to
I have two color pens. What __ you? =⇒ about
2 particles: a word that resembles a preposition, and often combined
with a verb to form a larger unit called phrasal verb. e.g. up, down,
on, off, in, out, at, by.
So I went on for some days cutting and hewing timber. =⇒ on is
followed by another pronoun for, instead of a noun phrase.
Moral reform is the effort to throw off sleep.

September 20, 2022September 20, 2022 21 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Examples of Prepositions and Particles

Table: Frequency count of Prepositions and particles from the COBUILD 16


million word corpus.

word freq word freq word freq

of 5,40,085 through 14,964 worth 1,563


in 3,31,235 after 13,670 toward 1,390
for 1,42,421 between 13,275 plus 750
to 1,25,691 under 9,525 till 686
with 1,24,965 per 6,515 amongst 525
on 1,09,129 among 5,090 via 351
at 1,00,169 within 5,030 amid 222
by 77,794 towards 4,700 underneath 164
from 74,843 above 3,056 versus 113
about 38,428 near 2,026 amidst 67
than 20,210 off 1,695 sans 20
over 18,071 past 1,575 circa 14

September 20, 2022September 20, 2022 22 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Example of single word particles

Table: Single word particles from Quirk et al. (1985).

abroad aside besides forwards(s) opposite through


about astray between home out throughout
above away beyond in outside together
across back by inside over under
ahead before close instead overhead underneath
alongside behind down near past up
apart below east off round within
around beneath eastwards on since without

September 20, 2022September 20, 2022 23 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Closed Class - Articles and Conjunctions

3 Article: Frequency of articles: a, an, the in COBUILD corpus:


a 1,071,676
an 413,887
59,359

4 Conjunctions: IT is uded to join


a, an, the

September 20, 2022September 20, 2022 24 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
For major open classes

Noun, Verbs, Adjectives, Adverbs

September 20, 2022September 20, 2022 25 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open Class - Noun

1 Proper Noun - Name of specific person or entities. e.g. IBM,


Colorado. Proper Noun are generally capitalized in English.
2 Common Noun - common nouns refer to generic people, places, and
things. e.g. man, woman, child, cop, criminal, city, town, country,.
Common Nouns are generally preceded by articles. e.g. The book is
upstairs.

September 20, 2022September 20, 2022 26 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open Class - Proper Noun vs Common Noun

Category Proper Noun Common Noun

Elon Mask, Cristiano Ronaldo, man, woman, child, cop,


People
Narendra Modi, Barack Obama criminal, friend, enemy
India, Vellore, Moscow,
city, town, country,
Places Europe, Asia, Australia,
state, outside, hallway
Colorado River, Sahara Desert
Jupiter, Google, Twitter, guitar, drums, apples,
Things
Kawasaki Ninja, Playstation 5 sky, stars, day, weeks
Ideas, Emotions Hinduism, Islam, happiness, sadness, fear,
, and Concepts Buddhism, Romanticism courage, confusion, doubt

September 20, 2022September 20, 2022 27 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open Class - Noun

1 Proper Noun - Name of specific person or entities.


2 Common Noun - common nouns refer to generic people, places, and
things.
count nouns: allows mathematical enumeration and can occur in
both singular and plural. e.g. goat/goats, one goat, two goats.
mass nouns: conceptualized as homogeneous group - e.g.- snow,
salt, and communism. Snow is white.

September 20, 2022September 20, 2022 28 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open Class - Verb

1 non-3rd-person-sg (eat)
2 3rd-person-sg (eats)
3 Progressive (eating)
4 simple past (ate)
5 past participle (eaten)

September 20, 2022September 20, 2022 29 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open Class - Verb

Auxiliary Verb
An auxiliary verb (or a helping verb) is used with a main verb to help
express the main verb’s tense, mood, or voice.

The main auxiliary verbs are to be, to have, and to do. They appear in
the following forms:
To Be: am, is, are, was, were, being, been, will be
To Have: has, have, had, having, will have
To Do: does, do, did, will do

September 20, 2022September 20, 2022 30 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open Class - Verb - Auxiliary Verb

What are the auxiliaries verb in the sentence below:


Tense:
He had eaten an apple.
He was snoring in all night.
Mood:
Did it go well?.
Do try our poori-dosa.
Voice:
The chocolate was eaten by me.

September 20, 2022September 20, 2022 31 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Verb - Auxiliary Verb

Tense:
He had eaten an apple. past perfect tense
He was snoring in all night. past progressive tense
Mood:
Did it go well?. interrogative mood
Do try our poori-dosa. imperative mood
Voice:
The chocolate was eaten by me. - passive voice

September 20, 2022September 20, 2022 32 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open class - Adjectives

color: white, black, red


age: young, old
value: good, bad

September 20, 2022September 20, 2022 33 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Open class - Adverbs

Directional Adverbs or locative adverbs: specify direction or location


of some action. e.g. home, here, downhill
degree adverbs: specify the extent of some action. e.g. slowly,
silkily, delicately
temporal adverbs: describe time of some action or an event. e.g.
yesterday, Monday

September 20, 2022September 20, 2022 34 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
Hidded Markov Model (HMM)

September 20, 2022September 20, 2022 35 /


Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36
September 20, 2022September 20, 2022 36 /
Dr. Durgesh Kumar Lecture-02 | NLP | CSE4022 36

You might also like