Skip to main content
QUICK REVIEW

[Paper Review] HIE-SQL: History Information Enhanced Network for Context-Dependent Text-to-SQL Semantic Parsing

Yanzhao Zheng, Haibin Wang|ArXiv.org|Mar 14, 2022
Topic Modeling4 citations
TL;DR

HIE-SQL proposes a history information enhanced network for context-dependent text-to-SQL parsing by jointly leveraging interaction history utterances and the last predicted SQL query through a bimodal pre-trained model (SQLBERT) and a schema-linking graph. It achieves state-of-the-art results on SparC (64.6% question match, 42.9% interaction match) and CoSQL (53.9% question match, 24.6% interaction match).

ABSTRACT

Recently, context-dependent text-to-SQL semantic parsing which translates natural language into SQL in an interaction process has attracted a lot of attention. Previous works leverage context-dependence information either from interaction history utterances or the previous predicted SQL queries but fail in taking advantage of both since of the mismatch between natural language and logic-form SQL. In this work, we propose a History Information Enhanced text-to-SQL model (HIE-SQL) to exploit context-dependence information from both history utterances and the last predicted SQL query. In view of the mismatch, we treat natural language and SQL as two modalities and propose a bimodal pre-trained model to bridge the gap between them. Besides, we design a schema-linking graph to enhance connections from utterances and the SQL query to the database schema. We show our history information enhanced methods improve the performance of HIE-SQL by a significant margin, which achieves new state-of-the-art results on the two context-dependent text-to-SQL benchmarks, the SparC and CoSQL datasets, at the writing time.

Motivation & Objective

  • Address the challenge of context-dependent text-to-SQL parsing where dependencies span multiple turns and require modeling of both natural language and logic-form SQL.
  • Overcome the mismatch between natural language utterances and logic-form SQL queries in context modeling by treating them as two modalities.
  • Improve long-range dependency modeling by incorporating both historical utterances and the last predicted SQL query into a unified context-aware framework.
  • Enhance schema grounding by designing a history information enhanced schema-linking graph that connects utterances, SQL queries, and database schema.
  • Achieve state-of-the-art performance on large-scale cross-domain context-dependent text-to-SQL benchmarks, SparC and CoSQL.

Proposed method

  • Propose SQLBERT, a bimodal pre-trained model that jointly encodes natural language utterances and logic-form SQL queries to bridge semantic gaps between modalities.
  • Design a history information enhanced schema-linking graph that explicitly models relations between current utterance, historical utterances, the last predicted SQL query, and the database schema.
  • Use relative self-attention mechanisms to encode long-range dependencies in the schema-linking graph, enabling dynamic attention over historical context.
  • Integrate R-Drop regularization to improve model robustness and generalization, especially under noisy or ambiguous context.
  • Employ a sequence-to-sequence decoder with grammar constraints to generate syntactically valid SQL queries while preserving context-aware representations.
  • Train the model end-to-end using cross-entropy loss and R-Drop, with beam search inference to optimize for exact match metrics.

Experimental results

Research questions

  • RQ1How can both interaction history utterances and the last predicted SQL query be effectively leveraged to improve context-dependent text-to-SQL parsing?
  • RQ2To what extent can a bimodal pre-trained model like SQLBERT reduce the semantic gap between natural language and logic-form SQL?
  • RQ3Can a schema-linking graph that incorporates both utterances and SQL queries improve grounding accuracy and long-range dependency modeling?
  • RQ4How does the integration of historical SQL queries affect model robustness and performance stability across training steps?
  • RQ5What is the impact of R-Drop regularization on the model’s ability to generalize and maintain high performance under varying context conditions?

Key findings

  • HIE-SQL achieves a 64.6% question match and 42.9% interaction match on the SparC benchmark, setting a new state-of-the-art.
  • On the CoSQL benchmark, HIE-SQL achieves 53.9% question match and 24.6% interaction match, also establishing a new state-of-the-art.
  • The ablation study confirms that incorporating the last predicted SQL query improves performance significantly, with a notable gain in interaction match accuracy.
  • SQLBERT pre-training improves model performance over simple concatenation of SQL and utterance embeddings, demonstrating its effectiveness in cross-modal representation learning.
  • The use of R-Drop leads to a more stable training curve and lower variance in interaction match scores, indicating improved robustness.
  • Case studies show HIE-SQL successfully inherits context from prior SQL queries—e.g., correctly extending the query in CoSQL example b3—while baselines like RAT-SQL fail due to misalignment in long-range dependencies.

Better researchstarts right now

From reading papers to final review, dramatically reduce your research time.

No credit card · Free plan available

This review was created by AI and reviewed by human editors.