首页 | 本学科首页   官方微博 | 高级检索  
     


Graph Embedding Based API Graph Search and Recommendation
Authors:Chun-Yang Ling  Yan-Zhen Zou  Ze-Qi Lin  Bing Xie
Affiliation:1.Key Laboratory of High Confidence Software Technologies, Ministry of Education, Beijing 100871, China;2.School of Electronics Engineering and Computer Science, Peking University, Beijing 100871, China
Abstract:Searching application programming interfaces (APIs) is very important for developers to reuse software projects. Existing natural language based API search mainly faces the following challenges. 1) More accurate results are required as software projects evolve to be more heterogeneous and complex. 2) The semantic relationships between APIs (e.g., inheritances between classes, and invocations between methods) need to be illustrated so that developers can better understand their usage scenarios. To deal with these issues, we propose GeAPI, a novel graph embedding based approach for API graph search and recommendation in this paper. First, we build a software project's API graph automatically from its source code and represent each API using graph embedding methods. Second, we search the API graph with a question in natural language, and return the corresponding subgraph that is composed of relevant code elements and their associated relationships, as the best answer of the question. In experiments, we select three well-known open source projects, JodaTime, Apache Lucene and POI, as examples to perform API search tasks. The experimental results show that our approach GeAPI improves F1-score by 10% compared with the existing shortest path based API search approach, while reduces the average response time about 60 times.
Keywords:application programming interface (API) recommendation  API graph  graph embedding  software reuse  
点击此处可从《计算机科学技术学报》浏览原始摘要信息
点击此处可从《计算机科学技术学报》下载全文
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号