Retrieval-Then-Parsing: A Two-Stage Model for SQL Generation in Financial Domain

Nengzheng Jin,Dongfang Li,Junying Chen,Yubin Qiu,Qingcai Chen
DOI: https://doi.org/10.1007/978-981-19-8300-9_23
2022-01-01
Abstract:Querying financial databases with natural language has been a strong requirement for financial company staff in recent years. The common method for this task is to transform the natural language into structured query language (SQL), which is referred to as semantic parsing. In this paper, we propose a two-stage model for semantic parsing in large financial databases. The two-stage model consists of an integrated table retriever that is used to retrieve related tables from a large database and a knowledge-enhanced semantic parser that utilizes a knowledge base for SQL generation. Experimental results show that our model achieves decent performance, which ranks the first place on both development and test datasets of CCKS 2022 evaluation task 11.
What problem does this paper attempt to address?