Skip to main content
QUICK REVIEW

[Paper Review] Macro Grammars and Holistic Triggering for Efficient Semantic Parsing

Yuchen Zhang, Panupong Pasupat|arXiv (Cornell University)|Jul 25, 2017
Natural Language Processing TechniquesComputer Science29 references5 citations
TL;DR

This paper proposes macro grammars and holistic triggering to accelerate semantic parsing by caching reusable logical form patterns and efficiently retrieving relevant ones using utterance similarity. On the WikitableQuestions dataset, the method achieves a new state-of-the-art accuracy of 43.7% with an 11x speedup over baseline training and a 16x speedup at test time.

ABSTRACT

To learn a semantic parser from denotations, a learning algorithm must search over a combinatorially large space of logical forms for ones consistent with the annotated denotations. We propose a new online learning algorithm that searches faster as training progresses. The two key ideas are using macro grammars to cache the abstract patterns of useful logical forms found thus far, and holistic triggering to efficiently retrieve the most relevant patterns based on sentence similarity. On the WikiTableQuestions dataset, we first expand the search space of an existing model to improve the state-of-the-art accuracy from 38.7% to 42.7%, and then use macro grammars and holistic triggering to achieve an 11x speedup and an accuracy of 43.7%.

Motivation & Objective

  • To reduce the computational cost of searching large logical form spaces in semantic parsing.
  • To improve search efficiency without sacrificing coverage of valid logical forms.
  • To enable faster training and inference by caching and reusing structurally meaningful patterns from previously parsed examples.
  • To handle lexical variation and paraphrases more robustly than phrase-anchored rule systems.
  • To maintain high accuracy while significantly reducing search space through dynamic rule selection.

Proposed method

  • Introduces macro grammars that abstract consistent logical forms into reusable templates by replacing specific relations and entities with placeholders.
  • Uses holistic triggering to select only the K most similar training examples' macro rules for parsing a new utterance, based on utterance-level similarity.
  • Employs an online learning algorithm that alternates between using the macro grammar for fast parsing and falling back to the base grammar when no consistent forms are found.
  • Dynamically enriches the macro grammar with new rules extracted from consistently parsed examples during training.
  • Separates rule retrieval (via similarity) from scoring (via a discriminative model), allowing coarse similarity metrics to be used efficiently.
  • Applies beam search over the filtered set of macro rules to balance efficiency and coverage.

Experimental results

Research questions

  • RQ1Can abstracting recurring logical form patterns into macro grammars reduce search space size and improve parsing efficiency?
  • RQ2Can holistic triggering—selecting macro rules based on overall utterance similarity—outperform phrase-anchored or floating rule triggering?
  • RQ3Does the combination of macro grammars and holistic triggering maintain or improve accuracy while enabling significant speedups?
  • RQ4To what extent can expanding the base grammar be safely done when combined with macro grammar caching?
  • RQ5Can the method generalize to unseen lexical paraphrases and complex questions without requiring explicit phrase matching?

Key findings

  • The method achieves a new state-of-the-art test accuracy of 43.7% on the WikitableQuestions dataset, representing a 1.0% absolute improvement over the previous best.
  • Training with macro grammars and holistic triggering yields an 11x speedup compared to training with only the base grammar.
  • At test time, the learned macro grammar achieves a 16x speedup over the base grammar while maintaining higher accuracy.
  • The macro grammar contributes positively to modeling, improving accuracy from 42.7% (base model) to 43.7% (with macro grammar).
  • The approach effectively handles lexical variation and paraphrases, as demonstrated by successful parsing of unseen wordings like 'Who is X, John or Y?'
  • The use of coarse similarity metrics for rule retrieval is sufficient due to the separation of retrieval and scoring, enabling efficient and scalable parsing.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.