Abstract Syntax Networks for Code Generation and Semantic Parsing
By Maxim Rabinovich, Mitchell Stern, Daniel Klein. 2017
389 citations recorded by the source corpus.
Tasks like code generation and semantic parsing require mapping unstructured (or partially structured) inputs to well-formed, executable outputs. We introduce abstract syntax networks, a modeling framework for these problems. The outputs are represented as abstract syntax trees (ASTs) and constructed by a decoder with a dynamically-determined modular structure paralleling the structure of the output tree. On the benchmark Hearthstone dataset for code generation, our model obtains 79.2 BLEU and 22.7% exact match accuracy, compared to previous state-of-the-art values of 67.1 and 6.1%. Furthermore, we perform competitively on the Atis, Jobs, and Geo semantic parsing datasets with no task-specific engineering.
Subfields: Artificial Intelligence, Information Systems, Natural Language Processing
How researchers see this paper
The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.
In Artificial Intelligence
- Graham Neubig
- Luke S. Zettlemoyer
- Percy Liang
- Mohit Bansal
- Jonathan Berant
- Jianfeng Gao
- Caiming Xiong
- Hannaneh Hajishirzi
In Information Systems
- Miltiadis Allamanis
- Uri Alon
- Eran Yahav
- Charles Sutton
- Graham Neubig
- Rishabh Singh
- Baishakhi Ray
- Omer Levy
In Natural Language Processing
- Graham Neubig
- Luke S. Zettlemoyer
- Percy Liang
- Jonathan Berant
- Mohit Bansal
- Mirella Lapata
- Caiming Xiong
- Matt Gardner
Citations in the corpus
- SPoC: Search-based Pseudocode to Code (2019, background): “…text descriptions to a one-line program [42, 35, 43, 44, 21, 8], and while recent work explored generating longer programs from text descriptions [22, 40, 29, 15, 16, 14], these programs are mostly evaluated on syntactic metrics (e.g., exact match and BLEU score) rather than functional correctness.”
- A Survey of Machine Learning for Big Code and Naturalness (2017, background): “d Pradel [153] PD(c) Syntax Annotated PCFG Fuzz Testing Pham et al. [154] PD(c) Bytecode Graphical Model (HMM) Code Completion Pu et al. [160] PD(c|s) Token NN (Seq2seq) Code Fixing Rabinovich et al. [162]∗ PD(c|m) Syntax NN (LSTM-based) Code Synthesis Raychev et al. [166] PD(c) Token+Constraints n-”
- A Retrieve-and-Edit Framework for Predicting Structured Outputs (2018, methodology): “Methods based on ASTs still achieve the highest BLEU and exact match scores, but we are able to significantly narrow the gap between specialized code generation techniques and vanilla sequence-tosequence models if the latter is boosted with the retrieve-and-edit framework.”
- Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Task (2018, background): “These tasks parse natural language descriptions into a more general-purpose programming language such as Python (Allamanis et al., 2015; Ling et al., 2016; Rabinovich et al., 2017; Yin and Neu-big, 2017).”
- CodeBLEU: a Method for Automatic Evaluation of Code Synthesis (2020, background): “In contrast, code has a natural tree structure and needs to be compiled according to their abstract syntax tree (Rabinovich, Stern, and Klein 2017).”
- Unsupervised Translation of Programming Languages (2020, background): “To address this issue, several approaches proposed to use additional constraints on the decoder, to ensure that the generated functions respect the syntax of the target language [3, 4, 5, 40, 48].”
- code2seq: Generating Sequences from Structured Representations of Code (2018, methodology): “…code and natural language can be used for automatic code summarization (Allamanis et al., 2016), documentation (Iyer et al., 2016), retrieval (Allamanis et al., 2015b), and even generation (Balog et al., 2016; Rabinovich et al., 2017; Yin and Neubig, 2017; Devlin et al., 2017; Murali et al., 2017).”
- Learning to Mine Aligned Code and Natural Language Pairs from Stack Overflow (2018, background): “.e., garbage in, garbage out [35]. For a particular class of applications, such as source code retrieval given a NL query [42], source code summarization in NL [15], and source code synthesis from NL [33, 47], all of which involve correspondence between NL utterances and code, it is essential to hav”
- GraphCodeBERT: Pre-training Code Representations with Data Flow (2020, background): “, 2020), code generation (Rabinovich et al., 2017; Yin & Neubig, 2017; Brockschmidt et al., 2018), code clone detection (Wei & Li, 2017; Zhang et al.”
- Tree-to-tree Neural Networks for Program Translation (2018, methodology): “Recently, various neural networks with tree structures have been proposed to employ the structural information of the data [11, 26, 25, 32, 3, 29, 34, 27, 13, 33, 28, 18, 6].”
- Neural Semantic Parsing with Type Constraints for Semi-Structured Tables (2017, background): “Recent work has explored similar ideas to ours in the context of Python code generation (Yin and Neubig, 2017; Rabinovich et al., 2017).”
- Coarse-to-Fine Decoding for Neural Semantic Parsing (2018, methodology): “…include tree decoders (Dong and Lapata, 2016; Alvarez-Melis and Jaakkola, 2017), decoders constrained by a grammar model (Xiao et al., 2016; Yin and Neu-big, 2017; Krishnamurthy et al., 2017), or modular decoders which use syntax to dynamically compose various submodels (Rabinovich et al., 2017).”
- Neural Program Synthesis with Priority Queue Training (2018, neutral): “…2016; Zaremba et al., 2016; Barone & Sennrich, 2017; Beltramelli, 2017; Cai et al., 2017; Devlin et al., 2017; Hu et al., 2017; Guu et al., 2017; Johnson et al.; Liang et al., 2017; Murali et al., 2017; Parisotto et al., 2016; Rabinovich et al., 2017; Vigueras et al., 2017; Yin & Neubig, 2017).”
- Benchmarking Meaning Representations in Neural Semantic Parsing (2020, methodology): “Multiple neural semantic parsing approaches (Dong and Lapata, 2016; Iyer et al., 2017; Rabinovich et al., 2017) adopt the data anonymization techniques to replace entities in utterances with placeholders.”
- On the Potential of Lexico-logical Alignments for Semantic Parsing to SQL Queries (2020, methodology): “For semantic parsing, Rabinovich et al. (2017) improve code generation with exact string-match heuristics to provide supervision for attention.”
- Generative Code Modeling with Graphs (2018, methodology): “Additional Improvements Following Rabinovich et al. [19], we provide additional information for Child edges.”
- Learning Programmatic Idioms for Scalable Semantic Parsing (2019, background): “Instead of directly generating a sequence of code tokens, recent methods focus on constrained decoding mechanisms to generate syntactically correct output using a decoder that is either grammar-aware or has a dynamically determined modular structure paralleling the structure of the abstract syntax t”