advanced dependency parsing
play

Advanced Dependency Parsing Joakim Nivre Uppsala University - PowerPoint PPT Presentation

Advanced Dependency Parsing Joakim Nivre Uppsala University Linguistics and Philology Based on tutorials with Ryan McDonald Advanced Dependency Parsing 1(36) Introduction Plan for the Lecture 1. Graph-based vs. transition-based dependency


  1. Advanced Transition-Based Parsing Techniques Online Learning with a Conventional Oracle Learn( { T 1 , . . . , T N } ) 1 w ← 0 . 0 2 for i in 1 .. K 3 for j in 1 .. N 4 c ← ([ ] , [0 , 1 , . . . , n j ] , { } ) 5 while B c � = [ ] t ∗ ← argmax t w · f ( c , t ) 6 7 t o ← o ( c , T i ) if t ∗ � = t o 8 w ← w + f ( c , t o ) − f ( c , t ∗ ) 9 10 c ← t o ( c ) 11 return w Advanced Dependency Parsing 22(36)

  2. Advanced Transition-Based Parsing Techniques Online Learning with a Conventional Oracle Learn( { T 1 , . . . , T N } ) 1 w ← 0 . 0 2 for i in 1 .. K 3 for j in 1 .. N 4 c ← ([ ] , [0 , 1 , . . . , n j ] , { } ) 5 while B c � = [ ] t ∗ ← argmax t w · f ( c , t ) 6 7 t o ← o ( c , T i ) if t ∗ � = t o 8 w ← w + f ( c , t o ) − f ( c , t ∗ ) 9 10 c ← t o ( c ) 11 return w ◮ Oracle o ( c , T i ) returns the optimal transition for c and T i Advanced Dependency Parsing 22(36)

  3. Advanced Transition-Based Parsing Techniques Conventional Oracle for Arc-Eager Parsing  Left-Arc if top( S c ) ← first( B c ) in T   if top( S c ) → first( B c ) in T Right-Arc  o ( c , T ) = Reduce if ∃ v < top( S c ) : v ↔ first( B c ) in T   Shift otherwise  ◮ Correct: ◮ Derives T in a configuration sequence C o , T = c 0 , . . . , c m ◮ Problems: ◮ Deterministic: Ignores other derivations of T ◮ Incomplete: Valid only for configurations in C o , T Advanced Dependency Parsing 23(36)

  4. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: Stack Buffer Arcs [ ] [ ROOT , He, sent, her, a, letter, .] p root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  5. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH Stack Buffer Arcs [ ROOT ] [He, sent, her, a, letter, .] p root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  6. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH Stack Buffer Arcs [ ROOT , He] [sent, her, a, letter, .] p root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  7. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA Stack Buffer Arcs sbj He ← − sent [ ROOT ] [sent, her, a, letter, .] p root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  8. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent] [her, a, letter, .] ROOT root − → sent p root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  9. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA-RA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, her] [a, letter, .] ROOT root − → sent iobj sent − → her p root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  10. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA-RA-SH Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, her, a] [letter, .] ROOT root − → sent iobj sent − → her p root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  11. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA-RA-SH-LA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, her] [letter, .] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  12. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA-RA-SH-LA-RE Stack Buffer Arcs sbj He ← − sent [ ROOT , sent] [letter, .] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj nsubj iobj det He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  13. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA-RA-SH-LA-RE-RA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, letter] [.] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj dobj nsubj iobj det sent − → letter He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  14. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA-RA-SH-LA-RE-RA-RE Stack Buffer Arcs sbj He ← − sent [ ROOT , sent] [.] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj dobj nsubj iobj det sent − → letter He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  15. Advanced Transition-Based Parsing Techniques Oracle Parse Transitions: SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, .] [ ] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj dobj nsubj iobj det sent − → letter p sent − → . He sent her a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 24(36)

  16. Advanced Transition-Based Parsing Techniques Non-Determinisim SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-RA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, her] [a, letter, .] ROOT root − → sent iobj sent − → her p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 25(36)

  17. Advanced Transition-Based Parsing Techniques Non-Determinisim SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-RA-RE Stack Buffer Arcs sbj He ← − sent [ ROOT , sent] [a, letter, .] ROOT root − → sent iobj sent − → her p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 25(36)

  18. Advanced Transition-Based Parsing Techniques Non-Determinisim SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-RA-RE-SH Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, a] [letter, .] ROOT root − → sent iobj sent − → her p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 25(36)

  19. Advanced Transition-Based Parsing Techniques Non-Determinisim SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-RA-RE-SH-LA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent] [letter, .] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 25(36)

  20. Advanced Transition-Based Parsing Techniques Non-Determinisim SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-RA-RE-SH-LA-RA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, letter] [.] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj dobj − → letter nsubj iobj det sent She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 25(36)

  21. Advanced Transition-Based Parsing Techniques Non-Determinisim SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-RA-RE-SH-LA-RA-RE Stack Buffer Arcs sbj He ← − sent [ ROOT , sent] [.] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj dobj − → letter nsubj iobj det sent She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 25(36)

  22. Advanced Transition-Based Parsing Techniques Non-Determinisim SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-RA-RE-SH-LA-RA-RE-RA Stack Buffer Arcs sbj He ← − sent [ ROOT , sent, .] [ ] ROOT root − → sent iobj sent − → her p det a ← − letter root dobj dobj − → letter nsubj iobj det sent p − → . sent She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 25(36)

  23. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA Stack Buffer Arcs sbj [ ROOT , sent] [her, a, letter, .] He ← − sent ROOT root − → sent p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  24. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH Stack Buffer Arcs sbj [ ROOT , sent, her] [a, letter, .] He ← − sent ROOT root − → sent p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  25. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH Stack Buffer Arcs sbj [ ROOT , sent, her, a] [letter, .] He ← − sent ROOT root − → sent p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  26. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA Stack Buffer Arcs sbj [ ROOT , sent, her] [letter, .] He ← − sent ROOT root − → sent det a ← − letter p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  27. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA-SH Stack Buffer Arcs sbj [ ROOT , sent, her, letter] [.] He ← − sent ROOT root − → sent det a ← − letter p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  28. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA-SH-SH [3/6] Stack Buffer Arcs sbj [ ROOT , sent, letter, .] [ ] He ← − sent ROOT root − → sent det a ← − letter p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  29. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA-SH-SH [3/6] SH-RA-LA-SH-SH-SH-LA Stack Buffer Arcs sbj [ ROOT , sent, her] [letter, .] He ← − sent ROOT root − → sent det a ← − letter p root dobj nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  30. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA-SH-SH [3/6] SH-RA-LA-SH-SH-SH-LA-LA Stack Buffer Arcs sbj [ ROOT , sent] [letter, .] He ← − sent ROOT root − → sent det a ← − letter p ? root dobj her ← − letter nsubj iobj det She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  31. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA-SH-SH [3/6] SH-RA-LA-SH-SH-SH-LA-LA-RA Stack Buffer Arcs sbj [ ROOT , sent, letter] [.] He ← − sent ROOT root − → sent det a ← − letter p ? root dobj her ← − letter dobj nsubj iobj det sent − → letter She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  32. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA-SH-SH [3/6] SH-RA-LA-SH-SH-SH-LA-LA-RA-RE Stack Buffer Arcs sbj [ ROOT , sent] [.] He ← − sent ROOT root − → sent det a ← − letter p ? root dobj her ← − letter dobj nsubj iobj det sent − → letter She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  33. Advanced Transition-Based Parsing Techniques Non-Optimality SH-SH-LA-RA-RA-SH-LA-RE-RA-RE-RA Transitions: SH-SH-LA-RA-SH-SH-LA-SH-SH [3/6] SH-RA-LA-SH-SH-SH-LA-LA-RA-RE-RA [5/6] Stack Buffer Arcs sbj [ ROOT , sent, .] [ ] He ← − sent ROOT root − → sent det a ← − letter p ? root dobj her ← − letter dobj nsubj iobj det sent − → letter p sent − → . She sent him a letter . ROOT pron verb pron det noun . ROOT Advanced Dependency Parsing 26(36)

  34. Advanced Transition-Based Parsing Techniques Dynamic Oracles ◮ Optimality: ◮ A transition is optimal if the best tree remains reachable ◮ Best tree = argmin T ′ L ( T , T ′ ) ◮ Oracle: ◮ Boolean function o ( c , t , T ) = true if t is optimal for c and T ◮ Non-deterministic: More than one transition can be optimal ◮ Complete: Correct for all configurations ◮ New problem: ◮ How do we know which trees are reachable? ◮ Easy for some transition systems (called arc-decomposable) Advanced Dependency Parsing 27(36)

  35. Advanced Transition-Based Parsing Techniques Oracles for Arc-Decomposable Systems � true if [ R ( c ) − R ( t ( c ))] ∩ T = ∅ o ( c , t , T ) = false otherwise where R ( c ) ≡ { a | a is an arc reachable in c } Arc-Eager � false if ∃ w ∈ B c : s ↔ w ∈ T (except s ← b ) o ( c , LA , T ) = true otherwise � false if ∃ w ∈ S c : w ↔ b ∈ T (except s → b ) o ( c , RA , T ) = true otherwise � false if ∃ w ∈ B c : s → w ∈ T o ( c , RE , T ) = true otherwise � false if ∃ w ∈ S c : w ↔ b ∈ T o ( c , SH , T ) = true otherwise Notation: s = node on top of the stack S b = first node in the buffer B Advanced Dependency Parsing 28(36)

  36. Advanced Transition-Based Parsing Techniques Online Learning with a Dynamic Oracle Learn( { T 1 , . . . , T N } ) 1 w ← 0 . 0 2 for i in 1 .. K 3 for j in 1 .. N 4 c ← ([ ] S , [ w 1 , . . . , w n j ] B , { } ) 5 while B c � = [ ] t ∗ ← argmax t w · f ( c , t ) 6 7 t o ← argmax t ∈{ t | o ( c , t , T i ) } w · f ( c , t ) if t ∗ � = t o 8 w ← w + f ( c , t o ) − f ( c , t ∗ ) 9 c ← choice( t o ( c ) , t ∗ ( c )) 10 11 return w Advanced Dependency Parsing 29(36)

  37. Advanced Transition-Based Parsing Techniques Online Learning with a Dynamic Oracle Learn( { T 1 , . . . , T N } ) 1 w ← 0 . 0 2 for i in 1 .. K 3 for j in 1 .. N 4 c ← ([ ] S , [ w 1 , . . . , w n j ] B , { } ) 5 while B c � = [ ] t ∗ ← argmax t w · f ( c , t ) 6 7 t o ← argmax t ∈{ t | o ( c , t , T i ) } w · f ( c , t ) if t ∗ � = t o 8 w ← w + f ( c , t o ) − f ( c , t ∗ ) 9 c ← choice( t o ( c ) , t ∗ ( c )) 10 11 return w ◮ Ambiguity: use model score to break ties ◮ Exploration: follow model prediction even if not optimal Advanced Dependency Parsing 29(36)

  38. Advanced Transition-Based Parsing Techniques [Goldberg and Nivre 2012] Advanced Dependency Parsing 30(36)

  39. Advanced Transition-Based Parsing Techniques Non-Projective Parsing ◮ Standard transition systems only derive projective trees ◮ Approaches to non-projective transition-based parsing: ◮ Pseudo-projective parsing [Nivre and Nilsson 2005] ◮ Non-adjacent arc transitions [Covington 2001, Attardi 2006, Nivre 2007] ◮ Online reordering [Nivre 2009, Nivre et al. 2009] Advanced Dependency Parsing 31(36)

  40. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  41. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  42. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  43. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  44. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  45. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  46. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  47. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  48. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  49. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  50. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  51. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  52. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  53. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  54. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  55. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  56. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  57. Advanced Transition-Based Parsing Techniques Projectivity and Word Order ◮ Projectivity is a property of a dependency tree only in relation to a particular word order ◮ Words can always be reordered to make the tree projective ◮ Given a dependency tree T = ( V , A , < ), let the projective order < p be the order defined by an inorder traversal of T with respect to < [Vesel´ a et al. 2004] p root tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT 0 1 2 6 7 3 4 5 8 9 Advanced Dependency Parsing 32(36)

  58. Advanced Transition-Based Parsing Techniques Transition System for Online Reordering Configuration: ( S , B , A ) [ S = Stack, B = Buffer, A = Arcs] Initial: ([ ] , [ w 0 , w 1 , . . . , w n ] , { } ) ( w 0 = ROOT) Terminal: ([0] , [ ] , A ) Shift: ( S , w i | B , A ) ⇒ ( S | w i , B , A ) Right-Arc( l ): ( S | w i | w j , B , A ) ⇒ ( S | w i , B , A ∪ { ( w i , l , w j ) } ) Left-Arc( l ): ( S | w i | w j , B , A ) ⇒ ( S | w j , B , A ∪ { ( w j , l , w i ) } ) i � = 0 Swap: ( S | w i | w j , B , A ) ⇒ ( S | w j , w i | B , A ) 0 < i < j Advanced Dependency Parsing 33(36)

  59. Advanced Transition-Based Parsing Techniques Transition System for Online Reordering Configuration: ( S , B , A ) [ S = Stack, B = Buffer, A = Arcs] Initial: ([ ] , [ w 0 , w 1 , . . . , w n ] , { } ) ( w 0 = ROOT) Terminal: ([0] , [ ] , A ) Shift: ( S , w i | B , A ) ⇒ ( S | w i , B , A ) Right-Arc( l ): ( S | w i | w j , B , A ) ⇒ ( S | w i , B , A ∪ { ( w i , l , w j ) } ) Left-Arc( l ): ( S | w i | w j , B , A ) ⇒ ( S | w j , B , A ∪ { ( w j , l , w i ) } ) i � = 0 Swap: ( S | w i | w j , B , A ) ⇒ ( S | w j , w i | B , A ) 0 < i < j ◮ Transition-based parsing with two interleaved processes: 1. Sort words into projective order < p 2. Build tree T by connecting adjacent subtrees ◮ T is projective with respect to < p but not (necessarily) < Advanced Dependency Parsing 33(36)

  60. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ] S [ ROOT , A, hearing, is, scheduled, on, the, issue, today, .] B A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  61. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT ] S [A, hearing, is, scheduled, on, the, issue, today, .] B A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  62. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , A] S [hearing, is, scheduled, on, the, issue, today, .] B A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  63. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , A, hearing] S [is, scheduled, on, the, issue, today, .] B A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  64. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing] S [is, scheduled, on, the, issue, today, .] B det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  65. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, is] S [scheduled, on, the, issue, today, .] B det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  66. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, is, scheduled] S [on, the, issue, today, .] B det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  67. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, scheduled] S [on, the, issue, today, .] B det aux A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  68. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, scheduled, on] S [the, issue, today, .] B det aux A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  69. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, scheduled, on, the] S [issue, today, .] B det aux A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  70. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, scheduled, on, the, issue] S [today, .] B det aux A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  71. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, scheduled, on, issue] S [today, .] B det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  72. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, scheduled, on] S [today, .] B pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  73. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, on] S [scheduled, today, .] B pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  74. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing] S [scheduled, today, .] B prep pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  75. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , hearing, scheduled] S [today, .] B prep pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  76. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , scheduled] S [today, .] B prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  77. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , scheduled, today] S [.] B prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

  78. Advanced Transition-Based Parsing Techniques Example Transition Sequence [ ROOT , scheduled] S [.] B tmod prep nsubj pobj det aux det A hearing is scheduled on the issue today . ROOT det noun verb verb prep det noun adv . ROOT Advanced Dependency Parsing 34(36)

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend