Text intelligent proofreading method and system based on deep learning

By employing a deep learning-based intelligent text proofreading method that combines graph convolutional neural networks and domain knowledge graphs, the problem of global logical proofreading for non-linear typesetting documents and vertical domain texts has been solved. This method achieves accurate differentiation of confused characters and ensures the logical rigor of document content, thereby improving proofreading accuracy and consistency.

CN121706769BActive Publication Date: 2026-04-21SHANDONG INST OF BUSINESS & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHANDONG INST OF BUSINESS & TECH
Filing Date
2026-02-10
Publication Date
2026-04-21

AI Technical Summary

Technical Problem

Existing technologies suffer from problems such as broken semantic association paths, incorrect recognition of professional terms, and logical conflicts in document content when dealing with non-linear typesetting documents, vertical domain texts, and global logical proofreading of long texts. They also lack spatial layout perception and knowledge logic constraint capabilities, and have low accuracy in recognizing subtle ambiguities.

Method used

We employ a deep learning-based intelligent text proofreading method. Through spatial layout awareness, domain knowledge graph enhancement, and cross-paragraph global consistency verification, we utilize graph convolutional neural networks and multi-head attention layers to generate feature matrices. We then combine supervised contrastive learning strategies to train sequence error detection and semantic correction models, thereby achieving accurate differentiation of confused characters and ensuring the logical rigor of document content.

Benefits of technology

It achieves semantic awareness of non-linear typesetting layout and accurate alignment of professional terms in vertical fields, eliminates the influence of physical space typesetting interference and lack of industry professional background, improves the calculation accuracy of error detection distribution and correction distribution, and solves the problems of inconsistent entity descriptions and content logic conflicts in long text proofreading.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121706769B_ABST
    Figure CN121706769B_ABST
Patent Text Reader

Abstract

This invention discloses a deep learning-based intelligent text proofreading method and system, belonging to the field of intelligent proofreading technology. The method includes acquiring a preprocessed text sequence and spatial distribution coordinates, extracting semantic vectors and knowledge vectors, constructing a spatial topology graph to extract spatial vectors, generating a feature matrix, using a supervised contrastive learning strategy to obtain optimized error detection and correction parameters, loading the error detection and correction parameters into the sequence error detection model and semantic correction model respectively, outputting the error detection distribution and correction distribution, comparing entity features with a global memory database to output a consistency score, and weightedly fusing the error detection distribution, correction distribution, and consistency score to determine the proofreading result. This invention integrates spatial layout awareness, domain knowledge graph enhancement, and cross-paragraph global consistency verification into a dual-path architecture, solving problems such as typesetting interference, lack of professional background, and logical conflicts, achieving accurate differentiation of confusing characters, and ensuring the logical rigor of document content.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of intelligent proofreading technology, specifically relating to a text intelligent proofreading method and system based on deep learning. Background Technology

[0002] Text proofreading refers to the process of detecting and automatically correcting errors in text data. The scope of detection and correction includes spelling errors, misuse of punctuation, grammatical and logical contradictions, deviations in proper nouns, and inappropriate semantic expressions. The increasing demand for large-scale text processing has led to a trend of text processing workflows evolving from manual review to automated computer proofreading. Early proofreading methods mainly used preset thesaurus matching and hard logic rule verification to achieve the expected functions. With the deep evolution of natural language processing technology, statistical models and semantic analysis techniques have been widely used in the field of text proofreading. Improving the error recognition rate and the accuracy of correction suggestions has become a research focus. The results of text proofreading directly determine the effectiveness of information transmission and the accuracy of text content.

[0003] To address the challenge of improving the success rate of global logical proofreading for non-linear typesetting documents, vertical domain texts, and long texts, existing technologies typically employ linear text sequence models combined with general feature extraction. However, when faced with physical spatial typesetting interference, lack of industry-specific background information, and inconsistent entity descriptions across paragraphs, issues arise such as broken semantic association paths, incorrect recognition of technical terms, and logical conflicts within document content. Consequently, text proofreading systems suffer from a lack of spatial layout awareness, a lack of knowledge logic constraints, and low accuracy in recognizing subtle and confusing characters. Summary of the Invention

[0004] The purpose of this invention is to provide a deep learning-based intelligent text proofreading method and system. By integrating spatial layout awareness, domain knowledge graph enhancement, and cross-paragraph global consistency verification into a dual-path architecture, it solves the problems of typesetting interference, lack of professional background, and logical conflicts, achieves accurate differentiation of confused characters, and ensures the logical rigor of document content.

[0005] To achieve the above objectives, the technical solution adopted by the present invention is as follows:

[0006] A deep learning-based intelligent text proofreading method includes the following steps:

[0007] Collect and preprocess the text sequence data and page image data to be proofread, and obtain the preprocessed text sequence and its corresponding spatial distribution coordinates;

[0008] Semantic vectors, entity information, and entity features are extracted from the preprocessed text sequence. The entity information is matched with a pre-defined domain knowledge graph to obtain knowledge vectors. A spatial topology graph is constructed based on the spatial distribution coordinates, and then input into a graph convolutional neural network to extract spatial vectors. Finally, a feature matrix is ​​generated through a multi-head attention layer.

[0009] A supervised contrastive learning strategy is introduced. By establishing a contrastive constraint function, a sequence error detection model and a semantic correction model are trained to obtain optimized error detection parameters and correction parameters.

[0010] The sequence error detection model loads error detection parameters, uses a bidirectional long short-term memory network architecture to calculate the feature matrix, and outputs the error detection distribution;

[0011] The semantic correction model loads correction parameters, uses a transformer architecture to calculate the feature matrix, and outputs the correction distribution.

[0012] The entity features are compared with a pre-defined global similarity database using cosine similarity, and a consistency score is output.

[0013] Weighted fusion and non-maximum suppression are performed on the error detection distribution, correction distribution and consistency score to determine the proofreading results and error prediction probability, and the error distribution is statistically analyzed.

[0014] Preferably, the process of obtaining the preprocessed text sequence and its corresponding spatial distribution coordinates includes:

[0015] The text capture device's data output port and the data input port of the data preprocessing unit are connected via a communication bus. The text capture device acquires text sequence data, and the text sequence data is transmitted to the data preprocessing unit via the communication bus.

[0016] The data preprocessing unit performs noise removal, abnormal character masking, and normalization format conversion on the text sequence data to generate a preprocessed text sequence;

[0017] The image signal output terminal of the text capture device and the signal receiving terminal of the image acquisition unit are connected by an electrical signal transmission line. The text capture device captures the visual information of the page to be proofread to generate page image data, and then transmits the page image data to the image acquisition unit through the electrical signal transmission line.

[0018] The image acquisition unit performs pixel enhancement, geometric correction, and noise reduction on the page image data to identify text units and extract the spatial distribution coordinates corresponding to the preprocessed text sequence, including the horizontal and vertical pixel coordinates of the center point of the text unit, as well as the horizontal width and vertical height of the bounding box.

[0019] The horizontal pixel coordinates are determined by the arithmetic mean of the minimum and maximum pixel coordinates of the text unit's bounding box in the horizontal direction, and the vertical pixel coordinates are determined by the arithmetic mean of the minimum and maximum pixel coordinates of the text unit's bounding box in the vertical direction.

[0020] The horizontal width is determined by the difference between the maximum and minimum pixel coordinates of the text unit's bounding box in the horizontal direction, and the vertical height is determined by the difference between the maximum and minimum pixel coordinates of the text unit's bounding box in the vertical direction.

[0021] Preferably, the process of acquiring knowledge vectors includes:

[0022] A deep neural network encoder is used to perform feature mapping on the preprocessed text sequence to generate semantic vectors;

[0023] The system identifies target entity items of a pre-defined type from a pre-processed text sequence to obtain entity information, and extracts the corresponding vector embedding representations of the entity information to generate entity features.

[0024] The subgraph matching logic maps entity information to the corresponding target node in the preset domain knowledge graph. It retrieves and extracts the set of first-order adjacent nodes of the target node and the set of edge labels connecting the target node and the set of first-order adjacent nodes. The subgraph matching logic is as follows: it retrieves nodes in the domain knowledge graph whose semantic overlap with the entity information is higher than the preset overlap threshold as target nodes.

[0025] The target node, the set of first-order adjacent nodes, and the set of edge labels are converted into numerical tensors, and mean pooling is performed on the numerical tensors to generate knowledge vectors.

[0026] Preferably, the process of extracting spatial vectors and generating feature matrices through a multi-head attention layer includes:

[0027] The horizontal pixel displacement distance between the horizontal pixel coordinates of the center point of each text unit in the preprocessed text sequence and the vertical pixel displacement distance between the vertical pixel coordinates of the center point are calculated respectively. When the horizontal pixel displacement distance and the vertical pixel displacement distance between two text units are both less than the corresponding preset distance threshold, an undirected edge connection relationship is established between the two text units, and a spatial topology graph composed of a node set and an adjacency matrix is ​​generated.

[0028] The spatial topology graph is input into a graph convolutional neural network. The graph convolutional neural network uses semantic vectors as node features, performs feature convolution operations on the adjacency matrix and node features to aggregate the neighborhood features of text units in the page layout, and performs global feature aggregation processing on the result of the feature convolution operation to output a spatial vector.

[0029] The semantic vector, knowledge vector, and spatial vector are concatenated along the feature dimension using cascaded concatenation logic to generate a feature matrix to be fused.

[0030] A multi-head attention layer is used to perform adaptive weight allocation and feature aggregation on the feature matrix to be fused, thereby generating the feature matrix.

[0031] Preferably, the process of obtaining the optimized error detection parameters and correction parameters includes:

[0032] The feature matrix is ​​processed using data augmentation logic to generate positive augmented samples and negative interference samples;

[0033] The feature matrix is ​​processed using random noise injection logic and feature shifting logic to generate positively enhanced samples;

[0034] The feature matrix is ​​processed using feature masking logic and feature permutation logic to generate negative interference samples;

[0035] The feature matrix, positive enhancement samples, and negative interference samples are input into the sequence error detection model and the semantic correction model to be trained.

[0036] By establishing a contrast constraint function, the contrast loss values ​​of the feature matrix, positive augmented samples, and negative interference samples in the vector space are calculated using the contrast constraint function. The Euclidean distance between the feature matrix and the positive augmented samples is the positive similarity score, and the Euclidean distance between the feature matrix and the negative interference samples is the negative similarity score.

[0037] Gradient update operations are performed on the sequence error detection model and the semantic correction model using the contrastive loss value to obtain the optimized error detection parameters and correction parameters.

[0038] By using contrastive loss values ​​to constrain the sequence error detection model and the semantic correction model, the Euclidean distance between the feature matrix and the positively augmented samples is reduced in the vector space.

[0039] By using contrastive loss values ​​to constrain the sequence error detection model and the semantic correction model, the Euclidean distance between the feature matrix and the negative interference samples is expanded in the vector space.

[0040] Preferably, the process of outputting the error detection distribution includes:

[0041] The sequence error detection model loads error detection parameters and uses a bidirectional long short-term memory network architecture to perform sequence feature modeling processing on the feature matrix, extracting the temporal correlation features of the feature matrix in the time step dimension, including the forward hidden state sequence, the backward hidden state sequence, and the bidirectional hidden state sequence;

[0042] By utilizing forward long short-term memory network units to perform recursive calculations from the first time step to the last time step of the feature matrix, a forward hidden state sequence is generated;

[0043] The backward long short-term memory network unit is used to perform recursive calculations from the last time step to the first time step of the feature matrix to generate the backward hidden state sequence;

[0044] By concatenating the forward hidden state sequence and the backward hidden state sequence at the corresponding time step, a bidirectional hidden state sequence is generated;

[0045] The sequence error detection model uses an error detection classification layer to perform a linear mapping operation on the bidirectional hidden state sequence to generate a feature score vector. It then calculates the ratio of the exponent value of each element in the feature score vector to the sum of the exponent values ​​of all elements in the feature score vector, generating the probability of each text unit in the preprocessed text sequence belonging to the error category and the probability of belonging to the correct category, thus forming the error detection distribution.

[0046] Preferably, the process of outputting the correction distribution includes:

[0047] The semantic correction model loads correction parameters and uses a transformer architecture to perform multi-layer self-attention encoding on the feature matrix to extract long-distance semantic dependency features of the preprocessed text sequence;

[0048] The feature matrix is ​​projected onto the query subspace, key subspace, and value subspace using linear transformation logic, respectively, generating the query vector matrix, key vector matrix, and value vector matrix.

[0049] The product of the query vector matrix and the transpose of the key vector matrix is ​​calculated to obtain the original attention score matrix. The original attention score matrix is ​​then scaled using the arithmetic square root of the preset feature dimension values. A normalized exponential operation is then performed on the scaled original attention score matrix to determine the weight distribution. The weight distribution is then used to perform a weighted aggregation calculation on the value vector matrix to obtain long-distance semantic dependency features.

[0050] A feedforward neural network is used to perform nonlinear mapping on long-range semantically dependent features to generate a bias-correcting intermediate feature matrix.

[0051] The semantic correction model uses a correction classification layer to perform a linear transformation on the correction intermediate feature matrix to generate a word list score vector. It also calculates the ratio of the index value of each element in the word list score vector to the sum of the index values ​​of all elements in the word list score vector. This generates the predicted probability of each candidate character in the preset candidate word list vector space corresponding to each text unit in the preprocessed text sequence, thus forming the correction distribution.

[0052] Preferably, the process of outputting consistency scores includes:

[0053] The system uses entity matching logic to search for historical records in a pre-defined global memory that match the name and category of the current entity information. It then extracts the historical entity features stored in the historical records, which are the entity features corresponding to each historical time step in the preprocessed text sequence before the current processing node.

[0054] Calculate the vector dot product of the current entity features and the historical entity features, and calculate the product of the L2 norm of the current entity features and the L2 norm of the historical entity features. Use the ratio of the vector dot product to the product to determine the consistency score.

[0055] The consistency score is compared with a preset safety threshold. When the consistency score is lower than the safety threshold, it is determined that there is a risk of logical inconsistency in the preprocessed text sequence, and a logical conflict alarm command is output.

[0056] The current entity features and corresponding current entity information are stored in the global memory as a historical record for subsequent verification processes.

[0057] Preferably, the process of determining the proofreading results and the probability of error prediction, and statistically analyzing the error distribution includes:

[0058] The probability of each text unit belonging to the error category in the error detection distribution is extracted as the error detection probability. The prediction probability of the candidate character with the highest prediction probability in the candidate word vector space corresponding to each text unit in the correction distribution is extracted as the correction probability. The error detection probability, correction probability and consistency score are linearly weighted and summed using preset weight allocation parameters to generate the error prediction probability corresponding to each text unit.

[0059] Non-maximum suppression is applied to the erroneous prediction probability to determine the correction result;

[0060] By comparing the error prediction probability of each text unit with a preset judgment logic threshold, text units with error prediction probabilities higher than the judgment logic threshold are selected as the set to be corrected.

[0061] The text units in the correction set are sorted in descending order of their error prediction probability.

[0062] Within a preset local neighborhood, for text units with overlapping positions in the set to be corrected, all text units in the set to be corrected except for the text unit with the highest misprediction probability value are removed, and the text unit with the highest misprediction probability value is retained as the error point;

[0063] The error location and the candidate character with the highest predicted probability are determined as the proofreading result.

[0064] Statistical analysis of error distribution, outputting a list of text correction suggestions and an error distribution heatmap;

[0065] Summarize the proofreading results in the preprocessed text sequence and generate a list of text correction suggestions, including the location of errors, the content of errors, and suggested corrections, according to the order of the text units in the preprocessed text sequence;

[0066] Extract the spatial distribution coordinates corresponding to each text unit in the preprocessed text sequence, and map the error prediction probability corresponding to each text unit to the positions corresponding to the horizontal and vertical pixel coordinates of the center point in the spatial distribution coordinates;

[0067] By using color depth to represent the magnitude of the error prediction probability and combining it with spatial distribution coordinates, an error distribution heatmap is generated that represents the error density distribution characteristics of a document page.

[0068] A deep learning-based intelligent text proofreading system, used to implement the above methods, includes:

[0069] The heterogeneous processing module is used to collect and preprocess the text sequence data and page image data to be proofread, and to obtain the preprocessed text sequence and its corresponding spatial distribution coordinates;

[0070] The feature integration module is used to extract semantic vectors, entity information, and entity features from the preprocessed text sequence. It performs subgraph matching between the entity information and the preset domain knowledge graph to obtain knowledge vectors. It constructs a spatial topology graph based on spatial distribution coordinates, inputs it into a graph convolutional neural network to extract spatial vectors, and generates a feature matrix through a multi-head attention layer.

[0071] The contrast constraint module is used to introduce a supervised contrastive learning strategy. By establishing a contrast constraint function, the sequence error detection model and the semantic correction model are trained to obtain the optimized error detection parameters and correction parameters.

[0072] The sequence error detection module is used to load error detection parameters into the sequence error detection model. It employs a bidirectional long short-term memory network architecture to calculate the feature matrix and output the error detection distribution.

[0073] The logical correction module is used to load correction parameters into the semantic correction model, calculate the feature matrix using a transformer architecture, and output the correction distribution.

[0074] The memory verification module is used to perform cosine similarity comparison between entity features and a preset global memory, and output a consistency score;

[0075] The decision fusion module performs weighted fusion operations and non-maximum suppression on the error detection distribution, correction distribution, and consistency score to determine the proofreading results and the probability of error prediction, and statistically analyzes the error distribution.

[0076] The beneficial effects of this invention are:

[0077] This invention utilizes an image acquisition unit to identify physical page image data and combines it with a graph convolutional neural network to extract spatial vectors. In conjunction with knowledge vectors obtained through domain knowledge graph matching, it achieves semantic perception of nonlinear layout and accurate alignment of vertical domain professional terms, eliminating the impact of physical spatial layout interference and lack of industry professional background on proofreading results.

[0078] This invention achieves document-level global consistency verification across paragraphs and pages by constructing a global memory and performing cosine similarity comparison of entity features. This solves the problems of inconsistent entity descriptions and content logic conflicts in the long text proofreading process, and ensures the logical rigor of the overall document content.

[0079] This invention introduces a supervised contrastive learning strategy, establishes a contrastive constraint function, and constructs an architecture consisting of a sequence error detection model and a semantic correction model. This enables accurate differentiation of similar-looking and similar-sounding confused characters in the feature space, improves the computational accuracy of the error detection distribution and the correction distribution, and solves the problems of low recognition accuracy of subtle confused characters and insufficient model robustness. Attached Figure Description

[0080] Figure 1 This is a flowchart illustrating the method of the present invention;

[0081] Figure 2 This is a schematic diagram of the modules of the system of the present invention;

[0082] Figure 3 This is a schematic diagram of the spatial topology sensing process during the verification process of this invention;

[0083] Figure 4 This is a schematic diagram illustrating the supervised comparison learning optimization process during the verification of this invention.

[0084] Figure 5 This is a schematic diagram of the weighted fusion operation and result output during the verification process of this invention. Detailed Implementation

[0085] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings.

[0086] Example 1: As Figure 1 As shown, the deep learning-based intelligent text proofreading method includes the following steps:

[0087] S1. Collect and preprocess the text sequence data and page image data to be proofread, and obtain the preprocessed text sequence and its corresponding spatial distribution coordinates;

[0088] S2. Extract semantic vectors, entity information, and entity features from the preprocessed text sequence. Perform subgraph matching between the entity information and the preset domain knowledge graph to obtain knowledge vectors. Construct a spatial topology graph based on spatial distribution coordinates, input it into a graph convolutional neural network, extract spatial vectors, and generate a feature matrix through a multi-head attention layer.

[0089] S3. Introduce a supervised contrastive learning strategy. By establishing a contrastive constraint function, train the sequence error detection model and the semantic correction model to obtain the optimized error detection parameters and correction parameters.

[0090] S4. The sequence error detection model loads error detection parameters, uses a bidirectional long short-term memory network architecture to calculate the feature matrix, and outputs the error detection distribution;

[0091] S5. The semantic correction model loads correction parameters, uses a transformer architecture to calculate the feature matrix, and outputs the correction distribution;

[0092] S6. Perform cosine similarity comparison between the entity features and the preset global memory, and output a consistency score;

[0093] S7. Perform weighted fusion operation and non-maximum suppression processing on the error detection distribution, correction distribution and consistency score to determine the proofreading results and error prediction probability, and statistically analyze the error distribution.

[0094] In S1, the data output port of the text capture device and the data input port of the data preprocessing unit are connected through a communication bus. The text capture device is used to acquire text sequence data, and the text sequence data is transmitted to the data preprocessing unit through the communication bus.

[0095] Text capture devices can be high-speed document scanners, intelligent document scanners, etc. For electronic documents such as PDF and Word, electronic document capture components can be used, that is, software-level text parsing plugins combined with hardware-level storage / transmission units, which can directly capture the text sequence data of electronic documents without the need for image recognition steps.

[0096] The data preprocessing unit performs noise removal, abnormal character masking, and normalization format conversion on the text sequence data to generate a preprocessed text sequence.

[0097] The image signal output terminal of the text capture device and the signal receiving terminal of the image acquisition unit are connected by an electrical signal transmission line. The text capture device captures the visual information of the page to be proofread to generate page image data, and then transmits the page image data to the image acquisition unit through the electrical signal transmission line.

[0098] The image acquisition unit is an image sensor or camera with OCR (Optical Character Recognition) function. It can use existing integrated OCR image sensors, embedded OCR sensor modules, or camera modules with integrated OCR function. Taking the embedded OCR sensor module as an example, it integrates hardware modules for optical imaging, character recognition algorithms, and data output interfaces, and can be directly embedded into intelligent scanning and proofreading workstations, mobile proofreading terminals, etc.

[0099] The image acquisition unit performs pixel enhancement, geometric correction and noise reduction on the page image data to identify text units and extract the spatial distribution coordinates corresponding to the preprocessed text sequence. The spatial distribution coordinates include the horizontal and vertical pixel coordinates of the center point of the text unit, as well as the horizontal width and vertical height of the bounding box.

[0100] The center point mapping logic is used to determine the horizontal and vertical pixel coordinates of the center point of the text unit in the spatial distribution coordinates. The center point mapping logic is to determine the horizontal pixel coordinates by using the arithmetic mean of the minimum and maximum pixel coordinates of the bounding box of the text unit in the horizontal direction, and to determine the vertical pixel coordinates by using the arithmetic mean of the minimum and maximum pixel coordinates of the bounding box of the text unit in the vertical direction.

[0101] The horizontal width and vertical height of the bounding box in the spatial distribution coordinates are determined by using geometric dimension mapping logic. The geometric dimension mapping logic is to determine the horizontal width by using the difference between the maximum and minimum pixel coordinate values ​​of the bounding box of the text unit in the horizontal direction, and to determine the vertical height by using the difference between the maximum and minimum pixel coordinate values ​​of the bounding box of the text unit in the vertical direction.

[0102] In S2, a deep neural network encoder is used to perform feature mapping on the preprocessed text sequence to generate semantic vectors.

[0103] The system identifies target entity items of a preset type from a preprocessed text sequence to obtain entity information, and extracts the vector embedding representations corresponding to the entity information to generate entity features.

[0104] The subgraph matching logic maps entity information to the corresponding target node in the preset domain knowledge graph. It retrieves and extracts the set of first-order adjacent nodes of the target node and the set of edge labels connecting the target node and the set of first-order adjacent nodes. The subgraph matching logic is as follows: retrieve nodes in the domain knowledge graph whose semantic overlap with the entity information is higher than the preset overlap threshold as target nodes.

[0105] The target node, the set of first-order adjacent nodes, and the set of edge labels are converted into numerical tensors, and mean pooling is performed on the numerical tensors to generate knowledge vectors.

[0106] The horizontal pixel displacement distance between the horizontal pixel coordinates of the center point of each text unit in the preprocessed text sequence and the vertical pixel displacement distance between the vertical pixel coordinates of the center point are calculated respectively. When the horizontal pixel displacement distance and the vertical pixel displacement distance between two text units are both less than the corresponding preset distance threshold, an undirected edge connection relationship is established between the two corresponding text units, and a spatial topology graph composed of a node set and an adjacency matrix I is generated.

[0107] Further consideration could be given to using dynamic distance thresholds to generate spatial topology maps, accurately distinguishing the relationships between text units at different layout levels, and improving the accuracy of the spatial topology maps. The method would be as follows:

[0108] For each text unit in the preprocessed text sequence, the extended function of the image acquisition unit is used to identify the type attributes and font size parameters of the text unit. The type attributes of the text unit include headings, body text, footnotes, and table text.

[0109] A preset type-font size-threshold mapping table stores the horizontal and vertical distance thresholds corresponding to different type attributes and font size parameters. The font size parameter and the distance threshold are positively correlated.

[0110] Based on the type attribute and font size parameter of each text unit, the corresponding dynamic horizontal distance threshold and dynamic vertical distance threshold are matched from the type-font size-threshold mapping table.

[0111] Calculate the horizontal and vertical pixel displacement distances between two text units. When the horizontal pixel displacement distance is less than the dynamic horizontal distance threshold and the vertical pixel displacement distance is less than the dynamic vertical distance threshold, establish an undirected edge connection between the two text units and generate a spatial topology graph.

[0112] The spatial topology graph is input into a graph convolutional neural network, which uses semantic vectors as node features. For the adjacency matrix I and node features Perform feature convolution operations to aggregate neighborhood features of text units within the page layout, and perform global feature aggregation processing on the results of the feature convolution operations to output a spatial vector. Where W represents the preset learnable weight matrix, This represents a non-linear activation function.

[0113] The semantic vector V, knowledge vector K, and spatial vector G are concatenated along the feature dimension using cascade concatenation logic to generate a feature matrix to be fused.

[0114] A multi-head attention layer is used to perform adaptive weight allocation and feature aggregation on the feature matrix to be fused, generating the feature matrix. ,in, Represents the semantic feature weight coefficients. Represents the knowledge feature weight coefficient. The spatial feature weight coefficients are obtained by calculating the correlation scores of the feature matrix to be fused in different feature subspaces through a multi-head attention layer.

[0115] In S3, data augmentation logic is used to process the feature matrix and generate positive augmentation samples and negative interference samples.

[0116] The feature matrix is ​​processed using random noise injection logic and feature translation logic to generate positively enhanced samples.

[0117] The feature matrix is ​​processed using feature masking logic and feature permutation logic to generate negative interference samples.

[0118] The feature matrix, positive enhancement samples, and negative interference samples are input into the sequence error detection model and the semantic error correction model to be trained.

[0119] By establishing a contrast constraint function, the contrast loss values ​​of the feature matrix, positive augmentation samples, and negative interference samples in the vector space are calculated using the contrast constraint function. The Euclidean distance between the feature matrix and the positively augmented samples is the positive similarity score. The Euclidean distance between the feature matrix and the negative interference samples is the negative similarity score. , This represents the preset temperature coefficient, where e is the natural constant.

[0120] Gradient update operations are performed on the sequence error detection model and the semantic correction model using the contrastive loss value to obtain the optimized error detection parameters and correction parameters.

[0121] By using contrastive loss values ​​to constrain the sequence error detection model and the semantic correction model, the Euclidean distance between the feature matrix and the positively enhanced samples is reduced in the vector space.

[0122] By using contrastive loss values ​​to constrain the sequence error detection model and the semantic correction model, the Euclidean distance between the feature matrix and the negative interference samples is expanded in the vector space.

[0123] In S4, the sequence error detection model loads error detection parameters and uses a bidirectional long short-term memory network architecture (BiLSTM) to perform sequence feature modeling processing on the feature matrix, extracting the temporal correlation features of the feature matrix in the time step dimension. The temporal correlation features include forward hidden state sequence, backward hidden state sequence and bidirectional hidden state sequence.

[0124] By utilizing forward long short-term memory network units to perform recursive calculations from the first time step to the last time step of the feature matrix, a forward hidden state sequence is generated.

[0125] The backward hidden state sequence is generated by using backward long short-term memory network units to perform recursive calculations from the last time step to the first time step of the feature matrix.

[0126] By concatenating the forward hidden state sequence and the backward hidden state sequence at the corresponding time step, a bidirectional hidden state sequence is generated.

[0127] The sequence error detection model uses an error detection classification layer to perform a linear mapping operation on the bidirectional hidden state sequence to generate a feature score vector. It then calculates the ratio of the exponent value of each element in the feature score vector to the sum of the exponent values ​​of all elements in the feature score vector, generating the probability of each text unit in the preprocessed text sequence belonging to the error category and the probability of belonging to the correct category, thus forming the error detection distribution.

[0128] In S5, the semantic correction model loads correction parameters and uses a transformer architecture (e.g., Transformer) to perform multi-layer self-attention encoding on the feature matrix to extract long-distance semantic dependency features of the preprocessed text sequence.

[0129] The feature matrix is ​​projected onto the query subspace, key subspace, and value subspace using linear transformation logic, respectively, to generate the query vector matrix, key vector matrix, and value vector matrix.

[0130] The product of the query vector matrix and the transpose of the key vector matrix is ​​calculated to obtain the original attention score matrix. The original attention score matrix is ​​scaled using the arithmetic square root of the preset feature dimension values. The scaled original attention score matrix is ​​then normalized exponentially to determine the weight distribution. The weight distribution is used to perform weighted aggregation calculation on the value vector matrix to obtain long-distance semantic dependency features.

[0131] A feedforward neural network is used to perform nonlinear mapping on long-distance semantically dependent features to generate a correction intermediate feature matrix.

[0132] The semantic correction model uses a correction classification layer to perform a linear transformation on the correction intermediate feature matrix to generate a word list score vector. It also calculates the ratio of the index value of each element in the word list score vector to the sum of the index values ​​of all elements in the word list score vector. This generates the predicted probability of each candidate character in the preset candidate word list vector space corresponding to each text unit in the preprocessed text sequence, thus forming the correction distribution.

[0133] In S6, entity matching logic is used to search for historical records in the preset global memory that match the name and category of the current entity information. The historical entity features stored in the historical records are extracted. The historical entity features are the entity features corresponding to each historical time step in the preprocessed text sequence before the current processing node.

[0134] A global consistency memory (GCM) can be a persistent storage system built on a vector database (such as Faiss, Milvus, or Elasticsearch). Its data structure includes entity ID, entity name, entity category, entity feature vector (a high-dimensional dense vector generated by a deep neural network encoder), domain labels (such as subject area, industry classification, and text type), and a timestamp field. The GCM can adopt an incremental update mechanism. After each entity feature extraction, the current entity features are compared with the historical records using cosine similarity. If the consistency score is lower than the safety threshold, a logical conflict alarm is triggered. At the same time, the new entity feature vector is dynamically fused and updated to the feature center of the corresponding domain using a mini-batch gradient descent algorithm, achieving document-level global consistency verification across paragraphs and pages.

[0135] Calculate the vector dot product of the current entity features and the historical entity features, and calculate the product of the L2 norm of the current entity features and the L2 norm of the historical entity features. Use the ratio of the vector dot product to the product to determine the consistency score.

[0136] The consistency score is compared with the preset safety threshold. When the consistency score is lower than the safety threshold, it is determined that there is a risk of logical inconsistency in the preprocessed text sequence, and a logical conflict alarm command is output.

[0137] The current entity features and corresponding current entity information are stored in the global memory as a historical record for subsequent verification processes.

[0138] When obtaining the consistency score, domain-adaptive dynamic optimization logic can be added to achieve adaptive optimization of the global memory, specifically:

[0139] A domain label field is added to the preset global memory. The domain label field is used to store the domain information corresponding to the features of each historical entity. The domain information includes the subject area, industry area and text type.

[0140] Calculate the cosine similarity between the domain feature vector of the current entity information and the domain feature vectors of each historical entity in the global memory, generate a domain matching score, and assign dynamic weights to historical entity features based on the domain matching score. The higher the domain matching score, the larger the weight coefficient of the corresponding historical entity feature.

[0141] An incremental learning triggering mechanism is introduced. When the number of historical entity features in the same domain in the global memory exceeds the preset update threshold, the mini-batch gradient descent algorithm is used to iteratively update the historical entity feature vectors in the global memory. The updated entity feature vector is the weighted fusion result of the newly added entity features and the original historical entity features.

[0142] An additional domain confusion verification step is added, which calculates the average similarity between the current entity features and cross-domain historical entity features. If the average similarity is higher than the preset confusion threshold, it is determined that there is a risk of domain confusion, outputs a domain differentiation prompt, and blocks the interference of cross-domain historical entity features on the consistency score.

[0143] In S7, the probability that each text unit belongs to the error category in the error detection distribution is extracted as the error detection probability. Extract the prediction probability of the candidate character with the highest prediction probability in the candidate word vector space corresponding to each text unit in the correction distribution, and use it as the correction probability. Using preset weighting parameters to assign error detection probability Correction probability The consistency score S is calculated using a linear weighted summation to generate the error prediction probability for each text unit. ,in, , , These represent the preset error detection probabilities. Correction probability And the weighting parameters for the consistency score S.

[0144] Non-maximum suppression is applied to the erroneous prediction probability to determine the correction result.

[0145] By comparing the error prediction probability of each text unit with the preset judgment logic threshold, text units with error prediction probabilities higher than the judgment logic threshold are selected as the set to be corrected.

[0146] The text units in the correction set are sorted in descending order of their error prediction probability.

[0147] Within a preset local neighborhood, for text units that overlap in the set to be corrected, remove all text units except the one with the highest error prediction probability, and retain the text unit with the highest error prediction probability as the error point.

[0148] The error location and the candidate character with the highest predicted probability are determined as the proofreading result.

[0149] Statistically analyze the error distribution, output a list of text correction suggestions, and an error distribution heatmap.

[0150] Summarize the proofreading results in the preprocessed text sequence and generate a list of text correction suggestions containing the error location, error content, and correction suggestions according to the order of each text unit in the preprocessed text sequence.

[0151] Extract the spatial distribution coordinates corresponding to each text unit in the preprocessed text sequence, and map the error prediction probability corresponding to each text unit to the position corresponding to the horizontal and vertical pixel coordinates of the center point in the spatial distribution coordinates.

[0152] By using color depth to represent the magnitude of the error prediction probability and combining it with spatial distribution coordinates, an error distribution heatmap is generated that represents the error density distribution characteristics of a document page.

[0153] Example 2: As Figure 2 As shown, the deep learning-based intelligent text proofreading system is used to implement the method in Example 1. It includes a heterogeneous processing module, a feature integration module, a comparison constraint module, a sequence error detection module, a logic correction module, a memory verification module, and a decision fusion module. The modules are electrically connected to each other.

[0154] The heterogeneous processing module is used to collect and preprocess the text sequence data and page image data to be proofread, and to obtain the preprocessed text sequence and its corresponding spatial distribution coordinates.

[0155] The feature integration module is used to extract semantic vectors, entity information and entity features from the preprocessed text sequence. It performs subgraph matching between the entity information and the preset domain knowledge graph to obtain knowledge vectors. It constructs a spatial topology graph based on the spatial distribution coordinates, inputs it into the graph convolutional neural network, extracts spatial vectors, and generates a feature matrix through a multi-head attention layer.

[0156] The contrast constraint module is used to introduce a supervised contrastive learning strategy. By establishing a contrast constraint function, the sequence error detection model and the semantic correction model are trained to obtain the optimized error detection parameters and correction parameters.

[0157] The sequence error detection module is used to load error detection parameters into the sequence error detection model. It uses a bidirectional long short-term memory network architecture to calculate the feature matrix and output the error detection distribution.

[0158] The logical correction module is used to load correction parameters into the semantic correction model, and uses a transformer architecture to calculate the feature matrix and output the correction distribution.

[0159] The memory verification module is used to perform cosine similarity comparison between entity features and a preset global memory, and output a consistency score.

[0160] The decision fusion module is used to perform weighted fusion operations and non-maximum suppression processing on the error detection distribution, correction distribution and consistency score to determine the proofreading results and error prediction probability, and to statistically analyze the error distribution.

[0161] The specific implementation details of each module are the same as in Example 1. This system can be integrated into platforms such as intelligent scanning and proofreading workstations, mobile proofreading terminals, intelligent proofreading all-in-one machines for publishing houses, and intelligent proofreading systems for digitized archives for practical applications. Taking the intelligent scanning and proofreading workstation as an example, the hardware components of the intelligent scanning and proofreading workstation include a high-speed document scanner (text capture device), an embedded image acquisition unit, an edge computing processing unit, and a touch screen. The scanner acquires image data of paper documents, the image acquisition unit completes pixel enhancement and geometric correction processing, and extracts the spatial distribution coordinates of text units; the edge computing unit has built-in heterogeneous processing modules, feature integration modules, etc., and can locally complete the construction of spatial topology maps and semantic vector extraction, and directly output error distribution heatmaps and correction lists on the touch screen.

[0162] The verification process is as follows:

[0163] Based on the system in this embodiment, it has the ability to perform high-precision text error detection, semantic correction, and logical verification even under the background of non-linear typesetting interference, lack of industry professional background, and inconsistency in long text logic.

[0164] Using a preprocessed text sequence containing 10 text units as the verification object, and a pre-defined domain knowledge graph and global memory as the logical verification benchmark, the verification results are as follows: Figures 3 to 5 As shown.

[0165] Figure 3 For the spatial topology perception process in the feature integration stage, the heterogeneous processing module extracts the spatial distribution coordinates corresponding to the preprocessed text sequence, and determines the center point pixel coordinates of each of the 10 text units according to the center point mapping logic. It demonstrates the process of calculating the horizontal and vertical pixel displacement distances between each text unit using the topology construction logic. When both the horizontal and vertical pixel displacement distances are less than the preset distance threshold, an undirected edge connection is established between the corresponding two text units, generating a spatial topology graph composed of 10 nodes. The graph convolutional neural network is used to perform feature convolution operations on the spatial topology graph to aggregate the neighborhood features of the text units in the page layout and output spatial vectors. This effectively solves the technical problem of the traditional linear text sequence model's contextual understanding being broken under complex layout.

[0166] Figure 4To illustrate the process of supervised contrastive learning optimization for the contrast constraint module (Dim A represents feature dimension A, Dim B represents feature dimension B), a supervised contrastive learning strategy is introduced. This strategy utilizes random noise injection, feature translation, feature masking, and feature permutation logic to process the feature matrix, demonstrating the phenomenon of dynamically adjusting the feature distribution within the feature space using a contrast constraint function. Specifically, the anchor text features are located at the coordinate center. Through training, the Euclidean distance between the feature matrix and positively enhanced samples continuously decreases in the vector space, while the Euclidean distance with negative interference samples (i.e., similar-looking or similar-sounding confused characters) is significantly increased (manifested as...). Figure 4 The red crosses representing negative interference samples are pushed towards the edge of the feature space. This process verifies the system's ability to accurately distinguish subtle confusing characters at the microscopic level.

[0167] Figure 5 The system summarizes the error detection distribution output by the sequence error detection module, the correction distribution output by the semantic correction module, and the consistency score output by the memory verification module. It demonstrates the mapping result of the error prediction probability calculated by the weighted fusion logic on the spatial distribution coordinates. By performing non-maximum suppression processing, the system retains the text unit with the highest error prediction probability as the error point. Figure 5 In the process, because the consistency score of the 10th text unit in the global memory verification was lower than the preset safety threshold, a logical conflict alarm was triggered, which caused the error prediction probability of the 10th text unit to increase significantly. The 10th text unit was shown as a dark red area in the error distribution heatmap, and a list of text correction suggestions (proofreading conclusion) containing correction suggestions was output simultaneously.

[0168] As can be seen from the above verification process, the system in this embodiment effectively solves the problems of physical layout interference and document content logical conflicts by combining spatial layout awareness, domain knowledge enhancement and cross-paragraph global consistency verification. Through supervised comparison learning strategy, it ensures robustness in recognizing similar-looking and similar-sounding characters.

[0169] The deep learning-based intelligent text proofreading system proposed in this embodiment demonstrates excellent feature modeling and logical correction capabilities in handling multimodal heterogeneous text proofreading tasks. At the same time, through multi-module electrical signal connection and collaborative operation, a proofreading system with spatial location topology awareness capability is constructed, which has high practical application value.

Claims

1. A deep learning-based intelligent text proofreading method, characterized in that, Includes the following steps: Collect and preprocess the text sequence data and page image data to be proofread, and obtain the preprocessed text sequence and its corresponding spatial distribution coordinates; Semantic vectors, entity information, and entity features are extracted from the preprocessed text sequence. Subgraph matching is performed between the entity information and the pre-defined domain knowledge graph to obtain knowledge vectors. A spatial topology graph is constructed based on the spatial distribution coordinates, input into the graph convolutional neural network, spatial vectors are extracted, and a feature matrix is ​​generated through a multi-head attention layer. A supervised contrastive learning strategy is introduced. By establishing a contrastive constraint function, a sequence error detection model and a semantic correction model are trained to obtain optimized error detection and correction parameters. The process includes: The feature matrix is ​​processed using data augmentation logic to generate positive augmented samples and negative interference samples; The feature matrix is ​​processed using random noise injection logic and feature translation logic to generate positively enhanced samples; The feature matrix is ​​processed using feature masking logic and feature permutation logic to generate negative interference samples; The feature matrix, positive enhancement samples, and negative interference samples are input into the sequence error detection model and the semantic correction model to be trained. By establishing a contrast constraint function, the contrast loss value of the feature matrix, positive augmentation sample and negative interference sample in the vector space is calculated using the contrast constraint function. The Euclidean distance between the feature matrix and the positive augmentation sample is the positive similarity score, and the Euclidean distance between the feature matrix and the negative interference sample is the negative similarity score. Gradient update operations are performed on the sequence error detection model and the semantic correction model using the contrastive loss value to obtain the optimized error detection parameters and correction parameters. By using contrastive loss values ​​to constrain the sequence error detection model and the semantic correction model, the Euclidean distance between the feature matrix and the positively enhanced samples is reduced in the vector space. By using contrastive loss values ​​to constrain sequence error detection and semantic correction models, the Euclidean distance between the feature matrix and negative interference samples is increased in the vector space. The sequence error detection model loads error detection parameters, uses a bidirectional long short-term memory network architecture to calculate the feature matrix, and outputs the error detection distribution. The semantic correction model loads correction parameters, uses a transformer architecture to calculate the feature matrix, and outputs the correction distribution. The entity features are compared with the pre-defined global memory using cosine similarity, and a consistency score is output. Weighted fusion operations and non-maximum suppression processing are performed on the error detection distribution, correction distribution, and consistency score to determine the proofreading results and error prediction probability, and the error distribution is statistically analyzed.

2. The deep learning-based intelligent text proofreading method according to claim 1, characterized in that, The process of obtaining the preprocessed text sequence and its corresponding spatial distribution coordinates includes: The text capture device's data output port and the data input port of the data preprocessing unit are connected via a communication bus. The text capture device acquires text sequence data and transmits the text sequence data to the data preprocessing unit via the communication bus. The data preprocessing unit performs noise removal, abnormal character masking, and normalization format conversion on the text sequence data to generate a preprocessed text sequence. The image signal output end of the text capture device and the signal receiving end of the image acquisition unit are connected by an electrical signal transmission line. The text capture device captures the visual information of the page to be proofread to generate page image data, and transmits the page image data to the image acquisition unit through the electrical signal transmission line. The image acquisition unit performs pixel enhancement, geometric correction and noise reduction on the page image data, identifies text units, and extracts the spatial distribution coordinates corresponding to the preprocessed text sequence, including the horizontal and vertical pixel coordinates of the center point of the text unit, as well as the horizontal width and vertical height of the bounding box. The horizontal pixel coordinates are determined by the arithmetic mean of the minimum and maximum pixel coordinates of the bounding box of the text unit in the horizontal direction, and the vertical pixel coordinates are determined by the arithmetic mean of the minimum and maximum pixel coordinates of the bounding box of the text unit in the vertical direction. The horizontal width is determined by the difference between the maximum and minimum pixel coordinates of the text unit's bounding box in the horizontal direction, and the vertical height is determined by the difference between the maximum and minimum pixel coordinates of the text unit's bounding box in the vertical direction.

3. The deep learning-based intelligent text proofreading method according to claim 1, characterized in that, The process of obtaining knowledge vectors includes: A deep neural network encoder is used to perform feature mapping on the preprocessed text sequence to generate semantic vectors. Identify target entity items of a preset type from a preprocessed text sequence to obtain entity information, and extract the vector embedding representations corresponding to the entity information to generate entity features; The subgraph matching logic maps entity information to the corresponding target node in the preset domain knowledge graph. It retrieves and extracts the set of first-order adjacent nodes of the target node and the set of edge labels connecting the target node and the set of first-order adjacent nodes. The subgraph matching logic is: retrieve nodes in the domain knowledge graph whose semantic overlap with the entity information is higher than the preset overlap threshold as target nodes. The target node, the set of first-order adjacent nodes, and the set of edge labels are converted into numerical tensors, and mean pooling is performed on the numerical tensors to generate knowledge vectors.

4. The deep learning-based intelligent text proofreading method according to claim 2, characterized in that, The process of extracting spatial vectors and generating feature matrices through a multi-head attention layer includes: The horizontal pixel displacement distance between the horizontal pixel coordinates of the center point of each text unit in the preprocessed text sequence and the vertical pixel displacement distance between the vertical pixel coordinates of the center point are calculated respectively. When the horizontal pixel displacement distance and the vertical pixel displacement distance between two text units are both less than the corresponding preset distance threshold, an undirected edge connection relationship is established between the two corresponding text units to generate a spatial topology graph composed of a node set and an adjacency matrix. The spatial topology graph is input into the graph convolutional neural network. The graph convolutional neural network uses semantic vectors as node features, performs feature convolution operations on the adjacency matrix and node features to aggregate the neighborhood features of text units in the page layout, and performs global feature aggregation processing on the result of the feature convolution operation to output a spatial vector. The semantic vector, knowledge vector, and spatial vector are concatenated along the feature dimension using cascaded concatenation logic to generate a feature matrix to be fused. A multi-head attention layer is used to perform adaptive weight allocation and feature aggregation on the feature matrix to be fused, thereby generating the feature matrix.

5. The deep learning-based intelligent text proofreading method according to claim 1, characterized in that, The process of outputting the error detection distribution includes: The sequence error detection model loads error detection parameters and uses a bidirectional long short-term memory network architecture to perform sequence feature modeling processing on the feature matrix, extracting the temporal correlation features of the feature matrix in the time step dimension, including forward hidden state sequence, backward hidden state sequence and bidirectional hidden state sequence. By utilizing forward long short-term memory network units to perform recursive calculations from the first time step to the last time step of the feature matrix, a forward hidden state sequence is generated. The backward hidden state sequence is generated by using backward long short-term memory network units to perform recursive calculations from the last time step to the first time step of the feature matrix. By concatenating the forward hidden state sequence and the backward hidden state sequence at the corresponding time step, a bidirectional hidden state sequence is generated. The sequence error detection model uses an error detection classification layer to perform a linear mapping operation on the bidirectional hidden state sequence to generate a feature score vector. It then calculates the ratio of the exponent value of each element in the feature score vector to the sum of the exponent values ​​of all elements in the feature score vector, generating the probability of each text unit in the preprocessed text sequence belonging to the error category and the probability of belonging to the correct category, thus forming the error detection distribution.

6. The deep learning-based intelligent text proofreading method according to claim 1, characterized in that, The process of outputting the correction distribution includes: The semantic correction model loads correction parameters and uses a transformer architecture to perform multi-layer self-attention encoding on the feature matrix to extract long-distance semantic dependency features of the preprocessed text sequence. The feature matrix is ​​projected onto the query subspace, key space, and value subspace using linear transformation logic, respectively, to generate the query vector matrix, key vector matrix, and value vector matrix. The product of the query vector matrix and the transpose of the key vector matrix is ​​calculated to obtain the original attention score matrix. The original attention score matrix is ​​scaled using the arithmetic square root of the preset feature dimension values. The scaled original attention score matrix is ​​then normalized exponentially to determine the weight distribution. The weight distribution is used to perform weighted aggregation calculation on the value vector matrix to obtain long-distance semantic dependency features. A feedforward neural network is used to perform nonlinear mapping processing on long-distance semantically dependent features to generate a bias-correcting intermediate feature matrix. The semantic correction model uses a correction classification layer to perform a linear transformation on the correction intermediate feature matrix to generate a word list score vector. It also calculates the ratio of the index value of each element in the word list score vector to the sum of the index values ​​of all elements in the word list score vector. This generates the predicted probability of each candidate character in the preset candidate word list vector space corresponding to each text unit in the preprocessed text sequence, thus forming the correction distribution.

7. The deep learning-based intelligent text proofreading method according to claim 1, characterized in that, The process of outputting consistency scores includes: The entity matching logic is used to search for historical records in the preset global memory that match the name and category of the current entity information. The historical entity features stored in the historical records are extracted. The historical entity features are the entity features corresponding to each historical time step before the current processing node in the preprocessed text sequence. Calculate the vector dot product of the current entity features and the historical entity features, and calculate the product of the L2 norm of the current entity features and the L2 norm of the historical entity features. Use the ratio of the vector dot product to the product to determine the consistency score. The consistency score is compared with the preset safety threshold. When the consistency score is lower than the safety threshold, it is determined that there is a risk of logical inconsistency in the preprocessed text sequence, and a logical conflict alarm command is output. The current entity features and corresponding current entity information are stored in the global memory as a historical record for subsequent verification processes.

8. The deep learning-based intelligent text proofreading method according to claim 1, characterized in that, The process of determining the proofreading results and the probability of error prediction, and statistically analyzing the error distribution, includes: Extract the probability that each text unit belongs to the error category in the error detection distribution as the error detection probability. Extract the prediction probability of the candidate character with the highest prediction probability in the candidate word vector space corresponding to each text unit in the correction distribution as the correction probability. Perform linear weighted summation calculation on the error detection probability, correction probability and consistency score using preset weight allocation parameters to generate the error prediction probability corresponding to each text unit. Perform nonmaximum suppression on the probability of incorrect predictions to determine the correction result; By comparing the error prediction probability of each text unit with the preset judgment logic threshold, text units with error prediction probabilities higher than the judgment logic threshold are selected as the set to be corrected. The text units in the correction set are sorted in descending order of their error prediction probability; Within a preset local neighborhood, for text units that overlap in the set to be corrected, remove all text units except the one with the highest error prediction probability, and retain the text unit with the highest error prediction probability as the error point. The error location and the candidate character with the highest predicted probability are determined as the proofreading result; Statistical analysis of error distribution, outputting a list of text correction suggestions and an error distribution heatmap; Summarize the proofreading results in the preprocessed text sequence and generate a list of text correction suggestions containing the error location, error content, and correction suggestions according to the order of each text unit in the preprocessed text sequence; Extract the spatial distribution coordinates corresponding to each text unit in the preprocessed text sequence, and map the error prediction probability corresponding to each text unit to the position corresponding to the horizontal and vertical pixel coordinates of the center point in the spatial distribution coordinates; By using color depth to represent the magnitude of the error prediction probability and combining it with spatial distribution coordinates, an error distribution heatmap is generated that represents the error density distribution characteristics of a document page.

9. A deep learning-based intelligent text proofreading system, used to implement the method described in any one of claims 1-8, characterized in that, include: The heterogeneous processing module is used to collect and preprocess the text sequence data and page image data to be proofread, and to obtain the preprocessed text sequence and its corresponding spatial distribution coordinates. The feature integration module is used to extract semantic vectors, entity information and entity features from the preprocessed text sequence, perform subgraph matching between the entity information and the preset domain knowledge graph to obtain knowledge vectors, construct a spatial topology graph based on spatial distribution coordinates, input it into the graph convolutional neural network to extract spatial vectors, and generate a feature matrix through a multi-head attention layer. The contrast constraint module is used to introduce a supervised contrastive learning strategy. By establishing a contrast constraint function, the sequence error detection model and the semantic correction model are trained to obtain the optimized error detection parameters and correction parameters. The sequence error detection module is used to load error detection parameters into the sequence error detection model. It uses a bidirectional long short-term memory network architecture to calculate the feature matrix and output the error detection distribution. The logical correction module is used to load correction parameters into the semantic correction model, calculate the feature matrix using a transformer architecture, and output the correction distribution. The memory verification module is used to perform cosine similarity comparison between entity features and a preset global memory, and output a consistency score. The decision fusion module is used to perform weighted fusion operations and non-maximum suppression processing on the error detection distribution, correction distribution and consistency score to determine the proofreading results and error prediction probability, and to statistically analyze the error distribution.

Citation Information

Patent Citations

  • Paper file information input method, system, equipment and medium

    CN121170806A

  • Document content extraction method and system based on multimodal model collaboration, terminal and medium

    CN121236773A