TY - JOUR
T1 - DiffHGCL
T2 - Task-aware diffusion-augmented heterogeneous graph contrastive learning for web API recommendation
AU - Yang, Xiuqi
AU - Xu, Xiaojun
AU - Du, Wenbiao
AU - Liu, Zeyang
AU - Chen, Junbao
AU - Fu, Yifeng
AU - Hu, Jingjing
N1 - Publisher Copyright:
© 2026 Elsevier Ltd. All rights are reserved, including those for text and data mining, AI training, and similar technologies.
PY - 2026/12/15
Y1 - 2026/12/15
N2 - The rapidly increasing popularity of mashup-based applications has led to a surge in the number of available Web APIs, making effective recommendations essential yet challenging. Some recent efforts have explored generative methods such as diffusion models to synthesize potential interactions between mashups and APIs, thereby alleviating data sparsity issues. Although they have been shown to be effective in generating statistically plausible interactions, these methods often overlook the misalignment between generative objectives and relevance-oriented recommendation goals.In this paper, we first investigate diffusion-based generation for Web API recommendation and reveal a fundamental task misalignment phenomenon: diffusion-generated confidence is highly influenced by popularity bias and does not reliably translate into ranking relevance. Motivated by this finding, we propose DiffHGCL, a task-aware multi-view heterogeneous graph contrastive learning framework that integrates diffusion-based augmentation with task-aware interaction proposal filtering. Specifically, we first construct multi-view graphs that capture both functional affinity and semantic proximity among mashups and APIs, thereby enriching the sparse interaction graph with auxiliary semantic information. Building upon these views, we employ diffusion models as task-conditioned interaction proposal generators rather than direct recommenders, and introduce a task-aware interaction proposal filtering mechanism to filter task-irrelevant generative bias. Furthermore, heterogeneous graph contrastive learning is leveraged as a regularizer to align representations across augmented views, enhancing robustness against sparsity and noise. Extensive experiments on ProgrammableWeb dataset demonstrate that DiffHGCL consistently outperforms state-of-the-art baselines, highlighting its effectiveness in alleviating data sparsity and enhancing representational robustness. The source code is available at https://github.com/Qornck/DiffHGCL.
AB - The rapidly increasing popularity of mashup-based applications has led to a surge in the number of available Web APIs, making effective recommendations essential yet challenging. Some recent efforts have explored generative methods such as diffusion models to synthesize potential interactions between mashups and APIs, thereby alleviating data sparsity issues. Although they have been shown to be effective in generating statistically plausible interactions, these methods often overlook the misalignment between generative objectives and relevance-oriented recommendation goals.In this paper, we first investigate diffusion-based generation for Web API recommendation and reveal a fundamental task misalignment phenomenon: diffusion-generated confidence is highly influenced by popularity bias and does not reliably translate into ranking relevance. Motivated by this finding, we propose DiffHGCL, a task-aware multi-view heterogeneous graph contrastive learning framework that integrates diffusion-based augmentation with task-aware interaction proposal filtering. Specifically, we first construct multi-view graphs that capture both functional affinity and semantic proximity among mashups and APIs, thereby enriching the sparse interaction graph with auxiliary semantic information. Building upon these views, we employ diffusion models as task-conditioned interaction proposal generators rather than direct recommenders, and introduce a task-aware interaction proposal filtering mechanism to filter task-irrelevant generative bias. Furthermore, heterogeneous graph contrastive learning is leveraged as a regularizer to align representations across augmented views, enhancing robustness against sparsity and noise. Extensive experiments on ProgrammableWeb dataset demonstrate that DiffHGCL consistently outperforms state-of-the-art baselines, highlighting its effectiveness in alleviating data sparsity and enhancing representational robustness. The source code is available at https://github.com/Qornck/DiffHGCL.
KW - Contrastive learning
KW - Diffusion models
KW - Heterogeneous graph neural networks
KW - Web API recommendation
UR - https://www.scopus.com/pages/publications/105043207139
U2 - 10.1016/j.eswa.2026.133349
DO - 10.1016/j.eswa.2026.133349
M3 - Article
AN - SCOPUS:105043207139
SN - 0957-4174
VL - 331
JO - Expert Systems with Applications
JF - Expert Systems with Applications
M1 - 133349
ER -