Text label annotation and label system evolution method based on extraction-linking decoupling

CN123012174APending Publication Date: 2026-10-30BEIJING DEEPZERO TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611210664.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-11
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

[0003]抽取与链接的耦合导致模型在解码阶段同时承担两项任务,标准标签值在提示中的出现会干扰模型对原文片段的无偏识别,尤其当文本中存在与标准标签值形近但语义不同的表述时,模型倾向于直接输出预置标签值而非忠实提取原文真实指称,造成标签与原文内容偏离

Benefits of technology

[0051]历史语料依据溯源标识追溯补标,新标签值自动回填既有数据,无需重新解析全量语料,降低演进成本。人工仅处理模糊样本与候选簇确认,常规标注全自动完成,效率大幅提升。抽取与链接分离使各环节独立优化,模型替换、阈值调整或聚类策略变更互不干扰,维护性强。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123012174A_ABST
    Figure CN123012174A_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of natural language processing, and more particularly to a text label annotation and label system evolution method based on extraction-linking decoupling. A to-be-annotated text corpus and to-be-annotated dimension definition are obtained, an extraction prompt word without a standard label value is constructed, a semantic analysis is performed based on the extraction prompt word to extract a referring text and an original text segment, the referring text is matched with a standard label value form set multi-signal, a hit, a fuzzy or no hit is determined according to a score difference and a threshold, a standard label value is assigned to the hit, a candidate label record carrying a corpus traceability identifier is generated for the no hit, the candidate label record is clustered and counted to retain a candidate cluster not lower than a promotion threshold, and the candidate cluster is compared with an existing standard label value to determine whether to be included, newly built or rejected, and the label system is updated after manual confirmation and traced and supplemented according to the traceability identifier. The present application improves annotation accuracy and the automation level of label system evolution by decoupling extraction and linking and multi-level determination.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of natural language processing technology, and in particular to a method for text tagging and tag system evolution based on extraction-link decoupling. Background Technology

[0002] In the field of text labeling, current conventional practices typically couple the extraction and linking processes together. Specifically, after constructing a predefined standard label system, annotation instructions are built based on the standard label values ​​in this system. This drives a language model to retrieve segments in the text to be labeled that match the standard label values ​​and directly map them as labels. In practical engineering, this process often leverages the semantic understanding capabilities of large-scale pre-trained language models, allowing the model to simultaneously discover candidate references and determine their correspondence with standard label values. To improve stability, such solutions also introduce auxiliary methods such as rule templates and dictionary matching to perform consistency correction on the model's output.

[0003] The coupling of extraction and linking causes the model to undertake two tasks simultaneously during the decoding phase. The presence of standard label values ​​in the prompts interferes with the model's unbiased recognition of the original text fragments, especially when there are expressions in the text that are similar in form to the standard label values ​​but different in meaning. The model tends to directly output the pre-set label values ​​instead of faithfully extracting the true reference of the original text, causing the labels to deviate from the original content. Once the pre-set standard label system is determined, it is in a static and fixed state. When new concepts or novel expressions not found in the standard system appear in the text corpus, due to the lack of a discovery and acceptance mechanism, such new expressions will be forced to be mapped to existing labels with similar meanings or directly discarded. As the corpus grows, the coverage of the label system gradually becomes mismatched with the actual semantic boundaries of the original labels, and the granularity and accuracy of the annotation results continue to decline. Subsequent maintenance can only rely on manual periodic review and manual expansion of the label table, making it difficult to adapt to the dynamically changing real-world corpus environment. Summary of the Invention

[0004] This invention provides a text tagging and tag system evolution method based on extraction-link decoupling, which can solve the problems in the prior art.

[0005] A first aspect of this invention provides a method for text tagging and tag system evolution based on extraction-link decoupling, comprising:

[0006] Obtain the text corpus to be labeled and the definition of the dimension to be labeled, and construct extraction prompt words, wherein the prompt words do not contain the standard label values ​​under that dimension;

[0007] Based on the extracted prompt words, semantic parsing is performed on the text corpus to be annotated to extract the referential text that matches the dimension to be annotated and the original text fragments of each referential text in the text corpus to be annotated.

[0008] For each referential text, perform multi-signal matching between it and the set of standard label values ​​in the corresponding dimension. Based on the difference between the highest and second-highest scores and the preset strong threshold, medium threshold and difference threshold, determine whether the referential text is a hit, ambiguous or no hit.

[0009] Assign corresponding standard label values ​​to texts that hit the reference, and generate candidate label records carrying corpus source identification for texts that do not hit the reference;

[0010] After grouping the candidate label records by dimension, approximate clustering is performed. Referential texts with similar semantics are grouped into the same candidate cluster. The frequency of each candidate cluster is calculated based on the number of source identifiers from different corpora that contribute to the cluster. Candidate clusters with frequency results not lower than the preset promotion threshold are retained.

[0011] The retained candidate clusters are semantically compared and analyzed with the existing standard label values ​​under the corresponding dimensions to determine whether each candidate cluster is assigned to the existing standard value, a new standard value, or rejected. After manual confirmation, the label system is updated and historical data is retrospectively supplemented with labels based on the corpus source traceability identifier.

[0012] Multi-signal matching, including:

[0013] For each standard label value under each dimension, construct a form set. The form set includes the standard name, the pinyin form of the standard name, all aliases, and the pinyin form corresponding to each alias. Index the entire form set by dimension.

[0014] For each referential text, the form set of each candidate standard label value is traversed under the corresponding dimension, and the exact match score of the alias is calculated. When the referential text is completely identical to any form literal in the form set of candidate standard label values, a preset full score is assigned.

[0015] To calculate the fuzzy similarity score of the pinyin, the pinyin form of the referred text is compared with the pinyin form of each pinyin form in the candidate standard label value form set by editing distance. The maximum value after editing distance normalization is used as the fuzzy similarity score of the pinyin of the candidate standard label value.

[0016] Calculate the core substring overlap score by taking the longest common continuous substring of each form in the form set of the reference text and the candidate standard label value. The ratio of the length of the longest common continuous substring to the shorter of the length of the reference text and the length of the candidate form is used as the core substring overlap score of the candidate standard label value.

[0017] For each candidate standard label value, the maximum value among its alias exact match score, pinyin fuzzy similarity score, and core substring overlap score is taken as the comprehensive match score of that candidate standard label value.

[0018] The three-state determination includes:

[0019] The candidate standard label values ​​are sorted in descending order of comprehensive matching score, and the highest score is taken as the first score, and the second highest score is taken as the second score.

[0020] Set a strong hit threshold, a medium hit threshold, and a lead difference threshold. When the first score is not lower than the strong hit threshold, the referencing text is determined to be hit and linked to the standard label value corresponding to the first score.

[0021] When the first score is not lower than the medium hit threshold and lower than the strong hit threshold, and the difference between the first score and the second score is not lower than the leading score difference threshold, the referencing text is determined to be hit and linked to the standard label value corresponding to the first score.

[0022] When the first score is lower than the hit threshold, the referred text is determined to be a no-hit and a candidate label record carrying the corpus source identification is generated;

[0023] When the first score is not lower than the mid-hit threshold and lower than the strong-hit threshold, and the difference between the first score and the second score is lower than the leading score difference threshold, the referred text is determined to be ambiguous, the set of candidate standard label values ​​corresponding to the first score is recorded and added to the manual disambiguation queue.

[0024] For the reference text that is determined to be a no match, the reference text is semantically compared with the top preset number of candidate standard label values ​​with the highest comprehensive matching score. It is determined whether the reference text is a different expression of a certain candidate standard label value. If so, it is assigned to the corresponding candidate standard label value; otherwise, the no match judgment is maintained.

[0025] Approximate clustering includes:

[0026] After grouping the accumulated candidate label records by dimension, the candidate referential text in each candidate label record is extracted. The candidate referential text is then standardized and converted into Pinyin form. Leading and trailing whitespace characters are removed and the text is uniformly converted into lowercase.

[0027] Within the same dimension, the edit distance of each candidate reference text's pinyin form is calculated pairwise. The edit distance is divided by the length of the longer pinyin form of the two pinyin forms as the normalized distance. A connection relationship is established between two candidate reference texts whose normalized distance is lower than the preset clustering threshold.

[0028] The connected component algorithm is used to traverse all candidate referential texts and their connection relationships within this dimension. Candidate referential texts that are directly or indirectly reachable through connection relationships are grouped into the same candidate cluster, while candidate referential texts that have not established connection relationships are each grouped into a separate cluster.

[0029] For each candidate cluster, collect the original text fragments and corpus source identifiers corresponding to each candidate referential text in the candidate label record;

[0030] For each candidate cluster, count the frequency of each candidate referential text in all candidate tag records, and take the candidate referential text with the highest frequency as the representative referential text of the candidate cluster.

[0031] The clustering result is output by combining the representative text, the set of original text fragments corresponding to the cluster, and the set of corpus source identifiers.

[0032] The connected component algorithm is used to traverse all candidate referential texts and their connections within this dimension, grouping candidate referential texts that are directly or indirectly reachable through connections into the same candidate cluster, including:

[0033] Construct an undirected graph data structure for candidate referential texts, treating each candidate referential text within a dimension as a node in the undirected graph, and treating the connection between two candidate referential texts whose normalized distance is less than a preset clustering threshold as an edge connecting the corresponding two nodes in the undirected graph, thus forming an undirected graph.

[0034] Initialize all nodes to be unvisited. Select the first unvisited node from the node list in order as the starting point of traversal. Explore the connected unvisited nodes one by one along the adjacent edges of the starting point. Check all the adjacent edges of each newly explored node. Recursively include unvisited nodes that can be explored along the adjacent edges into the traversal path of the current connected component until all nodes in the current connected component have no new unvisited adjacent nodes.

[0035] Mark all nodes in the current connected component traversal path as visited. The set of visited nodes constitutes a connected component. The candidate reference text, original text fragment and corpus source identifier corresponding to each node in the connected component are summarized into the constituent data of the candidate cluster corresponding to the connected component.

[0036] Select the next traversal starting point from the remaining unvisited nodes in the graph, repeat the connected component traversal process until all nodes in the graph are marked as visited, and output the candidate cluster set corresponding to all connected components and the composition data of each candidate cluster.

[0037] Semantic comparison analysis includes:

[0038] The semantic similarity of the representative reference text of each candidate cluster with the standard name and all aliases of the existing standard label value under the corresponding dimension is calculated. For each candidate cluster, the semantic matching score between the representative reference text and each existing standard label value is determined, and the existing standard label value corresponding to the highest score is taken.

[0039] When the highest semantic matching score is not lower than the preset inclusion threshold, the candidate cluster is determined to be included in the existing standard value, and the text referred to in the candidate cluster is added to the existing standard value as an alias.

[0040] When the highest semantic matching score is lower than the preset inclusion threshold, the semantic cohesion between each candidate referential text in the candidate cluster is calculated. When the semantic cohesion is not lower than the preset new threshold, the candidate cluster is determined to be a new standard value, the representative referential text is taken as the name of the new standard value and an alias set is constructed.

[0041] When the semantic cohesion is lower than the preset threshold for new clusters, the candidate cluster is rejected.

[0042] The judgment results of each candidate cluster are written into the tag system in draft form and marked as pending review. After manual review and confirmation of each item, they are released and take effect. For rejected candidate clusters, their representative reference text is recorded in the rejection list.

[0043] For candidate clusters that are determined to be classified into existing or newly created standard values, a backfill instruction is generated based on the source identifier set of the candidate cluster corpus, and retrospective labeling is performed on the historical corpus.

[0044] A second aspect of the present invention provides an electronic device, comprising:

[0045] processor;

[0046] Memory used to store processor-executable instructions;

[0047] The processor is configured to invoke instructions stored in the memory to execute the aforementioned method.

[0048] A third aspect of the present invention provides a computer-readable storage medium having stored thereon computer program instructions that, when executed by a processor, implement the aforementioned method.

[0049] Extraction and linking are decoupled; prompt words do not contain standard label values ​​to avoid misleading prior labels; semantic parsing faithfully preserves the original text context, completely retaining references and original text fragments. Multi-signal matching is stratified based on strong threshold, medium threshold, and difference threshold; fuzzy samples are not forcibly classified to reduce mislabeling. No-match references generate candidate label records carrying corpus source identification, allowing uncovered expressions to be preserved in a verifiable manner.

[0050] Candidate labels are grouped into approximate clusters based on dimensions, with semantically similar references grouped into the same cluster. Frequency is calculated based on source identifiers in the corpus, and only clusters that reach the promotion threshold are retained to avoid low-frequency noise. The retained clusters are compared with existing standard values ​​to determine whether to merge, create, or reject them. The label system is updated after manual confirmation, ensuring that the evolution is traceable and the risks are controllable.

[0051] Historical data is retrospectively labeled based on source identifiers, and new label values ​​are automatically filled into existing data, eliminating the need to re-parse the entire corpus and reducing evolution costs. Manual processing is only required for fuzzy samples and candidate cluster confirmation; routine labeling is fully automated, significantly improving efficiency. Separation of extraction and linking allows for independent optimization of each step; model replacement, threshold adjustment, or clustering strategy changes do not interfere with each other, resulting in strong maintainability.

[0052] The overall approach achieves a closed-loop evolution from corpus to labels, and from candidates to the system. The label set is continuously updated according to the distribution of the corpus, improving the inclusiveness and timeliness of long-tail expressions. The difference and threshold mechanism ensures that the judgment is conservative and controllable, and the explicit handling of fuzzy and miss samples reduces the accumulation of errors. The label quality remains stable during dynamic updates, making it suitable for large-scale annotation and long-term operation of the label system. Attached Figure Description

[0053] Figure 1 This is a flowchart illustrating the text tagging and tag system evolution method based on extraction-link decoupling according to an embodiment of the present invention.

[0054] Figure 2 This is a distribution diagram of the proportion of three-state results based on multi-signal matching and threshold determination in an embodiment of the present invention;

[0055] Figure 3 This is a bar chart showing the distribution of the number of corpus sources for each candidate cluster based on cluster frequency counting in an embodiment of the present invention;

[0056] Figure 4 This is a flowchart illustrating the traversal of connected components of an undirected graph of candidate text in an embodiment of the present invention. Detailed Implementation

[0057] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, 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.

[0058] The technical solution of the present invention will be described in detail below with reference to specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.

[0059] Figure 1 This is a flowchart illustrating the text tagging and tag system evolution method based on extraction-link decoupling according to an embodiment of the present invention.

[0060] Text tagging and tag system evolution methods based on extraction-link decoupling include:

[0061] Obtain the text corpus to be labeled and the definition of the dimension to be labeled, and construct extraction prompt words, wherein the prompt words do not contain the standard label values ​​under that dimension;

[0062] Based on the extracted prompt words, semantic parsing is performed on the text corpus to be annotated to extract the referential text that matches the dimension to be annotated and the original text fragments of each referential text in the text corpus to be annotated.

[0063] For each referential text, perform multi-signal matching between it and the set of standard label values ​​in the corresponding dimension. Based on the difference between the highest and second-highest scores and the preset strong threshold, medium threshold and difference threshold, determine whether the referential text is a hit, ambiguous or no hit.

[0064] Assign corresponding standard label values ​​to texts that hit the reference, and generate candidate label records carrying corpus source identification for texts that do not hit the reference;

[0065] After grouping the candidate label records by dimension, approximate clustering is performed. Referential texts with similar semantics are grouped into the same candidate cluster. The frequency of each candidate cluster is calculated based on the number of source identifiers from different corpora that contribute to the cluster. Candidate clusters with frequency results not lower than the preset promotion threshold are retained.

[0066] The retained candidate clusters are semantically compared and analyzed with the existing standard label values ​​under the corresponding dimensions to determine whether each candidate cluster is assigned to the existing standard value, a new standard value, or rejected. After manual confirmation, the label system is updated and historical data is retrospectively supplemented with labels based on the corpus source traceability identifier.

[0067] In one alternative implementation, multi-signal matching includes:

[0068] For each standard label value under each dimension, construct a form set. The form set includes the standard name, the pinyin form of the standard name, all aliases, and the pinyin form corresponding to each alias. Index the entire form set by dimension.

[0069] For each referential text, the form set of each candidate standard label value is traversed under the corresponding dimension, and the exact match score of the alias is calculated. When the referential text is completely identical to any form literal in the form set of candidate standard label values, a preset full score is assigned.

[0070] To calculate the fuzzy similarity score of the pinyin, the pinyin form of the referred text is compared with the pinyin form of each pinyin form in the candidate standard label value form set by editing distance. The maximum value after editing distance normalization is used as the fuzzy similarity score of the pinyin of the candidate standard label value.

[0071] calculating a core substring overlap score, where the longest common continuous substring between the referent text and each form in the form set of the candidate standard label value is obtained, and the ratio of the length of the longest common continuous substring to the shorter one of the length of the referent text and the length of the candidate form is taken as the core substring overlap score of the candidate standard label value;

[0072] for each candidate standard label value, the maximum value among the alias exact matching score, the pinyin fuzzy similarity score and the core substring overlap score is taken as the comprehensive matching score of the candidate standard label value.

[0073] In the stage of constructing the form set, for each standard label value under each dimension, the standard name, the pinyin form corresponding to the standard name, all registered aliases, and the pinyin form corresponding to each alias are collected respectively, and all the above contents are uniformly included in the form set of the standard label value. For example, for the standard label value "myocardial infarction", its form set contains multiple forms such as "myocardial infarction", "xin ji geng si", "heart infarction", "xin geng", "acute myocardial infarction", "ji xing xin geng" and the like. The generation of pinyin forms usually adopts a full pinyin expansion method, and for polyphonic characters, the most commonly used pronunciation can be selected according to the context of the word to reduce ambiguity. All form sets establish an index structure by dimension, so that when matching the referent text under a certain dimension, the form sets of all candidate standard label values under this dimension can be efficiently retrieved, and invalid cross-dimensional comparison is avoided.

[0074] For each referent text extracted from the text to be labeled, traverse the form sets of all candidate standard label values under its corresponding dimension, and sequentially calculate the scores of the three types of matching signals. The calculation logic of the alias exact matching score is: when the referent text is literally completely consistent with any form in the form set of a certain candidate standard label value, that is, each character is exactly the same and the lengths are equal, the alias exact matching score of the candidate standard label value is assigned a preset full score value, which can usually be set to 1.0; if there is no literal complete consistency between the referent text and all forms in the form set of the candidate standard label value, the alias exact matching score is 0. This signal can directly capture the strongest deterministic correspondence between the referent text and the standard label value, and has strong discrimination ability for dimensions with a high degree of standardization and a complete alias system.

[0075] The calculation method of the pinyin fuzzy similarity score is as follows: convert the referent text into its pinyin form, and then perform edit distance comparison with all pinyin forms in the candidate standard label value form set one by one. The edit distance measures the minimum number of single-character operations (including insertion, deletion and substitution) required to transform one string into another, and a smaller distance indicates a higher similarity between the two. To eliminate the influence of string length difference on the score, the edit distance is normalized. Let the length of the pinyin form of the referent text be , the length of the candidate pinyin form be , and the edit distance between the two be , then the normalized similarity is . The maximum value of the normalized similarities calculated for all pinyin forms in the candidate standard label value form set is taken as the pinyin fuzzy similarity score of the candidate standard label value. The pinyin fuzzy similarity signal can effectively solve the matching failure problems caused by homophones, near-homophones and slight spelling differences. For example, "heart infarction" and "myocardial infarction" are not completely consistent in literal meaning, but their pinyin forms have a small edit distance and the normalized similarity is still high, thus ensuring that such approximate referent texts can obtain high candidate scores.

[0076] The calculation method of the core substring overlap score is as follows: for a certain form in the referent text and the candidate standard label value form set, find the longest common continuous substring between the two, that is, the longest continuous character sequence that appears simultaneously in both strings. Let the length of the longest common continuous substring be , the length of the referent text be , and the length of the candidate form be , then the core substring overlap score is . The denominator takes the smaller value of the length of the referent text and the length of the candidate form, whose purpose is: when the referent text is short, taking the shorter one as the benchmark can more accurately reflect what proportion of the content in the referent text is covered by the candidate form, and avoid the artificially low score caused by the extremely long candidate form. After calculating the above overlap scores for all forms in the candidate standard label value form set respectively, the maximum value is taken as the core substring overlap score of the candidate standard label value. This signal has good adaptability to situations such as abbreviations, inclusion relationships or word order changes. For example, there is a long common continuous substring between "acute anterior wall myocardial infarction" and "anterior wall myocardial infarction", and the overlap score is high, which can assist in identifying such semantically similar expressions.

[0077] After calculating all three types of scores, for each candidate standard label value, the maximum value among its alias exact match score, pinyin fuzzy similarity score, and core substring overlap score is taken as the comprehensive matching score of that candidate standard label value for the current referring text. The strategy of taking the maximum value instead of weighted summation ensures that strong matching evidence in any signal dimension directly determines the comprehensive score, without being diluted by low scores in other signals. For example, when the alias exact match score is already a perfect score of 1.0, the comprehensive matching score is directly 1.0, without considering the other two types of scores; while when the exact match score is 0 but the pinyin fuzzy similarity score is high, the comprehensive matching score still reflects the degree of phonetic similarity between the candidate standard label value and the referring text. After calculating the comprehensive matching score for all candidate standard label values ​​in each dimension, they are sorted from highest to lowest score. The highest and second-highest scores are then combined with preset strong thresholds, medium thresholds, and difference thresholds to proceed to the subsequent hit, fuzzy, or no-hit determination process.

[0078] In practical applications, the quality of maintaining the morphological set directly impacts the overall performance of multi-signal matching. Higher alias coverage and more accurate pinyin morphological generation lead to higher recall rates for both exact matching and fuzzy pinyin matching. For long-tail expressions or emerging words, the core substring overlap signal can serve as a fallback, providing some score support for semantically similar candidate standard label values ​​even when exact matching and pinyin matching fail to achieve high scores, thus reducing the probability of missed detections. The complementarity of the three signal types allows the comprehensive matching score to capture the similarity between the referential text and the standard label values ​​at the literal, phonetic, and structural levels, improving the accuracy and robustness of link determination.

[0079] In one optional implementation, the three-state determination includes:

[0080] The candidate standard label values ​​are sorted in descending order of comprehensive matching score, and the highest score is taken as the first score, and the second highest score is taken as the second score.

[0081] Set a strong hit threshold, a medium hit threshold, and a lead difference threshold. When the first score is not lower than the strong hit threshold, the referencing text is determined to be hit and linked to the standard label value corresponding to the first score.

[0082] When the first score is not lower than the medium hit threshold and lower than the strong hit threshold, and the difference between the first score and the second score is not lower than the leading score difference threshold, the referencing text is determined to be hit and linked to the standard label value corresponding to the first score.

[0083] When the first score is lower than the hit threshold, the referred text is determined to be a no-hit and a candidate label record carrying the corpus source identification is generated;

[0084] When the first score is not lower than the mid-hit threshold and lower than the strong-hit threshold, and the difference between the first score and the second score is lower than the leading score difference threshold, the referred text is determined to be ambiguous, the set of candidate standard label values ​​corresponding to the first score is recorded and added to the manual disambiguation queue.

[0085] For the reference text that is determined to be a no match, the reference text is semantically compared with the top preset number of candidate standard label values ​​with the highest comprehensive matching score. It is determined whether the reference text is a different expression of a certain candidate standard label value. If so, it is assigned to the corresponding candidate standard label value; otherwise, the no match judgment is maintained.

[0086] like Figure 2 As shown, the method includes:

[0087] This figure presents the final attribution distribution of the referred texts after multi-signal matching and three-state determination. The hit rate is 64%, indicating that most references can establish a high-confidence link with existing standard label values ​​based on signals such as precise alias matching in the morphological set, fuzzy similarity of pinyin, and overlap of core substrings. The fuzzy rate is 17%, these references cannot be automatically assigned because the difference between the highest and second-highest scores is less than a preset threshold; they need to enter a manual disambiguation queue where annotators further confirm their correct labels based on the original text fragments. The no-hit rate is 19%, these references have an overall matching score below the medium threshold, and no semantically sufficiently close standard values ​​can be found in the existing labeling system; therefore, they are marked as no-hit, and candidate label records with corpus source identification are generated, providing raw material for subsequent clustering and system evolution. The distribution of these three proportions reflects the effective design of the confidence stratification in the automated determination process, ensuring rapid processing of high-confidence samples while preserving a traceable handling path for low-confidence and uncovered samples.

[0088] After completing multi-signal matching and obtaining the comprehensive matching score for each candidate standard label value, a tri-state determination needs to be performed on each referential text to determine its final attribution. All candidate standard label values ​​in the current dimension are sorted from highest to lowest according to their comprehensive matching score, and the score with the highest score is taken as the first score. The score ranked second is taken as the second score. It also pre-configures three judgment parameters: strong hit threshold. Hit threshold and the leading margin threshold All three are normalized intervals. real numbers on, and satisfying These three thresholds can be adjusted independently based on specific business scenarios and corpus quality. For example, in scenarios with a more refined tagging system and blurred semantic boundaries between tags, the thresholds can be appropriately increased. and To reduce false links; in scenarios with low corpus noise, the noise level can be appropriately reduced. To improve the recall rate.

[0089] when When a high-confidence match is found between the referred text and the standard label value corresponding to the first score, the referred text is directly determined to be in a hit state and linked to that standard label value. The logic behind this branch is that when the highest score exceeds the strong hit threshold, it means that regardless of the second score, the first candidate has sufficient matching strength, and there is no need to consider the score difference between the two. This design avoids unnecessary computational overhead caused by introducing the score difference condition in high-confidence scenarios, while ensuring the rapid convergence of strong matching results.

[0090] when If the candidate standard label value with the highest comprehensive matching score still fails to reach the acceptable matching lower limit, it means that the current referring text cannot find a semantically sufficiently close standard value in the existing labeling system. At this point, the referring text is determined to be in a no-match state, and a candidate label record is generated for it. This record carries a corpus source identifier, recording which original corpus the referring text originated from, so that it can be retrospectively supplemented in subsequent labeling system evolution stages. The no-match record is the starting point of the entire labeling system evolution process. It is only after these no-match referring texts undergo clustering, frequency filtering, and manual confirmation that they can develop into new standard label values.

[0091] when satisfy When the score enters the middle range, the judgment logic needs to further examine the difference between the first score and the second score. .like This indicates that although the first score did not reach the strong hit threshold, it had a significant lead over the second candidate, and the competitive situation was clear. Therefore, it can still be determined as a hit and linked to the standard label value corresponding to the first score. If If the scores of the first and second ranked candidate standard label values ​​are close, indicating ambiguity, then the referential text is considered ambiguous. The set of candidate standard label values ​​corresponding to the first score (usually containing the top candidates with similar scores) is recorded, and the referential text is added to a manual disambiguation queue, awaiting human intervention to confirm its final attribution. The introduction of ambiguity allows the entire judgment mechanism to establish a clear division of labor between automated processing and manual review, avoiding the introduction of noise by directly writing low-confidence link results into the annotation results.

[0092] For referential texts deemed to have no match, a secondary verification based on semantic comparison is required before generating candidate label records to address cases where multi-signal matching fails to identify synonymous or variant expressions. Specifically, the top-scoring candidate labels are selected. Candidate standard label values ​​( The preset number can be configured according to the scale of the tag system, with a typical value of 3 to 5, and will be used to associate the current referential text with this... Semantic comparison is performed on each candidate. Semantic comparison typically uses a pre-trained language model to vectorize the referential text and candidate standard label values, calculating cosine similarity to determine their closeness in the semantic space. If the semantic similarity between the referential text and a candidate exceeds a preset semantic comparison threshold, the referential text is considered a different representation of the candidate standard label value, and is assigned to the corresponding candidate standard label value and marked as a match. Simultaneously, this representation is recorded as an extended form of the standard label value for subsequent form set updates. If it is similar to all... If the semantic similarity of all candidates does not exceed the threshold, the no-hit judgment is maintained, and a candidate label record carrying the corpus source identification is officially generated.

[0093] The motivation behind this secondary verification mechanism is that multi-signal matching mainly relies on shallow features such as literal and phonetic forms. For expressions with significant literal differences but semantic equivalence (e.g., the correspondence between abbreviations, industry slang, colloquial expressions, and standardized terms), shallow matching scores are low, leading to misjudgments as no match. By introducing semantic vector comparison as a supplementary method, these implicit equivalence relationships can be effectively captured, reducing redundant entries in candidate label records and lowering the burden on subsequent clustering and manual review. Furthermore, semantic comparison is triggered only in the no-match branch, rather than being performed on all referential texts; this design balances computational efficiency and coverage.

[0094] The overall logic of the three-state determination forms a hierarchical decision-making structure: strong hits are directly and automatically linked; intermediate intervals are further distinguished between automatic hits and manual disambiguation based on the score difference; low scores directly enter the candidate record generation process and undergo additional semantic secondary verification. This hierarchical design enables automated processing to maximize coverage in high-confidence intervals, while concentrating uncertainty in the fuzzy queue and no-hit records, providing structured input for subsequent manual intervention and the evolution of the labeling system. Through reasonable configuration... , and These three parameters can strike a balance between the accuracy of automated annotation and the cost of manual intervention, adapting to the quality requirements of different business scenarios.

[0095] In one alternative implementation, approximate clustering includes:

[0096] After grouping the accumulated candidate label records by dimension, the candidate referential text in each candidate label record is extracted. The candidate referential text is then standardized and converted into Pinyin form. Leading and trailing whitespace characters are removed and the text is uniformly converted into lowercase.

[0097] Within the same dimension, the edit distance of each candidate reference text's pinyin form is calculated pairwise. The edit distance is divided by the length of the longer pinyin form of the two pinyin forms as the normalized distance. A connection relationship is established between two candidate reference texts whose normalized distance is lower than the preset clustering threshold.

[0098] The connected component algorithm is used to traverse all candidate referential texts and their connection relationships within this dimension. Candidate referential texts that are directly or indirectly reachable through connection relationships are grouped into the same candidate cluster, while candidate referential texts that have not established connection relationships are each grouped into a separate cluster.

[0099] For each candidate cluster, collect the original text fragments and corpus source identifiers corresponding to each candidate referential text in the candidate label record;

[0100] For each candidate cluster, count the frequency of each candidate referential text in all candidate tag records, and take the candidate referential text with the highest frequency as the representative referential text of the candidate cluster.

[0101] The clustering result is output by combining the representative text, the set of original text fragments corresponding to the cluster, and the set of corpus source identifiers.

[0102] like Figure 3 As shown, the method includes:

[0103] This figure shows the number of different corpus sources contributed by each of the six candidate clusters, with the bar values ​​from left to right being 12, 9, 7, 3, 2, and 1. This frequency index measures the breadth of coverage of each candidate cluster in the overall corpus, rather than simply relying on the total number of occurrences of references, thus avoiding interference from high-frequency repetitions in a single corpus. Based on a preset promotion threshold, only candidate clusters with frequency results not lower than this threshold are retained for subsequent semantic comparison. For example, if the threshold is set to 5, the first three clusters (12, 9, 7) are retained, while the last three (3, 2, 1) are filtered out due to their low frequency, effectively reducing noise interference during the evolution process. The retained candidate clusters will be further semantically similar to existing standard values ​​to determine whether they should be included, newly created, or rejected. After manual confirmation, the labeling system is updated, and historical corpora are retrospectively labeled based on source identification. These two figures together outline the complete quantitative decision-making chain from initial judgment to candidate accumulation and system update.

[0104] Before entering the clustering process, the accumulated candidate label records are first grouped by dimension to ensure that candidate referential texts within the same dimension are semantically comparable. For the candidate referential text carried in each candidate label record, normalization is performed: leading and trailing whitespace characters are removed, all characters are converted to lowercase, and the normalized text is converted to pinyin. The purpose of pinyin conversion is to eliminate the interference of differences in Chinese character writing styles (such as simplified / traditional characters, variant characters) on subsequent distance calculations, making referential texts with similar pronunciations closer in distance measurement. Normalization and pinyin conversion are fundamental guarantees of clustering quality; any remaining differences in capitalization or whitespace will cause referential texts that should belong to the same cluster to be incorrectly separated.

[0105] Within the same dimension, pairwise edit distance is calculated for the pinyin forms of all candidate referential texts. Edit distance measures the minimum number of single-character operations (insertion, deletion, replacement) required to convert one string to another. To eliminate the influence of string length differences on the absolute value of the distance, the edit distance between two pinyin forms is divided by the character length of the longer pinyin form to obtain the normalized distance. Let the pinyin forms of the two candidate referential texts be... and Its edit distance is The length of the longer pinyin form is Then the normalized distance is The range of values ​​for the normalized distance is... The smaller the value, the more similar the two pinyin forms are; a value of 0 indicates they are completely identical, and a value of 1 indicates they are completely different. When the clustering threshold is lower than the preset threshold, a connection is established between the corresponding two candidate referential texts. This connection is undirected, meaning that if... and Establish a connection, then and Similarly, connections are established. The selection of the clustering threshold has a significant impact on the clustering results: a threshold that is too small will prevent semantically similar descriptive texts from being grouped into the same cluster, while a threshold that is too large will incorrectly merge descriptive texts with significant semantic differences. In practical applications, the clustering threshold can be adjusted according to the distribution characteristics of descriptive texts in specific dimensions, and is usually set between 0.2 and 0.4.

[0106] After establishing all connections, the connected component algorithm is used to traverse all candidate referential texts and their connections within this dimension. The connected component algorithm divides nodes in the graph structure that are directly or indirectly reachable through edges into the same connected component. In this scenario, each candidate referential text corresponds to a node in the graph, and each connection corresponds to an undirected edge in the graph. Starting from any unvisited node, the algorithm traverses all nodes directly or indirectly connected to it using breadth-first search or depth-first search, marking these nodes as the same connected component, i.e., the same candidate cluster. After traversal, all visited nodes are assigned to their respective candidate clusters, while isolated nodes without any connections are grouped separately. This approach ensures the transitivity of clustering: if referential texts A and B are similar, and B and C are similar, even if the normalized distance between A and C is not lower than the clustering threshold, A, B, and C will still be assigned to the same candidate cluster, thus avoiding the problem of missed clustering due to chain-like similarity relationships.

[0107] For each candidate cluster, the original text fragments and corpus source identifiers corresponding to each candidate referential text within that cluster are collected from all candidate label records. An original text fragment refers to the specific text segment in the original unannotated text corpus that corresponds to the candidate referential text, preserving the complete expression of the referential text in its original context. A corpus source identifier is a unique identifier attached to each record when generating candidate label records, used to trace the source corpus from which the candidate referential text originates. The original text fragments corresponding to all candidate referential texts within the same candidate cluster are aggregated into an original text fragment set, and the corresponding corpus source identifiers are aggregated into a corpus source identifier set. Only one copy of each identifier is retained in the corpus source identifier set to prevent duplicate counting when the same referential text appears multiple times in the same corpus during subsequent frequency counting based on the number of different corpus sources.

[0108] For each candidate cluster, the frequency of each candidate referential text within that cluster is counted across all candidate label records. Frequency is counted per candidate label record; that is, each occurrence of the same candidate referential text across different candidate label records is counted as one occurrence. The candidate referential text with the highest frequency is selected as the representative referential text for that candidate cluster. The representative referential text serves to represent the semantics of the candidate cluster and is used as a semantic proxy in subsequent semantic comparisons with existing standard label values. If multiple candidate referential texts within a candidate cluster have the same highest frequency, a deterministic selection can be made based on rules such as prioritizing shorter texts or prioritizing texts in alphabetical order (e.g., those appearing earlier in the alphabetical order) to ensure the uniqueness and reproducibility of the representative referential text selection.

[0109] The clustering result is output by combining the representative referential text, the set of original text fragments corresponding to the cluster, and the set of corpus source identifiers. In the clustering result, the set of original text fragments provides rich contextual evidence for subsequent manual review and semantic comparison, enabling reviewers to intuitively determine whether the semantic content represented by the candidate cluster has practical significance. The set of corpus source identifiers is used to calculate the number of different corpus sources covered by the candidate cluster, serving as the basis for determining the promotion threshold. Using the number of different corpus source identifiers, rather than the total number of original text fragments, as the frequency index effectively avoids inflated frequency results due to the high-frequency repetition of the same referential text in a single corpus, and more accurately reflects the universality and representativeness of the candidate cluster within the overall corpus.

[0110] In one optional implementation, a connected component algorithm is used to traverse all candidate referential texts and their connections within this dimension, grouping candidate referential texts that are directly or indirectly reachable through connections into the same candidate cluster, including:

[0111] Construct an undirected graph data structure for candidate referential texts, treating each candidate referential text within a dimension as a node in the undirected graph, and treating the connection between two candidate referential texts whose normalized distance is less than a preset clustering threshold as an edge connecting the corresponding two nodes in the undirected graph, thus forming an undirected graph.

[0112] Initialize all nodes to be unvisited. Select the first unvisited node from the node list in order as the starting point of traversal. Explore the connected unvisited nodes one by one along the adjacent edges of the starting point. Check all the adjacent edges of each newly explored node. Recursively include unvisited nodes that can be explored along the adjacent edges into the traversal path of the current connected component until all nodes in the current connected component have no new unvisited adjacent nodes.

[0113] Mark all nodes in the current connected component traversal path as visited. The set of visited nodes constitutes a connected component. The candidate reference text, original text fragment and corpus source identifier corresponding to each node in the connected component are summarized into the constituent data of the candidate cluster corresponding to the connected component.

[0114] Select the next traversal starting point from the remaining unvisited nodes in the graph, repeat the connected component traversal process until all nodes in the graph are marked as visited, and output the candidate cluster set corresponding to all connected components and the composition data of each candidate cluster.

[0115] like Figure 4 As shown, the method includes:

[0116] After calculating the pairwise normalized distances between candidate referential texts, text pairs with distances below the clustering threshold need to be transformed into a traversable graph structure to facilitate final clustering using the connected component algorithm. To this end, an undirected graph data structure is constructed for all candidate referential texts within the same dimension. Each node in the undirected graph corresponds to a candidate referential text within that dimension. In addition to storing the referential text itself, the node's attributes also simultaneously store the corresponding original text fragment and source identifier from the original corpus, allowing for direct retrieval during subsequent candidate cluster aggregation without needing to look up the original records.

[0117] For any two candidate referential text nodes within a dimension, if their normalized distance is below a preset clustering threshold, an undirected edge is added between these two nodes. This indicates that they have sufficiently high semantic or morphological similarity and should be considered as candidates that can be classified into the same candidate cluster. Since the edge is undirected, the edge between node A and node B indicates that A can reach B, and B can reach A. This symmetry is the basis for subsequent connected component traversal to cover all indirect reachability relationships. When there are many candidate referential texts within a dimension, the number of edges is large. However, since edges are only built for text pairs with a distance below the threshold, the sparsity of the graph depends on the semantic distribution density of referential texts in the same dimension in the actual corpus. The selection of the clustering threshold directly affects the connectivity structure of the graph and the granularity of the final candidate clusters.

[0118] After the undirected graph is constructed, all nodes in the graph are initialized to be unvisited. The traversal process selects the first unvisited node from the node list as the starting point to begin exploring the current connected component. Using this starting point as the root, each adjacent node is checked along all its adjacent edges. If an adjacent node has not yet been visited, it is added to the traversal path of the current connected component, and this adjacent node becomes the new exploration base point. All adjacent edges are then checked, and any unvisited adjacent nodes are added back to the traversal path. This process is recursively performed, forming a depth-first exploration pattern: whenever a new unvisited node is found, the process immediately extends deeper along its adjacent edges until no unvisited adjacent nodes remain on the current path. Then, it backtracks to the previous level to continue checking the remaining adjacent edges.

[0119] The recursive backtracking continues until all adjacent paths to the starting point have been exhausted, at which point the traversal of the current connected component is complete. At this point, all nodes involved in the current traversal path are marked as visited; these nodes constitute a complete connected component. The semantic meaning of a connected component is that there exists at least one path between any two nodes, consisting of several edges connecting them end-to-end; that is, the two nodes are reachable from each other through direct or indirect similarity, and therefore should be classified into the same candidate cluster. The candidate referential texts, original text fragments, and corpus source identifiers corresponding to each node within this connected component are summarized to form the constituent data of the candidate clusters corresponding to this connected component, for subsequent frequency counting and promotion judgment.

[0120] It is worth noting that the connected component algorithm can capture indirect reachability relationships, a characteristic that is significant in labeling scenarios. For example, the normalized distance between denotative texts A and B may be below the clustering threshold, as may the normalized distance between B and C, but the normalized distance between A and C may be above the clustering threshold, meaning there is no direct edge between A and C. However, since A can reach C via B, all three still belong to the same connected component and will be grouped into the same candidate cluster. This transitive grouping method aligns with the actual pattern in natural language where synonymous or near-synonymous expressions are interconnected through intermediate forms, avoiding the fragmented grouping problem caused by relying solely on pairwise direct matching.

[0121] After marking the current connected component, select the next unvisited node from the remaining unvisited nodes in the graph as the new traversal starting point, and repeat the connected component exploration and marking process. This cycle continues, identifying a new connected component in each round and marking all its nodes as visited, until all nodes in the graph are in a visited state, at which point the traversal process ends. The final output is a one-to-one correspondence set of all connected components and candidate clusters in this dimension. Each candidate cluster includes its constituent data, including a list of all candidate referential texts belonging to that cluster, the original text fragments of each referential text in the original corpus, and a set of corpus source identifiers for each referential text.

[0122] For isolated nodes in the graph that do not form edges with any other nodes (i.e., the normalized distance between the candidate reference text and all other candidate reference texts within the dimension is not less than the clustering threshold), this node constitutes a connected component containing only a single node, corresponding to a candidate cluster containing only that reference text. Such single-node candidate clusters typically have low frequency values ​​when frequency-counting based on the number of source identifiers in the corpus, and are often filtered out during the promotion threshold screening stage, unless the reference text appears in multiple corpora from different sources, indicating a certain degree of universality, making it worthy of manual verification.

[0123] After all candidate clusters and their constituent data are output, frequency counting is performed on each candidate cluster based on the number of source identifiers from different corpus sources contributing to that cluster. The number of unique source identifiers from different corpus sources within each candidate cluster is counted to measure the breadth of coverage of the referential text represented by that candidate cluster within the overall corpus, rather than relying solely on the frequency of occurrence of original text fragments. This avoids interference from high-frequency repetitions in a single corpus on the frequency counting results. Candidate clusters with frequency counting results not lower than a preset promotion threshold are retained and proceed to the subsequent semantic comparison analysis process with existing standard label values. Finally, manual confirmation is performed to determine whether to classify them into existing standard values, create new standard values, or reject them. Retrospective labeling is then performed on historical corpus data based on the source identifiers.

[0124] In one alternative implementation, semantic comparison analysis includes:

[0125] The semantic similarity of the representative reference text of each candidate cluster with the standard name and all aliases of the existing standard label value under the corresponding dimension is calculated. For each candidate cluster, the semantic matching score between the representative reference text and each existing standard label value is determined, and the existing standard label value corresponding to the highest score is taken.

[0126] When the highest semantic matching score is not lower than the preset inclusion threshold, the candidate cluster is determined to be included in the existing standard value, and the text referred to in the candidate cluster is added to the existing standard value as an alias.

[0127] When the highest semantic matching score is lower than the preset inclusion threshold, the semantic cohesion between each candidate referential text in the candidate cluster is calculated. When the semantic cohesion is not lower than the preset new threshold, the candidate cluster is determined to be a new standard value, the representative referential text is taken as the name of the new standard value and an alias set is constructed.

[0128] When the semantic cohesion is lower than the preset threshold for new clusters, the candidate cluster is rejected.

[0129] The judgment results of each candidate cluster are written into the tag system in draft form and marked as pending review. After manual review and confirmation of each item, they are released and take effect. For rejected candidate clusters, their representative reference text is recorded in the rejection list.

[0130] For candidate clusters that are determined to be classified into existing or newly created standard values, a backfill instruction is generated based on the source identifier set of the candidate cluster corpus, and retrospective labeling is performed on the historical corpus.

[0131] The core objective of the semantic comparison analysis phase is to determine the relationship between each retained candidate cluster and the existing label system, thereby deciding whether the candidate cluster should be included in the existing standard value, created as an independent standard value, or rejected. For each retained candidate cluster, its representative referential text is first extracted. This representative referential text is usually the referential text with the highest frequency or the most semantically intermediate meaning within the candidate cluster, serving as the semantic representative of the cluster. Semantic similarity is calculated between the representative referential text and the standard name and all aliases of each existing standard label value under the corresponding dimension. The semantic similarity method used can be based on the vector cosine similarity of a pre-trained language model. The representative referential text, each standard name, and each alias are encoded into dense vectors, cosine similarity is calculated, and the maximum similarity between the representative referential text and all names (including the standard name and all aliases) under the standard label value is taken as the semantic matching score between the candidate cluster and the existing standard label value. After traversing all existing standard label values ​​under the corresponding dimension, the existing standard label value with the highest semantic matching score and its corresponding score are taken as the optimal matching result of the candidate cluster.

[0132] When the highest semantic matching score is not lower than the preset inclusion threshold When a candidate cluster is determined to be included in the existing standard value of the best match, all referential texts that have appeared within the candidate cluster (including representative referential texts and other semantically similar referential texts) are added as aliases to the existing alias set of the standard value. This enriches the morphological coverage of the standard value and helps to more accurately identify synonyms in subsequent matching stages. The inclusion operation does not change the standard name of the standard value, but only expands its alias set, maintaining the stability of the main structure of the tag system.

[0133] When the highest semantic matching score is lower than the preset inclusion threshold If the semantic content of the candidate cluster is not similar to the existing standard values, it indicates that the candidate cluster has sufficient semantic cohesion to support the newly established standard values. At this point, the semantic cohesion between each candidate referential text within the candidate cluster is calculated. Specifically, the semantic similarity of each pair of referential texts within the candidate cluster is calculated, and the average of all pairwise similarities is taken as the semantic cohesion score of the cluster, denoted as . .when Not lower than the preset new threshold When a candidate cluster is deemed to meet the conditions for establishing a new standard value, the representative referential text is taken as the standard name of the new standard value, and the remaining referential texts within the cluster are used to construct the initial alias set for the new standard value, thus completing the draft definition of the new standard value. Here, a new threshold is established. The setting is usually higher than the inclusion threshold. This is to ensure that the semantic concepts represented by the newly established standard values ​​have sufficient clarity and consistency, and to avoid incorrectly promoting semantically mixed candidate clusters to standard values.

[0134] when Below the preset new threshold If the candidate cluster is deemed semantically fragmented, lacking a consistent semantic focus among its various referential texts and unable to be summarized into a clear semantic concept, then the candidate cluster is rejected. Rejection does not mean that the information in these referential texts is completely discarded; rather, representative referential texts of the candidate cluster are added to the rejection list for reference during subsequent manual review, so that their value can be reassessed as the labeling system evolves.

[0135] After determining whether each candidate cluster should be included, created, or rejected, all results are written into the tagging system as drafts and marked as pending review, rather than being directly published. Drafts in the pending review state do not affect the ongoing tagging process; existing tagging logic continues to execute based on the published tagging system, thus ensuring the stability of online tagging. Draft content is organized by dimension. Each draft record includes the candidate cluster identifier, judgment type (inclusion / creation / rejection), the existing standard value involved (when inclusion) or the proposed new standard value name and alias set (when creation), the representative referential text, and the number of contributing corpus source identifiers, providing sufficient contextual basis for manual review.

[0136] The manual review process involves verifying each record in the draft. Reviewers can accept the judgment result, modify the standard value name or alias, adjust the judgment type (e.g., change the system's judgment of "new" to "inclusion in an existing standard value," or change "rejection" to "new"), or directly reject a draft record. After manual verification, accepted draft records are published and take effect, and the tagging system is updated accordingly: "Inclusion" records will have their aliases added to the corresponding existing standard values; "New" records will have the new standard value and its alias set formally incorporated into the tagging system; and "Rejection" records will have their representative text written into the rejection list and retain the review timestamp for future traceability.

[0137] For candidate clusters determined to be included in existing or newly created standard values, a backfill instruction is generated based on the set of corpus source identifiers carried by the candidate cluster after the tag system is updated and released. The corpus source identifiers are attached when candidate tag records are generated for previously unmatched referential texts, recording which original corpus the referential text originated from and its position within the corpus. The backfill instruction uses the corpus source identifiers as an index to locate the corresponding original text segment in the historical corpus, updating its annotation result to the confirmed standard tag value (updated to the corresponding existing standard value when included, and updated to the new standard value when newly created), thus achieving retrospective annotation of historical corpus. Retrospective annotation operations are executed asynchronously in batches to avoid putting pressure on online services. After annotation is completed, the corpus annotation version record is updated to ensure that the annotation status of historical corpus is consistent with the latest tag system. The entire semantic comparison and analysis process combines automated semantic judgment with manual review, ensuring the accuracy of the tag system evolution while minimizing the workload of manual intervention, achieving controllable and continuous evolution of the tag system.

[0138] A second aspect of the present invention provides an electronic device, comprising:

[0139] processor;

[0140] Memory used to store processor-executable instructions;

[0141] The processor is configured to invoke instructions stored in the memory to execute the aforementioned method.

[0142] A third aspect of the present invention provides a computer-readable storage medium having stored thereon computer program instructions that, when executed by a processor, implement the aforementioned method.

[0143] This invention can be a method, apparatus, system, and / or computer program product. The computer program product may include a computer-readable storage medium having computer-readable program instructions loaded thereon for performing various aspects of the invention.

[0144] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A text tagging and tag system evolution method based on extraction-link decoupling, characterized in that, include: Obtain the text corpus to be labeled and the definition of the dimension to be labeled, and construct extraction prompt words, wherein the prompt words do not contain the standard label values ​​under that dimension; Based on the extracted prompt words, semantic parsing is performed on the text corpus to be annotated to extract the referential text that matches the dimension to be annotated and the original text fragments of each referential text in the text corpus to be annotated. For each referential text, perform multi-signal matching between it and the set of standard label values ​​in the corresponding dimension. Based on the difference between the highest and second-highest scores and the preset strong threshold, medium threshold and difference threshold, determine whether the referential text is a hit, ambiguous or no hit. Assign corresponding standard label values ​​to texts that hit the reference, and generate candidate label records carrying corpus source identification for texts that do not hit the reference; After grouping the candidate label records by dimension, approximate clustering is performed. Referential texts with similar semantics are grouped into the same candidate cluster. The frequency of each candidate cluster is calculated based on the number of source identifiers from different corpora that contribute to the cluster. Candidate clusters with frequency results not lower than the preset promotion threshold are retained. The retained candidate clusters are semantically compared and analyzed with the existing standard label values ​​under the corresponding dimensions to determine whether each candidate cluster is assigned to the existing standard value, a new standard value, or rejected. After manual confirmation, the label system is updated and historical data is retrospectively supplemented with labels based on the corpus source traceability identifier.

2. The method according to claim 1, characterized in that, Multi-signal matching, including: For each standard label value under each dimension, construct a form set. The form set includes the standard name, the pinyin form of the standard name, all aliases, and the pinyin form corresponding to each alias. Index the entire form set by dimension. For each referential text, the form set of each candidate standard label value is traversed under the corresponding dimension, and the exact match score of the alias is calculated. When the referential text is completely identical to any form literal in the form set of candidate standard label values, a preset full score is assigned. To calculate the fuzzy similarity score of the pinyin, the pinyin form of the referred text is compared with the pinyin form of each pinyin form in the candidate standard label value form set by editing distance. The maximum value after editing distance normalization is used as the fuzzy similarity score of the pinyin of the candidate standard label value. Calculate the core substring overlap score by taking the longest common continuous substring of each form in the form set of the reference text and the candidate standard label value. The ratio of the length of the longest common continuous substring to the shorter of the length of the reference text and the length of the candidate form is used as the core substring overlap score of the candidate standard label value. For each candidate standard label value, the maximum value among its alias exact match score, pinyin fuzzy similarity score, and core substring overlap score is taken as the comprehensive match score of that candidate standard label value.

3. The method according to claim 2, characterized in that, The three-state determination includes: The candidate standard label values ​​are sorted in descending order of comprehensive matching score, and the highest score is taken as the first score, and the second highest score is taken as the second score. Set a strong hit threshold, a medium hit threshold, and a lead difference threshold. When the first score is not lower than the strong hit threshold, the referencing text is determined to be hit and linked to the standard label value corresponding to the first score. When the first score is not lower than the medium hit threshold and lower than the strong hit threshold, and the difference between the first score and the second score is not lower than the leading score difference threshold, the referencing text is determined to be hit and linked to the standard label value corresponding to the first score. When the first score is lower than the hit threshold, the referred text is determined to be a no-hit and a candidate label record carrying the corpus source identification is generated; When the first score is not lower than the mid-hit threshold and lower than the strong-hit threshold, and the difference between the first score and the second score is lower than the leading score difference threshold, the referred text is determined to be ambiguous, the set of candidate standard label values ​​corresponding to the first score is recorded and added to the manual disambiguation queue. For the reference text that is determined to be a no match, the reference text is semantically compared with the top preset number of candidate standard label values ​​with the highest comprehensive matching score. It is determined whether the reference text is a different expression of a certain candidate standard label value. If so, it is assigned to the corresponding candidate standard label value; otherwise, the no match judgment is maintained.

4. The method according to claim 1, characterized in that, Approximate clustering includes: After grouping the accumulated candidate label records by dimension, the candidate referential text in each candidate label record is extracted. The candidate referential text is then standardized and converted into Pinyin form. Leading and trailing whitespace characters are removed and the text is uniformly converted into lowercase. Within the same dimension, the edit distance of each candidate reference text's pinyin form is calculated pairwise. The edit distance is divided by the length of the longer pinyin form of the two pinyin forms as the normalized distance. A connection relationship is established between two candidate reference texts whose normalized distance is lower than the preset clustering threshold. The connected component algorithm is used to traverse all candidate referential texts and their connection relationships within this dimension. Candidate referential texts that are directly or indirectly reachable through connection relationships are grouped into the same candidate cluster, while candidate referential texts that have not established connection relationships are each grouped into a separate cluster. For each candidate cluster, collect the original text fragments and corpus source identifiers corresponding to each candidate referential text in the candidate label record; For each candidate cluster, count the frequency of each candidate referential text in all candidate tag records, and take the candidate referential text with the highest frequency as the representative referential text of the candidate cluster. The clustering result is output by combining the representative text, the set of original text fragments corresponding to the cluster, and the set of corpus source identifiers.

5. The method according to claim 4, characterized in that, The connected component algorithm is used to traverse all candidate referential texts and their connections within this dimension, grouping candidate referential texts that are directly or indirectly reachable through connections into the same candidate cluster, including: Construct an undirected graph data structure for candidate referential texts, treating each candidate referential text within a dimension as a node in the undirected graph, and treating the connection between two candidate referential texts whose normalized distance is less than a preset clustering threshold as an edge connecting the corresponding two nodes in the undirected graph, thus forming an undirected graph. Initialize all nodes to be unvisited. Select the first unvisited node from the node list in order as the starting point of traversal. Explore the connected unvisited nodes one by one along the adjacent edges of the starting point. Check all the adjacent edges of each newly explored node. Recursively include unvisited nodes that can be explored along the adjacent edges into the traversal path of the current connected component until all nodes in the current connected component have no new unvisited adjacent nodes. Mark all nodes in the current connected component traversal path as visited. The set of visited nodes constitutes a connected component. The candidate reference text, original text fragment and corpus source identifier corresponding to each node in the connected component are summarized into the constituent data of the candidate cluster corresponding to the connected component. Select the next traversal starting point from the remaining unvisited nodes in the graph, repeat the connected component traversal process until all nodes in the graph are marked as visited, and output the candidate cluster set corresponding to all connected components and the composition data of each candidate cluster.

6. The method according to claim 1, characterized in that, Semantic comparison analysis includes: The semantic similarity of the representative reference text of each candidate cluster with the standard name and all aliases of the existing standard label value under the corresponding dimension is calculated. For each candidate cluster, the semantic matching score between the representative reference text and each existing standard label value is determined, and the existing standard label value corresponding to the highest score is taken. When the highest semantic matching score is not lower than the preset inclusion threshold, the candidate cluster is determined to be included in the existing standard value, and the text referred to in the candidate cluster is added to the existing standard value as an alias. When the highest semantic matching score is lower than the preset inclusion threshold, the semantic cohesion between each candidate referential text in the candidate cluster is calculated. When the semantic cohesion is not lower than the preset new threshold, the candidate cluster is determined to be a new standard value, the representative referential text is taken as the name of the new standard value and an alias set is constructed. When the semantic cohesion is lower than the preset threshold for new clusters, the candidate cluster is rejected. The judgment results of each candidate cluster are written into the tag system in draft form and marked as pending review. After manual review and confirmation of each item, they are released and take effect. For rejected candidate clusters, their representative reference text is recorded in the rejection list. For candidate clusters that are determined to be classified into existing or newly created standard values, a backfill instruction is generated based on the source identifier set of the candidate cluster corpus, and retrospective labeling is performed on the historical corpus.

7. A text tagging and tag system evolution system based on extraction-link decoupling, used to implement the method as described in any one of claims 1-6, characterized in that, include: Construct a prompting unit to obtain the text corpus to be labeled and the dimension definition to be labeled, and construct an extraction prompt word, wherein the prompt word does not contain the standard label value under that dimension; The reference extraction unit is used to perform semantic parsing on the text corpus to be annotated based on the extracted prompt words, and to extract the reference text that matches the dimension to be annotated and the original text fragments of each reference text in the text corpus to be annotated. The hit determination unit is used to perform multi-signal matching on each referential text with the form set of standard label values ​​in the corresponding dimension. Based on the difference between the highest and second highest scores and the preset strong threshold, medium threshold and difference threshold, the unit determines whether the referential text is hit, ambiguous or not hit. The candidate generation unit is used to assign corresponding standard label values ​​to the text that hits the reference and to generate candidate label records carrying corpus source identification for the text that does not hit the reference. The clustering frequency counting unit is used to perform approximate clustering after grouping candidate label records by dimension, classifying semantically similar referential texts into the same candidate cluster, counting the frequency of each candidate cluster according to the number of different corpus source identifiers contributing to the cluster, and retaining candidate clusters whose frequency counting results are not lower than the preset promotion threshold. The update and supplementation unit is used to perform semantic comparison and analysis between the retained candidate clusters and the existing standard label values ​​under the corresponding dimensions, to determine whether each candidate cluster should be assigned to the existing standard value, a new standard value, or rejected. After manual confirmation, the label system is updated and retrospective supplementation is performed on the historical data based on the corpus source traceability identifier.

8. An electronic device, characterized in that, include: processor; Memory used to store processor-executable instructions; The processor is configured to invoke instructions stored in the memory to execute the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having computer program instructions stored thereon, characterized in that, When the computer program instructions are executed by the processor, they implement the method described in any one of claims 1 to 6.