Natural Language Outlines for Code: Literate Programming in the LLM Era
We propose using natural language outlines as a novel modality and interaction surface for providing AI assistance to developers throughout the software development process. An NL outline for a code function comprises multiple statements written in concise prose, which partition the code and summarize its main ideas in the style of literate programming. Crucially, we find that modern LLMs can generate accurate and high-quality NL outlines in practice. Moreover, NL outlines enable a bidirectional sync between code and NL, where a developer can change either code or NL and have the LLM automatically update the other. We discuss many use cases for NL outlines: they can accelerate understanding and navigation of code and diffs, simplify code maintenance, augment code search, steer code generation, and more. We then propose and compare multiple LLM prompting techniques for generating outlines and ask professional developers to judge outline quality. Finally, we present two case studies applying NL outlines toward code review and malware detection.
Authors
- Maxim Tabachnyk (ORCID: https://orcid.org/0009-0001-5710-2302)
- Charles Sutton (ORCID: https://orcid.org/0000-0002-0041-3820)
- Mihai Christodorescu (ORCID: https://orcid.org/0000-0001-5808-8015)
- Kensen Shi (ORCID: https://orcid.org/0000-0001-7140-7869)
- Tobias Welp
- Pengcheng Yin (ORCID: https://orcid.org/0000-0003-2739-1032)
- Deniz Altınbüken (ORCID: https://orcid.org/0000-0002-4558-2847)
- Saswat Anand
- Satish Chandra (ORCID: https://orcid.org/0000-0003-2546-9000)
- Brandon Ruffin
- Siddhant Sanyam
- Sara Toth
- Katja Grünwedel
- Alexa Koenings
- Marc Rasi
- Fredde Ribeiro
- S Sanyasi Naidu
- Roy Tu
- Manzil Zaheer
- Anurag Pathak
Institutions
- Google (United States) (US)
Publication Details
- Published
- 2025-06-23
- DOI
- https://doi.org/10.1145/3696630.3728541
- Citations
- 3
- Primary Topic
- Natural Language Processing Techniques
- Type
- article
- Field-Weighted Citation Impact
- 7.44