Difference between revisions of "McDonald et al, ACL 2005: Non-Projective Dependency Parsing Using Spanning Tree Algorithms"

From Cohen Courses
Jump to navigationJump to search
Line 22: Line 22:
  
 
The non-projective decoding problem is equivalent to finding the '''maximum spanning tree''' in a directed graph (also called the '''maximum arborescence'''). This can be solved using the [[UsesMethod::Chu-Liu-Edmonds algorithm]] (http://en.wikipedia.org/wiki/Edmonds'_algorithm Wikipedia]).
 
The non-projective decoding problem is equivalent to finding the '''maximum spanning tree''' in a directed graph (also called the '''maximum arborescence'''). This can be solved using the [[UsesMethod::Chu-Liu-Edmonds algorithm]] (http://en.wikipedia.org/wiki/Edmonds'_algorithm Wikipedia]).
 
[[File:Chu-Liu-Edmonds algorithm.png]]
 
  
 
A naive implementation of the Chu-Liu-Edmonds algorithm has a time complexity of <math>O(|V|^3)</math>. In 1977, Robert Tarjan implemented the algorithm with <math>O(|E|log|V|)</math> complexity for sparse graphs and <math>O(|V|^2)</math> complexity for dense graphs, the latter of which is used by this paper. In 1986, Gabow, Galil, Spencer, and Tarjan made an even faster implementation with a complexity of <math>O(|E| + |V|log|V|)</math>.
 
A naive implementation of the Chu-Liu-Edmonds algorithm has a time complexity of <math>O(|V|^3)</math>. In 1977, Robert Tarjan implemented the algorithm with <math>O(|E|log|V|)</math> complexity for sparse graphs and <math>O(|V|^2)</math> complexity for dense graphs, the latter of which is used by this paper. In 1986, Gabow, Galil, Spencer, and Tarjan made an even faster implementation with a complexity of <math>O(|E| + |V|log|V|)</math>.
  
A major advantage of the maximum spanning tree solution over previous solutions is its uniformity and simplicity. Previous algorithms for non-projective dependency parsing were modifications to the [[Eisner algorithm]] (a dynamic programming algorithm of complexity <math>O(|V|^3)</math>), and often involve approximation. In contrast, the maximum spanning tree solution searches the entire space of dependency parse trees, and it reveals the fact that non-projective dependency parsing is actually easier than projective dependency parsing.
+
A major advantage of the maximum spanning tree solution over previous solutions is its uniformity and simplicity. Previous algorithms for non-projective dependency parsing were modifications to the [[UsesMethod::Eisner algorithm]] (a dynamic programming algorithm of complexity <math>O(|V|^3)</math>), and often involve approximation. In contrast, the maximum spanning tree solution searches the entire space of dependency parse trees, and it reveals the fact that non-projective dependency parsing is actually easier than projective dependency parsing.
  
 
=== The Learning Problem ===
 
=== The Learning Problem ===
  
 +
An online large-margin learning algorithm, called [[UsesMethod::MIRA]], is used to train the weight vector <math>\mathbf{w}</math>. The algorithm passes through the training corpus multiple times, and for each training example <math>\mathbf{x}_t, \mathbf{y}_t</math>, it updates the weight vector so that the scores of <math>\mathbf{y}_t</math> and any other parse tree <math>\mathbf{y}'</math> are separated at least by a loss function <math>L(\mathbf{y}_t, \mathbf{y}')</math>. The loss function is defined as the number of vertices that have different parents in the two trees. The weight vectors after each update are averaged to yield the final weight vector.
 +
 +
[[File:MIRA.png]]
  
  
 
== Experiments ==
 
== Experiments ==

Revision as of 17:56, 22 October 2011

Citation

R. McDonald, F. Pereira, K. Ribarov, J. Hajič. Non-projective dependency parsing using spanning tree algorithms, Proceedings of Human Language Technology Conference and Conference on Empirical Methods in Natural Language Processing, pp. 523-530, Vancouver, October 2005.

Online Version

PDF version

Summary

This paper addresses the problem of non-projective dependency prasing.

Given a sentence , we can construct a directed graph . The vertex set contains one vertex for each word in the sentence, plus a dummy vertex for the "root". The edge set contains all directed edges of the form , where , , and . Each edge has a score of the form , where is a feature vector depending on the words and , and is a weight factor.

A dependency parse tree is a subgraph of which covers all the vertices in , and in which each vertex has exactly one predecessor (except for the root vertex which has no predecessor). A projective dependency parse tree has the additional constraint that each of its subtrees covers a contiguous region of the sentence. In either case, the score of a dependency tree is factored as the sum of the scores of its edges:

The (projective) decoding problem is to find the max-scoring (projective) dependency parse tree given a sentence , assuming that the weight vector is known. The learning problem is to find an optimal weight vector , such that the sum of the scores of the dependency parse trees in a training corpus is maximized.

The Decoding Problem

The non-projective decoding problem is equivalent to finding the maximum spanning tree in a directed graph (also called the maximum arborescence). This can be solved using the Chu-Liu-Edmonds algorithm (http://en.wikipedia.org/wiki/Edmonds'_algorithm Wikipedia]).

A naive implementation of the Chu-Liu-Edmonds algorithm has a time complexity of . In 1977, Robert Tarjan implemented the algorithm with complexity for sparse graphs and complexity for dense graphs, the latter of which is used by this paper. In 1986, Gabow, Galil, Spencer, and Tarjan made an even faster implementation with a complexity of .

A major advantage of the maximum spanning tree solution over previous solutions is its uniformity and simplicity. Previous algorithms for non-projective dependency parsing were modifications to the Eisner algorithm (a dynamic programming algorithm of complexity ), and often involve approximation. In contrast, the maximum spanning tree solution searches the entire space of dependency parse trees, and it reveals the fact that non-projective dependency parsing is actually easier than projective dependency parsing.

The Learning Problem

An online large-margin learning algorithm, called MIRA, is used to train the weight vector . The algorithm passes through the training corpus multiple times, and for each training example , it updates the weight vector so that the scores of and any other parse tree are separated at least by a loss function . The loss function is defined as the number of vertices that have different parents in the two trees. The weight vectors after each update are averaged to yield the final weight vector.

MIRA.png


Experiments