arXiv:2610.02990cs.LGOct 2026

Manuscript Offprint

arXiv:2610.02990

Differentiable Koopman Operator for Contrastive Learning on Dynamic Graphs

Md Abrar Jahin, Taufikur Rahman Fuad, Md Rizwan Parvez

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Real-world interaction networks are inherently dynamic: edges form and dissolve as node behavior shifts over time. Most snapshot-based contrastive methods encode temporal dependencies implicitly in encoder weights, without an explicit model of how node representations evolve, making them brittle under distribution shifts. We propose KAIROS (Koopman-Aligned Invariant Representations for Open Dynamic Systems), a self-supervised framework that embeds a differentiable Koopman operator within a dynamic graph contrastive learning loop to linearize temporal evolution in the learned embedding space. A dual-view encoder pairs raw node features with a graph-diffused structural view and is optimized with multi-granularity contrastive objectives across temporal windows. For anomaly detection, KAIROS uses the Koopman prediction residual together with temporal inconsistency and local neighborhood deviation to separate irregular behavior from predictable graph evolution. Evaluated on nine dynamic graph benchmarks, KAIROS achieves state-of-the-art anomaly detection results on all nine datasets, with gains of up to 23.15 ROC-AUC points over prior work, while remaining competitive for unsupervised node classification. These results show that explicit dynamics modeling provides a scalable and effective inductive bias for temporal graph representation learning.

1 Introduction

Real-world relational systems such as financial transaction networks, social platforms, and citation graphs are inherently dynamic. Dynamic Graph Representation Learning (DGRL) seeks node embeddings that capture structural dependencies and temporal evolution, enabling downstream tasks such as node classification, link prediction, and anomaly detection. Graph Neural Networks (GNNs) are well established for static graphs, but extending them to dynamic settings remains challenging.

Many dynamic-graph encoders model temporal evolution through architectural mechanisms and lack a transition operator that predicts how node embeddings evolve between snapshots. Snapshot-based models aggregate per-snapshot neighborhoods, while continuous-time models encode interactions through functional time encodings, causal anonymous walks, neighborhood/community influence aggregation, or frequency-domain temporal features [1, 2, 3, 4, 5]. These designs do not provide a parameterized one-step operator over node embeddings. Without such a model, predictable evolution and anomalous deviation are difficult to separate under distribution shift, where both may appear as movement in embedding space [6, 7, 8].

This limitation is amplified in self-supervised dynamic graph learning. Strong dynamic contrastive baselines such as CLDG and CLDG++ maximize agreement between temporal views [9, 10]. This provides a useful smoothness bias but does not model how representations evolve. When evolution is non-smooth, view agreement can penalize legitimate change and fail to isolate deviations. Existing dynamic graph anomaly detectors address temporal anomalies through dynamic embed-

Preprint.

dings, transformer-based spatiotemporal modeling, or semi-supervised pseudo-labeling [11, 12, 13]. However, they do not define anomaly scores as residuals of a learned transition operator.

Koopman operator theory offers a direct way to impose such a transition model: observables of nonlinear dynamical systems evolve linearly in an infinite-dimensional lifted space [14, 15]. Neural Koopman approximations have been used for forecasting, control, and sequence modeling through reconstruction, forecasting, or operator-regression objectives [16, 17, 18, 19, 20]. To our knowledge, no prior work couples a graph encoder and Koopman operator end-to-end under a contrastive objective, or uses the resulting Koopman residual as an unsupervised anomaly signal on dynamic graphs.

We propose KAIROS (Koopman-Aligned Invariant Representations for Open Dynamic Systems), a self-supervised framework that embeds a differentiable Koopman operator inside a dynamic graph contrastive learning loop. A dual-view GNN encoder processes raw features and a Personalized PageRank (PPR)-diffused view [21], and optimizes an InfoNCE objective across temporal windows. A linear operator K, initialized at the identity and regularized toward orthogonality, is co-optimized to predict each node's next-snapshot embedding. Initializing K = I makes the identity transition a special case of the learned operator, so any deviation from identity is loss-driven. The same encoder supports two downstream tasks without architectural change: (i) for unsupervised node classification, the Koopman regularizer is disabled and the frozen encoder feeds a linear probe; (ii) for unsupervised dynamic-graph anomaly detection, the Koopman prediction residual is combined with temporal inconsistency and local neighborhood deviation, each z-normalized, into a unified anomaly score.

Our main contributions are: (i) We couple a differentiable Koopman operator with self-supervised dynamic graph contrastive learning, jointly optimizing the graph encoder and linear temporal operator end-to-end. (ii) We introduce a dual-view contrastive objective over raw and PPR-diffused features, augmented with Koopman prediction and orthogonality regularization. (iii) We define a fully unsupervised anomaly score from temporal inconsistency, Koopman prediction residual, and neighborhood deviation, without pseudo-labels or reconstruction losses.

References (78)