Exploiting Text Semantics for Few and Zero Shot Node Classification on Text-attributed Graph
Yuxiang Wang, Xiao Yan, Shiyu Jin, Quanqing Xu, Chuang Hu, Yuanyuan Zhu, Bo Du, Jia Wu, Jiawei Jiang
TL;DR
The paper tackles the challenge of few- and zero-shot node classification on text-attributed graphs by introducing Text Semantics Augmentation (TSA), which enriches supervision with semantic relationships in text. TSA combines a graph encoder, a text encoder, and a dedicated negative-text encoder, optimizing with three losses: $\mathcal{L}_{CL}$ (contrastive), $\mathcal{L}_{PSM}$ (positive semantics matching), and $\mathcal{L}_{NSC}$ (negative semantics contrast). It introduces a scalable text bank and a learnable negative prompt to mine diverse text semantics and enforce opposite semantics, improving robustness and accuracy in both few- and zero-shot settings; a probability-average inference strategy further leverages positive and negative cues. Empirically, TSA outperforms 13 baselines on five datasets, with average improvements of 4.6% (accuracy) and 6.9% (F1) in few-shot, and 8.8% (accuracy) and 9.3% (F1) in zero-shot, demonstrating the practical value of exploiting text semantics for TAG classification. The work advances the state of the art in TAGs by integrating semantic-rich text supervision into end-to-end training and inference, offering a scalable path to reliable classification with limited labeled data.
Abstract
Text-attributed graph (TAG) provides a text description for each graph node, and few- and zero-shot node classification on TAGs have many applications in fields such as academia and social networks. Existing work utilizes various graph-based augmentation techniques to train the node and text embeddings, while text-based augmentations are largely unexplored. In this paper, we propose Text Semantics Augmentation (TSA) to improve accuracy by introducing more text semantic supervision signals. Specifically, we design two augmentation techniques, i.e., positive semantics matching and negative semantics contrast, to provide more reference texts for each graph node or text description. Positive semantic matching retrieves texts with similar embeddings to match with a graph node. Negative semantic contrast adds a negative prompt to construct a text description with the opposite semantics, which is contrasted with the original node and text. We evaluate TSA on 5 datasets and compare with 13 state-of-the-art baselines. The results show that TSA consistently outperforms all baselines, and its accuracy improvements over the best-performing baseline are usually over 5%.
