Intelligent Chinese text error correction method integrating spelling and semantics

By employing a multi-agent parallel generation and multi-dimensional evaluation mechanism, the rigidity of existing Chinese text correction systems has been addressed, enabling efficient and personalized Chinese text correction to meet diverse user needs in different scenarios.

CN120930635AActive Publication Date: 2025-11-11YICHUANG JINGYUN DIGITAL TECH CO LTD

Patent Information

Application Number
CN202511445457.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-11
Publication Date
2025-11-11
Estimated Expiration
2045-10-11

AI Technical Summary

Technical Problem

Existing Chinese text correction systems often neglect the richness of natural language expression and the personalized needs of users when outputting results, resulting in rigid outputs that are not suitable for different scenarios.

Method used

A candidate correction set is generated in parallel by multiple agents. Combined with conflict resolution and multi-dimensional evaluation mechanisms, spelling, grammar, semantics and style agents are dynamically called. The priority of agents is set according to the error correction strictness level of the user instruction, and efficient error correction is performed through a deep learning model.

Benefits of technology

Ensuring the accuracy and diversity of error correction meets the personalized needs of different scenarios, improves the system's usability and scalability, and reduces manual intervention.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120930635A_ABST
    Figure CN120930635A_ABST
Patent Text Reader

Abstract

The invention discloses an intelligent Chinese text error correction method integrating spelling and semantics, and relates to the technical field of data processing. Comprising the following steps: S1, according to an original Chinese text to be corrected and a correction intention instruction, obtaining an original candidate correction set of each agent through parallel operation of each agent; s2, processing the original candidate correction set according to the correction intention instruction, and obtaining the score of each original candidate correction item; and S3, comparing the original candidate correction items with the comprehensive evaluation scores through a diversity optimization screening algorithm, and determining a final candidate correction item set. According to the method, the candidate correction set is generated in parallel through multiple agents and is combined with the conflict resolution and multi-dimensional evaluation mechanism, so that the accuracy of error correction can be ensured, diversified expression selections can be provided, and the problems of single and rigid output of a traditional error correction system are avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, specifically to an intelligent error correction method for Chinese text that integrates spelling and semantics. Background Technology

[0002] With the rapid development of information technology and the widespread adoption of internet applications, the frequency of Chinese text usage in scenarios such as social media, online education, e-commerce, intelligent customer service, and office automation has increased dramatically. However, due to input errors, homophone confusion, misuse of similar-looking characters, and grammatical inaccuracies, user-generated Chinese text commonly contains various errors, seriously affecting the accurate transmission of information and user experience. Therefore, intelligent error correction technology for Chinese text, as an important research direction in the field of Natural Language Processing (NLP), has received widespread attention from academia and industry.

[0003] Currently, mainstream Chinese text correction methods can be categorized into rule-based methods, statistical methods, and deep learning-based methods. Early error correction systems largely relied on manually constructed language rule bases and dictionary matching, such as using homophone lists, similar-looking character lists, or grammatical templates to identify and correct errors. These methods have high accuracy in specific domains, but their rule coverage is limited, maintenance costs are high, and they struggle to cope with the dynamic evolution and diverse expressions of language.

[0004] Chinese invention patent application CN118426600A discloses an intelligent input method system based on large language model technology. By training and optimizing a large language model, it acquires the ability to understand natural language and, combined with user input habits and contextual information, achieves accurate understanding of the user's input intent, thus improving the intelligence and accuracy of the input method. The aim is to provide users with a more efficient, intelligent, and personalized input experience.

[0005] While the above-mentioned technical solutions can improve the intelligence and accuracy of text through input prediction and intent recognition, they adopt a one-way and black-box decision-making mechanism with the goal of finding a single optimal correction. This completely ignores the inherent richness of natural language expression and the personalized needs of users for correction style, tone and applicable scenarios, resulting in output results that are often mechanically correct but context-inappropriate and rigid. Summary of the Invention

[0006] The purpose of this invention is to provide an intelligent error correction method for Chinese text that integrates spelling and semantics, so as to solve the problems mentioned in the background art.

[0007] To achieve the above objectives, the present invention provides the following technical solution: a Chinese text intelligent error correction method integrating spelling and semantics, comprising: S1: Candidate generation: Based on the original Chinese text to be corrected and the correction intention instruction, the original candidate correction set of each agent is obtained through the parallel operation of each agent; S2: Evaluation and Determination: Based on the correction intention instruction, the original candidate correction set is processed to obtain the score of each original candidate correction item in the original candidate correction set, including: S2.1: Conflict resolution: By setting arbitration rules, all original candidate modification items are classified, and the joint candidate set without conflict is retained, while the candidate set with contradiction is directly filtered. S2.2: Multi-dimensional evaluation: Based on the original candidate correction items that have been retained and screened, a comprehensive evaluation score is determined for each of the original candidate correction items through the basic correctness score, style matching score, diversity contribution score, and user historical preference matching score. S3: Screening and Determination: By using a diversity optimization screening algorithm, the original candidate correction items with the comprehensive evaluation score are compared to determine the final set of candidate correction items.

[0008] Furthermore, the original candidate correction sets for each agent are obtained, including: S1.1: Data Acquisition: The original Chinese text to be corrected and the correction intent command are obtained through the user interface module and intent parsing engine; S1.2: Level Determination: The correction intent instruction is compared with the set strategy table to determine the corresponding error correction strictness level, and the combination of intelligent agents to be invoked is determined according to the error correction strictness level. The intelligent agents include spelling intelligent agents, grammar intelligent agents, semantic intelligent agents and style intelligent agents. S1.3: Agent generation: Based on the combination of agents called, the original Chinese text to be corrected is processed to obtain the candidate correction items corresponding to each agent.

[0009] Furthermore, the error correction strictness level includes only correcting typos, optimizing expression, and complete rewriting. When the error correction strictness level is only correcting typos, the corresponding calling agent combination is a spelling agent. When the error correction strictness level is optimizing expression, the corresponding calling agent combination is a spelling agent, a grammar agent, and a semantic agent. When the error correction strictness level is complete rewriting, the corresponding calling agent combination is a spelling agent, a grammar agent, a semantic agent, and a style agent.

[0010] Furthermore, the spelling intelligence agent uses a character-level Transformer and a knowledge graph of Chinese character structure to identify misspellings that are similar in form or sound, and is used to verify the correctness of the writing of characters and words in the original Chinese text; The grammatical agent detects syntactic errors through dependency parsing and CCG models, and is used to check the grammatical compliance of the original Chinese text. Semantic agents use pre-trained language models to identify semantic contradictions and referential ambiguities, which are then used to detect the sentence representation and sentence logic of raw Chinese text. The style agent identifies expressive styles through fine-grained style control vectors, which are used to add sentence style to the original Chinese text according to user instructions.

[0011] Furthermore, this involves retaining conflict-free joint candidate sets and directly filtering conflicting candidate sets, including: S2.1.1: Identification and processing: Based on the content of the original Chinese text, determine the modification position of each candidate correction item, and classify the candidate correction items with the same modification position into the same category. At the same time, based on the modification scheme content corresponding to the candidate correction items in each category, the modification schemes with conflicting modification content are taken as the contradictory candidate set, and the modification schemes with no conflicting modification content are taken as the non-conflicting joint candidate set. S2.1.2: Initial decision-making: Based on the correction intention instruction, determine the corresponding error correction strictness, and set the agent priority according to the error correction strictness. At the same time, based on the agent priority and the agent corresponding to each candidate correction item in the conflicting candidate set, retain the candidate correction item corresponding to the agent with the highest priority. S2.1.3: Processing and re-decision: The style agent is set to the highest priority by the coordinator, and the candidate correction items corresponding to the style agent are retained. At the same time, a new candidate correction item is obtained by using a word fusion strategy based on the word combination corresponding to all candidate correction items in the category that has not been deleted.

[0012] Furthermore, when the error correction strictness level is to correct only typos, the spelling agent is set to the highest priority; when the error correction strictness level is to optimize expression, the semantic agent is set to the highest priority; and when the error correction strictness level is to completely rewrite, the style agent is set to the highest priority.

[0013] Furthermore, through the established correctness review process and basic intelligent agents, the basic correctness scores of the original candidate correction items are obtained. The basic intelligent agents include syntactic intelligent agents and semantic intelligent agents. Based on the style requirements specified by the user, a target style vector is set, and the original candidate correction items are used as input to the style analysis model. The actual style vector is obtained as the output. The style matching score of the original candidate correction items is obtained by using the cosine similarity between the target style vector and the actual style vector. Based on the words, grammar, semantics, and style of each candidate correction item, we set lexical overlap, syntactic structural similarity, semantic equivalence, and style bias to determine the diversity contribution score of the original candidate correction items. Based on the context of the original Chinese text, scene features are set, and these scene features are used as input to the user intent evolution model. The output is the predicted probability, and the user historical preference matching score of the original candidate correction item is determined.

[0014] Furthermore, the final set of candidate correction terms is determined, including: S3.1: Determine the initial candidate: Based on the original candidate correction items with the comprehensive evaluation score, compare all comprehensive evaluation scores and determine the maximum comprehensive evaluation score. The candidate correction item corresponding to the comprehensive evaluation score is the initial candidate correction item. S3.2: Determine the remaining candidates: The coordinator obtains the difference between the initial candidate correction item and the remaining candidate correction items. At the same time, the difference between each remaining candidate correction item and the comprehensive evaluation score are combined to determine the final score corresponding to each remaining candidate correction item. All final scores are compared to determine the maximum final score. The candidate correction item corresponding to the maximum final score is the remaining candidate.

[0015] Furthermore, based on the modified text content corresponding to the initial candidate correction items and the remaining candidate items, the length, formality, and emotional intensity of the modified text content are determined, and descriptive tags are set. At the same time, the descriptive tags are combined with the modification reasons corresponding to the candidate solutions to construct a solution comparison table. The descriptive tags include conciseness, colloquialism, and emotional intensity.

[0016] Compared with the prior art, the beneficial effects of the present invention are: Firstly, this invention uses spelling agents, grammar agents, semantic agents, and style agents to generate candidate correction sets in parallel, and combines them with conflict resolution and multi-dimensional evaluation mechanisms. This not only ensures the accuracy of error correction, but also provides diverse expression options, thereby avoiding the problem of single and rigid output of traditional error correction systems. Secondly, this invention can determine the priority level of the intelligent agent based on the error correction strictness level of the user's instruction, and can also set up intelligent agent combinations based on the error correction strictness level of the error correction text, so that the error correction results can better meet the personalized needs of different scenarios. Thirdly, this invention can perform efficient error correction through deep learning models such as Transformer, dependency parsing, and style control vectors, and combines arbitration rules and diversity optimization algorithms, thereby not only reducing human intervention, but also improving the practicality and scalability of the system. Attached Figure Description

[0017] Figure 1 This is a flowchart illustrating the intelligent text correction method for Chinese text in this invention. Figure 2 This is a schematic diagram of the screening process for the candidate set of contradictions in this invention; Figure 3 This is a diagram illustrating the effect of the multi-dimensional scoring radar in this invention. Figure 4 This is a statistical chart of user preferences in this invention. Detailed Implementation

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

[0019] Current deep learning-based text correction systems typically employ a unidirectional and black-box decision-making mechanism when generating correction suggestions, aiming to find a single optimal correction. This completely ignores the inherent richness of natural language expression and the personalized needs of users regarding correction style, tone, and applicable scenarios. Consequently, the output often exhibits a rigid characteristic of mechanical correctness but inappropriate context. In contrast, the technical solution in this application dynamically invokes spelling, grammar, semantic, and style agents based on the user's correction strictness level, obtaining a corresponding candidate correction set. Simultaneously, the obtained candidate correction set undergoes conflict resolution and dimensionality evaluation processing to obtain a comprehensive score for each candidate correction item. Finally, a diversity optimization algorithm is used to determine the final set of candidate correction items.

[0020] Example 1

[0021] refer to Figures 1 - 4 This embodiment provides a Chinese text intelligent error correction method that integrates spelling and semantics. The Chinese text intelligent error correction method specifically includes the following steps: Step S1: Candidate Generation. This involves generating candidate correction sets for each agent by having them work in parallel based on the original Chinese text to be corrected and the user's displayed correction intent. Specifically: Step S1.1: Data Acquisition. This involves acquiring the original Chinese text to be corrected and the user's displayed correction intent through the configured user interface module and intent parsing engine. Specifically, an interactive interface can be set up via a graphical user interface / natural language command-line interface / API interface to receive the user's input of the original Chinese text and intent instructions.

[0022] Furthermore, based on the user's input of raw Chinese text and intent commands, the intent parsing engine parses the text and standardizes it into corresponding structured instruction objects. It is worth noting that the intent parsing engine in this embodiment includes, but is not limited to, simple mapping relationships and intent recognition models (such as rule-based intent recognition models or lightweight machine learning models).

[0023] Step S1.2: Level Determination. Based on the intent command obtained in Step S1.1, the corresponding instruction command is extracted, and the corresponding error correction strictness level is determined according to the extracted instruction command and the set strategy table. Simultaneously, based on the determined error correction strictness level, the corresponding modification operation and the combination of invoked intelligent agents are determined. Specifically, the intelligent agents in this embodiment include a spelling intelligent agent, a grammar intelligent agent, a semantic intelligent agent, and a style intelligent agent.

[0024] In this embodiment, the strategy table is set as shown in Table 1 below, specifically: Table 1: Strategy Table Error correction strictness level Modification operation Invoked agent Only correct typos Only replace typos and misused punctuation. Do not adjust word order, do not change sentence patterns, and do not replace vocabulary. Spelling agent Optimize expression Can correct errors, optimize word collocations, adjust unsmooth sentence patterns, and correct minor grammar problems. Spelling agent, grammar agent and semantic agent Completely rewrite Allow changing sentence structures, replacing a large number of words, and reconstructing semantic expressions to achieve advanced goals such as style conversion. Spelling agent, grammar agent, semantic agent and style agent Step S1.3: Agent Generation. This involves processing the original Chinese text obtained in Step S1.1 using the agent identified in Step 1.2 to obtain corresponding candidate correction terms. In other words, multiple candidate correction terms are obtained through spelling agents, grammar agents, semantic agents, and style agents.

[0025] In this embodiment, the spelling agent is used to verify the correctness of the writing of characters and words in the original Chinese text to ensure their accuracy. Specifically, it uses a character-level Transformer and a Chinese character structure knowledge graph to identify similar-looking / sounding misspellings, providing at least one compliant replacement for each incorrect character or word. More specifically, the spelling agent checks each character in the original Chinese text using a dictionary of similar-sounding characters and a knowledge graph of similar-looking characters to identify any similar-sounding or similar-looking confusion issues. When confusion issues arise, it provides multiple correct options—multiple candidate correction items—based on the established dictionary of similar-sounding characters and knowledge graph of similar-looking characters.

[0026] Furthermore, the grammatical agent is used to detect the grammatical compliance of the original Chinese text, ensuring that the sentence structure conforms to grammatical rules and the sentences are fluent and coherent. Specifically, it uses a dependency parser and a CCG model to detect syntactic errors and provide multiple compliant rewriting schemes for each type of error. Specifically, based on the sentence structure of the original Chinese text, syntactic analysis is performed to obtain the sentence structure distribution, including the subject, predicate, object, attributive, adverbial, and complement, to determine the relationships between these components. More specifically, based on the obtained sentence structure distribution, the grammatical compliance of the original Chinese text is judged to identify the corresponding grammatical problems, and based on these problems, multiple corresponding correct sentence structures are provided—that is, multiple candidate correction terms corresponding to the grammatical agent.

[0027] Furthermore, the semantic agent is used to detect the sentence representation and logic of the original Chinese text to ensure that the sentences in the original Chinese text are unambiguous. That is, through a pre-trained language model, semantic contradictions and referential ambiguities are identified, and multiple semantically consistent but worded or grammatically different correction suggestions are generated using conditional generation techniques. Specifically, the semantics of the original Chinese text are detected by the established language model to determine the corresponding semantic problems. Based on the identified semantic problems, a conditional generation algorithm generates multiple sentences with different wording but the same meaning, i.e., multiple candidate correction items for the semantic agent.

[0028] Furthermore, the style agent is used to add corresponding sentence styles to the original Chinese text according to user instructions. That is, through fine-grained style control vectors, it identifies inconsistent stylistic expressions and generates multiple stylistic correction suggestions within a continuous spectrum that conforms to the user instructions in terms of formality, sentiment intensity, and clutter dimensions. Specifically, it determines the corresponding style control parameters based on the user instructions, including but not limited to formality parameters, sentiment intensity parameters, and colloquialism parameters. Simultaneously, it determines the corresponding style attributes based on the content of the original Chinese text. In other words, based on the style attributes of the original Chinese text and the style control parameters corresponding to the user instructions, a deep generative model processes the data to generate multiple sentences that conform to the target style—that is, multiple candidate correction items for the style agent.

[0029] Step S2: Evaluation and Determination. This involves processing the candidate correction items for each agent obtained in Step S1.3 according to the user intent instructions in Step S1.1, scoring each candidate correction item, and obtaining a candidate score set. Specifically: Step S2.1: Conflict Resolution. This involves centrally processing the candidate modification items for each agent according to the established arbitration rules to determine conflicting candidate sets and conflict-free joint candidate sets. The conflict-free joint candidate sets are retained and scored, while the conflicting candidate sets are directly deleted. Details are as follows: Step S2.1.1: Identification and Processing. This involves the coordinator collecting candidate correction items for each agent and classifying them based on the content of the original Chinese text obtained in Step S1.1. Specifically, the modification location corresponding to each candidate correction item is determined based on the content of the original Chinese text. Furthermore, candidate correction items with the same modification location are grouped together.

[0030] Furthermore, based on all candidate correction items in each category, a unified comparison is made of the modification schemes corresponding to all candidate correction items in that category to identify conflicting modification schemes, i.e., opposing candidate correction items whose modification schemes conflict.

[0031] Step S2.1.2: Initial Decision Processing. Based on the user intent command obtained in Step S1.1, the corresponding error correction strictness and applicable scenario are determined. Simultaneously, based on the error correction strictness and applicable scenario, the priority of the corresponding agent is determined. Specifically, when the error correction strictness level corresponding to the user intent command is "correct only typos," the spelling agent has the highest priority. When the error correction strictness level corresponding to the user intent command is "optimize expression," the semantic agent has the highest priority. When the error correction strictness level corresponding to the user intent command is "complete rewrite," the style agent has the highest priority.

[0032] Furthermore, based on the determined agent priorities, conflicting modification schemes identified in each category of step S2.1.1 are filtered out. That is, when the spelling agent has the highest priority, and a spelling agent exists among the agents corresponding to conflicting modification schemes, the modification scheme corresponding to the spelling agent is retained, and other modification schemes are deleted. Similarly, when the semantic agent has the highest priority, and a semantic agent exists among the agents corresponding to conflicting modification schemes, the modification scheme corresponding to the semantic agent is retained, and other modification schemes are deleted. Likewise, when the style agent has the highest priority, and a style agent exists among the agents corresponding to conflicting modification schemes, the modification scheme corresponding to the style agent is retained, and other modification schemes are deleted.

[0033] Step S2.1.3: Processing and Re-decision. This involves the coordinator setting the style agent as the highest priority for all candidate corrections in the categories that were not deleted in step S2.1.2, in order to filter and eliminate all candidate corrections in these categories. Specifically, if a style agent exists among the agents corresponding to all candidate corrections in a category that was not deleted, the modification scheme corresponding to that style agent is retained, and the other modification schemes are deleted.

[0034] Furthermore, when there is no style agent among the agents corresponding to all candidate correction items in the category that has not undergone deletion processing, the coordinator will obtain the corresponding new candidate correction item through a word fusion strategy based on the word combination corresponding to all candidate correction items in the category that has not undergone deletion processing.

[0035] Step S2.2: Multi-dimensional evaluation. Based on the candidate correction items obtained in steps S2.1.2 and S2.1.3, a comprehensive evaluation score is determined for each candidate correction item by considering its basic correctness, matching degree with user intent style, difference from other candidates, and conformity with user historical preferences.

[0036] In this embodiment, a base agent, namely a grammatical agent and a semantic agent, is determined based on the agent corresponding to each candidate correction item. Specifically, when the agent corresponding to a candidate correction item is a grammatical agent or a semantic agent, its corresponding base correctness score is determined based on the confidence level of the grammatical agent and the semantic agent. Conversely, when the agent corresponding to a candidate correction item is a spelling agent or a style agent, a set correctness review process is used, such as calculating the sentence fluency of the candidate correction item through a fast grammar checker or a language model, to determine its corresponding base correctness score based on the sentence fluency.

[0037] Furthermore, based on the style requirements corresponding to the user's instructions, the style is decomposed into a target style vector that includes formality, sentiment intensity, and complexity. Each candidate correction term is then used as input to a style analysis model (such as an embedding vector model based on a pre-trained language model), and the output is the corresponding actual style vector. In other words, the style matching score for each candidate correction term is determined based on the cosine similarity between the target style vector and the actual style vector.

[0038] Furthermore, based on the vocabulary, grammar, semantics, and style of each candidate correction item, the lexical overlap, syntactic similarity, semantic equivalence, and style bias of each candidate correction item relative to other candidate correction items are determined. Specifically, the lexical overlap is determined based on the number of identical core words used in each candidate correction item. The syntactic similarity is determined based on the degree of similarity in sentence length and sentence structure among each candidate correction item. The semantic equivalence is determined based on the semantic content expressed by each candidate correction item. The style bias is determined based on the style preference of each candidate correction item. Simultaneously, based on the obtained lexical overlap, syntactic similarity, semantic equivalence, and style bias, the diversity contribution score for each candidate correction item is determined.

[0039] Furthermore, based on the context of the original Chinese text, the scene features corresponding to the current text are determined, including user ID, scene, user instructions and candidate solution features. The obtained scene features are used as input to the user intent evolution model (such as a recurrent neural network model based on sequence modeling), and the output is the corresponding prediction probability, that is, the user's historical preference matching score corresponding to each candidate correction item is obtained.

[0040] In this embodiment, based on the basic correctness score, style matching score, diversity contribution score, and user historical preference matching score corresponding to each candidate correction item, they are matched with their corresponding score weights to obtain the comprehensive evaluation score for each candidate correction item. Specifically:

[0041] in: To comprehensively evaluate the scores, The score weights for the basic correctness score, Based on the correctness score, The score weights for style matching score Score the style matching degree. The score weights that contribute to the score for diversity Contribute points to diversity The score weights for the user's historical preference matching score. A score is given to the user's historical preference matching degree.

[0042] Step S3: Selection and Determination. Based on the candidate correction items with comprehensive evaluation scores obtained in Step S2.2, a diversity optimization selection algorithm is used to determine the final set of candidate correction items. Specifically: Step S3.1: Determine the initial candidate items. This involves comparing the comprehensive evaluation scores of each candidate correction item obtained in Step S2.2 to determine the candidate item with the highest comprehensive evaluation score. In other words, the candidate correction item corresponding to this highest comprehensive evaluation score is the initial candidate correction item.

[0043] Step S3.2: Determine the remaining candidate items. Based on the initial candidate correction items determined in Step S3.1, the coordinator obtains the degree of difference between the remaining candidate correction items and the initial candidate correction items. Simultaneously, the degree of difference obtained for each remaining candidate correction item is combined with the comprehensive evaluation score to determine the final score corresponding to each remaining candidate correction item.

[0044] To elaborate further, the final scores corresponding to each of the remaining candidate correction items are compared collectively to determine the highest final score. In other words, the candidate correction item corresponding to the highest final score is the remaining candidate item.

[0045] In other words, the final set of candidate correction items can be obtained based on the initial candidate correction items determined in step S3.1 and the remaining candidate items determined in step S3.2.

[0046] refer to Figure 3 Option A has a style matching score of 0.9, a basic correctness score of 0.8, and a user history preference score of 0.7, but its diversity contribution is only 0.3. Option B has a style matching score of 0.5, a basic correctness score of 0.6, and a user history preference score of 0.4, but its diversity contribution is 0.8. Meanwhile, the obtained recommended option has a style matching score of 0.8, a basic correctness score of 0.9, a user history preference score of 0.8, and a diversity contribution of 0.6. Compared with Options A and B, the overall score of the obtained recommended option is 25% higher.

[0047] refer to Figure 4 By providing more diverse options, user satisfaction with the error correction results increased from 65% to 85%. Meanwhile, the introduction of style-based agents improved text acceptance by 30%.

[0048] Example 2

[0049] This embodiment provides an intelligent error correction method for Chinese text that integrates spelling and semantics. Its specific implementation method is the same as in Embodiment 1, except that a correction comparison table is determined based on the obtained final candidate correction item set, and the final candidate correction item is determined based on the correction comparison table. The invention will be illustrated below with specific examples of this embodiment.

[0050] In this embodiment, the obtained final candidate correction item set is converted into a corresponding scheme comparison table to facilitate the user's direct selection of the final candidate correction item. Specifically, based on the candidate schemes for each candidate correction item in the final candidate correction item set, the modified text content corresponding to each candidate scheme is determined. Simultaneously, based on the length, formality, and emotional intensity of the modified text content for each candidate scheme, corresponding descriptive tags are determined. That is, the length of the modified text content determines its conciseness, its formality determines its colloquialism, and its emotional intensity determines its emotional level.

[0051] Furthermore, based on the obtained brevity, formality, and emotionality, and combined with the reasons for modification corresponding to the candidate solutions, each candidate solution is compared to construct a corresponding solution comparison table, as shown in Table 2 below: Table 2: Comparison of Schemes Solution content Label Reason for modification Our company will hold a large-scale marketing event next week The most formal and the most detailed The original sentence "搞" is too colloquial and does not fit the business scenario Our company will hold an event next week Standard The original sentence "搞" is too colloquial. Replacing it with "举办" is more standard Our company has a big event next week The most colloquial and the most concise The style has been adjusted to a more relaxed colloquial expression In other words, based on the set scheme comparison table, users can directly determine the corresponding final candidate modification item according to their own needs.

[0052] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended embodiments and their equivalents.

Claims

1. A method for intelligent error correction of Chinese text that integrates spelling and semantics, characterized in that, Including: S1: Candidate generation: Based on the original Chinese text to be corrected and the correction intention instruction, the original candidate correction set of each agent is obtained through the parallel operation of each agent; S2: Evaluation and Determination: Based on the correction intention instruction, the original candidate correction set is processed to obtain the score of each original candidate correction item in the original candidate correction set, including: S2.1: Conflict resolution: By setting arbitration rules, all original candidate modification items are classified, and the joint candidate set without conflict is retained, while the candidate set with contradiction is directly filtered. S2.2: Multi-dimensional evaluation: Based on the original candidate correction items that have been retained and screened, a comprehensive evaluation score is determined for each of the original candidate correction items through the basic correctness score, style matching score, diversity contribution score, and user historical preference matching score. S3: Screening and Determination: By using a diversity optimization screening algorithm, the original candidate correction items with the comprehensive evaluation score are compared to determine the final set of candidate correction items.

2. The intelligent error correction method for Chinese text integrating spelling and semantics according to claim 1, characterized in that, The original candidate correction sets for each agent are obtained, including: S1.1: Data Acquisition: The original Chinese text to be corrected and the correction intent command are obtained through the user interface module and intent parsing engine; S1.2: Level Determination: The correction intent instruction is compared with the set strategy table to determine the corresponding error correction strictness level, and the combination of intelligent agents to be invoked is determined according to the error correction strictness level. The intelligent agents include spelling intelligent agents, grammar intelligent agents, semantic intelligent agents and style intelligent agents. S1.3: Agent generation: Based on the combination of agents called, the original Chinese text to be corrected is processed to obtain the candidate correction items corresponding to each agent.

3. The intelligent error correction method for Chinese text integrating spelling and semantics according to claim 2, characterized in that, The error correction strictness level includes correcting only typos, optimizing expression, and complete rewriting. When the error correction strictness level is correcting only typos, the corresponding calling agent combination is a spelling agent. When the error correction strictness level is optimizing expression, the corresponding calling agent combination is a spelling agent, a grammar agent, and a semantic agent. When the error correction strictness level is complete rewriting, the corresponding calling agent combination is a spelling agent, a grammar agent, a semantic agent, and a style agent.

4. A Chinese text intelligent error correction method integrating spelling and semantics according to claim 2 or 3, characterized in that, The spelling intelligence agent uses a character-level Transformer and a knowledge graph of Chinese character structure to identify misspellings that are similar in form or sound, and is used to verify the correctness of the writing of characters and words in the original Chinese text; The grammatical agent detects syntactic errors through dependency parsing and CCG models, and is used to check the grammatical compliance of the original Chinese text. Semantic agents use pre-trained language models to identify semantic contradictions and referential ambiguities, which are then used to detect the sentence representation and sentence logic of raw Chinese text. The style agent identifies expressive styles through fine-grained style control vectors, which are used to add sentence style to the original Chinese text according to user instructions.

5. The intelligent error correction method for Chinese text integrating spelling and semantics according to claim 1, characterized in that, The process involves retaining conflict-free joint candidate sets and directly filtering conflicting candidate sets, including: S2.1.1: Identification and processing: Based on the content of the original Chinese text, determine the modification position of each candidate correction item, and classify the candidate correction items with the same modification position into the same category. At the same time, based on the modification scheme content corresponding to the candidate correction items in each category, the modification schemes with conflicting modification content are taken as the contradictory candidate set, and the modification schemes with no conflicting modification content are taken as the non-conflicting joint candidate set. S2.1.2: Initial decision-making: Based on the correction intention instruction, determine the corresponding error correction strictness, and set the agent priority according to the error correction strictness. At the same time, based on the agent priority and the agent corresponding to each candidate correction item in the conflicting candidate set, retain the candidate correction item corresponding to the agent with the highest priority. S2.1.3: Processing and re-decision: The style agent is set to the highest priority by the coordinator, and the candidate correction items corresponding to the style agent are retained. At the same time, a new candidate correction item is obtained by using a word fusion strategy based on the word combination corresponding to all candidate correction items in the category that has not been deleted.

6. The intelligent error correction method for Chinese text integrating spelling and semantics according to claim 5, characterized in that, When the error correction strictness level is to correct only typos, the spelling agent is set to the highest priority; when the error correction strictness level is to optimize expression, the semantic agent is set to the highest priority; and when the error correction strictness level is to completely rewrite, the style agent is set to the highest priority.

7. The intelligent error correction method for Chinese text integrating spelling and semantics according to claim 1, characterized in that, By setting a correctness review process and a basic intelligent agent, the basic correctness score of the original candidate correction item is obtained. The basic intelligent agent includes a syntactic intelligent agent and a semantic intelligent agent. Based on the style requirements specified by the user, a target style vector is set, and the original candidate correction items are used as input to the style analysis model. The actual style vector is obtained as the output. The style matching score of the original candidate correction items is obtained by using the cosine similarity between the target style vector and the actual style vector. Based on the words, grammar, semantics, and style of each candidate correction item, we set lexical overlap, syntactic structural similarity, semantic equivalence, and style bias to determine the diversity contribution score of the original candidate correction items. Based on the context of the original Chinese text, scene features are set, and these scene features are used as input to the user intent evolution model. The output is the predicted probability, and the user historical preference matching score of the original candidate correction item is determined.

8. The intelligent error correction method for Chinese text integrating spelling and semantics according to claim 1, characterized in that, The final set of candidate correction terms was determined, including: S3.1: Determine the initial candidate: Based on the original candidate correction items with the comprehensive evaluation score, compare all comprehensive evaluation scores and determine the maximum comprehensive evaluation score. The candidate correction item corresponding to the comprehensive evaluation score is the initial candidate correction item. S3.2: Determine the remaining candidates: The coordinator obtains the difference between the initial candidate correction item and the remaining candidate correction items. At the same time, the difference between each remaining candidate correction item and the comprehensive evaluation score are combined to determine the final score corresponding to each remaining candidate correction item. All final scores are compared to determine the maximum final score. The candidate correction item corresponding to the maximum final score is the remaining candidate.

9. A Chinese text intelligent error correction method integrating spelling and semantics according to claim 1 or 8, characterized in that, Based on the modified text content corresponding to the initial candidate correction items and the remaining candidate items, the length, formality, and emotional intensity of the modified text content are determined, and description tags are set. At the same time, the description tags are combined with the modification reasons corresponding to the candidate solutions to construct a solution comparison table. The description tags include conciseness, colloquialism, and emotional intensity.

Citation Information

Patent Citations

  • Intelligent input method system based on large language model technology

    CN118426600A

  • Text error correction method and device, medium and electronic equipment

    CN112784581A

  • Text error correction method and device based on finite state converter

    CN114398876A

  • Activity scheme generation method and system based on artificial intelligence

    CN118537044A

  • Intelligent analysis method and system for multi-source book data, terminal and storage medium

    CN120471357A

Cited By

  • Safety measure ticket intelligent semantic error correction method and system based on OCR technology

    CN121170803A

  • Media asset playing intention type judgment method and system based on multi-signal correction

    CN121565142A

  • Intelligent agent collaborative text generation method based on multi-source information fusion

    CN122047184A

  • A Collaborative Text Generation Method Based on Multi-Source Information Fusion

    CN122047184B