SlowGuess/NAACL_2021_OCR huggingface dataset:
Wei Lu, Hwee Tou Ng, Wee Sun Lee, and Luke S. Zettlemoyer. 2008. A generative model for parsing natural language to meaning representations. In Proceedings of the 2008 Conference on Empirical Methods in Natural Language Processing, pages 783-792, Honolulu, Hawaii. Association for Computational Linguistics.
Christopher Manning and Hinrich Schütze. 1999. Foundations of statistical natural language processing. MIT press.
Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, and Ilya Sutskever. 2019. Language models are unsupervised multitask learners.
Rico Sennrich, Barry Haddow, and Alexandra Birch. 2016. Improving neural machine translation models with monolingual data. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 86-96, Berlin, Germany. Association for Computational Linguistics.
Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017, December 4-9, 2017, Long Beach, CA, USA, pages 5998-6008.
Bailin Wang, Mirella Lapata, and Ivan Titov. 2020a. Meta-learning for domain generalization in semantic parsing. arXiv preprint arXiv:2010.11988.
Bailin Wang, Richard Shin, Xiaodong Liu, Oleksandr Polozov, and Matthew Richardson. 2020b. RAT-SQL: Relation-aware schema encoding and linking for text-to-SQL parsers. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7567-7578, Online. Association for Computational Linguistics.
Daniel C Wang, Andrew W Appel, Jeffrey L Korn, and Christopher S Serra. 1997. The zephyr abstract syntax description language.
Yuk Wah Wong and Raymond Mooney. 2006. Learning for semantic parsing with statistical machine translation. In Proceedings of the Human Language Technology Conference of the NAACL, Main Conference, pages 439-446, New York City, USA. Association for Computational Linguistics.
Yuk Wah Wong and Raymond Mooney. 2007. Learning synchronous grammars for semantic parsing with lambda calculus. In Proceedings of the 45th Annual Meeting of the Association of Computational Linguistics, pages 960-967, Prague, Czech Republic. Association for Computational Linguistics.
Pengcheng Yin and Graham Neubig. 2018. TRANX: A transition-based neural abstract syntax parser for semantic parsing and code generation. In Proceedings of the 2018 Conference on Empirical Methods in
Natural Language Processing: System Demonstrations, pages 7-12, Brussels, Belgium. Association for Computational Linguistics.
Tao Yu, Chien-Sheng Wu, Xi Victoria Lin, Bailin Wang, Yi Chern Tan, Xinyi Yang, Dragomir Radev, Richard Socher, and Caiming Xiong. 2020. Grappa: Grammar-augmented pre-training for table semantic parsing.
Tao Yu, Rui Zhang, Kai Yang, Michihiro Yasunaga, Dongxu Wang, Zifan Li, James Ma, Irene Li, Qingning Yao, Shanelle Roman, Zilin Zhang, and Dragomir Radev. 2018b. Spider: A large-scale human-labeled dataset for complex and cross-domain semantic parsing and text-to-SQL task. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, pages 3911-3921, Brussels, Belgium. Association for Computational Linguistics.
Luke S. Zettlemoyer and Michael Collins. 2005. Learning to map sentences to logical form: Structured classification with probabilistic categorial grammars. In Proceedings of the Twenty-First Conference on Uncertainty in Artificial Intelligence, UAI'05, page 658-666, Arlington, Virginia, USA. AUAI Press.
Victor Zhong, Mike Lewis, Sida I. Wang, and Luke Zettlemoyer. 2020. Grounded adaptation for zero-shot executable semantic parsing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 6869-6882, Online. Association for Computational Linguistics.
A CFG Rules
Following Yin and Neubig (2018), we represent ASDL grammar of SQLs using a set of production rules, as illustrated in Figure 3.
Formally, a production rule  $T$  is denoted as  $N \to \zeta$ , where  $N$  represents a non-terminal variable type,  $\zeta$  represents a sequence of terminal or non-terminals. We can derive a set of production rules from our pre-defined ASDL grammar by instantiating original ASDL statements. For example, "sql = (select select, cond? where)" is instantiated into two rules: "sql → select" and "sql →
sql  $\rightarrow$  select; sql  $\rightarrow$  select, cond;   
select  $\rightarrow$  agg; select  $\rightarrow$  agg, agg;   
agg  $\rightarrow$  agg_type, column;   
agg_type  $\rightarrow$  NoneAggOp;   
agg_type  $\rightarrow$  Min; agg_type  $\rightarrow$  Max; cond  $\rightarrow$  And; cond  $\rightarrow$  Or; cond  $\rightarrow$  Not;
Figure 3: Context-free grammars that represent the ASDL grammar in Figure 2 of the main paper. Only variable types are used in the production rules.
select, cond". With pre-defined production rules, a SQL can be transformed into a sequence of production rules. For example, the SQL query "select max(age)" can be represented by the sequence:
(1)  $\mathrm{sq} \to \mathrm{select}$
(2) select  $\rightarrow$  agg
(3)  $\mathrm{agg} \rightarrow \mathrm{agg\_type}$ , column
(4)  $\mathrm{agg\_type} \to \mathrm{Max}$
(5) column  $\rightarrow$  age