A method, system and device for intelligent review of drilling engineering documents
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-15
- Publication Date
- 2026-08-11
AI Technical Summary
[0004]然而,基于样式标记的OOXML解析工具仅依赖预设的Word标题样式进行识别,而钻井文档普遍大量使用“第X章”“附表X”等中文自然语言作为章节标记,且未配置统一的标题样式,导致工具无法准确识别章节边界,后续内容定位与信息抽取的精度严重不足
本申请先获取待校审文档,基于预设解析规则构建包含多节点、各节点对应层级归属与置信度的初版文档语义树,其中预设解析规则可以同时兼容Word样式标记与“第X章”“附表X”等中文自然语言章节特征,通过规则化快速解析完成绝大多数章节的层级划分,同步输出各节点的识别置信度,既覆盖了现有技术无法识别的自然语言标记场景,还加快了规则解析速度;之后,利用预设语义处理模型,仅针对置信度低于第一预设阈值的节点进行层级归属修正,修正后得到结构精准的目标文档语义树,这种通过置信度阈值实现大模型的定向调用,仅对规则解析难以准确判定的模糊节点调用大模型的语义理解能力进行精准纠偏,既借助大模型的语义能力彻底解决了非规范章节标记识别不准的问题,又避免了全文档无差别调用大模型导致的成本过高、延迟过大的弊端;随后,通过预设校审规则对结构准确的目标文档语义树进行全量校审,输出最终校审结果,能够依据划分的章节层级与节点边界,将校审规则精准匹配到对应章节的内容范围,解决了现有技术因章节定位偏差导致的校审规则匹配错误、抽取精度不足的问题,大幅提升钻井工程文档校审的准确性与可靠性。整个方案各技术特征深度协同,在有效解决钻井工程文档格式多样、章节标记不规范导致的解析精度不足问题的同时,将大模型调用量控制在最低水平,兼顾了解析精度、处理效率与运行成本,能够高效支撑海量历史钻井工程文档的批量结构化解析与智能校审工作。
Smart Images

Figure CN122549448A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of document review technology, and in particular to a method, system and apparatus for intelligent review of drilling engineering documents. Background Technology
[0002] With the ongoing digital transformation of the oil and gas exploration and development industry, the structured parsing and information extraction of drilling engineering documents have become a crucial preliminary step in oil and gas field data asset governance, engineering quality review, and compliance auditing. The entire drilling operation cycle generates a massive amount of technical documents, including comprehensive logging reports, cuttings description records, casing running records, and engineering anomaly reports. These documents comprehensively record engineering information such as formation parameters, construction progress, equipment status, and anomaly handling, serving as vital data assets to support subsequent exploration and development decisions.
[0003] In existing technologies, style parsing tools based on the OOXML standard are typically used to identify chapters and extract content from Word documents used in drilling engineering. Specifically, OOXML parsing tools, such as Python-docx, identify heading and body styles by reading the built-in style tags in the Word document, then split the document into chapters according to the styles and locate the corresponding content. This approach is currently the mainstream implementation method for batch document parsing.
[0004] However, style-based OOXML parsing tools rely solely on preset Word heading styles for identification. Drilling documents commonly use Chinese natural language such as "Chapter X" and "Appendix X" as chapter markers and lack a unified heading style, causing the tool to fail to accurately identify chapter boundaries, resulting in severely insufficient accuracy in subsequent content location and information extraction. Summary of the Invention
[0005] To address the aforementioned technical problems, this application provides a method, system, and apparatus for intelligent review and verification of drilling engineering documents.
[0006] The technical solution provided in this application is described below:
[0007] The first aspect of this application provides a method for intelligent review and verification of drilling engineering documents, the method comprising: Obtain the document to be reviewed and construct an initial document semantic tree based on the preset parsing rules and the document to be reviewed. The initial document semantic tree includes multiple nodes and the hierarchical affiliation and confidence level of each node. The hierarchical affiliation and the confidence level are output after the document to be reviewed is parsed by the preset parsing rules. The hierarchical affiliation of nodes with confidence scores below a first preset threshold is corrected using a preset semantic processing model, and the corrected result is the semantic tree of the target document. The semantic tree of the target document is reviewed by a preset review rule, and the review result is output after review. The preset review rule includes data source definition rule, data location rule, data extraction rule and comparison rule. The step of reviewing the semantic tree of the target document using preset review rules and outputting the review results includes: The target data source is determined from the target document semantic tree according to the data source definition rules; Locate the target data item from the target data source according to the data location rules; The target data items are formatted according to the data extraction rules to obtain standardized data; The standardized data is reviewed and verified based on the comparison rules, and the review and verification results are output.
[0008] Optionally, the data location rules include table row and column location, regular expression location, and model semantic location, wherein the table row and column location, the regular expression location, and the model semantic location are executed in a chain according to a preset priority, and the first valid execution result returned after execution is taken as the target data item.
[0009] Optionally, locating the target data item from the target data source according to the data location rule includes: When performing the table row and column positioning, the target cell is located in the target data source by using preset row header keywords and preset column header keywords, and the text in the target cell is used as the target data item; When the regular expression is executed for location, the target text in the target data source is matched using the regular expression, and the matched target text is used as the target data item. When performing the model semantic localization, all text in the target data source is input into the preset semantic processing model. The target text is located from all the text through the preset semantic processing model and the target text is used as the target data item.
[0010] Optionally, the standardized data includes an identifier field, a measurement value field, and a natural language description field, and the comparison rules include an equal value comparison method, a numerical range comparison method, and a semantic approximation comparison method; The process of reviewing and verifying the standardized data based on the comparison rules, and outputting the review results, includes: When the standardized data belongs to the data of the identification field, the standardized data is compared with the preset identification reference value using the equivalent comparison method to check the identification consistency, and the check result is output. When the standardized data belongs to the data in the measured value field, the standardized data is compared with the preset reference tolerance range using the numerical range comparison method, and the comparison result is output. When the standardized data belongs to the data in the natural language description field, the data belonging to the natural language description field and the preset semantic reference value are input into the preset semantic processing model for semantic consistency verification using the semantic approximation comparison method, and the verification result is output.
[0011] Optionally, in the process of determining the target data source from the target document semantic tree according to the data source definition rules, the method further includes: Obtain auxiliary file tags from the preset review rules, and check whether the data source definition rules involve auxiliary files through the auxiliary file tags. The auxiliary file is an external document referenced by the auxiliary file tags in the preset review rules and used for cross-document comparison with the document to be reviewed. If so, multi-level matching is performed based on the auxiliary file tags and the filenames in the preset external filename set to establish a mapping relationship between the auxiliary file tags and the external documents corresponding to the matched filenames; An external document semantic tree is constructed for the external documents for which the mapping relationship is established, and the preset review rules are updated based on the external document semantic tree.
[0012] Optionally, in the process of reviewing the semantic tree of the target document using the preset review rules, the method further includes: After each rule in the preset review rules is executed, and before the next rule begins, check whether a task cancellation signal has been received. If so, the review process will be terminated.
[0013] Optionally, the step of constructing a preliminary document semantic tree based on preset parsing rules and the document to be reviewed includes: The document to be reviewed is parsed based on preset parsing rules to obtain a set of candidate chapters; Extract the first group of chapters marked with title styles from the candidate chapter set, and determine the uncovered document areas in the document to be reviewed based on the first group of chapters; The uncovered document area is re-identified using a preset chapter pattern set, and the identified natural language chapters are marked as the second group of chapters; Construct an initial document semantic tree based on the first group of chapters and the second group of chapters.
[0014] A second aspect of this application provides a system for intelligent review and verification of drilling engineering documents, the system comprising: A construction unit is used to obtain the document to be reviewed and construct an initial document semantic tree based on the preset parsing rules and the document to be reviewed. The initial document semantic tree includes multiple nodes and the hierarchical affiliation and confidence level of each node. The hierarchical affiliation and the confidence level are output by the preset parsing rules after parsing the document to be reviewed. The correction unit is used to correct the hierarchical affiliation of the nodes whose confidence level is lower than the first preset threshold using a preset semantic processing model, and obtain the target document semantic tree after correction. The review unit is used to review the semantic tree of the target document according to preset review rules, and output the review results after review. The preset review rules include data source definition rules, data location rules, data extraction rules, and comparison rules.
[0015] The review unit is specifically used for: The target data source is determined from the target document semantic tree according to the data source definition rules; Locate the target data item from the target data source according to the data location rules; The target data items are formatted according to the data extraction rules to obtain standardized data; The standardized data is reviewed and verified based on the comparison rules, and the review and verification results are output.
[0016] Optionally, the data location rules include table row and column location, regular expression location, and model semantic location, wherein the table row and column location, the regular expression location, and the model semantic location are executed in a chain according to a preset priority, and the first valid execution result returned after execution is taken as the target data item.
[0017] Optionally, the review unit is specifically used for: When performing the table row and column positioning, the target cell is located in the target data source by using preset row header keywords and preset column header keywords, and the text in the target cell is used as the target data item; When the regular expression is executed for location, the target text in the target data source is matched using the regular expression, and the matched target text is used as the target data item. When performing the model semantic localization, all text in the target data source is input into the preset semantic processing model. The target text is located from all the text through the preset semantic processing model and the target text is used as the target data item.
[0018] Optionally, the standardized data includes an identifier field, a measurement value field, and a natural language description field, and the comparison rules include an equal value comparison method, a numerical range comparison method, and a semantic approximation comparison method; The process of reviewing and verifying the standardized data based on the comparison rules, and outputting the review results, includes: When the standardized data belongs to the data of the identification field, the standardized data is compared with the preset identification reference value using the equivalent comparison method to check the identification consistency, and the check result is output. When the standardized data belongs to the data in the measured value field, the standardized data is compared with the preset reference tolerance range using the numerical range comparison method, and the comparison result is output. When the standardized data belongs to the data in the natural language description field, the data belonging to the natural language description field and the preset semantic reference value are input into the preset semantic processing model for semantic consistency verification using the semantic approximation comparison method, and the verification result is output.
[0019] Optionally, a first inspection unit may also be included, specifically for: Obtain auxiliary file tags from the preset review rules, and check whether the data source definition rules involve auxiliary files through the auxiliary file tags. The auxiliary file is an external document referenced by the auxiliary file tags in the preset review rules and used for cross-document comparison with the document to be reviewed. If so, multi-level matching is performed based on the auxiliary file tags and the filenames in the preset external filename set to establish a mapping relationship between the auxiliary file tags and the external documents corresponding to the matched filenames; An external document semantic tree is constructed for the external documents for which the mapping relationship is established, and the preset review rules are updated based on the external document semantic tree.
[0020] Optionally, a second checking unit may also be included, for: After each rule in the preset review rules is executed, and before the next rule begins, check whether a task cancellation signal has been received. If so, the review process will be terminated.
[0021] Optionally, the building unit is specifically used for: The document to be reviewed is parsed based on preset parsing rules to obtain a set of candidate chapters; Extract the first group of chapters marked with title styles from the candidate chapter set, and determine the uncovered document areas in the document to be reviewed based on the first group of chapters; The uncovered document area is re-identified using a preset chapter pattern set, and the identified natural language chapters are marked as the second group of chapters; Construct an initial document semantic tree based on the first group of chapters and the second group of chapters.
[0022] A third aspect of this application provides an apparatus for intelligent proofreading of drilling engineering documents, the apparatus comprising: Processor, memory, input / output units, and bus; The processor is connected to the memory, the input / output unit, and the bus; The memory stores a program, which the processor calls to execute the first aspect and any optional method of the first aspect for intelligent review of drilling engineering documents.
[0023] The fourth aspect of this application provides a computer-readable storage medium on which a program is stored, which, when executed on a computer, performs the method of intelligent review of drilling engineering documents as described in the first aspect and any optional method of the first aspect.
[0024] As can be seen from the above technical solutions, this application has the following advantages: This application first obtains the document to be reviewed and constructs an initial semantic tree based on preset parsing rules. This initial semantic tree includes multiple nodes, the hierarchical affiliation of each node, and their confidence scores. The preset parsing rules are compatible with both Word style tags and Chinese natural language chapter features such as "Chapter X" and "Appendix X." Through rule-based parsing, the hierarchical division of most chapters is completed quickly, and the recognition confidence scores of each node are output simultaneously. This not only covers natural language tagging scenarios that existing technologies cannot recognize but also accelerates the rule parsing speed. Then, using a preset semantic processing model, hierarchical affiliation correction is performed only on nodes with confidence scores below a first preset threshold. After correction, a structurally accurate target document semantic tree is obtained. This method of achieving a large model through a confidence threshold demonstrates its effectiveness. The targeted invocation of the large model precisely corrects ambiguities by leveraging its semantic understanding capabilities only for nodes where rule parsing struggles to accurately determine their meaning. This approach not only completely resolves the issue of inaccurate identification of non-standard chapter markers by utilizing the large model's semantic capabilities but also avoids the excessive costs and latency associated with indiscriminate invocation of the large model across the entire document. Subsequently, a full review of the structurally accurate semantic tree of the target document is conducted using pre-defined review rules, outputting the final review results. Based on the defined chapter levels and node boundaries, the review rules are precisely matched to the content range of the corresponding chapters, resolving the issues of incorrect rule matching and insufficient extraction accuracy caused by chapter positioning deviations in existing technologies. This significantly improves the accuracy and reliability of drilling engineering document review. The entire solution features deep synergy among its various technical features, effectively addressing the problem of insufficient parsing accuracy caused by diverse drilling engineering document formats and non-standard chapter markers while minimizing the amount of large model calls. It balances parsing accuracy, processing efficiency, and operating costs, efficiently supporting the batch structured parsing and intelligent review of massive amounts of historical drilling engineering documents. Attached Figure Description
[0025] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0026] Figure 1 A schematic flowchart of an embodiment of the intelligent review and verification method for drilling engineering documents provided in this application; Figure 2 A flowchart illustrating an implementation of step S101 in the intelligent review method for drilling engineering documents provided in this application; Figure 3 A flowchart illustrating an implementation of step S103 in the intelligent review and verification method for drilling engineering documents provided in this application; Figure 4A flowchart illustrating an embodiment of the method for intelligent review of drilling engineering documents provided in this application, which checks the data source definition rules. Figure 5 A flowchart illustrating an implementation of step S1032 in the intelligent review method for drilling engineering documents provided in this application; Figure 6 A flowchart illustrating an implementation of step S1034 in the intelligent review method for drilling engineering documents provided in this application; Figure 7 A schematic diagram of an embodiment of the intelligent proofreading system for drilling engineering documents provided in this application; Figure 8 A schematic diagram of an embodiment of the intelligent proofreading device for drilling engineering documents provided in this application. Detailed Implementation
[0027] This application provides a method for intelligent review and verification of drilling engineering documents, which can improve the accuracy of review and verification. It should be noted that the intelligent review and verification method for drilling engineering documents in this application is applied to a terminal.
[0028] It should be noted that the method, system, and apparatus for intelligent review of drilling engineering documents provided in this application can be applied to terminals, systems, and servers. For example, a terminal can be a smartphone, computer, tablet, smart TV, smartwatch, portable computer, or a desktop computer, etc. For ease of explanation, this application uses a terminal as the executing subject for illustration.
[0029] Please see Figure 1 This application first provides an embodiment of a method for intelligent review and verification of drilling engineering documents, which includes: S101. Obtain the document to be reviewed and construct a preliminary document semantic tree based on the preset parsing rules and the document to be reviewed. The preliminary document semantic tree includes multiple nodes and the hierarchical affiliation and confidence level of each node. The hierarchical affiliation and confidence level are output by the preset parsing rules after parsing the document to be reviewed. In this embodiment, the document to be reviewed needs to be acquired first. This document is the drilling engineering document to be reviewed, covering different types of professional documents such as logging reports, casing records, and cuttings descriptions. Then, a preset parsing rule is loaded. This preset parsing rule is compatible with Word's built-in heading style tags and Chinese natural language chapter features such as "Chapter X", "Section 1", "Appendix X", and "Figure X". The entire document to be reviewed is then scanned segment by segment, and each segment is matched with the preset parsing rule to identify chapter titles and content boundaries, and determine the hierarchical affiliation of each chapter node.
[0030] Furthermore, based on the degree of matching, a corresponding confidence score is output for each node. Generally, nodes that perfectly match standard heading styles or standardized chapter formats have higher confidence scores, while nodes with non-standard formats or ambiguous chapter characteristics have lower confidence scores. Then, all nodes are organized according to hierarchical relationships to generate an initial version of the document semantic tree with confidence score labels.
[0031] See Figure 2 The following is a specific implementation method for step S101, which includes: S1011. Based on preset parsing rules, parse the document to be reviewed to obtain a set of candidate chapters; Because drilling engineering documents come from diverse sources and have varying levels of formatting standards, with some documents using standard formatting styles and others simply using plain text numbering to mark chapters, a single parsing rule cannot achieve comprehensive coverage. Therefore, the preset parsing rule in this embodiment is a two-dimensional parsing rule. One dimension is the Word built-in heading style mapping rule, covering six levels of standard heading styles from Heading1 to Heading6. The other dimension is the Chinese chapter pattern set, covering typical expression formats of Chinese natural language chapters.
[0032] Specifically, the document to be reviewed is scanned segment by segment, the style attributes and text content of each paragraph are extracted, and they are matched with the preset parsing rules of the two dimensions respectively to initially identify all candidate chapters. These candidate chapters are then combined into a candidate chapter set, and the matching source and matching degree of each candidate chapter are recorded.
[0033] S1012. Extract the first group of chapters marked by the title style from the candidate chapter set, and determine the uncovered document area in the document to be reviewed based on the first group of chapters; From the candidate chapter set obtained after parsing, chapters that match the Word heading style are selected as the first group of chapters. These chapters are marked with standard heading styles, and have the highest recognition accuracy and confidence.
[0034] Next, using the start and end positions of the first group of chapters in the document to be reviewed as boundaries, blank text segments in the document to be reviewed that are not covered by any title style chapters are divided. These blank text segments are called uncovered document areas. Uncovered document areas include chapters, appendices, figures, etc. that are not marked with title styles and are only marked by plain text numbers.
[0035] S1013. Use the preset chapter pattern set to perform secondary recognition on the uncovered document area, and mark the recognized natural language chapters as the second group of chapters; In this embodiment, since most chapters in the uncovered document area do not have standard style attributes and only rely on plain text numbering to mark the hierarchy, a preset chapter pattern set is used to match these natural language tags to fill the coverage blind spots of style parsing. For example, content without style tags such as "Appendix 3 Casing Parameter Data Table" and "2.1.4 Drilling Fluid Performance Indicators" in the uncovered document area can be identified as the second group of chapters through regular expression matching of the preset chapter pattern set. The preset chapter pattern set includes various natural language chapter formats commonly found in drilling documents, such as "Chapter X", "Section X", "Appendix X", "Appendix X", and multi-level numbering.
[0036] Specifically, the process first scans the defined uncovered document areas segment by segment, matches each segment of text in the uncovered document areas with the regular expression rules in the preset chapter pattern set, identifies the successfully matched natural language chapters as the second group of chapters, and preliminarily determines the level of each node based on the number of levels of the chapter number, and assigns a confidence level to each chapter based on the completeness of the match.
[0037] S1014. Construct the initial document semantic tree based on the first group of chapters and the second group of chapters.
[0038] In this embodiment, the first group of chapters is used as the main component. Based on the heading style levels, nodes are divided into levels one to six to build the basic hierarchical framework of the initial document semantic tree. Then, the second group of chapters is inserted into the hierarchical branches of this basic framework to complete the missing nodes. Simultaneously, the corresponding confidence level is labeled for each node.
[0039] Generally, the confidence level of nodes corresponding to the first group of chapters will be higher than that of nodes corresponding to the second group of chapters. Additionally, after constructing the initial document semantic tree, duplicate chapter entries in the table of contents of the initial document semantic tree can be identified and removed, and the hierarchical relationships of all nodes can be reorganized.
[0040] S102. Using a preset semantic processing model, the hierarchical affiliation of nodes with confidence scores lower than the first preset threshold is corrected, and the target document semantic tree is obtained after correction. After the initial document semantic tree is constructed, all nodes in the initial document semantic tree will be traversed, and nodes with confidence scores lower than the first preset threshold will be selected. The text content, context, and hierarchical information of the surrounding nodes of these nodes will be input into the preset semantic processing model. The preset semantic processing model is a large language model adapted to the drilling professional field. The first preset threshold can be set to 0.6 to 0.8, depending on the actual needs.
[0041] Specifically, the preset semantic processing model, combined with the writing logic and professional standards of drilling engineering documents, re-determines the correct hierarchical classification of nodes with confidence levels below the first preset threshold, corrects problems such as misjudgment of hierarchy and incorrect classification in the preset parsing rules, and then re-integrates the corrected nodes with the original nodes with confidence levels not lower than the first preset threshold, and re-sorts the hierarchical classification to obtain the semantic tree of the target document.
[0042] In addition, before obtaining the target document semantic tree, misjudged entries corresponding to the document's table of contents can be removed. This is to avoid chapter titles in the table of contents being repeatedly identified as main text sections, ensuring that the target document semantic tree only corresponds to the true chapter structure of the main text, and eliminating the interference of the table of contents content on the hierarchical division. After obtaining the target document semantic tree, the constructed target document semantic tree can be cached based on the file hash value. The target document semantic tree is associated with the file's unique hash identifier and stored locally, so that the parsing and correction process does not need to be repeated when the same file is reviewed multiple times. This can effectively reduce the overhead of repeated calculations and greatly improve the processing efficiency of repeated review scenarios.
[0043] S103. Review the semantic tree of the target document using preset review rules, and output the review results after review. The preset review rules include data source definition rules, data location rules, data extraction rules, and comparison rules.
[0044] In this embodiment, the preset verification rules cover multiple types of verification rules, including data source definition rules, data location rules, data extraction rules, and comparison rules. Each rule is marked with its corresponding applicable chapter scope.
[0045] Specifically, the process involves first traversing the target document's semantic tree, and then matching the corresponding nodes within the semantic tree based on the data source definition rules, data location rules, data extraction rules, and the applicable scope of the comparison rules. Rule validation is then performed within the content boundaries of each node. After all rule validations are completed, all issues are summarized, and the node location, issue type, and suggested modifications for each issue are marked. Finally, a structured review result is output.
[0046] This embodiment first acquires the document to be reviewed and constructs an initial semantic tree based on preset parsing rules. This initial tree includes multiple nodes, their corresponding hierarchical affiliations, and confidence scores. The preset parsing rules are compatible with both Word style tags and Chinese natural language chapter features such as "Chapter X" and "Appendix X." Through rule-based parsing, the hierarchical division of most chapters is quickly completed, and the recognition confidence scores of each node are output simultaneously. This not only covers natural language tagging scenarios that existing technologies cannot recognize but also accelerates rule parsing speed. Then, using a preset semantic processing model, hierarchical affiliation correction is performed only on nodes with confidence scores below a first preset threshold. After correction, a structurally accurate target document semantic tree is obtained. This method of achieving a large model through a confidence threshold demonstrates its effectiveness. The targeted invocation of the large model precisely corrects ambiguities by leveraging its semantic understanding capabilities only for nodes where rule parsing struggles to accurately determine their meaning. This approach not only completely resolves the issue of inaccurate identification of non-standard chapter markers by utilizing the large model's semantic capabilities but also avoids the excessive costs and latency associated with indiscriminate invocation of the large model across the entire document. Subsequently, a full review of the structurally accurate semantic tree of the target document is conducted using pre-defined review rules, outputting the final review results. Based on the defined chapter levels and node boundaries, the review rules are precisely matched to the content range of the corresponding chapters, resolving the issues of incorrect rule matching and insufficient extraction accuracy caused by chapter positioning deviations in existing technologies. This significantly improves the accuracy and reliability of drilling engineering document review. The entire solution features deep synergy among its various technical features, effectively addressing the problem of insufficient parsing accuracy caused by diverse drilling engineering document formats and non-standard chapter markers while minimizing the amount of large model calls. It balances parsing accuracy, processing efficiency, and operating costs, efficiently supporting the batch structured parsing and intelligent review of massive amounts of historical drilling engineering documents.
[0047] In an optional embodiment, during the process of reviewing the semantic tree of the target document using preset review rules, after each rule in the preset review rules is executed and before the next rule begins, it is checked whether a task cancellation signal has been received; if so, the review process is terminated.
[0048] In this embodiment, a rule-level interruption check mechanism is introduced during the execution of each review rule. This interruption check mechanism is implemented through the terminal's built-in AI engine. Specifically, the AI engine executes each verification item in the preset review rules in order of priority. After completing the review of a single rule and recording the corresponding review result, during the rule switching interval before officially starting the next rule, it actively queries the status flag of the current task in the intermediate task table to check whether it has been marked as deleted by the business side, i.e., whether a task cancellation signal has been received.
[0049] If a task cancellation signal is detected, the execution of all subsequent verification rules will be terminated immediately, all computing resources occupied by the current task will be released, and the task status will be updated to terminated. If no cancellation signal is detected, the next verification rule will continue to be loaded and executed until all rules are executed. For example, if a logging report verification task containing 20 verification rules is executed and the user cancels when the 5th rule is executed, the process will terminate after the verification of the 5th rule is completed, and the remaining 15 rules do not need to be executed.
[0050] The review and verification of drilling engineering documents typically involves dozens of different types of verification rules, and the overall execution time is relatively long. Traditional task-level cancellation mechanisms require waiting for the entire task to be completed before responding to the cancellation command, which generates a lot of invalid calculations and wastes computing resources. By pushing the checkpoints down to the switching intervals of each rule, more granular interrupt control is achieved. The execution time of a single rule is usually tens of seconds to several minutes, which is much shorter than the total time of the entire task. This can significantly reduce the response delay of cancellation operations and avoid meaningless subsequent rule executions.
[0051] See Figure 3 The following is a specific implementation method for step S103, which includes: S1031. Determine the target data source from the target document semantic tree according to the data source definition rules; The data source definition rules clearly indicate the name, source type, and location assistance information for each data source. Source types cover three categories: main document tables, main document text paragraphs, and external auxiliary files. Therefore, this embodiment searches and matches within the target document's semantic tree according to the data source definition rules to pinpoint the data range of the corresponding target data source within the semantic tree. This approach achieves precise definition of the review data range, avoiding the inefficiencies and location errors associated with full-text search, and effectively improving the targeting and efficiency of subsequent data processing.
[0052] During step S1031, the data source definition rules also need to be checked. Please refer to [link / reference]. Figure 4 , Figure 4 An embodiment of the method for intelligent review of drilling engineering documents provided in this application, which includes checking the data source definition rules, includes: S401. Obtain auxiliary file tags from the preset review rules, and check whether the data source definition rules involve auxiliary files through the auxiliary file tags. The auxiliary file is an external document referenced by the auxiliary file tags in the preset review rules and used for cross-document comparison with the document to be reviewed. In this embodiment, it is necessary to first read the preset review rules to be executed, parse the data source definition rule part in the preset review rules, extract the corresponding auxiliary file tags, and verify them one by one. If the auxiliary file tag indicates that there is a data source of type external auxiliary file, then step S402 is executed; if the auxiliary file tag indicates that there is no data source of type external auxiliary file, then it means that no auxiliary file is involved, and step S1031 can be executed directly.
[0053] Furthermore, auxiliary documents are external documents referenced by pre-defined review rules through tags, such as cuttings description records, casing records, and after-effect gas detection records. Their purpose is to conduct cross-document data consistency comparisons with the documents to be reviewed. Pre-defined review rules are divided into two scenarios: internal checks of the main document and cross-document comparisons between the main and auxiliary documents. By distinguishing between these two scenarios in advance through pre-checks, rules that do not involve auxiliary documents can be skipped directly, avoiding invalid document matching and semantic tree construction operations. This enables on-demand routing of the review process and improves overall execution efficiency.
[0054] S402. Perform multi-level matching based on auxiliary file tags and filenames in a preset set of external filenames to establish a mapping relationship between auxiliary file tags and external documents corresponding to the matched filenames; When the data source definition rules involve auxiliary files, the auxiliary file tags are compared with the keyword inclusion of all filenames in the preset external filename set. If a filename contains the core keyword of the auxiliary file tag, the match is considered successful; if all matches fail, a second-level sequence similarity matching is performed, calculating the sequence similarity value between the auxiliary file tag and each filename. If the similarity value exceeds the similarity threshold, the match is considered successful; if the first two levels of matching fail, a third-level semantic matching is performed, calling a preset semantic processing model to determine the semantic relevance between the auxiliary file tag and the filename.
[0055] The matching process employs a chained execution logic. The first successful match becomes the final mapping relationship, and subsequent levels of matching are not executed. This approach is because the naming of auxiliary files in drilling projects typically follows strong patterns. The vast majority of files can be matched using keywords or fuzzy matching, with only a few non-standard files requiring model assistance. By progressively degrading the matching process from simple to complex, the number of model calls can be minimized while ensuring a high matching success rate, thus balancing matching efficiency and operating costs.
[0056] S403. Construct an external document semantic tree for the external documents with established mapping relationships, and update the preset review rules based on the external document semantic tree.
[0057] After successfully establishing the mapping relationship between auxiliary file tags and external documents, a semantic tree is constructed for each matched external document. Specifically, a hybrid strategy of style mapping, Chinese chapter regular expression matching, and semantic correction of low-confidence nodes is used to parse the chapter hierarchy and table structure of the external document, thereby generating a structured semantic tree for the external document.
[0058] After the system is built, the data source configuration of the preset review rules is updated based on the mapping relationship. The auxiliary file tags in the preset review rules are replaced with the corresponding external document semantic tree references, and the external document semantic tree is included in the unified query scope, so that the subsequent data location, extraction and comparison processes can be directly executed on the external document semantic tree.
[0059] S1032. Locate the target data item from the target data source according to the data location rules; Since drilling documents contain data in various formats such as structured tables and semi-structured text, a single strategy cannot cover all positioning scenarios. Therefore, this embodiment uses a multi-positioning strategy specified in the data positioning rules to locate target data items in the locked target data source, which can ensure the positioning efficiency of the vast majority of standardized data.
[0060] See Figure 5 The following provides a specific implementation method for step S1032. In this implementation method, the data location rules include table row and column location, regular expression location, and model semantic location. These methods are executed in a chain according to a preset priority. After execution, the first valid execution result returned is taken as the target data item. This implementation method includes: S10321. When performing table row and column positioning, the target cell is located in the target data source by using preset row header keywords and preset column header keywords, and the text in the target cell is used as the target data item. When the data location rule performs table row and column location, it first iterates through all embedded tables within the chapter range corresponding to the target data source, matching the preset row header keywords with the row headings in the table one by one to locate the row position of the target data. Then, it matches the preset column header keywords with the column headings in the table one by one to locate the column position of the target data. The cell where the row position and column position intersect is the target cell. After determining the target cell, the text content within the target cell is used as the target data item.
[0061] Furthermore, during the matching process, if a match is successful, the result is returned directly; if no valid target cell is found, it indicates that the table location has failed, and the process proceeds to the next level of the data location rules.
[0062] S10322. When performing regular expression positioning, the target text in the target data source is matched by regular expression, and the matched target text is used as the target data item. In drilling engineering documents, some parameters are scattered throughout the main text paragraphs and do not have a regular table structure, but they have a relatively fixed expression pattern, such as "Design well depth: XXXXm" and "Surface elevation: XXXm". Therefore, this embodiment can also perform regular expression positioning, which can efficiently match this kind of regular text data.
[0063] Specifically, when the data location rule is to use regular expressions, the regular expression corresponding to the preset verification rule is loaded. Different types of parameters correspond to different matching rules for the regular expression. Then, the system scans each paragraph in all text sections of the target data source, matches the target text that conforms to the regular expression, and extracts the matched target text as the target data item.
[0064] S10323. When performing semantic localization of the model, all text in the target data source is input into the preset semantic processing model. The target text is located from all texts through the preset semantic processing model and the target text is used as the target data item.
[0065] When the data location rule is to perform semantic location of the model, all text within the target data source range is sliced into paragraphs and input into a preset semantic processing model adapted to the drilling professional field along with natural language instructions describing the location requirements. The preset semantic processing model will combine drilling professional knowledge and contextual information to identify the target content that meets the requirements from the text, extract the corresponding target text as the target data item and return it.
[0066] This approach is necessary because drilling engineering documents contain a large amount of specialized descriptive content, such as lithological descriptions, engineering anomaly analyses, and construction measures descriptions. This type of content lacks a regular table structure and a fixed expression pattern, and deterministic rules cannot cover it. Therefore, it is necessary to achieve accurate positioning through the semantic understanding capabilities of a pre-set semantic processing model.
[0067] S1033. Format the target data items according to the data extraction rules to obtain standardized data; In this embodiment, formatting processing is performed on the located target data items according to the data extraction rules. The processing logic includes value mapping processing, unit normalization processing, and numerical precision alignment processing. Among them, value mapping processing converts the numerical values expressed in natural language in the target data items into the standard format through a pre-set value mapping table. For example, it converts the numerical values expressed in Chinese capital numbers into Arabic numerals. Unit normalization processing performs unified conversion on physical quantity units such as depth, pressure, temperature, etc., to eliminate different unit differences. Numerical precision alignment processing corrects the differences in precision habits of different writers. Finally, after the formatting processing of these three logics, standardized data with a unified format is output. For example, the same target data item in different documents is respectively expressed as "one thousand two hundred meters", "1200m", and "1.2km", and after standardization processing, it is unified into the numerical value 1200.0 meters, eliminating the expression differences.
[0068] S1034. Perform auditing on the standardized data based on the comparison rules, and output the auditing result after auditing.
[0069] There are essential differences in the consistency requirements for different types of data in drilling engineering. The identification fields must be exactly the same, reasonable errors are allowed for engineering measurement values, and the correctness of professional descriptions cannot be judged only by literal matching. Therefore, the differential comparison strategy adopted in this embodiment can meet the auditing requirements of different data, avoiding a large number of misjudgments caused by overly strict requirements for measurement values, and preventing missed judgments caused by literal matching of text descriptions, ensuring the professional rationality of the auditing results.
[0070] Specifically, perform auditing comparison on multiple groups of standardized data according to the differential comparison strategy, and after the comparison is completed, output a structured auditing result. Each result includes the data source, the source text location, the original value, the expected reference value, and the difference description.
[0071] Refer to Figure 6 , the following provides a specific implementation method for step S1034. In this implementation method, the standardized data includes identification fields, measurement value fields, and natural language description fields. The comparison rules include equal value comparison method, numerical range comparison method, and semantic approximation comparison method. This implementation method includes: S10341. When the standardized data belongs to the data of the identification field, use the equal value comparison method to perform identification consistency auditing on the standardized data and the preset identification reference value, and output the auditing result; In this embodiment, it is necessary to first determine the field type of the current standardized data. When the field type is fields with unique identity attributes such as well number, well name, block number, casing steel grade code, etc., then it means that the standardized data belongs to the data of the identification field. The identification field is the unique identity certificate of the document and the data. Once there is a deviation, it will cause serious problems such as incorrect document attribution and incorrect matching of equipment parameters, and there is no reasonable error space.
[0072] When standardized data belongs to the identifier field, the standardized data is matched character by character with the preset identifier reference value. If the two are completely consistent, the review is considered passed; if there are any character differences, the review is considered failed, and the corresponding field position, original value, and reference value are recorded and added to the review issue list.
[0073] S10342. When the standardized data belongs to the measured value field, the standardized data is compared with the preset reference tolerance range using the numerical range comparison method, and the verification result is output. When the field type of the current standardized data is a numerical field of engineering measurement such as formation depth, ground elevation, casing wall thickness, and drilling fluid density, then it means that the standardized data belongs to the field of measurement value.
[0074] When standardized data is determined to belong to the measured value field, the absolute difference between the standardized data and the target measured reference value is calculated. If the difference is within the preset reference tolerance range, it indicates that the data is consistent and the verification is passed; if the difference exceeds the preset reference tolerance range, it indicates that the data is inconsistent, and the magnitude of the difference and the extent of the exceedance are recorded and included in the verification issue list. For example, when verifying the consistency of formation depth, the preset reference tolerance range is 5 meters. The standardized data in the logging report is 4520.5 meters, which differs from the target measured reference value of 4523.0 meters in the cuttings record by 2.5 meters, which is within the tolerance range.
[0075] S10343. When the standardized data belongs to the natural language description field, the data belonging to the natural language description field and the preset semantic reference value are input into the preset semantic processing model for semantic consistency verification using the semantic approximation comparison method, and the verification result is output.
[0076] When the field types of the current standardized data are natural language fields such as lithological description, stratigraphic naming, engineering anomaly description, and construction measure description, then it means that the standardized data belongs to the natural language description field.
[0077] When it is determined that the standardized data belongs to the natural language description field, the standardized data and the preset semantic reference value are input into the preset semantic processing model adapted to the drilling professional field. The preset semantic processing model combines industry professional knowledge and contextual context to determine whether the professional meaning expressed by the two texts is consistent, not limited to the difference in literal wording, and finally outputs the semantic consistency verification result and difference explanation.
[0078] The following provides a detailed description of the intelligent proofreading system for drilling engineering documents provided in this application. Please refer to [link / reference]. Figure 7 , Figure 7An embodiment of the intelligent proofreading system for drilling engineering documents provided in this application, the system includes: Construction unit 701 is used to obtain the document to be reviewed and construct an initial document semantic tree based on the preset parsing rules and the document to be reviewed. The initial document semantic tree includes multiple nodes and the hierarchical affiliation and confidence level of each node. The hierarchical affiliation and confidence level are output by the preset parsing rules after parsing the document to be reviewed. Correction unit 702 is used to correct the hierarchical affiliation of nodes with confidence scores lower than the first preset threshold using a preset semantic processing model, and obtain the target document semantic tree after correction. The review unit 703 is used to review the semantic tree of the target document according to preset review rules, and output the review results after review. The preset review rules include data source definition rules, data location rules, data extraction rules and comparison rules.
[0079] The review and approval unit 703 is specifically used for: The target data source is determined from the semantic tree of the target document according to the data source definition rules; Locate the target data item from the target data source according to the data location rules; The target data items are formatted according to the data extraction rules to obtain standardized data; The standardized data is reviewed and verified based on the comparison rules, and the review and verification results are output.
[0080] Optionally, the data location rules include table row and column location, regular expression location, and model semantic location. The table row and column location, regular expression location, and model semantic location are executed in a chain according to a preset priority. After execution, the first valid execution result returned is taken as the target data item.
[0081] Optionally, the review unit 703 is specifically used for: When performing table row and column positioning, the target cell in the target data source is located by using preset row header keywords and preset column header keywords, and the text in the target cell is used as the target data item. When performing regular expression positioning, the target text in the target data source is matched with the regular expression, and the matched target text is used as the target data item. When performing semantic localization, all text from the target data source is input into the preset semantic processing model. The preset semantic processing model locates the target text from all text and uses the target text as the target data item.
[0082] Optionally, the standardized data includes an identifier field, a measurement value field, and a natural language description field, and the comparison rules include equivalent comparison, numerical range comparison, and semantic approximation comparison. The standardized data is reviewed and verified based on the comparison rules. The review and verification results are then output, including: When standardized data belongs to the identification field, the standardized data is compared with the preset identification reference value to check the consistency of the identification, and the check result is output. When the standardized data belongs to the measurement value field, the standardized data is compared with the preset reference tolerance range using the numerical range comparison method, and the verification result is output. When the standardized data belongs to the natural language description field, the data belonging to the natural language description field is compared with the preset semantic reference value and input into the preset semantic processing model for semantic consistency verification, and the verification result is output.
[0083] Optionally, it also includes a first inspection unit 704, specifically used for: Obtain auxiliary file tags from the preset review rules, and check whether the data source definition rules involve auxiliary files through the auxiliary file tags. The auxiliary file is an external document referenced by the auxiliary file tags in the preset review rules and used for cross-document comparison with the document to be reviewed. If so, multi-level matching is performed based on the auxiliary file tags and the filenames in the preset external filename set to establish a mapping relationship between the auxiliary file tags and the external documents corresponding to the matched filenames; Construct an external document semantic tree for external documents with established mapping relationships, and update the preset review rules based on the external document semantic tree.
[0084] Optionally, a second inspection unit 705 is also included, for: After each rule in the preset review rules is executed, and before the next rule begins, check whether a task cancellation signal has been received. If so, the review process will be terminated.
[0085] Optionally, building unit 701 is specifically used for: The document to be reviewed is parsed based on preset parsing rules to obtain a set of candidate chapters; Extract the first group of chapters marked with heading styles from the candidate chapter set, and determine the uncovered document areas in the document to be reviewed based on the first group of chapters; The pre-set chapter pattern set is used to perform secondary recognition on the uncovered document area, and the recognized natural language chapters are marked as the second group of chapters; The initial document semantic tree is constructed based on the first and second groups of chapters.
[0086] For details on the implementation method, please refer to [link / reference]. Figures 1-6 Examples will not be described in detail here.
[0087] This application also provides a device for intelligent proofreading of drilling engineering documents; please refer to [link / reference]. Figure 8 , Figure 8 An embodiment of the intelligent proofreading apparatus for drilling engineering documents provided in this application includes: Processor 801, memory 802, input / output unit 803, bus 804; The processor 801 is connected to the memory 802, the input / output unit 803, and the bus 804; The memory 802 stores a program, and the processor 801 calls the program to execute the intelligent review method for any of the drilling engineering documents mentioned above.
[0088] This application also relates to a computer-readable storage medium on which a program is stored, which, when run on a computer, causes the computer to perform the intelligent review method for any of the drilling engineering documents described above.
[0089] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0090] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between apparatuses or units through some interfaces, and may be electrical, mechanical, or other forms.
[0091] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0092] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0093] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
Claims
1. A method for intelligent proofreading of drilling engineering documents, characterized in that, include: Obtain the document to be reviewed and construct an initial document semantic tree based on the preset parsing rules and the document to be reviewed. The initial document semantic tree includes multiple nodes and the hierarchical affiliation and confidence level of each node. The hierarchical affiliation and the confidence level are output after the document to be reviewed is parsed by the preset parsing rules. The hierarchical affiliation of nodes with confidence scores below a first preset threshold is corrected using a preset semantic processing model, and the corrected result is the semantic tree of the target document. The semantic tree of the target document is reviewed by a preset review rule, and the review result is output after review. The preset review rule includes data source definition rule, data location rule, data extraction rule and comparison rule. The step of reviewing the semantic tree of the target document using preset review rules and outputting the review results includes: The target data source is determined from the target document semantic tree according to the data source definition rules; Locate the target data item from the target data source according to the data location rules; The target data items are formatted according to the data extraction rules to obtain standardized data; The standardized data is reviewed and verified based on the comparison rules, and the review and verification results are output.
2. The method according to claim 1, characterized in that, The data location rules include table row and column location, regular expression location, and model semantic location. The table row and column location, regular expression location, and model semantic location are executed in a chain according to a preset priority. After execution, the first valid execution result returned is taken as the target data item.
3. The method according to claim 2, characterized in that, Locating the target data item from the target data source according to the data location rules includes: When performing the table row and column positioning, the target cell is located in the target data source by using preset row header keywords and preset column header keywords, and the text in the target cell is used as the target data item; When the regular expression is executed for location, the target text in the target data source is matched using the regular expression, and the matched target text is used as the target data item. When performing the model semantic localization, all text in the target data source is input into the preset semantic processing model. The target text is located from all the text through the preset semantic processing model and the target text is used as the target data item.
4. The method according to claim 3, characterized in that, The standardized data includes an identification field, a measurement value field, and a natural language description field. The comparison rules include equal value comparison, numerical range comparison, and semantic approximation comparison. The process of reviewing and verifying the standardized data based on the comparison rules, and outputting the review results, includes: When the standardized data belongs to the data of the identification field, the standardized data is compared with the preset identification reference value using the equivalent comparison method to check the identification consistency, and the check result is output. When the standardized data belongs to the data of the measured value field, the standardized data is compared with the preset reference tolerance range using the numerical range comparison method, and the comparison result is output. When the standardized data belongs to the data in the natural language description field, the data belonging to the natural language description field and the preset semantic reference value are input into the preset semantic processing model for semantic consistency verification using the semantic approximation comparison method, and the verification result is output.
5. The method according to claim 1, characterized in that, In the process of determining the target data source from the target document semantic tree according to the data source definition rules, the method further includes: Obtain auxiliary file tags from the preset review rules, and check whether the data source definition rules involve auxiliary files through the auxiliary file tags. The auxiliary file is an external document referenced by the auxiliary file tags in the preset review rules and used for cross-document comparison with the document to be reviewed. If so, multi-level matching is performed based on the auxiliary file tags and the filenames in the preset external filename set to establish a mapping relationship between the auxiliary file tags and the external documents corresponding to the matched filenames; An external document semantic tree is constructed for the external documents for which the mapping relationship is established, and the preset review rules are updated based on the external document semantic tree.
6. The method according to claim 1, characterized in that, In the process of reviewing the semantic tree of the target document using the preset review rules, the method further includes: After each rule in the preset review rules is executed, and before the next rule begins, check whether a task cancellation signal has been received. If so, the review process will be terminated.
7. The method according to any one of claims 1 to 6, characterized in that, The construction of the initial document semantic tree based on preset parsing rules and the document to be reviewed includes: The document to be reviewed is parsed based on preset parsing rules to obtain a set of candidate chapters; Extract the first group of chapters marked with title styles from the candidate chapter set, and determine the uncovered document areas in the document to be reviewed based on the first group of chapters; The uncovered document area is re-identified using a preset chapter pattern set, and the identified natural language chapters are marked as the second group of chapters; Construct an initial document semantic tree based on the first group of chapters and the second group of chapters.
8. A system for intelligent proofreading and reviewing drilling engineering documents, characterized in that, include: A construction unit is used to obtain the document to be reviewed and construct an initial document semantic tree based on the preset parsing rules and the document to be reviewed. The initial document semantic tree includes multiple nodes and the hierarchical affiliation and confidence level of each node. The hierarchical affiliation and the confidence level are output by the preset parsing rules after parsing the document to be reviewed. The correction unit is used to correct the hierarchical affiliation of the nodes whose confidence level is lower than the first preset threshold using a preset semantic processing model, and obtain the target document semantic tree after correction. The review unit is used to review the semantic tree of the target document according to preset review rules, and output the review results after review. The preset review rules include data source definition rules, data location rules, data extraction rules, and comparison rules.
9. A device for intelligent proofreading of drilling engineering documents, characterized in that, include: Processor, memory, input / output units, and bus; The processor is connected to the memory, the input / output unit, and the bus; The memory stores a program, which the processor invokes to perform the method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium contains a program that, when executed on a computer, performs the method as described in any one of claims 1 to 7.