A document recognition method and device

By establishing preset association relationships and priority processing in document recognition, and using eigenvalue training models to identify target data in the document, the problem of low recognition efficiency and accuracy in the prior art is solved, and more efficient and accurate Data extraction.

CN118860986BActive Publication Date: 2024-12-24CHINA BOND FINANCIAL VALUATION CENT CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411322749.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-23
Publication Date
2024-12-24
Estimated Expiration
2044-09-23

AI Technical Summary

Technical Problem

The prior art has low efficiency and accuracy when identifying and extracting business data from unstructured information documents, making it difficult to quickly and accurately obtain target data in various information documents, affecting data management and analysis.

Method used

By establishing a preset association relationship between the document and the target data type, processing documents in groups, determining priority based on document complexity, prioritizing documents with low complexity, and using the document recognition model trained by feature value to identify them until the preset conditions are met , and generate a data processing link to send to the user.

Benefits of technology

It improves the efficiency and accuracy of document recognition, reduces the impact of interference items on target data, and ensures the accuracy and efficiency of identification results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118860986B_ABST
    Figure CN118860986B_ABST
Patent Text Reader

Abstract

The present application discloses a document recognition method and device, which relates to the field of digital processing technology, including: obtaining at least one document; grouping the documents based on the preset association relationship between the document and the target data type to obtain at least one document group; performing complexity recognition processing on each document in the document group to obtain the complexity corresponding to each document; determining the priority of each document based on the complexity corresponding to the document in the document group, wherein the lower the complexity, the higher the priority corresponding to the document; based on the priority corresponding to each document in the document group, sequentially identifying the data to be extracted corresponding to the target data type that has the preset association relationship with the document in the document, after identifying the data to be extracted, stopping the recognition of other documents in the document group, and extracting the data to be extracted as the target data. Based on this, the efficiency of document recognition can be improved, the influence of interference items can be reduced, and the accuracy of the obtained target data can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of digital processing technology, and more specifically, to a document recognition method and device. Background Art

[0002] As the use scenarios of business data continue to expand, the requirements for the accuracy and timeliness of collected business data are also increasing. Among them, business data is mostly collected from unstructured reports, PDFs, pictures and other information documents. For example, information documents such as issuance documents, payment reminders, interest payment and exercise announcements, financial reports, issuance forecasts or rating documents are obtained through external procurement, self-procurement, third-party channels, etc., and business data is further extracted from various information documents.

[0003] At present, business data can be identified and extracted from information documents by manual identification and input, or by using standardized model identification, but the above identification methods have low recognition efficiency and accuracy. Therefore, in the face of a variety of information documents as business data carriers, how to accurately and efficiently identify effective business data from information documents for direct use by data managers or data analysis systems has become an important constraint on the subsequent promotion of data product expansion and data value exploration. Summary of the invention

[0004] In view of the above problems, the present application provides a document recognition method and device to achieve the purpose of accurately and efficiently identifying valid data from a document. The specific scheme is as follows:

[0005] The first aspect of the present application provides a document recognition method, comprising:

[0006] Acquire at least one document, wherein the document has a preset association relationship with at least one target data type;

[0007] Based on the preset association relationship between the documents and the target data type, the documents are grouped to obtain at least one document group, wherein each document in the document group has the preset association relationship with the same target data type;

[0008] Performing complexity identification processing on each of the documents in the document group to obtain the complexity corresponding to each of the documents in the document group;

[0009] Determining the priority of each document according to the complexity corresponding to the documents in the document group, wherein the document with lower complexity has higher priority;

[0010] According to the priority level corresponding to each of the documents in the document group, the data to be extracted in the documents are identified in sequence until a target document containing the data to be extracted is identified, and the identification of other documents in the document group is stopped, wherein the data to be extracted is data corresponding to the target data type having the preset association relationship with the document;

[0011] The data to be extracted is extracted from the target document as target data.

[0012] In a possible implementation, identifying the data to be extracted in the documents in sequence according to the priority corresponding to each document in the document group until a target document containing the data to be extracted is identified, and then stopping the identification of other documents in the document group includes:

[0013] According to the priority level corresponding to each of the documents in the document group, determining the document that needs to be recognized in the current order as the document to be recognized;

[0014] Calling a document recognition model corresponding to the document type of the document to be recognized, performing recognition processing on the document to be recognized, and obtaining a data result corresponding to the target data type in the document to be recognized, wherein the document recognition model is a model trained in advance using sample documents belonging to the same document type as feature values ​​and the data result corresponding to the sample documents as target values;

[0015] Determine whether the data result meets the preset conditions;

[0016] If the data result meets the preset condition, the data result is used as the data to be extracted, and the recognition of other documents in the document group is stopped;

[0017] If the data result does not meet the preset condition, the step of determining the document that needs to be identified in the current order as the document to be identified based on the priority level corresponding to each document in the document group is executed until the data result corresponding to the target data type in the identified document to be identified meets the preset condition.

[0018] In a possible implementation, the method further includes:

[0019] In the case where there are multiple document groups, and each of the document groups has corresponding data to be extracted, determining the document recognition model corresponding to the data to be extracted of each of the document groups;

[0020] The target data is generated based on at least two of the document recognition models having a preset model association relationship and the data to be extracted corresponding to the document recognition models.

[0021] In a possible implementation, the determining whether the data result meets a preset condition includes:

[0022] Acquire a first preset condition corresponding to the target data type, where the first preset condition includes: at least one constraint condition that the target data corresponding to the target data type needs to satisfy;

[0023] Based on the first preset condition, checking the data result corresponding to the target data type to determine a satisfaction rate of the data result for the first preset condition;

[0024] It is determined whether the satisfaction rate is not less than a preset threshold specified by a second preset condition.

[0025] In a possible implementation, the method further includes:

[0026] When the satisfaction rate of the data result is not less than the preset threshold and is not equal to 1, it is determined that the data result is data to be extracted, and there are miscellaneous items that do not satisfy the constraint condition in the data to be extracted;

[0027] Based on the miscellaneous items in the data to be extracted that do not satisfy the constraint conditions, the data to be extracted are transformed, and the data to be extracted obtained after the transformation are used as target data, wherein the data to be extracted obtained after the transformation at least includes: a mark for the miscellaneous items, and the constraint conditions that the miscellaneous items do not satisfy.

[0028] In a possible implementation, the method further includes:

[0029] Generate a data processing link based on the data to be extracted corresponding to the target data type and the document corresponding to the data to be extracted, and the document recognition model for processing the document;

[0030] The data processing link is sent to the target user.

[0031] In a possible implementation, the method further includes:

[0032] In response to receiving an operation of the target user determining that the target data is false, predicting a duration for performing recognition processing on the document in the document group that has not been recognized, to obtain a first duration;

[0033] Predicting the duration of manual recognition of the document that has not been recognized, to obtain a second duration;

[0034] Determining whether the first duration is not less than the second duration;

[0035] If the first time length is less than the second time length, performing recognition processing on the document that has not been recognized;

[0036] If the first time length is not less than the second time length, the document that has not been recognized is sent to the target user, and the target user is prompted to perform manual recognition.

[0037] In a possible implementation, the method further includes:

[0038] After each of the documents in the document group is identified and processed, if the target data is not obtained, the identification process of the documents in the document group is suspended until the documents in the document group are updated, and the step of identifying the documents in turn according to the priority level corresponding to each document in the document group is executed.

[0039] In a possible implementation, obtaining at least one document includes:

[0040] Receive unstructured data files from different data sources;

[0041] The unstructured data file is converted into a document in a preset format.

[0042] A second aspect of the present application provides a document recognition device, comprising:

[0043] A document acquisition unit, used to acquire at least one document, wherein the document has a preset association relationship with at least one target data type;

[0044] A document grouping unit, configured to group the documents based on the preset association relationship between the documents and the target data type to obtain at least one document group, wherein each document in the document group has the preset association relationship with the same target data type;

[0045] A complexity identification unit, configured to perform complexity identification processing on each of the documents in the document group to obtain the complexity corresponding to each of the documents in the document group;

[0046] A priority determination unit, configured to determine the priority of each document according to the complexity corresponding to the document in the document group, wherein the document with lower complexity has higher priority;

[0047] an identification processing unit, configured to identify the data to be extracted in the documents in sequence according to the priority level corresponding to each document in the document group, until a target document containing the data to be extracted is identified, and then stop identifying other documents in the document group, wherein the data to be extracted is data corresponding to the target data type having the preset association relationship with the document;

[0048] The data extraction unit is used to extract the data to be extracted from the target document as target data.

[0049] From the above technical solution, it can be seen that the present application classifies documents that are associated with the same target data type into the same document group, and determines the complexity of each document in the same document group. Furthermore, according to the complexity of the document, the priority of each document in the document group for recognition processing is determined.

[0050] When performing recognition processing, the present application gives priority to documents with lower complexity, and can recognize more documents with lower complexity in a short time, so that data corresponding to the target data type that has a preset association relationship with the document group can be obtained more quickly, that is, the data to be extracted or the target data, thereby improving recognition efficiency. After the target data is recognized, the recognition of documents with lower priority and higher complexity is stopped, so as to minimize the impact of interference items on the target data and improve the accuracy of the extracted target data. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] In order to more clearly illustrate the embodiments of the present application 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 embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.

[0052] Figure 1 A flowchart of a method for implementing document recognition provided in an embodiment of the present application;

[0053] Figure 2 A schematic diagram of the mapping relationship of the data templates provided in the embodiment of the present application;

[0054] Figure 3 A diagram showing an application example of a document recognition method provided in an embodiment of the present application;

[0055] Figure 4 A schematic diagram of the structure of a document recognition device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0056] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0057] One of the main reasons for the low efficiency and accuracy of document recognition in the prior art is that the single processing object is too large, that is, the complexity of the document recognized at a single time is relatively high. Since the content of a highly complex document is relatively large and there are more interference items, the accuracy of the recognition result of a highly complex document is lower than that of a document with low complexity. For example, the data result obtained by recognizing a 100M document is less accurate than the data result obtained by recognizing a single 10M document, because the content of a 100M document is relatively large, and the context of the data result contains more relevant content, forming more interference items, which interfere with the accuracy of the data result.

[0058] In order to minimize the impact of interference items on data results, it takes more time to remove interference items from data results. Therefore, the recognition time consumed by processing documents with high complexity is much greater than that of documents with low complexity. In addition, if the single processing object is too large, the document recognition environment often runs at an overly high level, which is less efficient than running at a low level and has a higher risk of abnormal operation. It can be seen that the input-output ratio varies greatly when facing documents of different complexity.

[0059] Based on this, this application starts from the complexity of the document, improves the accuracy and efficiency of document recognition, and proposes a document recognition method that can be applied to various server terminals, PC terminals, mobile devices, etc. that can run computer programs, where the computer program is a program that implements the document recognition method described in the embodiment of this application.

[0060] Reference Figure 1 , a flowchart of a method for implementing document recognition provided in an embodiment of the present application is provided, and the recognition process corresponding to the document recognition method is introduced, which specifically includes the following steps:

[0061] Step S110, obtaining at least one document, wherein the document has a preset association relationship with at least one target data type.

[0062] In the embodiments of the present application, documents may also be referred to as files. In addition to files generated by word editing software such as word and excel, such as text files, pdf, tables, etc., they may also include files that are not directly generated by word editing software, such as editable programming files commonly found in software systems, such as source code files, configuration files, etc. Although programming files are generated by programming software, they are usually stored in text form. Therefore, the document recognition method proposed in the embodiments of the present application may also be used to perform document content recognition.

[0063] A document is a collection of data / information stored on a computer under a single name. The document contains data of at least one data type. The embodiment of the present application pre-associates the document with the data type contained therein. Before identifying the document content, the document is pre-classified so that when the relevant data of the target data type is subsequently extracted, it can be identified from the documents that have an associated relationship with the target data type, thereby improving the efficiency of document recognition and reducing invalid recognition of documents.

[0064] In a possible implementation, acquiring at least one document may include: receiving unstructured data files from different data sources; and converting the unstructured data files into documents in a preset format.

[0065] Inevitably, the acquired files are of various types, among which unstructured data is irregular or incomplete in structure, has no predefined data model, and is not convenient to be represented by a two-dimensional logical table in a database, including office documents of all formats, text, pictures, HTML, various reports, images, and audio / video information, etc. Therefore, it may not be suitable for operations such as recognition and extraction of data and text in files. For example, the text and picture data in PDF cannot be recognized or extracted. Therefore, before recognition, PDF needs to be converted into a text document in word format to facilitate the subsequent recognition and extraction of text data therein.

[0066] The embodiments of the present application can process various types of non-structured data, and can use but is not limited to using OCR technology (Optical Character Recognition) to convert PDF, PNG, JPG and other image formats and various scanned documents into JSON, Word and other formats that are easy to identify text content.

[0067] In an embodiment of the present application, the source of the document may be automatic network data crawling or external access, etc. Specifically, the document type and document acquisition method may be determined according to the application scenario of the document recognition method. For example, the document recognition method is applied to a bank's bond system to identify key information in various bond-related documents. Then, bond-related documents may be screened out from documents obtained by the bank from external, self-purchased, or third-party channels, such as: prospectuses, bond underwriting agreements, bond trading contracts, a company's fundraising instructions and evaluation and certification reports, bond trading documents, etc.

[0068] Further, according to the type of the document content of each document, the data type with which it is associated is determined, and the document is associated with the data type. For example, a bond trading contract contains the bond buyer and seller, the contract effective time, the bond type and other contents. Therefore, the bond trading contract can be associated with the contract effective time, the buyer's name, the seller's name, the bond type and other data types. The bond system obtains a large number of documents and document types each time, and the data type associated with each document may not be the same. Therefore, it is necessary to identify and summarize the data in it to simplify the information of the bond system and improve the information query efficiency of the staff.

[0069] Step S120: grouping the documents based on a preset association relationship between the documents and the target data type to obtain at least one document group.

[0070] Each document in the document group has a preset association with the same target data type.

[0071] When a large number of documents are obtained and each document is associated with a different target data type, documents with the same associated target data type can be divided into a document group. Based on this, each document in a document group has a preset association relationship with the same target data type. When identifying the target data corresponding to the target data type, only the documents in this document group can be identified, reducing the identification of other documents outside the document group that do not contain the target data type, thereby improving the efficiency of document recognition.

[0072] It is understandable that a document contains a lot of content, and there may be multiple associated target data types in one document. Therefore, if a document has multiple associated target data types, the document can be copied and assigned to each document group corresponding to the associated target data type to achieve multi-line recognition of the document. Alternatively, the document group contains the storage path of each document, rather than the document itself. When recognizing, you only need to follow the path of the document to obtain it.

[0073] Step S130 , performing complexity identification processing on each document in the document group to obtain the complexity corresponding to each document in the document group.

[0074] Step S140 , determining the priority of each document according to the complexity of the documents in the document group, wherein the lower the complexity, the higher the priority of the document.

[0075] The embodiments of the present application introduce the concept of document complexity. The complexity of a document depends on the amount of space occupied by the document, the degree of resource consumption, the difficulty of processing, the document content, the number of document-associated data types, etc. It can be understood that the larger the amount of space occupied by the document, the more document content, or the more document-associated data types, the higher the complexity of the document.

[0076] In one possible implementation, developers can pre-set a standard for evaluating document complexity based on the application scenario, for example, a linear calculation formula for document size and document complexity, where document complexity increases with the amount of space occupied by the document. The complexity of the document is determined based on the current document size and the linear calculation formula, or a complexity assessment model is trained by combining multiple complexity assessment factors, and the complexity assessment model is called to perform complexity assessment processing on each document to obtain the complexity of each document.

[0077] As described above, the higher the complexity of a document, the more interference items there are and the longer the recognition time is when the document is recognized. Therefore, the recognition priority of the documents in the document group is sorted according to the complexity of the document. The higher the complexity, the lower the priority. Conversely, the lower the complexity, the higher the priority. For example, the document group includes document 1, document 2, and document 3, and the corresponding complexities are 80%, 60%, and 30%, respectively. Based on this, the priority order is: document 3, document 2, document 1.

[0078] Step S150 , according to the priority level corresponding to each document in the document group, the data to be extracted in the documents are identified in sequence until a target document containing the data to be extracted is identified, and the identification of other documents in the document group is stopped.

[0079] Step S160: extracting the data to be extracted from the target document as target data.

[0080] The data to be extracted is data corresponding to a target data type that has a preset association relationship with the document.

[0081] In the embodiment of the present application, the priority represents the level of priority processing. The higher the priority, the earlier the processing order. For example, in step S140, the priority order is: document 3, document 2, document 1, then document 3 is processed in sequence, and after document 3 is recognized, document 2 and document 1 are recognized in sequence. Each time a single document is recognized, the next document is recognized after the recognition is completed. Optionally, when there are many documents in the document group, multi-threaded parallel recognition of documents can be performed to simultaneously recognize multiple documents in the document group to improve document recognition efficiency.

[0082] It is understandable that the higher the priority, the lower the complexity of the document, and the shorter the time consumed to identify the document. For example, 5 documents with a complexity of less than 40% can be identified within 10 seconds, but only 2 documents with a complexity of more than 60% can be identified within 10 seconds. Therefore, prioritizing the identification of documents with low complexity can identify multiple documents in a short time and improve the efficiency of document identification. In addition, documents with low complexity have fewer interference items on the target data, and the target data obtained by identification has a higher accuracy rate.

[0083] In the process of identifying documents in a document group, if the data to be extracted corresponding to the target data type associated with the document group is identified, the identification of other documents in the document group is stopped to prevent the data in other documents from affecting the accuracy of the identified data to be extracted. Moreover, if the data to be extracted has been obtained, continuing to identify other documents will prolong the identification time and reduce the document identification efficiency. Furthermore, the data to be extracted is extracted from the target document and can be sent to the front-end user as the target data, or can be summarized and stored according to the data type.

[0084] In summary, the embodiment of the present application groups documents that are associated with the same target data type into the same document group, and determines the complexity of each document in the same document group. Furthermore, the priority of each document in the document group for recognition processing is determined based on the complexity of the document. When performing recognition processing, documents with lower complexity are processed first, and more documents with lower complexity can be recognized in a short time, so that data corresponding to the target data type that has a preset association relationship with the document group, that is, data to be extracted or target data, can be obtained more quickly, thereby improving recognition efficiency, and after the target data is recognized, stop recognizing documents with lower priority and higher complexity, minimize the impact of interference items on the target data, and improve the accuracy of the extracted target data.

[0085] Next, other possible implementations of a document recognition method provided in an embodiment of the present application are described.

[0086] In a possible implementation, the above-mentioned step S150 may include: determining, based on the priority level corresponding to each document in the document group, the document that needs to be recognized in the current order as the document to be recognized; calling the document recognition model corresponding to the document type of the document to be recognized, and performing recognition processing on the document to be recognized to obtain a data result corresponding to the target data type in the document to be recognized, wherein the document recognition model is a model that is pre-trained with sample documents belonging to the same document type as feature values ​​and the data results corresponding to the sample documents as target values; and judging whether the data results meet preset conditions.

[0087] If the data result meets the preset conditions, the data result will be used as the data to be extracted, and the recognition of other documents in the document group will be stopped.

[0088] If the data result does not meet the preset conditions, the step of determining the documents that need to be identified in the current order as the documents to be identified is performed based on the priority level corresponding to each document in the document group, until the data result corresponding to the target data type in the identified documents to be identified meets the preset conditions.

[0089] Each time after the previous document is recognized and processed, the next document to be recognized is determined according to the priority of the documents in the document group as the document to be recognized, and subsequent steps are performed on the document to be recognized this time to avoid confusion in the document recognition order and reduce recognition efficiency.

[0090] The reasons for the low efficiency of document recognition in the prior art also include: a single standardized model, that is, all types of documents use the same document recognition model for recognition processing, while the carriers of target data / data to be extracted are often diverse. A single standardized model faces documents of different sizes and types, and the input-output ratio is quite different. To obtain the same target data, resource consumption often increases exponentially, and it will also affect the accuracy. For example, using a standardized model to recognize and process a PDF document of more than 100M, the processing resources and processing time consumed by the standardized model to recognize 10 10M documents exceed those consumed. If a model specially trained for recognizing PDF documents of more than 100M is used, the processing time will be greatly reduced, thereby improving the recognition efficiency. Alternatively, different bond companies have different ways of writing announcements, instructions, etc., so the corresponding document recognition model can also be selected according to the company described in the document or the type of file to which it belongs. For example, the prospectus and evaluation certification report of Company A use the bond information recognition model of Company A, and the prospectus of Company B uses the bond information recognition model of Company B. Similarly, if a model specially trained for recognizing a document of a certain document type is used, the processing time will also be greatly reduced.

[0091] Therefore, the embodiment of the present application creates a document recognition model for commonly recognized document types in advance, collects a document sample set corresponding to each document type from historical documents, and determines the data result corresponding to each document in the document sample set. During training, the document sample set is used as the input data of the document recognition model, and the data result corresponding to each document is used as the output data of the document recognition model. Based on this, training is performed, and the model parameters of the document recognition model are adjusted at the same time, so that the document recognition model obtained by training can be processed according to the input document and output the data result corresponding to the document.

[0092] Based on the above model training method, a document recognition model corresponding to each document type is obtained. Based on the document type of the current document to be processed, a document recognition model corresponding to the document type is determined from multiple pre-trained document recognition models, and document recognition processing is performed on it to obtain the corresponding data results.

[0093] It is understandable that a document may have multiple associated data types, and the data results output by the document recognition model may also include data of other data types contained in the document, as well as irrelevant data extracted by the document recognition model due to model errors. Therefore, it is necessary to further judge the correctness of the data results output by the model to avoid inaccurate target data.

[0094] Optionally, in the embodiment of the present application, judgment conditions may be set in advance for the data results of each target data type, i.e., the preset conditions mentioned above. The preset conditions may be set according to the format, form, threshold, etc. of the data results corresponding to the target data type. For example, when the target data type is a bond type, the corresponding preset condition is that the data result includes the pre-stored full name of the bond, the abbreviation of the bond, or the bond code. Alternatively, when the target data type is the name of the bond buyer, the corresponding preset condition may be that the data result is continuous Chinese characters. Once numbers or English characters appear in the data result, it is determined that the data result does not meet the preset conditions, and the recognition of the next document continues.

[0095] In one possible implementation, determining whether a data result meets a preset condition may include: obtaining a first preset condition corresponding to a target data type, the first preset condition including: at least one constraint condition that the target data corresponding to the target data type needs to satisfy; based on the first preset condition, inspecting the target data corresponding to the target data type to determine a satisfaction rate of the target data for the first constraint condition; and determining whether the satisfaction rate is not less than a preset threshold value specified by a second preset condition.

[0096] The embodiment of the present application uses a constraint check method to verify the data results to ensure that the data results meet the preset conditions. It is understandable that due to the large amount of content contained in the document, it is inevitable that the data results obtained by the document recognition model from the document contain miscellaneous items. Therefore, the embodiment of the present application determines whether the data results meet the preset conditions by the satisfaction rate of the data results for the constraint conditions. When the satisfaction rate reaches the preset threshold, it can be determined that the data results basically meet or completely meet the preset conditions, and can be used as the target data corresponding to the target data type associated with the document group. The data result is confirmed as the data to be extracted, and the recognition of the document group is terminated. If the satisfaction rate does not reach the preset threshold, it is determined that the data result does not meet the preset conditions, and the recognition process of the next document of the document group can be continued.

[0097] Next, the above judgment process is exemplified by the following example. When the above document recognition method is applied to a bank transaction system and is used to identify various types of data in a bank's daily transaction log document, when the target data type is bank operator information, assuming that the date is September 1, the employee information of the bank operator information obtained by identifying the transaction log document on September 1 should at least meet the constraint condition that the employee information is the employee information of an employee who has a work clock-in record on September 1, and the optional constraint condition may also include: the operation time corresponding to the identified employee information is within the preset operation time range, etc. The above constraint condition is determined as the first preset condition.

[0098] Determine the satisfaction rate of the employee information extracted from the transaction log document on September 1 for the first preset condition. In this example, the preset threshold is 80%. When the satisfaction rate is greater than or equal to 80%, it is determined that the identified employee information meets the preset condition, and the identified employee information is used as the data to be extracted, and the recognition of other documents in the document group is stopped. When the satisfaction rate is less than 80%, it is determined that the extracted employee information does not meet the preset condition, and other documents in the document group continue to be recognized in sequence.

[0099] Optionally, when the satisfaction rate of the data result is not less than a preset threshold and is not equal to 1, the data result is determined to be data to be extracted, and there are miscellaneous items in the data to be extracted that do not satisfy the constraints; based on the miscellaneous items in the data to be extracted that do not satisfy the constraints, the data to be extracted is transformed, and the data to be extracted after the transformation is used as the target data, and the data to be extracted after the transformation includes at least: marking of the miscellaneous items, and the constraints that the miscellaneous items do not satisfy.

[0100] It is understandable that if the satisfaction rate of the data result is not less than the preset threshold, it means that the data result meets the preset conditions and can be used as the data to be extracted or the target data. However, since the satisfaction rate is not equal to 1, there are a small amount of miscellaneous items in the data result that meet the preset conditions. In order to avoid the situation where the data result is fed back to the front-end user as the target data, the user does not remove the miscellaneous items and directly uses it, which leads to problems in subsequent documents or transactions. The embodiment of the present application pre-marks the miscellaneous items in the data to be extracted, and points out that the data is identified as miscellaneous items because it does not meet one or several of the preset conditions, so as to provide reference conditions for the front-end user to remove the miscellaneous items.

[0101] The embodiment of the present application takes into account that the model may have recognition errors and that correct data exists in the miscellaneous items, and therefore does not remove them from the target data. In actual applications, if the developer believes that the server or system can help the user to remove the miscellaneous items in the target data, and sets a procedure for extracting the miscellaneous items in the program that implements the document recognition method, then the miscellaneous items in the data to be extracted can be removed in advance before the target data is fed back, thereby simplifying the data processing operations of the front-end users.

[0102] In a possible implementation, multiple thresholds are set in the second preset condition, and the extracted data results are divided into four levels: fully compliant, basically compliant, basically non-compliant, and non-compliant with the preset condition, and different subsequent recognition strategies are set for each level. For example, when the satisfaction rate is greater than 90%, the data result is determined to be fully compliant with the preset condition, and the recognition of other documents in the document group is stopped; when the satisfaction rate is greater than 70% and less than 90%, the data result is determined to be basically compliant with the preset condition, and the recognition of other documents in the document group continues until the next data result that basically meets the preset condition is recognized again, and the two data results that basically meet the preset condition are combined as the data to be extracted, and the recognition of other documents in the document group is stopped; when the satisfaction rate is greater than 50% and less than 70%, or less than 50%, the data result is determined to be basically non-compliant with the preset condition or non-compliant with the preset condition, respectively, and the recognition of other documents in the document group continues.

[0103] In a possible implementation, the above-mentioned document recognition method may also include: when there are multiple document groups and each document group has corresponding data to be extracted, determining the document recognition model corresponding to the data to be extracted of each document group; generating target data based on at least two document recognition models that have a preset model association relationship, and the data to be extracted corresponding to the document recognition models.

[0104] It is understandable that the target data obtained from different document groups are often correlated. For example, in the document recognition method applied to the bond trading system, the target data of the target data type obtained from the bond-related documents, such as the bond buyer, seller, transaction time, etc., all have certain correlations. These related data exist in different documents. If the single data obtained by each document recognition model is used as the final data to be extracted or target data based on the mapping relationship between the document and the document recognition model, the data with correlation will be relatively scattered. The purpose of document recognition at the front end is to centrally manage or apply the data with correlation in the document. If the target data finally obtained are all independent data and the related data cannot be centrally output, it will be unfavorable to make an overall accuracy and completeness judgment on the group of related target data through correlation.

[0105] In an embodiment of the present application, a document recognition model whose output data is correlated has a pre-set association relationship, that is, a preset model association relationship between the document recognition models, and the data to be extracted output by several document recognition models that have a preset model association relationship are combined and sent to the front end as the final target data, so that the front-end user does not need to manually combine the correlated target data after receiving the target data.

[0106] Reference Figure 2 , a schematic diagram of the mapping relationship of the data template provided in the embodiment of the present application, the embodiment of the present application introduces the data template as the medium of the preset model association relationship, a data template can have a mapping relationship with multiple document recognition models, and the preset model association relationship described above exists between the multiple document recognition models that have a mapping relationship with the data template. Based on this, when the output of the document recognition model is determined to be data to be extracted that meets the preset conditions, there is no need to query the document model library for models with preset model association relationships. It is only necessary to deliver the data to be extracted to the data template. The data template combines the data to be identified obtained by multiple document recognition models according to the mapping relationship between the data template and the document recognition model to obtain a data template. Then, multiple related data to be extracted will be sent to the front-end user in a combined form, simplifying the data processing process of the front-end user and improving the management efficiency of the data in the document.

[0107] Figure 2 In the example, documents can be grouped according to data types to obtain document groups corresponding to each data type, that is, document group 1 having a preset association relationship with data type 1, document group 2 having a preset association relationship with data type 2, document group 3 having a preset association relationship with data type 3, and document group 4 having a preset association relationship with data type 4. Further, when identifying each document in the document group, the corresponding document processing model is called according to the document type of the document in the current order.

[0108] Data 1 to 4 output by models 1 to 3 respectively are all data to be extracted that are judged to meet the preset conditions. Models 1 to 3 input data 1 to 4 into the corresponding data templates respectively. Based on this, data template 1 finally generates the target data of the combination of "data 1, data 2, data 3", and data template 2 generates the target data of the combination of "data 2, data 4", and sends the target data to the front end for users to view and use, thereby reducing the time spent by users on manually searching and combining data and improving the user's data management efficiency.

[0109] In a possible implementation, the document recognition method may further include: generating a data processing link based on the data to be extracted corresponding to the target data type and the document corresponding to the data to be extracted, and a document recognition model for processing the document; and sending the data processing link to the target user.

[0110] It is understandable that the document recognition process involves document grouping, data types, document recognition models and data templates. If an abnormality occurs in any of these links, resulting in problems with the final target data, the front-end user may need to re-group and re-recognize all documents. The document recognition method has poor error correction and error location capabilities.

[0111] Based on this, the document recognition method of the embodiment of the present application generates a data processing link that can characterize the processing process of the target data while outputting the target data, such as "data to be extracted / target data-document recognition model-target document name / path-belonging document group-associated target data type".

[0112] Optionally, the document group may also include multiple documents that did not obtain the data to be extracted after identification, and the document identification models corresponding to each of these documents, the output data results, and the judgment process of the data results, etc., may also be added to the data processing link. However, in this implementation, the data processing link may not be presented in the above-mentioned shorter text, so the data processing link can be a web page jump link, which presents the above-mentioned content in the form of a web page, simplifying the page for the front-end user to display the target data.

[0113] Based on this consideration, in a possible implementation, the document recognition method may also include: in response to receiving an operation by the target user to determine that the target data is false, predicting the duration of recognition processing for the unrecognized documents in the document group to obtain a first duration; predicting the duration of manual recognition of the unrecognized documents to obtain a second duration; determining whether the first duration is not less than the second duration; if the first duration is less than the second duration, recognition processing is performed on the unrecognized documents; if the first duration is not less than the second duration, sending the unrecognized documents to the target user, and prompting the target user to perform manual recognition.

[0114] The target data is for front-end users to view and use. If the output target data is considered by the user to be wrong, that is, "false", the user can view the target data processing link corresponding to the target data to check whether the data processing process is correct. If the data processing process is correct, the recognition process of other unrecognized documents in the document group can be initiated to obtain other data that may be true.

[0115] However, there is a possibility that the remaining unrecognized documents in the document group are usually more complex than the recognized documents. Therefore, the time taken to identify them through the document recognition model may not be as short as the time for manual recognition. In addition, due to the large number of interference items in the document, the accuracy of the identified target data is reduced, and the target data obtained is still false.

[0116] In the embodiment of the present application, priority is given to the recognition time. If the time consumed by the document recognition model to recognize a document is longer than the time consumed by manual recognition of the document, manual processing is selected to send the unrecognized documents in the document group to the front-end user, and remind the user to perform manual recognition on them. In the case where the advantage of model recognition is smaller than that of manual recognition, the embodiment of the present application intelligently selects manual recognition of documents to improve the efficiency of document recognition, and the target data obtained by manual recognition is more in line with user needs and has higher accuracy. Based on this, the document recognition method provided in the embodiment of the present application can adjust the relationship between resources and efficiency and reduce unnecessary waste of resources.

[0117] In one possible implementation, after each document in the document group is recognized and processed, if the target data corresponding to the target data type is not obtained, the recognition process of the documents in the document group is suspended until the documents in the document group are updated, and the steps of recognizing the documents in turn according to the priority corresponding to each document in the document group are executed.

[0118] After each document in the document group is identified, no data result that meets the preset conditions is obtained, or the obtained target data is determined to be false by the user, but there are no other unidentified documents in the document group at this time, it is necessary to wait for the document group to receive a new document. When the document group receives the new document, if there is only one new document, the new document is identified; if there are two or more new documents, the above step S130 and subsequent steps are executed for the new document, and the new documents are identified in turn according to the complexity of the document.

[0119] Based on this, the embodiments of the present application can intelligently and adaptively schedule different recognition strategies for the authenticity of the document group and the target data corresponding to the document group, thereby improving the adaptability of the document recognition method.

[0120] The document recognition device provided in an embodiment of the present application is described below. The document recognition device described below and the document recognition method described above can be referenced to each other.

[0121] Reference Figure 3 , an application example diagram of a document recognition method provided in an embodiment of the present application, exemplifies the practical application of the document recognition method described above. In this example, the document recognition method is applied to a file management system consisting of "server-Qingyun system-user end", wherein the server can automatically collect tasks by crawling, that is, automatically collect pictures, documents, files, etc. that need to be recognized, that is, the original documents to be recognized, and the Qingyun system is a data storage system for storing original documents.

[0122] The server calls and executes the operation of "steps S110-160" to identify the original document to obtain the identification result. Among them, if there are unstructured documents such as pictures and tables in the collected files, the Ocr-table recognition service is used to convert the unstructured documents such as tables and pictures into documents in a preset format, such as a word document, and the converted documents are recognized. The document recognition can refer to the above steps S120-S160, which will not be repeated here.

[0123] During the collection process, the server records the collection batch information of each original document and generates a collection data batch table. At the same time, the collection record of the original document and the Qingyun ID are used to generate an image recognition record table, where the collection record can include: collection time, information source, etc. The Qingyun ID can include: the storage address of the original document in the Qingyun system, which is convenient for subsequent users to review the target data. In addition, the target data or target data template identified and extracted from the original document is saved to the "Collected Data Record-Intermediate Table".

[0124] The server can also call the SMS interface to notify the user through the SMS system, reminding the user to log in to the operating system or user terminal to review the document recognition results.

[0125] After the user logs in at the user end, the user information is collected and accessed, and the automatic collection history menu is entered. The user's operation interface displays the "Collected Data Batch Table", and the document batch that needs to be reviewed is selected, or whether there are any problems in the batch of documents to be reviewed. After the batch is reviewed, the user end reviews the information in the "Image Recognition Record Table" and the "Collected Data Record-Intermediate Table". During the review process, the user's display page will be displayed at the same time, according to the Qingyun ID recorded in the "Image Recognition Record Table", the original files downloaded from the Qingyun system, such as pictures, PDFs, etc., are compared with the original files to review the recognition results.

[0126] After the user confirms that the reviewed recognition result is correct, the user automatically saves the recognition result into the database and saves it to the "Collected Data Record-Target Table"; at the same time, the data before and after the review are saved to the history database to generate the "Collected Data Record-History Table".

[0127] First, combine Figure 4 , a schematic diagram of the structure of a document recognition device provided in an embodiment of the present application, and an introduction to the document recognition device is given, such as Figure 4 As shown, the document recognition device may include:

[0128] The document acquisition unit 100 is used to acquire at least one document, wherein the document has a preset association relationship with at least one target data type;

[0129] A document grouping unit 200, configured to group the documents based on the preset association relationship between the documents and the target data type to obtain at least one document group, wherein each document in the document group has the preset association relationship with the same target data type;

[0130] A complexity identification unit 300 is used to perform complexity identification processing on each of the documents in the document group to obtain the complexity corresponding to each of the documents in the document group;

[0131] A priority determination unit 400, configured to determine the priority of each document according to the complexity corresponding to the document in the document group, wherein the document with lower complexity has higher priority;

[0132] The identification processing unit 500 is used to identify the data to be extracted in the documents in sequence according to the priority corresponding to each document in the document group, until a target document containing the data to be extracted is identified, and then stop identifying other documents in the document group, wherein the data to be extracted is data corresponding to the target data type having the preset association relationship with the document;

[0133] The data extraction unit 600 is used to extract the data to be extracted from the target document as target data.

[0134] In summary, the embodiment of the present application groups documents that are associated with the same target data type into the same document group, and determines the complexity of each document in the same document group. Furthermore, the priority of each document in the document group for recognition processing is determined based on the complexity of the document. When performing recognition processing, documents with lower complexity are processed first, and more documents with lower complexity can be recognized in a short time, so that data corresponding to the target data type that has a preset association relationship with the document group, that is, data to be extracted or target data, can be obtained more quickly, thereby improving recognition efficiency, and after the target data is recognized, stop recognizing documents with lower priority and higher complexity, minimize the impact of interference items on the target data, and improve the accuracy of the extracted target data.

[0135] In a possible implementation, the identification processing unit 500 includes:

[0136] A to-be-recognized document determination subunit is used to determine the document that needs to be recognized in the current order as the to-be-recognized document according to the priority level corresponding to each of the documents in the document group;

[0137] A model calling subunit is used to call a document recognition model corresponding to the document type of the document to be recognized, perform recognition processing on the document to be recognized, and obtain a data result corresponding to the target data type in the document to be recognized, wherein the document recognition model is a model that is pre-trained using sample documents belonging to the same document type as feature values ​​and the data results corresponding to the sample documents as target values;

[0138] A condition judgment subunit, used to judge whether the data result meets the preset conditions;

[0139] an identification stop subunit, used for, if the determination result of the condition determination subunit is yes, using the data result as the data to be extracted and stopping the identification of other documents in the document group;

[0140] The identification continuation subunit is used to execute the step of determining the document that needs to be identified in the current order as the document to be identified based on the priority level corresponding to each document in the document group if the judgment result of the condition judgment subunit is no, until the data result corresponding to the target data type in the identified document to be identified meets the preset condition.

[0141] In a possible implementation, the identification processing unit 500 further includes:

[0142] A model determination subunit, configured to determine the document recognition model corresponding to the data to be extracted of each document group when there are multiple document groups and each of the document groups has corresponding data to be extracted;

[0143] The template generation subunit is used to generate a target data template based on at least two of the document recognition models that have a preset model association relationship and the data to be extracted corresponding to the document recognition models.

[0144] In a possible implementation, the condition judgment subunit includes:

[0145] A condition acquisition subunit is used to acquire a first preset condition corresponding to the target data type, wherein the first preset condition includes: at least one constraint condition that the target data corresponding to the target data type needs to satisfy;

[0146] a satisfaction rate determination subunit, configured to check the data result corresponding to the target data type based on the first preset condition, and determine a satisfaction rate of the data result for the first preset condition;

[0147] The threshold judgment subunit is used to judge whether the satisfaction rate is not less than a preset threshold specified by the second preset condition.

[0148] In a possible implementation, the method further includes:

[0149] a miscellaneous item determination subunit, configured to determine, when the satisfaction rate of the data result is not less than the preset threshold and is not equal to 1, that the data result is data to be extracted, and that miscellaneous items that do not satisfy the constraint condition exist in the data to be extracted;

[0150] The data conversion subunit is used to convert the data to be extracted based on the miscellaneous items that do not meet the constraint conditions in the data to be extracted, and use the data to be extracted after the conversion as target data, wherein the data to be extracted after the conversion at least includes: markings for the miscellaneous items and the constraint conditions that the miscellaneous items do not meet.

[0151] In a possible implementation, the method further includes:

[0152] A link generation subunit, configured to generate a data processing link based on the data to be extracted corresponding to the target data type and the document corresponding to the data to be extracted, and the document recognition model for processing the document;

[0153] The link sending subunit is used to send the data processing link to the target user.

[0154] In a possible implementation, the method further includes:

[0155] A first duration prediction unit is configured to predict the duration of performing recognition processing on the document in the document group that has not been recognized, in response to receiving an operation by a target user to determine that the target data is false, to obtain a first duration;

[0156] A second duration prediction subunit is used to predict the duration of manual recognition of the document that has not been recognized, to obtain a second duration;

[0157] A duration determination subunit, configured to determine whether the first duration is not less than the second duration;

[0158] A model processing subunit, configured to perform recognition processing on the document that has not been recognized if the duration judgment subunit determines that the document is negative;

[0159] The manual processing subunit is used to send the document that has not been recognized and processed to the target user and prompt the target user to perform manual recognition if the duration judgment subunit is yes.

[0160] In a possible implementation, the method further includes:

[0161] A document recognition pausing unit is used to suspend the recognition processing of the documents in the document group if the target data corresponding to the target data type is not obtained after the recognition processing of each of the documents in the document group, until the documents in the document group are updated, and execute the step of sequentially recognizing the documents according to the priority level corresponding to each document in the document group.

[0162] In a possible implementation, the document acquisition unit 100 includes:

[0163] A document receiving subunit, used for receiving unstructured data files from different data sources;

[0164] The document format conversion subunit is used to convert the unstructured data file into a document in a preset format.

[0165] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.

[0166] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0167] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A document recognition method, characterized in that: include: Acquire at least one document, wherein the document has a preset association relationship with at least one target data type; Based on the preset association relationship between the documents and the target data type, the documents are grouped to obtain at least one document group, wherein each document in the document group has the preset association relationship with the same target data type; Performing complexity identification processing on each of the documents in the document group to obtain the complexity corresponding to each of the documents in the document group; Determining the priority of each document according to the complexity corresponding to the documents in the document group, wherein the document with lower complexity has higher priority corresponding to it; According to the priority corresponding to each document in the document group, the data to be extracted in each document in the document group is identified in descending order of priority until a target document containing the data to be extracted is identified, and the identification of other documents in the document group is stopped, wherein the data to be extracted is data corresponding to the target data type having the preset association relationship with the document; The data to be extracted is extracted from the target document as target data.

2. The document recognition method according to claim 1, characterized in that: The step of identifying the data to be extracted in each document in the document group in descending order of priority according to the priority corresponding to each document in the document group, until a target document containing the data to be extracted is identified, and then stopping the identification of other documents in the document group, includes: According to the priority level corresponding to each of the documents in the document group, determining the document that needs to be recognized in the current order as the document to be recognized; Calling a document recognition model corresponding to the document type of the document to be recognized, performing recognition processing on the document to be recognized, and obtaining a data result corresponding to the target data type in the document to be recognized, wherein the document recognition model is a model trained in advance using sample documents belonging to the same document type as feature values ​​and the data result corresponding to the sample documents as target values; Determine whether the data result meets the preset conditions; If the data result meets the preset condition, the data result is used as the data to be extracted, and the recognition of other documents in the document group is stopped; If the data result does not meet the preset condition, the step of determining the document that needs to be identified in the current order as the document to be identified based on the priority level corresponding to each document in the document group is executed until the data result corresponding to the target data type in the identified document to be identified meets the preset condition.

3. The document recognition method according to claim 2, characterized in that: Also includes: In the case where there are multiple document groups, and each of the document groups has corresponding data to be extracted, determining the document recognition model corresponding to the data to be extracted of each of the document groups; The target data is generated based on at least two of the document recognition models having a preset model association relationship and the data to be extracted corresponding to the document recognition models.

4. The document recognition method according to claim 2, characterized in that: The determining whether the data result meets a preset condition includes: Acquire a first preset condition corresponding to the target data type, where the first preset condition includes: at least one constraint condition that the target data corresponding to the target data type needs to satisfy; Based on the first preset condition, checking the data result corresponding to the target data type to determine a satisfaction rate of the data result for the first preset condition; It is determined whether the satisfaction rate is not less than a preset threshold specified by a second preset condition.

5. The document recognition method according to claim 4, characterized in that: Also includes: When the satisfaction rate of the data result is not less than the preset threshold and is not equal to 1, it is determined that the data result is data to be extracted, and there are miscellaneous items that do not satisfy the constraint condition in the data to be extracted; Based on the miscellaneous items in the data to be extracted that do not satisfy the constraint conditions, the data to be extracted are transformed, and the data to be extracted obtained after the transformation are used as target data, wherein the data to be extracted obtained after the transformation at least includes: a mark for the miscellaneous items, and the constraint conditions that the miscellaneous items do not satisfy.

6. The document recognition method according to claim 2, characterized in that: Also includes: Generate a data processing link based on the data to be extracted corresponding to the target data type and the document corresponding to the data to be extracted, and the document recognition model for processing the document; The data processing link is sent to the target user.

7. The document recognition method according to claim 1, characterized in that: Also includes: In response to receiving an operation by a target user to determine that the target data is false, predicting a duration for performing recognition processing on documents in the document group that have not been recognized, to obtain a first duration; Predicting the duration of manual recognition of the unrecognized document to obtain a second duration; Determining whether the first duration is not less than the second duration; If the first time length is less than the second time length, performing recognition processing on the document that has not been recognized; If the first time length is not less than the second time length, the unrecognized document is sent to the target user, and the target user is prompted to perform manual recognition.

8. The document recognition method according to any one of claims 1 to 7, characterized in that: Also includes: After each of the documents in the document group is identified and processed, if the target data is not obtained, the identification process of the documents in the document group is suspended until the documents in the document group are updated, and the step of identifying the documents in turn according to the priority level corresponding to each document in the document group is executed.

9. The document recognition method according to any one of claims 1 to 7, characterized in that: The obtaining of at least one document comprises: Receive unstructured data files from different data sources; The unstructured data file is converted into a document in a preset format.

10. A document recognition device, characterized in that: include: A document acquisition unit, used to acquire at least one document, wherein the document has a preset association relationship with at least one target data type; A document grouping unit, configured to group the documents based on the preset association relationship between the documents and the target data type to obtain at least one document group, wherein each document in the document group has the preset association relationship with the same target data type; A complexity identification unit, configured to perform complexity identification processing on each of the documents in the document group to obtain the complexity corresponding to each of the documents in the document group; A priority determination unit, configured to determine the priority of each document according to the complexity corresponding to the document in the document group, wherein the document with lower complexity has higher priority; an identification processing unit, configured to identify the data to be extracted in each of the documents in the document group in descending order of priority according to the priority corresponding to each of the documents in the document group, until a target document containing the data to be extracted is identified, and then stop identifying other documents in the document group, wherein the data to be extracted is data corresponding to the target data type having the preset association relationship with the document; The data extraction unit is used to extract the data to be extracted from the target document as target data.