arXiv:2505.19547cs.LGcs.AI2025-05NeurIPS被引 10

通过检索时空模式提升模型在分布外场景的泛化能力

STRAP: Spatio-Temporal Pattern Retrieval for Out-of-Distribution Generalization

  • 构建包含历史、结构和语义信息的时空模式库,支持动态检索
  • 在推理时注入相似模式,显著提升多数据集上的泛化性能
  • 无需微调即可适应新场景,适合实时流式图数据应用

时空图神经网络(STGNN)在建模动态图数据方面表现强大,但在时空分布外(STOOD)场景中常出现泛化失败问题。为此,本文提出一种新型的时空检索增强模式学习框架STRAP,将检索增强学习融入STGNN的持续学习流程。其核心是一个紧凑且表达力强的模式库,存储了包含历史、结构和语义信息的代表性时空模式,该模式库在训练阶段被构建并优化。推理时,STRAP基于当前输入与模式库中的相似性检索相关模式,并通过即插即用的提示机制注入模型,强化时空表征并缓解灾难性遗忘。此外,引入知识平衡目标以协调新知识与检索知识。在多个真实世界流式图数据集上的大量实验表明,STRAP在多种STOOD任务中均优于现有SOTA STGNN基线,展现出强鲁棒性、高适应性和无需任务微调的优异泛化能力。

原文摘要 · Abstract (English)

Spatio-Temporal Graph Neural Networks (STGNNs) have emerged as a powerful tool for modeling dynamic graph-structured data across diverse domains. However, they often fail to generalize in Spatio-Temporal Out-of-Distribution (STOOD) scenarios, where both temporal dynamics and spatial structures evolve beyond the training distribution. To address this problem, we propose an innovative Spatio-Temporal Retrieval-Augmented Pattern Learning framework,STRAP, which enhances model generalization by integrating retrieval-augmented learning into the STGNN continue learning pipeline. The core of STRAP is a compact and expressive pattern library that stores representative spatio-temporal patterns enriched with historical, structural, and semantic information, which is obtained and optimized during the training phase. During inference, STRAP retrieves relevant patterns from this library based on similarity to the current input and injects them into the model via a plug-and-play prompting mechanism. This not only strengthens spatio-temporal representations but also mitigates catastrophic forgetting. Moreover, STRAP introduces a knowledge-balancing objective to harmonize new information with retrieved knowledge. Extensive experiments across multiple real-world streaming graph datasets show that STRAP consistently outperforms state-of-the-art STGNN baselines on STOOD tasks, demonstrating its robustness, adaptability, and strong generalization capability without task-specific fine-tuning.

时空建模分布外泛化模式检索图神经网络

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。