US11914968B2ActiveUtilityA1

Official document processing method, device, computer equipment and storage medium

37
Assignee: PING AN TECH SHENZHEN CO LTDPriority: Jun 10, 2020Filed: Dec 11, 2020Granted: Feb 27, 2024
Est. expiryJun 10, 2040(~13.9 yrs left)· nominal 20-yr term from priority
G06F 40/40G06F 40/103G06V 30/412G06V 30/418G06V 30/40G06F 40/131G06N 20/00G06V 10/22G06F 18/24G06F 40/232G06F 40/253G06F 40/216G06F 40/284G06F 40/177G06F 18/2415Y02D10/00
37
PatentIndex Score
0
Cited by
2
References
19
Claims

Abstract

The application belongs to the field of big data, and particularly relates to an official document processing method, device, computer equipment and storage medium. The method includes the following steps of: performing format analysis on the to-be-reviewed official document, then acquiring the to-be-reviewed official document of standard file type, and identifying all file components and contents in the to-be-reviewed official document of standard file type; performing text format detection, text content detection and frame layout detection synchronously by a preset text processing model, obtaining a format detection result, a content detection result and a layout detection result; generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content and the standard writing rule in the to-be-reviewed official document.

Claims

exact text as granted — not AI-modified
The invention claimed is: 
     
       1. An official document processing method, comprising:
 receiving a review request containing a to-be-reviewed official document sent by a user, performing format analysis on the to-be-reviewed official document and acquiring file type of the to-be-reviewed official document, then acquiring the to-be-reviewed official document of standard file type, and identifying all file component contents in the to-be-reviewed official document of standard file type by a preset BERT model; 
 performing text format detection, text content detection and frame layout detection synchronously by a preset text processing model constructed based on a distributed framework, obtaining a format detection result, a content detection result and a layout detection result; the text format detection comprises following steps of: calling a format detection rule corresponding to each file component content, extracting a text format keyword in the file component content, and obtaining a format detection result according to the text format keyword and a format bar in the format detection rule corresponding to the text format keyword; the text content detection comprises step of obtaining a content detection result after performing text content detection on the file component content; the frame layout detection comprises following steps of: dividing coordinate information of the to-be-reviewed official document of standard file type, and performing frame layout detection on the to-be-reviewed official document according to the coordinate information that is divided to obtain a layout detection result; and 
 generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user. 
 
     
     
       2. The official document processing method of  claim 1 , wherein the step of generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user comprises:
 inputting the format detection result, content detection result and layout detection result into a preset scoring model for scoring, and acquiring a scoring result of the to-be-reviewed official document output by the preset scoring model; and 
 generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content, the scoring result and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user. 
 
     
     
       3. The official document processing method of  claim 1 , wherein calling a format detection rule corresponding to each file component content comprises:
 determining a document category of the to-be-reviewed official document according to a title of the to-be-reviewed official document; 
 if the document category falls into a preset category, calling a format detection rule corresponding to each file component content by using a rule engine; and 
 if the document category does not fall into the preset category, prompting that the to-be-reviewed official document is not an official document. 
 
     
     
       4. The official document processing method of  claim 1 , wherein after performing format analysis on the to-be-reviewed official document, the method further comprises:
 if there is no file content in the to-be-reviewed official document, prompting the user to upload the to-be-reviewed official document again and rejecting the current review request. 
 
     
     
       5. The official document processing method of  claim 1 , wherein calling a format detection rule corresponding to each file component content, extracting a text format keyword in the file component content, and obtaining a format detection result according to the text format keyword and a format bar in the format detection rule corresponding to the text format keyword comprises:
 calling a format detection rule corresponding to each file component content by using a rule engine; one format detection rule contains at least one data type and a format bar in a combination form of each data type; 
 extracting a text format keyword in the file component content by keyword search technology of the rule engine, and determining whether the text format keyword is consistent with the format bar in the format detection rule corresponding to the text format keyword; one file component content corresponds to at least one text format keyword; 
 if the text format keyword in the file component content is consistent with the format bar in the format detection rule corresponding to the text format keyword, acquiring the format detection result that file format of the file component content is correct; and 
 if the text format keyword in the file component content is inconsistent with the format bar in the format detection rule corresponding to the text format keyword, acquiring the format detection result that file format of the file component content is incorrect. 
 
     
     
       6. The official document processing method of  claim 1 , wherein after acquiring the to-be-reviewed official document of standard file type, the method further comprises:
 when it is detected that there is a table in the to-be-reviewed official document, analyzing the table, and recording each content of the table as the file component content after analysis. 
 
     
     
       7. The official document processing method of  claim 1 , wherein dividing coordinate information of the to-be-reviewed official document of standard file type, and performing frame layout detection on the to-be-reviewed official document according to the coordinate information that is divided comprises:
 converting the to-be-reviewed official document of standard file type into a preset file type to obtain a to-be-reviewed official document of the preset file type; 
 inputting the to-be-reviewed official document of the preset file type into a file block division model associated with a text category of the to-be-reviewed official document by using an OCR algorithm engine, receiving a divided text block output by the file block division model, and extracting coordinate information of the divided text block; the coordinate information represents size and location of the divided text block; 
 performing frame layout detection on the to-be-reviewed official document of standard file type for text format and layout according to the coordinate information. 
 
     
     
       8. A computer equipment, comprising a memory, a processor, and computer readable instructions stored in the memory and executable on the processor, wherein the processor executes the computer readable instructions to implement following steps:
 receiving a review request containing a to-be-reviewed official document sent by a user, performing format analysis on the to-be-reviewed official document and acquiring file type of the to-be-reviewed official document, then acquiring the to-be-reviewed official document of standard file type, and identifying all file component contents in the to-be-reviewed official document of standard file type by a preset BERT model; 
 performing text format detection, text content detection and frame layout detection synchronously by a preset text processing model constructed based on a distributed framework, obtaining a format detection result, a content detection result and a layout detection result; the text format detection comprises following steps of: calling a format detection rule corresponding to each file component content, extracting a text format keyword in the file component content, and obtaining a format detection result according to the text format keyword and a format bar in the format detection rule corresponding to the text format keyword; the text content detection comprises step of obtaining a content detection result after performing text content detection on the file component content; the frame layout detection comprises following steps of: dividing coordinate information of the to-be-reviewed official document of standard file type, and performing frame layout detection on the to-be-reviewed official document according to the coordinate information that is divided to obtain a layout detection result; and 
 generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user. 
 
     
     
       9. The computer equipment of  claim 8 , wherein the step of generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user comprises:
 inputting the format detection result, content detection result and layout detection result into a preset scoring model for scoring, and acquiring a scoring result of the to-be-reviewed official document output by the preset scoring model; and 
 generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content, the scoring result and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user. 
 
     
     
       10. The computer equipment of  claim 8 , wherein calling a format detection rule corresponding to each file component content comprises:
 determining a document category of the to-be-reviewed official document according to a title of the to-be-reviewed official document; 
 if the document category falls into a preset category, calling a format detection rule corresponding to each file component content by using a rule engine; and 
 if the document category does not fall into the preset category, prompting that the to-be-reviewed official document is not an official document. 
 
     
     
       11. The computer equipment of  claim 8 , wherein calling a format detection rule corresponding to each file component content, extracting a text format keyword in the file component content, and obtaining a format detection result according to the text format keyword and a format bar in the format detection rule corresponding to the text format keyword comprises:
 calling a format detection rule corresponding to each file component content by using a rule engine; one format detection rule contains at least one data type and a format bar in a combination form of each data type; 
 extracting a text format keyword in the file component content by keyword search technology of the rule engine, and determining whether the text format keyword is consistent with the format bar in the format detection rule corresponding to the text format keyword; one file component content corresponds to at least one text format keyword; 
 if the text format keyword in the file component content is consistent with the format bar in the format detection rule corresponding to the text format keyword, acquiring the format detection result that file format of the file component content is correct; and 
 if the text format keyword in the file component content is inconsistent with the format bar in the format detection rule corresponding to the text format keyword, acquiring the format detection result that file format of the file component content is incorrect. 
 
     
     
       12. The computer equipment of  claim 8 , wherein after acquiring the to-be-reviewed official document of standard file type, the processor executes the computer readable instructions to further implement following steps:
 when it is detected that there is a table in the to-be-reviewed official document, analyzing the table, and recording each content of the table as the file component content after analysis. 
 
     
     
       13. The computer equipment of  claim 8 , wherein dividing coordinate information of the to-be-reviewed official document of standard file type, and performing frame layout detection on the to-be-reviewed official document according to the coordinate information that is divided comprises:
 converting the to-be-reviewed official document of standard file type into a preset file type to obtain a to-be-reviewed official document of the preset file type; 
 inputting the to-be-reviewed official document of the preset file type into a file block division model associated with a text category of the to-be-reviewed official document by using an OCR algorithm engine, receiving a divided text block output by the file block division model, and extracting coordinate information of the divided text block; the coordinate information represents size and location of the divided text block; 
 performing frame layout detection on the to-be-reviewed official document of standard file type for text format and layout according to the coordinate information. 
 
     
     
       14. One or more readable storage mediums, storing computer readable instructions, wherein the computer readable instructions, when executed by one or more processors, cause the one or more processors to implement following steps:
 receiving a review request containing a to-be-reviewed official document sent by a user, performing format analysis on the to-be-reviewed official document and acquiring file type of the to-be-reviewed official document, then acquiring the to-be-reviewed official document of standard file type, and identifying all file component contents in the to-be-reviewed official document of standard file type by a preset BERT model; 
 performing text format detection, text content detection and frame layout detection synchronously by a preset text processing model constructed based on a distributed framework, obtaining a format detection result, a content detection result and a layout detection result; the text format detection comprises following steps of: calling a format detection rule corresponding to each file component content, extracting a text format keyword in the file component content, and obtaining a format detection result according to the text format keyword and a format bar in the format detection rule corresponding to the text format keyword; the text content detection comprises step of obtaining a content detection result after performing text content detection on the file component content; the frame layout detection comprises following steps of: dividing coordinate information of the to-be-reviewed official document of standard file type, and performing frame layout detection on the to-be-reviewed official document according to the coordinate information that is divided to obtain a layout detection result; and 
 generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user. 
 
     
     
       15. The readable storage medium of  claim 14 , wherein the step of generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user comprises:
 inputting the format detection result, content detection result and layout detection result into a preset scoring model for scoring, and acquiring a scoring result of the to-be-reviewed official document output by the preset scoring model; and 
 generating a detected error content according to the format detection result, content detection result and layout detection result, calling out a standard writing rule corresponding to the detected error content, marking the detected error content, the scoring result and the standard writing rule at a preset position in the to-be-reviewed official document, and sending the to-be-reviewed official document that is successfully marked to a preset receiving location according to a storage path designated by the user. 
 
     
     
       16. The readable storage medium of  claim 14 , wherein calling a format detection rule corresponding to each file component content comprises:
 determining a document category of the to-be-reviewed official document according to a title of the to-be-reviewed official document; 
 if the document category falls into a preset category, calling a format detection rule corresponding to each file component content by using a rule engine; and 
 if the document category does not fall into the preset category, prompting that the to-be-reviewed official document is not an official document. 
 
     
     
       17. The readable storage medium of  claim 14 , wherein calling a format detection rule corresponding to each file component content, extracting a text format keyword in the file component content, and obtaining a format detection result according to the text format keyword and a format bar in the format detection rule corresponding to the text format keyword comprises:
 calling a format detection rule corresponding to each file component content by using a rule engine; one format detection rule contains at least one data type and a format bar in a combination form of each data type; 
 extracting a text format keyword in the file component content by keyword search technology of the rule engine, and determining whether the text format keyword is consistent with the format bar in the format detection rule corresponding to the text format keyword; one file component content corresponds to at least one text format keyword; 
 if the text format keyword in the file component content is consistent with the format bar in the format detection rule corresponding to the text format keyword, acquiring the format detection result that file format of the file component content is correct; and 
 if the text format keyword in the file component content is inconsistent with the format bar in the format detection rule corresponding to the text format keyword, acquiring the format detection result that file format of the file component content is incorrect. 
 
     
     
       18. The readable storage medium of  claim 14 , wherein after acquiring the to-be-reviewed official document of standard file type, the computer readable instructions, when executed by one or more processors, cause the one or more processors to further implement following steps:
 when it is detected that there is a table in the to-be-reviewed official document, analyzing the table, and recording each content of the table as the file component content after analysis. 
 
     
     
       19. The readable storage medium of  claim 14 , wherein dividing coordinate information of the to-be-reviewed official document of standard file type, and performing frame layout detection on the to-be-reviewed official document according to the coordinate information that is divided comprises:
 converting the to-be-reviewed official document of standard file type into a preset file type to obtain a to-be-reviewed official document of the preset file type; 
 inputting the to-be-reviewed official document of the preset file type into a file block division model associated with a text category of the to-be-reviewed official document by using an OCR algorithm engine, receiving a divided text block output by the file block division model, and extracting coordinate information of the divided text block; the coordinate information represents size and location of the divided text block; 
 performing frame layout detection on the to-be-reviewed official document of standard file type for text format and layout according to the coordinate information.

Cited by (0)

No later patents cite this yet.

References (0)

No backward citations on record.