Transition Propagation Graph Neural Networks for Temporal Networks
Researchers of temporal networks (e.g., social networks and transaction
networks) have been interested in mining dynamic patterns of nodes from their
diverse interactions.
  Inspired by recently powerful graph mining methods like skip-gram models and
Graph Neural Networks (GNNs), existing approaches focus on generating temporal
node embeddings sequentially with nodes' sequential interactions.
  However, the sequential modeling of previous approaches cannot handle the
transition structure between nodes' neighbors with limited memorization
capacity.
  Detailedly, an effective method for the transition structures is required to
both model nodes' personalized patterns adaptively and capture node dynamics
accordingly.
  In this paper, we propose a method, namely Transition Propagation Graph
Neural Networks (TIP-GNN), to tackle the challenges of encoding nodes'
transition structures.
  The proposed TIP-GNN focuses on the bilevel graph structure in temporal
networks: besides the explicit interaction graph, a node's sequential
interactions can also be constructed as a transition graph.
  Based on the bilevel graph, TIP-GNN further encodes transition structures by
multi-step transition propagation and distills information from neighborhoods
by a bilevel graph convolution.
  Experimental results over various temporal networks reveal the efficiency of
our TIP-GNN, with at most 7.2\% improvements of accuracy on temporal link
prediction.
  Extensive ablation studies further verify the effectiveness and limitations
of the transition propagation module.
  Our code is available at \url{https://github.com/doujiang-zheng/TIP-GNN}.
Tongya Zheng, Zunlei Feng, Tianli Zhang, Yunzhi Hao, Mingli Song, Xingen Wang, Xinyu Wang, Ji Zhao, Chun Chen
# Transition Propagation Graph Neural Networks for Temporal Networks

###### Abstract

Researchers of temporal networks (e.g., social networks and transaction networks) have been interested in mining dynamic patterns of nodes from their diverse interactions. Inspired by recently powerful graph mining methods like skip-gram models and Graph Neural Networks (GNNs), existing approaches focus on generating temporal node embeddings sequentially with nodes' sequential interactions. However, the sequential modeling of previous approaches cannot handle the transition structure between nodes' neighbors with limited memorization capacity. Detailedly, an effective method for the transition structures is required to both model nodes' personalized patterns adaptively and capture node dynamics accordingly. In this paper, we propose a method, namely Transltion Propagation Graph Neural Networks (TIP-GNN), to tackle the challenges of encoding nodes' transition structures. The proposed TIP-GNN focuses on the bilevel graph structure in temporal networks: besides the explicit interaction graph, a node's sequential interactions can also be constructed as a transition graph. Based on the bilevel graph, TIP-GNN further encodes transition structures by multi-step transition propagation and distills information from neighborhoods by a bilevel graph convolution. Experimental results over various temporal networks reveal the efficiency of our TIP-GNN, with at most 7.2% improvements of accuracy on temporal link prediction. Extensive ablation studies further verify the effectiveness and limitations of the transition propagation module. Our code is available at [https://github.com/doujiang-zheng/TIP-GNN](https://github.com/doujiang-zheng/TIP-GNN).

 Graph Embedding, Graph Neural Networks, Social Networks, Temporal Networks, Link Prediction.

## I Introduction

Temporal networks are widespread over real-life scenarios: users create, like, and dislike posts in social networks, and employees send, forward, and reply to emails in email networks [1, 2, 3, 4]. Nodes in these temporal networks exhibit their personalized dynamic patterns when keeping interacting with other nodes. For both researchers and industrial practitioners, it is beneficial to capture node dynamics to predict whether an account is malicious in risk management systems [5, 6], and recommend interesting items to users in online advertising systems[7, 8].

Previous approaches focus on mining node dynamics by aggregating neighborhood features chronologically from nodes' sequential interactions [5, 6, 7, 8, 9, 10, 11, 12], following a generalized sequential graph convolution paradigm as shown in Fig. 1(a). These methods are dedicated to modeling neighborhood impacts on nodes while mostly neglecting complex transitions between neighbors, as shown in Fig. 1(b). On the one hand, recurrent methods, which can be seen as one-layer temporal Graph Neural Networks (GNNs), update temporal node embeddings iteratively upon new interactions based on specific temporal point processes, such as the triad closure process in DynamicTriad [11], the attention-based Hawkes process in HTNE [7], and the mutual evolution process in JODIE [5]. On the other hand, temporal GNNs [6, 8, 10] have been proposed recently to deal with the dynamic high-order structure of the interaction graph, which demonstrate superior performance compared with recurrent methods (shallow GNNs with the one-layer neighborhood). Overall, existing approaches target generating temporal node embeddings based on the dynamic structure of a temporal network.

However, sequential modeling, the core of existing approaches, can hardly capture the transition structure of nodes' temporal neighbors with limited memorization capacity [13]. Fig. 1 provides an example that an employee finishes two

Fig. 1: A toy email network where an employee finishes two receive-forward-reply loops with a leader and two subordinates from \(t_{1}\) to \(t_{6}\). (a) The sequential graph convolution performs graph convolution sequentially over historical interactions. (b) The proposed bilevel graph convolution focuses on the transition structures (black arrows) between neighbors and distills the transition information with a hierarchical attention mechanism (highlighted orange arrows).
consecutive receive-forward-reply loops in an email network whose loop patterns challenge the representation capability of sequential modeling. As another example, users in social networks often propagate news in a hierarchical diffusion mechanism. These nodes' neighbors play different roles in their neighborhoods, presenting complex patterns in chronological order. If taking the transition structure into account, temporal network methods will make more precise predictions of whether the employee will forward the email to the subordinate or reply to the leader, as shown in Fig. 1(b).

Nonetheless, there exist two challenges in distilling the transition structure of nodes' neighbors into temporal node embeddings. Firstly, nodes in a network usually present interactions over a wide range, indicating that their personalized preferences require adaptive modeling. For instance, a leader may attend several consecutive meetings in one day, while a junior employee may only attend a weekly meeting during workdays. Thus, temporal node embeddings for the leader and the junior should capture their distinctive structures from their sequential interactions. Secondly, node dynamics of their temporal interactions imply the variation of their transition structures with time elapsing. For example, an employee will perform more interactions with high-level colleagues after getting promoted in a company. Its temporal node embeddings should also evolve forward according to the node dynamics of the transition structure. An effective method should handle both personalized and dynamic transition structures of neighbors.

To tackle these two challenges mentioned above, we investigate the bilevel graph structure inside temporal networks as shown in Fig. 1(b). Besides the explicit interaction graph, a node's sequential interactions can also be constructed as a transition graph according to chronological order. Specifically, the transition structure of neighbors is then encoded by multi-step propagation via transition links denoted by black arrows in Fig. 1(b). The multi-step propagation is proposed to deal with the first challenge of personalized structures: nodes with simple transitions are modeled by short-range propagations, while nodes with complex transitions can benefit from long-range propagations. Further, the bilevel graph convolution over multi-step neighborhood embeddings (highlighted arrows in Fig. 1(b)) is proposed to distill node dynamics accordingly from sequential interactions, aiming at the second challenge of dynamic structures.

Concretely, we propose the method, namely **T**rans**tion **P**ropagation **G**raph **N**eural **N**etworks (TIP-GNN), to handle nodes' transition structures in temporal networks adaptively and dynamically. Firstly, TIP-GNN translates a node's interactions into a small transition graph of neighbors and prepares the initialized neighborhood features for propagation. Secondly, TIP-GNN propagates neighborhood embeddings (latent features) in multiple steps, obtaining both short-range and long-range structures for nodes. Thirdly, TIP-GNN distills useful information from multi-step neighborhood embeddings by the bilevel graph convolution mechanism: the first transition pooling module accounts for structure encodings of transition structures dynamically, and the second bilevel graph convolution module accounts for detecting transition patterns adaptively. We conduct experiments over various real-life temporal networks and observe significant improvements in TIP-GNN compared with other state-of-the-art methods on most networks. Further, we perform extensive ablation studies and parameter sensitivity experiments, validating the effectiveness and limitations of our dedicated transition structures in temporal networks.

Our contributions can be summarized as follows:

* Besides the explicit interaction graph of temporal networks, we propose a novel transition graph between nodes' neighbors, revealing the latent dependencies between nodes' neighbors explicitly beyond previous sequential modeling.
* To distill transition structures from neighbors, we propose the TIP-GNN, consisting of a transition propagation module and a bilevel graph convolution module, which generates temporal node embeddings adaptively and dynamically with various interactions.
* Experimental results demonstrate the robustness and efficiency of our proposed TIP-GNN. Further, we discuss the effectiveness and limitations of the transition structure in temporal networks with a series of ablation studies.

## II Related Work

### _Static Graph Embedding_

Learning low-dimensional embeddings has shown great success in many graph mining applications such as risk monitoring [14], link prediction [15], and item recommendation [1] since decades ago [16, 17, 18, 1, 15]. Researchers are recently inspired to develop deep graph learning methods [19, 20, 21] with the breakthroughs of deep learning methods in computer vision [22] and natural language processing [23]. The deep graph learning methods mainly consist of two categories: skip-gram models [20] and graph neural networks [19]. DeepWalk [24] is the first skip-gram model to model the random walks on graphs as sampled node sequences. Node2Vec [25] further extends DeepWalk with two additional hyper-parameters controlling the preferences of random walks. Meanwhile, LINE [26] explores the high-order similarity of the graph topology between nodes. On the other hand, graph neural networks [27] have made attempts to define the convolution operation in the non-euclidean space. GCN [28] simplifies existing GNNs and applies successfully in semi-supervised node classification. GAT [29] further introduced a self-attention mechanism to compute the weights of neighbors adaptively and achieves substantial improvements in node classification. Nonetheless, static graph embedding methods are suitable for invariant relationships between entities in real life while being insufficient for temporal networks.

### _Temporal Network Embedding_

There are numerous temporal networks such as citation and collaboration [11, 12, 30], commodity purchasing [7, 5], and fraud detection [6]. According to the summarization of temporal network methods, existing approaches can be divided into two categories based on the property of graphs [31]. On
the one hand, a discrete-time temporal network refers to a sequence of graph snapshots, where edges in different snapshots may change accordingly. However, this kind of graph cannot model edges at the finest granularity (e.g., at a time scale of seconds) [32]. On the other hand, continuous-time graph methods generate the node embeddings dynamically, along with the upcoming new interactions. HTNE [7] and DyRep [12] follow a recurrent paradigm to update node embeddings with historical neighbors. Additionally, TigeCMN [30] adopts an external memory network to encode the network dynamics. Meanwhile, TGAT [8] and APAN [6] achieve inductive learning abilities by using graph neural networks. In comparison, our TIP-GNN proposes a novel transition structure instead of a sequential structure used by previous approaches.

### _Recommender System_

Researches of recommender systems [33, 34, 5, 35, 36, 37] are highly related to temporal networks when their interests are modeling user dynamics given historical interactions (e.g., views, clicks, and buys). However, their two-tower architectures and specific training objectives like BPR loss [38] are mainly optimized for recommendation tasks and not suitable for temporal networks that are homogeneous or long time-range. Methods related to temporal networks can be categorized into two kinds: recurrent recommender systems and session-based recommendations. On the one hand, Time-LSTM [33], Deep Coevolve [34], and JODIE [5] stand for recurrent recommender systems, ranking items according to nodes' temporal embeddings. On the other hand, session-based recommendation [35, 36, 37] explores recommendations based on anonymous user sessions, which utilize an item-to-item graph to encode co-occurrence relationships. Despite the similarity between the item-to-item graph and our proposed transition graph, session-based recommendation assumes the stationarity on the item-to-item graph, while we use dynamic transition graphs to represent node dynamics.

### _Comparisons between TIP-GNN and Previous Works_

TGAT [8] and GC-SAN [36] are the two most related works to our proposed TIP-GNN. Firstly, TGAT and TIP-GNN are both based on graph neural networks [28, 39], and the attention mechanism [13]. However, as depicted in Fig. 1, TGAT uses sequential graph convolution and can hardly capture the dynamic patterns in the transition graph. Secondly, GC-SAN and TIP-GNN are both based on the context graph and the attention mechanism [13]. GC-SAN, designed for sequential recommendation, utilizes the item co-occurrence matrix to recommend similar items for users. In contrast to TIP-GNN, GC-SAN cannot mine the high-order relationship in the interaction graph, and is not adapted for dynamic patterns as our multi-step transition propagation. Specifically, TIP-GNN focuses on nodes' temporal transition graphs and produces temporal node embeddings based on personalized transition graphs.

## III Method

Our proposed **T**ransI**tion **P**ropagation **G**raph **N**eural **N**etworks (TIP-GNN) focuses on the bilevel graph structure of nodes in temporal networks and extracts the transition relationship between nodes' neighbors by bilevel graph neural networks. As depicted in Fig. 2, TIP-GNN mainly consists of three modules: the sequence translation module accounts

\begin{table}
\begin{tabular}{l|l} \hline \hline Symbol & Meaning \\ \hline \(V,E\) & the vertex set and edge set of a graph \\ \hline \(G\) & \(G=(V,E)\), the notation of a graph \\ \hline \(u\) & a node in a graph, \(u\in V\) \\ \hline \(t\) & a timestamp, \(t\in\mathbb{R}^{+}\) \\ \hline \(h_{u,t}^{*}\) & \(u\)’s embedding at \(l\)-th TIP-GNN layer \\ \hline \(h_{u}^{k}\) & \(u\)’s embedding at \(k\)-th propagation step \\ \hline \(S_{u,t}\) & the interaction sequence of node \(u\) before \(t\) \\ \hline \(\mathcal{N}_{u,t}\) & the node set of neighbors in \(S_{u,t}\) \\ \hline \(s_{i}\) & an interaction \(s_{i}=(u,v_{i},t_{i})\) in \(S_{u,t}\) \\ \hline \(e_{i}\) & the edge feature of the interaction \(s_{i}\) \\ \hline \(A_{u,t}\) & the adjacency matrix of node \(u\)’s transition graph at \(t\) \\ \hline \(B_{u,t}\) & the incidence matrix between \(N_{u,t}\) and \(S_{u,t}\), indicating whether a node \(v\) is associated with an interaction \(s_{i}\) \\ \hline \(H_{S}\) & the stacked feature matrix of the interaction set \(S_{u,t}\) \\ \hline \(H_{\mathcal{N}_{u,t}}^{T}\) & node embeddings of \(\mathcal{N}_{u,t}\) at \(t\)-th TIP-GNN layer \\ \hline \(u^{*}\) & \(u^{*}\)’s neighbor in the set \(\mathcal{N}_{u,t}\) \\ \hline \(Z_{\mathcal{N}_{u,t}}^{k}\) & node embedding of \(u^{*}\) neighbor \(v\) at \(k\)-th propagation step \\ \hline \(Z_{\mathcal{N}_{u,t}}^{k}\) & node embeddings of \(\mathcal{N}_{u,t}\) at \(k\)-th propagation step \\ \hline \end{tabular}
\end{table} TABLE I: Mathematical symbols and their meanings used in this work.

Fig. 2: An illustration instance of the one-layer TIP-GNN model. (a) Given a query node \(u\) and timestamp \(t\), the sequence translation module translates node \(u\)’s interactions \(S_{u,t}\) before \(t\) into a directed transition graph \(A_{u,t}\), whose initialized node embeddings \(Z_{\mathcal{N}_{u,t}}^{0}\) are formed according to Eq. 4. (b) The transition propagation module extracts dynamic patterns from the transition graph by propagating node embeddings through multiple steps according to Eq. 6. (c) The bilevel graph convolution module distills useful information for node \(u\) by a hierarchical attention mechanism: firstly, it performs a multi-head attention pooling at each propagation step according to Eq. 7; secondly, it aggregates \(u\)’s node embeddings at different steps by another attention function according to Eq. 9.
for producing the directed transition graph; the transition propagation module is designed to represent nodes' dynamic patterns; the bilevel graph convolution module aims at distilling information from the transition graph and the interaction graph. Finally, our multi-layer TIP-GNN is optimized by the temporal link prediction task.

### _Sequence Translation_

#### Iii-A1 Transition Graph

Since proximity structures can be encoded by a graph with an adjacency matrix [28], we can also encode transition structures with a transition graph. Different from a static network, a temporal network denoted by \(G=(V,E)\) keeps expanding with time moving forward, where \(V\) represents nodes, and \(E\) represents edges. Given a node \(u\) and a timestamp \(t\), our problem is learning the temporal node embedding \(h_{u,t}\), which captures node dynamics precisely from its historical interactions \(S_{u,t}\). We construct the transition graph as a transition matrix \(A_{u,t}\in|\mathcal{N}_{u,t}|\times|\mathcal{N}_{u,t}|\) from these interactions, where \(\mathcal{N}_{u,t}=\{v_{i}|(u,v_{i},t_{i})\in S_{u,t}\}\) is the neighbor set of node \(u\)'s interactions.

\(S_{u,t}=\{\cdots,s_{i},s_{j},\cdots\}\) denotes the interaction set ordered by timestamps, where \(s_{i}\) and \(s_{j}\) are two consecutive interactions of the node \(u\). \(A_{u,t}\) denotes the transition matrix between node \(u\)'s neighbors defined by

\[A_{u,t}[\text{id}(v_{i}),\text{id}(v_{j})]=\begin{cases}1,&\text{if }s_{i}=(u,v_{i},t_{i}),s_{j}=(u,v_{j},t_{j})\\ 0,&\text{otherwise},\end{cases} \tag{1}\]

where the function \(\text{id}(\cdot)\) gives the node index in the neighbor set \(\mathcal{N}_{u,t}\). For instance, Figure 2 shows \(v_{1}\) appears at two interactions and \(\text{id}(\cdot)\) gives the same node index \(v_{1}\). The transition graph \(A_{u,t}\) includes only chronologically ascending transition links and excludes bi-directional links because inverse links may obscure the causal relations in the chronological order. Moreover, the above definition assumes that \(S_{u,t}\) has at least two interactions and makes nodes with sparse interactions less representative in the transition graph. The self-loop is thus added to the transition graph to help both numerical stability [28] and interaction sparsity, defined as \(\tilde{A}_{u,t}=I+A_{u,t}\).

#### Iii-A2 Feature Initialization

To prepare for transition propagation, besides existing node embeddings, we also transform edge features carried by these interactions into node features by an incidence matrix \(B_{u,t}\in|\mathcal{N}_{u,t}|\times|S_{u,t}|\), which connects each interaction \(s_{i}\) with each neighborhood node \(v_{i}\). The incidence matrix \(B_{u,t}\) is defined by

\[B_{u,t}[\text{id}(v_{i}),i]=\begin{cases}1,&\text{if }s_{i}=(u,v_{i},t_{i})\\ 0,&\text{otherwise},\end{cases} \tag{2}\]

where \(\text{id}(v_{i})\) and \(i\) are indices of nodes and edges, respectively. The incidence matrix \(B_{u,t}\) could sum up the edge features of neighbor's interactions in order to highlight the numerical impacts of individual neighbors.

A specific interaction \(s_{i}=(u,v_{i},t_{i})\) contains its original edge feature \(e_{i}\) and timestamp \(t_{i}\). Due to the wide range of timespans in different temporal networks (e.g., seconds, days, and weeks), the temporal kernel function of TGAT [8] is adopted for robust encoding of timespans, defined by

\[\Phi(\Delta t)=\textit{concat}(cos(\omega_{1}\Delta t),\cdots,cos(\omega_{d_ {t}}\Delta t)), \tag{3}\]

where \(\Delta t=t-t_{i}\) is the timespan between the prediction timestamp and the edge timestamp, \(\omega_{1}\) is a trainable parameter of the frequency of the cosine function, and \(d_{t}\) is the dimension of the output vector. The edge features of the interaction \(s_{i}\) is thus defined by \(\tilde{e}_{i}=\textit{concat}(e_{i},\Phi(t-t_{i}))\), and the edge matrix of the interaction set \(S_{u,t}\) is stacking interactions' features, defined by \(H_{S}=[\cdots,\tilde{e}_{i},\cdots]^{\intercal}\).

Let \(H_{V}^{l}\) be the embeddings of all nodes \(V\) in the \(l\)-th TIP-GNN layer, and then we extract the neighborhood embeddings \(H_{\mathcal{N}_{u,t}}^{l}\in|\mathcal{N}_{u,t}|\times d\) from the last layer (node features at the 0-th layer), where \(d\) is the embedding dimension. Finally, the initialized node embeddings at each layer are calculated by adding the node embeddings and edge features defined by

\[Z_{\mathcal{N}}^{0}=W\times ReLU(W_{n}H_{\mathcal{N}}^{l}+W_{e}B_{u,t}H_{S})+b, \tag{4}\]

where \(W,W_{n},W_{e},b\) are transformation parameters, edges features \(H_{S}\) are aggregated through the incidence matrix \(B_{u,t}\), \(H_{\mathcal{N}}^{l}\) is short for \(H_{\mathcal{N}_{u,t}}^{l}\), and \(Z_{\mathcal{N}}^{0}\) represents the node embeddings at the 0-th propagation step, as shown in Fig. 2.

### _Transition propagation_

As shown in Fig. 2, the graph propagation module is designed for encoding dynamic patterns from the transition graph. Inspired by PageRank [16] and recent graph isomorphism representation works [40], nodes' dynamic patterns in this paper refer to nodes' complex transitions among nodes' historical neighbors and can be encoded by graph neural networks through multiple propagation steps. Concretely, the transition propagation rule of a single transition graph is defined by

\[\tilde{Z}_{\mathcal{N}}^{k+1}=\tilde{A}_{u,t}MLP(Z_{\mathcal{N}}^{k}), \tag{5}\]

where \(k\) denotes the propagation step, \(Z_{\mathcal{N}}^{0}\) is defined in Eq. 4, \(\tilde{A}_{u,t}\) is the transition matrix with self-loop, and \(MLP\) is a multilayer perceptron. The multilayer perceptron is proposed to enhance the representation capacity of models by its nonlinear transformation. With \(k\) propagation steps, \(Z_{\mathcal{N}}^{k}\) can encode \(k\)-hop subgraphs of the transition graph around neighbors. Further, a damping factor \(\alpha\) is introduced to preserve the uniqueness of node embeddings due to the over-smoothing of graph neural networks, defined by

\[Z_{\mathcal{N}}^{k+1}=\alpha Z_{\mathcal{N}}^{k}+(1-\alpha)\tilde{Z}_{\mathcal{ N}}^{k+1}. \tag{6}\]

The damping factor [41] can also be seen as a residual connection between the previous step and the current step, which reduces the learning difficulty of models.

### _Bilevel Graph Convolution_

#### Iii-C1 Transition Pooling

The transition pooling module treats neighborhood embeddings at each propagation step separately and produces a summarized graph embedding \(h_{u}^{(k,l+1)}\) for the specific node \(u\). Specifically, we extract useful information from neighborhood embeddings by performing the attention
mechanism [13] between node embeddings \(h^{l}_{u,t}\) of the previous TIP-GNN layer (node features at the 0-th layer) and neighborhood embeddings \(z^{k}_{v}\in Z^{k}_{N}\), defined by

\[\alpha^{(k,l+1)}_{uv}=softmax\{(W^{l+1}_{0}h^{l}_{u,t})(W^{l+1}_{K }z^{k}_{v})^{\intercal}\}, \tag{7}\] \[h^{(k,l+1)}_{u}=\sum_{v\in N_{u,t}}\alpha^{(k,l+1)}_{uv}W^{l+1}_{ V}z^{k}_{v},\]

where \(h^{l}_{u,t}\) is extracted from \(H^{l}_{V}\) (node feature in the first TIP-GNN layer), \(W^{l+1}_{Q}\) and \(W^{l+1}_{K}\) transform node embeddings into the same space, and \(W^{l+1}_{V}\) provides additional transformation nonlinearity. The first equation computes the attention scores between node \(u\) and its neighborhood embeddings, and the second equation sums up transformed neighborhood embeddings according to their impacts on the target node \(u\). Moreover, the multi-head attention [13] is introduced to enhance the model capacity of graph representation, which computes \(h^{(k,l+1)}_{u}\) in Eq. 7 with different parameter matrices several times parallelly.

#### Iii-C2 Attention Fusion

The attention fusion module is the second level of the attention mechanism, aiming at fusing node embedding \(h^{(k,l+1)}_{u}\) at different propagation steps into a unified representation. Instead of the similarity-based attention used in Eq. 7, a projection-based attention is employed here to produce weights for different node embeddings, defined by

\[\omega^{(k,l+1)}_{u}=q^{\intercal}\cdot sigmoid(W^{(k,l+1)}h^{(k,l+1)}_{u}+b ^{(k,l+1)}), \tag{8}\]

where \(W^{(k,l+1)}\) and \(b^{(k,l+1)}\) are specified transformation parameters for each step, \(q\) is a shared projection vector across different steps, and \(\omega^{(k,l+1)}_{u}\) is an unnormalized scalar weight of each step. The final node embedding \(h^{l+1}_{u,t}\) at \(l+1\) TIP-GNN layer is computed by

\[\alpha^{k}_{u} =\frac{exp(\omega^{k}_{u})}{\sum_{k^{\prime}}exp(\omega^{k^{ \prime}}_{u})}, \tag{9}\] \[h^{l+1}_{u,t} =\sum_{k}\alpha^{k}_{u}h^{(k,l+1)}_{u},\]

where \(\alpha^{k}_{u}\) is the normalized weight of each step, and \(h^{l+1}_{u,t}\) sums up the weighted node embeddings at different steps.

### _Model Optimization_

#### Iii-D1 Loss Function

It is an effective pretext task for generating temporal node embeddings to predict whether a temporal interaction will happen between node pairs in the given timestamp [6, 8]. The probability \(\hat{p}^{t}_{uv}\) of the interaction's existence between node \(u\) and node \(v\) at \(t\) is thus defined as

\[\hat{p}^{t}_{uv}=sigmoid(W\times ReLU(W_{u}h^{L}_{u,t}+W_{v}h^{L}_{v,t})+b), \tag{10}\]

where \(W,W_{u},W_{v}\) are transformation matrices, \(h^{L}_{u,t}\) and \(h^{L}_{v,t}\) denote node embeddings at the \(L\)-th TIP-GNN layer, and \(L\) is the last TIP-GNN layer. The cross-entropy loss is adopted to classify the existence of the edge, which is defined as follows,

\[\underset{\theta}{\arg\min}-\sum_{(u,v,t)\in E}\{log(\hat{p}^{t}_{uv})+c\cdot \mathbb{E}_{j\sim P_{u}(u)}log(1-\hat{p}^{t}_{uj})\}, \tag{11}\]

where \(E\) is the set of temporal edges, \(P_{n}(u)\) is a uniform distribution over nodes for negative sampling, and \(c\) is the number of negative samples. The negative sampling loss is useful for boosting the training efficiency in network embedding methods [23]. For simplicity, the number of negative samples is set as 1 in our experiments. The model parameters are then updated using the Adam [42] optimizer, which uses the weight-decay strategy to regularize the magnitude of model parameters.

#### Iii-D2 Model Size

The proposed TIP-GNN model introduces additional modules on the transition graph compared with previous methods based on graph neural networks. Let \(d\), \(d_{e}\), \(d_{t}\) be the embedding dimension of node feature, edge feature, and time feature, respectively. Also, the hidden dimension is all set as \(d\) for simplicity. The first sequential translation module does not include trainable parameters. Let \(q\) be the MLP layer in the transition propagation, \(K\) be the number of propagation steps, and \(L\) be the number of TIP-GNN layers. The parameters of the transition propagation module are \(\mathcal{O}(d(d+d_{e}+d_{t})L+qd^{2}KL)\), which is mainly attributed to the feature initialization and the multilayer perceptron. The parameters of the bilevel graph convolution module are \(\mathcal{O}(3d^{2}KL+d^{2}KL+dL)\), which consist of the \(K\)-step transition pooling and the attention fusion, respectively. The final prediction layer also contains \(\mathcal{O}(3d^{2})\) parameters. To summarize, the model size of TIP-GNN is \(\mathcal{O}(3d^{2}L+qd^{2}KL+4d^{2}KL+dL+3d^{2})\), where we assume \(d,d_{e},d_{t}\) are at the same order.

#### Iii-D3 Complexity Analysis

For each node \(u\) at \(t\), a one-layer TIP-GNN samples \(b\) latest interactions from its interaction set \(S_{u,t}\), and provides node features, edge features, and edge timestamps. Let \(\hat{\mathcal{N}}_{u,t}\) be the sampled neighbor set, a \(2\)-layer TIP-GNN will sample the second-order interactions recursively from \(S_{\hat{\mathcal{N}}_{u,t}}\) following Section 3.4 of TGAT [8]. Let the TIP-GNN layer be \(L\), the total number of interactions for a node is denoted by \(\mathcal{B}\), which is \(1+b+\cdots+b^{L}\). The time complexity of sequence translation is \(\mathcal{O}(\mathcal{B})\). In practice, these transition graphs are cached to boost the training speed. The time complexity of transition propagation is \(\mathcal{O}(3d^{2}L\mathcal{B}+qd^{2}KL\mathcal{B}+dKLb\mathcal{B})\), where the last term refers to the propagation step. The time complexity of the bilevel graph convolution and the prediction layer is \(\mathcal{O}(3KLb\mathcal{B}+d^{2}KL\mathcal{B}+dL\mathcal{B})\) and \(\mathcal{O}(3bd^{2})\), respectively. Let \(\mathcal{M}\) be the model size of TIP-GNN; the time complexity of TIP-GNN is mainly \(\mathcal{O}(\mathcal{B}+b\mathcal{B}\mathcal{M})\), which is \(b\mathcal{B}\) times of the model size besides the sequence translation module.

## IV Experiment

We conduct elaborate experiments on various temporal networks to evaluate the efficiency and robustness of TIP-GNN, especially on the effectiveness of the transition propagation module. We aim to answer the following key research questions:

* **RQ1**: How does TIP-GNN perform compared with other state-of-the-art temporal network methods?
* **RQ2**: What are the effects of our specific transition propagation module on task performance?
* **RQ3**: How do different parameter settings (e.g., the number of TIP-GNN layers, the number of attention heads, and so on) affect the TIP-GNN model?
### _Datasets and Tasks_

Table II lists temporal networks collected over a wide range from Network Repository [4] and SNAP [5]. In consideration of scalability, nine medium-scale networks without node or edge features from Network Repository [4] are used for temporal link prediction, which contains various temporal patterns due to huge variations of the timespan. Meanwhile, two networks with preprocessed edge features from SNAP [5] are used for temporal link prediction in inductive settings and temporal node classification, whose label ratios are highly imbalanced. For clarity of analyses, experimental networks are divided according to their node number and graph density. The network with more than 5,000 nodes is referred to as a **large** network, and the other networks are seen as **small** networks. Meanwhile, the density of a **sparse** network is less than 0.005, and the other networks are considered as **dense** networks.

#### Iv-A1 Temporal Link Prediction

Temporal networks for temporal link prediction only consist of temporal interactions and do not carry any node features or edge features. These networks could sufficiently validate the robustness of existing methods because of huge differences in their essential properties. According to the above divisions of networks, existing networks mainly consist of two kinds, large and sparse networks, and small and dense networks. Notably, large and sparse networks often spread across a long timespan (over one year), and small and dense networks usually occur during a small timespan (less than two weeks). Further, networks with mixed properties challenge the representation ability of compared methods. For example, the timespans of small and dense networks like _fb-forum_ and _ia-radoslaw-email_ are around half a year. Experiments on these complex networks could reveal the performance of methods in industrial scenarios to some degree.

Temporal link prediction refers to predicting whether a given node pair will have an interaction at a given timestamp. We split the datasets into the training, validation, and testing sets with ratios 70:15:15 chronologically. We use the observed interactions in the testing set as positive samples and obtain negative samples by replacing target nodes in the testing set with nodes that have never interacted with source nodes. The labeled datasets are used for the evaluation of temporal network methods. Our collected temporal graphs from Network Repository [4] provide only graph topology without node or edge features, causing many comparing methods not suitable for new nodes in the testing set. Therefore, we remove new nodes from the validation and testing set for a fair comparison.

#### Iv-A2 Inductive Temporal Link Prediction and Temporal Node Classification

Temporal networks for inductive temporal link prediction and temporal node classification are two bipartite graphs consisting of user behaviors among Wikipedia pages and subreddits. Wikipedia consists of 8,227 users and 1,000 most edited pages, while Reddit contains 10,000 active users and 1,000 active subreddits. The edge features in both Wikipedia and Reddit are text features of interactions, by converting Wikipedia pages and Reddit posts into 172-dimensional vectors under the _linguistic inquiry and word count_ (LIWC) categories [44]. Detailedly, the interaction of Wikipedia is that a user-edited a page, while the interaction of Reddit is that a user created a post in the subreddit.

Inductive temporal link prediction validates the inductive capability of TIP-GNN on new nodes in the testing set by hiding 10% of nodes from the training set following the task settings of TGAT [8] and TGN [43]. Temporal node classification refers to classifying a user's temporal state, whether the user is banned from editing a Wikipedia page or posting in the subreddit. Also, we split the datasets into the training, validation, and testing sets with ratios 70:15:15 chronologically. The labels of the additional two datasets are extremely imbalanced: Wikipedia has 217 positive labels with 157,474 interactions (=0.14%), while Reddit has 366 true labels among 672,447 interactions (=0.05%).

#### Iv-A3 Evaluation Metrics

For temporal link prediction, we compute the classification _accuracy_ and the _area under the ROC curve_ (AUC-ROC) when obtaining the prediction probabilities of edge existence. For temporal link prediction in transductive and inductive settings, we adopt the Average Precision (AP) following TGAT [8] and TGN [43]. For temporal node classification, we use the AUC-ROC due to the highly imbalanced labels.

### _Experiment Setting_

#### Iv-B1 Baseline Methods

Most baseline methods generate temporal node embeddings with the pretext task of temporal link prediction. We employ a logistic classifier for temporal link prediction if methods cannot predict temporal links directly. These methods can be categorized as follows:

* **Static graph methods.** Node2Vec [25] and SAGE [39] are two classic and effective algorithms for skip-gram models and graph neural networks, respectively.
* **Discrete-time network methods.** TNODE [9] builds a recurrent model upon node embeddings in each time step, which is a state-of-the-art method on discrete-time networks.
* **Continous-time network methods.** CTDNE [32] and HTNE [7] are initially designed for continuous-time net

\begin{table}
\begin{tabular}{l r r r r r} \hline \hline Temporal Graph & \(|V|\) & \(|E|\) & Density & Repetition & Timespan \\ \hline \multicolumn{6}{c}{Temporal Link Prediction} \\ \hline in-network2000s & 92 & 9.8K & 2.34 & 77.19 & 11.43 \\ in-contacts-hypernet2009 & 113 & 20.8K & 3.28 & 59.09 & 2.46 \\ in-contact & 274 & 28.2K & 0.75 & 6.99 & 3.97 \\ do-form & 899 & 33.7K & 0.08 & 20.89 & 164.94 \\ sec-clip-bitcoin & 835 & 35.8K & 0.002 & 0.90 & 1903.27 \\ in-radoslaw-email & 167 & 82.9K & 5.98 & 18.89 & 271.19 \\ in-novileens-user202s-10m & 17K & 95.5K & 0.0007 & 19.99 & 1108.97 \\ in-primary-school proximity & 242 & 125.7K & 4.31 & 38.39 & 1.35 \\ ia-dashdot-reply-dir & 51K & 140.7K & 0.0001 & 4.2\% & 977.36 \\ \hline \multicolumn{6}{c}{Inductive Temporal Link Prediction} & \multicolumn{2}{c}{Temporal Node Classification} \\ \hline Wikipedia & 9.2K & 157.4K & 0.0036 & 79.1\% & 29.77 \\ Reddit & 10.9K & 672.4K & 0.011 & 61.4\% & 31.00 \\ \hline \hline \end{tabular}
\end{table} TABLE II: Temporal network datasets and statistics. \(|V|\) is the number of nodes in the dataset. \(|E|\) is the number of interactions. The graph density is the ratio between \(|E|\) and \(\frac{|V|(|V|-1)}{2}\). The repetition of interactions describes that a node interacts with the same neighbor the last time. The time unit of the timespan is one day.
works. However, they are not flexible for generating temporal node embeddings at a given timestamp. JODIE [5], TGAT [8], APAN [6] and TGN [43] are four state-of-the-art temporal network methods.

#### Iv-A2 Settings of Temporal Link Prediction

The embedding dimension for all methods is set to 128 for a fair comparison. For each method, we report the average testing performance and standard deviation over five runs of different hyper-parameters. For static graph methods, we use grid search of the random walk parameters \(p,q\) of Node2Vec [25] over \(\{0.25,0.5,1,2,4\}\), and implement an inductive SAGE [39] with uniformly sampling 100 neighbors from historical interactions. For discrete-time graph methods, we run TNODE over three different graph snapshot divisions, namely \(\{8,32,128\}\). For CTDNE [32], the number of the walk is set at 10, the walk length is set at 80, and the context window size is set at 10. The history length of HTNE [7] is searched over \(\{10,20,30\}\). The hyper-parameter settings of JODIE [5], TGAT [8], APAN [6] and TGN [43] are listed in Appendix B.

The proposed TIP-GNN is implemented in PyTorch [45]. In default settings, the learning rate is set to 0.0001, and the dropout ratio is set to 0.1. The number of TIP-GNN layers is searched over \(\{1,2\}\), and the number of attention heads of

\begin{table}
\begin{tabular}{l c c c c} \hline \hline  & \multicolumn{2}{c}{Wikipedia} & \multicolumn{2}{c}{Reddit} \\ \cline{2-5}  & Transductive & Inductive & Transductive & Inductive \\ \hline Node2Vec [25] & \(0.915\pm 0.003\) & \(\dagger\) & \(0.846\pm 0.005\) & \(\dagger\) \\ SAGE [39] & \(0.956\pm 0.003\) & \(0.911\pm 0.003\) & \(0.977\pm 0.002\) & \(0.963\pm 0.002\) \\ CTDNE [32] & \(0.922\pm 0.005\) & \(0.914\pm 0.003\) & \(\dagger\) \\ JODIE & \(0.946\pm 0.005\) & \(0.931\pm 0.004\) & \(0.971\pm 0.003\) & \(0.944\pm 0.011\) \\ APAN & \(0.981\pm 0.002\) & \(\dagger\) & \(\mathbf{0.992\pm 0.002}\) & \(\dagger\) \\ TGAP & \(0.953\pm 0.001\) & \(0.940\pm 0.003\) & \(0.981\pm 0.002\) & \(\dagger\) \\ TGN & \(0.985\pm 0.001\) & \(0.978\pm 0.001\) & \(0.987\pm 0.001\) & \(0.976\pm 0.001\) \\ TIP-GNN & \(\mathbf{0.986\pm 0.001}\) & \(\mathbf{0.982\pm 0.001}\) & \(0.988\pm 0.001\) & \(\mathbf{0.977\pm 0.001}\) \\ \hline \hline \end{tabular}
\end{table} TABLE IV: Average Precision for temporal link prediction in transductive and inductive settings.

\begin{table}
\begin{tabular}{l c c c c c} \hline \hline  & \multicolumn{2}{c}{**ia-workplace**} & \multicolumn{2}{c}{**ia-hypertext**} & \multicolumn{2}{c}{**ia-contact**} \\ \cline{2-5}  & Accuracy & AUC & Accuracy & AUC & Accuracy & AUC \\ \hline Node2Vec [25] & \(0.649\pm 0.033\) & \(0.688\pm 0.019\) & \(0.642\pm 0.047\) & \(0.678\pm 0.029\) & \(0.760\pm 0.028\) & \(0.801\pm 0.012\) \\ SAGE [39] & \(0.746\pm 0.008\) & \(0.857\pm 0.008\) & \(0.709\pm 0.009\) & \(0.830\pm 0.006\) & \(0.818\pm 0.004\) & \(0.856\pm 0.003\) \\ CTDNE [32] & \(0.625\pm 0.014\) & \(0.673\pm 0.010\) & \(0.546\pm 0.069\) & \(0.572\pm 0.036\) & \(0.821\pm 0.006\) & \(0.851\pm 0.004\) \\ HTNE [7] & \(0.621\pm 0.015\) & \(0.661\pm 0.015\) & \(0.517\pm 0.044\) & \(0.540\pm 0.021\) & \(0.806\pm 0.010\) & \(0.831\pm 0.010\) \\ TNODE [9] & \(0.801\pm 0.009\) & \(0.883\pm 0.006\) & \(0.623\pm 0.071\) & \(0.683\pm 0.019\) & \(0.815\pm 0.008\) & \(0.852\pm 0.002\) \\ JODIE [5] & \(0.538\pm 0.011\) & \(0.600\pm 0.054\) & \(0.610\pm 0.035\) & \(0.667\pm 0.067\) & \(0.812\pm 0.005\) & \(0.850\pm 0.005\) \\ APAN [6] & \(0.695\pm 0.016\) & \(0.763\pm 0.035\) & \(0.725\pm 0.007\) & \(0.807\pm 0.009\) & \(0.832\pm 0.003\) & \(0.884\pm 0.002\) \\ TGAT [8] & \(0.878\pm 0.001\) & \(0.959\pm 0.001\) & \(\mathbf{0.894\pm 0.001}\) & \(\mathbf{0.950\pm 0.001}\) & \(\mathbf{0.883\pm 0.001}\) & \(0.921\pm 0.001\) \\ TGN [43] & \(0.883\pm 0.004\) & \(0.960\pm 0.001\) & \(0.885\pm 0.001\) & \(0.953\pm 0.001\) & \(\mathbf{0.891\pm 0.001}\) & \(\mathbf{0.927\pm 0.001}\) \\ TIP-GNN & \(\mathbf{0.885\pm 0.010}\) & \(\mathbf{0.961\pm 0.007}\) & \(0.889\pm 0.009\) & \(0.958\pm 0.005\) & \(0.887\pm 0.003\) & \(0.922\pm 0.003\) \\ \hline Improvements & 0.2\% & 0.1\% & -0.5\% & -0.1\% & -0.4\% & -0.5\% \\ \hline \hline \multicolumn{5}{c}{**fb-form**} & \multicolumn{2}{c}{**soc-bitcoin**} & \multicolumn{2}{c}{**ia-radoslaw**} \\ \cline{2-5}  & Accuracy & AUC & Accuracy & AUC & Accuracy & AUC \\ \hline Node2Vec [25] & \(0.744\pm 0.009\) & \(0.823\pm 0.008\) & \(0.708\pm 0.014\) & \(0.774\pm 0.012\) & \(0.708\pm 0.011\) & \(0.773\pm 0.010\) \\ SAGE [39] & \(0.636\pm 0.006\) & \(0.724\pm 0.010\) & \(0.651\pm 0.008\) & \(0.734\pm 0.009\) & \(0.804\pm 0.006\) & \(0.894\pm 0.005\) \\ CTDNE [32] & \(0.745\pm 0.007\) & \(0.817\pm 0.005\) & \(0.778\pm 0.004\) & \(0.836\pm 0.003\) & \(0.723\pm 0.005\) & \(0.795\pm 0.004\) \\ HTNne [7] & \(0.668\pm 0.004\) & \(0.715\pm 0.005\) & \(0.611\pm 0.009\) & \(0.639\pm 0.005\) & \(0.679\pm 0.005\) & \(0.744\pm 0.007\) \\ TNODE [9] & \(0.716\pm 0.004\) & \(0.795\pm 0.007\) & \(0.724\pm 0.007\) & \(0.793\pm 0.008\) & \(0.775\pm 0.003\) & \(0.863\pm 0.001\) \\ JODIE [5] & \(0.632\pm 0.034\) & \(0.751\pm 0.045\) & \(0.814\pm 0.056\) & \(0.880\pm 0.019\) & \(0.713\pm 0.012\) & \(0.784\pm 0.022\) \\ APAN [6] & \(0.776\pm 0.01
the bilevel graph convolution is searched over \(\{1,2,3,4\}\). The early-stopping strategy is adopted until the validation AUC score does not improve for three epochs.

#### Iv-B3 Settings of Temporal Node Classification

Continuous-time graph methods, including JODIE [5], APAN [6], TGAT [8], TGN [43], and our TIP-GNN, predict users' states using temporal node embeddings. For other methods, we concatenate the node embeddings of the user and the corresponding Wikipedia page or subreddit as input features. We use the three-layer MLP [8] as a classifier, whose hidden dimensions are {80,10,1} respectively. In addition, the MLP classifier is trained with the Adam optimizer, the Glorot initialization, and the early-stopping strategy with ten epochs. Due to the data imbalance, the positive labels in each batch are oversampled for better performance.

### _RQ1: Overall Performance_

#### Iv-C1 Temporal Link Prediction

Table III reports the average performance of baseline methods over five runs on temporal link prediction. The discussions of their performance are organized as follows:

* Node2Vec [25] and SAGE [39] are two robust baselines on temporal networks, although they are designed for static networks. Specifically, SAGE [39] presents outstanding performance than CTDNE [32], HTNE [7] on the first three small and dense networks.
* CTDNE [32], HTNE [7], and TNODE [9] are three temporal network methods. Detailedly, CTDNE performs best on large and sparse networks, while its mechanism is not good for small and dense networks. TNODE beats HTNE on most datasets and outperforms CTDNE on small and dense networks especially.
* JODIE, which is initially designed for temporal item recommendation in temporal networks, demonstrates a performance decline on small and dense networks, namely _ia-workplace_, _ia-hypertext_, _fb-form_, _ia-radoslaw_, and _ia-primary_. Moreover, its high computational complexity causes the failed experiments of _ia-slashdot_ with 51,000 nodes on our P6000 GPU with a 24GB memory.
* APAN [6] and TGAT [8] are both based on graph neural networks. However, the dedication of APAN to inference efficiency may make it unsuitable for small networks, while TGAT achieves the second-best on most datasets. Nevertheless, TGAT shows performance degradation on the large and sparse network, namely _ia-slashdot_.
* TGN [43] is a lightweight and powerful temporal network method built upon the recurrent mechanism and graph neural networks. Table III shows that TGN achieves comparable AUC scores with TIP-GNN on several datasets. However, TGN underperforms TIP-GNN on _fb-form_ and _soc-bitcoin_, which may require the information of high-order transition structures.
* Our proposed TIP-GNN performs on par with or outperforms state-of-the-art methods on all datasets. Concretely, TIP-GNN and TGAT [8] obtain top-2 performance on the first three networks, indicating that existing methods can well model small networks. As for large networks, TIP-GNN demonstrates consistent and significant improvements, as shown in Table III. Further, TIP-GNN shows stable performance on experimental datasets, compared with the performance degradation of JODIE [5], APAN [6], and TGAT [8] on several networks. Overall, the improvements of TIP-GNN validate the importance of transition structures between neighbors.

#### Iv-C2 Inductive Temporal Link Prediction

Table IV reports the average AP scores of different methods, where most results are inherited from APAN [6] and TGN [43]. Overall, APAN, TGN, and TIP-GNN obtain close AP scores on _Wikipedia_ and _Reddit_, which indicate that predicting temporal links is somewhat easy for those two datasets. Table II also shows the high repetition ratios of those two datasets that our model could achieve high prediction precision by simply predicting the last neighbor.

#### Iv-C3 Temporal Node Classification

Table V reports the average AUC scores and standard deviations of methods over five runs except for TNODE [9] because the original node classifier of TNODE presents poor performance. The temporal node classification task on _Wikipedia_ and _Reddit_ is challenging to all methods due to their highly imbalanced label ratios. Specifically, static graph methods (Node2Vec [25] and SAGE [39]) outperform CTDNE and HTNE on both datasets, revealing that whether users are banned from editing Wikipedia pages or posting in the subreddits are strongly related to the target pages or subreddits. Also, the limited memorization capacity of CTDNE and HTNE may cause poor performance on temporal node classification. As for continuous-time network methods that can generalize to unseen nodes, JODIE [5], APAN [6], TGAT [8], TGN [43], and our TIP-GNN all demonstrate much better performance than other methods. Specifically, APAN [6] performs best on _Wikipedia_ and TGN [43] achieves the second-best on _Reddit_, indicating the dataset preferences of models.

On _Reddit_, TIP-GNN performs significantly better than other methods, which may be attributed to the increased density of _Reddit_ than _Wikipedia_.
and the damping factor \(\alpha\) for personalized embedding. In default settings, the number of propagation steps is 2, MLP layers are 2, and the damping factor \(\alpha\) is 0. As shown in Fig. 3, the effects of these designs are summarized as follows:

* The propagation at different steps aims at representing dynamic patterns at different granularities. Fig. 3(a) shows the obvious improvements of accuracy with the increase of propagation steps. However, the performance on most datasets achieves its peak at three propagation steps. It may be caused by aggregated noise from distant neighborhoods and the well-known over-smoothing problem of GNNs [28].
* The designed MLP aims at enhancing the nonlinearity of embeddings during transition propagation. On the contrary, Fig. 3(b) shows that the performance is almost irrelevant to the MLP layers and even suffers from a deep MLP. Significantly, the 0-layer MLP, which propagates embeddings without any parametrized projection, achieves comparable performance to the best performance on most datasets. This finding could be attributed to (1) the additional nonlinearity of the bilevel graph convolution module and (2) the uselessness of nonlinear transformation during graph convolution [46, 47].
* The damping factor \(\alpha\)[41] works as a residual connection to overcome the over-smoothing problem and the training difficulty of GNNs. Fig. 3(c) shows complex relations between \(\alpha\) and the performance: social networks with comments and replies (i.e., _ia-radoslaw_ and _ia-slash_)

Fig. 4: Attention weights at each propagation step of TIP-GNN.

Fig. 3: Ablation studies on the transition propagation module of TIP-GNN.
benefit significantly from the damping factor, while other networks perform stably regardless of their sparsity and repetition ratios. In general, a small damping factor could boost the performance, but an optimal damping factor depends on the network properties.

#### V-B2 Discussions on the propagation step

The propagation step defined by the Eq. 6 plays an essential role in the transition propagation module, where the number of MLP layers is 2 and the damping factor \(\alpha\) is 0. Since most datasets achieve the peak performance when the propagation step is 3 in Fig. 3(a), we visualize the corresponding attention weights of each propagation step defined by Eq. 9 in the last TIP-GNN layer. Findings from Fig. 4 can be concluded as follows:

* The 0-th step, which has not yet involved any transition propagation, usually obtains the most significant weights on most datasets compared with other propagation steps. Specifically, attention weights of the 0-th step are larger than 0.6 average on the first three networks, indicating that transition propagation may only boost the performance marginally for simple networks.
* With the increase of interactions, attention weights of the 0-th step decrease accordingly, and attention weights of

Fig. 5: Parameter sensitivity of TIP-GNN.

Fig. 6: Effects of the number of TIP-GNN layers and attention heads.
other steps even present on par with the 0-th step on several networks, namely _ia-radoslaw_, _ia-movielens_, and _ia-primary_. This observation validates the existence and benefits of transition structures in temporal networks.
* Lastly, attention weights of different temporal networks present various distributions of propagation steps. For example, _soc-bitcoin_ and _ia-slashdot_ are both large and sparse networks. However, _soc-bitcoin_ prefers short-range transitions, while _ia-slashdot_ prefers long-range transitions. Nevertheless, our proposed attention fusion module could learn preferences adaptively across different propagation steps.

### _RQ3: Parameter Sensitivity_

For quantitative comparison, the following experiments are conducted with fixed parameters of the transition propagation module that the number of propagation steps is 2, the number of MLP layers is 2, and the damping factor \(\alpha\) is 0.

#### Iv-E1 Model Architecture

The parameters of model architecture refer to the TIP-GNN layers and the attention heads of the transition pooling module. The training parameters are also fixed for simplicity that the number of sampled interactions is 20, the dropout ratio is 0.1, and the batch size is 200. We plot the grid search results of the number of TIP-GNN layers over \(\{1,2\}\) and the number of attention heads over \(\{1,2,3,4\}\) in Fig. 6, which can be summarized as follows:

* A deeper TIP-GNN layer perceives a wider neighborhood in networks. Fig. 6 demonstrates the superiority of a deeper layer on all networks, owing to the benefits of collaborative filtering [48, 47] and neighborhood smoothing [28, 46].
* A larger number of attention heads enlarges the model capacity [29, 13]. The results in Fig. 6 can be divided into two kinds: networks with low-repetition ratios in Table II benefit from more attention heads, while networks with high-repetition ratios (such as _ia-radoslaw_ and _ia-primary_) suffer from it on the contrary. It indicates that a complex model may degrade the performance of simple networks.

#### Iv-E2 Hyper-parameters

The compared hyper-parameters presented here include the number of neighbors, the dropout ratios, and the batch sizes. The parameters of model architectures are fixed that the number of TIP-GNN layers is 2, and the number of attention heads is 2. The first three networks present stable performance with different hyper-parameters. Thus, the following discussions only care about the last six networks:

* Interactions with recent neighbors usually reveal nodes' dynamic patterns in temporal networks. Fig 5(a) shows that most networks benefit from a larger window of temporal neighbors, while _ia-slashdot_ presents the contrary results. Fig 5(a) shows that most networks benefit from sampling more latest interactions, while _ia-slashdot_ presents the contrary results. The reason may be that nodes in most networks demonstrate long-range interests, while _ia-slashdot_ demonstrate fast shifts of node interests because it is a post-then-reply network.
* Dropout is effective for training a robust neural network model by setting some neurons of the model as zeros and adjusting the outputs accordingly [49] Fig. 5(b) shows that our original TIP-GNN is robust compared with training under the dropout technique. Nevertheless, TIP-GNN achieves slight performance improvements when using dropout.
* It is a _de facto_ standard to train neural network models with mini-batches. Similar to the effects of the dropout technique, Fig. 5(c) shows the robustness of our TIP-GNN on most networks under different batch sizes. Specifically, the network _ia-slashdot_ benefits from a larger batch size, which may be attributed to its large-scale nodes and sparsity of interactions.

## V Conclusion

In this paper, we propose a novel TIP-GNN based on graph neural networks to model the bilevel graph structure in temporal networks, which highlights nodes' personalized transition patterns among neighbors. The transition propagation module encodes nodes' dynamic patterns with personalized propagation rules; then, the bilevel graph convolution module extracts useful neighborhood embeddings with a bilevel attention mechanism. Experimental results demonstrate the superiority of encoding dynamic patterns in temporal networks that our TIP-GNN outperforms existing approaches consistently and significantly on experimental datasets. Extensive experiments further reveal the adaptivity of the multistep propagation of TIP-GNN for various temporal networks, as well as the robustness of TIP-GNN.

As for future works, on the one hand, we will explore the representation limitation of GNNs to overcome the performance decline in Fig 3(a). Our ablation studies on propagation steps shown in Fig. 3(a) demonstrate that TIP-GNN will achieve peak performance when enlarging the number of propagation steps properly. Following works' mitigating the over-smoothing problem of GNNs [50, 41], we additionally design controllable modules with the zero-layer MLP and the attention mechanism for different propagation steps. However, the bilevel attention mechanism cannot suppress additional noise induced by a larger propagation step. In the future, we will investigate the over-smoothing problem from the perspective of temporal networks and propose an enhanced GNN.

On the other hand, we will explore the interpretability of our proposed transition graphs following previous works [51, 52]. IGMC [51] reveals the common patterns of enclosing subgraphs between users and items, while KGIN [52] captures user intents with an attentive mechanism over Knowledge graph relations. In the future, we will investigate how to annotate user interactions with auxiliary information like public Knowledge Graphs.

## VI Acknowledgment

This work is supported by National Natural Science Foundation of China (U20B2066, 61976186), the Starry Night Science Fund of Zhejiang University Shanghai Institute for
Advanced Study (Grant No. SN-ZIU-SIAS-001), and the Fundamental Research Funds for the Central Universities (226-2022-00064).
