Latent Predictor Networks for Code Generation
By Wang Ling, Phil Blunsom, Edward Grefenstette, Karl Moritz Hermann, Tomás Kociský, Fumin Wang, Andrew W. Senior. 2016
410 citations recorded by the source corpus.
Many language generation tasks require the production of text conditioned on both structured and unstructured inputs. We present a novel neural network architecture which generates an output sequence conditioned on an arbitrary number of input functions. Crucially, our approach allows both the choice of conditioning context and the granularity of generation, for example characters or tokens, to be marginalised, thus permitting scalable and effective training. Using this framework, we address the problem of generating programming code from a mixed natural language and structured specification. We create two new data sets for this paradigm derived from the collectible trading card games Magic the Gathering and Hearthstone. On these, and a third preexisting corpus, we demonstrate that marginalising multiple predictors allows our model to outperform strong benchmarks.
Subfields: Artificial Intelligence, 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
- Mohit Bansal
- Luke S. Zettlemoyer
- Percy Liang
- Jianfeng Gao
- Caiming Xiong
- Quoc V. Le
- Yejin Choi
In Natural Language Processing
- Graham Neubig
- Mohit Bansal
- Luke S. Zettlemoyer
- Percy Liang
- Richard Socher
- Caiming Xiong
- Mirella Lapata
- Jonathan Berant
Citations in the corpus
- A Deep Reinforced Model for Abstractive Summarization (2017, background): “One way to fix this is to allow the decoder network to point back to some specific words or sub-sequences of the input and copy them onto the output sequence (Vinyals et al., 2015; Ling et al., 2016).”
- Pointer Sentinel Mixture Models (2016, methodology): “Extending this concept further, the latent predictor network (Ling et al., 2016) generates an output sequence conditioned on an arbitrary number of base models where each base model may have differing granularity.”
- Program Synthesis with Large Language Models (2021, methodology): “Also, several different methods have been proposed for the problem of mapping a natural language description to code in general-purpose languages like Python [Ling et al., 2016, Yin and Neubig, 2017, Iyer et al., 2018].”
- Evaluating Large Language Models Trained on Code (2021, background): “Latent Predictor Networks (Ling et al., 2016) showed that character-level language models could generate working code for implementing Magic the Gathering cards in an online arena, when aided with a latent mode that allows card attributes to be copied into code.”
- 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…”
- A Survey of Machine Learning for Big Code and Naturalness (2017, background): “[120] PD (c |m) Token RNN + Attention Code Synthesis”
- A Retrieve-and-Edit Framework for Predicting Structured Outputs (2018, methodology): “We also evaluate on the Hearthstone cards benchmark [22], where systems must predict a code snippet based on card properties and a natural language description.”
- CodeSearchNet Challenge: Evaluating the State of Semantic Code Search (2019, background): “Although most approaches are usually aimed towards creating an executable representation of a natural language utterance with a domain-specific language, general-purpose languages have been recently considered by Hashimoto et al. [13], Lin et al. [16], Ling et al. [17], Yin and Neubig [25].”
- Measuring Coding Challenge Competence With APPS (2021, methodology): “Ling et al. (2016) introduce datasets based on Hearthstone and Magic the Gathering card games for code generation.”
- Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Task (2018, background): “Recently, researchers have constructed some datasets for code generation including IFTTT (Quirk et al., 2015), DJANGO (Oda et al., 2015), HEARTHSTONE (Ling et al., 2016), NL2Bash (Lin et al., 2018), and CoNaLa (Yin et al., 2018).”
- DeepCoder: Learning to Write Programs (2016, background): “Only very recently, Riedel et al. (2016); Bunel et al. (2016); Gaunt et al. (2016) explored the use of gradient descent to induce source code from input-output examples via differentiable interpreters, and Ling et al. (2016) explored the generation of source code from unstructured text descriptions.”
- Latent Sequence Decompositions (2016, methodology): “We presented a biased training algorithm based on sampling valid extensions with an ǫ -greedy strategy, and an approximate decoding algorithm.”
- Reference-Aware Language Models (2016, methodology): “In terms of methodology, our work is closely related to previous works that incorporate copying mechanism with neural models (Gülçehre et al., 2016; Gu et al., 2016; Ling et al., 2016; Vinyals et al., 2015).”
- Abstract Syntax Networks for Code Generation and Semantic Parsing (2017, methodology): “Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics, pages 1139–1149 Vancouver, Canada, July 30 - August 4, 2017. c©2017 Association for Computational Linguistics https://doi.org/10.18653/v1/P17-1105 Abstract Syntax Networks for Code Generation and Semantic Parsin”
- Key-Value Retrieval Networks for Task-Oriented Dialogue (2017, background): “Recent literature has shown that incorporating a copying mechanism into neural architectures improves performance on various sequence-to-sequence tasks (Jia and Liang, 2016; Gu et al., 2016; Ling et al., 2016; Gulcehre et al., 2016; Eric and Manning, 2017).”
- Learning a Neural Semantic Parser from User Feedback (2017, background): “Finally, Ling et al. (2016) generate Java/Python code for trading cards given a natural language description; however, this system suffers from low overall accuracy.”