Causal discovery from time series is critical for many real-world applications, such as tracing the root causes of anomalies. Existing approaches typically rely on dataset-specific optimization, making it difficult to transfer their causal discovery capabilities to new time series governed by diverse causal mechanisms. In this paper, we propose \textbf{PTCD}, a novel \textbf{P}retraining framework for \textbf{T}ime-series \textbf{C}ausal \textbf{D}iscovery, which improves cross-task generalization through context-conditioned modeling and transferable causal augmentation. To model complex temporal causal dependencies, PTCD employs a dual-scale iterative attention mechanism to capture window-level causal relationships, and a Gaussian mixture with a context-level routing mechanism to handle heterogeneous exogenous distributions. To further address distribution shifts across causal graphs, PTCD adopts a pretraining paradigm on synthetic datasets that integrates intervention-based learning and a causal mixup strategy, promoting stable causal discovery and stronger generalization. Extensive experiments on multiple real-world out-of-distribution (OOD) datasets demonstrate that PTCD excels in both causal discovery and root cause identification.
翻译:从时间序列中发现因果关系对许多现实应用(如追溯异常的根本原因)至关重要。现有方法通常依赖数据集特定的优化,这使其难以将因果发现能力迁移到受不同因果机制支配的新时间序列上。本文提出 **PTCD**,一种新颖的时间序列因果发现**预训练框架**,通过上下文条件建模和可迁移的因果增强来提升跨任务泛化能力。为建模复杂的时间因果依赖关系,PTCD 采用双尺度迭代注意力机制捕捉窗口级因果关系,并利用具有上下文级路由机制的高斯混合模型处理异质的外生分布。为进一步应对因果图之间的分布偏移,PTCD 采用基于合成数据集的预训练范式,该范式整合了干预学习和因果混合策略,从而促进稳定的因果发现和更强的泛化能力。在多个真实世界分布外(OOD)数据集上的广泛实验表明,PTCD 在因果发现和根因识别方面均表现出色。