semantic parsing based on propositional representations fernandez, sopena, padró

69
Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Upload: quentin-heap

Post on 31-Mar-2015

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Semantic Parsing based on Propositional Representations

Fernandez, Sopena, Padró

Page 2: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

• Resumen– Objetivos– Estructura Proposicional– Arquitectura

• M1• M2

– Ejemplos• Canónico• PP-Attachment

Generalized Role Labeling using Propositional Representations

Page 3: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

• Objetivos

• Crear un analizador semántico mediante la implementación de un modelo psicológico plausible que:

– Lleva a cabo un mapeo directo i sencillo de las frases a su estructura proposicional

– No utiliza analizadores sintácticos ni estructura sintactica intermedia

• Obtener buenos resultados en textos reales (PTB)

Page 4: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

• Estructura proposicional– Predicado + 3 ArgumentosFrase canónica: “The man sold some offerings to the british tourist”

Pred:sold

Arg1:the man

Arg2:some offerings

Arg3:the british tourist

– Composición de proposiciones“The man sold some offerings to the british tourist in Barcelona”

(P1)Pred:soldArg1:the manArg2:some offeringsArg3:the british tourist

(P2)Pred:Arg1:P1Arg2:in BarcelonaArg3:

Page 5: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Page 6: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

• Estructura proposicional

– Argumentos temáticos generalizados (VanValin)

• A1-ACTOR (agent, perceiver, ....)

• A2-UNDERGOER (theme, patient, ... )

• A3-OTHERS (benefactive, goal, location, source, destination, ...)

– Mapping fácil con FrameNet i otros

• Arg1 i arg2 son los dos primeros argumentos core

• Arg3, argumentos core que se identifican por la preposición que los marca.

Page 7: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

• Arquitectura• Modulo1 - Estructural/Sintáctico

– Lleva a cabo el mapeo directo de las palabras a la proposición

– Modifica la proposición

– Sin información semántica explicita

• Modulo2 - Semántico– Acepta o rechaza las decisiones estructurales del primer

modulo.

» Consistencia con el verbo (+/-Subcategorization Frames)

» PP-Attachment

» Coordinacion

» Relativo

Generalized Role Labeling using Propositional Representations

Page 8: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Ventajas

• Complejidad lineal

• Fácil tratamiento de fenómenos sintácticos ‘difíciles’:– Coordinación y puntuación.– Word order– Non local dependencies.

• No se necesita corpus sintáctico etiquetado.

Page 9: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

• Arquitectura– Modulo1

Input Word

Slot 0 Slot 1 Slot 2 Slot 3 Type S Back, Test & Subcat.

STACK

Stored Context

Current Context

MODULE 1MODULE 1

Parser Commands

Page 10: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Input Word

Slot 0 Slot 1 Slot 2 Slot 3 Type S Back, Test & Subcat.

Current Context

MODULE 2MODULE 2

Verbo|ARG Adjunto|~Adjunto Coordinable|~CoordinableArg1|Arg2

Page 11: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2PUT1

Page 12: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

The | DT

PUT1

Page 13: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

The | DT

DT(The)

Page 14: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

man | DT_N

DT(The)

PUT1

Page 15: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

DT(The) DT_N(man)

man | DT_N

Page 16: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

sold | V_MA

PUT0

DT(The) DT_N(man)

Page 17: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

DT(The) DT_N(man)

sold | V_MA

V_MA(sold)

Page 18: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

some | DT

PUT2

DT(The) DT_N(man)V_MA(sold)

Page 19: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

V_MA(sold)

some | DT

DT(The) DT_N(man) DT(some)

Page 20: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Flags

Modul1 Modul2

The man sold some offerings to the president

offerings | DT_N

PUT2

Slot 3V_MA(sold) DT(The) DT_N(man) DT(some)

Page 21: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Flags

Modul1 Modul2

The man sold some offerings to the president

offerings | DT_N

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Slot 3V_MA(sold) DT(The) DT_N(man) DT(some) DT_N(offerings)

Page 22: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Flags

Modul1 Modul2

The man sold some offerings to the president

to | IIN_DT

PUT3

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Slot 3V_MA(sold) DT(The) DT_N(man) DT(some) DT_N(offerings)

Page 23: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Flags

Modul1 Modul2

The man sold some offerings to the president

to | IIN_DT

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3V_MA(sold) DT(The) DT_N(man) DT(some) DT_N(offerings) to(IIN_DT)

Page 24: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Flags

Modul1 Modul2

The man sold some offerings to the president

the | DT

PUT1

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3V_MA(sold) DT(The) DT_N(man) DT(some) DT_N(offerings) to(IIN_DT)

Page 25: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Flags

Modul1 Modul2

The man sold some offerings to the president

the | DT

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Slot 3V_MA(sold) DT(The) DT_N(man) DT(some) DT_N(offerings) to(IIN_DT) the(DT)

Page 26: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Flags

Modul1 Modul2

The man sold some offerings to the president

president | DT_N

PUT1

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Slot 3V_MA(sold) DT(The) DT_N(man) DT(some) DT_N(offerings) to(IIN_DT) the(DT)

Page 27: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Flags

Modul1 Modul2

The man sold some offerings to the president

president | DT_N

Slot 3

Slot 0 Slot 1 Slot 2 Slot 3

Slot 3V_MA(sold) DT(The) DT_N(man) DT(some) DT_N(offerings) to(IIN_DT) the(DT)

president(DT_N)

Page 28: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Un ejemplo no tan sencillo:

“The main manager bought some old cars with three wheels.”

Page 29: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Current

Pred:

A1:

A2:

A3:

Flags:

Input Word: The| DTM1: PUT1M2:

The main manager bought some old cars with three wheels.

Page 30: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Current

Pred:

A1: The

A2:

A3:

Flags: @1

Input Word: The| DTM1: NEXTM2:

The main manager bought some old cars with three wheels.

Page 31: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Current

Pred:

A1: The

A2:

A3:

Flags: @NEXT @1

Input Word: main | JJ_PRM1: *IZ-INM2:

The main manager bought some old cars with three wheels.

Page 32: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Current

Pred:

A1:

A2:

A3:

Flags:

Input Word: main| JJ_PRM1: PUT0M2:

The main manager bought some old cars with three wheels.

Top

Pred:

A1: The

A2:

A3:

Flags: @1

Page 33: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Current

Pred: main

A1:

A2:

A3:

Flags:

Input Word: main| JJ_PRM1: NEXTM2:

The main manager bought some old cars with three wheels.

Top

Pred:

A1: The

A2:

A3:

Flags: @1

Page 34: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: manager| DT_NM1: PUT1M2:

The main manager bought some old cars with three wheels.

Current

Pred: main

A1:

A2:

A3:

Flags: @NEXT

Top

Pred:

A1: The

A2:

A3:

Flags: @1

Page 35: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: manager| DT_NM1: OZ-OUTM2:

The main manager bought some old cars with three wheels.

Current

Pred: main

A1: manager

A2:

A3:

Flags: @NEXT

Top

Pred:

A1: The

A2:

A3:

Flags: @1

Page 36: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: manager| DT_NM1: PUT1M2:

The main manager bought some old cars with three wheels.

Current

Pred:

A1: The

A2:

A3:

Flags: @1 @OZ-OUT

P:main|A1:manager

Page 37: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: manager| DT_NM1: NEXTM2:

The main manager bought some old cars with three wheels.

Current

Pred:

A1: The manager

A2:

A3:

Flags: @1 @OZ-OUT

P:main|A1:manager

Page 38: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: bought| V_MAM1: PUT0M2:

The main manager bought some old cars with three wheels.

Current

Pred:

A1: The manager

A2:

A3:

Flags: @1 @NEXT

P:main|A1:manager

Page 39: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: bought| V_MAM1: NEXTM2:

The main manager bought some old cars with three wheels.

Current

Pred: bought

A1: The manager

A2:

A3:

Flags: @0

P:main|A1:manager

Page 40: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: some| DTM1: PUT2M2:

The main manager bought some old cars with three wheels.

Current

Pred: bought

A1: The manager

A2:

A3:

Flags: @0 @NEXT

P:main|A1:manager

Page 41: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: some| DTM1: NEXTM2:

The main manager bought some old cars with three wheels.

Current

Pred: bought

A1: The manager

A2: some

A3:

Flags: @2

P:main|A1:manager

Page 42: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: old| JJ_PRM1: *IZ-INM2:

The main manager bought some old cars with three wheels.

Current

Pred: bought

A1: The manager

A2: some

A3:

Flags: @2 @NEXT

P:main|A1:manager

Page 43: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: old| JJ_PRM1: PUT0M2:

The main manager bought some old cars with three wheels.

Current

Pred:

A1:

A2:

A3:

Flags: @IZ-IN

P:main|A1:manager

Top

Pred: bought

A1: The manager

A2: some

A3:

Flags: @2

Page 44: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: old| JJ_PRM1: NEXTM2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred: old

A1:

A2:

A3:

Flags: @IZ-IN @0

Top

Pred: bought

A1: The manager

A2: some

A3:

Flags: @2

Page 45: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: cars | DT_NM1: PUT1M2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred: old

A1:

A2:

A3:

Flags: @IZ-IN

@NEXT @0

Top

Pred: bought

A1: The manager

A2: some

A3:

Flags: @2

Page 46: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: cars | DT_NM1: OZ-OUTM2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred: old

A1: cars

A2:

A3:

Flags: @IZ-IN

@NEXT @1

Top

Pred: bought

A1: The manager

A2: some

A3:

Flags: @2

Page 47: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: cars | DT_NM1: PUT2M2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred: bought

A1: The manager

A2: some

A3:

Flags: @2

P:old|A1:cars

Page 48: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: cars | DT_NM1: NEXTM2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

P:old|A1:cars

Page 49: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: with | IIN_DTM1: IZ-IN1M2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2 @NEXT

P:old|A1:cars

Page 50: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: with | IIN_DTM1: PUT2M2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred:

A1: cars

A2:

A3:

Flags: @1

P:old|A1:cars

Top

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

Page 51: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: with | IIN_DTM1: NEXTM2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred:

A1: some cars

A2: with

A3:

Flags: @2

P:old|A1:cars

Top

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

Page 52: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: three | DTM1: PUT2M2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred:

A1: some cars

A2: with

A3:

Flags: @2 @NEXT

P:old|A1:cars

Top

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

Page 53: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: three | DTM1: NEXTM2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred:

A1: some cars

A2: with three

A3:

Flags: @2

P:old|A1:cars

Top

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

Page 54: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: wheels| DT_NM1: PUT2M2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred:

A1: some cars

A2: with three

A3:

Flags: @2 @NEXT

P:old|A1:cars

Top

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

Page 55: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: wheels| DT_NM1: NEXTM2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred:

A1: some cars

A2:with three wheels

A3:

Flags: @2

P:old|A1:cars

Top

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

Page 56: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Generalized Role Labeling using Propositional Representations

Input Word: .| DOTM1: OZ-OUTM2:

The main manager bought some old cars with three wheels.

P:main|A1:manager

Current

Pred:

A1: some cars

A2:with three wheels

A3:

Flags: @2 @NEXT

P:old|A1:cars

Top

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

Page 57: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Input Word: .| DOTM1: OZ-OUTM2:

P:main|A1:manager

Current

Pred: bought

A1: The manager

A2: some cars

A3:

Flags: @2

P:old|A1:cars

Generalized Role Labeling using Propositional Representations

The main manager bought some old cars with three wheels.

A1:cars|A2:with three wheels

Page 58: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Input Word: .| DOTM1: FINM2:

P:main|A1:manager

P:old|A1:cars

Generalized Role Labeling using Propositional Representations

The main manager bought some old cars with three wheels.

A1:cars|A2:with three wheels

P:bought|A1the managerA2:some cars

Page 59: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Training set

• SS-3-2- (DT_N I PUT1 NEXT)• SS-3-2- (V_MA took PUT0 NEXT)• SS-3-3- (DT_N her PUT2 NEXT)• SS-3-4- (IIN_DT to PUT3 NEXT)• SS-3-5- (DT_N school PUT3 NEXT)• SS-3-6- (. . OZ-OUT NEXT)• SS-3-7- (FIN)

Page 60: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company in 1999, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred: non-callable

A1: issue

A2:

A3:

Flags:

Page 61: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred:can be put_back

A1:

A2: the issue

A3: to the company

Page 62: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred:is priced

A1:

A2: the issue

A3: at 99 basis_points

Page 63: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred:

A1: 99 basis_points

A2: above the

A3:

Page 64: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred:

A1:

A2: treasury

A3:

Page 65: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred:

A1: note

A2: 10-year

A3:

Page 66: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred:

A1: note

A2: Treasury

A3:

Page 67: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

‘Elementary expressions’

• The non-callable issue, which can be put_back to the company, is priced at 99 basis_points above the Treasury 10-year note.

Current

Pred:is priced

A1:

A2: the issue

A3: at 99 basis_points

Page 68: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

Training set• SS-17-1- (DT_N IMB PUT1 NEXT)• SS-17-2- (V_MA bought PUT0 NEXT)• SS-17-3- (DT the PUT2 NEXT)• SS-17-4- (DT_N team PUT2 NEXT)• SS-17-5- (IIN_DT from PUT3 NEXT)• SS-17-6- (DT_N BUMBRIGHT PUT3 NEXT)• SS-17-7- (IIN_DT for CONSTRUAL PUT2 NEXT)

• SS-17-8- (DT 145.000 PUT2 &BACK OZ-OUT PUT3 NEXT)

• SS-17-9- (DT_N $ PUT3 NEXT)• SS-17-10- (. . OZ-OUT NEXT)• SS-17-11- (FIN)

Page 69: Semantic Parsing based on Propositional Representations Fernandez, Sopena, Padró

FIN