Dynamic Oracles for Top-Down and In-Order Shift-Reduce Constituent Parsing

Daniel Fernández-González, Carlos Gómez-RodríguezEMNLP 2018

Abstract

This paper introduces the first optimal dynamic oracles for top-down and in-order shift-reduce constituent parsers. Traditional shift-reduce parsers, while efficient, often suffer from error propagation due to static oracle training. By implementing a dynamic oracle that allows for error exploration during training, the authors enable parsers to learn recovery strategies from non-optimal states. The resulting in-order parser achieves a state-of-the-art F1 score of 92.05 on the Wall Street Journal (WSJ) benchmark for greedy constituent parsing.

Introduction: The Challenge of Error Propagation

Constituent parsing is the task of decomposing a sentence into its hierarchical syntactic components, such as Noun Phrases (NP) and Verb Phrases (VP). Shift-reduce parsers are favored for this task due to their linear-time complexity, making them significantly faster than chart-based alternatives.

Example of a constituent parse tree for the sentence "The public is still cautious."

However, these parsers typically rely on "static oracles" during training, which provide only the single correct sequence of actions. This creates a discrepancy between training and inference: if a parser makes a minor error at test time, it enters a state never encountered during training, often leading to a cascade of further mistakes. While dynamic oracles—which teach the model the best action from any reachable state—have been successful in dependency parsing, they were previously unavailable for top-down and in-order constituent transition systems.

Methodology: Dynamic Oracles and Error Exploration

The authors developed a mathematical framework to define dynamic oracles for two primary transition systems:

  1. Top-Down: The parser predicts a non-terminal label before its children.
  2. In-Order: The parser predicts the first child, then the parent label, followed by the remaining children.

To calculate the cost of non-optimal actions, the researchers utilized a loss function based on Hamming loss, representing the number of gold constituents that become unreachable from a given state. They addressed two key technical challenges: defining formal reachability conditions for constituents and using a Longest Increasing Subsequence (LIS) algorithm to penalize incorrect non-terminal ordering on the stack.

By introducing a small probability of taking non-optimal moves during training (error exploration), the model learns to minimize the impact of its own mistakes, effectively bridging the gap between training and real-world inference.

Experimental Results

The approach was evaluated on the English Wall Street Journal (WSJ) and the Chinese Treebank (CTB) 5.1. The results demonstrate that dynamic training consistently outperforms static training across both transition systems and languages.

F1 scores on WSJ and CTB datasets across different exploration rates, showing that dynamic oracles (exploration > 0) consistently improve performance.

As shown in the table above, the in-order parser with an exploration rate of 0.1 achieved an F1 score of 92.05 on the WSJ benchmark, setting a new record for single-model, fully supervised, greedy shift-reduce parsers. The in-order system consistently outperformed the top-down approach, suggesting it provides a superior balance of local and global context.

Insights and Conclusion

The primary takeaway is that parsers benefit significantly from "learning from failure." By allowing the model to navigate incorrect states during training, it becomes resilient to the error propagation that typically plagues transition-based systems.

While these greedy parsers are slightly less accurate than the most computationally intensive chart-based models, their speed and the performance gains provided by dynamic oracles make them highly practical for large-scale NLP applications. Future work may involve more sophisticated exploration strategies, such as scheduled sampling or reinforcement learning, to further refine these models.

Summary updated

BibTeX
@inproceedings{fernandezgonzalez2018dynamic,
  author = {Daniel Fernández-González and Carlos Gómez-Rodríguez},
  title = {{Dynamic Oracles for Top-Down and In-Order Shift-Reduce Constituent Parsing}},
  booktitle = {Conference on Empirical Methods in Natural Language Processing},
  year = {2018},
  doi = {10.18653/v1/d18-1161},
}
Figure