A work order text processing method and device

CN119128140BActive Publication Date: 2026-10-13上海蜜度蜜巢智能科技有限公司
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410322391.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-20
Publication Date
2026-10-13
Estimated Expiration
2044-03-20

AI Technical Summary

Technical Problem

[0004]首先,投诉内容所涉及的方向十分宽泛,因此为了尽可能涵盖这些方向,需要建立庞大且复杂的分类体系,这个过程十分不易

Benefits of technology

[0045]与现有技术相比,本申请通过获取关于投诉的预设数量的工单文本,并对所述预设数量的工单文本进行数据预处理,得到所述预设数量的预处理后的工单文本,所述预设数量包括至少两个;对所述预设数量的预处理后的工单文本进行文本聚类,得到不同诉求中的每种诉求对应的综合文本簇,每个所述综合文本簇包括至少一个预处理后的工单文本;对每种诉求对应的综合文本簇分别进行关键词提取操作和主题词生成操作,得到每种诉求对应的综合文本簇的关键词和主题词;对每种诉求对应的综合文本簇的关键词和主题词,以可视化的形式进行展示,实现了简单、高效地来挖掘关于投诉的工单文本中的重要信息,并将工单文本形成的文本簇的关键词和主题词进行可视化形式的展示,整个过程方便直观地帮助实际应用场景中的热线中心等及时发现工单文本中存在的各种诉求内容以及对应工单文本的关键信息,为后续的处理和决策提供数据支持。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119128140B_ABST
    Figure CN119128140B_ABST
Patent Text Reader

Abstract

The application aims to provide a work order text processing method and device. A preset number of work order texts about complaints are obtained, and data preprocessing is performed on the preset number of work order texts to obtain a preset number of preprocessed work order texts, the preset number including at least two. Text clustering is performed on the preset number of preprocessed work order texts to obtain a comprehensive text cluster corresponding to each type of appeal in different appeals, each comprehensive text cluster including at least one preprocessed work order text. Key word extraction operation and theme word generation operation are performed on the comprehensive text cluster corresponding to each type of appeal respectively to obtain key words and theme words of the comprehensive text cluster corresponding to each type of appeal. The key words and theme words of the comprehensive text cluster corresponding to each type of appeal are displayed in a visual form, important information in the work order texts about complaints is simply and efficiently mined, and the key words and theme words are displayed in a visual form.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a method and apparatus for processing work order text. Background Technology

[0002] In existing technologies, some large public service hotlines handle thousands of complaints and feedback daily. These complaints often involve multiple aspects such as service quality, policy implementation, and public safety, and are of great significance for maintaining social stability and enhancing the government's image. Faced with such a large volume of complaints and feedback, simply relying on manual review and processing would undoubtedly consume significant human and material resources. Therefore, introducing automated and intelligent text analysis technologies to mine textual information from a large number of complaint requests becomes particularly necessary.

[0003] Existing methods for processing complaint forms involve establishing a hierarchical classification system. This involves using Natural Language Processing (NLP) techniques to create a classification model and categorize different complaint forms. This approach allows for better organization and management of large volumes of complaint forms, facilitating better understanding and handling of complaints by professionals. However, existing methods for processing publicly available complaint texts also have the following drawbacks:

[0004] First, the scope of the complaints is very broad, so in order to cover these areas as much as possible, a large and complex classification system needs to be established, which is a very difficult process.

[0005] Secondly, the number of work orders of different types exhibits a severe long-tail distribution, meaning that most work order texts are concentrated in a few popular categories, while the remaining work orders are scattered in other less popular categories. This increases the difficulty of building a classification model, especially for work order texts belonging to less popular categories, where the model's classification performance may be poor. Therefore, in order to ensure that the model performs evenly across different categories, it is necessary to accumulate data on work order data of less popular categories over a long period of time, which in turn leads to a longer time consumption for the entire model building process.

[0006] Finally, the results presented are not intuitive enough and lack a visual information display process. Summary of the Invention

[0007] One objective of this application is to provide a method and device for processing work order texts, which enables a simple and efficient extraction of important information from work order texts related to complaints, and to visualize the keywords and themes of the text clusters formed by the work order texts. The entire process is convenient and intuitive, helping hotline centers and other real-world application scenarios to promptly identify various requests and key information in work order texts, providing data support for subsequent processing and decision-making.

[0008] According to one aspect of this application, a method for processing work order text is provided, wherein the method includes:

[0009] Obtain a preset number of work order texts related to complaints, and perform data preprocessing on the preset number of work order texts to obtain the preset number of preprocessed work order texts, wherein the preset number includes at least two.

[0010] The preset number of preprocessed work order texts are clustered to obtain a comprehensive text cluster corresponding to each of the different requests, and each comprehensive text cluster includes at least one preprocessed work order text.

[0011] For each type of claim, keyword extraction and topic term generation operations are performed on the comprehensive text clusters corresponding to each claim to obtain the keywords and topic terms for each type of claim's comprehensive text clusters.

[0012] The keywords and themes of the comprehensive text clusters corresponding to each claim are displayed in a visual format.

[0013] Further, in the above method, the step of preprocessing the preset number of work order texts to obtain a preset number of preprocessed work order texts includes:

[0014] Obtain a pre-defined general stop word lexicon and a constructed professional stop word lexicon; wherein, the professional stop word lexicon is obtained by sequentially processing historical work order texts related to complaints through word segmentation, word frequency statistics, and manual screening;

[0015] Based on the general stop word lexicon and the professional stop word lexicon, each work order text in the preset number of work order texts is sequentially processed by word segmentation, stop word removal, and valid word retention to obtain the preset number of preprocessed work order texts.

[0016] Furthermore, in the above method, the step of performing text clustering on the preset number of preprocessed work order texts to obtain comprehensive text clusters corresponding to each of the different requests, wherein each comprehensive text cluster includes at least one preprocessed work order text, including:

[0017] The density-based clustering algorithm HDBSCAN is used to perform initial clustering on the preset number of preprocessed work order texts to obtain at least two candidate text clusters, each of which includes at least one preprocessed work order text.

[0018] The cluster-term-inverse text frequency index (C-TF-IDF) algorithm and the density-based clustering algorithm (HDBSCAN) are used to perform secondary clustering on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each of the different requests. Each of the clustered text clusters includes at least one preprocessed work order text.

[0019] After the secondary clustering, it is determined whether there are any unclustered discrete work order texts among the preset number of preprocessed work order texts.

[0020] If not, then the clustered text cluster corresponding to each claim will be determined as the comprehensive text cluster corresponding to each claim;

[0021] If so, the discrete work order texts are merged based on the clustered text clusters corresponding to each request to obtain a comprehensive text cluster corresponding to each request in different requests, and each comprehensive text cluster includes at least one preprocessed work order text.

[0022] Furthermore, in the above method, the density-based clustering algorithm HDBSCAN is used to perform initial clustering on the preset number of preprocessed work order texts to obtain at least two candidate text clusters, including:

[0023] The semantic vector model BGE is used to obtain the sentence vector of each of the preprocessed work order texts in the preset number of preprocessed work order texts;

[0024] The Unified Manifold Approximation and Projection (UMAP) dimensionality reduction algorithm is used to reduce the dimensionality of the sentence vectors of each preprocessed work order text, thereby obtaining the dimensionality-reduced sentence vectors corresponding to each preprocessed work order text.

[0025] The dimensionality-reduced sentence vector corresponding to each preprocessed work order text is clustered using the density-based clustering algorithm HDBSCAN to obtain at least two candidate text clusters.

[0026] Furthermore, in the above method, the use of the Cluster-Term Frequency-Inverse Text Frequency Index (C-TF-IDF) algorithm and the density-based clustering algorithm HDBSCAN to perform secondary clustering on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each claim in different claims includes:

[0027] The C-TF-IDF algorithm is used to construct a vocabulary of words in the preprocessed work order text of the preset number of words, and the C-TF-IDF value of each word in the vocabulary is calculated. The vocabulary contains N words, where N is a positive integer greater than or equal to 2.

[0028] At least one preprocessed work order text in each of the at least two candidate text clusters is represented by a set of words in the vocabulary to form an N-dimensional vector;

[0029] In each candidate text cluster, the C-TF-IDF value of each word contained in each candidate text cluster is multiplied by the N-dimensional vector to obtain the vector representation of each candidate text cluster;

[0030] Based on the vector representation of each candidate text cluster and the density-based clustering algorithm HDBSCAN, a secondary clustering is performed on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each claim in different claims.

[0031] Furthermore, in the above method, the step of merging the discrete work order texts based on the clustered text clusters corresponding to each request to obtain a comprehensive text cluster corresponding to each request in different requests includes:

[0032] The vector representation of the discrete work order text is calculated using the Cluster-Term Frequency-Inverse Text Frequency Index (C-TF-IDF) algorithm.

[0033] The vector representation of the discrete work order text is compared with the vector representation of each candidate text cluster by calculating the cosine similarity to obtain the first similarity between the discrete work order text and each candidate text cluster.

[0034] If there exists a first similarity greater than a preset first similarity threshold, then the candidate text cluster corresponding to the largest first similarity is merged with the discrete work order text. If there is no first similarity greater than the first similarity threshold, then the discrete work order text is discarded or a new text cluster is added and the discrete work order text is assigned to the new text cluster to obtain a comprehensive text cluster corresponding to each of the different requests.

[0035] Furthermore, in the above method, the step of performing keyword extraction and topic term generation operations on the comprehensive text cluster corresponding to each claim to obtain the keywords and topic terms of the comprehensive text cluster corresponding to each claim includes:

[0036] For each of the comprehensive text clusters, obtain the C-TF-IDF values ​​of all words in at least one preprocessed work order text, and sort all words in reverse order according to the C-TF-IDF values. The first number of sorted words are taken as the keywords of the comprehensive text cluster.

[0037] A large model for generating keywords is determined; for each of the comprehensive text clusters, a cosine similarity is calculated between the vector representation of each preprocessed work order text in the comprehensive text cluster and the vector representation of the comprehensive text cluster to obtain a second similarity between the comprehensive text cluster and each of the preprocessed work order texts therein, and the second-highest number of preprocessed work order texts with the highest second similarity are taken as representative work order texts of the comprehensive text cluster; the representative work order texts of each of the comprehensive text clusters are input into the large model to generate keywords for each of the comprehensive text clusters.

[0038] Furthermore, in the above method, the keywords and thematic terms of the comprehensive text cluster corresponding to each claim are displayed in a visual form, including:

[0039] The keywords and themes of the comprehensive text clusters corresponding to each claim are displayed in the form of word clouds or association diagrams.

[0040] According to another aspect of this application, a non-volatile storage medium is also provided, on which computer-readable instructions are stored, which, when executed by a processor, cause the processor to implement the above-described method for processing work order text.

[0041] According to another aspect of this application, a work order text processing device is also provided, wherein the device includes:

[0042] One or more processors;

[0043] Computer-readable medium for storing one or more computer-readable instructions.

[0044] When the one or more computer-readable instructions are executed by the one or more processors, the one or more processors implement the work order text processing method described above.

[0045] Compared with existing technologies, this application obtains a preset number of work order texts related to complaints, and preprocesses these texts to obtain a preset number of preprocessed work order texts, where the preset number includes at least two. It then performs text clustering on these preprocessed work order texts to obtain comprehensive text clusters corresponding to each type of complaint, with each comprehensive text cluster including at least one preprocessed work order text. For each type of comprehensive text cluster, it performs keyword extraction and topic word generation operations to obtain keywords and topic words for each type of comprehensive text cluster. Finally, it visualizes the keywords and topic words of each type of comprehensive text cluster, achieving a simple and efficient way to extract important information from work order texts related to complaints. The entire process conveniently and intuitively helps hotline centers and other real-world application scenarios to promptly identify various complaint contents and key information in work order texts, providing data support for subsequent processing and decision-making. Attached Figure Description

[0046] Other features, objects, and advantages of this application will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings:

[0047] Figure 1 A flowchart illustrating a method for processing work order text according to one aspect of this application is shown.

[0048] Figure 2 This diagram illustrates the processing flow of a work order text processing method according to one aspect of this application in a practical application scenario.

[0049] Figure 3 This diagram illustrates text clustering in a work order text processing method according to one aspect of this application;

[0050] Figure 4 This diagram illustrates the acquisition of training corpus for training a large model in a method for processing work order text according to one aspect of this application.

[0051] Figure 5 This diagram illustrates a visualization of keywords and subject terms in a work order text processing method according to one aspect of this application.

[0052] The same or similar reference numerals in the accompanying drawings represent the same or similar parts. Detailed Implementation

[0053] The present application will now be described in further detail with reference to the accompanying drawings.

[0054] In a typical configuration of this application, the terminal, the device of the service network, and the trusted party all include one or more processors (CPUs), input / output interfaces, network interfaces, and memory.

[0055] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0056] Computer-readable media include both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include non-transitory computer-readable media, such as modulated data signals and carrier waves.

[0057] like Figure 1 As shown, Figure 1 This application provides a flowchart illustrating a method for processing work order texts. This method is applied in the processing of complaint or problem feedback centers or customer service centers that handle work order texts, enabling data mining of large volumes of work order texts. The processing of work order texts includes, for example... Figure 2 The data preprocessing, text clustering, keyword extraction, topic term generation, and visualization modules are shown. The method includes steps S11, S12, S13, and S14, specifically comprising the following steps:

[0058] Step S11: Obtain a preset number of work order texts related to complaints, and perform data preprocessing on the preset number of work order texts to obtain the preset number of preprocessed work order texts. The preset number includes at least two. It should be noted that the preset number of work order texts related to complaints are the original work order texts that have been recorded and have not undergone any data processing.

[0059] Since each work order document records a specific request, in order to understand the different types of requests in a more detailed way, it is necessary to first cluster the work order documents in the face of a large number of work order documents. In step S12, text clustering is performed on the preset number of preprocessed work order documents to obtain a comprehensive text cluster corresponding to each type of request. Each comprehensive text cluster includes at least one preprocessed work order document.

[0060] Step S13: Perform keyword extraction and topic term generation operations on the comprehensive text clusters corresponding to each claim to obtain the keywords and topic terms of the comprehensive text clusters corresponding to each claim.

[0061] Step S14: The keywords and themes of the comprehensive text cluster corresponding to each claim are displayed in a visual form.

[0062] Through the above steps S11 to S15, important information in complaint work order texts can be extracted simply and efficiently. The keywords and themes of the text clusters formed by the work order texts are displayed in a visual form. The whole process is convenient and intuitive to help hotline centers and other real-world application scenarios to discover various demands and key information in work order texts in a timely manner, providing data support for subsequent processing and decision-making.

[0063] Following the above embodiments of this application, step S11 performs data preprocessing on the preset number of work order texts to obtain a preset number of preprocessed work order texts, specifically including:

[0064] Obtain a pre-defined general stop word lexicon and a constructed professional stop word lexicon; wherein, the professional stop word lexicon is obtained by sequentially processing historical work order texts related to complaints through word segmentation, word frequency statistics, and manual screening;

[0065] Based on the general stop word lexicon and the professional stop word lexicon, each work order text in the preset number of work order texts is sequentially processed by word segmentation, stop word removal, and valid word retention to obtain the preset number of preprocessed work order texts.

[0066] In this embodiment, step S11 requires removing some words from the work order text that interfere with subsequent key steps such as clustering and keyword extraction. For example, phrases such as "citizens reported" appear frequently in the work order text about complaints, which will affect the effect of text clustering and keyword extraction in subsequent steps. Therefore, these meaningless words need to be removed in step S11. The specific steps are as follows: First, a pre-defined professional stop word lexicon is constructed. During this construction, historical work order texts related to complaints are sequentially segmented and frequency-counted. Words with high frequencies are selected as candidate words, and these are then manually filtered to obtain usable stop words, thus forming the professional stop word lexicon. The historical work order texts here are based on the current time; however, work order texts corresponding to the current time at a future point in time can also be considered historical work order texts. When constructing the professional stop word lexicon, a general stop word lexicon is also pre-defined to meet different practical application scenarios. Then, the general stop word lexicon and the professional stop word lexicon are obtained. Finally, using the obtained general and professional stop word lexicons, each work order text in the pre-defined number of work order texts is segmented. Stop words are then removed from the segmented texts, and the remaining words are merged to form a pre-processed work order text. This achieves data preprocessing of the original work order text, ensuring the accuracy of subsequent keyword extraction and topic term generation.

[0067] Following the above embodiments of this application, step S12 performs text clustering on the preset number of preprocessed work order texts to obtain comprehensive text clusters corresponding to each of the different requests. Each comprehensive text cluster includes at least one preprocessed work order text, specifically including:

[0068] The density-based clustering algorithm HDBSCAN is used to perform initial clustering on the preset number of preprocessed work order texts to obtain at least two candidate text clusters, each of which includes at least one preprocessed work order text.

[0069] The cluster-term-inverse text frequency index (C-TF-IDF) algorithm and the density-based clustering algorithm (HDBSCAN) are used to perform secondary clustering on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each of the different requests. Each of the clustered text clusters includes at least one preprocessed work order text.

[0070] After the secondary clustering, it is determined whether there are any unclustered discrete work order texts among the preset number of preprocessed work order texts.

[0071] If not, then the clustered text cluster corresponding to each claim will be determined as the comprehensive text cluster corresponding to each claim;

[0072] If so, the discrete work order texts are merged based on the clustered text clusters corresponding to each request to obtain a comprehensive text cluster corresponding to each request in different requests, and each comprehensive text cluster includes at least one preprocessed work order text.

[0073] In step S12, text clustering is performed on a preset number of preprocessed work order texts, such as... Figure 3 As shown, when performing text clustering on the preprocessed work order texts, an unsupervised hierarchical clustering model can be used: the density-based clustering algorithm HDBSCAN is used to cluster work order texts related to complaints. This hierarchical clustering model has advantages such as not requiring predefined categories, being insensitive to outliers, and adapting to clustering data of any shape, making it very convenient to use. Since a single clustering may produce similar text clusters, a two-step clustering method is used in this application to address this issue when performing text clustering on the preprocessed work order texts. The specific implementation of the two-step clustering method is as follows:

[0074] First, the density-based clustering algorithm HDBSCAN is used to perform initial clustering on the preset number of preprocessed work order texts to obtain at least two candidate text clusters, each of which includes at least one preprocessed work order text.

[0075] Then, since there are often many similar text clusters in the at least two candidate text clusters obtained after the initial clustering, it is necessary to merge these similar text clusters. Therefore, the cluster-term-inverse text frequency index (C-TF-IDF) algorithm and the density-based clustering algorithm HDBSCAN are used to perform secondary clustering on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each of the different requests. Each clustered text cluster includes at least one preprocessed work order text.

[0076] Finally, after the secondary clustering, since the results of clustering using the density-based clustering algorithm HDBSCAN may contain a large number of discrete work order texts (i.e., work order texts not appearing in any of the clustered text clusters after the secondary clustering), it is necessary to determine whether to merge the discrete work order texts with the existing clustered text clusters. That is, it is necessary to determine whether there are any un-clustered discrete work order texts among the preset number of preprocessed work order texts. If not, the clustered text clusters corresponding to each request are determined as the comprehensive text clusters corresponding to each request, and there is no need to merge the discrete work order texts. If so, in order to reduce the number of discrete work order texts, it is necessary to merge the discrete work order texts based on the clustered text clusters corresponding to each request to obtain comprehensive text clusters corresponding to each request in different requests. Each comprehensive text cluster includes at least one preprocessed work order text, thereby realizing the merging and clustering of discrete work order texts.

[0077] Following the above embodiments of this application, step S12, which uses the density-based clustering algorithm HDBSCAN to perform initial clustering on the preset number of preprocessed work order texts to obtain at least two candidate text clusters, specifically includes:

[0078] First, the semantic vector model BGE is used to obtain the sentence vector of each of the preprocessed work order texts in the preset number of preprocessed work order texts. Here, in the process of obtaining the sentence vector of each of the preprocessed work order texts using the semantic vector model BGE, the sentence-transformer library in Python can be used for loading. The semantic vector model BGE is a general BGE model obtained after domain-specific incremental pre-training on work order text data.

[0079] Then, the Unified Manifold Approximation and Projection (UMAP) dimensionality reduction algorithm is used to perform vector dimensionality reduction on the sentence vector of each preprocessed work order text in order to extract the main feature components of the text, thereby obtaining the dimensionality-reduced sentence vector corresponding to each preprocessed work order text.

[0080] Finally, the dimensionality-reduced sentence vector corresponding to each preprocessed work order text is clustered using the density-based clustering algorithm HDBSCAN to obtain at least two candidate text clusters, thereby achieving the initial clustering of a preset number of preprocessed work order texts.

[0081] Following the above embodiments of this application, step S12, which employs the cluster-term-inverse text frequency index (C-TF-IDF) algorithm and the density-based clustering algorithm HDBSCAN to perform secondary clustering on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each claim in different claims, specifically includes:

[0082] First, the C-TF-IDF algorithm is used to construct the vector representation of text clusters. The C-TF-IDF algorithm is an improved version of the TF-IDF algorithm and is suitable for representing the vector representation of text clusters. The specific formula for calculating the C-TF-IDF value of the C-TF-IDF algorithm is as follows:

[0083] W t,c =tf t,c log(1+A / df t )

[0084] Among them, tf t,cLet log(1+A / dft) represent the frequency of word t in text cluster c, where log(1+A / dft) is the inverse class frequency, A represents the average number of words in each cluster, and dft is the frequency of word t in text cluster c. t This indicates the number of times the word 't' appears in all clusters.

[0085] Then, the C-TF-IDF algorithm is used to construct a vocabulary for the words in the preprocessed work order text of the preset number of words, and the C-TF-IDF value of each word in the vocabulary is calculated. The number of words in the vocabulary is N, where N is a positive integer greater than or equal to 2.

[0086] Next, at least one preprocessed work order text in each of the at least two candidate text clusters is represented by a set of words from the vocabulary to form an N-dimensional vector;

[0087] Secondly, in each candidate text cluster, the C-TF-IDF value of each word contained in each candidate text cluster is multiplied by the N-dimensional vector to obtain the vector representation of each candidate text cluster;

[0088] Finally, based on the vector representation of each candidate text cluster and the density-based clustering algorithm HDBSCAN, a secondary clustering is performed on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each type of appeal. For example, assuming the vocabulary contains N words, the C-TF-IDF values ​​of these N words are calculated. When constructing the vector representation of the text cluster, for each candidate text cluster, which contains multiple work order texts, it can be represented by a set of words from the vocabulary. Therefore, the bag-of-words model can be used to represent it as an N-dimensional vector. This N-dimensional vector is then multiplied by the C-TF-IDF weight of each word to obtain the text cluster vector, thereby determining the vector representation of each text cluster.

[0089] Following the above embodiments of this application, step S12, which involves merging the discrete work order texts based on the clustered text clusters corresponding to each claim to obtain a comprehensive text cluster corresponding to each claim in different claims, specifically includes:

[0090] The vector representation of the discrete work order text is calculated using the Cluster-Term Frequency-Inverse Text Frequency Index (C-TF-IDF) algorithm.

[0091] The vector representation of the discrete work order text is compared with the vector representation of each candidate text cluster by calculating the cosine similarity to obtain the first similarity between the discrete work order text and each candidate text cluster.

[0092] If there exists a first similarity greater than a preset first similarity threshold, then the candidate text cluster corresponding to the largest first similarity is merged with the discrete work order text. If there is no first similarity greater than the first similarity threshold, then the discrete work order text is discarded or a new text cluster is added and the discrete work order text is assigned to the new text cluster to obtain a comprehensive text cluster corresponding to each of the different requests.

[0093] For example, the C-TF-IDF algorithm is first used to calculate the vector representation of each outlier work order text. Then, the cosine similarity between the vector representation of each outlier work order text and the vector representations of all candidate text clusters is calculated. A first similarity threshold is set. If there is a case where the first similarity is greater than the first similarity threshold, the candidate text cluster corresponding to the largest first similarity is selected and merged with the outlier work order text. If there is no case where the first similarity is greater than the first similarity threshold, the text is not merged. There are two cases for not merging: either the outlier work order text is discarded, or a new text cluster is added to the outlier work order text. This results in a comprehensive text cluster corresponding to each of the different requests, which can greatly reduce the number of outlier work order texts.

[0094] Following the above embodiments of this application, for each text cluster, the keyword is the extraction and summary of the demands expressed by the information carried in the preprocessed work order text within the text cluster. Traditional methods such as TF-IDF directly mine keyword information from the text, lacking a refinement and processing process. In the embodiments of this application, a large model is used to directly refine and summarize the work order text and generate keyword. That is, step S13 performs keyword extraction and keyword generation operations on the comprehensive text cluster corresponding to each demand, respectively, to obtain the keywords and keyword of the comprehensive text cluster corresponding to each demand, specifically including:

[0095] For each of the comprehensive text clusters, obtain the C-TF-IDF values ​​of all words in at least one preprocessed work order text, and sort all words in reverse order according to the C-TF-IDF values. The first number of sorted words are taken as the keywords of the comprehensive text cluster, so as to realize the extraction of keywords in each comprehensive text cluster.

[0096] A large model for generating keyword terms is determined; for each comprehensive text cluster, a cosine similarity is calculated between the vector representation of each preprocessed work order text in the comprehensive text cluster and the vector representation of the comprehensive text cluster, to obtain a second similarity between the comprehensive text cluster and each preprocessed work order text therein, and the second number of preprocessed work order texts with the highest second similarity are taken as representative work order texts of the comprehensive text cluster; the representative work order texts of each comprehensive text cluster are input into the large model to generate keyword terms for each comprehensive text cluster. Here, the second number can be any value; in a preferred embodiment of this application, the second number is preferably 10.

[0097] In this embodiment, the following five steps are required when generating keywords:

[0098] I. Model Selection. Considering both data sensitivity and inference time constraints, in one embodiment of this application, the open-source big oracle model baichuan2-7B-Base is selected as the base model. On the one hand, baichuan2-7B-Base, as an open-source model, can be deployed locally, solving the data sensitivity problem; on the other hand, the 7B-scale model, after inference speed optimization, can basically meet the enterprise's requirements for inference time.

[0099] II. Selection of Representative Work Order Texts. It is important to note that large models have limitations on the length of input text, and a text cluster often contains a large number of work order texts. Inputting all of them could easily exceed the length limit. Therefore, it is necessary to select representative work order texts as input to the large model. The selection method is as follows: First, the vector representation of each preprocessed work order text in the text cluster is calculated using the Cluster-Term Frequency-Inverse Text Frequency Index (C-TF-IDF) algorithm. Then, cosine similarity is calculated between the vector representations of these representations and the vector representations of the candidate text clusters. The top 10 work order texts with the highest calculated second similarity are selected as representative work order texts.

[0100] III. Acquisition of training corpus for training the large model used to generate topic terms. baichuan2-7B-Base requires fine-tuning to acquire topic generation capabilities. Regarding the acquisition of training corpus required for fine-tuning, as follows... Figure 4 As shown. First, a batch of historical work order texts are obtained. After clustering, multiple text clusters are obtained, and representative work order texts are obtained from them. The representative work order texts in each text cluster are sent to a large model to generate topic words. After manual screening, the final training corpus is obtained. In a preferred embodiment of this application, the Qwen-72B-Chat model is selected as the large model for generating topic words.

[0101] IV. Fine-tuning of instructions: Full instruction fine-tuning was performed on baichuan2-7B-Base on 4 A100 sheets. The parameters were set as batch_size 64, learning rate 1e-4, and epochs 5. Warmup was used to warm up the learning rate in the first 0.1 proportional steps, and cosine annealing was used to adjust the learning rate.

[0102] V. Model Inference. During inference and prediction, representative work order texts from the text cluster are selected as input and fed into a large model for generating topic terms, thereby generating topic terms.

[0103] Following the above embodiments of this application, step S14 visualizes the keywords and themes of the comprehensive text cluster corresponding to each claim, specifically including:

[0104] The keywords and themes of the comprehensive text clusters corresponding to each claim are displayed in the form of word clouds or association diagrams.

[0105] In this embodiment, the visualization in step S14 displays the keywords and themes obtained in step S13 in a visual form such as a word cloud or a relational graph. For example... Figure 5 As shown, Figure 5 The left side of the image shows a word cloud of keywords, where the font size of the keywords measures the number of texts in the corresponding text cluster. Figure 5 The right image in the diagram is a relationship diagram of topic words and keywords. In the middle of the relationship diagram is the topic word, and the surrounding information connected to it is keywords and other information.

[0106] In the embodiments of this application, unsupervised clustering is used to classify the problems reflected in a large number of work order texts; keywords are extracted and topic terms are generated from the clustered text clusters, and the results are presented in a visual form such as word cloud and association diagram. This allows staff to quickly locate the main requests and understand the key information related to the main requests, thereby improving the efficiency of analyzing and processing work order texts.

[0107] According to another aspect of this application, a non-volatile storage medium is also provided, on which computer-readable instructions are stored, which, when executed by a processor, cause the processor to implement the work order text processing method described above.

[0108] According to another aspect of this application, a work order text processing device is also provided, wherein the device includes:

[0109] One or more processors;

[0110] Computer-readable medium for storing one or more computer-readable instructions.

[0111] When the one or more computer-readable instructions are executed by the one or more processors, the one or more processors implement the work order text processing method described above.

[0112] For details of the various embodiments of the work order text processing device, please refer to the corresponding parts of the above-described work order text processing method embodiments, which will not be repeated here.

[0113] In summary, this application obtains a preset number of work order texts related to complaints, performs data preprocessing on these texts to obtain a preset number of preprocessed work order texts (the preset number includes at least two); performs text clustering on these preprocessed work order texts to obtain comprehensive text clusters corresponding to each type of request, with each comprehensive text cluster including at least one preprocessed work order text; performs keyword extraction and topic term generation operations on each comprehensive text cluster corresponding to each request to obtain keywords and topic terms for each comprehensive text cluster; and displays the keywords and topic terms of each comprehensive text cluster in a visual format. This achieves a simple and efficient way to extract important information from work order texts related to complaints and visualizes the keywords and topic terms of the text clusters formed by the work order texts. The entire process conveniently and intuitively helps hotline centers and other entities in practical application scenarios to promptly identify various requests and key information in work order texts, providing data support for subsequent processing and decision-making.

[0114] It should be noted that this application can be implemented in software and / or a combination of software and hardware, for example, using an application-specific integrated circuit (ASIC), a general-purpose computer, or any other similar hardware device. In one embodiment, the software program of this application can be executed by a processor to implement the steps or functions described above. Similarly, the software program of this application (including related data structures) can be stored in a computer-readable recording medium, such as RAM memory, magnetic or optical drives, floppy disks, and similar devices. Furthermore, some steps or functions of this application can be implemented in hardware, for example, as circuitry that cooperates with a processor to perform the various steps or functions.

[0115] Furthermore, a portion of this application can be applied as a computer program product, such as computer program instructions, which, when executed by a computer, can invoke or provide the methods and / or technical solutions according to this application through the operation of the computer. The program instructions invoking the methods of this application may be stored in a fixed or removable recording medium, and / or transmitted via data streams in broadcast or other signal carrying media, and / or stored in the working memory of a computer device operating according to the program instructions. Here, one embodiment of this application includes an apparatus comprising a memory for storing computer program instructions and a processor for executing the program instructions, wherein, when the computer program instructions are executed by the processor, the apparatus is triggered to operate the methods and / or technical solutions based on the foregoing embodiments of this application.

[0116] It will be apparent to those skilled in the art that this application is not limited to the details of the exemplary embodiments described above, and that this application can be implemented in other specific forms without departing from the spirit or essential characteristics of this application. Therefore, the embodiments should be considered exemplary and non-limiting in all respects, and the scope of this application is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be embraced within this application. No reference numerals in the claims should be construed as limiting the scope of the claims. Furthermore, it is clear that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. Multiple units or devices recited in the apparatus claims may also be implemented by a single unit or device in software or hardware. The terms "first," "second," etc., are used to indicate names and do not indicate any particular order.

Claims

1. A method for processing work order text, wherein, The method includes: Obtain a preset number of work order texts related to complaints, and perform data preprocessing on the preset number of work order texts to obtain the preset number of preprocessed work order texts, wherein the preset number includes at least two. The preset number of preprocessed work order texts are clustered to obtain a comprehensive text cluster corresponding to each of the different requests, and each comprehensive text cluster includes at least one preprocessed work order text. For each type of claim, keyword extraction and topic term generation operations are performed on the comprehensive text clusters corresponding to each claim to obtain the keywords and topic terms for each type of claim's comprehensive text clusters. The keywords and themes of the comprehensive text clusters corresponding to each claim are displayed in a visual form; Specifically, the process of performing text clustering on the preset number of preprocessed work order texts to obtain comprehensive text clusters corresponding to each of the different requests, wherein each comprehensive text cluster includes at least one preprocessed work order text, including: The density-based clustering algorithm HDBSCAN is used to perform initial clustering on the preset number of preprocessed work order texts to obtain at least two candidate text clusters, each of which includes at least one preprocessed work order text. The cluster-term-inverse text frequency index (C-TF-IDF) algorithm and the density-based clustering algorithm (HDBSCAN) are used to perform secondary clustering on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each of the different requests. Each of the clustered text clusters includes at least one preprocessed work order text. After the secondary clustering, it is determined whether there are any unclustered discrete work order texts among the preset number of preprocessed work order texts. If not, then the clustered text cluster corresponding to each claim will be determined as the comprehensive text cluster corresponding to each claim; If so, the discrete work order texts are merged based on the clustered text clusters corresponding to each request to obtain a comprehensive text cluster corresponding to each request in different requests, and each comprehensive text cluster includes at least one preprocessed work order text.

2. The method according to claim 1, wherein, The step of preprocessing the preset number of work order texts to obtain a preset number of preprocessed work order texts includes: Obtain a pre-defined general stop word lexicon and a constructed professional stop word lexicon; wherein, the professional stop word lexicon is obtained by sequentially processing historical work order texts related to complaints through word segmentation, word frequency statistics, and manual screening; Based on the general stop word lexicon and the professional stop word lexicon, each work order text in the preset number of work order texts is sequentially processed by word segmentation, stop word removal, and valid word retention to obtain the preset number of preprocessed work order texts.

3. The method according to claim 1, wherein, The density-based clustering algorithm HDBSCAN is used to perform initial clustering on the preset number of preprocessed work order texts, resulting in at least two candidate text clusters, including: The semantic vector model BGE is used to obtain the sentence vector of each of the preprocessed work order texts in the preset number of preprocessed work order texts; The Unified Manifold Approximation and Projection (UMAP) dimensionality reduction algorithm is used to reduce the dimensionality of the sentence vectors of each preprocessed work order text, thereby obtaining the dimensionality-reduced sentence vectors corresponding to each preprocessed work order text. The dimensionality-reduced sentence vector corresponding to each preprocessed work order text is clustered using the density-based clustering algorithm HDBSCAN to obtain at least two candidate text clusters.

4. The method according to claim 1, wherein, The cluster-term-inverse text frequency index (C-TF-IDF) algorithm and the density-based clustering algorithm HDBSCAN are used to perform secondary clustering on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each claim in different claims, including: The C-TF-IDF algorithm is used to construct a vocabulary of words in the preprocessed work order text of the preset number of words, and the C-TF-IDF value of each word in the vocabulary is calculated. The vocabulary contains N words, where N is a positive integer greater than or equal to 2. At least one preprocessed work order text in each of the at least two candidate text clusters is represented by a set of words in the vocabulary to form an N-dimensional vector; In each candidate text cluster, the C-TF-IDF value of each word contained in each candidate text cluster is multiplied by the N-dimensional vector to obtain the vector representation of each candidate text cluster; Based on the vector representation of each candidate text cluster and the density-based clustering algorithm HDBSCAN, a secondary clustering is performed on the at least two candidate text clusters to obtain the clustered text clusters corresponding to each claim in different claims.

5. The method according to claim 4, wherein, The process of merging the discrete work order texts based on the clustered text clusters corresponding to each request to obtain a comprehensive text cluster corresponding to each request in different requests includes: The vector representation of the discrete work order text is calculated using the Cluster-Term Frequency-Inverse Text Frequency Index (C-TF-IDF) algorithm. The vector representation of the discrete work order text is compared with the vector representation of each of the clustered text clusters using cosine similarity calculation to obtain the first similarity between the discrete work order text and each of the clustered text clusters. If there is a first similarity greater than the preset first similarity threshold, the clustered text cluster corresponding to the highest first similarity is merged with the discrete work order text. If there is no first similarity greater than the first similarity threshold, the discrete work order text is discarded or a new text cluster is added and the discrete work order text is assigned to the new text cluster to obtain a comprehensive text cluster corresponding to each of the different requests.

6. The method according to claim 4, wherein, The process involves performing keyword extraction and topic term generation operations on the comprehensive text clusters corresponding to each claim, resulting in keywords and topic terms for each claim's comprehensive text cluster, including: For each of the comprehensive text clusters, obtain the C-TF-IDF values ​​of all words in at least one preprocessed work order text, and sort all words in reverse order according to the C-TF-IDF values. The first number of sorted words are taken as the keywords of the comprehensive text cluster. A large model for generating keywords is determined; for each of the comprehensive text clusters, the cosine similarity between the vector representation of each preprocessed work order text in the comprehensive text cluster and the vector representation of the comprehensive text cluster is calculated to obtain the second similarity between the comprehensive text cluster and each of the preprocessed work order texts therein, and the second number of preprocessed work order texts with the highest second similarity are taken as the representative work order texts of the comprehensive text cluster; the representative work order texts of each of the comprehensive text clusters are input into the large model to generate keywords for each of the comprehensive text clusters.

7. The method according to any one of claims 1 to 6, wherein, The keywords and themes of the comprehensive text clusters corresponding to each claim are displayed in a visual form, including: The keywords and themes of the comprehensive text clusters corresponding to each claim are displayed in the form of word clouds or association diagrams.

8. A non-volatile storage medium having stored computer-readable instructions thereon, which, when executed by a processor, cause the processor to perform the method as described in any one of claims 1 to 7.

9. A device for processing work order text, wherein, The device includes: One or more processors; Computer-readable medium for storing one or more computer-readable instructions. When the one or more computer-readable instructions are executed by the one or more processors, the one or more processors cause the one or more processors to implement the method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Classification processing method and device for consultation type work orders, storage medium and electronic equipment

    CN117648438A

  • Text information clustering method and text information clustering system

    US20180365218A1