Lune

KDD2026Top-tier venue

Both Topology and Text Matter: Revisiting LLM-guided Out-of-Distribution Detection on Text-attributed Graphs

Yinlin Zhu, Di Wu, Xu Wang, Guocong Quan, Miao Hu

Abstract

Text-attributed graphs (TAGs) associate nodes with textual attributes and graph structure, enabling GNNs to jointly model semantic and structural information. Although effective on in-distribution (ID) data, GNNs often fail on out-of-distribution (OOD) nodes with unseen textual or structural patterns, producing overconfident predictions without reliable OOD detection. Existing topology-driven methods mitigate node-level bias through neighboring structures, but typically encode texts as shallow features, underutilizing semantic information. Recent LLM-based approaches instead synthesize pseudo OOD priors from textual knowledge, yet suffer from two key limitations: (1) a trade-off between reliability and informativeness, where generated OOD exposures either deviate from true OOD semantics or introduce substantial ID noise; and (2) dependence on specialized architectures, limiting compatibility with topology-level advances validated in prior work. To address these issues, we propose LG-Plug, an LLM-Guided Plug-and-play framework for TAG OOD detection. LG-Plug aligns topology and text representations to obtain fine-grained node embeddings, then constructs consensus-driven OOD exposure through clustered iterative LLM prompting. To reduce LLM query cost, it further adopts lightweight in-cluster codebooks and heuristic sampling. The generated OOD exposure acts as a regularizer that separates ID and OOD nodes, enabling seamless integration with existing detectors. Experiments on six TAG benchmarks demonstrate that LG-Plug consistently improves topology-driven OOD detectors (⩾7% FPR95 reduction) and surpasses prior LLM-based methods (⩾5% FPR95 reduction).

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

Questions to start from

Lune can draw on

the full paper · related work

Get the answer

Free to start. No credit card required.

Lineage

  • One For All: Towards Training One Graph Model For All Classification Tasks cites GraphGPT: Graph Instruction Tuning for Large Language Models
  • One For All: Towards Training One Graph Model For All Classification Tasks cites Can Language Models Solve Graph Problems in Natural Language?
Builds onCited byLeft to right by year; the more cited, the higher.

Builds on18

  1. Energy-based Out-of-distribution DetectionWeitang Liu, Xiaoyun Wang, John D. Owens, Yixuan LiNeurIPS 2020 · 2,213 citations
  2. Can Language Models Solve Graph Problems in Natural Language?Heng Wang, Shangbin Feng, Tianxing He, Zhaoxuan Tan et al.NeurIPS 2023 · 420 citations
  3. One For All: Towards Training One Graph Model For All Classification TasksHao Liu, Jiarui Feng, Lecheng Kong, Ningyue Liang et al.ICLR 2024 · 253 citations
  4. GraphGPT: Graph Instruction Tuning for Large Language ModelsJiabin Tang, Yuhao Yang, Wei Wei, Lei Shi et al.SIGIR 2024 · 182 citations
  5. Uncertainty Aware Semi-Supervised Learning on Graph DataXujiang Zhao, Feng Chen, Shu Hu, Jin-Hee ChoNeurIPS 2020 · 178 citations

Related papers

  1. Out-of-Distribution Detection via LLM-Guided Outlier Generation for Text-attributed GraphXiangwei Lv, Mengze Li, Jingyuan Chen, Zhiang Dong et al.ACL Findings 2025 · 4 citations
  2. Compressing LLM Knowledge into Graph Representations for Text-attributed Graphs LearningRunhuai Chen, Dian Shen, Dandan Zhang, Kaihong Huang et al.ACL 2026
  3. LLM-Enhanced Energy Contrastive Learning for Out-of-Distribution Detection in Text-Attributed GraphsXiaoxu Ma, Dong Li, Minglai Shao, Xintao Wu et al.AAAI 2026
  4. GraphTextack: A Realistic Black-Box Node Injection Attack on LLM-Enhanced GNNsJiaji Ma, Puja Trivedi, Danai KoutraAAAI 2026
  5. Generalization Principles for Inference over Text-Attributed Graphs with Large Language ModelsHaoyu Peter Wang, Shikun Liu, Rongzhe Wei, Pan LiICML 2025
Dusk over the sea between two cliffs drawn in fine vertical lines