# Graph Neural Network to Dilute Outliers for Refactoring Monolith Application

Utkarsh Desai, Sambaran Bandyopadhyay, Srikanth Tamilselvam

###### Abstract

Microservices are becoming the defacto design choice for software
architecture. It involves partitioning the software components into finer
modules such that the development can happen independently. It also provides
natural benefits when deployed on the cloud since resources can be allocated
dynamically to necessary components based on demand. Therefore, enterprises as
part of their journey to cloud, are increasingly looking to refactor their
monolith application into one or more candidate microservices; wherein each
service contains a group of software entities (e.g., classes) that are
responsible for a common functionality. Graphs are a natural choice to
represent a software system. Each software entity can be represented as nodes
and its dependencies with other entities as links. Therefore, this problem of
refactoring can be viewed as a graph based clustering task. In this work, we
propose a novel method to adapt the recent advancements in graph neural
networks in the context of code to better understand the software and apply
them in the clustering task. In that process, we also identify the outliers in
the graph which can be directly mapped to top refactor candidates in the
software. Our solution is able to improve state-of-the-art performance
compared to works from both software engineering and existing graph
representation based techniques.

##  1 Introduction

Microservices is an architectural style that structures an application as a
set of smaller services (Lewis and Fowler 2014). These services are built
around business functionalities and follow “Single Responsibility
Principle”111https://www.infoq.com/articles/microservices-intro. This allows
the team to develop business functionalities independently. Also, they
naturally benefit from cloud deployment due to the support for differential
and dynamic addition of resources like CPU, memory, disk space to specific
services based on the demand. However, there are lot of existing monolith
applications currently in use that cannot fully tap these benefits due to
their architecture style. Monoliths package all the business functionalities
into a single deployable unit making them unsuitable to fully leverage cloud
benefits. Therefore, there is a surge in enterprises wanting to refactor their
monolith applications into microservices. This is done by mapping business
functions onto the code structure and identifying the functional boundary in
such a way that there are less dependencies across the services (Jin et al.
2019). In typical monoliths, there are classes (or programs) loaded with
overlapping functionalities (Kalske et al. 2018). This can be identified by
their dependencies with cross functional classes. We refer to such classes as
outliers or refactorable candidates. They typically require top attention from
the developers for modification during refactoring to make the microservices
independent and deployable. But identifying functional boundaries on the
existing code is a hard task (Gouigoux and Tamzalit 2017) and the effort gets
multiplied when done without the help of original developers, which is
typically the case with legacy applications.

In the software engineering community, the problem is often referred as
software decomposition and several approaches (Fritzsch et al. 2018) have been
proposed. The approaches range from process mining, genetic algorithms to
graph based clustering. Graphs are a natural way to represent application
implementation structure. The classes in the application can be considered as
nodes and its interaction with the other classes can be considered as edges.
Further, the nodes can carry multiple features based on their type and their
invocation pattern. Figure 1 demonstrates the translation of an application
into a graph. Therefore, the application refactoring problem can be viewed as
a graph based clustering task. In the past, many clustering techniques have
been applied on code (Shtern and Tzerpos 2012), but they often consider only
the structural features of the application i.e the dependency of classes.
Also, none of these approaches have looked into attributed graph networks or
attempted to minimize the effect of outlier nodes during clustering.

Graph based mining tasks have received significant attention in recent years
due to development of graph representation learning that maps the nodes of a
graph to a vector space (Perozzi, Al-Rfou, and Skiena 2014; Hamilton, Ying,
and Leskovec 2017). They have also been applied to a diverse set of
applications such as social networks (Kipf and Welling 2017), drug discovery
(Gilmer et al. 2017), transportation and traffic networks (Guo et al. 2019),
etc. In this work, we propose a novel graph neural network based solution to
refactor monolith applications into a desired number of microservices. The
main contributions of our paper are listed below.

  1. 1.

We propose a novel way to translate the application implementation structure
to an attributed graph structure through static program analysis.

  2. 2.

We introduce two types of outliers that reflect the top refactoring program
candidates.

  3. 3.

We propose a novel graph neural network (GNN), referred as CO-GCN222Code
available at: https://github.com/utkd/cogcn (Clustering and Outlier aware
Graph Convolution Network), which unifies node representation, outlier node
detection & dilution and node clustering into the same framework for
refactoring monolith applications.

  4. 4.

We improve the state-of-the-art performance with respect to both software
engineering and graph representation based techniques to refactor four
publicly available monolith applications. We attach the source code in the
supplementary material for reproducibility of the results.

##  2 Related Work

Fritzsc et al. (Fritzsch et al. 2018) presented a survey on ten different
approaches towards refactoring a monolith application into microservices. Of
these, only four works were applied directly on application code and the rest
used other application artefacts such as logs, commit histories, UML diagrams
etc. However, all of these works have drawbacks since they either (1) focus on
only structural features; or (2) propose partitions focusing more on technical
layers which is not desirable (Taibi and Lenarduzzi 2018); or (3) partition
only a subset of program files like EJBs in java. (Mazlami, Cito, and Leitner
2017) proposed a graph based clustering approach with a focus on version
history. (Jin et al. 2019) proposed hierarchical clustering of program files,
but requires access to the runtime behavior of application which is
practically difficult. Moreover, these approaches do not exploit the power of
representation learning and graph neural networks. Also, they do not recommend
refactorable classes.

Graph representation learning (Hamilton, Ying, and Leskovec 2017) shows
promising results on multiple downstream graph mining tasks. Graph neural
networks (Wu et al. 2020) apply neural network directly on a graph structure.
In Graph convolution networks introduced by (Kipf and Welling 2017), a
localized first-order approximation of spectral graph convolutions is proposed
and experimented for semi-supervised node classification. An unsupervised
variation GCN autoencoder is proposed in (Kipf and Welling 2016). GNNs are
also proposed for supervised (Chen, Li, and Bruna 2019) and unsupervised
community detection (Zhang et al. 2019) in graphs. Recently, a self-supervised
learning based GNN, Deep Graph Infomax (DGI) (Veličković et al. 2019) is
proposed for obtaining node representation by using the principle of
information maximization. Outlier nodes are present in any real-world graph.
Outliers are shown to have adverse effect on the embeddings of regular nodes
in a graph (Liang et al. 2018). Unsupervised algorithms to minimize the effect
of outliers in the framework of graph representation learning are proposed
recently (Bandyopadhyay, Lokesh, and Murty 2019; Bandyopadhyay et al. 2020;
Bandyopadhyay, Vivek, and Murty 2020). However, minimizing the effect of
outliers in the framework of GNN has not been addressed in the literature.

Figure 1: Representation of a sample Java application as graph: The method
order() from class A invokes the method set() from class B, establishing a
direct relation between the two classes. If we represent classes A and B as
nodes in a graph, we can define a directed edge, $e(A,B)$ from A to B.

##  3 Methodology

Given a monolith application, we want to partition the monolith into $K$
clusters of classes, with $K$ provided by a subject matter expert (SME), where
each cluster is a group of classes that perform a well-defined functionality.
The clusters should exhibit high cohesion, i.e., have strong interaction
within the cluster and low coupling i.e., less interaction between clusters.
We also want to identify the following outlier classes from a monolith
application (Bandyopadhyay, Lokesh, and Murty 2019) to be handled by an SME.

  * •

Structural Outlier: A class which has high interaction with classes from
different clusters.

  * •

Attribute Outlier: A class which has attributes, such as usage patterns,
similar to attributes from other clusters.

###  3.1 Converting Applications to Graph

We now describe our approach to represent an application as a graph, given
it’s source code. Consider a simple Java application comprising of multiple
classes as shown in Figure 1. Each class in the application can be represented
as a node in a graph. We denote the set of such nodes as $V$. We establish a
directed edge from node A to node B if there is method in the class A that
calls a method from class B. We perform static
analysis333https://github.com/soot-oss/soot of the application code to
identify all such method calls between classes and obtain a set of edges, $E$
between the corresponding nodes. The edges are unweighted and multiple method
calls from class A to class B are still represented by a single edge from A to
B.

We now describe the process to generate the attribute matrix, $X$,
coressponding to the nodes $V$ of the graph. Most modern web applications
expose multiple APIs that perform various functions. These APIs (UI elements
in the case of a non web-based application) are referred to as EntryPoint
Specifications (Dietrich, Gauthier, and Krishnan 2018), or simply,
Entrypoints. The methods invoked through these APIs are specially annotated as
such and are called entrypoint methods in this work. Figure 1 shows an example
of such entrypoint methods annotated with @API. We refer to the classes
containing such entrypoint methods as entrypoint classes. Each entrypoint
class can thus be associated with multiple Entrypoints. Starting from an
entrypoint method, we can follow the call sequence of methods through the
application, keeping track of all classes invoked during the execution trace
of that Entrypoint. If $P$ is the set of Entrypoints in an application, we can
define a matrix $EP^{|V|\times|P|}$, such that $EP(i,p)=1$ if class $i$ is
present in the execution trace of entrypoint $p$, else $0$. Additionally, we
define $C^{|V|\times|V|}$ such that $C(i,j)$ is the number of Entrypoint
execution traces that contain both classes $i$ and $j$. If a class is not
invoked in an execution trace for any Entrypoint, we remove the corresponding
node from the graph. Finally, classes may also inherit from other classes or
Interfaces. In Figure 1, class A inherits from class Base. Although this
establishes a dependency between the classes, it does not involve direct
method invocation. Hence, we do not include this dependency as an edge in the
graph, but as a node attribute. Therefore, we set $In(i,j)=In(j,i)=1$ if
classes $i$ and $j$ are related via an inheritance relationship and $0$
otherwise. The attribute matrix $X$ is the concatenation of $EP$, $C$ and $In$
matrices. Thus, $X\in\mathbb{R}^{|V|\times F}$ where $F=|P|+2|V|$. Each
constituent of $X$ is row-normalized individually. The application can thus be
represented as a graph $G=(V,E,X)$.

###  3.2 Proposed Graph Neural Network

Given the graph $G$, we want to develop a graph neural network which can
jointly (i) derive vector representations (embeddings) of the nodes, (ii)
minimize the effect of outlier nodes in the embeddings of other regular nodes,
(iii) obtain communities in the graph. Let us use
$A\in\mathbb{R}^{|V|\times|V|}$ to denote the adjacency matrix of $G$, where
$A_{ij}$ is the weight of the edge $e_{ij}$ if it exists, otherwise
$A_{ij}=0$. We use a 2-layered graph convolution encoder (Kipf and Welling
2017) to obtain representation of each node as shown below:

$\displaystyle
Z=f(X,A)=\text{ReLU}(\hat{A}\;\text{ReLU}(\hat{A}XW^{(0)})\;W^{(1)})$ (1)

where each row of $Z\in\mathbb{R}^{|V|\times F^{\prime}}$ contains the
corresponding node representation. We compute $\tilde{A}=A+I$, where
$I\in\mathbb{R}^{|V|\times|V|}$ is the identity matrix and the degree diagonal
matrix $\tilde{D_{ii}}$ with $\tilde{D_{ii}}=\sum\limits_{j\in
V}\tilde{A}_{ij}$, $\forall i\in V$. We set
$\hat{A}=\tilde{D}^{-\frac{1}{2}}\tilde{A}\tilde{D}^{-\frac{1}{2}}$. $W^{(0)}$
and $W^{(1)}$ are the trainable parameter matrices of GCN encoder.
Traditionally, these parameters are trained on a node classification or link
prediction loss (Kipf and Welling 2016) in a graph.

However, our objective in the work is to consider and minimize the effect of
outlier nodes in the framework of graph convolution. We also want to do this
in an unsupervised way as obtaining ground truth class labels and outlier
information are extremely difficult for monolith applications. Towards this,
we use the following GCN based decoder to map the $F^{\prime}$ dimensional
node embeddings to the input feature space.

$\displaystyle\hat{X}=f(Z,A)=\text{ReLU}(\hat{A}\;\text{ReLU}(\hat{A}ZW^{(2)})\;W^{(3)})$
(2)

Here, $\hat{X}\in\mathbb{R}^{F}$, $W^{(2)}$ and $W^{(3)}$ are the trainable
parameters of the decoder. Let us use
$\mathcal{W}=\\{W^{(0)},\cdots,W^{(3)}\\}$ to denote the parameters of the
encoder and decoder combined. In the ideal world scenario when there is no
outlier node present in a graph, one can train the parameters of the GCN
autoencoder by directly minimizing some reconstruction loss. But as mentioned
in Section 1, the presence of outliers in monolith applications is prevalent
and if not handled properly, they can adversely affect the embeddings of
regular regular nodes in a graph (Bandyopadhyay et al. 2020). To address them,
we use the framework of multi-task learning where we design two loss
components to detect structural and attribute outliers respectively. We denote
structural and attribute outlierness (positive scalars) by $O_{si}$ and
$O_{ai}$ respectively, for each node $i\in V$.

First, we ensure that presence of an edge should be preserved by the
similarity of the two corresponding node embeddings in the vector space for
the regular nodes. However, structural outliers being inconsistent in their
link structure, do not necessarily follow this assumption. Hence, we design
the following loss component which needs to be minimized with respect to the
parameters of GCN and structural outlierness of the nodes:

$\displaystyle\mathcal{L}_{str}=\sum\limits_{i\in
V}\log\Big{(}\frac{1}{O_{si}}\Big{)}||A_{i:}-ZZ_{i:}^{T}||_{2}^{2}$ (3)

Here, $A_{i:}$ is the $i$th row of the adjacency matrix and $Z_{i:}$ is the
$i$th row (embedding of node $i$) of the node representation matrix. Clearly,
higher the value of $O_{si}$, i.e., higher the outlierness of node $i$, less
will be the value of $\log\Big{(}\frac{1}{O_{si}}\Big{)}$. Consequently,
contribution of the structural outlier nodes in this loss component will be
less. We also assume that total structural outlierness in a graph is bounded.
So we set $\sum\limits_{i\in V}O_{si}=1$. Without such a bound, the
optimization in Equation 3 would reach to a degenerate solution with each
$O_{si}$ assigned to $+\infty$ at the infimum. We also tried replacing $1$
with a hyperparameter $\mu$ as the bound, but that does not have much impact
on the quality of the final solution.

Next, to preserve the impact of node attributes in the node representations,
we want the reconstructed attributes in Equation 2 from the GCN decoder to
match the initial node attributes for most of the regular nodes in the graph.
However for attribute outliers, as their node attributes are significantly
different from the attributes of their respective neighboring nodes, we reduce
their contribution in the attribute reconstruction loss as follows:

$\displaystyle\mathcal{L}_{att}=\sum\limits_{i\in
V}\log\Big{(}\frac{1}{O_{ai}}\Big{)}||X_{i:}-\hat{X}_{i:}||_{2}^{2}$ (4)

Here, $X$ and $\hat{X}$ are the given and reconstructed node feature matrices.
Similar to the case of structural outlierness, nodes with more attribute
outlierness score $O_{ai}$ would have less impact in Equation 4 and
consequently the optimizer will be able to focus more on the regular nodes of
the graph. Again, we assume that $O_{ai}>0$, $\forall i\in V$ and
$\sum\limits_{i\in V}O_{ai}=1$.

Minimizing the loss components in Equations 3 and 4 with respect to the
parameters of GCN and outlier scores would be able to provide unsupervised
node embeddings. This will also detect the outlier nodes while minimize their
negative impact on the other nodes of the graph. However as discussed in
Section 1, our main goal in this work is to separate microservices within a
monolith application. This needs discovering clusters of nodes (or
communities) in the graph. One can potentially obtain the node embeddings
first and then use a clustering algorithm (for example, k-means++ (Arthur and
Vassilvitskii 2006)) as a post-processing step. But such a decoupled approach
often leads to a suboptimal solution as shown in (Yang et al. 2017). Hence, we
integrate node embedding, outlier detection and node clustering in a joint
framework of graph neural network. To achieve this, we use the following loss
to cluster the nodes in the graph, assuming their embeddings are already
given.

$\displaystyle\mathcal{L}_{clus}=\sum\limits_{i=1}^{N}\sum\limits_{k=1}^{K}M_{ik}||Z_{i:}-C_{k}||_{2}^{2}$
(5)

where $M\in\\{0,1\\}^{|V|\times K}$ is the binary cluster assignment matrix.
We assume to know the number of clusters $K$. $M_{ik}=1$ if node $i$ belongs
to $k$th cluster and $M_{ik}=0$ otherwise. $C_{k}\in\mathbb{R}^{F^{\prime}}$
is the center of each cluster in the embedding space. Equation 5 needs to be
minimized with respect to $M$ and $C=[C_{1}\cdots C_{K}]^{T}$ to obtain the
clustering. We call this method CO-GCN (Clustering and Outlier aware Graph
Convolution Network) and the joint loss function is:

$\displaystyle\underset{\mathcal{W},\mathcal{O},M,C}{\text{min}}\;$
$\displaystyle\mathcal{L}_{total}=\alpha_{1}\mathcal{L}_{str}+\alpha_{2}\mathcal{L}_{att}+\alpha_{3}\mathcal{L}_{clus}$
(6) such that, $\displaystyle\sum\limits_{i\in V}O_{si}=\sum\limits_{i\in
V}O_{ai}=1$ (7) $\displaystyle M\in\\{0,1\\}^{|V|\times
K},\;\;O_{si},O_{ai}>0\;\;\forall i\in V$ (8)

###  3.3 Optimization Procedure

The nature of the optimization problem in Eq. 6 is different with respect to
different variables. We use alternate minimization technique, where we
minimize the objective only with respect to one set of variables, keeping
others fixed.

#### Parameters of GCN

The set $\mathcal{W}$ contains all the parameters of the GCN encoder and
decoder as described in Section 3. We use standard ADAM optimization technique
(Kingma and Ba 2014) to minimize the total loss w.r.t. $\mathcal{W}$, keeping
other variables fixed. We use an initial learning rate of $0.01$ and
exponential decay rate of $0.95$ every $100$ iterations.

#### Outliers

One can show that optimization in Equation 6 is convex with respect to each
outlier variable when all other variables are fixed. This is because
$0<O_{si},O_{ai}\leq 1$, $\forall i$ and $\log(\cdot)$ is a concave function
and thus, $-\log(\cdot)$ is convex. Finally, L2 norms in both Equations 3 and
4 are non-negative. We aim to find the closed form update rules for the
outlier terms to speed up the optimization process.

Taking the Lagrangian of Eq. 6 with respect to the constraint
$\sum\limits_{i\in V}O_{si}=1$, we get (after ignoring terms that do not
include $O_{si}$),

$\displaystyle\frac{\partial}{\partial O_{si}}\sum\limits_{j\in
V}\log\Big{(}{\frac{1}{O_{sj}}}\Big{)}||A_{j:}-Z_{j:}^{T}Z||_{2}^{2}+\lambda(\sum\limits_{j\in
V}O_{sj}-1)$

$\lambda\in\mathbb{R}$ is the Lagrangian constant. Equating the partial
derivative w.r.t. $O_{si}$ to 0:

$\displaystyle-\frac{||A_{i:}-Z_{i:}^{T}Z||_{2}^{2}}{O_{si}}+\lambda=0,\;\Rightarrow
O_{si}=\frac{||A_{i:}-Z_{i:}^{T}Z||_{2}^{2}}{\lambda}$

But, $\sum\limits_{j=1}^{N}O_{ji}=1$ implies $\sum\limits_{j\in
V}\frac{||A_{j:}-Z_{j:}^{T}Z||_{2}^{2}}{\lambda}=1$. Hence,

$\displaystyle O_{si}=\frac{||A_{i:}-Z_{i:}^{T}Z||_{2}^{2}}{\sum\limits_{j\in
V}||A_{j:}-Z_{j:}^{T}Z||_{2}^{2}}$ (9)

The final update rule for structural outliers turns out to be quite intuitive.
Our goal while deriving the loss in Equation 3 was to approximate adjacency
structure of the graph by the similarity in the embedding space with outliers
being discounted. The structural outlierness of a node in Equation 10 is
proportional to the difference between the two after every iteration. In other
words, if some node is not able to preserve its adjacency structure in the
embedding space, it is more prone to be a structural outlier.

Similar to above, update rule for attribute outlier at each iteration can be
derived to the following.

$\displaystyle O_{ai}=\frac{||X_{i:}-\hat{X}_{i:}||_{2}^{2}}{\sum\limits_{j\in
V}||X_{j:}-\hat{X}_{j:}||_{2}^{2}}$ (10)

Because of the convexity of total loss in Equation 6 w.r.t. individual outlier
scores, derivations of the update rules for outlier scores ensure the
following lemma.

###### Lemma 1

Keeping all other variables fixed, the total loss in Equation 6 decreases
after every update of the outlier scores by Equations 10 and 9 until it
reaches to a stationary point.

#### Clustering Parameters

The total loss of CO-GCN also involves clustering parameters $M$ and $C$.
While all other variables to be fixed, cluster assignment matrix $M$ can be
obtained as:

$\displaystyle
M(i,k)=\begin{cases}1,\;\text{if\;}k=\underset{k^{\prime}\in\\{1,\cdots,K\\}}{\text{argmin}}||Z_{i}-C_{k^{\prime}}||_{2}^{2}\\\
0,\;\text{Otherwise}\end{cases}$ (11)

In the next step, $k$th row of cluster center matrix $C$ can be obtained as
(Arthur and Vassilvitskii 2006):

$\displaystyle C_{k}=\frac{1}{N_{k}}\sum\limits_{i\in\mathcal{C}_{k}}Z_{i:}$
(12)

where $\mathcal{C}_{k}=\\{i\in V\;|\;M_{ik}=1\\}$ is the $k$-th cluster and
$N_{k}=|\mathcal{C}_{k}|$ is the size of $k$-th cluster.

###  3.4 Pre-training, Algorithm and Analysis

To run CO-GCN, we first pre-train the GCN encoder and decoder by minimizing
$\mathcal{L}_{str}$ and $\mathcal{L}_{att}$ in Equations 3 and 4 respectively,
initializing $O_{si}$, $O_{ai}$ $\forall i\in V$ to uniform values. We also
use k-means++ (Arthur and Vassilvitskii 2006) to initialize the cluster
assignment and cluster center matrices. Then over iterations, we sequentially
solve $\mathcal{L}_{total}$ by alternating minimization technique described in
Section 3.3 with respect to different variables. Overall procedure of CO-GCN
is presented in Algorithm 1.

Algorithm 1 CO-GCN

1:Input: Class dependencies and Entrypoint definitions

2:Convert the application to a graph representation as defined in Section 3.1
and obtain the $V$, $E$ and $X$

3:Initialize outlier scores $O_{si}$ and $O_{ai}$ uniformly $\forall i\in V$.

4:Pre-train the GCN encoder and decoder

5:Use k-means++ to initialize the cluster assignment and cluster centers

6:for T iterations do

7: Update outlier scores $\mathcal{{O}}$ by Eq. 10 and 9.

8: Update cluster assignment and center matrices by Eq. 11 and 12

9: Update the parameters by GCN encoder and decoder by minimizing Eq. 6 using
ADAM.

10:end for

11:Output: Cluster assignment matrix $M$, Cluster center matrix $C$ and the
outlier scores $\mathcal{O}$

#### Time Complexity

Time taken by GCN encoder and decoder is $O(|E|FF^{\prime})$. Updating each
value of outlier score takes $O(NF^{\prime})$ and the total time to update all
outlier scores is $O(N^{2}F^{\prime})$. Updating the parameters of cluster
assignment and cluster center matrices takes $O(NF^{\prime}K)$ time. Thus,
each iteration of CO-GCN takes
$O(|E|FF^{\prime}+N^{2}F^{\prime}+NF^{\prime}K)$. The outlier update rules
although expensive, converge quickly because of the closed-form solution and
theoretical guarantee (Lemma 1). Also, for most real-world monolith
applications, number of classes is not very large (in 1000s). So the quadratic
dependency of the runtime on the number of classes is not a bottleneck.
However, one can try negative sampling approaches (Goldberg and Levy 2014) to
approximate the similarity between the embeddings in the outlier update rules
for other applications if needed.

##  4 Experimental Evaluation

Dataset | Description | Language | # Class | # Entrypoints | Cluster size
---|---|---|---|---|---
DayTrader | Trading App | Java | 111 | 203 | 8
PBW | Online plant store | Java | 36 | 47 | 6
Acme-Air | Airline App | Java | 38 | 20 | 4
DietApp | DietTracker | C# | 32 | 34 | 5

Table 1: Details about the monolith applications studied

###  4.1 Datasets (Monolith Applications) Used

To study the effectiveness of our approach, we chose four publicly-available
web-based monolith applications namely Daytrader
444https://github.com/WASdev/sample.daytrader7, Plantsbywebsphere
555https://github.com/WASdev/sample.plantsbywebsphere, Acme-
Air666https://github.com/acmeair/acmeair, Diet
App777https://github.com/SebastianBienert/DietApp/. They vary in programming
languages, technologies, objectives and complexity in terms of lines of code,
function sizes etc. Details of the monoliths are provided in Table 1.

###  4.2 Metrics

Figure 2: Comparison of the CO-GCN method with the baselines across the four
applications on the (a) Structural Modularity (b) Modularity (c) 1-NED and (d)
IFN metrics. The CO-GCN method clearly outperforms the baselines considered.

To evaluate the quality of the clusters identified as microservice candidates,
we define four metrics. The first two aim to capture the structural quality of
the clusters recommended as microservices and are the primary metrics in the
evaluation. The other two metrics define additional properties of the clusters
that are desirable.

  1. 1.

Modularity: Modularity is a commonly used metric to evaluate the quality of
clusters in a graph (Newman and Girvan 2004)(Newman 2006). It measures the
fraction of edges of the graph between members of the same cluster relative to
that of the same partition members but randomly generated graph edges. Higher
values of Modularity indicate a stronger community structure.

  2. 2.

Structural Modularity: An alternate measure of structural soundness of a
cluster that is more suited to software applications is defined in (Jin et al.
2019). Structural Modularity, (SM) is defined as

$SM=\frac{1}{K}\sum\limits_{k=1}^{K}\frac{u_{k}}{N^{2}_{k}}-\frac{1}{K(K-1)/2}\sum\limits_{k_{1}\not=k_{2}}^{K}\frac{\sigma_{k_{1},k_{2}}}{2(N_{k_{1}}N_{k_{2}})}$

and $u_{k}$ is the number of edges that lie completely within a cluster $k$,
$\sigma_{k_{1},k_{2}}$ is the number of edges between cluster $k_{1}$ and
cluster $k_{2}$. $N_{k_{1}}$ and $N_{k_{2}}$ are the number of members in
clusters $k_{1}$ and $k_{2}$ respectively.

  3. 3.

Non-Extreme Distribution(NED): It is desired that a microservice may not have
too many or too few classes. We therefore measure how evenly distributed the
sizes of the recommended clusters are as

$NED=\frac{\sum^{K}_{k=1,k\>not\>extreme}n_{k}}{|V|}$

$n_{k}$ is the number of classes in cluster $k$ and $V$ is the set of classes.
$k$ is not extreme if it’s size is within bounds of $\\{5,20\\}$. $NED$
captures the architectural soundness of the clusters (Wu, Hassan, and Holt
2005)(Bittencourt and Guerrero 2009). For better interpretability, we measure
$1-NED$ and lower values are favorable.

  4. 4.

Interface Number(IFN): As defined in (Jin et al. 2019), this is the average
number of published interfaces of a microservices partitioning.

$IFN=\frac{1}{K}\sum\limits_{k=1}^{K}ifn_{k},\;\;ifn_{k}=|I_{k}|$

where $I_{k}$ is the number of published interfaces in the microservice $k$
and $K$ is the number of such micorservices. We define a published interface
as any class in the microservice that is referenced by another class from a
different microservice. Lower values of $IFN$ are preferred.

###  4.3 Experimental Setup and Baselines

For each application in Table 1, we generate the adjacency matrix, $A$ and the
feature matrix, $X$. The CO-GCN encoder comprises of two layers with
dimensionality $64$ and $32$. The decoder consists of one layer of size $64$
followed by another of the appropriate feature dimension. We pretrain for
$250$ iterations and set $T=500$ in Algorithm 1. The final values of $M(i,k)$
are used as the cluster assignments from our algorithm. We set
$\\{\alpha_{1},\alpha_{2},\alpha_{3}\\}=\\{0.1,0.1,0.8\\}$ in Eq. 6.

We evaluate our approach against multiple unsupervised baselines for learning
node representations: Deepwalk (Perozzi, Al-Rfou, and Skiena 2014), Node2vec
(Grover and Leskovec 2016), ONE (Bandyopadhyay, Lokesh, and Murty 2019) GCN
(Kipf and Welling 2016) and DGI (Veličković et al. 2019). Among these, ONE
accounts for the effects of outliers in learning node embeddings. For all our
experiments, we set the size of the node embeddings to be $32$. We use
k-means++ algorithm on the embeddings generated by these baselines to obtain
clusters. K is carefully chosen based on online sources and SME inputs.In
contrast to these representation learning based baselines, the method of
(Mazlami, Cito, and Leitner 2017) is a state-of-the-art approach for
extracting microservices from a monolith application. This leverages Semantic
Coupling (SC) information with graph partitioning to identify clusters. We
also use it as a baseline. Since the implementation for the SC method does not
support .Net applications, we do not use it for DietApp.

Figure 3: Clusters and top 5 outliers identified for the PBW application, with
manual labels about their functionality. Figure 4: Results from the ablation
study on the structural modularity and modularity metrics across the
applications

###  4.4 Results on Separating Micro Services

Figure 2 shows the metrics values on all four application for the evaluated
methods. The three attributed graph neural network based methods (GCN, DGI and
CO-GCN) outperform the rest of the methods by a significant margin. The CO-GCN
method consistently achieves better modularity and structural modularity
scores which clearly validates the inclusion of outlier and clustering
objectives in the training. The CO-GCN method also achieves better $NED$ and
$IFN$ scores in most cases. Another interesting observation is the negative
scores for many of the baseline methods. This implies that are many inter-
cluster edges for the clusters recommended by these methods, hinting at the
fact that monolith applications may have several high-traffic nodes and
assigning them to appropriate clusters is difficult, but critical. Figure 3
shows the identified clusters for the PBW application and our manual
annotations to highlight the functionalities offered. We can notice the clear
distinction of functionalities

###  4.5 Detecting Outliers

The values of $O_{si}$ and $O_{ai}$ at the end of training represent the final
outlier scores of each node. The ranked list of outlier nodes represents the
top candidates for refactoring as part of microservices decomposition. Figure
3 highlights the combined top $5$ outliers detected (across structural and
attribute outlier scores) for PBW application by our approach. Among the
baselines, we report outlier detection results only for GCN and DGI as they
performed good for obtaining microservices. As GCN and DGI do not output
outliers directly, we use Isolation forest (Liu, Ting, and Zhou 2008) on the
embeddings generated by them to detect outliers.

To study the goodness of the outliers, we performed a qualitative study with
five software engineers who have minimum seven years industrial experience. We
randomly presented them with two out of the four monoliths and shared their
code repositories. We asked them to rank the top five refactor candidate
classes and compared them with the outliers identified by GCN, DGI and CO-GCN.
On an average, the top five outliers provided by the annotators overlapped
with our approach by 60%, GCN by 45% and DGI by 55%. Details of top $5$
outliers detected by each approach, our questionnaire and the results are
provided in the supplementary material. We can conclude that the outliers
identified by our approach are more relevant. The low overlap numbers indicate
the highly difficult and subjective nature of this task.

###  4.6 Ablation and Sensitivity Analysis

We perform another set of experiments to measure the usefulness of individual
components of CO-GCN.

  1. 1.

We remove the clustering objective from $\mathcal{L}_{total}$., i.e., set
$\alpha_{3}=0$ in Equation 6. Comparing the performance of this variant with
CO-GCN shows marginal contribution of integrating the clustering loss. We
denote this variant as CO-GCN~(C). We use k-means++ on the node embeddings
generated by this approach to obtain the clusters.

  2. 2.

We remove the effect of the $O_{si}$ and $O_{ai}$ on $\mathcal{L}_{str}$ and
$\mathcal{L}_{att}$ respectively, by removing the $\log(\cdot)$ terms. This is
equivalent to traditional link and attribute reconstruction, with the
clustering loss $\mathcal{L}_{clus}$. The goal is to evaluate the usefulness
of minimizing the effect of outliers for identifying good clusters. We denote
this variant as CO-GCN~(O).

The results of the ablation study are shown in Figure 4. In general,
incorporating outlier scores and the clustering objective does result in
higher modularity and structural modularity scores. However, the degree to
which these components contribute to the overall clustering quality vary for
each application and the metric used. For instance, in the Daytrader
application, removing the clustering objective reduces structural modularity
significantly, but has no effect on modularity. Conversely, removing the
outlier information reduces the modularity score, but has negligible effect on
structural modularity. This effect is also visible in the other applications.
Interestingly, removing the outlier information leads to improved modularity
for PBW, but this is balanced by a reduced structural modularity score. We can
still conclude that including the outlier scores and clustering loss in the
training objective improves cluster quality in general.

Finally, we also evaluate the effect of the node embeddings size on the
modularity and structural modularity values for each application. We
experiment with embedding sizes in $\\{8,16,32,64\\}$. The results are
presented in Figure 5. We notice the modularity scores do not have any
significant variation with a change in node embedding size. There is
relatively more variation in the structural modularity scores with change in
embedding sizes and once again, this variation is application dependent. There
is not enough evidence to make any substantial claims, but in general, the
performance seems to be better at higher embedding sizes.

Figure 5: Sensitivity analysis on embedding size

##  5 Conclusion

We introduced the traditional software engineering problem of monolith to
microservices decomposition as a clustering task building upon graph
representation learning. We showed how the application implementation
structure can be translated into an attributed graph network. We then proposed
a multi-objective Graph Convolution Network (GCN) based novel framework to not
just generate clusters which can be candidate microservices, but also
identified the outliers in the graph which can be considered as the important
refactor classes for the architect to focus on. Our approach improved state of
the art on multiple metrics from both graph and software engineering
literature and performed better than others in human evaluation for the
outlier detection. In future, we want to extend this work to automatically
identify the number of microservices and expand the studies to procedural
programming languages like COBOL.

##  6 Potential Ethical Impact (Non-Technical)

We believe this work doesn’t have any direct societal or ethical impact.

##  7 Acknowledgements

We would like to thank Giriprasad Sridhara, Amith Singhee, Shivali Agarwal,
Raunak Sinha from IBM India Research Labs and Yasu Kastuno, Ai Ishida, Aki
Tozawa, Fumiko Satoh from IBM Tokyo Research Labs for their insightful
suggestions during this work and valuable feedback towards improving the
paper.

## References

  * Arthur and Vassilvitskii (2006) Arthur, D.; and Vassilvitskii, S. 2006.  k-means++: The advantages of careful seeding.  Technical report, Stanford.
  * Bandyopadhyay, Lokesh, and Murty (2019) Bandyopadhyay, S.; Lokesh, N.; and Murty, M. N. 2019.  Outlier aware network embedding for attributed networks.  In _Proceedings of the AAAI Conference on Artificial Intelligence_ , volume 33, 12–19.
  * Bandyopadhyay et al. (2020) Bandyopadhyay, S.; Lokesh, N.; Vivek, S. V.; and Murty, M. 2020.  Outlier Resistant Unsupervised Deep Architectures for Attributed Network Embedding.  In _Proceedings of the 13th International Conference on Web Search and Data Mining_ , 25–33.
  * Bandyopadhyay, Vivek, and Murty (2020) Bandyopadhyay, S.; Vivek, S. V.; and Murty, M. N. 2020.  Integrating Network Embedding and Community Outlier Detection via Multiclass Graph Description.  In _ECAI 2020 - 24th European Conference on Artificial Intelligence, 29 August-8 September 2020, Santiago de Compostela, Spain_ , 976–983. IOS Press.  doi:10.3233/FAIA200191.
  * Bittencourt and Guerrero (2009) Bittencourt, R. A.; and Guerrero, D. D. S. 2009.  Comparison of graph clustering algorithms for recovering software architecture module views.  In _2009 13th European Conference on Software Maintenance and Reengineering_ , 251–254. IEEE.
  * Chen, Li, and Bruna (2019) Chen, Z.; Li, L.; and Bruna, J. 2019.  Supervised Community Detection with Line Graph Neural Networks.  In _International Conference on Learning Representations_.  URL https://openreview.net/forum?id=H1g0Z3A9Fm.
  * Dietrich, Gauthier, and Krishnan (2018) Dietrich, J.; Gauthier, F.; and Krishnan, P. 2018.  Driver Generation for Java EE Web Applications.  In _2018 25th Australasian Software Engineering Conference (ASWEC)_ , 121–125. IEEE.
  * Fritzsch et al. (2018) Fritzsch, J.; Bogner, J.; Zimmermann, A.; and Wagner, S. 2018.  From Monolith to Microservices: A Classification of Refactoring Approaches.  _CoRR_ abs/1807.10059.  URL http://arxiv.org/abs/1807.10059.
  * Gilmer et al. (2017) Gilmer, J.; Schoenholz, S. S.; Riley, P. F.; Vinyals, O.; and Dahl, G. E. 2017.  Neural message passing for Quantum chemistry.  In _Proceedings of the 34th International Conference on Machine Learning-Volume 70_ , 1263–1272.
  * Goldberg and Levy (2014) Goldberg, Y.; and Levy, O. 2014.  word2vec Explained: deriving Mikolov et al.’s negative-sampling word-embedding method.  _arXiv preprint arXiv:1402.3722_ .
  * Gouigoux and Tamzalit (2017) Gouigoux, J.-P.; and Tamzalit, D. 2017.  From monolith to microservices: Lessons learned on an industrial migration to a web oriented architecture.  In _2017 IEEE International Conference on Software Architecture Workshops (ICSAW)_ , 62–65. IEEE.
  * Grover and Leskovec (2016) Grover, A.; and Leskovec, J. 2016.  node2vec: Scalable feature learning for networks.  In _Proceedings of the 22nd ACM SIGKDD international conference on Knowledge discovery and data mining_ , 855–864.
  * Guo et al. (2019) Guo, S.; Lin, Y.; Feng, N.; Song, C.; and Wan, H. 2019.  Attention based spatial-temporal graph convolutional networks for traffic flow forecasting.  In _Proceedings of the AAAI Conference on Artificial Intelligence_ , volume 33, 922–929.
  * Hamilton, Ying, and Leskovec (2017) Hamilton, W. L.; Ying, R.; and Leskovec, J. 2017.  Representation learning on graphs: Methods and applications.  _arXiv preprint arXiv:1709.05584_ .
  * Jin et al. (2019) Jin, W.; Liu, T.; Cai, Y.; Kazman, R.; Mo, R.; and Zheng, Q. 2019.  Service candidate identification from monolithic systems based on execution traces.  _IEEE Transactions on Software Engineering_ .
  * Kalske et al. (2018) Kalske, M.; et al. 2018.  Transforming monolithic architecture towards microservice architecture .
  * Kingma and Ba (2014) Kingma, D. P.; and Ba, J. 2014.  Adam: A method for stochastic optimization.  _arXiv preprint arXiv:1412.6980_ .
  * Kipf and Welling (2016) Kipf, T. N.; and Welling, M. 2016.  Variational graph auto-encoders.  _arXiv preprint arXiv:1611.07308_ .
  * Kipf and Welling (2017) Kipf, T. N.; and Welling, M. 2017.  Semi-Supervised Classification with Graph Convolutional Networks.  In _5th International Conference on Learning Representations, ICLR 2017, Toulon, France, April 24-26, 2017, Conference Track Proceedings_. OpenReview.net.  URL https://openreview.net/forum?id=SJU4ayYgl.
  * Lewis and Fowler (2014) Lewis, J.; and Fowler, M. 2014.  https://www.martinfowler.com/articles/microservices.html .
  * Liang et al. (2018) Liang, J.; Jacobs, P.; Sun, J.; and Parthasarathy, S. 2018.  Semi-supervised embedding in attributed networks with outliers.  In _Proceedings of the 2018 SIAM International Conference on Data Mining_ , 153–161. SIAM.
  * Liu, Ting, and Zhou (2008) Liu, F. T.; Ting, K. M.; and Zhou, Z.-H. 2008.  Isolation forest.  In _2008 Eighth IEEE International Conference on Data Mining_ , 413–422. IEEE.
  * Mazlami, Cito, and Leitner (2017) Mazlami, G.; Cito, J.; and Leitner, P. 2017.  Extraction of Microservices from Monolithic Software Architectures.  In _2017 IEEE International Conference on Web Services (ICWS)_ , 524–531.
  * Newman (2006) Newman, M. E. 2006.  Modularity and community structure in networks.  _Proceedings of the national academy of sciences_ 103(23): 8577–8582.
  * Newman and Girvan (2004) Newman, M. E.; and Girvan, M. 2004.  Finding and evaluating community structure in networks.  _Physical review E_ 69(2): 026113.
  * Perozzi, Al-Rfou, and Skiena (2014) Perozzi, B.; Al-Rfou, R.; and Skiena, S. 2014.  Deepwalk: Online learning of social representations.  In _Proceedings of the 20th ACM SIGKDD international conference on Knowledge discovery and data mining_ , 701–710.
  * Shtern and Tzerpos (2012) Shtern, M.; and Tzerpos, V. 2012.  Clustering Methodologies for Software Engineering.  _Adv. Soft. Eng._ 2012\.  ISSN 1687-8655.  doi:10.1155/2012/792024.  URL https://doi.org/10.1155/2012/792024.
  * Taibi and Lenarduzzi (2018) Taibi, D.; and Lenarduzzi, V. 2018.  On the Definition of Microservice Bad Smells.  _IEEE Software_ 35(3): 56–62.
  * Veličković et al. (2019) Veličković, P.; Fedus, W.; Hamilton, W. L.; Liò, P.; Bengio, Y.; and Hjelm, R. D. 2019.  Deep graph infomax.  In _International Conference on Learning Representations_.  URL https://openreview.net/forum?id=rklz9iAcKQ.
  * Wu, Hassan, and Holt (2005) Wu, J.; Hassan, A. E.; and Holt, R. C. 2005.  Comparison of clustering algorithms in the context of software evolution.  In _21st IEEE International Conference on Software Maintenance (ICSM’05)_ , 525–535. IEEE.
  * Wu et al. (2020) Wu, Z.; Pan, S.; Chen, F.; Long, G.; Zhang, C.; and Philip, S. Y. 2020.  A comprehensive survey on graph neural networks.  _IEEE Transactions on Neural Networks and Learning Systems_ .
  * Yang et al. (2017) Yang, B.; Fu, X.; Sidiropoulos, N. D.; and Hong, M. 2017.  Towards k-means-friendly spaces: Simultaneous deep learning and clustering.  In _international conference on machine learning_ , 3861–3870. PMLR.
  * Zhang et al. (2019) Zhang, X.; Liu, H.; Li, Q.; and Wu, X.-M. 2019.  Attributed graph clustering via adaptive graph convolution.  In _Proceedings of the 28th International Joint Conference on Artificial Intelligence_ , 4327–4333. AAAI Press.

##  Appendix A Notation

Different notations used in the paper are summarized in Ta-2ble 1

##  Appendix B Outliers

###  B.1 Examples of an outlier from the source code

We define outliers as classes that have no unique business functionality
identity. Primarily, these are classes that are overloaded with multiple
business functionalities as seen in Figure 6. Daytrader
888https://github.com/WASdev/sample.daytrader7 is an online stock trading
monolith application. The application allows users to setup the trading
platform like configuring the database, user account and trading amount etc.
Once setup the platform allows users to view market summary, check stock
quotes, and buy or sell stocks. TradeDirect is one of the core class in the
application which implements TradeServices interface. This interface exposes
six different abstract functionalities through roughly twenty methods to
implement. TradeDirect implements the interface and provides logical support
to all six business functionalities. Now, the identity of this class is
overloaded and therefore, become top refactor candidates for the developers.
Developers tend to breakdown the methods and separate them into six classes
specific to the business functionality. There can be other type of outliers
too like classes that doesn’t support any business functionality but the core
business function classes depend on them for completion. They can be
identified by dependencies from multiple classes. Typically, utilities display
such a behavior. 2 lists the top five outliers determined by the three
attributed graph neural network based methods (CO-GCN, GCN and DGI) for each
of the four monolith applications namely Daytrader
999https://github.com/WASdev/sample.daytrader7, Plantsbywebsphere (PBW)
101010https://github.com/WASdev/sample.plantsbywebsphere, Acme-
Air111111https://github.com/acmeair/acmeair, Diet
App121212https://github.com/SebastianBienert/DietApp/.

Figure 6: TradeDirect class implements TradeServices interface to support six
different business functionalities through the twenty two methods. This
overladed business functionality classs is considered outlier class and
becomes a candidate refactorable class for the developer to break into six
classes containing only specific business function methods

###  B.2 Details of Outlier Evaluation Study

To study the goodness of the outliers, we performed a qualitative study with
five software engineers who have minimum seven years industrial experience. We
randomly presented them an overview of two out of the four four monoliths and
shared their code repositories. We requested them to manually go through the
program classes to understand the functionality exposed and the classes that
come together to support them. We intentionally did not explain the
application details since it might influence their perspective of outliers.
Application understanding is an time consuming and specialized activity. All
the annotators had prior experience in building web applications and are
proficient in the language used in the monolith applications. All the
annotator took roughly twenty four hours to study the monoliths. For the
study, we asked each annotator to rank the top five refactor candidate classes
for the two application they were presented. We then compared them with the
outliers identified by CO-GCN, GCN and DGI methods. On an average, the top
five outliers provided by the annotators overlapped with our approach by 60%,
GCN by 45% and DGI by 55%. Details of the overlap for the annotators for each
of the approaches for the four applications are listed in Table 3, Table 4
,Table 5 and Table 6. We can conclude that the outliers identified by our
approach are more relevant. The low overlap numbers also indicate the highly
difficult and subjective nature of this task.

Dataset | Approaches | Top 5 Outliers classes
---|---|---
Daytrader | CO-GCN | 1\. com.ibm.websphere.samples.daytrader.web.jsf.AccountDataJSF
2\. com.ibm.websphere.samples.daytrader.web.prims.PingJSONP
3\. com.ibm.websphere.samples.daytrader.util.FinancialUtils
4\. com.ibm.websphere.samples.daytrader.direct.TradeDirect
5\. om.ibm.websphere.samples.daytrader.TradeAction
GCN | 1\. com.ibm.websphere.samples.daytrader.web.prims.PingCDIBean
2\. com.ibm.websphere.samples.daytrader.util.TradeConfig
3\. com.ibm.websphere.samples.daytrader.util.Log
4\. com.ibm.websphere.samples.daytrader.util.TradeDirect
5\. com.ibm.websphere.samples.daytrader.web.prims.PingJSONP
DGI | 1\. com.ibm.websphere.samples.daytrader.web.jsf.QuoteData
2\. com.ibm.websphere.samples.daytrader.util.KeyBlock
3\. com.ibm.websphere.samples.daytrader.util.Log
4\. com.ibm.websphere.samples.daytrader.web.prims.PingUpgradeServlet
5\. com.ibm.websphere.samples.daytrader.web.prims.PingServletCDI
PBW | CO-GCN | 1\. com.ibm.websphere.samples.pbw.ejb.ResetDBBean
2\. com.ibm.websphere.samples.pbw.war.ShoppingBean
3\. com.ibm.websphere.samples.pbw.war.AccountBean
4\. com.ibm.websphere.samples.pbw.ejb.CustomerMgr
5\. com.ibm.websphere.samples.pbw.jpa.OrderItem
GCN | 1\. com.ibm.websphere.samples.pbw.ejb.EMailMessage
2\. com.ibm.websphere.samples.pbw.ejb.MailerBean
3\. com.ibm.websphere.samples.pbw.war.AccountBean
4\. com.ibm.websphere.samples.pbw.war.LoginInfo
5\. com.ibm.websphere.samples.pbw.jpa.Supplier
DGI | 1\. com.ibm.websphere.samples.pbw.ejb.EMailMessage
2\. com.ibm.websphere.samples.pbw.war.LoginInfo
3\. com.ibm.websphere.samples.pbw.jpa.Supplier
4\. com.ibm.websphere.samples.pbw.utils.ListProperties
5\. com.ibm.websphere.samples.pbw.war.AccountBean
Acme-Air | CO-GCN | 1\. com.acmeair.service.ServiceLocator
2\. com.acmeair.mongo.services.BookingServiceImpl
3\. com.acmeair.AirportCodeMapping
4\. com.acmeair.loader.BookingLoader
5\. com.acmeair.mongo.services.CustomerServiceImpl
GCN | 1\. com.acmeair.loader.Loader
2\. com.acmeair.config.AcmeAirConfiguration.ServiceData
3\. com.acmeair.web.BookingsREST
4\. com.acmeair.config.LoaderREST
5\. com.acmeair.mongo.services.BookingServiceImpl
DGI | 1\. com.acmeair.config.AcmeAirConfiguration.ServiceData
2\. com.acmeair.mongo.services.AuthServiceImpl
3\. com.acmeair.service.AuthService
4\. com.acmeair.service.ServiceLocator
5\. com.acmeair.service.FlightService
DietApp | CO-GCN | 1\. WebApplication1.Controllers.ManageController
2\. WebApplication1.Controllers.ProductController
3\. WebApplication1.Services.ProductService
4\. WebApplication1.Services.DietService
5\. WebApplication1.Models.DietDbContext
GCN | 1\. WebApplication1.RouteConfig
2\. WebApplication1.FilterConfig
3\. WebApplication1.Services.ProductService
4\. WebApplication1.BundleConfig
5\. WebApplication1.Repositories.Concrete.UserRepostiory
DGI | 1\. WebApplication1.Controllers.ManageController
2\. WebApplication1.Services.DietService
3\. WebApplication1.Repositories.Concrete.UserRepostiory
4\. WebApplication1.Services.ProductService
5\. WebApplication1.Controllers.EntryController
Table 2: Top five outliers detected using each of the approaches for the four monolith applications Dataset | Annotator | Approaches | # Overlapping
---|---|---|---
|  |  | Outlier classes
Daytrader | Annotator1 | CO-GCN | 3
GCN | 2
DGI | 3
Annotator2 | CO-GCN | 3
GCN | 3
DGI | 2
Table 3: Overlapping outliers for the three approaches from the two annotators for the Daytrader monolith application Dataset | Annotator | Approaches | # Overlapping
---|---|---|---
|  |  | Outlier classes
PBW | Annotator1 | CO-GCN | 3
GCN | 2
DGI | 2
Annotator2 | CO-GCN | 3
GCN | 3
DGI | 3
Table 4: Overlapping outliers for the three approaches from the two annotators for the PlantsByWebsphere monolith application Dataset | Annotator | Approaches | # Overlapping
---|---|---|---
|  |  | Outlier classes
Acme-Air | Annotator1 | CO-GCN | 2
GCN | 2
DGI | 3
Annotator2 | CO-GCN | 3
GCN | 2
DGI | 2
Table 5: Overlapping outliers for the three approaches from the two annotators for the Acme-Air monolith application Dataset | Annotator | Approaches | # Overlapping
---|---|---|---
|  |  | Outlier classes
DietApp | Annotator1 | CO-GCN | 2
GCN | 2
DGI | 2
Annotator2 | CO-GCN | 4
GCN | 2
DGI | 4
Table 6: Overlapping outliers for the three approaches from the two annotators
for the DietApp monolith application


††thanks<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>
# Layer-dependent Raman spectroscopy of ultrathin Ta2Pd3Te5

Zhenyu Sun† Institute of Physics, Chinese Academy of Sciences, Beijing 100190,
China  School of Physical Sciences, University of Chinese Academy of Sciences,
Beijing 100049, China  Zhaopeng Guo† Institute of Physics, Chinese Academy of
Sciences, Beijing 100190, China  School of Physical Sciences, University of
Chinese Academy of Sciences, Beijing 100049, China  Dayu Yan  Institute of
Physics, Chinese Academy of Sciences, Beijing 100190, China  School of
Physical Sciences, University of Chinese Academy of Sciences, Beijing 100049,
China  Peng Cheng  Institute of Physics, Chinese Academy of Sciences, Beijing
100190, China  School of Physical Sciences, University of Chinese Academy of
Sciences, Beijing 100049, China  Lan Chen  Institute of Physics, Chinese
Academy of Sciences, Beijing 100190, China  School of Physical Sciences,
University of Chinese Academy of Sciences, Beijing 100049, China  Songshan
Lake Materials Laboratory, Dongguan, Guangdong 523808, China  Youguo Shi
Institute of Physics, Chinese Academy of Sciences, Beijing 100190, China
School of Physical Sciences, University of Chinese Academy of Sciences,
Beijing 100049, China  Center of Materials Science and Optoelectronics
Engineering, University of Chinese Academy of Sciences, Beijing 100049, China
Songshan Lake Materials Laboratory, Dongguan, Guangdong 523808, China  Yuan
Huang  Advanced Research Institute of Multidisciplinary Science, Beijing
Institute of Technology, Beijing 100081, China  Zhijun Wang  Institute of
Physics, Chinese Academy of Sciences, Beijing 100190, China  School of
Physical Sciences, University of Chinese Academy of Sciences, Beijing 100049,
China  Kehui Wu  Institute of Physics, Chinese Academy of Sciences, Beijing
100190, China  School of Physical Sciences, University of Chinese Academy of
Sciences, Beijing 100049, China  Songshan Lake Materials Laboratory, Dongguan,
Guangdong 523808, China  Interdisciplinary Institute of Light-Element Quantum
Materials and Research Center for Light-Element Advanced Materials, Peking
University, Beijing, 100871, China  Baojie Feng  Institute of Physics, Chinese
Academy of Sciences, Beijing 100190, China  School of Physical Sciences,
University of Chinese Academy of Sciences, Beijing 100049, China
Interdisciplinary Institute of Light-Element Quantum Materials and Research
Center for Light-Element Advanced Materials, Peking University, Beijing,
100871, China

###### Abstract

Two-dimensional topological insulators (2DTIs) or quantum spin Hall insulators
are attracting increasing attention due to their potential applications in
next-generation spintronic devices. Despite their promising prospects,
realizable 2DTIs are still limited. Recently, Ta2Pd3Te5, a semiconducting van
der Waals material, has shown spectroscopic evidence of quantum spin Hall
states. However, achieving controlled preparation of few- to monolayer
samples, a crucial step in realizing quantum spin Hall devices, has not yet
been achieved. In this work, we fabricated few- to monolayer Ta2Pd3Te5 and
performed systematic thickness- and temperature-dependent Raman spectroscopy
measurements. Our results demonstrate that Raman spectra can provide valuable
information to determine the thickness of Ta2Pd3Te5 thin flakes. Moreover, our
angle-resolved polarized Raman (ARPR) spectroscopy measurements show that the
intensities of the Raman peaks are strongly anisotropic due to the quasi-one-
dimensional atomic structure, providing a straightforward method to determine
its crystalline orientation. Our findings may stimulate further efforts to
realize quantum devices based on few or monolayer Ta2Pd3Te5.

##  I Introduction

Topological quantum materials (TQMs) have been a topic of major interest in
condensed matter physics over the last decade QiXL2011 ; WangJ2017 ;
HasanMZ2010 . These materials possess topologically nontrivial band
structures, which can give rise to a variety of physical phenomena, such as
high carrier mobility, quantum spin/anomalous Hall effects, and axion
insulating states. Two-dimensional topological insulators (2DTIs) are a
special class of TQMs with insulating bulk states and topological edge states.
While the first type of 2DTI, quantum well systems such as HgTe/CdTe
KonigM2007  and InAs/GaSb SpantonEM2014 ; DuL2015 , posed challenges due to
the stringent requirements for composition and thickness control, recent
spectroscopic evidence suggests that several graphene-like 2D materials, such
as stanene ZhuF2015 ; DengJ2018  and bismuthene ReisF2017 , can be synthesized
in ultrahigh vacuum by molecular beam epitaxy. However, these epitaxial 2D
materials typically interact strongly with substrates and are challenging to
transfer to insulating substrates for device fabrication and transport
measurements.

In recent years, van der Waals materials represented by 1T′-MX2 (M=Mo, W; X=S,
Se, Te) have been predicted to be 2DTIs QianX2014 . However, despite these
predictions, only monolayer 1T′-WTe2 has provided transport evidence for 2DTIs
WuS2018 . In multilayer samples, QSH effects disappear due to the bulk band
gap closing. Nevertheless, a new van der Waals material, Ta2Pd3Te5, has been
recently predicted to be a 2DTI GuoZ2021 ; GuoZ2022 . Interestingly, both bulk
and monolayer samples host an inverted gap, which makes it possible to
fabricate QSH devices using multilayer samples. Compared to monolayer
materials, multilayer materials have numerous advantages such as increased
stability in ambient conditions and greater flexibility in thickness and twist
angles. Angle-resolved photoemission spectroscopy (ARPES) and scanning
tunneling spectroscopy (STS) measurements have confirmed the existence of a
bulk band gap and topological edge states in Ta2Pd3Te5 WangX2021 . Moreover,
recent transport measurements have demonstrated the existence of Tomonoga-
Luttinger liquid states in Ta2Pd3Te5 devices, indicating the coexistence of
topological order and strong correlation effects WangA2022 . However,
experimental realization of few to monolayer Ta2Pd3Te5 remains challenging,
yet is crucial for fabricating Ta2Pd3Te5-based quantum devices.

In this work, we successfully obtained large-scale few and monolayer Ta2Pd3Te5
flakes using the Au-assisted mechanical exfoliation method. Our study employed
a combination of Raman spectroscopy measurements and theoretical calculations
to identify all active vibrational modes and demonstrate their strong
anisotropy. Additionally, our investigation of the thickness-, temperature-,
and polarization-dependent behavior of Raman peaks provided critical
information for determining the thickness and crystalline orientation of
Ta2Pd3Te5 thin flakes.

##  II Methods

Ta2Pd3Te5 single crystals were synthesized using the self-flux method GuoZ2021
. High-purity Ta, Pd, and Te powders were mixed in an alumina crucible with a
molar ratio of 2:4.5:7.5, then sealed in a quartz tube, and heated to 950 ∘C
over 10 hours, dwelt for 2 days, and slowly cooled down to 800 ∘C. The extra
flux was removed by centrifuging at 800 ∘C. Large-area few to monolayer
Ta2Pd3Te5 flakes were obtained by the Au-assisted mechanical exfoliation
technique HuangY2020 . The SiO2/Si substrate was cleaned with oxygen plasma
treatment. An ultrathin Ti layer was prepared on the SiO2/Si substrate to
improve the smoothness and adhesion of the Au film. Afterward, a tape with a
freshly cleaved Ta2Pd3Te5 surface was pressed onto the Au film. Atomically
thin Ta2Pd3Te5 flakes can be obtained after removing the tape.

Optical images were acquired with an Olympus MX50 optical microscope. Atomic
force microscopy (AFM) measurements were performed using a commercial AFM
system (Oxford, Asylum Research Cypher S). Scanning electron microscopy (SEM)
measurements and energy-dispersive X-ray spectroscopy (EDS) mapping were
conducted using a commercial field-emission SEM (Hitachi, SU5000). Raman
spectroscopy measurements were performed using a micro-Raman system (Horiba
LabRam HR Evolution) with two laser sources (532 and 633 nm). The illumination
power was approximately 1 mW. The peak at 520 cm-1 originating from the Si
substrate was used to calibrate each spectrum.

First-principles calculations were performed using the Vienna ab initio
simulation package (VASP) KresseG1996-1 ; KresseG1996-2  within the projector-
augmented wave (PAW) framework BlochlPE1994 ; KresseG1999 . The generalized
gradient approximation (GGA) in Perdew-Burke-Ernzerhof (PBE) functional theory
PerdewJP1996  was used in the calculations. The energy cutoff of the plane
wave basis was set to 500 eV. A $1\times 4\times 1$ supercell was built to
calculate the Raman frequencies and irreducible representations using the
PHONOPY package TogoA2008 .

##  III Results and discussion

Ta2Pd3Te5 is a van der Waals material with a layered structure (space group:
_Pnma_). Its bulk unit cell consists of two monolayers, with each monolayer
exhibiting a two-dimensional topological insulator behavior GuoZ2021 . The
Ta2Pd3Te5 layers are stacked along the $[100]$ direction, and the adjacent
monolayers are held together by weak van der Waals interactions with a binding
energy of approximately 19.6 meV/Å2, similar to other van der Waals materials
GuoZ2021 . Hence, few and even monolayer Ta2Pd3Te5 can be obtained through
mechanical exfoliation for device fabrication. However, exfoliating large-
scale ultrathin samples on a pristine SiO2/Si substrate is challenging.
Therefore, we employed an Au-assisted method that is effective in exfoliating
transition metal dichalcogenides DesaiSB2016 ; VelickyM2018 ; LiuF2020 ;
HuangY2020  due to the enhanced adhesion between Te atoms in Ta2Pd3Te5 and Au.
Using this method, we obtained few and monolayer Ta2Pd3Te5 with high yield.
Fig. 1(a) shows a schematic drawing of the crystal structure of Ta2Pd3Te5,
while Fig. 1(b) displays a typical optical image of exfoliated Ta2Pd3Te5 thin
flakes on a Au/SiO2/Si substrate, indicating different thicknesses (1L to
10L). The thickness-dependent optical reflectivity from the green channel
image is presented in Fig. 1(c), and the linear relation is consistent with
the Fresnel-law-based model BlakeP2007 . The quality of the samples was
confirmed by atomic force microscopy (AFM) and scanning electron microscopy
(SEM) measurements, as shown in Fig. S2 and Fig. S3 within the Supplemental
Material (SM) SM . Although we also exfoliated Ta2Pd3Te5 directly on the
SiO2/Si substrate, the thinnest flakes we obtained were $\sim$4 nm thick,
approximately 6 layers of monolayer Ta2Pd3Te5.

Figure 1: (a) Schematic drawing of the crystal structure of Ta2Pd3Te5. (b)
Optical image of exfoliated Ta2Pd3Te5 thin flakes on an Au/SiO2/Si substrate,
with the number of layers indicated. (c) Relative optical reflectivity of 1-5L
extracted from the green channel image. The blue dotted line is a linear fit
of the optical reflectivity versus the number of layers.

To investigate the vibrational modes of Ta2Pd3Te5, we first conducted Raman
spectroscopy measurements on bulk materials. The results are presented in Fig.
2(a), which show several Raman peaks. The peak positions are found to be
independent of the incident light wavelength, despite variations in their
relative intensity, as shown in Fig. S4 within SM SM . To determine the
vibrational modes of each Raman peak, we performed first-principles
calculations, and the outcomes are summarized in Table S1 within SM SM . By
comparing the experimental and theoretical results, we identified 9 Ag modes
and 3 B3g modes, as indicated in Fig. 2(a). Based on the symmetry of the D2h
point group, the irreducible representation of the zone center phonon modes
are $\Gamma=20A_{g}+10B_{1g}+20B_{1u}+20B_{2g}+10B_{2u}+10B_{3g}+20B_{3u}$,
where the Ag, B1g, B2g, and B3g modes are Raman active Loudon1964 . Due to the
backscattering geometry in our measurements, only the Ag and B3g modes can be
detected according to the selection rules. These symmetry analyses are
consistent with our calculation results. The atomic displacements of these
vibrational modes are illustrated in Fig. 2(b) and Fig. S5 within SM SM ,
noting that all the B3g modes correspond to in-plane vibrations.

Figure 2: (a) Typical Raman spectrum of bulk Ta2Pd3Te5 measured with an
excitation wavelength of 532 nm, with the calculated Raman peaks indicated by
red lines. (b) Atomic displacements of the A${}_{g}^{8}$ and B${}_{3g}^{1}$
Raman modes.

After clarifying the vibrational modes of bulk Ta2Pd3Te5, we proceeded to
investigate ultrathin Ta2Pd3Te5 flakes. Figure 3(a) displays the Raman spectra
measured on different layers. As the thickness decreases, the intensity of the
Raman peaks gradually increases and then decreases towards the monolayer
limit. This phenomenon has also been observed in graphene and MoS2 and can be
attributed to the suppression of constructive interference enhancement due to
the absorption of incident and scattered light in bulk materials WangYY2008 ;
YuanH2019 . Based on the thickness-dependent Raman spectra, we have several
important observations. First, the Raman peak intensity of monolayer samples
is significantly weaker than that of few-layer or bulk samples, which may
originate from the strong charge transfer or chemical bonding at the
Ta2Pd3Te5/Au interface. The suppression of Raman signal in monolayer samples
has also been reported in exfoliated 2D materials on Au film LiG2022 . Second,
most Raman peaks show no detectable shift with respect to thickness, except
for the out-of-plane A${}_{g}^{6}$ mode at $\sim$154 cm-1, which exhibits a
blue shift with increasing thickness, as shown in Fig. S6 within SM SM . The
stiffening of the A${}_{g}^{6}$ mode in thicker films may be caused by the
increased interlayer interactions with additional layers LeeC2010 ;
YamamotoM2014 . Third, the intensity of the A${}_{g}^{1}$ mode at 89 cm-1
almost disappears when the thickness is reduced to 2L, as indicated by the
black arrows in Fig. 3(a). We will demonstrate later that the A${}_{g}^{1}$
mode reappears in 2L samples at low temperature, which can be utilized to
distinguish 1L and 2L samples. Fourth, the Raman intensity ratio of Ta2Pd3Te5
with respect to Si (520 cm-1) linearly increases with increasing thickness, as
shown in Fig. 3(b). This behavior is consistent with other van der Waals
materials HuangY2014 .

Figure 3: (a) Raman spectra of 1-10L Ta2Pd3Te5 with the excitation wavelength
set to 532 nm and the polarization parallel to the $c$ axis of Ta2Pd3Te5. (b)
Raman intensity ratio of the peak at 138 cm-1 with respect to Si as a function
of the number of layers. (c) Temperature-dependent Raman spectra of the 10L
sample in the range from 80 K to 300 K. (d) Raman spectra of the 1L and 2L
samples measured at 80, 180, 230, and 280 K, respectively.

We conducted a detailed investigation into the temperature dependence of the
vibrational modes of Ta2Pd3Te5 using Raman spectroscopy measurements from 80 K
to 300 K, as presented in Fig. 3(c). The results reported here are for the 10L
samples due to the greater Raman signal intensity. We observed a blue shift
and a noticeable linewidth sharpening for all Raman peaks as the temperature
decreased, as shown in Fig. S11 within SM SM . This behavior indicates the
suppression of anharmonic effects during cooling MenendezJ1984 ; SarkarS2020 .
Our results suggest that there is no structural phase transition, which is in
agreement with the electrical transport measurements of bulk Ta2Pd3Te5
WangX2021 . However, a careful analysis for Raman peak position and linewidth
Sorb2020  indicates that there might be an isostructural transition at around
150 K (Fig. S10-S12 within SM SM ). Since there is no obvious thickness-
dependent shift for most Raman peaks, the results are representative and
reliable for multi-layer or even bulk crystals. For the 1L sample, the
A${}_{g}^{5}$ mode had a negligible shift, which may be caused by the strong
interaction of the Au substrate, as shown in the top panel of Fig. 3(d). Such
interaction might be a covalent-like quasi-bonding between Te and Au atoms
HuangY2020 , which will suppress atomic vibrations at the interface. However,
for the 2L sample, a blue shift with decreasing temperature was observed,
which is analogous to thick samples, as shown in the bottom panel of Fig. 3(d)
and Fig. S13 within SM SM . Notably, the intensity of the A${}_{g}^{1}$ mode
in 2L samples increased at low temperatures, as indicated by the black arrows
in Fig. 3(d). Further theoretical and experimental efforts are required to
understand the origin of this behavior.

We used the ARPR technique to investigate the symmetry of the vibrational
modes of Ta2Pd3Te5. The experimental setup for ARPR spectroscopy measurements
is illustrated in Fig. 4(a). The samples were rotated continuously along the
perpendicular direction (the $[100]$ axis), while the incident light was kept
fixed. The scattered light was collected while the analyzer direction was set
parallel or perpendicular to the incident direction. The crystal orientations
of Ta2Pd3Te5 were determined by Laue diffraction measurements, as shown in
Fig. S14 within SM SM . The $[010]$ direction was defined as 0∘ in our
measurements. The ARPR measurement results are summarized in Fig. 4(b) and
4(c). We observed that the intensity of most Raman peaks exhibited periodic
oscillations with respect to the azimuth angle. In the parallel-polarized
configuration, all the Ag modes exhibited two-fold symmetry (Fig. S15 within
SM SM ). For example, the Raman intensity of the A${}_{g}^{8}$ mode reached
the maximum at 0∘ and 180∘, as shown in Fig. 4(d). In the cross-polarized
configuration, these Ag modes reached maximum intensity at 45∘, 135∘, 225∘ and
315∘ and formed a four-lobed shape in the polar graph, as shown in Fig. S16
within SM SM  and Fig. 4(e). As for the B3g modes, we observed a four-fold
symmetric angular-dependent evolution in both configurations, but the lobe was
rotated by 45∘, as shown in Fig. 4(f). These results indicated that the
vibrational modes of Ta2Pd3Te5 are strongly anisotropic.

Figure 4: (a) Schematic diagram of the ARPR measurement setup. (b) and (c)
Angular dependence of Raman intensities on the 10L sample in the parallel-
polarized (b) and cross-polarized (c) configuration, respectively. (d) and (e)
Normalized Raman intensities (red circles) of the A${}_{g}^{8}$ mode versus
the azimuth angle in the parallel-polarized (d) and cross-polarized (e)
configurations, respectively. (f) and (g) Normalized Raman intensities (red
circles) of the B3g mode versus the azimuth angle in the parallel-polarized
(f) and cross-polarized (g) configurations, respectively. The fitted results
are indicated by green dotted lines in (d)-(g). The excitation wavelength is
532 nm.

The results presented above can be well-explained using the classical Placzek
approximation Albrecht1961 ; Loudon1964 , in which the Raman intensity of a
phonon mode can be expressed as:

$I\propto\sum_{j}{\lvert\vec{e_{i}}\cdot\tilde{R_{j}}\cdot\vec{e_{a}}\rvert}^{2}$

Here, $\vec{e_{i}}$ and $\vec{e_{a}}$ are unit vectors of the incident and
scattered light polarization, and $\tilde{R_{j}}$ is a 3$\times$3 Raman
tensor. We have set the cartesian coordinates $(xyz)$ on the sample, with the
laser propagating along the $[100]$ direction. Defining the sample rotation
angle as $\theta$, and considering the Raman tensors of Ag and B3g modes,
which take the form based on the point group D2h Loudon1964 , we obtain the
following expressions:

$\tilde{R}\left(A_{g}\right)=\left({\begin{array}[]{*{20}{c}}a&0&0\\\ 0&b&0\\\
0&0&c\end{array}}\right)\tilde{R}\left(B_{3g}\right)=\left({\begin{array}[]{*{20}{c}}0&0&0\\\
0&0&d\\\ 0&d&0\end{array}}\right)$

Using these tensors, we can derive the angular-dependent intensity expressions
for the Ag and B3g modes:

$\displaystyle I_{\parallel}\left(A_{g}\right)\propto c^{2}\lvert
1+\left(\frac{b}{c}-1\right)\sin^{2}\theta\rvert^{2}$ $\displaystyle
I_{\perp}\left(A_{g}\right)\propto\frac{1}{4}\left(b-c\right)^{2}\sin^{2}2\theta$
$\displaystyle I_{\parallel}\left(B_{3g}\right)\propto d^{2}\sin^{2}2\theta$
$\displaystyle I_{\perp}\left(B_{3g}\right)\propto d^{2}\cos^{2}2\theta$

It is evident that $I_{\perp}\left(A_{g}\right)$,
$I_{\parallel}\left(B_{3g}\right)$, and $I_{\perp}\left(B_{3g}\right)$ are
proportional to $\sin^{2}2\theta$ or $\cos^{2}2\theta$. As a result, the three
vibrational modes exhibit fourfold symmetry with respect to $\theta$, in
agreement with our experimental results shown in Fig. 4(e)-4(g). The symmetry
of $I_{\parallel}\left(A_{g}\right)$ depends on the elements of the Raman
tensor, which vary for different Ag modes. Therefore, it is reasonable to
assume that the A${}_{g}^{5}$ mode has a different symmetry than the other Ag
modes in the parallel-polarized configuration.

##  IV Conclusion

In summary, we have successfully exfoliated large-area mono- to few-layer
Ta2Pd3Te5, and have conducted detailed Raman spectroscopy measurements in
combination with first-principles calculations. Our findings have clearly
revealed all observable phonon modes, and we have extensively studied the
thickness- and temperature-dependent Raman spectra. Additionally, we have
observed strong anisotropy in the intensities of the Raman peaks, and have
explained the symmetry of the Raman peaks using the classical Placzek
approximation. Our results represent a significant advancement towards the
realization of quantum devices based on few or monolayer Ta2Pd3Te5.

## Acknowledgments

This work was supported by the Ministry of Science and Technology of China
(Grant No. 2018YFE0202700), the National Natural Science Foundation of China
(Grants No. 11974391, No. 11825405, No. 1192780039, and No. U2032204), the
International Partnership Program of Chinese Academy of Sciences (Grant No.
112111KYSB20200012), the CAS Project for Young Scientists in Basic Research
(Grant No. YSBR-047), and the Strategic Priority Research Program of Chinese
Academy of Sciences (Grant No. XDB33030100).

⋆ These authors contributed equally to this work.

## References

  * (1) X.-L. Qi and S.-C. Zhang, Topological insulators and superconductors. Rev. Mod. Phys. 83, 1057-1110 (2011).
  * (2) J. Wang and S.-C. Zhang, Topological states of condensed matter. Nat. Mater. 16, 1062-1067 (2017).
  * (3) M. Z. Hasan and C. L. Kane, Colloquium: topological insulators. Rev. Mod. Phys. 82, 3045-3067 (2010).
  * (4) M. König, S. Wiedmann, C. Brüne, A. Roth, H. Buhmann, L. W. Molenkamp, X. L. Qi, and S. C. Zhang, Quantum spin Hall insulator state in HgTe quantum wells. Science 318, 766-770 (2007).
  * (5) L. Du, I. Knez, G. Sullivan, and R.-R. Du, Robust helical edge transport in gated InAs/GaSb bilayers. Phys. Rev. Lett. 114, 096802 (2015).
  * (6) E. M. Spanton, K. C. Nowack, L. Du, G. Sullivan, R.-R. Du, and K. A. Moler, Images of edge current in InAs/GaSb quantum wells. Phys. Rev. Lett. 113, 026804 (2014).
  * (7) F.-F. Zhu, W.-J. Chen, Y. Xu, C.-L. Gao, D.-D. Guan, C.-H. Liu, D. Qian, S.-C. Zhang, and J.-F. Jia, Epitaxial growth of two-dimensional stanene. Nat. Mater. 14, 1020-1025 (2015).
  * (8) J. Deng, B. Xia, X. Ma, H. Chen, H. Shan, X. Zhai, B. Li, A. Zhao, Y. Xu, W. Duan, S.-C. Zhang, B. Wang, and J. G. Hou, Epitaxial growth of ultraflat stanene with topological band inversion. Nat. Mater. 17, 1081-1086 (2018).
  * (9) F. Reis, G. Li, L. Dudy, M. Bauernfeind, S. Glass, W. Hanke, R. Thomale, J. Schäfer, and R. Claessen, Bismuthene on a SiC substrate: A candidate for a high-temperature quantum spin Hall material. Science 357, 287-290 (2017).
  * (10) X. Qian, J. Liu, L. Fu, and J. Li, Quantum spin Hall effect in two-dimensional transition metal dichalcogenides. Science 346, 1344-1347 (2014).
  * (11) S. Wu, V. Fatemi, Q. D. Gibson, K. Watanabe, T. Taniguchi, R. J. Cava, and P. Jarillo-Herrero, Observation of the quantum spin Hall effect up to 100 kelvin in a monolayer crystal. Science 359, 76-79 (2018).
  * (12) Z. Guo, D. Yan, H. Sheng, S. Nie, Y. Shi, and Z. Wang, Quantum spin Hall effect in Ta2M3Te5 (M=Pd, Ni). Phys. Rev. B 103, 115145 (2021)
  * (13) Z. Guo, J. Deng, Y. Xie and Z. Wang, Quadrupole topological insulators in Ta2M3Te5 (M = Ni, Pd) monolayers. npj Quantum Mater. 7, 87 (2022)
  * (14) X. Wang, D. Geng, D. Yan, W. Hu, H. Zhang, S. Yue, Z. Sun, S. Kumar, E. F. Schwier, K. Shimada, P. Cheng, L. Chen, S. Nie, Z. Wang, Y. Shi, Y.-Q. Zhang, K. Wu, and B. Feng, Observation of topological edge states in the quantum spin Hall insulator Ta2Pd3Te5. Phys. Rev. B 104, L241408 (2021)
  * (15) A. Wang, Y. Li, G. Yang, D. Yan, Y. Huang, Z. Guo, J. Gao, J. Huang, Q. Zeng, D. Qian, H. Wang, X. Guo, F. Meng, Q. Zhang, L. Gu, X. Zhou, G. Liu, F. Qu, L. Lu, T. Qian, Y. Shi, Z. Wang, and J. Shen, A robust and tunable Luttinger liquid in correlated edge of transition-metal second-order topological insulator Ta2Pd3Te5. arXiv:2210.06685.
  * (16) Y. Huang, Y.-H. Pan, R. Yang, L.-H. Bao, L. Meng, H.-L. Luo, Y.-Q. Cai, G.-D. Liu, W.-J. Zhao, Z. Zhou, L.-M. Wu, Z.-L. Zhu, M. Huang, L.-W. Liu, L. Liu, P. Cheng, K.-H. Wu, S.-B. Tian, C.-Z. Gu, Y.-G. Shi, Y.-F. Guo, Z. G. Cheng, J.-P. Hu, L. Zhao, G.-H. Yang, E. Sutter, P. Sutter, Y.-L. Wang, W. Ji, X.-J. Zhou, and H.-J. Gao, Universal mechanical exfoliation of large-area 2D crystals. Nat. Commun. 11, 2453 (2020).
  * (17) G. Kresse, and J. Furthmüller, Efficiency of ab-initio total energy calculations for metals and semiconductors using a plane-wave basis set. Comput. Mater. Sci. 6, 15-50 (1996).
  * (18) G. Kresse, and J. Furthmüller, Efficient iterative schemes for ab initio total-energy calculations using a plane-wave basis set. Phys. Rev. B 54, 11169-11186 (1996).
  * (19) P. E. Blöchl, Projector augmented-wave method. Phys. Rev. B 50, 17953-17979 (1994).
  * (20) G. Kresse, and D. Joubert, From ultrasoft pseudopotentials to the projector augmented-wave method. Phys. Rev. B 59, 1758-1775 (1999).
  * (21) J. P. Perdew, K. Burke, and M. Ernzerhof, Generalized gradient approximation made simple. Phys. Rev. Lett. 77, 3865-3868 (1996).
  * (22) A. Tago, F. Oba, and I. Tanaka, First-principles calculations of the ferroelastic transition between rutile-type and CaCl2-type SiO2 at high pressures. Phys. Rev. B 78, 134106 (2008).
  * (23) W. Tremel, Tetrahedral coordination of palladium in Ta2Pd3Te5: a compound with a “stuffed” Ta2NiSe5 structure. Angew. Chem. 32, 1752-1755 (1993).
  * (24) S. B. Desai, S. R. Madhvapathy, M. Amani, D. Kiriya, M. Hettick, M. Tosun, Y. Zhou, M. Dubey, J. W. Ager III, D. Chrzan, and A. Javey, Gold-mediated exfoliation of ultralarge optoelectronically-perfect monolayers. Adv. Mater. 28, 4053-4058 (2016).
  * (25) M. Velický, G. E. Donnelly, W. R. Hendren, S. McFarland, D. Scullion, W. J. I. DeBenedetti, G. C. Correa, Y. Han, A. J. Wain, M. A. Hines, D. A. Muller, K. S. Novoselov, H. D. Abru$\tilde{n}$a, R. M. Bowman, E. J. G. Santos, and F. Huang, Mechanism of gold-assisted exfoliation of centimeter-sized transition-metal dichalcogenide monolayers. ACS Nano 12, 10463-10472 (2018).
  * (26) F. Liu, W. Wu, Y. Bai, S. H. Chae, Q. Li, J. Wang, J. Hone, and X.-Y. Zhu, Disassembling 2D van der Waals crystals into macroscopic monolayers and reassembling into artificial lattices. Science 367, 903-906 (2020).
  * (27) P. Blake, E. W. Hill, A. H. Castro Neto, K. S. Novoselov, D. Jiang, R. Yang, T. J. Booth, and A. K. Geim. Making graphene visible. Appl. Phys. Lett. 91, 063124 (2007).
  * (28) See Supplemental Material at for additional optical images, AFM image, SEM images, additional Raman spectra and analyses, additional Laue diffraction pattern, and additional descriptions on Raman-active modes.
  * (29) R. Loudon, The Raman effect in crystals. Adv. Phys. 13, 423-482 (1964).
  * (30) Y. Y. Wang, Z. H. Ni, Z. X. Shen, H. M. Wang, and Y. H. Wu, Interference enhancement of Raman signal of graphene. Appl. Phys. Rev. 92, 043121 (2008).
  * (31) H. Yuan, X. Zhou, Y. Cao, Q. Bian, Z. Zhang, H. Sun, S. Li, Z. Shao, J. Hu, Y. Zhu, Z. Mao, W. Ji, and M. Pan, Raman detection of hidden phonons assisted by atomic point defects in a two-dimensional semimetal. npj 2D Mater. Appl. 3, 12 (2019).
  * (32) G. Li, X. Wu, Y. Gao, X. Ma, F. Hou, H. Cheng, Q. Huang, Y.-C. Wu, M. C. DeCapua, Y. Zhang, J. Lin, C. Liu, L. Huang, Y. Zhao, J. Han, and M. Huang, Observation of ultrastrong coupling between substrate and the magnetic topological insulator MnBi2Te4. Nano Lett. 22, 3856-3864 (2022).
  * (33) C. Lee, H. Yan, L. E. Brus, T. F. Heinz, J. Hone, and S. Ryu, Anomalous lattice vibrations of single and few-layer MoS2. ACS Nano 4, 2695-2700 (2010).
  * (34) M. Yamamoto, S. T. Wang, M. Ni, Y.-F. Lin, S.-L. Li, S. Aikawa, W.-B. Jian, K. Ueno, K. Wakabayashi, and K. Tsukagoshi, Strong enhancement of Raman scattering from a bulk-inactive vibrational mode in few-layer MoTe2. ACS Nano 8, 3895-3903 (2014).
  * (35) Y. Huang, E. Sutter, J. T. Sadowski, M. Cotlet, O. L.A. Monti, D. A. Racke, M. R. Neupane, D. Wickramaratne, R. K. Lake, B. A. Parkinson, and P. Sutter, Tin disulfide—an emerging layered metal dichalcogenide semiconductor: Materials properties and device characteristics. ACS Nano 8, 10743-10755 (2014).
  * (36) J. Menendez, and M. Cardona, Temperature dependence of the first-order Raman scattering by phonons in Si, Ge, and $\alpha$\- Sn: Anharmonic effects. Phys. Rev. B 29, 2051 (1984).
  * (37) S. Sarkar, I. Maity, H. L. Pradeepa, G. Nayak, L. Marty, J. Renard, Jo. Coraux, N. Bendiab, V. Bouchiat, S. Das, K. Majumdar, M. Jain, and A. Bid, Anharmonicity in Raman-active phonon modes in atomically thin MoS2. Phys. Rev. B 101, 205302 (2020).
  * (38) S. Yesudhas, R. Burns, B. Lavina, S. N. Tkachev, J. Sun, C. A. Ullrich, and S. Guha, Coupling of organic cation and inorganic lattice in methylammonium lead halide perovskites: Insights into a pressure-induced isostructural phase transition. Phys. Rev. Mater. 4, 105403 (2020).
  * (39) A. C. Albrecht, On the theory of Raman intensities. J. Chem. Phys. 34, 1476-1484 (1961).