README files play an essential role in shaping a developer's first impression of a software repository and in documenting the software project that the repository hosts. Yet, we lack a systematic understanding of the content of a typical README file as well as tools that can process these files automatically. To close this gap, we conduct a qualitative study involving the manual annotation of 4,226 README file sections from 393 randomly sampled GitHub repositories and we design and evaluate a classifier and a set of features that can categorize these sections automatically. We find that information discussing the `What' and `How' of a repository is very common, while many README files lack information regarding the purpose and status of a repository. Our multi-label classifier which can predict eight different categories achieves an F1 score of 0.746. To evaluate the usefulness of the classification, we used the automatically determined classes to label sections in GitHub README files using badges and showed files with and without these badges to twenty software professionals. The majority of participants perceived the automated labeling of sections based on our classifier to ease information discovery. This work enables the owners of software repositories to improve the quality of their documentation and it has the potential to make it easier for the software development community to discover relevant information in GitHub README files.
LLM-based Content Classification Approach for GitHub Repositories by the README Files
Department of Computing and Built Environment(计算与环境系);Birmingham City University(伯明翰城市大学);Department of Computer Science and Software Engineering(计算机科学与软件工程系);School of Engineering(工程学院);Penn State University, Behrend, Erie PA(宾夕法尼亚州立大学贝伦分校,埃里普斯帕州);Department of Electrical Engineering(电气工程系);UET Taxila(塔希尔工程大学)
Topic Recommendation for Software Repositories using Multi-label Classification Algorithms
许多平台利用协作标记来在搜索或导航时为用户提供更快、更准确的结果。标签可以传达不同的概念,例如主要特性、技术、功能和软件存储库的目标。最近,GitHub允许用户使用主题标签来注释存储库。它还提供了一组特色主题,以及在社区的帮助下精心策划的可能的别名。这就创造了一个机会,通过训练模型向开发人员推荐高质量的主题标签,使用这个初始的主题种子来自动注释所有剩余的存储库。在这项工作中,我们研究了应用多标签分类技术预测软件仓库的主题。首先,我们将大量的用户自定义主题映射到GitHub上的主题。其核心思想是从项目的可用文档中获取更多信息。我们的数据包含有关$152$ K GitHub存储库和$228$特色主题。然后,我们将监督模型应用于存储库的文本信息,如描述、README文件、wiki页面和文件名。我们评估我们的方法的性能定量和定性。我们提出的模型分别达到了$0.890$和$0.805$的Recall@5和LRAP分数。此外,根据用户的评估,我们的方法是高度能够推荐一个正确的和完整的主题集。最后,我们使用我们的模型来开发一个名为\texttt{Repository Catalogue}的在线工具,它可以自动预测GitHub存储库的主题,并且可以公开使用。