Data verification method, data verification device and storage medium

By converting text data into a structured format and establishing mapping relationships, and using semantic analysis for verification, the problem of low efficiency in traditional data verification is solved, achieving automated and efficient data verification.

CN120930610BActive Publication Date: 2025-12-23CHENGDU HONGRUI TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511457179.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-13
Publication Date
2025-12-23
Estimated Expiration
2045-10-13

AI Technical Summary

Technical Problem

Traditional data verification is inefficient and prone to omissions, making it difficult to handle various flexible and changing situations, and requiring a large amount of manual checking and confirmation.

Method used

By converting the editable first text data into a structured format that meets the conditions for semantic analysis, a mapping relationship between documents is established, semantic analysis is used for verification, and editable error messages are generated.

Benefits of technology

It has achieved a fully automated data verification process, reducing manual annotation and positioning steps, improving verification efficiency, and reducing false detections and missed detections.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120930610B_ABST
    Figure CN120930610B_ABST
Patent Text Reader

Abstract

The application relates to a data checking method, a data checking device and a storage medium. The application first establishes a mapping relationship between a first position of first text data in an editable format in a first document to be checked and a second position of second text data in a target format in a second document through semantic analysis, so that the original text to be checked and the text to be checked after conversion form a corresponding relationship in position. Then, the second document is checked through semantic analysis, and second text data that fails to pass the checking in the second document is taken as labeled data. Finally, based on the mapping relationship, a labeled position of the labeled data in the first document is determined, and an editable error prompt is generated at the labeled position. In this way, the time for manually finding the error position of the original document is reduced, the checking and correction efficiency is improved, and thus the data checking efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of data processing, in particular to a data verification method, a data verification device and a storage medium. BACKGROUND

[0002] Data verification refers to verifying the accuracy, completeness, consistency, validity and compliance of data in the data processing process to ensure that the data meets the preset standards, which directly affects the reliability of the data and the effectiveness of subsequent applications. Traditional data verification usually uses deep learning information extraction combined with probability model comparison for analysis. Since the same type of index description may have different cases, there are many places involving semantic understanding, and traditional models are difficult to handle flexible and variable multi-class situations. Moreover, traditional data verification, such as consistency checking, requires a lot of manual checking and confirmation after extracting and comparing index values. Traditional models usually give probability conclusions, lack analysis mechanisms and reasons, and require human intervention for checking and verification. Therefore, traditional data verification is time-consuming and prone to omissions, resulting in low efficiency of data verification. SUMMARY

[0003] The purpose of the present application is to provide a data verification method, a data verification device and a storage medium to solve the problem of low efficiency of traditional data verification.

[0004] To achieve the above purpose, the first aspect of the present application provides a data verification method, comprising:

[0005] Obtaining editable format first text data in a first document to be verified;

[0006] Converting the first text data into second text data in a target format to generate a second document, the target format being a structured format meeting semantic analysis conditions;

[0007] Based on the semantic relationship between the first document and the second document, a mapping relationship between the first position of the first text data in the first document and the second position of the second text data in the second document is established;

[0008] Verifying the second document through semantic analysis, and taking the second text data in the second document that fails the verification as labeled data;

[0009] Based on the mapping relationship, determining the labeled position of the labeled data in the first document, and generating an editable error prompt at the labeled position.

[0010] The second aspect of the present application provides a data verification device, comprising:

[0011] The acquisition module is configured to acquire editable format first text data in a first document to be verified.

[0012] The conversion module is configured to convert the first text data into second text data in a target format to generate a second document, the target format being a structured format meeting semantic analysis conditions.

[0013] The mapping module is configured to establish a mapping relationship between the first position of the first text data in the first document and the second position of the second text data in the second document based on semantic relationships between the first document and the second document.

[0014] The marking module is configured to verify the second document by semantic analysis, and mark the second text data in the second document that fails the verification as marking data.

[0015] The prompting module is configured to determine a marking position of the marking data in the first document based on the mapping relationship, and generate an editable error prompt at the marking position.

[0016] The third aspect of the present application provides a computer readable storage medium, the computer readable storage medium stores a program, the program can be loaded by a processor and execute the above-mentioned data verification method.

[0017] The beneficial effects of the present application are:

[0018] The present application first establishes a mapping relationship between the first position of the editable format first text data in the first document to be verified and the second position of the second text data in the second document in the target format through semantic analysis, so that the original text to be verified and the converted text to be verified form a corresponding relationship in position. Then, the second document is verified by semantic analysis, and the second text data in the second document that fails the verification is marked as marking data. Finally, based on the mapping relationship, the marking position of the marking data in the first document is determined, and an editable error prompt is generated at the marking position. In this way, the full automation process of format conversion, relationship mapping, semantic verification judgment and error marking can be completed, reducing the manual marking and positioning steps, thereby reducing the false detection and missed detection caused by human error. And based on the mapping relationship between the first position and the second position, the editable error prompt is generated directly in the first document according to the verification result of the second document, and the user can modify directly based on the editable error prompt at the marking position, reducing the time for manually finding the error position in the original document, and improving the verification and correction efficiency. In this way, the efficiency of data verification is improved.

[0019] Other features and advantages of the present application will be described in detail in the following specific embodiments. BRIEF DESCRIPTION OF DRAWINGS

[0020] Figure 1 A flowchart of a data verification method provided in an embodiment of the present application is shown in FIG. 1.

[0021] Figure 2 A flowchart of a data verification method provided in an embodiment of the present application is shown in FIG. 1.

[0022] Figure 3 A structural diagram of a data verification device provided in an embodiment of the present application is shown in FIG. 2.

[0023] Figure 4 A structural diagram of a data verification system provided in an embodiment of the present application is shown in FIG. 3. DETAILED DESCRIPTION

[0024] The technical solutions in the embodiments of the present application will be clearly and completely described with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present application.

[0025] In the description of the present application, it should be understood that the terms "first", "second" are used only for the purpose of description, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the technical features indicated. Therefore, the features defined with "first", "second" can explicitly or implicitly include one or more of the features. In the description of the present application, the meaning of "multiple" is two or more, unless otherwise specifically limited. In the present application, the word "exemplary" is used to mean "serving as an example, instance, or illustration". Any embodiment described as "exemplary" in the present application is not necessarily construed as preferred or advantageous over other embodiments. In order to enable any person skilled in the art to implement and use the present application, the following description is given. In the following description, details are listed for the purpose of explanation. It should be understood that those skilled in the art can realize the present application without using these specific details. In other examples, well-known structures and processes will not be described in detail to avoid unnecessary details making the description of the present application obscure. Therefore, the present application is not intended to be limited to the embodiments shown, but is consistent with the broadest scope consistent with the principles and features disclosed in the present application.

[0026] Figure 1 A flowchart of a data verification method provided in an embodiment of the present application is shown in FIG. 1. Figure 1 As shown in FIG. 1, the data verification method can include steps 101-105, which will be described in detail below.

[0027] In step 101, editable format first text data in a first document to be verified is obtained.

[0028] In the embodiments of the present application, the first document is an original document to be verified, and the first document can include one or more documents related to business scenarios. The first text data is data in the first document. The editable format refers to a format that allows users to modify. Therefore, the storage form of the first text data is to allow users to directly modify the content such as text, table, picture, etc. As an example, the first document can include but is not limited to a Word document, an Excel table, a Portable Document Format (PDF), etc. Correspondingly, the first text data in the first document can be extracted by, for example, an OpenXML-based Word parser, an Apache POI library, etc.

[0029] In addition, in the process of extracting the first text data, the physical position of the first text data in the first document, i.e., the first position, can be recorded synchronously, such as the XML node of a paragraph in a Word document, the cell coordinates of an Excel table, etc. In this way, the binding of the first text data and the original position can be ensured.

[0030] In step 102, the first text data is converted into second text data in a target format to generate a second document.

[0031] In the embodiments of the present application, the second text data is text data converted from the editable format first text data into a target format, and the document formed by the second text data is a second document. The target format is a structured format that meets the semantic analysis condition, and the feature of the target format is that the data structure is clear and machine-parsable, so as to facilitate subsequent verification of the second document based on semantic analysis. As an example, the target format can be a JSON format and a Markdown format, etc. By analyzing the nested structure of the JSON format, the data position can be located by a "key path". The structure of the Markdown format is usually composed of blocks such as headings, paragraphs, and tables. Therefore, the data position can be located by a line number + block type.

[0032] Generally, editable documents are designed for the convenience of users to create, modify, layout, and display content, and the design logic is convenient for users to read and edit, without following uniform machine-recognizable rules, i.e., non-machine-automatic parsing logic. Therefore, it is necessary to convert the first text data lacking uniform rules into a structured format that meets the semantic analysis condition. By converting the first text data into a uniform target format, consistent input can be provided for subsequent semantic analysis of the second document, and the situation of missing verification due to data type difference is reduced.

[0033] In addition, while the second document is being constructed, a unique second position for each second text data of the second document can also be generated synchronously, the second position being a logical position identifier based on a structured syntax, used to uniquely determine the position of the second text data in the second document. For example, when converting a certain paragraph of a Word document into a JSON field, the path of the field in the JSON can be recorded as the second position, and when converting a cell of an Excel table into a Markdown table, the row and column indexes can be recorded as the second position.

[0034] Step 103, based on the semantic relationship between the first document and the second document, a mapping relationship between the first position of the first text data in the first document and the second position of the second text data in the second document is established.

[0035] The embodiments of the present application can realize cross-document position association through semantic analysis, and establish a mapping relationship between the positions of the text data in the first document and the second document. As an example, the first text data and the second text data can be encoded by a pre-trained language model (such as Sentence-BERT) to obtain high-dimensional semantic vectors, so as to quantify the semantic information of the text. Then, the similarity between the encoded first text data and the second text data is calculated based on the semantic information, and the text pair composed of the first text data and the second text data with high similarity is taken as the text data with a mapping relationship, and then a mapping relationship is established between the first position corresponding to the first text data and the second position corresponding to the second text data in the text pair. The position mapping between the original text data and the text data in the converted format is established based on semantics rather than simple format tags, which reduces the association difficulty of different expressions of the same content, and reduces the error association caused by semantic ambiguity, providing reliable data basis for subsequent positioning.

[0036] Step 104, verifying the second document through semantic analysis, and taking the second text data in the second document that fails the verification as annotation data.

[0037] In the embodiments of the present application, the second text data in the second document is data in the target format, i.e., a structured format that can meet the semantic analysis condition. Therefore, the second document can be verified through semantic analysis to obtain a verification result of the second document, and the second text data that fails the verification in the verification result is taken as annotation data. For example, the annotation data can be second text data that does not conform to the verification rule or has contradictions.

[0038] As an example, the index to be checked can be obtained, which is the text data in the second text data that needs to be checked, such as a certain field, etc. The index description is the explanation, description and supplementary information of the index. The checking is performed through semantic understanding instead of simple string matching, which can process flexible expression of text data. For example, the hydrogen ion concentration index can be called "pH value" or "acidity and alkalinity", which can be the same index description. "Greater than or equal to 5" and "> 5" can be the same index description.

[0039] As an example, the checking of the second document includes but is not limited to various complex scenarios. For example, the checking of the second document can include consistency checking of the index description corresponding to the same index, and can also include checking whether the index description is compliant. In this way, the checking of different complex scenarios can be met, and the false detection and missed detection can be reduced.

[0040] In step 105, based on the mapping relationship, the annotation data is determined at the annotation position of the first document, and an editable error prompt is generated at the annotation position.

[0041] In the embodiment of the present application, the second position of the annotation data can be found in the second document first, and then based on the mapping relationship between the first position and the second position constructed in advance, the first position of the annotation data in the original first document is determined. The first position of the annotation data in the first document is the annotation position. At the same time, an editable error prompt can be generated at the annotation position. The editable error prompt refers to a prompt information that the user can perform editing operations such as modification, deletion, addition, etc. For example, in the Word document, the error prompt is in the revision mode, and the user can edit the annotation data at the annotation position according to the error prompt of the revision mode. As an example, the modification operation of the first document can be automatically synchronized to the second document, so as to realize the synchronous update between different format documents. By associating the error prompt with the original document position, the user does not need to switch between two documents, reducing the time of error positioning. And through the form of editable error prompt, the correction and reference basis are inherited, reducing the cost of manual judgment, improving the correction efficiency, and reducing the secondary errors caused by incomplete information.

[0042] The application solves the core pain points of traditional data checking, such as cross-format association difficulty, slow error positioning, weak multi-modal processing, and low correction efficiency, through the link of semantic mapping, semantic checking, and editable error prompt, and realizes the full-process automation from data extraction to error correction. Compared with the traditional scheme, the data checking efficiency is significantly improved, the accuracy of error positioning is improved, and the artificial cost is reduced. Users can directly modify based on the editable error prompt of the labeled position, reduce the time of manually searching for the error position of the original document, and improve the checking and correction efficiency. In this way, the efficiency of data checking is improved, and it is suitable for medical, pharmaceutical, financial and other fields with extremely high requirements for data specification, and has strong practical value and industry adaptability.

[0043] In the embodiment of the application, the first text data can include multiple types of data, such as text data, table data or picture data, etc. For different types of first text data, different extraction methods can be used. Therefore, in step 102, the first text data can be parsed first to separate the first text data, the first table data and the first picture data. The first text data, the first table data and the first picture data are the text format data, the table format data and the picture format data separated from the first text data respectively.

[0044] As an example, the first text data can be analyzed by a document parsing engine (such as Apache POI, Tesseract OCR, etc.), and the content can be split according to the characteristics of the data type, for example, the analysis can be based on XML tags or layout rules, etc. For the first text data, pure text paragraphs, titles and annotations, etc. can be extracted, for the first table data, the row, column and cell structures of the table can be recognized, and the correspondence between the table header and the data is preserved, and for the first picture data, the picture file path or binary data can be located, and the position of the first picture data in the first document can be recorded. By recording the position information of each data, data support can be provided for the subsequent mapping relationship. Then different processing methods can be used to process different types of data respectively.

[0045] The first text data and the first table data can be structured to obtain first structured data in a target format. The first structured data is structured data obtained by structuring. In an example, for the first text data, long text with the same semantic theme can be split into independent units according to semantic segmentation, and key information, i.e., indicators, can be labeled through named entity recognition technology. Then, logical relationships between entities are established, for example, a "drug name" corresponds to a "specification parameter". In another example, the header data of the first table data can be associated to obtain first table data in a "field-value" format, and then text values are converted into structured data such as numerical values and dates. Through structuring, the first text data and the first table data can be converted into a format that can be processed by a semantic analysis model, improving the efficiency of automatic checking. Furthermore, the expression forms of text and tables are unified, for example, both are converted into JSON objects, which can facilitate subsequent checking and comparison operations.

[0046] For the first picture data, the first picture data and the first prompt word can be input into a multimodal large language model (MLLM) for recognition. Then, second text data in the first picture data is extracted, and the second text data is structured to obtain second structured data in a target format. The first prompt word is a text instruction for prompting the MLLM to recognize, used to guide the MLLM to generate an output that meets the requirements, which can be a question, a description or a task instruction. The second structured data is structured data obtained by processing the MLLM.

[0047] Taking the first text data as an example of picture data of user handwriting records, for picture data of handwriting records, pre-processing is usually performed through an optical character recognition (OCR) model. However, handwriting data has various styles, complex environments and random layouts, and OCR is mainly trained based on printed data, so the coverage of handwriting data is insufficient, and therefore the recognition accuracy of handwriting record data processed by the OCR model cannot be guaranteed. Based on this, the embodiments of the present application can fuse visual and language information through the MLLM to realize deep understanding of the handwriting record data. The MLLM is a large language model (LLM) that integrates multiple modal information processing capabilities, further expands the data processing capabilities of non-text modalities such as images, audio and video on the basis of the text understanding and generation capabilities of traditional LLMs, and can realize cross-modal information fusion, understanding and reasoning.

[0048] Specifically, the first picture data and the first prompt word can be input into the MLLM. The MLLM first performs visual feature extraction, such as identifying the image features of the text in the first picture data through a CNN to generate a visual vector. Then, the visual vector is fused with the text knowledge of a pre-trained language model (such as BERT) to inject language knowledge. Next, the recognition result is verified through multiple rounds of reasoning by the generative ability, and the verification result and the corresponding confidence are output. If the recognition result is contradictory to other information, a secondary check of the MLLM can also be triggered. Then, the second text data is output, and the extracted second text data is then subjected to a structured conversion.

[0049] The MLLM can not only recognize text, but also understand the semantic relationship in the picture, such as the relationship between the label text and the graphics, thereby improving the recognition accuracy of the picture data. Moreover, the problem that the traditional check tool is difficult to handle the picture content is solved, and the MLLM is particularly suitable for medical reports, engineering drawings and other documents containing a large amount of pictures.

[0050] Finally, the first structured data and the second structured data are merged to obtain the second text data in the target format. In this way, different types of first text data can be integrated into unified data in the target format, facilitating subsequent semantic analysis models to perform check operations. As an example, based on entity association, relevant fields can be merged to achieve data alignment. When there is a data inconsistency, a conflict can be marked and the original data source can be retained. Then, the final second text data is obtained according to the syntax rules of the target format.

[0051] In step 103, first, a first position corresponding to the first text data is extracted in the first document, and a second position corresponding to the second text data is extracted in the second document. As an example, the physical position of the first text data, i.e., the first position, can be located in the first document. For example, the physical position of the first text data is located by an XML node path, the physical position of the first table data is located by a row and column coordinate, and the physical position of the first picture data is located by an anchor position or a recognition box coordinate. As another example, the logical position of the second text data, i.e., the second position, can be located in the second document. For example, the logical position of the second text data is located by a JSONPath expression or an XPath path.

[0052] Then, the first text data is encoded to obtain a first semantic vector, and the second text data is encoded to obtain a second semantic vector. As an example, a pre-trained language model can be used to convert text into a high-dimensional vector, so that the text data can be converted into a form that can be calculated.

[0053] Next, the similarity of the first semantic vector and the second semantic vector is calculated, and a matching pair is generated, each of which can include a first semantic vector and a second semantic vector with a mapping relationship. As an example, the similarity between different semantic vectors can be calculated using the cosine similarity method first, and the result range can be [-1, 1], with a higher value indicating a more similar semantic. Then, based on the set similarity threshold, the semantic vectors higher than the similarity threshold are retained as matching pairs to generate a set of matching pairs. Each matching pair can include a first semantic vector and a second semantic vector.

[0054] Finally, the positions corresponding to the semantic vectors in the matching pair are mapped. Specifically, the first position corresponding to the first semantic vector in each matching pair is mapped with the second position corresponding to the second semantic vector, establishing a mapping relationship between the first position of the first text data in the first document and the second position of the second text data in the second document. In this way, the position mapping relationship between the original document and the structured document can be established, and bidirectional tracing can be realized. In the case of subsequent verification of the second document, if the verification fails, the specific position in the original first document can be quickly located through the mapping table, improving the efficiency of verification positioning and correction. Moreover, compared with simple format matching, semantic-driven mapping can break through the limitations of fixed templates in traditional methods and support multiple types of document structures, which can adapt to different verification scenarios.

[0055] In the similarity judgment of text data, there may be a problem of semantic similarity but different scenarios. Taking medical records as an example, in medical records, diagnosis results and medication recommendations may contain the same name, but format features can distinguish between diagnosis and recommendations as belonging to different medical processes. Therefore, in step 103, the first structure feature corresponding to the first text data can be extracted in the first document, and the second structure feature corresponding to the second text data can be extracted in the second document. The structure feature is a formalized representation of the arrangement or hierarchical relationship of the text data in the document, which together with the semantic content of the text data constitutes the complete information of the text. For example, the structure feature can include at least one of paragraph level, table row and column number, and picture boundary coordinates.

[0056] Then, the first structure feature is fused with the first semantic vector after coding to obtain a first fusion vector, and the second structure feature is fused with the second semantic vector after coding to obtain a second fusion vector. Then, the similarity of the first fusion vector and the second fusion vector is calculated to obtain the initial similarity of a plurality of candidate matching pairs. The candidate matching pair refers to the first fusion vector and the second fusion vector whose semantic content similarity is greater than a set similarity threshold. However, there may be fusion vectors whose semantic content is similar but structure features are not matched. Therefore, the initial similarity needs to be weighted and adjusted according to the matching rule of the first structure feature and the second structure feature, and the candidate matching pair with matched structure features is selected as the matching pair. In this way, the semantic content and the structure feature are combined to determine the matching pair, which can improve the detection accuracy of the matching pair and reduce the false detection.

[0057] Since there may be different description methods for the description of the same index, that is, the same index description expresses the same meaning but presents different written forms, there are many places related to semantic understanding, and even the association of context and formula calculation. Based on this, the embodiment of the application proposes a way of checking the consistency of the index description corresponding to the to-be-verified index based on semantic relationship.

[0058] In step 104, the initial index to be verified can be searched in the second document based on semantic analysis, and the same index in the initial index is determined. The initial index refers to the index that needs to be verified in advance. For example, assuming that the input index that needs to be verified is A, B and C, and there are A1, A2, B1, B2, C1, etc. in the second document, which have semantic relationship with A, B and C respectively, then A1, A2, B1, B2 and C1 can all be used as initial indexes, and based on the semantic relationship, A and A1, A2 can be determined as the same index, B and B1, B2 can be determined as the same index, and C and C1 can be determined as the same index.

[0059] Then, for the same index, the index description having a semantic relationship with the index can also be determined based on semantic analysis. For the index description corresponding to the same index, the unmatched index description is determined as the second text data that fails the verification. The unmatched refers to the index description with different meanings or contradictions. The unmatched condition can include inconsistent units, values exceeding the threshold or conflicting descriptions, which can be determined by semantic analysis.

[0060] For example, assuming the index to be checked is "glucose injection specification", by semantic reasoning, the prompt word is set as "please compare the above index, find out the inconsistent values and mark them out", assuming that "10%" and "20%" can be found in the second document, after comparing "10%" and "20%", the two index descriptions can be determined as inconsistent index descriptions, and the check fails. As an example, the index to be checked and the prompt word can be input into an LLM with semantic analysis function, and the index description of the check failure is obtained. By determining whether the index descriptions corresponding to the same index are synonyms or near synonyms through semantic association, more implicitly associated index descriptions can be covered, without the need to predefine all synonym libraries, thereby improving the accuracy of the check. Moreover, the same index can appear in different positions of the document or in different batch documents. Through semantic search, all index descriptions corresponding to the index can be associated, reducing the case of inconsistent descriptions of the same index in different places, and improving the consistency check across paragraphs, fields or documents.

[0061] In one example, the target model with semantic analysis capability can be used to search for index descriptions corresponding to the index to be checked. For example, the target model can be an LLM, which can generate natural language text and understand the meaning of language text.

[0062] Specifically, the second document is first fragmented to obtain fragmented data, each fragmented data containing continuous and semantically consistent second text data. That is, the second document is divided into continuous fragments according to semantic topics. As an example, sliding windows can be used for detection. For example, the semantic similarity of adjacent sliding windows can be calculated by Sentence-BERT, and when the similarity is less than a set similarity threshold, it can be used as the position of the cut text, so that multiple continuous and semantically consistent fragmented data can be obtained.

[0063] Then a label is added to each fragmented data, including a unique identifier of the fragmented data and a second position of the fragmented data. The fragmented data can be used to input to the target model in a structured instruction. As an example, a unique identifier can be added to each fragmented data by document hash and fragment number. In this way, the fragmentation processing can reduce the performance degradation of the LLM in long text, and reduce the computational power consumption of the LLM. Moreover, by adding the unique identifier and the second position, the subsequent check result can be easily located.

[0064] Then, the fragmented data is added to the context structured text instruction of the target model, and a second prompt word is constructed based on the to-be-verified index. The second prompt word is a text instruction for prompting the LLM to recognize, and is used to guide the LLM to generate an output meeting the requirements, which can be a question, a description or a task instruction. The second structured data is structured data obtained by processing the LLM. For example, the second prompt word can be "find the numerical description of 'glucose injection specification' in the following text". Among them, "glucose injection specification" is an index that can be dynamically filled. By dynamically filling, the second prompt word is constructed based on the fragmented data and the to-be-verified index. Only one template is needed to fill in multiple times to generate the corresponding second prompt word, without the need to develop code based on new indexes, improving the prediction efficiency of the target model.

[0065] Finally, the fragmented data is subjected to semantic analysis based on the second prompt word to obtain an index description having a semantic relationship with the index. The LLM can capture all index descriptions having a semantic relationship with the index in one pass based on the input second prompt word, without the need for multiple regular expressions, reducing the workload of manual review, and carrying the second position, which can facilitate subsequent mapping back to the first document, achieving efficient positioning.

[0066] For the index description of the same index, there can be different formats of user input descriptions. For example, assuming that the search results of the semantic description based on "glucose injection specification" include { "glucose injection specification": "250ml:25g"} and { "glucose injection specification": "20%"}. The semantic descriptions need to be unified into the same format for subsequent comparison. Based on this, the application embodiment can set a preset format rule for the description format of the index description. For example, for the glucose injection specification, it needs to be presented in percentage. Therefore, the application embodiment can introduce a conversion tool for converting the format to unify the description format of the index description into the description format of the preset format rule. As an example, since the preset format rule can include a numerical unit unification rule, a significant digit rule or a symbol specification rule, etc., the conversion tool can include at least one of a unit conversion module and a numerical normalization module.

[0067] Specifically, in step 104, the description format in the index description can be obtained first. Then, it is judged whether the description format conforms to the preset format rule. If the description format does not conform to the preset format rule, the conversion tool is called to convert the description format to conform to the preset format rule. For example, for the index description, the unit conversion tool can be called for conversion to maintain the consistency of unit measurement in the unified parameter specification.

[0068] The traditional index checking and comparison usually optimizes the model itself to improve the accuracy, and it is difficult to check the common sense content. If the document to be checked and compared has a common sense error that does not conform to the business scenario, it is difficult to detect. For example, for the pharmaceutical industry, if the text data to be detected is "glucose", but the text data to be checked is "bubble gum", "bubble gum" conforms to the grammar rule, but does not conform to the current business scenario. The traditional index checking is difficult to identify "bubble gum" as a failed check.

[0069] Therefore, the embodiment of the present application can construct a knowledge base corresponding to the business scenario based on the business scenario. In step 104, the pre-constructed knowledge base can be obtained first. The knowledge base can include a mapping relationship between sample indicators, description rules and reference files. For example, for the pharmaceutical industry, drug professional knowledge can be put into the library, for example, the specification such as the pharmacopoeia is parsed by XML and converted into a markdown format file, and then the embedding model is used for vectorization through code slicing. Then, the vectorized content is stored in the vector database to obtain the knowledge base. If the reference file in the knowledge base is updated, the upgraded reference file can be parsed through XML, and then the increment is written into the rule table, and the version number is automatically upgraded.

[0070] Then, the description rule corresponding to the index in the knowledge base is searched based on the index, and it is judged whether the index description corresponding to the index satisfies the description rule. As an example, the Retrieval-Augmented Generation (RAG) technology can be used to detect whether the index description conforms to the rule. For example, the description rule is converted into a query vector. Then, the vector comparison is performed in the knowledge base, and the hit paragraph of the most similar reference file is searched out. Then, the query vector and the hit paragraph are input into the LLM model to generate a description rule corresponding to the hit paragraph. Then, it is judged whether the generated description rule conforms to the description rule.

[0071] As another example, the index description can be extracted, and the index text can be vectorized by Sentence-BERT. The rule is searched in the knowledge base, and the identification number of the rule is returned, which corresponds to a specification value of the index description. Then, the specification value corresponding to the identification number of the rule is matched with the index description respectively, and if the index description does not match the specification value, it is determined that the index description corresponding to the index does not satisfy the description rule. Finally, the index description that does not satisfy the description rule is determined as the second text data that fails the check, and the reference file corresponding to the description rule is generated at the annotation position of the index description. In this way, the reason for the check error and the corresponding reference file can be directly presented in the original document, which facilitates the correction of the text data based on the reference file.

[0072] In step 105, the annotation data can be determined at the second position of the second document first. That is, the position of the second text data that fails the verification in the second document is checked. Then, based on the mapping relationship between the first position and the second position, the first position of the annotation data in the first document is taken as the annotation position. In this way, the verification result can be accurately presented in the corresponding position of the first document. Finally, the error prompt is embedded in the annotation position in the form of editable annotations. The error prompt can include but is not limited to error type, error description, reference file source, and correction suggestion and other related information. In this way, the user can check the correctness of the data content based on the editable error displayed in the first document, and can directly correct the original first document based on the error prompt. The embodiment of the present application can realize direct error prompting and correction suggestion in the original document after data verification, reducing the time and cost of manual confirmation, and reducing the situation of human error detection and false detection, improving the efficiency of data verification and correction.

[0073] Figure 2 A flowchart of a data verification method provided in an embodiment of the present application is shown in FIG. 1. As shown in FIG. 1, taking the data verification of the pharmaceutical industry as an example, the first document is a Word document, and the format of the second document is markdown format. The data verification method includes steps 201-208. Figure 2

[0074] Step 201, constructing a knowledge base of the pharmaceutical industry. For example, the knowledge of pharmacopoeia, operation procedures, Good Manufacturing Practice of Medical Products (GMP), etc. is segmented into a vector library through embedding chuck, as a file to be searched.

[0075] Step 202, extracting the first text data of the original Word document using OpenXML. Select the Word document that needs to be checked, and use OpenXML technology to extract all the text content of the existing Word document.

[0076] Step 203, converting the first text data into markdown format second text data. The extracted text content is converted into markdown format that can be understood by LLM, and the positions of markdown text paragraphs and tables and XML paragraphs and tables are mapped, and the source of the file is annotated.

[0077] ​Step 204, content paragraph segmentation and semantic extraction of indicators. Segment the markdown paragraphs and tables, and use LLM semantic understanding to find and extract values based on the given indicators. If the original file is a scan or picture, use MLLM model for search and analysis.

[0078] Step 205, perform common sense specification check on extracted indicators using Retrieval-Augmented Generation (RAG) technology. Use RAG semantic enhancement vector retrieval to find knowledge base content based on extracted indicator names and values, and determine if the indicators meet industry common sense standards. If relevant knowledge is found, confirm that the indicators do not meet the specifications, and render the results back to Word using file and line number mapping positions for prompt and knowledge base source annotation.

[0079] Step 206, perform unit calculation and conversion on extracted indicators. Continue to analyze the semantics of the indicators to detect inconsistencies in units and descriptions (e.g., units: mg and ml). If the units are inconsistent, use the Model Context Protocol (MCP) to call unit conversion tools or other indicator calculation tools to ensure that the units are at the same granularity.

[0080] Step 207, perform consistency check using LLM and annotate in the original Word document. After uniformizing the unit descriptions of the indicators, use LLM semantic understanding to analyze and compare the consistency of the same indicators. If there are deviations and differences in the descriptions, use file and line number mapping positions to annotate and render the results back to Word, prompting the user to correct the inconsistencies. Also, annotate the unit conversion process and reasons for inconsistency for user reference.

[0081] Step 208, user confirms the correctness of the indicator verification and makes calibration modifications. The user confirms the inconsistency of the indicators and manually corrects and modifies the annotations.

[0082] The following is a specific example. Suppose we need to check the accuracy of all the procedures of a drug, involving files such as pharmacopoeia, GMP specifications, process information table, post operation manual, process specification, and drug quality standard and inspection operation procedure documents. The following is a detailed implementation method.

[0083] First, the drug knowledge base is stored. The pharmacopoeia and GPM specifications are parsed by XML and converted to markdown format files, then sliced by code and then the slices are vectorized using the embedding model, and then the vectorized content is stored in the pgvector vector database. For example, the paragraph in the pharmacopoeia: "Glucose injection specifications: (1) 10ml: 1g; (2) 10ml: 2g; (3) 10ml: 5g; (4) 20ml: 5g; (5) 20ml: 10g; (6) 50ml: 2.5g; (7) 50ml: 5g; (8) 100ml: 5g; (9) 100ml: 10g; (10) 100ml: 50g; (11) 200ml: 10g; (12) 250ml: 12.5g; (13) 250ml: 25g; (14) 250ml: 50g; (15) 250ml: 62.5g; (16) 250ml: 100g; (17) 250ml: 125g; (18) 300ml: 15g; (19) 500ml: 25g; (20) 500ml: 50g; (21) 500ml: 125g; (22) 1000ml: 50g; (23) 1000ml: 100g; (24) 1000ml: 250g" is vectorized and stored.

[0084] Then, the original Word file content is extracted. The process information table, job operation manual, process procedure, and drug quality standard and inspection operation procedure Word files are extracted using OpenXML technology, outputting text and table JSON structure, and converted to markdown, and the position is marked in the markdown content.

[0085] Next, the content paragraph is sliced. The extracted markdown content is input into LLM for semantic recognition, and the same content paragraph is sliced, and LLM is used for recognition. The purpose of this step is mainly because the context semantic length of the large model technology is limited, so the slicing method is used. The index semantic extraction can first add the sliced content to the context prompt of the large model, and the user outputs the index to be checked: for example "glucose injection specifications", and constructs the large model query second prompt word such as "the user wants to query <glucose injection specifications>, please find the matching content in the following paragraph and give the corresponding value…".

[0086] After LLM inference, the index assumption is {“Glucose Injection Specification”: “250ml:25g”}, {“Glucose Injection Specification”: “20%”}, and the result is obtained. By prompting the word “Judge whether the units of the indicators in the following indicators are consistent. If they are not consistent, call the ‘unit conversion tool’ for conversion”, at this time the unit of 250ml:25g is converted by calling the MCP server tool through the large model, and the result of {“Glucose Injection Specification”: “10%”}, {“Glucose Injection Specification”: “20%”} is obtained, which maintains the consistency of unit measurement in the same parameter specification. Among them, the MCP tool set can be established by writing a unit conversion tool through code, the input parameter is the volume and weight tool, and the output parameter is the concentration, and the MCP server is established.

[0087] It is known that the content of the pharmacopoeia knowledge base has been put into the first step. By embedding vector retrieval calculation “Glucose Injection Specification”: “250ml:25g”, the knowledge base original text “Glucose Injection Specification: (1) 10ml:1g; (2) 10ml:2g; (3) 10ml:5g; (4) 20ml:5g; (5) 20ml:10g; (6) 50ml:2.5g; (7) 50ml:5g; (8) 100ml:5g; (9) 100ml:10g; (10) 100ml:50g; (11) 200ml:10g; (12) 250ml:12.5g; (13) 250ml:25g; (14) 250ml:50g; (15) 250ml:62.5g; (16) 250ml:100g; (17) 250ml:125g; (18) 300ml:15g; (19) 500ml:25g; (20) 500ml:50g; (21) 500ml:125g; (22) 1000ml:50g; (23) 1000ml:100g; (24) 1000ml:250g” is found. At this time, through the LLM semantic understanding ability: “Call the MCP concentration calculation tool to get the concentration range of glucose injection between 5%-50%, and only include the above specifications, use the large model prompt word”, to judge whether the user's indicators meet the standards mentioned in the context, only answer “yes” and “no” to get the large model answer “yes”, and check the index common sense problem. If the check fails, locate the line number of the markdown of the failed index and the line number of the corresponding Word XML, edit the XML for annotation. Get the Word annotation “Does not conform to the specification of glucose injection in the Pharmacopoeia”.

[0088] Then, consistency checking is performed. After the previous step is passed, the indicators and corresponding values {“Glucose injection specification”: “10%”}, {“Glucose injection specification”: “20%”} are obtained, and the second prompt word “Please compare the above indicators, find out the inconsistent values and mark them out” of LLM is entered. At this time, LLM finds out the different indicators {“Glucose injection specification”: [“10%”, “20%”]} through semantic reasoning, and then starts to trace back. Through the mapping relationship of file name-line number-markdown line number established in the above steps, the XML relationship line number in the original Word is directly traced back to the XML location in the Word to annotate the XML “Inconsistent comparison results:\nIndicator name:\n《xxx Process Specification》Glucose sodium injection specification 250ml:25g\n《xxx Post Operation Procedure》Glucose injection specification 10%”.

[0089] Finally, the user can check the annotation results. By checking the content correctness by viewing the word annotation content, manually changing “20%” to “10%” at “Glucose injection specification”, the assisted document consistency checking and correction operation is completed.

[0090] The embodiment of the application solves the problem of low efficiency of checking multiple numerical indicators in pharmaceutical industry documents. In a set of pharmaceutical process documents, there are usually process information tables, post operation procedures, drug process specifications, production batch records and other documents. The same indicator in the drug manufacturing process is described in different documents. For example, the pH value, the dosage weight, the sterilization temperature and the like in the drug production process. After the document is completed in the early stage, checking the accuracy and consistency of the numerical values in the document becomes a necessary work. The embodiment of the application improves the accuracy and consistency of the pharmaceutical industry document indicators through the above steps.

[0091] It should be noted that although it is a pharmaceutical industry document indicator consistency checking task, the high-frequency scenarios related to numerical value checking, numerical content calculation, contract consistency evaluation can also use the technical solution of the embodiment of the application. For example, the embodiment of the application can also be applied to scenarios such as financial data checking, salary calculation and accounting, personnel performance accounting, and contract consistency evaluation business scenarios.

[0092] Figure 3 A structure diagram of a data verification device 300 provided in the embodiment of the application is shown in FIG. 1. Figure 3As shown, the data checking apparatus 300 can include an obtaining module 301, a converting module 302, a mapping module 303, a marking module 304, and a prompting module 305. The obtaining module 301 is configured to obtain first text data in an editable format in a first document to be checked. The converting module 302 is configured to convert the first text data into second text data in a target format to generate a second document, the target format being a structured format meeting a semantic analysis condition. The mapping module 303 is configured to establish a mapping relationship between a first position of the first text data in the first document and a second position of the second text data in the second document based on a semantic relationship between the first document and the second document. The marking module 304 is configured to check the second document by semantic analysis, and take second text data that fails the checking in the second document as marking data. The prompting module 305 is configured to determine a marking position of the marking data in the first document based on the mapping relationship, and generate an editable error prompt at the marking position.

[0093] In the embodiments of the present application, the converting module 302 can include a parsing unit, a first structuring unit, a second structuring unit, and a merging unit. The parsing unit is configured to parse the first text data, and separate out first character data, first table data, and first picture data. The first structuring unit is configured to perform structured processing on the first character data and the first table data to obtain first structured data in the target format. The second structuring unit is configured to input the first picture data and the first prompt word into a multi-modal large language model for recognition, extract second character data in the first picture data, and perform structured processing on the second character data to obtain second structured data in the target format. The merging unit is configured to merge the first structured data and the second structured data to obtain the second text data in the target format.

[0094] The mapping module 303 can include a first extracting unit, an encoding unit, a calculating unit, and a matching unit. The first extracting unit is configured to extract a first position corresponding to the first text data in the first document, and extract a second position corresponding to the second text data in the second document. The encoding unit is configured to encode the first text data to obtain a first semantic vector, and encode the second text data to obtain a second semantic vector. The calculating unit is configured to calculate a similarity between the first semantic vector and the second semantic vector, and generate a matching pair, each matching pair including the first semantic vector and the second semantic vector having a mapping relationship. The matching unit is configured to respectively map the first position corresponding to the first semantic vector and the second position corresponding to the second semantic vector in each matching pair, and establish a mapping relationship between the first position of the first text data in the first document and the second position of the second text data in the second document.

[0095] The mapping module 303 can further include a first extraction unit and a fusion unit. The first extraction unit is configured to extract first structural features corresponding to the first text data in the first document and extract second structural features corresponding to the second text data in the second document. The fusion unit is configured to fuse the first structural features with the first semantic vector after encoding to obtain a first fusion vector, and fuse the second structural features with the second semantic vector after encoding to obtain a second fusion vector. The calculation unit is further configured to calculate the similarity of the first fusion vector and the second fusion vector to obtain initial similarities of a plurality of candidate matching pairs; and perform weighted adjustment on the initial similarities according to a matching rule of the first structural features and the second structural features, and select a candidate matching pair that matches in structure as a matching pair.

[0096] The labeling module 304 includes a format acquisition unit, a judgment unit, a calling unit, a first search unit, a first determination unit, and a second determination unit. The format acquisition unit is configured to acquire a description format in the index description. The judgment unit is configured to judge whether the description format conforms to a preset format rule. The calling unit is configured to call a conversion tool to convert the description format to a description format conforming to the preset format rule in a case where the description format does not conform to the preset format rule. The first search unit is configured to search for an initial index to be verified in the second document based on semantic analysis and determine identical indexes in the initial index. The first determination unit is configured to determine index descriptions having a semantic relationship with the index for the identical indexes. The second determination unit is configured to determine an index description that does not match as second text data that fails to pass verification for the index descriptions corresponding to the identical indexes.

[0097] The first determination unit is further configured to divide the second document into pieces to obtain piece data, each piece of data containing continuous and semantically consistent second text data; add a label to each piece of data, the label including a unique identifier of the piece data and a second position of the piece data; add the piece data to a context structured text instruction of a target model, and construct a second prompt word based on the index, the target model being a model having semantic analysis capability; and perform semantic analysis on the piece data based on the second prompt word to obtain index descriptions having a semantic relationship with the index.

[0098] The labeling module 304 further includes a knowledge base acquisition unit, a second search unit, and a third determination unit. The knowledge base acquisition unit is configured to acquire a knowledge base constructed in advance, the knowledge base including a mapping relationship of a sample index, a description rule, and a reference file. The second search unit is configured to search for a description rule corresponding to the index in the knowledge base based on the index, and judge whether the index description corresponding to the index satisfies the description rule. The third determination unit is configured to determine an index description that does not satisfy the description rule as second text data that fails to pass verification, and generate a reference file corresponding to the description rule at a labeling position of the index description.

[0099] The prompt module 305 can include a fourth determination unit, a fifth determination unit, and an embedding unit. The fourth determination unit is configured to determine the second position of the annotation data in the second document. The fifth determination unit is configured to determine the first position of the annotation data in the first document as the annotation position based on the mapping relationship between the first position and the second position. The embedding unit is configured to embed the error prompt in the annotation position in the form of an editable comment, and the error prompt includes an error type, an error description, a reference file source, and a correction suggestion.

[0100] Figure 4 A structure diagram of a data verification system provided in an embodiment of the present application is shown in FIG. 4. As shown in FIG. 4, the data verification system 400 can include a memory 401 and a processor 402. The memory 401 is configured to store instructions. The processor 402 is configured to call the instructions from the memory 401 and implement the data verification method described above when executing the instructions. Figure 3

[0101] The embodiment of the present application further provides a computer readable storage medium, which stores a program capable of being loaded by a processor and executing any one of the data verification methods provided in the embodiments of the present application.

[0102] Since the data verification device, the data verification system, and the computer readable storage medium store instructions, the steps in any one of the data verification methods provided in the embodiments of the present application can be executed, and thus the beneficial effects of any one of the data verification methods provided in the embodiments of the present application can be achieved. Details are described in the foregoing embodiments, which will not be described herein again.

[0103] Those skilled in the art can understand that all or part of the functions of the various methods in the above embodiments can be implemented in the form of hardware or in the form of a computer program. When all or part of the functions in the above embodiments are implemented in the form of a computer program, the program can be stored in a computer readable storage medium, which can include a read-only memory, a random access memory, a magnetic disk, an optical disk, a hard disk, and the like. The above functions are implemented by executing the program by a computer. For example, the program is stored in a memory of a device, and when the program in the memory is executed by a processor, all or part of the above functions are implemented. In addition, when all or part of the functions in the above embodiments are implemented in the form of a computer program, the program can also be stored in a server, another computer, a disk, an optical disk, a flash disk, a mobile hard disk, or the like, and is downloaded or copied into a memory of a local device, or a system of the local device is updated in version, and when the program in the memory is executed by a processor, all or part of the functions in the above embodiments are implemented.

[0104] ​The above describes the present application by using specific examples, which is only used to help understand the present application and does not limit the present application. According to the idea of the present application, a person skilled in the art of the present application can make several simple deductions, deformations or substitutions.

Claims

1. A data verification method, characterized in that, include: Retrieve the editable first text data from the first document to be verified; The first text data is converted into second text data in a target format to generate a second document, wherein the target format is a structured format that meets the conditions for semantic analysis. Extract the first position and first structural features corresponding to the first text data in the first document, and extract the second position and second structural features corresponding to the second text data in the second document; The first text data is encoded to obtain a first semantic vector, and the second text data is encoded to obtain a second semantic vector; The first structural feature is encoded and fused with the first semantic vector to obtain a first fusion vector, and the second structural feature is encoded and fused with the second semantic vector to obtain a second fusion vector; Calculate the similarity between the first fusion vector and the second fusion vector to obtain the initial similarity of multiple candidate matching pairs; According to the matching rules of the first structural feature and the second structural feature, the initial similarity is weighted and adjusted, and the candidate matching pairs with matching structural features are selected as the matching pairs. Each matching pair includes the first semantic vector and the second semantic vector with a mapping relationship. In each matching pair, the first position corresponding to the first semantic vector and the second position corresponding to the second semantic vector are mapped respectively to establish a mapping relationship between the first position of the first text data in the first document and the second position of the second text data in the second document; The second document is validated through semantic analysis, and the second text data that fails the validation in the second document is used as labeled data. Based on the mapping relationship, the annotation position of the annotation data in the first document is determined, and an editable error message is generated at the annotation position.

2. The data verification method according to claim 1, characterized in that, The step of converting the first text data into second text data in the target format includes: Parse the first text data to separate the first text data, the first table data, and the first image data; The first text data and the first table data are subjected to structuring processing to obtain the first structured data in the target format; The first image data and the first prompt word are input into a multimodal large language model for recognition, the second text data in the first image data is extracted, and the second text data is processed in a structured manner to obtain the second structured data in the target format; The first structured data and the second structured data are merged to obtain the second text data in the target format.

3. The data verification method according to claim 1, characterized in that, The step of verifying the second document through semantic analysis includes: Based on semantic analysis, search for the initial metrics to be verified in the second document, and identify the same metrics among the initial metrics; For the same metric, determine the metric description that has a semantic relationship with the metric; Obtain the description format from the indicator description; Determine whether the description format conforms to preset format rules; If the description format does not conform to the preset format rules, then the conversion tool is invoked to convert the description format into a description format that conforms to the preset format rules; For the same indicator corresponding to the indicator description, the mismatched indicator description is determined as the second text data that failed the verification.

4. The data verification method according to claim 3, characterized in that, For the same metric, determining the metric description that has a semantic relationship with the metric includes: The second document is split into fragments to obtain fragment data, and each fragment data contains continuous second text data with a consistent semantic topic. A label is added to each of the data segments, the label including a unique identifier for the data segment and a second position of the data segment; The fragmented data is added to the contextual structured text instructions of the target model, and a second prompt word is constructed based on the indicators. The target model is a model with semantic analysis capabilities. Based on the second prompt word, semantic analysis is performed on the segmented data to obtain the indicator description that has a semantic relationship with the indicator.

5. The data verification method according to claim 3, characterized in that, The step of verifying the second document through semantic analysis also includes: Obtain a pre-built knowledge base, which includes the mapping relationship between sample indicators, description rules and reference documents; Based on the indicator, search the knowledge base for the description rule corresponding to the indicator, and determine whether the indicator description corresponding to the indicator satisfies the description rule; The indicator descriptions that do not meet the description rules are identified as the second text data that failed the verification, and a reference file corresponding to the description rules is generated at the marked position of the indicator description.

6. The data verification method according to claim 1, characterized in that, The step of determining the annotation position of the annotation data in the first document based on the mapping relationship, and generating an editable error message at the annotation position, includes: Determine the location of the labeled data in the second position of the second document; Based on the mapping relationship between the first position and the second position, the first position of the labeled data in the first document is taken as the labeled position; Error messages are embedded in the marked locations in the form of editable comments. The error messages include the error type, error description, source of referenced documents, and suggested corrections.

7. A data verification device, characterized in that, include: The acquisition module is used to acquire editable first text data from the first document to be verified. A conversion module is used to convert the first text data into second text data in a target format to generate a second document, wherein the target format is a structured format that meets the semantic analysis conditions; The mapping module is used to extract a first position and a first structural feature corresponding to the first text data in the first document, and to extract a second position and a second structural feature corresponding to the second text data in the second document; The first text data is encoded to obtain a first semantic vector, and the second text data is encoded to obtain a second semantic vector. The first structural feature is encoded and fused with the first semantic vector to obtain a first fusion vector, and the second structural feature is encoded and fused with the second semantic vector to obtain a second fusion vector. The similarity between the first fusion vector and the second fusion vector is calculated to obtain the initial similarity of multiple candidate matching pairs. According to the matching rules of the first structural feature and the second structural feature, the initial similarity is weighted and adjusted, and the candidate matching pairs with matching structural features are selected as the matching pairs. Each matching pair includes the first semantic vector and the second semantic vector with a mapping relationship. The first position corresponding to the first semantic vector in each matching pair is mapped to the second position corresponding to the second semantic vector to establish a mapping relationship between the first position of the first text data in the first document and the second position of the second text data in the second document. The annotation module is used to validate the second document through semantic analysis and to use the second text data in the second document that fails the validation as annotation data. The prompting module is used to determine the annotation position of the annotation data in the first document based on the mapping relationship, and generate an editable error prompt at the annotation position.

8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a program that can be loaded by a processor and executed as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Text extraction method and device and electronic equipment

    CN118522017A

  • PDF file analysis method and system, electronic equipment and storage medium

    CN119203989A