Structured Generative Models of Natural Source Code

By Chris J. Maddison, Daniel Tarlow. 2014

175 citations recorded by the source corpus.

We study the problem of building generative models of natural source code (NSC); that is, source code written and understood by humans. Our primary contribution is to describe a family of generative models for NSC that have three key properties: First, they incorporate both sequential and hierarchical structure. Second, we learn a distributed representation of source code elements. Finally, they integrate closely with a compiler, which allows leveraging compiler logic and abstractions when building structure into the model. We also develop an extension that includes more complex structure, refining how the model generates identifier tokens based on what variables are currently in scope. Our models can be learned efficiently, and we show empirically that including appropriate structure greatly improves the models, measured by the probability of generating test programs.

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

  1. Percy Liang
  2. Mohit Bansal
  3. Graham Neubig
  4. Luke S. Zettlemoyer
  5. Yoshua Bengio
  6. Quoc V. Le
  7. Sergey Levine
  8. Jianfeng Gao

In Information Systems

  1. Miltiadis Allamanis
  2. Charles Sutton
  3. Eran Yahav
  4. Uri Alon
  5. Michael Pradel
  6. Rishabh Singh
  7. Premkumar T. Devanbu
  8. Koushik Sen

In Natural Language Processing

  1. Graham Neubig
  2. Charles Sutton
  3. Miltiadis Allamanis
  4. Mohit Bansal
  5. Percy Liang
  6. Omer Levy
  7. Luke S. Zettlemoyer
  8. Kyunghyun Cho

Citations in the corpus