Electronic official document data security storage method

By constructing directed graphs and clustering algorithms, the problem of lack of integrity verification in electronic official document data encryption is solved, accurate integrity verification and secure storage of data are achieved, and the security of data storage is improved.

CN118981803AActive Publication Date: 2024-11-19WEI COUNTY ZHICHENG DATA COMMUNICATION TECHNOLOGY CO LTD

Patent Information

Application Number
CN202411154936.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-21
Publication Date
2024-11-19
Estimated Expiration
2044-08-21

AI Technical Summary

Technical Problem

Existing electronic document data encryption methods lack data integrity verification, key leakage or improper management leads to insufficient data security, and the inability to effectively verify the integrity of data during transmission or storage.

Method used

By constructing a directed graph based on word segment semantic relationships, obtaining phrase semantic parameters and key nodes, combining depth-first search and breadth-first search algorithm traversal graphs, filtering the primary and secondary nodes, and using clustering algorithms to verify the data consistency before and after encryption. Calculate untampered coefficients to detect data tampering.

Benefits of technology

It realizes the accuracy and reliability and completeness verification of electronic official document data, improves data storage security, can deeply understand the semantic changes of phrases, identify key information and structures, and detects the accuracy and reliability of data tampering.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118981803A_ABST
    Figure CN118981803A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of natural language processing, in particular to an electronic official document data secure storage method, which comprises the following steps: carrying out word segmentation processing on electronic official document data and constructing a directed graph; obtaining key parameters and key nodes of the nodes in combination with the distribution condition of the word vector similarity relationship and the connection relationship between the nodes; performing graph traversal search on the directed graph in combination with the key parameter to obtain a main node, and obtaining an information vector of the main node according to the key parameter and the word vector of the main node; screening the non-master nodes by using the frequency and key parameters of the non-master nodes and the connection relationship in the directed graph to obtain secondary nodes; and respectively acquiring a primary node and a secondary node of the electronic official document data before and after encryption, and performing clustering by combining the information vector, thereby performing data tampering verification. According to the invention, the integrity of the electronic document data before and after encryption can be accurately and reliably verified, and the storage security of the electronic document data is improved.
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 for securely storing electronic official document data. Background Art

[0002] In information-based office, traditional paper documents cannot meet the needs of information management and are gradually being replaced by electronic documents. However, this also brings new security challenges, making the secure storage of electronic documents an important part of information-based secure office.

[0003] Currently, when encrypting electronic official document data, the encryption algorithm commonly used only provides encryption function but does not provide data integrity verification. This means that while encrypting the data, additional mechanisms may be needed to verify the integrity of the data to prevent the data from being tampered with during transmission or storage.

[0004] However, traditional data verification methods rely on keys to generate and verify authentication codes or signatures. If the keys are leaked or improperly managed, the authentication codes or signatures will become invalid, thereby reducing the reliability of data integrity verification and resulting in insufficient accuracy and reliability of data security verification results. Summary of the invention

[0005] The invention provides a method for safely storing electronic official document data to solve the existing problems.

[0006] A method for securely storing electronic official document data of the present invention adopts the following technical solution: An embodiment of the present invention provides a method for securely storing electronic document data, the method comprising the following steps: Acquire electronic official document data, perform word segmentation on the electronic official document data, and construct a directed graph based on the semantic relationship between the word segments; Combined with the distribution of similarity between word vectors corresponding to the phrase, the semantic parameters of the phrase are obtained. Combined with the semantic parameters of the phrase and the connection relationship between the corresponding nodes of the phrase in the directed graph, the key parameters of the node and the key nodes in the directed graph are obtained. Performing graph traversal search on the directed graph in combination with the key parameters to obtain a number of key node sequences, wherein the key node sequences include a number of main nodes, and obtaining information vectors of the main nodes according to the key parameters and word vectors of the main nodes; The non-primary nodes are screened by using their frequencies, key parameters and connection relationships in the directed graph to obtain secondary nodes. The primary nodes and secondary nodes of the electronic document data before and after encryption are obtained respectively and clustered in combination with the information vector, and data tampering verification is performed on the electronic document data according to the clustering results.

[0007] Furthermore, the specific method of constructing a directed graph according to the semantic relationship between the segmented words is as follows: Any kind of phrase is taken as a node in a directed graph, the word order relationship of the phrases in the electronic document data is taken as the edge of the phrases in the directed graph, the word order of any two phrases in the electronic document data is taken as the direction of the corresponding edge of the phrases in the directed graph, and the frequency of the same word order is taken as the weight of the corresponding edge. The directed graph contains a number of nodes, and the corresponding edges between different nodes include out-degree edges and in-degree edges.

[0008] Furthermore, the semantic parameters of the phrases are obtained by combining the distribution of similarity relationships between word vectors corresponding to the phrases, including the following specific methods: Use the Word2Vec algorithm to convert each phrase in the electronic document data into a word vector; For any kind of phrase, obtain the cosine similarity between the corresponding word vectors of any two phrases in the same kind of phrase; The variance of the cosine similarity between the word vectors corresponding to all phrases in any type of phrase is obtained, and recorded as the semantic parameter of the type of phrase.

[0009] Furthermore, the semantic parameters of the combined phrases and the connection relationship between the corresponding nodes of the phrases in the directed graph are combined to obtain the key parameters of the nodes and the key nodes in the directed graph, including the following specific methods: Combining the semantic parameters of the phrase and the connection relationship between the corresponding nodes of the phrase in the directed graph, the key parameters of the corresponding nodes of the phrase in the directed graph are obtained; Nodes with a critical parameter greater than A are recorded as critical nodes, where A is a preset first parameter.

[0010] Furthermore, the method of performing graph traversal search on the directed graph in combination with the key parameters to obtain a number of key node sequences includes: A depth-first search algorithm and a breadth-first search algorithm are used respectively, and a graph traversal search is performed on a directed graph in combination with key parameters of nodes and directions of corresponding edges between nodes to obtain a key node sequence, wherein the key node sequence includes a depth key node sequence and a breadth key node sequence.

[0011] Furthermore, the specific method of obtaining the information vector of the node in the key node sequence according to the key parameters and word vectors of the node in the key node sequence includes: All nodes in all key node sequences are recorded as main nodes, and a vector formed by the key parameters of each main node and the word vector of the corresponding phrase is obtained, which is recorded as the information vector of the main node.

[0012] Furthermore, the non-primary nodes are screened by using the frequencies, key parameters and connection relationships of the non-primary nodes in the directed graph to obtain the secondary nodes, including the following specific methods: The frequency of each non-main node corresponding to a phrase in the electronic document data is obtained, and the structural coefficient of the non-main node is obtained by combining the frequency, key parameters and connection relationship of the non-main node in the directed graph.

[0013] Furthermore, the method of respectively obtaining the primary nodes and secondary nodes of the electronic document data before and after encryption and clustering them in combination with the information vector includes the following specific methods: Obtaining the primary node and the secondary node in the electronic document data before and after encryption, and obtaining the information vectors of all the secondary nodes, wherein the information vectors of the secondary nodes are obtained in the same manner as the information vectors of the primary nodes; According to the Euclidean distance of the information vector between the primary node and the secondary node, the DBSCAN clustering algorithm is used to cluster all the primary nodes and secondary nodes of the electronic document data before and after encryption to obtain several clusters.

[0014] Furthermore, the data tampering verification of the electronic document data according to the clustering result includes the following specific methods: The main nodes and secondary nodes are collectively referred to as text structure points. The non-tampering coefficient is obtained based on the number of clusters and the proportion of text structure points in the clusters.

[0015] Furthermore, the specific calculation method of the untampered coefficient is:

[0016] in, Indicates the tamper-free coefficient of electronic document data; Indicates the number of clusters; Indicates the number of all text structure points; Indicates the number of text structure points in the largest cluster; Indicates the number of key nodes in the directed graph corresponding to the electronic document data before encryption; Indicates the number of key nodes in the directed graph corresponding to the encrypted electronic document data; Indicates obtaining the absolute value. Represents an exponential function with a natural constant as base.

[0017] The technical solution of the present invention has the following beneficial effects: by constructing a directed graph based on the semantic relationship between word segments, the vocabulary and its semantic relationship in the text can be structured, the semantic relationship between phrases and the text structure in the electronic official document data are characterized, the semantic characteristics of each phrase are reflected by calculating the semantic parameters of the phrase, so as to deeply understand the stability of the semantic changes of the phrase in the electronic official document data, and by combining the semantic parameters of the phrase and the node connection relationship in the directed graph, the key nodes with the most information and influence in the text can be identified, which is helpful to determine the main information and structure in the text, and by traversing the directed graph and analyzing the key node sequence, the main information flow and important text parts in the text can be found, and by analyzing the frequency, key parameters and connection relationship of non-main nodes in the directed graph, the secondary nodes can be screened out, so as to assist in understanding and supplementing the main information, and by obtaining the information vectors of the main and secondary nodes, the description of the main information in the electronic official document data is improved, and the main nodes and secondary nodes of the electronic official document data before and after encryption are respectively obtained, and clustering is performed in combination with the information vectors, so that the consistency and integrity of the electronic official document data before and after encryption can be accurately and reliably detected and verified, and the storage security of the electronic official document data is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0019] Figure 1 A flowchart of the steps of a method for securely storing electronic official document data according to the present invention; Figure 2 It is a schematic diagram of a directed graph structure; Figure 3 It is a schematic diagram of the directed graph corresponding to the text data; Figure 4 It is a schematic diagram of the directed graph corresponding to the text data after "Party A" and "Party B" are replaced with each other; Figure 5 This is a schematic diagram of the directed graph corresponding to the text data after "rights" and "obligations" are replaced with each other. DETAILED DESCRIPTION

[0020] In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined invention purpose, the following is a detailed description of the specific implementation method, structure, features and effects of a method for secure storage of electronic official document data proposed by the present invention in combination with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.

[0021] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.

[0022] The specific scheme of the method for securely storing electronic document data provided by the present invention is described in detail below with reference to the accompanying drawings.

[0023] See also Figure 1 , which shows a flowchart of a method for securely storing electronic document data provided by an embodiment of the present invention, the method comprising the following steps: Step S001, obtaining electronic document data, performing word segmentation processing on the electronic document data, and constructing a directed graph based on the semantic relationship between the word segments.

[0024] It should be noted that electronic official document data, as text data, contains several phrases, which are formed by the combination of word order relationships. In order to better characterize and quantify the text structure characteristics of electronic official document data, a corresponding graph structure is constructed by converting its data structure, which can effectively reflect the text structure of electronic official document data while reducing the amount of data.

[0025] Specifically, in order to implement a method for securely storing electronic document data proposed in this embodiment, it is first necessary to collect the electronic document data, and the specific process is as follows: First, the text data in the electronic document data is obtained. When the electronic document data is in the image format, the text data in the image is extracted using OCR technology.

[0026] Then, the electronic document data is segmented using the Jieba word segmentation algorithm. In the word segmentation process, the text data in the electronic document data is not considered, and several phrases are obtained. The same phrase is regarded as a phrase, and several types of phrases are obtained.

[0027] Finally, a directed graph is constructed, with any phrase as a node in the directed graph, the word order relationship of the phrases in the electronic document data as the edge of the phrases in the directed graph, the word order of any two phrases in the electronic document data as the direction of the corresponding edge of the phrases in the directed graph, and the frequency of the same word order as the weight of the corresponding edge.

[0028] It should be noted that the directed graph contains several nodes, and the corresponding edges between different nodes include out-degree edges and in-degree edges, such as Figure 2 The figure shows a schematic diagram of a directed graph structure, where for node 2, edge 1 and edge 2 are the two out-degree edges of node 2, edge 3 is the one in-degree edge of node 2, weight 1, weight 2 and weight 3 are the corresponding weights of edge 1, edge 2 and edge 3 respectively. Similarly, it can be seen that edge 1 is the in-degree edge of node 1, edge 2 is the in-degree edge of node 3, and edge 3 is the out-degree edge of node 3.

[0029] For example, there is text data: Party A's rights and obligations: responsible for Party B's personnel management and responsible for paying Party B's salary; Party B's rights and obligations: accept Party A's management and enjoy salary benefits.

[0030] After word segmentation, the included words are: Party A, of, rights, and, obligations, responsible, Party B, personnel, management, responsible, pay, salary, accept, enjoy, treatment; the schematic diagram of the directed graph corresponding to the text data is as follows Figure 3 shown.

[0031] It should be noted that the Jieba word segmentation algorithm is an existing word segmentation method, so this embodiment will not be described in detail.

[0032] At this point, the electronic document data and the corresponding directed graph are obtained through the above method.

[0033] Step S002, combining the distribution of similarity relationships between word vectors corresponding to the phrases, obtaining the semantic parameters of the phrases, combining the semantic parameters of the phrases and the connection relationships between the corresponding nodes of the phrases in the directed graph, obtaining the key parameters of the nodes and the key nodes in the directed graph.

[0034] It should be noted that since the edges between different nodes in a directed graph represent the word order relationship of the corresponding phrases in the electronic document data, the network structure formed between the nodes reflects the text structure of the electronic document data. Therefore, when the integrity of the electronic document data is destroyed during the encrypted storage process, that is, the electronic document data is tampered with, the text structure of the electronic document data will change, thereby causing the network structure of the directed graph to change.

[0035] The direction of the edge between nodes in a directed graph reflects the word order of the phrase corresponding to the node in the electronic document data. When the electronic document data is tampered with, the tampering usually includes: word order permutation, phrase replacement, insertion, deletion, etc., which will cause the number or word order of the phrases to change. When the number of phrases changes, the connection relationship between the node corresponding to the phrase and other nodes in the directed graph will change. When the word order of the phrase changes, the direction of the edge corresponding to the node corresponding to the phrase and other nodes will change. In addition, since nouns, verbs, adjectives, prepositions, and conjunctions in official documents are crucial to understanding and processing the content of official documents, special attention should be paid to the phrases corresponding to the above parts of speech in the directed graph.

[0036] For example, if the text data in the above example is tampered with so that "Party A" and "Party B" are replaced with each other, it is tampered with as follows: Party B's rights and obligations: responsible for Party A's personnel management and responsible for paying Party A's salary; Party A's rights and obligations: accept Party B's management and enjoy salary benefits; Figure 4 Shown is a schematic diagram of the directed graph corresponding to the text data after "Party A" and "Party B" are replaced with each other.

[0037] according to Figure 4 It can be seen that the connection relationship between the corresponding nodes of the phrases "Party A" and "Party B" and other nodes has undergone significant changes compared to before the tampering, and the semantic information expressed by the text data before and after the tampering has also undergone tremendous changes.

[0038] However, if the phrases "rights" and "obligations" are swapped, the text data becomes: Party A's obligations and rights: responsible for Party B's personnel management and responsible for paying Party B's salary; Party B's obligations and rights: accept Party A's management and enjoy salary benefits; although the connection relationship between the corresponding nodes in the corresponding directed graph will also change (such as Figure 5 The figure shows a diagram of the directed graph corresponding to the text data after "rights" and "obligations" are replaced with each other), but the semantic information has not changed. Therefore, when the part of speech is the same, the criticality of different phrases will be different.

[0039] It should be noted that the embodiments of the present invention take into account that due to the different word order relationships or combination relationships between the same type of phrases and other phrases in the electronic document data, the meanings expressed by the phrases contained in the same type of phrases in the electronic document data may be different. Therefore, by obtaining the similarity relationship between the corresponding word vectors of each phrase in the same type of phrases, the stability of the semantics expressed by the phrases of this type is further analyzed.

[0040] Step 201, obtaining semantic parameters of a phrase based on the distribution of similarity relationships between word vectors corresponding to the phrase.

[0041] Specifically, as an embodiment, the method for obtaining the semantic parameters of a phrase includes: First, the Word2Vec algorithm is used to convert each phrase in the electronic document data into a word vector.

[0042] Then, for any kind of phrase, the cosine similarity between the corresponding word vectors of any two phrases in the same kind of phrase is obtained.

[0043] Finally, the variance of the cosine similarity between the word vectors corresponding to all phrases in any type of phrase is obtained and recorded as the semantic parameter of the type of phrase.

[0044] It should be noted that the semantic parameter is used to describe the stability of the corresponding semantic information of the corresponding type of phrase in the electronic document data. The smaller the semantic parameter, the embodiment of the present invention takes into account that the change of the combination relationship between the same type of phrase and other phrases in the text data will cause the semantic information to change. The Word2Vec algorithm can be used to combine the combination or word order relationship of the phrase with other phrases in the text data to obtain the vector of the phrase. Therefore, the embodiment of the present invention converts the phrase into a word vector to fully quantify and represent the specific meaning of the phrase contained in the same type of phrase in the electronic document data.

[0045] It should be noted that the Word2Vec algorithm is an existing word vector conversion algorithm, so this embodiment will not be described in detail.

[0046] Step 202: Acquire key parameters of the nodes corresponding to the phrase in the directed graph by combining the semantic parameters of the phrase and the connection relationship between the corresponding nodes of the phrase in the directed graph.

[0047] It should be noted that, in electronic official document data, phrases such as nouns, verbs, and adjectives usually have stable meanings, and the word order or combination relationship with other phrases will not change much, so the corresponding semantic parameters are small; in addition, the embodiment of the present invention takes into account that although the phrases connected by some prepositions and conjunctions in the text data will undergo more changes, they can accurately represent the relationship between the previous and next phrases, and therefore the role they produce in the text structure cannot be ignored. Therefore, in order to more accurately represent the text structure characteristics of the phrase in the electronic official document data, so as to facilitate the subsequent verification of whether the electronic official document data has been tampered with, the embodiment of the present invention obtains the key parameters of the corresponding nodes of the phrase in the directed graph by combining the semantic parameters of the phrase and the connection relationship between the corresponding nodes of the phrase in the directed graph.

[0048] Specifically, as an embodiment, a method for obtaining key parameters of a node corresponding to a phrase in a directed graph includes: The node corresponding to any type of phrase in the electronic document data in the directed graph is recorded as the target node, and the specific calculation method of the key parameters of the target node is:

[0049] in, Indicates the key parameters of the target node; Indicates the semantic parameters of the phrase corresponding to the target node; The target node The semantic parameters of the nodes corresponding to the out-degree edges; The target node The out-degree edges correspond to weights; Indicates the number of out-degree edges of the target node; The target node The semantic parameters of the nodes corresponding to the in-degree edges; The target node The in-degree edges correspond to weights; Indicates the number of in-degree edges of the target node; represents the linear normalization function.

[0050] Step 203: record the nodes whose key parameters are greater than A as key nodes, where A is a preset first parameter.

[0051] It should be noted that, based on experience, the first parameter A is usually preset to 0.7, and it can be adjusted according to actual conditions, and this embodiment does not specifically limit it.

[0052] It should be noted that the smaller the semantic parameter of the phrase corresponding to the node, the more stable the semantic information expressed by the phrase corresponding to the node in the corresponding electronic document data, and the greater the weight of the out-degree edge or in-degree edge corresponding to the node, it reflects that the text structure characteristics of the phrase corresponding to the node in the corresponding electronic document data are more obvious, and the role of the node in the text structure is greater, that is, the more critical the node is. Therefore, this embodiment obtains the criticality parameter by combining the semantic parameter of the node with the weight of the out-degree edge and in-degree edge corresponding to the node, which indicates the criticality of the corresponding node in the directed graph for subsequent verification of data security, that is, when the corresponding phrase of the node in the electronic document data is tampered with, the greater the degree of change of the semantic information in the electronic document data, the higher the accuracy and reliability of the detection result when the corresponding node is used for data security verification, the greater the criticality of the node corresponding to the phrase, and the greater the criticality of the node.

[0053] So far, the key parameters of each node in the directed graph and several key nodes are obtained through the above method.

[0054] Step S003, performing graph traversal search on the directed graph in combination with key parameters to obtain several key node sequences, wherein the key node sequences include several main nodes, and obtaining information vectors of the main nodes according to the key parameters and word vectors of the main nodes.

[0055] It should be noted that, when the embodiment of the present invention takes into account the existence of semantic or text structure associations between phrases with high criticality in electronic document data, the association structure formed between these phrases effectively represents the main text structure in the electronic document data. Therefore, by performing a graph traversal search on the directed graph of the electronic document data, nodes with obvious text structure features are obtained to facilitate subsequent data tampering verification.

[0056] Step 301 , using a depth-first search algorithm and a breadth-first search algorithm respectively, and combining the key parameters of the nodes and the directions of the corresponding edges between the nodes to perform a graph traversal search on the directed graph, to obtain a key node sequence.

[0057] The key node sequence includes a depth key node sequence and a breadth key node sequence, and the specific acquisition method is: As an embodiment, the specific steps of obtaining the deep key node sequence are: Firstly, the key node with the largest critical parameter in the directed graph is taken as the starting point, and any key node is taken as the ending point, and the depth-first search algorithm is used to traverse the directed graph.

[0058] Then, during the search process, the search is performed in the direction of the corresponding edges between the nodes to obtain several search paths between the starting point and any ending point. The sequence formed by all the nodes on the search path is obtained in the search order, which is recorded as the first key node sequence. Among the key node sequences formed by the starting point and all the ending points respectively, the B first key node sequences with the largest number of key nodes are recorded as deep key node sequences, where B is the preset second parameter.

[0059] It should be noted that, based on experience, the second parameter is usually preset to 20, and can be adjusted according to actual conditions, and is not specifically limited in the embodiment of the present invention.

[0060] As an embodiment, the specific steps of obtaining the breadth key node sequence are: First, the breadth-first search algorithm is used to traverse the nodes in the directed graph to obtain the shortest path between any two key nodes. In the process of traversal using the breadth-first search algorithm, the search is also performed in the direction between the nodes.

[0061] Then, a sequence formed by all nodes on the C shortest paths passing through the largest number of key nodes among the shortest paths between all key nodes is obtained, which is recorded as a breadth key node sequence, where C is a preset third parameter.

[0062] It should be noted that, based on experience, the third parameter is usually preset to 20, and can be adjusted according to actual conditions, and is not specifically limited in the embodiment of the present invention.

[0063] It should be noted that the embodiment of the present invention takes into account that the connection direction between nodes in the directed graph reflects the word order of the corresponding phrases in the electronic document data, and the change of the word order also represents that the electronic document data has been tampered with. Therefore, in the process of traversing the directed graph, the embodiment of the present invention performs a traversal search in the direction of the corresponding edges between the nodes, effectively retaining the word order information between the phrases, and ensuring the reliability of the verification result when the data tampering verification is performed later; in addition, the method of following the direction of the corresponding edges between the nodes during the search process is specifically, for example: Figure 3 In the search, you can only search from "Party A" to "Management", but not from "Management" to "Party A".

[0064] Step 302, all nodes in all key node sequences are recorded as main nodes, and a vector formed by the key parameters of each main node and the word vector of the corresponding phrase is obtained, and recorded as the information vector of the main node.

[0065] It should be noted that the method for obtaining the information vector is, for example, that the key parameter of the main node is 0.8, and the word vectors of the corresponding phrases include: 11, 12, 21, then the information vectors of the main node are: , , .

[0066] Step S004, screening the non-primary nodes by using the frequencies, key parameters and connection relationships of the non-primary nodes in the directed graph to obtain secondary nodes.

[0067] It should be noted that if only the main node is used for data tampering verification, false positives and missed positives may occur due to over-reliance on the phrases corresponding to the main node. Therefore, the embodiment of the present invention chooses to screen out secondary nodes by analyzing the frequency of non-main nodes in electronic documents and the graph structure information in the directed graph, while ensuring that the key text structure can be verified not to be tampered with.

[0068] First, the frequency of each non-main node corresponding to the phrase in the electronic document data is obtained, and the structural coefficient of the non-main node is obtained by combining the frequency, key parameters and connection relationship of the non-main node in the directed graph.

[0069] Optionally, in one embodiment, the specific calculation method of the structural coefficient of any non-primary node is:

[0070] in, Represents the structural coefficient of non-primary nodes; Indicates the frequency of the phrase corresponding to the non-main node in the electronic document data; Indicates the key parameters of non-primary nodes; Indicates the number of key nodes connected in the out-degree edges of non-primary nodes; Indicates the number of key nodes connected to the in-degree edges of non-primary nodes; represents an exponential function with a natural constant as base; represents the linear normalization function.

[0071] It should be noted that, since data tamperers may bypass the use of primary nodes for data tampering verification by changing the corresponding phrases of non-primary nodes or using synonyms, screening secondary primary nodes can help capture more subtle tampering traces. These phrases may have important semantic functions in specific contexts; in addition, although the phrases corresponding to some nodes in non-primary nodes may appear less frequently in the text, their existence or changes may indicate tampering, including these phrases, which can help reduce underreporting in verification, that is, detecting tampering that is not detected by keywords. Therefore, by combining the number of connections between out-degree edges, in-degree edges and primary nodes, the critical parameters of non-primary nodes and the frequency of non-primary node corresponding phrases in electronic document data, it more accurately reflects the degree of influence of non-primary nodes on the overall meaning and text structure of electronic document data. The larger the structural coefficient of non-primary nodes, the greater the degree of influence of non-primary node corresponding phrases in electronic document data.

[0072] Then, the structural coefficient is greater than The non-master node is used as the secondary node, where D is the preset fourth parameter.

[0073] Finally, the information vectors of all secondary nodes are obtained. The information vectors of the secondary nodes are obtained in the same way as the information vector of the primary node.

[0074] It should be noted that, based on experience, the fourth parameter is usually preset to 0.6, and can be adjusted according to actual conditions, and is not specifically limited in the embodiment of the present invention.

[0075] So far, several secondary nodes and the information vector of each secondary node are obtained through the above method.

[0076] Step S005, respectively obtaining the primary node and the secondary node of the electronic document data before and after encryption and clustering them in combination with the information vector, and performing data tampering verification on the electronic document data according to the clustering result.

[0077] Specifically, in step 501, the primary nodes and secondary nodes of the electronic document data before and after encryption are respectively obtained and clustered.

[0078] First, the primary node and the secondary node in the electronic document data before and after encryption are obtained.

[0079] Then, according to the Euclidean distance of the information vector between the primary node and the secondary node, the DBSCAN clustering algorithm is used to cluster all the primary nodes and secondary nodes of the electronic document data before and after encryption to obtain several clusters.

[0080] Step 502: verify the electronic document data for data tampering based on the clustering results.

[0081] First, the main nodes and secondary nodes are collectively referred to as text structure points, and the non-tampering coefficient is obtained according to the number of clusters and the proportion of text structure points in the clusters.

[0082] As an embodiment, the specific calculation method of the untampered coefficient is:

[0083] in, Indicates the tamper-free coefficient of electronic document data; Indicates the number of clusters; Indicates the number of all text structure points; Indicates the number of text structure points in the largest cluster; Indicates the number of key nodes in the directed graph corresponding to the electronic document data before encryption; Indicates the number of key nodes in the directed graph corresponding to the encrypted electronic document data; Indicates obtaining the absolute value. Represents an exponential function with a natural constant as base.

[0084] It should be noted that the larger the non-tampering coefficient is, the greater the probability that the electronic document data has not been tampered with, or in other words, the smaller the degree to which the electronic document data has been tampered with is.

[0085] Then, it is determined whether the electronic document data has been tampered with based on the size of the non-tampering coefficient.

[0086] As an embodiment, the specific determination method is: when When the electronic document data is tampered with; when When the electronic document data content changes; when When a warning is issued, it is suggested that the electronic document data has been tampered with, where E is the preset fifth parameter.

[0087] It should be noted that E is preset to 0.95 based on experience and can be adjusted according to actual conditions, and is not specifically limited in this embodiment.

[0088] At this point, this embodiment is completed.

[0089] It should be noted that the The model is only used to represent negative correlation and constrain the output of the model to be in In the specific implementation, it can be replaced by other models with the same purpose. This embodiment is only based on The model is described as an example without any specific limitation. is the input to the model.

[0090] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A method for securely storing electronic document data, characterized in that: The method comprises the following steps: Acquire electronic official document data, perform word segmentation on the electronic official document data, and construct a directed graph based on the semantic relationship between the word segments; Combined with the distribution of similarity between word vectors corresponding to the phrase, the semantic parameters of the phrase are obtained. Combined with the semantic parameters of the phrase and the connection relationship between the corresponding nodes of the phrase in the directed graph, the key parameters of the node and the key nodes in the directed graph are obtained. Performing graph traversal search on the directed graph in combination with the key parameters to obtain a number of key node sequences, wherein the key node sequences include a number of main nodes, and obtaining information vectors of the main nodes according to the key parameters and word vectors of the main nodes; The non-primary nodes are screened by using their frequencies, key parameters and connection relationships in the directed graph to obtain secondary nodes. The primary nodes and secondary nodes of the electronic document data before and after encryption are obtained respectively and clustered in combination with the information vector, and data tampering verification is performed on the electronic document data according to the clustering results.

2. According to claim 1, a method for securely storing electronic official document data is characterized in that: The specific method of constructing a directed graph according to the semantic relationship between the segmentations is as follows: Any kind of phrase is taken as a node in a directed graph, the word order relationship of the phrases in the electronic document data is taken as the edge of the phrases in the directed graph, the word order of any two phrases in the electronic document data is taken as the direction of the corresponding edge of the phrases in the directed graph, and the frequency of the same word order is taken as the weight of the corresponding edge. The directed graph contains a number of nodes, and the corresponding edges between different nodes include out-degree edges and in-degree edges.

3. According to claim 1, a method for securely storing electronic official document data is characterized in that: The specific method of obtaining the semantic parameters of the phrase by combining the distribution of similarity relationships between the word vectors corresponding to the phrases is as follows: Use the Word2Vec algorithm to convert each phrase in the electronic document data into a word vector; For any kind of phrase, obtain the cosine similarity between the corresponding word vectors of any two phrases in the same kind of phrase; The variance of the cosine similarity between the word vectors corresponding to all phrases in any type of phrase is obtained, and recorded as the semantic parameter of the type of phrase.

4. According to claim 1, a method for securely storing electronic official document data is characterized in that: The method of combining the semantic parameters of the phrases and the connection relationship between the corresponding nodes of the phrases in the directed graph to obtain the key parameters of the nodes and the key nodes in the directed graph includes the following specific methods: Combining the semantic parameters of the phrase and the connection relationship between the corresponding nodes of the phrase in the directed graph, the key parameters of the corresponding nodes of the phrase in the directed graph are obtained; Nodes with a critical parameter greater than A are recorded as critical nodes, where A is a preset first parameter.

5. According to claim 1, a method for securely storing electronic official document data is characterized in that: The method of performing graph traversal search on the directed graph in combination with the key parameters to obtain a number of key node sequences includes: A depth-first search algorithm and a breadth-first search algorithm are used respectively, and a graph traversal search is performed on a directed graph in combination with key parameters of nodes and directions of corresponding edges between nodes to obtain a key node sequence, wherein the key node sequence includes a depth key node sequence and a breadth key node sequence.

6. According to claim 1, a method for securely storing electronic official document data is characterized in that: The specific method of obtaining the information vector of the node in the key node sequence according to the key parameters and word vectors of the node in the key node sequence includes: All nodes in all key node sequences are recorded as main nodes, and a vector formed by the key parameters of each main node and the word vector of the corresponding phrase is obtained, which is recorded as the information vector of the main node.

7. A method for securely storing electronic official document data according to claim 1, characterized in that: The method of screening the non-primary nodes by using the frequencies, key parameters and connection relationships of the non-primary nodes in the directed graph to obtain the secondary nodes includes: The frequency of each non-main node corresponding to a phrase in the electronic document data is obtained, and the structural coefficient of the non-main node is obtained by combining the frequency, key parameters and connection relationship of the non-main node in the directed graph.

8. A method for securely storing electronic official document data according to claim 6, characterized in that: The specific method of respectively obtaining the primary nodes and secondary nodes of the electronic document data before and after encryption and clustering them in combination with the information vector includes: Obtaining the primary node and the secondary node in the electronic document data before and after encryption, and obtaining the information vectors of all the secondary nodes, wherein the information vectors of the secondary nodes are obtained in the same manner as the information vectors of the primary nodes; According to the Euclidean distance of the information vector between the primary node and the secondary node, the DBSCAN clustering algorithm is used to cluster all the primary nodes and secondary nodes of the electronic document data before and after encryption to obtain several clusters.

9. A method for securely storing electronic official document data according to claim 1, characterized in that: The data tampering verification of the electronic document data according to the clustering result includes the following specific methods: The main nodes and secondary nodes are collectively referred to as text structure points. The non-tampering coefficient is obtained based on the number of clusters and the proportion of text structure points in the clusters.

10. A method for securely storing electronic official document data according to claim 9, characterized in that: The specific calculation method of the untampered coefficient is: in, Indicates the tamper-free coefficient of electronic document data; Indicates the number of clusters; Indicates the number of all text structure points; Indicates the number of text structure points in the largest cluster; Indicates the number of key nodes in the directed graph corresponding to the electronic document data before encryption; Indicates the number of key nodes in the directed graph corresponding to the encrypted electronic document data; Indicates obtaining the absolute value. Represents an exponential function with a natural constant as base.

Citation Information

Patent Citations

  • Chinese short text clustering method

    CN106599029A

  • Classified storage method and system based on financial text data

    CN118227798A

  • Graph structure-based official document recommendation method, apparatus, computer device, and medium

    WO2021114810A1

Cited By

  • Customer information acquisition method and system based on multi-source data fusion

    CN120910038A

  • Customer information collection method and system based on multi-source data fusion

    CN120910038B