HyperAIHyperAI

Command Palette

Search for a command to run...

4 months ago

Semantic Parsing with Syntax- and Table-Aware SQL Generation

Yibo Sun; Duyu Tang; Nan Duan; Jianshu Ji; Guihong Cao; Xiaocheng Feng; Bing Qin; Ting Liu; Ming Zhou

Semantic Parsing with Syntax- and Table-Aware SQL Generation

Abstract

We present a generative model to map natural language questions into SQL queries. Existing neural network based approaches typically generate a SQL query word-by-word, however, a large portion of the generated results are incorrect or not executable due to the mismatch between question words and table contents. Our approach addresses this problem by considering the structure of table and the syntax of SQL language. The quality of the generated SQL query is significantly improved through (1) learning to replicate content from column names, cells or SQL keywords; and (2) improving the generation of WHERE clause by leveraging the column-cell relation. Experiments are conducted on WikiSQL, a recently released dataset with the largest question-SQL pairs. Our approach significantly improves the state-of-the-art execution accuracy from 69.0% to 74.4%.

Benchmarks

BenchmarkMethodologyMetrics
code-generation-on-wikisqlSTAMP+RL (Sun et al., 2018)+
Exact Match Accuracy: 61.0
Execution Accuracy: 74.6
code-generation-on-wikisqlSTAMP (Sun et al., 2018)+
Exact Match Accuracy: 60.7
Execution Accuracy: 74.4

Build AI with AI

From idea to launch — accelerate your AI development with free AI co-coding, out-of-the-box environment and best price of GPUs.

AI Co-coding
Ready-to-use GPUs
Best Pricing
Get Started

Hyper Newsletters

Subscribe to our latest updates
We will deliver the latest updates of the week to your inbox at nine o'clock every Monday morning
Powered by MailChimp
Semantic Parsing with Syntax- and Table-Aware SQL Generation | Papers | HyperAI