Generation as Dependency Parsing

Alexander Koller, Kristina Striegnitz

Abstract

Natural Language Generation (NLG) from flat semantics is a computationally intensive task, proven to be NP-complete. This paper introduces a method to solve surface realization efficiently by reframing it as a dependency parsing problem. By encoding Tree-Adjoining Grammar (TAG) generation into Topological Dependency Grammar (TDG), the authors utilize advanced constraint-programming techniques to achieve near-polynomial runtimes in practice. This approach significantly outperforms traditional chart-based generators, offering a scalable solution for complex linguistic structures.

The Challenge of Surface Realization

Surface realization is the process of transforming a "bag" of semantic meanings—flat semantics—into a grammatically correct sentence. The fundamental difficulty lies in the combinatorial explosion of possible word orders and syntactic connections. Because flat semantics do not specify word order or structural hierarchy, a generator must explore a massive search space. Historically, while parsing (meaning extraction) has been efficient, generation has remained slow and prone to timeouts on complex inputs. This paper demonstrates that this problem is NP-complete even for fixed grammars.

Methodology: From TAG to Dependency Parsing

The authors propose a reduction of the TAG generation problem into a Dependency Parsing (DP) problem using Topological Dependency Grammar (TDG). Unlike traditional grammars focused on linear word order, TDG treats parsing as a search for a tree structure that satisfies specific label and valency constraints.

The Encoding Process

The transformation involves several key steps:

  1. Semantic Mapping: Each semantic "atom" in the input is treated as a node in a dependency tree.
  2. Lexical Selection: Lexical entries for these nodes are derived from TAG elementary trees.
  3. Edge Representation: Edges in the dependency tree represent standard TAG operations: substitution (inserting a tree into a designated slot) or adjunction (inserting a tree into the middle of another).
Figure 3: Mapping of semantic atoms to TAG elementary trees (α1 through α5). Each atom like 'edge(i,k)' or 'start-eating' corresponds to a specific syntactic fragment.

Constraint Propagation

The system is implemented using the Mozart programming system, which utilizes "propagators." These efficient algorithms analyze the global state of the tree to prune impossible connections early. For instance, if a verb requires a specific subject and only one noun in the input satisfies that role, the propagator immediately "locks in" the connection. This global pruning prevents the search from exploring "dead-end" fragments common in traditional chart-based generators.

Evaluation and Results

The approach was evaluated using the XTAG grammar, a wide-coverage grammar for English. Testing focused on two benchmark sentences known for their length and structural ambiguity (Carroll et al., 1999).

The dependency-based approach demonstrated dramatic speed improvements:

  • Sentence 1: Generated in 470 milliseconds, a ~3.8x speedup over the 1.8-second baseline.
  • Sentence 2: Generated in 170 milliseconds, a ~25x speedup over the 4.3-second baseline.

The system also handled massive lexical ambiguity gracefully. In cases where a single word could correspond to over 100 different TAG trees, selection constraints compressed these possibilities into manageable classes, preventing search space explosion.

Key Insights

The central realization of this work is that generating from unordered semantics is functionally identical to parsing "free word order" languages. By "recycling" high-performance tools from the dependency parsing community, the authors provide a more robust framework for NLG. While the problem remains NP-complete in the worst case, the constraints inherent in natural language are typically strong enough to allow for polynomial-time solutions in practice.

Future Directions

While promising, the current model has limitations. It does not yet handle complex feature structures (like gender/number agreement) directly within the constraints. Additionally, the encoding uses a simplified version of TAG adjunction and assumes a one-to-one mapping between semantic atoms and lexical entries. Future work will focus on scaling this approach to full corpora and integrating more complex linguistic constraints.

Summary updated

BibTeX
@inproceedings{koller2002generation,
  author = {Alexander Koller and Kristina Striegnitz},
  title = {{Generation as Dependency Parsing}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2002},
  doi = {10.3115/1073083.1073088},
}
Figure