mlsanityData to 7 Oct 2026

Improved Automatic Summarization of Subroutines via Attention to File Context

arXiv 2004.04881 ↗First posted 10 Apr 2020cs.SEcited by 34

Not on the map. Why?

Abstract (arXiv)

Software documentation largely consists of short, natural language summaries of the subroutines in the software. These summaries help programmers quickly understand what a subroutine does without having to read the source code him or herself. The task of writing these descriptions is called "source code summarization" and has been a target of research for several years. Recently, AI-based approaches have superseded older, heuristic-based approaches. Yet, to date these AI-based approaches assume that all the content needed to predict summaries is inside subroutine itself. This assumption limits performance because many subroutines cannot be understood without surrounding context. In this paper, we present an approach that models the file context of subroutines (i.e. other subroutines in the same file) and uses an attention mechanism to find words and concepts to use in summaries. We show in an experiment that our approach extends and improves several recent baselines.

Key facts. Cited by 34 papers in the map (data through 7 Oct 2026). First posted on arXiv 10 Apr 2020.

Builds on

No reference list yet.

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2021: 9; 2022: 9; 2023: 10; 2024: 3; 2025: 2; 2026: 1.

34 papers.

Sort:

  1. 2022CoCoMIC: Code Completion By Jointly Modeling In-file and Cross-file Contextcited by 64
  2. 2021On the Evaluation of Neural Code Summarizationcited by 47
  3. 2021Multilingual training for Software Engineeringcited by 43
  4. 2023Automatic Code Summarization via ChatGPT: How Far Are We?cited by 34
  5. 2023Distilled GPT for Source Code Summarizationcited by 30
  6. 2021Project-Level Encoding for Neural Source Code Summarization of Subroutinescited by 24
  7. 2021A Survey on Machine Learning Techniques for Source Code Analysiscited by 23
  8. 2023Deep Learning for Code Intelligence: Survey, Benchmark and Toolkitcited by 22
  9. 2022Deep Learning Meets Software Engineering: A Survey on Pre-Trained Models of Source Codecited by 20
  10. 2021Improving Code Summarization with Block-wise Abstract Syntax Tree Splittingcited by 19
  11. 2022Pop Quiz! Can a Large Language Model Help With Reverse Engineering?cited by 13
  12. 2022An Exploratory Study on Code Attention in BERTcited by 12
22 more
  1. 2021API2Com: On the Improvement of Automatically Generated Code Comments Using API Documentationscited by 10
  2. 2022Learning to Parallelize in a Shared-Memory Environment with Transformerscited by 10
  3. 2025Towards an Understanding of Context Utilization in Code Intelligencecited by 10
  4. 2023Towards Modeling Human Attention from Eye Movements for Neural Source Code Summarizationcited by 8
  5. 2021HAConvGNN: Hierarchical Attention Based Convolutional Graph Neural Network for Code Documentation Generation in Jupyter Notebookscited by 6
  6. 2024ESALE: Enhancing Code-Summary Alignment Learning for Source Code Summarizationcited by 6
  7. 2021Learning to Generate Code Comments from Class Hierarchiescited by 5
  8. 2022GypSum: Learning Hybrid Representations for Code Summarizationcited by 5
  9. 2023Semantic Similarity Loss for Neural Source Code Summarizationcited by 5
  10. 2023A Comprehensive Evaluation of Parameter-Efficient Fine-Tuning on Software Engineering Taskscited by 5
  11. 2023Revisiting File Context for Source Code Summarizationcited by 3
  12. 2022Adding Context to Source Code Representations for Deep Learningcited by 2
  13. 2023APIContext2Com: Code Comment Generation by Incorporating Pre-Defined API Documentationcited by 2
  14. 2023Statement-based Memory for Neural Source Code Summarizationcited by 2
  15. 2022LAMNER: Code Comment Generation Using Character Language Model and Named Entity Recognitioncited by 1
  16. 2023An Exploratory Literature Study on Sharing and Energy Use of Language Models for Source Codecited by 1
  17. 2024Beyond Self-learned Attention: Mitigating Attention Bias in Transformer-based Models Using Attention Guidancecited by 1
  18. 2021Code Representation Learning with Pr"ufer Sequencescited by 0
  19. 2022Meta Learning for Code Summarizationcited by 0
  20. 2024CONCORD: Towards a DSL for Configurable Graph Code Representationcited by 0
  21. 2025Simple and Effective Baselines for Code Summarisation Evaluationcited by 0
  22. 2026On the Impact of Code Comments for Automated Bug-Fixing: An Empirical Studycited by 0