Skip to main content
Log in

A novel knowledge graph embedding based API recommendation method for Mashup development

  • Published:
World Wide Web Aims and scope Submit manuscript

Abstract

Web API is an efficient and cost-effective method for service-oriented software development, and Mashup is a popular technology which combines multiple services to create more powerful services to address the increasing complexity of business requirements and speed up the software development process. Here, accurate and efficient API recommendation is vital for successful Mashup development. Currently, many existing methods combine various technologies and adopt diverse features, which results in complex models at the cost of higher computational overhead but with very limited improvement on recommendation accuracy. To address such an issue, in this paper, we propose an unsupervised API recommendation method based on deep random walks on knowledge graph. Specifically, we first construct a refined knowledge graph utilizing Mashup-API co-invocation patterns and service category attributes, and then we learn implicit low-dimensional embedding representations of entities from truncated random walks by treating walks as the equivalent of sentences. Meanwhile, to improve the recommendation accuracy, we design an entity bias procedure to reflect different entity preference (namely API-based neighborhood or Mashup-based neighborhood). Finally, we estimate the relevance between Mashup requirements and the existing services (Mashups and APIs) to obtain the API recommendation list. Since the API recommendation results can be obtained through unsupervised feature learning, automatic API recommendation can be provided for Mashup developers in real time. Comprehensive experimental results on a real-world dataset demonstrate that our proposed method can outperform several state-of-the-art methods in both recommendation accuracy and efficiency.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6

Similar content being viewed by others

Notes

  1. https://www.programmableweb.com/

  2. http://rtw.ml.cmu.edu/rtw/

  3. http://wiki.dbpedia.org/

  4. https://developers.google.cn/knowledge-graph/

  5. https://searchengineland.com/library/bing/bing-satori

  6. http://globebop.com/web

  7. https://developers.google.com/maps/

  8. http://www.mediawiki.org/wiki/API

  9. http://www.nltk.org/

References

  1. Bai, B., Fan, Y., Tan, W., Zhang, J.: Dltsr: A deep learning framework for recommendations of long-tail Web services. IEEE Trans. Serv. Comput. 13(1), 73–85 (2017)

    Article  Google Scholar 

  2. Barros, A. P., Dumas, M.: The rise of Web service ecosystems. Science and Engineering Faculty (2006)

  3. Botangen, K. A., Yu, J., Sheng, Q. Z., Han, Y., Yongchareon, S.: Geographic-aware collaborative filtering for Web service recommendation. Exp. Sys. App. 151, 113347 (2020)

    Article  Google Scholar 

  4. Bouguettaya, A., Singh, M., Huhns, M.: A service computing manifesto: the next 10 years. Commun. ACM 60(4), 64–72 (2017)

    Article  Google Scholar 

  5. Cao, B., Li, B., Liu, J., Tang, M., Liu, Y.: Web apis recommendation for mashup development based on hierarchical dirichlet process and factorization machines. In: International Conference on Collaborative Computing: Networking, Applications and Worksharing, pp. 3–15 (2016)

  6. Cao, B., Liu, X., Rahman, M., Li, B., Liu, J., Tang, M.: Integrated content and network-based service clustering and Web apis recommendation for mashup development. IEEE Trans. Serv. Comput. 13(1), 99–113 (2017)

    Article  Google Scholar 

  7. Cao, Y., Liu, J., Shi, M., Cao, B., Chen, T., Wen, Y.: Service recommendation based on attentional factorization machine. In: 2019 IEEE International Conference on Services Computing (SCC), pp 189–196 (2019)

  8. Chen, S., Fan, Y., Tan, W., Zhang, J., Bai, B., Gao, Z.: Time-aware collaborative poisson factorization for service recommendation. In: 2016 IEEE International Conference on Web Services (ICWS), pp. 196–203 (2016)

  9. Dojchinovski, M., Vitvar, T.: Linked Web apis dataset. Sprachwissenschaft 9(4), 381–391 (2017)

    Google Scholar 

  10. Firmenich, S., Bosetti, G., Rossi, G., Winckler, M.: End-user software engineering for the personal Web: poster. In: 2017 IEEE/ACM 39th International Conference on Software Engineering Companion (ICSE-C), pp. 216–218 (2017)

  11. Fletcher, K.: Regularizing matrix factorization with implicit user preference embeddings for Web api recommendation. In: 2019 IEEE International Conference on Services Computing (SCC), pp. 1–8 (2019)

  12. Hao, Y., Fan, Y., Tan, W., Zhang, J.: Service recommendation based on targeted reconstruction of service descriptions. In: 2017 IEEE International Conference on Web Services (ICWS), pp. 285–292 (2017)

  13. Haveliwala, T.: Topic-sensitive pagerank: a context-sensitive ranking algorithm for Web search. IEEE Trans. Knowl. Data Eng. 15(4), 784–796 (2003)

    Article  Google Scholar 

  14. Jiang, H., Zhou, R., Zhang, L., Wang, H., Zhang, Y.: Sentence level topic models for associated topics extraction. World Wide Web 22(6), 2545–2560 (2019)

    Article  Google Scholar 

  15. Kang, G., Liu, J., Cao, B., Cao, M.: Nafm: Neural and attentional factorization machine for Web api recommendation. In: 2020 IEEE International Conference on Web Services (ICWS) (2020)

  16. Konstas, I., Stathopoulos, V., Jose, J. M.: On social networks and collaborative recommendation. In: Proceedings of the 32nd international ACM SIGIR conference on Research and development in information retrieval, pp. 195–202 (2009)

  17. Le, Q., Mikolov, T.: Distributed representations of sentences and documents. In: Proceedings of The 31st International Conference on Machine Learning, pp. 1188–1196 (2014)

  18. Liu, H., Jing, L., Wen, J., Wu, Z., Sun, X., Wang, J., Xiao, L., Yu, J.: Deep global and local generative model for recommendation. In: Proceedings of The Web Conference 2020, pp. 551–561 (2020)

  19. Meng, S., Li, Q., Chen, S., Yu, S., Qi, L., Lin, W., Xu, X., Dou, W.: Temporal-sparsity aware service recommendation method via hybrid collaborative filtering techniques. In: International Conference on Service-Oriented Computing, pp. 421–429 (2018)

  20. Mikolov, T., Chen, K., Corrado, G. S., Dean, J.: Efficient estimation of word representations in vector space. In: ICLR (Workshop Poster) (2013)

  21. Mnih, A., Hinton, G. E.: A scalable hierarchical distributed language model. In: Advances in Neural Information Processing Systems 21, pp. 1081–1088 (2008)

  22. Morin, F., Bengio, Y.: Hierarchical probabilistic neural network language model. In: AISTATS (2005)

  23. Onrust, L., van den Bosch, A., hamme, H. V.: Improving cross-domain n-gram language modelling with skipgrams. In: Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), vol. 2, pp 137–142 (2016)

  24. Peng, M., Zeng, G., Sun, Z., Huang, J., Wang, H., Tian, G.: Personalized app recommendation based on app permissions. World Wide Web 21(1), 89–104 (2018)

    Article  Google Scholar 

  25. Perozzi, B., Al-Rfou, R., Skiena, S.: Deepwalk: online learning of social representations. In: Proceedings of the 20th ACM SIGKDD international conference on Knowledge discovery and data mining, pp. 701–710 (2014)

  26. Qi, L., He, Q., Chen, F., Dou, W., Wan, S., Zhang, X., Xu, X.: Finding all you need: Web apis recommendation in Web of things through keywords search. IEEE Transactions on Computational Social Systems 6 (5), 1063–1072 (2019)

    Article  Google Scholar 

  27. Rahman, M., Liu, X., Cao, B.: Web api recommendation for mashup development using matrix factorization on integrated content and network-based service clustering. In: 2017 IEEE International Conference on Services Computing (SCC), pp. 225–232 (2017)

  28. Rangarajan, S., Liu, H., Wang, H.: Web service qos prediction using improved software source code metrics. PLOS ONE 15(1) (2020)

  29. Rosen-Zvi, M., Griffiths, T., Steyvers, M., Smyth, P.: The author-topic model for authors and documents. In: UAI ’04 Proceedings of the 20th conference on Uncertainty in artificial intelligence, pp. 487–494 (2004)

  30. Shi, M., Tang, Y., Liu, J.: Ta-blstm: Tag attention-based bidirectional long short-term memory for service recommendation in mashup creation. In: 2019 International Joint Conference on Neural Networks (IJCNN), pp. 1–8 (2019)

  31. Tan, W., Fan, Y., Ghoneim, A., Hossain, M. A., Dustdar, S.: From the service-oriented architecture to the Web api economy. IEEE Internet Computing 20(4), 64–68 (2016)

    Article  Google Scholar 

  32. Tang, J., Qu, M., Wang, M., Zhang, M., Yan, J., Mei, Q.: Line: Large-scale information network embedding. In: Proceedings of the 24th International Conference on World Wide Web, pp. 1067–1077 (2015)

  33. Wang, H., Wang, Z., Zhang, W.: Quantitative analysis of matthew effect and sparsity problem of recommender systems. In: 2018 IEEE 3rd International Conference on Cloud Computing and Big Data Analysis (ICCCBDA), pp 78–82. IEEE (2018)

  34. Wang, H., Zhang, F., Xie, X., Guo, M.: Dkn: Deep knowledge-aware network for news recommendation. In: WWW ’18 Proceedings of the 2018 World Wide Web Conference, pp. 1835–1844 (2018)

  35. Wang, J., Wang, Z., Zhang, D., Yan, J.: Combining knowledge with deep convolutional neural networks for short text classification. In: Twenty-Sixth International Joint Conference on Artificial Intelligence, pp. 2915–2921 (2017)

  36. Wang, X., He, X., Wang, M., Feng, F., Chua, T. S.: Neural graph collaborative filtering. In: Proceedings of the 42nd international ACM SIGIR conference on Research and development in Information Retrieval, pp. 165–174 (2019)

  37. Wang, X., Wu, H., Hsu, C. H.: Mashup-oriented api recommendation via random walk on knowledge graph. IEEE Access 7, 7651–7662 (2019)

    Article  Google Scholar 

  38. Wang, Z. J., Zhan, Z. H., Lin, Y., Yu, W. J., Wang, H., Kwong, S., Zhang, J.: Automatic niching differential evolution with contour prediction approach for multimodal optimization problems. IEEE Trans. Evol. Comput. 24(1), 114–128 (2020)

    Article  Google Scholar 

  39. Xia, B., Fan, Y., Tan, W., Huang, K., Zhang, J., Wu, C.: Category-aware api clustering and distributed recommendation for automatic mashup creation. IEEE Trans. Serv. Comput. 8(5), 674–687 (2014)

    Article  Google Scholar 

  40. Xiao, Y., Liu, J., Hu, R., Cao, B., Cao, Y.: Dinrec: Deep interest network based api recommendation approach for mashup creation. In: International Conference on Web Information Systems Engineering, pp. 179–193 (2020)

  41. Xie, F., Li, S., Chen, L., Xu, Y., Zheng, Z.: Generative adversarial network based service recommendation in heterogeneous information networks. In: 2019 IEEE International Conference on Web Services (ICWS), pp. 265–272 (2019)

  42. Xiong, R., Wang, J., Zhang, N., Ma, Y.: Deep hybrid collaborative filtering for Web service recommendation. Exp. Sys. Appl. 110, 191–205 (2018)

    Article  Google Scholar 

  43. Xu, W., Cao, J., Hu, L., Wang, J., Li, M.: A social-aware service recommendation approach for mashup creation. In: 2013 IEEE 20th International Conference on Web Services, pp. 107–114 (2013)

  44. Yang, B., Mitchell, T. M.: Leveraging knowledge bases in lstms for improving machine reading. In: Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), vol. 1, pp 1436–1446 (2017)

  45. Yao, L., Wang, X., Sheng, Q. Z., Benatallah, B., Huang, C.: Mashup recommendation by regularizing matrix factorization with api co-invocations. IEEE Trans. Serv. Comput.: 1–1 (2018)

  46. Zhang, Y., Yin, C., Wu, Q., He, Q., Zhu, H.: Location-aware deep collaborative filtering for service recommendation. IEEE Trans. Sys. Man Cybern., 1–12 (2020)

  47. Zhao, H., Wang, J., Zhou, Q., Wang, X., Wu, H.: Web api recommendation with features ensemble and learning-to-rank. CCF Conference on Big Data, 406–419 (2019)

  48. Zheng, Z., Ma, H., Lyu, M. R., King, I.: Wsrec: A collaborative filtering based Web service recommender system. In: 2009 IEEE International Conference on Web Services, pp. 437–444 (2009)

  49. Zhong, Y., Fan, Y., Tan, W., Zhang, J.: Web service recommendation with reconstructed profile from mashup descriptions. IEEE Trans. Autom. Sci. Eng. 15(2), 468–478 (2016)

    Article  Google Scholar 

Download references

Acknowledgment

This work was supported by the grands of the National Natural Science Foundation of China (61972290, 61962061, 61966037, 61463052, U1802271), supported by the Open Fund of Key Laboratory of Network Assessment Technology from CAS, partially supported by the Yunnan Provincial Foundation for Leaders of Disciplines in Science and Technology(202005AC160005), Top Young Talents of ”Ten Thousand Plan” in Yunnan Province(YNWR-QNBJ-2019-188), the Program for Excellent Young Talents of Yunnan University.

Author information

Authors and Affiliations

Authors

Corresponding authors

Correspondence to Jin Liu or Hao Wu.

Additional information

Publisher’s note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Wang, X., Liu, X., Liu, J. et al. A novel knowledge graph embedding based API recommendation method for Mashup development. World Wide Web 24, 869–894 (2021). https://doi.org/10.1007/s11280-021-00894-3

Download citation

  • Received:

  • Revised:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11280-021-00894-3

Keywords

Navigation