An Unsupervised Approach for Discovering Relevant Tutorial Fragments for APIs

被引:55
作者
Jiang, He [1 ,2 ,3 ]
Zhang, Jingxuan [1 ]
Ren, Zhilei [1 ]
Zhang, Tao [4 ]
机构
[1] Dalian Univ Technol, Sch Software, Dalian, Peoples R China
[2] Key Lab Ubiquitous Network & Serv Software Liaoni, Dalian, Peoples R China
[3] Wuhan Univ, State Key Lab Software Engn, Wuhan, Hubei, Peoples R China
[4] Harbin Engn Univ, Coll Comp Sci & Technol, Harbin, Heilongjiang, Peoples R China
来源
2017 IEEE/ACM 39TH INTERNATIONAL CONFERENCE ON SOFTWARE ENGINEERING (ICSE) | 2017年
基金
中国国家自然科学基金;
关键词
Application Programming Interface; PageRank Algorithm; Topic Model; Unsupervised Approaches; DOCUMENTATION; KNOWLEDGE;
D O I
10.1109/ICSE.2017.12
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Developers increasingly rely on API tutorials to facilitate software development. However, it remains a challenging task for them to discover relevant API tutorial fragments explaining unfamiliar APIs. Existing supervised approaches suffer from the heavy burden of manually preparing corpus-specific annotated data and features. In this study, we propose a novel unsupervised approach, namely Fragment Recommender for APIs with PageRank and Topic model (FRAPT). FRAPT can well address two main challenges lying in the task and effectively determine relevant tutorial fragments for APIs. In FRAPT, a Fragment Parser is proposed to identify APIs in tutorial fragments and replace ambiguous pronouns and variables with related ontologies and API names, so as to address the pronoun and variable resolution challenge. Then, a Fragment Filter employs a set of non-explanatory detection rules to remove non-explanatory fragments, thus address the non-explanatory fragment identification challenge. Finally, two correlation scores are achieved and aggregated to determine relevant fragments for APIs, by applying both topic model and PageRank algorithm to the retained fragments. Extensive experiments over two publicly open tutorial corpora show that, FRAPT improves the state-of-the-art approach by 8.77% and 12.32% respectively in terms of F-Measure. The effectiveness of key components of FRAPT is also validated.
引用
收藏
页码:38 / 48
页数:11
相关论文
共 35 条
[1]  
Alias-i, 2008, LINGPIPE 4 1 0
[2]  
[Anonymous], PROC OOPSLA
[3]  
[Anonymous], 2004, ADAPTIVE COMPUTATION
[4]  
[Anonymous], 2006, Google's PageRank and beyond: The science of search engine rankings
[5]  
[Anonymous], 2005, P 6 ACM C ELECT COMM
[6]  
Cardie C, 2010, P C 48 ANN M ASS COM
[7]  
Chen C., COMP P 36 INT C SOFT, P456
[8]   Using Traceability Links to Recommend Adaptive Changes for Documentation Evolution [J].
Dagenais, Barthelemy ;
Robillard, Martin P. .
IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2014, 40 (11) :1126-1146
[9]  
Dagenais B, 2012, PROC INT CONF SOFTW, P47, DOI 10.1109/ICSE.2012.6227207
[10]  
David M. W., 2012, P C EUR CHAPT ASS CO