Automated Commit Message Generation with Large Language Models: An Empirical Study and Beyond
Not on the map. Why?
Abstract (arXiv)
Commit Message Generation (CMG) approaches aim to automatically generate commit messages based on given code diffs, which facilitate collaboration among developers and play a critical role in Open-Source Software (OSS). Very recently, Large Language Models (LLMs) have demonstrated extensive applicability in diverse code-related task. But few studies systematically explored their effectiveness using LLMs. This paper conducts the first comprehensive experiment to investigate how far we have been in applying LLM to generate high-quality commit messages. Motivated by a pilot analysis, we first clean the most widely-used CMG dataset following practitioners' criteria. Afterward, we re-evaluate diverse state-of-the-art CMG approaches and make comparisons with LLMs, demonstrating the superior performance of LLMs against state-of-the-art CMG approaches. Then, we further propose four manual metrics following the practice of OSS, including Accuracy, Integrity, Applicability, and Readability, and assess various LLMs accordingly. Results reveal that GPT-3.5 performs best overall, but different LLMs carry different advantages. To further boost LLMs' performance in the CMG task, we propose an Efficient Retrieval-based In-Context Learning (ICL) framework, namely ERICommiter, which leverages a two-step filtering to accelerate the retrieval efficiency and introduces semantic/lexical-based retrieval algorithm to construct the ICL examples. Extensive experiments demonstrate the substantial performance improvement of ERICommiter on various LLMs for code diffs of different programming languages. Meanwhile, ERICommiter also significantly reduces the retrieval time while keeping almost the same performance. Our research contributes to the understanding of LLMs' capabilities in the CMG field and provides valuable insights for practitioners seeking to leverage these tools in their workflows.
Key facts. Cited by 10 papers in the map (data through 7 Oct 2026). First posted on arXiv 23 Apr 2024.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2024: 2; 2025: 3; 2026: 5.
10 papers.
- 2026AlignCoder: Aligning Retrieval with Target Intent for Repository-Level Code Completioncited by 7
- 2024A Methodology for Evaluating RAG Systems: A Case Study On Configuration Dependency Validationcited by 6
- 2025Hierarchical Repository-Level Code Summarization for Business Applications Using Local LLMscited by 6
- 2024LLM-Cure: LLM-based Competitor User Review Analysis for Feature Enhancementcited by 4
- 2026DRAINCODE: Stealthy Energy Consumption Attacks on Retrieval-Augmented Code Generation via Context Poisoningcited by 3
- 2026PhoenixRepair: Rethinking Repair Strategy Exploration in Software Agentscited by 2
- 2025CodeFuse-CommitEval: Towards Benchmarking LLM's Power on Commit Message and Code Change Inconsistency Detectioncited by 1
- 2025AI-Powered Commit Explorer (APCE)cited by 0
- 2026Schedule-and-Calibrate: Utility-Guided Multi-Task Reinforcement Learning for Code LLMscited by 0
- 2026XSearch: Explainable Code Search via Concept-to-Code Alignmentcited by 0
- 2026PhoenixRepair: Rethinking Repair Strategy Exploration in Software Agents21 Jul 2026
- 2026XSearch: Explainable Code Search via Concept-to-Code Alignment15 May 2026
- 2026Schedule-and-Calibrate: Utility-Guided Multi-Task Reinforcement Learning for Code LLMs7 May 2026
- 2026DRAINCODE: Stealthy Energy Consumption Attacks on Retrieval-Augmented Code Generation via Context Poisoning28 Jan 2026
- 2026AlignCoder: Aligning Retrieval with Target Intent for Repository-Level Code Completion27 Jan 2026
- 2025CodeFuse-CommitEval: Towards Benchmarking LLM's Power on Commit Message and Code Change Inconsistency Detection25 Nov 2025
- 2025AI-Powered Commit Explorer (APCE)21 Jul 2025
- 2025Hierarchical Repository-Level Code Summarization for Business Applications Using Local LLMs14 Jan 2025
- 2024A Methodology for Evaluating RAG Systems: A Case Study On Configuration Dependency Validation11 Oct 2024
- 2024LLM-Cure: LLM-based Competitor User Review Analysis for Feature Enhancement24 Sep 2024