Data processing method, device, computer equipment and storage medium

By calculating the similarity of strings in the document business field and establishing document association relationships, the problem of low document processing efficiency in the prior art is solved, and the efficiency of document processing is achieved.

CN112712086BActive Publication Date: 2024-11-26YUNDI SMART TECH CO LTD

Patent Information

Application Number
CN202011584752.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-12-28
Publication Date
2024-11-26
Estimated Expiration
2040-12-28

AI Technical Summary

Technical Problem

Existing data processing methods are inefficient when processing documents and cannot effectively improve document processing efficiency.

Method used

By obtaining business documents and fields of different document types, establishing a field conversion model, converting fields of document types into corresponding fields, and calculating string similarity to establish an association between documents, reducing manual operations.

Benefits of technology

By calculating the similarity of strings in the document business field, accurately judge the relationship between documents, improving document processing efficiency and reducing manual correlation operations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112712086B_ABST
    Figure CN112712086B_ABST
Patent Text Reader

Abstract

The present application relates to a data processing method, device, computer equipment and storage medium. The method includes: obtaining a first business document corresponding to a first document type and a second business document corresponding to a second document type; obtaining a first business field corresponding to the first business document; determining a field conversion model corresponding to the first business document; inputting the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; extracting a first string corresponding to the first business field from the first business document, and extracting a second string corresponding to the second business field from the second business document; calculating string similarity based on the first string and the second string; when the string similarity is greater than a similarity threshold, establishing an association relationship between the first business document and the second business document. The use of this method can improve document processing efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, and in particular to a data processing method, apparatus, computer equipment and storage medium. Background Art

[0002] With the development of data processing technology, data processing is increasingly used in finance, medical care, or the Internet. Through data processing, the common features of certain data can be analyzed, and these common features can be used to assist users in implementing certain applications. For example, through the consumption behavior data of a large number of users, the user's individual preferences can be analyzed through data processing, and personalized services can be customized for users based on the analysis results.

[0003] However, the current data processing method only processes documents on a certain enterprise's local system when processing documents, which reduces the efficiency of document processing. Summary of the invention

[0004] Based on this, it is necessary to provide a data processing method, device, computer equipment and storage medium that can improve document processing efficiency in response to the above technical problems.

[0005] A data processing method, the method comprising: obtaining a first business document corresponding to a first document type and a second business document corresponding to a second document type; obtaining a first business field corresponding to the first business document; determining a field conversion model corresponding to the first business document, the field conversion model being used to convert the field of the first document type into the field of the second document type; inputting the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; extracting a first character string corresponding to the first business field from the first business document, and extracting a second character string corresponding to the second business field from the second business document; calculating a character string similarity based on the first character string and the second character string; and establishing an association relationship between the first business document and the second business document when the character string similarity is greater than a similarity threshold.

[0006] In one embodiment, the calculating string similarity based on the first string and the second string includes: dividing the first string into a first substring set; dividing the second string into a second substring set; combining the first substring set with the substrings in the second substring set to obtain a third substring set; obtaining the first number of occurrences of a third substring in the third substring set in the first substring set, and obtaining the second number of occurrences of the third substring in the third substring set in the second substring set; obtaining a first vector based on the first number corresponding to the third substring, and obtaining a second vector based on the second number corresponding to the third substring; calculating the vector similarity between the first vector and the second vector, and obtaining the string similarity based on the vector similarity.

[0007] In one embodiment, obtaining a first vector based on the first number corresponding to the third substring and obtaining a second vector based on the second number corresponding to the third substring include: using the first number corresponding to each of the third substrings as a vector value to obtain a first vector; using the second number corresponding to each of the third substrings as a vector value to obtain a second vector; wherein the vector values ​​of the same dimension in the first vector and the second vector correspond to the same third substring.

[0008] In one embodiment, there are multiple first character strings and multiple second character strings, and calculating the string similarity based on the first character strings and the second character strings includes: calculating the similarity between each of the first character strings and the corresponding second character strings to obtain a first similarity; concatenating multiple first character strings in a character string order to obtain a first concatenated character string; concatenating multiple second character strings in the character string order to obtain a second concatenated character string; calculating the similarity between the first concatenated character string and the second concatenated character string to obtain a second similarity; performing statistics on the first similarity to obtain a statistical similarity; and performing a weighted sum calculation based on the statistical similarity and the second similarity to obtain a string similarity.

[0009] In one of the embodiments, after establishing the association relationship between the first business document and the second business document, the method also includes: obtaining a second business status corresponding to the second business document; updating the first business status corresponding to the first business document based on the second business status; and sending a status reminder message corresponding to the first business status to the first business terminal corresponding to the first business document.

[0010] In one of the embodiments, establishing an association relationship between the first business document and the second business document includes: sending association prompt information to a first terminal, the first terminal is a terminal of a first user corresponding to the first business document, and the association prompt information is used to prompt to associate the first business document with the second business document; in response to a document association request sent by the first terminal, establishing an association relationship between the first business document and the second business document, and the document association request is triggered by the first terminal after displaying the association prompt information in response to an association operation of the user.

[0011] In one embodiment, the training step of the field conversion model includes: obtaining a first training document corresponding to the first document type and a second training document corresponding to the second document type; extracting a first training business field from the first business document and extracting a second training business field from the second business document; inputting the first training business field into the field conversion model to be trained for field conversion to obtain a predicted business field; obtaining a model loss value based on the difference between the predicted business field and the second training business field; adjusting the model parameters of the field conversion model based on the model loss value to obtain a trained field conversion model.

[0012] A data processing device, the device comprising: a business document acquisition module, used to acquire a first business document corresponding to a first document type and a second business document corresponding to a second document type; a first business field acquisition module, used to acquire a first business field corresponding to the first business document; a field conversion model determination module, used to determine a field conversion model corresponding to the first business document, the field conversion model being used to convert a field of the first document type into a field of the second document type; a field conversion module, used to input the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; a string extraction module, used to extract a first string corresponding to the first business field from the first business document, and to extract a second string corresponding to the second business field from the second business document; a string similarity calculation module, used to calculate string similarity based on the first string and the second string; and an association establishment module, used to establish an association between the first business document and the second business document when the string similarity is greater than a similarity threshold.

[0013] In one embodiment, the string similarity calculation module is further used to: divide the first string into a first substring set; divide the second string into a second substring set; combine the first substring set with the substrings in the second substring set to obtain a third substring set; obtain the first number of times a third substring in the third substring set appears in the first substring set, and obtain the second number of times a third substring in the third substring set appears in the second substring set; obtain a first vector based on the first number corresponding to the third substring, and obtain a second vector based on the second number corresponding to the third substring; calculate the vector similarity between the first vector and the second vector, and obtain the string similarity based on the vector similarity.

[0014] In one embodiment, the string similarity calculation module is further used to: use the first digits corresponding to each of the third substrings as vector values ​​to obtain a first vector; use the second digits corresponding to each of the third substrings as vector values ​​to obtain a second vector; wherein the vector values ​​of the same dimension in the first vector and the second vector correspond to the same third substring.

[0015] In one embodiment, the string similarity calculation module is further used to: calculate the similarity between each of the first strings and the corresponding second strings to obtain a first similarity; concatenate multiple of the first strings in string order to obtain a first concatenated string; concatenate multiple of the second strings in string order to obtain a second concatenated string; calculate the similarity between the first concatenated string and the second concatenated string to obtain a second similarity; perform statistics on the first similarities to obtain statistical similarity; perform weighted sum calculation based on the statistical similarity and the second similarity to obtain string similarity.

[0016] In one of the embodiments, the data processing device is also used to: obtain a second business status corresponding to the second business document; update a first business status corresponding to the first business document based on the second business status; and send a status reminder message corresponding to the first business status to a first business terminal corresponding to the first business document.

[0017] In one of the embodiments, the association relationship establishing module is also used to: send association prompt information to a first terminal, where the first terminal is a terminal of a first user corresponding to a first business document, and the association prompt information is used to prompt to associate the first business document with the second business document; establish an association relationship between the first business document and the second business document in response to a document association request sent by the first terminal, and the document association request is triggered by the first terminal after displaying the association prompt information in response to an association operation by the user.

[0018] In one of the embodiments, the data processing device is also used to: obtain a first training document corresponding to the first document type and a second training document corresponding to the second document type; extract a first training business field from the first business document, and extract a second training business field from the second business document; input the first training business field into a field conversion model to be trained for field conversion to obtain a predicted business field; obtain a model loss value based on the difference between the predicted business field and the second training business field; adjust the model parameters of the field conversion model based on the model loss value to obtain a trained field conversion model.

[0019] A computer device comprises a memory and a processor, wherein the memory stores a computer program, and the processor implements the following steps when executing the computer program: obtaining a first business document corresponding to a first document type and a second business document corresponding to a second document type; obtaining a first business field corresponding to the first business document; determining a field conversion model corresponding to the first business document, wherein the field conversion model is used to convert the field of the first document type into the field of the second document type; inputting the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; extracting a first character string corresponding to the first business field from the first business document, and extracting a second character string corresponding to the second business field from the second business document; calculating a character string similarity based on the first character string and the second character string; and establishing an association relationship between the first business document and the second business document when the character string similarity is greater than a similarity threshold.

[0020] A computer-readable storage medium stores a computer program, which implements the following steps when executed by a processor: obtaining a first business document corresponding to a first document type and a second business document corresponding to a second document type; obtaining a first business field corresponding to the first business document; determining a field conversion model corresponding to the first business document, the field conversion model being used to convert the field of the first document type into the field of the second document type; inputting the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; extracting a first character string corresponding to the first business field from the first business document, and extracting a second character string corresponding to the second business field from the second business document; calculating a character string similarity based on the first character string and the second character string; and establishing an association relationship between the first business document and the second business document when the character string similarity is greater than a similarity threshold.

[0021] The above data processing method, device, computer equipment and storage medium, the server obtains the first business document corresponding to the first document type and the second business document corresponding to the second document type; and obtains the first business field corresponding to the above first business document; after the server determines the field conversion model corresponding to the first business document, the first business field is input into the field conversion model for field conversion to obtain the second business field corresponding to the second document type; wherein the field conversion model is used to convert the field of the first document type into the field of the second document type; extract the first string corresponding to the first business field from the first business document, and extract the second string corresponding to the second business field from the second business document; calculate the string similarity based on the first string and the second string; when the string similarity is greater than the similarity threshold, establish the association relationship between the first business document and the second business document. The similarity of the strings in the document business field can intuitively and accurately determine the association relationship between the documents in the two business systems, so that the correlation between the documents can be obtained, reducing the need for manual document association operations and improving document processing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] Figure 1 An application environment diagram of a data processing method in an embodiment;

[0023] Figure 2 is a flow chart of a data processing method in one embodiment;

[0024] Figure 3 It is a schematic diagram of a flow chart of calculating the string similarity according to the first string and the second string in one embodiment;

[0025] Figure 4It is a schematic diagram of a flow chart of calculating the string similarity according to the first string and the second string in another embodiment;

[0026] Figure 5 It is a schematic diagram of a flow chart of calculating the string similarity according to the first string and the second string in another embodiment;

[0027] Figure 6 is a flow chart of a data processing method in another embodiment;

[0028] Figure 7 A schematic diagram of a process of establishing an association relationship between a first business document and a second business document in one embodiment;

[0029] Figure 8 is a flow chart of a data processing method in another embodiment;

[0030] Fig. 9 is a structural block diagram of a data processing device in one embodiment;

[0031] Fig.10 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0032] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0033] The data processing method provided in this application can be applied to Figure 1In the application environment shown. It is specifically applied to a data processing system. The data processing system includes a server 102, a first terminal 104, and a second terminal 106. The server 102, the first terminal 104, and the second terminal 106 communicate through a network. The server 102 executes a data processing method. Specifically, the server 102 obtains a first business document corresponding to a first document type sent by the first terminal 104, and obtains a second business document corresponding to a second document type sent by the second terminal 106. The server 102 obtains the corresponding first business field through the above-mentioned first business document. A field conversion model corresponding to the first business document is determined on the server 102, and the field conversion model is used to convert the field of the first document type sent by the first terminal 104 into the field of the second document type sent by the second terminal 106; the first business field is input into the field conversion model through the server 102 for field conversion, and the second business field corresponding to the second document type is obtained; at the same time, the server 102 extracts the first character string corresponding to the first business field from the first business document, and extracts the second character string corresponding to the second business field from the second business document; the server 102 calculates the character string similarity according to the first character string and the second character string; when the character string similarity is greater than the similarity threshold, an association relationship between the first business document sent by the first terminal 104 and the second business document sent by the second terminal 106 is established. The first terminal 104 and the second terminal 106 communicate with the server 102 through a network. The first terminal 104 or the second terminal 106 can be, but not limited to, various personal computers, laptops, smart phones, tablet computers and portable wearable devices, and the server 102 can be implemented by an independent server or a server cluster composed of multiple servers.

[0034] In one embodiment, Figure 2 As shown, a data processing method is provided, which is applied to Figure 1 The server in the example is used to illustrate the following steps:

[0035] Step 202: Acquire a first business document corresponding to the first document type and a second business document corresponding to the second document type.

[0036] Among them, the document type refers to the specific type of the document, which is generally defined by the purpose of use. For example, the document type corresponding to the document of selling goods is the sales document type. Business document refers to the specific document corresponding to a certain document type. Different enterprises or companies may have multiple documents corresponding to a document type. For example, different sales documents corresponding to the sales document type can be used by multiple different companies of the enterprise's external cooperation.

[0037] Specifically, when two enterprises conduct business collaboration, they need to first obtain the business documents of the two enterprises.

[0038] In one embodiment, the server receives a first business document sending request sent by a first terminal, responds to the sending request, and obtains a first business document corresponding to a first document type sent by the first terminal; at the same time, the server receives a second business document sending request sent by a second terminal, responds to the sending request, and obtains a second business document corresponding to a second document type sent by the second terminal.

[0039] Step 204: Acquire a first business field corresponding to the first business document.

[0040] Among them, business fields refer to fields in business documents, which can also be called general parameters. For example, business fields in sales documents include "sales company information", "purchase customer information" or "sales item name".

[0041] Specifically, after the server obtains the first business document corresponding to the first document type, it is necessary to extract the first business field in the first business document so as to perform data processing on the first business field.

[0042] In one embodiment, the server can perform field recognition on the fields in the first business document through character recognition, and extract the corresponding fields in the first business document from the field list stored on the server. It can be understood that the field list includes the same fields as the first business field and other business fields. The purpose of the server storing the field list on the server is to facilitate fast and accurate finding of the first business field to be recognized.

[0043] Step 206: determine a field conversion model corresponding to the first business document, where the field conversion model is used to convert a field of the first document type into a field of the second document type.

[0044] The field conversion model refers to a model established for converting fields, for example, a machine learning model. The field conversion model can realize the conversion between the field of the first document type and the field of the second document type.

[0045] Specifically, after the server obtains the first business field corresponding to the first business document, it is necessary to determine the field conversion model corresponding to the first business document so as to convert the field of the first document type into the field of the second document type.

[0046] In one embodiment, the field conversion model can perform conversions between different document fields. The field conversion model corresponding to the first business document is pre-trained, and the step of training the model includes: first, by determining the model loss value of the field conversion model corresponding to the first business document, the model loss value is obtained based on the difference between the business field of the first document type and the business field of the second document type, for example, it can be calculated using a cross entropy algorithm, wherein the model loss value is positively correlated with the difference, that is, the greater the difference, the greater the loss value. After obtaining the loss value, a gradient descent method can be used to adjust the model parameters in a direction that reduces the loss value until the model converges. When the model converges, it is determined that the model can be used as a byte conversion model. Wherein, model convergence can be at least one of the model loss value being less than a preset threshold or the number of training times reaching a preset number of times.

[0047] Step 208: Input the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type.

[0048] Specifically, after the field conversion model corresponding to the first business document is determined, the field conversion model can be used to convert between fields, and the first business field can be converted into the second business field.

[0049] In one embodiment, the first business field is converted into a word vector on the input side of a field conversion model, and the vector is input into the field conversion model. After being processed by the model, a vector corresponding to the second business field is output on the output side of the model, and the corresponding second business field is obtained through the vector.

[0050] Step 210: extract a first character string corresponding to a first business field from the first business document, and extract a second character string corresponding to a second business field from the second business document.

[0051] The character string refers to the specific content included in the business field. For example, if the business field of the sales document is "sales company information" and the specific content in this business field is "Company A", then "Company A" is the character string corresponding to the business field "sales company information".

[0052] Specifically, in order to make the comparison between the first business document and the second business document more referenceable, it is necessary to extract the character string as the specific content in the corresponding business field, so as to facilitate the subsequent analysis of the character string.

[0053] In one embodiment, the server uses a string extraction tool to extract the first string corresponding to the first business field according to the specific name of the first business field. For example, the string extraction tool can be used to extract the string "Company A" corresponding to the business field "sales company information" according to the business field "sales company information". Similarly, the second string corresponding to the second business field can be extracted. The string extraction tool can be a script program.

[0054] Step 212: Calculate the string similarity based on the first string and the second string.

[0055] The string similarity refers to the degree of similarity between strings. The higher the string similarity, the smaller the difference between the first string and the second string; conversely, the lower the string similarity, the greater the difference between the first string and the second string.

[0056] Specifically, the string similarity between the first string and the second string may be calculated by using methods such as cosine similarity or Pearson correlation coefficient.

[0057] In one embodiment, the cosine similarity method can be used to calculate the string similarity between the first string and the second string. Specifically, the first string and the second string are vectorized respectively, and the string similarity between the first string and the second string is obtained by calculating the difference between the vector corresponding to the first string and the vector corresponding to the second string.

[0058] In one embodiment, the first string or the second string can be multiple. Assume that both the first string and the second string are multiple, multiple first strings form a first string array, and multiple second strings form a second string array. The string similarity needs to be obtained by combining the similarity between each first string in the first string array and each second string in the second string array at the corresponding array position. The string similarity can be a statistical value of the similarity between each first string in the first string array and each second string in the second string array at the corresponding array position. For example, the similarity is the average value of the similarity between each first string in the first string array and each second string in the second string array at the corresponding array position. For example, the first string array is {A, B, C, D}, and the second string array is {E, F, G, H}. If the similarity between the first string A and the second string E is expressed as x, the similarity between the first string B and the second string F is expressed as y, the similarity between the first string C and the second string G is expressed as z, the similarity between the first string D and the second string H is expressed as s, and the string similarity is expressed as o, then the string similarity o can be the average value of the similarities between the above-mentioned first strings and the second strings, and o is expressed as:

[0059] o=(x+y+z+s) / 4

[0060] Step 214: when the string similarity is greater than the similarity threshold, an association relationship between the first business document and the second business document is established.

[0061] The similarity threshold refers to a critical value of the similarity. If it is greater than the critical value, it means that the first character string and the second character string are similar, and if it is less than or equal to the critical value, it means that the first character string and the second character string are not similar.

[0062] Specifically, the association relationship between the first business document and the second business document may be determined through the character string similarity.

[0063] In one embodiment, the similarity threshold may be an empirical value obtained through multiple experiments. For example, the similarity threshold is 0.75. When the string similarity is greater than 0.75, it indicates that the first string and the second string are similar. Through the similarity relationship between the first string and the second string, it can be proved that the first business document corresponding to the first string and the second business document corresponding to the second string have an association relationship, and the association relationship between the first business document and the second business document is established.

[0064] In the above data processing method, the server obtains a first business document corresponding to a first document type and a second business document corresponding to a second document type; and obtains a first business field corresponding to the above first business document; after the server determines the field conversion model corresponding to the first business document, the first business field is input into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; wherein the field conversion model is used to convert the field of the first document type into the field of the second document type; extracts a first string corresponding to the first business field from the first business document, and extracts a second string corresponding to the second business field from the second business document; calculates the string similarity based on the first string and the second string; when the string similarity is greater than the similarity threshold, establishes an association relationship between the first business document and the second business document. The similarity of the strings in the document business field can intuitively and accurately determine the association relationship between the documents in the two business systems, thereby obtaining the correlation between the documents, reducing the need to manually associate the documents, and improving the document processing efficiency.

[0065] In one embodiment, Figure 3 As shown, calculating the string similarity based on the first string and the second string includes:

[0066] Step 302: Divide the first string into a first set of substrings.

[0067] Among them, a substring refers to the basic unit that makes up a string. A substring set refers to a set of substrings. For example, the string "B Province C City D Company" corresponding to the business field "Sales Unit" of a sales document has a substring set of "B", "Province", "C", "City", "D" and "Company".

[0068] Specifically, in order to improve the accuracy of similarity when comparing strings, the strings are divided into substring sets before performing similarity related operations.

[0069] In one embodiment, after the server obtains the first string, the server calls the application program interface for obtaining the related substrings, extracts the first substrings in the first string in sequence, and after the extraction is completed, stores the extracted first substrings in a preset area to form a first substring set. For example, each substring can be intercepted from a preset start index position to a preset end index position by calling an application program with a string interception function in the program. For example, if the first string is "January 2, 2000", the first substring can be obtained as "2000" by calling a program in the program that intercepts substrings at index positions 0 to 4.

[0070] Step 304: divide the second string into a second set of substrings.

[0071] Specifically, the second string needs to be processed in the same way as the first string, and the second string is divided into a second substring set. For example, if the second string is the second string "E brand daily necessities" corresponding to the business field "purchased item name" in the purchase document, then the second substring set is "E", "brand", "daily necessities" and "product".

[0072] Step 306: Combine the first substring set with the substrings in the second substring set to obtain a third substring set.

[0073] Specifically, after obtaining the first substring set and the second substring set, there are the same substrings in the two, for example, the first substring set is {"F brand" "rice" "G" "tons"}, the second substring set is {"F brand" "rice" "H" "bag"}, then the third substring set is {"F brand" "rice" "G" "H" "tons" "bag"}.

[0074] Step 308 , obtaining the first number of times the third substring in the third substring set appears in the first substring set, and obtaining the second number of times the third substring in the third substring set appears in the second substring set.

[0075] Specifically, after obtaining the third substring set, some substrings in the first substring set or the second substring set may not appear in the third substring set. The more similar the words used in the two strings are, the closer the contents are. The similarity between the two strings can be judged from the number of occurrences of the substrings. The similarity between the first string and the second string can be further judged by counting the frequency of the third substring in the third substring set appearing in the first substring set or the second substring set. For example, the first substring set is {"F brand" "rice" "G" "ton"}, the second substring set is {"F brand" "rice" "H" "bag"}, and the third substring set is {"F brand" "rice" "G" "H" "ton" "bag"}, then the first number of occurrences of the third substring "rice" in the third substring set in the first substring set is 1, and the second number of occurrences of the third substring "ton" in the third substring set in the second substring set is 0.

[0076] Step 310: Obtain a first vector based on the first order number corresponding to the third substring, and obtain a second vector based on the second order number corresponding to the third substring.

[0077] Specifically, by obtaining the first number and the second number, the corresponding vector can be obtained. For example, the first numbers corresponding to the third substring are {1 1 1 0 1 0}, and the second numbers corresponding to the third substring are {1 1 0 1 01}. Then, by the number, the first vector can be obtained as [1 1 1 0 1 0], and the second vector can be obtained as [1 1 0 1 0 1].

[0078] Step 312: Calculate the vector similarity between the first vector and the second vector, and obtain the string similarity according to the vector similarity.

[0079] The vector similarity refers to the similarity between vectors. By calculating the vector similarity, the similarity of the character strings corresponding to the vectors can be obtained.

[0080] In one embodiment, there is a positive correlation between the vector similarity and the string similarity. The greater the vector similarity, the greater the string similarity; conversely, the smaller the vector similarity, the smaller the string similarity.

[0081] In one embodiment, the similarity between two vectors can be measured by measuring the cosine value of the angle between them. The cosine value of an angle of 0 degrees is 1, while the cosine value of any other angle is not greater than 1; the cosine value of the angle between two vectors is used to determine whether the two vectors are pointing in approximately the same direction. When two vectors have the same direction, the cosine similarity value is 1; when the angle between the two vectors is 90°, the cosine similarity value is 0; when the two vectors point in completely opposite directions, the cosine similarity value is -1. It has nothing to do with the length of the vector, but only with the direction in which the vector points. Assuming that the first vector is represented by A, the second vector is represented by B, and the similarity is represented by cos(θ), the similarity between A and B can be expressed as:

[0082]

[0083] In this embodiment, by decomposing the first string and the second string into substring sets, after the substring sets are merged, the number of times the substrings in the substring sets appear in the first string and the second string is vectorized, so that the purpose of obtaining the similarity of the first string and the second string according to the vector similarity can be achieved, making the similarity result more accurate.

[0084] In one embodiment, Figure 4 As shown, obtaining the first vector based on the first order number corresponding to the third substring, and obtaining the second vector based on the second order number corresponding to the third substring includes:

[0085] Step 402: Taking the first order digits corresponding to each third substring as vector values ​​to obtain a first vector.

[0086] Specifically, the third substring set includes at least one third substring, and a vector needs to be obtained for each third substring as the first vector. For example, if the first substring set is {"F brand", "rice", "G", "tons"}, then the third substring set is {"F brand", "rice", "G", "H", "tons", "bags"}, and the first numbers of the third substrings in the third substring set appearing in the first substring set are {1 1 1 0 1 0}.

[0087] Step 404: Use the second order numbers corresponding to the third substrings as vector values ​​to obtain a second vector; wherein the vector values ​​of the same dimension in the first vector and the second vector correspond to the same third substring.

[0088] Specifically, to obtain the similarity between the first string and the second string, it is also necessary to take the second number corresponding to each third substring as a vector value as the second vector. For example, if the second substring set is {"F brand" "rice" "H" "bag"}, then the third substring set is {"F brand" "rice" "G" "H" "ton" "bag"}, then the second number of times the third substring in the third substring set appears in the second substring set is {1 1 0 1 0 1}. In the first vector and the second vector, the vector values ​​of the same dimension correspond to the same third substring. For example, the second dimension in the first vector corresponds to the "rice" in the third substring, and the second dimension in the second vector should also correspond to the "rice" in the third substring. The dimension is expressed as the position of the vector value in the vector. For example, the vector is [1 1 1 0 1 0], and the second vector value 1 is the vector value of the second dimension of the vector.

[0089] In this embodiment, the corresponding vector is obtained by the number of times each third substring corresponds to the first substring set or the second substring set, so as to achieve the purpose of obtaining the first vector and the second vector corresponding to the dimension.

[0090] In one embodiment, Figure 5 As shown, there are multiple first character strings and multiple second character strings, and calculating the character string similarity based on the first character strings and the second character strings includes:

[0091] Step 502: Calculate the similarity between each first character string and the corresponding second character string to obtain a first similarity.

[0092] Specifically, there may be multiple business fields in the enterprise document, and each business field has a corresponding character string, forming multiple character strings. When performing similarity calculation, it is necessary to perform similarity calculation on each character string. For example, the business fields of the selling enterprise include "name of sales item", "sales unit" or "price", etc., and the corresponding first character strings are "I model data cable", "J Technology Company" or "unit price K yuan", respectively. The business fields of the purchasing enterprise correspond to "name of purchase item", "purchase unit" and "purchase price", and the corresponding second character strings are "I model data cable", "H Technology Co., Ltd." or "unit price K yuan". The similarity of each of the above first character strings and the corresponding second character string is calculated respectively to obtain the first similarity. It can be understood that the first similarity is a set of similarities composed of multiple similarities, and the number of similarities in the set depends on the number of the first character string or the second character string. If the number of the first character string or the second character string is 5, then the number of the first similarity is 5.

[0093] In one embodiment, a first string array consisting of multiple first strings and a second string array consisting of multiple second strings, if a first string in the first string array or a second string in the second string array is missing, the first string or the second string is deleted, and the first string array and the second string array simultaneously delete the string at the same position in the array.

[0094] In one embodiment, if the first character string and the second character string are consistent, the first similarity obtained is optimized. The first similarity can be optimized using an optimization parameter. The optimization parameter can be the inverse of the first similarity. For example, assuming that the first similarity is 0.8, the optimization parameter is 1.25.

[0095] Step 504: concatenate multiple first character strings in character string order to obtain a first concatenated character string.

[0096] The concatenation refers to merging multiple character strings to form a merged character string. For example, if the first character strings are "I model data cable", "J technology company" or "unit price K yuan", the concatenated character string is "I model data cable J technology company unit price K yuan".

[0097] In one embodiment, the server can call software or plug-ins related to string concatenation to concatenate multiple first strings in string order, and obtain the string concatenation result from the software plug-in. For example, the command line window of Matlab (Matrix & laboratory) software is called to complete the concatenation of multiple first strings in string order. After the server determines that the concatenation is completed, it obtains the result of the first concatenated string from the Matlab software.

[0098] Step 506: concatenate the multiple second character strings in the order of the character strings to obtain a second concatenated character string.

[0099] Specifically, after the first concatenated string is obtained by concatenating the plurality of first strings in the string order, the plurality of second strings need to be concatenated in the string order to obtain the second concatenated string. For example, the second strings are respectively "I model data cable", "H Technology Co., Ltd." or "unit price K yuan", and the second concatenated string is "I model data cable H Technology Co., Ltd. unit price K yuan".

[0100] In one embodiment, the server may concatenate multiple second strings in string order by calling a string-related interface program to obtain a second concatenated string, for example, by calling a strcat() function.

[0101] Step 508: Calculate the similarity between the first concatenated character string and the second concatenated character string to obtain a second similarity.

[0102] Specifically, after obtaining the first concatenated character string and the second concatenated character string, similarity is calculated for the two concatenated character strings to obtain a second similarity.

[0103] In one embodiment, cosine similarity may be calculated for the first concatenated character string and the second concatenated character string, and the calculation result is used as the second similarity.

[0104] Step 510: Count the first similarity to obtain statistical similarity.

[0105] The statistical similarity refers to the similarity that can reflect the overall level of the first similarity, and can be the mean, median or mode of the first similarity.

[0106] In one embodiment, the average of the first similarities is taken to obtain the statistical similarity. For example, if the first similarity is 0.85, 0.9 or 0.6, the statistical similarity is 0.78.

[0107] In one embodiment, in order to improve the reliability of the statistical similarity, the statistical similarity is kept within a 95% confidence interval as a more accurate statistical similarity.

[0108] Step 512: Perform a weighted sum calculation based on the statistical similarity and the second similarity to obtain the string similarity.

[0109] Specifically, in order to improve the reliability of the string similarity, after obtaining the second similarity and the statistical similarity, a weighted sum calculation may be performed on the two similarities to obtain the string similarity.

[0110] In one embodiment, the weighting coefficient is represented by α, assuming that the statistical similarity is q, the second similarity is p, and the string similarity is represented by m, there is the following functional relationship:

[0111] m=α*(q+p)

[0112] In one embodiment, the weight coefficient α is set to 0.5, so that the weighted proportions of the statistical similarity q and the second similarity p in the string similarity are the same, and the string similarity is expressed as:

[0113] m=(q+p) / 2

[0114] In this embodiment, by calculating the similarity between the concatenated character strings and calculating the average value of the similarities of the various character strings, the purpose of making the character string similarity more accurate can be achieved.

[0115] In one embodiment, Figure 6 As shown, after establishing the association relationship between the first business document and the second business document, the data processing method further includes:

[0116] Step 602: Acquire a second business status corresponding to the second business document.

[0117] The business status refers to the progress status of the business document. For example, the business status of a sales document is that a shipping notice has been sent.

[0118] Specifically, after the first business document is associated with the second business document, the server can receive the business status of the first business document and the business status of the second business document, so that the first terminal corresponding to the first business document connected to the server or the second terminal corresponding to the second business document can synchronously view the business status corresponding to the document on the other end that is associated with the document on this end.

[0119] In one embodiment, the server responds to the business status reporting instruction sent by the second terminal corresponding to the second business document to obtain the second business status corresponding to the second business document. For example, the second business document is a purchase order, and the second business status is receiving a shipping notice.

[0120] Step 604: Update the first business status corresponding to the first business document based on the second business status.

[0121] Specifically, since the first business document is associated with the second business document, the business status of the two is also synchronized. After the second business status is updated, the first business status corresponding to the first business document also needs to be updated synchronously. For example, the business status of the purchase order as the second business document is receiving a shipping notice. After receiving the goods, the enterprise corresponding to the first business document will update the first business status to generating a delivery notice.

[0122] Step 606: Send a status reminder message corresponding to the first business status to the first business terminal corresponding to the first business document.

[0123] The status reminder message refers to a reminder message for the business status, for example, a reminder message "The sales document status has been updated, please check it."

[0124] Specifically, in order to enable the user corresponding to the first service terminal to receive the latest service status information in real time, the server may push a status reminder message corresponding to the first service status to the first service terminal.

[0125] In one embodiment, when there is a service status update in the server, a status reminder message sending instruction is triggered to send the status reminder message to the first service terminal. The status reminder message pushed by the server can be viewed on the server-based application page opened by the first service terminal.

[0126] In this embodiment, the first business status corresponding to the first business document can be updated by acquiring the second business status corresponding to the second business document, and the status reminder message corresponding to the first business status is pushed to the first business terminal, so that message synchronization and reminders can be achieved between two related business documents, thereby improving the efficiency of document processing.

[0127] In one embodiment, Figure 7 As shown, establishing an association relationship between the first business document and the second business document includes:

[0128] Step 702: sending association prompt information to a first terminal, where the first terminal is a terminal of a first user corresponding to the first service document, and the association prompt information is used to prompt to associate the first service document with the second service document.

[0129] Specifically, before the first service document and the second service document establish an association relationship, the terminal of the second user corresponding to the second service document sends an association request to the server, and the server sends the association request to the first terminal in the form of association prompt information.

[0130] In one embodiment, when the server receives an instruction from the second terminal to establish an association with the first terminal, the server triggers an operation of sending the association prompt information, sends the association prompt information to the first terminal, and waits for the first terminal to respond to the prompt message. For example, after the server receives the association instruction sent by the second terminal, it triggers the association prompt information based on the association instruction, "Company A needs to establish an association with you, please confirm."

[0131] Step 704: Establish an association relationship between the first business document and the second business document in response to the document association request sent by the first terminal. The document association request is triggered by the first terminal in response to the user's association operation after the first terminal displays the association prompt information.

[0132] The document association request refers to a request to establish an association relationship between documents, and the request may include the name of the other party to the document association or the requested matters, etc. For example, "Company A requests to establish an association request between sales documents and purchase documents, waiting for confirmation."

[0133] Specifically, when the server receives the document association request sent by the first terminal, it responds to the document association request and triggers the sending of a corresponding response message. The server can send the response message based on the document association request to the second terminal and wait for confirmation from the second terminal.

[0134] In this embodiment, by establishing an association relationship between a first business document corresponding to a first terminal and a second business document corresponding to a second terminal through a server, the association between the first business document and the second business document can be established in a visual form, thereby improving the efficiency of document processing and thus improving the convenience of business collaboration for enterprise users.

[0135] In one embodiment, Figure 8 As shown, the training steps of the field conversion model include:

[0136] Step 802: Obtain a first training document corresponding to the first document type and a second training document corresponding to the second document type.

[0137] The training document refers to the document used for field conversion model training.

[0138] Specifically, the field conversion model is a machine learning model trained by using multiple documents as samples.

[0139] In one embodiment, the server obtains a preset number of first training documents corresponding to the first document type and a second training document corresponding to the second document type, respectively, which are synchronously stored on the local end and the terminal. For example, the server obtains more than 1,000 documents in the most recent month as training documents.

[0140] Step 804: extract the first training service field from the first service document, and extract the second training service field from the second service document.

[0141] The training business field refers to the business field corresponding to the document used for field conversion model training.

[0142] Specifically, the field conversion model is a training model based on business fields. After obtaining the training document, it is necessary to obtain the training business field corresponding to the training document for model training.

[0143] In one embodiment, the server may extract the training service field corresponding to the ID (Identity document) of each training service field in each training document. The ID may uniquely identify the training service field.

[0144] Step 806: Input the first training business field into the field conversion model to be trained to perform field conversion to obtain a predicted business field.

[0145] Specifically, after the server obtains the first training business field, the first training business field is input into the field conversion model to be trained for field conversion. After the training is completed, the predicted business field is output.

[0146] Step 808: Obtain a model loss value based on the difference between the predicted business field and the second training business field.

[0147] The model loss value refers to the quantitative value of the difference between the second training business field and the predicted business field input during the training process of the field conversion model. It can be used to measure the quality of the field conversion model. The smaller the model loss value, the better the model. Conversely, the larger the model loss value, the worse the model.

[0148] Specifically, the model loss value is obtained based on the difference between the second training business field and the predicted business field, for example, it can be calculated using a cross entropy algorithm, wherein the model loss value is positively correlated with the difference, that is, the greater the difference, the greater the loss value. After obtaining the loss value, a gradient descent method can be used to adjust the model parameters in a direction that reduces the loss value until the model converges, and the model convergence can be at least one of the model loss value being less than a preset threshold or the number of training times reaching a preset number of times.

[0149] Step 810: Adjust the model parameters of the field conversion model based on the model loss value to obtain a trained field conversion model.

[0150] Model parameters are the parameters that play a key role in determining the model. These parameters can be used to adjust the performance of the model.

[0151] Specifically, when the field conversion model is trained on a large number of first training business fields, the model parameters are continuously adjusted based on the model loss value of each training until the model loss value is minimized.

[0152] In this embodiment, by obtaining a first training document corresponding to a first document type and a second training document corresponding to a second document type, and extracting the corresponding first training business field and second training business field, the first training business field is input into the field conversion model to be trained for field conversion, and a predicted business field is obtained. The model loss value is obtained by the difference between the predicted field and the second training business field, and the model parameters are continuously adjusted by the model loss value. The purpose of obtaining an accurate field conversion model can be achieved.

[0153] In one embodiment, the first document type is a sales document and the second document type is a purchase document. The ERP (Enterprise Resource Planning) system obtains the sales document sent by the first terminal and the purchase document sent by the second terminal. The ERP system obtains the sales document business field corresponding to the sales document from the sales document, for example, the sales unit. The sales document business field corresponding to the sales document is used as an input parameter, and the output business field is used as the predicted business field. The model loss value is determined by the difference between the predicted business field and the purchase document business field corresponding to the purchase document. The model parameters are continuously adjusted by the model loss value until the model loss value reaches the minimum. The model corresponding to the model parameters at this time is the model that is finally trained. After determining the field conversion model corresponding to the sales document, the business field of the sales document can be converted into a business field that is closer to the actual purchase document using the model. The similarity between the sales document and the actual purchase document is determined by calculating the similarity between the string in the sales document business field and the string in the business field close to the actual purchase document. The association relationship between the sales document and the actual purchase document can be obtained through the similarity. Specifically, the sales document business field corresponding to the sales document business field is extracted from the sales document. The sales document business field is converted into an intermediate document field, and the string corresponding to the intermediate document field is obtained from the purchase document according to the intermediate document field, and the string in the sales document business field and the string corresponding to the intermediate document field are calculated to obtain the similarity. According to the similarity, it can be known whether there is an association relationship between the sales document and the purchase document. When the similarity is greater than the similarity threshold, it can be determined that there is an association relationship between the sales document and the purchase document. Therefore, the purchase document can be updated later according to the changes in the document data of the sales document.

[0154] In one embodiment, when the similarity between the sales document and the purchase document has been determined, in order to improve the accuracy of the similarity, the character strings of each field of the sales document and the character strings of each field of the purchase document can be merged to obtain the similarity between the entire character strings after merging, which is recorded as p. The average value of the similarity between the character strings of each individual field is q, where q is the similarity value of the 95% confidence interval. The mean value m is obtained by the similarity p of the entire character string and the average value q of the similarity between the character strings of the individual fields. A more accurate similarity can be obtained by the similarity mean value. Assuming that the similarity threshold is 0.75, m is expressed as m=(p+q) / 2. When m is greater than 0.75, the sales document and the purchase document are associated.

[0155] It should be understood that although Figure 2-8The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 2-8 At least part of the steps may include multiple steps or multiple stages. These steps or stages are not necessarily performed at the same time, but can be performed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed in turn or alternately with other steps or at least part of the steps or stages in other steps.

[0156] In one embodiment, Fig. 9 As shown, a data processing device 900 is provided, including: a business document acquisition module 902, a first business field acquisition module 904, a field conversion model determination module 906, a field conversion module 908, a string extraction module 910, a string similarity calculation module 912 and an association relationship establishment module 914, wherein: the business document acquisition module 902 is used to acquire a first business document corresponding to a first document type and a second business document corresponding to a second document type; the first business field acquisition module 904 is used to acquire a first business field corresponding to the first business document; the field conversion model determination module 906 is used to determine the first business field; A field conversion model corresponding to the document, the field conversion model 908 is used to input the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; a string extraction module 910 is used to extract a first string corresponding to the first business field from the first business document, and extract a second string corresponding to the second business field from the second business document; a string similarity calculation module 912 is used to calculate string similarity based on the first string and the second string; an association relationship establishment module 914 is used to establish an association relationship between the first business document and the second business document when the string similarity is greater than a similarity threshold.

[0157] In one embodiment, the string similarity calculation module 912 is further used to: divide the first string into a first substring set; divide the second string into a second substring set; combine the first substring set with the substrings in the second substring set to obtain a third substring set; obtain the first number of times the third substring in the third substring set appears in the first substring set, and obtain the second number of times the third substring in the third substring set appears in the second substring set; obtain a first vector based on the first number corresponding to the third substring, and obtain a second vector based on the second number corresponding to the third substring; calculate the vector similarity between the first vector and the second vector, and obtain the string similarity based on the vector similarity.

[0158] In one embodiment, the string similarity calculation module 912 is further used to: use the first digits corresponding to each of the third substrings as vector values ​​to obtain a first vector; use the second digits corresponding to each of the third substrings as vector values ​​to obtain a second vector; wherein the vector values ​​of the same dimension in the first vector and the second vector correspond to the same third substring.

[0159] In one embodiment, the string similarity calculation module 912 is further used to: calculate the similarity between each first string and the corresponding second string to obtain a first similarity; concatenate multiple first strings in string order to obtain a first concatenated string; concatenate multiple second strings in string order to obtain a second concatenated string; calculate the similarity between the first concatenated string and the second concatenated string to obtain a second similarity; perform statistics on the first similarity to obtain a statistical similarity; perform weighted sum calculation based on the statistical similarity and the second similarity to obtain a string similarity.

[0160] In one embodiment, the data processing device 900 is further used to: obtain a second business status corresponding to the second business document; update a first business status corresponding to the first business document based on the second business status; and send a status reminder message corresponding to the first business status to the first business terminal corresponding to the first business document.

[0161] In one embodiment, the association relationship establishing module 914 is also used to: send association prompt information to the first terminal, the first terminal is the terminal of the first user corresponding to the first business document, and the association prompt information is used to prompt to associate the first business document with the second business document; in response to the document association request sent by the first terminal, establish an association relationship between the first business document and the second business document, and the document association request is triggered by the first terminal after displaying the association prompt information in response to the user's association operation.

[0162] In one embodiment, the data processing device 900 is also used to: obtain a first training document corresponding to the first document type and a second training document corresponding to the second document type; extract a first training business field from the first business document, and extract a second training business field from the second business document; input the first training business field into the field conversion model to be trained for field conversion to obtain a predicted business field; obtain a model loss value based on the difference between the predicted business field and the second training business field; adjust the model parameters of the field conversion model based on the model loss value to obtain a trained field conversion model.

[0163] For the specific definition of the data processing device, please refer to the definition of the data processing method above, which will not be repeated here. Each module in the above data processing device can be implemented in whole or in part by software, hardware and a combination thereof. The above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0164] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Fig.10 As shown. The computer device includes a processor, a memory and a network interface connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data processing data. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a data processing method is implemented.

[0165] Those skilled in the art will understand that Fig.10 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0166] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.

[0167] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.

[0168] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory, etc. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).

[0169] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0170] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.

Claims

1. A data processing method, characterized in that: The method comprises: Obtain a first business document corresponding to the first document type and a second business document corresponding to the second document type; Acquire a first business field corresponding to the first business document; Determine a field conversion model corresponding to the first business document, where the field conversion model is used to convert a field of the first document type into a field of the second document type; Inputting the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; Extracting a first character string corresponding to the first business field from the first business document, and extracting a second character string corresponding to the second business field from the second business document; Calculating string similarity based on the first string and the second string; When the string similarity is greater than a similarity threshold, an association relationship between the first business document and the second business document is established.

2. The method according to claim 1, characterized in that The calculating the string similarity according to the first string and the second string comprises: Dividing the first string into a first set of substrings; Dividing the second string into a second set of substrings; Combine the first substring set with the substrings in the second substring set to obtain a third substring set; Obtain the first number of times a third substring in the third substring set appears in the first substring set, and obtain the second number of times a third substring in the third substring set appears in the second substring set; Obtain a first vector based on the first order number corresponding to the third substring, and obtain a second vector based on the second order number corresponding to the third substring; The vector similarity between the first vector and the second vector is calculated, and the string similarity is obtained according to the vector similarity.

3. The method according to claim 2, characterized in that The obtaining of the first vector based on the first order number corresponding to the third substring, and the obtaining of the second vector based on the second order number corresponding to the third substring include: Taking the first order digits corresponding to each of the third substrings as vector values, to obtain a first vector; The second order numbers corresponding to the respective third substrings are taken as vector values ​​to obtain a second vector; wherein the vector values ​​of the same dimension in the first vector and the second vector correspond to the same third substring.

4. The method according to claim 1, characterized in that: There are multiple first character strings, there are multiple second character strings, and calculating the character string similarity based on the first character strings and the second character strings includes: Calculating the similarity between each of the first character strings and the corresponding second character string to obtain a first similarity; Concatenate the first strings in the order of the strings to obtain a first concatenated string; concatenate the plurality of second character strings in the character string order to obtain a second concatenated character string; Calculating the similarity between the first concatenated character string and the second concatenated character string to obtain a second similarity; Performing statistics on the first similarities to obtain statistical similarities; A weighted sum calculation is performed based on the statistical similarity and the second similarity to obtain the string similarity.

5. The method according to claim 1, characterized in that After establishing the association relationship between the first business document and the second business document, the method further includes: Obtaining a second business status corresponding to the second business document; updating a first business status corresponding to the first business document based on the second business status; A status reminder message corresponding to the first service status is sent to a first service terminal corresponding to the first service document.

6. The method according to claim 1, characterized in that The establishing of an association relationship between the first business document and the second business document includes: Sending association prompt information to a first terminal, where the first terminal is a terminal of a first user corresponding to the first service document, and the association prompt information is used to prompt to associate the first service document with the second service document; In response to a document association request sent by the first terminal, an association relationship between the first business document and the second business document is established, wherein the document association request is triggered in response to an association operation of a user after the first terminal displays the association prompt information.

7. The method according to claim 1, characterized in that The training steps of the field conversion model include: Obtaining a first training document corresponding to the first document type and a second training document corresponding to the second document type; Extracting a first training service field from the first service document, and extracting a second training service field from the second service document; Inputting the first training business field into the field conversion model to be trained to perform field conversion to obtain a predicted business field; Obtaining a model loss value based on a difference between the predicted business field and the second training business field; The model parameters of the field conversion model are adjusted based on the model loss value to obtain a trained field conversion model.

8. A data processing device, characterized in that: The device comprises: A business document acquisition module, used to acquire a first business document corresponding to a first document type and a second business document corresponding to a second document type; A first business field acquisition module, used to acquire a first business field corresponding to the first business document; A field conversion model determination module, used to determine a field conversion model corresponding to the first business document, wherein the field conversion model is used to convert a field of the first document type into a field of the second document type; A field conversion module, used for inputting the first business field into the field conversion model for field conversion to obtain a second business field corresponding to the second document type; a string extraction module, configured to extract a first string corresponding to the first business field from the first business document, and to extract a second string corresponding to the second business field from the second business document; A string similarity calculation module, used for calculating string similarity based on the first string and the second string; The association relationship establishing module is used to establish an association relationship between the first business document and the second business document when the similarity of the character strings is greater than a similarity threshold.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Business data tracking method and device

    CN106909492A

  • Character string comparison method and device, terminal equipment and storage medium

    CN108363729A

  • Service document conversion method and device, storage medium and computer equipment

    CN110704519A

  • System and program for automatic practice

    JP2010157199A

Cited By

  • Data processing

    US12762106B2

  • Data processing

    US20250307229A1