AI-Mediated Code Comment Improvement
Dhakal, Maria, Su, Chia-Yi, Wallace, Robert, Fakhimi, Chris, Bansal, Aakash, Li, Toby, Huang, Yu, McMillan, Collin
–arXiv.org Artificial Intelligence
This paper describes an approach to improve code comments along different quality axes by rewriting those comments with customized Artificial Intelligence (AI)-based tools. We conduct an empirical study followed by grounded theory qualitative analysis to determine the quality axes to improve. Then we propose a procedure using a Large Language Model (LLM) to rewrite existing code comments along the quality axes. We implement our procedure using GPT-4o, then distil the results into a smaller model capable of being run in-house, so users can maintain data custody. We evaluate both our approach using GPT-4o and the distilled model versions. We show in an evaluation how our procedure improves code comments along the quality axes. We release all data and source code in an online repository for reproducibility.
arXiv.org Artificial Intelligence
May-15-2025
- Country:
- North America > United States
- New York (0.04)
- Tennessee > Davidson County
- Nashville (0.04)
- Indiana > St. Joseph County
- Notre Dame (0.05)
- Europe > United Kingdom
- North America > United States
- Genre:
- Research Report
- New Finding (1.00)
- Experimental Study (1.00)
- Research Report
- Technology: