A knowledge-guided hierarchical query sentence intention understanding method and system

By obtaining the fusion of multi-level semantic embedding vectors and knowledge graphs, the problem of word context and fine-grained structures in natural language query comprehension is solved, the accuracy of query comprehension and new word processing capabilities are improved, and more comprehensive semantic understanding is achieved and information extraction.

CN118939682BActive Publication Date: 2025-01-14HARBIN INSTITUTE OF TECHNOLOGY (SHENZHEN) (INSTITUTE OF SCIENCE AND TECHNOLOGY INNOVATION HARBIN INSTITUTE OF TECHNOLOGY SHENZHEN) +3
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411425826.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-14
Publication Date
2025-01-14
Estimated Expiration
2044-10-14

AI Technical Summary

Technical Problem

Existing natural language query comprehension methods ignore word context information and sentence fine-grained structure, resulting in insufficient understanding, complex preprocessing and low efficiency, making it difficult to process new words and professional terms, affecting the accuracy of query analysis.

Method used

By obtaining the multi-level semantic embedding vector of the query statement, using external knowledge graph to search related knowledge embedding vectors for fusion, adaptively adjusting weights, and combining attention mechanisms to obtain the precise representation and intention of the query statement.

Benefits of technology

The accuracy of understanding of rare words and difficult-to-understand phrases in query sentences is improved, the representation correlation and information extraction accuracy are optimized, and a more comprehensive semantic understanding is achieved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118939682B_ABST
    Figure CN118939682B_ABST
Patent Text Reader

Abstract

The present invention provides a method and system for understanding the intention of hierarchical query statements based on knowledge guidance, which relates to the technical field of natural language processing. The method includes: obtaining query statements, converting the query statements into semantic embedding vectors of different levels; converting an external knowledge graph into a knowledge embedding matrix, retrieving the knowledge embedding vectors most relevant to the semantic embedding vectors of each level in the knowledge embedding matrix, fusing the retrieved knowledge embedding vectors with the corresponding semantic embedding vectors, and obtaining the fused semantic embedding vectors of each level; obtaining a weight matrix according to the fused semantic embedding vectors of each level, and calculating the semantic embedding vectors after weight redistribution; fusing the semantic embedding vectors after weight redistribution with the text embedding vectors based on the attention mechanism, obtaining an accurate representation of the query statement, and determining the intention of the query statement. The present invention can improve the understanding and representation accuracy of query statements.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of natural language processing, and in particular to a method and system for understanding the intent of hierarchical query statements based on knowledge guidance. Background Art

[0002] Query intent understanding refers to the technology of analyzing and determining the query intent proposed by users in natural language form in natural language processing (NLP). Existing natural language query encoding mechanisms can be roughly divided into two categories: sentence-level encoders and word-level encoders. Among them, sentence-level encoders mostly use the Skip-Thought method to globally represent natural language queries. Since this type of method often ignores the modeling of word context information, it cannot accurately understand natural language queries. To solve this problem, a natural language query representation model based on word-level encoders was proposed. It first converts each word into a corresponding embedding vector by using a pre-trained word embedding model, and then uses different temporal encoding models to obtain natural language query representation. In addition, some researchers use the attention mechanism to adaptively mine keyword information in natural language queries, and obtain natural language query representation by aggregating keyword information. However, these methods all ignore the fine-grained structure inherent in sentences, resulting in insufficient natural language query understanding and representation.

[0003] Existing methods usually require the use of natural language processing toolkits to perform semantic structural decomposition of natural language queries, so the preprocessing process is relatively complicated. At the same time, the accuracy of structured parsing of offline natural language processing toolkits seriously restricts the accuracy of query statement intent understanding, which also brings great challenges to practical applications. Specifically, the current query statement intent understanding method has the following limitations:

[0004] (1) Preprocessing complexity and low processing efficiency. Current methods rely on complex preprocessing steps, including semantic structured parsing of natural language processing toolkits, which not only increases processing latency but also affects the final query understanding effect due to the parsing accuracy limitations of the toolkit. In addition, this dependence makes it difficult for the system to respond in real time, reducing its application value in real-time query systems.

[0005] (2) Incomplete semantic understanding. Although existing methods attempt to capture the global intent of a query statement through structured decomposition and semantic role trees, they often ignore the implicit details and deep semantics in the query, such as contextual dependency and implicit intent, making semantic understanding incomplete and difficult to fully meet query requirements in complex contexts.

[0006] (3) Limitations of new word recognition and processing. Although related technologies have attempted to improve the model’s adaptability to new words by modeling new words through graph convolutional networks and layout-aware pre-training, these technologies still show insufficient processing when faced with professional terms or uncommon words, making it difficult to effectively understand and represent the exact meaning of these words, affecting the overall query parsing accuracy. Summary of the invention

[0007] In order to address the deficiencies of the prior art, the object of the present invention is to provide a knowledge-guided hierarchical query statement intent understanding method and system to improve the accuracy of query statement understanding and representation.

[0008] To achieve the above objectives, according to some embodiments, a first aspect of the present invention provides a knowledge-guided hierarchical query sentence intention understanding method, comprising:

[0009] Obtain query statements and convert them into semantic embedding vectors at different levels;

[0010] Convert the external knowledge graph into a knowledge embedding matrix, retrieve the knowledge embedding vector that is most relevant to the semantic embedding vector of each level in the knowledge embedding matrix, fuse the retrieved knowledge embedding vector with the corresponding semantic embedding vector, and obtain the fused semantic embedding vector of each level;

[0011] The weight matrix is ​​obtained according to the fused semantic embedding vectors of each level, and the semantic embedding vector after weight redistribution is calculated; the semantic embedding vector after weight redistribution is fused with the text embedding vector based on the attention mechanism to obtain an accurate representation of the query statement;

[0012] Determine the intent of the query based on the precise characterization of the query.

[0013] A second aspect of the present invention provides a knowledge-guided hierarchical query sentence intention understanding system, comprising:

[0014] A semantic encoding module, configured to obtain query statements and convert the query statements into semantic embedding vectors at different levels;

[0015] A knowledge retrieval module is configured to convert an external knowledge graph into a knowledge embedding matrix, retrieve the knowledge embedding vectors in the knowledge embedding matrix that are most relevant to the semantic embedding vectors at each level, and fuse the retrieved knowledge embedding vectors with the corresponding semantic embedding vectors to obtain fused semantic embedding vectors at each level;

[0016] The semantic fusion module is configured to obtain a weight matrix according to the fused semantic embedding vectors of each level, calculate the semantic embedding vector after weight redistribution, and fuse the semantic embedding vector after weight redistribution with the text embedding vector based on the attention mechanism to obtain an accurate representation of the query statement;

[0017] The query module is configured to determine the intent of the query statement based on the precise representation of the query statement.

[0018] According to a third aspect of the present invention, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to complete the steps of the above-mentioned knowledge-guided hierarchical query statement intention understanding method.

[0019] According to a fourth aspect of the present invention, a computer-readable storage medium is provided for storing computer instructions, which, when executed by a processor, complete the steps of the above-mentioned knowledge-guided hierarchical query statement intention understanding method.

[0020] In a fifth aspect of the present invention, a computer program product is provided, including a computer program / instruction, which, when executed by a processor, implements the steps of the above-mentioned knowledge-guided hierarchical query statement intention understanding method.

[0021] Compared with the prior art, the present invention has the following beneficial effects:

[0022] The present invention provides a method and system for understanding the intention of a hierarchical query statement based on knowledge guidance, which deconstructs the query statement into a multi-level semantic embedding vector, and then performs knowledge retrieval through an external knowledge graph. By fusing the retrieved knowledge embedding vectors, the uncommon words and difficult-to-understand phrases in the statements at each level are optimized, and the understanding accuracy of the uncommon words and difficult-to-understand phrases in the query statement is effectively improved, thereby obtaining a more reliable representation of the query statement; according to the correlation between the semantic embedding vectors at each level and the query statement, the weights of the representations at different levels are adaptively adjusted to ensure that highly correlated information is processed first, thereby achieving the optimization of the query statement representation, and effectively improving the relevance of the statement representation and the accuracy of information extraction.

[0023] Advantages of additional aspects of the present invention will be given in part in the following description, and in part will become obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] The accompanying drawings in the specification, which constitute a part of the present invention, are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute improper limitations on the present invention.

[0025] Figure 1 Schematic diagram of the method in Embodiment 1 of the present invention;

[0026] Figure 2 Schematic diagram of a word representation aggregator module in Embodiment 1 of the present invention;

[0027] Figure 3 Schematic diagram of a semantic fusion network in Embodiment 1 of the present invention. DETAILED DESCRIPTION

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

[0029] Embodiment 1

[0030] Embodiment 1 of the present invention provides a method for understanding the intent of a hierarchical query sentence based on knowledge guidance, including:

[0031] S1. Obtain query statements and convert them into semantic embedding vectors at different levels.

[0032] S2. Convert the external knowledge graph into a knowledge embedding matrix, retrieve the knowledge embedding vector that is most relevant to the semantic embedding vector of each level in the knowledge embedding matrix, fuse the retrieved knowledge embedding vector with the corresponding semantic embedding vector, and obtain the fused semantic embedding vector of each level;

[0033] S3, obtain the weight matrix according to the fused semantic embedding vectors of each level, calculate the semantic embedding vector after weight redistribution; fuse the semantic embedding vector after weight redistribution with the text embedding vector based on the attention mechanism to obtain the accurate representation of the query statement;

[0034] S4. Determine the intent of the query statement based on the precise representation of the query statement.

[0035] The method provided in this embodiment, such as Figure 1-Figure 3 As shown in the figure, firstly, a pre-trained text encoder is used to convert each word in the input query into an embedding vector. On this basis, the attention mechanism and graph convolution operation are used to perform bottom-up information aggregation and feature fusion on the embedding vectors to form semantic embedding vectors at different levels. The external knowledge graph is converted into a knowledge embedding matrix by the knowledge encoder, and then the knowledge retriever is used to calculate the similarity between the semantic embedding vectors of each level and the knowledge embedding matrix, and the relevant knowledge nodes are retrieved. Then, the semantic embedding vectors of each level are fused with the retrieved knowledge embedding vectors through a multi-layer perceptron. Using the semantic fusion network, the weights of the representations of different levels are adaptively adjusted according to the correlation between the semantic embedding vectors of each level and the representation of the query statement, and the weight matrix is ​​obtained. The final fused representation of the query statement is obtained by multiplying the weight matrix with the semantic embedding vectors of each level.

[0036] Specifically, in step S1, the embedding vector representation of the query statement is first obtained, and then the multi-level semantic embedding vector of the query statement is obtained using a word representation aggregator.

[0037] S101. Obtain a user's query statement, and use a text encoder to convert the query statement into an embedding vector form to obtain a text embedding vector.

[0038] The input text (query statement) is encoded to obtain an initial encoding. In a specific implementation, the initial encoding process is to segment the independent words of a given text and convert them into text embedding vectors using a text encoder.

[0039] S102. According to the converted text embedding vector, a word representation aggregator is used to obtain semantic embedding vectors of different levels.

[0040] The text embedding vector X is divided into multiple word embedding vectors (X1, X2, X3, ..., X n ), where X1, X2, X3, ..., X n Respectively represent the 1st, 2nd, 3rd, ..., nth word embedding vectors, and n represents the length of the vector sequence. An undirected graph is constructed with these word embedding vectors as nodes, where each node corresponds to a word embedding vector. The edges between nodes are determined by calculating the cosine similarity between word embedding vectors:

[0041] ;

[0042] Among them, Similarity() means calculating cosine similarity. They represent the word embedding vector of the ath node and the word embedding vector of the bth node respectively. When the cosine similarity of two nodes is greater than the set value (here set to 0.3), an edge is constructed between the two nodes. Through the above operations, an undirected graph is obtained.

[0043] The obtained undirected graph is processed using graph convolution operations so that each node aggregates the feature information of its neighboring nodes, and then the semantic embedding vector is obtained through the average pooling layer:

[0044] ;

[0045] Among them, AveragePool() represents the average pooling layer, It means that the word embedding vector after the i-th convolution layer is averaged and pooled to obtain the i-th semantic embedding vector. Therefore, through k times of graph convolution and pooling operations, k levels of semantic embedding vectors (S1, S2, S3, ..., S k ), where S1, S2, S3, ..., S k They represent the semantic embedding vectors of the 1st, 2nd, 3rd...kth levels respectively, and k represents the number of levels.

[0046] In step S2, the knowledge items in the external knowledge graph are converted into a knowledge embedding matrix, and the knowledge nodes related to the semantic embedding vectors of each level are retrieved from the knowledge embedding matrix to provide semantic enrichment and correction for the hierarchical representation of the query statement.

[0047] S201. Obtain an external knowledge graph and use the knowledge encoder to obtain a knowledge embedding matrix.

[0048] Encode the knowledge graph to obtain the knowledge embedding vector of each knowledge, and collect the knowledge embedding vectors of all knowledge to form a knowledge embedding matrix ,in, Represents the number of knowledge embedding vectors.

[0049] S202. Use the knowledge retriever to retrieve semantic nodes related to the hierarchical content from the knowledge graph, and fuse them with the semantic embedding vectors of each level.

[0050] First, the similarity between the semantic embedding vector of each level and each knowledge embedding vector in the knowledge embedding matrix is ​​calculated. In a specific implementation, the similarity between the semantic embedding vector of each level and the knowledge embedding vector is calculated using cosine similarity:

[0051] ;

[0052] Among them, Similarity() means calculating cosine similarity. They represent the semantic embedding vector of the i-th level and the j-th knowledge embedding vector respectively.

[0053] Then, according to the calculated similarity, the knowledge embedding vector that is most similar to the semantic embedding vector of each level is obtained respectively:

[0054] ;

[0055] in, represents the knowledge embedding vector that is most similar to the semantic embedding vector of the i-th layer, Represents the selection of semantic embedding vectors from the knowledge embedding matrix The knowledge embedding vector with the highest similarity value .

[0056] Using a multi-layer perceptron, the semantic embedding vector of each level is fused with the most similar knowledge embedding vector:

[0057] ;

[0058] in, It represents the semantic embedding vector after the semantic embedding vector of the i-th level is fused with the most similar knowledge embedding vector, that is, the fused representation of the query sentence. MLP() represents a multi-layer perceptron.

[0059] In step S3, the semantic fusion network is used to adaptively adjust the weights of representations at different levels according to the correlation between the semantic embedding vectors after fusion at each level and the query statement representation, thereby obtaining an accurate representation of the query statement.

[0060] S301, through the average pooling layer, the semantic embedding vectors after fusion of each level are mapped to the dimension of the query statement representation, and then the weight matrix of the semantic embedding vectors after fusion of each level to the query statement representation is obtained:

[0061] ;

[0062] ;

[0063] ;

[0064] Among them, AveragePool() represents the average pooling layer, Represents the representation after the semantic embedding vector is mapped to the dimension of the text embedding vector, Represents the text embedding vector converted from the query statement, represents the weight corresponding to the semantic embedding vector of the i-th level, Represents the weight matrix of the query statement represented by the semantic embedding vectors fused at each level.

[0065] S302: embedding the semantic vector after fusion of each level With the weight matrix Multiply them together and obtain an accurate representation of the query sentence through the attention mechanism.

[0066] First, the semantic embedding vector is multiplied by the weight matrix to obtain the joint representation of the semantic embedding vector after weight redistribution:

[0067] ;

[0068] Among them, H represents the semantic embedding vector after weight redistribution.

[0069] Then, through the cross-attention mechanism, the semantic embedding vectors after weight redistribution are fused, and then the multi-layer perceptron is used to map the query statement to obtain the precise representation Z:

[0070] ;

[0071] ;

[0072] Among them, Y represents the representation of the fusion of semantic embedding vector and text embedding vector, CrossAtt() represents the cross attention calculation formula, and the calculation process is expressed by the following formula:

[0073] ;

[0074] in, , , , is the scaling factor, , , They are the weight matrices of the query vector Q, key vector K, and value vector V respectively.

[0075] Through the above steps, an accurate expression of the query statement's intent, that is, an accurate representation Z of the query statement, is obtained.

[0076] Embodiment 2

[0077] This embodiment provides a knowledge-guided hierarchical query sentence intention understanding system, including:

[0078] A semantic encoding module, configured to obtain query statements and convert the query statements into semantic embedding vectors at different levels;

[0079] A knowledge retrieval module is configured to convert an external knowledge graph into a knowledge embedding matrix, retrieve the knowledge embedding vectors in the knowledge embedding matrix that are most relevant to the semantic embedding vectors at each level, and fuse the retrieved knowledge embedding vectors with the corresponding semantic embedding vectors to obtain fused semantic embedding vectors at each level;

[0080] The semantic fusion module is configured to obtain a weight matrix according to the fused semantic embedding vectors of each level, calculate the semantic embedding vector after weight redistribution, and fuse the semantic embedding vector after weight redistribution with the text embedding vector based on the attention mechanism to obtain an accurate representation of the query statement;

[0081] The query module is configured to determine the intent of the query statement based on the precise representation of the query statement.

[0082] It should be noted here that the various modules in this embodiment correspond one-to-one to the steps of the method in Example 1, and the specific implementation process is the same, which will not be repeated here.

[0083] Embodiment 3

[0084] This embodiment provides an electronic device, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to complete the steps of the method in the first embodiment.

[0085] Embodiment 4

[0086] This embodiment provides a computer-readable storage medium for storing computer instructions. When the computer instructions are executed by a processor, the steps of the method in the first embodiment are completed.

[0087] Embodiment 5

[0088] This embodiment provides a computer program product, including a computer program / instruction, which implements the steps of the method in Embodiment 1 when executed by a processor.

[0089] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A knowledge-guided hierarchical query sentence intention understanding method, characterized in that: include: Obtain query statements and convert them into semantic embedding vectors at different levels; The step of converting the query statement into semantic embedding vectors of different levels includes: using a text encoder to convert the query statement into a text embedding vector; dividing the text embedding vector according to the sequence length to obtain a plurality of word embedding vectors; based on an attention mechanism and a graph convolution operation, converting each word embedding vector into a semantic embedding vector to obtain semantic embedding vectors of different levels; The text embedding vector X is divided into multiple word embedding vectors (X1, X2, X3, ..., X n ), where X1, X2, X3, ..., X n Respectively represent the 1st, 2nd, 3rd, ..., nth word embedding vectors, and n represents the length of the vector sequence; Based on the attention mechanism and graph convolution operation, each word embedding vector is converted into a semantic embedding vector to obtain semantic embedding vectors at different levels, including: Each word embedding vector is used as a node, and the edges between nodes are constructed according to the similarity between nodes to obtain an undirected graph; multiple graph convolution and pooling operations are performed on the obtained undirected graph to obtain semantic embedding vectors of different levels; the external knowledge graph is converted into a knowledge embedding matrix, and the knowledge embedding vectors most relevant to the semantic embedding vectors of each level in the knowledge embedding matrix are retrieved, and the retrieved knowledge embedding vectors are fused with the corresponding semantic embedding vectors to obtain the fused semantic embedding vectors of each level; Obtain external knowledge graph and use knowledge encoder to obtain knowledge embedding matrix; Encode the knowledge graph to obtain the knowledge embedding vector of each knowledge, and collect the knowledge embedding vectors of all knowledge to form a knowledge embedding matrix ,in, Indicates the number of knowledge embedding vectors; obtains the weight matrix based on the fused semantic embedding vectors of each level, and calculates the semantic embedding vector after weight redistribution; fuses the semantic embedding vector after weight redistribution with the text embedding vector based on the attention mechanism to obtain an accurate representation of the query statement; Get the weight matrix of the query statement represented by the semantic embedding vectors after fusion at each level: ; ; ; Among them, AveragePool() represents the average pooling layer, Represents the representation after the semantic embedding vector is mapped to the dimension of the text embedding vector, Represents the text embedding vector converted from the query statement, represents the weight corresponding to the semantic embedding vector of the i-th level, The weight matrix representing the query statement represented by the semantic embedding vectors after fusion at each level; Through the cross-attention mechanism, the semantic embedding vector after weight redistribution is fused, and then the multi-layer perceptron is used to map the query statement to obtain the precise representation Z: ; ; Among them, H represents the semantic embedding vector after weight redistribution, Y represents the representation after the fusion of the semantic embedding vector and the text embedding vector, CrossAtt() represents the cross attention calculation formula, and the calculation process is expressed by the following formula: ; in, , , , is the scaling factor, , , They are the weight matrices of query vector Q, key vector K, and value vector V respectively; Determine the intent of the query based on the precise characterization of the query.

2. The method for understanding the intention of hierarchical query sentences based on knowledge guidance as claimed in claim 1, characterized in that: The knowledge embedding vector in the retrieved knowledge embedding matrix that is most relevant to the semantic embedding vectors at each level, The method includes calculating the cosine similarity between the semantic embedding vector of each level and each knowledge embedding vector in the knowledge embedding matrix, and taking the knowledge embedding vector with the highest cosine similarity as the knowledge embedding vector most relevant to the semantic embedding vector of the corresponding level.

3. A knowledge-guided hierarchical query sentence intention understanding system, characterized in that: include: A semantic encoding module, configured to obtain query statements and convert the query statements into semantic embedding vectors at different levels; The step of converting the query statement into semantic embedding vectors of different levels includes: using a text encoder to convert the query statement into a text embedding vector; dividing the text embedding vector according to the sequence length to obtain a plurality of word embedding vectors; based on an attention mechanism and a graph convolution operation, converting each word embedding vector into a semantic embedding vector to obtain semantic embedding vectors of different levels; The text embedding vector X is divided into multiple word embedding vectors (X1, X2, X3, ..., X n ), where X1, X2, X3, ..., X n Respectively represent the 1st, 2nd, 3rd, ..., nth word embedding vectors, and n represents the length of the vector sequence; Based on the attention mechanism and graph convolution operation, each word embedding vector is converted into a semantic embedding vector to obtain semantic embedding vectors at different levels, including: Each word embedding vector is used as a node, and the edges between nodes are constructed according to the similarity between the nodes to obtain an undirected graph. The obtained undirected graph is subjected to multiple graph convolution and pooling operations to obtain semantic embedding vectors at different levels. A knowledge retrieval module is configured to convert an external knowledge graph into a knowledge embedding matrix, retrieve the knowledge embedding vectors in the knowledge embedding matrix that are most relevant to the semantic embedding vectors at each level, and fuse the retrieved knowledge embedding vectors with the corresponding semantic embedding vectors to obtain fused semantic embedding vectors at each level; Obtain external knowledge graph and use knowledge encoder to obtain knowledge embedding matrix; Encode the knowledge graph to obtain the knowledge embedding vector of each knowledge, and collect the knowledge embedding vectors of all knowledge to form a knowledge embedding matrix ,in, Represents the number of knowledge embedding vectors; The semantic fusion module is configured to obtain a weight matrix according to the fused semantic embedding vectors of each level, calculate the semantic embedding vector after weight redistribution, and fuse the semantic embedding vector after weight redistribution with the text embedding vector based on the attention mechanism to obtain an accurate representation of the query statement; Get the weight matrix of the query statement represented by the semantic embedding vectors after fusion at each level: ; ; ; Among them, AveragePool() represents the average pooling layer, Represents the representation after the semantic embedding vector is mapped to the dimension of the text embedding vector, Represents the text embedding vector converted from the query statement, represents the weight corresponding to the semantic embedding vector of the i-th level, The weight matrix representing the query statement represented by the semantic embedding vectors after fusion at each level; Through the cross-attention mechanism, the semantic embedding vector after weight redistribution is fused, and then the multi-layer perceptron is used to map the query statement to obtain the precise representation Z: ; ; Among them, H represents the semantic embedding vector after weight redistribution, Y represents the representation after the fusion of the semantic embedding vector and the text embedding vector, CrossAtt() represents the cross attention calculation formula, and the calculation process is expressed by the following formula: ; in, , , , is the scaling factor, , , They are the weight matrices of query vector Q, key vector K, and value vector V respectively; The query module is configured to determine the intent of the query statement based on the precise representation of the query statement.

4. An electronic device, characterized in that: The invention comprises a memory, a processor and a computer program stored in the memory, wherein the processor executes the computer program to complete the steps of the method according to any one of claims 1 to 2.

5. A computer-readable storage medium, characterized in that: Used to store computer instructions, which, when executed by a processor, complete the steps of the method according to any one of claims 1 to 2.

6. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the steps of the method according to any one of claims 1 to 2 are implemented.

Citation Information

Patent Citations

  • Power dispatching command knowledge enhancement representation method and system based on graph neural network

    CN117171356A