arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1903.09174cs.SE
收藏

从Stack Overflow上的Crowd Knowledge引导API的Cookbooks

Bootstrapping Cookbooks for APIs from Crowd Knowledge on Stack Overflow

Lucas B. L. Souza, Eduardo C. Campos, Fernanda Madeiral, Klérisson Paixão, Adriano M. Rocha, Marcelo de Almeida Maia

摘要:

成熟的库通常都有API文档。然而,它们经常缺乏示例和解释,可能难以有效地重用它们。Stack Overflow是一个面向软件开发相关问题的问答网站。尽管越来越多地采用堆栈溢出,但与特定主题相关的信息(例如,API)分布在整个网站上。因此,Stack Overflow仍然缺乏对现有群众知识的组织。我们的目标是通过提供一个替代工件来解决API文档质量差的问题,该工件基于Stack Overflow上可用的群众知识来记录API,称为群众食谱。烹饪书是一本以食谱为导向的书,我们将我们的烹饪书称为人群烹饪书,因为它包含了人群生成的内容。烹饪书的目的是通过探索过程来使用,即浏览。在本文中,我们提出了一种半自动的方法,该方法组织了Stack Overflow上可用的人群知识,以构建API的食谱。我们已经为软件开发社区广泛使用的三种API生成了食谱:SWT,LINQ和QT。我们还定义了人群食谱必须满足的期望属性,并且我们对人类受试者的食谱进行了评估。结果表明,使用我们的方法构建的食谱,一般来说,满足这些属性。作为一个亮点,大多数食谱被认为是适当的,在食谱和有自我包含的信息。我们的结论是,我们的方法是能够自动生成足够的食谱,这可以是手动制作的食谱一样有用。这为API设计者提供了一个机会,可以用来自人群的不同观点来丰富现有的食谱,甚至可以生成新食谱的初始版本。

英文摘要:

Well established libraries typically have API documentation. However, they frequently lack examples and explanations, possibly making difficult their effective reuse. Stack Overflow is a question-and-answer website oriented to issues related to software development. Despite the increasing adoption of Stack Overflow, the information related to a particular topic (e.g., an API) is spread across the website. Thus, Stack Overflow still lacks organization of the crowd knowledge available on it. Our target goal is to address the problem of the poor quality documentation for APIs by providing an alternative artifact to document them based on the crowd knowledge available on Stack Overflow, called crowd cookbook. A cookbook is a recipe-oriented book, and we refer to our cookbook as crowd cookbook since it contains content generated by a crowd. The cookbooks are meant to be used through an exploration process, i.e. browsing. In this paper, we present a semi-automatic approach that organizes the crowd knowledge available on Stack Overflow to build cookbooks for APIs. We have generated cookbooks for three APIs widely used by the software development community: SWT, LINQ and QT. We have also defined desired properties that crowd cookbooks must meet, and we conducted an evaluation of the cookbooks against these properties with human subjects. The results showed that the cookbooks built using our approach, in general, meet those properties. As a highlight, most of the recipes were considered appropriate to be in the cookbooks and have self-contained information. We concluded that our approach is capable to produce adequate cookbooks automatically, which can be as useful as manually produced cookbooks. This opens an opportunity for API designers to enrich existent cookbooks with the different points of view from the crowd, or even to generate initial versions of new cookbooks.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑