The objective of this research project is to address key barriers towards automatic documentation generation for software source code. Programmers create software by writing instructions in source code. That source code is often very difficult to understand, and programmers often must spend significant time writing and updating natural language descriptions of the code to serve as a guide to other programmers. But programmers tend to avoid this task, leading to difficult-to-understand legacy code, bugs, struggles for novice programmers, and other problems. The process of writing these natural language descriptions is called "source code summarization" and this project aims to automate this process. The long-term goal of the project is that automatic documentation generation will improve productivity for software engineers, and increase the quality of software generally.<br/><br/>The two key barriers that this project targets are: 1) context-aware models of code summarization, and 2) improved optimization and evaluation procedures for those models. The research towards item (1) centers on novel neural network-based algorithms for reading and understanding source code. The "context" of a section of source code includes the surrounding source code, dependencies and dependents, programmer communications, bug reports, architecture documentation, and many other software artifacts. This proposal aims to build new neural models of code that include this context such as attentional graph neural networks and dynamic memory networks. The research towards item (2) centers on improving the metrics used to evaluate models of source code summarization, as well as optimization functions used to train these models. This project includes both design of these metrics and functions, and experiments to evaluate them.<br/><br/>This award reflects NSF's statutory mission and has been deemed worthy of support through evaluation using the Foundation's intellectual merit and broader impacts review criteria.