API recommendation for event-driven Android application development
Context: Software development is increasingly dependent on existing libraries. Developers need help to find suitable library APIs. Although many studies have been proposed to recommend relevant functional APIs that can be invoked for implementing a functionality, few studies have paid attention to a...
Saved in:
Main Authors: | , , , , , |
---|---|
Format: | text |
Language: | English |
Published: |
Institutional Knowledge at Singapore Management University
2019
|
Subjects: | |
Online Access: | https://ink.library.smu.edu.sg/sis_research/4284 https://ink.library.smu.edu.sg/context/sis_research/article/5287/viewcontent/main_R3_highlighted.pdf |
Tags: |
Add Tag
No Tags, Be the first to tag this record!
|
Institution: | Singapore Management University |
Language: | English |
id |
sg-smu-ink.sis_research-5287 |
---|---|
record_format |
dspace |
spelling |
sg-smu-ink.sis_research-52872020-03-31T06:10:05Z API recommendation for event-driven Android application development YUAN, Weizhao NGUYEN, Huu Hoang JIANG, Lingxiao CHEN, Yuting ZHAO, Jianjun YU, Haibo Context: Software development is increasingly dependent on existing libraries. Developers need help to find suitable library APIs. Although many studies have been proposed to recommend relevant functional APIs that can be invoked for implementing a functionality, few studies have paid attention to an orthogonal need associated with event-driven programming frameworks, such as the Android framework. In addition to invoking functional APIs, Android developers need to know where to place functional code according to various events that may be triggered within the framework.Objective: This paper aims to develop an API recommendation engine for Android application development that can recommend both (1) functional APIs for implementing a functionality and (2) the event callback APIs that are to be overridden to contain the functional code.Method: We carry out an empirical study on actual Android programming questions from StackOverflow to confirm the need of recommending callbacks. Then we build Android-specific API databases to contain the correlations among various functionalities and APIs, based on customized parsing of code snippets and natural language processing of texts in Android tutorials and SDK documents, and then textual and code similarity metrics are adapted for recommending relevant APIs.Results: We have evaluated our prototype recommendation engine, named LibraryGuru, with about 1500 questions on Android programming from StackOverflow, and demonstrated that our top-5 results on recommending callbacks and functional APIs can on estimate achieve up to 43.5% and 50.9% respectively in precision, 24.6% and 32.5% respectively in mean average precision (MAP) scores, and 51.1% and 44.0% respectively in recall.Conclusion: We conclude that it is important and possible to recommend both functional APIs and callbacks for Android application development, and future work is needed to take more data sources into consideration to make more relevant recommendations for developers’ needs. 2019-03-01T08:00:00Z text application/pdf https://ink.library.smu.edu.sg/sis_research/4284 info:doi/10.1016/j.infsof.2018.10.010 https://ink.library.smu.edu.sg/context/sis_research/article/5287/viewcontent/main_R3_highlighted.pdf http://creativecommons.org/licenses/by-nc-nd/4.0/ Research Collection School Of Computing and Information Systems eng Institutional Knowledge at Singapore Management University Android programming event callbacks code search API recommendation information retrieval Software Engineering |
institution |
Singapore Management University |
building |
SMU Libraries |
continent |
Asia |
country |
Singapore Singapore |
content_provider |
SMU Libraries |
collection |
InK@SMU |
language |
English |
topic |
Android programming event callbacks code search API recommendation information retrieval Software Engineering |
spellingShingle |
Android programming event callbacks code search API recommendation information retrieval Software Engineering YUAN, Weizhao NGUYEN, Huu Hoang JIANG, Lingxiao CHEN, Yuting ZHAO, Jianjun YU, Haibo API recommendation for event-driven Android application development |
description |
Context: Software development is increasingly dependent on existing libraries. Developers need help to find suitable library APIs. Although many studies have been proposed to recommend relevant functional APIs that can be invoked for implementing a functionality, few studies have paid attention to an orthogonal need associated with event-driven programming frameworks, such as the Android framework. In addition to invoking functional APIs, Android developers need to know where to place functional code according to various events that may be triggered within the framework.Objective: This paper aims to develop an API recommendation engine for Android application development that can recommend both (1) functional APIs for implementing a functionality and (2) the event callback APIs that are to be overridden to contain the functional code.Method: We carry out an empirical study on actual Android programming questions from StackOverflow to confirm the need of recommending callbacks. Then we build Android-specific API databases to contain the correlations among various functionalities and APIs, based on customized parsing of code snippets and natural language processing of texts in Android tutorials and SDK documents, and then textual and code similarity metrics are adapted for recommending relevant APIs.Results: We have evaluated our prototype recommendation engine, named LibraryGuru, with about 1500 questions on Android programming from StackOverflow, and demonstrated that our top-5 results on recommending callbacks and functional APIs can on estimate achieve up to 43.5% and 50.9% respectively in precision, 24.6% and 32.5% respectively in mean average precision (MAP) scores, and 51.1% and 44.0% respectively in recall.Conclusion: We conclude that it is important and possible to recommend both functional APIs and callbacks for Android application development, and future work is needed to take more data sources into consideration to make more relevant recommendations for developers’ needs. |
format |
text |
author |
YUAN, Weizhao NGUYEN, Huu Hoang JIANG, Lingxiao CHEN, Yuting ZHAO, Jianjun YU, Haibo |
author_facet |
YUAN, Weizhao NGUYEN, Huu Hoang JIANG, Lingxiao CHEN, Yuting ZHAO, Jianjun YU, Haibo |
author_sort |
YUAN, Weizhao |
title |
API recommendation for event-driven Android application development |
title_short |
API recommendation for event-driven Android application development |
title_full |
API recommendation for event-driven Android application development |
title_fullStr |
API recommendation for event-driven Android application development |
title_full_unstemmed |
API recommendation for event-driven Android application development |
title_sort |
api recommendation for event-driven android application development |
publisher |
Institutional Knowledge at Singapore Management University |
publishDate |
2019 |
url |
https://ink.library.smu.edu.sg/sis_research/4284 https://ink.library.smu.edu.sg/context/sis_research/article/5287/viewcontent/main_R3_highlighted.pdf |
_version_ |
1770574599536246784 |