Lune

ICSE2023Top-tier venue

Revisiting Learning-based Commit Message Generation

Jinhao Dong, Yiling Lou, Dan Hao, Lin Tan

Abstract

Commit messages summarize code changes and help developers understand the intention. To alleviate human efforts in writing commit messages, researchers have proposed various automated commit message generation techniques, among which learning-based techniques have achieved great success in recent years. However, existing evaluation on learning-based commit message generation relies on the automatic metrics (e.g., BLEU) widely used in natural language processing (NLP) tasks, which are aggregated scores calculated based on the similarity between generated commit messages and the ground truth. Therefore, it remains unclear what generated commit messages look like and what kind of commit messages could be precisely generated by existing learning-based techniques. To fill this knowledge gap, this work performs the first study to systematically investigate the detailed commit messages generated by learning-based techniques. In particular, we first investigate the frequent patterns of the commit messages generated by state-of-the-art learning-based techniques. Surprisingly, we find the majority ( 90%) of their generated commit messages belong to simple patterns (i.e., addition/removal/fix/avoidance patterns). To further explore the reasons, we then study the impact of datasets, input representations, and model components. We surprisingly find that existing learning-based techniques have competitive performance even when the inputs are only represented by change marks (i.e., “+”/“-”/“ ”), It indicates that existing learning-based techniques poorly utilize syntax and semantics in the code while mostly focusing on change marks, which could be the major reason for generating so many pattern-matching commit messages. We also find that the pattern ratio in the training set might also positively affect the pattern ratio of generated commit messages; and model components might have different impact on the pattern ratio.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

3 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Context Conquers Parameters: Outperforming Proprietary Llm in Commit Message Generation cites FIRA: Fine-Grained Graph-Based Code Change Representation for Automated Commit Message Generation
  • Context Conquers Parameters: Outperforming Proprietary Llm in Commit Message Generation cites What Makes a Good Commit Message?
  • Understanding Code Changes Practically with Small-Scale Language Models cites CC2Vec: distributed representations of code changes
  • Understanding Code Changes Practically with Small-Scale Language Models cites FIRA: Fine-Grained Graph-Based Code Change Representation for Automated Commit Message Generation
  • Understanding Code Changes Practically with Small-Scale Language Models cites What Makes a Good Commit Message?
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers3

  1. Understanding Code Changes Practically with Small-Scale Language ModelsCong Li, Zhaogui Xu, Peng Di, Dongxia Wang et al.ASE 2024 · 4 citations
  2. Mutual Learning-Based Framework for Enhancing Robustness of Code Models via Adversarial TrainingYangsen Wang, Yizhou Chen, Yifan Zhao, Zhihao Gong et al.ASE 2024 · 3 citations
  3. Context Conquers Parameters: Outperforming Proprietary Llm in Commit Message GenerationAaron Imani, Iftekhar Ahmed, Mohammad MoshirpourICSE 2025 · 1 citation

Builds on3

  1. CC2Vec: distributed representations of code changesThong Hoang, Hong Jin Kang, David Lo, Julia LawallICSE 2020 · 169 citations
  2. What Makes a Good Commit Message?Yingchen Tian, Yuxia Zhang, Klaas-Jan Stol, Lin Jiang et al.ICSE 2022 · 90 citations
  3. FIRA: Fine-Grained Graph-Based Code Change Representation for Automated Commit Message GenerationJinhao Dong, Yiling Lou, Qihao Zhu, Zeyu Sun et al.ICSE 2022 · 50 citations

Related papers

  1. An Empirical Study on Learning-based Techniques for Explicit and Implicit Commit Messages GenerationZhiquan Huang, Yuan Huang, Xiangping Chen, Xiaocong Zhou et al.ASE 2024 · 2 citations
  2. Evaluating Generated Commit Messages with Large Language ModelsQunhong Zeng, Yuxia Zhang, Zexiong Ma, Bo Jiang et al.ICSE 2026
  3. COME: Commit Message Generation with Modification EmbeddingYichen He, Liran Wang, Kaiyi Wang, Yupeng Zhang et al.ISSTA 2023 · 14 citations
  4. RACE: Retrieval-augmented Commit Message GenerationEnsheng Shi, Yanlin Wang, Wei Tao, Lun Du et al.EMNLP 2022 · 36 citations
  5. An Empirical Study on Commit Message Generation Using LLMs via In-Context LearningYifan Wu, Yunpeng Wang, Ying Li, Wei Tao et al.ICSE 2025 · 1 citation
Dusk over the sea between two cliffs drawn in fine vertical lines