Entity alignment method and system based on graph neural network and cross-layer attention mechanism

By introducing a cross-layer attention mechanism and multi-view embedding module in the graph neural network, the accuracy and efficiency problems of traditional methods when dealing with complex entity features and cross-layer information fusion are solved, and a more efficient entity alignment effect is achieved.

CN120145294APending Publication Date: 2025-06-13CHINA THREE GORGES UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510146189.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-10
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

When traditional graph neural networks deal with complex entity features, heterogeneous relationships, and cross-level information fusion, there is insufficient matching accuracy and low computational efficiency, making it difficult to effectively capture multi-level inter-entity relationships and semantic correspondence.

Method used

The entity alignment method based on graph neural network and cross-layer attention mechanism is adopted, and the multi-view embedding module and cross-layer attention mechanism module are used to enhance the learning representation of the initial characteristics of the entity by the GCN network, and the efficient propagation and fusion of features is achieved through the entity-to-relational and relationship-to-entity interaction network.

Benefits of technology

It improves the accuracy and efficiency of entity alignment, can capture the multi-dimensional feature information of entities more comprehensively, overcomes the problem of insufficient single view information in traditional methods, and continuously improves the entity alignment model accuracy of the knowledge graph by optimizing model parameters.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120145294A_ABST
    Figure CN120145294A_ABST
Patent Text Reader

Abstract

The invention relates to an entity alignment method based on a graph neural network and a cross-layer attention mechanism, and the method comprises the following steps: dividing a collected entity alignment data set into a training set and a test set, and carrying out the initial vectorization processing of the training set and the test set; constructing an improved GCN network, inputting the entity initial vector into the improved GCN network, and realizing feature propagation and fusion by using an entity relationship bidirectional interaction network to obtain a final entity to be embedded; calculating the entity to be embedded by using the entity model to obtain an entity alignment loss result; and adjusting parameters of the improved GCN network according to an entity alignment loss result, thereby optimizing the improved GCN network. According to the method, multi-layer information extraction is carried out on the entity by combining multi-view embedding and the graph convolutional network, then information interaction can be carried out among different levels through a cross-layer attention mechanism, fusion of low-level and high-level features is enhanced, and multi-dimensional feature information of the entity can be captured more comprehensively.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of entity alignment of knowledge graphs, and in particular to an entity alignment method based on graph neural networks and cross-layer attention mechanisms. Background Art

[0002] With the rapid development of global information exchange, knowledge graphs in different languages ​​and cultural backgrounds have become important tools for information storage and transmission. In order to enable knowledge graphs from different sources and languages ​​to collaborate and share with each other, entity alignment technology has become a key task in realizing cross-language knowledge graph integration. The goal of entity alignment is to identify and match nodes representing the same entity in different graphs, which is the basis for knowledge graph fusion and semantic understanding.

[0003] In recent years, entity alignment methods based on deep learning, especially those based on graph neural networks and graph attention mechanisms, have gradually become a hot topic of research. However, traditional graph neural networks have insufficient matching accuracy and low computational efficiency when dealing with complex entity features, heterogeneous relationships, and cross-level information fusion. How to effectively capture multi-level entity relationships and semantic correspondences is a difficult problem that needs to be solved urgently. Summary of the invention The technical problem of the present invention is to strengthen the information interaction between different layers through a cross-layer attention mechanism, enhance the cross-language and cross-domain entity alignment effect, and improve the accuracy and efficiency of entity alignment.

[0004] The technical solution of the present invention is an entity alignment method based on a graph neural network and a cross-layer attention mechanism, comprising the following steps: S1: Divide the collected entity alignment dataset into a training set and a test set, and perform initial vectorization on the training set and the test set; S2: Build an improved GCN network, input the entity initial vector into the improved GCN network, and use the entity relationship bidirectional interaction network to realize feature propagation and fusion to obtain the final entity to be embedded; S3: Use the entity model to calculate the entity to be embedded and obtain the entity alignment loss result; S4: Adjust the improved GCN network parameters according to the entity alignment loss results, and then optimize the improved GCN network.

[0005] Furthermore, the improved GCN network adds a multi-view embedding module and a cross-layer attention mechanism module to the GCN network structure.

[0006] Preferably, a multi-view embedding module is used to enhance the GCN network's learning representation of the initial entity features and obtain its underlying features, middle-level features, and high-level features; a cross-layer attention mechanism module is used to perform weighted fusion on entity features at different levels to obtain entity embeddings with multi-level features.

[0007] Further, step S2 includes the following sub-steps: S21: Use the multi-view embedding module to perform multi-view enhanced learning representation on the initial entity features. The expression is: ; ; In the formula, represents different view representations of the entity, represents the initial entity embedding, is a linear transformation matrix, represents the activation function, and V represents the result of concatenating multiple view features of the entity.

[0008] S22: Perform weighted fusion on the multi-view embedding features to obtain the underlying features. The expression is: ; In the formula, represents the attention weight learning parameter, ⊙ represents element-wise multiplication, σ represents the sigmoid activation function, and h represents the obtained underlying local features.

[0009] S23: Input the underlying features into the GCN network to implement graph structure transfer and update of the entity embedding, and obtain the entity embedding that fuses neighbor node information. The expression is: ; In the formula, represents the feature representation of node v in the 0th layer, represents the weight matrix acting on the current node feature, represents the bias term, represents the set of neighbor nodes of node v, represents the degree of node v, represents the node feature representation of node v in the 1st layer.

[0010] S24: Input the entity embedding that fuses neighbor node information into a gated network to obtain the filtered information, and perform an addition operation with the unfiltered information and the underlying local features to obtain the middle-level features. The expression is as follows: ; In the formula, represents the learning parameter of the gated network, represents the fused middle-level features, and h represents the underlying local features.

[0011] S25: Take the middle - layer features as the bottom - layer features, and repeat steps S23 and S24 to obtain the high - layer features.

[0012] S26: Use a bidirectional interaction network from entity - to - relation and relation - to - entity to achieve efficient propagation and fusion of features for the entity embeddings of multi - level features, and obtain the final entity embeddings.

[0013] Further, step S22 includes the following sub - steps: S221: Stack the three - layer features into a unified tensor, and the expression is: ; where N is the number of samples, d is the feature dimension, 、 respectively represent the bottom - layer features, middle - layer features, and high - layer features of the entity embeddings.

[0014] S222: Use attention weights to weighted - fuse the features of each layer to obtain the cross - layer fusion information of the entity, and the expression is: ; where represents the cross - layer attention weight, softmax represents the normalization exponential function, represents the th layer feature after stacking, is the cross - layer fusion information of the entity.

[0015] Further, step S22 also includes performing a non - linear transformation and feature projection on the weighted - fusion result to obtain the entity embedding of the fused cross - layer features, and the expression is: ; where is the activation function used, is the linear transformation matrix, is the bias term, represents the entity embedding of the fused cross - layer features.

[0016] Further, step S26 includes the following sub - steps: S261: Generate the head - entity features and tail - entity features after linear transformation of the entity embedding, calculate the head - entity attention score and tail - entity attention score based on the head and tail entity features, and apply an activation function and normalization to obtain the weights of the head and tail entities. The expression is: ; ; ; where The parameter matrix representing the head entity and the parameter matrix of the tail entity , represent the features of the head entity and the features of the tail entity , represent the attention scores of the head entity and the attention scores of the tail entity , and respectively represent , , and is the abbreviation of, and is the attention linear transformation parameter represent the weights of the head entity and the weights of the tail entity .

[0017] S262: Using sparse matrix multiplication, combining the attention weights and the features of the head and tail entities, aggregate to obtain the head and tail relationship features, and the final relationship embedding feature is obtained after summation. The expression is: ; In the formula, represents the final relationship embedding feature, represents sparse matrix multiplication, represents the attention weight of the head entity, represents the attention weight of the tail entity.

[0018] S263: Calculate the attention scores between the relationship embedding and the entity embeddings, and at the same time perform activation and normalization processing on the attention scores to obtain the attention weights of the relationship with the head and tail entities. The expression is: ; ; In the formula, represents the normalization exponential function, represents the activation function, represents the attention mechanism parameter from the relationship to the head entity and the attention mechanism parameter from the relationship to the tail entity .

[0019] S264: Using sparse matrix multiplication to combine the attention weights of the head and tail entities with the relationship embedding, transfer the relationship features to the entities, concatenate the head and tail entity features, and generate further enhanced entity embeddings through linear transformation. The expression is: ; ; In the formula, represents sparse matrix multiplication, represents the head and tail entity features of the fused relationship features and , represents the linear transformation matrix, and [ ; ] represents the concatenation operation.

[0020] S265: By calculating the attention scores between entities, global feature propagation and fusion are performed on the enhanced entity embeddings, and non-linear activation and dropout operations are performed on the propagated features to obtain global features. The expression is as follows: ; ; ; In the formula, represents the regularization dropout layer, represents the node and 's attention weights, represents the parameter of the node attention score to be learned, represents the linear transformation weight matrix.

[0021] Furthermore, step S26 also includes concatenating the relationship embedding features obtained from S232 and the global features obtained from S235 to generate the entity embedding features finally used for model training. The expression is: ; In the formula, Concat represents the concatenation operation, is the global feature, is the relationship embedding feature.

[0022] Preferably, in step S3, it includes generating negative samples based on the training set and calculating the alignment loss using the loss function. The expression is: , ; ; In the formula, respectively represent the enhanced entity embeddings to be aligned, represents the alignment distance of the positive sample, represents the alignment distance of the negative sample, represents the threshold of the alignment distance, represents the calculated loss value.

[0023] The entity alignment system based on the graph neural network and the cross-layer attention mechanism includes the following modules: The dataset construction and preprocessing module is used to construct an entity alignment dataset, divide the entity alignment dataset into a training set and a test set, and perform initial embedding representation on the dataset using pre-trained vectors; The multi-level feature learning module uses a multi-view embedding network and a GCN network with a gating mechanism to learn the initial entity vectors and obtain low-level features, middle-level features, and high-level features; The cross-layer feature fusion module uses a cross-layer attention mechanism to perform weighted fusion of features at different layers to obtain entity embeddings with multi-level features; The entity feature fusion module realizes efficient propagation and fusion of features through a bidirectional interaction network from entity to relation and from relation to entity, and obtains the final entity embedding.

[0024] Compared with the prior art, the beneficial effects of the present invention include: 1) The present invention extracts multi-level information of entities by combining multi-view embedding and graph convolutional network, and then through the cross-layer attention mechanism, it can perform information interaction between different levels, strengthen the fusion of low-level and high-level features, and can more comprehensively capture the multi-dimensional feature information of entities, overcoming the problem of insufficient single-view information in traditional methods.

[0025] 2) The present invention adjusts the parameters by backpropagation through calculating the loss of the enhanced entities, and continuously optimizes and improves the accuracy of the entity alignment model of the knowledge graph. Brief Description of the Drawings

[0026] The present invention will be further described below in conjunction with the drawings and embodiments.

[0027] Figure 1 It is the entity alignment flowchart based on the graph neural network and cross-layer attention mechanism of the embodiment of the present invention; Figure 2 It is the overall flowchart of the improved GCN network entity alignment model of the embodiment of the present invention; Figure 3 It is the structural diagram of the improved GCN network of the embodiment of the present invention; Figure 4 It is the structural diagram of the entity relationship perception module integrating the attention mechanism of the embodiment of the present invention; Figure 5 It is the loss change curve graph of each individual module of the entity alignment model of the embodiment of the present invention; Figure 6 It is the MRR change curve graph of each individual module of the entity alignment model of the embodiment of the present invention; Figure 7 It is the Hit@1 change curve graph of each individual module of the entity alignment model of the embodiment of the present invention. Detailed Embodiments

[0028] The present invention uses hit@1, hit@10, and MRR metrics on three publicly available datasets.

[0029] As Figure 1 and Figure 2 shown, the entity alignment method based on the graph neural network and the cross-layer attention mechanism includes the following steps: S1: Divide the collected entity alignment dataset into a training set and a test set, and perform initial vectorization processing on the training set and the test set.

[0030] S2: Construct an improved GCN network, input the initial entity vectors into the improved GCN network, and use the entity relationship bidirectional interaction network to achieve feature propagation and fusion to obtain the final entity to be embedded.

[0031] As Figure 3 shown, in the improved GCN network in step S2, a multi-view embedding module and a cross-layer attention mechanism module are added to the GCN network structure to enhance the GCN network's learning representation of the initial entity features, and obtain its underlying features, middle-level features, and high-level features; the cross-layer attention mechanism module is used to perform weighted fusion on entity features at different levels to obtain entity embeddings with multi-level features.

[0032] As Figure 4 shown, the entity relationship bidirectional interaction module uses the bidirectional interaction network from entity to relationship and from relationship to entity to achieve efficient propagation and fusion of features for entity embeddings with multi-level features, and obtain the final entity embeddings.

[0033] Step S2 includes the following sub-steps: S21: Use the multi-view embedding module to perform multi-view enhanced learning representation on the initial entity features, and the expression is: ; ; In the formula, represents different view representations of the entity, represents the initial entity embedding, is the linear transformation matrix, represents the activation function, and V represents the result of concatenating multiple view features of the entity.

[0034] S22: Perform weighted fusion on the multi-view embedding features to obtain the underlying features, and the expression is: ; In the formula, represents the attention weight learning parameter, ⊙ represents element-wise multiplication, σ represents the sigmoid activation function, and h represents the obtained underlying local features.

[0035] Step S22 includes the following sub-steps: S221: Stack the three-layer features into a unified tensor, with the expression: ; In the formula, N is the number of samples, d is the feature dimension, , , respectively represent the underlying feature, middle-layer feature, and high-layer feature of the entity embedding.

[0036] S222: Use the attention weights to weight and fuse the features of each layer to obtain the cross-layer fusion information of the entity, with the expression: ; In the formula, represents the cross-layer attention weight, softmax represents the normalized exponential function, represents the -th layer feature after stacking, is the cross-layer fusion information of the entity.

[0037] S223: Perform a non-linear transformation and feature projection on the weighted fusion result to obtain the entity embedding of the fused cross-layer features, with the expression: ; In the formula, is the activation function used, is the linear transformation matrix, is the bias term, represents the entity embedding of the fused cross-layer features.

[0038] Step S22 also includes inputting the underlying features into the GCN network to implement graph structure propagation and update of the entity embedding, and obtaining the entity embedding that fuses the neighbor node information, with the expression: ; In the formula, represents the feature representation of node v in the 0-th layer, represents the weight matrix acting on the current node feature, represents the bias term, represents the set of neighbor nodes of node v, represents the degree of node v, represents the node feature representation of node v in the 1-st layer.

[0039] S24: Input the entity embedding that fuses the neighbor node information into a gated network to obtain the filtered information, and perform an addition operation with the unfiltered information and the underlying local features to obtain the middle-layer features, with the following expression: ; In the formula, represents the learning parameters of the gating network, represents the fused middle-level features, and h represents the bottom-level local features.

[0040] S25: Use the middle-level features as the bottom-level features, and repeat steps S23 and S24 once to obtain the high-level features.

[0041] S26: Use the bidirectional interaction network from entity to relation and from relation to entity to achieve efficient propagation and fusion of features for the entity embeddings of multi-level features, and obtain the final entity embeddings.

[0042] Step S26 includes the following sub-steps: S261: After performing a linear transformation on the entity embeddings, generate the head entity features and tail entity features, calculate the head and tail entity attention scores based on the head and tail entity features, and apply an activation function and normalization to obtain the weights of the head and tail entities. The expression is: ; ; ; In the formula, represents the parameter matrix of the head entity and the parameter matrix of the tail entity , represents the features of the head entity and the features of the tail entity , represents the attention score of the head entity and the attention score of the tail entity , and respectively represent , , and abbreviations of, and are the attention linear transformation parameters. represents the weight of the head entity and the weight of the tail entity .

[0043] S262: Using sparse matrix multiplication, combine the attention weights and the head and tail entity features to aggregate and obtain the head and tail relation features, and then sum them to obtain the final relation embedding feature. The expression is: ; In the formula, represents the final relation embedding feature, represents sparse matrix multiplication, represents the attention weight of the head entity, Represents the attention weight of the tail entity.

[0044] S263: Calculate the attention scores between the relation embedding and the entity embeddings, and simultaneously activate and normalize the attention scores to obtain the attention weights of the relation with the head and tail entities. The expression is: ; ; In the formula, Represents the normalization exponential function, Is the activation function used, Represents the attention mechanism parameter of the relation to the head entity And the attention mechanism parameter of the relation to the tail entity .

[0045] S264: Use sparse matrix multiplication to combine the attention weights of the head and tail entities with the relation embedding, transfer the relation features to the entities, concatenate the head and tail entity features, and generate further enhanced entity embeddings through linear transformation. The expression is: ; ; In the formula, Represents sparse matrix multiplication, Represents the head and tail entity features that fuse the relation features And , Represents the linear transformation matrix, and [ ; ] represents the concatenation operation.

[0046] S265: Through calculating the attention scores between entities, perform global feature propagation and fusion on the enhanced entity embeddings, and perform non-linear activation and random dropout operations on the propagated features to obtain the global features. The expression is as follows: ; ; ; In the formula, Represents the regularization dropout layer, Represents the node And 's attention weight, Represents the parameter of the attention scores of the nodes to be learned, Represents the linear transformation weight matrix.

[0047] Step S26 also includes concatenating the relation embedding features obtained from S232 and the global features obtained from S235 to generate the entity embedding features finally used for model training. The expression is: ; In the formula, Concat represents the concatenation operation, is the global feature, is the relational embedding feature.

[0048] S3: Use the entity model to calculate the entity to be embedded, and obtain the entity alignment loss result.

[0049] In step S3, it includes generating negative samples based on the training set and calculating the alignment loss using the loss function. The expression is: , ; ; In the formula, represents the entity embedding to be aligned after enhancement, represents the alignment distance of the positive sample, represents the alignment distance of the negative sample, represents the threshold of the alignment distance, represents the calculated loss value.

[0050] S4: Adjust the parameters of the improved GCN network according to the entity alignment loss result, and then optimize the improved GCN network.

[0051] An entity alignment method system based on a graph neural network and a cross-layer attention mechanism includes the following modules: A dataset construction and preprocessing module for constructing an entity alignment dataset, dividing the entity alignment dataset into a training set and a test set, and using pre-trained vectors to perform initial embedding representation on the dataset; A multi-level feature learning module that uses a multi-view embedding network and a GCN network with a gating mechanism to learn the initial entity vectors and obtain low-level features, middle-level features, and high-level features; A cross-layer feature fusion module that uses a cross-layer attention mechanism to perform weighted fusion of features at different layers to obtain entity embeddings with multi-level features; An entity feature fusion module that realizes efficient propagation and fusion of features through a two-way interaction network from entity to relationship and from relationship to entity, and obtains the final entity embedding.

[0052] To verify the effectiveness of the improved method proposed by the invention, experiments were carried out on three sub-datasets of DBP15K respectively, and the experimental results are as shown in Figure 5 , Figure 6 , Figure 7 and Table 1.

[0053] Table 1

[0054] In the table, each module of the model is as follows: 1) A1: Only use the cross-layer attention embedding enhancement module to enhance the representation of entities; 2) B1: Only use the entity-relationship awareness module to map and represent entities and relationships; 3) A0_B1: Combine the GCN embedding enhancement module and the entity-relationship awareness module for experiments, where the A0 module is the A1 module directly using the GCN network to verify the influence of the multi-view embedding module; 4) A1_B0: Combine the cross-layer attention embedding enhancement module and do not add the entity-relationship awareness module, where the B0 module is the graph attention mechanism module without entity-relationship awareness, used to verify the effect of the entity-relationship awareness network; 5) A1_B1: Combine the cross-layer attention embedding enhancement module to initialize the entity embedding, and use the entity-relationship awareness module to achieve the fusion representation of relationship features.

[0055] The experimental results show that the experiment using only module A1 shows better performance than that using only module B1 on all test sets, indicating that in the entity alignment task, the multi-view embedding enhancement module is more effective in capturing the diversity of node features and global graph structure information, and this module plays a more important role in the model proposed in this paper; adding B0 on the basis of A1, that is, adding a separate graph attention mechanism on the basis of multi-view embedding enhancement, shows worse experimental results than using only module A1 on each dataset. The reason is that the B0 module sets a Dropout discard rate of 0.3, resulting in some entity features being discarded. Nevertheless, the experimental results are still better than those of using only module B1, which also verifies the effectiveness of the multi-view embedding enhancement module; in order to verify the role of multi-view embedding, this paper designs the A0_B1 experimental group, that is, removes the MuEmbedNet network without adding multi-view embedding representation; compared with using only B1 for experiments, all indicators have been greatly improved, but the effect is not as good as that of using only module A1.

[0056] From the above experimental comparison results, it can be seen that the multi-view embedding enhancement module plays a key role in the model proposed in this paper. The cross-layer attention embedding enhancement module can fully capture entity features by representing entities in multiple dimensions, and the representation of entities by the GCN network and residual connection can be further enhanced; in the entity-relationship awareness module, the separate entity-relationship awareness component has a greater effect on improving the model performance. This component can further improve the alignment effect of the model by introducing the interaction features of entities and relationships, proving that relationships have a certain influence on the feature representation of entities.

[0057] The above embodiments are only the preferred technical solutions of the present invention and should not be regarded as limitations on the present invention. The protection scope of the present invention should be the technical solutions recorded in the claims, including the equivalent replacement solutions of the technical features in the technical solutions recorded in the claims. That is, equivalent replacement improvements within this scope are also within the protection scope of the present invention.

Claims

1. An entity alignment method based on graph neural network and cross-layer attention mechanism, characterized in that: The following steps are involved: S1: Divide the collected entity alignment dataset into a training set and a test set, and perform initial vectorization on the training set and the test set; S2: Build an improved GCN network, input the entity initial vector into the improved GCN network, and use the entity relationship bidirectional interaction network to realize feature propagation and fusion to obtain the final entity to be embedded; S3: Use the entity model to calculate the entity to be embedded and obtain the entity alignment loss result; S4: Adjust the improved GCN network parameters according to the entity alignment loss results, and then optimize the improved GCN network.

2. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 1, characterized in that: In step S2, the improved GCN network adds a multi-view embedding module and a cross-layer attention mechanism module to the GCN network structure.

3. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 2 is characterized in that: The multi-view embedding module is used to enhance the GCN network to learn and represent the initial features of the entity, and obtain its bottom-level features, middle-level features and high-level features; The cross-layer attention mechanism module is used to perform weighted fusion on entity features at different levels to obtain entity embedding of multi-level features.

4. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 3 is characterized in that: The step S2 comprises the following sub-steps: S21: Use the multi-view embedding module to perform multi-view enhanced learning representation on the initial features of the entity, and the expression is: ; ; In the formula, Represents different views of an entity, represents the initial embedding of the entity, represents the linear transformation matrix, represents the activation function, V represents the result of concatenating multiple view features of the entity; S22: Weighted fusion of multi-view embedding features to obtain the underlying features, expressed as: ; In the formula, represents the attention weight learning parameter, ⊙ represents element-by-element multiplication, σ represents the sigmoid activation function, and h represents the underlying local features obtained; S23: Input the underlying features into the GCN network to implement graph structure transmission and update of entity embedding, and obtain entity embedding that integrates neighbor node information. The expression is: ; In the formula, represents the feature representation of node v in layer 0, Represents the weight matrix acting on the current node feature, represents the bias term, represents the set of neighbor nodes of node v, represents the degree of node v, Represents the node feature representation of node v at the first layer; S24: The entity embedding of the fused neighbor node information is input into a gated network to obtain the filtered information, and the mid-level features are obtained by adding the unfiltered information and the bottom-level local features. The expression is: ; In the formula, represents the learning parameters of the gating network, represents the fused middle-level features, and h represents the bottom-level local features; S25: Use the middle-level features as the bottom-level features and repeat steps S23 and S24 to obtain high-level features; S26: Utilize the bidirectional interaction network from entity to relationship and relationship to entity to embed the multi-level features into entities to achieve efficient propagation and fusion of features and obtain the final entity embedding.

5. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 4 is characterized in that: Step S22 includes the following sub-steps: S221: Stack the three layers of features into a unified tensor, expressed as: ; In the formula, N is the number of samples, d is the feature dimension, , and Respectively represent the low-level features, middle-level features, and high-level features of entity embedding; S222: Use the attention weight to weight the features of each layer to obtain the cross-layer fusion information of the entity, expressed as: ; In the formula, represents the cross-layer attention weight, softmax represents the normalized exponential function, Indicates the stacked Layer features, Represents cross-layer fusion information of entities.

6. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 4, characterized in that: Step S22 also includes performing nonlinear transformation and feature projection on the weighted fusion result to obtain entity embedding of fused cross-layer features, expressed as: ; In the formula, represents the activation function used, represents the linear transformation matrix, represents the bias term, It represents the entity embedding that integrates cross-layer features.

7. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 4, characterized in that: Step S26 includes the following sub-steps: S261: After performing a linear transformation on the entity embedding, the head entity feature and the tail entity feature are generated. The head and tail entity attention scores are calculated based on the head and tail entity features, and the activation function and normalization are applied to obtain the weights of the head and tail entities. The expression is: ; ; ; In the formula, Parameter matrix representing the head entity and the parameter matrix of the tail entity , Features representing the head entity Features of the tail entity , Indicates the attention score of the head entity and the attention score of the tail entity , and Respectively , , and is the abbreviation of the attention linear transformation parameter, Indicates the weight of the head entity and the weight of the tail entity ; S262: Using sparse matrix multiplication, combined with attention weights and head and tail entity features, the head and tail relationship features are aggregated and summed to obtain the final relationship embedding feature, which is expressed as: ; In the formula, represents the final relation embedding feature, represents sparse matrix multiplication, represents the attention weight of the head entity, Represents the attention weight of the tail entity; S263: Calculate the attention score between the relationship embedding and the entity embedding, and activate and normalize the attention score to obtain the attention weights of the relationship and the head and tail entities. The expression is: ; ; In the formula, represents the normalized exponential function, is the activation function used, Indicates the parameters of the attention mechanism related to the head entity The attention mechanism parameters related to the tail entity ; S264: Use sparse matrix multiplication to combine the attention weights of the head and tail entities with the relation embedding, transfer the relation features to the entity, splice the head and tail entity features, and generate further enhanced entity embedding through linear transformation. The expression is: ; ; In the formula, represents sparse matrix multiplication, Head and tail entity features representing fused relationship features and , represents a linear transformation matrix, [ ; ] represents a concatenation operation; S265: By calculating the attention scores between entities, the enhanced entity embedding is propagated and fused globally, and the propagated features are nonlinearly activated and randomly discarded to obtain the global features. The expression is as follows: ; ; ; In the formula, represents the regularized dropout layer, Representation Node and The attention weight, Parameters representing the attention scores of the nodes to be learned, Represents the linear transformation weight matrix.

8. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 4, characterized in that: Step S26 also includes concatenating the relation embedding feature obtained by S232 and the global feature obtained by S235 to generate the entity embedding feature finally used for model training, and the expression is: ; In the formula, Concat represents the concatenation operation. is a global feature, Embedding features for relations.

9. The entity alignment method based on graph neural network and cross-layer attention mechanism according to claim 4 is characterized in that: Step S3 includes generating negative samples based on the training set and calculating the alignment loss using the loss function, which is expressed as: , ; ; In the formula, They represent the enhanced entity embeddings to be aligned, represents the alignment distance of the positive sample, represents the alignment distance of negative samples, represents the threshold of the alignment distance, Represents the calculated loss value.

10. The entity alignment system based on graph neural network and cross-layer attention mechanism as described in claims 1-7, characterized in that: include: The dataset construction and preprocessing module is used to construct an entity-aligned dataset, divide the entity-aligned dataset into a training set and a test set, and use the pre-trained vector to perform an initial embedding representation on the dataset; The multi-level feature learning module uses a multi-view embedding network and a GCN network with a gating mechanism to learn the entity initial vector and obtain low-level features, middle-level features, and high-level features; The cross-layer feature fusion module uses the cross-layer attention mechanism to weightedly fuse features from different layers to obtain entity embeddings with multi-level features; The entity feature fusion module realizes efficient propagation and fusion of features through a bidirectional interactive network from entity to relationship and from relationship to entity to obtain the final entity embedding.