STAR: SQL Guided Pre-Training for Context-dependent Text-to-SQL Parsing

Zefeng Cai, Xiangyu Li, Binyuan Hui, Min Yang, Bowen Li +6 more
10/21/2022
cs.CL

Official code: AlibabaResearch/DAMO-ConvAI (1,623 stars, Python, MIT, last commit 2026-01-22).

Abstract

In this paper, we propose a novel SQL guided pre-training framework STAR for context-dependent text-to-SQL parsing, which leverages contextual information to enrich natural language (NL) utterance and table schema representations for text-to-SQL conversations. Concretely, we propose two novel pre-training objectives which respectively explore the context-dependent interactions of NL utterances and SQL queries within each text-to-SQL conversation: (i) schema state tracking (SST) objective that tracks and explores the schema states of context-dependent SQL queries in the form of schema-states by predicting and updating the value of each schema slot during interaction; (ii) utterance dependency tracking (UDT) objective that employs weighted contrastive learning to pull together two semantically similar NL utterances and push away the representations of semantically dissimilar NL utterances within each conversation.

Show full abstract

In addition, we construct a high-quality large-scale context-dependent text-to-SQL conversation corpus to pre-train STAR. Extensive experiments show that STAR achieves new state-of-the-art performance on two downstream benchmarks (SParC and CoSQL), significantly outperforming previous pre-training methods and ranking first on the leaderboard. We believe the release of the constructed corpus, codebase and pre-trained STAR checkpoints would push forward the research in this area. For reproducibility, we release our code and data at https://github.com/AlibabaResearch/DAMO-ConvAI/tree/main/star.

View on arXivView PDF

Code Implementations(1)

MIT

DAMO-ConvAI: The official repository which contains the codebase for Alibaba DAMO Conversational AI.

1,623253Python, Jupyter NotebookJul 15, 202210 months agoMIT
conversational-aideep-learningdialognatural-language-processing

Similar Papers

Cite this paper

@article{cai2022star,
  title  = {STAR: SQL Guided Pre-Training for Context-dependent Text-to-SQL Parsing},
  author = {Zefeng Cai and Xiangyu Li and Binyuan Hui and Min Yang and Bowen Li and Binhua Li and Zheng Cao and Weijie Li and Fei Huang and Luo Si and Yongbin Li},
  year   = {2022},
  eprint = {2210.11888},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2210.11888}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2210.11888.svg)](https://codeofpaper.com/paper/2210.11888)

Discussion