Title: Fall 2004
1EECS 595 / LING 541 / SI 661
Natural Language Processing
- Fall 2004
- Lecture Notes 8
2Discourse Analysis
3The problem
- Discourse
- Monologue and Dialogue (dialog)
- Human-computer interaction
- Example John went to Bills car dealership to
check out an Acura Integra. He looked at it for
about half an hour. - Example Id like to get from Boston to San
Francisco, on either December 5th or December
6th. Its okay if it stops in another city along
the way.
4Information extraction and discourse analysis
- Example First Union Corp. is continuing to
wrestle with severe problems unleashed by a
botched merger and a troubled business strategy.
According to industry insiders at Paine Webber,
their president, John R. Georgius, is planning to
retire by the end of the year. - Problems with summarization and generation
5Reference resolution
- The process of reference (associating John with
he). - Referring expressions and referents.
- Needed discourse models
- Problem many types of reference!
6Example (from Webber 91)
- According to John, Bob bought Sue an Integra, and
Sue bough Fred a legend. - But that turned out to be a lie. - referent is a
speech act. - But that was false. - proposition
- That struck me as a funny way to describe the
situation. - manner of description - That caused Sue to become rather poor. - event
- That caused them both to become rather poor. -
combination of several events.
7Reference phenomena
- Indefinite noun phrases I saw an Acura Integra
today. - Definite noun phrases The Integra was white.
- Pronouns It was white.
- Demonstratives this Acura.
- Inferrables I almost bought an Acura Integra
today, but a door had a dent and the engine
seemed noisy. - Mix the flour, butter, and water. Kneed the dough
until smooth and shiny.
8Constraints on coreference
- Number agreement John has an Acura. It is red.
- Person and case agreement () John and Mary have
Acuras. We love them (where WeJohn and Mary) - Gender agreement John has an Acura. He/it/she is
attractive. - Syntactic constraints
- John bought himself a new Acura.
- John bought him a new Acura.
- John told Bill to buy him a new Acura.
- John told Bill to buy himself a new Acura
- He told Bill to buy John a new Acura.
9Preferences in pronoun interpretation
- Recency John has an Integra. Bill has a Legend.
Mary likes to drive it. - Grammatical role John went to the Acura
dealership with Bill. He bought an Integra. - (?) John and Bill went to the Acura dealership.
He bought an Integra. - Repeated mention John needed a car to go to his
new job. He decided that he wanted something
sporty. Bill went to the Acura dealership with
him. He bought an Integra.
10Preferences in pronoun interpretation
- Parallelism Mary went with Sue to the Acura
dealership. Sally went with her to the Mazda
dealership. - ??? Mary went with Sue to the Acura dealership.
Sally told her not to buy anything. - Verb semantics John telephoned Bill. He lost his
pamphlet on Acuras. John criticized Bill. He lost
his pamphlet on Acuras.
11An algorithm for pronoun resolution
- Two steps discourse model update and pronoun
resolution. - Salience values are introduced when a noun phrase
that evokes a new entity is encountered. - Salience factors set empirically.
12Salience weights in Lappin and Leass
13Lappin and Leass (contd)
- Recency weights are cut in half after each
sentence is processed. - Examples
- An Acura Integra is parked in the lot. (subject)
- There is an Acura Integra parked in the lot.
(existential predicate nominal) - John parked an Acura Integra in the lot. (object)
- John gave Susan an Acura Integra. (indirect
object) - In his Acura Integra, John showed Susan his new
CD player. (demarcated adverbial PP)
14Algorithm
- Collect the potential referents (up to four
sentences back). - Remove potential referents that do not agree in
number or gender with the pronoun. - Remove potential referents that do not pass
intrasentential syntactic coreference
constraints. - Compute the total salience value of the referent
by adding any applicable values for role
parallelism (35) or cataphora (-175). - Select the referent with the highest salience
value. In case of a tie, select the closest
referent in terms of string position.
15Example
- John saw a beautiful Acura Integra at the
dealership last week. He showed it to Bob. He
bought it.
16Example (contd)
17Example (contd)
18Example (contd)
19Example (contd)
20Example (contd)
21Observations
- Lappin Leass - tested on computer manuals - 86
accuracy on unseen data. - Centering (Grosz, Josh, Weinstein) additional
concept of a center at any time in discourse,
an entity is centered. - Backwards looking center forward looking centers
(a set). - Centering has not been automatically tested on
actual data.
22Discourse structure
- () Bill went to see his mother. The trunk is
what makes the bonsai, it gives it both its grace
and power. - Coherence principle
- John hid Bills car keys. He was drunk
- ?? John hid Bills car keys. He likes spinach
- Rhetorical Structure Theory (Mann, Matthiessen,
and Thompson)
23Sample rhetorical relations
24Example (from MMT)
1) Title Bouquets in a basket - with living
flowers 2) There is a gardening revolution going
on. 3) People are planting flower baskets with
living plants, 4) mixing many types in one
container for a full summer of floral beauty. 5)
To create your own "Victorian" bouquet of
flowers, 6) choose varying shapes, sizes and
forms, besides a variety of complementary colors.
7) Plants that grow tall should be surrounded by
smaller ones and filled with others that tumble
over the side of a hanging basket. 8) Leaf
textures and colors will also be important. 9)
There is the silver-white foliage of dusty
miller, the feathery threads of lotus vine
floating down from above, the deep greens, or
chartreuse, even the widely varied foliage colors
of the coleus. Christian Science Monitor,
April, 1983
25Example (contd)
26Cross-document structure
27(No Transcript)
28(No Transcript)
29Dialogueand conversational agents
30Abbott You know, strange as it may seem, they
give ball players nowadays very peculiar
names...Now, on the Cooperstown team we have
Who's on first, What's on second, I Don't Know is
on third- Costello That's what I want to find
out. I want you to tell me the names of the
fellows on the Cooperstown team. Abbott I'm
telling you. Who's on first, What's on second, I
Don't Know is on third. Costello You know the
fellows' names? Abbott Yes. Costello Well,
then, who's playin' first? Abbott Yes.
Costello I mean the fellow's name on first
base. Abbott Who. Costello The fellow's name
on first base for Cooperstown. Abbott Who.
Costello The guy on first base. Abbott Who is
on first base. Costello Well, what are you
asking me for? Abbott I'm not asking you--I'm
telling you. Who is on first. Costello I'm
asking you--who's on first? Abbott That's the
man's name.
31Costello That's who's name? Abbott Yes.
Costello Well, go ahead, tell me! Abbott Who.
Costello The guy on first. Abbott Who.
Costello The first baseman. Abbott Who is on
first. Costello Have you got a first baseman on
first? Abbott Certainly. Costello Well, all
I'm trying to find out is what's the guy's name
on first base. Abbott Oh, no, no. What is on
second base. Costello I'm not asking you who's
on second.
32What makes dialogue different
- Turns and utterances (turn-taking)
- Turn-taking rules
- At each TRP (transition-relevance place)
- designated speaker, any speaker, current speaker
- Barge-in possible
- Significant silence
- A Is there something bothering you or not? (1.0
s) - A Yes or no? (1.5 s)
- A Eh?
- B No.
33Grounding
- Common ground between speaker and hearer.
- A returning on flight 1118
- C mm hmmm (backchannel, acknowledgment token)
- Other continuers
- Continued attention
- Relevant next contribution
- Acknowledgement (e.g. sure)
- Demonstration (paraphrasing, reformulating)
- Display (repeat verbatim)
- Example
- C I will take the 5 pm flight on the 11th.
- A On the 11th?
34Conversational Implicature
- Example
- When do you want to travel?
- I have a meeting there early in the morning on
the 13th. - Implicature licensed inferences reasonable
hearers can make. - Quantity
- Agent there are three non-stop flights daily
35Grices maxims
- Maxim of quantity
- make your contribution informative
- but not more than needed
- Maxim of quality
- do not say what you believe is false
- do not say that for which you lack evidence
- Maxim of relevance
- Maxim of manner
- avoid ambiguity
- avoid obscurity
- be brief
- be orderly
36Dialogue acts
- Performative sentences
- I name this ship the Titanic
- I second that motion
- I bet you five dollars that it will snow tomorrow
- Speech acts
- locutionary acts uttering a sentence with a
particular meaning - illocutionary acts asking, promising, answering
- perlocutionary acts producing effects upon the
feelings, thoughts, or actions of the addressee
37Speech acts (contd)
- Assertives suggesting, putting forward,
swearing, boasting, concluding - Directives asking, ordering, requesting,
inviting, advising, begging - Commissives promising, planning, vowing,
betting, opposing - Expressives thanking, apologizing, welcoming,
deploring - Declarations I resign, youre fired.
38Automatic interpretation of dialogue acts
- DAMSL - Dialogue Act Markup in Several Layers
- Agreement (Accept, Maybe, Reject-Part, Hold)
- Answer
- Understanding (Signal-not-understood,
Signal-understood, ack, repeat-rephrase,
completion)
39Techniques for DA recognition
- Plan theoretic (agents, assumptions, goals)
- Cue-based (please, are you?, rising pitch,
stress - agreement vs. backchannel) - Statistical approaches
40Semantic Analysis
41Syntax-Driven Semantic Analysis
- Meaning representations are assigned to
linguistic inputs - Needed static knowledge from the lexicon and
grammar - Principle of compositionality
42Principle of compositionality
- The meaning of a sentence is composed of the
meanings of its parts. - Ordering and grouping are important
- Problem which subcategorization frame? In
general a lot of knowledge about the particular
example is needed.
43Example
? e Isa (e,Serving) Server (e, NachoMamas)
Served (e, fajitas)
S
NP
VP
NP
Proper-Noun
Mass-Noun
Verb
NachoMamas
serves
fajitas
44Two important questions
- What does it mean for syntactic constituents to
have meanings? - What do these meanings have to be like so that
they can be composed into larger meanings?
45Semantic Augmentation to CFG Rules
- Semantic attachments
- A ? a1 an f(aj.sem, ,
ak.sem) - ProperNoun ? NachoMamas NachoMamasMassNoun
? fajitas fajitasNP ? ProperNoun
ProperNoun.semNP ? MassNoun MassNoun.semVerb
? serves ? e,x,y Isa (e,Serving) Server (e,
x) Served (e, y)Verb ? Isa (e,Serving)
Server (e,x) Served (e,fajitas) - Typical approaches include using lambda-calculus.
46Readings for next time