Generating ¡and ¡Interpreting ¡Referring ¡Expressions ¡in ¡Context
Dustin ¡Smith
Tuesday, November 5, 13
Generating and Interpreting Referring Expressions in Context Dustin - - PowerPoint PPT Presentation
Generating and Interpreting Referring Expressions in Context Dustin Smith 1 Tuesday, November 5, 13 The three readers Henry Agustn Marvin Lieberman Rayo Minsky 2 Tuesday, November 5, 13 3 Tuesday,
Generating ¡and ¡Interpreting ¡Referring ¡Expressions ¡in ¡Context
Dustin ¡Smith
Tuesday, November 5, 13The ¡three ¡readers ¡
2Henry ¡ Lieberman Agustín Rayo Marvin Minsky
Tuesday, November 5, 13Types ¡of ¡Referring ¡Expressions
7classification from [Cruse 2011]
Types ¡of ¡Referring ¡Expressions
I’d ¡like ¡the ¡tuna
8classification from [Cruse 2011]
Types ¡of ¡Referring ¡Expressions
I’d ¡like ¡a ¡tuna
9classification from [Cruse 2011]
Types ¡of ¡Referring ¡Expressions
I ¡usually ¡like ¡tuna
10classification from [Cruse 2011]
Types ¡of ¡Referring ¡Expressions
I’d ¡like ¡the ¡Albacore ¡tuna
11classification from [Cruse 2011]
Types ¡of ¡Referring ¡Expressions
I’d ¡like ¡the ¡Albacore ¡tuna
11classification from [Cruse 2011]
Ambiguity: financial/river/blood/sperm bank
Tuesday, November 5, 13Ambiguity: financial/river/blood/sperm bank Widening: does financial banks include ATMs?
Tuesday, November 5, 13Ambiguity: financial/river/blood/sperm bank Widening: does financial banks include ATMs? “the”: User believes a single such referent exists
Tuesday, November 5, 13Ambiguity: financial/river/blood/sperm bank Vagueness: how “new” is a new bank? Widening: does financial banks include ATMs? “the”: User believes a single such referent exists
Tuesday, November 5, 13“new”: The description “the bank” alone would have included 1+ older banks. Ambiguity: financial/river/blood/sperm bank Vagueness: how “new” is a new bank? Widening: does financial banks include ATMs? “the”: User believes a single such referent exists
Tuesday, November 5, 13Context-‑dependent ¡Meanings
18example from [Rayo 2007]
Go ¡to ¡the ¡blue ¡house
Tuesday, November 5, 13Context-‑dependent ¡Meanings
18example from [Rayo 2007]
Go ¡to ¡the ¡blue ¡house
Tuesday, November 5, 13+ “the blue ones”
Context Set Referring Expression Interpretation
Context-‑dependence ¡
Context-‑dependent ¡issues ¡in ¡Interpreta+on:
“the ¡blue ¡ones”
[Sperber ¡& ¡Wilson, ¡2012]
Tuesday, November 5, 13+ “the blue ones”
Context Set Referring Expression Interpretation
Context-‑dependence ¡
Context-‑dependent ¡issues ¡in ¡Interpreta+on:
[Sperber ¡& ¡Wilson, ¡2012]
“the ¡blue ¡ones”
Tuesday, November 5, 13[Tanenhaus, Spivey-Knowlton, Eberhard, & Sedivy, 1995]
Incremental ¡Interpretation
Let’s ¡go ¡fish ¡by ¡the ¡bank ¡
Tuesday, November 5, 13[Tanenhaus, Spivey-Knowlton, Eberhard, & Sedivy, 1995]
Incremental ¡Interpretation
Let’s ¡go ¡fish ¡by ¡the ¡bank ¡ ¡of ¡America
Tuesday, November 5, 13[Tanenhaus, Spivey-Knowlton, Eberhard, & Sedivy, 1995]
Incremental ¡Interpretation
Let’s ¡go ¡fish ¡by ¡the ¡bank ¡ ¡of ¡America Let’s ¡go ¡watch ¡a ¡short ¡movie
Tuesday, November 5, 13[Tanenhaus, Spivey-Knowlton, Eberhard, & Sedivy, 1995]
Incremental ¡Interpretation
Let’s ¡go ¡fish ¡by ¡the ¡bank ¡ ¡by ¡Ken ¡Burns ¡of ¡America Let’s ¡go ¡watch ¡a ¡short ¡movie
Tuesday, November 5, 13[Tanenhaus, Spivey-Knowlton, Eberhard, & Sedivy, 1995]
Incremental ¡Interpretation
Let’s ¡go ¡fish ¡by ¡the ¡bank ¡ “put ¡the ¡[blue ¡triangle ¡on ¡the ¡tray] ¡on ¡the ¡box” ¡ ¡by ¡Ken ¡Burns ¡of ¡America Let’s ¡go ¡watch ¡a ¡short ¡movie
Tuesday, November 5, 13[Tanenhaus, Spivey-Knowlton, Eberhard, & Sedivy, 1995]
Incremental ¡Interpretation
Let’s ¡go ¡fish ¡by ¡the ¡bank ¡ “put ¡the ¡[blue ¡triangle ¡on ¡the ¡tray] ¡on ¡the ¡box” ¡
“put ¡the ¡tall ¡-‑-‑” ¡by ¡Ken ¡Burns ¡of ¡America Let’s ¡go ¡watch ¡a ¡short ¡movie
Tuesday, November 5, 13Involving ¡Speaker ¡and ¡Hearer
22Genera+on: ¡given ¡an ¡intended ¡meaning, ¡produce ¡a ¡referring ¡ expression ¡that ¡will ¡allow ¡a ¡human ¡listener ¡to ¡derive ¡it Interpreta+on: ¡Given ¡a ¡human ¡speaker’s ¡referring ¡expression, ¡ infer ¡her ¡intended ¡meaning
I’d ¡like ¡the ¡Albacore ¡tuna Okay
Tuesday, November 5, 13Involving ¡Speaker ¡and ¡Hearer
22Genera+on: ¡given ¡an ¡intended ¡meaning, ¡produce ¡a ¡referring ¡ expression ¡that ¡will ¡allow ¡a ¡human ¡listener ¡to ¡derive ¡it Interpreta+on: ¡Given ¡a ¡human ¡speaker’s ¡referring ¡expression, ¡ infer ¡her ¡intended ¡meaning
I’d ¡like ¡the ¡Albacore ¡tuna Okay I’d ¡like ¡tuna
Tuesday, November 5, 13Involving ¡Speaker ¡and ¡Hearer
22Genera+on: ¡given ¡an ¡intended ¡meaning, ¡produce ¡a ¡referring ¡ expression ¡that ¡will ¡allow ¡a ¡human ¡listener ¡to ¡derive ¡it Interpreta+on: ¡Given ¡a ¡human ¡speaker’s ¡referring ¡expression, ¡ infer ¡her ¡intended ¡meaning
I’d ¡like ¡the ¡Albacore ¡tuna Okay I’d ¡like ¡tuna I’d ¡like ¡the ¡tuna ¡burger
Tuesday, November 5, 13/122
Related ¡Work
Appelt ¡1985; ¡Stone ¡& ¡Doran, ¡1997; ¡ ¡Koller ¡& ¡Stone ¡2007; ¡Koller ¡& ¡Petrick ¡ 2011 1. Modeling ¡vague ¡and ¡gradable ¡adjectives ¡ ¡Lassiter ¡2011; ¡Klein ¡1990; ¡ Bartsch ¡& ¡Vennermann ¡1976; ¡Zadeh ¡1975; 2. Modeling ¡both ¡generation ¡and ¡interpretation ¡Winograd ¡1976; ¡Appelt ¡ 1986; ¡ ¡Heeman ¡& ¡Hirst ¡1995
reasoning ¡about ¡generation. ¡Benotti ¡and ¡Traum ¡2009; ¡ ¡Bergen ¡
et ¡al ¡2012; ¡ ¡Goodman ¡& ¡Stuhlmüller ¡2013; ¡ ¡Vogel ¡et ¡al ¡2013 23
What’s ¡missing? ¡ ¡Computational ¡models ¡of ¡interpretation ¡and ¡ generation ¡that ¡are ¡fast, ¡incremental, ¡non-‑deterministic, ¡and ¡ address ¡context-‑dependencies.
Tuesday, November 5, 13/122 24
Presentation ¡Overview
I. A ¡computational ¡model ¡for ¡Automatically ¡Interpreting ¡& ¡ Generating ¡Referring ¡Expressions ¡(AIGRE)
1. Generation ¡as ¡belief-‑state ¡planning, ¡Interpretation ¡as ¡plan-‑recognition
2. Handles ¡context-‑dependent ¡word ¡meanings ¡for ¡a ¡fragment ¡of ¡English ¡NPs 3. Evaluation ¡on ¡Mechanical ¡Turk ¡Data
speakers’ ¡decisions
Tuesday, November 5, 13Context-‑dependent ¡Meanings
25 Denotation Context Reference Resolution Speaker Meaning Context Pragmatic Inference Encoded Meaning Linguistic Decoding Referring Expression Standard Model of Interpretation¡the ¡blue ¡house
Tuesday, November 5, 13Context-‑dependent ¡Meanings
26¡the ¡blue ¡house
[∃x [∀y blue1(y) ∧ house(y) → x = y]] ∨ [∃x [∀y blue2(y) ∧ house(y) → x = y]] Tuesday, November 5, 13Context-‑dependent ¡Meanings
27¡the ¡blue ¡house
[∃x [∀y blue1(y) ∧ house(y) → x = y]] ∨ [∃x [∀y blue2(y) ∧ house(y) → x = y]]. . . ∴ ¬blue1
Tuesday, November 5, 13Context-‑dependent ¡Meanings
28¡the ¡blue ¡house
[∃x [∀y blue1(y) ∧ house(y) → x = y]] ∨ [∃x [∀y blue2(y) ∧ house(y) → x = y]]. . . ∴ ¬blue1
x = x1349A3
Tuesday, November 5, 13NLU/NLG ¡Pipelines
Tuesday, November 5, 13NLU/NLG ¡Pipelines
Tuesday, November 5, 13The ¡“Lexical ¡Approach”
30[Stone & Doran, 1997; Koller & Stone 2007; Koller & Petrick 2011]
Meaning Representation Meaning Representation All linguistic encoding decisions All linguistic decoding decisions Referring Expression Generation Interpretation Context
Tuesday, November 5, 13The ¡“Lexical ¡Approach”
31Meaning Representation Meaning Representation All linguistic encoding decisions All linguistic decoding decisions Referring Expression Generation Interpretation Context
[Stone & Doran, 1997; Koller & Stone 2007; Koller & Petrick 2011]
Given ¡varying ¡initial ¡conditions
Tuesday, November 5, 13The ¡“Lexical ¡Approach”
31Meaning Representation Meaning Representation All linguistic encoding decisions All linguistic decoding decisions Referring Expression Generation Interpretation Context
[Stone & Doran, 1997; Koller & Stone 2007; Koller & Petrick 2011]
Given ¡varying ¡initial ¡conditions Choose ¡content, ¡words, ¡and ¡arrange ¡ them ¡in ¡order
Tuesday, November 5, 13The ¡“Lexical ¡Approach”
31Meaning Representation Meaning Representation All linguistic encoding decisions All linguistic decoding decisions Referring Expression Generation Interpretation Context
[Stone & Doran, 1997; Koller & Stone 2007; Koller & Petrick 2011]
Given ¡varying ¡initial ¡conditions Stop ¡when ¡ ¡ communication ¡goal ¡is ¡met Choose ¡content, ¡words, ¡and ¡arrange ¡ them ¡in ¡order
Tuesday, November 5, 13Generation ¡→ ¡Planning
lexical ¡entries encoded ¡meaning
the ¡meaning ¡of ¡the ¡referring ¡expression. ¡ Both ¡as ¡(1) ¡an ¡intensional ¡descrip.on and ¡(2) ¡its ¡referents ¡(denotaMon)
goal
meaning ¡that ¡idenMfies ¡targets change ¡encoded ¡meaning, ¡while ¡ adhering ¡to ¡semanMc ¡and ¡ morphosyntacMc ¡constraints
32ac+ons
change ¡the ¡state
state
representaMon ¡of ¡the ¡relevant ¡parts ¡of ¡ the ¡problem ¡or ¡environment
goal
desired ¡state(s)
Tuesday, November 5, 13Generation ¡→ ¡Planning
lexical ¡entries encoded ¡meaning
the ¡meaning ¡of ¡the ¡referring ¡expression. ¡ Both ¡as ¡(1) ¡an ¡intensional ¡descrip.on and ¡(2) ¡its ¡referents ¡(denotaMon)
goal
meaning ¡that ¡idenMfies ¡targets change ¡encoded ¡meaning, ¡while ¡ adhering ¡to ¡semanMc ¡and ¡ morphosyntacMc ¡constraints
33ac+ons
change ¡the ¡state
state
representaMon ¡of ¡the ¡relevant ¡parts ¡of ¡ the ¡problem ¡or ¡environment
goal
desired ¡state(s)
Tuesday, November 5, 13the cost: 0.01 1 size:7 2 size:7
Generation ¡→ ¡Planning
lexical ¡entries encoded ¡meaning
the ¡meaning ¡of ¡the ¡referring ¡expression. ¡ Both ¡as ¡(1) ¡an ¡intensional ¡descrip.on and ¡(2) ¡its ¡referents ¡(denotaMon)
goal
meaning ¡that ¡idenMfies ¡targets change ¡encoded ¡meaning, ¡while ¡ adhering ¡to ¡semanMc ¡and ¡ morphosyntacMc ¡constraints
33ac+ons
change ¡the ¡state
state
representaMon ¡of ¡the ¡relevant ¡parts ¡of ¡ the ¡problem ¡or ¡environment
goal
desired ¡state(s)
state ac+on state
Tuesday, November 5, 1370, ∞)
cost: 2.55 3 size:1 6 size:1
Generation ¡→ ¡Planning
lexical ¡entries encoded ¡meaning
the ¡meaning ¡of ¡the ¡referring ¡expression. ¡ Both ¡as ¡(1) ¡an ¡intensional ¡descrip.on and ¡(2) ¡its ¡referents ¡(denotaMon)
goal
meaning ¡that ¡idenMfies ¡targets change ¡encoded ¡meaning, ¡while ¡ adhering ¡to ¡semanMc ¡and ¡ morphosyntacMc ¡constraints
33ac+ons
change ¡the ¡state
state
representaMon ¡of ¡the ¡relevant ¡parts ¡of ¡ the ¡problem ¡or ¡environment
goal
desired ¡state(s)
state ac+on goal ¡state
Tuesday, November 5, 13C1 C2 C3
/122
The ¡CIRCLES ¡referential ¡domain
34
Tuesday, November 5, 13C1 C2 C3
the cost: 0.01 big1 (size) standard: [70, ∞) cost: 1.40/122
The ¡CIRCLES ¡referential ¡domain
35
Tuesday, November 5, 13C1 C2 C3
the cost: 0.01 big1 (size) standard: [70, ∞) cost: 1.40/122 36
“the ¡big ¡one”
R=3
Tuesday, November 5, 13C1 C2 C3
/122 37
“the ¡green ¡circles”
Tuesday, November 5, 13C1 C2 C3
38“a ¡green ¡circle”
a cost: 0.61 green cost: 1.61 circle cost: 2.91 b0 size:7 b1 size:7 b2 size:7 b3 size:2 Tuesday, November 5, 13“a ¡green ¡circle”
a cost: 0.61 green cost: 1.61 circle cost: 2.91 b0 size:7 b1 size:7 b2 size:7 b3 size:2 Tuesday, November 5, 13“a ¡green ¡circle”
a cost: 0.61 green cost: 1.61 circle cost: 2.91 b0 size:7 b1 size:7 b2 size:7 b3 size:2 0.0 0.5 1.0 Relative likelihood of denotation circle green a “a green circle” in CIRCLES domain Possible Targets {c1} {c2} {c3} {c1, c2} {c1, c3} {c2, c3} {c1, c2, c3} Tuesday, November 5, 13“any ¡two ¡circles”
0.0 0.5 1.0 Relative likelihood of denotation circles two any “any two circles” in CIRCLES domain Possible Targets {c1} {c2} {c3} {c1, c2} {c1, c3} {c2, c3} {c1, c2, c3} Tuesday, November 5, 13Representing ¡Referents
Belief ¡states ¡represent ¡an ¡intensional ¡descrip.on ¡of ¡the ¡ reference ¡domain. ¡ ¡This ¡is ¡a ¡conBnuum ¡between ¡a ¡category ¡of ¡ enBBes ¡and ¡a ¡single ¡enBty ¡in ¡the ¡referenBal ¡domain.
SHAPE: circle SIZE: 30 COLOR: green SHAPE: circle SIZE: 60 COLOR: green SHAPE: circle SIZE: 120 COLOR: bluesymbolic ¡
c1 c2 c3
visual ¡ aNribute-‑value ¡
40 Tuesday, November 5, 13Representing ¡Referents
Belief ¡states ¡represent ¡an ¡intensional ¡descrip.on ¡of ¡the ¡ reference ¡domain. ¡ ¡This ¡is ¡a ¡conBnuum ¡between ¡a ¡category ¡of ¡ enBBes ¡and ¡a ¡single ¡enBty ¡in ¡the ¡referenBal ¡domain.
SHAPE: circle SIZE: 30 COLOR: green SHAPE: circle SIZE: 60 COLOR: green SHAPE: circle SIZE: 120 COLOR: bluesymbolic ¡
c1 c2 c3
40 Tuesday, November 5, 13Representing ¡Belief ¡States
BoolCell DictCell IntervalCell LatLonCell LinearOrderedCell ListCell NameCell PartialOrderedCell PrefixCell RGBColorCell StringCell SetIntersectionCell SetUnionCell In [1]: import numpy as np In [2]: from beliefs.cells import * In [3]: size = IntervalCell(0, np.inf) Out[3]: [0.00, np.inf] In [4]: size.merge(IntervalCell(30, 50)) Out[4]: [30.00, 50.00] In [5]: size.merge(33) Out[5]: 33.00 In [6]: size.merge(10)[Sussman & Radul 2009] Download at http://eventteam.github.io/beliefs/
Belief ¡contain ¡aNributes ¡defined ¡by ¡data ¡structures ¡called ¡cells: ¡
41 Tuesday, November 5, 13Representing ¡Belief ¡States
BoolCell DictCell IntervalCell LatLonCell LinearOrderedCell ListCell NameCell PartialOrderedCell PrefixCell RGBColorCell StringCell SetIntersectionCell SetUnionCell In [1]: import numpy as np In [2]: from beliefs.cells import * In [3]: size = IntervalCell(0, np.inf) Out[3]: [0.00, np.inf] In [4]: size.merge(IntervalCell(30, 50)) Out[4]: [30.00, 50.00] In [5]: size.merge(33) Out[5]: 33.00 In [6]: size.merge(10)[Sussman & Radul 2009] Download at http://eventteam.github.io/beliefs/
Belief ¡contain ¡aNributes ¡defined ¡by ¡data ¡structures ¡called ¡cells: ¡
41 Tuesday, November 5, 13Representing ¡Belief ¡States
Belief ¡contain ¡aNributes ¡defined ¡by ¡data ¡structures ¡called ¡cells: ¡ The ¡same ¡extension ¡does ¡not ¡imply ¡the ¡same ¡intension.
BoolCell DictCell IntervalCell LatLonCell LinearOrderedCell ListCell NameCell PartialOrderedCell PrefixCell RGBColorCell StringCell SetIntersectionCell SetUnionCell SHAPE: SIZE: [20, 100] COLOR: {blue, green}≠
SHAPE: SIZE: 70 COLOR: In [1]: import numpy as np In [2]: from beliefs.cells import * In [3]: size = IntervalCell(0, np.inf) Out[3]: [0.00, np.inf] In [4]: size.merge(IntervalCell(30, 50)) Out[4]: [30.00, 50.00] In [5]: size.merge(33) Out[5]: 33.00 In [6]: size.merge(10)⊨ ¡{C1, ¡C2}
SHAPE: COLOR: {blue} ⊨ ¡{C1, ¡C2} SHAPE: SIZE: [20, 60]Download at http://eventteam.github.io/beliefs/
42[Sussman & Radul 2009]
Tuesday, November 5, 13A ¡belief ¡state ¡about ¡CIRCLES
43intension extension ¡(denotation)
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡Properties
44intension extension ¡(denotation)
resolve(CIRCLES, b) denote(CIRCLE, b) Tuesday, November 5, 13intension extension ¡(denotation)
Representing ¡Singular
resolve(CIRCLES, b) denote(CIRCLE, b) Tuesday, November 5, 13intension extension ¡(denotation)
Representing ¡Singular
resolve(CIRCLES, b)restricts ¡size ¡of ¡target ¡set
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡Plurals
46intension
resolve(CIRCLES, b)extension ¡(denotation)
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡“any”
47intension
resolve(CIRCLES, b)extension ¡(denotation)
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡“any”
47intension
resolve(CIRCLES, b)extension ¡(denotation)
restricts ¡size ¡of ¡difference ¡ between ¡target ¡set ¡and ¡largest ¡set
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡“the”
48intension
resolve(CIRCLES, b)extension ¡(denotation)
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡“the”
49intension
resolve(CIRCLES, b)extension ¡(denotation)
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡“the”
50intension
resolve(CIRCLES, b)extension ¡(denotation)
denote(CIRCLE, b) Tuesday, November 5, 13Representing ¡“the”
51intension
resolve(CIRCLES, b)extension ¡(denotation)
denote(CIRCLE, b) Tuesday, November 5, 13Determiner ¡meanings
This ¡simple ¡representation ¡captures ¡a ¡wide ¡range ¡of ¡articles ¡(the, ¡ a) ¡and ¡quantifier ¡meanings ¡(without ¡scope).
52 Tuesday, November 5, 13/122 53
Presentation ¡Overview
I. A ¡computational ¡model ¡for ¡Automatically ¡Interpreting ¡& ¡ Generating ¡Referring ¡Expressions ¡(AIGRE)
1. Generation ¡as ¡belief-‑state ¡planning, ¡Interpretation ¡as ¡plan-‑recognition
2. Handles ¡context-‑dependent ¡word ¡meanings ¡for ¡a ¡fragment ¡of ¡English ¡NPs
3. Evaluation ¡on ¡Turk ¡Data
speakers’ ¡decisions
Tuesday, November 5, 13C1 C2 C3
the cost: 0.01 big1 (size) standard: [70, ∞) cost: 1.40/122 54
“the ¡big ¡one”
Tuesday, November 5, 13/122
KINDLES ¡referential ¡domain
55
K1 K2 K3 K4 K5
Tuesday, November 5, 13/122 56
K1 K2 K3 K4 K5
“the ¡big ¡one”
Tuesday, November 5, 13Lexical ¡Ambiguity
(disk)The ¡same ¡lexical ¡item ¡can ¡generate ¡mulBple ¡outcomes ¡due ¡to ¡ two ¡types ¡of ¡lexical ¡ambiguity:
Polysemy
57Homonymy 1 1 2 4 2 3 big light ¡(weight) light ¡(color)
K5 K1 K2 K3 K4 K6
(screen) Tuesday, November 5, 13/122 58
K1 K2 K3 K4 K5“the ¡big ¡one”
Tuesday, November 5, 13/122 59
K1 K2 K3 K4 K5“the ¡big ¡one”
Tuesday, November 5, 13/122 60
K1 K2 K3 K4 K5“the ¡big ¡one”
Tuesday, November 5, 13/122 61
K1 K2 K3 K4 K5“the ¡big ¡one”
Tuesday, November 5, 13/122 62
K1 K2 K3 K4 K5“the ¡big ¡one”
Tuesday, November 5, 13Vagueness
heap? red?
[van ¡Deemter, ¡2010]
Tuesday, November 5, 13K1 K2 K3 K4 K5
Vagueness
ParBBon ¡on ¡all ¡possible ¡standards ¡of ¡comparison ¡for ¡the ¡context ¡
meanings:
std ¡≥ ¡$379 std ¡≥ ¡$199 std ¡≥ ¡$149 std ¡≥ ¡$99
642 3 4 5 6 std ¡≥ ¡$79 1 expensive
Tuesday, November 5, 13/122 65
“the ¡big ¡ones”
Tuesday, November 5, 13“the ¡second”
Ellipsis:
Tuesday, November 5, 13“the ¡second”
Ellipsis:
Tuesday, November 5, 13“the ¡second”
0.0 0.5 1.0 Relative likelihood of denotation [one2] [leftmost] second the “the second” in CIRCLES domain Possible Targets {c1} {c2} {c3} {c1, c2} {c1, c3} {c2, c3} {c1, c2, c3}Ellipsis:
Tuesday, November 5, 13“the ¡second”
0.0 0.5 1.0 Relative likelihood of denotation [one2] [leftmost] second the “the second” in CIRCLES domain Possible Targets {c1} {c2} {c3} {c1, c2} {c1, c3} {c2, c3} {c1, c2, c3}Ellipsis:
Tuesday, November 5, 13/122 68
Presentation ¡Overview
I. A ¡computational ¡model ¡for ¡Automatically ¡Interpreting ¡& ¡ Generating ¡Referring ¡Expressions ¡(AIGRE)
1. Generation ¡as ¡belief-‑state ¡planning, ¡Interpretation ¡as ¡plan-‑recognition
2. Handles ¡context-‑dependent ¡word ¡meanings ¡for ¡a ¡fragment ¡of ¡English ¡NPs
3. Evaluation ¡on ¡Turk ¡Data
speakers’ ¡decisions
Tuesday, November 5, 13/122
Collecting ¡Data
Created ¡web ¡interface ¡for ¡authoring ¡experiments
69
Tuesday, November 5, 13/122 70
Dataset ¡Details
Tuesday, November 5, 13Full ¡AIGRE ¡Generation ¡Output
Tuesday, November 5, 13/122
Evaluating ¡Generation ¡
72
Tuesday, November 5, 13{c1} {c2} {c3} {c1, c2} {c1, c3} {c2, c3} {c1, c2, c3}
0.0 0.2 0.4 0.6 0.8 1.0
Mean Sorensen-Dice coefficientReferring Expression Quality in CIRCLES domain for 15 Best-first Stochastic Hillclimbing Stochastic Hillclimbing with backtracking
/122
Generation ¡Quality
73
Tuesday, November 5, 13Scales ¡well ¡with ¡Lexicon ¡Size
Generation ¡scales ¡linearly ¡with ¡lexicon ¡size
74 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 Number of Actions −50 50 100 150 200 250 300 350 Search time (sec)Lexicon Size versus Search Time A* Best-first Stochastic Hillclimbing
Tuesday, November 5, 13Comparison of Search Methods for REG A* Search Best-first Search Stochastic Hillclimbing with Backtracking Stochastic Hillclimbing with 0.50 Backtracking
Scales ¡well ¡with ¡Task ¡Complexity
(p,d)-‑task: ¡ ¡Given ¡p ¡properties ¡are ¡required ¡to ¡ distinguish ¡the ¡target ¡from ¡d ¡distractors.
75[Koller ¡& ¡Petrick ¡2010]
Tuesday, November 5, 13/122 76
Evaluating ¡Interpretation
How ¡many ¡of ¡the ¡referring ¡expressions ¡could ¡AIGRE ¡ interpret ¡successfully?
Tuesday, November 5, 13/122
Preprocessing ¡Steps
words, ¡but ¡crucially, ¡did ¡not ¡extend ¡the ¡lexical ¡ semantics
modifiers, ¡all ¡complex ¡NP ¡of ¡the ¡list-‑form: ¡“X, ¡Y, ¡and ¡ Z” ¡were ¡interpreted ¡separately ¡as ¡their ¡parts ¡and ¡their ¡ denotation ¡was ¡the ¡union ¡of ¡the ¡three ¡ interpretations.
77
Tuesday, November 5, 13/122
Interpretation ¡Results
Very ¡good ¡coverage ¡on ¡CIRCLES, ¡not ¡as ¡good ¡on ¡
78
Tuesday, November 5, 13/122
Ablation ¡Analysis ¡/ ¡Semantic ¡Tagging
79
Which ¡types ¡of ¡words ¡were ¡most ¡common? ¡ ¡Gradable ¡
/122
Gradable ¡adjectives
80
1 2 3 4 Sense Number 5 10 15 20 25 30 35 40 Number of timese used What sense of a graded adjective did humans use?Like ¡AIGRE, ¡humans ¡tended ¡to ¡use ¡the ¡most ¡restrictive ¡ sense ¡of ¡a ¡graded ¡meaning.
Tuesday, November 5, 13/122
Extending ¡Vagueness
For ¡coarser ¡groupings, ¡a ¡tolerance ¡parameter ¡can ¡be ¡used
std ¡≥ ¡$379 std ¡≥ ¡$199 std ¡≥ ¡$149 std ¡≥ ¡$99 2 3 4 5 6 std ¡≥ ¡$79
τ= ¡0
clustering ¡coefficient ¡/ ¡tolerance ¡parameterstd ¡≥ ¡$379 std ¡≥ ¡$199 1 2 3 expensive
τ= ¡50
1 expensive
Tuesday, November 5, 13/122
Underspecification ¡(65%)
82
97 ¡errors ¡total ¡(26 ¡REs) ¡stemmed ¡from ¡two ¡descriptions:
the ¡kindle ¡touch the ¡kindle
K1 K2 K3 K4 K5
Tuesday, November 5, 13/122 83
the ¡kindle ¡touch the ¡kindle
K1 K2 K3 K4 K5
Underspecification ¡(65%)
97 ¡errors ¡total ¡(26 ¡REs) ¡stemmed ¡from ¡two ¡descriptions:
Tuesday, November 5, 13/122 84
the ¡kindle ¡touch the ¡kindle
K1 K2 K3 K4 K5
Underspecification ¡(65%)
97 ¡errors ¡total ¡(26 ¡REs) ¡stemmed ¡from ¡two ¡descriptions:
Tuesday, November 5, 13/122 85
Presentation ¡Overview
I. A ¡computational ¡model ¡for ¡Automatically ¡Interpreting ¡& ¡ Generating ¡Referring ¡Expressions ¡(AIGRE)
1. Generation ¡as ¡belief-‑state ¡planning, ¡Interpretation ¡as ¡plan-‑recognition
2. Handles ¡context-‑dependent ¡word ¡meanings ¡for ¡a ¡fragment ¡of ¡English ¡NPs
3. Evaluation ¡on ¡Turk ¡Data
speakers’ ¡decisions
Tuesday, November 5, 13/122 86
Which ¡goal ¡is ¡the ¡robot ¡after?
Tuesday, November 5, 13/122 87
Which ¡goal ¡is ¡the ¡robot ¡after?
Tuesday, November 5, 13/122 88
A ¡cost-‑difference ¡approach
¡[Ramírez ¡& ¡Geffner ¡2009,2010]
Tuesday, November 5, 13/122 89
A ¡cost-‑difference ¡approach
¡[Ramírez ¡& ¡Geffner ¡2009,2010]
Tuesday, November 5, 13/122 90
A ¡cost-‑difference ¡approach
¡[Ramírez ¡& ¡Geffner ¡2009,2010]
¡∆(G1) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a3) ¡-‑ ¡plan-‑cost(a5, ¡)
Tuesday, November 5, 13/122 91
A ¡cost-‑difference ¡approach
¡∆(G1) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a3) ¡-‑ ¡plan-‑cost(a5, ¡)
¡[Ramírez ¡& ¡Geffner ¡2009,2010]
Tuesday, November 5, 13/122 92
A ¡cost-‑difference ¡approach
¡∆(G1) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a3) ¡-‑ ¡plan-‑cost(a5,) ¡∆(G2) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a4) ¡-‑ ¡plan-‑cost(a6 ¡)
¡[Ramírez ¡& ¡Geffner ¡2009,2010]
Tuesday, November 5, 13/122 93
A ¡cost-‑difference ¡approach
¡∆(G1) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a3) ¡-‑ ¡plan-‑cost(a5,) ¡∆(G2) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a4) ¡-‑ ¡plan-‑cost(a6 ¡)
Pick ¡ Minimum
¡[Ramírez ¡& ¡Geffner ¡2009,2010]
Tuesday, November 5, 13/122 94
A ¡cost-‑difference ¡approach
¡∆(G1) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a3) ¡-‑ ¡plan-‑cost(a5,) ¡∆(G2) ¡ ¡= ¡plan-‑cost(a1, ¡a2, ¡a4) ¡-‑ ¡plan-‑cost(a6 ¡)
Pick ¡ Minimum
¡[Ramírez ¡& ¡Geffner ¡2009,2010]
Where ¡does ¡this ¡ theory ¡of ¡ alternative ¡actions ¡ come ¡from?
Tuesday, November 5, 13Summary
95achieve ¡fast, ¡incremental, ¡non-‑determinisBc ¡generaBon ¡and ¡ interpreta.on ¡of ¡referring ¡expressions.
Tuesday, November 5, 13Summary
96achieve ¡fast, ¡incremental, ¡non-‑determinisBc ¡generaBon ¡and ¡ interpreta.on ¡of ¡referring ¡expressions.
meanings ¡occur ¡first, ¡an ¡early-‑commit ¡search ¡leads ¡to ¡simple ¡ soluBons ¡for ¡vagueness ¡and ¡ambiguity.
Tuesday, November 5, 13Summary
97achieve ¡fast, ¡incremental, ¡non-‑determinisBc ¡generaBon ¡and ¡ interpreta.on ¡of ¡referring ¡expressions.
meanings ¡occur ¡first, ¡an ¡early-‑commit ¡search ¡leads ¡to ¡simple ¡ soluBons ¡for ¡vagueness ¡and ¡ambiguity.
modeled ¡in ¡tandem: ¡they ¡both ¡offer ¡constraints ¡on ¡the ¡other’s ¡ problem.
Tuesday, November 5, 13/122
Thanks ¡to
1. Advisors: ¡ ¡Henry ¡Lieberman, ¡Marvin ¡Minsky, ¡Augustin ¡Rayo, ¡ ¡Pattie ¡Maes 2. Colleagues: ¡ ¡Karthik ¡Dinakar, ¡Christopher ¡Fry, ¡Bo ¡Morgan, ¡The ¡ Commonsense ¡Group ¡(Catherine, ¡Rob, ¡Jason, ¡Ken) 3. UROPS: ¡ ¡Yin ¡Fu ¡Chan, ¡Nicolas ¡Bravo, ¡Tom ¡Roberts, ¡Erin ¡King, ¡Gleb ¡ Kuznetsov, ¡ 4. Support: ¡MIT ¡Media ¡Lab, ¡and ¡its ¡sponsors. ¡ ¡ 5. Friends ¡& ¡Family! 98
Scaling ¡up ¡the ¡Lexicon
99 fringe = PriorityQueue() closed = set() fringe.push((1.0, initial_state,)) # heuristic search loop while not fringe.empty(): # take node with lowest h h, node = fringe.pop() if node in closed: continue if goal_test_function(node) == True: return node for action in get_relevant_actions(node): for child_node in action(node): child_h = heuristic(child_node) child_h += path_cost(child_node) G.add_edge(node, child_node, action) fringe.push((child_h, child_node,)) closed.add(node)G (search graph): 1 t h e 2 aback 3 a b s u r d 4 22K z
k e d . . .
Tuesday, November 5, 13Scaling ¡up ¡the ¡Lexicon
100 fringe = PriorityQueue() closed = set() fringe.push((1.0, initial_state,)) # heuristic search loop while not fringe.empty(): # take node with lowest h h, node = fringe.pop() if node in closed: continue if goal_test_function(node) == True: return node for action in get_relevant_actions(node): for child_node in action(node): child_h = heuristic(child_node) child_h += path_cost(child_node) G.add_edge(node, child_node, action) fringe.push((child_h, child_node,)) closed.add(node)G (search graph): 1 t h e 2 aback 3 a b s u r d 4 22K z
k e d . . .
Approaches ¡to ¡filtering ¡Ac+ons: ¡ ¡1. ¡Use ¡language ¡model ¡ ¡ ¡ ¡ ¡ ¡s.ll ¡100Ks ¡to ¡consider ¡ ¡2. ¡Use ¡lexical-‑semanBc ¡informaBon ¡ ¡ ¡(1) ¡sort ¡by ¡lexical ¡frequency ¡ ¡ ¡(2) ¡sort ¡by ¡content ¡frequency ¡ ¡ ¡ ¡(3) ¡remove ¡no-‑ops
¡ ¡local ¡search ¡/ ¡hill ¡climbing
Tuesday, November 5, 13AIGRE’s ¡Approach
101G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: [] partial:{} 1
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
102G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: action: big/JJG effects: [] partial:{} 1
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
103G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: action: big/JJG partial:{} [] 1
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
104G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: action: big/JJG [(big/JJG, e1(), 0.8)] partial:{} 1
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
105G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: action: big/JJG partial: 1 {} effects: [(big/JJG, e1(), 0.8)]
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
106G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: action: big/JJG [(big/JJG, e1(), 0.8), (big/JJG, e2(), 1.6)] partial:{} 1
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
107G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: action: big/JJG [(big/JJG, e1(), 0.8), (big/JJG, e2(), 1.6)] partial: 1 {}
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
108G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: action: big/JJG [(big/JJG, e1(), 0.8), (big/JJG, e2(), 1.6), (big/JJG, e3(), 3.2)] 1 partial:{}
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break def big(node): """ The Graded Adjective BIG """ # iterate through each sense (polysemy/ambiguity) for path_to_attribute in node.get_property_paths('size'): # iterate through each value from max (gradability/vagueness) for value in node.get_values(path_to_attribute, sort_by='max'): def effect(node2): node2.merge(path_to_attribute, value) return actual_cost yield effect, estimated_cost Tuesday, November 5, 13AIGRE’s ¡Approach
109G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: action: big/JJG [(big/JJG, e1(), 0.8), (big/JJG, e2(), 1.6), (big/JJG, e3(), 3.2)] 1 partial:{}
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break def effect(node2): node2.merge(path_to_attribute, value) return actual_cost Tuesday, November 5, 13AIGRE’s ¡Approach
110G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: action: big/JJG [(big/JJG, e1(), 0.8), (big/JJG, e2(), 1.6), (big/JJG, e3(), 3.2)] 1 partial:{}
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break def effect(node2): node2.merge([‘hard_drive’,‘size‘], 20) return 1.3 Tuesday, November 5, 13AIGRE’s ¡Approach
111G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: [(big/JJG, e1(), 0.8), (big/JJG, e2(), 1.6), (big/JJG, e3(), 3.2), (cheap/JJG, e1(), 0.2), (cheap/JJG, e2(), 0.8), (dangerous/JJG, e1(), 0.8), (efficient/JJG, e1(), 0.2), (fast/JJG, e1(), 3.0), (good/JJG, e1(), 0.1), (horrible/JJG, e1(), 0.3)] 1 partial:{}
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
112G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: [(big/JJG, e1(), 0.1228), (big/JJG, e2(), 0.0011), (big/JJG, e3(), 0.0000083), (cheap/JJG, e1(), 0.10111), (cheap/JJG, e2(), 0.0082), (dangerous/JJG, e1(), 0.01820), (efficient/JJG, e1(), 0.00013), (fast/JJG, e1(), 0.20823), (good/JJG, e1(), 0.039168), (horrible/JJG, e1(), 0.002323)] 1 partial:{}
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
113G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: [(big/JJG, e1(), 0.1228), (big/JJG, e2(), 0.0011), (big/JJG, e3(), 0.0000083), (cheap/JJG, e1(), 0.10111), (cheap/JJG, e2(), 0.0082), (dangerous/JJG, e1(), 0.01820), (efficient/JJG, e1(), 0.00013), (fast/JJG, e1(), 0.20823), (good/JJG, e1(), 0.039168), (horrible/JJG, e1(), 0.002323)] partial:{} 1
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
113G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects: [(big/JJG, e1(), 0.1228), (big/JJG, e2(), 0.0011), (big/JJG, e3(), 0.0000083), (cheap/JJG, e1(), 0.10111), (cheap/JJG, e2(), 0.0082), (dangerous/JJG, e1(), 0.01820), (efficient/JJG, e1(), 0.00013), (fast/JJG, e1(), 0.20823), (good/JJG, e1(), 0.039168), (horrible/JJG, e1(), 0.002323)] partial:{} 1
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
114G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823) effect: 1 partial:{}
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
115G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823) effect: 1 partial:{} child_node: 3
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
116G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823) effect: 1 partial:{} child_node: act_cost: 3 3
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
117G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 Priority: Node: effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823) effect: 1 partial:{} child_node: act_cost: 3 3 child_h: 0.8
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
118G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823), effect: 1 partial:{} child_node: act_cost: 3 3 child_h: 0.8 Priority: 0.8 Node: 3
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
119G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823), effect: 1 partial:{} child_node: act_cost: 3 3 child_h: 0.8 3 f a s t 3 Priority: 0.8 Node: 3
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
120G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823), effect: 1 partial:{} child_node: act_cost: 3 3 child_h: 0.8 3 f a s t 3 Priority: 0.8 Node: 3
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
121G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823), effect: 1 partial: child_node: act_cost: 3 3 child_h: 0.8 3 f a s t 3 Priority: 0.8 Node: 3 { } 2
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
122G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 1.0 2 effects:[(big/JJG, e1(), 0.1228), ...] (fast/JJG, e1(), 0.20823), effect: 1 partial: child_node: act_cost: 3 3 child_h: 0.8 3 f a s t 3 Priority: 0.8 Node: 3 { } 2
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break Tuesday, November 5, 13AIGRE’s ¡Approach
123G (search graph): 1 t h e 2 fringe: closed: { } 1 h: node: 0.8 3
while not fringe.empty(): ... if goal_test_function(node): yield node effects = [] for action in get_relevant_actions(node): for est_cost, effect in action(node): effects.append((action, effect, est_cost,)) effects = normalize(effects) for _,effect,_ in sample_wo_repeats(effects): child_node = node.copy() act_cost = effect(child_node) child_h = heuristic(child_node) fringe.push((child_h, child_node,)) G.add_edge(node, child, action, act_cost) if child_h < h: partial.add(node) break1 partial: 3 f a s t 3 { } 2 Priority: Node:
Tuesday, November 5, 13Future ¡Work, ¡Learning ¡h()
124 fringe = PriorityQueue() closed = set() fringe.push((1.0, initial_state,)) # heuristic search loop while not fringe.empty(): # take node with lowest h h, node = fringe.pop() if node in closed: continue if goal_test_function(node) == True: return node for action in get_relevant_actions(node): for child_node in action(node): child_h = heuristic(child_node) G.add_edge(node, child_node, action) fringe.push((child_h, child_node,)) closed.add(node)How ¡do ¡we ¡esMmate ¡distances ¡to ¡the ¡goal? With ¡features ¡and ¡examples, ¡heuris+c ¡ func+ons ¡can ¡be ¡learned:
Tuesday, November 5, 13|b0| =
min(|R|−clow,thigh,|R|)
X
k=tlow
✓|R| k ◆
R = {r 2 referent domain : r | = b0.target ^ r 6| = b0.distractor}
/122
Computing ¡Size ¡w/o ¡Enumeration
TARGETSET_ARITY: [tlow, thigh] CONTRAST_ARITY: [clow, chigh] TARGET: DISTRACTOR:125
Tuesday, November 5, 13|b0| =
min(|R|−clow,thigh,|R|)
X
k=tlow
✓|R| k ◆
R = {r 2 referent domain : r | = b0.target ^ r 6| = b0.distractor}
/122
Computing ¡Size ¡w/o ¡Enumeration
TARGETSET_ARITY: [tlow, thigh] CONTRAST_ARITY: [clow, chigh] TARGET: DISTRACTOR:no ¡closed ¡form ¡solution, ¡but ¡ways ¡ to ¡simplify ¡computation 125
Tuesday, November 5, 13Belief-space ≠ State-space
User: ¡“How ¡many ¡files ¡are ¡in ¡/usr/foo ¡?” Computer: ¡ ¡“Let ¡me ¡check....”
cd /usr/foo
[Weld Golden 1996]
l s | w c rm -f /usr/foo
1261 3 2
AIGRE’s ¡actions ¡only ¡affect ¡belief ¡space, ¡and ¡there ¡are ¡no ¡ negative/delete ¡effects. ¡They ¡reduce ¡uncertainty ¡about ¡the ¡ state ¡space; ¡information ¡monotonically ¡increases.
[for state-space REG planning, see Koller’s SCRISP]
Tuesday, November 5, 13/122
Lexical ¡Units ¡are ¡Actions
the = DefiniteArticle('the') # this, these this = DefiniteArticle('this') # a, some a = IndefiniteArticle('a') red = CrispAdjective('red', 'color', 'red') yellow = CrispAdjective('yellow', 'color', 'yellow') green = CrispAdjective('green', 'color', 'green') blue = CrispAdjective('blue', 'color', 'blue')127
Tuesday, November 5, 13/122
Lexical ¡Units ¡are ¡Actions
the = DefiniteArticle('the') # this, these this = DefiniteArticle('this') # a, some a = IndefiniteArticle('a') red = CrispAdjective('red', 'color', 'red') yellow = CrispAdjective('yellow', 'color', 'yellow') green = CrispAdjective('green', 'color', 'green') blue = CrispAdjective('blue', 'color', 'blue')128
Tuesday, November 5, 13/122
Lexical ¡Units ¡are ¡Actions
the = DefiniteArticle('the') # this, these this = DefiniteArticle('this') # a, some a = IndefiniteArticle('a') red = CrispAdjective('red', 'color', 'red') yellow = CrispAdjective('yellow', 'color', 'yellow') green = CrispAdjective('green', 'color', 'green') blue = CrispAdjective('blue', 'color', 'blue')Granularities
128
Tuesday, November 5, 13/122
Lexical ¡Units ¡are ¡Actions
the = DefiniteArticle('the') # this, these this = DefiniteArticle('this') # a, some a = IndefiniteArticle('a') red = CrispAdjective('red', 'color', 'red') yellow = CrispAdjective('yellow', 'color', 'yellow') green = CrispAdjective('green', 'color', 'green') blue = CrispAdjective('blue', 'color', 'blue')Granularities
Gradable ¡ Adjectives
128
Tuesday, November 5, 13/122
Lexical ¡Units ¡are ¡Actions
the = DefiniteArticle('the') # this, these this = DefiniteArticle('this') # a, some a = IndefiniteArticle('a') red = CrispAdjective('red', 'color', 'red') yellow = CrispAdjective('yellow', 'color', 'yellow') green = CrispAdjective('green', 'color', 'green') blue = CrispAdjective('blue', 'color', 'blue')Granularities
Gradable ¡ Adjectives Polysemy
128
Tuesday, November 5, 13