# Learning Effective Feature Representation against User Privacy Protection on Social Networks
## 4 The Proposed Method
### Community-Cluster Informed NRL (c2n2v)  
We aim at exploiting the derived SAEM matrix to learn node embeddings. SAEM can be seen as an attribute-enhanced network, denoted by \(\mathcal{H}\), with respect to the original privacy-protected network \(H\). To be specific, let \(\mathcal{H}=(V,\mathcal{E})\). If for every element \(\mathbf{SAEM}_{ij}>0\), we create an edge \(e_{ij}=(v_{i},v_{j})\), and add it into \(\mathcal{E}\), i.e., \(\mathcal{E}\leftarrow\mathcal{E}\cup\{e_{ij}\}\). At this point, we can apply any typical NRL models, such as node2 vec [4] and DeepWalk [2], to network \(\mathcal{H}\), so as to generate node embeddings. Given \(\mathcal{H}\), in this section, we propose a community-cluster informed NRL, termed \(c2n2v\), for learning node embeddings, rather than directly applying existing NRL models. We aim to make the NRL learning process aware of both structural communities and node clusters detected from network \(\mathcal{H}\). The ultimate goal is to further improve the quality of node embeddings, in addition to SAEM, to overcome the issue of data sparsity. In other words, we will first detect network \"communities\" based on graph topology of \(\mathcal{H}\), and find node \"clusters\" according to the node-attribute matrix \(\hat{\mathbf{X}}\). Subsequently, the discovered communities and clusters are used in the process of NRL. Note that \"communities\" and \"clusters\" are different concepts. The \"communities\" are sets of nodes detected based on the graph structure. A community is a set of nodes that are densely connected with each other in the same set and are loosely connected with other nodes in different communities. The \"clusters\" are sets of nodes detected based on their attributes. A cluster is a set of nodes that share similar attributes. Before elaborating on the details of our NRL model, we first describe some basic settings and notations. We detect communities from network \(\mathcal{H}\) using Label Propagation algorithm [22], and find user clusters from matrix \(\mathbf{X}\) using Affinity Propagation algorithm [23]. Note that we choose such two algorithms since they are well-known, typical, and widely effective, and they can be replaced by any state-of-the-art version. Let \(C\) and \(\hat{C}\) denote the node sets of communities and clusters, respectively. Additionally, let \(c\) and \(\bar{c}\) denote every corresponding community and cluster. In addition, our NRL model is developed based on node2 vec [4]. We leverage the skip-gram architecture [5] from natural language processing to learn node embeddings in \(\mathcal{H}\). In natural language processing, the skip-gram architecture learns relations between words and their contexts. Here each node in the network is treated as a word, and node sequences sampled by random walk are sampled as sentences. Let \(f:V\rightarrow\mathbb{R}^{K}\) be the mapping function (equivalently a matrix of size \(|V|\times K\) parameters) from nodes to their embeddings, where \(K\) is the embedding dimensionality. For every node \(u\in V\), we denote \(N_{\varphi}(u)\subset V\) as the list of neighboring nodes of \(u\) by random walk sampling \(\varphi\). Here the random walk [24] is a mechanism \(\varphi\) that, by starting from node \(u\), randomly selects neighbor nodes in a consecutive manner, and eventually outputs a sequence of sampled nodes, denoted as \(N_{\varphi}(u)\). Subsequently, the goal is to find the mapping function \(f\) that maximize the objective function:  
\[\max_{f}\sum_{u\in V}\log P(N_{\varphi}(u)|f(u)), \tag{4}\]  
which maximizes the log-probability of observing a network neighborhood \(N_{\varphi}(u)\) conditioned on node \(u\)'s embedding vector \(f(u)\). The key step of community-cluster informed NRL lies in the generation of node sequences, i.e., the neighbor list \(N_{\varphi}(u)\) of node \(u\). Recall that we have the community set \(C\) and the cluster set \(\tilde{C}\).